Skip to content

Commit

Permalink
fixup! fixup! Allow check fields and selectable fields to render as r…
Browse files Browse the repository at this point in the history
…equired #487
  • Loading branch information
adamkudrna committed Dec 9, 2024
1 parent 52f3a12 commit 9c50f7f
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions src/components/CheckboxField/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -188,8 +188,8 @@ React.createElement(() => {

### Required State

The required state indicates that the input is mandatory. Required fields display an asterisk `*` after the label by
default.
The required state indicates that the input is mandatory. Required fields
display an asterisk `*` after the label by default.

```docoff-react-preview
React.createElement(() => {
Expand All @@ -205,9 +205,11 @@ React.createElement(() => {
});
```

However, your project may use the label color as the primary means to indicate the required state of input fields (see
[Forms Theming](/docs/customize/theming/forms) for more). Because not checking an input is also a valid action, it may
be confusing to users to see the optional check inputs greyed out.
However, your project may use the label color as the primary means to indicate
the required state of input fields (see
[Forms Theming](/docs/customize/theming/forms) for more). Because not checking
an input is also a valid action, it may be confusing to users to see the
optional check inputs greyed out.

For this case, there is the `renderAsRequired` prop:

Expand Down

0 comments on commit 9c50f7f

Please sign in to comment.