比如输入标题时可以自动编号 1 1.1 1.2 1.3 这种?可选第一级标题不自动编号,从二级标题可以自动编号
[功能建议] 可不可以加入标题自动编号的功能?
本贴最后更新于 1111 天前,其中的信息可能已经时异事殊
相关帖子
-
-
在主题中加入如下样式即可实现自动编号(导出为 HTML/PDF 时也能保留)
PS: 可以更改
font-size
字段调整编号的大小body { counter-reset: h1-count 0; } h1, .h1 { counter-reset: h2-count 0; } h2, .h2 { counter-reset: h3-count 0; } h3, .h3 { counter-reset: h4-count 0; } h4, .h4 { counter-reset: h5-count 0; } h5, .h5 { counter-reset: h6-count 0; } .protyle-wysiwyg [data-node-id].h1:before, .b3-typography h1:before { display: block; float: left; font-size: 50%; counter-increment: h1-count; content: counter(h1-count) "\00A0"; } .protyle-wysiwyg [data-node-id].h2:before, .b3-typography h2:before { display: block; float: left; font-size: 50%; counter-increment: h2-count; content: counter(h1-count) "."counter(h2-count) "\00A0"; } .protyle-wysiwyg [data-node-id].h3:before, .b3-typography h3:before { display: block; float: left; font-size: 50%; counter-increment: h3-count; content: counter(h1-count) "."counter(h2-count) "."counter(h3-count) "\00A0"; } .protyle-wysiwyg [data-node-id].h4:before, .b3-typography h4:before { display: block; float: left; font-size: 50%; counter-increment: h4-count; content: counter(h1-count) "."counter(h2-count) "."counter(h3-count) "."counter(h4-count) "\00A0"; } .protyle-wysiwyg [data-node-id].h5:before, .b3-typography h5:before { display: block; float: left; font-size: 50%; counter-increment: h5-count; content: counter(h1-count) "."counter(h2-count) "."counter(h3-count) "."counter(h4-count) "."counter(h5-count) "\00A0"; } .protyle-wysiwyg [data-node-id].h6:before, .b3-typography h6:before { display: block; float: left; font-size: 50%; counter-increment: h6-count; content: counter(h1-count) "."counter(h2-count) "."counter(h3-count) "."counter(h4-count) "."counter(h5-count) "."counter(h6-count) "\00A0"; }
1 回复
请输入回帖内容
...
欢迎来到这里!
我们正在构建一个小众社区,大家在这里相互信任,以平等 • 自由 • 奔放的价值观进行分享交流。最终,希望大家能够找到与自己志同道合的伙伴,共同成长。
注册 关于