Merge pull request #2047 from ONLYOFFICE/fix/font-name
Change font family name
This commit is contained in:
commit
0f30f41b39
|
@ -194,7 +194,7 @@
|
|||
} / false / true // if false/true - use as init value in de/pe. use instead of customization.spellcheck parameter
|
||||
},
|
||||
font: {
|
||||
family: "Arial",
|
||||
name: "Arial",
|
||||
},
|
||||
chat: true,
|
||||
comments: true,
|
||||
|
|
|
@ -381,8 +381,8 @@ define([
|
|||
Common.Utils.InternalSettings.set("save-guest-username", !!value);
|
||||
}
|
||||
if (this.appOptions.customization.font) {
|
||||
if (this.appOptions.customization.font.family && typeof this.appOptions.customization.font.family === 'string') {
|
||||
var arr = this.appOptions.customization.font.family.split(',');
|
||||
if (this.appOptions.customization.font.name && typeof this.appOptions.customization.font.name === 'string') {
|
||||
var arr = this.appOptions.customization.font.name.split(',');
|
||||
for (var i=0; i<arr.length; i++) {
|
||||
var item = arr[i].trim();
|
||||
if (item && (/[\s0-9\.]/).test(item)) {
|
||||
|
@ -1432,7 +1432,7 @@ define([
|
|||
}
|
||||
} else if (!this.appOptions.isDesktopApp && !this.appOptions.canBrandingExt &&
|
||||
this.editorConfig && this.editorConfig.customization && (this.editorConfig.customization.loaderName || this.editorConfig.customization.loaderLogo ||
|
||||
this.editorConfig.customization.font && this.editorConfig.customization.font.family)) {
|
||||
this.editorConfig.customization.font && this.editorConfig.customization.font.name)) {
|
||||
Common.UI.warning({
|
||||
title: this.textPaidFeature,
|
||||
msg : this.textCustomLoader,
|
||||
|
|
|
@ -340,8 +340,8 @@ define([
|
|||
Common.Utils.InternalSettings.set("save-guest-username", !!value);
|
||||
}
|
||||
if (this.appOptions.customization.font) {
|
||||
if (this.appOptions.customization.font.family && typeof this.appOptions.customization.font.family === 'string') {
|
||||
var arr = this.appOptions.customization.font.family.split(',');
|
||||
if (this.appOptions.customization.font.name && typeof this.appOptions.customization.font.name === 'string') {
|
||||
var arr = this.appOptions.customization.font.name.split(',');
|
||||
for (var i=0; i<arr.length; i++) {
|
||||
var item = arr[i].trim();
|
||||
if (item && (/[\s0-9\.]/).test(item)) {
|
||||
|
@ -1054,7 +1054,7 @@ define([
|
|||
}
|
||||
} else if (!this.appOptions.isDesktopApp && !this.appOptions.canBrandingExt &&
|
||||
this.editorConfig && this.editorConfig.customization && (this.editorConfig.customization.loaderName || this.editorConfig.customization.loaderLogo ||
|
||||
this.editorConfig.customization.font && this.editorConfig.customization.font.family)) {
|
||||
this.editorConfig.customization.font && this.editorConfig.customization.font.name)) {
|
||||
Common.UI.warning({
|
||||
title: this.textPaidFeature,
|
||||
msg : this.textCustomLoader,
|
||||
|
|
|
@ -378,8 +378,8 @@ define([
|
|||
Common.Utils.InternalSettings.set("save-guest-username", !!value);
|
||||
}
|
||||
if (this.appOptions.customization.font) {
|
||||
if (this.appOptions.customization.font.family && typeof this.appOptions.customization.font.family === 'string') {
|
||||
var arr = this.appOptions.customization.font.family.split(',');
|
||||
if (this.appOptions.customization.font.name && typeof this.appOptions.customization.font.name === 'string') {
|
||||
var arr = this.appOptions.customization.font.name.split(',');
|
||||
for (var i=0; i<arr.length; i++) {
|
||||
var item = arr[i].trim();
|
||||
if (item && (/[\s0-9\.]/).test(item)) {
|
||||
|
@ -1139,7 +1139,7 @@ define([
|
|||
}
|
||||
} else if (!this.appOptions.isDesktopApp && !this.appOptions.canBrandingExt && !(this.appOptions.isEditDiagram || this.appOptions.isEditMailMerge || this.appOptions.isEditOle) &&
|
||||
this.editorConfig && this.editorConfig.customization && (this.editorConfig.customization.loaderName || this.editorConfig.customization.loaderLogo ||
|
||||
this.editorConfig.customization.font && this.editorConfig.customization.font.family)) {
|
||||
this.editorConfig.customization.font && this.editorConfig.customization.font.name)) {
|
||||
Common.UI.warning({
|
||||
title: this.textPaidFeature,
|
||||
msg : this.textCustomLoader,
|
||||
|
|
Loading…
Reference in a new issue