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.

If I set a className for max width on TextInput the invalid wrapper extends past it

See original GitHub issue

What package(s) are you using?

  • carbon-components
  • carbon-components-react

Detailed description

Describe in detail the issue you’re having. I used the className prop of the TextInput to set a maxWidth on the input field for certain TextInput types. It works! Unfortunately if the TextInput is invalid, the wrapper class highlights extend way beyond the max width of the Text Input. Can we also send the className prop along on the wrapper, or give a separate wrapper class prop that we can override?

Is this issue related to a specific component? TextInput

Additional information

image

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:1
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
scottdickersoncommented, Jan 31, 2020
0reactions
sstrubbergcommented, Nov 14, 2022

Fixed with v11.

Read more comments on GitHub >

github_iconTop Results From Across the Web

max-width - CSS: Cascading Style Sheets - MDN Web Docs
The max-width CSS property sets the maximum width of an element. It prevents the used value of the width property from becoming larger...
Read more >
Adjust width of input field to its input - Stack Overflow
I want a text input field with a dynamically changing width, so that the input field fluids around its contents. Every input has...
Read more >
How To Create Wrapper Components in React with Props
To create wrapper components, you'll first learn to use the rest and spread operators to collect unused props to pass down to nested...
Read more >
How To Use Styled-Components In React - Smashing Magazine
Extending Styles #. Let's say you're working on a landing page, and you've set your container to a certain max-width to keep things...
Read more >
CSS · Bootstrap
Use .container for a responsive fixed width container. ... Using a single set of .col-md-* grid classes, you can create a basic grid...
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