css - 如何调整嵌套 UL 列表项的行距
问题描述
在从 Rmarkdown 生成的网络绑定文档中,我有迷你章节目录,格式为 s,具有两级列表项。
<div class="chaptercontents">
#### Chapter contents {-}
* Cholera
+ Farr's Diagrams
+ Farr's Natural Law of Cholera
+ The Transcendent Effect of Water
* John Snow on Cholera
+ The Broad Street Pump
+ The Neighborhoods Map
* Re-visioning the Broad Street Pump
* Graphical Successes and Failures
+ The Answer: A Bug
+ Florence Nightingale's Graphical Success
</div>
我在我的 CSS 文件中对章节内容使用这种样式:
.chaptercontents {
background-color: #daeff0;
}
.chaptercontents li {
line-height: 6px;
}
但是,每 2 级列表的第一项的间距是关闭的。我该如何纠正?
解决方案
推荐阅读
- c# - Sharepoint 2013“所有人”用户权限
- sql - SQL 查询最近 7 天日期前 3 名的售罄产品
- c# - 如何通过单击 ListView 中的特定行来打开表单
- awk - 使用 AWK 查找表并将第一个文件的第一列替换为第二个文件的另一列
- openlayers - OpenLayers 和 KML 支持
- python - 如何在不使用继承且不初始化init的情况下获取另一个类中一个类的变量的值?
- c++ - 在 C++ 中使用 Gdiplus 创建透明位图
- spring - Spring WebClient发生连接丢失时如何处理异常
- c# - T4 CustomHost 错误空路径 System.IO.FileStream.Init
- elixir - Elixir 中 == 和 === 有什么区别?