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

SelectMenu component #21852

Closed
dvh91 opened this issue Jul 20, 2020 · 5 comments
Closed

SelectMenu component #21852

dvh91 opened this issue Jul 20, 2020 · 5 comments
Labels
duplicate This issue or pull request already exists

Comments

@dvh91
Copy link

dvh91 commented Jul 20, 2020

There's an internal component called SelectInput which is used for Select implementation.
It composes the initiator of the popover select menu and a Menu component which contains the list of options.
Also, it includes a lot of Select logic.

My use case is that I want to use the Select menu only and would love if this select logic and the whole select menu would be extracted into a component that will be publicly exposed.

The way I'm doing it, for now, is basically copying SelectInput and removed the initiator and opening logic.

Another way of solving it could be extracting the select logic into a hook and expose it. Then use it along with a Menu component.

@dvh91 dvh91 added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Jul 20, 2020
@oliviertassinari
Copy link
Member

What UI problems do you aim to solve?

@oliviertassinari oliviertassinari added status: waiting for author Issue with insufficient information and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Jul 20, 2020
@dvh91
Copy link
Author

dvh91 commented Jul 20, 2020

@oliviertassinari
One use case I have: having an open select menu like a chart legend.
Another use case is making a specific component open the popper with the menu.

@oliviertassinari
Copy link
Member

What's missing from the Menu component to implement that?

@dvh91
Copy link
Author

dvh91 commented Jul 20, 2020

The whole implementation that is in SelectInput - selection management, modification of children MenuItems with proper props based on the value.
Everything that separates a Menu from SelectMenu

@oliviertassinari
Copy link
Member

Duplicate of #21022

@oliviertassinari oliviertassinari marked this as a duplicate of #21022 Jul 20, 2020
@oliviertassinari oliviertassinari added duplicate This issue or pull request already exists and removed status: waiting for author Issue with insufficient information labels Jul 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

2 participants