功能变化: 将网络字体改为本地字体
This commit is contained in:
4
web/src/theme/fa/css/font-awesome.min.css
vendored
Normal file
4
web/src/theme/fa/css/font-awesome.min.css
vendored
Normal file
File diff suppressed because one or more lines are too long
BIN
web/src/theme/fa/fonts/FontAwesome.otf
Normal file
BIN
web/src/theme/fa/fonts/FontAwesome.otf
Normal file
Binary file not shown.
BIN
web/src/theme/fa/fonts/fontawesome-webfont.eot
Normal file
BIN
web/src/theme/fa/fonts/fontawesome-webfont.eot
Normal file
Binary file not shown.
2671
web/src/theme/fa/fonts/fontawesome-webfont.svg
Normal file
2671
web/src/theme/fa/fonts/fontawesome-webfont.svg
Normal file
File diff suppressed because it is too large
Load Diff
|
After Width: | Height: | Size: 434 KiB |
BIN
web/src/theme/fa/fonts/fontawesome-webfont.ttf
Normal file
BIN
web/src/theme/fa/fonts/fontawesome-webfont.ttf
Normal file
Binary file not shown.
BIN
web/src/theme/fa/fonts/fontawesome-webfont.woff
Normal file
BIN
web/src/theme/fa/fonts/fontawesome-webfont.woff
Normal file
Binary file not shown.
BIN
web/src/theme/fa/fonts/fontawesome-webfont.woff2
Normal file
BIN
web/src/theme/fa/fonts/fontawesome-webfont.woff2
Normal file
Binary file not shown.
@@ -5,3 +5,4 @@
|
||||
@import './media/media.scss';
|
||||
@import './waves.scss';
|
||||
@import './dark.scss';
|
||||
@import './fa/css/font-awesome.min.css';
|
||||
|
||||
@@ -50,6 +50,17 @@ const getAwesomeIconfont = () => {
|
||||
const styles: any = document.styleSheets;
|
||||
let sheetsList = [];
|
||||
let sheetsIconList = [];
|
||||
// 判断fontFamily是否是本地加载
|
||||
for (let i = 0; i < styles.length; i++) {
|
||||
const rules = styles[i].cssRules || styles[i].rules;
|
||||
if (rules) {
|
||||
for (let j = 0; j < rules.length; j++) {
|
||||
if (rules[j].style && rules[j].style.fontFamily === 'FontAwesome') {
|
||||
sheetsList.push(styles[i])
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for (let i = 0; i < styles.length; i++) {
|
||||
if (styles[i].href && styles[i].href.indexOf('netdna.bootstrapcdn.com') > -1) {
|
||||
sheetsList.push(styles[i]);
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
const cssCdnUrlList: Array<string> = [
|
||||
'//at.alicdn.com/t/font_2298093_y6u00apwst.css',
|
||||
'//at.alicdn.com/t/c/font_3882322_9ah7y8m9175.css', //dvadmin3项目用icon
|
||||
'//netdna.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css'
|
||||
//'//netdna.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css'
|
||||
];
|
||||
// 第三方 js url
|
||||
const jsCdnUrlList: Array<string> = [];
|
||||
|
||||
Reference in New Issue
Block a user