使用说明 1、新增文章 根目录命令行输入hexo new <模板> <文章名>新建文章
2、发布 1 hexo clean && hexo g && hexo d
主题配置 1、系统图标配置 系统图标访问不到 国内无法访问https://use.fontawesome.com/, 导致图标不能显示。需要在主题配置里替换国内的CDN。 修改主题配置文件_config.yml中
1 2 3 4 5 6 7 providers: cdn: jsdelivr fontcdn: google iconcdn: https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@5.14.0/css/all.css`
2、主页三栏文章详情两栏 1、添加主题配置文件 复制_config.yml,生成一个_config.post.yml配置文件,设置_config.post.yml右侧没有widgets,在文章详情就两栏显示。 但是文章显示的时候比较布局臃肿,可以修改样式表调整样式。
2、修改样式 修改icarus/include/style/base.styl
中widescreen、fullhd的值
1 2 3 4 5 $gap ?= 64px $tablet ?= 769px $desktop ?= 1088px $widescreen ?= 1280px $fullhd ?= 1280px
diff:icarus/layout/common/widgets.jsx 1 2 3 4 5 6 7 8 9 10 function getColumnSizeClass(columnCount) { switch (columnCount) { case 2: - return 'is-4-tablet is-4-desktop is-4-widescreen'; + return 'is-4-tablet is-4-desktop is-3-widescreen' case 3: return 'is-4-tablet is-4-desktop is-3-widescreen'; } return ''; }
diff:/icarus/layout/layout.jsx 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 <body class={`is-${columnCount}-column`}> <Navbar config={config} helper={helper} page={page} /> <section class="section"> <div class="container"> <div class="columns"> <div class={classname({ column: true, 'order-2': true, 'column-main': true, 'is-12': columnCount - 'is-8-tablet is-8-desktop is-8-widescreen': + 'is-8-tablet is-8-desktop is-9-widescreen': columnCount 'is-8-tablet is-8-desktop is-6-widescreen': columnCount })} dangerouslySetInnerHTML={{ __html: body }}></div> <Widgets site={site} config={config} helper={helper} page={page} position={'left'} /> <Widgets site={site} config={config} helper={helper} page={page} position={'right'} /> </div> </div> </section> <Footer config={config} helper={helper} /> <Scripts site={site} config={config} helper={helper} page={page} /> <Search config={config} helper={helper} /> </body>
并修改尺寸
diff:/icarus/include/style/responsive.styl 1 2 3 4 5 6 7 8 9 10 11 12 +fullhd() .is-2-column .container max-width: $widescreen - 2 * $gap width: $widescreen - 2 * $gap .is-1-column .container max-width: $desktop - 2 * $gap width: $desktop - 2 * $gap + .is-3-column .container + max-width: screen-widescreen - gap + width: screen-widescreen - gap
顺便说一句你要找的问题 issues 上都有,如果没有,那你就new一个😄。