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

[Bug]: Token "field-disabled" not involved into layering model #9832

Closed
2 tasks done
Eugeno opened this issue Oct 10, 2021 · 5 comments · Fixed by #9987 or #10535
Closed
2 tasks done

[Bug]: Token "field-disabled" not involved into layering model #9832

Eugeno opened this issue Oct 10, 2021 · 5 comments · Fixed by #9987 or #10535
Assignees
Labels

Comments

@Eugeno
Copy link

Eugeno commented Oct 10, 2021

Package

@carbon/colors

Browser

No response

Package version

v11 beta 2

Description

For example, we have a theme gray10, there is a white card (layering model). So disabled field is white on white background.
Looks like there should be filed-disabled-01, -02, -03.

CodeSandbox example

Steps to reproduce

check https://github.com/carbon-design-system/carbon/blob/36a6fdc307/packages/themes/src/next/g10.js

Code of Conduct

@joshblack
Copy link
Contributor

cc @aagonzales just wanted to check-in if this was something that we missed when implementing the layer sets or if there is something else going on here 👀

@Eugeno
Copy link
Author

Eugeno commented Oct 27, 2021

Same for placeholder.
Theme: gray90. field-03.
What is the result? gray-60 text on gray-60 background

@aagonzales
Copy link
Member

aagonzales commented Oct 27, 2021

For the field-disabled colors we've actually decided to not add those into the layer sets and we're actually going to remove $field-disabled entirely for the sake of simplicity because the color was actually change between enabled and disabled. So for the disabled state the input just keep $field-01 ect and the other elements indicate the input is disable like the text color change and removing the border bottom.

But you are right is we kept a distinct token for disabled field then we would need one for all three sets.

image

@aagonzales
Copy link
Member

aagonzales commented Oct 27, 2021

Also you are right, looks like we need to update some of the text tokens in the dark themes

G90 updates

  • $text-placeholder should be updated to Gray 50 (that will get it visible on all fields, it never passes color contrast)
  • $text-helper should be update to Gray 30 so it will be contrast accessible.

G100 updates

  • $text-helper should be update to Gray 40 so it will be contrast accessible.

image

@aagonzales
Copy link
Member

aagonzales commented Dec 1, 2021

Re-opening issue as all concerns weren't addressed.

To-dos:

  • Remove $field-disabled token
  • Remove $layer-disabled token

Consequences:
Any place were $field-disabled and layer-disabled were used will now simply just continue using $field and $layer. There is not visual change in the backgrounds of disabled elements. Only text and icons change color and there these tokens are not needed.

Components that were using these tokens and will need to be updated:

  • text input
  • search
  • select
  • number input
  • date picker
  • dropdown
  • text area

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Archived in project
4 participants