一个用于在 mkdocs 文档中插入 changelog 时间轴的插件。
预览:https://note.tonycrane.cc/changelog/
可以通过 pypi 直接安装:
$ pip install mkdocs-changelog-plugin
也可以从源码安装
$ git clone https://github.com/TonyCrane/mkdocs-changelog-plugin.git
$ cd mkdocs-changelog-plugin
$ pip install . # or pip install -e .
yaml
plugins:
- changelogyaml
changelog: Truemarkdown
{{ placeholder }}例如:
- "placeholder1":
- "time1":
- "type": text
- "type": text
- "placeholder":
- "time2":
- "type":
text: text
href: /link/to/page/
- "type":
text: text
href: /link/to/page/
- "time3":
- "type": text
css
.changelog-type-refactor {
background-color: #c63f94b0;
}
.changelog-type-refactor::before {
content: "文档重构";
}具体可以参考我的 changelog.yml。
感觉 mkdocs 主流主题只有 material 用得多了,所以没做其他主题的适配。基本上就差在几个颜色的问题上,问题不大,可以自己通过 css 来覆盖这里规定的颜色,具体看 css/timeline.css。
嘛,基本就是我用纯 html+css 糊出来自己用的,然后为了方便写了个插件,代码也比较乱,在别人的主题里面可能会~~格式混乱、颜色爆炸~~。有想修改、改进的我非常且热烈欢迎,尽管 PR 就好(
$ claude mcp add mkdocs-changelog-plugin \
-- python -m otcore.mcp_server <graph>