Skip to content

Ensure only one flyout is open at a time #8042

@JasonStoltz

Description

@JasonStoltz

Is your feature request related to a problem? Please describe.
There have been a few instances where users have had issues with competing flyouts.

Here is an example in Kibana: elastic/kibana#193452

While things like this can be solved within a given solution, as seen here, it could be desirable to manage this more holistically, at a the EUI level.

I'm not sure whether or not this is possible within EUI or not. If not, we may be able to implement a shared service via the Shared UX team. I think the first step would be to consider whether or not this is even possible in EUI.

The rules could get a bit tricky here, as well. For instance, it doesn’t make sense to allow multiple push flyouts, but a push and 1 overlay flyout could make sense,

And additionally, I believe there were some proposals on the table at one point to allow multiple push flyouts at one time.

Describe the solution you'd like
A solution might involve maintaining a context of all opened Flyouts, and close any other Flyout when a new one is opened.

Describe alternatives you've considered
The alternative to doing this in EUI is expecting that consumers are responsible to manage this.

Desired timeline
None, that I know of.

Additional context
This issue was raised by @kertal

Related flyout issue: #7443

Another consideration:
There are situations where we have a globally available flyout (think of an ai assistant) that users can "pin", so that it remains open as users navigate from page to page. This can conflict with other flyouts that are already on the page.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions