diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/common/font-settings-panel.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/common/font-settings-panel.component.ts index c99efa8931..562001e3c4 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/common/font-settings-panel.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/common/font-settings-panel.component.ts @@ -69,6 +69,10 @@ export class FontSettingsPanelComponent extends PageComponent implements OnInit @coerceBoolean() autoScale = false; + @Input() + @coerceBoolean() + disabledLineHeight = false; + @Input() popover: TbPopoverComponent; @@ -106,7 +110,7 @@ export class FontSettingsPanelComponent extends PageComponent implements OnInit family: [this.font?.family, []], weight: [this.font?.weight, []], style: [this.font?.style, []], - lineHeight: [{ value: this.font?.lineHeight, disabled: this.autoScale }, []] + lineHeight: [{ value: this.font?.lineHeight, disabled: this.autoScale || this.disabledLineHeight }, []] } ); this.updatePreviewStyle(this.font); diff --git a/ui-ngx/src/app/modules/home/components/widget/lib/settings/common/font-settings.component.ts b/ui-ngx/src/app/modules/home/components/widget/lib/settings/common/font-settings.component.ts index 2c3780f1fe..0fc3b20da1 100644 --- a/ui-ngx/src/app/modules/home/components/widget/lib/settings/common/font-settings.component.ts +++ b/ui-ngx/src/app/modules/home/components/widget/lib/settings/common/font-settings.component.ts @@ -54,6 +54,10 @@ export class FontSettingsComponent implements OnInit, ControlValueAccessor { @coerceBoolean() autoScale = false; + @Input() + @coerceBoolean() + disabledLineHeight = false; + private modelValue: Font; private propagateChange = null; @@ -92,7 +96,8 @@ export class FontSettingsComponent implements OnInit, ControlValueAccessor { font: this.modelValue, initialPreviewStyle: this.initialPreviewStyle, clearButton: this.clearButton, - autoScale: this.autoScale + autoScale: this.autoScale, + disabledLineHeight: this.disabledLineHeight }; if (isDefinedAndNotNull(this.previewText)) { const previewText = typeof this.previewText === 'string' ? this.previewText : this.previewText();