Skip to content

Home Assistant Docs - Dark Mode by wfurphy

Mirrored from https://gist.githubusercontent.com/wfurphy/b380ab08d930c425f9add8c50073a4b6/raw/51519424c9ff76fa0429c952070eb4d687550624/home-assistant.io.user.css

Screenshot of Home Assistant Docs - Dark Mode

Details

Authorwfurphy

LicenseMIT

Categoryhome-assistant.io

Created

Updated

Code size3.6 kB

Code checksumf94c6de3

Statistics

Learn how we calculate statistics in the FAQ.

Failed to fetch stats.

Description

Home Assistant Documentation in Dark mode

Notes

Because the bright white background of Home Assistant's documentation is hard on the eyes in the wee hours of the home-automation morning.

Source code

/* ==UserStyle==
@name         Home Assistant Docs - Dark Mode
@namespace    github.com/openstyles/stylus
@author       Will Furphy
@description  Home Assistant Documentation in Dark mode
@version      0.2.1
@license      MIT
@preprocessor default
==/UserStyle== */

@-moz-document domain("home-assistant.io") {
    html {
        --hawf-primary: #6cbbf0;
        --hawf-primary-dark: #007fa8;
        --hawf-special: #e90;
        --hawf-secondary: #e06c75;
        --hawf-text: #cdcdcd;
        --hawf-bg: #353a44;
        --hawf-bg-light: #ededed;
        --hawf-box-bg: #232832;
        --hawf-box-alt-bg: #485268;
        --hawf-code-bg: #232832;
        --hawf-table-bg: #303443;
        --hawf-table-alt-bg: #494f66;
        --hawf-table-head-bg: #41bdf5;
        background-color: var(--hawf-bg);
    }
    
    body, p.img {
        background-color: var(--hawf-bg) !important;
        color: var(--hawf-text);
    }

    h1,h2,h3,h4, .title {
        color: #fff !important;
    }
    
    a {
        color: var(--hawf-primary);
    }

    a.active {
        color: var(--hawf-special) !important;
    }
    
    body>header {
        background-color: var(--hawf-bg-light) !important;
    }
    
    .site-header a {
        color: var(--hawf-primary);
    }

    .title {
        color: #fff;
    }
    
    .footer-nav h3 {
        color: var(--hawf-box-bg) !important;
    }
    
    .aside-module {
        background-color: var(--hawf-box-bg) !important;
        padding: 16px !important;
    }
    
    #toc-bar>.aside-module {
        background-color: var(--hawf-bg) !important;
    }
    
    .config-vars {
        background-color: var(--hawf-box-alt-bg) !important;
    }

    .config-vars-label-name {
        color: var(--hawf-secondary) !important;
    }

    .config-vars-description {
        color: var(--hawf-text) !important;
    }
    
    .config-vars-type {
        color: #488df0 !important;
    }

    .config-vars-required > span.true {
        color: var(--hawf-special) !important;
    }
    
    .alert {
        color: var(--hawf-bg);
    }
    
    .material-card {
        background-color: var(--hawf-box-alt-bg);
    }

    article.page > table {
        background-color: var(--hawf-table-bg);
        border-radius: 5px;
    }

    article.page > table > thead tr th {
        background-color: var(--hawf-table-head-bg) !important;
        color: #fff;
    }

    article.page > table > thead tr th:first-child {
        border-top-left-radius: 5px !important;
    }

    article.page > table > thead tr th:last-child {
        border-top-right-radius: 5px !important;
    }

    article.page > table tr:nth-child(even) {
        background-color: var(--hawf-table-alt-bg) !important;
    }
    
    /** Code */
    
        code {
        background-color: #000;
        color: var(--hawf-primary);
        border: none;
    }

    code.language-yaml {
        box-shadow: -1px 3px 3px -1px #1a1c22, -2px 5px 5px -2px #21242b !important;
        border-left: 10px solid #0a0a0d !important;
        color: #cccccc !important;
    }

    code.language-yaml > span.punctuation {
        color: #cccccc;
    }

    code.language-yaml > span.key {
        color: #e06c75;
    }

    code.language-yaml > span.string {
        color: #98c379;
    }

    code.language-yaml > span.number {
        color: #d29873;
    }


    div.code-toolbar > pre {
        background: none;
        border: none;
    }

    div.code-toolbar > pre > code {
        background-color: #21232b;
        color: #fff;
    }
    
    
    
}

Reviews

No reviews yet.