Skip to content

Commit

Permalink
界面优化,节点整理
Browse files Browse the repository at this point in the history
  • Loading branch information
ljxi committed Oct 2, 2023
1 parent 668e38c commit 3a4de04
Show file tree
Hide file tree
Showing 5 changed files with 60 additions and 123 deletions.
Binary file removed src/assets/SPEED.png
Binary file not shown.
142 changes: 35 additions & 107 deletions src/assets/nodes.json
Original file line number Diff line number Diff line change
@@ -1,108 +1,36 @@
[{
"label": "高速",
"options": [
{
"value": "https://cd.pddpic.com/android_dev/2023-07-28/5c04772968aee57ca690fbe1e7f29467.apk",
"label": "并夕夕(华为云)"
},
{
"value": "https://consumer.huawei.com/content/dam/huawei-cbg-site/cn/mkt/harmonyos-3/video/privacy/privacy-safe-center.webm",
"label": "华为云"
},
{
"value": "https://cloud.video.taobao.com/play/u/null/p/1/e/6/t/1/d/ud/329682839911.mp4",
"label": "阿里CDN"
},
{
"value": "https://storage.jd.com/jdmobile/JDMALL-PC2.apk",
"label": "京东CDN"
},
{
"value": "https://ma75.gdl.netease.com/Sky_Gold_0.11.4_228509_obt_netease_unisec_minify_b16066d78995a9048c08e5552198a642.apk",
"label": "网易CDN"
},
{
"value": "https://f100.g.mi.com/download/AppStore/09b005af75fff45bd88ff8f37d7910ba550d32a07",
"label": "金山云"
},
{
"value": "https://mesh.if.iqiyi.com/player/upgrade/file/last/IQIYIsetup_app.exe",
"label": "爱奇艺"
},
{
"value": "https://devtools.qiniu.com/linux/amd64/qrsctl",
"label": "七牛云"
},
{
"value": "https://issuecdn.baidupcs.com/issue/netdisk/yunguanjia/BaiduNetdisk_7.30.5.2.exe",
"label": "百度CDN"
},
{
"value": "https://issuepcdn.baidupcs.com/issue/netdisk/yunguanjia/BaiduNetdisk_7.30.5.2.exe",
"label": "百度PCDN"
},
{
"value": "https://www.douyin.com/download/pc/obj/douyin-pc-client/7044145585217083655/releases/10715336/2.6.0/win32-ia32/douyin-v2.6.0-win32-ia32-douyinDownload1.exe",
"label": "字节跳动"
}
]
}, {
"label": "常用",
"options": [{
"value": "https://game.gtimg.cn/images/nz/web202106/index/bc_part1.gif?0.3190485611376561",
"label": "腾讯CDN"
},
{
"value": "https://wwwstatic.vivo.com.cn/vivoportal/files/resource/funtouch/1651200648928/images/os2-jude-video.mp4",
"label": "vivo(阿里CDN)"
},
{
"value": "https://d.musicapp.migu.cn/upload/fbpt_rsync_apps/local/signed/MobileMusic7350/MobileMusic7350_014000D.apk",
"label": "咪咕音乐"
},
{
"value": "https://img.cmvideo.cn/publish/noms/2022/10/14/1O3VIGPVP6HTS.jpg",
"label": "咪咕视频"
},
{
"value": "https://img.mcloud.139.com/material_prod/material_media/20221128/1669626861087.png",
"label": "和彩云"
},
{
"value": "https://s1.xmcdn.com/yx/xmly-live-release/last/dist/Ximalaya-Live-Setup-4.18.550.exe",
"label": "喜马拉雅(华为云)"
},
{
"value": "https://dc.xiaohongshu.com/file/pkgs/base/xiaohongshu.apk",
"label": "小红书(优云CDN)"
},
{
"value": "https://vod-origin-rjzy.gdoss.xstore.ctyun.cn/07da9eb52ad948c7b58b760003c0006b.mp4",
"label": "天翼云"
},
{
"value": "https://desk.ctyun.cn:8999/desktop-prod/software/windows_tob_client/15/64/202000005/CtyunClouddeskUniversal_2.0.0_202000005_x86_20230421161227_Setup_Signed.exe",
"label": "天翼云桌面"
},
{
"value": "https://h5cdn.migufun.com/middleh5/_nuxt/643447d.js",
"label": "咪咕快游"
},
{
"value": "https://listen.10155.com/listener/womusic-bucket/90115000/mv_vod/volte_mp4/20230215/1625752132487675906.mp4",
"label": "联通电视"
{
"高速":{
"并夕夕":"https://cd.pddpic.com/android_dev/2023-07-28/5c04772968aee57ca690fbe1e7f29467.apk",
"华为":"https://consumer.huawei.com/content/dam/huawei-cbg-site/cn/mkt/harmonyos-3/video/privacy/privacy-safe-center.webm",
"淘宝网":"https://cloud.video.taobao.com/play/u/null/p/1/e/6/t/1/d/ud/329682839911.mp4",
"京东":"https://storage.jd.com/jdmobile/JDMALL-PC2.apk",
"网易":"https://ma75.gdl.netease.com/Sky_Gold_0.11.4_228509_obt_netease_unisec_minify_b16066d78995a9048c08e5552198a642.apk",
"小米":"https://f100.g.mi.com/download/AppStore/09b005af75fff45bd88ff8f37d7910ba550d32a07",
"爱奇艺":"https://mesh.if.iqiyi.com/player/upgrade/file/last/IQIYIsetup_app.exe",
"字节跳动":"https://www.douyin.com/download/pc/obj/douyin-pc-client/7044145585217083655/releases/10715336/2.6.0/win32-ia32/douyin-v2.6.0-win32-ia32-douyinDownload1.exe"
},
"运营商":{
"联通电视":"https://listen.10155.com/listener/womusic-bucket/90115000/mv_vod/volte_mp4/20230215/1625752132487675906.mp4",
"咪咕音乐":"https://d.musicapp.migu.cn/upload/fbpt_rsync_apps/local/signed/MobileMusic7350/MobileMusic7350_014000D.apk",
"咪咕视频":"https://img.cmvideo.cn/publish/noms/2022/10/14/1O3VIGPVP6HTS.jpg",
"咪咕快游":"https://h5cdn.migufun.com/middleh5/_nuxt/643447d.js",
"和彩云":"https://img.mcloud.139.com/material_prod/material_media/20221128/1669626861087.png",
"天翼云":"https://vod-origin-rjzy.gdoss.xstore.ctyun.cn/07da9eb52ad948c7b58b760003c0006b.mp4",
"天翼云桌面":"https://desk.ctyun.cn:8999/desktop-prod/software/windows_tob_client/15/64/202000005/CtyunClouddeskUniversal_2.0.0_202000005_x86_20230421161227_Setup_Signed.exe",
"21CN直播":"https://review.21cn.com/img/20220926/1/1664177550543.mp4"
},
"常用":{
"腾讯":"https://game.gtimg.cn/images/nz/web202106/index/bc_part1.gif?0.3190485611376561",
"喜马拉雅":"https://s1.xmcdn.com/yx/xmly-live-release/last/dist/Ximalaya-Live-Setup-4.18.550.exe",
"小红书":"https://dc.xiaohongshu.com/file/pkgs/base/xiaohongshu.apk",
"vivo":"https://wwwstatic.vivo.com.cn/vivoportal/files/resource/funtouch/1651200648928/images/os2-jude-video.mp4",
"七牛云":"https://devtools.qiniu.com/linux/amd64/qrsctl",
"百度CDN":"https://issuecdn.baidupcs.com/issue/netdisk/yunguanjia/BaiduNetdisk_7.30.5.2.exe",
"百度PCDN":"https://issuepcdn.baidupcs.com/issue/netdisk/yunguanjia/BaiduNetdisk_7.30.5.2.exe"
},
"全球[Global]":{
"Cachefly Test":"https://cachefly.cachefly.net/200mb.test",
"Cloudflare Speed":"https://speed.cloudflare.com/__down?bytes=1073741824",
"Cloudflare Workers":"https://gh.con.sh/https://github.com/AaronFeng753/Waifu2x-Extension-GUI/releases/download/v2.21.12/Waifu2x-Extension-GUI-v2.21.12-Portable.7z"
}
]
}, {
"label": "全球[Global]",
"options": [{
"value": "https://cachefly.cachefly.net/200mb.test",
"label": "Cachefly Test"
}, {
"value": "https://speed.cloudflare.com/__down?bytes=1073741824",
"label": "Cloudflare Speed"
}, {
"value": "https://gh.con.sh/https://github.com/AaronFeng753/Waifu2x-Extension-GUI/releases/download/v2.21.12/Waifu2x-Extension-GUI-v2.21.12-Portable.7z",
"label": "Cloudflare Workers"
}]
}]
}
4 changes: 1 addition & 3 deletions src/components/IPinfo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -86,12 +86,10 @@ async function getGlobalIp() {
try {
const response = await fetch('https://api-ipv4.ip.sb/geoip', { referrerPolicy: 'no-referrer' });
let resp = await response.json();
type ObjectKey = keyof typeof CountryCode;
const myVar = resp['country_code'] as ObjectKey;
let globalInfo:any={
ip:resp['ip'],
isp:resp['isp'],
country:CountryCode[myVar],
country:CountryCode[resp['country_code'] as keyof typeof CountryCode],
}
info['globalInfo']=globalInfo
if(props.IPinfo){
Expand Down
31 changes: 21 additions & 10 deletions src/components/Main.vue
Original file line number Diff line number Diff line change
Expand Up @@ -212,30 +212,41 @@ import { toClipboard } from '@soerenmartius/vue3-clipboard'
import MarkUI from './Mark.vue'
const showMark = ref({ show: false })
const customNodes: Ref<{
value: string;
label: string;
}[]> = ref(localStorage.customNodes ? JSON.parse(localStorage.customNodes) : [])
const customNodes = reactive(localStorage.customNodes ? JSON.parse(localStorage.customNodes) : [])
const OnlineNodes: {
label: string;
options: {
value: string;
label: string;
}[];
}[] = nodesJson
}[] = []
for(let groupName in nodesJson) {
const group=nodesJson[groupName as keyof typeof nodesJson]
const temp: {
label: string;
options: {
value: string;
label: string;
}[];
}={"label":groupName,options:[]}
for(let node in group) {
temp.options.push({"value":group[node as keyof typeof group],"label":node})
}
OnlineNodes.push(temp)
}
const nodes: Ref<{
label: string;
options: {
value: string;
label: string;
}[];
}[]> = ref(OnlineNodes)
if (customNodes.value.length) {
nodes.value = [{ "label": "自定义", "options": customNodes.value }].concat(OnlineNodes)
if (customNodes.length) {
nodes.value = [{ "label": "自定义", "options": customNodes}].concat(OnlineNodes)
}
watch(customNodes, async (newState, oldState) => {
if (customNodes.value.length) {
nodes.value = [{ "label": "自定义", "options": customNodes.value }].concat(OnlineNodes)
if (customNodes.length) {
nodes.value = [{ "label": "自定义", "options": customNodes }].concat(OnlineNodes)
} else nodes.value = OnlineNodes
localStorage.customNodes = JSON.stringify(newState)
}, { deep: true })
Expand Down Expand Up @@ -558,7 +569,7 @@ const addNode = async () => {
return
}
addForm.value.checking = false
customNodes.value.push({
customNodes.push({
label: addForm.value.label,
value: addForm.value.value,
})
Expand Down
6 changes: 3 additions & 3 deletions src/components/Mark.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<el-dialog align-center style="width: 95vw;max-width: 600px;height: 85vh;" v-model="show" title="排行榜">
<div style="overflow-y: auto;height: calc(85vh - 100px);margin-top:-30px">
<el-dialog align-center style="width: 95vw;max-width: 600px;max-height: 85vh;" v-model="show" title="排行榜">
<div style="overflow-y: auto;max-height: calc(85vh - 100px);margin-top:-30px">
<div class="mb-2 flex items-center text-sm">
<el-radio-group v-model="sortBy" @change="refreshMark" class="ml-4">
<el-radio label="allUsed" size="small">总流量</el-radio>
Expand Down Expand Up @@ -59,7 +59,7 @@
</el-table-column> -->
</el-table>
</div>
<el-button class="mt-4" style="width: 100%" @click="isShowMe=true">用户中心</el-button>
<el-button style="width: 100%" @click="isShowMe=true">用户中心</el-button>
</el-dialog>
<el-dialog style="width: 99vw;max-width: 500px;" v-model="isShowMe" title="用户中心">
<MyUI v-if="isShowMe" :loginInfo="props.loginInfo"/>
Expand Down

0 comments on commit 3a4de04

Please sign in to comment.