-
-
+
+
+
@@ -47,11 +34,11 @@ export default {
},
computed: {
- userNav () {
+ userNav() {
return this.$themeLocaleConfig.nav || this.$site.themeConfig.nav || []
},
- nav () {
+ nav() {
const { locales } = this.$site
if (locales && Object.keys(locales).length > 1) {
const currentLink = this.$page.path
@@ -62,7 +49,8 @@ export default {
ariaLabel: this.$themeLocaleConfig.ariaLabel || 'Select language',
items: Object.keys(locales).map(path => {
const locale = locales[path]
- const text = themeLocales[path] && themeLocales[path].label || locale.lang
+ const text =
+ (themeLocales[path] && themeLocales[path].label) || locale.lang
let link
// Stay on the current page
if (locale.lang === this.$lang) {
@@ -83,7 +71,7 @@ export default {
return this.userNav
},
- userLinks () {
+ userLinks() {
return (this.nav || []).map(link => {
return Object.assign(resolveNavLinkItem(link), {
items: (link.items || []).map(resolveNavLinkItem)
@@ -91,17 +79,15 @@ export default {
})
},
- repoLink () {
+ repoLink() {
const { repo } = this.$site.themeConfig
if (repo) {
- return /^https?:/.test(repo)
- ? repo
- : `https://github.com/${repo}`
+ return /^https?:/.test(repo) ? repo : `https://github.com/${repo}`
}
return null
},
- repoLabel () {
+ repoLabel() {
if (!this.repoLink) return
if (this.$site.themeConfig.repoLabel) {
return this.$site.themeConfig.repoLabel
@@ -128,6 +114,7 @@ export default {
a
line-height 1.4rem
color inherit
+ font-weight 500
&:hover, &.router-link-active
color $accentColor
.nav-item
diff --git a/src/.vuepress/theme/components/Sidebar.vue b/src/.vuepress/theme/components/Sidebar.vue
index 2ee765aae0..fe1f8b1f7e 100644
--- a/src/.vuepress/theme/components/Sidebar.vue
+++ b/src/.vuepress/theme/components/Sidebar.vue
@@ -42,7 +42,7 @@ export default {
font-size 1.1em
padding 0.5rem 0 0.5rem 1.5rem
& > .sidebar-links
- padding calc(1.5rem + 3rem) 0 // add $betaBannerHeight
+ padding 1.5rem 0
& > li > a.sidebar-link
font-size 1.1em
line-height 1.7
diff --git a/src/.vuepress/theme/styles/index.styl b/src/.vuepress/theme/styles/index.styl
index 5a0d16ae99..14e77c7dd7 100644
--- a/src/.vuepress/theme/styles/index.styl
+++ b/src/.vuepress/theme/styles/index.styl
@@ -23,7 +23,7 @@ body
.navbar
position fixed
z-index 20
- top 0
+ top 37px
left 0
right 0
height $navbarHeight
@@ -110,7 +110,7 @@ strong
font-weight 600
h1, h2, h3, h4, h5, h6
- font-weight 600
+ font-weight 500
line-height 1.25
{$contentClass}:not(.custom) > &
@@ -135,6 +135,7 @@ h1, h2, h3, h4, h5, h6
h1
font-size 2.2rem
+ font-weight 600
h2
font-size 1.65rem