@ringcentral/spring-ui 1.9.2 → 1.11.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/Alert.js +1 -1
- package/Announcement.js +4 -2
- package/Autocomplete.js +40 -7
- package/Avatar.js +42 -27
- package/DatePicker.js +45 -38
- package/DateUtilsContext.js +18 -1
- package/Dialer.js +1 -1
- package/Dialog.js +24 -15
- package/NestedMenuContext.js +4 -3
- package/Option.js +5 -5
- package/PickerTextField.js +2 -2
- package/Popper.js +1 -1
- package/Snackbar.js +7 -5
- package/SortableListDndContext.js +3 -3
- package/SortableListItem.js +21 -9
- package/SplitButton.js +1 -1
- package/SubMenu.js +208 -77
- package/SwipeableDrawer.js +1 -9
- package/Switch.js +15 -5
- package/TablePagination.js +11 -21
- package/TableRow.js +1 -1
- package/Text.js +2 -2
- package/Textarea.js +1 -1
- package/TimePicker.js +1 -1
- package/chunks/Alert.js +1 -1
- package/chunks/Drawer.js +1 -1
- package/chunks/Menu.js +25 -6
- package/chunks/Modal.js +7 -3
- package/chunks/PickerTextField.js +18 -7
- package/chunks/TextField.js +0 -1
- package/chunks/Tooltip.js +1 -1
- package/chunks/VirtualizedMenu.js +1 -1
- package/chunks/useMenuItemSelect.js +49 -17
- package/chunks/useNestedMenuItem.js +16 -5
- package/chunks/useNestedParentMenu.js +77 -5
- package/chunks/useTrayNavigate.js +1 -1
- package/index.css +543 -398
- package/index.js +1 -1
- package/package.json +4 -4
- package/src/Accordion/Accordion.classes.d.ts +3 -3
- package/src/Accordion/Accordion.d.ts +1 -1
- package/src/Accordion/Accordion.type.d.ts +1 -1
- package/src/Accordion/AccordionContext.d.ts +1 -1
- package/src/AccordionHeader/AccordionHeader.classes.d.ts +3 -3
- package/src/AccordionHeader/AccordionHeader.d.ts +1 -1
- package/src/AccordionHeader/AccordionHeader.type.d.ts +1 -1
- package/src/Alert/Alert.classes.d.ts +3 -3
- package/src/Alert/Alert.d.ts +3 -3
- package/src/Alert/Alert.type.d.ts +7 -7
- package/src/Alert/AlertTitle.classes.d.ts +3 -3
- package/src/Animation/components/ExpandCollapseCaret/ExpandCollapseCaret.classes.d.ts +3 -3
- package/src/Animation/components/ExpandCollapseCaret/ExpandCollapseCaret.d.ts +2 -2
- package/src/Animation/components/Fade/Fade.d.ts +1 -1
- package/src/Animation/components/Fade/getFade.d.ts +1 -1
- package/src/Animation/components/Grow/Grow.d.ts +1 -1
- package/src/Animation/components/Grow/getGrow.d.ts +4 -4
- package/src/Animation/components/ShowHideEye/ShowHideEye.classes.d.ts +3 -3
- package/src/Animation/components/ShowHideEye/ShowHideEye.d.ts +1 -1
- package/src/Animation/components/SlideIn/SlideIn.d.ts +1 -1
- package/src/Animation/components/SlideIn/getSlideIn.d.ts +2 -2
- package/src/Animation/components/SortableArrow/SortableArrow.classes.d.ts +3 -3
- package/src/Animation/components/SortableArrow/SortableArrow.d.ts +1 -1
- package/src/Animation/components/types.d.ts +2 -2
- package/src/Announcement/Announcement.classes.d.ts +3 -3
- package/src/Announcement/Announcement.type.d.ts +1 -1
- package/src/Autocomplete/Autocomplete.classes.d.ts +6 -6
- package/src/Autocomplete/Autocomplete.type.d.ts +6 -5
- package/src/Autocomplete/SuggestionList/SuggestionList.classes.d.ts +3 -3
- package/src/Autocomplete/SuggestionList/SuggestionList.d.ts +3 -3
- package/src/Autocomplete/SuggestionList/SuggestionListItem.d.ts +2 -2
- package/src/Autocomplete/SuggestionList/utils/SuggestionListItem.d.ts +1 -1
- package/src/Autocomplete/SuggestionList/utils/useDynamicHeight.d.ts +1 -1
- package/src/Autocomplete/SuggestionList/utils/useHighlightScroll.d.ts +1 -1
- package/src/Autocomplete/SuggestionList/utils/useSuggestionList.d.ts +11 -11
- package/src/Autocomplete/SuggestionList/utils/useSuggestionListGroup.d.ts +2 -2
- package/src/Autocomplete/useAutocomplete.d.ts +20 -20
- package/src/Autocomplete/useAutocompleteTag.d.ts +12 -12
- package/src/Avatar/Avatar.classes.d.ts +5 -5
- package/src/Avatar/Avatar.type.d.ts +7 -7
- package/src/AvatarGroup/AvatarGroup.classes.d.ts +3 -3
- package/src/AvatarGroup/AvatarGroup.type.d.ts +6 -6
- package/src/Backdrop/Backdrop.classes.d.ts +3 -3
- package/src/Backdrop/Backdrop.type.d.ts +1 -1
- package/src/Badge/Badge.classes.d.ts +5 -5
- package/src/Badge/Badge.type.d.ts +7 -7
- package/src/Block/Block.classes.d.ts +3 -3
- package/src/Block/Block.type.d.ts +6 -6
- package/src/BlockHeader/BlockHeader.classes.d.ts +3 -3
- package/src/BlockHeader/BlockHeader.type.d.ts +4 -4
- package/src/BottomNavigation/BottomNavigation.classes.d.ts +3 -3
- package/src/BottomNavigation/BottomNavigation.type.d.ts +2 -2
- package/src/BottomNavigation/BottomNavigationContext.d.ts +1 -1
- package/src/BottomNavigation/BottomNavigationGroup/BottomNavigationGroup.classes.d.ts +3 -3
- package/src/BottomNavigation/BottomNavigationGroup/BottomNavigationGroup.type.d.ts +1 -1
- package/src/BottomNavigationItem/BottomNavigationItem.classes.d.ts +3 -3
- package/src/BottomNavigationItem/BottomNavigationItem.type.d.ts +1 -1
- package/src/Button/Button.classes.d.ts +3 -3
- package/src/Button/Button.type.d.ts +8 -8
- package/src/CallButton/CallButton.classes.d.ts +3 -3
- package/src/CallButton/CallButton.type.d.ts +5 -5
- package/src/Checkbox/Checkbox.classes.d.ts +3 -3
- package/src/Checkbox/Checkbox.d.ts +2 -2
- package/src/Checkbox/Checkbox.type.d.ts +2 -2
- package/src/Chip/Chip.classes.d.ts +3 -3
- package/src/Chip/Chip.type.d.ts +5 -5
- package/src/CircularProgressIndicator/CircularProgressIndicator.classes.d.ts +4 -4
- package/src/CircularProgressIndicator/CircularProgressIndicator.d.ts +1 -1
- package/src/CircularProgressIndicator/CircularProgressIndicator.type.d.ts +4 -4
- package/src/ComponentsProps.d.ts +1 -1
- package/src/DatePicker/Calendar.d.ts +1 -1
- package/src/DatePicker/DatePicker.classes.d.ts +3 -3
- package/src/DatePicker/DatePicker.d.ts +1 -1
- package/src/DatePicker/DatePicker.type.d.ts +3 -3
- package/src/DatePicker/DatePickerHeader.d.ts +3 -2
- package/src/DatePicker/Day.d.ts +2 -2
- package/src/DatePicker/SlideDirection.d.ts +1 -1
- package/src/DatePicker/Year.d.ts +2 -2
- package/src/DatePicker/Years.d.ts +1 -1
- package/src/DatePicker/utils/DatePickerAriaLabelUtils.d.ts +12 -4
- package/src/DatePicker/utils/DatePickerUtils.d.ts +1 -1
- package/src/DatePicker/utils/findClosestEnabledDate.d.ts +1 -1
- package/src/DateUtilsContext/DateUtilsContext.d.ts +8 -2
- package/src/Dialer/DialDelete/DialDelete.d.ts +1 -1
- package/src/Dialer/DialPad/DialPad.classes.d.ts +3 -3
- package/src/Dialer/DialPad/DialPad.d.ts +2 -2
- package/src/Dialer/DialPad/utils/DialPadUtils.d.ts +3 -3
- package/src/Dialer/DialPad/utils/types.d.ts +2 -2
- package/src/Dialer/DialPad/utils/useDialKeyboard.d.ts +1 -1
- package/src/Dialer/DialPad/utils/useKeyAudio.d.ts +1 -1
- package/src/Dialer/DialPadButton/DialPadButton.classes.d.ts +3 -3
- package/src/Dialer/DialPadButton/DialPadButton.d.ts +1 -1
- package/src/Dialer/DialTextField/DialTextField.d.ts +2 -2
- package/src/Dialer/Dialer.d.ts +1 -1
- package/src/Dialer/utils/DialerContext.d.ts +1 -1
- package/src/Dialog/Dialog.classes.d.ts +14 -14
- package/src/Dialog/Dialog.d.ts +1 -1
- package/src/Dialog/Dialog.type.d.ts +5 -4
- package/src/Divider/Divider.classes.d.ts +4 -4
- package/src/Divider/Divider.type.d.ts +7 -7
- package/src/DragHandle/DragHandle.classes.d.ts +3 -3
- package/src/DragHandle/DragHandle.type.d.ts +5 -5
- package/src/Drawer/Drawer.classes.d.ts +5 -5
- package/src/Drawer/Drawer.d.ts +1 -1
- package/src/Drawer/Drawer.type.d.ts +4 -4
- package/src/Dropdown/Dropdown.classes.d.ts +3 -3
- package/src/Dropdown/Dropdown.type.d.ts +1 -1
- package/src/EmptyState/EmptyState.classes.d.ts +3 -3
- package/src/EmptyState/EmptyState.d.ts +1 -1
- package/src/EmptyState/EmptyState.type.d.ts +1 -1
- package/src/FabButton/FabButton.classes.d.ts +3 -3
- package/src/FabButton/FabButton.type.d.ts +5 -5
- package/src/FocusTrap/FocusTrap.d.ts +2 -2
- package/src/FormField/FormField.classes.d.ts +4 -4
- package/src/FormField/FormField.type.d.ts +3 -3
- package/src/FormLabel/FormLabel.classes.d.ts +4 -4
- package/src/FormLabel/FormLabel.d.ts +1 -1
- package/src/FormLabel/FormLabel.type.d.ts +2 -2
- package/src/FormLabel/FormLabelContext.d.ts +1 -1
- package/src/Icon/Icon.classes.d.ts +3 -3
- package/src/Icon/Icon.d.ts +1 -1
- package/src/Icon/Icon.type.d.ts +2 -2
- package/src/IconButton/IconButton.classes.d.ts +3 -3
- package/src/IconButton/IconButton.type.d.ts +9 -9
- package/src/IconButton/IconButtonLabel.classes.d.ts +3 -3
- package/src/IconButton/IconButtonLabel.d.ts +1 -1
- package/src/IconButton/IconButtonLabel.type.d.ts +1 -1
- package/src/IconButtonGroup/IconButtonGroup.classes.d.ts +3 -3
- package/src/IconButtonGroup/IconButtonGroup.type.d.ts +4 -4
- package/src/InlineEditable/InlineEditable.classes.d.ts +4 -4
- package/src/InlineEditable/InlineEditable.type.d.ts +5 -5
- package/src/LinearProgressIndicator/LinearProgressIndicator.classes.d.ts +4 -4
- package/src/LinearProgressIndicator/LinearProgressIndicator.type.d.ts +2 -2
- package/src/Link/Link.classes.d.ts +4 -4
- package/src/Link/Link.type.d.ts +4 -4
- package/src/List/List.classes.d.ts +3 -3
- package/src/List/List.type.d.ts +1 -1
- package/src/ListItem/HoverActions.d.ts +1 -1
- package/src/ListItem/ListItem.classes.d.ts +3 -3
- package/src/ListItem/ListItem.d.ts +1 -1
- package/src/ListItem/ListItem.type.d.ts +1 -1
- package/src/ListItemText/ListItemText.classes.d.ts +4 -4
- package/src/ListItemText/ListItemText.d.ts +1 -1
- package/src/ListItemText/ListItemText.type.d.ts +2 -2
- package/src/ListNavigation/ListNavigationContext.d.ts +1 -1
- package/src/ListNavigation/useListNavigation.d.ts +6 -6
- package/src/Menu/Menu.classes.d.ts +3 -3
- package/src/Menu/Menu.d.ts +1 -1
- package/src/Menu/Menu.type.d.ts +1 -1
- package/src/Menu/MenuContext.d.ts +1 -1
- package/src/MenuActions/MenuActions.classes.d.ts +6 -6
- package/src/MenuActions/MenuActions.type.d.ts +1 -1
- package/src/MenuDivider/MenuDivider.classes.d.ts +3 -3
- package/src/MenuDivider/MenuDivider.type.d.ts +1 -1
- package/src/MenuFooter/MenuFooter.classes.d.ts +3 -3
- package/src/MenuFooter/MenuFooter.type.d.ts +1 -1
- package/src/MenuHeader/MenuHeader.classes.d.ts +3 -3
- package/src/MenuHeader/MenuHeader.type.d.ts +1 -1
- package/src/MenuItem/MenuItem.classes.d.ts +3 -3
- package/src/MenuItem/MenuItem.d.ts +1 -1
- package/src/MenuItem/MenuItem.type.d.ts +1 -1
- package/src/MenuItem/MenuItemSelectContext.d.ts +1 -1
- package/src/MenuItem/useMenuItem.d.ts +1 -1
- package/src/MenuItem/useMenuItemSelect.d.ts +5 -5
- package/src/MenuItem/useVirtualizedMenuItem.d.ts +2 -1
- package/src/MenuItemText/MenuItemText.classes.d.ts +3 -3
- package/src/MenuItemText/MenuItemText.d.ts +1 -1
- package/src/MenuItemText/MenuItemText.type.d.ts +1 -1
- package/src/MenuList/MenuList.classes.d.ts +3 -3
- package/src/MenuList/MenuList.type.d.ts +1 -1
- package/src/MenuList/MenuListContext.d.ts +1 -1
- package/src/Modal/InnerModal.d.ts +1 -1
- package/src/Modal/InnerModal.type.d.ts +2 -2
- package/src/Modal/Modal.classes.d.ts +3 -3
- package/src/Modal/Modal.d.ts +1 -1
- package/src/Modal/Modal.type.d.ts +1 -1
- package/src/Modal/ModalContext.d.ts +1 -1
- package/src/NestedMenuContext/MenuOverlayGroupContext.d.ts +15 -0
- package/src/NestedMenuContext/NestedMenuContext.d.ts +22 -5
- package/src/NestedMenuContext/SubMenuTriggerNestedIdContext.d.ts +2 -0
- package/src/NestedMenuContext/pointerGrace.d.ts +8 -0
- package/src/NestedMenuContext/useNestedChildMenu.d.ts +4 -2
- package/src/NestedMenuContext/useNestedMenuItem.d.ts +8 -3
- package/src/NestedMenuContext/useNestedParentMenu.d.ts +8 -1
- package/src/Option/Option.d.ts +1 -1
- package/src/Option/Option.type.d.ts +1 -1
- package/src/Overlap/Overlap.classes.d.ts +3 -3
- package/src/Overlap/Overlap.type.d.ts +8 -8
- package/src/PageHeader/PageHeader.classes.d.ts +15 -15
- package/src/PageHeader/PageHeader.type.d.ts +6 -6
- package/src/PickerTextField/PickerTextField.classes.d.ts +3 -3
- package/src/PickerTextField/PickerTextField.d.ts +1 -1
- package/src/PickerTextField/PickerTextField.type.d.ts +2 -2
- package/src/Popover/Popover.classes.d.ts +3 -3
- package/src/Popover/Popover.d.ts +1 -1
- package/src/Popover/Popover.type.d.ts +2 -2
- package/src/Popper/Popper.d.ts +1 -1
- package/src/Popper/Popper.type.d.ts +4 -4
- package/src/PopperPaper/PopperPaper.classes.d.ts +3 -3
- package/src/PopperPaper/PopperPaper.d.ts +1 -1
- package/src/PopperPaper/PopperPaper.type.d.ts +1 -1
- package/src/Radio/Radio.classes.d.ts +3 -3
- package/src/Radio/Radio.d.ts +2 -2
- package/src/Radio/Radio.type.d.ts +1 -1
- package/src/RadioGroup/RadioGroup.classes.d.ts +3 -3
- package/src/RadioGroup/RadioGroup.context.d.ts +1 -1
- package/src/RadioGroup/RadioGroup.d.ts +1 -1
- package/src/RadioGroup/RadioGroup.type.d.ts +1 -1
- package/src/Rating/Rating.classes.d.ts +3 -3
- package/src/Rating/Rating.d.ts +1 -1
- package/src/Rating/Rating.type.d.ts +2 -2
- package/src/Rating/RatingItem.d.ts +1 -1
- package/src/Select/Select.classes.d.ts +4 -4
- package/src/Select/Select.type.d.ts +5 -5
- package/src/Select/useSelect.d.ts +1 -1
- package/src/SingleFilter/FilterButton/FilterButton.classes.d.ts +3 -3
- package/src/SingleFilter/FilterButton/FilterButton.d.ts +1 -1
- package/src/SingleFilter/FilterButton/FilterButton.type.d.ts +2 -2
- package/src/SingleFilter/SingleFilter.classes.d.ts +3 -3
- package/src/SingleFilter/SingleFilter.d.ts +1 -1
- package/src/SingleFilter/SingleFilter.type.d.ts +2 -2
- package/src/Skeleton/Skeleton.classes.d.ts +3 -3
- package/src/Skeleton/Skeleton.type.d.ts +1 -1
- package/src/Skeleton/SkeletonContainer/SkeletonContainer.classes.d.ts +3 -3
- package/src/Skeleton/SkeletonContainer/SkeletonContainer.type.d.ts +5 -5
- package/src/Slider/Slider.classes.d.ts +4 -4
- package/src/Slider/Slider.d.ts +3 -3
- package/src/Slider/Slider.type.d.ts +2 -2
- package/src/Slider/SliderThumb.d.ts +1 -1
- package/src/Snackbar/Snackbar.classes.d.ts +3 -3
- package/src/Snackbar/Snackbar.d.ts +1 -1
- package/src/Snackbar/Snackbar.type.d.ts +1 -1
- package/src/Snackbar/SnackbarContent/SnackbarContent.classes.d.ts +3 -3
- package/src/Snackbar/SnackbarContent/SnackbarContent.type.d.ts +1 -1
- package/src/SortableList/SortableList.type.d.ts +1 -1
- package/src/SortableListDndContext/SortableListDndContext.type.d.ts +2 -2
- package/src/SortableListItem/SortableListItem.d.ts +1 -1
- package/src/SortableListItem/SortableListItem.type.d.ts +2 -2
- package/src/SortableListItem/SortableListItemOverlay.d.ts +1 -1
- package/src/SortableListItem/SortableListItemOverlay.type.d.ts +1 -1
- package/src/SortableVirtualizedList/SortableVirtualizedList.type.d.ts +1 -1
- package/src/SplitButton/SplitButton.classes.d.ts +3 -3
- package/src/SplitButton/SplitButton.d.ts +1 -1
- package/src/SplitButton/SplitButton.type.d.ts +1 -1
- package/src/Squircle/Squircle.type.d.ts +5 -5
- package/src/Squircle/squircle.classes.d.ts +3 -3
- package/src/StatusIndicator/StatusIndicator.classes.d.ts +3 -3
- package/src/StatusIndicator/StatusIndicator.type.d.ts +1 -1
- package/src/Step/Step.classes.d.ts +3 -3
- package/src/Step/Step.type.d.ts +5 -5
- package/src/Step/StepContext.d.ts +1 -1
- package/src/StepButton/StepButton.classes.d.ts +3 -3
- package/src/StepButton/StepButton.type.d.ts +5 -5
- package/src/StepConnector/StepConnector.classes.d.ts +3 -3
- package/src/StepConnector/StepConnector.type.d.ts +1 -1
- package/src/StepContent/StepContent.classes.d.ts +3 -3
- package/src/StepContent/StepContent.d.ts +1 -1
- package/src/StepContent/StepContent.type.d.ts +1 -1
- package/src/StepIcon/StepIcon.classes.d.ts +3 -3
- package/src/StepIcon/StepIcon.type.d.ts +1 -1
- package/src/StepLabel/StepLabel.classes.d.ts +4 -4
- package/src/StepLabel/StepLabel.d.ts +1 -1
- package/src/StepLabel/StepLabel.type.d.ts +1 -1
- package/src/Stepper/Stepper.classes.d.ts +3 -3
- package/src/Stepper/Stepper.type.d.ts +6 -6
- package/src/Stepper/StepperContext.d.ts +1 -1
- package/src/SubMenu/PopperMenu.classes.d.ts +3 -3
- package/src/SubMenu/PopperMenu.d.ts +1 -1
- package/src/SubMenu/PopperMenu.type.d.ts +1 -1
- package/src/SubMenu/SubMenu.d.ts +1 -1
- package/src/SubMenu/SubMenu.type.d.ts +1 -1
- package/src/SubMenu/useSubMenuInteractionState.d.ts +13 -0
- package/src/SubMenu/useSubMenuPointerGrace.d.ts +15 -0
- package/src/SwipeableDrawer/SwipeableDrawer.classes.d.ts +3 -3
- package/src/SwipeableDrawer/SwipeableDrawer.d.ts +1 -1
- package/src/SwipeableDrawer/SwipeableDrawer.types.d.ts +2 -2
- package/src/SwipeableDrawer/hooks/useSnapPoints.d.ts +1 -1
- package/src/Switch/Switch.classes.d.ts +3 -3
- package/src/Switch/Switch.d.ts +4 -2
- package/src/Switch/Switch.type.d.ts +4 -1
- package/src/Tab/Tab.classes.d.ts +4 -4
- package/src/Tab/Tab.d.ts +1 -1
- package/src/Tab/Tab.type.d.ts +4 -4
- package/src/TabContext/TabContext.type.d.ts +1 -1
- package/src/TabPanel/TabPanel.classes.d.ts +3 -3
- package/src/TabPanel/TabPanel.d.ts +1 -1
- package/src/TabPanel/TabPanel.type.d.ts +1 -1
- package/src/Table/Table.classes.d.ts +3 -3
- package/src/Table/Table.type.d.ts +5 -5
- package/src/Table/TableContext.d.ts +1 -1
- package/src/Table/Tablelvl2Context.d.ts +1 -1
- package/src/TableBody/TableBody.classes.d.ts +3 -3
- package/src/TableBody/TableBody.type.d.ts +5 -5
- package/src/TableCell/TableCell.classes.d.ts +3 -3
- package/src/TableCell/TableCell.type.d.ts +7 -7
- package/src/TableContainer/TableContainer.classes.d.ts +3 -3
- package/src/TableContainer/TableContainer.type.d.ts +6 -6
- package/src/TableFooter/TableFooter.classes.d.ts +3 -3
- package/src/TableFooter/TableFooter.d.ts +1 -1
- package/src/TableFooter/TableFooter.type.d.ts +1 -1
- package/src/TableHead/TableHead.classes.d.ts +3 -3
- package/src/TableHead/TableHead.type.d.ts +5 -5
- package/src/TablePagination/TablePagination.classes.d.ts +3 -3
- package/src/TablePagination/TablePagination.type.d.ts +8 -6
- package/src/TableRow/TableRow.classes.d.ts +3 -3
- package/src/TableRow/TableRow.type.d.ts +5 -5
- package/src/Tabs/TabMoreMenu.d.ts +2 -2
- package/src/Tabs/TabScrollButton.d.ts +2 -2
- package/src/Tabs/Tabs.classes.d.ts +9 -9
- package/src/Tabs/Tabs.d.ts +1 -1
- package/src/Tabs/Tabs.type.d.ts +2 -2
- package/src/Tabs/TabsContext.d.ts +1 -1
- package/src/Tabs/hooks/useTabsScroller.d.ts +3 -3
- package/src/Tag/Tag.classes.d.ts +3 -3
- package/src/Tag/Tag.d.ts +1 -1
- package/src/Tag/Tag.type.d.ts +2 -2
- package/src/Text/Text.classes.d.ts +3 -3
- package/src/Text/Text.type.d.ts +5 -5
- package/src/TextField/TextField.classes.d.ts +3 -3
- package/src/TextField/TextField.d.ts +1 -1
- package/src/TextField/TextField.type.d.ts +9 -9
- package/src/Textarea/Textarea.classes.d.ts +4 -4
- package/src/Textarea/Textarea.d.ts +1 -1
- package/src/Textarea/Textarea.type.d.ts +3 -3
- package/src/TimePicker/NumberPicker.d.ts +1 -1
- package/src/TimePicker/NumberPicker.type.d.ts +3 -3
- package/src/TimePicker/PickerView.type.d.ts +3 -3
- package/src/TimePicker/SelectionView.d.ts +1 -1
- package/src/TimePicker/TimeButton.d.ts +1 -1
- package/src/TimePicker/TimePicker.classes.d.ts +3 -3
- package/src/TimePicker/TimePicker.type.d.ts +1 -1
- package/src/TimePicker/ToggleText.d.ts +1 -1
- package/src/TimePicker/ToggleText.type.d.ts +2 -2
- package/src/TimePicker/utils/TimeBoundary.d.ts +3 -3
- package/src/TimePicker/utils/TimePickerHelper.d.ts +5 -5
- package/src/TimePicker/utils/getNumberPickerBoundary.d.ts +1 -1
- package/src/TimePicker/utils/runKeyHandler.d.ts +1 -1
- package/src/Tooltip/Tooltip.type.d.ts +1 -1
- package/src/Tooltip/TooltipTrigger.a11y.d.ts +4 -4
- package/src/Tooltip/TooltipTrigger.type.d.ts +1 -1
- package/src/Tooltip/TooltipView.classes.d.ts +3 -3
- package/src/Tooltip/TooltipView.type.d.ts +2 -2
- package/src/Tooltip/withTooltip/withTooltip.d.ts +1 -1
- package/src/Tray/Tray.classes.d.ts +6 -6
- package/src/Tray/Tray.d.ts +1 -1
- package/src/Tray/Tray.type.d.ts +2 -2
- package/src/Tray/TrayContext.d.ts +1 -1
- package/src/Tray/TrayPanel.d.ts +1 -1
- package/src/Tray/hooks/useTray.d.ts +2 -2
- package/src/Tray/hooks/useTrayPanel.d.ts +2 -2
- package/src/Tray/types.d.ts +2 -2
- package/src/TrayMenu/TrayMenu.d.ts +1 -1
- package/src/TrayMenu/TrayMenu.type.d.ts +1 -1
- package/src/TrayMenu/TrayMenuItem.d.ts +2 -2
- package/src/VirtualizedList/VirtualizedItemPropsContext.d.ts +1 -1
- package/src/VirtualizedList/VirtualizedList.type.d.ts +2 -2
- package/src/VirtualizedList/VirtuosoContextType.d.ts +1 -1
- package/src/VirtualizedMenu/VirtualizedMenu.classes.d.ts +3 -3
- package/src/VirtualizedMenu/VirtualizedMenu.context.d.ts +1 -1
- package/src/VirtualizedMenu/VirtualizedMenu.type.d.ts +1 -1
- package/src/VirtualizedMenu/VirtualizedMenuList.d.ts +1 -1
- package/src/VisuallyHidden/VisuallyHidden.classes.d.ts +3 -3
- package/src/VisuallyHidden/VisuallyHidden.type.d.ts +1 -1
- package/src/internal/utils/composeEventHandlers.d.ts +7 -0
- package/src/internal/utils/index.d.ts +1 -0
- package/src/Animation/hooks/useMotionSafeTransition/useMotionSafeTransition.d.ts +0 -6
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { CamelCase } from 'type-fest';
|
|
2
|
-
export
|
|
3
|
-
export
|
|
4
|
-
export
|
|
2
|
+
export type BaseTextFieldClassesKey = 'clear' | 'root' | 'full-width' | 'hide-native-clear' | 'input' | 'end-adornment' | 'start-adornment' | 'form-field-content' | 'outlined' | 'standard' | 'quiet' | 'helper-text' | 'mask-value-button';
|
|
3
|
+
export type TextFieldClassesKey = CamelCase<BaseTextFieldClassesKey>;
|
|
4
|
+
export type TextFieldClasses = {
|
|
5
5
|
name: 'text-field';
|
|
6
6
|
classes: BaseTextFieldClassesKey;
|
|
7
7
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ElementType } from 'react';
|
|
2
2
|
import textFieldStyle from './styles/TextField.css';
|
|
3
3
|
import { TextFieldProps } from './TextField.type';
|
|
4
|
-
declare const TextField: import("react").ForwardRefExoticComponent<Pick<TextFieldProps<ElementType
|
|
4
|
+
declare const TextField: import("react").ForwardRefExoticComponent<Pick<TextFieldProps<ElementType>, "error" | "value" | "onKeyDown" | "onKeyUp" | "onClick" | "disabled" | "label" | "classes" | "focused" | "required" | "className" | "id" | "defaultValue" | "placeholder" | "readOnly" | "size" | "type" | "onFocus" | "onBlur" | "onChange" | "helperText" | "FormHelperTextProps" | "variant" | "autoFocus" | "fullWidth" | "inputProps" | "inputRef" | "endAdornment" | "startAdornment" | "RootProps" | "clearBtn" | "useNativeClearBtn" | "clearText" | "showCharacterCount" | "ClearButtonProps" | "onClear" | "inputComponent" | "showMaskValueToggleButton" | "maskValue" | "onMaskValueChange" | "MaskValueButtonProps" | "ShowHideEyeIconProps"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
5
5
|
export { TextField, textFieldStyle };
|
|
@@ -5,11 +5,11 @@ import { FormFieldProps } from '../FormField';
|
|
|
5
5
|
import { IconButtonProps } from '../IconButton';
|
|
6
6
|
import { ShowHideEyeProps } from '../Animation';
|
|
7
7
|
import { TextFieldClassesKey } from './TextField.classes';
|
|
8
|
-
|
|
9
|
-
export
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
8
|
+
type ReactInputComponentProps = React.HTMLAttributes<HTMLInputElement | HTMLTextAreaElement>;
|
|
9
|
+
export type StandardInputAttributes = HTMLAttributes<HTMLInputElement | HTMLTextAreaElement> & (InputHTMLAttributes<HTMLInputElement> | TextareaHTMLAttributes<HTMLTextAreaElement>);
|
|
10
|
+
type InputComponentProps = ReactInputComponentProps & StandardInputAttributes;
|
|
11
|
+
type OmittedInputProps = 'type' | 'className' | 'placeholder' | 'children';
|
|
12
|
+
type TextFieldRawProps = {
|
|
13
13
|
ref?: Ref<HTMLDivElement>;
|
|
14
14
|
placeholder?: string;
|
|
15
15
|
RootProps?: FormFieldProps & HTMLDataAttribute;
|
|
@@ -30,14 +30,14 @@ declare type TextFieldRawProps = {
|
|
|
30
30
|
onKeyDown?: KeyboardEventHandler<HTMLDivElement>;
|
|
31
31
|
onKeyUp?: KeyboardEventHandler<HTMLDivElement>;
|
|
32
32
|
} & Pick<FormFieldProps, 'className' | 'label' | 'helperText' | 'variant' | 'focused' | 'size' | 'FormHelperTextProps'> & Omit<UseInputParameters, 'value' | 'defaultValue' | 'onBlur' | 'onFocus' | 'onClick'> & Pick<ComponentPropsWithRef<'input'>, 'autoFocus' | 'id' | 'readOnly'>;
|
|
33
|
-
|
|
34
|
-
export
|
|
33
|
+
type BaseTextFieldProps = WithClassesProps<TextFieldRawProps, TextFieldClassesKey>;
|
|
34
|
+
export type OverridableTextFieldProps<B, T extends ElementType, P extends InputComponentProps> = B & {
|
|
35
35
|
inputComponent?: T;
|
|
36
36
|
inputProps?: (T extends 'input' ? Omit<P & InputHTMLAttributes<HTMLInputElement>, OmittedInputProps> : Omit<P, OmittedInputProps>) & HTMLDataAttribute;
|
|
37
37
|
focused?: boolean;
|
|
38
38
|
};
|
|
39
|
-
export
|
|
40
|
-
export
|
|
39
|
+
export type SharedTextInputProps<T extends ElementType = 'input', P extends InputComponentProps = InputComponentProps> = OverridableTextFieldProps<BaseTextFieldProps, T, P>;
|
|
40
|
+
export type TextFieldProps<T extends ElementType = 'input', P extends InputComponentProps = InputComponentProps> = SharedTextInputProps<T, P> & {
|
|
41
41
|
type?: 'text' | 'password' | 'number' | 'email' | 'tel' | 'url' | 'search';
|
|
42
42
|
showMaskValueToggleButton?: boolean;
|
|
43
43
|
maskValue?: boolean;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import type { CamelCase } from 'type-fest';
|
|
2
2
|
import { FormFieldSize } from '../FormField';
|
|
3
3
|
import type { TextAreaVariant } from './Textarea.type';
|
|
4
|
-
export
|
|
5
|
-
export
|
|
6
|
-
export
|
|
7
|
-
export
|
|
4
|
+
export type TextareaSlot = 'input' | 'form-field-content';
|
|
5
|
+
export type BaseTextareaClassesKey = 'root' | TextAreaVariant | TextareaSlot | `${TextareaSlot}-${FormFieldSize}` | `${TextAreaVariant}-${TextareaSlot}` | 'clear' | `clear-${TextAreaVariant}` | `clear-${FormFieldSize}`;
|
|
6
|
+
export type TextareaClassesKey = CamelCase<BaseTextareaClassesKey>;
|
|
7
|
+
export type TextareaClasses = {
|
|
8
8
|
name: 'textarea';
|
|
9
9
|
classes: BaseTextareaClassesKey;
|
|
10
10
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import textareaStyle from './styles/Textarea.css';
|
|
3
3
|
import { TextareaProps } from './Textarea.type';
|
|
4
|
-
declare const Textarea: import("react").ForwardRefExoticComponent<Pick<TextareaProps, "error" | "value" | "onKeyDown" | "onKeyUp" | "onMouseDown" | "onClick" | "disabled" | "
|
|
4
|
+
declare const Textarea: import("react").ForwardRefExoticComponent<Pick<TextareaProps, "error" | "value" | "onKeyDown" | "onKeyUp" | "onMouseDown" | "onClick" | "disabled" | "form" | "label" | "slot" | "style" | "title" | "aria-live" | "aria-atomic" | "aria-hidden" | "role" | "classes" | "name" | "focused" | "required" | "className" | "accessKey" | "dir" | "draggable" | "hidden" | "lang" | "translate" | "id" | "prefix" | "contentEditable" | "inputMode" | "tabIndex" | "key" | "defaultChecked" | "defaultValue" | "dirName" | "maxLength" | "minLength" | "placeholder" | "readOnly" | "size" | "cols" | "rows" | "wrap" | "onFocus" | "onBlur" | "onMouseEnter" | "onMouseLeave" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "contextMenu" | "spellCheck" | "radioGroup" | "about" | "datatype" | "inlist" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "is" | "aria-activedescendant" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDownCapture" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | `data-${string}` | "helperText" | "FormHelperTextProps" | "variant" | "autoFocus" | "autoComplete" | "fullWidth" | "inputProps" | "inputRef" | "maxRows" | "minRows" | "endAdornment" | "startAdornment" | "RootProps" | "clearBtn" | "useNativeClearBtn" | "clearText" | "showCharacterCount" | "ClearButtonProps" | "onClear" | "inputComponent"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
5
5
|
export { Textarea, textareaStyle };
|
|
@@ -2,12 +2,12 @@ import { TextareaAutosize, TextareaAutosizeProps } from '@mui/base';
|
|
|
2
2
|
import { StandardProps, UnionOmit } from '@ringcentral/spring-base';
|
|
3
3
|
import { SharedTextInputProps } from '../TextField';
|
|
4
4
|
import { TextFieldClassesKey } from '../TextField/TextField.classes';
|
|
5
|
-
export
|
|
6
|
-
|
|
5
|
+
export type TextAreaVariant = UnionOmit<NonNullable<SharedTextInputProps['variant']>, 'quiet'>;
|
|
6
|
+
type TextAreaInputProps = {
|
|
7
7
|
maxRows?: number;
|
|
8
8
|
minRows?: number;
|
|
9
9
|
rows?: number;
|
|
10
10
|
variant?: TextAreaVariant;
|
|
11
11
|
} & Omit<TextareaAutosizeProps, 'value' | 'defaultValue'>;
|
|
12
|
-
export
|
|
12
|
+
export type TextareaProps = StandardProps<TextAreaInputProps & SharedTextInputProps<typeof TextareaAutosize, TextAreaInputProps>, TextFieldClassesKey, typeof TextareaAutosize, 'inputComponent' | 'variant'>;
|
|
13
13
|
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { NumberPickerProps, NumberPickerRef } from './NumberPicker.type';
|
|
3
|
-
declare const NumberPicker: import("react").ForwardRefExoticComponent<Pick<NumberPickerProps, "value" | "children" | "onKeyDown" | "onKeyUp" | "onMouseDown" | "onClick" | "
|
|
3
|
+
declare const NumberPicker: import("react").ForwardRefExoticComponent<Pick<NumberPickerProps, "value" | "children" | "onKeyDown" | "onKeyUp" | "onMouseDown" | "onClick" | "slot" | "source" | "style" | "title" | "aria-live" | "aria-atomic" | "aria-hidden" | "role" | "className" | "accessKey" | "dir" | "draggable" | "hidden" | "lang" | "translate" | "id" | "prefix" | "contentEditable" | "inputMode" | "tabIndex" | "key" | "defaultChecked" | "defaultValue" | "max" | "min" | "placeholder" | "step" | "onFocus" | "onBlur" | "onMouseEnter" | "onMouseLeave" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "contextMenu" | "spellCheck" | "radioGroup" | "about" | "datatype" | "inlist" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "is" | "aria-activedescendant" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDownCapture" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | `data-${string}` | "autoFocus" | "renderValue" | "getScreenReaderLabel" | "isTwelveHourSystem"> & import("react").RefAttributes<NumberPickerRef>>;
|
|
4
4
|
export { NumberPicker };
|
|
5
5
|
export type { NumberPickerProps, NumberPickerRef };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { PropsWithRoot } from '@ringcentral/spring-base';
|
|
2
2
|
import { Ref } from 'react';
|
|
3
|
-
export
|
|
3
|
+
export type NumberPickerProps = PropsWithRoot<{
|
|
4
4
|
min?: number;
|
|
5
5
|
max?: number;
|
|
6
6
|
onClick?: () => void;
|
|
@@ -14,11 +14,11 @@ export declare type NumberPickerProps = PropsWithRoot<{
|
|
|
14
14
|
isTwelveHourSystem?: boolean;
|
|
15
15
|
ref?: Ref<NumberPickerRef>;
|
|
16
16
|
}, 'div'>;
|
|
17
|
-
export
|
|
17
|
+
export type NumberPickerRef = {
|
|
18
18
|
value: number;
|
|
19
19
|
setRange: (range: Range) => void;
|
|
20
20
|
};
|
|
21
|
-
export
|
|
21
|
+
export type Range = {
|
|
22
22
|
min?: number;
|
|
23
23
|
max?: number;
|
|
24
24
|
};
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { TIME_SYSTEM_TEXT } from './constant';
|
|
2
2
|
import { TimeBoundary } from './utils';
|
|
3
|
-
export
|
|
3
|
+
export type PickerViewScreenReaderProps = {
|
|
4
4
|
getHourPickerAriaLabel: (hour: string) => string;
|
|
5
5
|
getMinutePickerAriaLabel: (minute: string) => string;
|
|
6
6
|
getPeriodToggleAriaLabel: (period: TIME_SYSTEM_TEXT) => string;
|
|
7
7
|
};
|
|
8
|
-
export
|
|
8
|
+
export type PickerViewValue = {
|
|
9
9
|
hour: number;
|
|
10
10
|
minute: number;
|
|
11
11
|
period: TIME_SYSTEM_TEXT;
|
|
12
12
|
};
|
|
13
|
-
export
|
|
13
|
+
export type PickerViewProps = {
|
|
14
14
|
isTwelveHourSystem: boolean;
|
|
15
15
|
selectionShowType: 'none' | 'hour' | 'minute';
|
|
16
16
|
onSelectionShowTypeChange: (selectionShowType: 'none' | 'hour' | 'minute') => void;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { PropsWithRoot } from '@ringcentral/spring-base';
|
|
3
|
-
|
|
3
|
+
type TimeButtonProps = PropsWithRoot<{
|
|
4
4
|
selected?: boolean;
|
|
5
5
|
}, 'button'>;
|
|
6
6
|
declare const TimeButton: import("react").ForwardRefExoticComponent<Pick<TimeButtonProps, "selected" | "key" | `data-${string}` | keyof import("react").ButtonHTMLAttributes<HTMLButtonElement>> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { CamelCase } from 'type-fest';
|
|
2
|
-
export
|
|
3
|
-
export
|
|
4
|
-
export
|
|
2
|
+
export type BaseTimePickerClassesKey = 'root' | 'picker-root' | 'time-button' | 'number-picker' | 'picker-view' | 'main-view' | 'minute-selection-view' | 'hour-selection-view' | 'twelve-hour';
|
|
3
|
+
export type TimePickerClassesKey = CamelCase<BaseTimePickerClassesKey>;
|
|
4
|
+
export type TimePickerClasses = {
|
|
5
5
|
name: 'time-picker';
|
|
6
6
|
classes: BaseTimePickerClassesKey;
|
|
7
7
|
};
|
|
@@ -3,7 +3,7 @@ import { ReactElement } from 'react';
|
|
|
3
3
|
import { PickerTextField } from '../PickerTextField';
|
|
4
4
|
import { PickerViewScreenReaderProps } from './PickerView.type';
|
|
5
5
|
import { TimePickerClassesKey } from './TimePicker.classes';
|
|
6
|
-
export
|
|
6
|
+
export type TimePickerProps<T = false> = StandardProps<{
|
|
7
7
|
isTwelveHourSystem?: boolean;
|
|
8
8
|
value: (T extends true ? Date : number) | null;
|
|
9
9
|
dateMode?: T;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { ToggleTextProps, ToggleTextRef } from './ToggleText.type';
|
|
3
|
-
declare const ToggleText: import("react").ForwardRefExoticComponent<Pick<ToggleTextProps, "value" | "children" | "onKeyDown" | "onKeyUp" | "onMouseDown" | "onClick" | "disabled" | "
|
|
3
|
+
declare const ToggleText: import("react").ForwardRefExoticComponent<Pick<ToggleTextProps, "value" | "children" | "onKeyDown" | "onKeyUp" | "onMouseDown" | "onClick" | "disabled" | "form" | "slot" | "style" | "title" | "aria-live" | "aria-atomic" | "aria-hidden" | "role" | "name" | "className" | "accessKey" | "dir" | "draggable" | "hidden" | "lang" | "translate" | "id" | "prefix" | "contentEditable" | "inputMode" | "tabIndex" | "key" | "defaultChecked" | "defaultValue" | "formAction" | "formMethod" | "formNoValidate" | "formTarget" | "placeholder" | "type" | "onFocus" | "onBlur" | "onMouseEnter" | "onMouseLeave" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "contextMenu" | "spellCheck" | "radioGroup" | "about" | "datatype" | "inlist" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "is" | "aria-activedescendant" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDownCapture" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | `data-${string}` | "autoFocus" | "formEncType" | "getScreenReaderLabel" | "isTwelveHourSystem"> & import("react").RefAttributes<ToggleTextRef>>;
|
|
4
4
|
export { ToggleText };
|
|
5
5
|
export type { ToggleTextProps, ToggleTextRef };
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { PropsWithRoot } from '@ringcentral/spring-base';
|
|
2
2
|
import { TIME_SYSTEM_TEXT } from './constant';
|
|
3
|
-
export
|
|
3
|
+
export type ToggleTextProps = PropsWithRoot<{
|
|
4
4
|
onChange: (value: TIME_SYSTEM_TEXT, reason: 'arrowKey' | 'arrowButton') => void;
|
|
5
5
|
value: TIME_SYSTEM_TEXT;
|
|
6
6
|
getScreenReaderLabel?: (value: TIME_SYSTEM_TEXT) => string;
|
|
7
7
|
isTwelveHourSystem?: boolean;
|
|
8
8
|
}, 'button'>;
|
|
9
|
-
export
|
|
9
|
+
export type ToggleTextRef = {
|
|
10
10
|
value: TIME_SYSTEM_TEXT;
|
|
11
11
|
};
|
|
@@ -15,9 +15,9 @@ export declare class TimeBoundary {
|
|
|
15
15
|
private getDateTime;
|
|
16
16
|
}
|
|
17
17
|
export declare const getRangeBoundary: ({ min, max, gap, }: {
|
|
18
|
-
min?: number | Date
|
|
19
|
-
max?: number | Date
|
|
20
|
-
gap?: number
|
|
18
|
+
min?: number | Date;
|
|
19
|
+
max?: number | Date;
|
|
20
|
+
gap?: number;
|
|
21
21
|
}) => {
|
|
22
22
|
min: TimeBoundary;
|
|
23
23
|
max: TimeBoundary;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { TIME_SYSTEM_TEXT } from '../constant';
|
|
2
|
-
declare const parseNumber: (value: number, isTwelveHourSystem?: boolean
|
|
3
|
-
declare const parseNumberToString: (value: number, isTwelveHourSystem?: boolean
|
|
2
|
+
declare const parseNumber: (value: number, isTwelveHourSystem?: boolean) => number;
|
|
3
|
+
declare const parseNumberToString: (value: number, isTwelveHourSystem?: boolean) => string;
|
|
4
4
|
declare const pad: (num: number, size?: number) => string;
|
|
5
|
-
|
|
5
|
+
type GetFormattedTimeOption = {
|
|
6
6
|
hour: number;
|
|
7
7
|
minute: number;
|
|
8
8
|
period: TIME_SYSTEM_TEXT;
|
|
9
9
|
};
|
|
10
|
-
declare const getFormattedTime: ({ hour, minute, period }: GetFormattedTimeOption, isTwelveHourSystem?: boolean
|
|
10
|
+
declare const getFormattedTime: ({ hour, minute, period }: GetFormattedTimeOption, isTwelveHourSystem?: boolean) => string;
|
|
11
11
|
declare const HALF_DAY_HOURS = 12;
|
|
12
12
|
declare const HOUR_MINUTES = 60;
|
|
13
13
|
declare const TIME_GAP = 15;
|
|
@@ -29,5 +29,5 @@ declare const getTimestampFromHourAndMin: (option: {
|
|
|
29
29
|
minute: number;
|
|
30
30
|
}) => number;
|
|
31
31
|
declare function getPeriod(currHour: number): TIME_SYSTEM_TEXT;
|
|
32
|
-
declare const getRecoupHour: (currHour: number, period?: TIME_SYSTEM_TEXT
|
|
32
|
+
declare const getRecoupHour: (currHour: number, period?: TIME_SYSTEM_TEXT) => number;
|
|
33
33
|
export { getFormattedTime, getHourAndMinute, getPeriod, getRecoupHour, getTimestamp, getTimestampFromDate, getTimestampFromHourAndMin, HALF_DAY_HOURS, HOUR_MINUTES, lastMinute, minuteSource, ONE_HOUR, pad, parseNumber, parseNumberToString, TIME_GAP, twelveHourSystemSource, twentyFourHourSystemSource, };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { KeyboardEvent } from 'react';
|
|
2
|
-
|
|
2
|
+
type KeyHandlers = Record<KeyboardEvent['key'], () => void>;
|
|
3
3
|
export declare const runKeyHandler: (e: KeyboardEvent<unknown>, keyHandlers: KeyHandlers) => void;
|
|
4
4
|
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { TooltipTriggerProps } from './TooltipTrigger.type';
|
|
2
2
|
import { TooltipViewProps } from './TooltipView.type';
|
|
3
|
-
export
|
|
3
|
+
export type TooltipProps = {
|
|
4
4
|
disableBackdropAnimation?: boolean;
|
|
5
5
|
} & Omit<TooltipViewProps, 'anchorEl' | 'children' | 'title'> & Omit<TooltipTriggerProps, 'renderTooltip' | 'tooltipId'>;
|
|
@@ -3,21 +3,21 @@ import { TooltipTriggerProps } from './TooltipTrigger.type';
|
|
|
3
3
|
declare const ARIA_DESCRIBEDBY = "aria-describedby";
|
|
4
4
|
declare const ARIA_LABEL = "aria-label";
|
|
5
5
|
declare const ARIA_LABELLEDBY = "aria-labelledby";
|
|
6
|
-
|
|
6
|
+
type TooltipA11yNameOrDescProps = {
|
|
7
7
|
title?: string | null;
|
|
8
8
|
[ARIA_DESCRIBEDBY]?: string | null;
|
|
9
9
|
[ARIA_LABEL]?: string | null;
|
|
10
10
|
[ARIA_LABELLEDBY]?: string | null;
|
|
11
11
|
};
|
|
12
|
-
|
|
12
|
+
type TooltipDisabledOverrides = {
|
|
13
13
|
title?: string | null;
|
|
14
14
|
[ARIA_DESCRIBEDBY]?: string;
|
|
15
15
|
};
|
|
16
|
-
export
|
|
16
|
+
export type TooltipA11yResult = {
|
|
17
17
|
nameOrDescProps: TooltipA11yNameOrDescProps;
|
|
18
18
|
disabledOverrides: TooltipDisabledOverrides;
|
|
19
19
|
};
|
|
20
|
-
|
|
20
|
+
type TooltipA11yInput = {
|
|
21
21
|
title: TooltipTriggerProps['title'];
|
|
22
22
|
describeChild: boolean;
|
|
23
23
|
triggerWhenDisabled?: boolean;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ReactElement, ReactNode } from 'react';
|
|
2
2
|
import { TooltipViewProps } from './TooltipView.type';
|
|
3
|
-
export
|
|
3
|
+
export type TooltipTriggerProps = {
|
|
4
4
|
children: ReactElement;
|
|
5
5
|
renderTooltip: (open: boolean, getAnchorEl: () => Element | null, tooltipId: string) => ReactNode;
|
|
6
6
|
onOpenStateChange?: (event: Event, isOpen: boolean) => void;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import type { CamelCase } from 'type-fest';
|
|
2
2
|
import type { TooltipSize } from './TooltipView.type';
|
|
3
|
-
export
|
|
4
|
-
export
|
|
5
|
-
export
|
|
3
|
+
export type BaseTooltipViewClassesKey = 'root' | 'paper' | 'paper-content' | `paper-content-${TooltipSize}` | 'icon' | TooltipSize | 'content' | `content-${TooltipSize}` | 'neutral' | 'success' | 'danger' | 'force-hide' | 'inverted' | 'disable-interactions';
|
|
4
|
+
export type TooltipViewClassesKey = CamelCase<BaseTooltipViewClassesKey>;
|
|
5
|
+
export type TooltipViewClasses = {
|
|
6
6
|
name: 'tooltip-view';
|
|
7
7
|
classes: BaseTooltipViewClassesKey;
|
|
8
8
|
};
|
|
@@ -5,8 +5,8 @@ import { IconProps } from '../Icon';
|
|
|
5
5
|
import { PopperProps } from '../Popper';
|
|
6
6
|
import { PopperPaperProps } from '../PopperPaper';
|
|
7
7
|
import { TooltipViewClassesKey } from './TooltipView.classes';
|
|
8
|
-
export
|
|
9
|
-
export
|
|
8
|
+
export type TooltipSize = 'small' | 'medium';
|
|
9
|
+
export type TooltipViewProps = StandardProps<{
|
|
10
10
|
children?: ReactNode;
|
|
11
11
|
color?: 'neutral' | 'danger' | 'success' | 'inverted';
|
|
12
12
|
size?: TooltipSize;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { ComponentType } from 'react';
|
|
2
2
|
import { TooltipProps } from '../Tooltip.type';
|
|
3
|
-
export
|
|
3
|
+
export type WithTooltipProps<P extends {} = {}> = P & {
|
|
4
4
|
TooltipProps?: Omit<TooltipProps, 'children'>;
|
|
5
5
|
};
|
|
6
6
|
export declare function withTooltip<T extends {}>(Component: ComponentType<T>): React.ForwardRefExoticComponent<React.PropsWithoutRef<WithTooltipProps<T>> & React.RefAttributes<unknown>>;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import type { CamelCase } from 'type-fest';
|
|
2
|
-
export
|
|
3
|
-
export
|
|
4
|
-
export
|
|
2
|
+
export type BaseTrayClassesKey = 'root';
|
|
3
|
+
export type TrayClassesKey = CamelCase<BaseTrayClassesKey>;
|
|
4
|
+
export type TrayClasses = {
|
|
5
5
|
name: 'tray';
|
|
6
6
|
classes: BaseTrayClassesKey;
|
|
7
7
|
};
|
|
8
|
-
export
|
|
9
|
-
export
|
|
10
|
-
export
|
|
8
|
+
export type BaseTrayPanelClassesKey = 'root' | 'activated';
|
|
9
|
+
export type TrayPanelClassesKey = CamelCase<BaseTrayPanelClassesKey>;
|
|
10
|
+
export type TrayPanelClasses = {
|
|
11
11
|
name: 'tray-panel';
|
|
12
12
|
classes: BaseTrayPanelClassesKey;
|
|
13
13
|
};
|
package/src/Tray/Tray.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import trayStyle from './styles/Tray.css';
|
|
3
3
|
import { TrayProps } from './Tray.type';
|
|
4
|
-
declare const Tray: import("react").ForwardRefExoticComponent<Pick<TrayProps, "value" | "children" | "onKeyDown" | "onKeyUp" | "onMouseDown" | "onClick" | "
|
|
4
|
+
declare const Tray: import("react").ForwardRefExoticComponent<Pick<TrayProps, "value" | "children" | "onKeyDown" | "onKeyUp" | "onMouseDown" | "onClick" | "slot" | "style" | "title" | "aria-live" | "aria-atomic" | "aria-hidden" | "role" | "classes" | "className" | "accessKey" | "dir" | "draggable" | "hidden" | "lang" | "translate" | "id" | "prefix" | "contentEditable" | "inputMode" | "tabIndex" | "key" | "defaultChecked" | "defaultValue" | "placeholder" | "onFocus" | "onBlur" | "onMouseEnter" | "onMouseLeave" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "contextMenu" | "spellCheck" | "radioGroup" | "about" | "datatype" | "inlist" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "is" | "aria-activedescendant" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDownCapture" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | `data-${string}` | "actions"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
5
5
|
export { Tray, trayStyle };
|
package/src/Tray/Tray.type.d.ts
CHANGED
|
@@ -2,10 +2,10 @@ import { StandardProps } from '@ringcentral/spring-base';
|
|
|
2
2
|
import { Ref } from 'react';
|
|
3
3
|
import { TrayClassesKey } from './Tray.classes';
|
|
4
4
|
import { TrayNavigateValue, TrayValue } from './types';
|
|
5
|
-
export
|
|
5
|
+
export type TrayActions = {
|
|
6
6
|
navigateTo: (value: TrayNavigateValue) => void;
|
|
7
7
|
};
|
|
8
|
-
export
|
|
8
|
+
export type TrayProps = StandardProps<{
|
|
9
9
|
value?: TrayValue;
|
|
10
10
|
defaultValue?: TrayValue;
|
|
11
11
|
onChange?: (event: React.SyntheticEvent | null, value: TrayValue) => void;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { RefObject, SyntheticEvent } from 'react';
|
|
2
2
|
import { TrayNavigateValue } from './types';
|
|
3
|
-
export
|
|
3
|
+
export type TrayContextValue = {
|
|
4
4
|
value: string | number;
|
|
5
5
|
navigateTo: (value: TrayNavigateValue, event: SyntheticEvent | null) => void;
|
|
6
6
|
direction: 'left' | 'right';
|
package/src/Tray/TrayPanel.d.ts
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
import { StandardProps } from '@ringcentral/spring-base';
|
|
3
3
|
import { UseTrayPanelParameters } from './hooks/useTrayPanel';
|
|
4
4
|
import { TrayPanelClassesKey } from './Tray.classes';
|
|
5
|
-
export
|
|
5
|
+
export type TrayPanelProps = StandardProps<UseTrayPanelParameters, TrayPanelClassesKey, 'div'>;
|
|
6
6
|
declare const TrayPanel: import("react").ForwardRefExoticComponent<Pick<TrayPanelProps, "value" | "classes" | "key" | `data-${string}` | keyof import("react").HTMLAttributes<HTMLDivElement>> & import("react").RefAttributes<HTMLDivElement>>;
|
|
7
7
|
export { TrayPanel };
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { RefObject, SyntheticEvent } from 'react';
|
|
2
2
|
import { TrayNavigateValue, TrayValue } from '../types';
|
|
3
|
-
export
|
|
3
|
+
export type UseTrayParameters = {
|
|
4
4
|
value?: TrayValue;
|
|
5
5
|
defaultValue?: TrayValue;
|
|
6
6
|
onChange?: (event: SyntheticEvent | null, value: TrayValue) => void;
|
|
7
7
|
containerRef: RefObject<HTMLDivElement>;
|
|
8
8
|
};
|
|
9
|
-
export
|
|
9
|
+
export type UseTray = (parameters: UseTrayParameters) => {
|
|
10
10
|
trayContextValue: {
|
|
11
11
|
value: TrayValue;
|
|
12
12
|
navigateTo: (value: TrayNavigateValue, event?: SyntheticEvent | null) => void;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { RefObject } from 'react';
|
|
2
2
|
import { TrayValue } from '../types';
|
|
3
|
-
export
|
|
3
|
+
export type UseTrayPanelParameters = {
|
|
4
4
|
value: TrayValue;
|
|
5
5
|
};
|
|
6
|
-
export
|
|
6
|
+
export type UseTrayPanel = (parameters: UseTrayPanelParameters) => {
|
|
7
7
|
activated: boolean;
|
|
8
8
|
containerRef: RefObject<HTMLDivElement>;
|
|
9
9
|
direction: 'left' | 'right';
|
package/src/Tray/types.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export
|
|
2
|
-
export
|
|
1
|
+
export type TrayValue = string | number;
|
|
2
|
+
export type TrayNavigateValue = TrayValue | null;
|