ControlGroup
ControlGroup is a layout component for displaying controls. It should be used primarily on parent-level settings pages.
Internal Component
This component is intended solely for use within GitHub and is not available for external use.React
draft
Props
ControlGroup
| Name | Default | Description |
|---|---|---|
border | boolean | |
fullWidth | boolean | |
data-testid | string | |
className | string |
ControlGroup.Item
| Name | Default | Description |
|---|---|---|
nestedLevel | 0 | 0 | 1 | 2 | undefined |
disabled | false | boolean |
contentsClassname | string |
ControlGroup.LinkItem
| Name | Default | Description |
|---|---|---|
href Required | string | |
leadingIcon | ReactNode | |
nestedLevel | 0 | 0 | 1 | 2 | undefined |
value | string |
ControlGroup.Selector
| Name | Default | Description |
|---|---|---|
title Required | stringTitle of the selection first row | |
description | stringDescription of the selection first row | |
selectorIcon | IconIcon to show in the mode selector in the first row | |
selectedMode | stringThe currently selected mode | |
onModeChange | ((mode: string) => void) | undefinedCallback when the mode changes | |
modes Required | Mode[]The available mode options. If there's only one, selector dropdown is not displayed and the mode editor is shown directly in the first row. | |
labelId | string | |
descriptionId | string |