@bifrostui/react 1.4.8-beta.0 → 2.0.0-alpha.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/dist/ActionSheet/ActionSheet.css +16 -6
- package/dist/ActionSheet/ActionSheetItem.css +11 -17
- package/dist/ActionSheet/ActionSheetItem.js +3 -8
- package/dist/ActionSheet/ActionSheetItem.types.d.ts +2 -2
- package/dist/ActionSheet/index.css +89 -0
- package/dist/Alert/Alert.types.d.ts +3 -3
- package/dist/Alert/index.css +18 -14
- package/dist/Avatar/Avatar.css +16 -12
- package/dist/Avatar/Avatar.js +3 -8
- package/dist/Avatar/AvatarGroup.css +19 -15
- package/dist/Avatar/AvatarGroup.js +2 -6
- package/dist/Avatar/index.css +93 -0
- package/dist/Backdrop/Backdrop.d.ts +1 -1
- package/dist/Backdrop/Backdrop.js +1 -1
- package/dist/Backdrop/{Backdrop.css → index.css} +6 -2
- package/dist/Badge/Badge.d.ts +1 -1
- package/dist/Badge/Badge.js +4 -9
- package/dist/Badge/Badge.types.d.ts +1 -1
- package/dist/Badge/{Badge.css → index.css} +47 -27
- package/dist/Breadcrumb/Breadcrumb.d.ts +1 -1
- package/dist/Breadcrumb/Breadcrumb.js +1 -1
- package/dist/Breadcrumb/index.css +38 -0
- package/dist/Button/Button.d.ts +1 -1
- package/dist/Button/Button.js +6 -11
- package/dist/Button/Button.types.d.ts +8 -7
- package/{es/Button/Button.css → dist/Button/index.css} +93 -63
- package/dist/Calendar/Calendar.d.ts +1 -1
- package/dist/Calendar/Calendar.js +10 -22
- package/dist/Calendar/Calendar.types.d.ts +0 -5
- package/dist/Calendar/{Calendar.css → index.css} +35 -31
- package/dist/Card/Card.css +9 -0
- package/dist/Card/CardContent.css +1 -2
- package/dist/Card/CardFooter.css +2 -4
- package/dist/Card/CardHeader.css +5 -5
- package/dist/Card/CardHeader.js +2 -2
- package/dist/Card/index.css +77 -0
- package/dist/Checkbox/Checkbox.d.ts +1 -1
- package/dist/Checkbox/Checkbox.js +4 -8
- package/dist/Checkbox/CheckboxGroup.d.ts +1 -1
- package/dist/Checkbox/CheckboxGroup.js +5 -8
- package/dist/Checkbox/{Checkbox.css → index.css} +14 -10
- package/dist/CitySelector/CitySelector.miniapp.d.ts +0 -1
- package/dist/CitySelector/CitySelector.miniapp.js +0 -1
- package/dist/CitySelector/CitySelectorCore.d.ts +1 -1
- package/dist/CitySelector/CitySelectorCore.js +1 -1
- package/dist/CitySelector/Selector/index.css +4 -4
- package/{es/CitySelector/CitySelector.css → dist/CitySelector/index.css} +31 -27
- package/dist/Collapse/Collapse.d.ts +2 -2
- package/dist/Collapse/Collapse.js +9 -12
- package/{es/Collapse/Collapse.css → dist/Collapse/index.css} +1 -0
- package/dist/CollapsePanel/CollapsePanel.d.ts +1 -1
- package/dist/CollapsePanel/CollapsePanel.js +1 -1
- package/dist/CollapsePanel/CollapsePanelItem.js +45 -46
- package/{es/CollapsePanel/CollapsePanel.css → dist/CollapsePanel/index.css} +12 -10
- package/dist/Countdown/Countdown.d.ts +1 -1
- package/dist/Countdown/Countdown.js +6 -13
- package/{es/Countdown/Countdown.css → dist/Countdown/index.css} +12 -8
- package/dist/Dialog/FunctionalDialog.js +1 -1
- package/dist/Dialog/index.css +26 -23
- package/dist/Divider/Divider.d.ts +1 -1
- package/dist/Divider/Divider.js +9 -6
- package/{es/Divider/Divider.css → dist/Divider/index.css} +14 -10
- package/dist/Drawer/Drawer.d.ts +1 -1
- package/dist/Drawer/Drawer.js +5 -11
- package/dist/Drawer/{Drawer.css → index.css} +2 -0
- package/dist/Fade/Fade.js +52 -56
- package/dist/IconButton/IconButton.d.ts +1 -1
- package/dist/IconButton/IconButton.js +7 -14
- package/dist/IconButton/IconButton.types.d.ts +4 -3
- package/{es/IconButton/IconButton.css → dist/IconButton/index.css} +79 -29
- package/dist/Image/Image.js +112 -119
- package/dist/Image/index.css +6 -2
- package/dist/Input/Input.d.ts +1 -1
- package/dist/Input/Input.js +6 -12
- package/{es/Input/Input.css → dist/Input/index.css} +22 -18
- package/dist/ItemSelector/ItemSelector.miniapp.d.ts +0 -1
- package/dist/ItemSelector/ItemSelector.miniapp.js +0 -1
- package/dist/ItemSelector/ItemSelectorCore.d.ts +1 -1
- package/dist/ItemSelector/ItemSelectorCore.js +1 -1
- package/dist/List/List.css +7 -3
- package/dist/List/List.js +3 -8
- package/dist/List/ListItem.css +3 -3
- package/dist/List/ListItem.js +42 -44
- package/dist/List/ListItemContent.js +1 -4
- package/dist/List/ListItemExtra.js +9 -4
- package/dist/List/ListItemFooter.js +9 -4
- package/dist/List/ListItemHeader.js +9 -4
- package/dist/List/index.css +80 -0
- package/dist/Loading/Loading.d.ts +1 -1
- package/dist/Loading/Loading.js +14 -5
- package/{es/Loading/Loading.css → dist/Loading/index.css} +10 -6
- package/dist/Modal/Modal.d.ts +1 -1
- package/dist/Modal/Modal.js +1 -7
- package/dist/Modal/Modal.miniapp.d.ts +2 -2
- package/dist/Modal/Modal.miniapp.js +5 -11
- package/dist/NavBar/NavBar.d.ts +1 -1
- package/dist/NavBar/NavBar.js +1 -2
- package/dist/NavBar/index.css +65 -0
- package/dist/Picker/Picker.css +21 -21
- package/dist/Picker/Picker.js +6 -28
- package/dist/Picker/Picker.types.d.ts +4 -17
- package/dist/Picker/PickerPanel.css +8 -12
- package/dist/Picker/PickerPanel.js +39 -29
- package/dist/Picker/index.css +116 -0
- package/dist/Popover/Popover.d.ts +1 -1
- package/dist/Popover/Popover.js +28 -71
- package/{es/Popover/Popover.css → dist/Popover/index.css} +32 -28
- package/dist/Portal/Portal.miniapp.js +4 -7
- package/dist/Progress/Progress.d.ts +1 -1
- package/dist/Progress/Progress.js +1 -1
- package/dist/Progress/index.css +28 -0
- package/dist/Radio/Radio.d.ts +1 -1
- package/dist/Radio/Radio.js +3 -7
- package/dist/Radio/RadioButtonIcon.js +6 -1
- package/dist/Radio/RadioGroup.d.ts +1 -1
- package/dist/Radio/RadioGroup.js +1 -4
- package/dist/Radio/{Radio.css → index.css} +10 -7
- package/dist/Rating/Rating.d.ts +1 -1
- package/dist/Rating/Rating.js +9 -19
- package/{es/Rating/Rating.css → dist/Rating/index.css} +20 -7
- package/dist/ScrollView/ScrollView.d.ts +1 -1
- package/dist/ScrollView/ScrollView.js +12 -25
- package/dist/ScrollView/ScrollView.types.d.ts +1 -0
- package/dist/Select/Select.d.ts +1 -1
- package/dist/Select/Select.js +43 -76
- package/dist/Select/SelectOption.d.ts +1 -1
- package/dist/Select/SelectOption.js +1 -1
- package/dist/Select/{Select.css → index.css} +30 -20
- package/dist/Skeleton/Skeleton.d.ts +1 -1
- package/dist/Skeleton/Skeleton.js +6 -10
- package/dist/Skeleton/{Skeleton.css → index.css} +7 -3
- package/dist/Slide/Slide.js +69 -74
- package/dist/Slider/Slider.d.ts +1 -1
- package/dist/Slider/Slider.js +13 -29
- package/dist/Slider/index.css +111 -0
- package/dist/Stack/Stack.d.ts +1 -1
- package/dist/Stack/Stack.js +1 -1
- package/dist/Steps/Step.css +14 -14
- package/dist/Steps/Step.js +81 -82
- package/dist/Steps/Steps.css +18 -14
- package/dist/Steps/Steps.d.ts +1 -1
- package/dist/Steps/Steps.js +57 -60
- package/dist/Steps/index.css +199 -0
- package/dist/Swiper/Swiper.d.ts +1 -1
- package/dist/Swiper/Swiper.js +1 -1
- package/{es/Swiper/Swiper.css → dist/Swiper/index.css} +6 -2
- package/dist/Switch/Switch.d.ts +1 -1
- package/dist/Switch/Switch.js +76 -79
- package/dist/Switch/Switch.types.d.ts +1 -1
- package/{es/Switch/Switch.css → dist/Switch/index.css} +46 -35
- package/dist/TabBar/TabBar.css +12 -8
- package/dist/TabBar/TabBar.js +3 -8
- package/dist/TabBar/TabBarContext.d.ts +3 -3
- package/dist/TabBar/TabBarItem.css +6 -0
- package/dist/TabBar/TabBarItem.js +3 -3
- package/dist/TabBar/index.css +59 -0
- package/dist/TabBar/index.types.d.ts +3 -3
- package/dist/Tabs/Tab.css +10 -16
- package/dist/Tabs/Tab.js +2 -3
- package/dist/Tabs/Tabs.css +32 -21
- package/dist/Tabs/Tabs.js +39 -70
- package/dist/Tabs/Tabs.types.d.ts +0 -10
- package/dist/Tabs/index.css +135 -0
- package/dist/Tabs/utils/bound.d.ts +1 -0
- package/dist/{DesktopPicker/utils/calcAfterMounted.js → Tabs/utils/bound.js} +14 -7
- package/dist/Tag/Tag.css +49 -23
- package/dist/Tag/Tag.js +3 -7
- package/dist/Tag/Tag.types.d.ts +4 -4
- package/dist/Tag/TagGroup.css +15 -11
- package/dist/Tag/TagGroup.d.ts +2 -2
- package/dist/Tag/TagGroup.js +16 -14
- package/dist/Tag/index.css +182 -0
- package/dist/TextArea/TextArea.d.ts +1 -1
- package/dist/TextArea/TextArea.js +6 -13
- package/dist/TextArea/index.css +57 -0
- package/dist/ThemeProvider/ThemeProvider.js +1 -4
- package/dist/ThemeProvider/ThemeProvider.types.d.ts +5 -10
- package/dist/ThemeProvider/utils/constants.d.ts +1 -1
- package/dist/ThemeProvider/utils/constants.js +4 -1
- package/dist/ThemeProvider/utils/mountTokens.d.ts +4 -4
- package/dist/Toast/FunctionalToast.js +1 -1
- package/dist/Toast/Toast.d.ts +1 -1
- package/dist/Toast/Toast.js +5 -5
- package/dist/Toast/index.css +58 -0
- package/dist/Tooltip/Tooltip.d.ts +1 -1
- package/dist/Tooltip/Tooltip.js +28 -71
- package/dist/Tooltip/index.css +95 -0
- package/dist/Transition/TransitionCore.js +3 -8
- package/dist/index.d.ts +0 -6
- package/dist/index.js +1 -13
- package/dist/locales/base.d.ts +0 -11
- package/dist/locales/en-US.js +0 -24
- package/dist/locales/zh-CN.js +0 -24
- package/dist/locales/zh-TW.js +0 -24
- package/es/ActionSheet/ActionSheet.css +16 -6
- package/es/ActionSheet/ActionSheetItem.css +11 -17
- package/es/ActionSheet/ActionSheetItem.js +3 -8
- package/es/ActionSheet/ActionSheetItem.types.d.ts +2 -2
- package/es/ActionSheet/index.css +89 -0
- package/es/Alert/Alert.types.d.ts +3 -3
- package/es/Alert/index.css +18 -14
- package/es/Avatar/Avatar.css +16 -12
- package/es/Avatar/Avatar.js +3 -8
- package/es/Avatar/AvatarGroup.css +19 -15
- package/es/Avatar/AvatarGroup.js +2 -6
- package/es/Avatar/index.css +93 -0
- package/es/Backdrop/Backdrop.d.ts +1 -1
- package/es/Backdrop/Backdrop.js +1 -1
- package/es/Backdrop/{Backdrop.css → index.css} +6 -2
- package/es/Badge/Badge.d.ts +1 -1
- package/es/Badge/Badge.js +4 -9
- package/es/Badge/Badge.types.d.ts +1 -1
- package/es/Badge/{Badge.css → index.css} +47 -27
- package/es/Breadcrumb/Breadcrumb.d.ts +1 -1
- package/es/Breadcrumb/Breadcrumb.js +1 -1
- package/es/Breadcrumb/index.css +38 -0
- package/es/Button/Button.d.ts +1 -1
- package/es/Button/Button.js +6 -11
- package/es/Button/Button.types.d.ts +8 -7
- package/{dist/Button/Button.css → es/Button/index.css} +93 -63
- package/es/Calendar/Calendar.d.ts +1 -1
- package/es/Calendar/Calendar.js +10 -22
- package/es/Calendar/Calendar.types.d.ts +0 -5
- package/es/Calendar/{Calendar.css → index.css} +35 -31
- package/es/Card/Card.css +9 -0
- package/es/Card/CardContent.css +1 -2
- package/es/Card/CardFooter.css +2 -4
- package/es/Card/CardHeader.css +5 -5
- package/es/Card/CardHeader.js +2 -2
- package/es/Card/index.css +77 -0
- package/es/Checkbox/Checkbox.d.ts +1 -1
- package/es/Checkbox/Checkbox.js +4 -8
- package/es/Checkbox/CheckboxGroup.d.ts +1 -1
- package/es/Checkbox/CheckboxGroup.js +5 -8
- package/es/Checkbox/{Checkbox.css → index.css} +14 -10
- package/es/CitySelector/CitySelector.miniapp.d.ts +0 -1
- package/es/CitySelector/CitySelector.miniapp.js +0 -1
- package/es/CitySelector/CitySelectorCore.d.ts +1 -1
- package/es/CitySelector/CitySelectorCore.js +1 -1
- package/es/CitySelector/Selector/index.css +4 -4
- package/{dist/CitySelector/CitySelector.css → es/CitySelector/index.css} +31 -27
- package/es/Collapse/Collapse.d.ts +2 -2
- package/es/Collapse/Collapse.js +9 -12
- package/{dist/Collapse/Collapse.css → es/Collapse/index.css} +1 -0
- package/es/CollapsePanel/CollapsePanel.d.ts +1 -1
- package/es/CollapsePanel/CollapsePanel.js +1 -1
- package/es/CollapsePanel/CollapsePanelItem.js +45 -46
- package/{dist/CollapsePanel/CollapsePanel.css → es/CollapsePanel/index.css} +12 -10
- package/es/Countdown/Countdown.d.ts +1 -1
- package/es/Countdown/Countdown.js +6 -13
- package/{dist/Countdown/Countdown.css → es/Countdown/index.css} +12 -8
- package/es/Dialog/FunctionalDialog.js +2 -2
- package/es/Dialog/index.css +26 -23
- package/es/Divider/Divider.d.ts +1 -1
- package/es/Divider/Divider.js +9 -6
- package/{dist/Divider/Divider.css → es/Divider/index.css} +14 -10
- package/es/Drawer/Drawer.d.ts +1 -1
- package/es/Drawer/Drawer.js +5 -11
- package/es/Drawer/{Drawer.css → index.css} +2 -0
- package/es/Fade/Fade.js +52 -56
- package/es/IconButton/IconButton.d.ts +1 -1
- package/es/IconButton/IconButton.js +7 -14
- package/es/IconButton/IconButton.types.d.ts +4 -3
- package/{dist/IconButton/IconButton.css → es/IconButton/index.css} +79 -29
- package/es/Image/Image.js +112 -119
- package/es/Image/index.css +6 -2
- package/es/Input/Input.d.ts +1 -1
- package/es/Input/Input.js +6 -12
- package/{dist/Input/Input.css → es/Input/index.css} +22 -18
- package/es/ItemSelector/ItemSelector.miniapp.d.ts +0 -1
- package/es/ItemSelector/ItemSelector.miniapp.js +0 -1
- package/es/ItemSelector/ItemSelectorCore.d.ts +1 -1
- package/es/ItemSelector/ItemSelectorCore.js +1 -1
- package/es/List/List.css +7 -3
- package/es/List/List.js +3 -8
- package/es/List/ListItem.css +3 -3
- package/es/List/ListItem.js +42 -44
- package/es/List/ListItemContent.js +1 -4
- package/es/List/ListItemExtra.js +9 -4
- package/es/List/ListItemFooter.js +9 -4
- package/es/List/ListItemHeader.js +9 -4
- package/es/List/index.css +80 -0
- package/es/Loading/Loading.d.ts +1 -1
- package/es/Loading/Loading.js +14 -5
- package/{dist/Loading/Loading.css → es/Loading/index.css} +10 -6
- package/es/Modal/Modal.d.ts +1 -1
- package/es/Modal/Modal.js +1 -7
- package/es/Modal/Modal.miniapp.d.ts +2 -2
- package/es/Modal/Modal.miniapp.js +5 -11
- package/es/NavBar/NavBar.d.ts +1 -1
- package/es/NavBar/NavBar.js +1 -2
- package/es/NavBar/index.css +65 -0
- package/es/Picker/Picker.css +21 -21
- package/es/Picker/Picker.js +6 -28
- package/es/Picker/Picker.types.d.ts +4 -17
- package/es/Picker/PickerPanel.css +8 -12
- package/es/Picker/PickerPanel.js +52 -31
- package/es/Picker/index.css +116 -0
- package/es/Popover/Popover.d.ts +1 -1
- package/es/Popover/Popover.js +30 -74
- package/{dist/Popover/Popover.css → es/Popover/index.css} +32 -28
- package/es/Portal/Portal.miniapp.js +5 -8
- package/es/Progress/Progress.d.ts +1 -1
- package/es/Progress/Progress.js +1 -1
- package/es/Progress/index.css +28 -0
- package/es/Radio/Radio.d.ts +1 -1
- package/es/Radio/Radio.js +3 -7
- package/es/Radio/RadioButtonIcon.js +6 -1
- package/es/Radio/RadioGroup.d.ts +1 -1
- package/es/Radio/RadioGroup.js +1 -4
- package/es/Radio/{Radio.css → index.css} +10 -7
- package/es/Rating/Rating.d.ts +1 -1
- package/es/Rating/Rating.js +9 -19
- package/{dist/Rating/Rating.css → es/Rating/index.css} +20 -7
- package/es/ScrollView/ScrollView.d.ts +1 -1
- package/es/ScrollView/ScrollView.js +12 -25
- package/es/ScrollView/ScrollView.types.d.ts +1 -0
- package/es/Select/Select.d.ts +1 -1
- package/es/Select/Select.js +44 -76
- package/es/Select/SelectOption.d.ts +1 -1
- package/es/Select/SelectOption.js +1 -1
- package/es/Select/{Select.css → index.css} +30 -20
- package/es/Skeleton/Skeleton.d.ts +1 -1
- package/es/Skeleton/Skeleton.js +6 -10
- package/es/Skeleton/{Skeleton.css → index.css} +7 -3
- package/es/Slide/Slide.js +69 -74
- package/es/Slider/Slider.d.ts +1 -1
- package/es/Slider/Slider.js +14 -32
- package/es/Slider/index.css +111 -0
- package/es/Stack/Stack.d.ts +1 -1
- package/es/Stack/Stack.js +1 -1
- package/es/Steps/Step.css +14 -14
- package/es/Steps/Step.js +81 -82
- package/es/Steps/Steps.css +18 -14
- package/es/Steps/Steps.d.ts +1 -1
- package/es/Steps/Steps.js +57 -60
- package/es/Steps/index.css +199 -0
- package/es/Swiper/Swiper.d.ts +1 -1
- package/es/Swiper/Swiper.js +1 -1
- package/{dist/Swiper/Swiper.css → es/Swiper/index.css} +6 -2
- package/es/Switch/Switch.d.ts +1 -1
- package/es/Switch/Switch.js +76 -79
- package/es/Switch/Switch.types.d.ts +1 -1
- package/{dist/Switch/Switch.css → es/Switch/index.css} +46 -35
- package/es/TabBar/TabBar.css +12 -8
- package/es/TabBar/TabBar.js +3 -8
- package/es/TabBar/TabBarContext.d.ts +3 -3
- package/es/TabBar/TabBarItem.css +6 -0
- package/es/TabBar/TabBarItem.js +2 -2
- package/es/TabBar/index.css +59 -0
- package/es/TabBar/index.types.d.ts +3 -3
- package/es/Tabs/Tab.css +10 -16
- package/es/Tabs/Tab.js +2 -3
- package/es/Tabs/Tabs.css +32 -21
- package/es/Tabs/Tabs.js +41 -83
- package/es/Tabs/Tabs.types.d.ts +0 -10
- package/es/Tabs/index.css +135 -0
- package/es/Tabs/utils/bound.d.ts +1 -0
- package/es/Tabs/utils/bound.js +13 -0
- package/es/Tag/Tag.css +49 -23
- package/es/Tag/Tag.js +3 -7
- package/es/Tag/Tag.types.d.ts +4 -4
- package/es/Tag/TagGroup.css +15 -11
- package/es/Tag/TagGroup.d.ts +2 -2
- package/es/Tag/TagGroup.js +16 -14
- package/es/Tag/index.css +182 -0
- package/es/TextArea/TextArea.d.ts +1 -1
- package/es/TextArea/TextArea.js +6 -13
- package/es/TextArea/index.css +57 -0
- package/es/ThemeProvider/ThemeProvider.js +1 -4
- package/es/ThemeProvider/ThemeProvider.types.d.ts +5 -10
- package/es/ThemeProvider/utils/constants.d.ts +1 -1
- package/es/ThemeProvider/utils/constants.js +4 -1
- package/es/ThemeProvider/utils/mountTokens.d.ts +4 -4
- package/es/Toast/FunctionalToast.js +2 -2
- package/es/Toast/Toast.d.ts +1 -1
- package/es/Toast/Toast.js +5 -5
- package/es/Toast/index.css +58 -0
- package/es/Tooltip/Tooltip.d.ts +1 -1
- package/es/Tooltip/Tooltip.js +30 -74
- package/es/Tooltip/index.css +95 -0
- package/es/Transition/TransitionCore.js +3 -8
- package/es/index.d.ts +0 -6
- package/es/index.js +0 -6
- package/es/locales/base.d.ts +0 -11
- package/es/locales/en-US.js +0 -24
- package/es/locales/zh-CN.js +0 -24
- package/es/locales/zh-TW.js +0 -24
- package/package.json +14 -6
- package/dist/Breadcrumb/Breadcrumb.css +0 -34
- package/dist/CitySelector/miniapp.css +0 -4
- package/dist/Collapse/Collapse.miniapp.d.ts +0 -5
- package/dist/Collapse/Collapse.miniapp.js +0 -177
- package/dist/DatePicker/DatePicker.d.ts +0 -4
- package/dist/DatePicker/DatePicker.js +0 -335
- package/dist/DatePicker/DatePicker.types.d.ts +0 -36
- package/dist/DatePicker/DatePicker.types.js +0 -15
- package/dist/DatePicker/constants.d.ts +0 -9
- package/dist/DatePicker/constants.js +0 -37
- package/dist/DatePicker/index.d.ts +0 -3
- package/dist/DatePicker/index.js +0 -44
- package/dist/DesktopDatePicker/DesktopDatePicker.d.ts +0 -5
- package/dist/DesktopDatePicker/DesktopDatePicker.js +0 -280
- package/dist/DesktopDatePicker/DesktopDatePicker.types.d.ts +0 -163
- package/dist/DesktopDatePicker/DesktopDatePicker.types.js +0 -15
- package/dist/DesktopDatePicker/deskTopPickerContainer.css +0 -100
- package/dist/DesktopDatePicker/index.css +0 -61
- package/dist/DesktopDatePicker/index.d.ts +0 -2
- package/dist/DesktopDatePicker/index.js +0 -41
- package/dist/DesktopDatePicker/useGetDatePickerContent.d.ts +0 -6
- package/dist/DesktopDatePicker/useGetDatePickerContent.js +0 -343
- package/dist/DesktopDateTimePicker/DesktopDateTimePicker.d.ts +0 -5
- package/dist/DesktopDateTimePicker/DesktopDateTimePicker.js +0 -322
- package/dist/DesktopDateTimePicker/DesktopDateTimePicker.types.d.ts +0 -163
- package/dist/DesktopDateTimePicker/DesktopDateTimePicker.types.js +0 -15
- package/dist/DesktopDateTimePicker/index.css +0 -66
- package/dist/DesktopDateTimePicker/index.d.ts +0 -2
- package/dist/DesktopDateTimePicker/index.js +0 -41
- package/dist/DesktopPicker/DesktopPicker.d.ts +0 -5
- package/dist/DesktopPicker/DesktopPicker.js +0 -238
- package/dist/DesktopPicker/DesktopPicker.types.d.ts +0 -57
- package/dist/DesktopPicker/DesktopPicker.types.js +0 -15
- package/dist/DesktopPicker/index.css +0 -37
- package/dist/DesktopPicker/index.d.ts +0 -2
- package/dist/DesktopPicker/index.js +0 -41
- package/dist/DesktopPicker/utils/calcAfterMounted.d.ts +0 -2
- package/dist/DesktopPicker/utils/calcAfterMounted.miniapp.d.ts +0 -2
- package/dist/DesktopPicker/utils/calcAfterMounted.miniapp.js +0 -38
- package/dist/DesktopTimePicker/DesktopTimePicker.d.ts +0 -5
- package/dist/DesktopTimePicker/DesktopTimePicker.js +0 -288
- package/dist/DesktopTimePicker/DesktopTimePicker.types.d.ts +0 -182
- package/dist/DesktopTimePicker/DesktopTimePicker.types.js +0 -15
- package/dist/DesktopTimePicker/DesktopTimePickerList.d.ts +0 -4
- package/dist/DesktopTimePicker/DesktopTimePickerList.js +0 -111
- package/dist/DesktopTimePicker/index.css +0 -170
- package/dist/DesktopTimePicker/index.d.ts +0 -2
- package/dist/DesktopTimePicker/index.js +0 -41
- package/dist/DesktopTimePicker/useGetTimePickerContent.d.ts +0 -6
- package/dist/DesktopTimePicker/useGetTimePickerContent.js +0 -249
- package/dist/DesktopTimePicker/utils/scrollUtil.d.ts +0 -2
- package/dist/DesktopTimePicker/utils/scrollUtil.js +0 -27
- package/dist/DesktopTimePicker/utils/scrollUtil.miniapp.d.ts +0 -2
- package/dist/DesktopTimePicker/utils/scrollUtil.miniapp.js +0 -51
- package/dist/DesktopTimePicker/utils/utils.d.ts +0 -28
- package/dist/DesktopTimePicker/utils/utils.js +0 -408
- package/dist/ItemSelector/miniapp.css +0 -4
- package/dist/NavBar/NavBar.css +0 -61
- package/dist/Progress/Progress.css +0 -24
- package/dist/Slider/Slider.css +0 -106
- package/dist/SwipeAction/SwipeAction.css +0 -79
- package/dist/SwipeAction/SwipeAction.d.ts +0 -5
- package/dist/SwipeAction/SwipeAction.js +0 -349
- package/dist/SwipeAction/SwipeAction.types.d.ts +0 -75
- package/dist/SwipeAction/SwipeAction.types.js +0 -15
- package/dist/SwipeAction/SwipeActionContext.d.ts +0 -4
- package/dist/SwipeAction/SwipeActionContext.js +0 -30
- package/dist/SwipeAction/SwipeActionItem.css +0 -31
- package/dist/SwipeAction/SwipeActionItem.d.ts +0 -5
- package/dist/SwipeAction/SwipeActionItem.js +0 -105
- package/dist/SwipeAction/constants.d.ts +0 -9
- package/dist/SwipeAction/constants.js +0 -39
- package/dist/SwipeAction/index.d.ts +0 -5
- package/dist/SwipeAction/index.js +0 -50
- package/dist/Tabs/utils/scroll.d.ts +0 -2
- package/dist/Tabs/utils/scroll.js +0 -55
- package/dist/TextArea/TextArea.css +0 -53
- package/dist/Toast/Toast.css +0 -53
- package/dist/Tooltip/Tooltip.css +0 -91
- package/es/Breadcrumb/Breadcrumb.css +0 -34
- package/es/CitySelector/miniapp.css +0 -4
- package/es/Collapse/Collapse.miniapp.d.ts +0 -5
- package/es/Collapse/Collapse.miniapp.js +0 -157
- package/es/DatePicker/DatePicker.d.ts +0 -4
- package/es/DatePicker/DatePicker.js +0 -308
- package/es/DatePicker/DatePicker.types.d.ts +0 -36
- package/es/DatePicker/DatePicker.types.js +0 -1
- package/es/DatePicker/constants.d.ts +0 -9
- package/es/DatePicker/constants.js +0 -14
- package/es/DatePicker/index.d.ts +0 -3
- package/es/DatePicker/index.js +0 -8
- package/es/DesktopDatePicker/DesktopDatePicker.d.ts +0 -5
- package/es/DesktopDatePicker/DesktopDatePicker.js +0 -253
- package/es/DesktopDatePicker/DesktopDatePicker.types.d.ts +0 -163
- package/es/DesktopDatePicker/DesktopDatePicker.types.js +0 -1
- package/es/DesktopDatePicker/deskTopPickerContainer.css +0 -100
- package/es/DesktopDatePicker/index.css +0 -61
- package/es/DesktopDatePicker/index.d.ts +0 -2
- package/es/DesktopDatePicker/index.js +0 -6
- package/es/DesktopDatePicker/useGetDatePickerContent.d.ts +0 -6
- package/es/DesktopDatePicker/useGetDatePickerContent.js +0 -316
- package/es/DesktopDateTimePicker/DesktopDateTimePicker.d.ts +0 -5
- package/es/DesktopDateTimePicker/DesktopDateTimePicker.js +0 -295
- package/es/DesktopDateTimePicker/DesktopDateTimePicker.types.d.ts +0 -163
- package/es/DesktopDateTimePicker/DesktopDateTimePicker.types.js +0 -1
- package/es/DesktopDateTimePicker/index.css +0 -66
- package/es/DesktopDateTimePicker/index.d.ts +0 -2
- package/es/DesktopDateTimePicker/index.js +0 -9
- package/es/DesktopPicker/DesktopPicker.d.ts +0 -5
- package/es/DesktopPicker/DesktopPicker.js +0 -221
- package/es/DesktopPicker/DesktopPicker.types.d.ts +0 -57
- package/es/DesktopPicker/DesktopPicker.types.js +0 -1
- package/es/DesktopPicker/index.css +0 -37
- package/es/DesktopPicker/index.d.ts +0 -2
- package/es/DesktopPicker/index.js +0 -6
- package/es/DesktopPicker/utils/calcAfterMounted.d.ts +0 -2
- package/es/DesktopPicker/utils/calcAfterMounted.js +0 -6
- package/es/DesktopPicker/utils/calcAfterMounted.miniapp.d.ts +0 -2
- package/es/DesktopPicker/utils/calcAfterMounted.miniapp.js +0 -9
- package/es/DesktopTimePicker/DesktopTimePicker.d.ts +0 -5
- package/es/DesktopTimePicker/DesktopTimePicker.js +0 -261
- package/es/DesktopTimePicker/DesktopTimePicker.types.d.ts +0 -182
- package/es/DesktopTimePicker/DesktopTimePicker.types.js +0 -1
- package/es/DesktopTimePicker/DesktopTimePickerList.d.ts +0 -4
- package/es/DesktopTimePicker/DesktopTimePickerList.js +0 -84
- package/es/DesktopTimePicker/index.css +0 -170
- package/es/DesktopTimePicker/index.d.ts +0 -2
- package/es/DesktopTimePicker/index.js +0 -6
- package/es/DesktopTimePicker/useGetTimePickerContent.d.ts +0 -6
- package/es/DesktopTimePicker/useGetTimePickerContent.js +0 -226
- package/es/DesktopTimePicker/utils/scrollUtil.d.ts +0 -2
- package/es/DesktopTimePicker/utils/scrollUtil.js +0 -8
- package/es/DesktopTimePicker/utils/scrollUtil.miniapp.d.ts +0 -2
- package/es/DesktopTimePicker/utils/scrollUtil.miniapp.js +0 -22
- package/es/DesktopTimePicker/utils/utils.d.ts +0 -28
- package/es/DesktopTimePicker/utils/utils.js +0 -365
- package/es/ItemSelector/miniapp.css +0 -4
- package/es/NavBar/NavBar.css +0 -61
- package/es/Progress/Progress.css +0 -24
- package/es/Slider/Slider.css +0 -106
- package/es/SwipeAction/SwipeAction.css +0 -79
- package/es/SwipeAction/SwipeAction.d.ts +0 -5
- package/es/SwipeAction/SwipeAction.js +0 -334
- package/es/SwipeAction/SwipeAction.types.d.ts +0 -75
- package/es/SwipeAction/SwipeAction.types.js +0 -1
- package/es/SwipeAction/SwipeActionContext.d.ts +0 -4
- package/es/SwipeAction/SwipeActionContext.js +0 -11
- package/es/SwipeAction/SwipeActionItem.css +0 -31
- package/es/SwipeAction/SwipeActionItem.d.ts +0 -5
- package/es/SwipeAction/SwipeActionItem.js +0 -78
- package/es/SwipeAction/constants.d.ts +0 -9
- package/es/SwipeAction/constants.js +0 -15
- package/es/SwipeAction/index.d.ts +0 -5
- package/es/SwipeAction/index.js +0 -12
- package/es/Tabs/utils/scroll.d.ts +0 -2
- package/es/Tabs/utils/scroll.js +0 -36
- package/es/TextArea/TextArea.css +0 -53
- package/es/Toast/Toast.css +0 -53
- package/es/Tooltip/Tooltip.css +0 -91
- /package/dist/ItemSelector/{ItemSelector.css → index.css} +0 -0
- /package/dist/Modal/{Modal.css → index.css} +0 -0
- /package/dist/ScrollView/{ScrollView.css → index.css} +0 -0
- /package/dist/Stack/{Stack.css → index.css} +0 -0
- /package/es/ItemSelector/{ItemSelector.css → index.css} +0 -0
- /package/es/Modal/{Modal.css → index.css} +0 -0
- /package/es/ScrollView/{ScrollView.css → index.css} +0 -0
- /package/es/Stack/{Stack.css → index.css} +0 -0
|
@@ -1,14 +1,18 @@
|
|
|
1
|
+
:root,
|
|
2
|
+
page,
|
|
3
|
+
xhs-page {
|
|
4
|
+
--bui-badge-position: 14%;
|
|
5
|
+
--bui-badge-min-width: 15px;
|
|
6
|
+
--bui-badge-height: 15px;
|
|
7
|
+
--bui-badge-line-height: 15px;
|
|
8
|
+
--bui-badge-padding: 0 3px;
|
|
9
|
+
--bui-badge-border-radius: 8px;
|
|
10
|
+
--bui-badge-outlined-padding: 0 2px;
|
|
11
|
+
--bui-badge-dot-size: 9px;
|
|
12
|
+
--bui-badge-bubble-padding: 0 5px;
|
|
13
|
+
--bui-badge-bubble-border-radius: 6px 6px 6px 0;
|
|
14
|
+
}
|
|
1
15
|
.bui-badge {
|
|
2
|
-
--badge-position: var(--bui-badge-position, 14%);
|
|
3
|
-
--min-width: var(--bui-badge-min-width, 15px);
|
|
4
|
-
--height: var(--bui-badge-height, 15px);
|
|
5
|
-
--line-height: var(--bui-badge-line-height, 15px);
|
|
6
|
-
--padding: var(--bui-badge-padding, 0 3px);
|
|
7
|
-
--border-radius: var(--bui-badge-border-radius, 8px);
|
|
8
|
-
--outlined-padding: var(--bui-badge-outlined-padding, 0 2px);
|
|
9
|
-
--dot-size: var(--bui-badge-dot-size, 9px);
|
|
10
|
-
--bubble-padding: var(--bui-badge-bubble-padding, 0 5px);
|
|
11
|
-
--bubble-border-radius: var(--bui-badge-bubble-border-radius, 6px 6px 6px 0);
|
|
12
16
|
display: inline-block;
|
|
13
17
|
font-family: var(--bui-font-family);
|
|
14
18
|
}
|
|
@@ -18,18 +22,18 @@
|
|
|
18
22
|
.bui-badge-position .bui-badge-contained,
|
|
19
23
|
.bui-badge-position .bui-badge-outlined {
|
|
20
24
|
position: absolute;
|
|
21
|
-
top: var(--badge-position);
|
|
22
|
-
right: var(--badge-position);
|
|
25
|
+
top: var(--bui-badge-position);
|
|
26
|
+
right: var(--bui-badge-position);
|
|
23
27
|
transform: scale(1) translate(50%, -50%);
|
|
24
28
|
}
|
|
25
29
|
.bui-badge-position .bui-badge-dot {
|
|
26
|
-
top: var(--badge-position);
|
|
27
|
-
right: var(--badge-position);
|
|
30
|
+
top: var(--bui-badge-position);
|
|
31
|
+
right: var(--bui-badge-position);
|
|
28
32
|
transform: scale(1) translate(50%, -50%);
|
|
29
33
|
}
|
|
30
34
|
.bui-badge-position .bui-badge-bubble {
|
|
31
|
-
top: var(--badge-position);
|
|
32
|
-
right: var(--badge-position);
|
|
35
|
+
top: var(--bui-badge-position);
|
|
36
|
+
right: var(--bui-badge-position);
|
|
33
37
|
transform: scale(1) translate(50%, -50%);
|
|
34
38
|
}
|
|
35
39
|
.bui-badge-contained,
|
|
@@ -38,18 +42,18 @@
|
|
|
38
42
|
box-sizing: border-box;
|
|
39
43
|
align-items: center;
|
|
40
44
|
justify-content: center;
|
|
41
|
-
min-width: var(--min-width);
|
|
42
|
-
height: var(--height);
|
|
43
|
-
line-height: var(--line-height);
|
|
44
|
-
padding: var(--padding);
|
|
45
|
+
min-width: var(--bui-badge-min-width);
|
|
46
|
+
height: var(--bui-badge-height);
|
|
47
|
+
line-height: var(--bui-badge-line-height);
|
|
48
|
+
padding: var(--bui-badge-padding);
|
|
45
49
|
font-size: var(--bui-text-size-4);
|
|
46
|
-
border-radius: var(--border-radius);
|
|
50
|
+
border-radius: var(--bui-badge-border-radius);
|
|
47
51
|
color: var(--bui-color-bg-view);
|
|
48
52
|
white-space: nowrap;
|
|
49
53
|
z-index: 1;
|
|
50
54
|
}
|
|
51
55
|
.bui-badge-outlined {
|
|
52
|
-
padding: var(--outlined-padding);
|
|
56
|
+
padding: var(--bui-badge-outlined-padding);
|
|
53
57
|
}
|
|
54
58
|
.bui-badge-primary {
|
|
55
59
|
background-color: var(--bui-color-primary);
|
|
@@ -66,16 +70,23 @@
|
|
|
66
70
|
.bui-badge-danger {
|
|
67
71
|
background-color: var(--bui-color-danger);
|
|
68
72
|
}
|
|
73
|
+
.bui-badge-light {
|
|
74
|
+
color: var(--bui-color-fg-default);
|
|
75
|
+
background-color: var(--bui-color-bg-view);
|
|
76
|
+
}
|
|
77
|
+
.bui-badge-dark {
|
|
78
|
+
background-color: var(--bui-color-fg-default);
|
|
79
|
+
}
|
|
69
80
|
.bui-badge-dot {
|
|
70
|
-
width: var(--dot-size);
|
|
81
|
+
width: var(--bui-badge-dot-size);
|
|
71
82
|
min-width: 0;
|
|
72
|
-
height: var(--dot-size);
|
|
83
|
+
height: var(--bui-badge-dot-size);
|
|
73
84
|
padding: 0;
|
|
74
85
|
border-radius: 100%;
|
|
75
86
|
}
|
|
76
87
|
.bui-badge-bubble {
|
|
77
|
-
border-radius: var(--bubble-border-radius);
|
|
78
|
-
padding: var(--bubble-padding);
|
|
88
|
+
border-radius: var(--bui-badge-bubble-border-radius);
|
|
89
|
+
padding: var(--bui-badge-bubble-padding);
|
|
79
90
|
}
|
|
80
91
|
.bui-badge-outlined {
|
|
81
92
|
background: var(--bui-color-bg-view);
|
|
@@ -100,6 +111,15 @@
|
|
|
100
111
|
border: 1px solid var(--bui-color-danger);
|
|
101
112
|
color: var(--bui-color-danger);
|
|
102
113
|
}
|
|
114
|
+
.bui-badge-outlined.bui-badge-light {
|
|
115
|
+
background: var(--bui-color-bg-default);
|
|
116
|
+
border: 1px solid var(--bui-color-bg-view);
|
|
117
|
+
color: var(--bui-color-bg-view);
|
|
118
|
+
}
|
|
119
|
+
.bui-badge-outlined.bui-badge-dark {
|
|
120
|
+
border: 1px solid var(--bui-color-fg-default);
|
|
121
|
+
color: var(--bui-color-fg-default);
|
|
122
|
+
}
|
|
103
123
|
.bui-badge-outlined.bui-badge-bubble {
|
|
104
|
-
border-radius: var(--bubble-border-radius);
|
|
124
|
+
border-radius: var(--bui-badge-bubble-border-radius);
|
|
105
125
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BreadcrumbProps } from './Breadcrumb.types';
|
|
3
|
-
import './
|
|
3
|
+
import './index.less';
|
|
4
4
|
declare const Breadcrumb: React.ForwardRefExoticComponent<Omit<BreadcrumbProps<"nav", {}>, "ref"> & React.RefAttributes<HTMLElement>>;
|
|
5
5
|
export default Breadcrumb;
|
|
@@ -29,7 +29,7 @@ var __objRest = (source, exclude) => {
|
|
|
29
29
|
import React from "react";
|
|
30
30
|
import clsx from "clsx";
|
|
31
31
|
import BreadcrumbItem from "./BreadcrumbItem";
|
|
32
|
-
import "./
|
|
32
|
+
import "./index.css";
|
|
33
33
|
const prefixCls = "bui-breadcrumb";
|
|
34
34
|
const Breadcrumb = /* @__PURE__ */ React.forwardRef(
|
|
35
35
|
(props, ref) => {
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
:root,
|
|
2
|
+
page,
|
|
3
|
+
xhs-page {
|
|
4
|
+
--bui-breadcrumb-margin: 0;
|
|
5
|
+
--bui-breadcrumb-padding: 0;
|
|
6
|
+
--bui-breadcrumb-color: rgba(0, 0, 0, 0.45);
|
|
7
|
+
--bui-breadcrumb-item-separator-margin: 0 8px;
|
|
8
|
+
--bui-breadcrumb-last-item-color: rgba(0, 0, 0, 0.88);
|
|
9
|
+
}
|
|
10
|
+
.bui-breadcrumb {
|
|
11
|
+
margin: var(--bui-breadcrumb-margin);
|
|
12
|
+
padding: var(--bui-breadcrumb-padding);
|
|
13
|
+
color: var(--bui-breadcrumb-color);
|
|
14
|
+
list-style: none;
|
|
15
|
+
font-size: var(--bui-text-size-1);
|
|
16
|
+
line-height: var(--bui-line-height);
|
|
17
|
+
}
|
|
18
|
+
.bui-breadcrumb-list {
|
|
19
|
+
display: flex;
|
|
20
|
+
flex-wrap: wrap;
|
|
21
|
+
margin: var(--bui-breadcrumb-margin);
|
|
22
|
+
padding: var(--bui-breadcrumb-padding);
|
|
23
|
+
list-style: none;
|
|
24
|
+
}
|
|
25
|
+
.bui-breadcrumb-list a {
|
|
26
|
+
color: var(--bui-breadcrumb-color);
|
|
27
|
+
text-decoration: none;
|
|
28
|
+
cursor: pointer;
|
|
29
|
+
}
|
|
30
|
+
.bui-breadcrumb-list li:last-child {
|
|
31
|
+
color: var(--bui-breadcrumb-last-item-color);
|
|
32
|
+
}
|
|
33
|
+
.bui-breadcrumb-item {
|
|
34
|
+
cursor: pointer;
|
|
35
|
+
}
|
|
36
|
+
.bui-breadcrumb-item-separator {
|
|
37
|
+
margin: var(--bui-breadcrumb-item-separator-margin);
|
|
38
|
+
}
|
package/es/Button/Button.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import './Button.less';
|
|
3
2
|
import { ButtonProps } from './Button.types';
|
|
3
|
+
import './index.less';
|
|
4
4
|
declare const Button: React.ForwardRefExoticComponent<Omit<ButtonProps<"button", {}>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
5
5
|
export default Button;
|
package/es/Button/Button.js
CHANGED
|
@@ -28,7 +28,7 @@ var __objRest = (source, exclude) => {
|
|
|
28
28
|
};
|
|
29
29
|
import clsx from "clsx";
|
|
30
30
|
import React from "react";
|
|
31
|
-
import "./
|
|
31
|
+
import "./index.css";
|
|
32
32
|
const prefixCls = "bui-btn";
|
|
33
33
|
const ButtonIcon = ({ children, iconPosition }) => {
|
|
34
34
|
return /* @__PURE__ */ React.createElement("span", { className: `${prefixCls}-icon-${iconPosition}` }, children);
|
|
@@ -40,10 +40,10 @@ const Button = /* @__PURE__ */ React.forwardRef(
|
|
|
40
40
|
children,
|
|
41
41
|
startIcon,
|
|
42
42
|
endIcon,
|
|
43
|
-
size,
|
|
44
|
-
variant,
|
|
43
|
+
size = "medium",
|
|
44
|
+
variant = "outlined",
|
|
45
45
|
color,
|
|
46
|
-
disabled
|
|
46
|
+
disabled = false
|
|
47
47
|
} = _a, others = __objRest(_a, [
|
|
48
48
|
"className",
|
|
49
49
|
"children",
|
|
@@ -68,7 +68,8 @@ const Button = /* @__PURE__ */ React.forwardRef(
|
|
|
68
68
|
},
|
|
69
69
|
className
|
|
70
70
|
),
|
|
71
|
-
ref
|
|
71
|
+
ref,
|
|
72
|
+
disabled
|
|
72
73
|
}, others),
|
|
73
74
|
startIcon && /* @__PURE__ */ React.createElement(ButtonIcon, { iconPosition: "start" }, startIcon),
|
|
74
75
|
children,
|
|
@@ -77,12 +78,6 @@ const Button = /* @__PURE__ */ React.forwardRef(
|
|
|
77
78
|
}
|
|
78
79
|
);
|
|
79
80
|
Button.displayName = "BuiButton";
|
|
80
|
-
Button.defaultProps = {
|
|
81
|
-
size: "medium",
|
|
82
|
-
variant: "outlined",
|
|
83
|
-
color: "default",
|
|
84
|
-
disabled: false
|
|
85
|
-
};
|
|
86
81
|
var Button_default = Button;
|
|
87
82
|
export {
|
|
88
83
|
Button_default as default
|
|
@@ -16,19 +16,20 @@ export type ButtonProps<D extends React.ElementType = 'button', P = {}> = Overri
|
|
|
16
16
|
* @default 'medium'
|
|
17
17
|
*/
|
|
18
18
|
size?: 'small' | 'medium' | 'large' | 'full';
|
|
19
|
-
/**
|
|
20
|
-
*
|
|
19
|
+
/**
|
|
20
|
+
* 按钮颜色
|
|
21
|
+
* @default 'neutral'
|
|
21
22
|
*/
|
|
22
|
-
color?: ThemeColor | '
|
|
23
|
+
color?: ThemeColor | 'vip';
|
|
23
24
|
/**
|
|
24
25
|
* 按钮类型
|
|
25
26
|
* - text: 文字按钮
|
|
26
|
-
* - outlined:
|
|
27
|
-
* - contained:
|
|
28
|
-
* -
|
|
27
|
+
* - outlined: 线框按钮
|
|
28
|
+
* - contained: 填充按钮
|
|
29
|
+
* - subtle: 柔和按钮
|
|
29
30
|
* @default 'outlined'
|
|
30
31
|
*/
|
|
31
|
-
variant?: 'outlined' | 'text' | 'contained' | '
|
|
32
|
+
variant?: 'outlined' | 'text' | 'contained' | 'subtle';
|
|
32
33
|
/**
|
|
33
34
|
* 在子元素前放在的内容
|
|
34
35
|
*/
|
|
@@ -1,27 +1,31 @@
|
|
|
1
|
+
:root,
|
|
2
|
+
page,
|
|
3
|
+
xhs-page {
|
|
4
|
+
--bui-btn-font-size: var(--bui-text-size-3);
|
|
5
|
+
--bui-btn-font-weight: var(--bui-font-weight-medium);
|
|
6
|
+
--bui-btn-border-radius: 120px;
|
|
7
|
+
--bui-btn-small-border-radius: 120px;
|
|
8
|
+
--bui-btn-large-border-radius: 120px;
|
|
9
|
+
--bui-btn-full-border-radius: 120px;
|
|
10
|
+
--bui-btn-color: var(--bui-color-fg-muted);
|
|
11
|
+
--bui-btn-background: var(--bui-color-bg-view);
|
|
12
|
+
--bui-btn-border: 0;
|
|
13
|
+
--bui-btn-height: 27px;
|
|
14
|
+
--bui-btn-small-height: 24px;
|
|
15
|
+
--bui-btn-large-height: 33px;
|
|
16
|
+
--bui-btn-full-height: 42px;
|
|
17
|
+
--bui-btn-subtle-border: 0;
|
|
18
|
+
--bui-btn-outlined-border: 1px solid var(--bui-color-neutral-4);
|
|
19
|
+
--bui-btn-disabled-opacity: 0.5;
|
|
20
|
+
--bui-btn-small-padding: 0 11px;
|
|
21
|
+
--bui-btn-padding: 0 14px;
|
|
22
|
+
--bui-btn-large-padding: 0 14px;
|
|
23
|
+
--bui-btn-full-font-size: var(--bui-title-size-4);
|
|
24
|
+
--bui-btn-full-font-family: var(--bui-font-family);
|
|
25
|
+
}
|
|
1
26
|
.bui-btn {
|
|
2
|
-
--border-radius: var(--bui-button-border-radius, 100px);
|
|
3
|
-
--text-color: var(--bui-button-text-color, var(--bui-color-fg-muted));
|
|
4
|
-
--bg-color: var(--bui-button-default-bg-color, var(--bui-color-neutral-5));
|
|
5
|
-
--border-color: var(--bui-button-border-color, var(--bui-color-neutral-4));
|
|
6
|
-
--height: var(--bui-button-height, 27px);
|
|
7
|
-
--icon-start-margin-right: var(--bui-button-icon-start-margin-right, var(--bui-spacing-xs));
|
|
8
|
-
--icon-start-margin-left: var(--bui-button-icon-start-margin-left, var(--bui-spacing-xs));
|
|
9
|
-
--default-border: var(--bui-button-default-border, 1px solid transparent);
|
|
10
|
-
--light-border: var(--bui-button-light-border, 1px solid transparent);
|
|
11
|
-
--outlined-default-border: var(--bui-button-outlined-default-border, 1px solid var(--bui-color-neutral-4));
|
|
12
|
-
--disabled-opacity: var(--bui-button-disabled-opacity, 0.5);
|
|
13
|
-
--small-padding: var(--bui-button-small-padding, 0 11px);
|
|
14
|
-
--small-height: var(--bui-button-small-height, 24px);
|
|
15
|
-
--medium-padding: var(--bui-button-medium-padding, 0 14px);
|
|
16
|
-
--large-padding: var(--bui-button-large-padding, 0 14px);
|
|
17
|
-
--large-height: var(--bui-button-large-height, 33px);
|
|
18
|
-
--full-font-size: var(--bui-button-full-font-size, var(--bui-title-size-4));
|
|
19
|
-
--full-height: var(--bui-button-full-height, 42px);
|
|
20
|
-
border: var(--default-border);
|
|
21
27
|
outline: 0;
|
|
22
|
-
background-color: transparent;
|
|
23
28
|
cursor: pointer;
|
|
24
|
-
color: var(--text-color);
|
|
25
29
|
box-sizing: border-box;
|
|
26
30
|
position: relative;
|
|
27
31
|
display: inline-flex;
|
|
@@ -29,10 +33,14 @@
|
|
|
29
33
|
align-items: center;
|
|
30
34
|
justify-content: center;
|
|
31
35
|
white-space: nowrap;
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
+
color: var(--bui-btn-color);
|
|
37
|
+
background: var(--bui-btn-background);
|
|
38
|
+
font-size: var(--bui-btn-font-size);
|
|
39
|
+
font-weight: var(--bui-btn-font-weight);
|
|
40
|
+
border: var(--bui-btn-border);
|
|
41
|
+
border-radius: var(--bui-btn-border-radius);
|
|
42
|
+
height: var(--bui-btn-height);
|
|
43
|
+
padding: var(--bui-btn-padding);
|
|
36
44
|
line-height: var(--bui-line-height);
|
|
37
45
|
font-family: var(--bui-font-family);
|
|
38
46
|
}
|
|
@@ -68,36 +76,39 @@
|
|
|
68
76
|
display: inline-flex;
|
|
69
77
|
align-self: center;
|
|
70
78
|
flex-shrink: 0;
|
|
71
|
-
margin-right: var(--
|
|
79
|
+
margin-right: var(--bui-spacing-xs);
|
|
72
80
|
}
|
|
73
81
|
.bui-btn-icon-end {
|
|
74
82
|
display: inline-flex;
|
|
75
83
|
align-self: center;
|
|
76
84
|
flex-shrink: 0;
|
|
77
|
-
margin-left: var(--
|
|
85
|
+
margin-left: var(--bui-spacing-xs);
|
|
78
86
|
}
|
|
79
87
|
.bui-btn-disabled {
|
|
80
88
|
pointer-events: none;
|
|
81
|
-
opacity: var(--disabled-opacity);
|
|
89
|
+
opacity: var(--bui-btn-disabled-opacity);
|
|
82
90
|
}
|
|
83
91
|
.bui-btn-small {
|
|
84
92
|
font-size: var(--bui-text-size-4);
|
|
85
|
-
padding: var(--small-padding);
|
|
86
|
-
height: var(--small-height);
|
|
87
|
-
|
|
88
|
-
.bui-btn-medium {
|
|
89
|
-
padding: var(--medium-padding);
|
|
90
|
-
height: var(--height);
|
|
93
|
+
padding: var(--bui-btn-small-padding);
|
|
94
|
+
height: var(--bui-btn-small-height);
|
|
95
|
+
border-radius: var(--bui-btn-small-border-radius);
|
|
91
96
|
}
|
|
92
97
|
.bui-btn-large {
|
|
93
98
|
font-size: var(--bui-text-size-2);
|
|
94
|
-
padding: var(--large-padding);
|
|
95
|
-
height: var(--large-height);
|
|
99
|
+
padding: var(--bui-btn-large-padding);
|
|
100
|
+
height: var(--bui-btn-large-height);
|
|
101
|
+
border-radius: var(--bui-btn-large-border-radius);
|
|
96
102
|
}
|
|
97
103
|
.bui-btn-full {
|
|
98
|
-
font-
|
|
104
|
+
font-family: var(--bui-btn-full-font-family);
|
|
105
|
+
font-size: var(--bui-btn-full-font-size);
|
|
99
106
|
width: 100%;
|
|
100
|
-
height: var(--full-height);
|
|
107
|
+
height: var(--bui-btn-full-height);
|
|
108
|
+
border-radius: var(--bui-btn-full-border-radius);
|
|
109
|
+
}
|
|
110
|
+
.bui-btn-text {
|
|
111
|
+
background: none;
|
|
101
112
|
}
|
|
102
113
|
.bui-btn-text.bui-btn-primary {
|
|
103
114
|
color: var(--bui-color-primary);
|
|
@@ -114,11 +125,17 @@
|
|
|
114
125
|
.bui-btn-text.bui-btn-danger {
|
|
115
126
|
color: var(--bui-color-danger);
|
|
116
127
|
}
|
|
128
|
+
.bui-btn-text.bui-btn-light {
|
|
129
|
+
color: var(--bui-color-bg-view);
|
|
130
|
+
}
|
|
131
|
+
.bui-btn-text.bui-btn-dark {
|
|
132
|
+
color: var(--bui-color-fg-default);
|
|
133
|
+
}
|
|
117
134
|
.bui-btn-text.bui-btn-vip {
|
|
118
135
|
color: var(--bui-color-vip);
|
|
119
136
|
}
|
|
120
137
|
.bui-btn-contained {
|
|
121
|
-
background
|
|
138
|
+
background: var(--bui-color-neutral-5);
|
|
122
139
|
}
|
|
123
140
|
.bui-btn-contained.bui-btn-primary {
|
|
124
141
|
color: var(--bui-color-white);
|
|
@@ -160,6 +177,14 @@
|
|
|
160
177
|
var(--bui-color-danger-start) 0%,
|
|
161
178
|
var(--bui-color-danger-end) 100%);
|
|
162
179
|
}
|
|
180
|
+
.bui-btn-contained.bui-btn-light {
|
|
181
|
+
color: var(--bui-color-fg-default);
|
|
182
|
+
background: var(--bui-color-bg-view);
|
|
183
|
+
}
|
|
184
|
+
.bui-btn-contained.bui-btn-dark {
|
|
185
|
+
color: var(--bui-color-bg-view);
|
|
186
|
+
background: var(--bui-color-fg-default);
|
|
187
|
+
}
|
|
163
188
|
.bui-btn-contained.bui-btn-vip {
|
|
164
189
|
color: #582331;
|
|
165
190
|
background-image:
|
|
@@ -169,7 +194,8 @@
|
|
|
169
194
|
var(--bui-color-vip-end) 100%);
|
|
170
195
|
}
|
|
171
196
|
.bui-btn-outlined {
|
|
172
|
-
|
|
197
|
+
background: none;
|
|
198
|
+
border: var(--bui-btn-outlined-border);
|
|
173
199
|
}
|
|
174
200
|
.bui-btn-outlined.bui-btn-primary {
|
|
175
201
|
color: var(--bui-color-primary);
|
|
@@ -191,46 +217,50 @@
|
|
|
191
217
|
color: var(--bui-color-danger);
|
|
192
218
|
border-color: var(--bui-color-danger);
|
|
193
219
|
}
|
|
220
|
+
.bui-btn-outlined.bui-btn-light {
|
|
221
|
+
color: var(--bui-color-bg-view);
|
|
222
|
+
border: 1px solid var(--bui-color-bg-view);
|
|
223
|
+
}
|
|
224
|
+
.bui-btn-outlined.bui-btn-dark {
|
|
225
|
+
color: var(--bui-color-fg-default);
|
|
226
|
+
border: 1px solid var(--bui-color-fg-default);
|
|
227
|
+
}
|
|
194
228
|
.bui-btn-outlined.bui-btn-vip {
|
|
195
229
|
color: var(--bui-color-vip);
|
|
196
230
|
border-color: var(--bui-color-vip);
|
|
197
231
|
}
|
|
198
|
-
.bui-btn-
|
|
232
|
+
.bui-btn-subtle {
|
|
199
233
|
background-image: none;
|
|
200
234
|
background-color: var(--bui-color-gray-light);
|
|
201
|
-
border: var(--
|
|
235
|
+
border: var(--bui-btn-subtle-border);
|
|
202
236
|
}
|
|
203
|
-
.bui-btn-
|
|
204
|
-
background-image: none;
|
|
205
|
-
border: var(--light-border);
|
|
237
|
+
.bui-btn-subtle.bui-btn-warning {
|
|
206
238
|
color: var(--bui-color-warning);
|
|
207
|
-
background
|
|
239
|
+
background: var(--bui-color-warning-light);
|
|
208
240
|
}
|
|
209
|
-
.bui-btn-
|
|
210
|
-
background-image: none;
|
|
211
|
-
border: var(--light-border);
|
|
241
|
+
.bui-btn-subtle.bui-btn-primary {
|
|
212
242
|
color: var(--bui-color-primary);
|
|
213
|
-
background
|
|
243
|
+
background: var(--bui-color-primary-light);
|
|
214
244
|
}
|
|
215
|
-
.bui-btn-
|
|
216
|
-
background-image: none;
|
|
217
|
-
border: var(--light-border);
|
|
245
|
+
.bui-btn-subtle.bui-btn-info {
|
|
218
246
|
color: var(--bui-color-info);
|
|
219
|
-
background
|
|
247
|
+
background: var(--bui-color-info-light);
|
|
220
248
|
}
|
|
221
|
-
.bui-btn-
|
|
222
|
-
background-image: none;
|
|
223
|
-
border: var(--light-border);
|
|
249
|
+
.bui-btn-subtle.bui-btn-success {
|
|
224
250
|
color: var(--bui-color-success);
|
|
225
|
-
background
|
|
251
|
+
background: var(--bui-color-success-light);
|
|
226
252
|
}
|
|
227
|
-
.bui-btn-
|
|
228
|
-
background-image: none;
|
|
229
|
-
border: var(--light-border);
|
|
253
|
+
.bui-btn-subtle.bui-btn-danger {
|
|
230
254
|
color: var(--bui-color-danger);
|
|
231
|
-
background
|
|
255
|
+
background: var(--bui-color-danger-light);
|
|
256
|
+
}
|
|
257
|
+
.bui-btn-subtle.bui-btn-light {
|
|
258
|
+
color: var(--bui-color-bg-view);
|
|
259
|
+
}
|
|
260
|
+
.bui-btn-subtle.bui-btn-dark {
|
|
261
|
+
color: var(--bui-color-fg-default);
|
|
232
262
|
}
|
|
233
|
-
.bui-btn-
|
|
263
|
+
.bui-btn-subtle.bui-btn-vip {
|
|
234
264
|
color: var(--bui-color-vip);
|
|
235
265
|
position: relative;
|
|
236
266
|
background-color: rgba(255, 134, 110, 0.3);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { CalendarProps } from './Calendar.types';
|
|
3
|
-
import './
|
|
3
|
+
import './index.less';
|
|
4
4
|
declare const Calendar: React.ForwardRefExoticComponent<Omit<CalendarProps<"div", {}>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
5
5
|
export default Calendar;
|
package/es/Calendar/Calendar.js
CHANGED
|
@@ -34,13 +34,11 @@ import { useDidMountEffect, useValue } from "@bifrostui/utils";
|
|
|
34
34
|
import clsx from "clsx";
|
|
35
35
|
import dayjs from "dayjs";
|
|
36
36
|
import isoWeek from "dayjs/plugin/isoWeek";
|
|
37
|
-
import customParseFormat from "dayjs/plugin/customParseFormat";
|
|
38
37
|
import React, { useMemo, useState } from "react";
|
|
39
38
|
import { formatDate, isRange, isSame } from "./utils";
|
|
40
39
|
import { useLocaleText } from "../locales";
|
|
41
|
-
import "./
|
|
40
|
+
import "./index.css";
|
|
42
41
|
dayjs.extend(isoWeek);
|
|
43
|
-
dayjs.extend(customParseFormat);
|
|
44
42
|
const classes = {
|
|
45
43
|
root: "bui-calendar",
|
|
46
44
|
handler: "bui-calendar-handler",
|
|
@@ -54,16 +52,15 @@ const Calendar = /* @__PURE__ */ React.forwardRef(
|
|
|
54
52
|
className,
|
|
55
53
|
defaultValue,
|
|
56
54
|
value,
|
|
57
|
-
minDate,
|
|
58
|
-
maxDate,
|
|
59
|
-
mode,
|
|
60
|
-
hideDaysOutsideCurrentMonth,
|
|
61
|
-
headerBarFormat,
|
|
55
|
+
minDate = dayjs(dayjs().format("YYYYMMDD")).add(0, "month").toDate(),
|
|
56
|
+
maxDate = dayjs(dayjs().format("YYYYMMDD")).add(11, "month").toDate(),
|
|
57
|
+
mode = "single",
|
|
58
|
+
hideDaysOutsideCurrentMonth = false,
|
|
59
|
+
headerBarFormat = "YYYY/MM",
|
|
62
60
|
headerBarLeftIcon,
|
|
63
61
|
headerBarRightIcon,
|
|
64
62
|
disabledDate,
|
|
65
|
-
highlightDate,
|
|
66
|
-
headerVisible = false,
|
|
63
|
+
highlightDate = "today",
|
|
67
64
|
dateRender,
|
|
68
65
|
weekRender,
|
|
69
66
|
onMonthChange,
|
|
@@ -81,7 +78,6 @@ const Calendar = /* @__PURE__ */ React.forwardRef(
|
|
|
81
78
|
"headerBarRightIcon",
|
|
82
79
|
"disabledDate",
|
|
83
80
|
"highlightDate",
|
|
84
|
-
"headerVisible",
|
|
85
81
|
"dateRender",
|
|
86
82
|
"weekRender",
|
|
87
83
|
"onMonthChange",
|
|
@@ -127,14 +123,14 @@ const Calendar = /* @__PURE__ */ React.forwardRef(
|
|
|
127
123
|
CaretLeftIcon,
|
|
128
124
|
{
|
|
129
125
|
className: `${classes.handler}-btn-icon`,
|
|
130
|
-
htmlColor: isMinMonth && "
|
|
126
|
+
htmlColor: isMinMonth && "var(--bui-color-fg-disabled)"
|
|
131
127
|
}
|
|
132
128
|
),
|
|
133
129
|
right: headerBarRightIcon ? headerBarRightIcon({ isMaxMonth }) : /* @__PURE__ */ React.createElement(
|
|
134
130
|
CaretRightIcon,
|
|
135
131
|
{
|
|
136
132
|
className: `${classes.handler}-btn-icon`,
|
|
137
|
-
htmlColor: isMaxMonth && "
|
|
133
|
+
htmlColor: isMaxMonth && "var(--bui-color-fg-disabled)"
|
|
138
134
|
}
|
|
139
135
|
)
|
|
140
136
|
};
|
|
@@ -296,7 +292,7 @@ const Calendar = /* @__PURE__ */ React.forwardRef(
|
|
|
296
292
|
}, others), {
|
|
297
293
|
"data-mode": mode
|
|
298
294
|
}), data),
|
|
299
|
-
|
|
295
|
+
/* @__PURE__ */ React.createElement("div", { className: classes.handler }, /* @__PURE__ */ React.createElement("div", { onClick: onClickPrev, className: `${classes.handler}-btn` }, headerBarIcon.left), /* @__PURE__ */ React.createElement("div", { className: `${classes.handler}-text` }, dayjs(renderMonth).format(headerBarFormat)), /* @__PURE__ */ React.createElement("div", { onClick: onClickNext, className: `${classes.handler}-btn` }, headerBarIcon.right)),
|
|
300
296
|
/* @__PURE__ */ React.createElement("div", { className: classes.week }, SUNDAY_WEEK_DATA == null ? void 0 : SUNDAY_WEEK_DATA.map((w) => {
|
|
301
297
|
return weekRender ? weekRender(w) : /* @__PURE__ */ React.createElement("div", { key: w, className: `${classes.week}-item` }, w);
|
|
302
298
|
})),
|
|
@@ -305,14 +301,6 @@ const Calendar = /* @__PURE__ */ React.forwardRef(
|
|
|
305
301
|
}
|
|
306
302
|
);
|
|
307
303
|
Calendar.displayName = "BuiCalendar";
|
|
308
|
-
Calendar.defaultProps = {
|
|
309
|
-
hideDaysOutsideCurrentMonth: false,
|
|
310
|
-
headerBarFormat: "YYYY/MM",
|
|
311
|
-
mode: "single",
|
|
312
|
-
minDate: dayjs(dayjs().format("YYYYMMDD")).add(0, "month").toDate(),
|
|
313
|
-
maxDate: dayjs(dayjs().format("YYYYMMDD")).add(11, "month").toDate(),
|
|
314
|
-
highlightDate: "today"
|
|
315
|
-
};
|
|
316
304
|
var Calendar_default = Calendar;
|
|
317
305
|
export {
|
|
318
306
|
Calendar_default as default
|