@bifrostui/react 2.0.0-alpha.11 → 2.0.0-alpha.13
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.d.ts +1 -1
- package/dist/ActionSheet/ActionSheet.js +8 -8
- package/dist/ActionSheet/ActionSheet.types.d.ts +1 -1
- package/dist/ActionSheet/ActionSheetContext.d.ts +1 -1
- package/dist/ActionSheet/ActionSheetContext.js +2 -2
- package/dist/ActionSheet/ActionSheetItem.types.d.ts +1 -1
- package/dist/Alert/Alert.d.ts +1 -1
- package/dist/Alert/Alert.js +16 -16
- package/dist/Alert/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Alert/__tests__/fixtures/A11yDemos.js +12 -12
- package/dist/Avatar/Avatar.d.ts +1 -1
- package/dist/Avatar/Avatar.js +5 -5
- package/dist/Avatar/Avatar.types.d.ts +1 -1
- package/dist/Avatar/AvatarGroup.types.d.ts +1 -1
- package/dist/Backdrop/Backdrop.d.ts +1 -1
- package/dist/Backdrop/Backdrop.js +3 -3
- package/dist/Backdrop/Backdrop.types.d.ts +1 -1
- package/dist/Backdrop/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Backdrop/__tests__/fixtures/A11yDemos.js +3 -3
- package/dist/Badge/Badge.d.ts +1 -1
- package/dist/Badge/Badge.js +4 -4
- package/dist/Badge/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Badge/__tests__/fixtures/A11yDemos.js +13 -13
- package/dist/Breadcrumb/Breadcrumb.d.ts +1 -1
- package/dist/Breadcrumb/Breadcrumb.js +9 -9
- package/dist/Breadcrumb/Breadcrumb.types.d.ts +1 -1
- package/dist/Breadcrumb/BreadcrumbItem.d.ts +1 -1
- package/dist/Breadcrumb/BreadcrumbItem.js +4 -4
- package/dist/Button/Button.d.ts +1 -1
- package/dist/Button/Button.js +6 -6
- package/dist/Button/Button.types.d.ts +1 -1
- package/dist/Button/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Button/__tests__/fixtures/A11yDemos.js +8 -8
- package/dist/Calendar/Calendar.types.d.ts +1 -1
- package/dist/Calendar/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Calendar/__tests__/fixtures/A11yDemos.js +2 -2
- package/dist/Card/Card.d.ts +1 -1
- package/dist/Card/Card.js +3 -3
- package/dist/Card/Card.types.d.ts +1 -1
- package/dist/Card/CardContent.d.ts +1 -1
- package/dist/Card/CardContent.js +3 -3
- package/dist/Card/CardContent.types.d.ts +1 -1
- package/dist/Card/CardFooter.d.ts +1 -1
- package/dist/Card/CardFooter.js +3 -3
- package/dist/Card/CardFooter.types.d.ts +1 -1
- package/dist/Card/CardHeader.d.ts +1 -1
- package/dist/Card/CardHeader.js +10 -10
- package/dist/Checkbox/CheckboxContext.d.ts +1 -1
- package/dist/Checkbox/CheckboxContext.js +2 -2
- package/dist/Checkbox/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Checkbox/__tests__/fixtures/A11yDemos.js +4 -4
- package/dist/CitySelector/CitySelector.types.d.ts +1 -0
- package/dist/CitySelector/Selector/index.d.ts +1 -1
- package/dist/CitySelector/Selector/index.js +2 -2
- package/dist/Collapse/Collapse.types.d.ts +1 -1
- package/dist/CollapsePanel/CollapsePanel.d.ts +1 -1
- package/dist/CollapsePanel/CollapsePanel.js +9 -9
- package/dist/CollapsePanel/CollapsePanel.types.d.ts +1 -1
- package/dist/CollapsePanel/CollapsePanelItem.d.ts +1 -1
- package/dist/CollapsePanel/CollapsePanelItem.js +5 -5
- package/dist/Countdown/Countdown.types.d.ts +2 -2
- package/dist/Countdown/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Countdown/__tests__/fixtures/A11yDemos.js +10 -10
- package/dist/Countdown/utils.d.ts +2 -2
- package/dist/Countdown/utils.js +4 -4
- package/dist/DatePicker/DatePicker.types.d.ts +1 -1
- package/dist/DesktopPicker/DesktopPicker.types.d.ts +1 -1
- package/dist/DesktopTimePicker/DesktopTimePicker.types.d.ts +11 -11
- package/dist/DesktopTimePicker/useGetTimePickerContent.js +2 -2
- package/dist/DesktopTimePicker/utils/utils.d.ts +1 -1
- package/dist/DesktopTimePicker/utils/utils.js +3 -3
- package/dist/Dialog/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Dialog/__tests__/fixtures/A11yDemos.js +4 -4
- package/dist/Divider/Divider.types.d.ts +1 -1
- package/dist/Drawer/Drawer.d.ts +1 -1
- package/dist/Drawer/Drawer.js +5 -5
- package/dist/Drawer/Drawer.types.d.ts +1 -1
- package/dist/Fade/Fade.d.ts +1 -1
- package/dist/Fade/Fade.js +4 -4
- package/dist/Fade/Fade.types.d.ts +1 -1
- package/dist/IconButton/IconButton.d.ts +1 -1
- package/dist/IconButton/IconButton.js +6 -6
- package/dist/IconButton/IconButton.types.d.ts +1 -1
- package/dist/Input/Input.types.d.ts +1 -1
- package/dist/Input/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Input/__tests__/fixtures/A11yDemos.js +7 -7
- package/dist/ItemSelector/ItemSelector.miniapp.js +7 -5
- package/dist/ItemSelector/ItemSelector.types.d.ts +1 -0
- package/dist/ItemSelector/Selector/index.d.ts +1 -1
- package/dist/ItemSelector/Selector/index.js +2 -2
- package/dist/List/List.d.ts +1 -1
- package/dist/List/List.js +4 -4
- package/dist/List/ListContext.d.ts +1 -1
- package/dist/List/ListContext.js +2 -2
- package/dist/List/ListItem.d.ts +1 -1
- package/dist/List/ListItem.js +8 -8
- package/dist/List/ListItem.types.d.ts +1 -1
- package/dist/List/ListItemContent.d.ts +1 -1
- package/dist/List/ListItemContent.js +3 -3
- package/dist/List/ListItemContent.types.d.ts +1 -1
- package/dist/List/ListItemExtra.d.ts +1 -1
- package/dist/List/ListItemExtra.js +3 -3
- package/dist/List/ListItemExtra.types.d.ts +1 -1
- package/dist/List/ListItemFooter.d.ts +1 -1
- package/dist/List/ListItemFooter.js +3 -3
- package/dist/List/ListItemFooter.types.d.ts +1 -1
- package/dist/List/ListItemHeader.d.ts +1 -1
- package/dist/List/ListItemHeader.js +3 -3
- package/dist/List/ListItemHeader.types.d.ts +1 -1
- package/dist/Loading/Loading.d.ts +1 -1
- package/dist/Loading/Loading.js +5 -5
- package/dist/Loading/Loading.types.d.ts +1 -1
- package/dist/Modal/Modal.d.ts +1 -1
- package/dist/Modal/Modal.js +6 -6
- package/dist/Modal/Modal.miniapp.d.ts +1 -1
- package/dist/Modal/Modal.miniapp.js +7 -7
- package/dist/Modal/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Modal/__tests__/fixtures/A11yDemos.js +3 -3
- package/dist/Modal/useModal.js +26 -29
- package/dist/NavBar/NavBar.d.ts +1 -1
- package/dist/NavBar/NavBar.js +10 -10
- package/dist/Picker/Picker.js +0 -1
- package/dist/Picker/Picker.types.d.ts +1 -1
- package/dist/Picker/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Picker/__tests__/fixtures/A11yDemos.js +2 -2
- package/dist/Popover/Popover.d.ts +1 -1
- package/dist/Popover/Popover.js +8 -8
- package/dist/Popover/Popover.types.d.ts +1 -1
- package/dist/Popover/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Popover/__tests__/fixtures/A11yDemos.js +21 -21
- package/dist/Portal/Portal.d.ts +1 -1
- package/dist/Portal/Portal.js +3 -3
- package/dist/Portal/Portal.types.d.ts +1 -1
- package/dist/Progress/Progress.d.ts +1 -1
- package/dist/Progress/Progress.js +4 -4
- package/dist/Progress/Progress.types.d.ts +1 -1
- package/dist/Progress/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Progress/__tests__/fixtures/A11yDemos.js +9 -9
- package/dist/Radio/RadioButtonIcon.d.ts +1 -1
- package/dist/Radio/RadioButtonIcon.js +4 -4
- package/dist/Radio/RadioContext.d.ts +1 -1
- package/dist/Radio/RadioContext.js +2 -2
- package/dist/Radio/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Radio/__tests__/fixtures/A11yDemos.js +4 -4
- package/dist/Rating/Rating.types.d.ts +1 -1
- package/dist/ScrollView/ScrollView.types.d.ts +1 -1
- package/dist/ScrollView/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/ScrollView/__tests__/fixtures/A11yDemos.js +30 -30
- package/dist/ScrollView/useScrollView.js +16 -4
- package/dist/Skeleton/Skeleton.d.ts +1 -1
- package/dist/Skeleton/Skeleton.js +3 -3
- package/dist/Skeleton/Skeleton.types.d.ts +1 -1
- package/dist/Slide/Slide.d.ts +1 -1
- package/dist/Slide/Slide.js +4 -4
- package/dist/Slider/Slider.types.d.ts +1 -1
- package/dist/Steps/Step.types.d.ts +1 -1
- package/dist/Steps/StepsContext.d.ts +1 -1
- package/dist/Steps/StepsContext.js +2 -2
- package/dist/SwipeAction/SwipeAction.js +7 -8
- package/dist/SwipeAction/SwipeAction.types.d.ts +1 -1
- package/dist/Swiper/Swiper.types.d.ts +1 -1
- package/dist/Swiper/SwiperItem.d.ts +1 -1
- package/dist/Swiper/SwiperItem.js +2 -2
- package/dist/Switch/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Switch/__tests__/fixtures/A11yDemos.js +4 -4
- package/dist/TabBar/TabBar.d.ts +1 -1
- package/dist/TabBar/TabBar.js +5 -5
- package/dist/Tabs/Tab.css +1 -22
- package/dist/Tabs/Tab.d.ts +2 -2
- package/dist/Tabs/Tab.js +42 -34
- package/dist/Tabs/Tab.types.d.ts +1 -1
- package/dist/Tabs/TabIndicator.d.ts +13 -0
- package/dist/Tabs/TabIndicator.js +115 -0
- package/dist/Tabs/TabMask.d.ts +9 -0
- package/dist/Tabs/TabMask.js +88 -0
- package/dist/Tabs/TabPanel.types.d.ts +1 -1
- package/dist/Tabs/Tabs.css +15 -5
- package/dist/Tabs/Tabs.js +84 -159
- package/dist/Tabs/Tabs.types.d.ts +5 -6
- package/dist/Tabs/TabsContext.d.ts +15 -6
- package/dist/Tabs/TabsContext.js +6 -14
- package/dist/Tabs/classes.d.ts +10 -0
- package/dist/Tabs/classes.js +54 -0
- package/dist/Tabs/index.css +16 -27
- package/dist/Tabs/index.d.ts +2 -2
- package/dist/Tabs/index.js +4 -4
- package/dist/Tabs/index.miniapp.d.ts +5 -0
- package/dist/Tabs/index.miniapp.js +50 -0
- package/dist/Tabs/miniapp/Tab.d.ts +5 -0
- package/dist/Tabs/miniapp/Tab.js +104 -0
- package/dist/Tabs/miniapp/TabIndicator.d.ts +15 -0
- package/dist/Tabs/miniapp/TabIndicator.js +207 -0
- package/dist/Tabs/miniapp/TabMask.d.ts +13 -0
- package/dist/Tabs/miniapp/TabMask.js +67 -0
- package/dist/Tabs/miniapp/Tabs.d.ts +5 -0
- package/dist/Tabs/miniapp/Tabs.js +261 -0
- package/dist/Tabs/miniapp/TabsContext.d.ts +17 -0
- package/dist/Tabs/miniapp/TabsContext.js +39 -0
- package/dist/Tabs/miniapp/index.d.ts +2 -0
- package/dist/Tabs/miniapp/index.js +41 -0
- package/dist/Tabs/miniapp/scroll.d.ts +21 -0
- package/dist/Tabs/miniapp/scroll.js +52 -0
- package/dist/Tabs/miniapp/utils/queryBatch.d.ts +68 -0
- package/dist/Tabs/miniapp/utils/queryBatch.js +100 -0
- package/dist/Tabs/utils/scroll.js +10 -4
- package/dist/Tag/Tag.d.ts +1 -1
- package/dist/Tag/Tag.js +6 -6
- package/dist/Tag/Tag.types.d.ts +1 -1
- package/dist/Tag/TagGroup.d.ts +1 -1
- package/dist/Tag/TagGroup.js +3 -3
- package/dist/Tag/TagGroup.types.d.ts +1 -1
- package/dist/Tag/__tests__/fixtures/A11yDemos.js +3 -3
- package/dist/TextArea/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/TextArea/__tests__/fixtures/A11yDemos.js +6 -6
- package/dist/ThemeProvider/hooks/ThemeContext.d.ts +1 -1
- package/dist/ThemeProvider/hooks/ThemeContext.js +2 -2
- package/dist/ThemeProvider/hooks/useTheme.js +2 -2
- package/dist/ThemeProvider/utils/mountTokens.js +2 -2
- package/dist/Toast/Toast.d.ts +1 -1
- package/dist/Toast/Toast.js +8 -8
- package/dist/Toast/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Toast/__tests__/fixtures/A11yDemos.js +2 -2
- package/dist/Tooltip/Tooltip.d.ts +1 -1
- package/dist/Tooltip/Tooltip.js +5 -5
- package/dist/Tooltip/Tooltip.types.d.ts +1 -1
- package/dist/Tooltip/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/dist/Tooltip/__tests__/fixtures/A11yDemos.js +14 -14
- package/dist/Transition/Transition.d.ts +1 -1
- package/dist/Transition/Transition.js +3 -3
- package/dist/Transition/Transition.miniapp.d.ts +1 -1
- package/dist/Transition/Transition.miniapp.js +3 -3
- package/dist/Transition/TransitionCore.js +8 -2
- package/dist/_.._/benchmarks/components/Button.d.js +15 -0
- package/dist/_.._/benchmarks/components/Button.js +2 -2
- package/dist/_.._/benchmarks/components/Input.d.js +15 -0
- package/dist/_.._/benchmarks/components/Tabs.d.js +15 -0
- package/es/ActionSheet/ActionSheet.d.ts +1 -1
- package/es/ActionSheet/ActionSheet.js +1 -1
- package/es/ActionSheet/ActionSheet.types.d.ts +1 -1
- package/es/ActionSheet/ActionSheetContext.d.ts +1 -1
- package/es/ActionSheet/ActionSheetContext.js +1 -1
- package/es/ActionSheet/ActionSheetItem.types.d.ts +1 -1
- package/es/Alert/Alert.d.ts +1 -1
- package/es/Alert/Alert.js +1 -1
- package/es/Alert/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Alert/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Avatar/Avatar.d.ts +1 -1
- package/es/Avatar/Avatar.js +1 -1
- package/es/Avatar/Avatar.types.d.ts +1 -1
- package/es/Avatar/AvatarGroup.types.d.ts +1 -1
- package/es/Backdrop/Backdrop.d.ts +1 -1
- package/es/Backdrop/Backdrop.js +1 -1
- package/es/Backdrop/Backdrop.types.d.ts +1 -1
- package/es/Backdrop/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Backdrop/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Badge/Badge.d.ts +1 -1
- package/es/Badge/Badge.js +1 -1
- package/es/Badge/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Badge/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Breadcrumb/Breadcrumb.d.ts +1 -1
- package/es/Breadcrumb/Breadcrumb.js +1 -1
- package/es/Breadcrumb/Breadcrumb.types.d.ts +1 -1
- package/es/Breadcrumb/BreadcrumbItem.d.ts +1 -1
- package/es/Breadcrumb/BreadcrumbItem.js +1 -1
- package/es/Button/Button.d.ts +1 -1
- package/es/Button/Button.js +1 -1
- package/es/Button/Button.types.d.ts +1 -1
- package/es/Button/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Button/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Calendar/Calendar.types.d.ts +1 -1
- package/es/Calendar/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Calendar/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Card/Card.d.ts +1 -1
- package/es/Card/Card.js +1 -1
- package/es/Card/Card.types.d.ts +1 -1
- package/es/Card/CardContent.d.ts +1 -1
- package/es/Card/CardContent.js +1 -1
- package/es/Card/CardContent.types.d.ts +1 -1
- package/es/Card/CardFooter.d.ts +1 -1
- package/es/Card/CardFooter.js +1 -1
- package/es/Card/CardFooter.types.d.ts +1 -1
- package/es/Card/CardHeader.d.ts +1 -1
- package/es/Card/CardHeader.js +1 -1
- package/es/Checkbox/CheckboxContext.d.ts +1 -1
- package/es/Checkbox/CheckboxContext.js +1 -1
- package/es/Checkbox/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Checkbox/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/CitySelector/CitySelector.types.d.ts +1 -0
- package/es/CitySelector/Selector/index.d.ts +1 -1
- package/es/CitySelector/Selector/index.js +1 -1
- package/es/Collapse/Collapse.types.d.ts +1 -1
- package/es/CollapsePanel/CollapsePanel.d.ts +1 -1
- package/es/CollapsePanel/CollapsePanel.js +1 -1
- package/es/CollapsePanel/CollapsePanel.types.d.ts +1 -1
- package/es/CollapsePanel/CollapsePanelItem.d.ts +1 -1
- package/es/CollapsePanel/CollapsePanelItem.js +1 -1
- package/es/Countdown/Countdown.types.d.ts +2 -2
- package/es/Countdown/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Countdown/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Countdown/utils.d.ts +2 -2
- package/es/Countdown/utils.js +4 -4
- package/es/DatePicker/DatePicker.d.ts +1 -1
- package/es/DatePicker/DatePicker.types.d.ts +1 -1
- package/es/DesktopPicker/DesktopPicker.types.d.ts +1 -1
- package/es/DesktopTimePicker/DesktopTimePicker.types.d.ts +11 -11
- package/es/DesktopTimePicker/useGetTimePickerContent.js +3 -3
- package/es/DesktopTimePicker/utils/utils.d.ts +1 -1
- package/es/DesktopTimePicker/utils/utils.js +2 -2
- package/es/Dialog/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Dialog/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Divider/Divider.types.d.ts +1 -1
- package/es/Drawer/Drawer.d.ts +1 -1
- package/es/Drawer/Drawer.js +1 -1
- package/es/Drawer/Drawer.types.d.ts +1 -1
- package/es/Fade/Fade.d.ts +1 -1
- package/es/Fade/Fade.js +1 -1
- package/es/Fade/Fade.types.d.ts +1 -1
- package/es/IconButton/IconButton.d.ts +1 -1
- package/es/IconButton/IconButton.js +1 -1
- package/es/IconButton/IconButton.types.d.ts +1 -1
- package/es/Input/Input.types.d.ts +1 -1
- package/es/Input/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Input/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/ItemSelector/ItemSelector.miniapp.js +7 -5
- package/es/ItemSelector/ItemSelector.types.d.ts +1 -0
- package/es/ItemSelector/Selector/index.d.ts +1 -1
- package/es/ItemSelector/Selector/index.js +1 -1
- package/es/List/List.d.ts +1 -1
- package/es/List/List.js +1 -1
- package/es/List/ListContext.d.ts +1 -1
- package/es/List/ListContext.js +1 -1
- package/es/List/ListItem.d.ts +1 -1
- package/es/List/ListItem.js +1 -1
- package/es/List/ListItem.types.d.ts +1 -1
- package/es/List/ListItemContent.d.ts +1 -1
- package/es/List/ListItemContent.js +1 -1
- package/es/List/ListItemContent.types.d.ts +1 -1
- package/es/List/ListItemExtra.d.ts +1 -1
- package/es/List/ListItemExtra.js +1 -1
- package/es/List/ListItemExtra.types.d.ts +1 -1
- package/es/List/ListItemFooter.d.ts +1 -1
- package/es/List/ListItemFooter.js +1 -1
- package/es/List/ListItemFooter.types.d.ts +1 -1
- package/es/List/ListItemHeader.d.ts +1 -1
- package/es/List/ListItemHeader.js +1 -1
- package/es/List/ListItemHeader.types.d.ts +1 -1
- package/es/Loading/Loading.d.ts +1 -1
- package/es/Loading/Loading.js +1 -1
- package/es/Loading/Loading.types.d.ts +1 -1
- package/es/Modal/Modal.d.ts +1 -1
- package/es/Modal/Modal.js +1 -1
- package/es/Modal/Modal.miniapp.d.ts +2 -2
- package/es/Modal/Modal.miniapp.js +1 -1
- package/es/Modal/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Modal/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Modal/useModal.js +26 -29
- package/es/NavBar/NavBar.d.ts +1 -1
- package/es/NavBar/NavBar.js +1 -1
- package/es/Picker/Picker.js +0 -1
- package/es/Picker/Picker.types.d.ts +1 -1
- package/es/Picker/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Picker/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Popover/Popover.d.ts +1 -1
- package/es/Popover/Popover.js +1 -1
- package/es/Popover/Popover.types.d.ts +1 -1
- package/es/Popover/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Popover/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Portal/Portal.d.ts +1 -1
- package/es/Portal/Portal.js +1 -1
- package/es/Portal/Portal.types.d.ts +1 -1
- package/es/Progress/Progress.d.ts +1 -1
- package/es/Progress/Progress.js +1 -1
- package/es/Progress/Progress.types.d.ts +1 -1
- package/es/Progress/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Progress/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Radio/RadioButtonIcon.d.ts +1 -1
- package/es/Radio/RadioButtonIcon.js +1 -1
- package/es/Radio/RadioContext.d.ts +1 -1
- package/es/Radio/RadioContext.js +1 -1
- package/es/Radio/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Radio/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Rating/Rating.types.d.ts +1 -1
- package/es/ScrollView/ScrollView.types.d.ts +1 -1
- package/es/ScrollView/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/ScrollView/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/ScrollView/useScrollView.js +16 -4
- package/es/Skeleton/Skeleton.d.ts +1 -1
- package/es/Skeleton/Skeleton.js +1 -1
- package/es/Skeleton/Skeleton.types.d.ts +1 -1
- package/es/Slide/Slide.d.ts +1 -1
- package/es/Slide/Slide.js +1 -1
- package/es/Slider/Slider.types.d.ts +1 -1
- package/es/Steps/Step.types.d.ts +1 -1
- package/es/Steps/StepsContext.d.ts +1 -1
- package/es/Steps/StepsContext.js +1 -1
- package/es/SwipeAction/SwipeAction.js +7 -8
- package/es/SwipeAction/SwipeAction.types.d.ts +1 -1
- package/es/Swiper/Swiper.js +5 -1
- package/es/Swiper/Swiper.types.d.ts +1 -1
- package/es/Swiper/SwiperItem.d.ts +1 -1
- package/es/Swiper/SwiperItem.js +1 -1
- package/es/Switch/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Switch/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/TabBar/TabBar.d.ts +1 -1
- package/es/TabBar/TabBar.js +1 -1
- package/es/Tabs/Tab.css +1 -22
- package/es/Tabs/Tab.d.ts +2 -2
- package/es/Tabs/Tab.js +44 -36
- package/es/Tabs/Tab.types.d.ts +1 -1
- package/es/Tabs/TabIndicator.d.ts +13 -0
- package/es/Tabs/TabIndicator.js +86 -0
- package/es/Tabs/TabMask.d.ts +9 -0
- package/es/Tabs/TabMask.js +59 -0
- package/es/Tabs/TabPanel.types.d.ts +1 -1
- package/es/Tabs/Tabs.css +15 -5
- package/es/Tabs/Tabs.js +86 -161
- package/es/Tabs/Tabs.types.d.ts +5 -6
- package/es/Tabs/TabsContext.d.ts +15 -6
- package/es/Tabs/TabsContext.js +6 -4
- package/es/Tabs/classes.d.ts +10 -0
- package/es/Tabs/classes.js +22 -0
- package/es/Tabs/index.css +16 -27
- package/es/Tabs/index.d.ts +2 -2
- package/es/Tabs/index.js +2 -2
- package/es/Tabs/index.miniapp.d.ts +5 -0
- package/es/Tabs/index.miniapp.js +11 -0
- package/es/Tabs/miniapp/Tab.d.ts +5 -0
- package/es/Tabs/miniapp/Tab.js +75 -0
- package/es/Tabs/miniapp/TabIndicator.d.ts +15 -0
- package/es/Tabs/miniapp/TabIndicator.js +178 -0
- package/es/Tabs/miniapp/TabMask.d.ts +13 -0
- package/es/Tabs/miniapp/TabMask.js +38 -0
- package/es/Tabs/miniapp/Tabs.d.ts +5 -0
- package/es/Tabs/miniapp/Tabs.js +239 -0
- package/es/Tabs/miniapp/TabsContext.d.ts +17 -0
- package/es/Tabs/miniapp/TabsContext.js +16 -0
- package/es/Tabs/miniapp/index.d.ts +2 -0
- package/es/Tabs/miniapp/index.js +7 -0
- package/es/Tabs/miniapp/scroll.d.ts +21 -0
- package/es/Tabs/miniapp/scroll.js +29 -0
- package/es/Tabs/miniapp/utils/queryBatch.d.ts +68 -0
- package/es/Tabs/miniapp/utils/queryBatch.js +65 -0
- package/es/Tabs/utils/scroll.js +10 -4
- package/es/Tag/Tag.d.ts +1 -1
- package/es/Tag/Tag.js +4 -4
- package/es/Tag/Tag.types.d.ts +1 -1
- package/es/Tag/TagGroup.d.ts +1 -1
- package/es/Tag/TagGroup.js +1 -1
- package/es/Tag/TagGroup.types.d.ts +1 -1
- package/es/Tag/__tests__/fixtures/A11yDemos.js +3 -3
- package/es/TextArea/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/TextArea/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/ThemeProvider/hooks/ThemeContext.d.ts +1 -1
- package/es/ThemeProvider/hooks/ThemeContext.js +1 -1
- package/es/ThemeProvider/hooks/useTheme.js +1 -1
- package/es/ThemeProvider/utils/mountTokens.js +1 -1
- package/es/Toast/Toast.d.ts +1 -1
- package/es/Toast/Toast.js +1 -1
- package/es/Toast/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Toast/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Tooltip/Tooltip.d.ts +1 -1
- package/es/Tooltip/Tooltip.js +1 -1
- package/es/Tooltip/Tooltip.types.d.ts +1 -1
- package/es/Tooltip/__tests__/fixtures/A11yDemos.d.ts +1 -1
- package/es/Tooltip/__tests__/fixtures/A11yDemos.js +1 -1
- package/es/Transition/Transition.d.ts +1 -1
- package/es/Transition/Transition.js +1 -1
- package/es/Transition/Transition.miniapp.d.ts +1 -1
- package/es/Transition/Transition.miniapp.js +1 -1
- package/es/Transition/TransitionCore.js +8 -2
- package/es/_.._/benchmarks/components/Button.d.js +0 -0
- package/es/_.._/benchmarks/components/Button.js +1 -1
- package/es/_.._/benchmarks/components/Input.d.js +0 -0
- package/es/_.._/benchmarks/components/Tabs.d.js +0 -0
- package/package.json +7 -6
|
@@ -52,10 +52,10 @@ __export(A11yDemos_exports, {
|
|
|
52
52
|
ThresholdTestDemo: () => ThresholdTestDemo
|
|
53
53
|
});
|
|
54
54
|
module.exports = __toCommonJS(A11yDemos_exports);
|
|
55
|
-
var
|
|
55
|
+
var React = __toESM(require("react"));
|
|
56
56
|
var import_ScrollView = __toESM(require("../../ScrollView"));
|
|
57
57
|
const BasicScrollViewDemo = () => {
|
|
58
|
-
return /* @__PURE__ */
|
|
58
|
+
return /* @__PURE__ */ React.createElement(import_ScrollView.default, { scrollY: true, style: { height: "300px", width: "100%" } }, Array.from({ length: 50 }, (_, index) => /* @__PURE__ */ React.createElement(
|
|
59
59
|
"div",
|
|
60
60
|
{
|
|
61
61
|
key: index,
|
|
@@ -66,7 +66,7 @@ const BasicScrollViewDemo = () => {
|
|
|
66
66
|
)));
|
|
67
67
|
};
|
|
68
68
|
const HorizontalScrollViewDemo = () => {
|
|
69
|
-
return /* @__PURE__ */
|
|
69
|
+
return /* @__PURE__ */ React.createElement(import_ScrollView.default, { scrollX: true, style: { width: "300px" } }, /* @__PURE__ */ React.createElement("div", { style: { display: "flex", width: "max-content" } }, Array.from({ length: 20 }, (_, index) => /* @__PURE__ */ React.createElement(
|
|
70
70
|
"div",
|
|
71
71
|
{
|
|
72
72
|
key: index,
|
|
@@ -86,7 +86,7 @@ const HorizontalScrollViewDemo = () => {
|
|
|
86
86
|
))));
|
|
87
87
|
};
|
|
88
88
|
const ScrollEventsDemo = () => {
|
|
89
|
-
const [scrollInfo, setScrollInfo] =
|
|
89
|
+
const [scrollInfo, setScrollInfo] = React.useState({
|
|
90
90
|
scrollTop: 0,
|
|
91
91
|
atTop: false,
|
|
92
92
|
atBottom: false
|
|
@@ -105,7 +105,7 @@ const ScrollEventsDemo = () => {
|
|
|
105
105
|
const handleScrollToLower = () => {
|
|
106
106
|
setScrollInfo((prev) => __spreadProps(__spreadValues({}, prev), { atTop: false, atBottom: true }));
|
|
107
107
|
};
|
|
108
|
-
return /* @__PURE__ */
|
|
108
|
+
return /* @__PURE__ */ React.createElement("div", null, /* @__PURE__ */ React.createElement(
|
|
109
109
|
"div",
|
|
110
110
|
{
|
|
111
111
|
"data-testid": "scroll-info",
|
|
@@ -115,10 +115,10 @@ const ScrollEventsDemo = () => {
|
|
|
115
115
|
backgroundColor: "#f9f9f9"
|
|
116
116
|
}
|
|
117
117
|
},
|
|
118
|
-
/* @__PURE__ */
|
|
119
|
-
/* @__PURE__ */
|
|
120
|
-
/* @__PURE__ */
|
|
121
|
-
), /* @__PURE__ */
|
|
118
|
+
/* @__PURE__ */ React.createElement("p", null, "Scroll Top: ", scrollInfo.scrollTop),
|
|
119
|
+
/* @__PURE__ */ React.createElement("p", null, "At Top: ", scrollInfo.atTop ? "Yes" : "No"),
|
|
120
|
+
/* @__PURE__ */ React.createElement("p", null, "At Bottom: ", scrollInfo.atBottom ? "Yes" : "No")
|
|
121
|
+
), /* @__PURE__ */ React.createElement(
|
|
122
122
|
import_ScrollView.default,
|
|
123
123
|
{
|
|
124
124
|
scrollY: true,
|
|
@@ -129,7 +129,7 @@ const ScrollEventsDemo = () => {
|
|
|
129
129
|
upperThreshold: 30,
|
|
130
130
|
lowerThreshold: 30
|
|
131
131
|
},
|
|
132
|
-
Array.from({ length: 30 }, (_, index) => /* @__PURE__ */
|
|
132
|
+
Array.from({ length: 30 }, (_, index) => /* @__PURE__ */ React.createElement(
|
|
133
133
|
"div",
|
|
134
134
|
{
|
|
135
135
|
key: index,
|
|
@@ -141,8 +141,8 @@ const ScrollEventsDemo = () => {
|
|
|
141
141
|
));
|
|
142
142
|
};
|
|
143
143
|
const ControlledScrollDemo = () => {
|
|
144
|
-
const [scrollTop, setScrollTop] =
|
|
145
|
-
const [scrollIntoView, setScrollIntoView] =
|
|
144
|
+
const [scrollTop, setScrollTop] = React.useState(0);
|
|
145
|
+
const [scrollIntoView, setScrollIntoView] = React.useState("");
|
|
146
146
|
const scrollToPosition = (position) => {
|
|
147
147
|
setScrollIntoView("");
|
|
148
148
|
setScrollTop(position);
|
|
@@ -151,7 +151,7 @@ const ControlledScrollDemo = () => {
|
|
|
151
151
|
setScrollTop(0);
|
|
152
152
|
setScrollIntoView(elementId);
|
|
153
153
|
};
|
|
154
|
-
return /* @__PURE__ */
|
|
154
|
+
return /* @__PURE__ */ React.createElement("div", null, /* @__PURE__ */ React.createElement(
|
|
155
155
|
"div",
|
|
156
156
|
{
|
|
157
157
|
style: {
|
|
@@ -160,7 +160,7 @@ const ControlledScrollDemo = () => {
|
|
|
160
160
|
backgroundColor: "#f5f5f5"
|
|
161
161
|
}
|
|
162
162
|
},
|
|
163
|
-
/* @__PURE__ */
|
|
163
|
+
/* @__PURE__ */ React.createElement(
|
|
164
164
|
"button",
|
|
165
165
|
{
|
|
166
166
|
type: "button",
|
|
@@ -169,7 +169,7 @@ const ControlledScrollDemo = () => {
|
|
|
169
169
|
},
|
|
170
170
|
"Top"
|
|
171
171
|
),
|
|
172
|
-
/* @__PURE__ */
|
|
172
|
+
/* @__PURE__ */ React.createElement(
|
|
173
173
|
"button",
|
|
174
174
|
{
|
|
175
175
|
type: "button",
|
|
@@ -178,7 +178,7 @@ const ControlledScrollDemo = () => {
|
|
|
178
178
|
},
|
|
179
179
|
"200px"
|
|
180
180
|
),
|
|
181
|
-
/* @__PURE__ */
|
|
181
|
+
/* @__PURE__ */ React.createElement(
|
|
182
182
|
"button",
|
|
183
183
|
{
|
|
184
184
|
type: "button",
|
|
@@ -187,8 +187,8 @@ const ControlledScrollDemo = () => {
|
|
|
187
187
|
},
|
|
188
188
|
"Item 10"
|
|
189
189
|
),
|
|
190
|
-
/* @__PURE__ */
|
|
191
|
-
), /* @__PURE__ */
|
|
190
|
+
/* @__PURE__ */ React.createElement("button", { type: "button", onClick: () => scrollToElement("item-20") }, "Item 20")
|
|
191
|
+
), /* @__PURE__ */ React.createElement(
|
|
192
192
|
import_ScrollView.default,
|
|
193
193
|
{
|
|
194
194
|
scrollY: true,
|
|
@@ -197,7 +197,7 @@ const ControlledScrollDemo = () => {
|
|
|
197
197
|
scrollIntoView,
|
|
198
198
|
scrollWithAnimation: true
|
|
199
199
|
},
|
|
200
|
-
Array.from({ length: 30 }, (_, index) => /* @__PURE__ */
|
|
200
|
+
Array.from({ length: 30 }, (_, index) => /* @__PURE__ */ React.createElement(
|
|
201
201
|
"div",
|
|
202
202
|
{
|
|
203
203
|
key: index,
|
|
@@ -216,7 +216,7 @@ const ControlledScrollDemo = () => {
|
|
|
216
216
|
));
|
|
217
217
|
};
|
|
218
218
|
const BidirectionalScrollDemo = () => {
|
|
219
|
-
return /* @__PURE__ */
|
|
219
|
+
return /* @__PURE__ */ React.createElement(
|
|
220
220
|
import_ScrollView.default,
|
|
221
221
|
{
|
|
222
222
|
scrollX: true,
|
|
@@ -228,7 +228,7 @@ const BidirectionalScrollDemo = () => {
|
|
|
228
228
|
borderRadius: "4px"
|
|
229
229
|
}
|
|
230
230
|
},
|
|
231
|
-
/* @__PURE__ */
|
|
231
|
+
/* @__PURE__ */ React.createElement(
|
|
232
232
|
"div",
|
|
233
233
|
{
|
|
234
234
|
style: {
|
|
@@ -240,7 +240,7 @@ const BidirectionalScrollDemo = () => {
|
|
|
240
240
|
position: "relative"
|
|
241
241
|
}
|
|
242
242
|
},
|
|
243
|
-
/* @__PURE__ */
|
|
243
|
+
/* @__PURE__ */ React.createElement(
|
|
244
244
|
"div",
|
|
245
245
|
{
|
|
246
246
|
style: {
|
|
@@ -255,21 +255,21 @@ const BidirectionalScrollDemo = () => {
|
|
|
255
255
|
boxShadow: "0 2px 8px rgba(0,0,0,0.1)"
|
|
256
256
|
}
|
|
257
257
|
},
|
|
258
|
-
/* @__PURE__ */
|
|
259
|
-
/* @__PURE__ */
|
|
258
|
+
/* @__PURE__ */ React.createElement("h3", { style: { margin: "0 0 10px 0", color: "#007acc" } }, "Scroll in both directions!"),
|
|
259
|
+
/* @__PURE__ */ React.createElement("p", { style: { margin: 0, color: "#666" } }, "This content area is larger than the viewport")
|
|
260
260
|
)
|
|
261
261
|
)
|
|
262
262
|
);
|
|
263
263
|
};
|
|
264
264
|
const ThresholdTestDemo = () => {
|
|
265
|
-
const [thresholdEvents, setThresholdEvents] =
|
|
265
|
+
const [thresholdEvents, setThresholdEvents] = React.useState([]);
|
|
266
266
|
const addEvent = (event) => {
|
|
267
267
|
setThresholdEvents((prev) => [
|
|
268
268
|
...prev.slice(-4),
|
|
269
269
|
`${(/* @__PURE__ */ new Date()).toLocaleTimeString()}: ${event}`
|
|
270
270
|
]);
|
|
271
271
|
};
|
|
272
|
-
return /* @__PURE__ */
|
|
272
|
+
return /* @__PURE__ */ React.createElement("div", null, /* @__PURE__ */ React.createElement(
|
|
273
273
|
"div",
|
|
274
274
|
{
|
|
275
275
|
"data-testid": "threshold-events",
|
|
@@ -280,9 +280,9 @@ const ThresholdTestDemo = () => {
|
|
|
280
280
|
minHeight: "80px"
|
|
281
281
|
}
|
|
282
282
|
},
|
|
283
|
-
/* @__PURE__ */
|
|
284
|
-
thresholdEvents.map((event, index) => /* @__PURE__ */
|
|
285
|
-
), /* @__PURE__ */
|
|
283
|
+
/* @__PURE__ */ React.createElement("strong", null, "Threshold Events:"),
|
|
284
|
+
thresholdEvents.map((event, index) => /* @__PURE__ */ React.createElement("div", { key: index, style: { fontSize: "12px", color: "#666" } }, event))
|
|
285
|
+
), /* @__PURE__ */ React.createElement(
|
|
286
286
|
import_ScrollView.default,
|
|
287
287
|
{
|
|
288
288
|
scrollY: true,
|
|
@@ -292,7 +292,7 @@ const ThresholdTestDemo = () => {
|
|
|
292
292
|
onScrollToUpper: () => addEvent("Reached upper threshold (20px)"),
|
|
293
293
|
onScrollToLower: () => addEvent("Reached lower threshold (20px)")
|
|
294
294
|
},
|
|
295
|
-
Array.from({ length: 20 }, (_, index) => /* @__PURE__ */
|
|
295
|
+
Array.from({ length: 20 }, (_, index) => /* @__PURE__ */ React.createElement(
|
|
296
296
|
"div",
|
|
297
297
|
{
|
|
298
298
|
key: index,
|
|
@@ -113,25 +113,31 @@ function useScrollView(parameters) {
|
|
|
113
113
|
const scrollVertical = (0, import_react.useCallback)((top, isAnimation) => {
|
|
114
114
|
if (top === void 0)
|
|
115
115
|
return;
|
|
116
|
+
if (!container.current)
|
|
117
|
+
return;
|
|
116
118
|
if (isAnimation) {
|
|
117
119
|
easeOutScroll(container.current.scrollTop, top, (pos) => {
|
|
118
120
|
if (container.current)
|
|
119
121
|
container.current.scrollTop = pos;
|
|
120
122
|
});
|
|
121
|
-
} else
|
|
123
|
+
} else {
|
|
122
124
|
container.current.scrollTop = top;
|
|
125
|
+
}
|
|
123
126
|
}, []);
|
|
124
127
|
const scrollHorizontal = (0, import_react.useCallback)(
|
|
125
128
|
(left, isAnimation) => {
|
|
126
129
|
if (left === void 0)
|
|
127
130
|
return;
|
|
131
|
+
if (!container.current)
|
|
132
|
+
return;
|
|
128
133
|
if (isAnimation) {
|
|
129
134
|
easeOutScroll(container.current.scrollLeft, left, (pos) => {
|
|
130
135
|
if (container.current)
|
|
131
136
|
container.current.scrollLeft = pos;
|
|
132
137
|
});
|
|
133
|
-
} else
|
|
138
|
+
} else {
|
|
134
139
|
container.current.scrollLeft = left;
|
|
140
|
+
}
|
|
135
141
|
},
|
|
136
142
|
[]
|
|
137
143
|
);
|
|
@@ -141,9 +147,13 @@ function useScrollView(parameters) {
|
|
|
141
147
|
const isAnimation = scrollWithAnimation;
|
|
142
148
|
if (scrollIntoView && typeof scrollIntoView === "string" && ((_b = (_a2 = container == null ? void 0 : container.current) == null ? void 0 : _a2.querySelector) == null ? void 0 : _b.call(_a2, `#${scrollIntoView}`))) {
|
|
143
149
|
const doScrollIntoView = (id, alignment = "start", _isAnimation = isAnimation) => {
|
|
150
|
+
if (!container.current)
|
|
151
|
+
return;
|
|
144
152
|
const target = container.current.querySelector(
|
|
145
153
|
`#${id}`
|
|
146
154
|
);
|
|
155
|
+
if (!target)
|
|
156
|
+
return;
|
|
147
157
|
if (scrollY) {
|
|
148
158
|
const start = target.offsetTop;
|
|
149
159
|
const end = target.offsetTop + target.offsetHeight - container.current.clientHeight;
|
|
@@ -196,14 +206,14 @@ function useScrollView(parameters) {
|
|
|
196
206
|
);
|
|
197
207
|
}
|
|
198
208
|
} else {
|
|
199
|
-
if (scrollY && typeof scrollTopProp === "number" && scrollTopProp !== container.current.scrollTop) {
|
|
209
|
+
if (scrollY && typeof scrollTopProp === "number" && container.current && scrollTopProp !== container.current.scrollTop) {
|
|
200
210
|
if (isInit) {
|
|
201
211
|
setTimeout(() => scrollVertical(scrollTopProp, isAnimation), 10);
|
|
202
212
|
} else {
|
|
203
213
|
scrollVertical(scrollTopProp, isAnimation);
|
|
204
214
|
}
|
|
205
215
|
}
|
|
206
|
-
if (scrollX && typeof scrollLeftProp === "number" && scrollLeftProp !== container.current.scrollLeft) {
|
|
216
|
+
if (scrollX && typeof scrollLeftProp === "number" && container.current && scrollLeftProp !== container.current.scrollLeft) {
|
|
207
217
|
if (isInit) {
|
|
208
218
|
setTimeout(() => scrollHorizontal(scrollLeftProp, isAnimation), 10);
|
|
209
219
|
} else {
|
|
@@ -261,6 +271,8 @@ function useScrollView(parameters) {
|
|
|
261
271
|
}
|
|
262
272
|
};
|
|
263
273
|
const onScrollHandler = (e) => {
|
|
274
|
+
if (!container.current)
|
|
275
|
+
return;
|
|
264
276
|
const { scrollLeft, scrollTop, scrollHeight, scrollWidth } = container.current;
|
|
265
277
|
Object.defineProperty(e, "detail", {
|
|
266
278
|
enumerable: true,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React from 'react';
|
|
1
|
+
import * as React from 'react';
|
|
2
2
|
import { SkeletonProps } from './Skeleton.types';
|
|
3
3
|
import './index.less';
|
|
4
4
|
declare const Skeleton: React.ForwardRefExoticComponent<Omit<SkeletonProps<"div", {}>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
|
|
@@ -57,10 +57,10 @@ __export(Skeleton_exports, {
|
|
|
57
57
|
});
|
|
58
58
|
module.exports = __toCommonJS(Skeleton_exports);
|
|
59
59
|
var import_clsx = __toESM(require("clsx"));
|
|
60
|
-
var
|
|
60
|
+
var React = __toESM(require("react"));
|
|
61
61
|
var import_index = require("./index.css");
|
|
62
62
|
const prefixCls = "bui-skeleton";
|
|
63
|
-
const Skeleton = /* @__PURE__ */
|
|
63
|
+
const Skeleton = /* @__PURE__ */ React.forwardRef(
|
|
64
64
|
(_a, ref) => {
|
|
65
65
|
var _b = _a, {
|
|
66
66
|
className,
|
|
@@ -79,7 +79,7 @@ const Skeleton = /* @__PURE__ */ import_react.default.forwardRef(
|
|
|
79
79
|
"variant",
|
|
80
80
|
"children"
|
|
81
81
|
]);
|
|
82
|
-
return /* @__PURE__ */
|
|
82
|
+
return /* @__PURE__ */ React.createElement(
|
|
83
83
|
"span",
|
|
84
84
|
__spreadValues({
|
|
85
85
|
className: (0, import_clsx.default)(
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { OverrideProps } from '@bifrostui/types';
|
|
2
|
-
import React from 'react';
|
|
2
|
+
import * as React from 'react';
|
|
3
3
|
export type VariantEnum = 'text' | 'circular' | 'rectangular' | 'rounded';
|
|
4
4
|
export type animationEnum = 'wave' | 'pulse' | false;
|
|
5
5
|
export type SkeletonProps<D extends React.ElementType = 'div', P = {}> = OverrideProps<{
|
package/dist/Slide/Slide.d.ts
CHANGED
package/dist/Slide/Slide.js
CHANGED
|
@@ -60,7 +60,7 @@ __export(Slide_exports, {
|
|
|
60
60
|
});
|
|
61
61
|
module.exports = __toCommonJS(Slide_exports);
|
|
62
62
|
var import_utils = require("@bifrostui/utils");
|
|
63
|
-
var
|
|
63
|
+
var React = __toESM(require("react"));
|
|
64
64
|
var import_Transition = __toESM(require("../Transition"));
|
|
65
65
|
const defaultEasing = {
|
|
66
66
|
enter: import_utils.easing.easeOut,
|
|
@@ -70,7 +70,7 @@ const defaultTimeout = {
|
|
|
70
70
|
enter: import_utils.duration.enteringScreen,
|
|
71
71
|
exit: import_utils.duration.leavingScreen
|
|
72
72
|
};
|
|
73
|
-
const Slide = /* @__PURE__ */
|
|
73
|
+
const Slide = /* @__PURE__ */ React.forwardRef(
|
|
74
74
|
(_a, ref) => {
|
|
75
75
|
var _b = _a, {
|
|
76
76
|
appear = true,
|
|
@@ -107,7 +107,7 @@ const Slide = /* @__PURE__ */ import_react.default.forwardRef(
|
|
|
107
107
|
};
|
|
108
108
|
if (!children)
|
|
109
109
|
return null;
|
|
110
|
-
return /* @__PURE__ */
|
|
110
|
+
return /* @__PURE__ */ React.createElement(
|
|
111
111
|
import_Transition.default,
|
|
112
112
|
__spreadProps(__spreadValues({}, others), {
|
|
113
113
|
appear,
|
|
@@ -127,7 +127,7 @@ const Slide = /* @__PURE__ */ import_react.default.forwardRef(
|
|
|
127
127
|
)
|
|
128
128
|
) : "none";
|
|
129
129
|
const transform = state === "entering" || state === "entered" ? "none" : getTranslateValue(direction);
|
|
130
|
-
return
|
|
130
|
+
return React.cloneElement(children, __spreadValues({
|
|
131
131
|
style: __spreadValues(__spreadValues({
|
|
132
132
|
visibility: state === "exited" ? "hidden" : "visible",
|
|
133
133
|
transition,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { OverrideProps } from '@bifrostui/types';
|
|
2
|
-
import React from 'react';
|
|
2
|
+
import * as React from 'react';
|
|
3
3
|
export type SliderValue = number | [number, number];
|
|
4
4
|
export type SliderProps<D extends React.ElementType = 'div', P = {}> = OverrideProps<{
|
|
5
5
|
props: P & {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { OverrideProps } from '@bifrostui/types';
|
|
2
|
-
import React from 'react';
|
|
2
|
+
import * as React from 'react';
|
|
3
3
|
import { OnChangeEvent } from './Steps.types';
|
|
4
4
|
export type StatusProps = 'wait' | 'active' | 'finish' | 'error';
|
|
5
5
|
export type StepProps<D extends React.ElementType = 'div', P = {}> = OverrideProps<{
|
|
@@ -31,8 +31,8 @@ __export(StepsContext_exports, {
|
|
|
31
31
|
default: () => StepsContext_default
|
|
32
32
|
});
|
|
33
33
|
module.exports = __toCommonJS(StepsContext_exports);
|
|
34
|
-
var
|
|
35
|
-
const StepsContext =
|
|
34
|
+
var React = __toESM(require("react"));
|
|
35
|
+
const StepsContext = React.createContext(null);
|
|
36
36
|
const StepsContextProvider = StepsContext.Provider;
|
|
37
37
|
var StepsContext_default = StepsContext;
|
|
38
38
|
// Annotate the CommonJS export names for ESM import in node:
|
|
@@ -114,7 +114,7 @@ const SwipeAction = /* @__PURE__ */ import_react.default.forwardRef(
|
|
|
114
114
|
const startingX = (0, import_react.useRef)(0);
|
|
115
115
|
const currentX = (0, import_react.useRef)(0);
|
|
116
116
|
const isDragging = (0, import_react.useRef)(false);
|
|
117
|
-
let
|
|
117
|
+
let preTranslateX = 0;
|
|
118
118
|
let dragPhase = import_constants.DragPhaseEnum.START;
|
|
119
119
|
const dragThreshold = 5;
|
|
120
120
|
const leftWidthCache = (0, import_react.useRef)(0);
|
|
@@ -181,11 +181,11 @@ const SwipeAction = /* @__PURE__ */ import_react.default.forwardRef(
|
|
|
181
181
|
100
|
|
182
182
|
);
|
|
183
183
|
const emitActionsReveal = (targetX, stop = false) => {
|
|
184
|
-
const isSpecial = targetX ===
|
|
185
|
-
if (targetX ===
|
|
184
|
+
const isSpecial = targetX === preTranslateX && targetX !== 0;
|
|
185
|
+
if (targetX === preTranslateX && !isSpecial || stop)
|
|
186
186
|
return;
|
|
187
187
|
let resStr = null;
|
|
188
|
-
const shouldOpen = targetX > 0 &&
|
|
188
|
+
const shouldOpen = targetX > 0 && preTranslateX <= 0 || targetX < 0 && preTranslateX >= 0 || isSpecial;
|
|
189
189
|
if (shouldOpen) {
|
|
190
190
|
if (targetX > 0) {
|
|
191
191
|
resStr = import_constants.SideTypeEnum.LEFT;
|
|
@@ -220,15 +220,14 @@ const SwipeAction = /* @__PURE__ */ import_react.default.forwardRef(
|
|
|
220
220
|
}
|
|
221
221
|
if (dragPhase === import_constants.DragPhaseEnum.END || import_utils.isMini) {
|
|
222
222
|
emitActionsReveal(targetX);
|
|
223
|
-
console.log("handleTouchEnd\uFF1A", targetX, e);
|
|
224
223
|
setTranslateX(targetX);
|
|
225
|
-
|
|
224
|
+
preTranslateX = targetX;
|
|
226
225
|
}
|
|
227
226
|
currentX.current = 0;
|
|
228
227
|
});
|
|
229
228
|
const close = () => {
|
|
230
229
|
setTranslateX(0);
|
|
231
|
-
|
|
230
|
+
preTranslateX = 0;
|
|
232
231
|
setIsOpen(false);
|
|
233
232
|
};
|
|
234
233
|
(0, import_react.useEffect)(() => {
|
|
@@ -272,7 +271,7 @@ const SwipeAction = /* @__PURE__ */ import_react.default.forwardRef(
|
|
|
272
271
|
targetX = yield getLefRefWidth();
|
|
273
272
|
}
|
|
274
273
|
setTranslateX(targetX);
|
|
275
|
-
|
|
274
|
+
preTranslateX = targetX;
|
|
276
275
|
emitActionsReveal(targetX);
|
|
277
276
|
}),
|
|
278
277
|
close,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { OverrideProps, ThemeColor } from '@bifrostui/types';
|
|
2
|
-
import React from 'react';
|
|
2
|
+
import * as React from 'react';
|
|
3
3
|
import { SideTypeEnum } from './constants';
|
|
4
4
|
export type SwipeActionProps<D extends React.ElementType = 'div', P = {}> = OverrideProps<{
|
|
5
5
|
props: P & {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { OverrideProps } from '@bifrostui/types';
|
|
2
2
|
import { SwiperProps as SwiperPropsH5 } from 'swiper/react';
|
|
3
|
-
import React from 'react';
|
|
3
|
+
import * as React from 'react';
|
|
4
4
|
export type SwiperProps<D extends React.ElementType = 'div', P = {}> = OverrideProps<{
|
|
5
5
|
props: P & SwiperPropsH5 & {
|
|
6
6
|
/** 是否显示面板指示点
|
|
@@ -58,11 +58,11 @@ __export(SwiperItem_exports, {
|
|
|
58
58
|
module.exports = __toCommonJS(SwiperItem_exports);
|
|
59
59
|
var import_react = require("swiper/react");
|
|
60
60
|
var import_clsx = __toESM(require("clsx"));
|
|
61
|
-
var
|
|
61
|
+
var React = __toESM(require("react"));
|
|
62
62
|
const SwiperItem = (props) => {
|
|
63
63
|
const _a = props, { className, style, children } = _a, restProps = __objRest(_a, ["className", "style", "children"]);
|
|
64
64
|
const cls = (0, import_clsx.default)("swiper-slide", className);
|
|
65
|
-
return /* @__PURE__ */
|
|
65
|
+
return /* @__PURE__ */ React.createElement(import_react.SwiperSlide, __spreadValues({ className: cls, style }, restProps), children);
|
|
66
66
|
};
|
|
67
67
|
SwiperItem.displayName = "BuiSwiperItem-SwiperSlide";
|
|
68
68
|
var SwiperItem_default = SwiperItem;
|
|
@@ -33,16 +33,16 @@ __export(A11yDemos_exports, {
|
|
|
33
33
|
disabledSwitchDemo: () => disabledSwitchDemo
|
|
34
34
|
});
|
|
35
35
|
module.exports = __toCommonJS(A11yDemos_exports);
|
|
36
|
-
var
|
|
36
|
+
var React = __toESM(require("react"));
|
|
37
37
|
var import_Switch = __toESM(require("../../Switch"));
|
|
38
38
|
const basicSwitchDemo = () => {
|
|
39
|
-
return /* @__PURE__ */
|
|
39
|
+
return /* @__PURE__ */ React.createElement("div", null, /* @__PURE__ */ React.createElement("label", null, /* @__PURE__ */ React.createElement(import_Switch.default, null), "Switch"));
|
|
40
40
|
};
|
|
41
41
|
const disabledSwitchDemo = () => {
|
|
42
|
-
return /* @__PURE__ */
|
|
42
|
+
return /* @__PURE__ */ React.createElement("div", null, /* @__PURE__ */ React.createElement("label", null, /* @__PURE__ */ React.createElement(import_Switch.default, { disabled: true }), "Switch"));
|
|
43
43
|
};
|
|
44
44
|
const ariaLabelSwitchDemo = () => {
|
|
45
|
-
return /* @__PURE__ */
|
|
45
|
+
return /* @__PURE__ */ React.createElement("div", null, /* @__PURE__ */ React.createElement(import_Switch.default, { inputProps: { "aria-label": "\u5F00\u5173" } }, "Switch"));
|
|
46
46
|
};
|
|
47
47
|
var A11yDemos_default = {
|
|
48
48
|
basicSwitchDemo,
|
package/dist/TabBar/TabBar.d.ts
CHANGED
package/dist/TabBar/TabBar.js
CHANGED
|
@@ -56,12 +56,12 @@ __export(TabBar_exports, {
|
|
|
56
56
|
default: () => TabBar_default
|
|
57
57
|
});
|
|
58
58
|
module.exports = __toCommonJS(TabBar_exports);
|
|
59
|
-
var
|
|
59
|
+
var React = __toESM(require("react"));
|
|
60
60
|
var import_clsx = __toESM(require("clsx"));
|
|
61
61
|
var import_TabBarContext = __toESM(require("./TabBarContext"));
|
|
62
62
|
var import_TabBar = require("./TabBar.css");
|
|
63
63
|
const prefixCls = "bui-tab-bar";
|
|
64
|
-
const TabBar = /* @__PURE__ */
|
|
64
|
+
const TabBar = /* @__PURE__ */ React.forwardRef((props, ref) => {
|
|
65
65
|
const _a = props || {}, {
|
|
66
66
|
current = 0,
|
|
67
67
|
activeColor = "primary",
|
|
@@ -77,7 +77,7 @@ const TabBar = /* @__PURE__ */ import_react.default.forwardRef((props, ref) => {
|
|
|
77
77
|
"className",
|
|
78
78
|
"onChange"
|
|
79
79
|
]);
|
|
80
|
-
return /* @__PURE__ */
|
|
80
|
+
return /* @__PURE__ */ React.createElement(
|
|
81
81
|
import_TabBarContext.default.Provider,
|
|
82
82
|
{
|
|
83
83
|
value: {
|
|
@@ -87,9 +87,9 @@ const TabBar = /* @__PURE__ */ import_react.default.forwardRef((props, ref) => {
|
|
|
87
87
|
onChange
|
|
88
88
|
}
|
|
89
89
|
},
|
|
90
|
-
/* @__PURE__ */
|
|
90
|
+
/* @__PURE__ */ React.createElement("div", __spreadValues({ ref, className: (0, import_clsx.default)(`${prefixCls}`, className) }, others), React.Children.toArray(children).map(
|
|
91
91
|
(item, index) => {
|
|
92
|
-
return
|
|
92
|
+
return React.cloneElement(item, {
|
|
93
93
|
index
|
|
94
94
|
});
|
|
95
95
|
}
|
package/dist/Tabs/Tab.css
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
.bui-tab {
|
|
2
|
-
display: flex;
|
|
2
|
+
display: inline-flex;
|
|
3
3
|
align-items: center;
|
|
4
4
|
justify-content: center;
|
|
5
5
|
white-space: nowrap;
|
|
@@ -19,28 +19,7 @@
|
|
|
19
19
|
font-weight: var(--bui-font-weight-bold);
|
|
20
20
|
font-family: var(--bui-tab-active-font-family);
|
|
21
21
|
}
|
|
22
|
-
.bui-tab-miniapp-active {
|
|
23
|
-
color: var(--bui-tab-active-color);
|
|
24
|
-
line-height: 1.5;
|
|
25
|
-
font-weight: var(--bui-font-weight-bold);
|
|
26
|
-
position: relative;
|
|
27
|
-
}
|
|
28
|
-
.bui-tab-miniapp-active-line {
|
|
29
|
-
position: absolute;
|
|
30
|
-
bottom: 0;
|
|
31
|
-
left: -12px;
|
|
32
|
-
right: -12px;
|
|
33
|
-
margin: 0 auto !important;
|
|
34
|
-
width: 18px;
|
|
35
|
-
height: 2px;
|
|
36
|
-
transition: all 100ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;
|
|
37
|
-
background-color: var(--bui-color-primary);
|
|
38
|
-
}
|
|
39
22
|
.bui-tab-disabled {
|
|
40
23
|
opacity: 0.5;
|
|
41
24
|
pointer-events: none;
|
|
42
25
|
}
|
|
43
|
-
.bui-indicator-invisible {
|
|
44
|
-
visibility: hidden;
|
|
45
|
-
background-color: transparent;
|
|
46
|
-
}
|
package/dist/Tabs/Tab.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { TabProps } from './Tab.types';
|
|
3
3
|
import './Tab.less';
|
|
4
|
-
declare const
|
|
5
|
-
export default
|
|
4
|
+
declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<Omit<TabProps<"div", {}>, "ref"> & React.RefAttributes<HTMLDivElement>>>;
|
|
5
|
+
export default _default;
|