designsystemet icon indicating copy to clipboard operation
designsystemet copied to clipboard

fix(Popover): unnecesary call of `onOpen` and missing call of `onClose`

Open unekinn opened this issue 2 months ago • 3 comments

Summary

Popover: Fix unnecesary call of onOpen and missing call of onClose

  • Don't call onOpen when clicking Popover.Trigger when Popover is already open.
  • Call onClose when a controlled Popover is closed by clicking on Popover.Trigger.

Checks

unekinn avatar Nov 11 '25 09:11 unekinn

🦋 Changeset detected

Latest commit: 4ab3095774b4bcb696c3e128a32879812e309286

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 4 packages
Name Type
@digdir/designsystemet-react Patch
@digdir/designsystemet Patch
@digdir/designsystemet-css Patch
@digdir/designsystemet-theme Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

changeset-bot[bot] avatar Nov 11 '25 09:11 changeset-bot[bot]

Preview deployments for this pull request:

storybook - 21. Nov 2025 - 14:18

github-actions[bot] avatar Nov 11 '25 10:11 github-actions[bot]

I'll make sure to fix this before next release 😄

Barsnes avatar Nov 21 '25 10:11 Barsnes