链接混淆字符串改为动态加载
This commit is contained in:
parent
34b1fdaadf
commit
77d0c0f077
@ -31,7 +31,6 @@
|
|||||||
目标分辨率:<el-select v-model="targetResolution">
|
目标分辨率:<el-select v-model="targetResolution">
|
||||||
<el-option v-for="(fileSize, resolution) in preDownloadGallery.availableResolution" :value="resolution"
|
<el-option v-for="(fileSize, resolution) in preDownloadGallery.availableResolution" :value="resolution"
|
||||||
:label="modify(resolution, fileSize)">
|
:label="modify(resolution, fileSize)">
|
||||||
|
|
||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</tr>
|
</tr>
|
||||||
@ -83,7 +82,11 @@ export default {
|
|||||||
return store.getters.preDownloadVideo
|
return store.getters.preDownloadVideo
|
||||||
})
|
})
|
||||||
|
|
||||||
const loadComplete = computed(() => {
|
let maskDomain = computed(() => {
|
||||||
|
return store.getters.maskDomain
|
||||||
|
})
|
||||||
|
|
||||||
|
let loadComplete = computed(() => {
|
||||||
return store.getters.loadComplete
|
return store.getters.loadComplete
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -157,19 +160,10 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function coverLink(rawLink){
|
function coverLink(rawLink){
|
||||||
let tempLink = ""
|
maskDomain.value.forEach((mask) => {
|
||||||
if(rawLink.includes("hentai")) {
|
rawLink = rawLink.replace(mask['raw'], mask['mask'])
|
||||||
if (rawLink.includes("exhentai.org"))
|
})
|
||||||
tempLink = rawLink.replace("exhentai.org", "element-plus.org")
|
return rawLink;
|
||||||
else if (rawLink.includes("e-hentai.org"))
|
|
||||||
tempLink = rawLink.replace("e-hentai.org", "element.org")
|
|
||||||
}
|
|
||||||
else if(rawLink.includes("xvideos.com") || rawLink.includes("pornhub.com")){
|
|
||||||
tempLink = rawLink.replace("xvideos.com", "xiaomi.com").
|
|
||||||
replace("cn.pornhub.com", "pixiv.com").
|
|
||||||
replace("pornhub.com", "pixiv.com")
|
|
||||||
}
|
|
||||||
return tempLink;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function validateLink(rawLink){
|
function validateLink(rawLink){
|
||||||
@ -222,8 +216,7 @@ export default {
|
|||||||
isRemember,
|
isRemember,
|
||||||
preDownloadGallery,
|
preDownloadGallery,
|
||||||
preDownloadVideo,
|
preDownloadVideo,
|
||||||
targetResolution,
|
targetResolution
|
||||||
store
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -120,6 +120,7 @@ const actions = {
|
|||||||
context.commit("_authed", AuthCode, context)
|
context.commit("_authed", AuthCode, context)
|
||||||
context.dispatch("updateGalleryTasks").then()
|
context.dispatch("updateGalleryTasks").then()
|
||||||
context.dispatch("updateVideoTasks").then()
|
context.dispatch("updateVideoTasks").then()
|
||||||
|
context.dispatch("loadMaskDomain").then()
|
||||||
setInterval(() => {
|
setInterval(() => {
|
||||||
context.dispatch("update").then()
|
context.dispatch("update").then()
|
||||||
}, 30000)
|
}, 30000)
|
||||||
@ -135,6 +136,13 @@ const actions = {
|
|||||||
else
|
else
|
||||||
context.dispatch("updateGalleryTasks").then()
|
context.dispatch("updateGalleryTasks").then()
|
||||||
},
|
},
|
||||||
|
loadMaskDomain(context){
|
||||||
|
axios.get(BaseUrl + "maskDomain").then((res) => {
|
||||||
|
if(res.data.result === "success"){
|
||||||
|
context.commit("_setMaskDomain", JSON.parse(res.data.data))
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
searchByLink(context, link){
|
searchByLink(context, link){
|
||||||
context.commit("_searchByLink", link)
|
context.commit("_searchByLink", link)
|
||||||
},
|
},
|
||||||
@ -304,6 +312,9 @@ const mutations = {
|
|||||||
_setShowType(state, showType){
|
_setShowType(state, showType){
|
||||||
state.showType = showType
|
state.showType = showType
|
||||||
},
|
},
|
||||||
|
_setMaskDomain(state, maskDomain){
|
||||||
|
state.maskDomain = maskDomain
|
||||||
|
},
|
||||||
_openHistoryPanel(state){
|
_openHistoryPanel(state){
|
||||||
state.isShowHistory = true
|
state.isShowHistory = true
|
||||||
},
|
},
|
||||||
@ -329,7 +340,9 @@ const state = {
|
|||||||
isInclude:false, //是否搜索到任务
|
isInclude:false, //是否搜索到任务
|
||||||
searchTask:[], //搜索到的任务
|
searchTask:[], //搜索到的任务
|
||||||
isShowHistory:false, //是否打开面板
|
isShowHistory:false, //是否打开面板
|
||||||
showType:"gallery"
|
showType:"gallery",
|
||||||
|
|
||||||
|
maskDomain:[]
|
||||||
}
|
}
|
||||||
|
|
||||||
const getters = {
|
const getters = {
|
||||||
@ -390,6 +403,9 @@ const getters = {
|
|||||||
},
|
},
|
||||||
showType(state){
|
showType(state){
|
||||||
return state.showType
|
return state.showType
|
||||||
|
},
|
||||||
|
maskDomain(state){
|
||||||
|
return state.maskDomain
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user