Skip to content

Docs-Swift-Org by gy37

Screenshot of Docs-Swift-Org

Details

Authorgy37

LicenseNo License

Categoryswift.doc.org

Created

Updated

Size3.8 kB

Statistics

Learn how we calculate statistics in the FAQ.

Failed to fetch stats.

Description

custom docs.swift.org styles

Notes

@media(prefers-color-scheme: dark)

Source code

/* ==UserStyle==
@name           Docs-Swift-Org & Swift-Org
@namespace      github.com/gy37
@version        1.0.0
@description    docs.swift.org & swift.org styles
@author         yuyuyu37
==/UserStyle== */
@-moz-document domain("docs.swift.org"), domain("www.swift.org") {
    @media screen and (min-width: 1920px) {
        #jump_to_toggle {
            display: none;
        }
        #jump_to menu {
            display: block;
            margin: 0 0 0;
            padding: 0 15px;
            background: rgb(250, 250, 250);
            border: 1px solid rgb(230, 230, 230);
            width: 320px;
            font-size: 12px;
            line-height: 15px;
            color: #666;
        }
        #jump_to menu ul ul li {
            font-size: 16px;
        }
        #jump_to menu ul ul ul li {
            font-size: 12px;
        }
        #jump_to menu ul ul ul {
            display: block;
        }
        article h3 {
            padding: 0.4em 0;
            position: sticky;
            top: 0;
            background-color: #0d1117;
        }
    }
    @media screen and (max-width: 1920px) {
        #jump_to.open menu ul ul li {
            font-size: 14px;
        }
        #jump_to.open menu ul ul ul li {
            font-size: 12px;
        }
         #jump_to.open menu ul ul ul {
            display: block;
        }
    }
    #bashful .inner {
        max-width: unset;
    }
    nav[role="navigation"] {
        width: 320px;
    }
    main {
        max-width: 1200px;
        margin-left: 320px;
    }
    .highlight-swift .code-sample .highlight {
        width: unset;
    }
    footer[role="contentinfo"] {
        margin-left: 320px;
    }
    
    @media(prefers-color-scheme: dark) {
        @media screen and (min-width: 1920px) {
            #jump_to menu {
                background: #0d1117;
                border: 1px solid rgb(59, 64, 66);
            }
        }
        #jump_to #jump_to_toggle,
        #jump_to.open #jump_to_toggle {
            background-color: #0d1117;
            color: #c9d1d9;
            border: 1px solid rgb(59, 64, 66);
        }
        #jump_to.open menu {
            background: #0d1117;
            border: 1px solid rgb(59, 64, 66);
        }
        #jump_to menu ul ul a {
            color: #c9d1d9;
        }
        
        body {
            background-color: #0d1117;
        }
        nav[role="navigation"] {
            background-color: #0d1117;
            border-right: 1px solid rgb(59, 64, 66);
        }
        nav[role="navigation"] h2 {
            color: #c9d1d9;
        }
        nav[role="navigation"] ul li ul a:link, 
        nav[role="navigation"] ul li a:visited {
            color: #c9d1d9;
        }
        main {
            background-color: #0d1117;
            color: #c9d1d9;
        }
        .highlight-swift {
            background-color: #0d1117;
        }
        .highlight-swift .code-sample {
            background-color: #0d1117;
        }
        .highlight-swift .code-sample .highlight {
            background-color: #0d1117;
            border: 1px solid rgb(59, 64, 66);
            border-left: 6px solid rgb(21 92 181);
        }
        .highlight .code-lines .k {
            color: #FC5FA3;
        }
        .highlight .code-lines .nv {
            color: #41A1C0;
        }
        .highlight .code-lines .s {
            color: #FC6A5D;
        }
        .highlight .code-lines .c {
            color: #6C7986;
        }
        .highlight .code-lines .m {
            color: #D0BF69;  
        }
        .highlight .code-lines .nc {
            color: #D0A8FF
        }

        .admonition {
            background-color: #0d1117;
            border: 1px solid rgb(59, 64, 66);
            border-left: solid 6px #9b5f5f;
        }
    }
}

Reviews

No reviews yet.