CSS片段-双链加图标
...大约 2 分钟
说明:
实现给obsidian的双链加上图标,以示区别
使用方法:
- 复制以下代码,保存为
coffebean-双链加图标.css
文件格式 - 将
coffebean-双链加图标.css
复制到库的css片段中,刷新obsidian片段。重启obsidian生效
添加启动css片段的方法
- 打开obsidian设置 → 外观 → CSS 代码片段,点击此处的文件夹图标📁,打开css片段文件夹
- 复制你的css文件到这个文件夹,回到obsidian中,刷新并启动片段。偶尔需要重启ob生效
代码
代码框右下有复制按钮,点击自动复制代码
/*
@Author : 咖啡豆
@contact : https://obsidian.vip/
@File : coffeebean-双链加图标.css
@Software : vscode
@Date : 2022-08-09 23:15:00
@upDate : 2023-01-27 16:35:47
@Desc : 实现给obsidian的双链加上图标,以示区别
*/
/* 引用文件时,文件名前面会出现 “文档” icon */
.markdown-preview-view a.internal-link::before {
margin-right: 4px;
margin-left: 2px;
content: '';
background-image: url("data:image/svg+xml,%3Csvg t='1626093724345' class='icon' viewBox='0 0 1024 1024' version='1.1' xmlns='http://www.w3.org/2000/svg' p-id='3856' width='200' height='200'%3E%3Cpath d='M896.5 328.5h-256c-13.3 0-24-10.7-24-24v-256c0-13.3 10.7-24 24-24s24 10.7 24 24v232h232c13.3 0 24 10.7 24 24s-10.7 24-24 24z' fill='%230A59F7' p-id='3857'%3E%3C/path%3E%3Cpath d='M896.5 1000.5h-768c-13.3 0-24-10.7-24-24v-928c0-13.3 10.7-24 24-24h512c6.4 0 12.5 2.5 17 7l256 256c4.5 4.5 7 10.6 7 17v672c0 13.3-10.7 24-24 24z m-744-48h720V314.4L630.6 72.5H152.5v880z' fill='%230A59F7' p-id='3858'%3E%3C/path%3E%3Cpath d='M704.5 792.5h-384c-13.3 0-24-10.7-24-24s10.7-24 24-24h384c13.3 0 24 10.7 24 24s-10.7 24-24 24zM704.5 632.5h-384c-13.3 0-24-10.7-24-24s10.7-24 24-24h384c13.3 0 24 10.7 24 24s-10.7 24-24 24zM704.5 472.5h-384c-13.3 0-24-10.7-24-24s10.7-24 24-24h384c13.3 0 24 10.7 24 24s-10.7 24-24 24zM448.5 312.5h-128c-13.3 0-24-10.7-24-24s10.7-24 24-24h128c13.3 0 24 10.7 24 24s-10.7 24-24 24z' fill='%230A59F7' p-id='3859'%3E%3C/path%3E%3C/svg%3E");
background-size: 16px 16px;
transform: translate(0, 3px);
background-repeat: no-repeat;
display: inline-block;
height: 16.8px;
width: 16.33px;
}
Powered by Waline v2.15.4