Skip to content

Simple Global Light by sisrfeng

Screenshot of Simple Global Light

Details

Authorsisrfeng

LicenseNo License

Categoryall

Created

Updated

Size18 kB

Statistics

Learn how we calculate statistics in the FAQ.

Failed to fetch stats.

Description

The style "Global Solarized Light" looks good, but too complex for me.
I've removed something and change some colors

Notes

Userstyle doesn't have notes.

Source code

Source code has over 10K characters, so we truncated it. You can inspect the full source code on install link.
/* ==UserStyle==
@name           Simple Global Light
@namespace      leo_180
@author         leo_180
@version        2022-07-18
@license        CC-BY-NC-SA-4.0
@preprocessor   uso

@description    simplified global solarized light, original repo:   https://uso.kkx.one/style/173443
==/UserStyle== */


/*
UserCSS is essentially a CSS stylesheet
    with some extra data added to the beginning.
    Besides standard CSS,
        these preprocessors are supported:
            LESS,
            Stylus-lang
            the USO-format.

    Furthermore you can utilize whatever you want
    by using live-reload and your own external editor
*/

/*
    教程: https://github.com/openstyles/stylus/wiki/Writing-styles#user-content-selecting-specific-elements-on-a-page
    #xxx 中xxx表示DOM的一个对象的ID

*/
/* Declares the color */
* {
    --base0   : #839496;
    --base1   : #93a1a1;
    /* --base2   : #eee8d5; */
    /* base2改叫block, 表示code block */
    --block   : #f5f5f5d0;
    --block_fg: #333333d0;
    /* --border  : #c0c0c7; */
    --border  : #e0e0e7;
    --Border  : #f0f0e2;
	
	
    /* --bg      : #f0f0e0; */
    /* --bg      :#f1ede3; */
	/*--bg       : #f9f4e4;*/
    
    --bg_float       : #f9f4e4;
    --bright_bg_float: #f6f8fa;
    /* windows termnial 背景是6%透明的 */
	--bg       : #f9f4e4d0;
    --bright_bg: #f6f8fad0;


    --base00  : #657b83;

    --txt     : #000000;
    --txt2    : #588e75;
    --base02  : #073642;
    --base03  : #002b36;

    --gray    : #303034;
    --red_black   : #551111;
    --bold    : #404044;
    --faded   : #5a5c58;
    --url     : #306e57;

    --red     : #dc322f;
    --magenta : #d33682;
    --orange  : #da921a;
    --yellow  : #998844;
    --green   : #859900;
    --blue    : #268bd2;
    --cyan    : #2aa198;
    --violet  : #6c71c4;

    /* For debugging what the original code is doing */
    --debug   : #FF000F;
}


/* 教程里是这么缩进的( 缩进不影响语法吧 ) */
@-moz-document url-prefix("ftp://"),
               url-prefix("file://"),
               url-prefix("about"),
               url-prefix("javascript"),
               regexp("https?://(?!(e1mim51z0p.feishu.cn/docx|www.youtube.com|www.kaggle.com|support.google.com)).*")
               /* regexp("https?://(?!(e1mim51z0p.feishu.cn/docx|www.youtube.com|www.kaggle.com|support.google.com|www.zhihu.com|www.zhuanlan.zhihu.com|zhuanlan.zhihu.com)).*") */
                /* 刨掉了知乎 */
{  
    html {
        background: var(--bg)  !important
    }

    /*----- default text, border & background colors -----*/
    * {
        /* font-weight: normal  ;   */
        font-weight: 500 ;		/* 好像不是 "无级变速" , 整百?*/
        /* color               : var(--txt) !important; */
        /* background-color    : var(--bg) !important;  */
        color               : var(--txt) ;
        background-color    : var(--bg)  ;
        border-color        : var(--border) !important;
        outline-color       : var(--border) !important;
        /* text-shadow         : none !important;  */
        box-shadow          : none !important;
        /* box-shadow:   X , Y offsets relative to the element,  blur and spread radius, and color.  */


        border-top-color    : var(--border) !important;
        border-bottom-color : var(--border) !important;
        border-left-color   : var(--border) !important;
        border-right-color  : var(--border) !important;
    }

    [class*="ml-1 js-codesearch-count Counter Counter--primary"]  {  
        background-color    : var(--bright_bg)
    } 


    /* 对付知乎的?  这里像是被一块东西盖住了 */
    [class*="QuestionHeader-tags"],
    [class*="QuestionHeader-title"]
    {
        /* background-color    : var(--debug) !important  */
        background-color    : var(--bg) !important
    }

    /* 头2个class专治github */
    [class*="d-flex js-sticky js-position-sticky top-0 border-top-0 border-bottom p-2 flex-items-center flex-justify-between color-bg-default rounded-top-2"],
    [class*="css-truncate css-truncate-target d-block width-fit"],
    [class*="color-fg-muted"],
    a,
    summary
    {
        background-color    : var(--bg) !important /* !important必须要加 */
    }

	div	{
		background-color    : var(--bg) !important  /* 会导致代码区域的背景颜色没了? , */
	}


    /* 影响stackoverflow的顶栏 */
    /*
    /* body { */
        /* background: #eee8d5 !important */
        /* background: #f4f4ea !important */
        /* background: #f4f4ea  */
    /* } */



    a,
    a * {
        color           : var(--url)  !important;
        text-decoration : none        !important
    }

    [class*="pytorch-content-wrap"] { background-color    : var(--bg) !important  }

    a:hover,
    a:hover *,
    a:visited:hover,
    a:visited:hover *,
    span[onclick]:hover,
    div[onclick]:hover,
    [role="link"]:hover,
    [role="link"]:hover *,
    [role="button"]:hover *,
    [role="menuitem"]:hover,
    [role="menuitem"]:hover *,
    .link:hover,
    .link:hover *         {  color: var(--yellow) !important  }


    a:visited,
    a:visited *   {  color: var(--faded) !important  }

    a.highlight,
    a.highlight *,
    a.active,
    a.active *,
    .selected,
    .selected *,
    [href="#"] {
                    color: var(--txt2) !important;
                    font-weight: bold !important
                }

    h1,
    h2,
    h1 *,
    h2 * {
        /* color: var(--red_black) !important;  */
        /* color: var(--orange) !important; */
        color: var(--cyan) !important;
    }

    h3,
    h4,
    h3 *,
    h4 * {
        color: rgb(1, 100, 200) !important ;
        /* text-transform: lowercase;  还是别加了 会导致有些术语变小写 */
    }
        /* color: var(--yellow) !important */

    h5,
    h6,
    h5 *,
    h6 * {
        color: var(--orange) !important;

    }

    /* Bold,  italic, underlined */
    strong,
    [id*="headline"],
    [class*="headline"],
    [id*="header"],
    [class*="header"],
    [class*="header"] td,
    b{  color: var(--bold) !important  }
    /* 知乎高亮受它控制 */

    /*  i, */
    u {  color: var(--red_black) !important  }
    /*
      a h1,
      a h2,
      a h3,
      a h4, a h5, a h6, h1 a, h2 a, h3 a,
      a strong,
      a[id*="headline"],
      a[class*="headline"],
      a[id*="header"],
      a[class*="header"] {
          text-decoration: underline !important
        }
    */

    /* [class="sourceCode"], */
    code,
    [class="sourceCode"],
    [class="sourceCode python"],
    [class*="error"],
    [class*="alert"],
    span[onclick],
    div[onclick]    {
        background: var(--block) !important;
        /*
        现在还是很丑。
        code block里, 只能匹配到有定义syntax的地方
        (readme里很多位置不会被匹配, 所以才显得不丑
        */

        color:      var(--block_fg) !important
    }

    /* div[class*="CodeMirror*"]   不行
        span统一一个样式?
        span.cm,
        span.pl-c
    */

    /* span, */    /* 加了这行 导致文字底下被高亮; 如果不加, code block的背景就有点丑 */
    div[class*="CodeMirror-lines"]
    {
        background: var(--block) !important;
    }

    [class*="State"]{
        background: var(--bg) !important;
        border:  var(--bg);
    }
    [class*="State State--merged"]{
        color: var(--gray) !important;
    }

    [class*="State State--open"]{
        color: var(--green) !important;
    }

    span.js-issue-title.markdown-title {
        background: var(--bg) !important;
    }



    ::-moz-selection,
    ::selection {
        background: var(--base02) !important;
        color: var(--base1) !important
    }

    :focus {  outline: none !important  }

    /*----- menu & co background-colors -----*/
    div[style="display: block;"],
    div[role="navigation"] {  background: var(--bg) !important  }

    table {
            background: var(--bg) !important;
            border-radius: 6px !important
          }
    table > tbody > tr:nth-child(even),
    table > tbody > tr > td:nth-child(even)   {  background-color: var(--block) !important  }


    iframe,
    embed,
    nav,
    label [onclick],
    nav ul,
    div[style*="position:"][style*="left:"][style*="visible"],
    div[style*="z-index:"][style*="left:"][style*="visible"],
    div[style*="-moz-user-select"],
    div[role="menu"],
    div[role="dialog"],
    span[class*="script"] div,
    [id*="menu"],
    [id*="Menu"],
    [class*="dropdown"],
    [class*="popup"],
    [class="title"],
    ul[style*="display:"],
    ul[style*="visibility:"] ul,
    [id*="nav"] ul,
    [class*="nav"] ul,
    ul[class*="menu"],
    a[onclick][style*="display"],
    a[id*="ghosteryfirefox"],
    #ghostery-purple-bubble,
    #translator-popup,
    .menu,
    .tooltip,
    .hovercard,
    .vbmenu_popup {
        background    : var(--bg) !important;
        border-radius : 1px;
        box-shadow    : 0px 0px 1px var(--base1) !important
                        /* Adds shadow around elements like ul,
                        iframes and videos and etc */
    }

    header,
    #header,
    footer,
    #footer {
        background: var(--bg)!important;
        box-shadow: 0 0 2px var(--base1) !important
    }

    
    /* bing 必应的框框  */
    #b_header,li{
        /* background-color    : var(--debug) !important  */
        background-color    : var(--bg) !important
    }
    




    [id*="overlay"],
    [id*="lightbox"],
    blockquote.strong,
    blockquote {
        background-color : var(--block) !important;
        border-radius    : 2px
    }

    pre,
    dl,
    .Message code {  background-color: var(--block) !important  }


    /*  default buttons, searchboxes   */
    input,
    select,
    button,
    [role="button"],
    a.button,
    a.submit,
    a.BigButton,
    a.TabLink,
    .install[onclick] {
        -moz-appearance    : none !important;
        -webkit-appearance : none !important;

        background         : var(--bg) !important;
        color              : var(--base00) !important;
                            /* color of text you write */
        transition         : border-color 0.3s !important;
        border             : 1px solid var(--border) !important;
                            /* Checkbox, github顶部搜索框和star框 等...

Reviews

No reviews yet.