-
Notifications
You must be signed in to change notification settings - Fork 13
fix: textarea overflow, default rows, and size/variant API #738
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
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -5,15 +5,14 @@ | |
| outline: none; | ||
| height: auto; | ||
| width: 100%; | ||
| min-height: var(--rs-space-13); | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Removing Example: If someone sets |
||
| background-color: var(--rs-color-background-base-primary); | ||
| border: 0.5px solid var(--rs-color-border-base-tertiary); | ||
| border-radius: var(--rs-radius-2); | ||
| font-size: var(--rs-font-size-small); | ||
| line-height: var(--rs-line-height-small); | ||
| color: var(--rs-color-foreground-base-primary); | ||
| padding: var(--rs-space-3); | ||
| overflow: hidden; | ||
| overflow: auto; | ||
| } | ||
|
|
||
| @media (prefers-reduced-motion: no-preference) { | ||
|
|
@@ -61,3 +60,34 @@ | |
| .textarea[data-invalid]:focus { | ||
| border-color: var(--rs-color-border-danger-emphasis-hover); | ||
| } | ||
|
|
||
| /* Size variants */ | ||
| .size-large { | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| padding: var(--rs-space-3); | ||
| font-size: var(--rs-font-size-small); | ||
| line-height: var(--rs-line-height-small); | ||
| } | ||
|
|
||
| .size-small { | ||
| padding: var(--rs-space-2); | ||
| font-size: var(--rs-font-size-small); | ||
| line-height: var(--rs-line-height-small); | ||
| } | ||
|
|
||
| /* Variant styles */ | ||
| .variant-default { | ||
| border: 0.5px solid var(--rs-color-border-base-tertiary); | ||
| } | ||
|
|
||
| .variant-borderless { | ||
| border-color: transparent; | ||
| } | ||
|
|
||
| .variant-borderless:hover { | ||
| border-color: transparent; | ||
| } | ||
|
|
||
| .variant-borderless:focus:not(:disabled) { | ||
| border-color: transparent; | ||
| outline: none; | ||
| } | ||
|
Comment on lines
+90
to
+93
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Borderless variant loses visible keyboard focus state. Line 90–93 keeps border transparent and removes outline, so focused and unfocused states become visually indistinguishable for keyboard users. Please retain a visible focus indicator for Suggested patch .variant-borderless:focus:not(:disabled) {
border-color: transparent;
- outline: none;
+ outline: 2px solid var(--rs-color-border-accent-emphasis);
+ outline-offset: 1px;
}🤖 Prompt for AI Agents
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We have focus ring related improvements planned. Will be picked later.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets add rows prop control as well in the playground.