mirror of
https://github.com/Kuingsmile/PicList.git
synced 2025-03-13 08:28:13 -04:00
✨ Feature(custom): support picbed name click to config page
This commit is contained in:
parent
868407f123
commit
48cfaab0eb
@ -16,9 +16,7 @@
|
|||||||
@click="handleNameClick"
|
@click="handleNameClick"
|
||||||
>
|
>
|
||||||
{{ picBedName }} {{ $T('SETTINGS') }}</span>
|
{{ picBedName }} {{ $T('SETTINGS') }}</span>
|
||||||
<el-icon
|
<el-icon>
|
||||||
v-if="linkToLogInList.includes(picBedName)"
|
|
||||||
>
|
|
||||||
<Link />
|
<Link />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
<el-button
|
<el-button
|
||||||
@ -201,34 +199,29 @@ const handleReset = async () => {
|
|||||||
$router.back()
|
$router.back()
|
||||||
}
|
}
|
||||||
|
|
||||||
const linkToLogInList = ['GitHub', '腾讯云COS', '阿里云OSS', 'SM.MS', '七牛云', 'Imgur', '又拍云', 'githubPlus']
|
|
||||||
|
|
||||||
function handleNameClick () {
|
function handleNameClick () {
|
||||||
switch ($route.params.type) {
|
const typeUrlMap: IStringKeyMap = {
|
||||||
case 'github':
|
github: 'https://piclist.cn/configure.html#github%E5%9B%BE%E5%BA%8A',
|
||||||
case 'githubPlus':
|
githubPlus: 'https://piclist.cn/configure.html#github%E5%9B%BE%E5%BA%8A',
|
||||||
sendToMain(OPEN_URL, 'https://github.com')
|
tcyun: 'https://piclist.cn/configure.html#%E8%85%BE%E8%AE%AF%E4%BA%91cos',
|
||||||
break
|
aliyun: 'https://piclist.cn/configure.html#%E9%98%BF%E9%87%8C%E4%BA%91oss',
|
||||||
case 'tcyun':
|
smms: 'https://piclist.cn/configure.html#sm-ms',
|
||||||
sendToMain(OPEN_URL, 'https://cloud.tencent.com/login')
|
qiniu: 'https://piclist.cn/configure.html#%E4%B8%83%E7%89%9B%E4%BA%91',
|
||||||
break
|
imgur: 'https://piclist.cn/configure.html#imgur',
|
||||||
case 'aliyun':
|
upyun: 'https://piclist.cn/configure.html#%E5%8F%88%E6%8B%8D%E4%BA%91',
|
||||||
sendToMain(OPEN_URL, 'https://account.aliyun.com/login/login.htm')
|
'aws-s3-plist': 'https://piclist.cn/configure.html#%E5%86%85%E7%BD%AEaws-s3',
|
||||||
break
|
'aws-s3': 'https://piclist.cn/configure.html#%E5%86%85%E7%BD%AEaws-s3',
|
||||||
case 'smms':
|
local: 'https://piclist.cn/configure.html#%E6%9C%AC%E5%9C%B0%E5%9B%BE%E5%BA%8A',
|
||||||
sendToMain(OPEN_URL, 'https://smms.app')
|
lskyplist: 'https://piclist.cn/configure.html#%E5%85%B0%E7%A9%BA%E5%9B%BE%E5%BA%8A',
|
||||||
break
|
sftpplist: 'https://piclist.cn/configure.html#%E5%86%85%E7%BD%AEsftp',
|
||||||
case 'qiniu':
|
telegraphplist: 'https://piclist.cn/configure.html#telegra-ph',
|
||||||
sendToMain(OPEN_URL, 'https://portal.qiniu.com')
|
webdavplist: 'https://piclist.cn/configure.html#webdav',
|
||||||
break
|
piclist: 'https://piclist.cn/configure.html#piclist',
|
||||||
case 'imgur':
|
lankong: 'https://github.com/hellodk34/picgo-plugin-lankong'
|
||||||
sendToMain(OPEN_URL, 'https://imgur.com')
|
}
|
||||||
break
|
const url = typeUrlMap[$route.params.type as string]
|
||||||
case 'upyun':
|
if (url) {
|
||||||
sendToMain(OPEN_URL, 'https://console.upyun.com')
|
sendToMain(OPEN_URL, url)
|
||||||
break
|
|
||||||
default:
|
|
||||||
break
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user