添加鸿蒙及思源字体,删除其他字体等

master
yujialong 4 months ago
parent 3e1c8159de
commit 71527981c9
  1. 20
      public/styles/css/editor.css
  2. BIN
      public/styles/font/HarmonyOS_SansSC_Light.ttf
  3. BIN
      public/styles/font/SourceHanSansCN-VF-2.otf
  4. 4
      src/components/editor.js
  5. 2
      src/mixins/page/index.js
  6. 4
      src/pages/article/add/editor.js
  7. 1
      src/pages/footer/index.vue
  8. 30
      src/styles/common.scss
  9. BIN
      src/styles/font/HarmonyOS_SansSC_Light.ttf
  10. BIN
      src/styles/font/PingFang-Regular.otf
  11. BIN
      src/styles/font/PingFangSC-Medium.otf
  12. BIN
      src/styles/font/PingFangTC-Semibold.ttf
  13. BIN
      src/styles/font/ProximaNova-Regular.otf
  14. BIN
      src/styles/font/SF-Pro-Display-Bold.otf
  15. BIN
      src/styles/font/SourceHanSansCN-VF-2.otf
  16. 2
      src/styles/layout/index.scss
  17. 2
      src/styles/lib/_style.scss

@ -1,18 +1,10 @@
@font-face { @font-face {
font-family: SFProDisplay; font-family: Harmony;
src: url('./styles/font/SF-Pro-Display-Regular.otf'); src: url('./styles/font/HarmonyOS_SansSC_Light.ttf');
} }
@font-face { @font-face {
font-family: ProximaNova; font-family: siyuan;
src: url('./styles/font/ProximaNova-Regular.otf'); src: url('./styles/font/SourceHanSansCN-VF-2.otf');
}
@font-face {
font-family: PingFang;
src: url('./styles/font/PingFang-Regular.otf');
}
@font-face {
font-family: PingFang SC;
src: url('./styles/font/PingFang-Regular.otf');
} }
.mce-content-body:not([dir='rtl']) blockquote { .mce-content-body:not([dir='rtl']) blockquote {
padding: 8px 15px; padding: 8px 15px;
@ -48,7 +40,6 @@
.tiny-wrap .block p { .tiny-wrap .block p {
margin: 0 0 10px; margin: 0 0 10px;
font-size: 19px; font-size: 19px;
font-family: SFProDisplay;
font-weight: 400; font-weight: 400;
color: #101010; color: #101010;
line-height: 32px; line-height: 32px;
@ -56,14 +47,12 @@
} }
.tiny-wrap .en-block p, .tiny-wrap .en-block p,
.tiny-wrap .en-block .img-des { .tiny-wrap .en-block .img-des {
font-family: ProximaNova;
letter-spacing: -0.0135em; letter-spacing: -0.0135em;
line-height: 1.5em; line-height: 1.5em;
} }
.tiny-wrap .block .tiny-title { .tiny-wrap .block .tiny-title {
margin: 10px 0; margin: 10px 0;
font-size: 24px; font-size: 24px;
font-family: SFProDisplay;
font-weight: 500; font-weight: 500;
color: #101010; color: #101010;
line-height: 32px; line-height: 32px;
@ -106,7 +95,6 @@
} }
.tiny-wrap .people h6 { .tiny-wrap .people h6 {
font-size: 24px; font-size: 24px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500; font-weight: 500;
color: #333333; color: #333333;
} }

@ -185,7 +185,7 @@ export default {
], ],
// content_style: Style, // content_style: Style,
fontsize_formats: '12px 14px 16px 18px 19px 22px 24px 36px 48px 56px 72px', fontsize_formats: '12px 14px 16px 18px 19px 22px 24px 36px 48px 56px 72px',
font_formats: '苹果苹方=PingFang SC,Microsoft YaHei,sans-serif;宋体=simsun,serif;微软雅黑=Microsoft YaHei,Helvetica Neue,PingFang SC,sans-serif;仿宋体=FangSong,serif;黑体=SimHei,sans-serif;Arial=arial,helvetica,sans-serif;Arial Black=arial black,avant garde;Book Antiqua=book antiqua,palatino;Comic Sans MS=comic sans ms,sans-serif;Courier New=courier new,courier;Georgia=georgia,palatino;Helvetica=helvetica;Impact=impact,chicago;Symbol=symbol;Tahoma=tahoma,arial,helvetica,sans-serif;Terminal=terminal,monaco;Times New Roman=times new roman,times;Verdana=verdana,geneva;Webdings=webdings;Wingdings=wingdings,zapf dingbats;知乎配置=BlinkMacSystemFont, Helvetica Neue, PingFang SC, Microsoft YaHei, Source Han Sans SC, Noto Sans CJK SC, WenQuanYi Micro Hei, sans-serif;小米配置=Helvetica Neue,Helvetica,Arial,Microsoft Yahei,Hiragino Sans GB,Heiti SC,WenQuanYi Micro Hei,sans-serif', font_formats: '鸿蒙=Harmony;思源=siyuan;宋体=simsun,serif;微软雅黑=Microsoft YaHei,Helvetica Neue,仿宋体=FangSong,serif;黑体=SimHei,sans-serif;Arial=arial,helvetica,sans-serif;Arial Black=arial black,avant garde;Book Antiqua=book antiqua,palatino;Comic Sans MS=comic sans ms,sans-serif;Courier New=courier new,courier;Georgia=georgia,palatino;Helvetica=helvetica;Impact=impact,chicago;Symbol=symbol;Tahoma=tahoma,arial,helvetica,sans-serif;Terminal=terminal,monaco;Times New Roman=times new roman,times;Verdana=verdana,geneva;Webdings=webdings;Wingdings=wingdings,zapf dingbats;知乎配置=BlinkMacSystemFont, Helvetica Neue, PingFang SC, Microsoft YaHei, Source Han Sans SC, Noto Sans CJK SC, WenQuanYi Micro Hei, sans-serif;小米配置=Helvetica Neue,Helvetica,Arial,Microsoft Yahei,Hiragino Sans GB,Heiti SC,WenQuanYi Micro Hei,sans-serif',
link_list: [ link_list: [
{ title: '预置链接1', value: 'http://www.tinymce.com' }, { title: '预置链接1', value: 'http://www.tinymce.com' },
{ title: '预置链接2', value: 'http://tinymce.ax-z.cn' } { title: '预置链接2', value: 'http://tinymce.ax-z.cn' }
@ -387,7 +387,7 @@ export default {
editor.on('init', function (ed) { editor.on('init', function (ed) {
// 设置默认字体(新增才需要设置) // 设置默认字体(新增才需要设置)
if (editor.iframeElement.contentWindow.document.body.innerText === '\n') { if (editor.iframeElement.contentWindow.document.body.innerText === '\n') {
ed.target.editorCommands.execCommand("fontName", false, "Microsoft Yahei") ed.target.editorCommands.execCommand("fontName", false, "Harmony")
ed.target.editorCommands.execCommand("fontSize", false, "19px") ed.target.editorCommands.execCommand("fontSize", false, "19px")
ed.target.editorCommands.execCommand("lineHeight", false, "1.5") ed.target.editorCommands.execCommand("lineHeight", false, "1.5")
} }

@ -41,7 +41,7 @@ export default {
}, },
mounted () { mounted () {
this.getInfo() this.getInfo()
this.getColumnInfo() this.columnId && this.getColumnInfo()
}, },
methods: { methods: {
// 获取详情 // 获取详情

@ -188,7 +188,7 @@ export default {
], ],
// content_style: Style, // content_style: Style,
fontsize_formats: '12px 14px 16px 19px 24px 36px 48px 56px 72px', fontsize_formats: '12px 14px 16px 19px 24px 36px 48px 56px 72px',
font_formats: '苹果苹方=PingFang SC,Microsoft YaHei,sans-serif;宋体=simsun,serif;微软雅黑=Microsoft YaHei,Helvetica Neue,PingFang SC,sans-serif;仿宋体=FangSong,serif;黑体=SimHei,sans-serif;Arial=arial,helvetica,sans-serif;Arial Black=arial black,avant garde;Book Antiqua=book antiqua,palatino;Comic Sans MS=comic sans ms,sans-serif;Courier New=courier new,courier;Georgia=georgia,palatino;Helvetica=helvetica;Impact=impact,chicago;Symbol=symbol;Tahoma=tahoma,arial,helvetica,sans-serif;Terminal=terminal,monaco;Times New Roman=times new roman,times;Verdana=verdana,geneva;Webdings=webdings;Wingdings=wingdings,zapf dingbats;知乎配置=BlinkMacSystemFont, Helvetica Neue, PingFang SC, Microsoft YaHei, Source Han Sans SC, Noto Sans CJK SC, WenQuanYi Micro Hei, sans-serif;小米配置=Helvetica Neue,Helvetica,Arial,Microsoft Yahei,Hiragino Sans GB,Heiti SC,WenQuanYi Micro Hei,sans-serif', font_formats: '鸿蒙=Harmony;思源=siyuan;宋体=simsun,serif;微软雅黑=Microsoft YaHei,Helvetica Neue,仿宋体=FangSong,serif;黑体=SimHei,sans-serif;Arial=arial,helvetica,sans-serif;Arial Black=arial black,avant garde;Book Antiqua=book antiqua,palatino;Comic Sans MS=comic sans ms,sans-serif;Courier New=courier new,courier;Georgia=georgia,palatino;Helvetica=helvetica;Impact=impact,chicago;Symbol=symbol;Tahoma=tahoma,arial,helvetica,sans-serif;Terminal=terminal,monaco;Times New Roman=times new roman,times;Verdana=verdana,geneva;Webdings=webdings;Wingdings=wingdings,zapf dingbats;知乎配置=BlinkMacSystemFont, Helvetica Neue, PingFang SC, Microsoft YaHei, Source Han Sans SC, Noto Sans CJK SC, WenQuanYi Micro Hei, sans-serif;小米配置=Helvetica Neue,Helvetica,Arial,Microsoft Yahei,Hiragino Sans GB,Heiti SC,WenQuanYi Micro Hei,sans-serif',
link_list: [ link_list: [
{ title: '预置链接1', value: 'http://www.tinymce.com' }, { title: '预置链接1', value: 'http://www.tinymce.com' },
{ title: '预置链接2', value: 'http://tinymce.ax-z.cn' } { title: '预置链接2', value: 'http://tinymce.ax-z.cn' }
@ -485,7 +485,7 @@ export default {
editor.on('init', function (ed) { editor.on('init', function (ed) {
// 设置默认字体(新增才需要设置) // 设置默认字体(新增才需要设置)
if (editor.iframeElement.contentWindow.document.body.innerText === '\n') { if (editor.iframeElement.contentWindow.document.body.innerText === '\n') {
ed.target.editorCommands.execCommand("fontName", false, "Microsoft Yahei") ed.target.editorCommands.execCommand("fontName", false, "Harmony")
ed.target.editorCommands.execCommand("fontSize", false, "19px") ed.target.editorCommands.execCommand("fontSize", false, "19px")
ed.target.editorCommands.execCommand("lineHeight", false, "1") ed.target.editorCommands.execCommand("lineHeight", false, "1")
} }

@ -264,7 +264,6 @@ export default {
} }
]) ])
this.originForm = _.cloneDeep(this.form) this.originForm = _.cloneDeep(this.form)
console.log(111, Modules.footer, this.modules)
this.getData() this.getData()
this.getColumn() this.getColumn()
}, },

@ -1,32 +1,12 @@
@import "./default/index.scss"; @import "./default/index.scss";
@font-face { @font-face {
font-family: PingFang; font-family: Harmony;
src: url('font/PingFang-Regular.otf'); src: url('font/HarmonyOS_SansSC_Light.ttf');
} }
@font-face { @font-face {
font-family: PingFangSC-Medium; font-family: siyuan;
src: url('font/PingFangSC-Medium.otf'); src: url('font/SourceHanSansCN-VF-2.otf');
}
@font-face {
font-family: PingFangSC-Semibold;
src: url('font/PingFangTC-Semibold.ttf');
}
@font-face {
font-family: SFProDisplay-Bold;
src: url('font/SF-Pro-Display-Bold.otf');
}
@font-face {
font-family: SFProDisplay;
src: url('font/SF-Pro-Display-Regular.otf');
}
@font-face {
font-family: toppan;
src: url('font/toppan.otf');
}
@font-face {
font-family: ProximaNova;
src: url('font/ProximaNova-Regular.otf');
} }
[v-cloak] { [v-cloak] {
display: none; display: none;
@ -208,7 +188,6 @@
.cell { .cell {
font-size: 12px; font-size: 12px;
color: #333; color: #333;
font-family: PingFangSC-Regular, PingFang SC;
} }
} }
th { th {
@ -218,7 +197,6 @@
color: #323232; color: #323232;
font-size: 12px; font-size: 12px;
font-weight: 500; font-weight: 500;
font-family: PingFangSC-Medium, PingFang SC;
} }
} }
} }

@ -11,7 +11,7 @@ body,
body { body {
min-width: 1280px; min-width: 1280px;
font-family: PingFang, PingFang SC, "Helvetica Neue", Helvetica, "microsoft yahei", arial, STHeiTi, sans-serif; font-family: Harmony, STHeiTi, sans-serif;
font-size: 14px; font-size: 14px;
background: #F0F2F5; background: #F0F2F5;
} }

@ -1,3 +1,3 @@
html { html {
font-family: 'PingFang SC', "Helvetica Neue", Helvetica, "microsoft yahei", arial, STHeiTi, sans-serif; font-family: Harmony, STHeiTi, sans-serif;
} }

Loading…
Cancel
Save