question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Tag component doesn't look like a tag when there is only one character

See original GitHub issue

What package(s) are you using?

  • carbon-components 10.9.0
  • carbon-components-react 7.9.0

Detailed description

Describe in detail the issue you’re having. We are using Tag component to show the count of roles a user can have and when it’s in single-digit the component looks like a ball instead of tag. There should a min width provided to make it look like a tag.

Is this issue related to a specific component? Tag

What did you expect to happen? What happened instead? What would you like to see changed? We are using Tag component to show the count of roles a user can have and when it’s in single-digit the component looks like a ball instead of tag.

What browser are you working in? FF Chrome Safari

What version of the Carbon Design System are you using?

  • carbon-components 10.9.0
  • carbon-components-react 7.9.0

What offering/product do you work on? Any pressing ship or release dates we should be aware of? IBM Cloud

Steps to reproduce the issue

  1. Use a single character in a tag component and see the issue

Screen Shot 2020-01-10 at 11 12 59 AM Screen Shot 2020-01-10 at 11 13 03 AM

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

3reactions
tw15egancommented, Jan 15, 2020

If this is okay, I’ll go ahead and make a PR 👍

2reactions
tw15egancommented, Jan 14, 2020

@aagonzales It seems like we can center the single-digit without it affecting the other variations

https://codesandbox.io/s/codesandbox-x5etc

Screen Shot 2020-01-14 at 2 51 58 PM
Read more comments on GitHub >

github_iconTop Results From Across the Web

In React ES6, why does the input field lose focus after typing a ...
Every time your state/prop change, the function returns a new form. it caused you to lose focus.
Read more >
WebD2: Common HTML Tags - University of Washington
Tags are comprised of elements and attributes. An element is an object on a page (such as a heading, paragraph, or image), and...
Read more >
HTML elements reference - HTML: HyperText Markup Language
There can be only one <base> element in a document. ... It only contains text; tags within the element are ignored.
Read more >
Structural markup and right-to-left text in HTML - W3C
This article looks at ways of handling text direction for structural markup in HTML, ie. at the document level and for elements like...
Read more >
Building a Tag Input Component with the Vue 3 Composition API
Right now they just show up below the input which doesn't make this feel like a tag input at all. They need to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found