@varlet/cli 1.24.7 → 1.24.11-alpha.1641915594478
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +5 -5
- package/site/mobile/App.vue +14 -28
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@varlet/cli",
|
|
3
|
-
"version": "1.24.
|
|
3
|
+
"version": "1.24.11-alpha.1641915594478",
|
|
4
4
|
"description": "cli of varlet",
|
|
5
5
|
"bin": {
|
|
6
6
|
"varlet-cli": "./lib/index.js"
|
|
@@ -29,9 +29,9 @@
|
|
|
29
29
|
},
|
|
30
30
|
"gitHead": "ee9c3866bedad96c86365b0f9888a3a6bb781b1f",
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@varlet/icons": "1.24.
|
|
33
|
-
"@varlet/markdown-vite-plugin": "1.24.
|
|
34
|
-
"@varlet/touch-emulator": "1.24.
|
|
32
|
+
"@varlet/icons": "1.24.11-alpha.1641915594478",
|
|
33
|
+
"@varlet/markdown-vite-plugin": "1.24.11-alpha.1641915594478",
|
|
34
|
+
"@varlet/touch-emulator": "1.24.11-alpha.1641915594478",
|
|
35
35
|
"@babel/core": "^7.14.8",
|
|
36
36
|
"@babel/preset-env": "^7.14.8",
|
|
37
37
|
"@babel/preset-typescript": "^7.14.5",
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
"@types/lodash-es": "^4.17.5"
|
|
74
74
|
},
|
|
75
75
|
"peerDependencies": {
|
|
76
|
-
"@varlet/touch-emulator": "1.24.
|
|
76
|
+
"@varlet/touch-emulator": "1.24.11-alpha.1641915594478",
|
|
77
77
|
"@vue/test-utils": "^2.0.0-rc.6",
|
|
78
78
|
"vue": "3.2.16",
|
|
79
79
|
"vue-router": "4.0.12",
|
package/site/mobile/App.vue
CHANGED
|
@@ -1,32 +1,21 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div style="position: relative">
|
|
3
3
|
<header>
|
|
4
|
-
<var-site-app-bar
|
|
5
|
-
class="app-bar"
|
|
6
|
-
title-position="left"
|
|
7
|
-
:title="bigCamelizeComponentName"
|
|
8
|
-
>
|
|
4
|
+
<var-site-app-bar class="app-bar" title-position="left" :title="bigCamelizeComponentName">
|
|
9
5
|
<template #left>
|
|
10
|
-
<var-site-button
|
|
11
|
-
|
|
12
|
-
text
|
|
13
|
-
round
|
|
14
|
-
@click="back"
|
|
15
|
-
color="transparent"
|
|
16
|
-
text-color="#fff"
|
|
17
|
-
>
|
|
18
|
-
<var-site-icon name="chevron-left" :size="28" style="margin-top: 1px;" />
|
|
6
|
+
<var-site-button v-if="showBackIcon" text round @click="back" color="transparent" text-color="#fff">
|
|
7
|
+
<var-site-icon name="chevron-left" :size="28" style="margin-top: 1px" />
|
|
19
8
|
</var-site-button>
|
|
20
9
|
<var-site-button
|
|
21
10
|
v-if="!showBackIcon && github"
|
|
22
|
-
style="margin-left: 2px
|
|
11
|
+
style="margin-left: 2px"
|
|
23
12
|
text
|
|
24
13
|
round
|
|
25
14
|
@click="toGithub"
|
|
26
15
|
color="transparent"
|
|
27
16
|
text-color="#fff"
|
|
28
17
|
>
|
|
29
|
-
<var-site-icon name="github" :size="28" style="margin-top: 1px
|
|
18
|
+
<var-site-icon name="github" :size="28" style="margin-top: 1px" />
|
|
30
19
|
</var-site-button>
|
|
31
20
|
</template>
|
|
32
21
|
<template #right>
|
|
@@ -36,7 +25,7 @@
|
|
|
36
25
|
color="transparent"
|
|
37
26
|
text-color="#fff"
|
|
38
27
|
:style="{
|
|
39
|
-
transform: languages ? 'translateX(2px)' : 'translateX(-4px)'
|
|
28
|
+
transform: languages ? 'translateX(2px)' : 'translateX(-4px)',
|
|
40
29
|
}"
|
|
41
30
|
v-if="darkMode"
|
|
42
31
|
@click="toggleTheme"
|
|
@@ -66,10 +55,7 @@
|
|
|
66
55
|
</div>
|
|
67
56
|
|
|
68
57
|
<transition name="site-menu">
|
|
69
|
-
<div
|
|
70
|
-
class="settings var-site-elevation--3"
|
|
71
|
-
v-if="showMenu"
|
|
72
|
-
>
|
|
58
|
+
<div class="settings var-site-elevation--3" v-if="showMenu">
|
|
73
59
|
<var-site-cell
|
|
74
60
|
v-for="(value, key) in nonEmptyLanguages"
|
|
75
61
|
:key="key"
|
|
@@ -102,7 +88,7 @@ import {
|
|
|
102
88
|
import { get } from 'lodash-es'
|
|
103
89
|
|
|
104
90
|
export default defineComponent({
|
|
105
|
-
setup: function() {
|
|
91
|
+
setup: function () {
|
|
106
92
|
const bigCamelizeComponentName: Ref<string> = ref('')
|
|
107
93
|
const route = useRoute()
|
|
108
94
|
const showBackIcon: Ref<boolean> = ref(false)
|
|
@@ -122,7 +108,7 @@ export default defineComponent({
|
|
|
122
108
|
window.location.href = `./mobile.html#${route.path}?language=${language.value}&replace=${route.query.replace}`
|
|
123
109
|
|
|
124
110
|
if (!isPhone() && inIframe()) {
|
|
125
|
-
(window.top as any).scrollToMenu(redirect.slice(1))
|
|
111
|
+
;(window.top as any).scrollToMenu(redirect.slice(1))
|
|
126
112
|
}
|
|
127
113
|
}
|
|
128
114
|
|
|
@@ -130,7 +116,7 @@ export default defineComponent({
|
|
|
130
116
|
window.location.href = `./mobile.html#${redirect}?language=${language.value}&replace=${redirect.slice(1)}`
|
|
131
117
|
|
|
132
118
|
if (!isPhone() && inIframe()) {
|
|
133
|
-
(window.top as any).scrollToMenu(redirect.slice(1))
|
|
119
|
+
;(window.top as any).scrollToMenu(redirect.slice(1))
|
|
134
120
|
}
|
|
135
121
|
}
|
|
136
122
|
|
|
@@ -173,7 +159,7 @@ export default defineComponent({
|
|
|
173
159
|
}
|
|
174
160
|
}
|
|
175
161
|
|
|
176
|
-
(window as any).toggleTheme = toggleTheme
|
|
162
|
+
;(window as any).toggleTheme = toggleTheme
|
|
177
163
|
|
|
178
164
|
setThemes(config, currentThemes.value)
|
|
179
165
|
window.postMessage(getThemesMessage(), '*')
|
|
@@ -199,9 +185,9 @@ export default defineComponent({
|
|
|
199
185
|
toGithub,
|
|
200
186
|
back,
|
|
201
187
|
changeLanguage,
|
|
202
|
-
toggleTheme
|
|
188
|
+
toggleTheme,
|
|
203
189
|
}
|
|
204
|
-
}
|
|
190
|
+
},
|
|
205
191
|
})
|
|
206
192
|
</script>
|
|
207
193
|
|
|
@@ -218,7 +204,7 @@ body {
|
|
|
218
204
|
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
|
|
219
205
|
background: var(--site-config-color-bar);
|
|
220
206
|
color: var(--site-config-color-text);
|
|
221
|
-
transition: background-color .25s, color .25s;
|
|
207
|
+
transition: background-color 0.25s, color 0.25s;
|
|
222
208
|
}
|
|
223
209
|
|
|
224
210
|
::-webkit-scrollbar {
|