@carbon/react 1.83.0 → 1.84.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.playwright/INTERNAL_AVT_REPORT_DO_NOT_USE.json +909 -874
- package/README.md +1 -1
- package/es/components/AILabel/index.js +27 -30
- package/es/components/AISkeleton/AISkeletonIcon.js +4 -5
- package/es/components/AISkeleton/AISkeletonPlaceholder.js +4 -5
- package/es/components/AISkeleton/AISkeletonText.js +4 -5
- package/es/components/Accordion/Accordion.Skeleton.js +9 -10
- package/es/components/Accordion/Accordion.js +10 -11
- package/es/components/Accordion/AccordionItem.js +13 -14
- package/es/components/Accordion/AccordionProvider.js +4 -5
- package/es/components/AspectRatio/AspectRatio.js +7 -8
- package/es/components/BadgeIndicator/index.js +5 -6
- package/es/components/Breadcrumb/Breadcrumb.Skeleton.js +4 -5
- package/es/components/Button/Button.Skeleton.js +7 -8
- package/es/components/Button/ButtonBase.js +23 -24
- package/es/components/ChatButton/ChatButton.Skeleton.js +5 -6
- package/es/components/ChatButton/ChatButton.js +11 -12
- package/es/components/Checkbox/Checkbox.Skeleton.js +4 -5
- package/es/components/Checkbox/Checkbox.js +19 -20
- package/es/components/CheckboxGroup/CheckboxGroup.js +16 -17
- package/es/components/ClassPrefix/index.js +4 -5
- package/es/components/CodeSnippet/CodeSnippet.Skeleton.js +5 -6
- package/es/components/CodeSnippet/CodeSnippet.js +25 -26
- package/es/components/ComboBox/ComboBox.js +24 -30
- package/es/components/ComboBox/tools/filter.js +9 -12
- package/es/components/ComboButton/index.js +16 -18
- package/es/components/ComposedModal/ComposedModal.js +50 -36
- package/es/components/ComposedModal/ModalFooter.js +37 -42
- package/es/components/ComposedModal/ModalHeader.js +14 -15
- package/es/components/ContainedList/ContainedList.js +10 -11
- package/es/components/ContainedList/ContainedListItem/ContainedListItem.js +9 -10
- package/es/components/ContentSwitcher/ContentSwitcher.d.ts +9 -29
- package/es/components/ContentSwitcher/ContentSwitcher.js +96 -128
- package/es/components/ContentSwitcher/index.d.ts +3 -4
- package/es/components/ContextMenu/useContextMenu.js +1 -2
- package/es/components/Copy/Copy.js +11 -12
- package/es/components/CopyButton/CopyButton.js +10 -11
- package/es/components/DataTable/DataTable.js +45 -53
- package/es/components/DataTable/Table.js +15 -18
- package/es/components/DataTable/TableBatchAction.js +8 -11
- package/es/components/DataTable/TableBatchActions.js +18 -20
- package/es/components/DataTable/TableBody.js +8 -11
- package/es/components/DataTable/TableContainer.js +9 -10
- package/es/components/DataTable/TableDecoratorRow.js +4 -5
- package/es/components/DataTable/TableExpandHeader.js +14 -15
- package/es/components/DataTable/TableExpandRow.js +13 -14
- package/es/components/DataTable/TableExpandedRow.js +6 -7
- package/es/components/DataTable/TableHeader.js +15 -16
- package/es/components/DataTable/TableSelectAll.js +11 -12
- package/es/components/DataTable/TableSelectRow.js +12 -13
- package/es/components/DataTable/TableSlugRow.js +4 -5
- package/es/components/DataTable/TableToolbar.js +7 -8
- package/es/components/DataTable/TableToolbarMenu.js +8 -9
- package/es/components/DataTable/TableToolbarSearch.js +22 -24
- package/es/components/DataTable/state/sorting.js +3 -4
- package/es/components/DataTable/tools/filter.js +10 -12
- package/es/components/DataTable/tools/normalize.js +6 -8
- package/es/components/DataTable/tools/sorting.js +24 -30
- package/es/components/DataTableSkeleton/DataTableSkeleton.js +11 -12
- package/es/components/DatePicker/DatePicker.Skeleton.js +7 -8
- package/es/components/DatePicker/DatePicker.js +88 -65
- package/es/components/DatePickerInput/DatePickerInput.js +5 -6
- package/es/components/Dialog/index.d.ts +193 -8
- package/es/components/Dialog/index.js +454 -35
- package/es/components/Dropdown/Dropdown.Skeleton.js +6 -7
- package/es/components/Dropdown/Dropdown.js +40 -43
- package/es/components/ErrorBoundary/ErrorBoundary.js +2 -2
- package/es/components/ExpandableSearch/ExpandableSearch.js +9 -10
- package/es/components/FeatureFlags/index.js +11 -12
- package/es/components/FileUploader/FileUploader.Skeleton.js +4 -5
- package/es/components/FileUploader/FileUploader.js +22 -24
- package/es/components/FileUploader/FileUploaderButton.js +16 -17
- package/es/components/FileUploader/FileUploaderDropContainer.js +15 -16
- package/es/components/FileUploader/FileUploaderItem.js +13 -14
- package/es/components/FileUploader/Filename.js +9 -10
- package/es/components/FluidComboBox/FluidComboBox.Skeleton.js +4 -5
- package/es/components/FluidComboBox/FluidComboBox.js +5 -6
- package/es/components/FluidDatePicker/FluidDatePicker.Skeleton.js +5 -6
- package/es/components/FluidDatePicker/FluidDatePicker.js +10 -11
- package/es/components/FluidDropdown/FluidDropdown.Skeleton.js +4 -5
- package/es/components/FluidDropdown/FluidDropdown.js +5 -6
- package/es/components/FluidForm/FluidForm.js +5 -6
- package/es/components/FluidMultiSelect/FluidMultiSelect.Skeleton.js +4 -5
- package/es/components/FluidMultiSelect/FluidMultiSelect.js +6 -7
- package/es/components/FluidNumberInput/FluidNumberInput.Skeleton.js +4 -5
- package/es/components/FluidNumberInput/FluidNumberInput.d.ts +40 -1
- package/es/components/FluidNumberInput/FluidNumberInput.js +38 -5
- package/es/components/FluidSearch/FluidSearch.Skeleton.js +4 -5
- package/es/components/FluidSearch/FluidSearch.js +4 -5
- package/es/components/FluidSelect/FluidSelect.Skeleton.js +4 -5
- package/es/components/FluidSelect/FluidSelect.js +5 -6
- package/es/components/FluidTextArea/FluidTextArea.Skeleton.js +4 -5
- package/es/components/FluidTextArea/FluidTextArea.js +4 -5
- package/es/components/FluidTextInput/FluidTextInput.Skeleton.js +4 -5
- package/es/components/FluidTextInput/FluidTextInput.js +5 -6
- package/es/components/FluidTimePicker/FluidTimePicker.Skeleton.js +5 -6
- package/es/components/FluidTimePicker/FluidTimePicker.js +11 -12
- package/es/components/FluidTimePickerSelect/FluidTimePickerSelect.js +5 -6
- package/es/components/Form/Form.js +5 -6
- package/es/components/FormGroup/FormGroup.js +11 -12
- package/es/components/FormItem/FormItem.js +5 -6
- package/es/components/FormLabel/FormLabel.js +6 -7
- package/es/components/Grid/CSSGrid.js +17 -19
- package/es/components/Grid/Column.js +28 -27
- package/es/components/Grid/ColumnHang.js +6 -7
- package/es/components/Grid/FlexGrid.js +9 -10
- package/es/components/Grid/GridContext.js +5 -6
- package/es/components/Grid/Row.js +8 -9
- package/es/components/Heading/index.js +5 -6
- package/es/components/Icon/Icon.Skeleton.js +4 -5
- package/es/components/IconButton/index.js +20 -21
- package/es/components/IconIndicator/index.js +7 -8
- package/es/components/IdPrefix/index.js +4 -5
- package/es/components/InlineLoading/InlineLoading.js +9 -10
- package/es/components/Layer/index.js +8 -9
- package/es/components/Layout/index.js +21 -26
- package/es/components/LayoutDirection/LayoutDirection.js +6 -7
- package/es/components/Link/Link.d.ts +1 -1
- package/es/components/Link/Link.js +14 -15
- package/es/components/ListBox/ListBoxField.js +6 -7
- package/es/components/ListBox/ListBoxMenu.js +5 -6
- package/es/components/ListBox/ListBoxMenuIcon.js +4 -5
- package/es/components/ListBox/ListBoxMenuItem.js +8 -10
- package/es/components/ListBox/ListBoxSelection.js +8 -9
- package/es/components/ListBox/next/ListBoxSelection.js +9 -10
- package/es/components/ListBox/next/ListBoxTrigger.js +5 -6
- package/es/components/ListItem/ListItem.js +5 -6
- package/es/components/Loading/Loading.js +8 -9
- package/es/components/Menu/Menu.js +23 -24
- package/es/components/Menu/MenuItem.js +39 -44
- package/es/components/MenuButton/index.js +16 -18
- package/es/components/Modal/Modal.js +74 -65
- package/es/components/ModalWrapper/ModalWrapper.js +2 -2
- package/es/components/MultiSelect/FilterableMultiSelect.js +67 -48
- package/es/components/MultiSelect/MultiSelect.js +43 -45
- package/es/components/MultiSelect/tools/sorting.js +11 -15
- package/es/components/Notification/Notification.js +96 -105
- package/es/components/NumberInput/NumberFormatPropTypes.d.ts +29 -0
- package/es/components/NumberInput/NumberFormatPropTypes.js +40 -0
- package/es/components/NumberInput/NumberInput.Skeleton.js +6 -7
- package/es/components/NumberInput/NumberInput.d.ts +39 -3
- package/es/components/NumberInput/NumberInput.js +174 -44
- package/es/components/OrderedList/OrderedList.js +7 -8
- package/es/components/OverflowMenu/OverflowMenu.d.ts +1 -1
- package/es/components/OverflowMenu/OverflowMenu.js +39 -46
- package/es/components/OverflowMenu/next/index.js +12 -13
- package/es/components/PageHeader/PageHeader.d.ts +39 -14
- package/es/components/PageHeader/PageHeader.js +187 -81
- package/es/components/PageHeader/index.d.ts +2 -2
- package/es/components/PageHeader/index.js +1 -1
- package/es/components/Pagination/Pagination.Skeleton.js +4 -5
- package/es/components/Pagination/Pagination.js +24 -25
- package/es/components/Pagination/experimental/PageSelector.js +8 -9
- package/es/components/Pagination/experimental/Pagination.js +20 -21
- package/es/components/PaginationNav/PaginationNav.js +33 -38
- package/es/components/Popover/index.js +26 -28
- package/es/components/ProgressBar/ProgressBar.js +11 -12
- package/es/components/ProgressIndicator/ProgressIndicator.Skeleton.js +5 -6
- package/es/components/ProgressIndicator/ProgressIndicator.js +29 -32
- package/es/components/RadioTile/RadioTile.js +17 -18
- package/es/components/Search/Search.Skeleton.js +5 -6
- package/es/components/Search/Search.js +26 -29
- package/es/components/Select/Select.Skeleton.js +5 -6
- package/es/components/Select/Select.js +24 -25
- package/es/components/SelectItem/SelectItem.js +8 -9
- package/es/components/SelectItemGroup/SelectItemGroup.js +7 -8
- package/es/components/ShapeIndicator/index.js +7 -8
- package/es/components/SkeletonIcon/SkeletonIcon.js +4 -5
- package/es/components/SkeletonPlaceholder/SkeletonPlaceholder.js +4 -5
- package/es/components/SkeletonText/SkeletonText.js +8 -9
- package/es/components/Slider/Slider.Skeleton.js +8 -9
- package/es/components/Slider/Slider.js +75 -83
- package/es/components/Slider/SliderHandles.js +6 -6
- package/es/components/StructuredList/StructuredList.Skeleton.js +5 -6
- package/es/components/Tabs/Tabs.Skeleton.js +5 -6
- package/es/components/Tabs/Tabs.js +83 -98
- package/es/components/Tabs/usePressable.js +7 -8
- package/es/components/Tag/DismissibleTag.js +16 -17
- package/es/components/Tag/OperationalTag.js +10 -11
- package/es/components/Tag/SelectableTag.js +13 -14
- package/es/components/Tag/Tag.Skeleton.js +5 -6
- package/es/components/Tag/Tag.js +19 -20
- package/es/components/Text/Text.js +6 -7
- package/es/components/Text/TextDirection.js +5 -6
- package/es/components/TextArea/TextArea.js +7 -7
- package/es/components/TextInput/ControlledPasswordInput.js +24 -25
- package/es/components/TextInput/PasswordInput.js +26 -27
- package/es/components/TextInput/TextInput.Skeleton.js +5 -6
- package/es/components/TextInput/TextInput.js +27 -28
- package/es/components/TextInput/util.js +14 -17
- package/es/components/Theme/index.js +10 -12
- package/es/components/Tile/Tile.js +68 -74
- package/es/components/TileGroup/TileGroup.d.ts +4 -4
- package/es/components/TileGroup/TileGroup.js +45 -53
- package/es/components/TileGroup/index.d.ts +3 -3
- package/es/components/Toggle/Toggle.Skeleton.js +4 -5
- package/es/components/Toggle/Toggle.js +17 -18
- package/es/components/ToggleSmall/ToggleSmall.Skeleton.js +6 -7
- package/es/components/Toggletip/index.js +33 -39
- package/es/components/Tooltip/DefinitionTooltip.js +13 -14
- package/es/components/Tooltip/Tooltip.js +15 -16
- package/es/components/TreeView/TreeNode.js +20 -21
- package/es/components/TreeView/TreeView.js +14 -16
- package/es/components/UIShell/Content.js +6 -7
- package/es/components/UIShell/Header.js +5 -6
- package/es/components/UIShell/HeaderContainer.js +5 -6
- package/es/components/UIShell/HeaderGlobalAction.js +12 -13
- package/es/components/UIShell/HeaderMenu.d.ts +10 -112
- package/es/components/UIShell/HeaderMenu.js +154 -201
- package/es/components/UIShell/HeaderMenuButton.js +10 -11
- package/es/components/UIShell/HeaderMenuItem.js +12 -12
- package/es/components/UIShell/HeaderName.js +6 -7
- package/es/components/UIShell/HeaderNavigation.js +7 -8
- package/es/components/UIShell/HeaderPanel.js +9 -10
- package/es/components/UIShell/HeaderSideNavItems.js +5 -6
- package/es/components/UIShell/Link.js +8 -9
- package/es/components/UIShell/SideNav.js +23 -25
- package/es/components/UIShell/SideNavDetails.js +6 -7
- package/es/components/UIShell/SideNavDivider.js +3 -4
- package/es/components/UIShell/SideNavFooter.js +6 -7
- package/es/components/UIShell/SideNavHeader.js +5 -6
- package/es/components/UIShell/SideNavIcon.js +5 -6
- package/es/components/UIShell/SideNavItem.js +5 -6
- package/es/components/UIShell/SideNavItems.js +5 -6
- package/es/components/UIShell/SideNavLink.js +10 -11
- package/es/components/UIShell/SideNavLinkText.js +5 -6
- package/es/components/UIShell/SideNavMenu.js +11 -12
- package/es/components/UIShell/SkipToContent.js +7 -8
- package/es/components/UIShell/Switcher.js +4 -5
- package/es/components/UIShell/SwitcherDivider.js +4 -5
- package/es/components/UnorderedList/UnorderedList.js +6 -7
- package/es/index.js +3 -3
- package/es/internal/FloatingMenu.js +26 -28
- package/es/internal/Selection.js +15 -17
- package/es/internal/getAnnouncement.d.ts +8 -0
- package/es/internal/getAnnouncement.js +22 -0
- package/es/internal/keyboard/match.js +6 -7
- package/es/internal/useControllableState.d.ts +1 -1
- package/es/internal/useControllableState.js +8 -9
- package/es/internal/useDelayedState.js +1 -2
- package/es/internal/useDocumentLang.d.ts +12 -0
- package/es/internal/useId.js +2 -4
- package/es/internal/useMatchMedia.js +1 -2
- package/es/internal/useMergedRefs.d.ts +1 -1
- package/es/internal/useNoInteractiveChildren.js +2 -4
- package/es/internal/useNormalizedInputProps.js +9 -10
- package/es/internal/useOverflowItems.d.ts +29 -0
- package/es/internal/useOverflowItems.js +122 -0
- package/es/internal/useResizeObserver.js +4 -5
- package/es/internal/useSavedCallback.js +1 -3
- package/es/internal/wrapFocus.js +20 -29
- package/es/prop-types/deprecate.js +1 -4
- package/es/prop-types/deprecateValuesWithin.js +1 -4
- package/es/prop-types/isRequiredOneOf.js +1 -4
- package/es/prop-types/requiredIfGivenPropIsTruthy.js +1 -4
- package/es/tools/events.js +1 -4
- package/es/tools/mergeRefs.js +9 -14
- package/es/tools/uniqueId.js +1 -2
- package/es/tools/wrapComponent.js +9 -11
- package/lib/components/AILabel/index.js +27 -30
- package/lib/components/AISkeleton/AISkeletonIcon.js +4 -5
- package/lib/components/AISkeleton/AISkeletonPlaceholder.js +4 -5
- package/lib/components/AISkeleton/AISkeletonText.js +4 -5
- package/lib/components/Accordion/Accordion.Skeleton.js +9 -10
- package/lib/components/Accordion/Accordion.js +10 -11
- package/lib/components/Accordion/AccordionItem.js +13 -14
- package/lib/components/Accordion/AccordionProvider.js +4 -5
- package/lib/components/AspectRatio/AspectRatio.js +7 -8
- package/lib/components/BadgeIndicator/index.js +5 -6
- package/lib/components/Breadcrumb/Breadcrumb.Skeleton.js +4 -5
- package/lib/components/Button/Button.Skeleton.js +7 -8
- package/lib/components/Button/ButtonBase.js +23 -24
- package/lib/components/ChatButton/ChatButton.Skeleton.js +5 -6
- package/lib/components/ChatButton/ChatButton.js +11 -12
- package/lib/components/Checkbox/Checkbox.Skeleton.js +4 -5
- package/lib/components/Checkbox/Checkbox.js +19 -20
- package/lib/components/CheckboxGroup/CheckboxGroup.js +16 -17
- package/lib/components/ClassPrefix/index.js +4 -5
- package/lib/components/CodeSnippet/CodeSnippet.Skeleton.js +5 -6
- package/lib/components/CodeSnippet/CodeSnippet.js +25 -26
- package/lib/components/ComboBox/ComboBox.js +24 -30
- package/lib/components/ComboBox/tools/filter.js +9 -12
- package/lib/components/ComboButton/index.js +16 -18
- package/lib/components/ComposedModal/ComposedModal.js +50 -36
- package/lib/components/ComposedModal/ModalFooter.js +37 -42
- package/lib/components/ComposedModal/ModalHeader.js +14 -15
- package/lib/components/ContainedList/ContainedList.js +10 -11
- package/lib/components/ContainedList/ContainedListItem/ContainedListItem.js +9 -10
- package/lib/components/ContentSwitcher/ContentSwitcher.d.ts +9 -29
- package/lib/components/ContentSwitcher/ContentSwitcher.js +94 -126
- package/lib/components/ContentSwitcher/index.d.ts +3 -4
- package/lib/components/ContextMenu/useContextMenu.js +1 -2
- package/lib/components/Copy/Copy.js +11 -12
- package/lib/components/CopyButton/CopyButton.js +10 -11
- package/lib/components/DataTable/DataTable.js +45 -53
- package/lib/components/DataTable/Table.js +15 -18
- package/lib/components/DataTable/TableBatchAction.js +8 -11
- package/lib/components/DataTable/TableBatchActions.js +18 -20
- package/lib/components/DataTable/TableBody.js +8 -11
- package/lib/components/DataTable/TableContainer.js +9 -10
- package/lib/components/DataTable/TableDecoratorRow.js +4 -5
- package/lib/components/DataTable/TableExpandHeader.js +14 -15
- package/lib/components/DataTable/TableExpandRow.js +13 -14
- package/lib/components/DataTable/TableExpandedRow.js +6 -7
- package/lib/components/DataTable/TableHeader.js +15 -16
- package/lib/components/DataTable/TableSelectAll.js +11 -12
- package/lib/components/DataTable/TableSelectRow.js +12 -13
- package/lib/components/DataTable/TableSlugRow.js +4 -5
- package/lib/components/DataTable/TableToolbar.js +7 -8
- package/lib/components/DataTable/TableToolbarMenu.js +8 -9
- package/lib/components/DataTable/TableToolbarSearch.js +22 -24
- package/lib/components/DataTable/state/sorting.js +3 -4
- package/lib/components/DataTable/tools/filter.js +10 -12
- package/lib/components/DataTable/tools/normalize.js +6 -8
- package/lib/components/DataTable/tools/sorting.js +24 -30
- package/lib/components/DataTableSkeleton/DataTableSkeleton.js +11 -12
- package/lib/components/DatePicker/DatePicker.Skeleton.js +7 -8
- package/lib/components/DatePicker/DatePicker.js +87 -64
- package/lib/components/DatePickerInput/DatePickerInput.js +5 -6
- package/lib/components/Dialog/index.d.ts +193 -8
- package/lib/components/Dialog/index.js +457 -33
- package/lib/components/Dropdown/Dropdown.Skeleton.js +6 -7
- package/lib/components/Dropdown/Dropdown.js +40 -43
- package/lib/components/ErrorBoundary/ErrorBoundary.js +2 -2
- package/lib/components/ExpandableSearch/ExpandableSearch.js +9 -10
- package/lib/components/FeatureFlags/index.js +11 -12
- package/lib/components/FileUploader/FileUploader.Skeleton.js +4 -5
- package/lib/components/FileUploader/FileUploader.js +22 -24
- package/lib/components/FileUploader/FileUploaderButton.js +16 -17
- package/lib/components/FileUploader/FileUploaderDropContainer.js +15 -16
- package/lib/components/FileUploader/FileUploaderItem.js +13 -14
- package/lib/components/FileUploader/Filename.js +9 -10
- package/lib/components/FluidComboBox/FluidComboBox.Skeleton.js +4 -5
- package/lib/components/FluidComboBox/FluidComboBox.js +5 -6
- package/lib/components/FluidDatePicker/FluidDatePicker.Skeleton.js +5 -6
- package/lib/components/FluidDatePicker/FluidDatePicker.js +10 -11
- package/lib/components/FluidDropdown/FluidDropdown.Skeleton.js +4 -5
- package/lib/components/FluidDropdown/FluidDropdown.js +5 -6
- package/lib/components/FluidForm/FluidForm.js +5 -6
- package/lib/components/FluidMultiSelect/FluidMultiSelect.Skeleton.js +4 -5
- package/lib/components/FluidMultiSelect/FluidMultiSelect.js +6 -7
- package/lib/components/FluidNumberInput/FluidNumberInput.Skeleton.js +4 -5
- package/lib/components/FluidNumberInput/FluidNumberInput.d.ts +40 -1
- package/lib/components/FluidNumberInput/FluidNumberInput.js +38 -5
- package/lib/components/FluidSearch/FluidSearch.Skeleton.js +4 -5
- package/lib/components/FluidSearch/FluidSearch.js +4 -5
- package/lib/components/FluidSelect/FluidSelect.Skeleton.js +4 -5
- package/lib/components/FluidSelect/FluidSelect.js +5 -6
- package/lib/components/FluidTextArea/FluidTextArea.Skeleton.js +4 -5
- package/lib/components/FluidTextArea/FluidTextArea.js +4 -5
- package/lib/components/FluidTextInput/FluidTextInput.Skeleton.js +4 -5
- package/lib/components/FluidTextInput/FluidTextInput.js +5 -6
- package/lib/components/FluidTimePicker/FluidTimePicker.Skeleton.js +5 -6
- package/lib/components/FluidTimePicker/FluidTimePicker.js +11 -12
- package/lib/components/FluidTimePickerSelect/FluidTimePickerSelect.js +5 -6
- package/lib/components/Form/Form.js +5 -6
- package/lib/components/FormGroup/FormGroup.js +11 -12
- package/lib/components/FormItem/FormItem.js +5 -6
- package/lib/components/FormLabel/FormLabel.js +6 -7
- package/lib/components/Grid/CSSGrid.js +17 -19
- package/lib/components/Grid/Column.js +28 -27
- package/lib/components/Grid/ColumnHang.js +6 -7
- package/lib/components/Grid/FlexGrid.js +9 -10
- package/lib/components/Grid/GridContext.js +5 -6
- package/lib/components/Grid/Row.js +8 -9
- package/lib/components/Heading/index.js +5 -6
- package/lib/components/Icon/Icon.Skeleton.js +4 -5
- package/lib/components/IconButton/index.js +20 -21
- package/lib/components/IconIndicator/index.js +7 -8
- package/lib/components/IdPrefix/index.js +4 -5
- package/lib/components/InlineLoading/InlineLoading.js +9 -10
- package/lib/components/Layer/index.js +8 -9
- package/lib/components/Layout/index.js +21 -26
- package/lib/components/LayoutDirection/LayoutDirection.js +6 -7
- package/lib/components/Link/Link.d.ts +1 -1
- package/lib/components/Link/Link.js +14 -15
- package/lib/components/ListBox/ListBoxField.js +6 -7
- package/lib/components/ListBox/ListBoxMenu.js +5 -6
- package/lib/components/ListBox/ListBoxMenuIcon.js +4 -5
- package/lib/components/ListBox/ListBoxMenuItem.js +8 -10
- package/lib/components/ListBox/ListBoxSelection.js +8 -9
- package/lib/components/ListBox/next/ListBoxSelection.js +9 -10
- package/lib/components/ListBox/next/ListBoxTrigger.js +5 -6
- package/lib/components/ListItem/ListItem.js +5 -6
- package/lib/components/Loading/Loading.js +8 -9
- package/lib/components/Menu/Menu.js +23 -24
- package/lib/components/Menu/MenuItem.js +39 -44
- package/lib/components/MenuButton/index.js +16 -18
- package/lib/components/Modal/Modal.js +74 -65
- package/lib/components/ModalWrapper/ModalWrapper.js +2 -2
- package/lib/components/MultiSelect/FilterableMultiSelect.js +66 -47
- package/lib/components/MultiSelect/MultiSelect.js +43 -45
- package/lib/components/MultiSelect/tools/sorting.js +11 -15
- package/lib/components/Notification/Notification.js +96 -105
- package/lib/components/NumberInput/NumberFormatPropTypes.d.ts +29 -0
- package/lib/components/NumberInput/NumberFormatPropTypes.js +48 -0
- package/lib/components/NumberInput/NumberInput.Skeleton.js +6 -7
- package/lib/components/NumberInput/NumberInput.d.ts +39 -3
- package/lib/components/NumberInput/NumberInput.js +173 -43
- package/lib/components/OrderedList/OrderedList.js +7 -8
- package/lib/components/OverflowMenu/OverflowMenu.d.ts +1 -1
- package/lib/components/OverflowMenu/OverflowMenu.js +39 -46
- package/lib/components/OverflowMenu/next/index.js +12 -13
- package/lib/components/PageHeader/PageHeader.d.ts +39 -14
- package/lib/components/PageHeader/PageHeader.js +185 -81
- package/lib/components/PageHeader/index.d.ts +2 -2
- package/lib/components/PageHeader/index.js +0 -2
- package/lib/components/Pagination/Pagination.Skeleton.js +4 -5
- package/lib/components/Pagination/Pagination.js +24 -25
- package/lib/components/Pagination/experimental/PageSelector.js +8 -9
- package/lib/components/Pagination/experimental/Pagination.js +20 -21
- package/lib/components/PaginationNav/PaginationNav.js +33 -38
- package/lib/components/Popover/index.js +26 -28
- package/lib/components/ProgressBar/ProgressBar.js +11 -12
- package/lib/components/ProgressIndicator/ProgressIndicator.Skeleton.js +5 -6
- package/lib/components/ProgressIndicator/ProgressIndicator.js +29 -32
- package/lib/components/RadioTile/RadioTile.js +17 -18
- package/lib/components/Search/Search.Skeleton.js +5 -6
- package/lib/components/Search/Search.js +26 -29
- package/lib/components/Select/Select.Skeleton.js +5 -6
- package/lib/components/Select/Select.js +24 -25
- package/lib/components/SelectItem/SelectItem.js +8 -9
- package/lib/components/SelectItemGroup/SelectItemGroup.js +7 -8
- package/lib/components/ShapeIndicator/index.js +7 -8
- package/lib/components/SkeletonIcon/SkeletonIcon.js +4 -5
- package/lib/components/SkeletonPlaceholder/SkeletonPlaceholder.js +4 -5
- package/lib/components/SkeletonText/SkeletonText.js +8 -9
- package/lib/components/Slider/Slider.Skeleton.js +8 -9
- package/lib/components/Slider/Slider.js +75 -83
- package/lib/components/Slider/SliderHandles.js +6 -6
- package/lib/components/StructuredList/StructuredList.Skeleton.js +5 -6
- package/lib/components/Tabs/Tabs.Skeleton.js +5 -6
- package/lib/components/Tabs/Tabs.js +83 -98
- package/lib/components/Tabs/usePressable.js +7 -8
- package/lib/components/Tag/DismissibleTag.js +16 -17
- package/lib/components/Tag/OperationalTag.js +10 -11
- package/lib/components/Tag/SelectableTag.js +13 -14
- package/lib/components/Tag/Tag.Skeleton.js +5 -6
- package/lib/components/Tag/Tag.js +19 -20
- package/lib/components/Text/Text.js +6 -7
- package/lib/components/Text/TextDirection.js +5 -6
- package/lib/components/TextArea/TextArea.js +7 -7
- package/lib/components/TextInput/ControlledPasswordInput.js +24 -25
- package/lib/components/TextInput/PasswordInput.js +26 -27
- package/lib/components/TextInput/TextInput.Skeleton.js +5 -6
- package/lib/components/TextInput/TextInput.js +27 -28
- package/lib/components/TextInput/util.js +14 -17
- package/lib/components/Theme/index.js +10 -12
- package/lib/components/Tile/Tile.js +68 -74
- package/lib/components/TileGroup/TileGroup.d.ts +4 -4
- package/lib/components/TileGroup/TileGroup.js +44 -52
- package/lib/components/TileGroup/index.d.ts +3 -3
- package/lib/components/Toggle/Toggle.Skeleton.js +4 -5
- package/lib/components/Toggle/Toggle.js +17 -18
- package/lib/components/ToggleSmall/ToggleSmall.Skeleton.js +6 -7
- package/lib/components/Toggletip/index.js +33 -39
- package/lib/components/Tooltip/DefinitionTooltip.js +13 -14
- package/lib/components/Tooltip/Tooltip.js +15 -16
- package/lib/components/TreeView/TreeNode.js +20 -21
- package/lib/components/TreeView/TreeView.js +14 -16
- package/lib/components/UIShell/Content.js +6 -7
- package/lib/components/UIShell/Header.js +5 -6
- package/lib/components/UIShell/HeaderContainer.js +5 -6
- package/lib/components/UIShell/HeaderGlobalAction.js +12 -13
- package/lib/components/UIShell/HeaderMenu.d.ts +10 -112
- package/lib/components/UIShell/HeaderMenu.js +152 -199
- package/lib/components/UIShell/HeaderMenuButton.js +10 -11
- package/lib/components/UIShell/HeaderMenuItem.js +12 -12
- package/lib/components/UIShell/HeaderName.js +6 -7
- package/lib/components/UIShell/HeaderNavigation.js +7 -8
- package/lib/components/UIShell/HeaderPanel.js +9 -10
- package/lib/components/UIShell/HeaderSideNavItems.js +5 -6
- package/lib/components/UIShell/Link.js +8 -9
- package/lib/components/UIShell/SideNav.js +23 -25
- package/lib/components/UIShell/SideNavDetails.js +6 -7
- package/lib/components/UIShell/SideNavDivider.js +3 -4
- package/lib/components/UIShell/SideNavFooter.js +6 -7
- package/lib/components/UIShell/SideNavHeader.js +5 -6
- package/lib/components/UIShell/SideNavIcon.js +5 -6
- package/lib/components/UIShell/SideNavItem.js +5 -6
- package/lib/components/UIShell/SideNavItems.js +5 -6
- package/lib/components/UIShell/SideNavLink.js +10 -11
- package/lib/components/UIShell/SideNavLinkText.js +5 -6
- package/lib/components/UIShell/SideNavMenu.js +11 -12
- package/lib/components/UIShell/SkipToContent.js +7 -8
- package/lib/components/UIShell/Switcher.js +4 -5
- package/lib/components/UIShell/SwitcherDivider.js +4 -5
- package/lib/components/UnorderedList/UnorderedList.js +6 -7
- package/lib/index.js +36 -36
- package/lib/internal/FloatingMenu.js +26 -28
- package/lib/internal/Selection.js +15 -17
- package/lib/internal/getAnnouncement.d.ts +8 -0
- package/lib/internal/getAnnouncement.js +26 -0
- package/lib/internal/keyboard/match.js +6 -7
- package/lib/internal/useControllableState.d.ts +1 -1
- package/lib/internal/useControllableState.js +8 -9
- package/lib/internal/useDelayedState.js +1 -2
- package/lib/internal/useDocumentLang.d.ts +12 -0
- package/lib/internal/useId.js +2 -4
- package/lib/internal/useMatchMedia.js +1 -2
- package/lib/internal/useMergedRefs.d.ts +1 -1
- package/lib/internal/useNoInteractiveChildren.js +2 -4
- package/lib/internal/useNormalizedInputProps.js +9 -10
- package/lib/internal/useOverflowItems.d.ts +29 -0
- package/lib/internal/useOverflowItems.js +126 -0
- package/lib/internal/useResizeObserver.js +4 -5
- package/lib/internal/useSavedCallback.js +1 -3
- package/lib/internal/wrapFocus.js +20 -29
- package/lib/prop-types/deprecate.js +1 -4
- package/lib/prop-types/deprecateValuesWithin.js +1 -4
- package/lib/prop-types/isRequiredOneOf.js +1 -4
- package/lib/prop-types/requiredIfGivenPropIsTruthy.js +1 -4
- package/lib/tools/events.js +1 -4
- package/lib/tools/mergeRefs.js +9 -14
- package/lib/tools/uniqueId.js +1 -2
- package/lib/tools/wrapComponent.js +9 -11
- package/package.json +21 -19
- package/telemetry.yml +25 -1
- package/es/components/ContentSwitcher/index.js +0 -13
- package/es/feature-flags.d.ts +0 -7
- package/es/internal/useAnnouncer.js +0 -21
- package/lib/components/ContentSwitcher/index.js +0 -18
- package/lib/feature-flags.d.ts +0 -7
- package/lib/internal/useAnnouncer.js +0 -25
package/README.md
CHANGED
|
@@ -31,7 +31,7 @@ links:
|
|
|
31
31
|
For info on how to configure Sass for your project, here are some common
|
|
32
32
|
framework's documentation worth reviewing:
|
|
33
33
|
|
|
34
|
-
- [Next.js with Sass](https://nextjs.org/docs/
|
|
34
|
+
- [Next.js with Sass](https://nextjs.org/docs/app/guides/sass)
|
|
35
35
|
- [Remix with Sass](https://remix.run/docs/en/1.18.0/guides/styling#css-preprocessors)
|
|
36
36
|
- [Gatsby with Sass](https://www.gatsbyjs.com/docs/how-to/styling/sass/)
|
|
37
37
|
|
|
@@ -19,12 +19,11 @@ import { useId } from '../../internal/useId.js';
|
|
|
19
19
|
import deprecate from '../../prop-types/deprecate.js';
|
|
20
20
|
|
|
21
21
|
var _Undo;
|
|
22
|
-
const AILabelContent = /*#__PURE__*/React.forwardRef(function AILabelContent(
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
} = _ref;
|
|
22
|
+
const AILabelContent = /*#__PURE__*/React.forwardRef(function AILabelContent({
|
|
23
|
+
className,
|
|
24
|
+
children,
|
|
25
|
+
...rest
|
|
26
|
+
}, ref) {
|
|
28
27
|
const prefix = usePrefix();
|
|
29
28
|
const hasAILabelActions = React.Children.toArray(children).some(child => {
|
|
30
29
|
const item = child;
|
|
@@ -49,12 +48,11 @@ AILabelContent.propTypes = {
|
|
|
49
48
|
*/
|
|
50
49
|
className: PropTypes.string
|
|
51
50
|
};
|
|
52
|
-
const AILabelActions = /*#__PURE__*/React.forwardRef(function AILabelActions(
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
} = _ref2;
|
|
51
|
+
const AILabelActions = /*#__PURE__*/React.forwardRef(function AILabelActions({
|
|
52
|
+
className,
|
|
53
|
+
children,
|
|
54
|
+
...rest
|
|
55
|
+
}, ref) {
|
|
58
56
|
const prefix = usePrefix();
|
|
59
57
|
const aiLabelActionsClasses = cx(className, {
|
|
60
58
|
[`${prefix}--ai-label-actions`]: true
|
|
@@ -80,24 +78,23 @@ AILabelActions.propTypes = {
|
|
|
80
78
|
* @deprecated Use NewPopoverAlignment instead.
|
|
81
79
|
*/
|
|
82
80
|
|
|
83
|
-
const AILabel = /*#__PURE__*/React.forwardRef(function AILabel(
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
} = _ref3;
|
|
81
|
+
const AILabel = /*#__PURE__*/React.forwardRef(function AILabel({
|
|
82
|
+
aiText = 'AI',
|
|
83
|
+
aiTextLabel,
|
|
84
|
+
textLabel,
|
|
85
|
+
align,
|
|
86
|
+
autoAlign = true,
|
|
87
|
+
children,
|
|
88
|
+
className,
|
|
89
|
+
kind = 'default',
|
|
90
|
+
onRevertClick,
|
|
91
|
+
revertActive,
|
|
92
|
+
revertLabel = 'Revert to AI input',
|
|
93
|
+
slugLabel = 'Show information',
|
|
94
|
+
['aria-label']: ariaLabel = 'Show information',
|
|
95
|
+
size = 'xs',
|
|
96
|
+
...rest
|
|
97
|
+
}, ref) {
|
|
101
98
|
const prefix = usePrefix();
|
|
102
99
|
const id = useId('AILabel');
|
|
103
100
|
const aiLabelClasses = cx(className, {
|
|
@@ -12,11 +12,10 @@ import cx from 'classnames';
|
|
|
12
12
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
13
13
|
import SkeletonIcon from '../SkeletonIcon/SkeletonIcon.js';
|
|
14
14
|
|
|
15
|
-
const AISkeletonIcon =
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
} = _ref;
|
|
15
|
+
const AISkeletonIcon = ({
|
|
16
|
+
className,
|
|
17
|
+
...rest
|
|
18
|
+
}) => {
|
|
20
19
|
const prefix = usePrefix();
|
|
21
20
|
const AISkeletonIconClasses = cx(className, {
|
|
22
21
|
[`${prefix}--skeleton__icon--ai`]: true
|
|
@@ -12,11 +12,10 @@ import cx from 'classnames';
|
|
|
12
12
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
13
13
|
import SkeletonPlaceholder from '../SkeletonPlaceholder/SkeletonPlaceholder.js';
|
|
14
14
|
|
|
15
|
-
const AISkeletonPlaceholder =
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
} = _ref;
|
|
15
|
+
const AISkeletonPlaceholder = ({
|
|
16
|
+
className,
|
|
17
|
+
...other
|
|
18
|
+
}) => {
|
|
20
19
|
const prefix = usePrefix();
|
|
21
20
|
const AISkeletonPlaceholderClasses = cx({
|
|
22
21
|
className,
|
|
@@ -12,11 +12,10 @@ import cx from 'classnames';
|
|
|
12
12
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
13
13
|
import SkeletonText from '../SkeletonText/SkeletonText.js';
|
|
14
14
|
|
|
15
|
-
const AISkeletonText =
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
} = _ref;
|
|
15
|
+
const AISkeletonText = ({
|
|
16
|
+
className,
|
|
17
|
+
...rest
|
|
18
|
+
}) => {
|
|
20
19
|
const prefix = usePrefix();
|
|
21
20
|
const aiSkeletonTextClasses = cx(className, {
|
|
22
21
|
[`${prefix}--skeleton__text--ai`]: true
|
|
@@ -14,16 +14,15 @@ import SkeletonText from '../SkeletonText/SkeletonText.js';
|
|
|
14
14
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
15
15
|
|
|
16
16
|
var _SkeletonText, _SkeletonText2, _SkeletonText3;
|
|
17
|
-
function AccordionSkeleton(
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
} = _ref;
|
|
17
|
+
function AccordionSkeleton({
|
|
18
|
+
align = 'end',
|
|
19
|
+
className,
|
|
20
|
+
count = 4,
|
|
21
|
+
isFlush,
|
|
22
|
+
open = true,
|
|
23
|
+
ordered = false,
|
|
24
|
+
...rest
|
|
25
|
+
}) {
|
|
27
26
|
const prefix = usePrefix();
|
|
28
27
|
const classes = cx(`${prefix}--accordion`, `${prefix}--skeleton`, className, {
|
|
29
28
|
[`${prefix}--accordion--${align}`]: align,
|
|
@@ -12,17 +12,16 @@ import PropTypes from 'prop-types';
|
|
|
12
12
|
import React from 'react';
|
|
13
13
|
import { AccordionProvider } from './AccordionProvider.js';
|
|
14
14
|
|
|
15
|
-
function Accordion(
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
} = _ref;
|
|
15
|
+
function Accordion({
|
|
16
|
+
align = 'end',
|
|
17
|
+
children,
|
|
18
|
+
className: customClassName,
|
|
19
|
+
disabled = false,
|
|
20
|
+
isFlush = false,
|
|
21
|
+
ordered = false,
|
|
22
|
+
size,
|
|
23
|
+
...rest
|
|
24
|
+
}) {
|
|
26
25
|
const prefix = usePrefix();
|
|
27
26
|
const className = cx(`${prefix}--accordion`, customClassName, {
|
|
28
27
|
[`${prefix}--accordion--${align}`]: align,
|
|
@@ -22,20 +22,19 @@ import { Text } from '../Text/Text.js';
|
|
|
22
22
|
const defaultRenderToggle = props => /*#__PURE__*/React.createElement("button", _extends({
|
|
23
23
|
type: "button"
|
|
24
24
|
}, props));
|
|
25
|
-
function AccordionItem(
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
} = _ref;
|
|
25
|
+
function AccordionItem({
|
|
26
|
+
children,
|
|
27
|
+
className: customClassName = '',
|
|
28
|
+
open = false,
|
|
29
|
+
onHeadingClick,
|
|
30
|
+
renderExpando = defaultRenderToggle,
|
|
31
|
+
// remove renderExpando in next major release
|
|
32
|
+
renderToggle,
|
|
33
|
+
title = 'title',
|
|
34
|
+
disabled: controlledDisabled,
|
|
35
|
+
handleAnimationEnd,
|
|
36
|
+
...rest
|
|
37
|
+
}) {
|
|
39
38
|
const [isOpen, setIsOpen] = useState(open);
|
|
40
39
|
const [prevIsOpen, setPrevIsOpen] = useState(open);
|
|
41
40
|
const accordionState = useContext(AccordionContext);
|
|
@@ -10,11 +10,10 @@ import React, { createContext } from 'react';
|
|
|
10
10
|
const AccordionContext = /*#__PURE__*/createContext({
|
|
11
11
|
disabled: false
|
|
12
12
|
});
|
|
13
|
-
const AccordionProvider =
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
} = _ref;
|
|
13
|
+
const AccordionProvider = ({
|
|
14
|
+
disabled,
|
|
15
|
+
children
|
|
16
|
+
}) => {
|
|
18
17
|
return /*#__PURE__*/React.createElement(AccordionContext.Provider, {
|
|
19
18
|
value: {
|
|
20
19
|
disabled
|
|
@@ -17,14 +17,13 @@ import { usePrefix } from '../../internal/usePrefix.js';
|
|
|
17
17
|
* This is often useful alongside our grid components, or for media assets like
|
|
18
18
|
* images or videos.
|
|
19
19
|
*/
|
|
20
|
-
const AspectRatio =
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
} = _ref;
|
|
20
|
+
const AspectRatio = ({
|
|
21
|
+
as: BaseComponent = 'div',
|
|
22
|
+
className: containerClassName,
|
|
23
|
+
children,
|
|
24
|
+
ratio = '1x1',
|
|
25
|
+
...rest
|
|
26
|
+
}) => {
|
|
28
27
|
const prefix = usePrefix();
|
|
29
28
|
const className = cx(containerClassName, `${prefix}--aspect-ratio`, `${prefix}--aspect-ratio--${ratio}`);
|
|
30
29
|
return /*#__PURE__*/React.createElement(BaseComponent, _extends({
|
|
@@ -11,12 +11,11 @@ import React from 'react';
|
|
|
11
11
|
import cx from 'classnames';
|
|
12
12
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
13
13
|
|
|
14
|
-
const BadgeIndicator = /*#__PURE__*/React.forwardRef(function BadgeIndicatorContent(
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
} = _ref;
|
|
14
|
+
const BadgeIndicator = /*#__PURE__*/React.forwardRef(function BadgeIndicatorContent({
|
|
15
|
+
className: customClassName,
|
|
16
|
+
count,
|
|
17
|
+
...rest
|
|
18
|
+
}, ref) {
|
|
20
19
|
const prefix = usePrefix();
|
|
21
20
|
const classNames = cx(`${prefix}--badge-indicator`, customClassName, {
|
|
22
21
|
[`${prefix}--badge-indicator--count`]: count
|
|
@@ -20,11 +20,10 @@ function Item() {
|
|
|
20
20
|
className: `${prefix}--link`
|
|
21
21
|
}, "\xA0"));
|
|
22
22
|
}
|
|
23
|
-
function BreadcrumbSkeleton(
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
} = _ref;
|
|
23
|
+
function BreadcrumbSkeleton({
|
|
24
|
+
className,
|
|
25
|
+
...rest
|
|
26
|
+
}) {
|
|
28
27
|
const prefix = usePrefix();
|
|
29
28
|
const classes = cx(`${prefix}--breadcrumb`, `${prefix}--skeleton`, className);
|
|
30
29
|
return /*#__PURE__*/React.createElement("div", _extends({
|
|
@@ -11,14 +11,13 @@ import React from 'react';
|
|
|
11
11
|
import cx from 'classnames';
|
|
12
12
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
13
13
|
|
|
14
|
-
const ButtonSkeleton =
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
} = _ref;
|
|
14
|
+
const ButtonSkeleton = ({
|
|
15
|
+
className,
|
|
16
|
+
small = false,
|
|
17
|
+
href,
|
|
18
|
+
size = 'lg',
|
|
19
|
+
...rest
|
|
20
|
+
}) => {
|
|
22
21
|
const prefix = usePrefix();
|
|
23
22
|
const buttonClasses = cx(className, {
|
|
24
23
|
[`${prefix}--skeleton`]: true,
|
|
@@ -10,30 +10,29 @@ import cx from 'classnames';
|
|
|
10
10
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
11
11
|
import { useId } from '../../internal/useId.js';
|
|
12
12
|
|
|
13
|
-
const ButtonBase = /*#__PURE__*/React.forwardRef(function ButtonBase(
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
} = _ref;
|
|
13
|
+
const ButtonBase = /*#__PURE__*/React.forwardRef(function ButtonBase({
|
|
14
|
+
as,
|
|
15
|
+
children,
|
|
16
|
+
className,
|
|
17
|
+
dangerDescription = 'danger',
|
|
18
|
+
disabled = false,
|
|
19
|
+
hasIconOnly = false,
|
|
20
|
+
href,
|
|
21
|
+
iconDescription,
|
|
22
|
+
isExpressive = false,
|
|
23
|
+
isSelected,
|
|
24
|
+
kind = 'primary',
|
|
25
|
+
onBlur,
|
|
26
|
+
onClick,
|
|
27
|
+
onFocus,
|
|
28
|
+
onMouseEnter,
|
|
29
|
+
onMouseLeave,
|
|
30
|
+
renderIcon: ButtonImageElement,
|
|
31
|
+
size,
|
|
32
|
+
tabIndex,
|
|
33
|
+
type = 'button',
|
|
34
|
+
...rest
|
|
35
|
+
}, ref) {
|
|
37
36
|
const prefix = usePrefix();
|
|
38
37
|
const buttonClasses = cx(className, {
|
|
39
38
|
[`${prefix}--btn`]: true,
|
|
@@ -11,12 +11,11 @@ import React from 'react';
|
|
|
11
11
|
import cx from 'classnames';
|
|
12
12
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
13
13
|
|
|
14
|
-
const ChatButtonSkeleton =
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
} = _ref;
|
|
14
|
+
const ChatButtonSkeleton = ({
|
|
15
|
+
className,
|
|
16
|
+
size,
|
|
17
|
+
...rest
|
|
18
|
+
}) => {
|
|
20
19
|
const prefix = usePrefix();
|
|
21
20
|
const skeletonClasses = cx(className, `${prefix}--skeleton`, `${prefix}--btn`, `${prefix}--chat-btn`, {
|
|
22
21
|
[`${prefix}--layout--size-${size}`]: size
|
|
@@ -13,18 +13,17 @@ import Button from '../Button/Button.js';
|
|
|
13
13
|
import '../Button/Button.Skeleton.js';
|
|
14
14
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
15
15
|
|
|
16
|
-
const ChatButton = /*#__PURE__*/React.forwardRef(function ChatButton(
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
} = _ref;
|
|
16
|
+
const ChatButton = /*#__PURE__*/React.forwardRef(function ChatButton({
|
|
17
|
+
className,
|
|
18
|
+
children,
|
|
19
|
+
disabled,
|
|
20
|
+
isQuickAction,
|
|
21
|
+
isSelected,
|
|
22
|
+
kind,
|
|
23
|
+
renderIcon,
|
|
24
|
+
size,
|
|
25
|
+
...other
|
|
26
|
+
}, ref) {
|
|
28
27
|
const prefix = usePrefix();
|
|
29
28
|
const classNames = cx(className, {
|
|
30
29
|
[`${prefix}--chat-btn`]: true,
|
|
@@ -11,11 +11,10 @@ import React from 'react';
|
|
|
11
11
|
import cx from 'classnames';
|
|
12
12
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
13
13
|
|
|
14
|
-
const CheckboxSkeleton =
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
} = _ref;
|
|
14
|
+
const CheckboxSkeleton = ({
|
|
15
|
+
className,
|
|
16
|
+
...rest
|
|
17
|
+
}) => {
|
|
19
18
|
const prefix = usePrefix();
|
|
20
19
|
return /*#__PURE__*/React.createElement("div", _extends({
|
|
21
20
|
className: cx(`${prefix}--form-item`, `${prefix}--checkbox-wrapper`, `${prefix}--checkbox-skeleton`, className)
|
|
@@ -17,26 +17,25 @@ import { useId } from '../../internal/useId.js';
|
|
|
17
17
|
import { noopFn } from '../../internal/noopFn.js';
|
|
18
18
|
import { Text } from '../Text/Text.js';
|
|
19
19
|
|
|
20
|
-
const Checkbox = /*#__PURE__*/React.forwardRef((
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
} = _ref;
|
|
20
|
+
const Checkbox = /*#__PURE__*/React.forwardRef(({
|
|
21
|
+
className,
|
|
22
|
+
decorator,
|
|
23
|
+
helperText,
|
|
24
|
+
id,
|
|
25
|
+
labelText,
|
|
26
|
+
onChange = noopFn,
|
|
27
|
+
onClick,
|
|
28
|
+
indeterminate = false,
|
|
29
|
+
invalid,
|
|
30
|
+
invalidText,
|
|
31
|
+
hideLabel,
|
|
32
|
+
readOnly,
|
|
33
|
+
title = '',
|
|
34
|
+
warn,
|
|
35
|
+
warnText,
|
|
36
|
+
slug,
|
|
37
|
+
...other
|
|
38
|
+
}, ref) => {
|
|
40
39
|
const prefix = usePrefix();
|
|
41
40
|
const showWarning = !readOnly && !invalid && warn;
|
|
42
41
|
const showHelper = !invalid && !warn;
|
|
@@ -14,23 +14,22 @@ import { usePrefix } from '../../internal/usePrefix.js';
|
|
|
14
14
|
import { WarningFilled, WarningAltFilled } from '@carbon/icons-react';
|
|
15
15
|
import { useId } from '../../internal/useId.js';
|
|
16
16
|
|
|
17
|
-
const CheckboxGroup =
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
} = _ref;
|
|
17
|
+
const CheckboxGroup = ({
|
|
18
|
+
children,
|
|
19
|
+
className,
|
|
20
|
+
decorator,
|
|
21
|
+
helperText,
|
|
22
|
+
invalid,
|
|
23
|
+
invalidText,
|
|
24
|
+
legendId,
|
|
25
|
+
legendText,
|
|
26
|
+
readOnly,
|
|
27
|
+
warn,
|
|
28
|
+
warnText,
|
|
29
|
+
slug,
|
|
30
|
+
orientation = 'vertical',
|
|
31
|
+
...rest
|
|
32
|
+
}) => {
|
|
34
33
|
const prefix = usePrefix();
|
|
35
34
|
const showWarning = !readOnly && !invalid && warn;
|
|
36
35
|
const showHelper = !invalid && !warn;
|
|
@@ -9,11 +9,10 @@ import PropTypes from 'prop-types';
|
|
|
9
9
|
import React from 'react';
|
|
10
10
|
import { PrefixContext } from '../../internal/usePrefix.js';
|
|
11
11
|
|
|
12
|
-
function ClassPrefix(
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
} = _ref;
|
|
12
|
+
function ClassPrefix({
|
|
13
|
+
children,
|
|
14
|
+
prefix
|
|
15
|
+
}) {
|
|
17
16
|
return /*#__PURE__*/React.createElement(PrefixContext.Provider, {
|
|
18
17
|
value: prefix
|
|
19
18
|
}, children);
|
|
@@ -12,12 +12,11 @@ import React from 'react';
|
|
|
12
12
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
13
13
|
|
|
14
14
|
var _span, _span2, _span3, _span4;
|
|
15
|
-
function CodeSnippetSkeleton(
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
} = _ref;
|
|
15
|
+
function CodeSnippetSkeleton({
|
|
16
|
+
className: containerClassName,
|
|
17
|
+
type = 'single',
|
|
18
|
+
...rest
|
|
19
|
+
}) {
|
|
21
20
|
const prefix = usePrefix();
|
|
22
21
|
const className = cx(containerClassName, {
|
|
23
22
|
[`${prefix}--snippet`]: true,
|
|
@@ -27,32 +27,31 @@ const defaultMaxCollapsedNumberOfRows = 15;
|
|
|
27
27
|
const defaultMaxExpandedNumberOfRows = 0;
|
|
28
28
|
const defaultMinCollapsedNumberOfRows = 3;
|
|
29
29
|
const defaultMinExpandedNumberOfRows = 16;
|
|
30
|
-
function CodeSnippet(
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
} = _ref;
|
|
30
|
+
function CodeSnippet({
|
|
31
|
+
align = 'bottom',
|
|
32
|
+
autoAlign = false,
|
|
33
|
+
className,
|
|
34
|
+
type = 'single',
|
|
35
|
+
children,
|
|
36
|
+
disabled,
|
|
37
|
+
feedback,
|
|
38
|
+
feedbackTimeout,
|
|
39
|
+
onClick,
|
|
40
|
+
['aria-label']: ariaLabel = 'Copy to clipboard',
|
|
41
|
+
ariaLabel: deprecatedAriaLabel,
|
|
42
|
+
copyText,
|
|
43
|
+
copyButtonDescription,
|
|
44
|
+
light,
|
|
45
|
+
showMoreText = 'Show more',
|
|
46
|
+
showLessText = 'Show less',
|
|
47
|
+
hideCopyButton,
|
|
48
|
+
wrapText = false,
|
|
49
|
+
maxCollapsedNumberOfRows = defaultMaxCollapsedNumberOfRows,
|
|
50
|
+
maxExpandedNumberOfRows = defaultMaxExpandedNumberOfRows,
|
|
51
|
+
minCollapsedNumberOfRows = defaultMinCollapsedNumberOfRows,
|
|
52
|
+
minExpandedNumberOfRows = defaultMinExpandedNumberOfRows,
|
|
53
|
+
...rest
|
|
54
|
+
}) {
|
|
56
55
|
const [expandedCode, setExpandedCode] = useState(false);
|
|
57
56
|
const [shouldShowMoreLessBtn, setShouldShowMoreLessBtn] = useState(false);
|
|
58
57
|
const {
|