Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
是否可以更改代码块的背景颜色和其他属性?是否有与代码块相关的类?
修改内联代码的背景颜色很简单:
.remark-inline-code{ background-color: #000000 }
但我无法找到专门用于代码块的等价物。
使用 Chrome 开发人员工具检查 div,您会看到颜色是由 class 设置的.hljs-github .hljs。
.hljs-github .hljs
环境
.hljs-github .hljs { background: red; }
应该做你想做的:)