Closed Rean-Schwarze closed 6 months ago
标签居右是更换了 markdown-it 插件
字体需要自定义配置
font:
font-size: 16px
code-font-size: 16px
font-family: '"PingFang SC","Hiragino Sans GB","Microsoft YaHei"'
code-font-family: 'monospace, monospace'
字体需要自定义配置
font: font-size: 16px code-font-size: 16px font-family: '"PingFang SC","Hiragino Sans GB","Microsoft YaHei"' code-font-family: 'monospace, monospace'
如果是默认的配置,这两个地方的字体都是宋体
更改code-font-family第一个字体为consolas,这里的字体
可以起作用,但是代码块仍然是宋体
font:
font-size: 16px
code-font-size: 16px
font-family: '"PingFang SC","Hiragino Sans GB","Microsoft YaHei"'
code-font-family: 'consolas, consolas'
(另外还发现这里有序列表的序号似乎全是1)
标签居右是更换了 markdown-it 插件
这里没太懂,可以详细一点吗
发链接给我
你电脑没这个字体吧,我这里正常显示
标签靠右需要调整一下配置项,参考一下:
# markdown-it
markdown:
preset: 'default'
render:
html: true
xhtmlOut: false
langPrefix: 'language-'
breaks: true
linkify: true
typographer: true
quotes: '“”‘’'
enable_rules:
disable_rules:
plugins:
- '@renbaoshuo/markdown-it-katex'
anchors:
level: 2
collisionSuffix: ''
permalink: true
permalinkClass: 'headerlink'
permalinkSide: 'left'
permalinkSymbol: ''
case: 0
separator: '-'
images:
lazyload: true
prepend_root: false
post_asset: false
inline: false
里面使用了ketx插件
字体是有的 而且这里的字体显示正常 只有下面代码的字体不正常,然后用手机访问能正常显示。。。好怪啊 同样的字体配置,用回butterfly主题,可以正常显示
然后居右的问题,调整了配置项还是没有解决 附一个控制台信息
是dev分支吧,重新拉一下
清一下缓存
我这里都显示正常的字体
还是不行,不知道哪一环有问题,这里css去掉flex-derection就居左了
字体的话似乎是配置无法影响到最终的css,使用的是默认的monospace
还是不行,不知道哪一环有问题,这里css去掉flex-derection就居左了
打印一下使用的插件 npm ls -dept 0
字体的话可能是edge的锅了 默认monospace显示就是不行的。。。
但是改solitude/source/css/_global/index.styl
的134行为font-family consolas, monospace
可以暂时解决
font:
font-size: 16px
code-font-size: 16px
font-family: 'PingFang SC, Hiragino Sans GB, Microsoft YaHei'
code-font-family: 'monospace, monospace'
标题在右是因为使用了markdown-it插件但没有设置 headerlink,需要加上,permalinkSymbol 可以为 ''
代码字体不对看你自己的配置项
字体配置没问题,是配置无法应用到css上,这个是在chechThemeConfig
里面log的hexo.theme.config
_config.yml
设置也设了,但是还是居右
同样改solitude/source/css/_post/content.styl
的172行为flex-direction row
可暂时解决
加群给我远程帮你看一下
加群给我远程帮你看一下
请问能加一下群吗,我遇到了似乎是,一样的问题
加群给我远程帮你看一下
请问能加一下群吗,我遇到了似乎是,一样的问题
加群,群在issue里有跳转
前置确认
⚠️ 搜索issues中是否已存在类似问题
操作系统类型?
Windows
运行的Hexo版本是?
Hexo 7.0.0
你所使用的主题版本是稳定/最新?
稳定版(main)
问题描述 😯
如图所示,在官方的演示网站上同样存在代码块字体变宋体的问题;标签居右的原因未知,使用默认主题设置的时候仍然存在这个问题
终端日志 📒
No response