vuepress-theme-uniapp-official 1.4.38 → 1.4.40
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/components/AlgoliaSearchBox.vue +2 -2
- package/components/NavLinks.vue +1 -0
- package/global-components/SourceCode.vue +55 -0
- package/index.js +33 -16
- package/layouts/Layout.vue +73 -99
- package/package.json +8 -3
- package/styles/navbar.styl +7 -8
- package/styles/palette.styl +1 -0
|
@@ -69,11 +69,11 @@
|
|
|
69
69
|
flex-direction column
|
|
70
70
|
justify-content center
|
|
71
71
|
#docsearch span
|
|
72
|
-
@media (min-width:
|
|
72
|
+
@media (min-width: $DocSearch_MQMobile)
|
|
73
73
|
&
|
|
74
74
|
display flex
|
|
75
75
|
|
|
76
|
-
@media (max-width:
|
|
76
|
+
@media (max-width: $DocSearch_MQMobile)
|
|
77
77
|
:root
|
|
78
78
|
--docsearch-spacing 10px
|
|
79
79
|
--docsearch-footer-height 40px
|
package/components/NavLinks.vue
CHANGED
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
import { defineComponent, h } from 'vue';
|
|
3
|
+
|
|
4
|
+
function vnode2h(vnode) {
|
|
5
|
+
if (typeof vnode.tag === 'undefined') {
|
|
6
|
+
return vnode.text
|
|
7
|
+
}
|
|
8
|
+
return h(vnode.tag, vnode.data, vnode.children ? vnode.children.map(vnode2h) : [])
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export default defineComponent({
|
|
12
|
+
setup(props, { slots }) {
|
|
13
|
+
const sources = {}
|
|
14
|
+
const renderVNodes = []
|
|
15
|
+
slots.default()
|
|
16
|
+
.forEach(vnode => {
|
|
17
|
+
if (typeof vnode.tag !== 'undefined' || (typeof vnode.text !== 'undefined' && vnode.text.trim().length > 0)) {
|
|
18
|
+
if (vnode.tag === 'blockquote') {
|
|
19
|
+
if (vnode.children && vnode.children.length > 0) {
|
|
20
|
+
const p = vnode.children[0]
|
|
21
|
+
const text = p.children[0].text && p.children[0].text.trim()
|
|
22
|
+
if (typeof text === 'string') {
|
|
23
|
+
const [_, git, url] = text.match(/\s*(\w+):\s*(https?:\/\/\S+)$/) || []
|
|
24
|
+
sources[git] = url
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
} else {
|
|
28
|
+
renderVNodes.push(vnode)
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
})
|
|
32
|
+
|
|
33
|
+
const H = renderVNodes[0]
|
|
34
|
+
if (!H.data.style) H.data.style = {}
|
|
35
|
+
Object.assign(H.data.style, { display: 'flex', justifyContent: 'space-between' })
|
|
36
|
+
return () => h(
|
|
37
|
+
H.tag,
|
|
38
|
+
H.data,
|
|
39
|
+
[
|
|
40
|
+
h('span', null, H.children.map(vnode2h)),
|
|
41
|
+
h('span', { style: { marginLeft: '10px', alignSelf: 'center', fontSize: 'initial' } },
|
|
42
|
+
Object.keys(sources).map(git => h('a', {
|
|
43
|
+
attrs: {
|
|
44
|
+
href: sources[git],
|
|
45
|
+
target: '_blank',
|
|
46
|
+
rel: 'noopener noreferrer',
|
|
47
|
+
},
|
|
48
|
+
style: { marginLeft: '5px' }
|
|
49
|
+
}, git))
|
|
50
|
+
)
|
|
51
|
+
]
|
|
52
|
+
)
|
|
53
|
+
}
|
|
54
|
+
});
|
|
55
|
+
</script>
|
package/index.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
function getFormattedDate() {
|
|
2
|
-
|
|
2
|
+
const now = new Date();
|
|
3
3
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
4
|
+
const year = now.getFullYear();
|
|
5
|
+
const month = (now.getMonth() + 1).toString().padStart(2, '0');
|
|
6
|
+
const day = now.getDate().toString().padStart(2, '0');
|
|
7
|
+
const hours = now.getHours().toString().padStart(2, '0');
|
|
8
|
+
const minutes = now.getMinutes().toString().padStart(2, '0');
|
|
9
|
+
const seconds = now.getSeconds().toString().padStart(2, '0');
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
const formattedDate = `${year}-${month}-${day}_${hours}-${minutes}-${seconds}`;
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
return formattedDate;
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
const nowString = getFormattedDate();
|
|
@@ -40,7 +40,7 @@ module.exports = (themeConfig, ctx, pluginAPI) => {
|
|
|
40
40
|
}
|
|
41
41
|
})
|
|
42
42
|
|
|
43
|
-
pluginAPI.options.extendMarkdown.add('vuepress-theme-uni-app-md-plugins', (md) =>{
|
|
43
|
+
pluginAPI.options.extendMarkdown.add('vuepress-theme-uni-app-md-plugins', (md) => {
|
|
44
44
|
md.core.ruler.disable('emoji', true)
|
|
45
45
|
md.use(require('markdown-it-attrs'), {
|
|
46
46
|
leftDelimiter: '#{',
|
|
@@ -59,9 +59,9 @@ module.exports = (themeConfig, ctx, pluginAPI) => {
|
|
|
59
59
|
*/
|
|
60
60
|
ctx.siteConfig.shouldPrefetch = function (path, type) {
|
|
61
61
|
let themeShouldPrefetch = true
|
|
62
|
-
|
|
62
|
+
if (type === 'script') themeShouldPrefetch = path.includes('vendors~') || path.includes('layout-') || path.includes('index.')
|
|
63
63
|
else { themeShouldPrefetch = false }
|
|
64
|
-
|
|
64
|
+
return originalShouldPrefetch.call(this, path, type) || themeShouldPrefetch
|
|
65
65
|
}
|
|
66
66
|
ctx.siteConfig.patterns = ctx.siteConfig.patterns || ['**/!(_sidebar).md', '**/*.vue']
|
|
67
67
|
|
|
@@ -89,7 +89,24 @@ module.exports = (themeConfig, ctx, pluginAPI) => {
|
|
|
89
89
|
}
|
|
90
90
|
}
|
|
91
91
|
}],
|
|
92
|
-
['container',{
|
|
92
|
+
['container', {
|
|
93
|
+
type: 'sourceCode',
|
|
94
|
+
validate: (params) => {
|
|
95
|
+
return params.trim().match(/^sourceCode/);
|
|
96
|
+
},
|
|
97
|
+
|
|
98
|
+
render: (tokens, idx, opts, event) => {
|
|
99
|
+
var m = tokens[idx].info.trim().match(/^sourceCode\s+(.*)$/);
|
|
100
|
+
if (tokens[idx].nesting === 1) {
|
|
101
|
+
// opening tag
|
|
102
|
+
return `<SourceCode>`;
|
|
103
|
+
} else {
|
|
104
|
+
// closing tag
|
|
105
|
+
return `</SourceCode>`;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
}],
|
|
109
|
+
['container', {
|
|
93
110
|
type: klass,
|
|
94
111
|
render(tokens, idx, opts, env) {
|
|
95
112
|
const token = tokens[idx]
|
|
@@ -106,7 +123,7 @@ module.exports = (themeConfig, ctx, pluginAPI) => {
|
|
|
106
123
|
bgColor: 'rgba(0,0,0,0.6)'
|
|
107
124
|
}
|
|
108
125
|
}],
|
|
109
|
-
['named-chunks',{
|
|
126
|
+
['named-chunks', {
|
|
110
127
|
layoutChunkName: (layout) => 'layout-' + layout.componentName,
|
|
111
128
|
pageChunkName: page => {
|
|
112
129
|
const _context = page._context
|
|
@@ -123,8 +140,8 @@ module.exports = (themeConfig, ctx, pluginAPI) => {
|
|
|
123
140
|
return curPath
|
|
124
141
|
}
|
|
125
142
|
}],
|
|
126
|
-
['check-md2',{
|
|
127
|
-
filter({errMsg, fileUrl, fullText, matchUrl, col, line}){
|
|
143
|
+
['check-md2', {
|
|
144
|
+
filter({ errMsg, fileUrl, fullText, matchUrl, col, line }) {
|
|
128
145
|
/**
|
|
129
146
|
* errMsg:"Should use .md instead of .html"、"File is not found"、"Hash should slugify"、"Hash is not found"
|
|
130
147
|
*/
|
package/layouts/Layout.vue
CHANGED
|
@@ -6,49 +6,41 @@
|
|
|
6
6
|
@touchend="onTouchEnd"
|
|
7
7
|
@keydown.ctrl="openSearch = true"
|
|
8
8
|
>
|
|
9
|
-
<Navbar
|
|
10
|
-
v-if="shouldShowNavbar"
|
|
11
|
-
@toggle-sidebar="toggleSidebar"
|
|
12
|
-
/>
|
|
9
|
+
<Navbar v-if="shouldShowNavbar" @toggle-sidebar="toggleSidebar" />
|
|
13
10
|
|
|
14
|
-
<div
|
|
15
|
-
class="sidebar-mask"
|
|
16
|
-
@click="toggleSidebar(false)"
|
|
17
|
-
/>
|
|
11
|
+
<div class="sidebar-mask" @click="toggleSidebar(false)" />
|
|
18
12
|
|
|
19
|
-
<
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
<
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
<
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
13
|
+
<div class="content-container">
|
|
14
|
+
<Sidebar
|
|
15
|
+
ref="sidebar"
|
|
16
|
+
:items="sidebarItems"
|
|
17
|
+
@toggle-sidebar="toggleSidebar"
|
|
18
|
+
@hook:mounted="activeSidebarLinkVisible"
|
|
19
|
+
>
|
|
20
|
+
<template #top>
|
|
21
|
+
<slot name="sidebar-top" />
|
|
22
|
+
</template>
|
|
23
|
+
<template #bottom>
|
|
24
|
+
<slot name="sidebar-bottom" />
|
|
25
|
+
<SiderBarBottom v-if="$lang === LOCALE_ZH_HANS" />
|
|
26
|
+
</template>
|
|
27
|
+
</Sidebar>
|
|
33
28
|
|
|
34
|
-
|
|
29
|
+
<Home v-if="$page.frontmatter.home" />
|
|
35
30
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
<slot name="page-bottom" />
|
|
47
|
-
<Footer />
|
|
48
|
-
</template>
|
|
49
|
-
</Page>
|
|
31
|
+
<Page v-else :sidebar-items="sidebarItems" :style="pageStyle">
|
|
32
|
+
<template #top>
|
|
33
|
+
<slot name="page-top" />
|
|
34
|
+
<TocTop />
|
|
35
|
+
</template>
|
|
36
|
+
<template #bottom>
|
|
37
|
+
<slot name="page-bottom" />
|
|
38
|
+
<Footer />
|
|
39
|
+
</template>
|
|
40
|
+
</Page>
|
|
50
41
|
|
|
51
|
-
|
|
42
|
+
<Toc />
|
|
43
|
+
</div>
|
|
52
44
|
</div>
|
|
53
45
|
</template>
|
|
54
46
|
|
|
@@ -57,18 +49,18 @@ import Home from '@theme/components/Home.vue'
|
|
|
57
49
|
import Navbar from '@theme/components/Navbar.vue'
|
|
58
50
|
import Page from '@theme/components/Page.vue'
|
|
59
51
|
import Sidebar from '@theme/components/Sidebar.vue'
|
|
60
|
-
import Footer from '@theme/components/Footer.vue'
|
|
61
|
-
import SiderBarBottom from '../components/SiderBarBottom.vue'
|
|
62
|
-
import Toc from '../components/Toc'
|
|
63
|
-
import TocTop from '../components/Toc-top'
|
|
52
|
+
import Footer from '@theme/components/Footer.vue'
|
|
53
|
+
import SiderBarBottom from '../components/SiderBarBottom.vue'
|
|
54
|
+
import Toc from '../components/Toc'
|
|
55
|
+
import TocTop from '../components/Toc-top'
|
|
64
56
|
import { resolveSidebarItems, forbidScroll } from '../util'
|
|
65
|
-
import navProvider from '../mixin/navProvider'
|
|
66
|
-
import toc from '../mixin/toc'
|
|
67
|
-
import { LOCALE_ZH_HANS } from '@theme-config/i18n'
|
|
57
|
+
import navProvider from '../mixin/navProvider'
|
|
58
|
+
import toc from '../mixin/toc'
|
|
59
|
+
import { LOCALE_ZH_HANS } from '@theme-config/i18n'
|
|
68
60
|
|
|
69
61
|
export default {
|
|
70
62
|
name: 'Layout',
|
|
71
|
-
mixins: [
|
|
63
|
+
mixins: [navProvider, toc],
|
|
72
64
|
components: {
|
|
73
65
|
Home,
|
|
74
66
|
Page,
|
|
@@ -77,67 +69,50 @@ export default {
|
|
|
77
69
|
Footer,
|
|
78
70
|
SiderBarBottom,
|
|
79
71
|
Toc,
|
|
80
|
-
TocTop
|
|
72
|
+
TocTop,
|
|
81
73
|
},
|
|
82
|
-
data
|
|
74
|
+
data() {
|
|
83
75
|
return {
|
|
84
76
|
isSidebarOpen: false,
|
|
85
|
-
LOCALE_ZH_HANS
|
|
77
|
+
LOCALE_ZH_HANS,
|
|
86
78
|
}
|
|
87
79
|
},
|
|
88
80
|
computed: {
|
|
89
|
-
shouldShowNavbar
|
|
81
|
+
shouldShowNavbar() {
|
|
90
82
|
const { themeConfig } = this.$site
|
|
91
83
|
const { frontmatter } = this.$page
|
|
92
|
-
if (
|
|
93
|
-
frontmatter.navbar === false
|
|
94
|
-
|| themeConfig.navbar === false) {
|
|
84
|
+
if (frontmatter.navbar === false || themeConfig.navbar === false) {
|
|
95
85
|
return false
|
|
96
86
|
}
|
|
97
|
-
return
|
|
98
|
-
this.$title
|
|
99
|
-
|| themeConfig.logo
|
|
100
|
-
|| themeConfig.repo
|
|
101
|
-
|| themeConfig.nav
|
|
102
|
-
|| this.$themeLocaleConfig.nav
|
|
103
|
-
)
|
|
87
|
+
return this.$title || themeConfig.logo || themeConfig.repo || themeConfig.nav || this.$themeLocaleConfig.nav
|
|
104
88
|
},
|
|
105
|
-
shouldShowSidebar
|
|
89
|
+
shouldShowSidebar() {
|
|
106
90
|
const { frontmatter } = this.$page
|
|
107
|
-
return
|
|
108
|
-
!frontmatter.home
|
|
109
|
-
&& frontmatter.sidebar !== false
|
|
110
|
-
&& this.sidebarItems.length
|
|
111
|
-
)
|
|
91
|
+
return !frontmatter.home && frontmatter.sidebar !== false && this.sidebarItems.length
|
|
112
92
|
},
|
|
113
|
-
sidebarItems
|
|
114
|
-
return resolveSidebarItems(
|
|
115
|
-
this.$page,
|
|
116
|
-
this.$page.regularPath,
|
|
117
|
-
this.$site,
|
|
118
|
-
this.$localePath
|
|
119
|
-
)
|
|
93
|
+
sidebarItems() {
|
|
94
|
+
return resolveSidebarItems(this.$page, this.$page.regularPath, this.$site, this.$localePath)
|
|
120
95
|
},
|
|
121
|
-
pageClasses
|
|
96
|
+
pageClasses() {
|
|
122
97
|
const userPageClass = this.$page.frontmatter.pageClass
|
|
123
98
|
return [
|
|
124
99
|
{
|
|
125
100
|
'no-navbar': !this.shouldShowNavbar,
|
|
126
101
|
'sidebar-open': this.isSidebarOpen,
|
|
127
|
-
'no-sidebar': !this.shouldShowSidebar
|
|
102
|
+
'no-sidebar': !this.shouldShowSidebar,
|
|
128
103
|
},
|
|
129
|
-
userPageClass
|
|
104
|
+
userPageClass,
|
|
130
105
|
]
|
|
131
106
|
},
|
|
132
|
-
pageStyle
|
|
133
|
-
const style = {}
|
|
107
|
+
pageStyle() {
|
|
108
|
+
const style = {}
|
|
134
109
|
|
|
135
|
-
!this.visible && (style.paddingRight = '0px')
|
|
110
|
+
!this.visible && (style.paddingRight = '0px')
|
|
136
111
|
|
|
137
|
-
return style
|
|
138
|
-
}
|
|
112
|
+
return style
|
|
113
|
+
},
|
|
139
114
|
},
|
|
140
|
-
mounted
|
|
115
|
+
mounted() {
|
|
141
116
|
this.$router.afterEach(() => {
|
|
142
117
|
this.isSidebarOpen = false
|
|
143
118
|
})
|
|
@@ -145,18 +120,18 @@ export default {
|
|
|
145
120
|
this.renderNavLinkState()
|
|
146
121
|
},
|
|
147
122
|
methods: {
|
|
148
|
-
toggleSidebar
|
|
123
|
+
toggleSidebar(to) {
|
|
149
124
|
this.isSidebarOpen = typeof to === 'boolean' ? to : !this.isSidebarOpen
|
|
150
125
|
this.$emit('toggle-sidebar', this.isSidebarOpen)
|
|
151
126
|
},
|
|
152
127
|
// side swipe
|
|
153
|
-
onTouchStart
|
|
128
|
+
onTouchStart(e) {
|
|
154
129
|
this.touchStart = {
|
|
155
130
|
x: e.changedTouches[0].clientX,
|
|
156
|
-
y: e.changedTouches[0].clientY
|
|
131
|
+
y: e.changedTouches[0].clientY,
|
|
157
132
|
}
|
|
158
133
|
},
|
|
159
|
-
onTouchEnd
|
|
134
|
+
onTouchEnd(e) {
|
|
160
135
|
const dx = e.changedTouches[0].clientX - this.touchStart.x
|
|
161
136
|
const dy = e.changedTouches[0].clientY - this.touchStart.y
|
|
162
137
|
if (Math.abs(dx) > Math.abs(dy) && Math.abs(dx) > 40) {
|
|
@@ -172,16 +147,18 @@ export default {
|
|
|
172
147
|
const navs = document.querySelectorAll('nav')
|
|
173
148
|
const navLinks = []
|
|
174
149
|
const sidebarLinks = Object.keys(this.$themeConfig.sidebar)
|
|
175
|
-
const matchSidebar = sidebarLinks
|
|
150
|
+
const matchSidebar = sidebarLinks
|
|
151
|
+
.filter(i => this.$page.path.includes(i))
|
|
152
|
+
.sort((a, b) => b.length - a.length)[0]
|
|
176
153
|
navs.forEach(nav => {
|
|
177
154
|
nav.querySelectorAll('a').forEach(navLink => {
|
|
178
|
-
if(navLink.className.indexOf('external') === -1) {
|
|
155
|
+
if (navLink.className.indexOf('external') === -1) {
|
|
179
156
|
navLinks.push(navLink)
|
|
180
157
|
}
|
|
181
158
|
})
|
|
182
159
|
})
|
|
183
160
|
|
|
184
|
-
navLinks.forEach((navLink,index) => {
|
|
161
|
+
navLinks.forEach((navLink, index) => {
|
|
185
162
|
navLink.classList.remove('router-link-active')
|
|
186
163
|
const matchWithoutMatchSidebar = sidebarLinks
|
|
187
164
|
.filter(i => i !== matchSidebar && i !== '/')
|
|
@@ -191,10 +168,7 @@ export default {
|
|
|
191
168
|
if (path) {
|
|
192
169
|
if (
|
|
193
170
|
navLink.href.match(matchSidebar) !== null &&
|
|
194
|
-
(
|
|
195
|
-
typeof matchWithoutMatchSidebar === 'undefined' ||
|
|
196
|
-
matchWithoutMatchSidebar.length < matchSidebar.length
|
|
197
|
-
)
|
|
171
|
+
(typeof matchWithoutMatchSidebar === 'undefined' || matchWithoutMatchSidebar.length < matchSidebar.length)
|
|
198
172
|
) {
|
|
199
173
|
navLink.classList.add('router-link-active')
|
|
200
174
|
}
|
|
@@ -204,7 +178,7 @@ export default {
|
|
|
204
178
|
} else {
|
|
205
179
|
// 0 => PC
|
|
206
180
|
// navLinks.length / 2 => mobile
|
|
207
|
-
if(index === 0 || index === navLinks.length / 2) {
|
|
181
|
+
if (index === 0 || index === navLinks.length / 2) {
|
|
208
182
|
navLink.classList.add('router-link-active')
|
|
209
183
|
return
|
|
210
184
|
}
|
|
@@ -220,19 +194,19 @@ export default {
|
|
|
220
194
|
const sidebarScrollTop = sidebarEL.scrollTop
|
|
221
195
|
const windowInnerHeight = window.innerHeight
|
|
222
196
|
const { height, top, bottom } = activeLink.getBoundingClientRect()
|
|
223
|
-
if (
|
|
224
|
-
activeLink.scrollIntoView({ block:
|
|
197
|
+
if (sidebarScrollTop + 50 > activeLink.offsetTop || bottom + height > windowInnerHeight) {
|
|
198
|
+
activeLink.scrollIntoView({ block: 'center' })
|
|
225
199
|
}
|
|
226
200
|
}
|
|
227
201
|
})
|
|
228
|
-
}
|
|
202
|
+
},
|
|
229
203
|
},
|
|
230
204
|
watch: {
|
|
231
205
|
isSidebarOpen: forbidScroll,
|
|
232
206
|
$route() {
|
|
233
207
|
this.renderNavLinkState()
|
|
234
208
|
this.activeSidebarLinkVisible()
|
|
235
|
-
}
|
|
236
|
-
}
|
|
209
|
+
},
|
|
210
|
+
},
|
|
237
211
|
}
|
|
238
212
|
</script>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vuepress-theme-uniapp-official",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.40",
|
|
4
4
|
"description": "uni-app official website theme for vuepress",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"repository": {
|
|
@@ -43,8 +43,13 @@
|
|
|
43
43
|
"vuepress-plugin-mermaidjs": "1.9.1",
|
|
44
44
|
"vuepress-plugin-named-chunks": "^1.1.4",
|
|
45
45
|
"vuepress-plugin-zooming": "^1.1.8",
|
|
46
|
-
"vuepress-plugin-
|
|
47
|
-
"vuepress-plugin-
|
|
46
|
+
"vuepress-plugin-check-md2": "^1.0.5",
|
|
47
|
+
"vuepress-plugin-expandable-row": "^1.0.10"
|
|
48
|
+
},
|
|
49
|
+
"resolutions": {
|
|
50
|
+
"terser-webpack-plugin": "1.4.6",
|
|
51
|
+
"markdown-it": "< 14",
|
|
52
|
+
"vue": "2.7.16"
|
|
48
53
|
},
|
|
49
54
|
"scripts": {
|
|
50
55
|
"publish:patch": "npm version patch && npm publish",
|
package/styles/navbar.styl
CHANGED
|
@@ -16,7 +16,7 @@ $navbar-logo-height = $navbar-main-navbar-height - 2rem
|
|
|
16
16
|
.title-logo
|
|
17
17
|
padding-left 20px
|
|
18
18
|
border-left 1px solid #ccc
|
|
19
|
-
@media (max-width:
|
|
19
|
+
@media (max-width: $DocSearch_MQMobile)
|
|
20
20
|
&
|
|
21
21
|
display none
|
|
22
22
|
.sub-navbar
|
|
@@ -35,8 +35,7 @@ $navbar-logo-height = $navbar-main-navbar-height - 2rem
|
|
|
35
35
|
justify-content center
|
|
36
36
|
align-items center
|
|
37
37
|
.main-navbar-links
|
|
38
|
-
width
|
|
39
|
-
white-space: nowrap;
|
|
38
|
+
width 55%
|
|
40
39
|
display inline-block
|
|
41
40
|
@media (min-width: 1080px) and (max-width: 1680px)
|
|
42
41
|
&
|
|
@@ -77,7 +76,7 @@ $navbar-logo-height = $navbar-main-navbar-height - 2rem
|
|
|
77
76
|
color inherit
|
|
78
77
|
&:hover
|
|
79
78
|
color $accentColor
|
|
80
|
-
|
|
79
|
+
|
|
81
80
|
.custom-main-navbar
|
|
82
81
|
position absolute
|
|
83
82
|
height 30px
|
|
@@ -87,7 +86,7 @@ $navbar-logo-height = $navbar-main-navbar-height - 2rem
|
|
|
87
86
|
display none
|
|
88
87
|
a
|
|
89
88
|
color inherit
|
|
90
|
-
.nav-dropdown
|
|
89
|
+
.nav-dropdown
|
|
91
90
|
right auto
|
|
92
91
|
left 0
|
|
93
92
|
z-index 12
|
|
@@ -100,7 +99,7 @@ $navbar-logo-height = $navbar-main-navbar-height - 2rem
|
|
|
100
99
|
user-select none
|
|
101
100
|
position absolute
|
|
102
101
|
right 12.5rem
|
|
103
|
-
@media (max-width:
|
|
102
|
+
@media (max-width: $DocSearch_MQMobile)
|
|
104
103
|
&
|
|
105
104
|
right 4.5rem
|
|
106
105
|
&>div:nth-child(1)
|
|
@@ -237,7 +236,7 @@ $navbar-logo-height = $navbar-main-navbar-height - 2rem
|
|
|
237
236
|
height 1px
|
|
238
237
|
background-color #e4e8eb
|
|
239
238
|
transform scaleY(.5)
|
|
240
|
-
.subnavbar__item
|
|
239
|
+
.subnavbar__item
|
|
241
240
|
a
|
|
242
241
|
display block
|
|
243
242
|
padding 0 16px
|
|
@@ -290,4 +289,4 @@ emphasize()
|
|
|
290
289
|
|
|
291
290
|
.sidebar-group.depth-1
|
|
292
291
|
.sidebar-links>li>.sidebar-link.active:not(.data-no-emphasize)
|
|
293
|
-
emphasize()
|
|
292
|
+
emphasize()
|
package/styles/palette.styl
CHANGED