You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
`optionText` is especially useful when the choices are records coming from a `<ReferenceArrayInput>` or a `<ReferenceManyToManyInput>`. By default, react-admin uses the [`recordRepresentation`](./Resource.md#recordrepresentation) function to display the record label. But if you set the `optionText` prop, react-admin will use it instead.
`optionText` also accepts a function, so you can shape the option text based on the entire choice object:
144
169
145
170
```jsx
@@ -192,6 +217,16 @@ By default, the checkboxes are displayed in a row. You can change that and let r
192
217
193
218

194
219
220
+
## `sx`: CSS API
221
+
222
+
The `<CheckboxGroupInput>` component accepts the usual `className` prop. You can also override many styles of the inner components thanks to the `sx` property (as most MUI components, see their [documentation about it](https://mui.com/customization/how-to-customize/#overriding-nested-component-styles)). This property accepts the following subclasses:
|`& .RaCheckboxGroupInput-label`| Applied to the underlying MUI's `FormLabel` component |
227
+
228
+
To override the style of all instances of `<CheckboxGroupInput>` using the [MUI style overrides](https://mui.com/customization/globals/#css), use the `RaCheckboxGroupInput` key.
229
+
195
230
## `translateChoice`
196
231
197
232
The choices are translated by default, so you can use translation identifiers as choices:
@@ -210,30 +245,3 @@ However, in some cases (e.g. inside a `<ReferenceArrayInput>`), you may not want
The `<CheckboxGroupInput>` component accepts the usual `className` prop. You can also override many styles of the inner components thanks to the `sx` property (as most MUI components, see their [documentation about it](https://mui.com/customization/how-to-customize/#overriding-nested-component-styles)). This property accepts the following subclasses:
|`& .RaCheckboxGroupInput-label`| Applied to the underlying MUI's `FormLabel` component |
238
-
239
-
To override the style of all instances of `<CheckboxGroupInput>` using the [MUI style overrides](https://mui.com/customization/globals/#css), use the `RaCheckboxGroupInput` key.
0 commit comments