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

Read-only TextInput has incorrect background color due to Tearsheet overriding style #6698

Open
2 tasks done
richardpilot opened this issue Jan 14, 2025 · 1 comment
Open
2 tasks done

Comments

@richardpilot
Copy link
Contributor

Package

Carbon for IBM Products

Description

The scss for the Tearsheet overrides the styling for TextInput, however when a TextInput component is in read-only mode, it's background-color is designed to match the background colour of the container.

https://github.com/carbon-design-system/ibm-products/blob/main/packages/ibm-products-styles/src/components/Tearsheet/_tearsheet.scss
Search for the override background-color: $field;

Current behaviour:
Image

Expected behaviour:
Image

Component(s) impacted

TextInput inside of any Tearsheet variant

Browser

No response

@carbon/ibm-products (previously @carbon/ibm-cloud-cognitive) version

2.47.0

Suggested Severity

None

Product/offering

MQ

CodeSandbox or Stackblitz example

https://codesandbox.io/p/devbox/wizardly-ellis-mf45yv

Steps to reproduce the issue (if applicable)

No response

Release date (if applicable)

No response

Code of Conduct

@github-project-automation github-project-automation bot moved this to Needs triage 🧐 in Carbon for IBM Products Jan 14, 2025
@richardpilot richardpilot changed the title [YOUR TITLE]: Brief description Read-only TextInput has incorrect background color due to Tearsheet overriding style Jan 14, 2025
@makafsal
Copy link
Member

Image

Observed similar issues with components text-area, search-input, select-input, dropdown, dropdown-list, and date-picker.

Fix: Avoid this style override for components in readOnly state Line 408

Test: Make sure working with all themes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Needs triage 🧐
Development

No branches or pull requests

2 participants