-
Notifications
You must be signed in to change notification settings - Fork 51
SuperSelect::Multiple
- Fix grouped options with show selected display
#2948
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
Conversation
The latest updates on your projects. Learn more about Vercel for Git โ๏ธ
|
โฆth show selected
98ab206
to
d27849c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with @shleewhite I can't think of a better way to select these using CSS than what you have
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interesting, this is a nice improvement! We don't really have the concept of grouped options in Figma (at least from a layout perspective), so I don't think any changes are needed in design tooling.
๐ Summary
If merged, this PR would enhance the display of
OptionGroup
options in theSuperSelect::Multiple
, when only selected options are shown.PREVIEW
๐ ๏ธ Detailed description
Currently in the
OptionGroup
of theSuper::Select::Multiple
, when the "show selected" button is used to only show selected options, if no options are selected the group and sub-group titles are shown with no options.This differs from the pattern used on super selects that do not contain groups. In those instances there is nothing shown in the menu besides the
noMatchesMessage
.In this PR we have made it so when "show selected" is active, the group or sub-group title of an option is only visible when an option in that group is selected. If a group / sub-group contains no selection options then their titles are not shown.
๐ธ Screenshots
"Show selected" with no options selected
Before

After

"Show selected" with some options selected
Before

After

๐ External links
Jira ticket: HDS-4775
๐ Component checklist
๐ฌ Please consider using conventional comments when reviewing this PR.
๐ PCI review checklist
Examples of changes to controls include access controls, encryption, logging, etc.
Examples include changes to operating systems, ports, protocols, services, cryptography-related components, PII processing code, etc.