From fdc59fcb84bf78a5e1c8f277c39ea87de350a712 Mon Sep 17 00:00:00 2001 From: steinsebastian <54309425+steinsebastian@users.noreply.github.com> Date: Wed, 10 Jul 2024 13:19:48 +0200 Subject: [PATCH] fix: wrong usage of attribute required (#19005) --- .../configurator-attribute-numeric-input-field.component.html | 2 +- .../configurator-attribute-radio-button.component.html | 2 +- ...nfigurator-attribute-single-selection-image.component.html | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/feature-libs/product-configurator/rulebased/components/attribute/types/numeric-input-field/configurator-attribute-numeric-input-field.component.html b/feature-libs/product-configurator/rulebased/components/attribute/types/numeric-input-field/configurator-attribute-numeric-input-field.component.html index c17dc5a1465..cb975ba54ac 100644 --- a/feature-libs/product-configurator/rulebased/components/attribute/types/numeric-input-field/configurator-attribute-numeric-input-field.component.html +++ b/feature-libs/product-configurator/rulebased/components/attribute/types/numeric-input-field/configurator-attribute-numeric-input-field.component.html @@ -17,7 +17,7 @@ : createAttributeUiKey('label', attribute.name) " attr.role="{{ attribute.dataType }}" - attr.required="{{ attribute.required }}" + [attr.required]="attribute.required === true ? 'required' : null" (change)="onChange()" maxlength="{{ attribute.maxlength }}" [attr.aria-label]="getAriaLabelComplete()" diff --git a/feature-libs/product-configurator/rulebased/components/attribute/types/radio-button/configurator-attribute-radio-button.component.html b/feature-libs/product-configurator/rulebased/components/attribute/types/radio-button/configurator-attribute-radio-button.component.html index afa938d32e3..4e9afef0657 100644 --- a/feature-libs/product-configurator/rulebased/components/attribute/types/radio-button/configurator-attribute-radio-button.component.html +++ b/feature-libs/product-configurator/rulebased/components/attribute/types/radio-button/configurator-attribute-radio-button.component.html @@ -21,7 +21,7 @@ type="radio" formcontrolname="attributeRadioButtonForm" [formControl]="attributeRadioButtonForm" - [attr.required]="attribute.required" + [attr.required]="attribute.required === true ? 'required' : null" [value]="value.valueCode" name="{{ createAttributeIdForConfigurator(attribute) }}" attr.name="{{ createAttributeIdForConfigurator(attribute) }}" diff --git a/feature-libs/product-configurator/rulebased/components/attribute/types/single-selection-image/configurator-attribute-single-selection-image.component.html b/feature-libs/product-configurator/rulebased/components/attribute/types/single-selection-image/configurator-attribute-single-selection-image.component.html index 9040add9edd..9a7606b2491 100644 --- a/feature-libs/product-configurator/rulebased/components/attribute/types/single-selection-image/configurator-attribute-single-selection-image.component.html +++ b/feature-libs/product-configurator/rulebased/components/attribute/types/single-selection-image/configurator-attribute-single-selection-image.component.html @@ -24,7 +24,7 @@ [value]="value.valueCode" name="{{ createAttributeIdForConfigurator(attribute) }}" attr.name="{{ createAttributeIdForConfigurator(attribute) }}" - [attr.required]="attribute.required" + [attr.required]="attribute.required === true ? 'required' : null" [attr.checked]=" attributeRadioButtonForm.value === value.valueCode ? 'checked' : null " @@ -96,7 +96,7 @@ [value]="value.valueCode" name="{{ createAttributeIdForConfigurator(attribute) }}" attr.name="{{ createAttributeIdForConfigurator(attribute) }}" - [attr.required]="attribute.required" + [attr.required]="attribute.required === true ? 'required' : null" [attr.checked]=" attributeRadioButtonForm.value === value.valueCode ? 'checked'