Skip to content

Instantly share code, notes, and snippets.

@qzi
Created November 21, 2025 21:02
Show Gist options
  • Select an option

  • Save qzi/0ef17e739b19d8065e9d4881fdda0efb to your computer and use it in GitHub Desktop.

Select an option

Save qzi/0ef17e739b19d8065e9d4881fdda0efb to your computer and use it in GitHub Desktop.
markdown.preview.for.vscode.css
/* VS Code Markdown Preview */
/* Center images */
img {
display: block;
margin-left: auto;
margin-right: auto;
}
/* Desktop left-aligned images */
@media (min-width: 768px) {
img {
margin-left: 0;
margin-right: auto;
}
}
/* Lists */
ul, ol {
padding-left: 1.5em;
margin-bottom: 1.5em;
}
/* Bullets */
ul li::marker {
color: #a1a1a1;
font-size: 1em;
}
/* List items */
li {
margin-bottom: 0.5em;
line-height: 1.6;
position: relative;
}
/* Links - Use VS Code variables for theme adaptation */
/* Light theme: gray text, dark theme: white text */
body.vscode-light a {
color: #555;
text-decoration: none;
border-bottom: 1px solid #999;
transition: all 0.2s ease;
}
body.vscode-light a:hover {
color: #222;
border-bottom-color: #222;
transition: all 0.2s ease;
}
body.vscode-dark a,
body.vscode-high-contrast a {
color: #fff;
text-decoration: none;
border-bottom: 1px solid #999;
transition: all 0.2s ease;
}
body.vscode-dark a:hover,
body.vscode-high-contrast a:hover {
color: #fff;
border-bottom-color: #fff;
transition: all 0.2s ease;
}
/* Fallback for when body class is not available */
a {
color: #555;
text-decoration: none;
border-bottom: 1px solid #999;
transition: all 0.2s ease;
}
a:hover {
color: #222;
border-bottom-color: #222;
transition: all 0.2s ease;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment