Skip to content

Commit 0e77b91

Browse files
fixed codemirror zig-zag issue
1 parent 8ba31d3 commit 0e77b91

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/app/components/core/configuration-manager/show-configuration/show-configuration.component.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@
1111
{{configuration.label}}
1212
</label>
1313
</div>
14-
<div class="field-body">
14+
<div class="field-body">
1515
<div [ngSwitch]="configuration.controlType" class="field" #cdmrField
16-
[style.max-width.px]="['SCRIPT'].includes(configuration.controlType) && cdmrField.offsetWidth !== 0 ? cdmrField.offsetWidth : ''"
17-
[ngClass]="{'codemirror-field': ['SCRIPT'].includes(configuration.controlType)}">
16+
[style.max-width.px]="['CODE', 'SCRIPT', 'JSON'].includes(configuration.controlType) && cdmrField.offsetWidth !== 0 ? cdmrField.offsetWidth : ''"
17+
[ngClass]="{'codemirror-field': ['CODE', 'SCRIPT', 'JSON'].includes(configuration.controlType)}">
1818

1919
<input *ngSwitchCase="'TEXT'" [formControlName]="configuration.key" [id]="configuration.key"
2020
[type]="configuration.type" class="input is-fullwidth is-small">
@@ -130,8 +130,8 @@
130130
</div>
131131
<div class="field-body">
132132
<div [ngSwitch]="configuration.controlType" class="field" #cdmrField
133-
[style.max-width.px]="['SCRIPT'].includes(configuration.controlType) && cdmrField.offsetWidth !== 0 ? cdmrField.offsetWidth : ''"
134-
[ngClass]="{'codemirror-field': ['SCRIPT'].includes(configuration.controlType)}">
133+
[style.max-width.px]="['CODE', 'SCRIPT', 'JSON'].includes(configuration.controlType) && cdmrField.offsetWidth !== 0 ? cdmrField.offsetWidth : ''"
134+
[ngClass]="{'codemirror-field': ['CODE', 'SCRIPT', 'JSON'].includes(configuration.controlType)}">
135135

136136
<label *ngSwitchCase="'CHECKBOX'" class="checkbox" [id]="configuration.key">
137137
<input [type]="configuration.type" [checked]="configuration.value.toLowerCase() == 'true'"

0 commit comments

Comments
 (0)