Created
April 28, 2021 04:25
-
-
Save TTTPOB/1b8295799c537c436e0513536e18fab7 to your computer and use it in GitHub Desktop.
全局字体替换
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@namespace url(http://www.w3.org/1999/xhtml); | |
/*! | |
* custom-yahei-family.css | |
* https://n2o.io/go?page=custom.css | |
* | |
* Copyright 2018 Francis Zhao <francis@n2o.io> | |
* https://n2o.io/license | |
* | |
* Date: 2018-03-11T15:00+06:00 | |
*/ | |
::selection{ | |
background: rgba(188, 0, 45) !important; | |
color: rgb(255,255,255) | |
} | |
/* | |
html, | |
[lang=zh-CN] { | |
font-family: "Sarasa UI SC", sans-serif; | |
} | |
[lang=zh-TW] { | |
font-family: "Sarasa UI TC", sans-serif; | |
} | |
[lang=zh-HK] { | |
font-family: "Sarasa UI TC", sans-serif; | |
} | |
[lang=ja-JP] { | |
font-family: "Sarasa UI J", sans-serif; | |
} | |
[lang=ko-KR] { | |
font-family: "Sarasa UI K", sans-serif; | |
} | |
body, | |
input, | |
textarea, | |
keygen, | |
select, | |
button { | |
font-family: inherit; | |
-webkit-font-smoothing: antialiased; | |
-moz-osx-font-smoothing: grayscale; | |
text-rendering: optimizeLegibility; | |
} | |
*/ | |
/* 字体替换:西文字母 */ | |
@font-face { | |
font-family: "Arial"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "12px/1.5 arial"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "Tahoma"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "Verdana"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "Helvetica Neue"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "Helvetica"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "Segoe UI"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "Courier"; | |
src: local(Sarasa Mono SC); | |
} | |
@font-face { | |
font-family: "Courier New"; | |
src: local(Sarasa Mono SC); | |
} | |
@font-face { | |
font-family: "Consolas"; | |
src: local(Sarasa Mono SC); | |
} | |
/* 字体替换:中文 (简体) */ | |
@font-face { | |
font-family: "SimSun"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "SimSun-ExtB"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "宋体"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "\5b8b\4f53"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "NSimSun"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "新宋体"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "SimHei"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "黑体"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "Microsoft YaHei"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "Microsoft YaHei UI"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "微软雅黑UI"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "微软雅黑"; | |
src: local(Sarasa UI SC); | |
} | |
@font-face { | |
font-family: "STHeiti SC"; | |
src: local("Sarasa UI SC"); | |
} | |
/* 字体替换:中文 (繁體) */ | |
@font-face { | |
font-family: "MingLiU"; | |
src: local("Sarasa UI TC"); | |
} | |
@font-face { | |
font-family: "MingLiU-ExtB"; | |
src: local("Sarasa UI TC"); | |
} | |
@font-face { | |
font-family: "MingLiU_HKSCS"; | |
src: local("Sarasa UI TC"); | |
} | |
@font-face { | |
font-family: "MingLiU_HKSCS-ExtB"; | |
src: local("Sarasa UI TC"); | |
} | |
@font-face { | |
font-family: "PMingLiU"; | |
src: local("Sarasa UI TC"); | |
} | |
@font-face { | |
font-family: "PMingLiU-ExtB"; | |
src: local("Sarasa UI TC"); | |
} | |
@font-face { | |
font-family: "STHeiti TC"; | |
src: local("PingFang TC"); | |
} | |
/* i really want this to be global */ | |
/* 字体替换:特定网站 */ | |
@-moz-document regexp(".*") { | |
code, kbd, pre, samp { | |
font-family: Consolas | |
} | |
} | |
@-moz-document domain("readthedocs.io") { | |
.rst-content div[class^="highlight"] pre { | |
font-family: Consolas; | |
} | |
} | |
@-moz-document domain("github.com") { | |
.blob-code-inner, code, pre, tt, .CodeMirror pre, .file-info { | |
font-family: Consolas; | |
} | |
} | |
@-moz-document domain("baidu.com"), domain("sogou.com"), domain("so.com"), domain("live.bilibili.com"), domain("bbs.pku.edu.cn"), domain("tmall.com"), domain("bilibili.com") { | |
* { | |
font-family: Sarasa UI SC, sans-serif !important; | |
} | |
} | |
/* 广告隐藏:通用 */ | |
.adsbygoogle { | |
display: none !important; | |
} | |
/* 广告隐藏:特定网站 */ | |
@-moz-document url("https://www.baidu.com/"), url("https://www.baidu.com/#"), url-prefix("https://www.baidu.com/?tn=") { | |
.s-treasure, | |
.mnav[href^="http"]:not([href*="baidu.com"]), | |
.qrcode-layer { | |
display: none !important; | |
} | |
} | |
@-moz-document domain("sogou.com") { | |
.nav-new, | |
.bizr_rb, | |
[id^="rightgameout"] { | |
display: none !important; | |
} | |
} | |
@-moz-document domain("so.com") { | |
#mohe-know_side_nlp-imagelist, | |
#mohe-hot_hqr { | |
display: none !important; | |
} | |
} | |
@-moz-document domain("userstyles.org") { | |
.ad { | |
display: none !important; | |
} | |
} | |
@-moz-document domain("bilibili.com") { | |
.bb-comment, .comment-bilibili-fold { | |
font-family: Sarasa UI SC,Sarasa UI SC,Helvetica,sans-serif; | |
} | |
.bilibili-player { | |
font-family: Sarasa UI SC; | |
} | |
} | |
@-moz-document domain("baike.baidu.com") { | |
* { | |
font-family: Sarasa UI SC,Sarasa UI SC,Helvetica,sans-serif; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment