@bifrostui/react 2.0.0-alpha.31 → 2.0.0-alpha.33
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.js +18 -8
- package/dist/ActionSheet/ActionSheetItem.d.ts +1 -1
- package/dist/ActionSheet/ActionSheetItem.js +12 -5
- package/dist/Alert/Alert.d.ts +1 -1
- package/dist/Alert/Alert.js +36 -34
- package/dist/Alert/__tests__/fixtures/A11yDemos.d.ts +8 -9
- package/dist/Alert/__tests__/fixtures/A11yDemos.js +60 -54
- package/dist/Avatar/Avatar.d.ts +1 -1
- package/dist/Avatar/Avatar.js +11 -9
- package/dist/Avatar/AvatarGroup.d.ts +1 -1
- package/dist/Avatar/AvatarGroup.js +10 -6
- package/dist/Backdrop/Backdrop.d.ts +1 -1
- package/dist/Backdrop/Backdrop.js +9 -5
- package/dist/Backdrop/__tests__/fixtures/A11yDemos.d.ts +4 -5
- package/dist/Backdrop/__tests__/fixtures/A11yDemos.js +3 -3
- package/dist/Badge/Badge.d.ts +1 -1
- package/dist/Badge/Badge.js +23 -15
- package/dist/Badge/__tests__/fixtures/A11yDemos.d.ts +16 -17
- package/dist/Badge/__tests__/fixtures/A11yDemos.js +60 -27
- package/dist/Badge/index.css +3 -3
- package/dist/Breadcrumb/Breadcrumb.d.ts +1 -1
- package/dist/Breadcrumb/Breadcrumb.js +19 -10
- package/dist/Breadcrumb/BreadcrumbItem.d.ts +1 -1
- package/dist/Breadcrumb/BreadcrumbItem.js +18 -10
- package/dist/Button/Button.d.ts +1 -1
- package/dist/Button/Button.js +14 -7
- package/dist/Button/__tests__/fixtures/A11yDemos.d.ts +14 -15
- package/dist/Button/__tests__/fixtures/A11yDemos.js +32 -8
- package/dist/CSSTransition/CSSTransition.js +2 -1
- package/dist/CSSTransition/demo/CSSTransitionDemo.d.ts +1 -2
- package/dist/CSSTransition/demo/CSSTransitionDemo.js +28 -35
- package/dist/Calendar/Calendar.d.ts +1 -1
- package/dist/Calendar/Calendar.js +74 -66
- package/dist/Calendar/__tests__/fixtures/A11yDemos.d.ts +1 -2
- package/dist/Calendar/__tests__/fixtures/A11yDemos.js +2 -2
- package/dist/Card/Card.d.ts +1 -1
- package/dist/Card/Card.js +9 -4
- package/dist/Card/CardContent.d.ts +1 -1
- package/dist/Card/CardContent.js +5 -1
- package/dist/Card/CardFooter.d.ts +1 -1
- package/dist/Card/CardFooter.js +5 -1
- package/dist/Card/CardHeader.d.ts +1 -1
- package/dist/Card/CardHeader.js +16 -9
- package/dist/Checkbox/Checkbox.d.ts +1 -1
- package/dist/Checkbox/Checkbox.js +27 -23
- package/dist/Checkbox/CheckboxGroup.d.ts +1 -1
- package/dist/Checkbox/CheckboxGroup.js +9 -5
- package/dist/Checkbox/__tests__/fixtures/A11yDemos.d.ts +6 -7
- package/dist/Checkbox/__tests__/fixtures/A11yDemos.js +10 -4
- package/dist/Checkbox/index.css +4 -4
- package/dist/CitySelector/CitySelector.d.ts +1 -1
- package/dist/CitySelector/CitySelector.js +2 -1
- package/dist/CitySelector/CitySelector.miniapp.d.ts +1 -1
- package/dist/CitySelector/CitySelector.miniapp.js +2 -1
- package/dist/CitySelector/CitySelectorCore.js +83 -61
- package/dist/CitySelector/Selector/index.d.ts +1 -1
- package/dist/CitySelector/Selector/index.js +5 -15
- package/dist/Collapse/Collapse.js +51 -50
- package/dist/CollapsePanel/CollapsePanel.d.ts +1 -1
- package/dist/CollapsePanel/CollapsePanel.js +10 -8
- package/dist/CollapsePanel/CollapsePanelItem.d.ts +1 -1
- package/dist/CollapsePanel/CollapsePanelItem.js +27 -17
- package/dist/Countdown/Countdown.d.ts +1 -1
- package/dist/Countdown/Countdown.js +39 -29
- package/dist/Countdown/__tests__/fixtures/A11yDemos.d.ts +14 -15
- package/dist/Countdown/__tests__/fixtures/A11yDemos.js +37 -23
- package/dist/DatePicker/DatePicker.d.ts +1 -1
- package/dist/DatePicker/DatePicker.js +3 -2
- package/dist/DesktopDatePicker/DesktopDatePicker.d.ts +1 -1
- package/dist/DesktopDatePicker/DesktopDatePicker.js +45 -40
- package/dist/DesktopDatePicker/useGetDatePickerContent.d.ts +1 -2
- package/dist/DesktopDatePicker/useGetDatePickerContent.js +48 -41
- package/dist/DesktopDateTimePicker/DesktopDateTimePicker.d.ts +1 -1
- package/dist/DesktopDateTimePicker/DesktopDateTimePicker.js +57 -51
- package/dist/DesktopPicker/DesktopPicker.d.ts +1 -1
- package/dist/DesktopPicker/DesktopPicker.js +36 -25
- package/dist/DesktopTimePicker/DesktopTimePicker.d.ts +1 -1
- package/dist/DesktopTimePicker/DesktopTimePicker.js +46 -41
- package/dist/DesktopTimePicker/DesktopTimePickerList.js +21 -20
- package/dist/DesktopTimePicker/useGetTimePickerContent.d.ts +1 -2
- package/dist/DesktopTimePicker/useGetTimePickerContent.js +9 -8
- package/dist/Dialog/Dialog.js +48 -39
- package/dist/Dialog/FunctionalDialog.js +8 -8
- package/dist/Dialog/__tests__/fixtures/A11yDemos.d.ts +3 -4
- package/dist/Dialog/__tests__/fixtures/A11yDemos.js +4 -4
- package/dist/Divider/Divider.d.ts +1 -1
- package/dist/Divider/Divider.js +9 -4
- package/dist/Drawer/Drawer.js +28 -25
- package/dist/Drawer/__tests__/fixtures/A11yDemos.d.ts +12 -13
- package/dist/Drawer/__tests__/fixtures/A11yDemos.js +88 -35
- package/dist/Fade/Fade.js +23 -22
- package/dist/IconButton/IconButton.d.ts +1 -1
- package/dist/IconButton/IconButton.js +14 -9
- package/dist/Image/Image.d.ts +1 -1
- package/dist/Image/Image.js +15 -10
- package/dist/Image/__tests__/fixtures/A11yDemos.d.ts +12 -13
- package/dist/Image/__tests__/fixtures/A11yDemos.js +29 -25
- package/dist/Input/Input.d.ts +1 -1
- package/dist/Input/Input.js +28 -24
- package/dist/Input/__tests__/fixtures/A11yDemos.d.ts +12 -13
- package/dist/Input/__tests__/fixtures/A11yDemos.js +31 -13
- package/dist/ItemSelector/ItemSelector.d.ts +1 -1
- package/dist/ItemSelector/ItemSelector.js +2 -1
- package/dist/ItemSelector/ItemSelector.miniapp.d.ts +1 -1
- package/dist/ItemSelector/ItemSelector.miniapp.js +2 -1
- package/dist/ItemSelector/ItemSelectorCore.js +82 -68
- package/dist/ItemSelector/Selector/index.d.ts +1 -1
- package/dist/ItemSelector/Selector/index.js +5 -15
- package/dist/List/List.d.ts +1 -1
- package/dist/List/List.js +14 -7
- package/dist/List/ListItem.d.ts +1 -1
- package/dist/List/ListItem.js +14 -7
- package/dist/List/ListItemContent.d.ts +1 -1
- package/dist/List/ListItemContent.js +8 -1
- package/dist/List/ListItemExtra.d.ts +1 -1
- package/dist/List/ListItemExtra.js +5 -1
- package/dist/List/ListItemFooter.d.ts +1 -1
- package/dist/List/ListItemFooter.js +5 -1
- package/dist/List/ListItemHeader.d.ts +1 -1
- package/dist/List/ListItemHeader.js +5 -1
- package/dist/Loading/Loading.d.ts +1 -1
- package/dist/Loading/Loading.js +13 -6
- package/dist/Modal/Modal.d.ts +1 -1
- package/dist/Modal/Modal.js +5 -1
- package/dist/Modal/Modal.miniapp.d.ts +2 -4
- package/dist/Modal/Modal.miniapp.js +9 -6
- package/dist/Modal/__tests__/fixtures/A11yDemos.d.ts +2 -3
- package/dist/Modal/__tests__/fixtures/A11yDemos.js +7 -7
- package/dist/NavBar/NavBar.d.ts +1 -1
- package/dist/NavBar/NavBar.js +24 -11
- package/dist/Picker/Picker.d.ts +1 -1
- package/dist/Picker/Picker.js +63 -57
- package/dist/Picker/PickerPanel.d.ts +1 -1
- package/dist/Picker/PickerPanel.js +44 -37
- package/dist/Picker/__tests__/fixtures/A11yDemos.d.ts +1 -2
- package/dist/Picker/__tests__/fixtures/A11yDemos.js +2 -2
- package/dist/Popover/Popover.d.ts +1 -1
- package/dist/Popover/Popover.js +65 -52
- package/dist/Popover/__tests__/fixtures/A11yDemos.d.ts +16 -17
- package/dist/Popover/__tests__/fixtures/A11yDemos.js +62 -50
- package/dist/Popover/hooks/usePopoverPosition.js +1 -1
- package/dist/Portal/Portal.js +2 -1
- package/dist/Portal/Portal.miniapp.js +3 -2
- package/dist/Progress/Progress.d.ts +1 -1
- package/dist/Progress/Progress.js +9 -4
- package/dist/Progress/__tests__/fixtures/A11yDemos.d.ts +12 -13
- package/dist/Progress/__tests__/fixtures/A11yDemos.js +51 -30
- package/dist/Radio/Radio.d.ts +1 -1
- package/dist/Radio/Radio.js +25 -22
- package/dist/Radio/RadioButtonIcon.d.ts +1 -2
- package/dist/Radio/RadioButtonIcon.js +24 -22
- package/dist/Radio/RadioGroup.d.ts +1 -1
- package/dist/Radio/RadioGroup.js +9 -5
- package/dist/Radio/__tests__/fixtures/A11yDemos.d.ts +6 -7
- package/dist/Radio/__tests__/fixtures/A11yDemos.js +10 -4
- package/dist/Rating/Rating.d.ts +1 -1
- package/dist/Rating/Rating.js +42 -33
- package/dist/ScrollView/ScrollView.d.ts +1 -1
- package/dist/ScrollView/ScrollView.js +3 -2
- package/dist/ScrollView/__tests__/fixtures/A11yDemos.js +205 -168
- package/dist/Select/Select.d.ts +1 -1
- package/dist/Select/Select.js +87 -78
- package/dist/Select/SelectOption.d.ts +1 -1
- package/dist/Select/SelectOption.js +5 -4
- package/dist/Select/__tests__/fixtures/A11yDemos.d.ts +12 -13
- package/dist/Select/__tests__/fixtures/A11yDemos.js +76 -46
- package/dist/Skeleton/Skeleton.d.ts +1 -1
- package/dist/Skeleton/Skeleton.js +9 -4
- package/dist/Slide/Slide.js +25 -24
- package/dist/Slider/Slider.d.ts +1 -1
- package/dist/Slider/Slider.js +34 -27
- package/dist/Stack/Stack.d.ts +1 -1
- package/dist/Stack/Stack.js +17 -9
- package/dist/Stack/demo/StackDemo.d.ts +1 -2
- package/dist/Stack/demo/StackDemo.js +114 -101
- package/dist/Steps/Step.d.ts +1 -1
- package/dist/Steps/Step.js +56 -44
- package/dist/Steps/Steps.d.ts +1 -1
- package/dist/Steps/Steps.js +23 -17
- package/dist/SwipeAction/SwipeAction.d.ts +1 -1
- package/dist/SwipeAction/SwipeAction.js +55 -46
- package/dist/SwipeAction/SwipeActionItem.d.ts +1 -1
- package/dist/SwipeAction/SwipeActionItem.js +9 -4
- package/dist/Swiper/Swiper.d.ts +1 -1
- package/dist/Swiper/Swiper.js +7 -6
- package/dist/Swiper/SwiperItem.d.ts +1 -2
- package/dist/Swiper/SwiperItem.js +5 -2
- package/dist/Switch/Switch.d.ts +1 -1
- package/dist/Switch/Switch.js +22 -18
- package/dist/Switch/__tests__/fixtures/A11yDemos.d.ts +6 -7
- package/dist/Switch/__tests__/fixtures/A11yDemos.js +10 -4
- package/dist/Switch/index.css +11 -11
- package/dist/TabBar/TabBar.d.ts +1 -1
- package/dist/TabBar/TabBar.js +14 -10
- package/dist/TabBar/TabBarItem.d.ts +1 -1
- package/dist/TabBar/TabBarItem.js +31 -20
- package/dist/Tabs/Tab.d.ts +1 -1
- package/dist/Tabs/Tab.js +5 -4
- package/dist/Tabs/TabIndicator.js +3 -2
- package/dist/Tabs/TabMask.js +2 -1
- package/dist/Tabs/TabPanel.d.ts +1 -1
- package/dist/Tabs/TabPanel.js +10 -5
- package/dist/Tabs/Tabs.d.ts +1 -1
- package/dist/Tabs/Tabs.js +26 -17
- package/dist/Tabs/miniapp/Tab.d.ts +1 -1
- package/dist/Tabs/miniapp/Tab.js +5 -4
- package/dist/Tabs/miniapp/TabIndicator.js +3 -2
- package/dist/Tabs/miniapp/Tabs.d.ts +1 -1
- package/dist/Tabs/miniapp/Tabs.js +33 -23
- package/dist/Tag/Tag.d.ts +1 -1
- package/dist/Tag/Tag.js +9 -4
- package/dist/Tag/TagGroup.d.ts +1 -1
- package/dist/Tag/TagGroup.js +9 -4
- package/dist/Tag/__tests__/fixtures/A11yDemos.d.ts +12 -13
- package/dist/Tag/__tests__/fixtures/A11yDemos.js +121 -83
- package/dist/TextArea/TextArea.d.ts +1 -1
- package/dist/TextArea/TextArea.js +40 -36
- package/dist/TextArea/__tests__/fixtures/A11yDemos.d.ts +10 -11
- package/dist/TextArea/__tests__/fixtures/A11yDemos.js +18 -15
- package/dist/ThemeProvider/ThemeProvider.d.ts +1 -1
- package/dist/ThemeProvider/ThemeProvider.js +3 -2
- package/dist/Toast/FunctionalToast.js +11 -11
- package/dist/Toast/Toast.js +38 -32
- package/dist/Toast/__tests__/fixtures/A11yDemos.d.ts +1 -2
- package/dist/Toast/__tests__/fixtures/A11yDemos.js +5 -5
- package/dist/Tooltip/Tooltip.d.ts +1 -1
- package/dist/Tooltip/Tooltip.js +13 -6
- package/dist/Tooltip/__tests__/fixtures/A11yDemos.d.ts +16 -17
- package/dist/Tooltip/__tests__/fixtures/A11yDemos.js +51 -18
- package/dist/Tooltip/useTooltip.js +1 -1
- package/dist/Transition/Transition.js +2 -1
- package/dist/Transition/Transition.miniapp.js +2 -1
- package/dist/Transition/TransitionCore.js +8 -2
- package/dist/TransitionGroup/TransitionGroup.d.ts +1 -2
- package/dist/TransitionGroup/TransitionGroup.js +3 -2
- package/dist/TransitionGroup/demo/TransitionGroupDemo.d.ts +1 -2
- package/dist/TransitionGroup/demo/TransitionGroupDemo.js +24 -27
- package/dist/_.._/benchmarks/components/Button.js +2 -12
- package/dist/_.._/benchmarks/components/Input.js +3 -12
- package/dist/_.._/benchmarks/components/Tabs.js +8 -12
- package/es/ActionSheet/ActionSheet.js +18 -8
- package/es/ActionSheet/ActionSheetItem.d.ts +1 -1
- package/es/ActionSheet/ActionSheetItem.js +12 -5
- package/es/Alert/Alert.d.ts +1 -1
- package/es/Alert/Alert.js +36 -34
- package/es/Alert/__tests__/fixtures/A11yDemos.d.ts +8 -9
- package/es/Alert/__tests__/fixtures/A11yDemos.js +60 -54
- package/es/Avatar/Avatar.d.ts +1 -1
- package/es/Avatar/Avatar.js +11 -9
- package/es/Avatar/AvatarGroup.d.ts +1 -1
- package/es/Avatar/AvatarGroup.js +10 -6
- package/es/Backdrop/Backdrop.d.ts +1 -1
- package/es/Backdrop/Backdrop.js +9 -5
- package/es/Backdrop/__tests__/fixtures/A11yDemos.d.ts +4 -5
- package/es/Backdrop/__tests__/fixtures/A11yDemos.js +3 -3
- package/es/Badge/Badge.d.ts +1 -1
- package/es/Badge/Badge.js +23 -15
- package/es/Badge/__tests__/fixtures/A11yDemos.d.ts +16 -17
- package/es/Badge/__tests__/fixtures/A11yDemos.js +60 -27
- package/es/Badge/index.css +3 -3
- package/es/Breadcrumb/Breadcrumb.d.ts +1 -1
- package/es/Breadcrumb/Breadcrumb.js +19 -10
- package/es/Breadcrumb/BreadcrumbItem.d.ts +1 -1
- package/es/Breadcrumb/BreadcrumbItem.js +18 -10
- package/es/Button/Button.d.ts +1 -1
- package/es/Button/Button.js +14 -7
- package/es/Button/__tests__/fixtures/A11yDemos.d.ts +14 -15
- package/es/Button/__tests__/fixtures/A11yDemos.js +32 -8
- package/es/CSSTransition/CSSTransition.js +2 -1
- package/es/CSSTransition/demo/CSSTransitionDemo.d.ts +1 -2
- package/es/CSSTransition/demo/CSSTransitionDemo.js +28 -25
- package/es/Calendar/Calendar.d.ts +1 -1
- package/es/Calendar/Calendar.js +67 -59
- package/es/Calendar/__tests__/fixtures/A11yDemos.d.ts +1 -2
- package/es/Calendar/__tests__/fixtures/A11yDemos.js +2 -2
- package/es/Card/Card.d.ts +1 -1
- package/es/Card/Card.js +9 -4
- package/es/Card/CardContent.d.ts +1 -1
- package/es/Card/CardContent.js +5 -1
- package/es/Card/CardFooter.d.ts +1 -1
- package/es/Card/CardFooter.js +5 -1
- package/es/Card/CardHeader.d.ts +1 -1
- package/es/Card/CardHeader.js +16 -9
- package/es/Checkbox/Checkbox.d.ts +1 -1
- package/es/Checkbox/Checkbox.js +30 -23
- package/es/Checkbox/CheckboxGroup.d.ts +1 -1
- package/es/Checkbox/CheckboxGroup.js +9 -5
- package/es/Checkbox/__tests__/fixtures/A11yDemos.d.ts +6 -7
- package/es/Checkbox/__tests__/fixtures/A11yDemos.js +10 -4
- package/es/Checkbox/index.css +4 -4
- package/es/CitySelector/CitySelector.d.ts +1 -1
- package/es/CitySelector/CitySelector.js +2 -1
- package/es/CitySelector/CitySelector.miniapp.d.ts +1 -1
- package/es/CitySelector/CitySelector.miniapp.js +2 -1
- package/es/CitySelector/CitySelectorCore.js +83 -61
- package/es/CitySelector/Selector/index.d.ts +1 -1
- package/es/CitySelector/Selector/index.js +5 -5
- package/es/Collapse/Collapse.js +51 -50
- package/es/CollapsePanel/CollapsePanel.d.ts +1 -1
- package/es/CollapsePanel/CollapsePanel.js +10 -8
- package/es/CollapsePanel/CollapsePanelItem.d.ts +1 -1
- package/es/CollapsePanel/CollapsePanelItem.js +27 -17
- package/es/Countdown/Countdown.d.ts +1 -1
- package/es/Countdown/Countdown.js +39 -29
- package/es/Countdown/__tests__/fixtures/A11yDemos.d.ts +14 -15
- package/es/Countdown/__tests__/fixtures/A11yDemos.js +37 -23
- package/es/DatePicker/DatePicker.d.ts +1 -1
- package/es/DatePicker/DatePicker.js +3 -2
- package/es/DesktopDatePicker/DesktopDatePicker.d.ts +1 -1
- package/es/DesktopDatePicker/DesktopDatePicker.js +45 -40
- package/es/DesktopDatePicker/useGetDatePickerContent.d.ts +1 -2
- package/es/DesktopDatePicker/useGetDatePickerContent.js +48 -41
- package/es/DesktopDateTimePicker/DesktopDateTimePicker.d.ts +1 -1
- package/es/DesktopDateTimePicker/DesktopDateTimePicker.js +57 -51
- package/es/DesktopPicker/DesktopPicker.d.ts +1 -1
- package/es/DesktopPicker/DesktopPicker.js +36 -25
- package/es/DesktopTimePicker/DesktopTimePicker.d.ts +1 -1
- package/es/DesktopTimePicker/DesktopTimePicker.js +46 -41
- package/es/DesktopTimePicker/DesktopTimePickerList.js +21 -20
- package/es/DesktopTimePicker/useGetTimePickerContent.d.ts +1 -2
- package/es/DesktopTimePicker/useGetTimePickerContent.js +9 -8
- package/es/Dialog/Dialog.js +48 -39
- package/es/Dialog/FunctionalDialog.js +8 -8
- package/es/Dialog/__tests__/fixtures/A11yDemos.d.ts +3 -4
- package/es/Dialog/__tests__/fixtures/A11yDemos.js +4 -4
- package/es/Divider/Divider.d.ts +1 -1
- package/es/Divider/Divider.js +9 -4
- package/es/Drawer/Drawer.js +28 -25
- package/es/Drawer/__tests__/fixtures/A11yDemos.d.ts +12 -13
- package/es/Drawer/__tests__/fixtures/A11yDemos.js +88 -35
- package/es/Fade/Fade.js +23 -22
- package/es/IconButton/IconButton.d.ts +1 -1
- package/es/IconButton/IconButton.js +14 -9
- package/es/Image/Image.d.ts +1 -1
- package/es/Image/Image.js +15 -10
- package/es/Image/__tests__/fixtures/A11yDemos.d.ts +12 -13
- package/es/Image/__tests__/fixtures/A11yDemos.js +29 -25
- package/es/Input/Input.d.ts +1 -1
- package/es/Input/Input.js +28 -24
- package/es/Input/__tests__/fixtures/A11yDemos.d.ts +12 -13
- package/es/Input/__tests__/fixtures/A11yDemos.js +31 -13
- package/es/ItemSelector/ItemSelector.d.ts +1 -1
- package/es/ItemSelector/ItemSelector.js +2 -1
- package/es/ItemSelector/ItemSelector.miniapp.d.ts +1 -1
- package/es/ItemSelector/ItemSelector.miniapp.js +2 -1
- package/es/ItemSelector/ItemSelectorCore.js +82 -68
- package/es/ItemSelector/Selector/index.d.ts +1 -1
- package/es/ItemSelector/Selector/index.js +5 -5
- package/es/List/List.d.ts +1 -1
- package/es/List/List.js +14 -7
- package/es/List/ListItem.d.ts +1 -1
- package/es/List/ListItem.js +14 -7
- package/es/List/ListItemContent.d.ts +1 -1
- package/es/List/ListItemContent.js +8 -1
- package/es/List/ListItemExtra.d.ts +1 -1
- package/es/List/ListItemExtra.js +5 -1
- package/es/List/ListItemFooter.d.ts +1 -1
- package/es/List/ListItemFooter.js +5 -1
- package/es/List/ListItemHeader.d.ts +1 -1
- package/es/List/ListItemHeader.js +5 -1
- package/es/Loading/Loading.d.ts +1 -1
- package/es/Loading/Loading.js +13 -6
- package/es/Modal/Modal.d.ts +1 -1
- package/es/Modal/Modal.js +5 -1
- package/es/Modal/Modal.miniapp.d.ts +2 -4
- package/es/Modal/Modal.miniapp.js +9 -6
- package/es/Modal/__tests__/fixtures/A11yDemos.d.ts +2 -3
- package/es/Modal/__tests__/fixtures/A11yDemos.js +7 -7
- package/es/NavBar/NavBar.d.ts +1 -1
- package/es/NavBar/NavBar.js +24 -11
- package/es/Picker/Picker.d.ts +1 -1
- package/es/Picker/Picker.js +63 -57
- package/es/Picker/PickerPanel.d.ts +1 -1
- package/es/Picker/PickerPanel.js +44 -37
- package/es/Picker/__tests__/fixtures/A11yDemos.d.ts +1 -2
- package/es/Picker/__tests__/fixtures/A11yDemos.js +2 -2
- package/es/Popover/Popover.d.ts +1 -1
- package/es/Popover/Popover.js +65 -52
- package/es/Popover/__tests__/fixtures/A11yDemos.d.ts +16 -17
- package/es/Popover/__tests__/fixtures/A11yDemos.js +62 -50
- package/es/Popover/hooks/usePopoverPosition.js +1 -1
- package/es/Portal/Portal.js +2 -1
- package/es/Portal/Portal.miniapp.js +3 -2
- package/es/Progress/Progress.d.ts +1 -1
- package/es/Progress/Progress.js +9 -4
- package/es/Progress/__tests__/fixtures/A11yDemos.d.ts +12 -13
- package/es/Progress/__tests__/fixtures/A11yDemos.js +51 -30
- package/es/Radio/Radio.d.ts +1 -1
- package/es/Radio/Radio.js +25 -22
- package/es/Radio/RadioButtonIcon.d.ts +1 -2
- package/es/Radio/RadioButtonIcon.js +24 -22
- package/es/Radio/RadioGroup.d.ts +1 -1
- package/es/Radio/RadioGroup.js +9 -5
- package/es/Radio/__tests__/fixtures/A11yDemos.d.ts +6 -7
- package/es/Radio/__tests__/fixtures/A11yDemos.js +10 -4
- package/es/Rating/Rating.d.ts +1 -1
- package/es/Rating/Rating.js +42 -33
- package/es/ScrollView/ScrollView.d.ts +1 -1
- package/es/ScrollView/ScrollView.js +3 -2
- package/es/ScrollView/__tests__/fixtures/A11yDemos.js +205 -168
- package/es/Select/Select.d.ts +1 -1
- package/es/Select/Select.js +87 -78
- package/es/Select/SelectOption.d.ts +1 -1
- package/es/Select/SelectOption.js +5 -4
- package/es/Select/__tests__/fixtures/A11yDemos.d.ts +12 -13
- package/es/Select/__tests__/fixtures/A11yDemos.js +76 -46
- package/es/Skeleton/Skeleton.d.ts +1 -1
- package/es/Skeleton/Skeleton.js +9 -4
- package/es/Slide/Slide.js +25 -24
- package/es/Slider/Slider.d.ts +1 -1
- package/es/Slider/Slider.js +34 -27
- package/es/Stack/Stack.d.ts +1 -1
- package/es/Stack/Stack.js +17 -9
- package/es/Stack/demo/StackDemo.d.ts +1 -2
- package/es/Stack/demo/StackDemo.js +114 -91
- package/es/Steps/Step.d.ts +1 -1
- package/es/Steps/Step.js +56 -44
- package/es/Steps/Steps.d.ts +1 -1
- package/es/Steps/Steps.js +23 -17
- package/es/SwipeAction/SwipeAction.d.ts +1 -1
- package/es/SwipeAction/SwipeAction.js +55 -46
- package/es/SwipeAction/SwipeActionItem.d.ts +1 -1
- package/es/SwipeAction/SwipeActionItem.js +9 -4
- package/es/Swiper/Swiper.d.ts +1 -1
- package/es/Swiper/Swiper.js +7 -6
- package/es/Swiper/SwiperItem.d.ts +1 -2
- package/es/Swiper/SwiperItem.js +5 -2
- package/es/Switch/Switch.d.ts +1 -1
- package/es/Switch/Switch.js +22 -18
- package/es/Switch/__tests__/fixtures/A11yDemos.d.ts +6 -7
- package/es/Switch/__tests__/fixtures/A11yDemos.js +10 -4
- package/es/Switch/index.css +11 -11
- package/es/TabBar/TabBar.d.ts +1 -1
- package/es/TabBar/TabBar.js +14 -10
- package/es/TabBar/TabBarItem.d.ts +1 -1
- package/es/TabBar/TabBarItem.js +31 -20
- package/es/Tabs/Tab.d.ts +1 -1
- package/es/Tabs/Tab.js +5 -4
- package/es/Tabs/TabIndicator.js +3 -2
- package/es/Tabs/TabMask.js +2 -1
- package/es/Tabs/TabPanel.d.ts +1 -1
- package/es/Tabs/TabPanel.js +10 -5
- package/es/Tabs/Tabs.d.ts +1 -1
- package/es/Tabs/Tabs.js +26 -17
- package/es/Tabs/miniapp/Tab.d.ts +1 -1
- package/es/Tabs/miniapp/Tab.js +5 -4
- package/es/Tabs/miniapp/TabIndicator.js +3 -2
- package/es/Tabs/miniapp/Tabs.d.ts +1 -1
- package/es/Tabs/miniapp/Tabs.js +33 -23
- package/es/Tag/Tag.d.ts +1 -1
- package/es/Tag/Tag.js +9 -4
- package/es/Tag/TagGroup.d.ts +1 -1
- package/es/Tag/TagGroup.js +9 -4
- package/es/Tag/__tests__/fixtures/A11yDemos.d.ts +12 -13
- package/es/Tag/__tests__/fixtures/A11yDemos.js +121 -83
- package/es/TextArea/TextArea.d.ts +1 -1
- package/es/TextArea/TextArea.js +40 -36
- package/es/TextArea/__tests__/fixtures/A11yDemos.d.ts +10 -11
- package/es/TextArea/__tests__/fixtures/A11yDemos.js +18 -15
- package/es/ThemeProvider/ThemeProvider.d.ts +1 -1
- package/es/ThemeProvider/ThemeProvider.js +3 -2
- package/es/Toast/FunctionalToast.js +11 -11
- package/es/Toast/Toast.js +38 -32
- package/es/Toast/__tests__/fixtures/A11yDemos.d.ts +1 -2
- package/es/Toast/__tests__/fixtures/A11yDemos.js +5 -5
- package/es/Tooltip/Tooltip.d.ts +1 -1
- package/es/Tooltip/Tooltip.js +13 -6
- package/es/Tooltip/__tests__/fixtures/A11yDemos.d.ts +16 -17
- package/es/Tooltip/__tests__/fixtures/A11yDemos.js +51 -18
- package/es/Tooltip/useTooltip.js +1 -1
- package/es/Transition/Transition.js +2 -1
- package/es/Transition/Transition.miniapp.js +2 -1
- package/es/Transition/TransitionCore.js +8 -2
- package/es/TransitionGroup/TransitionGroup.d.ts +1 -2
- package/es/TransitionGroup/TransitionGroup.js +3 -2
- package/es/TransitionGroup/demo/TransitionGroupDemo.d.ts +1 -2
- package/es/TransitionGroup/demo/TransitionGroupDemo.js +24 -17
- package/es/_.._/benchmarks/components/Button.js +2 -2
- package/es/_.._/benchmarks/components/Input.js +3 -2
- package/es/_.._/benchmarks/components/Tabs.js +8 -2
- package/package.json +17 -11
|
@@ -1,25 +1,24 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
/**
|
|
3
2
|
* 自定义 Badge 组件 Demo 集合
|
|
4
3
|
* 这个文件包含多个测试 demo,展示如何使用 getCustomDemoCodesFromFile 进行无障碍测试
|
|
5
4
|
* 文件名必须是 A11yDemos.tsx(固定约定)
|
|
6
5
|
*/
|
|
7
|
-
export declare const basicBadgeDemo: () =>
|
|
8
|
-
export declare const colorBadgeDemo: () =>
|
|
9
|
-
export declare const typeBadgeDemo: () =>
|
|
10
|
-
export declare const maxBadgeDemo: () =>
|
|
11
|
-
export declare const accessibilityBadgeDemo: () =>
|
|
12
|
-
export declare const invisibilityBadgeDemo: () =>
|
|
13
|
-
export declare const complexInteractionBadgeDemo: () =>
|
|
14
|
-
export declare const specialContentBadgeDemo: () =>
|
|
6
|
+
export declare const basicBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare const colorBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export declare const typeBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export declare const maxBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export declare const accessibilityBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export declare const invisibilityBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export declare const complexInteractionBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export declare const specialContentBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
15
14
|
declare const _default: {
|
|
16
|
-
basicBadgeDemo: () =>
|
|
17
|
-
colorBadgeDemo: () =>
|
|
18
|
-
typeBadgeDemo: () =>
|
|
19
|
-
maxBadgeDemo: () =>
|
|
20
|
-
accessibilityBadgeDemo: () =>
|
|
21
|
-
invisibilityBadgeDemo: () =>
|
|
22
|
-
complexInteractionBadgeDemo: () =>
|
|
23
|
-
specialContentBadgeDemo: () =>
|
|
15
|
+
basicBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
colorBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
typeBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
maxBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
accessibilityBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
invisibilityBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
complexInteractionBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
22
|
+
specialContentBadgeDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
24
23
|
};
|
|
25
24
|
export default _default;
|
|
@@ -1,51 +1,84 @@
|
|
|
1
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
1
2
|
import * as React from "react";
|
|
2
3
|
import Badge from "../../Badge";
|
|
3
4
|
const basicBadgeDemo = () => {
|
|
4
|
-
return /* @__PURE__ */
|
|
5
|
+
return /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(Badge, { content: "12", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "\u5185\u5BB9" }) }) });
|
|
5
6
|
};
|
|
6
7
|
const colorBadgeDemo = () => {
|
|
7
|
-
return /* @__PURE__ */
|
|
8
|
+
return /* @__PURE__ */ jsxs("div", { style: { display: "flex", gap: "10px" }, children: [
|
|
9
|
+
/* @__PURE__ */ jsx(Badge, { content: "1", color: "primary", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "Primary" }) }),
|
|
10
|
+
/* @__PURE__ */ jsx(Badge, { content: "2", color: "success", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "Success" }) }),
|
|
11
|
+
/* @__PURE__ */ jsx(Badge, { content: "3", color: "warning", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "Warning" }) }),
|
|
12
|
+
/* @__PURE__ */ jsx(Badge, { content: "4", color: "danger", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "Danger" }) })
|
|
13
|
+
] });
|
|
8
14
|
};
|
|
9
15
|
const typeBadgeDemo = () => {
|
|
10
|
-
return /* @__PURE__ */
|
|
16
|
+
return /* @__PURE__ */ jsxs("div", { style: { display: "flex", gap: "10px" }, children: [
|
|
17
|
+
/* @__PURE__ */ jsx(Badge, { content: "99", type: "standard", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "Standard" }) }),
|
|
18
|
+
/* @__PURE__ */ jsx(Badge, { type: "dot", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "Dot" }) }),
|
|
19
|
+
/* @__PURE__ */ jsx(Badge, { content: "NEW", type: "bubble", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "Bubble" }) })
|
|
20
|
+
] });
|
|
11
21
|
};
|
|
12
22
|
const maxBadgeDemo = () => {
|
|
13
|
-
return /* @__PURE__ */
|
|
23
|
+
return /* @__PURE__ */ jsxs("div", { style: { display: "flex", gap: "10px" }, children: [
|
|
24
|
+
/* @__PURE__ */ jsx(Badge, { content: 99, max: 50, children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "50+" }) }),
|
|
25
|
+
/* @__PURE__ */ jsx(Badge, { content: 150, max: 99, children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "99+" }) })
|
|
26
|
+
] });
|
|
14
27
|
};
|
|
15
28
|
const accessibilityBadgeDemo = () => {
|
|
16
|
-
return /* @__PURE__ */
|
|
29
|
+
return /* @__PURE__ */ jsxs("div", { style: { display: "flex", gap: "10px", flexDirection: "column" }, children: [
|
|
30
|
+
/* @__PURE__ */ jsx(Badge, { content: 5, "aria-label": "\u81EA\u5B9A\u4E49\u6807\u7B7E", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "\u81EA\u5B9A\u4E49\u6807\u7B7E" }) }),
|
|
31
|
+
/* @__PURE__ */ jsx(Badge, { content: 3, role: "img", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "\u81EA\u5B9A\u4E49\u89D2\u8272" }) }),
|
|
32
|
+
/* @__PURE__ */ jsx(Badge, { content: 1, "aria-hidden": true, children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "\u9690\u85CF\u89D2\u8272" }) }),
|
|
33
|
+
/* @__PURE__ */ jsx(Badge, { content: 2, "aria-hidden": true, children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "\u9690\u85CF" }) })
|
|
34
|
+
] });
|
|
17
35
|
};
|
|
18
36
|
const invisibilityBadgeDemo = () => {
|
|
19
|
-
return /* @__PURE__ */
|
|
37
|
+
return /* @__PURE__ */ jsxs("div", { style: { display: "flex", gap: "10px" }, children: [
|
|
38
|
+
/* @__PURE__ */ jsx(Badge, { content: 0, showZero: true, children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "ShowZero" }) }),
|
|
39
|
+
/* @__PURE__ */ jsx(Badge, { content: 0, showZero: false, children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "HideZero" }) }),
|
|
40
|
+
/* @__PURE__ */ jsx(Badge, { content: 5, invisible: false, children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "Visible" }) })
|
|
41
|
+
] });
|
|
20
42
|
};
|
|
21
43
|
const complexInteractionBadgeDemo = () => {
|
|
22
44
|
const ComplexInteractionBadgeDemo = () => {
|
|
23
45
|
const [count, setCount] = React.useState(1);
|
|
24
46
|
const [visible, setVisible] = React.useState(true);
|
|
25
|
-
return /* @__PURE__ */
|
|
26
|
-
"
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
47
|
+
return /* @__PURE__ */ jsxs("div", { style: { display: "flex", gap: "10px", alignItems: "center" }, children: [
|
|
48
|
+
/* @__PURE__ */ jsx(Badge, { content: count, invisible: !visible, children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "\u5185\u5BB9" }) }),
|
|
49
|
+
/* @__PURE__ */ jsxs(
|
|
50
|
+
"button",
|
|
51
|
+
{
|
|
52
|
+
type: "button",
|
|
53
|
+
onClick: () => setCount(count + 1),
|
|
54
|
+
style: { padding: "4px 8px" },
|
|
55
|
+
children: [
|
|
56
|
+
"\u589E\u52A0(",
|
|
57
|
+
count,
|
|
58
|
+
")"
|
|
59
|
+
]
|
|
60
|
+
}
|
|
61
|
+
),
|
|
62
|
+
/* @__PURE__ */ jsx(
|
|
63
|
+
"button",
|
|
64
|
+
{
|
|
65
|
+
type: "button",
|
|
66
|
+
onClick: () => setVisible(!visible),
|
|
67
|
+
style: { padding: "4px 8px" },
|
|
68
|
+
children: visible ? "\u9690\u85CF" : "\u663E\u793A"
|
|
69
|
+
}
|
|
70
|
+
)
|
|
71
|
+
] });
|
|
44
72
|
};
|
|
45
|
-
return /* @__PURE__ */
|
|
73
|
+
return /* @__PURE__ */ jsx(ComplexInteractionBadgeDemo, {});
|
|
46
74
|
};
|
|
47
75
|
const specialContentBadgeDemo = () => {
|
|
48
|
-
return /* @__PURE__ */
|
|
76
|
+
return /* @__PURE__ */ jsxs("div", { style: { display: "flex", gap: "10px", flexWrap: "wrap" }, children: [
|
|
77
|
+
/* @__PURE__ */ jsx(Badge, { content: "NEW", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "\u6587\u672C" }) }),
|
|
78
|
+
/* @__PURE__ */ jsx(Badge, { content: "99+", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "99+" }) }),
|
|
79
|
+
/* @__PURE__ */ jsx(Badge, { content: 1, children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "\u5355\u6570" }) }),
|
|
80
|
+
/* @__PURE__ */ jsx(Badge, { content: "", children: /* @__PURE__ */ jsx("div", { style: { width: 40, height: 40, background: "#f0f0f0" }, children: "\u7A7A\u5185\u5BB9" }) })
|
|
81
|
+
] });
|
|
49
82
|
};
|
|
50
83
|
var A11yDemos_default = {
|
|
51
84
|
basicBadgeDemo,
|
package/es/Badge/index.css
CHANGED
|
@@ -8,7 +8,7 @@ xhs-page {
|
|
|
8
8
|
--bui-badge-padding: 0 3px;
|
|
9
9
|
--bui-badge-border-radius: 8px;
|
|
10
10
|
--bui-badge-outlined-padding: 0 2px;
|
|
11
|
-
--bui-badge-dot-size:
|
|
11
|
+
--bui-badge-dot-size: 10px;
|
|
12
12
|
--bui-badge-bubble-padding: 0 5px;
|
|
13
13
|
--bui-badge-bubble-border-radius: 6px 6px 6px 0;
|
|
14
14
|
}
|
|
@@ -89,7 +89,7 @@ xhs-page {
|
|
|
89
89
|
padding: var(--bui-badge-bubble-padding);
|
|
90
90
|
}
|
|
91
91
|
.bui-badge-outlined {
|
|
92
|
-
background: var(--bui-color-bg-view);
|
|
92
|
+
background-color: var(--bui-color-bg-view);
|
|
93
93
|
}
|
|
94
94
|
.bui-badge-outlined.bui-badge-primary {
|
|
95
95
|
border: 1px solid var(--bui-color-primary);
|
|
@@ -112,7 +112,7 @@ xhs-page {
|
|
|
112
112
|
color: var(--bui-color-danger);
|
|
113
113
|
}
|
|
114
114
|
.bui-badge-outlined.bui-badge-light {
|
|
115
|
-
background: var(--bui-color-bg-default);
|
|
115
|
+
background-color: var(--bui-color-bg-default);
|
|
116
116
|
border: 1px solid var(--bui-color-bg-view);
|
|
117
117
|
color: var(--bui-color-bg-view);
|
|
118
118
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { BreadcrumbProps } from './Breadcrumb.types';
|
|
3
3
|
import './index.less';
|
|
4
|
-
declare const Breadcrumb: React.ForwardRefExoticComponent<Omit<BreadcrumbProps
|
|
4
|
+
declare const Breadcrumb: React.ForwardRefExoticComponent<Omit<BreadcrumbProps, "ref"> & React.RefAttributes<HTMLElement>>;
|
|
5
5
|
export default Breadcrumb;
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
var __defProp = Object.defineProperty;
|
|
2
|
+
var __defProps = Object.defineProperties;
|
|
3
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
2
4
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
3
5
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
4
6
|
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
@@ -14,6 +16,7 @@ var __spreadValues = (a, b) => {
|
|
|
14
16
|
}
|
|
15
17
|
return a;
|
|
16
18
|
};
|
|
19
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
17
20
|
var __objRest = (source, exclude) => {
|
|
18
21
|
var target = {};
|
|
19
22
|
for (var prop in source)
|
|
@@ -26,6 +29,7 @@ var __objRest = (source, exclude) => {
|
|
|
26
29
|
}
|
|
27
30
|
return target;
|
|
28
31
|
};
|
|
32
|
+
import { jsx } from "react/jsx-runtime";
|
|
29
33
|
import * as React from "react";
|
|
30
34
|
import clsx from "clsx";
|
|
31
35
|
import BreadcrumbItem from "./BreadcrumbItem";
|
|
@@ -51,13 +55,14 @@ const Breadcrumb = /* @__PURE__ */ React.forwardRef(
|
|
|
51
55
|
return items.map((item, index) => {
|
|
52
56
|
const _a2 = item, { title } = _a2, otherItemProps = __objRest(_a2, ["title"]);
|
|
53
57
|
const isLast = index === items.length - 1;
|
|
54
|
-
return /* @__PURE__ */
|
|
58
|
+
return /* @__PURE__ */ jsx(
|
|
55
59
|
BreadcrumbItem,
|
|
56
|
-
__spreadValues({
|
|
57
|
-
key: index,
|
|
60
|
+
__spreadProps(__spreadValues({
|
|
58
61
|
separator: isLast ? "" : separator
|
|
59
|
-
}, otherItemProps),
|
|
60
|
-
|
|
62
|
+
}, otherItemProps), {
|
|
63
|
+
children: title
|
|
64
|
+
}),
|
|
65
|
+
index
|
|
61
66
|
);
|
|
62
67
|
});
|
|
63
68
|
}
|
|
@@ -71,7 +76,10 @@ const Breadcrumb = /* @__PURE__ */ React.forwardRef(
|
|
|
71
76
|
const newProps = {
|
|
72
77
|
separator: index === childrenLength - 1 ? "" : itemSeparator
|
|
73
78
|
};
|
|
74
|
-
return React.cloneElement(
|
|
79
|
+
return React.cloneElement(
|
|
80
|
+
child,
|
|
81
|
+
newProps
|
|
82
|
+
);
|
|
75
83
|
}
|
|
76
84
|
return child;
|
|
77
85
|
}
|
|
@@ -83,14 +91,15 @@ const Breadcrumb = /* @__PURE__ */ React.forwardRef(
|
|
|
83
91
|
if (items == null && children == null) {
|
|
84
92
|
return null;
|
|
85
93
|
}
|
|
86
|
-
return /* @__PURE__ */
|
|
94
|
+
return /* @__PURE__ */ jsx(
|
|
87
95
|
"nav",
|
|
88
|
-
__spreadValues({
|
|
96
|
+
__spreadProps(__spreadValues({
|
|
89
97
|
className: clsx(prefixCls, className),
|
|
90
98
|
style,
|
|
91
99
|
ref
|
|
92
|
-
}, others),
|
|
93
|
-
|
|
100
|
+
}, others), {
|
|
101
|
+
children: /* @__PURE__ */ jsx("ol", { className: `${prefixCls}-list`, children: renderList() })
|
|
102
|
+
})
|
|
94
103
|
);
|
|
95
104
|
}
|
|
96
105
|
);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { BreadcrumbItemProps } from './Breadcrumb.types';
|
|
3
|
-
declare const BreadcrumbItem: React.ForwardRefExoticComponent<Omit<BreadcrumbItemProps
|
|
3
|
+
declare const BreadcrumbItem: React.ForwardRefExoticComponent<Omit<BreadcrumbItemProps, "ref"> & React.RefAttributes<HTMLLIElement>>;
|
|
4
4
|
export default BreadcrumbItem;
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
var __defProp = Object.defineProperty;
|
|
2
|
+
var __defProps = Object.defineProperties;
|
|
3
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
2
4
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
3
5
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
4
6
|
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
@@ -14,6 +16,7 @@ var __spreadValues = (a, b) => {
|
|
|
14
16
|
}
|
|
15
17
|
return a;
|
|
16
18
|
};
|
|
19
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
17
20
|
var __objRest = (source, exclude) => {
|
|
18
21
|
var target = {};
|
|
19
22
|
for (var prop in source)
|
|
@@ -26,22 +29,27 @@ var __objRest = (source, exclude) => {
|
|
|
26
29
|
}
|
|
27
30
|
return target;
|
|
28
31
|
};
|
|
32
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
29
33
|
import * as React from "react";
|
|
30
34
|
import clsx from "clsx";
|
|
31
35
|
const prefixCls = "bui-breadcrumb-item";
|
|
32
36
|
const BreadcrumbItem = /* @__PURE__ */ React.forwardRef(
|
|
33
37
|
(props, ref) => {
|
|
34
38
|
const _a = props, { className, style, separator, children, onClick } = _a, others = __objRest(_a, ["className", "style", "separator", "children", "onClick"]);
|
|
35
|
-
return /* @__PURE__ */
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
39
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
40
|
+
/* @__PURE__ */ jsx(
|
|
41
|
+
"li",
|
|
42
|
+
__spreadProps(__spreadValues({
|
|
43
|
+
className: clsx(`${prefixCls}`, className),
|
|
44
|
+
style,
|
|
45
|
+
ref,
|
|
46
|
+
onClick
|
|
47
|
+
}, others), {
|
|
48
|
+
children
|
|
49
|
+
})
|
|
50
|
+
),
|
|
51
|
+
separator && /* @__PURE__ */ jsx("li", { className: `${prefixCls}-separator`, children: separator })
|
|
52
|
+
] });
|
|
45
53
|
}
|
|
46
54
|
);
|
|
47
55
|
BreadcrumbItem.displayName = "BuiBreadcrumbItem";
|
package/es/Button/Button.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { ButtonProps } from './Button.types';
|
|
3
3
|
import './index.less';
|
|
4
|
-
declare const Button: React.ForwardRefExoticComponent<Omit<ButtonProps
|
|
4
|
+
declare const Button: React.ForwardRefExoticComponent<Omit<ButtonProps, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
5
5
|
export default Button;
|
package/es/Button/Button.js
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
var __defProp = Object.defineProperty;
|
|
2
|
+
var __defProps = Object.defineProperties;
|
|
3
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
2
4
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
3
5
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
4
6
|
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
@@ -14,6 +16,7 @@ var __spreadValues = (a, b) => {
|
|
|
14
16
|
}
|
|
15
17
|
return a;
|
|
16
18
|
};
|
|
19
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
17
20
|
var __objRest = (source, exclude) => {
|
|
18
21
|
var target = {};
|
|
19
22
|
for (var prop in source)
|
|
@@ -26,12 +29,13 @@ var __objRest = (source, exclude) => {
|
|
|
26
29
|
}
|
|
27
30
|
return target;
|
|
28
31
|
};
|
|
32
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
29
33
|
import clsx from "clsx";
|
|
30
34
|
import * as React from "react";
|
|
31
35
|
import "./index.css";
|
|
32
36
|
const prefixCls = "bui-btn";
|
|
33
37
|
const ButtonIcon = ({ children, iconPosition }) => {
|
|
34
|
-
return /* @__PURE__ */
|
|
38
|
+
return /* @__PURE__ */ jsx("span", { className: `${prefixCls}-icon-${iconPosition}`, children });
|
|
35
39
|
};
|
|
36
40
|
const Button = /* @__PURE__ */ React.forwardRef(
|
|
37
41
|
(props, ref) => {
|
|
@@ -54,9 +58,9 @@ const Button = /* @__PURE__ */ React.forwardRef(
|
|
|
54
58
|
"color",
|
|
55
59
|
"disabled"
|
|
56
60
|
]);
|
|
57
|
-
return /* @__PURE__ */
|
|
61
|
+
return /* @__PURE__ */ jsxs(
|
|
58
62
|
"button",
|
|
59
|
-
__spreadValues({
|
|
63
|
+
__spreadProps(__spreadValues({
|
|
60
64
|
type: "button",
|
|
61
65
|
className: clsx(
|
|
62
66
|
prefixCls,
|
|
@@ -71,10 +75,13 @@ const Button = /* @__PURE__ */ React.forwardRef(
|
|
|
71
75
|
ref,
|
|
72
76
|
disabled,
|
|
73
77
|
"aria-disabled": disabled ? "true" : void 0
|
|
74
|
-
}, others),
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
+
}, others), {
|
|
79
|
+
children: [
|
|
80
|
+
startIcon && /* @__PURE__ */ jsx(ButtonIcon, { iconPosition: "start", children: startIcon }),
|
|
81
|
+
children,
|
|
82
|
+
endIcon && /* @__PURE__ */ jsx(ButtonIcon, { iconPosition: "end", children: endIcon })
|
|
83
|
+
]
|
|
84
|
+
})
|
|
78
85
|
);
|
|
79
86
|
}
|
|
80
87
|
);
|
|
@@ -1,23 +1,22 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
/**
|
|
3
2
|
* 自定义 Button 组件 Demo 集合
|
|
4
3
|
* 这个文件包含多个测试 demo,展示如何使用 getCustomDemoCodesFromFile 进行无障碍测试
|
|
5
4
|
* 文件名必须是 customDemoComponent.tsx(固定约定)
|
|
6
5
|
*/
|
|
7
|
-
export declare const basicButtonDemo: () =>
|
|
8
|
-
export declare const variantButtonDemo: () =>
|
|
9
|
-
export declare const colorButtonDemo: () =>
|
|
10
|
-
export declare const sizeButtonDemo: () =>
|
|
11
|
-
export declare const disabledButtonDemo: () =>
|
|
12
|
-
export declare const iconButtonDemo: () =>
|
|
13
|
-
export declare const ariaLabelButtonDemo: () =>
|
|
6
|
+
export declare const basicButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare const variantButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export declare const colorButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export declare const sizeButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export declare const disabledButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export declare const iconButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export declare const ariaLabelButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
14
13
|
declare const _default: {
|
|
15
|
-
basicButtonDemo: () =>
|
|
16
|
-
variantButtonDemo: () =>
|
|
17
|
-
colorButtonDemo: () =>
|
|
18
|
-
sizeButtonDemo: () =>
|
|
19
|
-
disabledButtonDemo: () =>
|
|
20
|
-
iconButtonDemo: () =>
|
|
21
|
-
ariaLabelButtonDemo: () =>
|
|
14
|
+
basicButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
variantButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
colorButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
sizeButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
disabledButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
iconButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
ariaLabelButtonDemo: () => import("react/jsx-runtime").JSX.Element;
|
|
22
21
|
};
|
|
23
22
|
export default _default;
|
|
@@ -1,25 +1,49 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import Button from "../../Button";
|
|
3
3
|
const basicButtonDemo = () => {
|
|
4
|
-
return /* @__PURE__ */
|
|
4
|
+
return /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(Button, { children: "\u57FA\u7840\u6309\u94AE" }) });
|
|
5
5
|
};
|
|
6
6
|
const variantButtonDemo = () => {
|
|
7
|
-
return /* @__PURE__ */
|
|
7
|
+
return /* @__PURE__ */ jsxs("div", { children: [
|
|
8
|
+
/* @__PURE__ */ jsx(Button, { variant: "text", children: "\u6587\u5B57\u6309\u94AE" }),
|
|
9
|
+
/* @__PURE__ */ jsx(Button, { variant: "outlined", children: "\u7EBF\u6846\u6309\u94AE" }),
|
|
10
|
+
/* @__PURE__ */ jsx(Button, { variant: "contained", children: "\u586B\u5145\u6309\u94AE" }),
|
|
11
|
+
/* @__PURE__ */ jsx(Button, { variant: "subtle", children: "\u67D4\u548C\u6309\u94AE" })
|
|
12
|
+
] });
|
|
8
13
|
};
|
|
9
14
|
const colorButtonDemo = () => {
|
|
10
|
-
return /* @__PURE__ */
|
|
15
|
+
return /* @__PURE__ */ jsxs("div", { children: [
|
|
16
|
+
/* @__PURE__ */ jsx(Button, { color: "primary", children: "\u4E3B\u8981\u6309\u94AE" }),
|
|
17
|
+
/* @__PURE__ */ jsx(Button, { color: "success", children: "\u6210\u529F\u6309\u94AE" }),
|
|
18
|
+
/* @__PURE__ */ jsx(Button, { color: "warning", children: "\u8B66\u544A\u6309\u94AE" }),
|
|
19
|
+
/* @__PURE__ */ jsx(Button, { color: "danger", children: "\u5371\u9669\u6309\u94AE" })
|
|
20
|
+
] });
|
|
11
21
|
};
|
|
12
22
|
const sizeButtonDemo = () => {
|
|
13
|
-
return /* @__PURE__ */
|
|
23
|
+
return /* @__PURE__ */ jsxs("div", { children: [
|
|
24
|
+
/* @__PURE__ */ jsx(Button, { size: "small", children: "\u5C0F\u6309\u94AE" }),
|
|
25
|
+
/* @__PURE__ */ jsx(Button, { size: "medium", children: "\u4E2D\u6309\u94AE" }),
|
|
26
|
+
/* @__PURE__ */ jsx(Button, { size: "large", children: "\u5927\u6309\u94AE" }),
|
|
27
|
+
/* @__PURE__ */ jsx(Button, { size: "full", style: { width: "200px" }, children: "\u5168\u5BBD\u6309\u94AE" })
|
|
28
|
+
] });
|
|
14
29
|
};
|
|
15
30
|
const disabledButtonDemo = () => {
|
|
16
|
-
return /* @__PURE__ */
|
|
31
|
+
return /* @__PURE__ */ jsxs("div", { children: [
|
|
32
|
+
/* @__PURE__ */ jsx(Button, { disabled: true, children: "\u7981\u7528\u6309\u94AE" }),
|
|
33
|
+
/* @__PURE__ */ jsx(Button, { variant: "contained", disabled: true, children: "\u7981\u7528\u586B\u5145\u6309\u94AE" })
|
|
34
|
+
] });
|
|
17
35
|
};
|
|
18
36
|
const iconButtonDemo = () => {
|
|
19
|
-
return /* @__PURE__ */
|
|
37
|
+
return /* @__PURE__ */ jsxs("div", { children: [
|
|
38
|
+
/* @__PURE__ */ jsx(Button, { startIcon: /* @__PURE__ */ jsx("span", { children: "\u{1F31F}" }), children: "\u5E26\u524D\u7F00\u56FE\u6807" }),
|
|
39
|
+
/* @__PURE__ */ jsx(Button, { endIcon: /* @__PURE__ */ jsx("span", { children: "\u{1F4C5}" }), children: "\u5E26\u540E\u7F00\u56FE\u6807" })
|
|
40
|
+
] });
|
|
20
41
|
};
|
|
21
42
|
const ariaLabelButtonDemo = () => {
|
|
22
|
-
return /* @__PURE__ */
|
|
43
|
+
return /* @__PURE__ */ jsxs("div", { children: [
|
|
44
|
+
/* @__PURE__ */ jsx(Button, { "aria-label": "\u63D0\u4EA4\u8868\u5355", children: "\u63D0\u4EA4" }),
|
|
45
|
+
/* @__PURE__ */ jsx(Button, { "aria-label": "\u53D6\u6D88\u64CD\u4F5C", children: "\u53D6\u6D88" })
|
|
46
|
+
] });
|
|
23
47
|
};
|
|
24
48
|
var A11yDemos_default = {
|
|
25
49
|
basicButtonDemo,
|
|
@@ -29,6 +29,7 @@ var __objRest = (source, exclude) => {
|
|
|
29
29
|
}
|
|
30
30
|
return target;
|
|
31
31
|
};
|
|
32
|
+
import { jsx } from "react/jsx-runtime";
|
|
32
33
|
import React, { useRef } from "react";
|
|
33
34
|
import {
|
|
34
35
|
addClass as addOneClass,
|
|
@@ -130,7 +131,7 @@ const CSSTransition = /* @__PURE__ */ React.forwardRef(
|
|
|
130
131
|
props.onExited(node);
|
|
131
132
|
}
|
|
132
133
|
};
|
|
133
|
-
return /* @__PURE__ */
|
|
134
|
+
return /* @__PURE__ */ jsx(
|
|
134
135
|
Transition,
|
|
135
136
|
__spreadProps(__spreadValues({
|
|
136
137
|
ref,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { useState } from "react";
|
|
2
3
|
import { Button, Alert, CSSTransition } from "@bifrostui/react";
|
|
3
4
|
import "./index.css";
|
|
4
5
|
const StackDemo = () => {
|
|
@@ -11,37 +12,39 @@ const StackDemo = () => {
|
|
|
11
12
|
exitActive: "slide-exit-active",
|
|
12
13
|
exitDone: "slide-exit-done"
|
|
13
14
|
};
|
|
14
|
-
return /* @__PURE__ */
|
|
15
|
+
return /* @__PURE__ */ jsxs(
|
|
15
16
|
"div",
|
|
16
17
|
{
|
|
17
18
|
style: {
|
|
18
19
|
width: "300px",
|
|
19
20
|
height: "100px",
|
|
20
21
|
overflow: "hidden"
|
|
21
|
-
}
|
|
22
|
-
},
|
|
23
|
-
/* @__PURE__ */ React.createElement(
|
|
24
|
-
Button,
|
|
25
|
-
{
|
|
26
|
-
onClick: () => {
|
|
27
|
-
setOpen((prev) => !prev);
|
|
28
|
-
},
|
|
29
|
-
style: {
|
|
30
|
-
marginBottom: "18px"
|
|
31
|
-
}
|
|
32
22
|
},
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
23
|
+
children: [
|
|
24
|
+
/* @__PURE__ */ jsx(
|
|
25
|
+
Button,
|
|
26
|
+
{
|
|
27
|
+
onClick: () => {
|
|
28
|
+
setOpen((prev) => !prev);
|
|
29
|
+
},
|
|
30
|
+
style: {
|
|
31
|
+
marginBottom: "18px"
|
|
32
|
+
},
|
|
33
|
+
children: open ? "Exit" : "Enter"
|
|
34
|
+
}
|
|
35
|
+
),
|
|
36
|
+
/* @__PURE__ */ jsx(
|
|
37
|
+
CSSTransition,
|
|
38
|
+
{
|
|
39
|
+
in: open,
|
|
40
|
+
timeout: 300,
|
|
41
|
+
unmountOnExit: false,
|
|
42
|
+
classNames: transitionClasses,
|
|
43
|
+
children: /* @__PURE__ */ jsx(Alert, { className: "my-node", color: "success", children: "\u8FC7\u6E21\u8FC7\u7A0B\u4E2D\u4F1A\u4FEE\u6539className" })
|
|
44
|
+
}
|
|
45
|
+
)
|
|
46
|
+
]
|
|
47
|
+
}
|
|
45
48
|
);
|
|
46
49
|
};
|
|
47
50
|
var CSSTransitionDemo_default = StackDemo;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { CalendarProps } from './Calendar.types';
|
|
3
3
|
import './index.less';
|
|
4
|
-
declare const Calendar: React.ForwardRefExoticComponent<Omit<CalendarProps
|
|
4
|
+
declare const Calendar: React.ForwardRefExoticComponent<Omit<CalendarProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
5
5
|
export default Calendar;
|