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]: Fluid TextInput does not show a background in readonly mode #18152

Closed
2 tasks done
remagpie opened this issue Nov 25, 2024 · 4 comments
Closed
2 tasks done

[Bug]: Fluid TextInput does not show a background in readonly mode #18152

remagpie opened this issue Nov 25, 2024 · 4 comments

Comments

@remagpie
Copy link

remagpie commented Nov 25, 2024

Package

@carbon/react

Browser

Firefox

Package version

v1.71.0

React version

18.3.0

Description

According to the design document, TextInput in Fluid style should have a background color in readonly mode. But when I try it with @carbon/react package, it shows a transparent background instead.

Expected:
Image

Actual:
Image

Reproduction/example

https://stackblitz.com/edit/github-jqvw5p?file=src%2FApp.jsx

Steps to reproduce

Use the stackblitz link provided and render the App.jsx file.

Suggested Severity

Severity 2 = User cannot complete task, and/or no workaround within the user experience of a given component.

Application/PAL

No response

Code of Conduct

@alina-jacob
Copy link
Member

Hi @remagpie, this is the intended implementation, you can check the read-only state documented here (scroll a bit further down)
Image

@remagpie
Copy link
Author

@alina-jacob It seems that the image you gave me came from the Default mode of TextInput. My issue was related to the TextInput in Fluid mode. The document says the intended design has an gray background:

Image

@remagpie
Copy link
Author

And it seems that the image(the "Expected" one) I included in the issue was a wrong one. Sorry about that. It's now replaced with the correct image.

@alina-jacob
Copy link
Member

Oh yes sorry about the default fluid bit.
Upon double checking, turns out we have two stories for Fluid text input. The one you've linked in the incorrect one, here's the correct one. (Its marked unstable, but can you use it! Read more about unstable state here)

Just for reference, here's a Stackblitz of both, one with error and one without error.
We will fix the incorrect one, thanks for bringing it to our attention!

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

No branches or pull requests

2 participants