feat(InputMenu): add collapse-tags and collapse-hover props by Mewweb ยท Pull Request #6029 ยท nuxt/ui
๐ Linked issue
Resolves #6012
โ Type of change
- ๐ Documentation (updates to the documentation or readme)
- ๐ Bug fix (a non-breaking change that fixes an issue)
- ๐ Enhancement (improving an existing functionality)
- โจ New feature (a non-breaking change that adds functionality)
- ๐งน Chore (updates to the build process or auxiliary tools and libraries)
- โ ๏ธ Breaking change (fix or feature that would cause existing functionality to change)
๐ Description
What
Add collapse-tags to the InputMenu component to limit the number of selected options displayed as tags, with the remaining ones grouped into a counter (works with multiple).
Also add collapse-hover, which shows the remaining selected options when hovering over the counter (works with multiple and collapse-tags).
I have also modified the InputMenu documentation to reflect the change.
Why
To improve usability and responsiveness when many options are selected, which can otherwise clutter the InputMenu UI.
How
Implemented by introducing two new props:
collapse-tags: limits visible tags and groups overflow into a countercollapse-hover: displays hidden selections on hover
The behavior integrates with the existing multiple option.
๐ Checklist
- I have linked an issue or discussion.
- I have updated the documentation accordingly.