Skip to content

Commit

Permalink
v1.6.3
Browse files Browse the repository at this point in the history
  • Loading branch information
xugaoyi committed Dec 15, 2020
1 parent a306a03 commit 8a75b5b
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 10 deletions.
1 change: 1 addition & 0 deletions docs/.vuepress/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ module.exports = {
// showToArticle: true, // 显示到文章页底部,默认true
// moreArticle: '/archives' // “更多文章”跳转的页面,默认'/archives'
// },
// rightMenuBar: false, // 是否显示右侧文章大纲栏,默认true (屏宽小于1300px下无论如何都不显示)
// sidebarOpen: false, // 初始状态是否打开侧边栏,默认true
// pageButton: false, // 是否显示快捷翻页按钮,默认true

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"vuepress-plugin-one-click-copy": "^1.0.2",
"vuepress-plugin-thirdparty-search": "^1.0.2",
"vuepress-plugin-zooming": "^1.1.7",
"vuepress-theme-vdoing": "^1.6.2",
"vuepress-theme-vdoing": "^1.6.3",
"yamljs": "^0.3.0"
},
"dependencies": {
Expand Down
18 changes: 13 additions & 5 deletions theme-vdoing/components/Page.vue
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,13 @@ export default {
return !this.$frontmatter.pageComponent
},
showRightMenu () {
return this.$page.headers && (this.$frontmatter && this.$frontmatter.sidebar && this.$frontmatter.sidebar !== false) !== false
const { $frontmatter, $themeConfig, $page } = this
const { sidebar } = $frontmatter
return (
$themeConfig.rightMenuBar !== false &&
$page.headers &&
($frontmatter && sidebar && sidebar !== false) !== false
)
},
pageComponent () {
return this.$frontmatter.pageComponent ? this.$frontmatter.pageComponent.name : false
Expand Down Expand Up @@ -138,9 +144,11 @@ export default {
.page
padding-right 0.8rem !important
@media (max-width 1279px)
.right-menu-wrapper
display none
.have-rightmenu
.right-menu-wrapper
display none
@media (min-width 1280px)
.sidebar .sidebar-sub-headers
display none
.have-rightmenu
.sidebar .sidebar-sub-headers
display none
</style>
6 changes: 3 additions & 3 deletions theme-vdoing/components/SidebarGroup.vue
Original file line number Diff line number Diff line change
Expand Up @@ -81,12 +81,12 @@ export default {
&.is-sub-group
padding-left 0
& > .sidebar-heading
font-size 1em
font-size 1.01em
line-height 1.4
font-weight normal
font-weight bold
padding-left 2rem
&:not(.clickable)
opacity 0.5
// opacity 0.9
& > .sidebar-group-items
padding-left 1rem
& > li > .sidebar-link
Expand Down
1 change: 1 addition & 0 deletions theme-vdoing/layouts/Layout.vue
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ export default {
const { headers } = this.$page
return (
!this.$frontmatter.home
&& this.$themeConfig.rightMenuBar !== false
&& headers
&& headers.length
&& this.$frontmatter.sidebar !== false
Expand Down
2 changes: 1 addition & 1 deletion theme-vdoing/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vuepress-theme-vdoing",
"version": "1.6.2",
"version": "1.6.3",
"description": "Vdoing theme for VuePress. 一个基于VuePress的知识管理兼博客主题。",
"author": {
"name": "gaoyi(Evan) Xu"
Expand Down

0 comments on commit 8a75b5b

Please sign in to comment.