Skip to content

Conversation

@madsrasmussen
Copy link
Contributor

@madsrasmussen madsrasmussen commented May 13, 2025

This PR is a workaround for the bug and fixes #19295

For one reason or another, the 'umb-dropdowndoesn't toggle the popover when the.open` property is set. I have added two methods to open and close the dropdown, which do the same thing but actually work.

@madsrasmussen madsrasmussen marked this pull request as ready for review May 13, 2025 08:29
Copilot AI review requested due to automatic review settings May 13, 2025 08:29
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR implements a workaround for the dropdown toggling bug by replacing the binding to the .open property with explicit method calls.

  • In entity-actions-bundle.element.ts, the _dropdownIsOpen state is removed and replaced with a query-based dropdown element that calls closeDropdown() when an action is executed.
  • In dropdown.element.ts, the updated() lifecycle now warns users and calls openDropdown() or closeDropdown() directly instead of relying on the non-functional .open property.

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/Umbraco.Web.UI.Client/src/packages/core/components/entity-actions-bundle/entity-actions-bundle.element.ts Removed state-based toggling and replaced it with direct method calls on the dropdown element.
src/Umbraco.Web.UI.Client/src/packages/core/components/dropdown/dropdown.element.ts Updated the lifecycle to warn against using the .open property and to invoke the new dropdown methods.

@iOvergaard iOvergaard enabled auto-merge (squash) May 13, 2025 08:49
@iOvergaard iOvergaard disabled auto-merge May 13, 2025 10:56
@iOvergaard iOvergaard merged commit 8878bda into release/16.0 May 13, 2025
21 of 23 checks passed
@iOvergaard iOvergaard deleted the v16/hotfix/close-dropdown-after-executed-action branch May 13, 2025 10:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants