Skip to content

Instantly share code, notes, and snippets.

@chev2
Last active March 21, 2022 20:07
Show Gist options
  • Save chev2/f40bd0b6f94fbf861875c7a214622257 to your computer and use it in GitHub Desktop.
Save chev2/f40bd0b6f94fbf861875c7a214622257 to your computer and use it in GitHub Desktop.
Facepunch Wiki Dark Mode - for wiki.facepunch.com. This is primarily aimed to work with the Garry's Mod wiki, but should also work with the other wikis (Rust / Facepunch.Steamworks)
:root {
--bg-color-primary: #2b2b2b;
--bg-color-secondary: #393939;
--bg-color-tertiary: #444;
--text-color-primary: #fff;
--text-color-secondary: #cecece;
--text-color-code-inline: #e85278;
}
/* Main body */
.body .content, html > body > .body > .content, #pagelinks a.active, .page.diff {
background: var(--bg-color-primary);
}
/* Footers */
#pagefooter, html > body > .body > .footer, .markdown code, .markdown > .function .function_line {
background-color: var(--bg-color-secondary);
}
/* Footer - active wiki */
.body > .footer > div > div ul li a.active {
background-color: var(--bg-color-tertiary);
}
/* Text */
.body-tabs ul li a.active {
color: var(--text-color-primary);
}
.body > .footer > div > div ul li a, html > body > .body > .content > .footer {
color: var(--text-color-secondary);
}
/* Markdown headers */
.markdown, .member_line, .markdown div.internal, .markdown > .function .function_arguments .default, .body .content, .body-tabs ul li a {
color: var(--text-color-secondary);
}
/* Lighter inline code color */
.markdown code {
color: var(--text-color-code-inline);
}
/* Markdown tables */
.markdown table th, .markdown table td {
border: none;
}
.markdown table th {
background-color: #535353;
}
/* Alternating row colors */
.markdown table tbody tr td {
background-color: #424242;
}
.markdown table tbody tr:nth-child(2n) td {
background-color: #4f4f4f;
}
/* Class methods */
.member_line a.subject {
color: #618eff !important;
}
.member_line {
font-size: 14px;
}
/* Wiki editor */
/* Top bar */
.contentbar {
background-color: #222;
border-bottom: none;
}
#edit_display .headline, #edit_display .headline2, #edit_display .headline3 {
background-color: var(--bg-color-secondary);
}
#edit_display .bold {
background-color: transparent;
color: var(--text-color-secondary);
}
#edit_display span.inlinecode {
background-color: var(--bg-color-secondary);
color: var(--text-color-code-inline);
}
#edit_display .link {
background-color: var(--bg-color-secondary);
color: #618eff;
}
/* Page history */
.content > .diff .textdiff .inserted {
color: #c2ccb6;
}
.content > .diff .textdiff .deleted {
color: #c4a3a1;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment