@iress-oss/ids-mcp-server 5.15.0 → 5.20.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/generated/docs/components_components-alert-docs.md +496 -0
- package/generated/docs/components_components-autocomplete-docs.md +3429 -0
- package/generated/docs/{components-autocomplete-recipes-docs.md → components_components-autocomplete-recipes-docs.md} +39 -14
- package/generated/docs/{components-badge-docs.md → components_components-badge-docs.md} +222 -30
- package/generated/docs/components_components-button-docs.md +2078 -0
- package/generated/docs/components_components-button-recipes-docs.md +37 -0
- package/generated/docs/components_components-buttongroup-docs.md +1045 -0
- package/generated/docs/components_components-card-docs.md +2290 -0
- package/generated/docs/{components-card-recipes-docs.md → components_components-card-recipes-docs.md} +132 -15
- package/generated/docs/components_components-checkbox-docs.md +1040 -0
- package/generated/docs/{components-checkboxgroup-docs.md → components_components-checkboxgroup-docs.md} +1001 -82
- package/generated/docs/{components-checkboxgroup-recipes-docs.md → components_components-checkboxgroup-recipes-docs.md} +102 -12
- package/generated/docs/{components-col-docs.md → components_components-col-docs.md} +331 -58
- package/generated/docs/components_components-combobox-docs.md +3735 -0
- package/generated/docs/{components-container-docs.md → components_components-container-docs.md} +61 -24
- package/generated/docs/{components-divider-docs.md → components_components-divider-docs.md} +83 -24
- package/generated/docs/{components-expander-docs.md → components_components-expander-docs.md} +266 -33
- package/generated/docs/components_components-field-docs.md +1369 -0
- package/generated/docs/components_components-filter-docs.md +4080 -0
- package/generated/docs/{components-form-docs.md → components_components-form-docs.md} +1556 -360
- package/generated/docs/{components-form-recipes-docs.md → components_components-form-recipes-docs.md} +277 -60
- package/generated/docs/{components-hide-docs.md → components_components-hide-docs.md} +195 -124
- package/generated/docs/components_components-icon-docs.md +1337 -0
- package/generated/docs/{components-inline-docs.md → components_components-inline-docs.md} +462 -42
- package/generated/docs/components_components-input-docs.md +1468 -0
- package/generated/docs/components_components-input-recipes-docs.md +367 -0
- package/generated/docs/components_components-inputcurrency-docs.md +432 -0
- package/generated/docs/{components-inputcurrency-recipes-docs.md → components_components-inputcurrency-recipes-docs.md} +113 -17
- package/generated/docs/components_components-label-docs.md +323 -0
- package/generated/docs/components_components-menu-docs.md +2345 -0
- package/generated/docs/components_components-menu-menuitem-docs.md +633 -0
- package/generated/docs/{components-modal-docs.md → components_components-modal-docs.md} +1640 -231
- package/generated/docs/components_components-navbar-docs.md +1847 -0
- package/generated/docs/{components-navbar-recipes-docs.md → components_components-navbar-recipes-docs.md} +721 -40
- package/generated/docs/{components-panel-docs.md → components_components-panel-docs.md} +754 -57
- package/generated/docs/components_components-placeholder-docs.md +92 -0
- package/generated/docs/components_components-popover-docs.md +1643 -0
- package/generated/docs/components_components-popover-recipes-docs.md +491 -0
- package/generated/docs/components_components-progress-docs.md +115 -0
- package/generated/docs/{components-provider-docs.md → components_components-provider-docs.md} +42 -33
- package/generated/docs/components_components-radio-docs.md +491 -0
- package/generated/docs/{components-radiogroup-docs.md → components_components-radiogroup-docs.md} +927 -75
- package/generated/docs/components_components-readonly-docs.md +263 -0
- package/generated/docs/components_components-richselect-docs.md +6521 -0
- package/generated/docs/{components-row-docs.md → components_components-row-docs.md} +353 -43
- package/generated/docs/{components-select-docs.md → components_components-select-docs.md} +719 -61
- package/generated/docs/components_components-skeleton-docs.md +480 -0
- package/generated/docs/{components-skeleton-recipes-docs.md → components_components-skeleton-recipes-docs.md} +51 -11
- package/generated/docs/{components-skiplink-docs.md → components_components-skiplink-docs.md} +53 -14
- package/generated/docs/components_components-slideout-docs.md +2293 -0
- package/generated/docs/components_components-slider-docs.md +1276 -0
- package/generated/docs/components_components-spinner-docs.md +82 -0
- package/generated/docs/{components-stack-docs.md → components_components-stack-docs.md} +223 -40
- package/generated/docs/components_components-table-docs.md +3658 -0
- package/generated/docs/components_components-tabset-docs.md +772 -0
- package/generated/docs/components_components-tabset-tab-docs.md +262 -0
- package/generated/docs/components_components-tag-docs.md +257 -0
- package/generated/docs/{components-text-docs.md → components_components-text-docs.md} +491 -51
- package/generated/docs/{components-toaster-docs.md → components_components-toaster-docs.md} +187 -85
- package/generated/docs/components_components-toaster-toast-docs.md +634 -0
- package/generated/docs/components_components-toggle-docs.md +461 -0
- package/generated/docs/{components-tooltip-docs.md → components_components-tooltip-docs.md} +286 -41
- package/generated/docs/{components-validationmessage-docs.md → components_components-validationmessage-docs.md} +230 -61
- package/generated/docs/components_contact-us-docs.md +12 -0
- package/generated/docs/{foundations-accessibility-docs.md → components_foundations-accessibility-docs.md} +11 -21
- package/generated/docs/{foundations-colours-docs.md → components_foundations-colour-030-colours.md} +8 -15
- package/generated/docs/{foundations-consistency-docs.md → components_foundations-consistency-docs.md} +12 -20
- package/generated/docs/{foundations-content-docs.md → components_foundations-content-docs.md} +6 -11
- package/generated/docs/components_foundations-introduction-docs.md +15 -0
- package/generated/docs/{foundations-principles-docs.md → components_foundations-principles-docs.md} +14 -24
- package/generated/docs/components_foundations-typography-docs.md +608 -0
- package/generated/docs/{foundations-user-experience-docs.md → components_foundations-user-experience-docs.md} +16 -26
- package/generated/docs/{foundations-visual-design-docs.md → components_foundations-visual-design-docs.md} +10 -17
- package/generated/docs/{frequently-asked-questions-docs.md → components_frequently-asked-questions-docs.md} +14 -23
- package/generated/docs/components_get-started-develop-docs.md +84 -0
- package/generated/docs/components_get-started-using-storybook-docs.md +55 -0
- package/generated/docs/components_introduction-docs.md +15 -0
- package/generated/docs/{patterns-loading-docs.md → components_patterns-loading-docs.md} +798 -153
- package/generated/docs/components_resources-changelog-docs.md +4 -0
- package/generated/docs/{resources-code-katas-docs.md → components_resources-code-katas-docs.md} +5 -9
- package/generated/docs/{resources-migration-guides-from-v4-to-v5-docs.md → components_resources-migration-guides-from-v4-to-v5-docs.md} +54 -239
- package/generated/docs/components_sandbox-docs.md +4 -0
- package/generated/docs/{versions-docs.md → components_versions-docs.md} +5 -8
- package/generated/docs/guidelines.md +484 -200
- package/generated/docs/introduction-docs.md +19 -30
- package/package.json +41 -45
- package/generated/docs/components-alert-docs.md +0 -130
- package/generated/docs/components-autocomplete-docs.md +0 -754
- package/generated/docs/components-button-docs.md +0 -362
- package/generated/docs/components-button-recipes-docs.md +0 -76
- package/generated/docs/components-buttongroup-docs.md +0 -310
- package/generated/docs/components-card-docs.md +0 -494
- package/generated/docs/components-checkbox-docs.md +0 -193
- package/generated/docs/components-combobox-docs.md +0 -1016
- package/generated/docs/components-field-docs.md +0 -675
- package/generated/docs/components-filter-docs.md +0 -1109
- package/generated/docs/components-icon-docs.md +0 -553
- package/generated/docs/components-input-docs.md +0 -335
- package/generated/docs/components-input-recipes-docs.md +0 -140
- package/generated/docs/components-inputcurrency-docs.md +0 -157
- package/generated/docs/components-label-docs.md +0 -135
- package/generated/docs/components-menu-docs.md +0 -704
- package/generated/docs/components-menu-menuitem-docs.md +0 -193
- package/generated/docs/components-navbar-docs.md +0 -291
- package/generated/docs/components-placeholder-docs.md +0 -27
- package/generated/docs/components-popover-docs.md +0 -464
- package/generated/docs/components-popover-recipes-docs.md +0 -245
- package/generated/docs/components-progress-docs.md +0 -104
- package/generated/docs/components-radio-docs.md +0 -107
- package/generated/docs/components-readonly-docs.md +0 -89
- package/generated/docs/components-richselect-docs.md +0 -2433
- package/generated/docs/components-skeleton-docs.md +0 -214
- package/generated/docs/components-slideout-docs.md +0 -538
- package/generated/docs/components-slider-docs.md +0 -346
- package/generated/docs/components-spinner-docs.md +0 -59
- package/generated/docs/components-table-ag-grid-docs.md +0 -1074
- package/generated/docs/components-table-docs.md +0 -1305
- package/generated/docs/components-tabset-docs.md +0 -341
- package/generated/docs/components-tabset-tab-docs.md +0 -86
- package/generated/docs/components-tag-docs.md +0 -115
- package/generated/docs/components-toaster-toast-docs.md +0 -157
- package/generated/docs/components-toggle-docs.md +0 -158
- package/generated/docs/contact-us-docs.md +0 -27
- package/generated/docs/extensions-editor-docs.md +0 -288
- package/generated/docs/extensions-editor-recipes-docs.md +0 -39
- package/generated/docs/foundations-introduction-docs.md +0 -17
- package/generated/docs/foundations-typography-docs.md +0 -191
- package/generated/docs/get-started-develop-docs.md +0 -209
- package/generated/docs/get-started-using-storybook-docs.md +0 -68
- package/generated/docs/resources-changelog-docs.md +0 -6
- package/generated/docs/themes-available-themes-docs.md +0 -66
- package/generated/docs/themes-introduction-docs.md +0 -121
- package/generated/docs/themes-tokens-docs.md +0 -1200
- /package/{LICENSE.txt → LICENSE} +0 -0
package/generated/docs/{components-radiogroup-docs.md → components_components-radiogroup-docs.md}
RENAMED
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
RadioGroup
|
|
2
|
+
==========
|
|
3
3
|
|
|
4
4
|
Overview
|
|
5
5
|
--------
|
|
6
6
|
|
|
7
7
|
A radio group is a group of radio buttons that allows the user to select one option from multiple options, where all options are visible.
|
|
8
8
|
|
|
9
|
+
[](./iframe.html?id=components-radiogroup--radio-children)
|
|
10
|
+
|
|
9
11
|
Google
|
|
10
12
|
|
|
11
13
|
Newspaper
|
|
@@ -14,9 +16,7 @@ Friend
|
|
|
14
16
|
|
|
15
17
|
Other
|
|
16
18
|
|
|
17
|
-
Hide
|
|
18
|
-
|
|
19
|
-
\[data-radix-scroll-area-viewport\] { scrollbar-width: none; -ms-overflow-style: none; -webkit-overflow-scrolling: touch; } \[data-radix-scroll-area-viewport\]::-webkit-scrollbar { display: none; } :where(\[data-radix-scroll-area-viewport\]) { display: flex; flex-direction: column; align-items: stretch; } :where(\[data-radix-scroll-area-content\]) { flex-grow: 1; }
|
|
19
|
+
Hide codedrawOpen in CodeSandbox
|
|
20
20
|
|
|
21
21
|
<IressRadioGroup\>
|
|
22
22
|
<IressRadio value\="google"\>
|
|
@@ -29,17 +29,125 @@ Hide code
|
|
|
29
29
|
Other </IressRadio\>
|
|
30
30
|
</IressRadioGroup\>
|
|
31
31
|
|
|
32
|
-
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
Props
|
|
35
|
+
-----
|
|
36
|
+
|
|
37
|
+
IressRadioGroupIressRadio
|
|
38
|
+
|
|
39
|
+
| Name | Description | Default | Control |
|
|
40
|
+
| --- | --- | --- | --- |
|
|
41
|
+
| children |
|
|
42
|
+
Content of the radio group, usually multiple `IressRadio` components.
|
|
43
|
+
|
|
44
|
+
ReactNode
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
| \- | \- |
|
|
49
|
+
| defaultValue |
|
|
50
|
+
|
|
51
|
+
Initial value of radio group when in uncontrolled mode.
|
|
52
|
+
|
|
53
|
+
FormControlValue
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
| \- | Set object |
|
|
58
|
+
| hiddenRadio |
|
|
59
|
+
|
|
60
|
+
Hides the radio control to allow the creation of custom radio buttons.
|
|
61
|
+
|
|
62
|
+
boolean
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
| \- | Set boolean |
|
|
67
|
+
| layout |
|
|
68
|
+
|
|
69
|
+
Sets which of the block / inline layout options apply.
|
|
70
|
+
|
|
71
|
+
union
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
|
|
75
|
+
|
|
|
76
|
+
|
|
77
|
+
'stack'
|
|
78
|
+
|
|
79
|
+
| Set object |
|
|
80
|
+
| name |
|
|
81
|
+
|
|
82
|
+
Name to be applied to all radios in the group.
|
|
83
|
+
|
|
84
|
+
string
|
|
85
|
+
|
|
33
86
|
|
|
34
|
-
[](#examples)Examples
|
|
35
|
-
---------------------
|
|
36
87
|
|
|
37
|
-
|
|
88
|
+
| \- | Set string |
|
|
89
|
+
| onChange |
|
|
90
|
+
|
|
91
|
+
Called when a user selects one of its children radio buttons. If you pass in a non-string value, you can access it using the second parameter of the function.
|
|
92
|
+
|
|
93
|
+
( e: React.ChangeEvent<HTMLInputElement>, value?: FormControlValue, ) => void
|
|
94
|
+
|
|
95
|
+
| \- | \- |
|
|
96
|
+
| readonly |
|
|
97
|
+
|
|
98
|
+
Renders a readonly radio group.
|
|
99
|
+
|
|
100
|
+
boolean
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
| \- | Set boolean |
|
|
105
|
+
| required |
|
|
106
|
+
|
|
107
|
+
When true, marks the field as required
|
|
108
|
+
|
|
109
|
+
boolean
|
|
110
|
+
|
|
111
|
+
|
|
112
|
+
|
|
113
|
+
| \- | Set boolean |
|
|
114
|
+
| role |
|
|
115
|
+
|
|
116
|
+
|
|
|
117
|
+
|
|
118
|
+
'radiogroup'
|
|
119
|
+
|
|
120
|
+
| Set object |
|
|
121
|
+
| touch |
|
|
122
|
+
|
|
123
|
+
Add the button-like border and padding to radio when `touch` is true.
|
|
124
|
+
|
|
125
|
+
boolean
|
|
126
|
+
|
|
127
|
+
|
|
128
|
+
|
|
129
|
+
| \- | Set boolean |
|
|
130
|
+
| value |
|
|
131
|
+
|
|
132
|
+
Value of radio group when in controlled mode.
|
|
133
|
+
|
|
134
|
+
FormControlValue
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
|
|
138
|
+
| \- | Set object |
|
|
139
|
+
|
|
140
|
+
Examples
|
|
141
|
+
--------
|
|
142
|
+
|
|
143
|
+
### Radio children
|
|
38
144
|
|
|
39
145
|
Individual radio buttons can be passed directly into `IressRadioGroup`.
|
|
40
146
|
|
|
41
147
|
**Note:** The `mapRadioGroupOptions` helper function, originally used to map options to `IressRadio` components, is now deprecated. Instead, you can use `array.map` to map the options to `IressRadio` components.
|
|
42
148
|
|
|
149
|
+
[](./iframe.html?id=components-radiogroup--radio-children)
|
|
150
|
+
|
|
43
151
|
Google
|
|
44
152
|
|
|
45
153
|
Newspaper
|
|
@@ -48,9 +156,7 @@ Friend
|
|
|
48
156
|
|
|
49
157
|
Other
|
|
50
158
|
|
|
51
|
-
Hide
|
|
52
|
-
|
|
53
|
-
\[data-radix-scroll-area-viewport\] { scrollbar-width: none; -ms-overflow-style: none; -webkit-overflow-scrolling: touch; } \[data-radix-scroll-area-viewport\]::-webkit-scrollbar { display: none; } :where(\[data-radix-scroll-area-viewport\]) { display: flex; flex-direction: column; align-items: stretch; } :where(\[data-radix-scroll-area-content\]) { flex-grow: 1; }
|
|
159
|
+
Hide codedrawOpen in CodeSandbox
|
|
54
160
|
|
|
55
161
|
<IressRadioGroup\>
|
|
56
162
|
<IressRadio value\="google"\>
|
|
@@ -63,14 +169,121 @@ Hide code
|
|
|
63
169
|
Other </IressRadio\>
|
|
64
170
|
</IressRadioGroup\>
|
|
65
171
|
|
|
66
|
-
|
|
172
|
+
```
|
|
173
|
+
|
|
174
|
+
#### Props
|
|
175
|
+
|
|
176
|
+
IressRadioGroupIressRadio
|
|
177
|
+
|
|
178
|
+
| Name | Description | Default | Control |
|
|
179
|
+
| --- | --- | --- | --- |
|
|
180
|
+
| children |
|
|
181
|
+
Content of the radio group, usually multiple `IressRadio` components.
|
|
182
|
+
|
|
183
|
+
ReactNode
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
|
|
187
|
+
| \- | \- |
|
|
188
|
+
| defaultValue |
|
|
189
|
+
|
|
190
|
+
Initial value of radio group when in uncontrolled mode.
|
|
191
|
+
|
|
192
|
+
FormControlValue
|
|
193
|
+
|
|
194
|
+
|
|
195
|
+
|
|
196
|
+
| \- | Set object |
|
|
197
|
+
| hiddenRadio |
|
|
198
|
+
|
|
199
|
+
Hides the radio control to allow the creation of custom radio buttons.
|
|
200
|
+
|
|
201
|
+
boolean
|
|
202
|
+
|
|
203
|
+
|
|
204
|
+
|
|
205
|
+
| \- | Set boolean |
|
|
206
|
+
| layout |
|
|
207
|
+
|
|
208
|
+
Sets which of the block / inline layout options apply.
|
|
209
|
+
|
|
210
|
+
union
|
|
211
|
+
|
|
212
|
+
|
|
213
|
+
|
|
214
|
+
|
|
|
215
|
+
|
|
216
|
+
'stack'
|
|
217
|
+
|
|
218
|
+
| Set object |
|
|
219
|
+
| name |
|
|
220
|
+
|
|
221
|
+
Name to be applied to all radios in the group.
|
|
222
|
+
|
|
223
|
+
string
|
|
224
|
+
|
|
67
225
|
|
|
68
|
-
|
|
226
|
+
|
|
227
|
+
| \- | Set string |
|
|
228
|
+
| onChange |
|
|
229
|
+
|
|
230
|
+
Called when a user selects one of its children radio buttons. If you pass in a non-string value, you can access it using the second parameter of the function.
|
|
231
|
+
|
|
232
|
+
( e: React.ChangeEvent<HTMLInputElement>, value?: FormControlValue, ) => void
|
|
233
|
+
|
|
234
|
+
| \- | \- |
|
|
235
|
+
| readonly |
|
|
236
|
+
|
|
237
|
+
Renders a readonly radio group.
|
|
238
|
+
|
|
239
|
+
boolean
|
|
240
|
+
|
|
241
|
+
|
|
242
|
+
|
|
243
|
+
| \- | Set boolean |
|
|
244
|
+
| required |
|
|
245
|
+
|
|
246
|
+
When true, marks the field as required
|
|
247
|
+
|
|
248
|
+
boolean
|
|
249
|
+
|
|
250
|
+
|
|
251
|
+
|
|
252
|
+
| \- | Set boolean |
|
|
253
|
+
| role |
|
|
254
|
+
|
|
255
|
+
|
|
|
256
|
+
|
|
257
|
+
'radiogroup'
|
|
258
|
+
|
|
259
|
+
| Set object |
|
|
260
|
+
| touch |
|
|
261
|
+
|
|
262
|
+
Add the button-like border and padding to radio when `touch` is true.
|
|
263
|
+
|
|
264
|
+
boolean
|
|
265
|
+
|
|
266
|
+
|
|
267
|
+
|
|
268
|
+
| \- | Set boolean |
|
|
269
|
+
| value |
|
|
270
|
+
|
|
271
|
+
Value of radio group when in controlled mode.
|
|
272
|
+
|
|
273
|
+
FormControlValue
|
|
274
|
+
|
|
275
|
+
|
|
276
|
+
|
|
277
|
+
| \- | Set object |
|
|
278
|
+
|
|
279
|
+
### Radio selection
|
|
69
280
|
|
|
70
281
|
The default checked state of the radio children should always be set using the `value` prop. Sometimes you may wish to use the `IressRadioGroup` as an "uncontrolled" component - for example, because you are using a third party form library that requires it. In this case, simply use `defaultValue` instead of `value`.
|
|
71
282
|
|
|
72
283
|
**Note:** The `value` prop on the `IressRadioGroup` component will always override the `checked` state of the `IressRadio` children.
|
|
73
284
|
|
|
285
|
+
[](./iframe.html?id=components-radiogroup--radio-selection)
|
|
286
|
+
|
|
74
287
|
Google
|
|
75
288
|
|
|
76
289
|
Newspaper
|
|
@@ -79,9 +292,7 @@ Friend
|
|
|
79
292
|
|
|
80
293
|
Other
|
|
81
294
|
|
|
82
|
-
Hide
|
|
83
|
-
|
|
84
|
-
\[data-radix-scroll-area-viewport\] { scrollbar-width: none; -ms-overflow-style: none; -webkit-overflow-scrolling: touch; } \[data-radix-scroll-area-viewport\]::-webkit-scrollbar { display: none; } :where(\[data-radix-scroll-area-viewport\]) { display: flex; flex-direction: column; align-items: stretch; } :where(\[data-radix-scroll-area-content\]) { flex-grow: 1; }
|
|
295
|
+
Hide codedrawOpen in CodeSandbox
|
|
85
296
|
|
|
86
297
|
<IressRadioGroup defaultValue\="newspaper"\>
|
|
87
298
|
<IressRadio value\="google"\>
|
|
@@ -94,9 +305,118 @@ Hide code
|
|
|
94
305
|
Other </IressRadio\>
|
|
95
306
|
</IressRadioGroup\>
|
|
96
307
|
|
|
97
|
-
|
|
308
|
+
```
|
|
309
|
+
|
|
310
|
+
#### Props
|
|
311
|
+
|
|
312
|
+
IressRadioGroupIressRadio
|
|
313
|
+
|
|
314
|
+
| Name | Description | Default | Control |
|
|
315
|
+
| --- | --- | --- | --- |
|
|
316
|
+
| children |
|
|
317
|
+
Content of the radio group, usually multiple `IressRadio` components.
|
|
318
|
+
|
|
319
|
+
ReactNode
|
|
320
|
+
|
|
321
|
+
|
|
322
|
+
|
|
323
|
+
| \- | \- |
|
|
324
|
+
| defaultValue |
|
|
325
|
+
|
|
326
|
+
Initial value of radio group when in uncontrolled mode.
|
|
327
|
+
|
|
328
|
+
FormControlValue
|
|
329
|
+
|
|
330
|
+
|
|
331
|
+
|
|
332
|
+
| \- |
|
|
333
|
+
|
|
334
|
+
"newspaper"
|
|
335
|
+
|
|
336
|
+
|
|
|
337
|
+
| hiddenRadio |
|
|
338
|
+
|
|
339
|
+
Hides the radio control to allow the creation of custom radio buttons.
|
|
340
|
+
|
|
341
|
+
boolean
|
|
342
|
+
|
|
343
|
+
|
|
344
|
+
|
|
345
|
+
| \- | Set boolean |
|
|
346
|
+
| layout |
|
|
347
|
+
|
|
348
|
+
Sets which of the block / inline layout options apply.
|
|
349
|
+
|
|
350
|
+
union
|
|
351
|
+
|
|
352
|
+
|
|
353
|
+
|
|
354
|
+
|
|
|
355
|
+
|
|
356
|
+
'stack'
|
|
357
|
+
|
|
358
|
+
| Set object |
|
|
359
|
+
| name |
|
|
360
|
+
|
|
361
|
+
Name to be applied to all radios in the group.
|
|
362
|
+
|
|
363
|
+
string
|
|
364
|
+
|
|
98
365
|
|
|
99
|
-
|
|
366
|
+
|
|
367
|
+
| \- | Set string |
|
|
368
|
+
| onChange |
|
|
369
|
+
|
|
370
|
+
Called when a user selects one of its children radio buttons. If you pass in a non-string value, you can access it using the second parameter of the function.
|
|
371
|
+
|
|
372
|
+
( e: React.ChangeEvent<HTMLInputElement>, value?: FormControlValue, ) => void
|
|
373
|
+
|
|
374
|
+
| \- | \- |
|
|
375
|
+
| readonly |
|
|
376
|
+
|
|
377
|
+
Renders a readonly radio group.
|
|
378
|
+
|
|
379
|
+
boolean
|
|
380
|
+
|
|
381
|
+
|
|
382
|
+
|
|
383
|
+
| \- | Set boolean |
|
|
384
|
+
| required |
|
|
385
|
+
|
|
386
|
+
When true, marks the field as required
|
|
387
|
+
|
|
388
|
+
boolean
|
|
389
|
+
|
|
390
|
+
|
|
391
|
+
|
|
392
|
+
| \- | Set boolean |
|
|
393
|
+
| role |
|
|
394
|
+
|
|
395
|
+
|
|
|
396
|
+
|
|
397
|
+
'radiogroup'
|
|
398
|
+
|
|
399
|
+
| Set object |
|
|
400
|
+
| touch |
|
|
401
|
+
|
|
402
|
+
Add the button-like border and padding to radio when `touch` is true.
|
|
403
|
+
|
|
404
|
+
boolean
|
|
405
|
+
|
|
406
|
+
|
|
407
|
+
|
|
408
|
+
| \- | Set boolean |
|
|
409
|
+
| value |
|
|
410
|
+
|
|
411
|
+
Value of radio group when in controlled mode.
|
|
412
|
+
|
|
413
|
+
FormControlValue
|
|
414
|
+
|
|
415
|
+
|
|
416
|
+
|
|
417
|
+
| \- | Set object |
|
|
418
|
+
|
|
419
|
+
### Layout
|
|
100
420
|
|
|
101
421
|
The layout prop controls how the radio group is displayed and can have three basic layouts:
|
|
102
422
|
|
|
@@ -111,6 +431,8 @@ Note:
|
|
|
111
431
|
|
|
112
432
|
If using any of the inline\* props within a `Field` component, the `Field` also needs the inline prop to be set for the inline layouts to take effect.
|
|
113
433
|
|
|
434
|
+
[](./iframe.html?id=components-radiogroup--layout)
|
|
435
|
+
|
|
114
436
|
### stack
|
|
115
437
|
|
|
116
438
|
Google
|
|
@@ -161,9 +483,7 @@ Friend
|
|
|
161
483
|
|
|
162
484
|
Other
|
|
163
485
|
|
|
164
|
-
Hide
|
|
165
|
-
|
|
166
|
-
\[data-radix-scroll-area-viewport\] { scrollbar-width: none; -ms-overflow-style: none; -webkit-overflow-scrolling: touch; } \[data-radix-scroll-area-viewport\]::-webkit-scrollbar { display: none; } :where(\[data-radix-scroll-area-viewport\]) { display: flex; flex-direction: column; align-items: stretch; } :where(\[data-radix-scroll-area-content\]) { flex-grow: 1; }
|
|
486
|
+
Hide codedrawOpen in CodeSandbox
|
|
167
487
|
|
|
168
488
|
<IressText className\="iress-u-stack iress--gutter--lg"\>
|
|
169
489
|
<div\>
|
|
@@ -171,22 +491,22 @@ Hide code
|
|
|
171
491
|
stack </h3\>
|
|
172
492
|
<IressRadioGroup layout\="stack"\>
|
|
173
493
|
<IressRadio
|
|
174
|
-
className\="ids-styles--add-border-
|
|
494
|
+
className\="ids-styles--add-border-v5203"
|
|
175
495
|
value\="google"
|
|
176
496
|
\>
|
|
177
497
|
Google </IressRadio\>
|
|
178
498
|
<IressRadio
|
|
179
|
-
className\="ids-styles--add-border-
|
|
499
|
+
className\="ids-styles--add-border-v5203"
|
|
180
500
|
value\="newspaper"
|
|
181
501
|
\>
|
|
182
502
|
Newspaper </IressRadio\>
|
|
183
503
|
<IressRadio
|
|
184
|
-
className\="ids-styles--add-border-
|
|
504
|
+
className\="ids-styles--add-border-v5203"
|
|
185
505
|
value\="friend"
|
|
186
506
|
\>
|
|
187
507
|
Friend </IressRadio\>
|
|
188
508
|
<IressRadio
|
|
189
|
-
className\="ids-styles--add-border-
|
|
509
|
+
className\="ids-styles--add-border-v5203"
|
|
190
510
|
value\="other"
|
|
191
511
|
\>
|
|
192
512
|
Other </IressRadio\>
|
|
@@ -197,22 +517,22 @@ Hide code
|
|
|
197
517
|
block </h3\>
|
|
198
518
|
<IressRadioGroup layout\="block"\>
|
|
199
519
|
<IressRadio
|
|
200
|
-
className\="ids-styles--add-border-
|
|
520
|
+
className\="ids-styles--add-border-v5203"
|
|
201
521
|
value\="google"
|
|
202
522
|
\>
|
|
203
523
|
Google </IressRadio\>
|
|
204
524
|
<IressRadio
|
|
205
|
-
className\="ids-styles--add-border-
|
|
525
|
+
className\="ids-styles--add-border-v5203"
|
|
206
526
|
value\="newspaper"
|
|
207
527
|
\>
|
|
208
528
|
Newspaper </IressRadio\>
|
|
209
529
|
<IressRadio
|
|
210
|
-
className\="ids-styles--add-border-
|
|
530
|
+
className\="ids-styles--add-border-v5203"
|
|
211
531
|
value\="friend"
|
|
212
532
|
\>
|
|
213
533
|
Friend </IressRadio\>
|
|
214
534
|
<IressRadio
|
|
215
|
-
className\="ids-styles--add-border-
|
|
535
|
+
className\="ids-styles--add-border-v5203"
|
|
216
536
|
value\="other"
|
|
217
537
|
\>
|
|
218
538
|
Other </IressRadio\>
|
|
@@ -223,22 +543,22 @@ Hide code
|
|
|
223
543
|
inline </h3\>
|
|
224
544
|
<IressRadioGroup layout\="inline"\>
|
|
225
545
|
<IressRadio
|
|
226
|
-
className\="ids-styles--add-border-
|
|
546
|
+
className\="ids-styles--add-border-v5203"
|
|
227
547
|
value\="google"
|
|
228
548
|
\>
|
|
229
549
|
Google </IressRadio\>
|
|
230
550
|
<IressRadio
|
|
231
|
-
className\="ids-styles--add-border-
|
|
551
|
+
className\="ids-styles--add-border-v5203"
|
|
232
552
|
value\="newspaper"
|
|
233
553
|
\>
|
|
234
554
|
Newspaper </IressRadio\>
|
|
235
555
|
<IressRadio
|
|
236
|
-
className\="ids-styles--add-border-
|
|
556
|
+
className\="ids-styles--add-border-v5203"
|
|
237
557
|
value\="friend"
|
|
238
558
|
\>
|
|
239
559
|
Friend </IressRadio\>
|
|
240
560
|
<IressRadio
|
|
241
|
-
className\="ids-styles--add-border-
|
|
561
|
+
className\="ids-styles--add-border-v5203"
|
|
242
562
|
value\="other"
|
|
243
563
|
\>
|
|
244
564
|
Other </IressRadio\>
|
|
@@ -249,22 +569,22 @@ Hide code
|
|
|
249
569
|
inlineFlex </h3\>
|
|
250
570
|
<IressRadioGroup layout\="inlineFlex"\>
|
|
251
571
|
<IressRadio
|
|
252
|
-
className\="ids-styles--add-border-
|
|
572
|
+
className\="ids-styles--add-border-v5203"
|
|
253
573
|
value\="google"
|
|
254
574
|
\>
|
|
255
575
|
Google </IressRadio\>
|
|
256
576
|
<IressRadio
|
|
257
|
-
className\="ids-styles--add-border-
|
|
577
|
+
className\="ids-styles--add-border-v5203"
|
|
258
578
|
value\="newspaper"
|
|
259
579
|
\>
|
|
260
580
|
Newspaper </IressRadio\>
|
|
261
581
|
<IressRadio
|
|
262
|
-
className\="ids-styles--add-border-
|
|
582
|
+
className\="ids-styles--add-border-v5203"
|
|
263
583
|
value\="friend"
|
|
264
584
|
\>
|
|
265
585
|
Friend </IressRadio\>
|
|
266
586
|
<IressRadio
|
|
267
|
-
className\="ids-styles--add-border-
|
|
587
|
+
className\="ids-styles--add-border-v5203"
|
|
268
588
|
value\="other"
|
|
269
589
|
\>
|
|
270
590
|
Other </IressRadio\>
|
|
@@ -275,22 +595,22 @@ Hide code
|
|
|
275
595
|
inlineEqualWidth </h3\>
|
|
276
596
|
<IressRadioGroup layout\="inlineEqualWidth"\>
|
|
277
597
|
<IressRadio
|
|
278
|
-
className\="ids-styles--add-border-
|
|
598
|
+
className\="ids-styles--add-border-v5203"
|
|
279
599
|
value\="google"
|
|
280
600
|
\>
|
|
281
601
|
Google </IressRadio\>
|
|
282
602
|
<IressRadio
|
|
283
|
-
className\="ids-styles--add-border-
|
|
603
|
+
className\="ids-styles--add-border-v5203"
|
|
284
604
|
value\="newspaper"
|
|
285
605
|
\>
|
|
286
606
|
Newspaper </IressRadio\>
|
|
287
607
|
<IressRadio
|
|
288
|
-
className\="ids-styles--add-border-
|
|
608
|
+
className\="ids-styles--add-border-v5203"
|
|
289
609
|
value\="friend"
|
|
290
610
|
\>
|
|
291
611
|
Friend </IressRadio\>
|
|
292
612
|
<IressRadio
|
|
293
|
-
className\="ids-styles--add-border-
|
|
613
|
+
className\="ids-styles--add-border-v5203"
|
|
294
614
|
value\="other"
|
|
295
615
|
\>
|
|
296
616
|
Other </IressRadio\>
|
|
@@ -298,14 +618,121 @@ Hide code
|
|
|
298
618
|
</div\>
|
|
299
619
|
</IressText\>
|
|
300
620
|
|
|
301
|
-
|
|
621
|
+
```
|
|
622
|
+
|
|
623
|
+
#### Props
|
|
624
|
+
|
|
625
|
+
IressRadioGroupIressRadio
|
|
626
|
+
|
|
627
|
+
| Name | Description | Default | Control |
|
|
628
|
+
| --- | --- | --- | --- |
|
|
629
|
+
| children |
|
|
630
|
+
Content of the radio group, usually multiple `IressRadio` components.
|
|
631
|
+
|
|
632
|
+
ReactNode
|
|
633
|
+
|
|
634
|
+
|
|
635
|
+
|
|
636
|
+
| \- | \- |
|
|
637
|
+
| defaultValue |
|
|
638
|
+
|
|
639
|
+
Initial value of radio group when in uncontrolled mode.
|
|
640
|
+
|
|
641
|
+
FormControlValue
|
|
642
|
+
|
|
643
|
+
|
|
644
|
+
|
|
645
|
+
| \- | Set object |
|
|
646
|
+
| hiddenRadio |
|
|
647
|
+
|
|
648
|
+
Hides the radio control to allow the creation of custom radio buttons.
|
|
649
|
+
|
|
650
|
+
boolean
|
|
651
|
+
|
|
652
|
+
|
|
653
|
+
|
|
654
|
+
| \- | Set boolean |
|
|
655
|
+
| layout |
|
|
656
|
+
|
|
657
|
+
Sets which of the block / inline layout options apply.
|
|
658
|
+
|
|
659
|
+
union
|
|
660
|
+
|
|
661
|
+
|
|
662
|
+
|
|
663
|
+
|
|
|
664
|
+
|
|
665
|
+
'stack'
|
|
666
|
+
|
|
667
|
+
| \- |
|
|
668
|
+
| name |
|
|
669
|
+
|
|
670
|
+
Name to be applied to all radios in the group.
|
|
671
|
+
|
|
672
|
+
string
|
|
673
|
+
|
|
674
|
+
|
|
302
675
|
|
|
303
|
-
|
|
676
|
+
| \- | Set string |
|
|
677
|
+
| onChange |
|
|
678
|
+
|
|
679
|
+
Called when a user selects one of its children radio buttons. If you pass in a non-string value, you can access it using the second parameter of the function.
|
|
680
|
+
|
|
681
|
+
( e: React.ChangeEvent<HTMLInputElement>, value?: FormControlValue, ) => void
|
|
682
|
+
|
|
683
|
+
| \- | \- |
|
|
684
|
+
| readonly |
|
|
685
|
+
|
|
686
|
+
Renders a readonly radio group.
|
|
687
|
+
|
|
688
|
+
boolean
|
|
689
|
+
|
|
690
|
+
|
|
691
|
+
|
|
692
|
+
| \- | Set boolean |
|
|
693
|
+
| required |
|
|
694
|
+
|
|
695
|
+
When true, marks the field as required
|
|
696
|
+
|
|
697
|
+
boolean
|
|
698
|
+
|
|
699
|
+
|
|
700
|
+
|
|
701
|
+
| \- | Set boolean |
|
|
702
|
+
| role |
|
|
703
|
+
|
|
704
|
+
|
|
|
705
|
+
|
|
706
|
+
'radiogroup'
|
|
707
|
+
|
|
708
|
+
| Set object |
|
|
709
|
+
| touch |
|
|
710
|
+
|
|
711
|
+
Add the button-like border and padding to radio when `touch` is true.
|
|
712
|
+
|
|
713
|
+
boolean
|
|
714
|
+
|
|
715
|
+
|
|
716
|
+
|
|
717
|
+
| \- | Set boolean |
|
|
718
|
+
| value |
|
|
719
|
+
|
|
720
|
+
Value of radio group when in controlled mode.
|
|
721
|
+
|
|
722
|
+
FormControlValue
|
|
723
|
+
|
|
724
|
+
|
|
725
|
+
|
|
726
|
+
| \- | Set object |
|
|
727
|
+
|
|
728
|
+
### Hidden radio buttons
|
|
304
729
|
|
|
305
730
|
You can use the `hiddenRadio` prop to create custom radio buttons. When enabled, the actual radio button will be visually hidden, allowing you to create more interesting controls. The checked state will be shown by the label's border, which is thicker when the radio button is checked.
|
|
306
731
|
|
|
307
732
|
When `hiddenRadio` is enabled, the label will have no padding. Padding can be added by using a Panel or utility classes.
|
|
308
733
|
|
|
734
|
+
[](./iframe.html?id=components-radiogroup--hidden-radio-buttons)
|
|
735
|
+
|
|
309
736
|
**I'd like to discuss the following in my financial review:
|
|
310
737
|
|
|
311
738
|
Select one option
|
|
@@ -318,9 +745,7 @@ Saving for a holiday
|
|
|
318
745
|
|
|
319
746
|
Reducing my debt
|
|
320
747
|
|
|
321
|
-
Hide
|
|
322
|
-
|
|
323
|
-
\[data-radix-scroll-area-viewport\] { scrollbar-width: none; -ms-overflow-style: none; -webkit-overflow-scrolling: touch; } \[data-radix-scroll-area-viewport\]::-webkit-scrollbar { display: none; } :where(\[data-radix-scroll-area-viewport\]) { display: flex; flex-direction: column; align-items: stretch; } :where(\[data-radix-scroll-area-content\]) { flex-grow: 1; }
|
|
748
|
+
Hide codedrawOpen in CodeSandbox
|
|
324
749
|
|
|
325
750
|
<IressField
|
|
326
751
|
hint\="Select one option"
|
|
@@ -392,14 +817,129 @@ Hide code
|
|
|
392
817
|
</IressRadioGroup\>
|
|
393
818
|
</IressField\>
|
|
394
819
|
|
|
395
|
-
|
|
820
|
+
```
|
|
396
821
|
|
|
397
|
-
|
|
822
|
+
#### Props
|
|
823
|
+
|
|
824
|
+
IressRadioGroupIressRadio
|
|
825
|
+
|
|
826
|
+
| Name | Description | Default | Control |
|
|
827
|
+
| --- | --- | --- | --- |
|
|
828
|
+
| children |
|
|
829
|
+
Content of the radio group, usually multiple `IressRadio` components.
|
|
830
|
+
|
|
831
|
+
ReactNode
|
|
832
|
+
|
|
833
|
+
|
|
834
|
+
|
|
835
|
+
| \- | \- |
|
|
836
|
+
| defaultValue |
|
|
837
|
+
|
|
838
|
+
Initial value of radio group when in uncontrolled mode.
|
|
839
|
+
|
|
840
|
+
FormControlValue
|
|
841
|
+
|
|
842
|
+
|
|
843
|
+
|
|
844
|
+
| \- |
|
|
845
|
+
|
|
846
|
+
"home"
|
|
847
|
+
|
|
848
|
+
|
|
|
849
|
+
| hiddenRadio |
|
|
850
|
+
|
|
851
|
+
Hides the radio control to allow the creation of custom radio buttons.
|
|
852
|
+
|
|
853
|
+
boolean
|
|
854
|
+
|
|
855
|
+
|
|
856
|
+
|
|
857
|
+
| \- | FalseTrue |
|
|
858
|
+
| layout |
|
|
859
|
+
|
|
860
|
+
Sets which of the block / inline layout options apply.
|
|
861
|
+
|
|
862
|
+
union
|
|
863
|
+
|
|
864
|
+
|
|
865
|
+
|
|
866
|
+
|
|
|
867
|
+
|
|
868
|
+
'stack'
|
|
869
|
+
|
|
870
|
+
|
|
|
871
|
+
|
|
872
|
+
"inline"
|
|
873
|
+
|
|
874
|
+
|
|
|
875
|
+
| name |
|
|
876
|
+
|
|
877
|
+
Name to be applied to all radios in the group.
|
|
878
|
+
|
|
879
|
+
string
|
|
880
|
+
|
|
881
|
+
|
|
882
|
+
|
|
883
|
+
| \- | Set string |
|
|
884
|
+
| onChange |
|
|
885
|
+
|
|
886
|
+
Called when a user selects one of its children radio buttons. If you pass in a non-string value, you can access it using the second parameter of the function.
|
|
887
|
+
|
|
888
|
+
( e: React.ChangeEvent<HTMLInputElement>, value?: FormControlValue, ) => void
|
|
889
|
+
|
|
890
|
+
| \- | \- |
|
|
891
|
+
| readonly |
|
|
892
|
+
|
|
893
|
+
Renders a readonly radio group.
|
|
894
|
+
|
|
895
|
+
boolean
|
|
896
|
+
|
|
897
|
+
|
|
898
|
+
|
|
899
|
+
| \- | Set boolean |
|
|
900
|
+
| required |
|
|
901
|
+
|
|
902
|
+
When true, marks the field as required
|
|
903
|
+
|
|
904
|
+
boolean
|
|
905
|
+
|
|
906
|
+
|
|
907
|
+
|
|
908
|
+
| \- | FalseTrue |
|
|
909
|
+
| role |
|
|
910
|
+
|
|
911
|
+
|
|
|
912
|
+
|
|
913
|
+
'radiogroup'
|
|
914
|
+
|
|
915
|
+
| Set object |
|
|
916
|
+
| touch |
|
|
917
|
+
|
|
918
|
+
Add the button-like border and padding to radio when `touch` is true.
|
|
919
|
+
|
|
920
|
+
boolean
|
|
921
|
+
|
|
922
|
+
|
|
923
|
+
|
|
924
|
+
| \- | Set boolean |
|
|
925
|
+
| value |
|
|
926
|
+
|
|
927
|
+
Value of radio group when in controlled mode.
|
|
928
|
+
|
|
929
|
+
FormControlValue
|
|
930
|
+
|
|
931
|
+
|
|
932
|
+
|
|
933
|
+
| \- | Set object |
|
|
934
|
+
|
|
935
|
+
### Laying out custom radio buttons
|
|
398
936
|
|
|
399
937
|
The radio group's `layout` prop gives you some default options to help control the layout of your controls. But sometimes you need more granular control, which you can achieve with a bit of custom CSS.
|
|
400
938
|
|
|
401
939
|
The example below uses CSS grid to give us evenly spaced / sized radio buttons, which will wrap on to new lines as the screen size reduces. The grid wrapper element is a div that wraps around the `<IressRadio />` elements, as shown by the dashed border. Use the grab handle in the bottom right-hand corner of the grid wrapper to see how the controls change size to respond to the container's width.
|
|
402
940
|
|
|
941
|
+
[](./iframe.html?id=components-radiogroup--custom-radio-group-layout)
|
|
942
|
+
|
|
403
943
|
**I'd like to discuss the following in my financial review:
|
|
404
944
|
|
|
405
945
|
Select one option
|
|
@@ -422,9 +962,7 @@ Reducing my debt
|
|
|
422
962
|
|
|
423
963
|
Starting a business
|
|
424
964
|
|
|
425
|
-
Hide
|
|
426
|
-
|
|
427
|
-
\[data-radix-scroll-area-viewport\] { scrollbar-width: none; -ms-overflow-style: none; -webkit-overflow-scrolling: touch; } \[data-radix-scroll-area-viewport\]::-webkit-scrollbar { display: none; } :where(\[data-radix-scroll-area-viewport\]) { display: flex; flex-direction: column; align-items: stretch; } :where(\[data-radix-scroll-area-content\]) { flex-grow: 1; }
|
|
965
|
+
Hide codedrawOpen in CodeSandbox
|
|
428
966
|
|
|
429
967
|
<IressField
|
|
430
968
|
hint\="Select one option"
|
|
@@ -441,7 +979,7 @@ Hide code
|
|
|
441
979
|
}}
|
|
442
980
|
\>
|
|
443
981
|
<div
|
|
444
|
-
className\="ids-styles--resizable-
|
|
982
|
+
className\="ids-styles--resizable-v5203"
|
|
445
983
|
style\={{
|
|
446
984
|
display: 'grid',
|
|
447
985
|
gridAutoRows: '1fr',
|
|
@@ -607,19 +1145,128 @@ Hide code
|
|
|
607
1145
|
</IressRadioGroup\>
|
|
608
1146
|
</IressField\>
|
|
609
1147
|
|
|
610
|
-
|
|
1148
|
+
```
|
|
1149
|
+
|
|
1150
|
+
#### Props
|
|
1151
|
+
|
|
1152
|
+
IressRadioGroupIressRadio
|
|
1153
|
+
|
|
1154
|
+
| Name | Description | Default | Control |
|
|
1155
|
+
| --- | --- | --- | --- |
|
|
1156
|
+
| children |
|
|
1157
|
+
Content of the radio group, usually multiple `IressRadio` components.
|
|
1158
|
+
|
|
1159
|
+
ReactNode
|
|
1160
|
+
|
|
1161
|
+
|
|
1162
|
+
|
|
1163
|
+
| \- | \- |
|
|
1164
|
+
| defaultValue |
|
|
1165
|
+
|
|
1166
|
+
Initial value of radio group when in uncontrolled mode.
|
|
1167
|
+
|
|
1168
|
+
FormControlValue
|
|
1169
|
+
|
|
1170
|
+
|
|
1171
|
+
|
|
1172
|
+
| \- | Set object |
|
|
1173
|
+
| hiddenRadio |
|
|
1174
|
+
|
|
1175
|
+
Hides the radio control to allow the creation of custom radio buttons.
|
|
1176
|
+
|
|
1177
|
+
boolean
|
|
1178
|
+
|
|
1179
|
+
|
|
1180
|
+
|
|
1181
|
+
| \- | FalseTrue |
|
|
1182
|
+
| layout |
|
|
1183
|
+
|
|
1184
|
+
Sets which of the block / inline layout options apply.
|
|
1185
|
+
|
|
1186
|
+
union
|
|
1187
|
+
|
|
1188
|
+
|
|
1189
|
+
|
|
1190
|
+
|
|
|
1191
|
+
|
|
1192
|
+
'stack'
|
|
1193
|
+
|
|
1194
|
+
|
|
|
1195
|
+
|
|
1196
|
+
"block"
|
|
1197
|
+
|
|
1198
|
+
|
|
|
1199
|
+
| name |
|
|
1200
|
+
|
|
1201
|
+
Name to be applied to all radios in the group.
|
|
1202
|
+
|
|
1203
|
+
string
|
|
1204
|
+
|
|
1205
|
+
|
|
1206
|
+
|
|
1207
|
+
| \- | financial-review |
|
|
1208
|
+
| onChange |
|
|
1209
|
+
|
|
1210
|
+
Called when a user selects one of its children radio buttons. If you pass in a non-string value, you can access it using the second parameter of the function.
|
|
1211
|
+
|
|
1212
|
+
( e: React.ChangeEvent<HTMLInputElement>, value?: FormControlValue, ) => void
|
|
1213
|
+
|
|
1214
|
+
| \- | \- |
|
|
1215
|
+
| readonly |
|
|
1216
|
+
|
|
1217
|
+
Renders a readonly radio group.
|
|
1218
|
+
|
|
1219
|
+
boolean
|
|
1220
|
+
|
|
1221
|
+
|
|
1222
|
+
|
|
1223
|
+
| \- | Set boolean |
|
|
1224
|
+
| required |
|
|
1225
|
+
|
|
1226
|
+
When true, marks the field as required
|
|
1227
|
+
|
|
1228
|
+
boolean
|
|
1229
|
+
|
|
1230
|
+
|
|
1231
|
+
|
|
1232
|
+
| \- | FalseTrue |
|
|
1233
|
+
| role |
|
|
1234
|
+
|
|
1235
|
+
|
|
|
1236
|
+
|
|
1237
|
+
'radiogroup'
|
|
1238
|
+
|
|
1239
|
+
| Set object |
|
|
1240
|
+
| touch |
|
|
1241
|
+
|
|
1242
|
+
Add the button-like border and padding to radio when `touch` is true.
|
|
1243
|
+
|
|
1244
|
+
boolean
|
|
1245
|
+
|
|
1246
|
+
|
|
1247
|
+
|
|
1248
|
+
| \- | Set boolean |
|
|
1249
|
+
| value |
|
|
1250
|
+
|
|
1251
|
+
Value of radio group when in controlled mode.
|
|
1252
|
+
|
|
1253
|
+
FormControlValue
|
|
1254
|
+
|
|
1255
|
+
|
|
611
1256
|
|
|
612
|
-
|
|
1257
|
+
| \- | Set object |
|
|
1258
|
+
|
|
1259
|
+
### Readonly
|
|
613
1260
|
|
|
614
1261
|
The `readonly` prop changes how the radio group is rendered. It will only render if the children radio that is checked (alongside a hidden input that contains the `value` if it was set), otherwise it will not be rendered.
|
|
615
1262
|
|
|
616
1263
|
It is understandable that this may not be the desired behavior for all use cases. If you need a radio group that is not editable, but still visible, simply do not set the `readonly` prop and set the `value` prop instead.
|
|
617
1264
|
|
|
618
|
-
|
|
1265
|
+
[](./iframe.html?id=components-radiogroup--readonly)
|
|
619
1266
|
|
|
620
|
-
|
|
1267
|
+
Newspaper
|
|
621
1268
|
|
|
622
|
-
|
|
1269
|
+
Hide codedrawOpen in CodeSandbox
|
|
623
1270
|
|
|
624
1271
|
<IressRadioGroup
|
|
625
1272
|
defaultValue\="newspaper"
|
|
@@ -635,12 +1282,123 @@ Hide code
|
|
|
635
1282
|
Other </IressRadio\>
|
|
636
1283
|
</IressRadioGroup\>
|
|
637
1284
|
|
|
638
|
-
|
|
1285
|
+
```
|
|
1286
|
+
|
|
1287
|
+
#### Props
|
|
1288
|
+
|
|
1289
|
+
IressRadioGroupIressRadio
|
|
1290
|
+
|
|
1291
|
+
| Name | Description | Default | Control |
|
|
1292
|
+
| --- | --- | --- | --- |
|
|
1293
|
+
| children |
|
|
1294
|
+
Content of the radio group, usually multiple `IressRadio` components.
|
|
1295
|
+
|
|
1296
|
+
ReactNode
|
|
1297
|
+
|
|
1298
|
+
|
|
1299
|
+
|
|
1300
|
+
| \- | \- |
|
|
1301
|
+
| defaultValue |
|
|
1302
|
+
|
|
1303
|
+
Initial value of radio group when in uncontrolled mode.
|
|
1304
|
+
|
|
1305
|
+
FormControlValue
|
|
1306
|
+
|
|
1307
|
+
|
|
1308
|
+
|
|
1309
|
+
| \- |
|
|
1310
|
+
|
|
1311
|
+
"newspaper"
|
|
1312
|
+
|
|
1313
|
+
|
|
|
1314
|
+
| hiddenRadio |
|
|
1315
|
+
|
|
1316
|
+
Hides the radio control to allow the creation of custom radio buttons.
|
|
1317
|
+
|
|
1318
|
+
boolean
|
|
1319
|
+
|
|
1320
|
+
|
|
1321
|
+
|
|
1322
|
+
| \- | Set boolean |
|
|
1323
|
+
| layout |
|
|
1324
|
+
|
|
1325
|
+
Sets which of the block / inline layout options apply.
|
|
1326
|
+
|
|
1327
|
+
union
|
|
1328
|
+
|
|
1329
|
+
|
|
1330
|
+
|
|
1331
|
+
|
|
|
1332
|
+
|
|
1333
|
+
'stack'
|
|
1334
|
+
|
|
1335
|
+
| Set object |
|
|
1336
|
+
| name |
|
|
1337
|
+
|
|
1338
|
+
Name to be applied to all radios in the group.
|
|
1339
|
+
|
|
1340
|
+
string
|
|
1341
|
+
|
|
1342
|
+
|
|
1343
|
+
|
|
1344
|
+
| \- | Set string |
|
|
1345
|
+
| onChange |
|
|
1346
|
+
|
|
1347
|
+
Called when a user selects one of its children radio buttons. If you pass in a non-string value, you can access it using the second parameter of the function.
|
|
1348
|
+
|
|
1349
|
+
( e: React.ChangeEvent<HTMLInputElement>, value?: FormControlValue, ) => void
|
|
1350
|
+
|
|
1351
|
+
| \- | \- |
|
|
1352
|
+
| readonly |
|
|
1353
|
+
|
|
1354
|
+
Renders a readonly radio group.
|
|
1355
|
+
|
|
1356
|
+
boolean
|
|
1357
|
+
|
|
1358
|
+
|
|
1359
|
+
|
|
1360
|
+
| \- | FalseTrue |
|
|
1361
|
+
| required |
|
|
1362
|
+
|
|
1363
|
+
When true, marks the field as required
|
|
1364
|
+
|
|
1365
|
+
boolean
|
|
1366
|
+
|
|
1367
|
+
|
|
1368
|
+
|
|
1369
|
+
| \- | Set boolean |
|
|
1370
|
+
| role |
|
|
1371
|
+
|
|
1372
|
+
|
|
|
1373
|
+
|
|
1374
|
+
'radiogroup'
|
|
1375
|
+
|
|
1376
|
+
| Set object |
|
|
1377
|
+
| touch |
|
|
1378
|
+
|
|
1379
|
+
Add the button-like border and padding to radio when `touch` is true.
|
|
1380
|
+
|
|
1381
|
+
boolean
|
|
1382
|
+
|
|
1383
|
+
|
|
1384
|
+
|
|
1385
|
+
| \- | Set boolean |
|
|
1386
|
+
| value |
|
|
1387
|
+
|
|
1388
|
+
Value of radio group when in controlled mode.
|
|
1389
|
+
|
|
1390
|
+
FormControlValue
|
|
1391
|
+
|
|
1392
|
+
|
|
639
1393
|
|
|
640
|
-
|
|
1394
|
+
| \- | Set object |
|
|
1395
|
+
|
|
1396
|
+
### Touch
|
|
641
1397
|
|
|
642
1398
|
The `touch` prop adds the button-like border and padding to radio.
|
|
643
1399
|
|
|
1400
|
+
[](./iframe.html?id=components-radiogroup--touch)
|
|
1401
|
+
|
|
644
1402
|
Google
|
|
645
1403
|
|
|
646
1404
|
Newspaper
|
|
@@ -649,9 +1407,7 @@ Friend
|
|
|
649
1407
|
|
|
650
1408
|
Other
|
|
651
1409
|
|
|
652
|
-
Hide
|
|
653
|
-
|
|
654
|
-
\[data-radix-scroll-area-viewport\] { scrollbar-width: none; -ms-overflow-style: none; -webkit-overflow-scrolling: touch; } \[data-radix-scroll-area-viewport\]::-webkit-scrollbar { display: none; } :where(\[data-radix-scroll-area-viewport\]) { display: flex; flex-direction: column; align-items: stretch; } :where(\[data-radix-scroll-area-content\]) { flex-grow: 1; }
|
|
1410
|
+
Hide codedrawOpen in CodeSandbox
|
|
655
1411
|
|
|
656
1412
|
<IressRadioGroup
|
|
657
1413
|
defaultValue\="newspaper"
|
|
@@ -667,17 +1423,113 @@ Hide code
|
|
|
667
1423
|
Other </IressRadio\>
|
|
668
1424
|
</IressRadioGroup\>
|
|
669
1425
|
|
|
670
|
-
|
|
1426
|
+
```
|
|
1427
|
+
|
|
1428
|
+
#### Props
|
|
1429
|
+
|
|
1430
|
+
IressRadioGroupIressRadio
|
|
1431
|
+
|
|
1432
|
+
| Name | Description | Default | Control |
|
|
1433
|
+
| --- | --- | --- | --- |
|
|
1434
|
+
| children |
|
|
1435
|
+
Content of the radio group, usually multiple `IressRadio` components.
|
|
1436
|
+
|
|
1437
|
+
ReactNode
|
|
1438
|
+
|
|
1439
|
+
|
|
1440
|
+
|
|
1441
|
+
| \- | \- |
|
|
1442
|
+
| defaultValue |
|
|
1443
|
+
|
|
1444
|
+
Initial value of radio group when in uncontrolled mode.
|
|
1445
|
+
|
|
1446
|
+
FormControlValue
|
|
1447
|
+
|
|
1448
|
+
|
|
1449
|
+
|
|
1450
|
+
| \- |
|
|
1451
|
+
|
|
1452
|
+
"newspaper"
|
|
1453
|
+
|
|
1454
|
+
|
|
|
1455
|
+
| hiddenRadio |
|
|
1456
|
+
|
|
1457
|
+
Hides the radio control to allow the creation of custom radio buttons.
|
|
1458
|
+
|
|
1459
|
+
boolean
|
|
1460
|
+
|
|
1461
|
+
|
|
1462
|
+
|
|
1463
|
+
| \- | Set boolean |
|
|
1464
|
+
| layout |
|
|
1465
|
+
|
|
1466
|
+
Sets which of the block / inline layout options apply.
|
|
1467
|
+
|
|
1468
|
+
union
|
|
1469
|
+
|
|
1470
|
+
|
|
1471
|
+
|
|
1472
|
+
|
|
|
1473
|
+
|
|
1474
|
+
'stack'
|
|
1475
|
+
|
|
1476
|
+
| Set object |
|
|
1477
|
+
| name |
|
|
1478
|
+
|
|
1479
|
+
Name to be applied to all radios in the group.
|
|
1480
|
+
|
|
1481
|
+
string
|
|
1482
|
+
|
|
1483
|
+
|
|
1484
|
+
|
|
1485
|
+
| \- | Set string |
|
|
1486
|
+
| onChange |
|
|
1487
|
+
|
|
1488
|
+
Called when a user selects one of its children radio buttons. If you pass in a non-string value, you can access it using the second parameter of the function.
|
|
1489
|
+
|
|
1490
|
+
( e: React.ChangeEvent<HTMLInputElement>, value?: FormControlValue, ) => void
|
|
1491
|
+
|
|
1492
|
+
| \- | \- |
|
|
1493
|
+
| readonly |
|
|
1494
|
+
|
|
1495
|
+
Renders a readonly radio group.
|
|
1496
|
+
|
|
1497
|
+
boolean
|
|
1498
|
+
|
|
1499
|
+
|
|
1500
|
+
|
|
1501
|
+
| \- | Set boolean |
|
|
1502
|
+
| required |
|
|
1503
|
+
|
|
1504
|
+
When true, marks the field as required
|
|
1505
|
+
|
|
1506
|
+
boolean
|
|
1507
|
+
|
|
1508
|
+
|
|
1509
|
+
|
|
1510
|
+
| \- | Set boolean |
|
|
1511
|
+
| role |
|
|
1512
|
+
|
|
1513
|
+
|
|
|
1514
|
+
|
|
1515
|
+
'radiogroup'
|
|
1516
|
+
|
|
1517
|
+
| Set object |
|
|
1518
|
+
| touch |
|
|
1519
|
+
|
|
1520
|
+
Add the button-like border and padding to radio when `touch` is true.
|
|
1521
|
+
|
|
1522
|
+
boolean
|
|
1523
|
+
|
|
1524
|
+
|
|
1525
|
+
|
|
1526
|
+
| \- | FalseTrue |
|
|
1527
|
+
| value |
|
|
1528
|
+
|
|
1529
|
+
Value of radio group when in controlled mode.
|
|
1530
|
+
|
|
1531
|
+
FormControlValue
|
|
1532
|
+
|
|
671
1533
|
|
|
672
|
-
On this page
|
|
673
1534
|
|
|
674
|
-
|
|
675
|
-
* [Props](#props)
|
|
676
|
-
* [Examples](#examples)
|
|
677
|
-
* [Radio children](#radio-children)
|
|
678
|
-
* [Radio selection](#radio-selection)
|
|
679
|
-
* [Layout](#layout)
|
|
680
|
-
* [Hidden radio buttons](#hidden-radio-buttons)
|
|
681
|
-
* [Laying out custom radio buttons](#laying-out-custom-radio-buttons)
|
|
682
|
-
* [Readonly](#readonly)
|
|
683
|
-
* [Touch](#touch)
|
|
1535
|
+
| \- | Set object |
|