From fa087df758a5f2270b2bb5fbe943efc72071587f Mon Sep 17 00:00:00 2001 From: mohamed yahia Date: Mon, 3 Feb 2025 14:13:13 +0200 Subject: [PATCH] Fix important value not clearing after changing the selected component (#6381) Co-authored-by: Artur Arseniev --- packages/core/src/style_manager/model/Property.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/core/src/style_manager/model/Property.ts b/packages/core/src/style_manager/model/Property.ts index 4eed38023..a248b01b6 100644 --- a/packages/core/src/style_manager/model/Property.ts +++ b/packages/core/src/style_manager/model/Property.ts @@ -354,7 +354,7 @@ export default class Property = PropertyProps> ext } __getClearProps() { - return { value: '' } as unknown as Partial; + return { value: '', important: false } as unknown as Partial; } /** @@ -492,7 +492,7 @@ export default class Property = PropertyProps> ext const fn = this.get('functionName'); const def = this.getDefaultValue(); let value = isUndefined(val) ? (this.get('value') as string) : val; - const hasValue = !isUndefined(value) && value !== ''; + const hasValue = this.hasValue(); if (value && def && value === def) { return def;