Skip to content

日本語サイトの表示をマシにするスタイル (Style ja-JP) by MaruniUmebachi

Details

AuthorMaruniUmebachi

LicenseCC 0

CategoryStyle

Created

Updated

Size6.0 kB

Statistics

Learn how we calculate statistics in the FAQ.

Failed to fetch stats.

Description

すべてのページに適用するスタイル。私の別のスタイルとセットじゃないと、何も動作しません。

Notes

Userstyle doesn't have notes.

Source code

/* ==UserStyle==
@name         0. Style
@version      20241205.09.54
@namespace    https://userstyles.world/user/MaruniUmebachi
@description  すべてのページに適用するスタイル。
@homepage     https://userstyles.world/user/MaruniUmebachi
@author       MaruniUmebachi
@license      CC 0
==/UserStyle== */

@-moz-document url("http"), url-prefix("http"), regexp(".*://.*"), regexp(".*") {
/* all */
:root {
    --Stylus-CSS: "* Style";
    font-language-override: var(--font-language-override-Stylus);
    /* スモールキャップ代替字形 */
    .small-caps {
        --Stylus-CSS: "* Style", "MDN";
        font-feature-settings: "smcp" on;
    }

    /* 大文字と小文字の両方をスモールキャップに変換 (記号も) */
    .all-small-caps {
        --Stylus-CSS: "* Style", "MDN";
        font-feature-settings: "c2sc", "smcp";
    }

    /* スラッシュのついたゼロを使用して "O" と区別する */
    .nice-zero {
        --Stylus-CSS: "* Style", "MDN";
        font-feature-settings: "zero";
    }

    /* 歴史的な書体を有効に */
    .historical {
        --Stylus-CSS: "* Style", "MDN";
        font-feature-settings: "hist";
    }

    /* よくある合字を無効にする (既定ではオン) */
    .no-ligatures {
        --Stylus-CSS: "* Style", "MDN";
        font-feature-settings: "liga" 0;
    }

    /* 表内の数字を有効にする (等幅) */
    td.tabular {
        --Stylus-CSS: "* Style", "MDN";
        font-feature-settings: "tnum";
    }

    /* 自動的に分数化する */
    .fractions {
        --Stylus-CSS: "* Style", "MDN";
        font-feature-settings: "frac";
    }

    /* 利用可能な2番目のスウォッシュ文字を使用 */
    .swash {
        --Stylus-CSS: "* Style", "MDN";
        font-feature-settings: "swsh" 2;
    }

    /* スタイリッシュセット 7 を有効にする */
    .fancy-style {
        --Stylus-CSS: "* Style", "MDN";
        font-family: Gabriola;
        font-feature-settings: "ss07";
    }
}
}

@-moz-document url-prefix("http"), regexp(".*") {
/* Reader */
:root {
    --Stylus-CSS: "* Style";
    --Stylus-section-CSS: "reader-domain";
    body:has(a[id="reader-domain"]) {
        --Stylus-CSS: "* Style";
        --Stylus-section-CSS: "reader-domain";
        div[id^="readability-page-"] > div > p {
            --Stylus-CSS: "* Style";
            --Stylus-section-CSS: "reader-domain";
            font: var(--font-Stylus-article-p);
            font-feature-settings: "nlck" "pkan";
            font-kerning: var(--font-kerning-Stylus-article-p);
            text-align: var(--text-align-Stylus-article-p);
            text-align-last: var(--text-align-last-Stylus-article-p);
            word-spacing: var(--word-spacing-Stylus-article-p);
            hyphens: var(--hyphens-Stylus-article-p);
            > br {
                --Stylus-CSS: "* Style";
                --Stylus-section-CSS: "reader-domain";
                display: var(--display-Stylus-article-p-br);
                content: var(--content-Stylus-article-p-br);
                margin: var(--margin-Stylus-article-p-br);
            }

            ~ p:has(:not(br)) {
                --Stylus-CSS: "* Style";
                --Stylus-section-CSS: "reader-domain";
                text-indent: var(--text-indent-Stylus-article-p);
            }
        }

        #article-body > p {
            --Stylus-CSS: "* Style";
            --Stylus-section-CSS: "reader-domain";
            font: var(--font-Stylus-article-p);
            font-feature-settings: var(--font-feature-settings-Stylus-article-p);
            --font-feature-settings-Stylus-article-p: normal;
            --font-feature-settings-Stylus-article-p: "kalt";
            --font-feature-settings-Stylus-article-p: "nlck", "kalt";
            font-kerning: var(--font-kerning-Stylus-article-p);
            text-align: var(--text-align-Stylus-article-p);
            text-align-last: var(--text-align-last-Stylus-article-p);
            word-spacing: var(--word-spacing-Stylus-article-p);
            hyphens: var(--hyphens-Stylus-article-p);
        }
    }
}
}

@-moz-document url("http"), url-prefix("http"), regexp(".*://.*"), regexp(".*") {
/* lang */
}

@-moz-document url("http"), url-prefix("http"), regexp(".*://.*"), regexp(".*") {
/* code */
.ͼ1 :is(.cm-scroller) *,
code {
    --Stylus-CSS: "* Style";
    font-family: var(--font-family-settings-Stylus-code), monospace;
    font-kerning: var(--font-kerning-Stylus-code);
    font-feature-settings: var(--font-feature-settings-Stylus-code);
    font-variant: var(--font-variant-Stylus-code);
    font-variant-east-asian: var(--font-variant-east-asian-Stylus-code);
    font-variant-numeric: var(--font-variant-numeric-Stylus-code);
    letter-spacing: var(--letter-spacing-Stylus-code);
    word-spacing: var(--word-spacing-Stylus-code);
}

pre {
    --Stylus-CSS: "* Style";
    font-family: var(--font-family-settings-Stylus-pre), monospace;
    font-kerning: var(--font-kerning-Stylus-pre);
    font-feature-settings: var(--font-feature-settings-Stylus-pre);
    font-variant: var(--font-variant-Stylus-pre);
    font-variant-east-asian: var(--font-variant-east-asian-Stylus-pre);
    font-variant-numeric: var(--font-variant-numeric-Stylus-pre);
    letter-spacing: var(--letter-spacing-Stylus-pre);
    word-spacing: var(--word-spacing-Stylus-pre);
}

.CodeMirror {
    --Stylus-CSS: "* Style";
    font-family: var(--font-family-settings-Stylus-CodeMirror), monospace;
    font-kerning: var(--font-kerning-Stylus-CodeMirror);
    font-feature-settings: var(--font-feature-settings-Stylus-CodeMirror);
    font-variant: var(--font-variant-Stylus-CodeMirror);
    font-variant-east-asian: var(--font-variant-east-asian-Stylus-CodeMirror);
    font-variant-numeric: var(--font-variant-numeric-Stylus-CodeMirror);
    letter-spacing: var(--letter-spacing-Stylus-CodeMirror);
    word-spacing: var(--word-spacing-Stylus-CodeMirror);
}
}

@-moz-document regexp("^\\w+-extension://.+") {

}

Reviews

No reviews yet.