File tree Expand file tree Collapse file tree 2 files changed +16
-1
lines changed
components/ruby_ui/textarea Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -19,7 +19,14 @@ def default_attrs
19
19
ruby_ui__form_field_target : "input" ,
20
20
action : "input->ruby-ui--form-field#onInput invalid->ruby-ui--form-field#onInvalid"
21
21
} ,
22
- class : "flex w-full rounded-md border bg-background px-3 py-1 text-sm shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium focus-visible:outline-none focus-visible:ring-1 disabled:cursor-not-allowed disabled:opacity-50 border-border focus-visible:ring-ring placeholder:text-muted-foreground"
22
+ class : [
23
+ "flex w-full rounded-md border bg-background px-3 py-1 text-sm shadow-sm transition-colors border-border" ,
24
+ "placeholder:text-muted-foreground" ,
25
+ "disabled:cursor-not-allowed disabled:opacity-50" ,
26
+ "file:border-0 file:bg-transparent file:text-sm file:font-medium" ,
27
+ "focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring" ,
28
+ "aria-disabled:cursor-not-allowed aria-disabled:opacity-50 aria-disabled:pointer-events-none"
29
+ ]
23
30
}
24
31
end
25
32
end
Original file line number Diff line number Diff line change @@ -25,6 +25,14 @@ def view_template
25
25
RUBY
26
26
end
27
27
28
+ render Docs ::VisualCodeExample . new ( title : "Aria Disabled" , context : self ) do
29
+ <<~RUBY
30
+ div(class: "grid w-full max-w-sm items-center gap-1.5") do
31
+ Textarea(aria: {disabled: "true"}, placeholder: "Aria Disabled")
32
+ end
33
+ RUBY
34
+ end
35
+
28
36
render Docs ::VisualCodeExample . new ( title : "With FormField" , context : self ) do
29
37
<<~RUBY
30
38
div(class: "grid w-full max-w-sm items-center gap-1.5") do
You can’t perform that action at this time.
0 commit comments