\hexo\node_modules\hexo-theme-next\source\css\_common\components\post\index.styl
,在该文件中搜索.post-block
,修改如下:
1 2 3 4 5 6 7 8 9 10 11 12
| .use-motion { if (hexo-config('motion.transition.post_block')) { .post-block, { padding: 25px; -webkit-box-shadow: 0 0 5px rgba(202, 203, 203, 0.5); -moz-box-shadow: 0 0 5px rgba(202, 203, 204, 0.5); } .pagination, .comments { visibility: hidden; } } }
|
修改后显示效果如下:
【推荐,防止更新主题重置】或者修改主题的config.yml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
|
custom_file_path: sidebar: source/_data/sidebar.njk footer: source/_data/footer.njk style: source/_data/styles.styl
|
新建文件source/_data/styles.styl,在文件中添加如下内容:
1 2 3 4 5 6 7 8 9 10 11 12
| .use-motion { if (hexo-config('motion.transition.post_block')) { .post-block, { padding: 25px; -webkit-box-shadow: 0 0 5px rgba(202, 203, 203, 0.5); -moz-box-shadow: 0 0 5px rgba(202, 203, 204, 0.5); } .pagination, .comments { visibility: hidden; } } }
|