@iress-oss/ids-mcp-server 6.0.0-alpha.0 → 6.0.0-alpha.1-canary-20251204014525-3f0dce4
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/dist/searchHandlers.test.js +8 -2
- package/dist/toolHandler.test.js +9 -9
- package/dist/utils.test.js +6 -2
- package/package.json +32 -30
- package/generated/docs/components-alert-docs.md +0 -702
- package/generated/docs/components-autocomplete-docs.md +0 -1433
- package/generated/docs/components-autocomplete-recipes-docs.md +0 -104
- package/generated/docs/components-badge-docs.md +0 -531
- package/generated/docs/components-button-docs.md +0 -1442
- package/generated/docs/components-buttongroup-docs.md +0 -748
- package/generated/docs/components-card-docs.md +0 -944
- package/generated/docs/components-checkbox-docs.md +0 -694
- package/generated/docs/components-checkboxgroup-docs.md +0 -1087
- package/generated/docs/components-checkboxgroup-recipes-docs.md +0 -119
- package/generated/docs/components-col-docs.md +0 -881
- package/generated/docs/components-container-docs.md +0 -123
- package/generated/docs/components-divider-docs.md +0 -576
- package/generated/docs/components-expander-docs.md +0 -594
- package/generated/docs/components-field-docs.md +0 -2007
- package/generated/docs/components-filter-docs.md +0 -1322
- package/generated/docs/components-hide-docs.md +0 -702
- package/generated/docs/components-icon-docs.md +0 -816
- package/generated/docs/components-image-docs.md +0 -493
- package/generated/docs/components-inline-docs.md +0 -2003
- package/generated/docs/components-input-docs.md +0 -867
- package/generated/docs/components-input-recipes-docs.md +0 -140
- package/generated/docs/components-inputcurrency-docs.md +0 -689
- package/generated/docs/components-inputcurrency-recipes-docs.md +0 -115
- package/generated/docs/components-introduction-docs.md +0 -450
- package/generated/docs/components-label-docs.md +0 -562
- package/generated/docs/components-link-docs.md +0 -586
- package/generated/docs/components-menu-docs.md +0 -1146
- package/generated/docs/components-menu-menuitem-docs.md +0 -739
- package/generated/docs/components-modal-docs.md +0 -1346
- package/generated/docs/components-panel-docs.md +0 -600
- package/generated/docs/components-placeholder-docs.md +0 -446
- package/generated/docs/components-popover-docs.md +0 -1529
- package/generated/docs/components-popover-recipes-docs.md +0 -211
- package/generated/docs/components-progress-docs.md +0 -568
- package/generated/docs/components-provider-docs.md +0 -160
- package/generated/docs/components-radio-docs.md +0 -563
- package/generated/docs/components-radiogroup-docs.md +0 -1153
- package/generated/docs/components-readonly-docs.md +0 -535
- package/generated/docs/components-richselect-docs.md +0 -5836
- package/generated/docs/components-row-docs.md +0 -2354
- package/generated/docs/components-select-docs.md +0 -940
- package/generated/docs/components-skeleton-docs.md +0 -597
- package/generated/docs/components-skeleton-recipes-docs.md +0 -76
- package/generated/docs/components-skiplink-docs.md +0 -587
- package/generated/docs/components-slideout-docs.md +0 -1036
- package/generated/docs/components-slider-docs.md +0 -828
- package/generated/docs/components-spinner-docs.md +0 -450
- package/generated/docs/components-stack-docs.md +0 -923
- package/generated/docs/components-table-ag-grid-docs.md +0 -1444
- package/generated/docs/components-table-docs.md +0 -2327
- package/generated/docs/components-tabset-docs.md +0 -768
- package/generated/docs/components-tabset-tab-docs.md +0 -550
- package/generated/docs/components-tag-docs.md +0 -548
- package/generated/docs/components-text-docs.md +0 -585
- package/generated/docs/components-toaster-docs.md +0 -755
- package/generated/docs/components-toggle-docs.md +0 -614
- package/generated/docs/components-tooltip-docs.md +0 -747
- package/generated/docs/components-validationmessage-docs.md +0 -1161
- package/generated/docs/contact-us-docs.md +0 -27
- package/generated/docs/extensions-editor-docs.md +0 -1181
- package/generated/docs/extensions-editor-recipes-docs.md +0 -89
- package/generated/docs/foundations-accessibility-docs.md +0 -40
- package/generated/docs/foundations-consistency-docs.md +0 -52
- package/generated/docs/foundations-content-docs.md +0 -23
- package/generated/docs/foundations-grid-docs.md +0 -74
- package/generated/docs/foundations-introduction-docs.md +0 -19
- package/generated/docs/foundations-principles-docs.md +0 -70
- package/generated/docs/foundations-responsive-breakpoints-docs.md +0 -193
- package/generated/docs/foundations-tokens-colour-docs.md +0 -564
- package/generated/docs/foundations-tokens-elevation-docs.md +0 -155
- package/generated/docs/foundations-tokens-introduction-docs.md +0 -190
- package/generated/docs/foundations-tokens-radius-docs.md +0 -71
- package/generated/docs/foundations-tokens-spacing-docs.md +0 -89
- package/generated/docs/foundations-tokens-typography-docs.md +0 -322
- package/generated/docs/foundations-user-experience-docs.md +0 -63
- package/generated/docs/foundations-visual-design-docs.md +0 -46
- package/generated/docs/foundations-z-index-stacking-docs.md +0 -31
- package/generated/docs/frequently-asked-questions-docs.md +0 -53
- package/generated/docs/get-started-develop-docs.md +0 -209
- package/generated/docs/get-started-using-storybook-docs.md +0 -68
- package/generated/docs/guidelines.md +0 -2054
- package/generated/docs/introduction-docs.md +0 -87
- package/generated/docs/news-version-6-docs.md +0 -93
- package/generated/docs/patterns-form-docs.md +0 -3902
- package/generated/docs/patterns-form-recipes-docs.md +0 -1370
- package/generated/docs/patterns-introduction-docs.md +0 -24
- package/generated/docs/patterns-loading-docs.md +0 -4043
- package/generated/docs/resources-code-katas-docs.md +0 -29
- package/generated/docs/resources-introduction-docs.md +0 -38
- package/generated/docs/resources-mcp-server-docs.md +0 -27
- package/generated/docs/resources-migration-guides-from-v4-to-v5-docs.md +0 -437
- package/generated/docs/styling-props-colour-docs.md +0 -172
- package/generated/docs/styling-props-elevation-docs.md +0 -88
- package/generated/docs/styling-props-radius-docs.md +0 -86
- package/generated/docs/styling-props-reference-docs.md +0 -160
- package/generated/docs/styling-props-screen-readers-docs.md +0 -71
- package/generated/docs/styling-props-sizing-docs.md +0 -627
- package/generated/docs/styling-props-spacing-docs.md +0 -2282
- package/generated/docs/styling-props-typography-docs.md +0 -121
- package/generated/docs/themes-available-themes-docs.md +0 -66
- package/generated/docs/themes-introduction-docs.md +0 -121
- package/generated/docs/versions-docs.md +0 -17
- /package/{LICENSE.txt → LICENSE} +0 -0
|
@@ -1,1087 +0,0 @@
|
|
|
1
|
-
[](#checkbox-group)Checkbox Group
|
|
2
|
-
=================================
|
|
3
|
-
|
|
4
|
-
Overview
|
|
5
|
-
--------
|
|
6
|
-
|
|
7
|
-
Checkbox groups allow users to make more than one choice in a set of related options.
|
|
8
|
-
|
|
9
|
-
* * *
|
|
10
|
-
|
|
11
|
-
Updated
|
|
12
|
-
|
|
13
|
-
**Recently updated**
|
|
14
|
-
|
|
15
|
-
This component has been recently updated with new props. The props have been marked as beta. Please tell us if there are any issues.
|
|
16
|
-
|
|
17
|
-
Lemon drizzle
|
|
18
|
-
|
|
19
|
-
Victoria Sponge
|
|
20
|
-
|
|
21
|
-
Carrot Cake
|
|
22
|
-
|
|
23
|
-
Hide code
|
|
24
|
-
|
|
25
|
-
\[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; }
|
|
26
|
-
|
|
27
|
-
<IressCheckboxGroup name\="let-them-eat-cake"\>
|
|
28
|
-
<IressCheckbox value\="lemon-drizzle"\>
|
|
29
|
-
Lemon drizzle </IressCheckbox\>
|
|
30
|
-
<IressCheckbox value\="victoria-sponge"\>
|
|
31
|
-
Victoria Sponge </IressCheckbox\>
|
|
32
|
-
<IressCheckbox value\="carrot-cake"\>
|
|
33
|
-
Carrot Cake </IressCheckbox\>
|
|
34
|
-
</IressCheckboxGroup\>
|
|
35
|
-
|
|
36
|
-
Copy
|
|
37
|
-
|
|
38
|
-
[](#props)Props
|
|
39
|
-
---------------
|
|
40
|
-
|
|
41
|
-
| Name | Description | Default | Control |
|
|
42
|
-
| --- | --- | --- | --- |
|
|
43
|
-
| bg |
|
|
44
|
-
**`bg`** sets the background color of an element using the `background-color` css property using the color tokens in the design system.
|
|
45
|
-
|
|
46
|
-
We recommend using the following token values for best background contrast:
|
|
47
|
-
|
|
48
|
-
* `colour.primary.fill` for primary backgrounds that need to stand out
|
|
49
|
-
* `colour.primary.surface` for primary backgrounds that need to be less prominent
|
|
50
|
-
* `colour.neutral.10` for the base background color, normally white in light mode or shade of grey in dark mode
|
|
51
|
-
* `colour.neutral.20` for a slightly darker background color, used in neutral state components
|
|
52
|
-
* `colour.system.danger.fill` for error backgrounds that need to stand out
|
|
53
|
-
* `colour.system.danger.surface` for error backgrounds that need to be less prominent
|
|
54
|
-
* `colour.system.success.fill` for success backgrounds that need to stand out
|
|
55
|
-
* `colour.system.success.surface` for success backgrounds that need to be less prominent
|
|
56
|
-
* `colour.system.warning.fill` for warning backgrounds that need to stand out
|
|
57
|
-
* `colour.system.warning.surface` for warning backgrounds that need to be less prominent
|
|
58
|
-
* `colour.system.info.fill` for info backgrounds that need to stand out
|
|
59
|
-
* `colour.system.info.surface` for info backgrounds that need to be less prominent
|
|
60
|
-
|
|
61
|
-
ResponsiveProp<ColorToken> | undefined
|
|
62
|
-
|
|
63
|
-
| \- | Set object |
|
|
64
|
-
| borderRadius |
|
|
65
|
-
|
|
66
|
-
The **`border-radius`** CSS property rounds the corners of an element's outer border edge using the radius tokens in the design system.
|
|
67
|
-
|
|
68
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
69
|
-
| --- | --- | --- | --- | --- |
|
|
70
|
-
| **4** | **4** | **5** | **12** | **9** |
|
|
71
|
-
| 1 _\-x-_ | | 3 _\-x-_ | | |
|
|
72
|
-
|
|
73
|
-
ResponsiveProp<RadiusToken> | undefined
|
|
74
|
-
|
|
75
|
-
| \- | Set object |
|
|
76
|
-
| children |
|
|
77
|
-
|
|
78
|
-
Content to be displayed inside the group, usually multiple `IressCheckbox`.
|
|
79
|
-
|
|
80
|
-
ReactNode
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
| \- | \- |
|
|
85
|
-
| defaultValue |
|
|
86
|
-
|
|
87
|
-
Value of checkbox group when in uncontrolled mode.
|
|
88
|
-
|
|
89
|
-
T | T\[\] | undefined
|
|
90
|
-
|
|
91
|
-
| \- | Set object |
|
|
92
|
-
| focusable |
|
|
93
|
-
|
|
94
|
-
The `focusable` prop is used to apply the focus elevation when focused. It can be set to `true` to apply focus styles on focus, or `'within'` to apply focus styles when the element or any of its children are focused.
|
|
95
|
-
|
|
96
|
-
"true""within"undefined
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
| \- | Set object |
|
|
101
|
-
| hiddenCheckbox |
|
|
102
|
-
|
|
103
|
-
Hides the checkbox controls to allow the creation of custom checkboxes.
|
|
104
|
-
|
|
105
|
-
booleanundefined
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
| \- | Set object |
|
|
110
|
-
| hide |
|
|
111
|
-
|
|
112
|
-
Set **`hide`** to hide an element completely using `display: none`. It can also be set to an object of breakpoints to hide the element at specific breakpoints.
|
|
113
|
-
|
|
114
|
-
Hide on all breakpoints: `hide: true` Hide on specific breakpoints: `hide: { xs: false, sm: true, md: false, lg: true, xl: false, xxl: true }`
|
|
115
|
-
|
|
116
|
-
Notes:
|
|
117
|
-
|
|
118
|
-
* If you need to hide an element but allow it to be visible to screen readers, use the `srOnly` prop instead.
|
|
119
|
-
* Consider if you can conditionally render the element instead of hiding it.
|
|
120
|
-
|
|
121
|
-
ResponsiveProp<boolean> | undefined
|
|
122
|
-
|
|
123
|
-
| \- | Set object |
|
|
124
|
-
| layerStyle |
|
|
125
|
-
|
|
126
|
-
Elevate a layer by using a **`layerStyle`**. These are connected to the elevation tokens in the design system. They can be combined to create hierarchy and structure.
|
|
127
|
-
|
|
128
|
-
* `elevation.raised`: Raised elevations sit slightly higher than other content. They are reserved for cards that can be moved, such as Jira issue cards and Trello cards. In special circumstances, they can be used for cards as a way to provide additional heirarchy or emphasis.
|
|
129
|
-
* `elevation.floating`: Floating is the highest elevation available. It is reserved for a UI that sits over another UI, such as modals, dialogs, dropdown menus, floating toolbars, and floating single-action buttons.
|
|
130
|
-
* `elevation.overflow`: Overflow is a shadow indicating content has scrolled outside a view. It can be used for vertical or horizontal scroll. An example of overflow shadows is the horizontal scroll in tables on a Confluence page.
|
|
131
|
-
|
|
132
|
-
ResponsiveProp<"elevation.raised" | "elevation.floating" | "elevation.overflow" | "elevation.focus" | "elevation.focusCompact"> | undefined
|
|
133
|
-
|
|
134
|
-
| \- | Set object |
|
|
135
|
-
| layout |
|
|
136
|
-
|
|
137
|
-
Sets which of the block / inline layout options apply.
|
|
138
|
-
|
|
139
|
-
"block""inline""stack"undefined
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
|
144
|
-
|
|
145
|
-
stack
|
|
146
|
-
|
|
147
|
-
| Set object |
|
|
148
|
-
| m |
|
|
149
|
-
|
|
150
|
-
The **`m`** property is short for `margin`, and sets the margin area on all four sides of an element.
|
|
151
|
-
|
|
152
|
-
It uses the spacing tokens in the design system. You can also use the negative values to overlap elements or ignore padding based on the design requirements.
|
|
153
|
-
|
|
154
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
155
|
-
| --- | --- | --- | --- | --- |
|
|
156
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
157
|
-
|
|
158
|
-
ResponsiveProp<SpacingToken | "auto"> | undefined
|
|
159
|
-
|
|
160
|
-
| \- | Set object |
|
|
161
|
-
| maxWidth |
|
|
162
|
-
|
|
163
|
-
The **`max-width`** CSS property sets the maximum width of an element. It prevents the used value of the `width` property from becoming larger than the value specified by `max-width`.
|
|
164
|
-
|
|
165
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
166
|
-
| --- | --- | --- | --- | --- |
|
|
167
|
-
| **1** | **1** | **1** | **12** | **7** |
|
|
168
|
-
|
|
169
|
-
ResponsiveProp<"auto" | SizeToken | "screen" | "1/2" | "1/3" | "2/3" | "1/4" | "2/4" | "3/4" | "1/5" | "2/5" | "3/5" | "4/5" | "1/6" | "2/6" | "3/6" | "4/6" | "5/6" | "1/12" | "2/12" | ... 8 more ... | "11/12"> | undefined
|
|
170
|
-
|
|
171
|
-
| \- | Set object |
|
|
172
|
-
| mb |
|
|
173
|
-
|
|
174
|
-
The **`mb`** property is short for `margin-bottom` and sets the margin area on the bottom side of an element. A positive value places it farther from its neighbors, while a negative value places it closer.
|
|
175
|
-
|
|
176
|
-
It uses the spacing tokens in the design system.
|
|
177
|
-
|
|
178
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
179
|
-
| --- | --- | --- | --- | --- |
|
|
180
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
181
|
-
|
|
182
|
-
ResponsiveProp<SpacingToken | "auto"> | undefined
|
|
183
|
-
|
|
184
|
-
| \- | Set object |
|
|
185
|
-
| ml |
|
|
186
|
-
|
|
187
|
-
The **`ml`** property is short for `margin-left` and sets the margin area on the left side of an element. A positive value places it farther from its neighbors, while a negative value places it closer.
|
|
188
|
-
|
|
189
|
-
It uses the spacing tokens in the design system.
|
|
190
|
-
|
|
191
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
192
|
-
| --- | --- | --- | --- | --- |
|
|
193
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
194
|
-
|
|
195
|
-
ResponsiveProp<SpacingToken | "auto"> | undefined
|
|
196
|
-
|
|
197
|
-
| \- | Set object |
|
|
198
|
-
| mr |
|
|
199
|
-
|
|
200
|
-
The **`mr`** property is short for `margin-right` and sets the margin area on the right side of an element. A positive value places it farther from its neighbors, while a negative value places it closer.
|
|
201
|
-
|
|
202
|
-
It uses the spacing tokens in the design system.
|
|
203
|
-
|
|
204
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
205
|
-
| --- | --- | --- | --- | --- |
|
|
206
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
207
|
-
|
|
208
|
-
ResponsiveProp<SpacingToken | "auto"> | undefined
|
|
209
|
-
|
|
210
|
-
| \- | Set object |
|
|
211
|
-
| mt |
|
|
212
|
-
|
|
213
|
-
The **`mt`** property is short for `margin-top` and sets the margin area on the top side of an element. A positive value places it farther from its neighbors, while a negative value places it closer.
|
|
214
|
-
|
|
215
|
-
It uses the spacing tokens in the design system.
|
|
216
|
-
|
|
217
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
218
|
-
| --- | --- | --- | --- | --- |
|
|
219
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
220
|
-
|
|
221
|
-
ResponsiveProp<SpacingToken | "auto"> | undefined
|
|
222
|
-
|
|
223
|
-
| \- | Set object |
|
|
224
|
-
| mx |
|
|
225
|
-
|
|
226
|
-
The **`mx`** property is short for `margin-inline`. It is a shorthand property that defines both the logical inline start and end margins of an element, which maps to physical margins depending on the element's writing mode, directionality, and text orientation.
|
|
227
|
-
|
|
228
|
-
It uses the spacing tokens in the design system. You can also use the negative values to overlap elements or ignore padding based on the design requirements.
|
|
229
|
-
|
|
230
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
231
|
-
| --- | --- | --- | --- | --- |
|
|
232
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
233
|
-
|
|
234
|
-
ResponsiveProp<SpacingToken | "auto"> | undefined
|
|
235
|
-
|
|
236
|
-
| \- | Set object |
|
|
237
|
-
| my |
|
|
238
|
-
|
|
239
|
-
The **`my`** property is short for `margin-block`. It defines the logical block start and end margins of an element, which maps to physical margins depending on the element's writing mode, directionality, and text orientation.
|
|
240
|
-
|
|
241
|
-
It uses the spacing tokens in the design system. You can also use the negative values to overlap elements or ignore padding based on the design requirements.
|
|
242
|
-
|
|
243
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
244
|
-
| --- | --- | --- | --- | --- |
|
|
245
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
246
|
-
|
|
247
|
-
ResponsiveProp<SpacingToken | "auto"> | undefined
|
|
248
|
-
|
|
249
|
-
| \- | Set object |
|
|
250
|
-
| name |
|
|
251
|
-
|
|
252
|
-
Name to be applied to all checkboxes in the group.
|
|
253
|
-
|
|
254
|
-
stringundefined
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
| \- |
|
|
259
|
-
|
|
260
|
-
"let-them-eat-cake"
|
|
261
|
-
|
|
262
|
-
|
|
|
263
|
-
| noGutter |
|
|
264
|
-
|
|
265
|
-
The **`noGutter`** property is used to remove the bottom margin from the last child of a component. This is useful when you want to avoid extra spacing at the end of a layout.
|
|
266
|
-
|
|
267
|
-
booleanundefined
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
| \- | Set object |
|
|
272
|
-
| onChange |
|
|
273
|
-
|
|
274
|
-
Called with collated new value when a user toggles one of its children checkboxes.
|
|
275
|
-
|
|
276
|
-
((value?: T\[\] | undefined) => void) | undefined
|
|
277
|
-
|
|
278
|
-
| \- | \- |
|
|
279
|
-
| p |
|
|
280
|
-
|
|
281
|
-
The **`p`** property is short for `padding`, and sets the padding area on all four sides of an element at once.
|
|
282
|
-
|
|
283
|
-
It uses the spacing tokens in the design system. Padding cannot use negative values, if you need to overlap elements or ignore padding, use the margin property instead.
|
|
284
|
-
|
|
285
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
286
|
-
| --- | --- | --- | --- | --- |
|
|
287
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
288
|
-
|
|
289
|
-
ResponsiveProp<"xs" | "sm" | "md" | "lg" | "xl" | "none" | "spacing.000" | "spacing.050" | "spacing.100" | "spacing.150" | "spacing.200" | "spacing.250" | "spacing.300" | "spacing.350" | ... 9 more ... | "slider.tick"> | undefined
|
|
290
|
-
|
|
291
|
-
| \- | Set object |
|
|
292
|
-
| pb |
|
|
293
|
-
|
|
294
|
-
The **`pb`** property is short for `padding-bottom` and sets the padding area on the bottom side of an element.
|
|
295
|
-
|
|
296
|
-
It uses the spacing tokens in the design system. Padding cannot use negative values, if you need to overlap elements or ignore padding, use the margin property instead.
|
|
297
|
-
|
|
298
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
299
|
-
| --- | --- | --- | --- | --- |
|
|
300
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
301
|
-
|
|
302
|
-
ResponsiveProp<"xs" | "sm" | "md" | "lg" | "xl" | "none" | "spacing.000" | "spacing.050" | "spacing.100" | "spacing.150" | "spacing.200" | "spacing.250" | "spacing.300" | "spacing.350" | ... 9 more ... | "slider.tick"> | undefined
|
|
303
|
-
|
|
304
|
-
| \- | Set object |
|
|
305
|
-
| pl |
|
|
306
|
-
|
|
307
|
-
The **`pl`** property is short for `padding-left` and sets the padding area on the left side of an element.
|
|
308
|
-
|
|
309
|
-
It uses the spacing tokens in the design system. Padding cannot use negative values, if you need to overlap elements or ignore padding, use the margin property instead.
|
|
310
|
-
|
|
311
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
312
|
-
| --- | --- | --- | --- | --- |
|
|
313
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
314
|
-
|
|
315
|
-
ResponsiveProp<"xs" | "sm" | "md" | "lg" | "xl" | "none" | "spacing.000" | "spacing.050" | "spacing.100" | "spacing.150" | "spacing.200" | "spacing.250" | "spacing.300" | "spacing.350" | ... 9 more ... | "slider.tick"> | undefined
|
|
316
|
-
|
|
317
|
-
| \- | Set object |
|
|
318
|
-
| pr |
|
|
319
|
-
|
|
320
|
-
The **`pr`** property is short for `padding-right` and sets the padding area on the right side of an element.
|
|
321
|
-
|
|
322
|
-
It uses the spacing tokens in the design system. Padding cannot use negative values, if you need to overlap elements or ignore padding, use the margin property instead.
|
|
323
|
-
|
|
324
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
325
|
-
| --- | --- | --- | --- | --- |
|
|
326
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
327
|
-
|
|
328
|
-
ResponsiveProp<"xs" | "sm" | "md" | "lg" | "xl" | "none" | "spacing.000" | "spacing.050" | "spacing.100" | "spacing.150" | "spacing.200" | "spacing.250" | "spacing.300" | "spacing.350" | ... 9 more ... | "slider.tick"> | undefined
|
|
329
|
-
|
|
330
|
-
| \- | Set object |
|
|
331
|
-
| pt |
|
|
332
|
-
|
|
333
|
-
The **`pt`** property is short for `padding-top` and sets the padding area on the top side of an element.
|
|
334
|
-
|
|
335
|
-
It uses the spacing tokens in the design system. Padding cannot use negative values, if you need to overlap elements or ignore padding, use the margin property instead.
|
|
336
|
-
|
|
337
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
338
|
-
| --- | --- | --- | --- | --- |
|
|
339
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
340
|
-
|
|
341
|
-
ResponsiveProp<"xs" | "sm" | "md" | "lg" | "xl" | "none" | "spacing.000" | "spacing.050" | "spacing.100" | "spacing.150" | "spacing.200" | "spacing.250" | "spacing.300" | "spacing.350" | ... 9 more ... | "slider.tick"> | undefined
|
|
342
|
-
|
|
343
|
-
| \- | Set object |
|
|
344
|
-
| px |
|
|
345
|
-
|
|
346
|
-
The **`px`** property is short for `padding-inline`. It is a shorthand property that defines both the logical inline start and end paddings of an element, which maps to physical paddings depending on the element's writing mode, directionality, and text orientation.
|
|
347
|
-
|
|
348
|
-
It uses the spacing tokens in the design system. Padding cannot use negative values, if you need to overlap elements or ignore padding, use the margin property instead.
|
|
349
|
-
|
|
350
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
351
|
-
| --- | --- | --- | --- | --- |
|
|
352
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
353
|
-
|
|
354
|
-
ResponsiveProp<"xs" | "sm" | "md" | "lg" | "xl" | "none" | "spacing.000" | "spacing.050" | "spacing.100" | "spacing.150" | "spacing.200" | "spacing.250" | "spacing.300" | "spacing.350" | ... 9 more ... | "slider.tick"> | undefined
|
|
355
|
-
|
|
356
|
-
| \- | Set object |
|
|
357
|
-
| py |
|
|
358
|
-
|
|
359
|
-
The **`py`** property is short for `padding-block`. It defines the logical block start and end paddings of an element, which maps to physical paddings depending on the element's writing mode, directionality, and text orientation.
|
|
360
|
-
|
|
361
|
-
It uses the spacing tokens in the design system. Padding cannot use negative values, if you need to overlap elements or ignore padding, use the margin property instead.
|
|
362
|
-
|
|
363
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
364
|
-
| --- | --- | --- | --- | --- |
|
|
365
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
366
|
-
|
|
367
|
-
ResponsiveProp<"xs" | "sm" | "md" | "lg" | "xl" | "none" | "spacing.000" | "spacing.050" | "spacing.100" | "spacing.150" | "spacing.200" | "spacing.250" | "spacing.300" | "spacing.350" | ... 9 more ... | "slider.tick"> | undefined
|
|
368
|
-
|
|
369
|
-
| \- | Set object |
|
|
370
|
-
| readOnly |
|
|
371
|
-
|
|
372
|
-
Renders the group in a read-only state.
|
|
373
|
-
|
|
374
|
-
booleanundefined
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
| \- | Set object |
|
|
379
|
-
| ref |
|
|
380
|
-
|
|
381
|
-
ForwardedRef<CheckboxGroupRef<T>> | undefined
|
|
382
|
-
|
|
383
|
-
| \- | Set object |
|
|
384
|
-
| rowGap |
|
|
385
|
-
|
|
386
|
-
The **`row-gap`** CSS property sets the size of the gap (gutter) between an element's rows.
|
|
387
|
-
|
|
388
|
-
Note: It only has an effect when used as a direct child of a layout component, such as IressRow, IressStack or IressInline.
|
|
389
|
-
|
|
390
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
391
|
-
| --- | --- | --- | --- | --- |
|
|
392
|
-
| **47** | **52** | **10.1** | **16** | No |
|
|
393
|
-
|
|
394
|
-
ResponsiveProp<"xs" | "sm" | "md" | "lg" | "xl" | "none" | "spacing.000" | "spacing.050" | "spacing.100" | "spacing.150" | "spacing.200" | "spacing.250" | "spacing.300" | "spacing.350" | ... 9 more ... | "slider.tick"> | undefined
|
|
395
|
-
|
|
396
|
-
| \- | Set object |
|
|
397
|
-
| srOnly |
|
|
398
|
-
|
|
399
|
-
Set **`srOnly`** to hide an element visually but still make it accessible to screen readers. It can also be set to an object of breakpoints to hide the element at specific breakpoints.
|
|
400
|
-
|
|
401
|
-
Hide on all breakpoints: `srOnly: true` Hide on specific breakpoints: `srOnly: { xs: false, sm: true, md: false, lg: true, xl: false, xxl: true }`
|
|
402
|
-
|
|
403
|
-
ResponsiveProp<boolean> | undefined
|
|
404
|
-
|
|
405
|
-
| \- | Set object |
|
|
406
|
-
| stretch |
|
|
407
|
-
|
|
408
|
-
The **`stretch`** property is used to stretch an element to fill the available space in its parent container. It sets the `height` property to `100%` and `alignSelf` to `stretch`, allowing the element to expand and contract based on the size of its parent.
|
|
409
|
-
|
|
410
|
-
booleanundefined
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
| \- | Set object |
|
|
415
|
-
| textAlign |
|
|
416
|
-
|
|
417
|
-
The **`text-align`** CSS property sets the horizontal alignment of the inline-level content inside a block element or table-cell box.
|
|
418
|
-
|
|
419
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
420
|
-
| --- | --- | --- | --- | --- |
|
|
421
|
-
| **1** | **1** | **1** | **12** | **3** |
|
|
422
|
-
|
|
423
|
-
ResponsiveProp<"center" | "left" | "right" | "inherit" | "justify"> | undefined
|
|
424
|
-
|
|
425
|
-
| \- | Set object |
|
|
426
|
-
| textStyle |
|
|
427
|
-
|
|
428
|
-
Select the typography to be used using the **`textStyle`** prop. These are connected to the typography tokens in the design system.'
|
|
429
|
-
|
|
430
|
-
* `typography.body.sm` - Use for small components such as badges and disclaimers, as well as compact variations of tables and lists.
|
|
431
|
-
* `typography.body.md` - The most commonly used body text size, used for most text content in the product and the default state of all components in the design system.
|
|
432
|
-
* `typography.body.lg` - Use for tag lines, subtitles, and other large text content in the product.
|
|
433
|
-
* `typography.heading.1` - Use for the main page title to establish a clear hierarchy. There is typically only one H1 per screen, emphasising the primary purpose or context of the page.
|
|
434
|
-
* `typography.heading.2` - Use for primary section headings within a page to organise content and guide the user through key areas. Also suitable for large components—such as modals—where space allows and where it pairs well with body.md or body.lg.
|
|
435
|
-
* `typography.heading.3` - Use for sub-sections under H2s to further structure content and maintain a clear visual hierarchy. Ideal for breaking down complex sections into manageable parts.
|
|
436
|
-
* `typography.heading.4` - Use for supporting headings within content blocks or small components where space is limited—such as table headers, cards, or side panels. Provides structure without overwhelming the layout.
|
|
437
|
-
* `typography.heading.5` - Use for minor labels or titles in compact UI elements, such as cards, sidebars, or inline labels. Best used to emphasise supplementary information without drawing too much attention. Works well with body.sm and is ideal for subtle content like fine print. Use sparingly to preserve typographic hierarchy.
|
|
438
|
-
* `typography.code` - Used to display code snippets in the product, such as in the API documentation.
|
|
439
|
-
|
|
440
|
-
ResponsiveProp<"typography.heading.1" | "typography.heading.2" | "typography.heading.3" | "typography.heading.4" | "typography.heading.5" | "typography.body.sm" | "typography.body.sm.regular" | ... 10 more ... | "typography.code"> | undefined
|
|
441
|
-
|
|
442
|
-
| \- | Set object |
|
|
443
|
-
| touch |
|
|
444
|
-
|
|
445
|
-
Add the button-like border and padding to checkbox when `touch` is true.
|
|
446
|
-
|
|
447
|
-
booleanundefined
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
| \- | Set object |
|
|
452
|
-
| value |
|
|
453
|
-
|
|
454
|
-
Value of checkbox group when in controlled mode.
|
|
455
|
-
|
|
456
|
-
T | T\[\] | undefined
|
|
457
|
-
|
|
458
|
-
| \- | Set object |
|
|
459
|
-
| width |
|
|
460
|
-
|
|
461
|
-
The **`width`** CSS property sets an element's width. By default, it sets the width of the content area, but if `box-sizing` is set to `border-box`, it sets the width of the border area.
|
|
462
|
-
|
|
463
|
-
This prop only allows widths available throughout the component library. To use a custom width, you need to use the `style` prop, or add a custom class to the element and use CSS.
|
|
464
|
-
|
|
465
|
-
| Chrome | Firefox | Safari | Edge | IE |
|
|
466
|
-
| --- | --- | --- | --- | --- |
|
|
467
|
-
| **1** | **1** | **1** | **12** | **4** |
|
|
468
|
-
|
|
469
|
-
ResponsiveProp<"auto" | SizeToken | "screen" | "1/2" | "1/3" | "2/3" | "1/4" | "2/4" | "3/4" | "1/5" | "2/5" | "3/5" | "4/5" | "1/6" | "2/6" | "3/6" | "4/6" | "5/6" | "1/12" | "2/12" | ... 8 more ... | "11/12"> | undefined
|
|
470
|
-
|
|
471
|
-
| \- | Set object |
|
|
472
|
-
|
|
473
|
-
[](#examples)Examples
|
|
474
|
-
---------------------
|
|
475
|
-
|
|
476
|
-
### [](#checkbox-children)Checkbox children
|
|
477
|
-
|
|
478
|
-
Individual checkboxes can be passed directly into `IressCheckboxGroup`.
|
|
479
|
-
|
|
480
|
-
**Note:** The `mapCheckboxGroupOptions` helper function, originally used to map options to `IressCheckbox` components, is now deprecated. Instead, you can use `array.map` to map the options to `IressCheckbox` components.
|
|
481
|
-
|
|
482
|
-
Lemon drizzle
|
|
483
|
-
|
|
484
|
-
Victoria Sponge
|
|
485
|
-
|
|
486
|
-
Carrot Cake
|
|
487
|
-
|
|
488
|
-
Hide code
|
|
489
|
-
|
|
490
|
-
\[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; }
|
|
491
|
-
|
|
492
|
-
<IressCheckboxGroup name\="let-them-eat-cake"\>
|
|
493
|
-
<IressCheckbox value\="lemon-drizzle"\>
|
|
494
|
-
Lemon drizzle </IressCheckbox\>
|
|
495
|
-
<IressCheckbox value\="victoria-sponge"\>
|
|
496
|
-
Victoria Sponge </IressCheckbox\>
|
|
497
|
-
<IressCheckbox value\="carrot-cake"\>
|
|
498
|
-
Carrot Cake </IressCheckbox\>
|
|
499
|
-
</IressCheckboxGroup\>
|
|
500
|
-
|
|
501
|
-
Copy
|
|
502
|
-
|
|
503
|
-
### [](#default-checked)Default checked
|
|
504
|
-
|
|
505
|
-
The default checked state of the checkbox children should always be set using the `defaultValue` prop (not directly on the checkbox component).
|
|
506
|
-
|
|
507
|
-
The `defaultValue` prop can contain an array of strings, numbers or booleans.
|
|
508
|
-
|
|
509
|
-
Lemon drizzle
|
|
510
|
-
|
|
511
|
-
Victoria Sponge
|
|
512
|
-
|
|
513
|
-
Carrot Cake
|
|
514
|
-
|
|
515
|
-
Hide code
|
|
516
|
-
|
|
517
|
-
\[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; }
|
|
518
|
-
|
|
519
|
-
<IressCheckboxGroup
|
|
520
|
-
defaultValue\={\[
|
|
521
|
-
'lemon-drizzle',
|
|
522
|
-
'victoria-sponge'
|
|
523
|
-
\]}
|
|
524
|
-
name\="let-them-eat-cake"
|
|
525
|
-
\>
|
|
526
|
-
<IressCheckbox value\="lemon-drizzle"\>
|
|
527
|
-
Lemon drizzle </IressCheckbox\>
|
|
528
|
-
<IressCheckbox value\="victoria-sponge"\>
|
|
529
|
-
Victoria Sponge </IressCheckbox\>
|
|
530
|
-
<IressCheckbox value\="carrot-cake"\>
|
|
531
|
-
Carrot Cake </IressCheckbox\>
|
|
532
|
-
</IressCheckboxGroup\>
|
|
533
|
-
|
|
534
|
-
Copy
|
|
535
|
-
|
|
536
|
-
### [](#changing-the-checked-state)Changing the checked state
|
|
537
|
-
|
|
538
|
-
The `value` prop can be updated if you need to change the checked state without interacting with the checkboxes.
|
|
539
|
-
|
|
540
|
-
For example, if you want to clear down the selected options:
|
|
541
|
-
|
|
542
|
-
Lemon drizzle
|
|
543
|
-
|
|
544
|
-
Victoria Sponge
|
|
545
|
-
|
|
546
|
-
Carrot Cake
|
|
547
|
-
|
|
548
|
-
Clear
|
|
549
|
-
|
|
550
|
-
Hide code
|
|
551
|
-
|
|
552
|
-
\[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; }
|
|
553
|
-
|
|
554
|
-
import {
|
|
555
|
-
FormControlValue,
|
|
556
|
-
IressButton,
|
|
557
|
-
IressCheckbox,
|
|
558
|
-
IressCheckboxGroup,
|
|
559
|
-
IressCheckboxGroupProps,
|
|
560
|
-
IressStack,
|
|
561
|
-
} from '@iress-oss/ids-components';
|
|
562
|
-
import { useState } from 'react';
|
|
563
|
-
export const CheckboxGroupUsingState \= <T \= FormControlValue,\>(
|
|
564
|
-
<T\>,
|
|
565
|
-
) => {
|
|
566
|
-
const \[value, setValue\] \= useState<T\[\]\>(\[\]);
|
|
567
|
-
return (
|
|
568
|
-
<IressStack gap\="sm"\>
|
|
569
|
-
<IressCheckboxGroup
|
|
570
|
-
{...{
|
|
571
|
-
name: 'let-them-eat-cake',
|
|
572
|
-
}}
|
|
573
|
-
value\={value}
|
|
574
|
-
onChange\={(newValue) \=> setValue(newValue ?? \[\])}
|
|
575
|
-
\>
|
|
576
|
-
<IressCheckbox value\="lemon-drizzle"\>Lemon drizzle</IressCheckbox\>
|
|
577
|
-
<IressCheckbox value\="victoria-sponge"\>Victoria Sponge</IressCheckbox\>
|
|
578
|
-
<IressCheckbox value\="carrot-cake"\>Carrot Cake</IressCheckbox\>
|
|
579
|
-
</IressCheckboxGroup\>
|
|
580
|
-
<IressButton onClick\={() \=> setValue(\[\])}\>Clear</IressButton\>
|
|
581
|
-
</IressStack\>
|
|
582
|
-
);
|
|
583
|
-
};
|
|
584
|
-
|
|
585
|
-
Copy
|
|
586
|
-
|
|
587
|
-
### [](#layout)Layout
|
|
588
|
-
|
|
589
|
-
The `layout` prop controls how the checkbox group is displayed and can have three basic layouts:
|
|
590
|
-
|
|
591
|
-
* **Stack (Default):** Checkboxes are laid out vertically. Labels are only as wide as their text.
|
|
592
|
-
* **Block:** Same as Stack, but labels take up the full width of the container.
|
|
593
|
-
* **Inline:** Checkboxes are laid out horizontally. Labels are only as wide as their text.
|
|
594
|
-
|
|
595
|
-
### block
|
|
596
|
-
|
|
597
|
-
Google
|
|
598
|
-
|
|
599
|
-
Newspaper
|
|
600
|
-
|
|
601
|
-
Friend
|
|
602
|
-
|
|
603
|
-
Other
|
|
604
|
-
|
|
605
|
-
### inline
|
|
606
|
-
|
|
607
|
-
Google
|
|
608
|
-
|
|
609
|
-
Newspaper
|
|
610
|
-
|
|
611
|
-
Friend
|
|
612
|
-
|
|
613
|
-
Other
|
|
614
|
-
|
|
615
|
-
### stack
|
|
616
|
-
|
|
617
|
-
Google
|
|
618
|
-
|
|
619
|
-
Newspaper
|
|
620
|
-
|
|
621
|
-
Friend
|
|
622
|
-
|
|
623
|
-
Other
|
|
624
|
-
|
|
625
|
-
Hide code
|
|
626
|
-
|
|
627
|
-
\[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; }
|
|
628
|
-
|
|
629
|
-
<IressText\>
|
|
630
|
-
<h3\>
|
|
631
|
-
block </h3\>
|
|
632
|
-
<IressCheckboxGroup layout\="block"\>
|
|
633
|
-
<IressCheckbox
|
|
634
|
-
className\="\_addBorderToLabel\_1d00u\_74"
|
|
635
|
-
value\="google"
|
|
636
|
-
\>
|
|
637
|
-
Google </IressCheckbox\>
|
|
638
|
-
<IressCheckbox
|
|
639
|
-
className\="\_addBorderToLabel\_1d00u\_74"
|
|
640
|
-
value\="newspaper"
|
|
641
|
-
\>
|
|
642
|
-
Newspaper </IressCheckbox\>
|
|
643
|
-
<IressCheckbox
|
|
644
|
-
className\="\_addBorderToLabel\_1d00u\_74"
|
|
645
|
-
value\="friend"
|
|
646
|
-
\>
|
|
647
|
-
Friend </IressCheckbox\>
|
|
648
|
-
<IressCheckbox
|
|
649
|
-
className\="\_addBorderToLabel\_1d00u\_74"
|
|
650
|
-
value\="other"
|
|
651
|
-
\>
|
|
652
|
-
Other </IressCheckbox\>
|
|
653
|
-
</IressCheckboxGroup\>
|
|
654
|
-
<h3\>
|
|
655
|
-
inline </h3\>
|
|
656
|
-
<IressCheckboxGroup layout\="inline"\>
|
|
657
|
-
<IressCheckbox
|
|
658
|
-
className\="\_addBorderToLabel\_1d00u\_74"
|
|
659
|
-
value\="google"
|
|
660
|
-
\>
|
|
661
|
-
Google </IressCheckbox\>
|
|
662
|
-
<IressCheckbox
|
|
663
|
-
className\="\_addBorderToLabel\_1d00u\_74"
|
|
664
|
-
value\="newspaper"
|
|
665
|
-
\>
|
|
666
|
-
Newspaper </IressCheckbox\>
|
|
667
|
-
<IressCheckbox
|
|
668
|
-
className\="\_addBorderToLabel\_1d00u\_74"
|
|
669
|
-
value\="friend"
|
|
670
|
-
\>
|
|
671
|
-
Friend </IressCheckbox\>
|
|
672
|
-
<IressCheckbox
|
|
673
|
-
className\="\_addBorderToLabel\_1d00u\_74"
|
|
674
|
-
value\="other"
|
|
675
|
-
\>
|
|
676
|
-
Other </IressCheckbox\>
|
|
677
|
-
</IressCheckboxGroup\>
|
|
678
|
-
<h3\>
|
|
679
|
-
stack </h3\>
|
|
680
|
-
<IressCheckboxGroup layout\="stack"\>
|
|
681
|
-
<IressCheckbox
|
|
682
|
-
className\="\_addBorderToLabel\_1d00u\_74"
|
|
683
|
-
value\="google"
|
|
684
|
-
\>
|
|
685
|
-
Google </IressCheckbox\>
|
|
686
|
-
<IressCheckbox
|
|
687
|
-
className\="\_addBorderToLabel\_1d00u\_74"
|
|
688
|
-
value\="newspaper"
|
|
689
|
-
\>
|
|
690
|
-
Newspaper </IressCheckbox\>
|
|
691
|
-
<IressCheckbox
|
|
692
|
-
className\="\_addBorderToLabel\_1d00u\_74"
|
|
693
|
-
value\="friend"
|
|
694
|
-
\>
|
|
695
|
-
Friend </IressCheckbox\>
|
|
696
|
-
<IressCheckbox
|
|
697
|
-
className\="\_addBorderToLabel\_1d00u\_74"
|
|
698
|
-
value\="other"
|
|
699
|
-
\>
|
|
700
|
-
Other </IressCheckbox\>
|
|
701
|
-
</IressCheckboxGroup\>
|
|
702
|
-
</IressText\>
|
|
703
|
-
|
|
704
|
-
Copy
|
|
705
|
-
|
|
706
|
-
### [](#hidden-checkboxes)Hidden checkboxes
|
|
707
|
-
|
|
708
|
-
You can use the `hiddenCheckbox` prop to create custom checkboxes. When enabled, the actual checkbox 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 checkbox is checked.
|
|
709
|
-
|
|
710
|
-
When `hiddenCheckbox` is enabled, the label will have no padding. Padding can be added by using an `IressPanel`.
|
|
711
|
-
|
|
712
|
-
**I'd like to discuss the following with my financial adviser:**
|
|
713
|
-
|
|
714
|
-
Select all that apply
|
|
715
|
-
|
|
716
|
-
Buying my first home
|
|
717
|
-
|
|
718
|
-
Saving for a holiday
|
|
719
|
-
|
|
720
|
-
Reducing my debt
|
|
721
|
-
|
|
722
|
-
Hide code
|
|
723
|
-
|
|
724
|
-
\[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; }
|
|
725
|
-
|
|
726
|
-
<IressField
|
|
727
|
-
hint\="Select all that apply"
|
|
728
|
-
label\="I'd like to discuss the following with my financial adviser:"
|
|
729
|
-
\>
|
|
730
|
-
<IressCheckboxGroup
|
|
731
|
-
defaultValue\={\[
|
|
732
|
-
'home'
|
|
733
|
-
\]}
|
|
734
|
-
hiddenCheckbox
|
|
735
|
-
layout\="inline"
|
|
736
|
-
name\="financial-review"
|
|
737
|
-
\>
|
|
738
|
-
<IressCheckbox value\="home"\>
|
|
739
|
-
<IressPanel
|
|
740
|
-
bg\="transparent"
|
|
741
|
-
p\="lg"
|
|
742
|
-
textAlign\="center"
|
|
743
|
-
\>
|
|
744
|
-
<IressStack gap\="md"\>
|
|
745
|
-
<IressIcon
|
|
746
|
-
name\="house"
|
|
747
|
-
textStyle\="typography.heading.1"
|
|
748
|
-
/>
|
|
749
|
-
<IressText
|
|
750
|
-
noGutter
|
|
751
|
-
textStyle\="typography.heading.4"
|
|
752
|
-
\>
|
|
753
|
-
Buying my first home </IressText\>
|
|
754
|
-
</IressStack\>
|
|
755
|
-
</IressPanel\>
|
|
756
|
-
</IressCheckbox\>
|
|
757
|
-
<IressCheckbox value\="holiday"\>
|
|
758
|
-
<IressPanel
|
|
759
|
-
bg\="transparent"
|
|
760
|
-
p\="lg"
|
|
761
|
-
textAlign\="center"
|
|
762
|
-
\>
|
|
763
|
-
<IressStack gap\="md"\>
|
|
764
|
-
<IressIcon
|
|
765
|
-
name\="mountain"
|
|
766
|
-
textStyle\="typography.heading.1"
|
|
767
|
-
/>
|
|
768
|
-
<IressText
|
|
769
|
-
noGutter
|
|
770
|
-
textStyle\="typography.heading.4"
|
|
771
|
-
\>
|
|
772
|
-
Saving for a holiday </IressText\>
|
|
773
|
-
</IressStack\>
|
|
774
|
-
</IressPanel\>
|
|
775
|
-
</IressCheckbox\>
|
|
776
|
-
<IressCheckbox value\="debt"\>
|
|
777
|
-
<IressPanel
|
|
778
|
-
bg\="transparent"
|
|
779
|
-
p\="lg"
|
|
780
|
-
textAlign\="center"
|
|
781
|
-
\>
|
|
782
|
-
<IressStack gap\="md"\>
|
|
783
|
-
<IressIcon
|
|
784
|
-
name\="credit-card"
|
|
785
|
-
textStyle\="typography.heading.1"
|
|
786
|
-
/>
|
|
787
|
-
<IressText
|
|
788
|
-
noGutter
|
|
789
|
-
textStyle\="typography.heading.4"
|
|
790
|
-
\>
|
|
791
|
-
Reducing my debt </IressText\>
|
|
792
|
-
</IressStack\>
|
|
793
|
-
</IressPanel\>
|
|
794
|
-
</IressCheckbox\>
|
|
795
|
-
</IressCheckboxGroup\>
|
|
796
|
-
</IressField\>
|
|
797
|
-
|
|
798
|
-
Copy
|
|
799
|
-
|
|
800
|
-
### [](#laying-out-custom-checkboxes)Laying out custom checkboxes
|
|
801
|
-
|
|
802
|
-
The checkbox 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.
|
|
803
|
-
|
|
804
|
-
The example below uses CSS grid to give us evenly spaced / sized checkboxes, which will wrap on to new lines as the screen size reduces. The grid wrapper element is a div that wraps around the `<IressCheckbox>` 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.
|
|
805
|
-
|
|
806
|
-
**I'd like to discuss the following with my financial adviser:**
|
|
807
|
-
|
|
808
|
-
Select all that apply
|
|
809
|
-
|
|
810
|
-
Retirement
|
|
811
|
-
|
|
812
|
-
Buying my first home
|
|
813
|
-
|
|
814
|
-
Saving for a holiday
|
|
815
|
-
|
|
816
|
-
Saving for my child's education
|
|
817
|
-
|
|
818
|
-
Saving for emergency
|
|
819
|
-
|
|
820
|
-
Spending more time on my hobbies
|
|
821
|
-
|
|
822
|
-
Reducing my debt
|
|
823
|
-
|
|
824
|
-
Starting a business
|
|
825
|
-
|
|
826
|
-
Hide code
|
|
827
|
-
|
|
828
|
-
\[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; }
|
|
829
|
-
|
|
830
|
-
<IressField
|
|
831
|
-
hint\="Select all that apply"
|
|
832
|
-
label\="I'd like to discuss the following with my financial adviser:"
|
|
833
|
-
\>
|
|
834
|
-
<IressCheckboxGroup
|
|
835
|
-
defaultValue\={\[
|
|
836
|
-
'home'
|
|
837
|
-
\]}
|
|
838
|
-
hiddenCheckbox
|
|
839
|
-
layout\="block"
|
|
840
|
-
name\="financial-review"
|
|
841
|
-
\>
|
|
842
|
-
<div
|
|
843
|
-
className\="\_resizable\_1d00u\_78"
|
|
844
|
-
style\={{
|
|
845
|
-
display: 'grid',
|
|
846
|
-
gridAutoRows: '1fr',
|
|
847
|
-
gridGap: '16px',
|
|
848
|
-
gridTemplateColumns: 'repeat(auto-fit, minmax(240px, 1fr))',
|
|
849
|
-
padding: '0.5rem',
|
|
850
|
-
width: '100%'
|
|
851
|
-
}}
|
|
852
|
-
\>
|
|
853
|
-
<IressCheckbox value\="retirement"\>
|
|
854
|
-
<IressPanel
|
|
855
|
-
bg\="transparent"
|
|
856
|
-
p\="lg"
|
|
857
|
-
textAlign\="center"
|
|
858
|
-
\>
|
|
859
|
-
<IressStack gap\="md"\>
|
|
860
|
-
<IressIcon
|
|
861
|
-
name\="tree-palm"
|
|
862
|
-
textStyle\="typography.heading.1"
|
|
863
|
-
/>
|
|
864
|
-
<IressText
|
|
865
|
-
noGutter
|
|
866
|
-
textStyle\="typography.heading.4"
|
|
867
|
-
\>
|
|
868
|
-
Retirement </IressText\>
|
|
869
|
-
</IressStack\>
|
|
870
|
-
</IressPanel\>
|
|
871
|
-
</IressCheckbox\>
|
|
872
|
-
<IressCheckbox value\="home"\>
|
|
873
|
-
<IressPanel
|
|
874
|
-
bg\="transparent"
|
|
875
|
-
p\="lg"
|
|
876
|
-
textAlign\="center"
|
|
877
|
-
\>
|
|
878
|
-
<IressStack gap\="md"\>
|
|
879
|
-
<IressIcon
|
|
880
|
-
name\="house"
|
|
881
|
-
textStyle\="typography.heading.1"
|
|
882
|
-
/>
|
|
883
|
-
<IressText
|
|
884
|
-
noGutter
|
|
885
|
-
textStyle\="typography.heading.4"
|
|
886
|
-
\>
|
|
887
|
-
Buying my first home </IressText\>
|
|
888
|
-
</IressStack\>
|
|
889
|
-
</IressPanel\>
|
|
890
|
-
</IressCheckbox\>
|
|
891
|
-
<IressCheckbox value\="holiday"\>
|
|
892
|
-
<IressPanel
|
|
893
|
-
bg\="transparent"
|
|
894
|
-
p\="lg"
|
|
895
|
-
textAlign\="center"
|
|
896
|
-
\>
|
|
897
|
-
<IressStack gap\="md"\>
|
|
898
|
-
<IressIcon
|
|
899
|
-
name\="mountain"
|
|
900
|
-
textStyle\="typography.heading.1"
|
|
901
|
-
/>
|
|
902
|
-
<IressText
|
|
903
|
-
noGutter
|
|
904
|
-
textStyle\="typography.heading.4"
|
|
905
|
-
\>
|
|
906
|
-
Saving for a holiday </IressText\>
|
|
907
|
-
</IressStack\>
|
|
908
|
-
</IressPanel\>
|
|
909
|
-
</IressCheckbox\>
|
|
910
|
-
<IressCheckbox value\="education"\>
|
|
911
|
-
<IressPanel
|
|
912
|
-
bg\="transparent"
|
|
913
|
-
p\="lg"
|
|
914
|
-
textAlign\="center"
|
|
915
|
-
\>
|
|
916
|
-
<IressStack gap\="md"\>
|
|
917
|
-
<IressIcon
|
|
918
|
-
name\="graduation-cap"
|
|
919
|
-
textStyle\="typography.heading.1"
|
|
920
|
-
/>
|
|
921
|
-
<IressText
|
|
922
|
-
noGutter
|
|
923
|
-
textStyle\="typography.heading.4"
|
|
924
|
-
\>
|
|
925
|
-
Saving for my child's education </IressText\>
|
|
926
|
-
</IressStack\>
|
|
927
|
-
</IressPanel\>
|
|
928
|
-
</IressCheckbox\>
|
|
929
|
-
<IressCheckbox value\="emergency"\>
|
|
930
|
-
<IressPanel
|
|
931
|
-
bg\="transparent"
|
|
932
|
-
p\="lg"
|
|
933
|
-
textAlign\="center"
|
|
934
|
-
\>
|
|
935
|
-
<IressStack gap\="md"\>
|
|
936
|
-
<IressIcon
|
|
937
|
-
name\="medkit"
|
|
938
|
-
textStyle\="typography.heading.1"
|
|
939
|
-
/>
|
|
940
|
-
<IressText
|
|
941
|
-
noGutter
|
|
942
|
-
textStyle\="typography.heading.4"
|
|
943
|
-
\>
|
|
944
|
-
Saving for emergency </IressText\>
|
|
945
|
-
</IressStack\>
|
|
946
|
-
</IressPanel\>
|
|
947
|
-
</IressCheckbox\>
|
|
948
|
-
<IressCheckbox value\="hobby"\>
|
|
949
|
-
<IressPanel
|
|
950
|
-
bg\="transparent"
|
|
951
|
-
p\="lg"
|
|
952
|
-
textAlign\="center"
|
|
953
|
-
\>
|
|
954
|
-
<IressStack gap\="md"\>
|
|
955
|
-
<IressIcon
|
|
956
|
-
name\="bicycle"
|
|
957
|
-
textStyle\="typography.heading.1"
|
|
958
|
-
/>
|
|
959
|
-
<IressText
|
|
960
|
-
noGutter
|
|
961
|
-
textStyle\="typography.heading.4"
|
|
962
|
-
\>
|
|
963
|
-
Spending more time on my hobbies </IressText\>
|
|
964
|
-
</IressStack\>
|
|
965
|
-
</IressPanel\>
|
|
966
|
-
</IressCheckbox\>
|
|
967
|
-
<IressCheckbox value\="debt"\>
|
|
968
|
-
<IressPanel
|
|
969
|
-
bg\="transparent"
|
|
970
|
-
p\="lg"
|
|
971
|
-
textAlign\="center"
|
|
972
|
-
\>
|
|
973
|
-
<IressStack gap\="md"\>
|
|
974
|
-
<IressIcon
|
|
975
|
-
name\="chart-line-down"
|
|
976
|
-
textStyle\="typography.heading.1"
|
|
977
|
-
/>
|
|
978
|
-
<IressText
|
|
979
|
-
noGutter
|
|
980
|
-
textStyle\="typography.heading.4"
|
|
981
|
-
\>
|
|
982
|
-
Reducing my debt </IressText\>
|
|
983
|
-
</IressStack\>
|
|
984
|
-
</IressPanel\>
|
|
985
|
-
</IressCheckbox\>
|
|
986
|
-
<IressCheckbox value\="business"\>
|
|
987
|
-
<IressPanel
|
|
988
|
-
bg\="transparent"
|
|
989
|
-
p\="lg"
|
|
990
|
-
textAlign\="center"
|
|
991
|
-
\>
|
|
992
|
-
<IressStack gap\="md"\>
|
|
993
|
-
<IressIcon
|
|
994
|
-
name\="user-tie"
|
|
995
|
-
textStyle\="typography.heading.1"
|
|
996
|
-
/>
|
|
997
|
-
<IressText
|
|
998
|
-
noGutter
|
|
999
|
-
textStyle\="typography.heading.4"
|
|
1000
|
-
\>
|
|
1001
|
-
Starting a business </IressText\>
|
|
1002
|
-
</IressStack\>
|
|
1003
|
-
</IressPanel\>
|
|
1004
|
-
</IressCheckbox\>
|
|
1005
|
-
</div\>
|
|
1006
|
-
</IressCheckboxGroup\>
|
|
1007
|
-
</IressField\>
|
|
1008
|
-
|
|
1009
|
-
Copy
|
|
1010
|
-
|
|
1011
|
-
### [](#read-only)Read only
|
|
1012
|
-
|
|
1013
|
-
The `readOnly` prop changes how the checkbox group is rendered. It will only render the children that are checked (alongside a hidden input that contains the `value` if it was set), otherwise it not be rendered.
|
|
1014
|
-
|
|
1015
|
-
It is understandable that this may not be the desired behavior for all use cases. If you need a checkbox group that is not editable, but still visible, simply do not set the `readOnly` prop and set the `value` prop instead.
|
|
1016
|
-
|
|
1017
|
-
Lemon drizzle
|
|
1018
|
-
|
|
1019
|
-
Victoria Sponge
|
|
1020
|
-
|
|
1021
|
-
Hide code
|
|
1022
|
-
|
|
1023
|
-
\[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; }
|
|
1024
|
-
|
|
1025
|
-
<IressCheckboxGroup
|
|
1026
|
-
defaultValue\={\[
|
|
1027
|
-
'lemon-drizzle',
|
|
1028
|
-
'victoria-sponge'
|
|
1029
|
-
\]}
|
|
1030
|
-
name\="let-them-eat-cake"
|
|
1031
|
-
readOnly
|
|
1032
|
-
\>
|
|
1033
|
-
<IressCheckbox value\="lemon-drizzle"\>
|
|
1034
|
-
Lemon drizzle </IressCheckbox\>
|
|
1035
|
-
<IressCheckbox value\="victoria-sponge"\>
|
|
1036
|
-
Victoria Sponge </IressCheckbox\>
|
|
1037
|
-
<IressCheckbox value\="carrot-cake"\>
|
|
1038
|
-
Carrot Cake </IressCheckbox\>
|
|
1039
|
-
</IressCheckboxGroup\>
|
|
1040
|
-
|
|
1041
|
-
Copy
|
|
1042
|
-
|
|
1043
|
-
### [](#touch)Touch
|
|
1044
|
-
|
|
1045
|
-
The `touch` prop adds the button-like border and padding to checkbox.
|
|
1046
|
-
|
|
1047
|
-
Lemon drizzle
|
|
1048
|
-
|
|
1049
|
-
Victoria Sponge
|
|
1050
|
-
|
|
1051
|
-
Carrot Cake
|
|
1052
|
-
|
|
1053
|
-
Hide code
|
|
1054
|
-
|
|
1055
|
-
\[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; }
|
|
1056
|
-
|
|
1057
|
-
<IressCheckboxGroup
|
|
1058
|
-
defaultValue\={\[
|
|
1059
|
-
'lemon-drizzle',
|
|
1060
|
-
'victoria-sponge'
|
|
1061
|
-
\]}
|
|
1062
|
-
name\="let-them-eat-cake"
|
|
1063
|
-
touch
|
|
1064
|
-
\>
|
|
1065
|
-
<IressCheckbox value\="lemon-drizzle"\>
|
|
1066
|
-
Lemon drizzle </IressCheckbox\>
|
|
1067
|
-
<IressCheckbox value\="victoria-sponge"\>
|
|
1068
|
-
Victoria Sponge </IressCheckbox\>
|
|
1069
|
-
<IressCheckbox value\="carrot-cake"\>
|
|
1070
|
-
Carrot Cake </IressCheckbox\>
|
|
1071
|
-
</IressCheckboxGroup\>
|
|
1072
|
-
|
|
1073
|
-
Copy
|
|
1074
|
-
|
|
1075
|
-
On this page
|
|
1076
|
-
|
|
1077
|
-
* [Overview](#overview)
|
|
1078
|
-
* [Props](#props)
|
|
1079
|
-
* [Examples](#examples)
|
|
1080
|
-
* [Checkbox children](#checkbox-children)
|
|
1081
|
-
* [Default checked](#default-checked)
|
|
1082
|
-
* [Changing the checked state](#changing-the-checked-state)
|
|
1083
|
-
* [Layout](#layout)
|
|
1084
|
-
* [Hidden checkboxes](#hidden-checkboxes)
|
|
1085
|
-
* [Laying out custom checkboxes](#laying-out-custom-checkboxes)
|
|
1086
|
-
* [Read only](#read-only)
|
|
1087
|
-
* [Touch](#touch)
|