2020-02-20 21:37:10 +08:00
|
|
|
// Author: Sivan [sun.sivan@gmail.com]
|
|
|
|
// Description: define global font stacks.
|
2020-02-11 21:01:13 +08:00
|
|
|
@import "../variables";
|
2020-02-11 20:47:29 +08:00
|
|
|
|
|
|
|
@mixin hetiFontModifier {
|
2020-02-11 21:01:13 +08:00
|
|
|
// 定义默认采用无衬线字体
|
2020-02-11 20:47:29 +08:00
|
|
|
// 定义无衬线字体为黑体
|
2020-02-11 21:01:13 +08:00
|
|
|
&,
|
|
|
|
&--sans {
|
2020-02-11 20:47:29 +08:00
|
|
|
font-family: $font-family-hei;
|
|
|
|
}
|
|
|
|
|
|
|
|
// 定义衬线字体为宋体
|
2020-02-11 21:01:13 +08:00
|
|
|
&--serif {
|
2020-02-11 20:47:29 +08:00
|
|
|
font-family: $font-family-song;
|
|
|
|
}
|
|
|
|
|
|
|
|
// 定义传统字体
|
2021-08-12 18:46:53 +08:00
|
|
|
// 「传统字体」仅供设计参考。主旨为标题用楷体,正文用宋体,表头等客观指标描述场合用黑体。
|
|
|
|
// 由于渲染机制等原因,应尽量避免衬线、非衬线字体混排,会引起行高不一致的bug。
|
2020-02-11 21:01:13 +08:00
|
|
|
&--classic {
|
|
|
|
// 正文使用宋体
|
2020-02-11 20:47:29 +08:00
|
|
|
font-family: $font-family-song;
|
|
|
|
|
2020-02-18 14:56:35 +08:00
|
|
|
// 标题使用楷体 800 字重
|
2020-02-11 20:47:29 +08:00
|
|
|
h1,
|
|
|
|
h2,
|
|
|
|
h3,
|
|
|
|
h4,
|
|
|
|
h5,
|
|
|
|
h6 {
|
2020-02-18 14:56:35 +08:00
|
|
|
font-family: $font-family-kai-black;
|
2020-02-11 20:47:29 +08:00
|
|
|
font-weight: $font-weight-bolder;
|
|
|
|
}
|
|
|
|
|
2020-02-18 14:56:35 +08:00
|
|
|
// 引用使用楷体
|
2020-02-11 20:47:29 +08:00
|
|
|
blockquote,
|
|
|
|
cite,
|
|
|
|
q {
|
|
|
|
font-family: $font-family-kai;
|
|
|
|
}
|
|
|
|
|
2021-08-12 18:46:53 +08:00
|
|
|
// 说明文字、表头等反应客观指标、事物的位置使用黑体
|
2020-02-11 20:47:29 +08:00
|
|
|
figcaption,
|
|
|
|
caption,
|
|
|
|
th {
|
|
|
|
font-family: $font-family-hei;
|
|
|
|
}
|
|
|
|
}
|
2020-02-18 14:56:35 +08:00
|
|
|
|
|
|
|
&--hei {
|
|
|
|
font-family: $font-family-hei;
|
|
|
|
}
|
|
|
|
|
|
|
|
&--song {
|
|
|
|
font-family: $font-family-song;
|
|
|
|
}
|
|
|
|
|
|
|
|
&--kai {
|
|
|
|
font-family: $font-family-kai;
|
|
|
|
}
|
2020-02-11 20:47:29 +08:00
|
|
|
}
|