Add icon support to the tabs component #1453
Closed
HiDeoo
started this conversation in
Feature Requests
Replies: 2 comments 1 reply
-
Sorry for the slow response on this one — yes I don’t see why we shouldn’t support this. And adds an argument for exposing all those extra icons in #1308 😁 The one difference from the above example I guess is that these would be monochrome icons, but I guess that’s OK? |
Beta Was this translation helpful? Give feedback.
1 reply
-
Available in Starlight |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
What version of
starlight
are you using?0.17.2
What is your idea?
Adding a new
icon
prop to the<TabItem>
component that would optionally accept an iconname
from the Starlight icon set and render it next to the tab label.Why is this feature necessary?
This would allow for more flexibility in the design of tabbed interfaces and make it easier to visually distinguish between tabs.
The idea originally comes from a features from Erika on the
starlight-package-managers
component (which internally uses the default Starlight tabs and only enhances them with sync between the tabs) to display package manager icons next to the package manager names.Do you have examples of this feature in other projects?
The Biome website uses that approach for package managers related comnmands in their documentation and I personally think it looks great.
For the specific use case of
starlight-package-managers
, #1308 already adds icons fornpm
,yarn
, andpnpm
.bun
could be added as well at some point if this is something of interest.Participation
Beta Was this translation helpful? Give feedback.
All reactions