vitepress 1.0.0-draft.6 → 1.0.0-draft.7
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.
|
@@ -59,7 +59,7 @@ const pageName = computed(() => {
|
|
|
59
59
|
|
|
60
60
|
@media (min-width: 960px) {
|
|
61
61
|
.VPDoc {
|
|
62
|
-
padding: 32px 32px
|
|
62
|
+
padding: 32px 32px 0;
|
|
63
63
|
}
|
|
64
64
|
|
|
65
65
|
.VPDoc:not(.has-sidebar) .container {
|
|
@@ -118,7 +118,7 @@ const pageName = computed(() => {
|
|
|
118
118
|
top: 0;
|
|
119
119
|
margin-top: calc(var(--vp-nav-height-desktop) * -1 - 32px);
|
|
120
120
|
padding-top: calc(var(--vp-nav-height-desktop) + 32px);
|
|
121
|
-
|
|
121
|
+
height: 100vh;
|
|
122
122
|
overflow-x: hidden;
|
|
123
123
|
overflow-y: auto;
|
|
124
124
|
scrollbar-width: none;
|
|
@@ -133,12 +133,15 @@ const pageName = computed(() => {
|
|
|
133
133
|
bottom: 0;
|
|
134
134
|
z-index: 10;
|
|
135
135
|
width: 224px;
|
|
136
|
-
height:
|
|
136
|
+
height: 32px;
|
|
137
137
|
background: linear-gradient(transparent, var(--vp-c-bg) 70%);
|
|
138
138
|
}
|
|
139
139
|
|
|
140
140
|
.aside-content {
|
|
141
|
-
|
|
141
|
+
display: flex;
|
|
142
|
+
flex-direction: column;
|
|
143
|
+
min-height: calc(100vh - (var(--vp-nav-height-desktop) + 32px));
|
|
144
|
+
padding-bottom: 32px;
|
|
142
145
|
}
|
|
143
146
|
|
|
144
147
|
.content {
|
|
@@ -149,7 +152,7 @@ const pageName = computed(() => {
|
|
|
149
152
|
|
|
150
153
|
@media (min-width: 960px) {
|
|
151
154
|
.content {
|
|
152
|
-
padding: 0 32px
|
|
155
|
+
padding: 0 32px 128px;
|
|
153
156
|
}
|
|
154
157
|
}
|
|
155
158
|
|
|
@@ -14,6 +14,8 @@ const { page, theme } = useData()
|
|
|
14
14
|
<VPDocAsideOutline v-if="page.headers.length" />
|
|
15
15
|
<slot name="aside-outline-after" />
|
|
16
16
|
|
|
17
|
+
<div class="spacer" />
|
|
18
|
+
|
|
17
19
|
<slot name="aside-ads-before" />
|
|
18
20
|
<VPDocAsideCarbonAds v-if="theme.carbonAds" />
|
|
19
21
|
<slot name="aside-ads-after" />
|
|
@@ -23,8 +25,18 @@ const { page, theme } = useData()
|
|
|
23
25
|
</template>
|
|
24
26
|
|
|
25
27
|
<style scoped>
|
|
26
|
-
.VPDocAside
|
|
27
|
-
|
|
28
|
+
.VPDocAside {
|
|
29
|
+
display: flex;
|
|
30
|
+
flex-direction: column;
|
|
31
|
+
flex-grow: 1;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.spacer {
|
|
35
|
+
flex-grow: 1;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.VPDocAside :deep(.spacer + .VPDocAsideSponsors),
|
|
39
|
+
.VPDocAside :deep(.spacer + .VPDocAsideCarbonAds) {
|
|
28
40
|
margin-top: 24px;
|
|
29
41
|
}
|
|
30
42
|
|
|
@@ -29,50 +29,55 @@ function handleClick({ target: el }: Event) {
|
|
|
29
29
|
|
|
30
30
|
<template>
|
|
31
31
|
<div class="VPDocAsideOutline" :class="{ 'has-outline': hasOutline }" ref="container">
|
|
32
|
-
<div class="
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
<
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
<
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
<
|
|
51
|
-
<
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
32
|
+
<div class="content">
|
|
33
|
+
<div class="outline-marker" ref="marker" />
|
|
34
|
+
|
|
35
|
+
<div class="outline-title">On this page</div>
|
|
36
|
+
|
|
37
|
+
<nav aria-labelledby="doc-outline-aria-label">
|
|
38
|
+
<span class="visually-hidden" id="doc-outline-aria-label">
|
|
39
|
+
Table of Contents for current page
|
|
40
|
+
</span>
|
|
41
|
+
|
|
42
|
+
<ul class="root">
|
|
43
|
+
<li
|
|
44
|
+
v-for="{ text, link, children, hidden } in resolvedHeaders"
|
|
45
|
+
v-show="!hidden"
|
|
46
|
+
>
|
|
47
|
+
<a class="outline-link" :href="link" @click="handleClick">
|
|
48
|
+
{{ text }}
|
|
49
|
+
</a>
|
|
50
|
+
<ul v-if="children && frontmatter.outline === 'deep'">
|
|
51
|
+
<li v-for="{ text, link, hidden } in children" v-show="!hidden">
|
|
52
|
+
<a class="outline-link nested" :href="link" @click="handleClick">
|
|
53
|
+
{{ text }}
|
|
54
|
+
</a>
|
|
55
|
+
</li>
|
|
56
|
+
</ul>
|
|
57
|
+
</li>
|
|
58
|
+
</ul>
|
|
59
|
+
</nav>
|
|
60
|
+
</div>
|
|
59
61
|
</div>
|
|
60
62
|
</template>
|
|
61
63
|
|
|
62
64
|
<style scoped>
|
|
63
65
|
.VPDocAsideOutline {
|
|
64
|
-
position: relative;
|
|
65
66
|
display: none;
|
|
66
|
-
border-left: 1px solid var(--vp-c-divider-light);
|
|
67
|
-
padding-left: 16px;
|
|
68
|
-
font-size: 13px;
|
|
69
|
-
font-weight: 500;
|
|
70
67
|
}
|
|
71
68
|
|
|
72
69
|
.VPDocAsideOutline.has-outline {
|
|
73
70
|
display: block;
|
|
74
71
|
}
|
|
75
72
|
|
|
73
|
+
.content {
|
|
74
|
+
position: relative;
|
|
75
|
+
border-left: 1px solid var(--vp-c-divider-light);
|
|
76
|
+
padding-left: 16px;
|
|
77
|
+
font-size: 13px;
|
|
78
|
+
font-weight: 500;
|
|
79
|
+
}
|
|
80
|
+
|
|
76
81
|
.outline-marker {
|
|
77
82
|
position: absolute;
|
|
78
83
|
top: 32px;
|
package/dist/node/cli.js
CHANGED
|
@@ -266,7 +266,7 @@ function isNumber (x) {
|
|
|
266
266
|
return /^[-+]?(?:\d+(?:\.\d*)?|\.\d+)(e[-+]?\d+)?$/.test(x);
|
|
267
267
|
}
|
|
268
268
|
|
|
269
|
-
var version = "1.0.0-draft.
|
|
269
|
+
var version = "1.0.0-draft.7";
|
|
270
270
|
|
|
271
271
|
const argv = minimist(process.argv.slice(2));
|
|
272
272
|
console.log(c.cyan(`vitepress v${version}`));
|
package/dist/node-cjs/cli.cjs
CHANGED
|
@@ -268,7 +268,7 @@ function isNumber (x) {
|
|
|
268
268
|
return /^[-+]?(?:\d+(?:\.\d*)?|\.\d+)(e[-+]?\d+)?$/.test(x);
|
|
269
269
|
}
|
|
270
270
|
|
|
271
|
-
var version = "1.0.0-draft.
|
|
271
|
+
var version = "1.0.0-draft.7";
|
|
272
272
|
|
|
273
273
|
const argv = minimist(process.argv.slice(2));
|
|
274
274
|
console.log(serve.c.cyan(`vitepress v${version}`));
|