💡 Proposal - Tag vs Pill
See original GitHub issueTag and Pill migration in v4
The problem
Hey everyone!
Currently, we have 2 components that might be confusing.
<Tag />
which is mostly used for labeling of highlighting elements in the interface
Example:
<Pill />
which is used for tagging elements in the interface
Example:
I think in order to achieve more consistency in naming we could migrate those 2 components in v4 to align their names with their purpose
The proposed solution
- Migrate
<Tag />
to<Label />
:
- create a separate package for
<Label />
that will contain current<Tag />
- I would like to introduce a set of “filled” Labels. Currently, we have only
filled-primary
and I wish we have a full set, the same as we have with the default (light) state. Downside - they look a bit like Buttons to me 😕 Fixing my own bug: I’ve got to the conclusion, that it would be better to createsolid
boolean property for the component, instead of for exampletagType="primary-filled"
it would be something like:
<Label labelType="primary" size="small" solid>new</Label>
This is how it potentially would look like (more or less):
- Migrate
<Pill />
to<Tag />
, with the existing functionalities ofPill
. Maybe we would like to extend the color set ofPill
? is there a usecase for having more colors for this component?
Breaking changes
v4
Open questions:
- do we agree to the proposed naming or maybe we would like to migrate
<Tag />
to something likeBadge
? - do we want to create
solid
labels (current Tags) and do we have any objections against thesolid
boolean prop? - do we want to extend the colors set for
<Pill />
(future Tag) component - more details #585?
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:14 (11 by maintainers)
Top Results From Across the Web
What is the difference between Pills, Chips and Tags/Tokens?
The short answer: they have different shapes. The (only slightly) longer answer: The tags in your question are not the UI device shown...
Read more >Badges vs. Pills vs. Chips vs. Tags · Issue #266 · openui/open-ui
The Badges research contains badge components and a "pills" section (as well as "icon"). There is also a PR open to add Pills...
Read more >22 Best UX Tools & Software to Perfect the User Experience
Here are the 22 most useful UX tools that designers can use to improve the user experience.
Read more >The Retailer's Guide to POS Hardware (2022) - Shopify
Researching what point-of-sale (POS) hardware you need to run your retail store? Read this guide for a complete roundup of what you need...
Read more >Design: Differentiate trigger jobs from regular jobs in the pipeline ...
Add a Trigger job badge to the trigger job pill. It should match the styling of the labels we use on multi-project and...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I think I missed the discussion about the reason behind having two similar components, could you show me?
IMO, Label is a confusing name because for me Label is a component related to the
<label>
tag used in forms so I suggest using other name: Tag or BadgeThe boolean prop idea is great 🙌
I am also +1 for renaming both. But I could see some issues if we repurpose the existing
Pill
to become theTag
component (event though it is a better name for it).I did some quick research to see how other design systems name our current
Pill
component: https://material.io/components/chips#usage https://atlassian.design/components/tag/examples https://www.carbondesignsystem.com/components/tag/usage https://www.lightningdesignsystem.com/components/pills/What is unique to our current
Pill
is that we also have a draggable state. Haven’t seen that in any other Design System. Another reason to renamePill
toTag
is in which context we use it most of the times which is displaying tag-like entities - at least for the usages that I am aware of.Naming is hard 😃