Skip to content

fix: popover doesn't close in FluentOverflow #2390

Description

🐛 Bug Report

This is a regression in FluentPopover when updating from 4.7.2 to 4.9.1. A FluentPopover that's nested inside a FluentOverflow isn't closing when clicking on the page outside of the popup.

💻 Repro or Code Sample

Code here:
https://github.com/dotnet/aspire/blob/1f94dac8188391804b22a8441c979d033b7b43b9/src/Aspire.Dashboard/Components/ResourcesGridColumns/EndpointsColumnDisplay.razor#L17-L60

Notably the popover is bound to a field, @bind-Open="_popoverVisible".

I changed it to a property for debugging and found clicking outside of the popup set it to false in 4.7.2:
image

But in 4.9.2 that changed to true:
image

🤔 Expected Behavior

Clicking on the page outside of the popup will close the popup.

😯 Current Behavior

The popup flickers but stays visible:
fluentpopover-open

💁 Possible Solution

🔦 Context

🌍 Your Environment

  • OS & Device: Windows
  • Browser: Chrome
  • .NET 8

Activity

  1. added
    triage
    on Jul 17, 2024
  2. vnbaaij commented on Jul 17, 2024

    @vnbaaij
    Collaborator

    Hmm, weird. The only files I see have changed between v4.7.2 and 4.9.1 are FluentOverflow.razor.cs and FluentOverflow.razor.js but there is nothing in there that could cause this.

    I can fix it easily by changing some code in FluentPopover.CloseAsync() (but that file was changed last 103 days ago!). A new PR will be up for this soon

  3. added
    status:in-progress
    and removed
    triage
    on Jul 17, 2024
  4. added a commit that references this issue on Jul 17, 2024
    7c4d22b
  5. added a commit that references this issue on Jul 18, 2024
    5ebaa3d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    status:in-progress

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions