@vuepress/theme-default 2.0.0-rc.80 → 2.0.0-rc.82
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/lib/client/components/VPHome.vue +1 -2
- package/lib/client/components/VPNavbar.vue +3 -3
- package/lib/client/components/VPNavbarBrand.vue +1 -1
- package/lib/client/components/VPNavbarDropdown.vue +7 -10
- package/lib/client/components/VPNavbarItems.vue +3 -3
- package/lib/client/components/VPPage.vue +3 -3
- package/lib/client/components/VPPageMeta.vue +6 -7
- package/lib/client/components/VPPageNav.vue +2 -4
- package/lib/client/components/VPSidebar.vue +12 -5
- package/lib/client/components/VPSidebarItem.vue +11 -8
- package/lib/client/components/VPToggleColorModeButton.vue +1 -1
- package/lib/client/components/VPToggleSidebarButton.vue +1 -1
- package/lib/client/components/global/Badge.vue +3 -3
- package/lib/client/layouts/Layout.vue +1 -1
- package/lib/client/styles/arrow.scss +8 -0
- package/lib/client/styles/code-group.scss +1 -2
- package/lib/client/styles/external-link-icon.scss +1 -1
- package/lib/node/defaultTheme.js +2 -1
- package/lib/node/typings.d.ts +2 -1
- package/package.json +17 -17
|
@@ -113,20 +113,20 @@ useUpdateDeviceStatus(
|
|
|
113
113
|
border-color var(--vp-t-color);
|
|
114
114
|
|
|
115
115
|
@media screen and (max-width: $MQMobile) {
|
|
116
|
-
padding-
|
|
116
|
+
padding-inline-start: 4rem;
|
|
117
117
|
}
|
|
118
118
|
}
|
|
119
119
|
|
|
120
120
|
.vp-navbar-items-wrapper {
|
|
121
121
|
position: absolute;
|
|
122
|
+
inset-inline-end: var(--navbar-padding-h);
|
|
122
123
|
top: var(--navbar-padding-v);
|
|
123
|
-
right: var(--navbar-padding-h);
|
|
124
124
|
|
|
125
125
|
display: flex;
|
|
126
126
|
|
|
127
127
|
box-sizing: border-box;
|
|
128
128
|
height: var(--navbar-line-height);
|
|
129
|
-
padding-
|
|
129
|
+
padding-inline-start: var(--navbar-padding-h);
|
|
130
130
|
|
|
131
131
|
font-size: 0.9rem;
|
|
132
132
|
white-space: nowrap;
|
|
@@ -13,7 +13,7 @@ const props = defineProps<{
|
|
|
13
13
|
|
|
14
14
|
const { config } = toRefs(props)
|
|
15
15
|
|
|
16
|
-
const [open, toggleOpen] = useToggle(
|
|
16
|
+
const [open, toggleOpen] = useToggle()
|
|
17
17
|
|
|
18
18
|
const dropdownAriaLabel = computed(
|
|
19
19
|
() => config.value.ariaLabel || config.value.text,
|
|
@@ -159,8 +159,8 @@ onContentUpdated(() => {
|
|
|
159
159
|
|
|
160
160
|
.vp-navbar-dropdown-wrapper:not(.mobile) & {
|
|
161
161
|
position: absolute;
|
|
162
|
+
inset-inline-end: 0;
|
|
162
163
|
top: 100%;
|
|
163
|
-
right: 0;
|
|
164
164
|
|
|
165
165
|
display: none;
|
|
166
166
|
|
|
@@ -178,7 +178,7 @@ onContentUpdated(() => {
|
|
|
178
178
|
|
|
179
179
|
background-color: var(--vp-c-bg-elv);
|
|
180
180
|
|
|
181
|
-
text-align:
|
|
181
|
+
text-align: start;
|
|
182
182
|
white-space: nowrap;
|
|
183
183
|
}
|
|
184
184
|
}
|
|
@@ -260,20 +260,19 @@ onContentUpdated(() => {
|
|
|
260
260
|
content: '';
|
|
261
261
|
|
|
262
262
|
position: absolute;
|
|
263
|
+
inset-inline-start: 9px;
|
|
263
264
|
top: calc(50% - 2px);
|
|
264
|
-
left: 9px;
|
|
265
265
|
|
|
266
266
|
width: 0;
|
|
267
267
|
height: 0;
|
|
268
268
|
border-top: 3px solid transparent;
|
|
269
269
|
border-bottom: 3px solid transparent;
|
|
270
|
-
border-
|
|
270
|
+
border-inline-start: 5px solid var(--vp-c-accent);
|
|
271
271
|
}
|
|
272
272
|
}
|
|
273
273
|
}
|
|
274
274
|
|
|
275
275
|
.vp-navbar-dropdown-wrapper.mobile & > a {
|
|
276
|
-
font-size: 15px;
|
|
277
276
|
line-height: 2rem;
|
|
278
277
|
}
|
|
279
278
|
}
|
|
@@ -290,7 +289,6 @@ onContentUpdated(() => {
|
|
|
290
289
|
padding-bottom: 0;
|
|
291
290
|
border-top: 0;
|
|
292
291
|
|
|
293
|
-
font-size: 15px;
|
|
294
292
|
line-height: 2rem;
|
|
295
293
|
}
|
|
296
294
|
|
|
@@ -301,7 +299,7 @@ onContentUpdated(() => {
|
|
|
301
299
|
}
|
|
302
300
|
|
|
303
301
|
> span {
|
|
304
|
-
padding:
|
|
302
|
+
padding-inline: 1.25rem 1.5rem;
|
|
305
303
|
}
|
|
306
304
|
|
|
307
305
|
> .auto-link {
|
|
@@ -324,8 +322,7 @@ onContentUpdated(() => {
|
|
|
324
322
|
font-size: 0.9em;
|
|
325
323
|
|
|
326
324
|
.vp-navbar-dropdown-wrapper.mobile & {
|
|
327
|
-
padding-
|
|
328
|
-
font-size: 14px;
|
|
325
|
+
padding-inline-start: 1rem;
|
|
329
326
|
}
|
|
330
327
|
}
|
|
331
328
|
</style>
|
|
@@ -75,15 +75,15 @@ useUpdateDeviceStatus(
|
|
|
75
75
|
.vp-navbar-item {
|
|
76
76
|
position: relative;
|
|
77
77
|
display: inline-block;
|
|
78
|
-
margin-
|
|
78
|
+
margin-inline-start: 1.5rem;
|
|
79
79
|
line-height: var(--navbar-line-height);
|
|
80
80
|
|
|
81
81
|
@media (max-width: $MQMobile) {
|
|
82
|
-
margin-
|
|
82
|
+
margin-inline-start: 0;
|
|
83
83
|
}
|
|
84
84
|
|
|
85
85
|
&:first-child {
|
|
86
|
-
margin-
|
|
86
|
+
margin-inline-start: 0;
|
|
87
87
|
}
|
|
88
88
|
|
|
89
89
|
.auto-link {
|
|
@@ -44,18 +44,18 @@ defineSlots<{
|
|
|
44
44
|
padding-bottom: 2rem;
|
|
45
45
|
|
|
46
46
|
// leave space for sidebar
|
|
47
|
-
padding-
|
|
47
|
+
padding-inline-start: var(--sidebar-width);
|
|
48
48
|
|
|
49
49
|
// narrow desktop / iPad
|
|
50
50
|
@media (max-width: $MQNarrow) {
|
|
51
51
|
// leave space for sidebar
|
|
52
|
-
padding-
|
|
52
|
+
padding-inline-start: var(--sidebar-width-mobile);
|
|
53
53
|
}
|
|
54
54
|
|
|
55
55
|
// wide mobile
|
|
56
56
|
@media (max-width: $MQMobile) {
|
|
57
57
|
// sidebar is collapsed
|
|
58
|
-
padding-
|
|
58
|
+
padding-inline-start: 0;
|
|
59
59
|
}
|
|
60
60
|
|
|
61
61
|
[vp-content] {
|
|
@@ -70,8 +70,7 @@ const contributors = useContributors()
|
|
|
70
70
|
|
|
71
71
|
@media print {
|
|
72
72
|
margin: 0 !important;
|
|
73
|
-
padding-
|
|
74
|
-
padding-left: 0 !important;
|
|
73
|
+
padding-inline: 0 !important;
|
|
75
74
|
}
|
|
76
75
|
|
|
77
76
|
@media (max-width: $MQMobile) {
|
|
@@ -101,9 +100,9 @@ const contributors = useContributors()
|
|
|
101
100
|
|
|
102
101
|
.edit-link {
|
|
103
102
|
margin-top: 0.25rem;
|
|
104
|
-
margin-right: 0.5rem;
|
|
105
103
|
margin-bottom: 0.25rem;
|
|
106
|
-
|
|
104
|
+
margin-inline-end: 0.5rem;
|
|
105
|
+
font-size: 0.875em;
|
|
107
106
|
|
|
108
107
|
@media print {
|
|
109
108
|
display: none;
|
|
@@ -115,7 +114,7 @@ const contributors = useContributors()
|
|
|
115
114
|
|
|
116
115
|
width: 1em;
|
|
117
116
|
height: 1em;
|
|
118
|
-
margin-
|
|
117
|
+
margin-inline-end: 0.25em;
|
|
119
118
|
}
|
|
120
119
|
}
|
|
121
120
|
|
|
@@ -123,10 +122,10 @@ const contributors = useContributors()
|
|
|
123
122
|
.contributors {
|
|
124
123
|
margin-top: 0.25rem;
|
|
125
124
|
margin-bottom: 0.25rem;
|
|
126
|
-
font-size:
|
|
125
|
+
font-size: 0.875em;
|
|
127
126
|
|
|
128
127
|
@media (max-width: $MQMobile) {
|
|
129
|
-
font-size:
|
|
128
|
+
font-size: 0.825em;
|
|
130
129
|
text-align: start;
|
|
131
130
|
}
|
|
132
131
|
}
|
|
@@ -69,17 +69,15 @@ useEventListener('keydown', (event): void => {
|
|
|
69
69
|
|
|
70
70
|
max-width: var(--content-width, 740px);
|
|
71
71
|
min-height: 2rem;
|
|
72
|
+
margin-inline: auto;
|
|
72
73
|
margin-top: 0;
|
|
73
|
-
margin-right: auto;
|
|
74
|
-
margin-left: auto;
|
|
75
74
|
padding: 1rem 2rem 0;
|
|
76
75
|
border-top: 1px solid var(--vp-c-gutter);
|
|
77
76
|
|
|
78
77
|
transition: border-top var(--vp-t-color);
|
|
79
78
|
|
|
80
79
|
@media (max-width: $MQNarrow) {
|
|
81
|
-
padding-
|
|
82
|
-
padding-left: 1rem;
|
|
80
|
+
padding-inline: 1rem;
|
|
83
81
|
}
|
|
84
82
|
|
|
85
83
|
@media print {
|
|
@@ -23,11 +23,11 @@ defineSlots<{
|
|
|
23
23
|
|
|
24
24
|
.vp-sidebar {
|
|
25
25
|
position: fixed;
|
|
26
|
+
inset-inline-start: 0;
|
|
26
27
|
|
|
27
28
|
// leave space for navbar
|
|
28
29
|
top: var(--navbar-height);
|
|
29
30
|
bottom: 0;
|
|
30
|
-
left: 0;
|
|
31
31
|
z-index: 10;
|
|
32
32
|
|
|
33
33
|
overflow-y: auto;
|
|
@@ -35,11 +35,11 @@ defineSlots<{
|
|
|
35
35
|
box-sizing: border-box;
|
|
36
36
|
width: var(--sidebar-width);
|
|
37
37
|
margin: 0;
|
|
38
|
-
border-
|
|
38
|
+
border-inline-end: 1px solid var(--vp-c-border);
|
|
39
39
|
|
|
40
40
|
background-color: var(--vp-sidebar-c-bg);
|
|
41
41
|
|
|
42
|
-
font-size:
|
|
42
|
+
font-size: 1rem;
|
|
43
43
|
|
|
44
44
|
transition:
|
|
45
45
|
transform var(--vp-t-transform),
|
|
@@ -52,7 +52,7 @@ defineSlots<{
|
|
|
52
52
|
// narrow desktop / iPad
|
|
53
53
|
@media (max-width: $MQNarrow) {
|
|
54
54
|
width: var(--sidebar-width-mobile);
|
|
55
|
-
font-size:
|
|
55
|
+
font-size: 0.9rem;
|
|
56
56
|
}
|
|
57
57
|
|
|
58
58
|
// wide mobile
|
|
@@ -62,6 +62,10 @@ defineSlots<{
|
|
|
62
62
|
// leave space for navbar
|
|
63
63
|
padding-top: var(--navbar-height);
|
|
64
64
|
transform: translateX(-100%);
|
|
65
|
+
|
|
66
|
+
[dir='rtl'] & {
|
|
67
|
+
transform: translateX(100%);
|
|
68
|
+
}
|
|
65
69
|
}
|
|
66
70
|
|
|
67
71
|
&::-webkit-scrollbar {
|
|
@@ -105,7 +109,10 @@ defineSlots<{
|
|
|
105
109
|
// override styles
|
|
106
110
|
.vp-navbar-item {
|
|
107
111
|
display: block;
|
|
108
|
-
|
|
112
|
+
|
|
113
|
+
padding-block: 0.5rem;
|
|
114
|
+
padding-inline: 1.5rem 0;
|
|
115
|
+
|
|
109
116
|
font-size: 1.1em;
|
|
110
117
|
line-height: 1.25rem;
|
|
111
118
|
}
|
|
@@ -102,7 +102,7 @@ onBeforeUnmount(() => {
|
|
|
102
102
|
@use '../styles/variables' as *;
|
|
103
103
|
|
|
104
104
|
.vp-sidebar-item {
|
|
105
|
-
border-
|
|
105
|
+
border-inline-start: 0.25rem solid transparent;
|
|
106
106
|
color: var(--vp-c-text);
|
|
107
107
|
cursor: default;
|
|
108
108
|
|
|
@@ -115,7 +115,8 @@ onBeforeUnmount(() => {
|
|
|
115
115
|
box-sizing: border-box;
|
|
116
116
|
width: 100%;
|
|
117
117
|
margin: 0;
|
|
118
|
-
padding: 0.35rem
|
|
118
|
+
padding-block: 0.35rem;
|
|
119
|
+
padding-inline: 1.25rem 1.5rem;
|
|
119
120
|
|
|
120
121
|
font-weight: bold;
|
|
121
122
|
font-size: 1.1em;
|
|
@@ -139,33 +140,35 @@ onBeforeUnmount(() => {
|
|
|
139
140
|
box-sizing: border-box;
|
|
140
141
|
width: 100%;
|
|
141
142
|
margin: 0;
|
|
142
|
-
padding: 0.35rem
|
|
143
|
+
padding-block: 0.35rem;
|
|
144
|
+
padding-inline: 2rem 1rem;
|
|
143
145
|
|
|
144
146
|
font-weight: 400;
|
|
145
147
|
font-size: 1em;
|
|
146
148
|
line-height: 1.4;
|
|
147
149
|
|
|
148
150
|
+ .vp-sidebar-children {
|
|
149
|
-
padding-
|
|
151
|
+
padding-inline-start: 1rem;
|
|
150
152
|
font-size: 0.95em;
|
|
151
153
|
}
|
|
152
154
|
|
|
153
155
|
.vp-sidebar-children .vp-sidebar-children & {
|
|
154
|
-
padding: 0.25rem
|
|
156
|
+
padding-block: 0.25rem;
|
|
157
|
+
padding-inline: 1.75rem 1rem;
|
|
155
158
|
|
|
156
159
|
&.active {
|
|
157
|
-
border-
|
|
160
|
+
border-inline-start-color: transparent;
|
|
158
161
|
font-weight: 500;
|
|
159
162
|
}
|
|
160
163
|
}
|
|
161
164
|
|
|
162
165
|
a.vp-sidebar-heading + .vp-sidebar-children &.active {
|
|
163
|
-
border-
|
|
166
|
+
border-inline-start-color: transparent;
|
|
164
167
|
}
|
|
165
168
|
}
|
|
166
169
|
|
|
167
170
|
&.active:not(p.vp-sidebar-heading) {
|
|
168
|
-
border-
|
|
171
|
+
border-inline-start-color: var(--vp-c-accent);
|
|
169
172
|
color: var(--vp-c-accent);
|
|
170
173
|
font-weight: 600;
|
|
171
174
|
}
|
|
@@ -45,15 +45,15 @@ defineSlots<{
|
|
|
45
45
|
display: inline-block;
|
|
46
46
|
vertical-align: top;
|
|
47
47
|
|
|
48
|
-
height:
|
|
48
|
+
height: 1.3em;
|
|
49
49
|
padding: 0 6px;
|
|
50
50
|
border-radius: 3px;
|
|
51
51
|
|
|
52
52
|
background: var(--vp-c-accent-soft);
|
|
53
53
|
color: var(--vp-c-accent);
|
|
54
54
|
|
|
55
|
-
font-size:
|
|
56
|
-
line-height:
|
|
55
|
+
font-size: 0.875em;
|
|
56
|
+
line-height: 1.3;
|
|
57
57
|
|
|
58
58
|
transition:
|
|
59
59
|
background var(--vp-t-color),
|
package/lib/node/defaultTheme.js
CHANGED
|
@@ -91,7 +91,8 @@ export const defaultTheme = ({ hostname, themePlugins = {}, ...localeOptions } =
|
|
|
91
91
|
? gitPlugin({
|
|
92
92
|
createdTime: false,
|
|
93
93
|
updatedTime: localeOptions.lastUpdated !== false,
|
|
94
|
-
|
|
94
|
+
changelog: { repoUrl: localeOptions.repo || '' },
|
|
95
|
+
...(isPlainObject(themePlugins.git) ? themePlugins.git : {}),
|
|
95
96
|
})
|
|
96
97
|
: [],
|
|
97
98
|
// @vuepress/plugin-links-check
|
package/lib/node/typings.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { BackToTopPluginOptions } from '@vuepress/plugin-back-to-top';
|
|
2
2
|
import type { CopyCodePluginOptions } from '@vuepress/plugin-copy-code';
|
|
3
|
+
import type { GitPluginOptions } from '@vuepress/plugin-git';
|
|
3
4
|
import type { LinksCheckPluginOptions } from '@vuepress/plugin-links-check';
|
|
4
5
|
import type { MarkdownHintPluginOptions } from '@vuepress/plugin-markdown-hint';
|
|
5
6
|
import type { MarkdownTabPluginOptions } from '@vuepress/plugin-markdown-tab';
|
|
@@ -22,7 +23,7 @@ export interface DefaultThemePluginsOptions {
|
|
|
22
23
|
/**
|
|
23
24
|
* Enable @vuepress/plugin-git or not
|
|
24
25
|
*/
|
|
25
|
-
git?: boolean;
|
|
26
|
+
git?: GitPluginOptions | boolean;
|
|
26
27
|
/**
|
|
27
28
|
* Enable @vuepress/plugin-markdown-hint or not
|
|
28
29
|
*/
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vuepress/theme-default",
|
|
3
|
-
"version": "2.0.0-rc.
|
|
3
|
+
"version": "2.0.0-rc.82",
|
|
4
4
|
"description": "Default theme of VuePress",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"vuepress-theme",
|
|
@@ -37,22 +37,22 @@
|
|
|
37
37
|
"templates"
|
|
38
38
|
],
|
|
39
39
|
"dependencies": {
|
|
40
|
-
"@vuepress/helper": "2.0.0-rc.
|
|
41
|
-
"@vuepress/plugin-active-header-links": "2.0.0-rc.
|
|
42
|
-
"@vuepress/plugin-back-to-top": "2.0.0-rc.
|
|
43
|
-
"@vuepress/plugin-copy-code": "2.0.0-rc.
|
|
44
|
-
"@vuepress/plugin-git": "2.0.0-rc.
|
|
45
|
-
"@vuepress/plugin-links-check": "2.0.0-rc.
|
|
46
|
-
"@vuepress/plugin-markdown-hint": "2.0.0-rc.
|
|
47
|
-
"@vuepress/plugin-markdown-tab": "2.0.0-rc.
|
|
48
|
-
"@vuepress/plugin-medium-zoom": "2.0.0-rc.
|
|
49
|
-
"@vuepress/plugin-nprogress": "2.0.0-rc.
|
|
50
|
-
"@vuepress/plugin-palette": "2.0.0-rc.
|
|
51
|
-
"@vuepress/plugin-prismjs": "2.0.0-rc.
|
|
52
|
-
"@vuepress/plugin-seo": "2.0.0-rc.
|
|
53
|
-
"@vuepress/plugin-sitemap": "2.0.0-rc.
|
|
40
|
+
"@vuepress/helper": "2.0.0-rc.82",
|
|
41
|
+
"@vuepress/plugin-active-header-links": "2.0.0-rc.82",
|
|
42
|
+
"@vuepress/plugin-back-to-top": "2.0.0-rc.82",
|
|
43
|
+
"@vuepress/plugin-copy-code": "2.0.0-rc.82",
|
|
44
|
+
"@vuepress/plugin-git": "2.0.0-rc.82",
|
|
45
|
+
"@vuepress/plugin-links-check": "2.0.0-rc.82",
|
|
46
|
+
"@vuepress/plugin-markdown-hint": "2.0.0-rc.82",
|
|
47
|
+
"@vuepress/plugin-markdown-tab": "2.0.0-rc.82",
|
|
48
|
+
"@vuepress/plugin-medium-zoom": "2.0.0-rc.82",
|
|
49
|
+
"@vuepress/plugin-nprogress": "2.0.0-rc.82",
|
|
50
|
+
"@vuepress/plugin-palette": "2.0.0-rc.82",
|
|
51
|
+
"@vuepress/plugin-prismjs": "2.0.0-rc.82",
|
|
52
|
+
"@vuepress/plugin-seo": "2.0.0-rc.82",
|
|
53
|
+
"@vuepress/plugin-sitemap": "2.0.0-rc.82",
|
|
54
54
|
"@vuepress/plugin-theme-data": "2.0.0-rc.79",
|
|
55
|
-
"@vueuse/core": "^12.
|
|
55
|
+
"@vueuse/core": "^12.8.2",
|
|
56
56
|
"vue": "^3.5.13"
|
|
57
57
|
},
|
|
58
58
|
"peerDependencies": {
|
|
@@ -75,5 +75,5 @@
|
|
|
75
75
|
"publishConfig": {
|
|
76
76
|
"access": "public"
|
|
77
77
|
},
|
|
78
|
-
"gitHead": "
|
|
78
|
+
"gitHead": "638c0c2bc539b886de501c9ee74915caec280e00"
|
|
79
79
|
}
|