-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[WNMGDS-2505] Fix react-aria's react support and remove downshift (#2667
) * Replace react-aria dependency with local copy * Removed locales we don't need, and it shaved of 30k from our bundle * Fix the Preact bug in react-aria * Configure the doc site to build Preact storybook again * Add comment explaining the fix * Remove Downshift and references to it Nonen of the documentation I removed seemed very useful, so I didn't bother rewriting it * Fix bug where you could get it to show more items than it should 1. In the default example with all the drugs, type "ac" and select "Acetaminophen" 2. Arrow down and select that drug by pressing ENTER 3. Now type "c" at the end of the word 4. Previously you could see both "No results" and all the drugs (or just Acetaminophen), but with the fix, you should only see "No results" * Don't make Preact the default for storybook build command right now * Clear the text when clear search button is pressed too now with this fix, it calls `onInputValueChange` with `""` where it didn’t in the previous version, but I actually think that’s more correct, especially for controlled components * Give a clue about the origin of these imports
- Loading branch information
Showing
15 changed files
with
7,252 additions
and
109 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
15 changes: 0 additions & 15 deletions
15
packages/design-system/src/components/Autocomplete/WrapperDiv.tsx
This file was deleted.
Oops, something went wrong.
43 changes: 0 additions & 43 deletions
43
packages/design-system/src/components/Autocomplete/createFilteredA11yStatusMessageFn.ts
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
export { default as Autocomplete } from './Autocomplete'; | ||
export * from './Autocomplete'; |
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
4 changes: 2 additions & 2 deletions
4
packages/design-system/src/components/Dropdown/DropdownMenuOption.tsx
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
4 changes: 2 additions & 2 deletions
4
packages/design-system/src/components/Dropdown/DropdownMenuSection.tsx
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
12 changes: 12 additions & 0 deletions
12
packages/design-system/src/components/react-aria/index.d.ts
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
export { Item, Section, useComboBoxState, useSelectState } from 'react-stately'; | ||
export { | ||
HiddenSelect, | ||
useButton, | ||
useComboBox, | ||
useListBox, | ||
useListBoxSection, | ||
useOption, | ||
useSelect, | ||
} from 'react-aria'; | ||
export type { ComboBoxState, ListState, Node, OverlayTriggerState } from 'react-stately'; | ||
export type { AriaListBoxOptions, AriaPopoverProps } from 'react-aria'; |
Oops, something went wrong.