fix: fix title display in homeBlog.vue

This commit is contained in:
reco_luan 2019-12-09 11:31:35 +08:00
parent 106f72d860
commit 80dc4d7254
2 changed files with 15 additions and 15 deletions

View File

@ -7,12 +7,12 @@
background: `url(${$frontmatter.bgImage ? $withBase($frontmatter.bgImage) : require('../images/home-bg.jpg')}) center/cover no-repeat`}"></div>
<ModuleTransition>
<img
v-if="recoShowModule && $frontmatter.isShowHeroImage === true"
:style="heroImageStyle"
:src="$frontmatter.heroImage ? $withBase($frontmatter.heroImage) : require('../images/icon_vuepress_reco.png')"
v-if="recoShowModule && $frontmatter.heroImage"
:style="heroImageStyle || {}"
:src="$withBase($frontmatter.heroImage)"
alt="hero">
</ModuleTransition>
<ModuleTransition>
<ModuleTransition delay="0.04">
<h1 v-if="$frontmatter.isShowTitleInHome !== false">{{ $frontmatter.heroText || $title || '午后南杂' }}</h1>
</ModuleTransition>
@ -184,7 +184,7 @@ export default {
bottom 0
left 0
right 0
z-index 0
z-index -1
&:after {
display block
content ' '

View File

@ -1,15 +1,15 @@
---
home: true
heroImage: /hero.png
heroImageStyle: {
maxWidth: '600px',
width: '100%',
display: block,
margin: '9rem auto 2rem',
background: '#fff',
borderRadius: '1rem',
}
isShowTitleInHome: false
# heroImage: /hero.png
# heroImageStyle: {
# maxWidth: '600px',
# width: '100%',
# display: block,
# margin: '9rem auto 2rem',
# background: '#fff',
# borderRadius: '1rem',
# }
# isShowTitleInHome: false
actionText: Guide
actionLink: /views/other/guide
features: