Skip to content
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

Right alligned toggle has overflowing label text #6865

Closed
2 tasks
ptlm500 opened this issue Sep 21, 2020 · 1 comment · Fixed by #8469
Closed
2 tasks

Right alligned toggle has overflowing label text #6865

ptlm500 opened this issue Sep 21, 2020 · 1 comment · Fixed by #8469
Labels

Comments

@ptlm500
Copy link

ptlm500 commented Sep 21, 2020

Right alligned toggle has overflowing label text:

What package(s) are you using?

  • carbon-components
  • carbon-components-react

Detailed description

Describe in detail the issue you're having.

When a Carbon toggle is right aligned the label text is able to overflow.

Eg when the toggle is in a flex parent that has the align-items: flex-end; applied:
image

Is this issue related to a specific component?
Toggle component https://www.carbondesignsystem.com/components/toggle/

What did you expect to happen? What happened instead? What would you like to
see changed?
Expected: The label text doesn't overflow from the toggle component
Actual: Label text isn't contained within the bx--toggle-input__label element, so always overflows
Desired: Label text should be contained within the bx--toggle-input__label element, so it is possible to right align the toggle component

What browser are you working in?

Observed in Chrome Version 85.0.4183.102, Firefox 68.12.0esr

What version of the Carbon Design System are you using?

        "carbon-components": "^10.3.0",
        "carbon-components-react": "^7.3.0",

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

IBM Netcool Operations Insight

Please create a reduced test case in CodeSandbox

https://codesandbox.io/s/frosty-hooks-o783wx
image

@tw15egan
Copy link
Member

tw15egan commented Nov 4, 2020

Related: #7210

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants