markdown - styles.css 在 markdown 和 bookdown 中的行为不同
问题描述
我使用框和图标来突出我的降价文件中的段落。最近我想将我的单个文件以 bookdown 格式编译为章节。以下内容在独立降价中效果很好:
---
title: "Untitled"
author: "Author"
output: html_document
---
<html>
<style>
.infobox {
padding: 1em 1em 1em 4em;
margin-bottom: 10px;
border: 0px solid blue;
border-radius: 10px;
background: #f5f5f5 5px center/3em no-repeat;
}
.information {
background-image: url("question.png");
}
</style>
</html>
::: {.infobox .information data-latex="warning"}
Hello World.
:::
并且在 bookdown 中不起作用。似乎以不同的方式处理图像或路径。有人可以帮忙吗?我很确定它原则上是有效的,因为 yihui 在 bookdown 中使用它:
https://bookdown.org/yihui/blogdown/website-basics.html
我想拥有这么漂亮的仙人掌。
解决方案
推荐阅读
- ios - 没有 AppDelegate 的 SwiftUI 远程推送通知(Firebase 云消息传递)
- javascript - 重分类和求和图像集合 MODIS Google Earth Engine
- selenium - Selenium Edge 驱动程序和文件输入类型
- javascript - ReactJS 与 Google AdSense
- python - 如何根据 Pandas 中的一列列表组合两个数据框
- python - Python:BeautifulSoup find_all 在标签内搜索还是其他一切?
- c++ - MFC 中带有 2 个指针的滑块
- c# - 传送门不断地来回传送我
- python - 如何定位 pygal 图表?(烧瓶)
- javascript - 获取 JSON 并显示 HTML 表格