-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: ComboBox - @deephaven/components (#2067)
* New `ComboBox` component in @deephaven/components * Split out some shared logic from `Picker` since `ComboBox` is basically a subclass * Deleted old `ComboBox` component and replaced usage (condition column + row formatting. Also tested to make sure it still works as before) * Updated Styleguide resolves #2065 BREAKING CHANGE: ComboBox component has been replaced. To migrate to new version: - Passing children is used instead of `options` prop to define dropdown items. For cases where option value and display are the same, passing an array of values as `children` will work. For cases where value and display differ, `Item` elements must be passed as children. e.g. `<Item key={value}>{display}</Item>` e.g. ```typescript // values will be used for display + value const items = useMemo( () => ['Aaa', 'Bbb', 'Ccc'], [] ) <ComboBox>{items}</ComboBox> ``` ```typescript <ComboBox> <Item key="aaa">Aaa</Item> <Item key="bbb">Bbb</Item> <Item key="ccc">Ccc</Item> </ComboBox> ``` - The `spellcheck=false` prop is no longer supported or needed - `searchPlaceholder` and `inputPlaceholder` props are no longer supported and should be omitted. There is an optional `description` prop for cases where a descriptive label is desired. There is also a `label` prop for the primary component label.
- Loading branch information
Showing
59 changed files
with
719 additions
and
830 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.