Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Dropddow] Items are not updated when remove manually #2998

Open
Jasonlgrd opened this issue Feb 12, 2024 · 2 comments
Open

[Dropddow] Items are not updated when remove manually #2998

Jasonlgrd opened this issue Feb 12, 2024 · 2 comments
Labels
tag/next-release/nightly Any issue which has a corresponding PR which has been merged and is available in the nightly build type/bug Any issue which is a bug or PR which fixes a bug
Milestone

Comments

@Jasonlgrd
Copy link

Bug Report

When I add item in input value manually and I call $('.ui.selection.dropdown').data().moduleDropdown.trigger.change(); it works. The items in dropdown are correctly added.
But, when I remove item in input value manally and I call $('.ui.selection.dropdown').data().moduleDropdown.trigger.change(); it doesn't work.

Steps to reproduce

I have created JsFiddle to simply reproduce this bug.

  1. In dropdown, select 3 or 4 elements.
  2. Check the DOM, you can see input with right value and all <a /> elements
  3. Click on the "Remove button"
  4. Check the DOM, you can see input with last element is removed but the <a /> element is always there.

Expected result

When item is removed and $('.ui.selection.dropdown').data().moduleDropdown.trigger.change(); is called, the <a /> element should be removed from the DOM.

Actual result

The <a /> element isn't removed from the DOM, so he is always display in dropdown.

Testcase

Screenshot (if possible)

Version

2.x.x

@Jasonlgrd Jasonlgrd added state/awaiting-investigation Anything which needs more investigation state/awaiting-triage Any issues or pull requests which haven't yet been triaged type/bug Any issue which is a bug or PR which fixes a bug labels Feb 12, 2024
@lubber-de
Copy link
Member

Fixed by #3000 See your adjusted jsfiddle here https://jsfiddle.net/lubber/v6eth3qu/

@lubber-de lubber-de added state/has-pr An issue which has a related PR open and removed state/awaiting-investigation Anything which needs more investigation state/awaiting-triage Any issues or pull requests which haven't yet been triaged labels Feb 14, 2024
@lubber-de lubber-de added this to the 2.9.4 milestone Feb 14, 2024
@Jasonlgrd
Copy link
Author

Oh nice ! I'm waiting a new release now, thanks of lot !

@lubber-de lubber-de added tag/next-release/nightly Any issue which has a corresponding PR which has been merged and is available in the nightly build and removed state/has-pr An issue which has a related PR open labels Feb 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tag/next-release/nightly Any issue which has a corresponding PR which has been merged and is available in the nightly build type/bug Any issue which is a bug or PR which fixes a bug
Projects
None yet
Development

No branches or pull requests

2 participants