Skip to content

Commit de395ea

Browse files
committed
更新[BoxJs]: 增加仓库协作&贡献者信息, 点击订阅跳转作者仓库
1 parent ffdfd38 commit de395ea

2 files changed

Lines changed: 70 additions & 30 deletions

File tree

‎box/release/box.release.json‎

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,22 @@
11
{
22
"releases": [
3+
{
4+
"version": "0.4.18",
5+
"tags": ["beta"],
6+
"author": "@chavyleung",
7+
"icon": "https://avatars3.githubusercontent.com/u/29748519",
8+
"repo": "https://github.com/chavyleung",
9+
"notes": [
10+
{
11+
"name": "新增",
12+
"descs": ["仓库协作者&贡献者信息 (带跳转)", "点击订阅可以跳转至作者仓库"]
13+
},
14+
{
15+
"name": "修复",
16+
"descs": ["删除多余日志输出"]
17+
}
18+
]
19+
},
320
{
421
"version": "0.4.17",
522
"tags": ["beta"],

‎chavy.box.js‎

Lines changed: 53 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
const $ = new Env('BoxJs')
22
$.domain = '8.8.8.8'
33

4-
$.version = '0.4.17'
4+
$.version = '0.4.18'
55
$.versionType = 'beta'
66
$.KEY_sessions = 'chavy_boxjs_sessions'
77
$.KEY_versions = 'chavy_boxjs_versions'
@@ -73,11 +73,26 @@ function getSystemCfgs() {
7373
icon: 'https://avatars3.githubusercontent.com/u/29748519',
7474
repo: 'https://github.com/chavyleung/scripts'
7575
},
76+
senku: {
77+
id: 'GideonSenku',
78+
icon: 'https://avatars1.githubusercontent.com/u/39037656',
79+
repo: 'https://github.com/GideonSenku'
80+
},
7681
orz3: {
7782
id: 'Orz-3',
7883
icon: 'https://raw.githubusercontent.com/Orz-3/task/master/Orz-3.png',
7984
repo: 'https://github.com/Orz-3/'
8085
},
86+
contributors: [
87+
{ id: 'danchaw', icon: 'https://avatars1.githubusercontent.com/u/33873206?s=60&v=4', repo: 'https://github.com/danchaw' },
88+
{ id: '0x959', icon: 'https://avatars3.githubusercontent.com/u/42092849?s=60&v=4', repo: 'https://github.com/0x959' },
89+
{ id: 'lcandy2', icon: 'https://avatars1.githubusercontent.com/u/45784494?s=60&v=4', repo: 'https://github.com/lcandy2' },
90+
{ id: 'lowking', icon: 'https://avatars0.githubusercontent.com/u/33308659?s=60&v=4', repo: 'https://github.com/lowking' },
91+
{ id: 'chouchoui', icon: 'https://avatars1.githubusercontent.com/u/14866249?s=60&v=4', repo: 'https://github.com/chouchoui' },
92+
{ id: 'evilbutcher', icon: 'https://avatars1.githubusercontent.com/u/62224738?s=60&v=4', repo: 'https://github.com/evilbutcher' },
93+
{ id: 'eegod', icon: 'https://avatars0.githubusercontent.com/u/9635792?s=60&v=4', repo: 'https://github.com/eegod' },
94+
{ id: 'KaytZ', icon: 'https://avatars2.githubusercontent.com/u/17397324?s=60&v=4', repo: 'https://github.com/KaytZ' }
95+
],
8196
boxjs: {
8297
id: 'BoxJs',
8398
show: false,
@@ -342,7 +357,6 @@ function wrapapps(apps) {
342357
if (![null, undefined].includes(valdat)) {
343358
setting.val = valdat ? valdat.split(',') : []
344359
}
345-
console.log(setting.val)
346360
} else {
347361
setting.val = val || setting.val
348362
}
@@ -665,46 +679,37 @@ function printHtml(data, curapp = null, curview = 'app') {
665679
[v-cloak]{
666680
display: none
667681
}
668-
669682
.v-bottom-navigation,
670683
.v-bottom-sheet {
671-
padding-bottom: constant(safe-area-inset-bottom);
672-
padding-bottom: env(safe-area-inset-bottom);
684+
padding-bottom: constant(safe-area-inset-bottom);
685+
padding-bottom: env(safe-area-inset-bottom);
673686
}
674-
675687
.v-bottom-navigation{
676-
box-sizing: content-box;
688+
box-sizing: content-box;
677689
}
678-
679690
.v-bottom-navigation button {
680-
box-sizing: border-box;
691+
box-sizing: border-box;
681692
}
682-
683693
.v-main.safe {
684-
margin-bottom: 56px;
685-
margin-bottom: calc(56px + constant(safe-area-inset-bottom));
686-
margin-bottom: calc(56px + env(safe-area-inset-bottom));
687-
694+
margin-bottom: 56px;
695+
margin-bottom: calc(56px + constant(safe-area-inset-bottom));
696+
margin-bottom: calc(56px + env(safe-area-inset-bottom));
688697
}
689-
690698
.v-main .v-main__wrap {
691-
padding-bottom: 68px;
692-
padding-bottom: calc(68px + constant(safe-area-inset-bottom));
693-
padding-bottom: calc(68px + env(safe-area-inset-bottom));
699+
padding-bottom: 68px;
700+
padding-bottom: calc(68px + constant(safe-area-inset-bottom));
701+
padding-bottom: calc(68px + env(safe-area-inset-bottom));
694702
}
695-
696703
.v-main.safe .v-main__wrap {
697-
padding-bottom: 68px;
704+
padding-bottom: 68px;
698705
}
699-
700706
.v-speed-dial {
701-
bottom: calc(12px + constant(safe-area-inset-bottom));
702-
bottom: calc(12px + env(safe-area-inset-bottom));
707+
bottom: calc(12px + constant(safe-area-inset-bottom));
708+
bottom: calc(12px + env(safe-area-inset-bottom));
703709
}
704-
705710
.v-speed-dial.has-nav {
706-
bottom: calc(68px + constant(safe-area-inset-bottom));
707-
bottom: calc(68px + env(safe-area-inset-bottom));
711+
bottom: calc(68px + constant(safe-area-inset-bottom));
712+
bottom: calc(68px + env(safe-area-inset-bottom));
708713
}
709714
</style>
710715
</head>
@@ -785,14 +790,29 @@ function printHtml(data, curapp = null, curview = 'app') {
785790
<v-navigation-drawer v-model="ui.drawer.show" app temporary right>
786791
<v-list dense nav>
787792
<v-list-item two-line dense @click="onLink(box.syscfgs.chavy.repo)">
788-
<v-list-item-avatar>
789-
<img src="https://avatars3.githubusercontent.com/u/29748519?s=460&u=392a19e85465abbcb1791c9b8b32184a16e6795e&v=4" />
790-
</v-list-item-avatar>
793+
<v-list-item-avatar><img :src="box.syscfgs.chavy.icon" /></v-list-item-avatar>
791794
<v-list-item-content>
792795
<v-list-item-title>{{ box.syscfgs.chavy.id }}</v-list-item-title>
793796
<v-list-item-subtitle>{{ box.syscfgs.chavy.repo }}</v-list-item-subtitle>
794797
</v-list-item-content>
795798
</v-list-item>
799+
<v-list-item two-line dense @click="onLink(box.syscfgs.senku.repo)">
800+
<v-list-item-avatar><img :src="box.syscfgs.senku.icon" /></v-list-item-avatar>
801+
<v-list-item-content>
802+
<v-list-item-title>{{ box.syscfgs.senku.id }}</v-list-item-title>
803+
<v-list-item-subtitle>{{ box.syscfgs.senku.repo }}</v-list-item-subtitle>
804+
</v-list-item-content>
805+
</v-list-item>
806+
<v-divider></v-divider>
807+
<v-list-item class="pt-1">
808+
<v-row align="center" justify="start" no-gutters>
809+
<v-col v-for="(c, cIdx) in box.syscfgs.contributors" cols="2">
810+
<v-avatar class="ma-1" size="26" @click="onGoToRepo(c.repo)">
811+
<img :src="c.icon" />
812+
</v-avatar>
813+
</v-col>
814+
</v-row>
815+
</v-list-item>
796816
<v-divider></v-divider>
797817
<v-list-item v-if="false">
798818
<v-list-item-content>
@@ -1115,7 +1135,7 @@ function printHtml(data, curapp = null, curview = 'app') {
11151135
</v-tooltip>
11161136
<v-btn icon @click="ui.addAppSubDialog.show = true"><v-icon color="green">mdi-plus-circle</v-icon></v-btn>
11171137
</v-subheader>
1118-
<v-list-item two-line dense v-for="(sub, subIdx) in appsubs" :key="sub.id">
1138+
<v-list-item two-line dense v-for="(sub, subIdx) in appsubs" :key="sub.id" @click="onGoToRepo(sub.repo)">
11191139
<v-list-item-avatar v-if="sub.icon"><v-img :src="sub.icon"></v-img></v-list-item-avatar>
11201140
<v-list-item-avatar v-else color="grey"><v-icon dark>mdi-account</v-icon></v-list-item-avatar>
11211141
<v-list-item-content>
@@ -1848,6 +1868,9 @@ function printHtml(data, curapp = null, curview = 'app') {
18481868
_v2 = v2.split('.'),
18491869
_r = _v1[0] - _v2[0]
18501870
return _r == 0 && v1 != v2 ? compareVersion(_v1.splice(1).join('.'), _v2.splice(1).join('.')) : _r
1871+
},
1872+
onGoToRepo(url) {
1873+
window.open(url)
18511874
}
18521875
},
18531876
mounted: function () {

0 commit comments

Comments
 (0)