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

Add Navigation flyout panel #1350

Open
Tracked by #188
rebeccaalpert opened this issue Oct 24, 2024 · 2 comments
Open
Tracked by #188

Add Navigation flyout panel #1350

rebeccaalpert opened this issue Oct 24, 2024 · 2 comments
Assignees
Labels
Milestone

Comments

@rebeccaalpert
Copy link
Member

rebeccaalpert commented Oct 24, 2024

Background

UXD is contributing to Composer AI Studio. As part of this work, Mark Riggan created wireframes for what their UI could look like. These wireframes included a flyout panel that comes out when a nav item is clicked.

Example:
Image

When "Chats" is clicked, you would see the panel with "Start your first conversation."

Specifications:

  • The panel can contain buttons, forms, loading states, error messages, or any other type of content.
  • It should close when users click outside of it or hit the escape key
  • It should "float" over the main body content
  • It should match the height of the main navigation.
  • It should be positioned at the top of the main navigation.
  • It would need to receive focus when opened and have a focus trap.
  • When closed, it should place the focus back on the main navigation item that opened it.
  • It should have appropriate aria attributes.

For mobile, suggestions have been made to make it full width on top of the navigation on mobile like this ugly mock-up:
Image

Explain why this feature is needed and/or why these requirements cannot be met using existing components.

We need a way to offer more complex user interactions that relate to the page content.

We attempted initially to create this using the Navigation Flyout Nav. However, the React implementation uses Popper.

  • Popper programmatically positions the menu content so it is close to the triggering nav item, rather than the entire sidebar as a whole. It is difficult to override this because it is done via inline styles.
  • There is no way to identify when Popper is open without an event listener, so it is difficult to programmatically set the height of the panel to match the main navigation.

If this is for specific applications, list them here along with any dates that you need this for.

This is for Composer AI Studio. However, both Andrew and Nicole reported having seen similar concepts for other products.

Link any detailed design documents, rough sketches, wireframes or workflows.

State whether this is a new feature or an enhancement on an existing pattern by labeling it accordingly

I guess this is an enhancement?

If this is an enhancement to an existing feature, identify the feature that you want to modify.

This would be a flyout menu attached to the Navigation component, similar to the flyout nav. However, it would be the full height of the nav sidebar and be positioned at the top of the nav sidebar. We would need it to to be well behaved on mobile and also desktop.

@rebeccaalpert rebeccaalpert added Enhancement PatternFly 6 Design issues related to Penta work labels Oct 24, 2024
@github-project-automation github-project-automation bot moved this to Needs triage in PatternFly Issues Oct 24, 2024
@rebeccaalpert
Copy link
Member Author

@thatblindgeye took a look at a crappy implementation I did so we could start working through potential issues.

It sounds like if we were to do this, we'd want the trigger to be a button rather than a link, with aria-haspopup="dialog" and an aria-expanded.

We have some open questions I'll bring up at working session:

  • Should it actually close when users click outside of it? It seems like that could be bad for forms, etc.
  • Whether it makes sense to have links in the nav that aren't nav items per se
    • Eric did find an example of a nav on W3c that consisted of a paragraph with links.

@kaylachumley
Copy link
Collaborator

Brand New Component Request! Interest from composer AI and Ansible Automation Platform

@andrew-ronaldson andrew-ronaldson moved this from Needs triage to Ready to assign in PatternFly Issues Nov 4, 2024
@andrew-ronaldson andrew-ronaldson added this to the 2024.Q4 milestone Nov 4, 2024
@andrew-ronaldson andrew-ronaldson moved this from Ready to assign to On deck in PatternFly Issues Nov 4, 2024
@bekah-stephens bekah-stephens self-assigned this Nov 4, 2024
@andrew-ronaldson andrew-ronaldson moved this from On deck to Not started in PatternFly Issues Nov 9, 2024
@bekah-stephens bekah-stephens moved this from Not started to In Progress in PatternFly Issues Nov 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: In Progress
Status: No status
Development

No branches or pull requests

4 participants