@itwin/itwinui-react 3.0.0-dev.9 → 3.0.1
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/CHANGELOG.md +80 -768
- package/README.md +5 -7
- package/cjs/core/Alert/Alert.d.ts +1 -1
- package/cjs/core/Alert/Alert.js +4 -3
- package/cjs/core/Avatar/Avatar.js +2 -1
- package/cjs/core/Breadcrumbs/Breadcrumbs.js +23 -6
- package/cjs/core/ButtonGroup/ButtonGroup.js +6 -8
- package/cjs/core/Buttons/{Button/Button.d.ts → Button.d.ts} +2 -2
- package/cjs/core/Buttons/{Button/Button.js → Button.js} +1 -1
- package/{esm/core/Buttons/DropdownButton → cjs/core/Buttons}/DropdownButton.d.ts +3 -3
- package/cjs/core/Buttons/{DropdownButton/DropdownButton.js → DropdownButton.js} +7 -7
- package/{esm/core/Buttons/IconButton → cjs/core/Buttons}/IconButton.d.ts +2 -2
- package/cjs/core/Buttons/{IconButton/IconButton.js → IconButton.js} +6 -3
- package/{esm/core/Buttons/IdeasButton → cjs/core/Buttons}/IdeasButton.d.ts +1 -1
- package/cjs/core/Buttons/{IdeasButton/IdeasButton.js → IdeasButton.js} +3 -3
- package/cjs/core/Buttons/{SplitButton/SplitButton.d.ts → SplitButton.d.ts} +3 -3
- package/cjs/core/Buttons/{SplitButton/SplitButton.js → SplitButton.js} +14 -13
- package/cjs/core/Carousel/Carousel.d.ts +14 -7
- package/cjs/core/Carousel/Carousel.js +9 -39
- package/cjs/core/Carousel/CarouselContext.d.ts +0 -4
- package/cjs/core/Carousel/CarouselDot.js +1 -1
- package/cjs/core/Carousel/CarouselDotsList.js +26 -2
- package/cjs/core/Carousel/CarouselNavigation.d.ts +3 -3
- package/cjs/core/Carousel/CarouselNavigation.js +13 -26
- package/cjs/core/Carousel/CarouselSlide.d.ts +1 -1
- package/cjs/core/Carousel/CarouselSlide.js +12 -2
- package/cjs/core/Carousel/CarouselSlider.d.ts +1 -1
- package/cjs/core/Carousel/CarouselSlider.js +2 -2
- package/cjs/core/Checkbox/Checkbox.js +7 -7
- package/cjs/core/ColorPicker/ColorBuilder.js +5 -3
- package/cjs/core/ColorPicker/ColorInputPanel.js +50 -30
- package/cjs/core/ColorPicker/ColorPalette.js +2 -80
- package/cjs/core/ColorPicker/ColorPicker.d.ts +9 -0
- package/cjs/core/ColorPicker/ColorPicker.js +6 -1
- package/cjs/core/ColorPicker/ColorSwatch.d.ts +1 -1
- package/cjs/core/ColorPicker/ColorSwatch.js +25 -15
- package/cjs/core/ComboBox/ComboBox.d.ts +6 -1
- package/cjs/core/ComboBox/ComboBox.js +19 -18
- package/cjs/core/ComboBox/ComboBoxEndIcon.js +2 -1
- package/cjs/core/ComboBox/ComboBoxInput.d.ts +1 -1
- package/cjs/core/ComboBox/ComboBoxInput.js +10 -10
- package/cjs/core/ComboBox/ComboBoxInputContainer.js +6 -6
- package/cjs/core/ComboBox/ComboBoxMenu.d.ts +1 -1
- package/cjs/core/ComboBox/ComboBoxMenu.js +12 -14
- package/cjs/core/ComboBox/helpers.d.ts +1 -1
- package/cjs/core/DatePicker/DatePicker.d.ts +9 -0
- package/cjs/core/DatePicker/DatePicker.js +13 -8
- package/cjs/core/Dialog/DialogBackdrop.js +4 -4
- package/cjs/core/Dialog/DialogTitleBar.js +2 -2
- package/cjs/core/{utils/components → Divider}/Divider.d.ts +1 -1
- package/cjs/core/{utils/components → Divider}/Divider.js +1 -1
- package/cjs/core/DropdownMenu/DropdownMenu.d.ts +2 -2
- package/cjs/core/DropdownMenu/DropdownMenu.js +4 -3
- package/cjs/core/ExpandableBlock/ExpandableBlock.d.ts +1 -1
- package/cjs/core/ExpandableBlock/ExpandableBlock.js +3 -2
- package/cjs/core/FileUpload/FileUploadCard.js +3 -2
- package/cjs/core/FileUpload/FileUploadTemplate.js +1 -1
- package/cjs/core/{utils/components → Flex}/Flex.d.ts +2 -2
- package/cjs/core/{utils/components → Flex}/Flex.js +1 -1
- package/cjs/core/Header/Header.js +11 -11
- package/cjs/core/Header/HeaderBasicButton.d.ts +1 -1
- package/cjs/core/Header/HeaderButton.d.ts +2 -2
- package/cjs/core/Header/HeaderDropdownButton.d.ts +1 -1
- package/cjs/core/Header/HeaderDropdownButton.js +6 -6
- package/cjs/core/Header/HeaderSplitButton.d.ts +1 -1
- package/cjs/core/Header/HeaderSplitButton.js +7 -7
- package/{esm/core/utils/components → cjs/core/Icon}/Icon.d.ts +2 -2
- package/cjs/core/{utils/components → Icon}/Icon.js +1 -1
- package/cjs/core/InformationPanel/InformationPanelHeader.js +7 -7
- package/cjs/core/Input/Input.d.ts +0 -1
- package/cjs/core/Input/Input.js +0 -1
- package/cjs/core/InputGroup/InputGroup.d.ts +1 -1
- package/cjs/core/InputGroup/InputGroup.js +6 -6
- package/cjs/core/InputWithDecorations/InputWithDecorations.d.ts +1 -1
- package/cjs/core/InputWithDecorations/InputWithDecorations.js +2 -2
- package/cjs/core/LabeledInput/LabeledInput.d.ts +4 -4
- package/cjs/core/LabeledInput/LabeledInput.js +11 -13
- package/cjs/core/LabeledSelect/LabeledSelect.d.ts +2 -2
- package/cjs/core/LabeledSelect/LabeledSelect.js +10 -9
- package/cjs/core/LabeledTextarea/LabeledTextarea.d.ts +1 -1
- package/cjs/core/LabeledTextarea/LabeledTextarea.js +2 -2
- package/{esm/core/utils/components → cjs/core/LinkAction}/LinkAction.d.ts +2 -2
- package/cjs/core/{utils/components → LinkAction}/LinkAction.js +1 -1
- package/cjs/core/Menu/MenuItem.js +2 -1
- package/cjs/core/Menu/MenuItemSkeleton.js +2 -1
- package/cjs/core/Modal/Modal.js +5 -5
- package/cjs/core/NonIdealState/ErrorPage.js +17 -15
- package/cjs/core/{utils/components → Popover}/Popover.d.ts +29 -13
- package/cjs/core/{utils/components → Popover}/Popover.js +43 -25
- package/cjs/core/RadioTiles/RadioTileGroup.d.ts +1 -1
- package/cjs/core/RadioTiles/RadioTileGroup.js +4 -4
- package/cjs/core/SearchBox/SearchBox.d.ts +3 -2
- package/cjs/core/SearchBox/SearchBox.js +4 -3
- package/cjs/core/Select/Select.d.ts +2 -2
- package/cjs/core/Select/Select.js +39 -30
- package/cjs/core/Select/SelectTagContainer.js +2 -2
- package/cjs/core/SideNavigation/SideNavigation.js +5 -5
- package/cjs/core/SideNavigation/SidenavButton.d.ts +1 -1
- package/cjs/core/SideNavigation/SidenavButton.js +2 -2
- package/cjs/core/Slider/Slider.d.ts +3 -7
- package/cjs/core/Slider/Slider.js +8 -22
- package/cjs/core/Slider/Thumb.d.ts +2 -3
- package/cjs/core/Slider/Thumb.js +5 -9
- package/cjs/core/StatusMessage/StatusMessage.d.ts +1 -1
- package/cjs/core/StatusMessage/StatusMessage.js +2 -1
- package/cjs/core/Stepper/StepperStep.js +7 -7
- package/cjs/core/Stepper/WorkflowDiagramStep.js +5 -5
- package/cjs/core/Surface/Surface.d.ts +8 -0
- package/cjs/core/Surface/Surface.js +19 -1
- package/cjs/core/Table/SubRowExpander.d.ts +1 -1
- package/cjs/core/Table/SubRowExpander.js +2 -2
- package/cjs/core/Table/Table.d.ts +1 -1
- package/cjs/core/Table/Table.js +53 -60
- package/cjs/core/Table/TableCell.d.ts +1 -1
- package/cjs/core/Table/TablePaginator.js +27 -25
- package/cjs/core/Table/TableRowMemoized.d.ts +1 -1
- package/cjs/core/Table/actionHandlers/expandHandler.d.ts +1 -1
- package/cjs/core/Table/actionHandlers/filterHandler.d.ts +1 -1
- package/cjs/core/Table/actionHandlers/resizeHandler.d.ts +17 -17
- package/cjs/core/Table/actionHandlers/selectHandler.d.ts +8 -8
- package/cjs/core/Table/cells/DefaultCell.d.ts +1 -1
- package/cjs/core/Table/cells/EditableCell.d.ts +1 -1
- package/cjs/core/Table/columns/actionColumn.d.ts +2 -2
- package/cjs/core/Table/columns/actionColumn.js +10 -15
- package/cjs/core/Table/columns/expanderColumn.d.ts +1 -1
- package/cjs/core/Table/columns/expanderColumn.js +5 -4
- package/cjs/core/Table/columns/selectionColumn.d.ts +1 -1
- package/cjs/core/Table/columns/selectionColumn.js +5 -5
- package/cjs/core/Table/filters/DateRangeFilter/DatePickerInput.d.ts +1 -1
- package/cjs/core/Table/filters/DateRangeFilter/DatePickerInput.js +25 -19
- package/cjs/core/Table/filters/FilterButtonBar.js +3 -3
- package/cjs/core/Table/filters/FilterToggle.d.ts +1 -1
- package/cjs/core/Table/filters/FilterToggle.js +5 -3
- package/cjs/core/Table/filters/NumberRangeFilter/NumberRangeFilter.js +3 -3
- package/cjs/core/Table/filters/TextFilter/TextFilter.js +2 -2
- package/cjs/core/Table/filters/customFilterFunctions.d.ts +1 -1
- package/cjs/core/Table/filters/defaultFilterFunctions.d.ts +1 -1
- package/cjs/core/Table/filters/types.d.ts +2 -19
- package/cjs/core/Table/hooks/useColumnDragAndDrop.d.ts +1 -1
- package/cjs/core/Table/hooks/useExpanderCell.d.ts +1 -1
- package/cjs/core/Table/hooks/useResizeColumns.d.ts +1 -1
- package/cjs/core/Table/hooks/useScrollToRow.d.ts +1 -1
- package/cjs/core/Table/hooks/useScrollToRow.js +1 -1
- package/cjs/core/Table/hooks/useSelectionCell.d.ts +1 -1
- package/cjs/core/Table/hooks/useStickyColumns.d.ts +1 -1
- package/cjs/core/Table/hooks/useSubRowFiltering.d.ts +1 -1
- package/cjs/core/Table/hooks/useSubRowSelection.d.ts +1 -1
- package/cjs/core/Table/index.d.ts +1 -1
- package/cjs/core/Table/utils.d.ts +1 -1
- package/cjs/core/Tabs/Tabs.d.ts +222 -52
- package/cjs/core/Tabs/Tabs.js +429 -375
- package/cjs/core/Tag/Tag.js +2 -2
- package/cjs/core/Textarea/Textarea.js +2 -2
- package/cjs/core/ThemeProvider/ThemeProvider.d.ts +3 -2
- package/cjs/core/ThemeProvider/ThemeProvider.js +17 -8
- package/cjs/core/Tile/Tile.d.ts +2 -2
- package/cjs/core/Tile/Tile.js +20 -18
- package/cjs/core/Toast/Toast.js +2 -2
- package/cjs/core/TransferList/TransferList.d.ts +1 -1
- package/cjs/core/TransferList/TransferList.js +6 -5
- package/cjs/core/Tree/TreeNodeExpander.d.ts +1 -1
- package/cjs/core/Tree/TreeNodeExpander.js +2 -2
- package/{esm/core/Typography/Anchor → cjs/core/Typography}/Anchor.d.ts +1 -1
- package/cjs/core/Typography/{Anchor/Anchor.js → Anchor.js} +1 -1
- package/{esm/core/Typography/Blockquote → cjs/core/Typography}/Blockquote.d.ts +1 -1
- package/cjs/core/Typography/{Blockquote/Blockquote.js → Blockquote.js} +1 -1
- package/cjs/core/Typography/{Code/Code.d.ts → Code.d.ts} +1 -1
- package/cjs/core/Typography/{Code/Code.js → Code.js} +1 -1
- package/{esm/core/Typography/Kbd → cjs/core/Typography}/Kbd.d.ts +1 -1
- package/cjs/core/Typography/{Kbd/Kbd.js → Kbd.js} +1 -1
- package/{esm/core/Typography/Text → cjs/core/Typography}/Text.d.ts +1 -1
- package/cjs/core/Typography/{Text/Text.js → Text.js} +1 -1
- package/{esm/core/utils/components → cjs/core/VisuallyHidden}/VisuallyHidden.d.ts +1 -1
- package/cjs/core/{utils/components → VisuallyHidden}/VisuallyHidden.js +1 -1
- package/cjs/core/utils/components/AutoclearingHiddenLiveRegion.js +1 -1
- package/cjs/core/utils/components/InputContainer.js +4 -4
- package/cjs/core/utils/components/WithCSSTransition.js +7 -1
- package/cjs/core/utils/components/index.d.ts +0 -6
- package/cjs/core/utils/components/index.js +0 -6
- package/cjs/core/utils/functions/dev.d.ts +11 -0
- package/cjs/core/utils/functions/dev.js +34 -0
- package/cjs/core/utils/functions/index.d.ts +1 -0
- package/cjs/core/utils/functions/index.js +1 -0
- package/cjs/core/utils/hooks/useGlobals.d.ts +1 -1
- package/cjs/core/utils/hooks/useGlobals.js +3 -7
- package/cjs/core/utils/hooks/useOverflow.js +3 -1
- package/cjs/index.d.ts +112 -2
- package/cjs/index.js +950 -5
- package/cjs/react-table/react-table.d.ts +745 -0
- package/cjs/{core/Badge/index.js → react-table/react-table.js} +5 -10
- package/cjs/styles.js +15 -15
- package/esm/core/Alert/Alert.d.ts +1 -1
- package/esm/core/Alert/Alert.js +2 -2
- package/esm/core/Avatar/Avatar.js +2 -6
- package/esm/core/Breadcrumbs/Breadcrumbs.js +24 -6
- package/esm/core/ButtonGroup/ButtonGroup.js +6 -8
- package/esm/core/Buttons/{Button/Button.d.ts → Button.d.ts} +2 -2
- package/esm/core/Buttons/{Button/Button.js → Button.js} +1 -1
- package/{cjs/core/Buttons/DropdownButton → esm/core/Buttons}/DropdownButton.d.ts +3 -3
- package/esm/core/Buttons/{DropdownButton/DropdownButton.js → DropdownButton.js} +3 -3
- package/{cjs/core/Buttons/IconButton → esm/core/Buttons}/IconButton.d.ts +2 -2
- package/esm/core/Buttons/{IconButton/IconButton.js → IconButton.js} +3 -2
- package/{cjs/core/Buttons/IdeasButton → esm/core/Buttons}/IdeasButton.d.ts +1 -1
- package/esm/core/Buttons/{IdeasButton/IdeasButton.js → IdeasButton.js} +2 -2
- package/esm/core/Buttons/{SplitButton/SplitButton.d.ts → SplitButton.d.ts} +3 -3
- package/esm/core/Buttons/{SplitButton/SplitButton.js → SplitButton.js} +5 -5
- package/esm/core/Carousel/Carousel.d.ts +14 -7
- package/esm/core/Carousel/Carousel.js +9 -39
- package/esm/core/Carousel/CarouselContext.d.ts +0 -4
- package/esm/core/Carousel/CarouselDot.js +1 -1
- package/esm/core/Carousel/CarouselDotsList.js +26 -2
- package/esm/core/Carousel/CarouselNavigation.d.ts +3 -3
- package/esm/core/Carousel/CarouselNavigation.js +6 -23
- package/esm/core/Carousel/CarouselSlide.d.ts +1 -1
- package/esm/core/Carousel/CarouselSlide.js +15 -3
- package/esm/core/Carousel/CarouselSlider.d.ts +1 -1
- package/esm/core/Carousel/CarouselSlider.js +2 -2
- package/esm/core/Checkbox/Checkbox.js +1 -1
- package/esm/core/ColorPicker/ColorBuilder.js +3 -1
- package/esm/core/ColorPicker/ColorInputPanel.js +27 -7
- package/esm/core/ColorPicker/ColorPalette.js +3 -83
- package/esm/core/ColorPicker/ColorPicker.d.ts +9 -0
- package/esm/core/ColorPicker/ColorPicker.js +6 -1
- package/esm/core/ColorPicker/ColorSwatch.d.ts +1 -1
- package/esm/core/ColorPicker/ColorSwatch.js +18 -12
- package/esm/core/ComboBox/ComboBox.d.ts +6 -1
- package/esm/core/ComboBox/ComboBox.js +6 -4
- package/esm/core/ComboBox/ComboBoxEndIcon.js +2 -1
- package/esm/core/ComboBox/ComboBoxInput.d.ts +1 -1
- package/esm/core/ComboBox/ComboBoxInput.js +1 -1
- package/esm/core/ComboBox/ComboBoxInputContainer.js +1 -1
- package/esm/core/ComboBox/ComboBoxMenu.d.ts +1 -1
- package/esm/core/ComboBox/ComboBoxMenu.js +2 -4
- package/esm/core/ComboBox/helpers.d.ts +1 -1
- package/esm/core/DatePicker/DatePicker.d.ts +9 -0
- package/esm/core/DatePicker/DatePicker.js +12 -3
- package/esm/core/Dialog/DialogBackdrop.js +1 -1
- package/esm/core/Dialog/DialogTitleBar.js +1 -1
- package/esm/core/{utils/components → Divider}/Divider.d.ts +1 -1
- package/esm/core/{utils/components → Divider}/Divider.js +1 -1
- package/esm/core/DropdownMenu/DropdownMenu.d.ts +2 -2
- package/esm/core/DropdownMenu/DropdownMenu.js +2 -3
- package/esm/core/ExpandableBlock/ExpandableBlock.d.ts +1 -1
- package/esm/core/ExpandableBlock/ExpandableBlock.js +1 -1
- package/esm/core/FileUpload/FileUploadCard.js +2 -2
- package/esm/core/FileUpload/FileUploadTemplate.js +1 -1
- package/esm/core/{utils/components → Flex}/Flex.d.ts +2 -2
- package/esm/core/{utils/components → Flex}/Flex.js +1 -1
- package/esm/core/Header/Header.js +2 -2
- package/esm/core/Header/HeaderBasicButton.d.ts +1 -1
- package/esm/core/Header/HeaderButton.d.ts +2 -2
- package/esm/core/Header/HeaderDropdownButton.d.ts +1 -1
- package/esm/core/Header/HeaderDropdownButton.js +1 -1
- package/esm/core/Header/HeaderSplitButton.d.ts +1 -1
- package/esm/core/Header/HeaderSplitButton.js +1 -1
- package/{cjs/core/utils/components → esm/core/Icon}/Icon.d.ts +2 -2
- package/esm/core/{utils/components → Icon}/Icon.js +1 -1
- package/esm/core/InformationPanel/InformationPanelHeader.js +1 -1
- package/esm/core/Input/Input.d.ts +0 -1
- package/esm/core/Input/Input.js +0 -1
- package/esm/core/InputGroup/InputGroup.d.ts +1 -1
- package/esm/core/InputGroup/InputGroup.js +3 -3
- package/esm/core/InputWithDecorations/InputWithDecorations.d.ts +1 -1
- package/esm/core/InputWithDecorations/InputWithDecorations.js +1 -1
- package/esm/core/LabeledInput/LabeledInput.d.ts +4 -4
- package/esm/core/LabeledInput/LabeledInput.js +5 -4
- package/esm/core/LabeledSelect/LabeledSelect.d.ts +2 -2
- package/esm/core/LabeledSelect/LabeledSelect.js +6 -4
- package/esm/core/LabeledTextarea/LabeledTextarea.d.ts +1 -1
- package/esm/core/LabeledTextarea/LabeledTextarea.js +2 -2
- package/{cjs/core/utils/components → esm/core/LinkAction}/LinkAction.d.ts +2 -2
- package/esm/core/{utils/components → LinkAction}/LinkAction.js +1 -1
- package/esm/core/Menu/MenuItem.js +1 -1
- package/esm/core/Menu/MenuItemSkeleton.js +2 -1
- package/esm/core/Modal/Modal.js +1 -1
- package/esm/core/NonIdealState/ErrorPage.js +2 -2
- package/esm/core/{utils/components → Popover}/Popover.d.ts +29 -13
- package/esm/core/{utils/components → Popover}/Popover.js +45 -25
- package/esm/core/RadioTiles/RadioTileGroup.d.ts +1 -1
- package/esm/core/RadioTiles/RadioTileGroup.js +1 -1
- package/esm/core/SearchBox/SearchBox.d.ts +3 -2
- package/esm/core/SearchBox/SearchBox.js +2 -2
- package/esm/core/Select/Select.d.ts +2 -2
- package/esm/core/Select/Select.js +17 -10
- package/esm/core/Select/SelectTagContainer.js +1 -1
- package/esm/core/SideNavigation/SideNavigation.js +2 -2
- package/esm/core/SideNavigation/SidenavButton.d.ts +1 -1
- package/esm/core/SideNavigation/SidenavButton.js +1 -1
- package/esm/core/Slider/Slider.d.ts +3 -7
- package/esm/core/Slider/Slider.js +8 -19
- package/esm/core/Slider/Thumb.d.ts +2 -3
- package/esm/core/Slider/Thumb.js +2 -6
- package/esm/core/StatusMessage/StatusMessage.d.ts +1 -1
- package/esm/core/StatusMessage/StatusMessage.js +2 -1
- package/esm/core/Stepper/StepperStep.js +1 -1
- package/esm/core/Stepper/WorkflowDiagramStep.js +1 -1
- package/esm/core/Surface/Surface.d.ts +8 -0
- package/esm/core/Surface/Surface.js +19 -1
- package/esm/core/Table/SubRowExpander.d.ts +1 -1
- package/esm/core/Table/SubRowExpander.js +1 -1
- package/esm/core/Table/Table.d.ts +1 -1
- package/esm/core/Table/Table.js +7 -13
- package/esm/core/Table/TableCell.d.ts +1 -1
- package/esm/core/Table/TablePaginator.js +5 -3
- package/esm/core/Table/TableRowMemoized.d.ts +1 -1
- package/esm/core/Table/actionHandlers/expandHandler.d.ts +1 -1
- package/esm/core/Table/actionHandlers/filterHandler.d.ts +1 -1
- package/esm/core/Table/actionHandlers/resizeHandler.d.ts +17 -17
- package/esm/core/Table/actionHandlers/selectHandler.d.ts +8 -8
- package/esm/core/Table/cells/DefaultCell.d.ts +1 -1
- package/esm/core/Table/cells/EditableCell.d.ts +1 -1
- package/esm/core/Table/columns/actionColumn.d.ts +2 -2
- package/esm/core/Table/columns/actionColumn.js +4 -6
- package/esm/core/Table/columns/expanderColumn.d.ts +1 -1
- package/esm/core/Table/columns/expanderColumn.js +2 -1
- package/esm/core/Table/columns/selectionColumn.d.ts +1 -1
- package/esm/core/Table/columns/selectionColumn.js +1 -1
- package/esm/core/Table/filters/DateRangeFilter/DatePickerInput.d.ts +1 -1
- package/esm/core/Table/filters/DateRangeFilter/DatePickerInput.js +8 -5
- package/esm/core/Table/filters/FilterButtonBar.js +1 -1
- package/esm/core/Table/filters/FilterToggle.d.ts +1 -1
- package/esm/core/Table/filters/FilterToggle.js +4 -7
- package/esm/core/Table/filters/NumberRangeFilter/NumberRangeFilter.js +1 -1
- package/esm/core/Table/filters/TextFilter/TextFilter.js +1 -1
- package/esm/core/Table/filters/customFilterFunctions.d.ts +1 -1
- package/esm/core/Table/filters/defaultFilterFunctions.d.ts +1 -1
- package/esm/core/Table/filters/types.d.ts +2 -19
- package/esm/core/Table/hooks/useColumnDragAndDrop.d.ts +1 -1
- package/esm/core/Table/hooks/useExpanderCell.d.ts +1 -1
- package/esm/core/Table/hooks/useResizeColumns.d.ts +1 -1
- package/esm/core/Table/hooks/useScrollToRow.d.ts +1 -1
- package/esm/core/Table/hooks/useScrollToRow.js +1 -1
- package/esm/core/Table/hooks/useSelectionCell.d.ts +1 -1
- package/esm/core/Table/hooks/useStickyColumns.d.ts +1 -1
- package/esm/core/Table/hooks/useSubRowFiltering.d.ts +1 -1
- package/esm/core/Table/hooks/useSubRowSelection.d.ts +1 -1
- package/esm/core/Table/index.d.ts +1 -1
- package/esm/core/Table/utils.d.ts +1 -1
- package/esm/core/Tabs/Tabs.d.ts +222 -52
- package/esm/core/Tabs/Tabs.js +424 -368
- package/esm/core/Tag/Tag.js +1 -1
- package/esm/core/Textarea/Textarea.js +1 -1
- package/esm/core/ThemeProvider/ThemeProvider.d.ts +3 -2
- package/esm/core/ThemeProvider/ThemeProvider.js +17 -8
- package/esm/core/Tile/Tile.d.ts +2 -2
- package/esm/core/Tile/Tile.js +15 -14
- package/esm/core/Toast/Toast.js +1 -1
- package/esm/core/TransferList/TransferList.d.ts +1 -1
- package/esm/core/TransferList/TransferList.js +3 -2
- package/esm/core/Tree/TreeNodeExpander.d.ts +1 -1
- package/esm/core/Tree/TreeNodeExpander.js +1 -1
- package/{cjs/core/Typography/Anchor → esm/core/Typography}/Anchor.d.ts +1 -1
- package/esm/core/Typography/{Anchor/Anchor.js → Anchor.js} +1 -1
- package/{cjs/core/Typography/Blockquote → esm/core/Typography}/Blockquote.d.ts +1 -1
- package/esm/core/Typography/{Blockquote/Blockquote.js → Blockquote.js} +1 -1
- package/esm/core/Typography/{Code/Code.d.ts → Code.d.ts} +1 -1
- package/esm/core/Typography/{Code/Code.js → Code.js} +1 -1
- package/{cjs/core/Typography/Kbd → esm/core/Typography}/Kbd.d.ts +1 -1
- package/esm/core/Typography/{Kbd/Kbd.js → Kbd.js} +1 -1
- package/{cjs/core/Typography/Text → esm/core/Typography}/Text.d.ts +1 -1
- package/esm/core/Typography/{Text/Text.js → Text.js} +1 -1
- package/{cjs/core/utils/components → esm/core/VisuallyHidden}/VisuallyHidden.d.ts +1 -1
- package/esm/core/{utils/components → VisuallyHidden}/VisuallyHidden.js +1 -1
- package/esm/core/utils/components/AutoclearingHiddenLiveRegion.js +1 -1
- package/esm/core/utils/components/InputContainer.js +2 -2
- package/esm/core/utils/components/WithCSSTransition.js +7 -1
- package/esm/core/utils/components/index.d.ts +0 -6
- package/esm/core/utils/components/index.js +0 -6
- package/esm/core/utils/functions/dev.d.ts +11 -0
- package/esm/core/utils/functions/dev.js +29 -0
- package/esm/core/utils/functions/index.d.ts +1 -0
- package/esm/core/utils/functions/index.js +1 -0
- package/esm/core/utils/hooks/useGlobals.d.ts +1 -1
- package/esm/core/utils/hooks/useGlobals.js +1 -5
- package/esm/core/utils/hooks/useOverflow.js +3 -1
- package/esm/index.d.ts +112 -2
- package/esm/index.js +123 -2
- package/esm/react-table/react-table.d.ts +745 -0
- package/esm/{core/Backdrop/index.js → react-table/react-table.js} +5 -1
- package/esm/styles.js +15 -15
- package/package.json +22 -21
- package/react-table.d.ts +745 -0
- package/styles.css +57 -66
- package/cjs/core/Alert/index.d.ts +0 -3
- package/cjs/core/Alert/index.js +0 -15
- package/cjs/core/Avatar/index.d.ts +0 -3
- package/cjs/core/Avatar/index.js +0 -15
- package/cjs/core/AvatarGroup/index.d.ts +0 -3
- package/cjs/core/AvatarGroup/index.js +0 -15
- package/cjs/core/Backdrop/index.d.ts +0 -1
- package/cjs/core/Backdrop/index.js +0 -14
- package/cjs/core/Badge/index.d.ts +0 -3
- package/cjs/core/Breadcrumbs/index.d.ts +0 -3
- package/cjs/core/Breadcrumbs/index.js +0 -15
- package/cjs/core/ButtonGroup/index.d.ts +0 -3
- package/cjs/core/ButtonGroup/index.js +0 -15
- package/cjs/core/Buttons/Button/index.d.ts +0 -3
- package/cjs/core/Buttons/Button/index.js +0 -15
- package/cjs/core/Buttons/DropdownButton/index.d.ts +0 -3
- package/cjs/core/Buttons/DropdownButton/index.js +0 -15
- package/cjs/core/Buttons/IconButton/index.d.ts +0 -3
- package/cjs/core/Buttons/IconButton/index.js +0 -15
- package/cjs/core/Buttons/IdeasButton/index.d.ts +0 -3
- package/cjs/core/Buttons/IdeasButton/index.js +0 -15
- package/cjs/core/Buttons/SplitButton/index.d.ts +0 -3
- package/cjs/core/Buttons/SplitButton/index.js +0 -15
- package/cjs/core/Buttons/index.d.ts +0 -5
- package/cjs/core/Buttons/index.js +0 -47
- package/cjs/core/Carousel/index.d.ts +0 -3
- package/cjs/core/Carousel/index.js +0 -15
- package/cjs/core/Checkbox/index.d.ts +0 -3
- package/cjs/core/Checkbox/index.js +0 -15
- package/cjs/core/ColorPicker/index.d.ts +0 -7
- package/cjs/core/ColorPicker/index.js +0 -48
- package/cjs/core/ComboBox/index.d.ts +0 -3
- package/cjs/core/ComboBox/index.js +0 -15
- package/cjs/core/DatePicker/index.d.ts +0 -3
- package/cjs/core/DatePicker/index.js +0 -21
- package/cjs/core/Dialog/index.d.ts +0 -3
- package/cjs/core/Dialog/index.js +0 -15
- package/cjs/core/DropdownMenu/index.d.ts +0 -4
- package/cjs/core/DropdownMenu/index.js +0 -15
- package/cjs/core/ExpandableBlock/index.d.ts +0 -3
- package/cjs/core/ExpandableBlock/index.js +0 -15
- package/cjs/core/Fieldset/index.d.ts +0 -3
- package/cjs/core/Fieldset/index.js +0 -15
- package/cjs/core/FileUpload/index.d.ts +0 -6
- package/cjs/core/FileUpload/index.js +0 -40
- package/cjs/core/Footer/index.d.ts +0 -4
- package/cjs/core/Footer/index.js +0 -21
- package/cjs/core/Header/index.d.ts +0 -6
- package/cjs/core/Header/index.js +0 -40
- package/cjs/core/InformationPanel/index.d.ts +0 -7
- package/cjs/core/InformationPanel/index.js +0 -48
- package/cjs/core/Input/index.d.ts +0 -3
- package/cjs/core/Input/index.js +0 -15
- package/cjs/core/InputGrid/index.d.ts +0 -3
- package/cjs/core/InputGrid/index.js +0 -15
- package/cjs/core/InputGroup/index.d.ts +0 -3
- package/cjs/core/InputGroup/index.js +0 -15
- package/cjs/core/InputWithDecorations/index.d.ts +0 -3
- package/cjs/core/InputWithDecorations/index.js +0 -15
- package/cjs/core/Label/index.d.ts +0 -3
- package/cjs/core/Label/index.js +0 -15
- package/cjs/core/LabeledInput/index.d.ts +0 -3
- package/cjs/core/LabeledInput/index.js +0 -15
- package/cjs/core/LabeledSelect/index.d.ts +0 -3
- package/cjs/core/LabeledSelect/index.js +0 -15
- package/cjs/core/LabeledTextarea/index.d.ts +0 -3
- package/cjs/core/LabeledTextarea/index.js +0 -15
- package/cjs/core/List/index.d.ts +0 -2
- package/cjs/core/List/index.js +0 -21
- package/cjs/core/Menu/index.d.ts +0 -5
- package/cjs/core/Menu/index.js +0 -47
- package/cjs/core/Modal/index.d.ts +0 -5
- package/cjs/core/Modal/index.js +0 -29
- package/cjs/core/NonIdealState/index.d.ts +0 -5
- package/cjs/core/NonIdealState/index.js +0 -22
- package/cjs/core/NotificationMarker/index.d.ts +0 -3
- package/cjs/core/NotificationMarker/index.js +0 -15
- package/cjs/core/Overlay/index.d.ts +0 -1
- package/cjs/core/Overlay/index.js +0 -14
- package/cjs/core/ProgressIndicators/index.d.ts +0 -2
- package/cjs/core/ProgressIndicators/index.js +0 -21
- package/cjs/core/Radio/index.d.ts +0 -3
- package/cjs/core/Radio/index.js +0 -15
- package/cjs/core/RadioTiles/index.d.ts +0 -4
- package/cjs/core/RadioTiles/index.js +0 -22
- package/cjs/core/SearchBox/index.d.ts +0 -3
- package/cjs/core/SearchBox/index.js +0 -15
- package/cjs/core/Select/index.d.ts +0 -4
- package/cjs/core/Select/index.js +0 -15
- package/cjs/core/SideNavigation/index.d.ts +0 -6
- package/cjs/core/SideNavigation/index.js +0 -40
- package/cjs/core/SkipToContentLink/index.d.ts +0 -3
- package/cjs/core/SkipToContentLink/index.js +0 -15
- package/cjs/core/Slider/index.d.ts +0 -3
- package/cjs/core/Slider/index.js +0 -15
- package/cjs/core/StatusMessage/index.d.ts +0 -3
- package/cjs/core/StatusMessage/index.js +0 -15
- package/cjs/core/Stepper/index.d.ts +0 -3
- package/cjs/core/Stepper/index.js +0 -21
- package/cjs/core/Surface/index.d.ts +0 -3
- package/cjs/core/Surface/index.js +0 -15
- package/cjs/core/Tabs/Tab.d.ts +0 -40
- package/cjs/core/Tabs/Tab.js +0 -65
- package/cjs/core/Tabs/index.d.ts +0 -2
- package/cjs/core/Tabs/index.js +0 -21
- package/cjs/core/Tag/index.d.ts +0 -4
- package/cjs/core/Tag/index.js +0 -22
- package/cjs/core/Textarea/index.d.ts +0 -3
- package/cjs/core/Textarea/index.js +0 -15
- package/cjs/core/ThemeProvider/index.d.ts +0 -4
- package/cjs/core/ThemeProvider/index.js +0 -15
- package/cjs/core/Tile/index.d.ts +0 -3
- package/cjs/core/Tile/index.js +0 -15
- package/cjs/core/TimePicker/index.d.ts +0 -4
- package/cjs/core/TimePicker/index.js +0 -15
- package/cjs/core/Toast/index.d.ts +0 -1
- package/cjs/core/Toast/index.js +0 -14
- package/cjs/core/ToggleSwitch/index.d.ts +0 -3
- package/cjs/core/ToggleSwitch/index.js +0 -15
- package/cjs/core/Tooltip/index.d.ts +0 -3
- package/cjs/core/Tooltip/index.js +0 -15
- package/cjs/core/TransferList/index.d.ts +0 -3
- package/cjs/core/TransferList/index.js +0 -15
- package/cjs/core/Tree/index.d.ts +0 -4
- package/cjs/core/Tree/index.js +0 -28
- package/cjs/core/Typography/Anchor/index.d.ts +0 -3
- package/cjs/core/Typography/Anchor/index.js +0 -15
- package/cjs/core/Typography/Blockquote/index.d.ts +0 -3
- package/cjs/core/Typography/Blockquote/index.js +0 -15
- package/cjs/core/Typography/Code/index.d.ts +0 -3
- package/cjs/core/Typography/Code/index.js +0 -15
- package/cjs/core/Typography/Kbd/index.d.ts +0 -3
- package/cjs/core/Typography/Kbd/index.js +0 -21
- package/cjs/core/Typography/Text/index.d.ts +0 -3
- package/cjs/core/Typography/Text/index.js +0 -15
- package/cjs/core/Typography/index.d.ts +0 -5
- package/cjs/core/Typography/index.js +0 -54
- package/cjs/core/index.d.ts +0 -68
- package/cjs/core/index.js +0 -916
- package/cjs/types/react-table-config.d.ts +0 -135
- package/cjs/types/react-table-config.js +0 -2
- package/esm/core/Alert/index.d.ts +0 -3
- package/esm/core/Alert/index.js +0 -6
- package/esm/core/Avatar/index.d.ts +0 -3
- package/esm/core/Avatar/index.js +0 -6
- package/esm/core/AvatarGroup/index.d.ts +0 -3
- package/esm/core/AvatarGroup/index.js +0 -6
- package/esm/core/Backdrop/index.d.ts +0 -1
- package/esm/core/Badge/index.d.ts +0 -3
- package/esm/core/Badge/index.js +0 -6
- package/esm/core/Breadcrumbs/index.d.ts +0 -3
- package/esm/core/Breadcrumbs/index.js +0 -6
- package/esm/core/ButtonGroup/index.d.ts +0 -3
- package/esm/core/ButtonGroup/index.js +0 -6
- package/esm/core/Buttons/Button/index.d.ts +0 -3
- package/esm/core/Buttons/Button/index.js +0 -6
- package/esm/core/Buttons/DropdownButton/index.d.ts +0 -3
- package/esm/core/Buttons/DropdownButton/index.js +0 -6
- package/esm/core/Buttons/IconButton/index.d.ts +0 -3
- package/esm/core/Buttons/IconButton/index.js +0 -6
- package/esm/core/Buttons/IdeasButton/index.d.ts +0 -3
- package/esm/core/Buttons/IdeasButton/index.js +0 -6
- package/esm/core/Buttons/SplitButton/index.d.ts +0 -3
- package/esm/core/Buttons/SplitButton/index.js +0 -6
- package/esm/core/Buttons/index.d.ts +0 -5
- package/esm/core/Buttons/index.js +0 -9
- package/esm/core/Carousel/index.d.ts +0 -3
- package/esm/core/Carousel/index.js +0 -6
- package/esm/core/Checkbox/index.d.ts +0 -3
- package/esm/core/Checkbox/index.js +0 -6
- package/esm/core/ColorPicker/index.d.ts +0 -7
- package/esm/core/ColorPicker/index.js +0 -10
- package/esm/core/ComboBox/index.d.ts +0 -3
- package/esm/core/ComboBox/index.js +0 -6
- package/esm/core/DatePicker/index.d.ts +0 -3
- package/esm/core/DatePicker/index.js +0 -6
- package/esm/core/Dialog/index.d.ts +0 -3
- package/esm/core/Dialog/index.js +0 -6
- package/esm/core/DropdownMenu/index.d.ts +0 -4
- package/esm/core/DropdownMenu/index.js +0 -6
- package/esm/core/ExpandableBlock/index.d.ts +0 -3
- package/esm/core/ExpandableBlock/index.js +0 -6
- package/esm/core/Fieldset/index.d.ts +0 -3
- package/esm/core/Fieldset/index.js +0 -6
- package/esm/core/FileUpload/index.d.ts +0 -6
- package/esm/core/FileUpload/index.js +0 -9
- package/esm/core/Footer/index.d.ts +0 -4
- package/esm/core/Footer/index.js +0 -6
- package/esm/core/Header/index.d.ts +0 -6
- package/esm/core/Header/index.js +0 -9
- package/esm/core/InformationPanel/index.d.ts +0 -7
- package/esm/core/InformationPanel/index.js +0 -10
- package/esm/core/Input/index.d.ts +0 -3
- package/esm/core/Input/index.js +0 -6
- package/esm/core/InputGrid/index.d.ts +0 -3
- package/esm/core/InputGrid/index.js +0 -6
- package/esm/core/InputGroup/index.d.ts +0 -3
- package/esm/core/InputGroup/index.js +0 -6
- package/esm/core/InputWithDecorations/index.d.ts +0 -3
- package/esm/core/InputWithDecorations/index.js +0 -6
- package/esm/core/Label/index.d.ts +0 -3
- package/esm/core/Label/index.js +0 -6
- package/esm/core/LabeledInput/index.d.ts +0 -3
- package/esm/core/LabeledInput/index.js +0 -6
- package/esm/core/LabeledSelect/index.d.ts +0 -3
- package/esm/core/LabeledSelect/index.js +0 -6
- package/esm/core/LabeledTextarea/index.d.ts +0 -3
- package/esm/core/LabeledTextarea/index.js +0 -6
- package/esm/core/List/index.d.ts +0 -2
- package/esm/core/List/index.js +0 -6
- package/esm/core/Menu/index.d.ts +0 -5
- package/esm/core/Menu/index.js +0 -9
- package/esm/core/Modal/index.d.ts +0 -5
- package/esm/core/Modal/index.js +0 -8
- package/esm/core/NonIdealState/index.d.ts +0 -5
- package/esm/core/NonIdealState/index.js +0 -7
- package/esm/core/NotificationMarker/index.d.ts +0 -3
- package/esm/core/NotificationMarker/index.js +0 -6
- package/esm/core/Overlay/index.d.ts +0 -1
- package/esm/core/Overlay/index.js +0 -5
- package/esm/core/ProgressIndicators/index.d.ts +0 -2
- package/esm/core/ProgressIndicators/index.js +0 -6
- package/esm/core/Radio/index.d.ts +0 -3
- package/esm/core/Radio/index.js +0 -6
- package/esm/core/RadioTiles/index.d.ts +0 -4
- package/esm/core/RadioTiles/index.js +0 -7
- package/esm/core/SearchBox/index.d.ts +0 -3
- package/esm/core/SearchBox/index.js +0 -6
- package/esm/core/Select/index.d.ts +0 -4
- package/esm/core/Select/index.js +0 -6
- package/esm/core/SideNavigation/index.d.ts +0 -6
- package/esm/core/SideNavigation/index.js +0 -9
- package/esm/core/SkipToContentLink/index.d.ts +0 -3
- package/esm/core/SkipToContentLink/index.js +0 -6
- package/esm/core/Slider/index.d.ts +0 -3
- package/esm/core/Slider/index.js +0 -6
- package/esm/core/StatusMessage/index.d.ts +0 -3
- package/esm/core/StatusMessage/index.js +0 -6
- package/esm/core/Stepper/index.d.ts +0 -3
- package/esm/core/Stepper/index.js +0 -6
- package/esm/core/Surface/index.d.ts +0 -3
- package/esm/core/Surface/index.js +0 -6
- package/esm/core/Tabs/Tab.d.ts +0 -40
- package/esm/core/Tabs/Tab.js +0 -57
- package/esm/core/Tabs/index.d.ts +0 -2
- package/esm/core/Tabs/index.js +0 -6
- package/esm/core/Tag/index.d.ts +0 -4
- package/esm/core/Tag/index.js +0 -7
- package/esm/core/Textarea/index.d.ts +0 -3
- package/esm/core/Textarea/index.js +0 -6
- package/esm/core/ThemeProvider/index.d.ts +0 -4
- package/esm/core/ThemeProvider/index.js +0 -6
- package/esm/core/Tile/index.d.ts +0 -3
- package/esm/core/Tile/index.js +0 -6
- package/esm/core/TimePicker/index.d.ts +0 -4
- package/esm/core/TimePicker/index.js +0 -6
- package/esm/core/Toast/index.d.ts +0 -1
- package/esm/core/Toast/index.js +0 -5
- package/esm/core/ToggleSwitch/index.d.ts +0 -3
- package/esm/core/ToggleSwitch/index.js +0 -6
- package/esm/core/Tooltip/index.d.ts +0 -3
- package/esm/core/Tooltip/index.js +0 -6
- package/esm/core/TransferList/index.d.ts +0 -3
- package/esm/core/TransferList/index.js +0 -6
- package/esm/core/Tree/index.d.ts +0 -4
- package/esm/core/Tree/index.js +0 -7
- package/esm/core/Typography/Anchor/index.d.ts +0 -3
- package/esm/core/Typography/Anchor/index.js +0 -6
- package/esm/core/Typography/Blockquote/index.d.ts +0 -3
- package/esm/core/Typography/Blockquote/index.js +0 -6
- package/esm/core/Typography/Code/index.d.ts +0 -3
- package/esm/core/Typography/Code/index.js +0 -6
- package/esm/core/Typography/Kbd/index.d.ts +0 -3
- package/esm/core/Typography/Kbd/index.js +0 -6
- package/esm/core/Typography/Text/index.d.ts +0 -3
- package/esm/core/Typography/Text/index.js +0 -6
- package/esm/core/Typography/index.d.ts +0 -5
- package/esm/core/Typography/index.js +0 -9
- package/esm/core/index.d.ts +0 -68
- package/esm/core/index.js +0 -132
- package/esm/types/react-table-config.d.ts +0 -135
- package/esm/types/react-table-config.js +0 -1
|
@@ -53,6 +53,7 @@ exports.CarouselDotsList = React.forwardRef((props, ref) => {
|
|
|
53
53
|
context.setCurrentIndex(index);
|
|
54
54
|
context.scrollToSlide.current(index);
|
|
55
55
|
}
|
|
56
|
+
listRef.current?.children[index]?.focus();
|
|
56
57
|
onSlideChange?.(index);
|
|
57
58
|
},
|
|
58
59
|
[context, onSlideChange],
|
|
@@ -105,13 +106,12 @@ exports.CarouselDotsList = React.forwardRef((props, ref) => {
|
|
|
105
106
|
index < firstVisibleDotIndex || index > lastVisibleDotIndex;
|
|
106
107
|
return React.createElement(CarouselDot_js_1.CarouselDot, {
|
|
107
108
|
key: index,
|
|
108
|
-
'aria-label': `Slide ${index}`,
|
|
109
|
+
'aria-label': `Slide ${index + 1}`,
|
|
109
110
|
isActive: index === currentIndex,
|
|
110
111
|
onClick: () => handleSlideChange(index),
|
|
111
112
|
isSmall: isSecondSmallDot,
|
|
112
113
|
isSmaller: isFirstSmallDot || isClipped,
|
|
113
114
|
id: idPrefix && `${idPrefix}--dot-${index}`,
|
|
114
|
-
'aria-controls': idPrefix && `${idPrefix}--slide-${index}`,
|
|
115
115
|
});
|
|
116
116
|
});
|
|
117
117
|
}, [
|
|
@@ -138,6 +138,27 @@ exports.CarouselDotsList = React.forwardRef((props, ref) => {
|
|
|
138
138
|
justMounted.current = false;
|
|
139
139
|
}
|
|
140
140
|
}, [currentIndex, firstVisibleDotIndex, slideCount, visibleCount, width]);
|
|
141
|
+
const handleKeyDown = (event) => {
|
|
142
|
+
if (event.altKey || event.ctrlKey || event.metaKey || event.shiftKey) {
|
|
143
|
+
return;
|
|
144
|
+
}
|
|
145
|
+
const key = event.key;
|
|
146
|
+
if (key === 'ArrowLeft' || key === 'ArrowRight') {
|
|
147
|
+
event.preventDefault();
|
|
148
|
+
}
|
|
149
|
+
};
|
|
150
|
+
const handleKeyUp = (event) => {
|
|
151
|
+
switch (event.key) {
|
|
152
|
+
case 'ArrowLeft': {
|
|
153
|
+
handleSlideChange((slideCount + currentIndex - 1) % slideCount);
|
|
154
|
+
break;
|
|
155
|
+
}
|
|
156
|
+
case 'ArrowRight': {
|
|
157
|
+
handleSlideChange((slideCount + currentIndex + 1) % slideCount);
|
|
158
|
+
break;
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
};
|
|
141
162
|
return React.createElement(
|
|
142
163
|
React.Fragment,
|
|
143
164
|
null,
|
|
@@ -151,6 +172,9 @@ exports.CarouselDotsList = React.forwardRef((props, ref) => {
|
|
|
151
172
|
role: 'tablist',
|
|
152
173
|
'aria-label': 'Slides',
|
|
153
174
|
ref: refs,
|
|
175
|
+
onKeyDown: handleKeyDown,
|
|
176
|
+
onKeyUp: handleKeyUp,
|
|
177
|
+
tabIndex: -1,
|
|
154
178
|
...rest,
|
|
155
179
|
},
|
|
156
180
|
children ?? dots,
|
|
@@ -6,14 +6,14 @@ import type { PolymorphicForwardRefComponent } from '../utils/index.js';
|
|
|
6
6
|
*
|
|
7
7
|
* `children` can be specified to override what is shown in this navigation section.
|
|
8
8
|
*/
|
|
9
|
-
export declare const CarouselNavigation: PolymorphicForwardRefComponent<"
|
|
9
|
+
export declare const CarouselNavigation: PolymorphicForwardRefComponent<"div", {}> & {
|
|
10
10
|
PreviousButton: PolymorphicForwardRefComponent<"button", Omit<Omit<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & {
|
|
11
11
|
ref?: ((instance: HTMLButtonElement | null) => void) | React.RefObject<HTMLButtonElement> | null | undefined;
|
|
12
12
|
}, "label" | "as" | "size" | "htmlDisabled" | "styleType" | "isActive" | "iconProps"> & {
|
|
13
13
|
isActive?: boolean | undefined;
|
|
14
14
|
label?: React.ReactNode;
|
|
15
15
|
iconProps?: React.DetailedHTMLProps<React.HTMLAttributes<HTMLSpanElement>, HTMLSpanElement> | undefined;
|
|
16
|
-
} & Omit<import("../Buttons/Button
|
|
16
|
+
} & Omit<import("../Buttons/Button.js").ButtonProps, "startIcon" | "endIcon" | "labelProps" | "startIconProps" | "endIconProps"> & {
|
|
17
17
|
as?: "button" | undefined;
|
|
18
18
|
}>;
|
|
19
19
|
NextButton: PolymorphicForwardRefComponent<"button", Omit<Omit<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & {
|
|
@@ -22,7 +22,7 @@ export declare const CarouselNavigation: PolymorphicForwardRefComponent<"nav", {
|
|
|
22
22
|
isActive?: boolean | undefined;
|
|
23
23
|
label?: React.ReactNode;
|
|
24
24
|
iconProps?: React.DetailedHTMLProps<React.HTMLAttributes<HTMLSpanElement>, HTMLSpanElement> | undefined;
|
|
25
|
-
} & Omit<import("../Buttons/Button
|
|
25
|
+
} & Omit<import("../Buttons/Button.js").ButtonProps, "startIcon" | "endIcon" | "labelProps" | "startIconProps" | "endIconProps"> & {
|
|
26
26
|
as?: "button" | undefined;
|
|
27
27
|
}>;
|
|
28
28
|
};
|
|
@@ -9,15 +9,14 @@ const tslib_1 = require('tslib');
|
|
|
9
9
|
const React = tslib_1.__importStar(require('react'));
|
|
10
10
|
const classnames_1 = tslib_1.__importDefault(require('classnames'));
|
|
11
11
|
const CarouselContext_js_1 = require('./CarouselContext.js');
|
|
12
|
-
const
|
|
12
|
+
const IconButton_js_1 = require('../Buttons/IconButton.js');
|
|
13
13
|
const CarouselDotsList_js_1 = require('./CarouselDotsList.js');
|
|
14
|
-
const
|
|
14
|
+
const index_js_1 = require('../utils/index.js');
|
|
15
15
|
const CarouselNavigationComponent = React.forwardRef((props, ref) => {
|
|
16
16
|
const { className, children, ...rest } = props;
|
|
17
17
|
return React.createElement(
|
|
18
|
-
|
|
18
|
+
index_js_1.Box,
|
|
19
19
|
{
|
|
20
|
-
as: 'nav',
|
|
21
20
|
className: (0, classnames_1.default)(
|
|
22
21
|
'iui-carousel-navigation',
|
|
23
22
|
className,
|
|
@@ -30,13 +29,13 @@ const CarouselNavigationComponent = React.forwardRef((props, ref) => {
|
|
|
30
29
|
React.Fragment,
|
|
31
30
|
null,
|
|
32
31
|
React.createElement(
|
|
33
|
-
|
|
32
|
+
index_js_1.Box,
|
|
34
33
|
{ className: 'iui-carousel-navigation-left' },
|
|
35
34
|
React.createElement(PreviousButton, null),
|
|
36
35
|
),
|
|
37
36
|
React.createElement(CarouselDotsList_js_1.CarouselDotsList, null),
|
|
38
37
|
React.createElement(
|
|
39
|
-
|
|
38
|
+
index_js_1.Box,
|
|
40
39
|
{ className: 'iui-carousel-navigation-right' },
|
|
41
40
|
React.createElement(NextButton, null),
|
|
42
41
|
),
|
|
@@ -49,20 +48,14 @@ const PreviousButton = React.forwardRef((props, ref) => {
|
|
|
49
48
|
if (!context) {
|
|
50
49
|
throw new Error('CarouselNavigation should be used inside Carousel');
|
|
51
50
|
}
|
|
52
|
-
const {
|
|
53
|
-
slideCount,
|
|
54
|
-
currentIndex,
|
|
55
|
-
setCurrentIndex,
|
|
56
|
-
keysPressed,
|
|
57
|
-
scrollToSlide,
|
|
58
|
-
} = context;
|
|
51
|
+
const { slideCount, currentIndex, setCurrentIndex, scrollToSlide } = context;
|
|
59
52
|
return React.createElement(
|
|
60
|
-
|
|
53
|
+
IconButton_js_1.IconButton,
|
|
61
54
|
{
|
|
62
55
|
styleType: 'borderless',
|
|
63
56
|
size: 'small',
|
|
64
57
|
tabIndex: -1,
|
|
65
|
-
'
|
|
58
|
+
'aria-label': 'Previous',
|
|
66
59
|
ref: ref,
|
|
67
60
|
...props,
|
|
68
61
|
onClick: (e) => {
|
|
@@ -72,7 +65,7 @@ const PreviousButton = React.forwardRef((props, ref) => {
|
|
|
72
65
|
props?.onClick?.(e);
|
|
73
66
|
},
|
|
74
67
|
},
|
|
75
|
-
React.createElement(
|
|
68
|
+
React.createElement(index_js_1.SvgChevronLeft, null),
|
|
76
69
|
);
|
|
77
70
|
});
|
|
78
71
|
/** Button for switching to next slide */
|
|
@@ -81,20 +74,14 @@ const NextButton = React.forwardRef((props, ref) => {
|
|
|
81
74
|
if (!context) {
|
|
82
75
|
throw new Error('CarouselNavigation should be used inside Carousel');
|
|
83
76
|
}
|
|
84
|
-
const {
|
|
85
|
-
slideCount,
|
|
86
|
-
currentIndex,
|
|
87
|
-
setCurrentIndex,
|
|
88
|
-
keysPressed,
|
|
89
|
-
scrollToSlide,
|
|
90
|
-
} = context;
|
|
77
|
+
const { slideCount, currentIndex, setCurrentIndex, scrollToSlide } = context;
|
|
91
78
|
return React.createElement(
|
|
92
|
-
|
|
79
|
+
IconButton_js_1.IconButton,
|
|
93
80
|
{
|
|
94
81
|
styleType: 'borderless',
|
|
95
82
|
size: 'small',
|
|
96
83
|
tabIndex: -1,
|
|
97
|
-
'
|
|
84
|
+
'aria-label': 'Next',
|
|
98
85
|
ref: ref,
|
|
99
86
|
...props,
|
|
100
87
|
onClick: (e) => {
|
|
@@ -104,7 +91,7 @@ const NextButton = React.forwardRef((props, ref) => {
|
|
|
104
91
|
props?.onClick?.(e);
|
|
105
92
|
},
|
|
106
93
|
},
|
|
107
|
-
React.createElement(
|
|
94
|
+
React.createElement(index_js_1.SvgChevronRight, null),
|
|
108
95
|
);
|
|
109
96
|
});
|
|
110
97
|
/**
|
|
@@ -12,5 +12,5 @@ type CarouselSlideProps = {
|
|
|
12
12
|
* It is recommended that the slide content bring its own dimensions (esp. height) and that
|
|
13
13
|
* the dimensions should be the same for all slides.
|
|
14
14
|
*/
|
|
15
|
-
export declare const CarouselSlide: PolymorphicForwardRefComponent<"
|
|
15
|
+
export declare const CarouselSlide: PolymorphicForwardRefComponent<"div", CarouselSlideProps>;
|
|
16
16
|
export {};
|
|
@@ -22,7 +22,7 @@ exports.CarouselSlide = React.forwardRef((props, ref) => {
|
|
|
22
22
|
if (!context || index == null) {
|
|
23
23
|
throw new Error('CarouselSlide must be used within Carousel');
|
|
24
24
|
}
|
|
25
|
-
const { isManuallyUpdating, setCurrentIndex } = context;
|
|
25
|
+
const { isManuallyUpdating, currentIndex, setCurrentIndex } = context;
|
|
26
26
|
const updateActiveIndexOnScroll = React.useCallback(() => {
|
|
27
27
|
// only update index if scroll was triggered by browser
|
|
28
28
|
if (!isManuallyUpdating.current) {
|
|
@@ -38,15 +38,25 @@ exports.CarouselSlide = React.forwardRef((props, ref) => {
|
|
|
38
38
|
return React.createElement(
|
|
39
39
|
index_js_1.Box,
|
|
40
40
|
{
|
|
41
|
-
as: 'li',
|
|
42
41
|
className: (0, classnames_1.default)(
|
|
43
42
|
'iui-carousel-slider-item',
|
|
44
43
|
className,
|
|
45
44
|
),
|
|
46
45
|
role: 'tabpanel',
|
|
47
46
|
'aria-roledescription': 'slide',
|
|
47
|
+
tabIndex: index === currentIndex ? 0 : undefined,
|
|
48
48
|
ref: refs,
|
|
49
|
+
inert: index !== currentIndex ? '' : undefined,
|
|
49
50
|
...rest,
|
|
51
|
+
onKeyDown: (0, index_js_1.mergeEventHandlers)(
|
|
52
|
+
props.onKeyDown,
|
|
53
|
+
(event) => {
|
|
54
|
+
// prevent default browser scrolling on arrow keys because focus will get lost when slide switches
|
|
55
|
+
if (event.key === 'ArrowLeft' || event.key === 'ArrowRight') {
|
|
56
|
+
event.preventDefault();
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
),
|
|
50
60
|
},
|
|
51
61
|
children,
|
|
52
62
|
);
|
|
@@ -2,4 +2,4 @@ import type { PolymorphicForwardRefComponent } from '../utils/index.js';
|
|
|
2
2
|
/**
|
|
3
3
|
* `CarouselSlider` is the scrollable list that should consist of `CarouselSlide` components.
|
|
4
4
|
*/
|
|
5
|
-
export declare const CarouselSlider: PolymorphicForwardRefComponent<"
|
|
5
|
+
export declare const CarouselSlider: PolymorphicForwardRefComponent<"div", {}>;
|
|
@@ -27,6 +27,7 @@ exports.CarouselSlider = React.forwardRef((props, ref) => {
|
|
|
27
27
|
React.isValidElement(child)
|
|
28
28
|
? React.cloneElement(child, {
|
|
29
29
|
id: `${idPrefix}--slide-${index}`,
|
|
30
|
+
'aria-labelledby': `${idPrefix}--dot-${index}`,
|
|
30
31
|
index,
|
|
31
32
|
})
|
|
32
33
|
: child,
|
|
@@ -65,11 +66,10 @@ exports.CarouselSlider = React.forwardRef((props, ref) => {
|
|
|
65
66
|
return React.createElement(
|
|
66
67
|
index_js_1.Box,
|
|
67
68
|
{
|
|
68
|
-
as: 'ol',
|
|
69
|
-
'aria-live': 'polite',
|
|
70
69
|
className: (0, classnames_1.default)('iui-carousel-slider', className),
|
|
71
70
|
ref: refs,
|
|
72
71
|
onScroll: handleOnScroll,
|
|
72
|
+
tabIndex: -1,
|
|
73
73
|
...rest,
|
|
74
74
|
},
|
|
75
75
|
items,
|
|
@@ -8,8 +8,8 @@ const tslib_1 = require('tslib');
|
|
|
8
8
|
*--------------------------------------------------------------------------------------------*/
|
|
9
9
|
const classnames_1 = tslib_1.__importDefault(require('classnames'));
|
|
10
10
|
const React = tslib_1.__importStar(require('react'));
|
|
11
|
-
const
|
|
12
|
-
const
|
|
11
|
+
const ProgressRadial_js_1 = require('../ProgressIndicators/ProgressRadial.js');
|
|
12
|
+
const index_js_1 = require('../utils/index.js');
|
|
13
13
|
/**
|
|
14
14
|
* Simple input checkbox
|
|
15
15
|
* @example
|
|
@@ -37,7 +37,7 @@ exports.Checkbox = React.forwardRef((props, ref) => {
|
|
|
37
37
|
...rest
|
|
38
38
|
} = props;
|
|
39
39
|
const inputElementRef = React.useRef(null);
|
|
40
|
-
const refs = (0,
|
|
40
|
+
const refs = (0, index_js_1.useMergedRefs)(inputElementRef, ref);
|
|
41
41
|
React.useEffect(() => {
|
|
42
42
|
if (inputElementRef.current) {
|
|
43
43
|
inputElementRef.current.indeterminate = indeterminate;
|
|
@@ -49,7 +49,7 @@ exports.Checkbox = React.forwardRef((props, ref) => {
|
|
|
49
49
|
const checkbox = React.createElement(
|
|
50
50
|
React.Fragment,
|
|
51
51
|
null,
|
|
52
|
-
React.createElement(
|
|
52
|
+
React.createElement(index_js_1.Box, {
|
|
53
53
|
as: 'input',
|
|
54
54
|
className: (0, classnames_1.default)(
|
|
55
55
|
'iui-checkbox',
|
|
@@ -66,7 +66,7 @@ exports.Checkbox = React.forwardRef((props, ref) => {
|
|
|
66
66
|
...rest,
|
|
67
67
|
}),
|
|
68
68
|
isLoading &&
|
|
69
|
-
React.createElement(
|
|
69
|
+
React.createElement(ProgressRadial_js_1.ProgressRadial, {
|
|
70
70
|
size: 'x-small',
|
|
71
71
|
indeterminate: true,
|
|
72
72
|
}),
|
|
@@ -76,7 +76,7 @@ exports.Checkbox = React.forwardRef((props, ref) => {
|
|
|
76
76
|
return !label
|
|
77
77
|
? checkbox
|
|
78
78
|
: React.createElement(
|
|
79
|
-
|
|
79
|
+
index_js_1.Box,
|
|
80
80
|
{
|
|
81
81
|
as: 'label',
|
|
82
82
|
className: (0, classnames_1.default)(
|
|
@@ -93,7 +93,7 @@ exports.Checkbox = React.forwardRef((props, ref) => {
|
|
|
93
93
|
checkbox,
|
|
94
94
|
label &&
|
|
95
95
|
React.createElement(
|
|
96
|
-
|
|
96
|
+
index_js_1.Box,
|
|
97
97
|
{
|
|
98
98
|
as: 'span',
|
|
99
99
|
className: (0, classnames_1.default)(
|
|
@@ -9,7 +9,7 @@ const tslib_1 = require('tslib');
|
|
|
9
9
|
const React = tslib_1.__importStar(require('react'));
|
|
10
10
|
const classnames_1 = tslib_1.__importDefault(require('classnames'));
|
|
11
11
|
const index_js_1 = require('../utils/index.js');
|
|
12
|
-
const
|
|
12
|
+
const Slider_js_1 = require('../Slider/Slider.js');
|
|
13
13
|
const ColorPickerContext_js_1 = require('./ColorPickerContext.js');
|
|
14
14
|
const getVerticalPercentageOfRectangle = (rect, pointer) => {
|
|
15
15
|
const position = (0, index_js_1.getBoundedValue)(
|
|
@@ -267,7 +267,7 @@ exports.ColorBuilder = React.forwardRef((props, ref) => {
|
|
|
267
267
|
ref: colorDotRef,
|
|
268
268
|
}),
|
|
269
269
|
),
|
|
270
|
-
React.createElement(
|
|
270
|
+
React.createElement(Slider_js_1.Slider, {
|
|
271
271
|
minLabel: '',
|
|
272
272
|
maxLabel: '',
|
|
273
273
|
values: [sliderValue],
|
|
@@ -282,9 +282,10 @@ exports.ColorBuilder = React.forwardRef((props, ref) => {
|
|
|
282
282
|
},
|
|
283
283
|
min: 0,
|
|
284
284
|
max: 359,
|
|
285
|
+
thumbProps: () => ({ 'aria-label': 'Hue' }),
|
|
285
286
|
}),
|
|
286
287
|
showAlpha &&
|
|
287
|
-
React.createElement(
|
|
288
|
+
React.createElement(Slider_js_1.Slider, {
|
|
288
289
|
minLabel: '',
|
|
289
290
|
maxLabel: '',
|
|
290
291
|
values: [alphaValue],
|
|
@@ -303,6 +304,7 @@ exports.ColorBuilder = React.forwardRef((props, ref) => {
|
|
|
303
304
|
style: {
|
|
304
305
|
'--iui-color-picker-selected-color': hueColorString,
|
|
305
306
|
},
|
|
307
|
+
thumbProps: () => ({ 'aria-label': 'Opacity' }),
|
|
306
308
|
}),
|
|
307
309
|
);
|
|
308
310
|
});
|
|
@@ -8,9 +8,9 @@ const tslib_1 = require('tslib');
|
|
|
8
8
|
*--------------------------------------------------------------------------------------------*/
|
|
9
9
|
const React = tslib_1.__importStar(require('react'));
|
|
10
10
|
const classnames_1 = tslib_1.__importDefault(require('classnames'));
|
|
11
|
-
const
|
|
12
|
-
const
|
|
13
|
-
const
|
|
11
|
+
const IconButton_js_1 = require('../Buttons/IconButton.js');
|
|
12
|
+
const Input_js_1 = require('../Input/Input.js');
|
|
13
|
+
const index_js_1 = require('../utils/index.js');
|
|
14
14
|
const ColorPickerContext_js_1 = require('./ColorPickerContext.js');
|
|
15
15
|
/**
|
|
16
16
|
* `ColorInputPanel` shows input fields to enter precise color values in the specified format.
|
|
@@ -41,10 +41,10 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
41
41
|
if (currentFormat === 'hsl') {
|
|
42
42
|
const hsl = activeColor.toHslColor();
|
|
43
43
|
setInput([
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
44
|
+
index_js_1.ColorValue.getFormattedColorNumber(hsvColor.h),
|
|
45
|
+
index_js_1.ColorValue.getFormattedColorNumber(hsl.s),
|
|
46
|
+
index_js_1.ColorValue.getFormattedColorNumber(hsl.l),
|
|
47
|
+
index_js_1.ColorValue.getFormattedColorNumber(
|
|
48
48
|
hsl.a ?? activeColor.getAlpha() / 255,
|
|
49
49
|
2,
|
|
50
50
|
),
|
|
@@ -55,7 +55,7 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
55
55
|
rgb.r.toString(),
|
|
56
56
|
rgb.g.toString(),
|
|
57
57
|
rgb.b.toString(),
|
|
58
|
-
|
|
58
|
+
index_js_1.ColorValue.getFormattedColorNumber(
|
|
59
59
|
rgb.a ?? activeColor.getAlpha() / 255,
|
|
60
60
|
2,
|
|
61
61
|
),
|
|
@@ -85,7 +85,7 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
85
85
|
if (currentFormat === 'hex') {
|
|
86
86
|
try {
|
|
87
87
|
const value = input[0].replace(/ /g, '').toLowerCase(); // remove white space from input
|
|
88
|
-
color =
|
|
88
|
+
color = index_js_1.ColorValue.create(value);
|
|
89
89
|
setValidHexInput(true);
|
|
90
90
|
if (activeColor.toHexString(showAlpha).toLowerCase() === value) {
|
|
91
91
|
return;
|
|
@@ -113,7 +113,7 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
113
113
|
if (hsl.h === h && hsl.s === s && hsl.l === l && hsl.a === a) {
|
|
114
114
|
return;
|
|
115
115
|
}
|
|
116
|
-
color =
|
|
116
|
+
color = index_js_1.ColorValue.create({ h, s, l, a });
|
|
117
117
|
}
|
|
118
118
|
if (currentFormat === 'rgb') {
|
|
119
119
|
const [r, g, b, a] = input.map(Number);
|
|
@@ -133,17 +133,18 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
133
133
|
if (rgb.r === r && rgb.g === g && rgb.b === b && rgb.a === a) {
|
|
134
134
|
return;
|
|
135
135
|
}
|
|
136
|
-
color =
|
|
136
|
+
color = index_js_1.ColorValue.create({ r, g, b, a });
|
|
137
137
|
}
|
|
138
138
|
if (color) {
|
|
139
139
|
applyHsvColorChange(color.toHsvColor(), true, color);
|
|
140
140
|
}
|
|
141
141
|
};
|
|
142
|
-
const hexInputField = React.createElement(
|
|
142
|
+
const hexInputField = React.createElement(Input_js_1.Input, {
|
|
143
143
|
size: 'small',
|
|
144
144
|
maxLength: showAlpha ? 9 : 7,
|
|
145
145
|
minLength: 1,
|
|
146
146
|
placeholder: 'HEX',
|
|
147
|
+
'aria-label': 'Hex',
|
|
147
148
|
value: input[0],
|
|
148
149
|
onChange: (event) => {
|
|
149
150
|
const value = event.target.value.startsWith('#')
|
|
@@ -166,13 +167,14 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
166
167
|
const hslInputs = React.createElement(
|
|
167
168
|
React.Fragment,
|
|
168
169
|
null,
|
|
169
|
-
React.createElement(
|
|
170
|
+
React.createElement(Input_js_1.Input, {
|
|
170
171
|
size: 'small',
|
|
171
172
|
type: 'number',
|
|
172
173
|
min: '0',
|
|
173
174
|
max: '359',
|
|
174
175
|
step: '.1',
|
|
175
176
|
placeholder: 'H',
|
|
177
|
+
'aria-label': 'Hue',
|
|
176
178
|
value: input[0] ?? '',
|
|
177
179
|
onChange: (event) => {
|
|
178
180
|
setInput([event.target.value, input[1], input[2], input[3]]);
|
|
@@ -192,13 +194,14 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
192
194
|
status:
|
|
193
195
|
Number(input[0]) < 0 || Number(input[0]) > 360 ? 'negative' : undefined,
|
|
194
196
|
}),
|
|
195
|
-
React.createElement(
|
|
197
|
+
React.createElement(Input_js_1.Input, {
|
|
196
198
|
size: 'small',
|
|
197
199
|
type: 'number',
|
|
198
200
|
min: '0',
|
|
199
201
|
max: '100',
|
|
200
202
|
step: '.1',
|
|
201
203
|
placeholder: 'S',
|
|
204
|
+
'aria-label': 'Saturation',
|
|
202
205
|
value: input[1] ?? '',
|
|
203
206
|
onChange: (event) => {
|
|
204
207
|
setInput([input[0], event.target.value, input[2], input[3]]);
|
|
@@ -218,13 +221,14 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
218
221
|
status:
|
|
219
222
|
Number(input[1]) < 0 || Number(input[1]) > 100 ? 'negative' : undefined,
|
|
220
223
|
}),
|
|
221
|
-
React.createElement(
|
|
224
|
+
React.createElement(Input_js_1.Input, {
|
|
222
225
|
size: 'small',
|
|
223
226
|
type: 'number',
|
|
224
227
|
min: '0',
|
|
225
228
|
max: '100',
|
|
226
229
|
step: '.1',
|
|
227
230
|
placeholder: 'L',
|
|
231
|
+
'aria-label': 'Lightness',
|
|
228
232
|
value: input[2] ?? '',
|
|
229
233
|
onChange: (event) => {
|
|
230
234
|
setInput([input[0], input[1], event.target.value, input[3]]);
|
|
@@ -245,13 +249,14 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
245
249
|
Number(input[2]) < 0 || Number(input[2]) > 100 ? 'negative' : undefined,
|
|
246
250
|
}),
|
|
247
251
|
showAlpha &&
|
|
248
|
-
React.createElement(
|
|
252
|
+
React.createElement(Input_js_1.Input, {
|
|
249
253
|
size: 'small',
|
|
250
254
|
type: 'number',
|
|
251
255
|
min: '0',
|
|
252
256
|
max: '1',
|
|
253
257
|
step: '.01',
|
|
254
258
|
placeholder: 'A',
|
|
259
|
+
'aria-label': 'Alpha',
|
|
255
260
|
value: input[3] ?? '',
|
|
256
261
|
onChange: (event) => {
|
|
257
262
|
setInput([input[0], input[1], input[2], event.target.value]);
|
|
@@ -275,12 +280,13 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
275
280
|
const rgbInputs = React.createElement(
|
|
276
281
|
React.Fragment,
|
|
277
282
|
null,
|
|
278
|
-
React.createElement(
|
|
283
|
+
React.createElement(Input_js_1.Input, {
|
|
279
284
|
size: 'small',
|
|
280
285
|
type: 'number',
|
|
281
286
|
min: '0',
|
|
282
287
|
max: '255',
|
|
283
288
|
placeholder: 'R',
|
|
289
|
+
'aria-label': 'Red',
|
|
284
290
|
value: input[0] ?? '',
|
|
285
291
|
onChange: (event) => {
|
|
286
292
|
setInput([event.target.value, input[1], input[2], input[3]]);
|
|
@@ -300,12 +306,13 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
300
306
|
status:
|
|
301
307
|
Number(input[0]) < 0 || Number(input[0]) > 255 ? 'negative' : undefined,
|
|
302
308
|
}),
|
|
303
|
-
React.createElement(
|
|
309
|
+
React.createElement(Input_js_1.Input, {
|
|
304
310
|
size: 'small',
|
|
305
311
|
type: 'number',
|
|
306
312
|
min: '0',
|
|
307
313
|
max: '255',
|
|
308
314
|
placeholder: 'G',
|
|
315
|
+
'aria-label': 'Green',
|
|
309
316
|
value: input[1] ?? '',
|
|
310
317
|
onChange: (event) => {
|
|
311
318
|
setInput([input[0], event.target.value, input[2], input[3]]);
|
|
@@ -325,12 +332,13 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
325
332
|
status:
|
|
326
333
|
Number(input[1]) < 0 || Number(input[1]) > 255 ? 'negative' : undefined,
|
|
327
334
|
}),
|
|
328
|
-
React.createElement(
|
|
335
|
+
React.createElement(Input_js_1.Input, {
|
|
329
336
|
size: 'small',
|
|
330
337
|
type: 'number',
|
|
331
338
|
min: '0',
|
|
332
339
|
max: '255',
|
|
333
340
|
placeholder: 'B',
|
|
341
|
+
'aria-label': 'Blue',
|
|
334
342
|
value: input[2] ?? '',
|
|
335
343
|
onChange: (event) => {
|
|
336
344
|
setInput([input[0], input[1], event.target.value, input[3]]);
|
|
@@ -351,13 +359,14 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
351
359
|
Number(input[2]) < 0 || Number(input[2]) > 255 ? 'negative' : undefined,
|
|
352
360
|
}),
|
|
353
361
|
showAlpha &&
|
|
354
|
-
React.createElement(
|
|
362
|
+
React.createElement(Input_js_1.Input, {
|
|
355
363
|
size: 'small',
|
|
356
364
|
type: 'number',
|
|
357
365
|
min: '0',
|
|
358
366
|
max: '1',
|
|
359
367
|
step: '.01',
|
|
360
368
|
placeholder: 'A',
|
|
369
|
+
'aria-label': 'Alpha',
|
|
361
370
|
value: input[3] ?? '',
|
|
362
371
|
onChange: (event) => {
|
|
363
372
|
setInput([input[0], input[1], input[2], event.target.value]);
|
|
@@ -378,8 +387,9 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
378
387
|
Number(input[3]) < 0 || Number(input[3]) > 1 ? 'negative' : undefined,
|
|
379
388
|
}),
|
|
380
389
|
);
|
|
390
|
+
const labelId = (0, index_js_1.useId)();
|
|
381
391
|
return React.createElement(
|
|
382
|
-
|
|
392
|
+
index_js_1.Box,
|
|
383
393
|
{
|
|
384
394
|
className: (0, classnames_1.default)(
|
|
385
395
|
'iui-color-input-wrapper',
|
|
@@ -389,24 +399,34 @@ exports.ColorInputPanel = React.forwardRef((props, ref) => {
|
|
|
389
399
|
...rest,
|
|
390
400
|
},
|
|
391
401
|
React.createElement(
|
|
392
|
-
|
|
393
|
-
{ className: 'iui-color-picker-section-label' },
|
|
394
|
-
showAlpha && currentFormat
|
|
402
|
+
index_js_1.Box,
|
|
403
|
+
{ className: 'iui-color-picker-section-label', id: labelId },
|
|
404
|
+
showAlpha && currentFormat !== 'hex'
|
|
395
405
|
? currentFormat.toUpperCase() + 'A'
|
|
396
406
|
: currentFormat.toUpperCase(),
|
|
397
407
|
),
|
|
398
408
|
React.createElement(
|
|
399
|
-
|
|
409
|
+
index_js_1.Box,
|
|
400
410
|
{ className: 'iui-color-input' },
|
|
401
411
|
allowedColorFormats.length > 1 &&
|
|
402
412
|
React.createElement(
|
|
403
|
-
|
|
404
|
-
{
|
|
405
|
-
|
|
413
|
+
IconButton_js_1.IconButton,
|
|
414
|
+
{
|
|
415
|
+
styleType: 'borderless',
|
|
416
|
+
onClick: swapColorFormat,
|
|
417
|
+
size: 'small',
|
|
418
|
+
label: 'Switch format',
|
|
419
|
+
},
|
|
420
|
+
React.createElement(index_js_1.SvgSwap, null),
|
|
406
421
|
),
|
|
407
422
|
React.createElement(
|
|
408
|
-
|
|
409
|
-
{
|
|
423
|
+
index_js_1.Box,
|
|
424
|
+
{
|
|
425
|
+
ref: inputsContainerRef,
|
|
426
|
+
className: 'iui-color-input-fields',
|
|
427
|
+
role: currentFormat !== 'hex' ? 'group' : undefined,
|
|
428
|
+
'aria-labelledby': currentFormat !== 'hex' ? labelId : undefined,
|
|
429
|
+
},
|
|
410
430
|
currentFormat === 'hex' && hexInputField,
|
|
411
431
|
currentFormat === 'rgb' && rgbInputs,
|
|
412
432
|
currentFormat === 'hsl' && hslInputs,
|