Skip to content

Instantly share code, notes, and snippets.

@muyexi
Created April 5, 2026 06:59
Show Gist options
  • Select an option

  • Save muyexi/44d374e738cd89307dc3f0e911132107 to your computer and use it in GitHub Desktop.

Select an option

Save muyexi/44d374e738cd89307dc3f0e911132107 to your computer and use it in GitHub Desktop.
Claude.ai theme for Markdown Viewer browser extension
/* Claude.ai Theme for Markdown Viewer */
/* https://github.com/simov/markdown-viewer */
/* ── Fonts ── */
@font-face {
font-family: anthropicSerif;
src: url(https://assets-proxy.anthropic.com/claude-ai/v1/_next/static/media/fe66948be403232d-s.p.woff2) format("woff2");
font-display: swap;
font-weight: 300 800;
font-style: normal;
}
@font-face {
font-family: anthropicSerif;
src: url(https://assets-proxy.anthropic.com/claude-ai/v1/_next/static/media/56139cc7a3934d47-s.p.woff2) format("woff2");
font-display: swap;
font-weight: 300 800;
font-style: italic;
}
@font-face {
font-family: anthropicSans;
src: url(https://assets-proxy.anthropic.com/claude-ai/v1/_next/static/media/01d1396bd69a228a-s.p.woff2) format("woff2");
font-display: swap;
font-weight: 300 800;
font-style: normal;
}
@font-face {
font-family: anthropicSans;
src: url(https://assets-proxy.anthropic.com/claude-ai/v1/_next/static/media/8d6f5db32d507c08-s.p.woff2) format("woff2");
font-display: swap;
font-weight: 300 800;
font-style: italic;
}
@font-face {
font-family: anthropicMono;
src: url(https://assets-proxy.anthropic.com/claude-ai/v1/_next/static/media/5ab84f5ed5bd55bd-s.p.woff2) format("woff2");
font-display: swap;
font-weight: 300 800;
font-style: normal;
}
@font-face {
font-family: anthropicMono;
src: url(https://assets-proxy.anthropic.com/claude-ai/v1/_next/static/media/c25fe61b276783b5-s.p.woff2) format("woff2");
font-display: swap;
font-weight: 300 800;
font-style: italic;
}
/* ── Light Mode (default) ── */
@media (prefers-color-scheme: light) {
body {
color: hsl(60 2.6% 7.6%);
background: hsl(48 33.3% 97.1%);
}
a { color: hsl(210 73.7% 40.2%); }
a:hover { color: hsl(210 70.9% 51.6%); }
hr {
border-color: hsl(30 3.3% 11.8% / 0.3);
}
blockquote {
border-left-color: hsl(30 3.3% 11.8% / 0.3);
background: hsl(48 33.3% 97.1%);
}
code:not([class^="language-"]):not([class^="hljs"]) {
background: hsl(48 33.3% 97.1%);
color: hsl(60 2.6% 7.6%);
}
pre {
background: #282c34;
}
table th {
color: hsl(60 2.6% 7.6%);
border-bottom-color: hsl(30 3.3% 11.8% / 0.6);
}
table td {
border-bottom-color: hsl(30 3.3% 11.8% / 0.3);
}
table tr:nth-child(even) td {
background: hsl(48 33.3% 97.1%);
}
}
/* ── Dark Mode ── */
@media (prefers-color-scheme: dark) {
body {
color: hsl(48 33.3% 97.1%);
background: hsl(60 2.1% 18.4%);
}
a { color: hsl(210 65.5% 67.1%); }
a:hover { color: hsl(210 70.9% 51.6%); }
strong, b { font-weight: 530; }
hr {
border-color: hsl(51 16.5% 84.5% / 0.3);
}
blockquote {
border-left-color: hsl(51 16.5% 84.5% / 0.3);
background: hsl(60 2.7% 14.5%);
}
code:not([class^="language-"]):not([class^="hljs"]) {
background: hsl(60 2.7% 14.5%);
color: hsl(48 33.3% 97.1%);
}
pre {
background: #282c34;
}
table th {
color: hsl(48 33.3% 97.1%);
border-bottom-color: hsl(51 16.5% 84.5% / 0.6);
}
table td {
border-bottom-color: hsl(51 16.5% 84.5% / 0.3);
}
table tr:nth-child(even) td {
background: hsl(60 2.7% 14.5%);
}
}
/* ── Base ── */
body {
font-family: anthropicSerif, Georgia, "Times New Roman", Times, serif;
font-weight: 400;
line-height: 1.7;
max-width: 48rem;
margin: 0 auto;
padding: 1.5rem 2.75rem;
}
/* ── Headings ── */
h1, h2, h3, h4, h5, h6 {
font-weight: 600;
margin-top: 1.5rem;
margin-bottom: 0.25rem;
}
h1 {
font-size: 1.375rem;
margin-top: 0.75rem;
}
h2 {
font-size: 1.125rem;
margin-top: 0.75rem;
}
h3 {
font-size: 1rem;
margin-top: 0.5rem;
}
h4 {
font-size: 0.875rem;
}
/* ── Paragraph ── */
p {
margin: 0;
line-height: 1.7;
overflow-wrap: break-word;
}
p + p {
margin-top: 0.875rem;
}
/* ── Links ── */
a {
text-decoration: none;
}
a:hover {
text-decoration: underline;
}
/* ── Bold / Italic ── */
strong, b {
font-weight: 600;
}
/* ── Horizontal Rule ── */
hr {
border: none;
border-top: 0.5px solid;
margin: 0.75rem 0.375rem;
}
/* ── Lists ── */
ul {
list-style-type: disc;
padding-left: 2rem;
margin: 0 0 0.75rem;
display: flex;
flex-direction: column;
gap: 0.25rem;
}
ol {
list-style-type: decimal;
padding-left: 2rem;
margin: 0 0 0.75rem;
display: flex;
flex-direction: column;
gap: 0.25rem;
}
li {
padding-left: 0.5rem;
overflow-wrap: break-word;
}
li ul, li ol {
margin-top: 0.25rem;
margin-bottom: 0;
}
/* ── Blockquote ── */
blockquote {
border-left: 3px solid;
padding: 0.25rem 1rem;
margin: 0.75rem 0;
}
blockquote p {
margin: 0.25rem 0;
}
/* ── Inline Code ── */
code:not([class^="language-"]):not([class^="hljs"]) {
font-family: anthropicMono, ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
font-size: 0.813rem;
line-height: 1.5;
border-radius: 0.25rem;
padding: 0.125rem 0.375rem;
font-weight: 400;
}
/* ── Code Block ── */
pre {
border-radius: 0.75rem;
padding: 1rem;
margin: 0.5rem 0;
overflow-x: auto;
}
pre code {
font-family: anthropicMono, ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
font-size: 0.813rem;
line-height: 1.5;
font-weight: 400;
background: none;
padding: 0;
}
/* ── Table ── */
table {
min-width: 100%;
border-collapse: collapse;
font-size: 0.875rem;
line-height: 1.7;
margin: 0.5rem 0 1.5rem;
}
thead {
text-align: left;
}
th {
font-weight: 600;
padding: 0.5rem 1rem 0.5rem 0;
border-bottom-width: 0.5px;
border-bottom-style: solid;
vertical-align: top;
text-align: left;
}
td {
padding: 0.5rem 1rem 0.5rem 0;
border-bottom-width: 0.5px;
border-bottom-style: solid;
vertical-align: top;
}
/* ── Image ── */
img {
max-width: 100%;
height: auto;
border-radius: 0.5rem;
}
/* ── Syntax Highlighting (One Dark) ── */
pre code.hljs { display: block; overflow-x: auto; padding: 1em; }
code.hljs { padding: 3px 5px; }
.hljs { color: #abb2bf; background: #282c34; }
.hljs-comment, .hljs-quote { color: #5c6370; font-style: italic; }
.hljs-doctag, .hljs-formula, .hljs-keyword { color: #c678dd; }
.hljs-deletion, .hljs-name, .hljs-section, .hljs-selector-tag, .hljs-subst { color: #e06c75; }
.hljs-literal { color: #56b6c2; }
.hljs-addition, .hljs-attribute, .hljs-meta .hljs-string, .hljs-regexp, .hljs-string { color: #98c379; }
.hljs-attr, .hljs-number, .hljs-selector-attr, .hljs-selector-class, .hljs-selector-pseudo, .hljs-template-variable, .hljs-type, .hljs-variable { color: #d19a66; }
.hljs-bullet, .hljs-link, .hljs-meta, .hljs-selector-id, .hljs-symbol, .hljs-title { color: #61aeee; }
.hljs-built_in, .hljs-class .hljs-title, .hljs-title.class_ { color: #e6c07b; }
.hljs-emphasis { font-style: italic; }
.hljs-strong { font-weight: 700; }
.hljs-link { text-decoration: underline; }
/* ── Content Spacing (mimics Claude's grid gap) ── */
body > * + * {
margin-top: 0.875rem;
}
body > hr + h1,
body > hr + h2,
body > hr + h3,
body > hr + h4 {
margin-top: 0 !important;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment