rsuite 5.46.1 → 5.48.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/CHANGELOG.md +23 -0
- package/CloseButton/styles/index.less +13 -7
- package/DateInput/package.json +7 -0
- package/Message/styles/mixin.less +8 -0
- package/Notification/styles/index.less +8 -0
- package/Picker/styles/index.less +0 -9
- package/Tag/styles/index.less +2 -5
- package/Uploader/styles/index.less +1 -2
- package/cjs/Affix/Affix.d.ts +6 -0
- package/cjs/Affix/Affix.js +7 -0
- package/cjs/Animation/Bounce.d.ts +4 -0
- package/cjs/Animation/Bounce.js +4 -0
- package/cjs/Animation/Collapse.d.ts +4 -0
- package/cjs/Animation/Collapse.js +5 -0
- package/cjs/Animation/Fade.d.ts +4 -0
- package/cjs/Animation/Fade.js +4 -0
- package/cjs/Animation/Slide.d.ts +4 -0
- package/cjs/Animation/Slide.js +4 -0
- package/cjs/Animation/Transition.d.ts +4 -0
- package/cjs/Animation/Transition.js +4 -0
- package/cjs/AutoComplete/AutoComplete.d.ts +3 -0
- package/cjs/AutoComplete/AutoComplete.js +3 -0
- package/cjs/Avatar/Avatar.d.ts +4 -0
- package/cjs/Avatar/Avatar.js +4 -0
- package/cjs/AvatarGroup/AvatarGroup.d.ts +4 -0
- package/cjs/AvatarGroup/AvatarGroup.js +5 -0
- package/cjs/Badge/Badge.d.ts +4 -0
- package/cjs/Badge/Badge.js +4 -0
- package/cjs/Breadcrumb/Breadcrumb.d.ts +4 -0
- package/cjs/Breadcrumb/Breadcrumb.js +4 -0
- package/cjs/Breadcrumb/BreadcrumbItem.d.ts +4 -0
- package/cjs/Breadcrumb/BreadcrumbItem.js +4 -0
- package/cjs/Button/Button.d.ts +4 -0
- package/cjs/Button/Button.js +4 -0
- package/cjs/ButtonGroup/ButtonGroup.d.ts +4 -0
- package/cjs/ButtonGroup/ButtonGroup.js +4 -0
- package/cjs/ButtonToolbar/ButtonToolbar.d.ts +4 -0
- package/cjs/ButtonToolbar/ButtonToolbar.js +4 -0
- package/cjs/Calendar/Calendar.d.ts +4 -0
- package/cjs/Calendar/Calendar.js +4 -0
- package/cjs/Carousel/Carousel.d.ts +4 -0
- package/cjs/Carousel/Carousel.js +4 -0
- package/cjs/Cascader/Cascader.d.ts +4 -0
- package/cjs/Cascader/Cascader.js +5 -0
- package/cjs/CheckPicker/CheckPicker.d.ts +4 -0
- package/cjs/CheckPicker/CheckPicker.js +4 -0
- package/cjs/CheckTree/index.d.ts +4 -0
- package/cjs/CheckTree/index.js +4 -0
- package/cjs/CheckTreePicker/CheckTreePicker.d.ts +5 -0
- package/cjs/CheckTreePicker/CheckTreePicker.js +6 -0
- package/cjs/Checkbox/Checkbox.d.ts +6 -0
- package/cjs/Checkbox/Checkbox.js +4 -0
- package/cjs/CheckboxGroup/CheckboxGroup.d.ts +4 -0
- package/cjs/CheckboxGroup/CheckboxGroup.js +4 -0
- package/cjs/CloseButton/CloseButton.js +3 -5
- package/cjs/Col/Col.d.ts +4 -0
- package/cjs/Col/Col.js +4 -0
- package/cjs/Container/Container.d.ts +4 -0
- package/cjs/Container/Container.js +4 -0
- package/cjs/Content/Content.d.ts +3 -0
- package/cjs/Content/Content.js +3 -0
- package/cjs/CustomProvider/CustomProvider.d.ts +8 -3
- package/cjs/CustomProvider/CustomProvider.js +6 -0
- package/cjs/DOMHelper/index.d.ts +4 -0
- package/cjs/DOMHelper/index.js +4 -0
- package/cjs/DateInput/DateField.d.ts +180 -0
- package/cjs/DateInput/DateField.js +151 -0
- package/cjs/DateInput/DateInput.d.ts +18 -0
- package/cjs/DateInput/DateInput.js +222 -0
- package/cjs/DateInput/index.d.ts +3 -0
- package/cjs/DateInput/index.js +9 -0
- package/cjs/DateInput/useDateInputState.d.ts +165 -0
- package/cjs/DateInput/useDateInputState.js +105 -0
- package/cjs/DateInput/utils.d.ts +41 -0
- package/cjs/DateInput/utils.js +159 -0
- package/cjs/DatePicker/DatePicker.d.ts +5 -0
- package/cjs/DatePicker/DatePicker.js +5 -0
- package/cjs/DateRangePicker/DateRangePicker.d.ts +5 -0
- package/cjs/DateRangePicker/DateRangePicker.js +5 -0
- package/cjs/Divider/Divider.d.ts +4 -0
- package/cjs/Divider/Divider.js +4 -0
- package/cjs/Drawer/Drawer.d.ts +4 -0
- package/cjs/Drawer/Drawer.js +4 -0
- package/cjs/Dropdown/Dropdown.d.ts +6 -3
- package/cjs/Dropdown/Dropdown.js +6 -3
- package/cjs/Dropdown/DropdownItem.d.ts +3 -3
- package/cjs/Dropdown/DropdownItem.js +3 -3
- package/cjs/Dropdown/DropdownMenu.d.ts +3 -3
- package/cjs/Dropdown/DropdownMenu.js +3 -3
- package/cjs/Dropdown/DropdownSeparator.d.ts +1 -1
- package/cjs/Dropdown/DropdownSeparator.js +1 -1
- package/cjs/FlexboxGrid/FlexboxGrid.d.ts +4 -0
- package/cjs/FlexboxGrid/FlexboxGrid.js +4 -0
- package/cjs/FlexboxGrid/FlexboxGridItem.d.ts +4 -0
- package/cjs/FlexboxGrid/FlexboxGridItem.js +4 -0
- package/cjs/Footer/Footer.d.ts +4 -0
- package/cjs/Footer/Footer.js +4 -0
- package/cjs/Form/Form.d.ts +4 -0
- package/cjs/Form/Form.js +4 -0
- package/cjs/FormControl/FormControl.d.ts +4 -0
- package/cjs/FormControl/FormControl.js +4 -0
- package/cjs/FormControlLabel/FormControlLabel.d.ts +4 -0
- package/cjs/FormControlLabel/FormControlLabel.js +4 -0
- package/cjs/FormErrorMessage/FormErrorMessage.d.ts +4 -0
- package/cjs/FormErrorMessage/FormErrorMessage.js +4 -0
- package/cjs/FormGroup/FormGroup.d.ts +4 -0
- package/cjs/FormGroup/FormGroup.js +5 -0
- package/cjs/FormHelpText/FormHelpText.d.ts +4 -0
- package/cjs/FormHelpText/FormHelpText.js +4 -0
- package/cjs/Grid/Grid.d.ts +4 -0
- package/cjs/Grid/Grid.js +4 -0
- package/cjs/Header/Header.d.ts +4 -0
- package/cjs/Header/Header.js +4 -0
- package/cjs/IconButton/IconButton.d.ts +4 -0
- package/cjs/IconButton/IconButton.js +4 -0
- package/cjs/Input/Input.d.ts +4 -0
- package/cjs/Input/Input.js +4 -0
- package/cjs/InputGroup/InputGroup.d.ts +4 -0
- package/cjs/InputGroup/InputGroup.js +4 -0
- package/cjs/InputGroup/InputGroupAddon.d.ts +4 -0
- package/cjs/InputGroup/InputGroupAddon.js +4 -0
- package/cjs/InputGroup/InputGroupButton.d.ts +4 -0
- package/cjs/InputGroup/InputGroupButton.js +4 -0
- package/cjs/InputNumber/InputNumber.d.ts +4 -0
- package/cjs/InputNumber/InputNumber.js +5 -0
- package/cjs/InputPicker/InputPicker.d.ts +8 -22
- package/cjs/InputPicker/InputPicker.js +13 -8
- package/cjs/InputPicker/InputPickerContext.d.ts +26 -0
- package/cjs/InputPicker/InputPickerContext.js +13 -0
- package/cjs/List/List.d.ts +4 -0
- package/cjs/List/List.js +4 -0
- package/cjs/List/ListItem.d.ts +4 -0
- package/cjs/List/ListItem.js +4 -0
- package/cjs/Loader/Loader.d.ts +4 -0
- package/cjs/Loader/Loader.js +4 -0
- package/cjs/MaskedInput/TextMask.d.ts +4 -0
- package/cjs/MaskedInput/TextMask.js +5 -0
- package/cjs/MaskedInput/createTextMaskInputElement.js +6 -16
- package/cjs/Message/Message.d.ts +4 -0
- package/cjs/Message/Message.js +4 -0
- package/cjs/Modal/Modal.d.ts +4 -0
- package/cjs/Modal/Modal.js +4 -0
- package/cjs/MultiCascader/MultiCascader.d.ts +4 -0
- package/cjs/MultiCascader/MultiCascader.js +5 -0
- package/cjs/Nav/Nav.d.ts +4 -0
- package/cjs/Nav/Nav.js +4 -0
- package/cjs/Nav/NavDropdown.d.ts +2 -1
- package/cjs/Nav/NavDropdown.js +2 -1
- package/cjs/Nav/NavItem.d.ts +6 -3
- package/cjs/Nav/NavItem.js +6 -3
- package/cjs/Nav/NavMenu.d.ts +6 -3
- package/cjs/Nav/NavMenu.js +6 -3
- package/cjs/Navbar/Navbar.d.ts +4 -0
- package/cjs/Navbar/Navbar.js +4 -0
- package/cjs/Notification/Notification.d.ts +5 -0
- package/cjs/Notification/Notification.js +5 -0
- package/cjs/Overlay/Overlay.d.ts +4 -0
- package/cjs/Overlay/Overlay.js +5 -0
- package/cjs/Overlay/OverlayTrigger.d.ts +4 -0
- package/cjs/Overlay/OverlayTrigger.js +16 -11
- package/cjs/Overlay/Position.d.ts +4 -0
- package/cjs/Overlay/Position.js +4 -0
- package/cjs/Pagination/Pagination.d.ts +5 -0
- package/cjs/Pagination/Pagination.js +5 -0
- package/cjs/Panel/Panel.d.ts +4 -0
- package/cjs/Panel/Panel.js +4 -0
- package/cjs/PanelGroup/PanelGroup.d.ts +4 -0
- package/cjs/PanelGroup/PanelGroup.js +5 -0
- package/cjs/Picker/DropdownMenu.d.ts +1 -0
- package/cjs/Picker/DropdownMenu.js +7 -3
- package/cjs/Picker/DropdownMenuCheckItem.d.ts +2 -0
- package/cjs/Picker/DropdownMenuCheckItem.js +18 -14
- package/cjs/Picker/PickerToggle.js +3 -1
- package/cjs/Placeholder/Placeholder.d.ts +4 -0
- package/cjs/Placeholder/Placeholder.js +4 -0
- package/cjs/Placeholder/PlaceholderGraph.d.ts +4 -0
- package/cjs/Placeholder/PlaceholderGraph.js +4 -0
- package/cjs/Placeholder/PlaceholderGrid.d.ts +4 -0
- package/cjs/Placeholder/PlaceholderGrid.js +4 -0
- package/cjs/Placeholder/PlaceholderParagraph.d.ts +4 -0
- package/cjs/Placeholder/PlaceholderParagraph.js +4 -0
- package/cjs/Plaintext/Plaintext.d.ts +2 -1
- package/cjs/Plaintext/Plaintext.js +5 -2
- package/cjs/Popover/Popover.d.ts +4 -0
- package/cjs/Popover/Popover.js +4 -0
- package/cjs/Progress/Progress.d.ts +4 -0
- package/cjs/Progress/Progress.js +4 -0
- package/cjs/Progress/ProgressCircle.d.ts +4 -0
- package/cjs/Progress/ProgressCircle.js +4 -0
- package/cjs/Progress/ProgressLine.d.ts +4 -0
- package/cjs/Progress/ProgressLine.js +4 -0
- package/cjs/Radio/Radio.d.ts +4 -0
- package/cjs/Radio/Radio.js +4 -0
- package/cjs/RadioGroup/RadioGroup.d.ts +4 -0
- package/cjs/RadioGroup/RadioGroup.js +5 -0
- package/cjs/RadioTile/RadioTile.d.ts +5 -0
- package/cjs/RadioTile/RadioTile.js +5 -0
- package/cjs/RadioTileGroup/RadioTileGroup.d.ts +5 -0
- package/cjs/RadioTileGroup/RadioTileGroup.js +6 -0
- package/cjs/RangeSlider/RangeSlider.d.ts +4 -0
- package/cjs/RangeSlider/RangeSlider.js +5 -0
- package/cjs/Rate/Rate.d.ts +4 -0
- package/cjs/Rate/Rate.js +4 -0
- package/cjs/Ripple/Ripple.d.ts +4 -0
- package/cjs/Ripple/Ripple.js +5 -0
- package/cjs/Row/Row.d.ts +4 -0
- package/cjs/Row/Row.js +4 -0
- package/cjs/SafeAnchor/SafeAnchor.d.ts +4 -0
- package/cjs/SafeAnchor/SafeAnchor.js +5 -0
- package/cjs/Schema/Schema.d.ts +6 -0
- package/cjs/Schema/Schema.js +6 -0
- package/cjs/SelectPicker/SelectPicker.d.ts +4 -0
- package/cjs/SelectPicker/SelectPicker.js +4 -0
- package/cjs/Sidebar/Sidebar.d.ts +4 -0
- package/cjs/Sidebar/Sidebar.js +4 -0
- package/cjs/Sidenav/Sidenav.d.ts +4 -0
- package/cjs/Sidenav/Sidenav.js +5 -0
- package/cjs/Sidenav/SidenavBody.d.ts +5 -0
- package/cjs/Sidenav/SidenavBody.js +5 -0
- package/cjs/Sidenav/SidenavHeader.d.ts +5 -0
- package/cjs/Sidenav/SidenavHeader.js +5 -0
- package/cjs/Slider/Slider.d.ts +5 -0
- package/cjs/Slider/Slider.js +6 -0
- package/cjs/Stack/Stack.d.ts +6 -0
- package/cjs/Stack/Stack.js +6 -0
- package/cjs/Stack/StackItem.d.ts +5 -0
- package/cjs/Stack/StackItem.js +5 -0
- package/cjs/Steps/StepItem.d.ts +5 -0
- package/cjs/Steps/StepItem.js +5 -0
- package/cjs/Steps/Steps.d.ts +5 -0
- package/cjs/Steps/Steps.js +5 -0
- package/cjs/Table/Table.d.ts +19 -2
- package/cjs/Table/Table.js +20 -1
- package/cjs/Tag/Tag.d.ts +6 -0
- package/cjs/Tag/Tag.js +13 -1
- package/cjs/TagGroup/TagGroup.d.ts +5 -0
- package/cjs/TagGroup/TagGroup.js +5 -0
- package/cjs/TagInput/index.d.ts +8 -15
- package/cjs/TagInput/index.js +8 -2
- package/cjs/TagPicker/index.d.ts +13 -10
- package/cjs/TagPicker/index.js +13 -5
- package/cjs/Timeline/Timeline.d.ts +5 -0
- package/cjs/Timeline/Timeline.js +5 -0
- package/cjs/Timeline/TimelineItem.d.ts +5 -0
- package/cjs/Timeline/TimelineItem.js +5 -0
- package/cjs/Toggle/Toggle.d.ts +5 -0
- package/cjs/Toggle/Toggle.js +5 -0
- package/cjs/Tooltip/Tooltip.d.ts +5 -0
- package/cjs/Tooltip/Tooltip.js +5 -0
- package/cjs/Tree/Tree.d.ts +5 -0
- package/cjs/Tree/Tree.js +5 -0
- package/cjs/TreePicker/TreePicker.d.ts +5 -0
- package/cjs/TreePicker/TreePicker.js +6 -0
- package/cjs/Uploader/UploadFileItem.js +19 -5
- package/cjs/Uploader/Uploader.d.ts +5 -0
- package/cjs/Uploader/Uploader.js +6 -0
- package/cjs/Whisper/Whisper.d.ts +6 -0
- package/cjs/Whisper/Whisper.js +6 -0
- package/cjs/Windowing/AutoSizer.d.ts +5 -0
- package/cjs/Windowing/AutoSizer.js +5 -0
- package/cjs/Windowing/List.d.ts +6 -1
- package/cjs/Windowing/List.js +5 -0
- package/cjs/index.d.ts +3 -0
- package/cjs/index.js +6 -2
- package/cjs/locales/ar_EG.d.ts +3 -0
- package/cjs/locales/ar_EG.js +5 -2
- package/cjs/locales/da_DK.d.ts +3 -0
- package/cjs/locales/da_DK.js +5 -2
- package/cjs/locales/de_DE.d.ts +3 -0
- package/cjs/locales/de_DE.js +5 -2
- package/cjs/locales/default.d.ts +3 -0
- package/cjs/locales/default.js +5 -2
- package/cjs/locales/en_US.d.ts +3 -0
- package/cjs/locales/en_US.js +5 -2
- package/cjs/locales/es_AR.d.ts +3 -0
- package/cjs/locales/es_AR.js +5 -2
- package/cjs/locales/es_ES.d.ts +3 -0
- package/cjs/locales/es_ES.js +5 -2
- package/cjs/locales/fa_IR.d.ts +3 -0
- package/cjs/locales/fa_IR.js +5 -2
- package/cjs/locales/fi_FI.d.ts +3 -0
- package/cjs/locales/fi_FI.js +5 -2
- package/cjs/locales/fr_FR.d.ts +3 -0
- package/cjs/locales/fr_FR.js +5 -2
- package/cjs/locales/hu_HU.d.ts +3 -0
- package/cjs/locales/hu_HU.js +5 -2
- package/cjs/locales/index.d.ts +1 -1
- package/cjs/locales/it_IT.d.ts +3 -0
- package/cjs/locales/it_IT.js +5 -2
- package/cjs/locales/ja_JP.d.ts +3 -0
- package/cjs/locales/ja_JP.js +5 -2
- package/cjs/locales/kk_KZ.d.ts +3 -0
- package/cjs/locales/kk_KZ.js +5 -2
- package/cjs/locales/ko_KR.d.ts +3 -0
- package/cjs/locales/ko_KR.js +5 -2
- package/cjs/locales/ne_NP.d.ts +3 -0
- package/cjs/locales/ne_NP.js +5 -2
- package/cjs/locales/nl_NL.d.ts +3 -0
- package/cjs/locales/nl_NL.js +5 -2
- package/cjs/locales/pt_BR.d.ts +3 -0
- package/cjs/locales/pt_BR.js +5 -2
- package/cjs/locales/ru_RU.d.ts +3 -0
- package/cjs/locales/ru_RU.js +6 -3
- package/cjs/locales/sv_SE.d.ts +3 -0
- package/cjs/locales/sv_SE.js +5 -2
- package/cjs/locales/tr_TR.d.ts +3 -0
- package/cjs/locales/tr_TR.js +5 -2
- package/cjs/locales/zh_CN.d.ts +3 -0
- package/cjs/locales/zh_CN.js +5 -2
- package/cjs/locales/zh_TW.d.ts +3 -0
- package/cjs/locales/zh_TW.js +5 -2
- package/cjs/toaster/toaster.d.ts +9 -7
- package/cjs/toaster/useToaster.d.ts +19 -1
- package/cjs/toaster/useToaster.js +19 -1
- package/cjs/useMediaQuery/index.d.ts +2 -0
- package/cjs/useMediaQuery/index.js +9 -0
- package/cjs/useMediaQuery/useMediaQuery.d.ts +23 -0
- package/cjs/useMediaQuery/useMediaQuery.js +123 -0
- package/cjs/utils/BrowserDetection.d.ts +1 -0
- package/cjs/utils/BrowserDetection.js +5 -1
- package/cjs/utils/dateUtils.d.ts +6 -0
- package/cjs/utils/dateUtils.js +13 -1
- package/cjs/utils/index.d.ts +1 -0
- package/cjs/utils/index.js +4 -1
- package/cjs/utils/safeSetSelection.d.ts +2 -0
- package/cjs/utils/safeSetSelection.js +21 -0
- package/cjs/utils/treeUtils.d.ts +2 -2
- package/dist/rsuite-no-reset-rtl.css +54 -25
- package/dist/rsuite-no-reset-rtl.min.css +1 -1
- package/dist/rsuite-no-reset-rtl.min.css.map +1 -1
- package/dist/rsuite-no-reset.css +54 -25
- package/dist/rsuite-no-reset.min.css +1 -1
- package/dist/rsuite-no-reset.min.css.map +1 -1
- package/dist/rsuite-rtl.css +54 -25
- package/dist/rsuite-rtl.min.css +1 -1
- package/dist/rsuite-rtl.min.css.map +1 -1
- package/dist/rsuite.css +54 -25
- package/dist/rsuite.js +354 -129
- package/dist/rsuite.js.map +1 -1
- package/dist/rsuite.min.css +1 -1
- package/dist/rsuite.min.css.map +1 -1
- package/dist/rsuite.min.js +1 -1
- package/dist/rsuite.min.js.map +1 -1
- package/esm/Affix/Affix.d.ts +6 -0
- package/esm/Affix/Affix.js +7 -0
- package/esm/Animation/Bounce.d.ts +4 -0
- package/esm/Animation/Bounce.js +4 -0
- package/esm/Animation/Collapse.d.ts +4 -0
- package/esm/Animation/Collapse.js +5 -0
- package/esm/Animation/Fade.d.ts +4 -0
- package/esm/Animation/Fade.js +4 -0
- package/esm/Animation/Slide.d.ts +4 -0
- package/esm/Animation/Slide.js +4 -0
- package/esm/Animation/Transition.d.ts +4 -0
- package/esm/Animation/Transition.js +4 -0
- package/esm/AutoComplete/AutoComplete.d.ts +3 -0
- package/esm/AutoComplete/AutoComplete.js +3 -0
- package/esm/Avatar/Avatar.d.ts +4 -0
- package/esm/Avatar/Avatar.js +4 -0
- package/esm/AvatarGroup/AvatarGroup.d.ts +4 -0
- package/esm/AvatarGroup/AvatarGroup.js +5 -0
- package/esm/Badge/Badge.d.ts +4 -0
- package/esm/Badge/Badge.js +4 -0
- package/esm/Breadcrumb/Breadcrumb.d.ts +4 -0
- package/esm/Breadcrumb/Breadcrumb.js +4 -0
- package/esm/Breadcrumb/BreadcrumbItem.d.ts +4 -0
- package/esm/Breadcrumb/BreadcrumbItem.js +4 -0
- package/esm/Button/Button.d.ts +4 -0
- package/esm/Button/Button.js +4 -0
- package/esm/ButtonGroup/ButtonGroup.d.ts +4 -0
- package/esm/ButtonGroup/ButtonGroup.js +4 -0
- package/esm/ButtonToolbar/ButtonToolbar.d.ts +4 -0
- package/esm/ButtonToolbar/ButtonToolbar.js +4 -0
- package/esm/Calendar/Calendar.d.ts +4 -0
- package/esm/Calendar/Calendar.js +4 -0
- package/esm/Carousel/Carousel.d.ts +4 -0
- package/esm/Carousel/Carousel.js +4 -0
- package/esm/Cascader/Cascader.d.ts +4 -0
- package/esm/Cascader/Cascader.js +5 -0
- package/esm/CheckPicker/CheckPicker.d.ts +4 -0
- package/esm/CheckPicker/CheckPicker.js +4 -0
- package/esm/CheckTree/index.d.ts +4 -0
- package/esm/CheckTree/index.js +4 -0
- package/esm/CheckTreePicker/CheckTreePicker.d.ts +5 -0
- package/esm/CheckTreePicker/CheckTreePicker.js +6 -0
- package/esm/Checkbox/Checkbox.d.ts +6 -0
- package/esm/Checkbox/Checkbox.js +4 -0
- package/esm/CheckboxGroup/CheckboxGroup.d.ts +4 -0
- package/esm/CheckboxGroup/CheckboxGroup.js +4 -0
- package/esm/CloseButton/CloseButton.js +3 -5
- package/esm/Col/Col.d.ts +4 -0
- package/esm/Col/Col.js +4 -0
- package/esm/Container/Container.d.ts +4 -0
- package/esm/Container/Container.js +4 -0
- package/esm/Content/Content.d.ts +3 -0
- package/esm/Content/Content.js +3 -0
- package/esm/CustomProvider/CustomProvider.d.ts +8 -3
- package/esm/CustomProvider/CustomProvider.js +6 -0
- package/esm/DOMHelper/index.d.ts +4 -0
- package/esm/DOMHelper/index.js +5 -0
- package/esm/DateInput/DateField.d.ts +180 -0
- package/esm/DateInput/DateField.js +144 -0
- package/esm/DateInput/DateInput.d.ts +18 -0
- package/esm/DateInput/DateInput.js +215 -0
- package/esm/DateInput/index.d.ts +3 -0
- package/esm/DateInput/index.js +3 -0
- package/esm/DateInput/useDateInputState.d.ts +165 -0
- package/esm/DateInput/useDateInputState.js +99 -0
- package/esm/DateInput/utils.d.ts +41 -0
- package/esm/DateInput/utils.js +151 -0
- package/esm/DatePicker/DatePicker.d.ts +5 -0
- package/esm/DatePicker/DatePicker.js +5 -0
- package/esm/DateRangePicker/DateRangePicker.d.ts +5 -0
- package/esm/DateRangePicker/DateRangePicker.js +5 -0
- package/esm/Divider/Divider.d.ts +4 -0
- package/esm/Divider/Divider.js +4 -0
- package/esm/Drawer/Drawer.d.ts +4 -0
- package/esm/Drawer/Drawer.js +4 -0
- package/esm/Dropdown/Dropdown.d.ts +6 -3
- package/esm/Dropdown/Dropdown.js +6 -3
- package/esm/Dropdown/DropdownItem.d.ts +3 -3
- package/esm/Dropdown/DropdownItem.js +3 -3
- package/esm/Dropdown/DropdownMenu.d.ts +3 -3
- package/esm/Dropdown/DropdownMenu.js +3 -3
- package/esm/Dropdown/DropdownSeparator.d.ts +1 -1
- package/esm/Dropdown/DropdownSeparator.js +1 -1
- package/esm/FlexboxGrid/FlexboxGrid.d.ts +4 -0
- package/esm/FlexboxGrid/FlexboxGrid.js +4 -0
- package/esm/FlexboxGrid/FlexboxGridItem.d.ts +4 -0
- package/esm/FlexboxGrid/FlexboxGridItem.js +4 -0
- package/esm/Footer/Footer.d.ts +4 -0
- package/esm/Footer/Footer.js +4 -0
- package/esm/Form/Form.d.ts +4 -0
- package/esm/Form/Form.js +4 -0
- package/esm/FormControl/FormControl.d.ts +4 -0
- package/esm/FormControl/FormControl.js +4 -0
- package/esm/FormControlLabel/FormControlLabel.d.ts +4 -0
- package/esm/FormControlLabel/FormControlLabel.js +4 -0
- package/esm/FormErrorMessage/FormErrorMessage.d.ts +4 -0
- package/esm/FormErrorMessage/FormErrorMessage.js +4 -0
- package/esm/FormGroup/FormGroup.d.ts +4 -0
- package/esm/FormGroup/FormGroup.js +5 -0
- package/esm/FormHelpText/FormHelpText.d.ts +4 -0
- package/esm/FormHelpText/FormHelpText.js +4 -0
- package/esm/Grid/Grid.d.ts +4 -0
- package/esm/Grid/Grid.js +4 -0
- package/esm/Header/Header.d.ts +4 -0
- package/esm/Header/Header.js +4 -0
- package/esm/IconButton/IconButton.d.ts +4 -0
- package/esm/IconButton/IconButton.js +4 -0
- package/esm/Input/Input.d.ts +4 -0
- package/esm/Input/Input.js +4 -0
- package/esm/InputGroup/InputGroup.d.ts +4 -0
- package/esm/InputGroup/InputGroup.js +4 -0
- package/esm/InputGroup/InputGroupAddon.d.ts +4 -0
- package/esm/InputGroup/InputGroupAddon.js +4 -0
- package/esm/InputGroup/InputGroupButton.d.ts +4 -0
- package/esm/InputGroup/InputGroupButton.js +5 -0
- package/esm/InputNumber/InputNumber.d.ts +4 -0
- package/esm/InputNumber/InputNumber.js +5 -0
- package/esm/InputPicker/InputPicker.d.ts +8 -22
- package/esm/InputPicker/InputPicker.js +11 -5
- package/esm/InputPicker/InputPickerContext.d.ts +26 -0
- package/esm/InputPicker/InputPickerContext.js +7 -0
- package/esm/List/List.d.ts +4 -0
- package/esm/List/List.js +4 -0
- package/esm/List/ListItem.d.ts +4 -0
- package/esm/List/ListItem.js +4 -0
- package/esm/Loader/Loader.d.ts +4 -0
- package/esm/Loader/Loader.js +4 -0
- package/esm/MaskedInput/TextMask.d.ts +4 -0
- package/esm/MaskedInput/TextMask.js +5 -0
- package/esm/MaskedInput/createTextMaskInputElement.js +6 -16
- package/esm/Message/Message.d.ts +4 -0
- package/esm/Message/Message.js +4 -0
- package/esm/Modal/Modal.d.ts +4 -0
- package/esm/Modal/Modal.js +4 -0
- package/esm/MultiCascader/MultiCascader.d.ts +4 -0
- package/esm/MultiCascader/MultiCascader.js +5 -0
- package/esm/Nav/Nav.d.ts +4 -0
- package/esm/Nav/Nav.js +4 -0
- package/esm/Nav/NavDropdown.d.ts +2 -1
- package/esm/Nav/NavDropdown.js +2 -1
- package/esm/Nav/NavItem.d.ts +6 -3
- package/esm/Nav/NavItem.js +6 -3
- package/esm/Nav/NavMenu.d.ts +6 -3
- package/esm/Nav/NavMenu.js +6 -3
- package/esm/Navbar/Navbar.d.ts +4 -0
- package/esm/Navbar/Navbar.js +4 -0
- package/esm/Notification/Notification.d.ts +5 -0
- package/esm/Notification/Notification.js +5 -0
- package/esm/Overlay/Overlay.d.ts +4 -0
- package/esm/Overlay/Overlay.js +5 -0
- package/esm/Overlay/OverlayTrigger.d.ts +4 -0
- package/esm/Overlay/OverlayTrigger.js +16 -11
- package/esm/Overlay/Position.d.ts +4 -0
- package/esm/Overlay/Position.js +4 -0
- package/esm/Pagination/Pagination.d.ts +5 -0
- package/esm/Pagination/Pagination.js +5 -0
- package/esm/Panel/Panel.d.ts +4 -0
- package/esm/Panel/Panel.js +4 -0
- package/esm/PanelGroup/PanelGroup.d.ts +4 -0
- package/esm/PanelGroup/PanelGroup.js +5 -0
- package/esm/Picker/DropdownMenu.d.ts +1 -0
- package/esm/Picker/DropdownMenu.js +7 -3
- package/esm/Picker/DropdownMenuCheckItem.d.ts +2 -0
- package/esm/Picker/DropdownMenuCheckItem.js +18 -14
- package/esm/Picker/PickerToggle.js +4 -2
- package/esm/Placeholder/Placeholder.d.ts +4 -0
- package/esm/Placeholder/Placeholder.js +4 -0
- package/esm/Placeholder/PlaceholderGraph.d.ts +4 -0
- package/esm/Placeholder/PlaceholderGraph.js +4 -0
- package/esm/Placeholder/PlaceholderGrid.d.ts +4 -0
- package/esm/Placeholder/PlaceholderGrid.js +4 -0
- package/esm/Placeholder/PlaceholderParagraph.d.ts +4 -0
- package/esm/Placeholder/PlaceholderParagraph.js +4 -0
- package/esm/Plaintext/Plaintext.d.ts +2 -1
- package/esm/Plaintext/Plaintext.js +5 -2
- package/esm/Popover/Popover.d.ts +4 -0
- package/esm/Popover/Popover.js +4 -0
- package/esm/Progress/Progress.d.ts +4 -0
- package/esm/Progress/Progress.js +4 -0
- package/esm/Progress/ProgressCircle.d.ts +4 -0
- package/esm/Progress/ProgressCircle.js +4 -0
- package/esm/Progress/ProgressLine.d.ts +4 -0
- package/esm/Progress/ProgressLine.js +4 -0
- package/esm/Radio/Radio.d.ts +4 -0
- package/esm/Radio/Radio.js +4 -0
- package/esm/RadioGroup/RadioGroup.d.ts +4 -0
- package/esm/RadioGroup/RadioGroup.js +5 -0
- package/esm/RadioTile/RadioTile.d.ts +5 -0
- package/esm/RadioTile/RadioTile.js +5 -0
- package/esm/RadioTileGroup/RadioTileGroup.d.ts +5 -0
- package/esm/RadioTileGroup/RadioTileGroup.js +6 -0
- package/esm/RangeSlider/RangeSlider.d.ts +4 -0
- package/esm/RangeSlider/RangeSlider.js +5 -0
- package/esm/Rate/Rate.d.ts +4 -0
- package/esm/Rate/Rate.js +4 -0
- package/esm/Ripple/Ripple.d.ts +4 -0
- package/esm/Ripple/Ripple.js +5 -0
- package/esm/Row/Row.d.ts +4 -0
- package/esm/Row/Row.js +4 -0
- package/esm/SafeAnchor/SafeAnchor.d.ts +4 -0
- package/esm/SafeAnchor/SafeAnchor.js +5 -0
- package/esm/Schema/Schema.d.ts +6 -0
- package/esm/Schema/Schema.js +7 -0
- package/esm/SelectPicker/SelectPicker.d.ts +4 -0
- package/esm/SelectPicker/SelectPicker.js +4 -0
- package/esm/Sidebar/Sidebar.d.ts +4 -0
- package/esm/Sidebar/Sidebar.js +4 -0
- package/esm/Sidenav/Sidenav.d.ts +4 -0
- package/esm/Sidenav/Sidenav.js +5 -0
- package/esm/Sidenav/SidenavBody.d.ts +5 -0
- package/esm/Sidenav/SidenavBody.js +5 -0
- package/esm/Sidenav/SidenavHeader.d.ts +5 -0
- package/esm/Sidenav/SidenavHeader.js +5 -0
- package/esm/Slider/Slider.d.ts +5 -0
- package/esm/Slider/Slider.js +6 -0
- package/esm/Stack/Stack.d.ts +6 -0
- package/esm/Stack/Stack.js +6 -0
- package/esm/Stack/StackItem.d.ts +5 -0
- package/esm/Stack/StackItem.js +5 -0
- package/esm/Steps/StepItem.d.ts +5 -0
- package/esm/Steps/StepItem.js +5 -0
- package/esm/Steps/Steps.d.ts +5 -0
- package/esm/Steps/Steps.js +5 -0
- package/esm/Table/Table.d.ts +19 -2
- package/esm/Table/Table.js +23 -4
- package/esm/Tag/Tag.d.ts +6 -0
- package/esm/Tag/Tag.js +14 -2
- package/esm/TagGroup/TagGroup.d.ts +5 -0
- package/esm/TagGroup/TagGroup.js +5 -0
- package/esm/TagInput/index.d.ts +8 -15
- package/esm/TagInput/index.js +7 -1
- package/esm/TagPicker/index.d.ts +13 -10
- package/esm/TagPicker/index.js +12 -4
- package/esm/Timeline/Timeline.d.ts +5 -0
- package/esm/Timeline/Timeline.js +5 -0
- package/esm/Timeline/TimelineItem.d.ts +5 -0
- package/esm/Timeline/TimelineItem.js +5 -0
- package/esm/Toggle/Toggle.d.ts +5 -0
- package/esm/Toggle/Toggle.js +5 -0
- package/esm/Tooltip/Tooltip.d.ts +5 -0
- package/esm/Tooltip/Tooltip.js +5 -0
- package/esm/Tree/Tree.d.ts +5 -0
- package/esm/Tree/Tree.js +5 -0
- package/esm/TreePicker/TreePicker.d.ts +5 -0
- package/esm/TreePicker/TreePicker.js +6 -0
- package/esm/Uploader/UploadFileItem.js +19 -5
- package/esm/Uploader/Uploader.d.ts +5 -0
- package/esm/Uploader/Uploader.js +6 -0
- package/esm/Whisper/Whisper.d.ts +6 -0
- package/esm/Whisper/Whisper.js +6 -0
- package/esm/Windowing/AutoSizer.d.ts +5 -0
- package/esm/Windowing/AutoSizer.js +5 -0
- package/esm/Windowing/List.d.ts +6 -1
- package/esm/Windowing/List.js +5 -0
- package/esm/index.d.ts +3 -0
- package/esm/index.js +3 -1
- package/esm/locales/ar_EG.d.ts +3 -0
- package/esm/locales/ar_EG.js +5 -2
- package/esm/locales/da_DK.d.ts +3 -0
- package/esm/locales/da_DK.js +5 -2
- package/esm/locales/de_DE.d.ts +3 -0
- package/esm/locales/de_DE.js +5 -2
- package/esm/locales/default.d.ts +3 -0
- package/esm/locales/default.js +5 -2
- package/esm/locales/en_US.d.ts +3 -0
- package/esm/locales/en_US.js +5 -2
- package/esm/locales/es_AR.d.ts +3 -0
- package/esm/locales/es_AR.js +5 -2
- package/esm/locales/es_ES.d.ts +3 -0
- package/esm/locales/es_ES.js +5 -2
- package/esm/locales/fa_IR.d.ts +3 -0
- package/esm/locales/fa_IR.js +5 -2
- package/esm/locales/fi_FI.d.ts +3 -0
- package/esm/locales/fi_FI.js +5 -2
- package/esm/locales/fr_FR.d.ts +3 -0
- package/esm/locales/fr_FR.js +5 -2
- package/esm/locales/hu_HU.d.ts +3 -0
- package/esm/locales/hu_HU.js +5 -2
- package/esm/locales/index.d.ts +1 -1
- package/esm/locales/it_IT.d.ts +3 -0
- package/esm/locales/it_IT.js +5 -2
- package/esm/locales/ja_JP.d.ts +3 -0
- package/esm/locales/ja_JP.js +5 -2
- package/esm/locales/kk_KZ.d.ts +3 -0
- package/esm/locales/kk_KZ.js +5 -2
- package/esm/locales/ko_KR.d.ts +3 -0
- package/esm/locales/ko_KR.js +5 -2
- package/esm/locales/ne_NP.d.ts +3 -0
- package/esm/locales/ne_NP.js +5 -2
- package/esm/locales/nl_NL.d.ts +3 -0
- package/esm/locales/nl_NL.js +5 -2
- package/esm/locales/pt_BR.d.ts +3 -0
- package/esm/locales/pt_BR.js +5 -2
- package/esm/locales/ru_RU.d.ts +3 -0
- package/esm/locales/ru_RU.js +6 -3
- package/esm/locales/sv_SE.d.ts +3 -0
- package/esm/locales/sv_SE.js +5 -2
- package/esm/locales/tr_TR.d.ts +3 -0
- package/esm/locales/tr_TR.js +5 -2
- package/esm/locales/zh_CN.d.ts +3 -0
- package/esm/locales/zh_CN.js +5 -2
- package/esm/locales/zh_TW.d.ts +3 -0
- package/esm/locales/zh_TW.js +5 -2
- package/esm/toaster/toaster.d.ts +9 -7
- package/esm/toaster/useToaster.d.ts +19 -1
- package/esm/toaster/useToaster.js +19 -1
- package/esm/useMediaQuery/index.d.ts +2 -0
- package/esm/useMediaQuery/index.js +3 -0
- package/esm/useMediaQuery/useMediaQuery.d.ts +23 -0
- package/esm/useMediaQuery/useMediaQuery.js +113 -0
- package/esm/utils/BrowserDetection.d.ts +1 -0
- package/esm/utils/BrowserDetection.js +3 -0
- package/esm/utils/dateUtils.d.ts +6 -0
- package/esm/utils/dateUtils.js +6 -0
- package/esm/utils/index.d.ts +1 -0
- package/esm/utils/index.js +1 -0
- package/esm/utils/safeSetSelection.d.ts +2 -0
- package/esm/utils/safeSetSelection.js +16 -0
- package/esm/utils/treeUtils.d.ts +2 -2
- package/package.json +1 -1
- package/styles/color-modes/dark.less +3 -1
- package/styles/color-modes/high-contrast.less +3 -1
- package/styles/color-modes/light.less +3 -1
- package/useMediaQuery/package.json +7 -0
|
@@ -27,6 +27,12 @@ var emptyArray = [];
|
|
|
27
27
|
var itemSize = function itemSize() {
|
|
28
28
|
return 36;
|
|
29
29
|
};
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* The `CheckTreePicker` component is used for selecting multiple options which are organized in a tree structure.
|
|
33
|
+
*
|
|
34
|
+
* @see https://rsuitejs.com/components/check-tree-picker
|
|
35
|
+
*/
|
|
30
36
|
var CheckTreePicker = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
31
37
|
var _props$as = props.as,
|
|
32
38
|
Component = _props$as === void 0 ? 'div' : _props$as,
|
|
@@ -36,6 +36,12 @@ export interface CheckboxProps<V = ValueType> extends WithAsProps {
|
|
|
36
36
|
onClick?: (event: React.SyntheticEvent) => void;
|
|
37
37
|
/** Called when the checkbox is clicked. */
|
|
38
38
|
onCheckboxClick?: (event: React.SyntheticEvent) => void;
|
|
39
|
+
/** Called when the user presses down a key. */
|
|
40
|
+
onKeyDown?: (event: React.KeyboardEvent) => void;
|
|
39
41
|
}
|
|
42
|
+
/**
|
|
43
|
+
* The Checkbox component is used for selecting multiple options from a set.
|
|
44
|
+
* @see https://rsuitejs.com/components/checkbox
|
|
45
|
+
*/
|
|
40
46
|
declare const Checkbox: RsRefForwardingComponent<'div', CheckboxProps>;
|
|
41
47
|
export default Checkbox;
|
package/cjs/Checkbox/Checkbox.js
CHANGED
|
@@ -13,6 +13,10 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
|
13
13
|
var _utils = require("../utils");
|
|
14
14
|
var _CheckboxGroup = require("../CheckboxGroup");
|
|
15
15
|
var _templateObject, _templateObject2, _templateObject3;
|
|
16
|
+
/**
|
|
17
|
+
* The Checkbox component is used for selecting multiple options from a set.
|
|
18
|
+
* @see https://rsuitejs.com/components/checkbox
|
|
19
|
+
*/
|
|
16
20
|
var Checkbox = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
17
21
|
var checkboxGroupContext = (0, _react.useContext)(_CheckboxGroup.CheckboxGroupContext);
|
|
18
22
|
var _ref = checkboxGroupContext !== null && checkboxGroupContext !== void 0 ? checkboxGroupContext : {},
|
|
@@ -9,5 +9,9 @@ export interface CheckboxGroupProps<V = ValueType[]> extends WithAsProps, FormCo
|
|
|
9
9
|
/** Inline layout */
|
|
10
10
|
inline?: boolean;
|
|
11
11
|
}
|
|
12
|
+
/**
|
|
13
|
+
* The `CheckboxGroup` component is used for selecting multiple options which are unrelated.
|
|
14
|
+
* @see https://rsuitejs.com/components/checkbox/#checkbox-group
|
|
15
|
+
*/
|
|
12
16
|
declare const CheckboxGroup: RsRefForwardingComponent<'div', CheckboxGroupProps>;
|
|
13
17
|
export default CheckboxGroup;
|
|
@@ -14,6 +14,10 @@ var _remove = _interopRequireDefault(require("lodash/remove"));
|
|
|
14
14
|
var _utils = require("../utils");
|
|
15
15
|
var _Plaintext = _interopRequireDefault(require("../Plaintext"));
|
|
16
16
|
var _CheckboxGroupContext = require("./CheckboxGroupContext");
|
|
17
|
+
/**
|
|
18
|
+
* The `CheckboxGroup` component is used for selecting multiple options which are unrelated.
|
|
19
|
+
* @see https://rsuitejs.com/components/checkbox/#checkbox-group
|
|
20
|
+
*/
|
|
17
21
|
var CheckboxGroup = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
18
22
|
var _props$as = props.as,
|
|
19
23
|
Component = _props$as === void 0 ? 'div' : _props$as,
|
|
@@ -14,7 +14,7 @@ var _utils = require("../utils");
|
|
|
14
14
|
*/
|
|
15
15
|
var CloseButton = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
16
16
|
var _props$as = props.as,
|
|
17
|
-
Component = _props$as === void 0 ? '
|
|
17
|
+
Component = _props$as === void 0 ? 'button' : _props$as,
|
|
18
18
|
_props$classPrefix = props.classPrefix,
|
|
19
19
|
classPrefix = _props$classPrefix === void 0 ? 'btn-close' : _props$classPrefix,
|
|
20
20
|
className = props.className,
|
|
@@ -27,13 +27,11 @@ var CloseButton = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
|
27
27
|
locale = _useCustom.locale;
|
|
28
28
|
var classes = merge(className, withClassPrefix());
|
|
29
29
|
return /*#__PURE__*/_react.default.createElement(Component, (0, _extends2.default)({
|
|
30
|
-
|
|
31
|
-
}, rest, {
|
|
30
|
+
type: "button",
|
|
32
31
|
ref: ref,
|
|
33
32
|
className: classes,
|
|
34
|
-
title: locale === null || locale === void 0 ? void 0 : locale.closeLabel,
|
|
35
33
|
"aria-label": locale === null || locale === void 0 ? void 0 : locale.closeLabel
|
|
36
|
-
}), /*#__PURE__*/_react.default.createElement(_Close.default, null));
|
|
34
|
+
}, rest), /*#__PURE__*/_react.default.createElement(_Close.default, null));
|
|
37
35
|
});
|
|
38
36
|
CloseButton.displayName = 'CloseButton';
|
|
39
37
|
var _default = CloseButton;
|
package/cjs/Col/Col.d.ts
CHANGED
|
@@ -61,5 +61,9 @@ export interface ColProps extends WithAsProps {
|
|
|
61
61
|
/** Hide column on Ultra large devices Desktops */
|
|
62
62
|
xxlHidden?: boolean;
|
|
63
63
|
}
|
|
64
|
+
/**
|
|
65
|
+
* The `Col` component is used for layout and grids.
|
|
66
|
+
* @see https://rsuitejs.com/en/components/grid
|
|
67
|
+
*/
|
|
64
68
|
declare const Col: RsRefForwardingComponent<'div', ColProps>;
|
|
65
69
|
export default Col;
|
package/cjs/Col/Col.js
CHANGED
|
@@ -10,6 +10,10 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
10
10
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
11
11
|
var _omit = _interopRequireDefault(require("lodash/omit"));
|
|
12
12
|
var _utils = require("../utils");
|
|
13
|
+
/**
|
|
14
|
+
* The `Col` component is used for layout and grids.
|
|
15
|
+
* @see https://rsuitejs.com/en/components/grid
|
|
16
|
+
*/
|
|
13
17
|
var Col = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
14
18
|
var _props$as = props.as,
|
|
15
19
|
Component = _props$as === void 0 ? 'div' : _props$as,
|
|
@@ -5,5 +5,9 @@ export declare const ContainerContext: React.Context<ContainerContextValue>;
|
|
|
5
5
|
interface ContainerContextValue {
|
|
6
6
|
setHasSidebar?: (value: boolean) => void;
|
|
7
7
|
}
|
|
8
|
+
/**
|
|
9
|
+
* The Container component is used to wrap content in a themed container with a max-width.
|
|
10
|
+
* @see https://rsuitejs.com/components/container
|
|
11
|
+
*/
|
|
8
12
|
declare const Container: React.ForwardRefExoticComponent<WithAsProps<React.ElementType<any>> & React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
9
13
|
export default Container;
|
|
@@ -12,6 +12,10 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
|
12
12
|
var _utils = require("../utils");
|
|
13
13
|
var ContainerContext = /*#__PURE__*/_react.default.createContext({});
|
|
14
14
|
exports.ContainerContext = ContainerContext;
|
|
15
|
+
/**
|
|
16
|
+
* The Container component is used to wrap content in a themed container with a max-width.
|
|
17
|
+
* @see https://rsuitejs.com/components/container
|
|
18
|
+
*/
|
|
15
19
|
var Container = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
16
20
|
var _props$as = props.as,
|
|
17
21
|
Component = _props$as === void 0 ? 'section' : _props$as,
|
package/cjs/Content/Content.d.ts
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import { ComponentProps } from '../utils/createComponent';
|
|
2
2
|
export declare type ContentProps = ComponentProps;
|
|
3
3
|
/**
|
|
4
|
+
* The Content component is used to wrap content in a themed container with a max-width.
|
|
5
|
+
* @see https://rsuitejs.com/components/container/
|
|
6
|
+
*
|
|
4
7
|
* For Internet Explorer 11 and lower, it's suggested that an ARIA role of "main"
|
|
5
8
|
* be added to the <main> element to ensure it is accessible
|
|
6
9
|
*/
|
package/cjs/Content/Content.js
CHANGED
|
@@ -6,6 +6,9 @@ exports.__esModule = true;
|
|
|
6
6
|
exports.default = void 0;
|
|
7
7
|
var _createComponent = _interopRequireDefault(require("../utils/createComponent"));
|
|
8
8
|
/**
|
|
9
|
+
* The Content component is used to wrap content in a themed container with a max-width.
|
|
10
|
+
* @see https://rsuitejs.com/components/container/
|
|
11
|
+
*
|
|
9
12
|
* For Internet Explorer 11 and lower, it's suggested that an ARIA role of "main"
|
|
10
13
|
* be added to the <main> element to ensure it is accessible
|
|
11
14
|
*/
|
|
@@ -55,6 +55,8 @@ declare const CustomContext: React.Context<CustomProviderProps<{
|
|
|
55
55
|
common?: {
|
|
56
56
|
loading: string;
|
|
57
57
|
emptyMessage: string;
|
|
58
|
+
remove: string;
|
|
59
|
+
clear: string;
|
|
58
60
|
} | undefined;
|
|
59
61
|
Plaintext?: {
|
|
60
62
|
unfilled: string;
|
|
@@ -134,9 +136,6 @@ declare const CustomContext: React.Context<CustomProviderProps<{
|
|
|
134
136
|
} | undefined;
|
|
135
137
|
InputPicker?: {
|
|
136
138
|
newItem: string;
|
|
137
|
-
/**
|
|
138
|
-
* A Map of toast containers
|
|
139
|
-
*/
|
|
140
139
|
createOption: string;
|
|
141
140
|
} | undefined;
|
|
142
141
|
Uploader?: {
|
|
@@ -146,6 +145,7 @@ declare const CustomContext: React.Context<CustomProviderProps<{
|
|
|
146
145
|
complete: string;
|
|
147
146
|
emptyFile: string;
|
|
148
147
|
upload: string;
|
|
148
|
+
removeFile: string;
|
|
149
149
|
} | undefined;
|
|
150
150
|
CloseButton?: {
|
|
151
151
|
closeLabel: string;
|
|
@@ -158,6 +158,11 @@ declare const CustomContext: React.Context<CustomProviderProps<{
|
|
|
158
158
|
off: string;
|
|
159
159
|
} | undefined;
|
|
160
160
|
}>>;
|
|
161
|
+
/**
|
|
162
|
+
* CustomProvider is used to provide global configuration, such as language, theme, etc.
|
|
163
|
+
*
|
|
164
|
+
* @see https://rsuitejs.com/components/custom-provider
|
|
165
|
+
*/
|
|
161
166
|
declare const CustomProvider: (props: Omit<CustomProviderProps, 'toasters'>) => JSX.Element;
|
|
162
167
|
export { CustomContext };
|
|
163
168
|
export default CustomProvider;
|
|
@@ -15,6 +15,12 @@ var _utils = require("../utils");
|
|
|
15
15
|
var CustomContext = /*#__PURE__*/_react.default.createContext({});
|
|
16
16
|
exports.CustomContext = CustomContext;
|
|
17
17
|
var themes = ['light', 'dark', 'high-contrast'];
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* CustomProvider is used to provide global configuration, such as language, theme, etc.
|
|
21
|
+
*
|
|
22
|
+
* @see https://rsuitejs.com/components/custom-provider
|
|
23
|
+
*/
|
|
18
24
|
var CustomProvider = function CustomProvider(props) {
|
|
19
25
|
var children = props.children,
|
|
20
26
|
_props$classPrefix = props.classPrefix,
|
package/cjs/DOMHelper/index.d.ts
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import * as helpers from 'dom-lib';
|
|
3
3
|
export * from 'dom-lib';
|
|
4
|
+
/**
|
|
5
|
+
* a wrapper of dom-lib with some custom methods.
|
|
6
|
+
* @see https://rsuitejs.com/components/dom-helper/
|
|
7
|
+
*/
|
|
4
8
|
declare const DOMHelper: {
|
|
5
9
|
isElement: (value: any) => value is HTMLElement;
|
|
6
10
|
on: typeof helpers.on;
|
package/cjs/DOMHelper/index.js
CHANGED
|
@@ -15,6 +15,10 @@ Object.keys(helpers).forEach(function (key) {
|
|
|
15
15
|
exports[key] = helpers[key];
|
|
16
16
|
});
|
|
17
17
|
var _isElement = _interopRequireDefault(require("./isElement"));
|
|
18
|
+
/**
|
|
19
|
+
* a wrapper of dom-lib with some custom methods.
|
|
20
|
+
* @see https://rsuitejs.com/components/dom-helper/
|
|
21
|
+
*/
|
|
18
22
|
var DOMHelper = (0, _extends2.default)({}, helpers, {
|
|
19
23
|
isElement: _isElement.default
|
|
20
24
|
});
|
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { type Locale } from 'date-fns';
|
|
3
|
+
export declare const patternMap: {
|
|
4
|
+
y: string;
|
|
5
|
+
M: string;
|
|
6
|
+
d: string;
|
|
7
|
+
H: string;
|
|
8
|
+
h: string;
|
|
9
|
+
m: string;
|
|
10
|
+
s: string;
|
|
11
|
+
a: string;
|
|
12
|
+
};
|
|
13
|
+
export declare class DateField extends Object {
|
|
14
|
+
format: string;
|
|
15
|
+
patternArray: {
|
|
16
|
+
pattern: string;
|
|
17
|
+
key: string;
|
|
18
|
+
}[];
|
|
19
|
+
year: number | null;
|
|
20
|
+
month: number | null;
|
|
21
|
+
day: number | null;
|
|
22
|
+
hour: number | null;
|
|
23
|
+
minute: number | null;
|
|
24
|
+
second: number | null;
|
|
25
|
+
meridian: 'AM' | 'PM' | null;
|
|
26
|
+
constructor(format: string, value?: Date | null);
|
|
27
|
+
}
|
|
28
|
+
export declare const useDateField: (format: string, localize: Locale['localize'], date?: Date | null) => {
|
|
29
|
+
dateField: {
|
|
30
|
+
year: any;
|
|
31
|
+
format: string;
|
|
32
|
+
patternArray: {
|
|
33
|
+
pattern: string;
|
|
34
|
+
key: string;
|
|
35
|
+
}[];
|
|
36
|
+
month: number | null;
|
|
37
|
+
day: number | null;
|
|
38
|
+
hour: number | null;
|
|
39
|
+
minute: number | null;
|
|
40
|
+
second: number | null;
|
|
41
|
+
meridian: 'AM' | 'PM' | null;
|
|
42
|
+
constructor: Function;
|
|
43
|
+
toString(): string;
|
|
44
|
+
toLocaleString(): string;
|
|
45
|
+
valueOf(): Object;
|
|
46
|
+
hasOwnProperty(v: PropertyKey): boolean;
|
|
47
|
+
isPrototypeOf(v: Object): boolean;
|
|
48
|
+
propertyIsEnumerable(v: PropertyKey): boolean;
|
|
49
|
+
should: Chai.Assertion;
|
|
50
|
+
} | {
|
|
51
|
+
month: any;
|
|
52
|
+
format: string;
|
|
53
|
+
patternArray: {
|
|
54
|
+
pattern: string;
|
|
55
|
+
key: string;
|
|
56
|
+
}[];
|
|
57
|
+
year: number | null;
|
|
58
|
+
day: number | null;
|
|
59
|
+
hour: number | null;
|
|
60
|
+
minute: number | null;
|
|
61
|
+
second: number | null;
|
|
62
|
+
meridian: 'AM' | 'PM' | null;
|
|
63
|
+
constructor: Function;
|
|
64
|
+
toString(): string;
|
|
65
|
+
toLocaleString(): string;
|
|
66
|
+
valueOf(): Object;
|
|
67
|
+
hasOwnProperty(v: PropertyKey): boolean;
|
|
68
|
+
isPrototypeOf(v: Object): boolean;
|
|
69
|
+
propertyIsEnumerable(v: PropertyKey): boolean;
|
|
70
|
+
should: Chai.Assertion;
|
|
71
|
+
} | {
|
|
72
|
+
day: any;
|
|
73
|
+
format: string;
|
|
74
|
+
patternArray: {
|
|
75
|
+
pattern: string;
|
|
76
|
+
key: string;
|
|
77
|
+
}[];
|
|
78
|
+
year: number | null;
|
|
79
|
+
month: number | null;
|
|
80
|
+
hour: number | null;
|
|
81
|
+
minute: number | null;
|
|
82
|
+
second: number | null;
|
|
83
|
+
meridian: 'AM' | 'PM' | null;
|
|
84
|
+
constructor: Function;
|
|
85
|
+
toString(): string;
|
|
86
|
+
toLocaleString(): string;
|
|
87
|
+
valueOf(): Object;
|
|
88
|
+
hasOwnProperty(v: PropertyKey): boolean;
|
|
89
|
+
isPrototypeOf(v: Object): boolean;
|
|
90
|
+
propertyIsEnumerable(v: PropertyKey): boolean;
|
|
91
|
+
should: Chai.Assertion;
|
|
92
|
+
} | {
|
|
93
|
+
hour: any;
|
|
94
|
+
format: string;
|
|
95
|
+
patternArray: {
|
|
96
|
+
pattern: string;
|
|
97
|
+
key: string;
|
|
98
|
+
}[];
|
|
99
|
+
year: number | null;
|
|
100
|
+
month: number | null;
|
|
101
|
+
day: number | null;
|
|
102
|
+
minute: number | null;
|
|
103
|
+
second: number | null;
|
|
104
|
+
meridian: 'AM' | 'PM' | null;
|
|
105
|
+
constructor: Function;
|
|
106
|
+
toString(): string;
|
|
107
|
+
toLocaleString(): string;
|
|
108
|
+
valueOf(): Object;
|
|
109
|
+
hasOwnProperty(v: PropertyKey): boolean;
|
|
110
|
+
isPrototypeOf(v: Object): boolean;
|
|
111
|
+
propertyIsEnumerable(v: PropertyKey): boolean;
|
|
112
|
+
should: Chai.Assertion;
|
|
113
|
+
} | {
|
|
114
|
+
minute: any;
|
|
115
|
+
format: string;
|
|
116
|
+
patternArray: {
|
|
117
|
+
pattern: string;
|
|
118
|
+
key: string;
|
|
119
|
+
}[];
|
|
120
|
+
year: number | null;
|
|
121
|
+
month: number | null;
|
|
122
|
+
day: number | null;
|
|
123
|
+
hour: number | null;
|
|
124
|
+
second: number | null;
|
|
125
|
+
meridian: 'AM' | 'PM' | null;
|
|
126
|
+
constructor: Function;
|
|
127
|
+
toString(): string;
|
|
128
|
+
toLocaleString(): string;
|
|
129
|
+
valueOf(): Object;
|
|
130
|
+
hasOwnProperty(v: PropertyKey): boolean;
|
|
131
|
+
isPrototypeOf(v: Object): boolean;
|
|
132
|
+
propertyIsEnumerable(v: PropertyKey): boolean;
|
|
133
|
+
should: Chai.Assertion;
|
|
134
|
+
} | {
|
|
135
|
+
second: any;
|
|
136
|
+
format: string;
|
|
137
|
+
patternArray: {
|
|
138
|
+
pattern: string;
|
|
139
|
+
key: string;
|
|
140
|
+
}[];
|
|
141
|
+
year: number | null;
|
|
142
|
+
month: number | null;
|
|
143
|
+
day: number | null;
|
|
144
|
+
hour: number | null;
|
|
145
|
+
minute: number | null;
|
|
146
|
+
meridian: 'AM' | 'PM' | null;
|
|
147
|
+
constructor: Function;
|
|
148
|
+
toString(): string;
|
|
149
|
+
toLocaleString(): string;
|
|
150
|
+
valueOf(): Object;
|
|
151
|
+
hasOwnProperty(v: PropertyKey): boolean;
|
|
152
|
+
isPrototypeOf(v: Object): boolean;
|
|
153
|
+
propertyIsEnumerable(v: PropertyKey): boolean;
|
|
154
|
+
should: Chai.Assertion;
|
|
155
|
+
} | {
|
|
156
|
+
meridian: any;
|
|
157
|
+
format: string;
|
|
158
|
+
patternArray: {
|
|
159
|
+
pattern: string;
|
|
160
|
+
key: string;
|
|
161
|
+
}[];
|
|
162
|
+
year: number | null;
|
|
163
|
+
month: number | null;
|
|
164
|
+
day: number | null;
|
|
165
|
+
hour: number | null;
|
|
166
|
+
minute: number | null;
|
|
167
|
+
second: number | null;
|
|
168
|
+
constructor: Function;
|
|
169
|
+
toString(): string;
|
|
170
|
+
toLocaleString(): string;
|
|
171
|
+
valueOf(): Object;
|
|
172
|
+
hasOwnProperty(v: PropertyKey): boolean;
|
|
173
|
+
isPrototypeOf(v: Object): boolean;
|
|
174
|
+
propertyIsEnumerable(v: PropertyKey): boolean;
|
|
175
|
+
should: Chai.Assertion;
|
|
176
|
+
};
|
|
177
|
+
dispatch: import("react").Dispatch<any>;
|
|
178
|
+
toDate: (type: string, value: number | null) => Date;
|
|
179
|
+
toDateString: () => string;
|
|
180
|
+
};
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
"use strict";
|
|
3
|
+
|
|
4
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
5
|
+
exports.__esModule = true;
|
|
6
|
+
exports.useDateField = exports.DateField = exports.patternMap = void 0;
|
|
7
|
+
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
8
|
+
var _inheritsLoose2 = _interopRequireDefault(require("@babel/runtime/helpers/inheritsLoose"));
|
|
9
|
+
var _wrapNativeSuper2 = _interopRequireDefault(require("@babel/runtime/helpers/wrapNativeSuper"));
|
|
10
|
+
var _react = require("react");
|
|
11
|
+
var _utils = require("./utils");
|
|
12
|
+
var patternMap = {
|
|
13
|
+
y: 'year',
|
|
14
|
+
M: 'month',
|
|
15
|
+
d: 'day',
|
|
16
|
+
H: 'hour',
|
|
17
|
+
h: 'hour',
|
|
18
|
+
m: 'minute',
|
|
19
|
+
s: 'second',
|
|
20
|
+
a: 'meridian'
|
|
21
|
+
};
|
|
22
|
+
exports.patternMap = patternMap;
|
|
23
|
+
var DateField = /*#__PURE__*/function (_Object) {
|
|
24
|
+
(0, _inheritsLoose2.default)(DateField, _Object);
|
|
25
|
+
function DateField(format, value) {
|
|
26
|
+
var _this;
|
|
27
|
+
_this = _Object.call(this) || this;
|
|
28
|
+
_this.format = void 0;
|
|
29
|
+
_this.patternArray = [];
|
|
30
|
+
_this.year = null;
|
|
31
|
+
_this.month = null;
|
|
32
|
+
_this.day = null;
|
|
33
|
+
_this.hour = null;
|
|
34
|
+
_this.minute = null;
|
|
35
|
+
_this.second = null;
|
|
36
|
+
_this.meridian = null;
|
|
37
|
+
_this.format = format;
|
|
38
|
+
var formatArray = format.match(new RegExp('([y|d|M|H|h|m|s|a])+', 'ig')) || [];
|
|
39
|
+
_this.patternArray = formatArray.map(function (pattern) {
|
|
40
|
+
return {
|
|
41
|
+
pattern: pattern,
|
|
42
|
+
key: patternMap[pattern[0]]
|
|
43
|
+
};
|
|
44
|
+
});
|
|
45
|
+
if (value) {
|
|
46
|
+
_this.year = value.getFullYear();
|
|
47
|
+
_this.month = value.getMonth() + 1;
|
|
48
|
+
_this.day = value.getDate();
|
|
49
|
+
_this.hour = value.getHours();
|
|
50
|
+
_this.minute = value.getMinutes();
|
|
51
|
+
_this.second = value.getSeconds();
|
|
52
|
+
_this.meridian = value.getHours() > 12 ? 'PM' : 'AM';
|
|
53
|
+
}
|
|
54
|
+
return _this;
|
|
55
|
+
}
|
|
56
|
+
return DateField;
|
|
57
|
+
}( /*#__PURE__*/(0, _wrapNativeSuper2.default)(Object));
|
|
58
|
+
/**
|
|
59
|
+
* Pad a number with zeros to the left.
|
|
60
|
+
*/
|
|
61
|
+
exports.DateField = DateField;
|
|
62
|
+
function padNumber(number, length) {
|
|
63
|
+
var numberString = String(number);
|
|
64
|
+
if (numberString.length >= length) {
|
|
65
|
+
return numberString;
|
|
66
|
+
}
|
|
67
|
+
var paddingCount = length - numberString.length;
|
|
68
|
+
for (var i = 0; i < paddingCount; i++) {
|
|
69
|
+
numberString = '0' + numberString;
|
|
70
|
+
}
|
|
71
|
+
return numberString;
|
|
72
|
+
}
|
|
73
|
+
var useDateField = function useDateField(format, localize, date) {
|
|
74
|
+
var _useReducer = (0, _react.useReducer)(function (state, action) {
|
|
75
|
+
switch (action.type) {
|
|
76
|
+
case 'setYear':
|
|
77
|
+
return (0, _extends2.default)({}, state, {
|
|
78
|
+
year: action.value
|
|
79
|
+
});
|
|
80
|
+
case 'setMonth':
|
|
81
|
+
return (0, _extends2.default)({}, state, {
|
|
82
|
+
month: action.value
|
|
83
|
+
});
|
|
84
|
+
case 'setDay':
|
|
85
|
+
return (0, _extends2.default)({}, state, {
|
|
86
|
+
day: action.value
|
|
87
|
+
});
|
|
88
|
+
case 'setHour':
|
|
89
|
+
return (0, _extends2.default)({}, state, {
|
|
90
|
+
hour: action.value
|
|
91
|
+
});
|
|
92
|
+
case 'setMinute':
|
|
93
|
+
return (0, _extends2.default)({}, state, {
|
|
94
|
+
minute: action.value
|
|
95
|
+
});
|
|
96
|
+
case 'setSecond':
|
|
97
|
+
return (0, _extends2.default)({}, state, {
|
|
98
|
+
second: action.value
|
|
99
|
+
});
|
|
100
|
+
case 'setMeridian':
|
|
101
|
+
return (0, _extends2.default)({}, state, {
|
|
102
|
+
meridian: action.value
|
|
103
|
+
});
|
|
104
|
+
default:
|
|
105
|
+
return state;
|
|
106
|
+
}
|
|
107
|
+
}, new DateField(format, date)),
|
|
108
|
+
dateField = _useReducer[0],
|
|
109
|
+
dispatch = _useReducer[1];
|
|
110
|
+
var toDateString = function toDateString() {
|
|
111
|
+
var str = format;
|
|
112
|
+
dateField.patternArray.forEach(function (item) {
|
|
113
|
+
var key = item.key,
|
|
114
|
+
pattern = item.pattern;
|
|
115
|
+
var value = dateField[key];
|
|
116
|
+
if (value !== null) {
|
|
117
|
+
if (pattern === 'MMM' && typeof value === 'number') {
|
|
118
|
+
value = localize === null || localize === void 0 ? void 0 : localize.month(value - 1, {
|
|
119
|
+
width: 'abbreviated'
|
|
120
|
+
});
|
|
121
|
+
} else if (pattern === 'MMMM' && typeof value === 'number') {
|
|
122
|
+
value = localize === null || localize === void 0 ? void 0 : localize.month(value - 1, {
|
|
123
|
+
width: 'wide'
|
|
124
|
+
});
|
|
125
|
+
} else if (pattern === 'aa' && typeof value === 'number') {
|
|
126
|
+
value = value === 0 ? 'AM' : 'PM';
|
|
127
|
+
} else if (pattern === 'hh' && typeof value === 'number') {
|
|
128
|
+
value = value === 0 ? 12 : value > 12 ? value - 12 : value;
|
|
129
|
+
}
|
|
130
|
+
if (typeof value === 'number') {
|
|
131
|
+
value = padNumber(value, pattern.length);
|
|
132
|
+
}
|
|
133
|
+
str = str.replace(pattern, value);
|
|
134
|
+
}
|
|
135
|
+
});
|
|
136
|
+
return str;
|
|
137
|
+
};
|
|
138
|
+
var toDate = function toDate(type, value) {
|
|
139
|
+
if (value === null) {
|
|
140
|
+
return new Date('');
|
|
141
|
+
}
|
|
142
|
+
return (0, _utils.modifyDate)(new Date(dateField.year, dateField.month ? dateField.month - 1 : 0, dateField.day, dateField.hour, dateField.minute, dateField.second), type, value);
|
|
143
|
+
};
|
|
144
|
+
return {
|
|
145
|
+
dateField: dateField,
|
|
146
|
+
dispatch: dispatch,
|
|
147
|
+
toDate: toDate,
|
|
148
|
+
toDateString: toDateString
|
|
149
|
+
};
|
|
150
|
+
};
|
|
151
|
+
exports.useDateField = useDateField;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { InputProps } from '../Input';
|
|
3
|
+
import { FormControlBaseProps } from '../@types/common';
|
|
4
|
+
export interface DateInputProps extends Omit<InputProps, 'value' | 'onChange' | 'defaultValue'>, FormControlBaseProps<Date | null> {
|
|
5
|
+
/**
|
|
6
|
+
* Format of the date when rendered in the input.
|
|
7
|
+
* Format of the string is based on Unicode Technical Standard: https://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table
|
|
8
|
+
* @default 'yyyy-MM-dd'
|
|
9
|
+
**/
|
|
10
|
+
format?: string;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* The DateInput component lets users select a date with the keyboard.
|
|
14
|
+
* @version 5.58.0
|
|
15
|
+
* @see https://rsuitejs.com/components/date-input/
|
|
16
|
+
*/
|
|
17
|
+
declare const DateInput: React.ForwardRefExoticComponent<DateInputProps & React.RefAttributes<unknown>>;
|
|
18
|
+
export default DateInput;
|