|
| 1 | +This a custom component with a custom design. |
| 2 | + |
| 3 | +## Props |
| 4 | + |
| 5 | +Dual list select is wrapped in a form group, so it accepts all [form group props](/mappers/component-api#formgroupwrappedcomponents). |
| 6 | + |
| 7 | +|Props|Type|Default|Description| |
| 8 | +|-----|----|-------|-----------| |
| 9 | +|options|array|[]|`[{label, value, ...props}]` *see below*| |
| 10 | +|leftTitle|String|'Options'|Title for options| |
| 11 | +|rightTitle|String|'Selected'|Title for selected items| |
| 12 | +|moveLeftTitle|String|'Move selected to left'|Tooltip for move to left button| |
| 13 | +|moveRightTitle|String|'Move selected to right'|Tooltip for move to right button| |
| 14 | +|moveAllLeftTitle|String|'Move all to left'|Tooltip for move all to left button| |
| 15 | +|moveAllRightTitle|String|'Move all to right'|Tooltip for move all to right button| |
| 16 | +|noValueTitle|String|'No selected'|Placeholder for empty value| |
| 17 | +|noOptionsTitle|String|'No available options'|Placeholder for empty options| |
| 18 | +|filterOptionsTitle|String|'Filter options'|Placeholder for options filter input| |
| 19 | +|filterValueTitle|String|'Filter selected value'|Placeholder for value filter input| |
| 20 | +|filterValueText|String|'Remove your filter to see all selected'|Placeholder for value when there is no filtered value| |
| 21 | +|filterOptionsText|String|'Remove your filter to see all options'|Placeholder for options when there is no filtered option| |
| 22 | + |
| 23 | +### Options |
| 24 | + |
| 25 | +|Props|Type|Description| |
| 26 | +|-----|----|-----------| |
| 27 | +|value|string|Value of the option| |
| 28 | +|label|node|ListItemText primary text| |
| 29 | +|ListRowProps|object|Props for [StructuredListRow](https://react.carbondesignsystem.com/?path=/docs/structuredlist--selection)| |
| 30 | +|ListCellProps|object|Props for [StructuredListCell](https://react.carbondesignsystem.com/?path=/docs/structuredlist--selection)| |
| 31 | +|GridProps|object|Props for [Grid](https://react.carbondesignsystem.com/?path=/docs/grid--auto-columns)| |
| 32 | +|RowProps|object|Props for [Row](https://react.carbondesignsystem.com/?path=/docs/grid--auto-columns)| |
| 33 | +|LabelProps|object|Props for [Column](https://react.carbondesignsystem.com/?path=/docs/grid--auto-columns) containing the label| |
| 34 | +|CheckmarkProps|object|Props for [Column](https://react.carbondesignsystem.com/?path=/docs/grid--auto-columns) containing the checkmark| |
| 35 | + |
| 36 | +### Customization |
| 37 | + |
| 38 | +You can modify elements of titles by setting a string with HTML elements: |
| 39 | + |
| 40 | +|Props| |
| 41 | +|-----| |
| 42 | +|LeftTitleElement| |
| 43 | +|RightTitleElement| |
| 44 | + |
| 45 | +All these props are object: |
| 46 | + |
| 47 | +|Props|Component| |
| 48 | +|-----|---------| |
| 49 | +|LeftTitleProps|depends on LeftTitleElement| |
| 50 | +|RightTitleProps|depends on RightTitleElement| |
| 51 | +|FormGroupProps|[FormGroup](https://react.carbondesignsystem.com/?path=/docs/form--default)| |
| 52 | +|GridProps|[Grid](https://react.carbondesignsystem.com/?path=/docs/grid--auto-columns)| |
| 53 | +|RowProps|[Row](https://react.carbondesignsystem.com/?path=/docs/grid--auto-columns)| |
| 54 | +|OptionsColumnProps|[Column](https://react.carbondesignsystem.com/?path=/docs/grid--auto-columns)| |
| 55 | +|ButtonColumnProps|[Column](https://react.carbondesignsystem.com/?path=/docs/grid--auto-columns)| |
| 56 | +|ValuesColumnProps|[Column](https://react.carbondesignsystem.com/?path=/docs/grid--auto-columns)| |
| 57 | +|AddButtonProps|[Button](https://react.carbondesignsystem.com/?path=/docs/button--default)| |
| 58 | +|AddAllButtonProps|[Button](https://react.carbondesignsystem.com/?path=/docs/button--default)| |
| 59 | +|RemoveButtonProps|[Button](https://react.carbondesignsystem.com/?path=/docs/button--default)| |
| 60 | +|RemoveAllButtonProps|[Button](https://react.carbondesignsystem.com/?path=/docs/button--default)| |
| 61 | +|LeftToolbarProps|div| |
| 62 | +|RightToolbarProps|div| |
| 63 | +|LeftSearchProps|[Search](https://react.carbondesignsystem.com/?path=/docs/search--default)| |
| 64 | +|RightSearchProps|[Search](https://react.carbondesignsystem.com/?path=/docs/search--default)| |
| 65 | +|LeftSortProps|[TooltipIcon](https://react.carbondesignsystem.com/?path=/docs/tooltipicon--default)| |
| 66 | +|RightSortProps|[TooltipIcon](https://react.carbondesignsystem.com/?path=/docs/tooltipicon--default)| |
| 67 | +|LeftListProps|[StructuredList](https://react.carbondesignsystem.com/?path=/docs/structuredlist--selection)| |
| 68 | +|LeftBodyProps|[StructuredListBody](https://react.carbondesignsystem.com/?path=/docs/structuredlist--selection)| |
| 69 | +|RightListProps|[StructuredList](https://react.carbondesignsystem.com/?path=/docs/structuredlist--selection)| |
| 70 | +|RightBodyProps|[StructuredListBody](https://react.carbondesignsystem.com/?path=/docs/structuredlist--selection)| |
0 commit comments