#update if site.data.update each i in site.data.update .author-content.author-content-item.UpdatePage.single(style = `background: url(${i.top_background}) left 37% / cover no-repeat !important;`) .card-content .author-content-item-tips=i.class_name span.author-content-item-title=i.description .content-bottom .tips=i.tip .banner-button-group a.banner-button(href=i.buttonLink) i.anzhiyufont.anzhiyu-icon-arrow-circle-right(style='font-size: 1.3rem') span.banner-button-text=i.buttonText
#article-container != page.content
4.添加 update.yml 文件
在 source/_data 下新建 update.yml 文件,并添加以下内容:
1 2 3 4 5 6
-top_background:"https://xxxxxx.png" class_name:"Update Class 1" description:"Description of the first update" tip:"Tip for the first update" buttonLink:"http://link_to_update1.com" buttonText:"More"
如果不想要页面上方图片,将此文件中的内容全部注释即可
5.新建 Update 页面
使用 Hexo new page update 命令新建页面,并在 Front-matter 中添加 type: update。