allianz / ng-aquila

Angular UI Component library for the Open Insurance Platform
https://allianz.github.io/ng-aquila/
Other
213 stars 38 forks source link

[Dropdown] DropdownItem displays nxValue instead of view value when disabled #40

Closed silviolosi closed 2 years ago

silviolosi commented 2 years ago

⚡ Reproduction

Steps to reproduce:

1 - Create a standard dropdown component with some options and disable one of them 2 - Set the disabled option as selected

<nx-dropdown [nxValue]="1">
    <nx-dropdown-item [nxValue]="0">option 1</nx-dropdown-item>
    <nx-dropdown-item [nxValue]="1" disabled>option 2</nx-dropdown-item>
    <nx-dropdown-item [nxValue]="2">option 3</nx-dropdown-item>
</nx-dropdown>

📗 Expected Behavior

The dropdown should show "Option 2" as the selected value

📕 Actual Behavior

The dropdown shows "1" as the selected value

📦 Environment

Probably this problem is related to a feature implemented in v.11.7.0: feat(dropdown): lazy rendering (#322)

yd-allianz commented 2 years ago

Hi @silviolosi thanks for reporting, we'll have to fix this.

yd-allianz commented 2 years ago

Hi @silviolosi we're happy to announce that this issue is fixed and is going to be available with the next release. Thanks for contributing!