This snippet makes your Obsidian.md code blocks look a little fancier
- Download the files (Code -> Download ZIP)
- Open your Obsidian.md vault in explorer
- Copy and paste the .obsidian folder in it
- Go to: Obsidian app -> Settings -> Appearance -> CSS Snippets
- Turn on "Neat code blocks"
- (optional) copy and paste the 'Showcase.md' file to your vault too
- Go to: Obsidian app -> Settings -> Appearance -> CSS Snippets
- Open in explorer
- Open the Neat code blocks.css
- In the
:root { ... }
add:
/* I recommend copying the lang's logo color to here */
--NAME-color: rgb(0, 0, 0); /* or #ffffff. Left border color */
--NAME-content: 'NAME'; /* displayed name */
- Copy and paste this to the end of the file and change the
NAME
:
pre>code.language-NAME {
border-color: var(--NAME-color); /* change the name */
}
pre>code.language-NAME::after {
content: var(--NAME-content); /* change the name */
}
Might as well contribute after that