<!-- AUTO-GENERATED by packages/components/bin/generate-skill-component-catalog.js. Do not edit by hand. -->

# r-checkbox-group

Groups multiple `r-checkbox` elements under a shared label with optional select-all functionality, validation, and native form integration.

Example:
```
<r-checkbox-group name="preferences" label="Select your preferences">
  <r-checkbox value="news">News updates</r-checkbox>
  <r-checkbox value="offers">Special offers</r-checkbox>
  <r-checkbox value="events">Events</r-checkbox>
</r-checkbox-group>
```

## class: `RCheckboxGroup`, `r-checkbox-group`

### Fields

| Name                  | Privacy | Type      | Default | Description                                                                                                                                                                                                                        | Inherited From |
| --------------------- | ------- | --------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------- |
| `checked`             |         | `boolean` |         | Specifies if select-all checkbox is initially in checked state                                                                                                                                                                     |                |
| `customErrorMessage`  |         | `string`  |         | Set custom message for `customError` property of a ValidityState object <br>indicating whether the element's custom validity message has been set to a non-empty <br>string by calling the element's setCustomValidity() method. |                |
| `error`               |         | `string`  |         | Custom validation error message                                                                                                                                                                                                    |                |
| `fieldIndicator`      |         | `string`  |         | An optional field indicator for the label.                                                                                                                                                                                         |                |
| `form`                |         | `string`  |         | Specifies the `id` of the `<form>` to which the element belongs.                                                                                                                                                                   |                |
| `help`                |         | `string`  |         | Help text for the checkbox group.                                                                                                                                                                                                  |                |
| `helpIcon`            |         | `string`  |         | An optional icon to display in the help text.                                                                                                                                                                                      |                |
| `helpIconColor`       |         | `string`  |         | The color of the help icon.                                                                                                                                                                                                        |                |
| `hint`                |         | `string`  |         | A hint providing additional information for the checkbox group.                                                                                                                                                                    |                |
| `indeterminate`       |         | `boolean` |         | Specifies if select-all checkbox is initially in indeterminate state                                                                                                                                                               |                |
| `indetermitate`       |         | `boolean` |         |                                                                                                                                                                                                                                    |                |
| `invalid`             |         | `boolean` |         | Apply validation error visual style                                                                                                                                                                                                |                |
| `label`               |         | `string`  |         | The label for the checkbox group.                                                                                                                                                                                                  |                |
| `name`                |         | `string`  |         | Specifies `name` property of the 'select-all' checkbox, representing the group as a whole.                                                                                                                                         |                |
| `novalidate`          |         | `boolean` |         | Specifies if element must be ignored during validation of the form elements                                                                                                                                                        |                |
| `required`            |         | `boolean` | `false` | Specifies whether the `value` is required.                                                                                                                                                                                         |                |
| `showSelectAll`       |         | `boolean` |         | Whether to show a "Select All" checkbox.                                                                                                                                                                                           |                |
| `valid`               |         | `boolean` |         | Apply validation success visual style                                                                                                                                                                                              |                |
| `value`               |         | `string`  | `''`    | Specifies `value` property of the 'select-all', representing the group as a whole.                                                                                                                                                 |                |
| `valueMissingMessage` |         | `string`  |         | Set custom message for `valueMissing` property <br>of a ValidityState object (set by `required`) <br>within Constrain Validation API                                                                                             |                |

### Methods

| Name                | Privacy | Description                                                                                                                                                              | Parameters        | Return             | Inherited From |
| ------------------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ----------------- | ------------------ | -------------- |
| `checkAll`          |         | Checks all checkboxes in the slot.                                                                                                                                       |                   | `Promise<this>`    |                |
| `checkValidity`     |         | Validates the checkbox group without triggering UI and returns a boolean indicating its validity.                                                                        |                   | `Promise<boolean>` |                |
| `resetValidity`     |         | Resets the validity state and message of the radio group.<br>This method clears the validity message and state, and sets the invalid<br>property to its initial value. |                   | `Promise<void>`    |                |
| `setCustomValidity` |         | Validates the checkbox group, displays provided message in case value is invalid.                                                                                        | `message: string` | `Promise<void>`    |                |
| `uncheckAll`        |         | Unchecks all checkboxes in the slot.                                                                                                                                     |                   | `Promise<this>`    |                |

### Events

| Name        | Type                                               | Description                       | Inherited From |
| ----------- | -------------------------------------------------- | --------------------------------- | -------------- |
| `rValidate` | `CustomEvent<{ state: string; message: string; }>` | Emits event after each validation |                |

### Attributes

| Name                    | Field               | Inherited From |
| ----------------------- | ------------------- | -------------- |
| `checked`               | checked             |                |
| `custom-error-message`  | customErrorMessage  |                |
| `error`                 | error               |                |
| `field-indicator`       | fieldIndicator      |                |
| `form`                  | form                |                |
| `help`                  | help                |                |
| `help-icon`             | helpIcon            |                |
| `help-icon-color`       | helpIconColor       |                |
| `hint`                  | hint                |                |
| `indeterminate`         | indeterminate       |                |
| `indetermitate`         | indetermitate       |                |
| `invalid`               | invalid             |                |
| `label`                 | label               |                |
| `name`                  | name                |                |
| `novalidate`            | novalidate          |                |
| `required`              | required            |                |
| `show-select-all`       | showSelectAll       |                |
| `valid`                 | valid               |                |
| `value`                 | value               |                |
| `value-missing-message` | valueMissingMessage |                |

### CSS Parts

| Name      | Description                      |
| --------- | -------------------------------- |
| `content` | Wrap for the group of checkboxes |
| `label`   | Label element for the group      |

### Slots

| Name      | Description                                               |
| --------- | --------------------------------------------------------- |
|           | Checkbox items (`r-checkbox` elements) inside the group   |
| `label`   | Custom label content for the group                        |
| `popover` | Popover element (`r-popover`) attached to the group label |

<hr/>

## Exports

| Kind                        | Name               | Declaration    | Module | Package |
| --------------------------- | ------------------ | -------------- | ------ | ------- |
| `js`                        | `RCheckboxGroup`   | RCheckboxGroup |        |         |
| `custom-element-definition` | `r-checkbox-group` | RCheckboxGroup |        |         |
