@arco-design/mobile-react 2.30.1 → 2.30.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +24 -0
- package/README.en-US.md +2 -2
- package/README.md +2 -2
- package/cjs/form/type.d.ts +2 -2
- package/cjs/image-preview/index.d.ts +6 -0
- package/cjs/image-preview/index.js +48 -14
- package/cjs/image-preview/style/css/index.css +2 -1
- package/cjs/image-preview/style/index.less +2 -1
- package/cjs/nav-bar/back-icon.js +20 -10
- package/cjs/picker-view/components/picker-cell.js +1 -1
- package/cjs/picker-view/index.js +1 -1
- package/cjs/popover/style/css/index.css +9 -2
- package/cjs/popover/style/css/menu.css +4 -0
- package/cjs/popover/style/index.less +1 -2
- package/cjs/popover/style/menu.less +1 -1
- package/cjs/slider/hooks/useSliderEvents.js +14 -8
- package/cjs/slider/hooks/useSliderStyle.js +13 -7
- package/cjs/slider/index.js +4 -2
- package/cjs/slider/marks.js +4 -2
- package/cjs/slider/style/css/index.css +28 -0
- package/cjs/slider/style/index.less +13 -4
- package/dist/index.js +118 -64
- package/dist/index.min.js +4 -4
- package/dist/style.css +39 -3
- package/dist/style.min.css +1 -1
- package/esm/form/type.d.ts +2 -2
- package/esm/image-preview/index.d.ts +6 -0
- package/esm/image-preview/index.js +48 -14
- package/esm/image-preview/style/css/index.css +2 -1
- package/esm/image-preview/style/index.less +2 -1
- package/esm/nav-bar/back-icon.js +18 -10
- package/esm/picker-view/components/picker-cell.js +1 -1
- package/esm/picker-view/index.js +1 -1
- package/esm/popover/style/css/index.css +9 -2
- package/esm/popover/style/css/menu.css +4 -0
- package/esm/popover/style/index.less +1 -2
- package/esm/popover/style/menu.less +1 -1
- package/esm/slider/hooks/useSliderEvents.js +13 -8
- package/esm/slider/hooks/useSliderStyle.js +12 -7
- package/esm/slider/index.js +4 -2
- package/esm/slider/marks.js +4 -2
- package/esm/slider/style/css/index.css +28 -0
- package/esm/slider/style/index.less +13 -4
- package/package.json +3 -3
- package/style/css/public.css +2 -0
- package/tokens/app/arcodesign/default/css-variables.less +1 -1
- package/tokens/app/arcodesign/default/index.d.ts +1 -1
- package/tokens/app/arcodesign/default/index.js +1 -1
- package/tokens/app/arcodesign/default/index.json +7 -7
- package/tokens/app/arcodesign/default/index.less +1 -1
- package/umd/form/type.d.ts +2 -2
- package/umd/image-preview/index.d.ts +6 -0
- package/umd/image-preview/index.js +48 -14
- package/umd/image-preview/style/css/index.css +2 -1
- package/umd/image-preview/style/index.less +2 -1
- package/umd/nav-bar/back-icon.js +20 -14
- package/umd/picker-view/components/picker-cell.js +1 -1
- package/umd/picker-view/index.js +1 -1
- package/umd/popover/style/css/index.css +9 -2
- package/umd/popover/style/css/menu.css +4 -0
- package/umd/popover/style/index.less +1 -2
- package/umd/popover/style/menu.less +1 -1
- package/umd/slider/hooks/useSliderEvents.js +16 -12
- package/umd/slider/hooks/useSliderStyle.js +15 -11
- package/umd/slider/index.js +4 -2
- package/umd/slider/marks.js +4 -2
- package/umd/slider/style/css/index.css +28 -0
- package/umd/slider/style/index.less +13 -4
- package/cjs/action-sheet/demo/style/css/mobile.css +0 -523
- package/cjs/action-sheet/demo/style/mobile.less +0 -52
- package/cjs/avatar/demo/style/css/mobile.css +0 -578
- package/cjs/avatar/demo/style/mobile.less +0 -96
- package/cjs/badge/demo/style/css/mobile.css +0 -580
- package/cjs/badge/demo/style/mobile.less +0 -107
- package/cjs/button/demo/style/css/mobile.css +0 -530
- package/cjs/button/demo/style/mobile.less +0 -44
- package/cjs/carousel/demo/style/css/mobile.css +0 -553
- package/cjs/carousel/demo/style/mobile.less +0 -70
- package/cjs/cell/demo/style/css/mobile.css +0 -585
- package/cjs/cell/demo/style/mobile.less +0 -102
- package/cjs/checkbox/demo/style/css/mobile.css +0 -520
- package/cjs/checkbox/demo/style/mobile.less +0 -45
- package/cjs/circle-progress/demo/style/css/mobile.css +0 -516
- package/cjs/circle-progress/demo/style/mobile.less +0 -34
- package/cjs/collapse/demo/style/css/mobile.css +0 -516
- package/cjs/collapse/demo/style/mobile.less +0 -33
- package/cjs/context-provider/demo/style/css/mobile.css +0 -520
- package/cjs/context-provider/demo/style/mobile.less +0 -37
- package/cjs/count-down/demo/style/css/mobile.css +0 -575
- package/cjs/count-down/demo/style/mobile.less +0 -96
- package/cjs/date-picker/demo/style/css/mobile.css +0 -520
- package/cjs/date-picker/demo/style/mobile.less +0 -37
- package/cjs/dialog/demo/style/css/mobile.css +0 -548
- package/cjs/dialog/demo/style/mobile.less +0 -80
- package/cjs/divider/demo/style/css/mobile.css +0 -516
- package/cjs/divider/demo/style/mobile.less +0 -36
- package/cjs/dropdown/demo/style/css/mobile.css +0 -515
- package/cjs/dropdown/demo/style/mobile.less +0 -32
- package/cjs/dropdown-menu/demo/style/css/mobile.css +0 -516
- package/cjs/dropdown-menu/demo/style/mobile.less +0 -33
- package/cjs/ellipsis/demo/style/css/mobile.css +0 -528
- package/cjs/ellipsis/demo/style/mobile.less +0 -53
- package/cjs/grid/demo/style/css/mobile.css +0 -613
- package/cjs/grid/demo/style/mobile.less +0 -157
- package/cjs/image/demo/style/css/mobile.css +0 -580
- package/cjs/image/demo/style/mobile.less +0 -86
- package/cjs/image-picker/demo/style/css/mobile.css +0 -550
- package/cjs/image-picker/demo/style/mobile.less +0 -67
- package/cjs/image-preview/demo/style/css/mobile.css +0 -551
- package/cjs/image-preview/demo/style/mobile.less +0 -61
- package/cjs/index-bar/demo/style/css/mobile.css +0 -533
- package/cjs/index-bar/demo/style/mobile.less +0 -51
- package/cjs/input/demo/style/css/mobile.css +0 -602
- package/cjs/input/demo/style/mobile.less +0 -132
- package/cjs/keyboard/demo/style/css/mobile.css +0 -520
- package/cjs/keyboard/demo/style/mobile.less +0 -42
- package/cjs/load-more/demo/style/css/mobile.css +0 -520
- package/cjs/load-more/demo/style/mobile.less +0 -39
- package/cjs/loading/demo/style/css/mobile.css +0 -529
- package/cjs/loading/demo/style/mobile.less +0 -48
- package/cjs/masking/demo/style/css/mobile.css +0 -535
- package/cjs/masking/demo/style/mobile.less +0 -56
- package/cjs/nav-bar/demo/style/css/mobile.css +0 -523
- package/cjs/nav-bar/demo/style/mobile.less +0 -46
- package/cjs/notice-bar/demo/style/css/mobile.css +0 -4
- package/cjs/notice-bar/demo/style/mobile.less +0 -6
- package/cjs/notify/demo/style/css/mobile.css +0 -545
- package/cjs/notify/demo/style/mobile.less +0 -60
- package/cjs/pagination/demo/style/css/index.css +0 -516
- package/cjs/pagination/demo/style/index.less +0 -35
- package/cjs/picker/demo/style/css/mobile.css +0 -531
- package/cjs/picker/demo/style/mobile.less +0 -49
- package/cjs/picker-view/demo/style/css/mobile.css +0 -513
- package/cjs/picker-view/demo/style/mobile.less +0 -32
- package/cjs/popover/demo/style/css/mobile.css +0 -649
- package/cjs/popover/demo/style/mobile.less +0 -135
- package/cjs/popup/demo/style/css/mobile.css +0 -540
- package/cjs/popup/demo/style/mobile.less +0 -66
- package/cjs/popup-swiper/demo/style/css/mobile.css +0 -540
- package/cjs/popup-swiper/demo/style/mobile.less +0 -66
- package/cjs/portal/demo/style/css/mobile.css +0 -527
- package/cjs/portal/demo/style/mobile.less +0 -48
- package/cjs/progress/demo/style/css/mobile.css +0 -520
- package/cjs/progress/demo/style/mobile.less +0 -39
- package/cjs/pull-refresh/demo/style/css/mobile.css +0 -554
- package/cjs/pull-refresh/demo/style/mobile.less +0 -83
- package/cjs/radio/demo/style/css/mobile.css +0 -529
- package/cjs/radio/demo/style/mobile.less +0 -54
- package/cjs/rate/demo/style/css/mobile.css +0 -514
- package/cjs/rate/demo/style/mobile.less +0 -33
- package/cjs/search-bar/demo/style/css/mobile.css +0 -520
- package/cjs/search-bar/demo/style/mobile.less +0 -43
- package/cjs/show-monitor/demo/style/css/mobile.css +0 -569
- package/cjs/show-monitor/demo/style/mobile.less +0 -90
- package/cjs/skeleton/demo/style/css/mobile.css +0 -517
- package/cjs/skeleton/demo/style/mobile.less +0 -38
- package/cjs/slider/demo/style/css/mobile.css +0 -529
- package/cjs/slider/demo/style/mobile.less +0 -60
- package/cjs/stepper/demo/style/css/mobile.css +0 -514
- package/cjs/stepper/demo/style/mobile.less +0 -34
- package/cjs/steps/demo/style/css/mobile.css +0 -611
- package/cjs/steps/demo/style/mobile.less +0 -75
- package/cjs/sticky/demo/style/css/mobile.css +0 -527
- package/cjs/sticky/demo/style/mobile.less +0 -48
- package/cjs/swipe-action/demo/style/css/mobile.css +0 -515
- package/cjs/swipe-action/demo/style/mobile.less +0 -34
- package/cjs/swipe-load/demo/style/css/mobile.css +0 -580
- package/cjs/swipe-load/demo/style/mobile.less +0 -116
- package/cjs/switch/demo/style/css/mobile.css +0 -524
- package/cjs/switch/demo/style/mobile.less +0 -49
- package/cjs/tab-bar/demo/style/css/mobile.css +0 -553
- package/cjs/tab-bar/demo/style/mobile.less +0 -59
- package/cjs/tabs/demo/style/css/mobile.css +0 -633
- package/cjs/tabs/demo/style/mobile.less +0 -174
- package/cjs/tag/demo/style/css/mobile.css +0 -516
- package/cjs/tag/demo/style/mobile.less +0 -33
- package/cjs/textarea/demo/style/css/mobile.css +0 -523
- package/cjs/textarea/demo/style/mobile.less +0 -47
- package/cjs/toast/demo/style/css/mobile.css +0 -520
- package/cjs/toast/demo/style/mobile.less +0 -37
- package/cjs/transition/demo/style/css/mobile.css +0 -529
- package/cjs/transition/demo/style/mobile.less +0 -47
- package/esm/action-sheet/demo/style/css/mobile.css +0 -523
- package/esm/action-sheet/demo/style/mobile.less +0 -52
- package/esm/avatar/demo/style/css/mobile.css +0 -578
- package/esm/avatar/demo/style/mobile.less +0 -96
- package/esm/badge/demo/style/css/mobile.css +0 -580
- package/esm/badge/demo/style/mobile.less +0 -107
- package/esm/button/demo/style/css/mobile.css +0 -530
- package/esm/button/demo/style/mobile.less +0 -44
- package/esm/carousel/demo/style/css/mobile.css +0 -553
- package/esm/carousel/demo/style/mobile.less +0 -70
- package/esm/cell/demo/style/css/mobile.css +0 -585
- package/esm/cell/demo/style/mobile.less +0 -102
- package/esm/checkbox/demo/style/css/mobile.css +0 -520
- package/esm/checkbox/demo/style/mobile.less +0 -45
- package/esm/circle-progress/demo/style/css/mobile.css +0 -516
- package/esm/circle-progress/demo/style/mobile.less +0 -34
- package/esm/collapse/demo/style/css/mobile.css +0 -516
- package/esm/collapse/demo/style/mobile.less +0 -33
- package/esm/context-provider/demo/style/css/mobile.css +0 -520
- package/esm/context-provider/demo/style/mobile.less +0 -37
- package/esm/count-down/demo/style/css/mobile.css +0 -575
- package/esm/count-down/demo/style/mobile.less +0 -96
- package/esm/date-picker/demo/style/css/mobile.css +0 -520
- package/esm/date-picker/demo/style/mobile.less +0 -37
- package/esm/dialog/demo/style/css/mobile.css +0 -548
- package/esm/dialog/demo/style/mobile.less +0 -80
- package/esm/divider/demo/style/css/mobile.css +0 -516
- package/esm/divider/demo/style/mobile.less +0 -36
- package/esm/dropdown/demo/style/css/mobile.css +0 -515
- package/esm/dropdown/demo/style/mobile.less +0 -32
- package/esm/dropdown-menu/demo/style/css/mobile.css +0 -516
- package/esm/dropdown-menu/demo/style/mobile.less +0 -33
- package/esm/ellipsis/demo/style/css/mobile.css +0 -528
- package/esm/ellipsis/demo/style/mobile.less +0 -53
- package/esm/grid/demo/style/css/mobile.css +0 -613
- package/esm/grid/demo/style/mobile.less +0 -157
- package/esm/image/demo/style/css/mobile.css +0 -580
- package/esm/image/demo/style/mobile.less +0 -86
- package/esm/image-picker/demo/style/css/mobile.css +0 -550
- package/esm/image-picker/demo/style/mobile.less +0 -67
- package/esm/image-preview/demo/style/css/mobile.css +0 -551
- package/esm/image-preview/demo/style/mobile.less +0 -61
- package/esm/index-bar/demo/style/css/mobile.css +0 -533
- package/esm/index-bar/demo/style/mobile.less +0 -51
- package/esm/input/demo/style/css/mobile.css +0 -602
- package/esm/input/demo/style/mobile.less +0 -132
- package/esm/keyboard/demo/style/css/mobile.css +0 -520
- package/esm/keyboard/demo/style/mobile.less +0 -42
- package/esm/load-more/demo/style/css/mobile.css +0 -520
- package/esm/load-more/demo/style/mobile.less +0 -39
- package/esm/loading/demo/style/css/mobile.css +0 -529
- package/esm/loading/demo/style/mobile.less +0 -48
- package/esm/masking/demo/style/css/mobile.css +0 -535
- package/esm/masking/demo/style/mobile.less +0 -56
- package/esm/nav-bar/demo/style/css/mobile.css +0 -523
- package/esm/nav-bar/demo/style/mobile.less +0 -46
- package/esm/notice-bar/demo/style/css/mobile.css +0 -4
- package/esm/notice-bar/demo/style/mobile.less +0 -6
- package/esm/notify/demo/style/css/mobile.css +0 -545
- package/esm/notify/demo/style/mobile.less +0 -60
- package/esm/pagination/demo/style/css/index.css +0 -516
- package/esm/pagination/demo/style/index.less +0 -35
- package/esm/picker/demo/style/css/mobile.css +0 -531
- package/esm/picker/demo/style/mobile.less +0 -49
- package/esm/picker-view/demo/style/css/mobile.css +0 -513
- package/esm/picker-view/demo/style/mobile.less +0 -32
- package/esm/popover/demo/style/css/mobile.css +0 -649
- package/esm/popover/demo/style/mobile.less +0 -135
- package/esm/popup/demo/style/css/mobile.css +0 -540
- package/esm/popup/demo/style/mobile.less +0 -66
- package/esm/popup-swiper/demo/style/css/mobile.css +0 -540
- package/esm/popup-swiper/demo/style/mobile.less +0 -66
- package/esm/portal/demo/style/css/mobile.css +0 -527
- package/esm/portal/demo/style/mobile.less +0 -48
- package/esm/progress/demo/style/css/mobile.css +0 -520
- package/esm/progress/demo/style/mobile.less +0 -39
- package/esm/pull-refresh/demo/style/css/mobile.css +0 -554
- package/esm/pull-refresh/demo/style/mobile.less +0 -83
- package/esm/radio/demo/style/css/mobile.css +0 -529
- package/esm/radio/demo/style/mobile.less +0 -54
- package/esm/rate/demo/style/css/mobile.css +0 -514
- package/esm/rate/demo/style/mobile.less +0 -33
- package/esm/search-bar/demo/style/css/mobile.css +0 -520
- package/esm/search-bar/demo/style/mobile.less +0 -43
- package/esm/show-monitor/demo/style/css/mobile.css +0 -569
- package/esm/show-monitor/demo/style/mobile.less +0 -90
- package/esm/skeleton/demo/style/css/mobile.css +0 -517
- package/esm/skeleton/demo/style/mobile.less +0 -38
- package/esm/slider/demo/style/css/mobile.css +0 -529
- package/esm/slider/demo/style/mobile.less +0 -60
- package/esm/stepper/demo/style/css/mobile.css +0 -514
- package/esm/stepper/demo/style/mobile.less +0 -34
- package/esm/steps/demo/style/css/mobile.css +0 -611
- package/esm/steps/demo/style/mobile.less +0 -75
- package/esm/sticky/demo/style/css/mobile.css +0 -527
- package/esm/sticky/demo/style/mobile.less +0 -48
- package/esm/swipe-action/demo/style/css/mobile.css +0 -515
- package/esm/swipe-action/demo/style/mobile.less +0 -34
- package/esm/swipe-load/demo/style/css/mobile.css +0 -580
- package/esm/swipe-load/demo/style/mobile.less +0 -116
- package/esm/switch/demo/style/css/mobile.css +0 -524
- package/esm/switch/demo/style/mobile.less +0 -49
- package/esm/tab-bar/demo/style/css/mobile.css +0 -553
- package/esm/tab-bar/demo/style/mobile.less +0 -59
- package/esm/tabs/demo/style/css/mobile.css +0 -633
- package/esm/tabs/demo/style/mobile.less +0 -174
- package/esm/tag/demo/style/css/mobile.css +0 -516
- package/esm/tag/demo/style/mobile.less +0 -33
- package/esm/textarea/demo/style/css/mobile.css +0 -523
- package/esm/textarea/demo/style/mobile.less +0 -47
- package/esm/toast/demo/style/css/mobile.css +0 -520
- package/esm/toast/demo/style/mobile.less +0 -37
- package/esm/transition/demo/style/css/mobile.css +0 -529
- package/esm/transition/demo/style/mobile.less +0 -47
- package/umd/action-sheet/demo/style/css/mobile.css +0 -523
- package/umd/action-sheet/demo/style/mobile.less +0 -52
- package/umd/avatar/demo/style/css/mobile.css +0 -578
- package/umd/avatar/demo/style/mobile.less +0 -96
- package/umd/badge/demo/style/css/mobile.css +0 -580
- package/umd/badge/demo/style/mobile.less +0 -107
- package/umd/button/demo/style/css/mobile.css +0 -530
- package/umd/button/demo/style/mobile.less +0 -44
- package/umd/carousel/demo/style/css/mobile.css +0 -553
- package/umd/carousel/demo/style/mobile.less +0 -70
- package/umd/cell/demo/style/css/mobile.css +0 -585
- package/umd/cell/demo/style/mobile.less +0 -102
- package/umd/checkbox/demo/style/css/mobile.css +0 -520
- package/umd/checkbox/demo/style/mobile.less +0 -45
- package/umd/circle-progress/demo/style/css/mobile.css +0 -516
- package/umd/circle-progress/demo/style/mobile.less +0 -34
- package/umd/collapse/demo/style/css/mobile.css +0 -516
- package/umd/collapse/demo/style/mobile.less +0 -33
- package/umd/context-provider/demo/style/css/mobile.css +0 -520
- package/umd/context-provider/demo/style/mobile.less +0 -37
- package/umd/count-down/demo/style/css/mobile.css +0 -575
- package/umd/count-down/demo/style/mobile.less +0 -96
- package/umd/date-picker/demo/style/css/mobile.css +0 -520
- package/umd/date-picker/demo/style/mobile.less +0 -37
- package/umd/dialog/demo/style/css/mobile.css +0 -548
- package/umd/dialog/demo/style/mobile.less +0 -80
- package/umd/divider/demo/style/css/mobile.css +0 -516
- package/umd/divider/demo/style/mobile.less +0 -36
- package/umd/dropdown/demo/style/css/mobile.css +0 -515
- package/umd/dropdown/demo/style/mobile.less +0 -32
- package/umd/dropdown-menu/demo/style/css/mobile.css +0 -516
- package/umd/dropdown-menu/demo/style/mobile.less +0 -33
- package/umd/ellipsis/demo/style/css/mobile.css +0 -528
- package/umd/ellipsis/demo/style/mobile.less +0 -53
- package/umd/grid/demo/style/css/mobile.css +0 -613
- package/umd/grid/demo/style/mobile.less +0 -157
- package/umd/image/demo/style/css/mobile.css +0 -580
- package/umd/image/demo/style/mobile.less +0 -86
- package/umd/image-picker/demo/style/css/mobile.css +0 -550
- package/umd/image-picker/demo/style/mobile.less +0 -67
- package/umd/image-preview/demo/style/css/mobile.css +0 -551
- package/umd/image-preview/demo/style/mobile.less +0 -61
- package/umd/index-bar/demo/style/css/mobile.css +0 -533
- package/umd/index-bar/demo/style/mobile.less +0 -51
- package/umd/input/demo/style/css/mobile.css +0 -602
- package/umd/input/demo/style/mobile.less +0 -132
- package/umd/keyboard/demo/style/css/mobile.css +0 -520
- package/umd/keyboard/demo/style/mobile.less +0 -42
- package/umd/load-more/demo/style/css/mobile.css +0 -520
- package/umd/load-more/demo/style/mobile.less +0 -39
- package/umd/loading/demo/style/css/mobile.css +0 -529
- package/umd/loading/demo/style/mobile.less +0 -48
- package/umd/masking/demo/style/css/mobile.css +0 -535
- package/umd/masking/demo/style/mobile.less +0 -56
- package/umd/nav-bar/demo/style/css/mobile.css +0 -523
- package/umd/nav-bar/demo/style/mobile.less +0 -46
- package/umd/notice-bar/demo/style/css/mobile.css +0 -4
- package/umd/notice-bar/demo/style/mobile.less +0 -6
- package/umd/notify/demo/style/css/mobile.css +0 -545
- package/umd/notify/demo/style/mobile.less +0 -60
- package/umd/pagination/demo/style/css/index.css +0 -516
- package/umd/pagination/demo/style/index.less +0 -35
- package/umd/picker/demo/style/css/mobile.css +0 -531
- package/umd/picker/demo/style/mobile.less +0 -49
- package/umd/picker-view/demo/style/css/mobile.css +0 -513
- package/umd/picker-view/demo/style/mobile.less +0 -32
- package/umd/popover/demo/style/css/mobile.css +0 -649
- package/umd/popover/demo/style/mobile.less +0 -135
- package/umd/popup/demo/style/css/mobile.css +0 -540
- package/umd/popup/demo/style/mobile.less +0 -66
- package/umd/popup-swiper/demo/style/css/mobile.css +0 -540
- package/umd/popup-swiper/demo/style/mobile.less +0 -66
- package/umd/portal/demo/style/css/mobile.css +0 -527
- package/umd/portal/demo/style/mobile.less +0 -48
- package/umd/progress/demo/style/css/mobile.css +0 -520
- package/umd/progress/demo/style/mobile.less +0 -39
- package/umd/pull-refresh/demo/style/css/mobile.css +0 -554
- package/umd/pull-refresh/demo/style/mobile.less +0 -83
- package/umd/radio/demo/style/css/mobile.css +0 -529
- package/umd/radio/demo/style/mobile.less +0 -54
- package/umd/rate/demo/style/css/mobile.css +0 -514
- package/umd/rate/demo/style/mobile.less +0 -33
- package/umd/search-bar/demo/style/css/mobile.css +0 -520
- package/umd/search-bar/demo/style/mobile.less +0 -43
- package/umd/show-monitor/demo/style/css/mobile.css +0 -569
- package/umd/show-monitor/demo/style/mobile.less +0 -90
- package/umd/skeleton/demo/style/css/mobile.css +0 -517
- package/umd/skeleton/demo/style/mobile.less +0 -38
- package/umd/slider/demo/style/css/mobile.css +0 -529
- package/umd/slider/demo/style/mobile.less +0 -60
- package/umd/stepper/demo/style/css/mobile.css +0 -514
- package/umd/stepper/demo/style/mobile.less +0 -34
- package/umd/steps/demo/style/css/mobile.css +0 -611
- package/umd/steps/demo/style/mobile.less +0 -75
- package/umd/sticky/demo/style/css/mobile.css +0 -527
- package/umd/sticky/demo/style/mobile.less +0 -48
- package/umd/swipe-action/demo/style/css/mobile.css +0 -515
- package/umd/swipe-action/demo/style/mobile.less +0 -34
- package/umd/swipe-load/demo/style/css/mobile.css +0 -580
- package/umd/swipe-load/demo/style/mobile.less +0 -116
- package/umd/switch/demo/style/css/mobile.css +0 -524
- package/umd/switch/demo/style/mobile.less +0 -49
- package/umd/tab-bar/demo/style/css/mobile.css +0 -553
- package/umd/tab-bar/demo/style/mobile.less +0 -59
- package/umd/tabs/demo/style/css/mobile.css +0 -633
- package/umd/tabs/demo/style/mobile.less +0 -174
- package/umd/tag/demo/style/css/mobile.css +0 -516
- package/umd/tag/demo/style/mobile.less +0 -33
- package/umd/textarea/demo/style/css/mobile.css +0 -523
- package/umd/textarea/demo/style/mobile.less +0 -47
- package/umd/toast/demo/style/css/mobile.css +0 -520
- package/umd/toast/demo/style/mobile.less +0 -37
- package/umd/transition/demo/style/css/mobile.css +0 -529
- package/umd/transition/demo/style/mobile.less +0 -47
@@ -18,6 +18,12 @@ export interface PreviewImageProps {
|
|
18
18
|
* @en Transition image url
|
19
19
|
*/
|
20
20
|
fallbackSrc?: string;
|
21
|
+
/**
|
22
|
+
* 过渡图到原图放大动效完成后,移除过渡图的延迟时间(ms),一般当原图过大时有调整需求
|
23
|
+
* @en After the transition image to the original image enlargement effect is completed, the delay time (ms) before the transition image is removed
|
24
|
+
* @default 30
|
25
|
+
*/
|
26
|
+
transitionEndDelay?: number;
|
21
27
|
/**
|
22
28
|
* 缩略图填充方式(backgroundPosition),默认top center
|
23
29
|
* @en Thumbnail fill mode (backgroundPosition), default value is top center
|
@@ -173,7 +173,7 @@
|
|
173
173
|
transformersRef.current = []; // 移除过渡图片
|
174
174
|
// @en Remove transition image
|
175
175
|
|
176
|
-
removeChild(
|
176
|
+
removeChild(transImageRef.current);
|
177
177
|
setTransImageInfo(null);
|
178
178
|
setPlaceholders({});
|
179
179
|
var mounted = isInitialMount.current;
|
@@ -216,7 +216,9 @@
|
|
216
216
|
|
217
217
|
function removeChild(child) {
|
218
218
|
try {
|
219
|
-
|
219
|
+
var _domRef$current, _domRef$current$query, _domRef$current$query2;
|
220
|
+
|
221
|
+
child && ((_domRef$current = domRef.current) == null ? void 0 : (_domRef$current$query = _domRef$current.querySelectorAll('.carousel-item')) == null ? void 0 : (_domRef$current$query2 = _domRef$current$query[innerIndexRef.current]) == null ? void 0 : _domRef$current$query2.removeChild(child));
|
220
222
|
} catch (e) {}
|
221
223
|
} // 监听滑动到上下边缘后还在往外滑动的操作,则关闭弹窗
|
222
224
|
// @en Monitor the operation of sliding out after sliding to the upper and lower edges, then close the popup
|
@@ -635,7 +637,41 @@
|
|
635
637
|
}
|
636
638
|
}
|
637
639
|
|
638
|
-
var handleClick = (0, _helpers.useSingleAndDoubleClick)(handleImageClick, handleImageDoubleClick);
|
640
|
+
var handleClick = (0, _helpers.useSingleAndDoubleClick)(handleImageClick, handleImageDoubleClick); // 当使用 getThumbBounds 时,关闭图片预览有缩小效果
|
641
|
+
// @en When using getThumbBounds, closing the image preview has a shrinking effect
|
642
|
+
|
643
|
+
function animateBeforeClose() {
|
644
|
+
var _imagesRef$current$in2;
|
645
|
+
|
646
|
+
var index = innerIndexRef.current;
|
647
|
+
var imageDom = (_imagesRef$current$in2 = imagesRef.current[index]) == null ? void 0 : _imagesRef$current$in2.image;
|
648
|
+
var thumbBounds = getThumbBounds == null ? void 0 : getThumbBounds(index);
|
649
|
+
|
650
|
+
if (!imageDom || !thumbBounds || !thumbBounds.width || !thumbBounds.height) {
|
651
|
+
return;
|
652
|
+
} // 小图超过一半在视野外时,不展示缩小效果
|
653
|
+
// @en When more than half of the thumbnail is outside the field of view, the zoom effect will not be displayed
|
654
|
+
|
655
|
+
|
656
|
+
if (thumbBounds.top < -1 * thumbBounds.height / 2 || thumbBounds.top > windowHeight - thumbBounds.height / 2 || thumbBounds.left < -1 * thumbBounds.width / 2 || thumbBounds.left > windowWidth - thumbBounds.width / 2) {
|
657
|
+
return;
|
658
|
+
}
|
659
|
+
|
660
|
+
var imageDomRect = imageDom.getBoundingClientRect();
|
661
|
+
|
662
|
+
if (!imageDomRect.width || !imageDomRect.height) {
|
663
|
+
return;
|
664
|
+
}
|
665
|
+
|
666
|
+
imageDom.classList.add('closing-animation');
|
667
|
+
setImageBounds(imageDom, imageDomRect, imageDomRect);
|
668
|
+
imageDom.style.objectPosition = images[index].thumbPosition || 'top center';
|
669
|
+
(0, _mobileUtils.nextTick)(function () {
|
670
|
+
imageDom.style.transitionDuration = displayDuration + "ms";
|
671
|
+
imageDom.style.webkitTransitionDuration = displayDuration + "ms";
|
672
|
+
setImageBounds(imageDom, thumbBounds, imageDomRect);
|
673
|
+
});
|
674
|
+
}
|
639
675
|
|
640
676
|
function goClose(e) {
|
641
677
|
if (closingRef.current) {
|
@@ -643,6 +679,7 @@
|
|
643
679
|
}
|
644
680
|
|
645
681
|
closingRef.current = true;
|
682
|
+
animateBeforeClose();
|
646
683
|
close(e);
|
647
684
|
}
|
648
685
|
/**
|
@@ -665,7 +702,7 @@
|
|
665
702
|
|
666
703
|
|
667
704
|
function setDisplayAnimation(index) {
|
668
|
-
var _imagesStatusRef$curr4;
|
705
|
+
var _imagesStatusRef$curr4, _domRef$current2, _domRef$current2$quer, _domRef$current2$quer2;
|
669
706
|
|
670
707
|
var firstLoaded = (_imagesStatusRef$curr4 = imagesStatusRef.current[index]) == null ? void 0 : _imagesStatusRef$curr4.firstLoaded;
|
671
708
|
var fallbackSrc = replaceFallbackWhenLoaded && firstLoaded ? images[index].src : images[index].fallbackSrc; // 用户设置了getThumbBounds和images的fallbackSrc属性才有放大过渡效果
|
@@ -696,7 +733,7 @@
|
|
696
733
|
transImage.style.opacity = '0';
|
697
734
|
transImage.style.transitionDuration = displayDuration + "ms";
|
698
735
|
transImage.style.webkitTransitionDuration = displayDuration + "ms";
|
699
|
-
|
736
|
+
(_domRef$current2 = domRef.current) == null ? void 0 : (_domRef$current2$quer = _domRef$current2.querySelectorAll('.carousel-item')) == null ? void 0 : (_domRef$current2$quer2 = _domRef$current2$quer[index]) == null ? void 0 : _domRef$current2$quer2.prepend(transImage); // 拿到放大之后的位置rect,没拿到就取消小图放大效果
|
700
737
|
// @en Get the zoomed-in position rect, and cancel the zoom-in effect if not getting it
|
701
738
|
|
702
739
|
getNewImageBounds(index, fallbackSrc, transImage, function (rect) {
|
@@ -718,9 +755,10 @@
|
|
718
755
|
return (0, _extends5.default)({}, holders, (_extends3 = {}, _extends3[index] = true, _extends3));
|
719
756
|
});
|
720
757
|
}, Math.max(0, displayDuration - 80));
|
758
|
+
var transitionEndDelay = images[index].transitionEndDelay || 30;
|
721
759
|
setTimeout(function () {
|
722
760
|
resetAnimation(index);
|
723
|
-
}, displayDuration +
|
761
|
+
}, displayDuration + transitionEndDelay);
|
724
762
|
});
|
725
763
|
});
|
726
764
|
}
|
@@ -880,18 +918,14 @@
|
|
880
918
|
}) : null;
|
881
919
|
}
|
882
920
|
|
883
|
-
function renderLoadingArea(
|
884
|
-
|
885
|
-
// @en The loadingArea is extracted and placed on the upper layer of the transition image
|
886
|
-
return index === openIndex ? /*#__PURE__*/_react.default.createElement(_portal.default, {
|
887
|
-
getContainer: getContainer
|
888
|
-
}, /*#__PURE__*/_react.default.createElement("div", {
|
921
|
+
function renderLoadingArea() {
|
922
|
+
return /*#__PURE__*/_react.default.createElement("div", {
|
889
923
|
className: "image-preview-loading-area"
|
890
924
|
}, loadingArea || /*#__PURE__*/_react.default.createElement(_loading.default, {
|
891
925
|
type: "circle",
|
892
926
|
className: "loading-icon",
|
893
927
|
radius: 7
|
894
|
-
}))
|
928
|
+
}));
|
895
929
|
}
|
896
930
|
|
897
931
|
return /*#__PURE__*/_react.default.createElement(_contextProvider.ContextLayout, null, function (_ref3) {
|
@@ -939,7 +973,7 @@
|
|
939
973
|
imagesRef.current[index] = r;
|
940
974
|
},
|
941
975
|
showLoading: showLoading,
|
942
|
-
loadingArea: renderLoadingArea(
|
976
|
+
loadingArea: renderLoadingArea(),
|
943
977
|
errorArea: errorArea,
|
944
978
|
showError: showError,
|
945
979
|
retryTime: retryTime,
|
@@ -575,6 +575,7 @@
|
|
575
575
|
height: 100%;
|
576
576
|
opacity: 0;
|
577
577
|
}
|
578
|
+
.arco-image-preview .image-container img.closing-animation,
|
578
579
|
.image-preview-fake-trans-image {
|
579
580
|
position: fixed;
|
580
581
|
left: 0;
|
@@ -584,7 +585,7 @@
|
|
584
585
|
transition: all cubic-bezier(0.34, 0.69, 0.1, 1) ;
|
585
586
|
will-change: transform;
|
586
587
|
pointer-events: none;
|
587
|
-
|
588
|
+
height: auto !important;
|
588
589
|
}
|
589
590
|
.image-preview-loading-area {
|
590
591
|
position: fixed;
|
@@ -77,6 +77,7 @@
|
|
77
77
|
opacity: 0;
|
78
78
|
}
|
79
79
|
|
80
|
+
.@{prefix}-image-preview .image-container img.closing-animation,
|
80
81
|
.image-preview-fake-trans-image {
|
81
82
|
position: fixed;
|
82
83
|
left: 0;
|
@@ -85,7 +86,7 @@
|
|
85
86
|
.use-var(transition, image-preview-thumb-transition);
|
86
87
|
will-change: transform;
|
87
88
|
pointer-events: none;
|
88
|
-
|
89
|
+
height: auto !important;
|
89
90
|
}
|
90
91
|
|
91
92
|
.image-preview-loading-area {
|
package/umd/nav-bar/back-icon.js
CHANGED
@@ -1,16 +1,16 @@
|
|
1
1
|
(function (global, factory) {
|
2
2
|
if (typeof define === "function" && define.amd) {
|
3
|
-
define(["exports", "react"], factory);
|
3
|
+
define(["exports", "react", "@arco-design/mobile-utils", "../context-provider"], factory);
|
4
4
|
} else if (typeof exports !== "undefined") {
|
5
|
-
factory(exports, require("react"));
|
5
|
+
factory(exports, require("react"), require("@arco-design/mobile-utils"), require("../context-provider"));
|
6
6
|
} else {
|
7
7
|
var mod = {
|
8
8
|
exports: {}
|
9
9
|
};
|
10
|
-
factory(mod.exports, global.react);
|
10
|
+
factory(mod.exports, global.react, global.mobileUtils, global.contextProvider);
|
11
11
|
global.backIcon = mod.exports;
|
12
12
|
}
|
13
|
-
})(typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : this, function (_exports, _react) {
|
13
|
+
})(typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : this, function (_exports, _react, _mobileUtils, _contextProvider) {
|
14
14
|
"use strict";
|
15
15
|
|
16
16
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
@@ -22,16 +22,22 @@
|
|
22
22
|
function BackArrow(_ref) {
|
23
23
|
var _ref$color = _ref.color,
|
24
24
|
color = _ref$color === void 0 ? 'currentColor' : _ref$color;
|
25
|
-
return /*#__PURE__*/_react.default.createElement(
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
25
|
+
return /*#__PURE__*/_react.default.createElement(_contextProvider.ContextLayout, null, function (_ref2) {
|
26
|
+
var _ref2$locale = _ref2.locale,
|
27
|
+
locale = _ref2$locale === void 0 ? _mobileUtils.defaultLocale : _ref2$locale;
|
28
|
+
return /*#__PURE__*/_react.default.createElement("div", {
|
29
|
+
role: "button",
|
30
|
+
className: "c-svg-arrow nav-bar-back",
|
31
|
+
"aria-label": locale.NavBar.backBtnAriaLabel
|
32
|
+
}, /*#__PURE__*/_react.default.createElement("svg", {
|
33
|
+
height: "100%",
|
34
|
+
viewBox: "0 0 16 16"
|
35
|
+
}, /*#__PURE__*/_react.default.createElement("path", {
|
36
|
+
id: "path-1_1_",
|
37
|
+
d: "M2.1,8l5.4,5.4c0.1,0.1,0.1,0.3,0,0.5L7,14.4c-0.1,0.1-0.3,0.1-0.5,0L0.7,8.5c-0.3-0.3-0.3-0.7,0-0.9 l5.9-5.9c0.1-0.1,0.3-0.1,0.5,0l0.5,0.5c0.1,0.1,0.1,0.3,0,0.5L2.1,8z",
|
38
|
+
fill: color
|
39
|
+
})));
|
40
|
+
});
|
35
41
|
}
|
36
42
|
|
37
43
|
var _default = BackArrow;
|
@@ -308,7 +308,7 @@
|
|
308
308
|
function getCurrentCellValue() {
|
309
309
|
var _data$currentIndex;
|
310
310
|
|
311
|
-
return
|
311
|
+
return (_data$currentIndex = data[currentIndex]) == null ? void 0 : _data$currentIndex.value;
|
312
312
|
}
|
313
313
|
|
314
314
|
function _clearTimer() {
|
package/umd/picker-view/index.js
CHANGED
@@ -549,6 +549,10 @@
|
|
549
549
|
font-size: 0.4rem;
|
550
550
|
line-height: 1;
|
551
551
|
}
|
552
|
+
[dir="rtl"] .arco-popover-menu-icon {
|
553
|
+
margin-right: initial;
|
554
|
+
margin-left: 0.16rem;
|
555
|
+
}
|
552
556
|
.arco-popover-menu-icon > * {
|
553
557
|
float: left;
|
554
558
|
}
|
@@ -634,7 +638,6 @@
|
|
634
638
|
width: -webkit-max-content;
|
635
639
|
width: max-content;
|
636
640
|
z-index: 1010;
|
637
|
-
right: 0;
|
638
641
|
background-color: transparent;
|
639
642
|
visibility: hidden;
|
640
643
|
will-change: transform;
|
@@ -716,11 +719,15 @@
|
|
716
719
|
padding: 0 0.2rem 0 0.22rem ;
|
717
720
|
}
|
718
721
|
.arco-popover-inner .text-suffix {
|
719
|
-
padding: 0
|
722
|
+
padding-right: 0.24rem ;
|
720
723
|
-webkit-box-flex: 0;
|
721
724
|
-webkit-flex: 0 0 auto;
|
722
725
|
flex: 0 0 auto;
|
723
726
|
}
|
727
|
+
[dir="rtl"] .arco-popover-inner .text-suffix {
|
728
|
+
padding-right: initial;
|
729
|
+
padding-left: 0.24rem ;
|
730
|
+
}
|
724
731
|
.arco-popover-inner .popover-arrow {
|
725
732
|
position: absolute;
|
726
733
|
-webkit-transform: rotate(45deg);
|
@@ -29,7 +29,6 @@
|
|
29
29
|
position: absolute;
|
30
30
|
width: max-content;
|
31
31
|
z-index: @full-screen-z-index + 10;
|
32
|
-
right: 0;
|
33
32
|
background-color: transparent;
|
34
33
|
visibility: hidden;
|
35
34
|
will-change: transform;
|
@@ -104,7 +103,7 @@
|
|
104
103
|
}
|
105
104
|
|
106
105
|
.text-suffix {
|
107
|
-
.use-var(padding, popover-text-suffix-
|
106
|
+
.use-var-with-rtl(padding-right, popover-text-suffix-edge);
|
108
107
|
flex: 0 0 auto;
|
109
108
|
}
|
110
109
|
|
@@ -1,16 +1,16 @@
|
|
1
1
|
(function (global, factory) {
|
2
2
|
if (typeof define === "function" && define.amd) {
|
3
|
-
define(["exports", "react", "."], factory);
|
3
|
+
define(["exports", "react", ".", "../../context-provider"], factory);
|
4
4
|
} else if (typeof exports !== "undefined") {
|
5
|
-
factory(exports, require("react"), require("."));
|
5
|
+
factory(exports, require("react"), require("."), require("../../context-provider"));
|
6
6
|
} else {
|
7
7
|
var mod = {
|
8
8
|
exports: {}
|
9
9
|
};
|
10
|
-
factory(mod.exports, global.react, global._);
|
10
|
+
factory(mod.exports, global.react, global._, global.contextProvider);
|
11
11
|
global.useSliderEvents = mod.exports;
|
12
12
|
}
|
13
|
-
})(typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : this, function (_exports, _react, _) {
|
13
|
+
})(typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : this, function (_exports, _react, _, _contextProvider) {
|
14
14
|
"use strict";
|
15
15
|
|
16
16
|
_exports.__esModule = true;
|
@@ -30,13 +30,16 @@
|
|
30
30
|
setValueGroup = _ref.setValueGroup,
|
31
31
|
setCommonIsTouching = _ref.setCommonIsTouching;
|
32
32
|
|
33
|
-
var _useContext = (0, _react.useContext)(
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
33
|
+
var _useContext = (0, _react.useContext)(_contextProvider.GlobalContext),
|
34
|
+
useRtl = _useContext.useRtl;
|
35
|
+
|
36
|
+
var _useContext2 = (0, _react.useContext)(_.SliderContext),
|
37
|
+
disabled = _useContext2.disabled,
|
38
|
+
step = _useContext2.step,
|
39
|
+
min = _useContext2.min,
|
40
|
+
max = _useContext2.max,
|
41
|
+
type = _useContext2.type,
|
42
|
+
draggableTrackOnly = _useContext2.draggableTrackOnly;
|
40
43
|
|
41
44
|
var _useState = (0, _react.useState)(IsTouchingStatus.Idle),
|
42
45
|
isTouching = _useState[0],
|
@@ -62,7 +65,8 @@
|
|
62
65
|
length = _linePositionRef$curr.length,
|
63
66
|
start = _linePositionRef$curr.start;
|
64
67
|
if (length === 0) return 0;
|
65
|
-
var
|
68
|
+
var rtlRatio = useRtl ? -1 : 1;
|
69
|
+
var newWidth = isHorizontal ? (touchPosition - start) * rtlRatio : length - touchPosition + start;
|
66
70
|
|
67
71
|
if (newWidth < 0) {
|
68
72
|
newWidth = 0;
|
@@ -1,16 +1,16 @@
|
|
1
1
|
(function (global, factory) {
|
2
2
|
if (typeof define === "function" && define.amd) {
|
3
|
-
define(["exports", "react", "."], factory);
|
3
|
+
define(["exports", "react", ".", "../../context-provider"], factory);
|
4
4
|
} else if (typeof exports !== "undefined") {
|
5
|
-
factory(exports, require("react"), require("."));
|
5
|
+
factory(exports, require("react"), require("."), require("../../context-provider"));
|
6
6
|
} else {
|
7
7
|
var mod = {
|
8
8
|
exports: {}
|
9
9
|
};
|
10
|
-
factory(mod.exports, global.react, global._);
|
10
|
+
factory(mod.exports, global.react, global._, global.contextProvider);
|
11
11
|
global.useSliderStyle = mod.exports;
|
12
12
|
}
|
13
|
-
})(typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : this, function (_exports, _react, _) {
|
13
|
+
})(typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : this, function (_exports, _react, _, _contextProvider) {
|
14
14
|
"use strict";
|
15
15
|
|
16
16
|
_exports.__esModule = true;
|
@@ -21,12 +21,15 @@
|
|
21
21
|
commonIsTouching = _ref.commonIsTouching,
|
22
22
|
valueGroup = _ref.valueGroup;
|
23
23
|
|
24
|
-
var _useContext = (0, _react.useContext)(
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
24
|
+
var _useContext = (0, _react.useContext)(_contextProvider.GlobalContext),
|
25
|
+
useRtl = _useContext.useRtl;
|
26
|
+
|
27
|
+
var _useContext2 = (0, _react.useContext)(_.SliderContext),
|
28
|
+
size = _useContext2.size,
|
29
|
+
useAnimation = _useContext2.useAnimation,
|
30
|
+
min = _useContext2.min,
|
31
|
+
max = _useContext2.max,
|
32
|
+
type = _useContext2.type;
|
30
33
|
|
31
34
|
var isHorizontal = /^horizontal/g.test(type);
|
32
35
|
var heightStyle = (0, _react.useMemo)(function () {
|
@@ -60,7 +63,8 @@
|
|
60
63
|
length = (larger - min) / (max - min) * length - start;
|
61
64
|
}
|
62
65
|
|
63
|
-
|
66
|
+
var leftStyle = useRtl ? 'right' : 'left';
|
67
|
+
return _ref3 = {}, _ref3[isHorizontal ? leftStyle : 'bottom'] = start + "px", _ref3[isHorizontal ? 'width' : 'height'] = Math.abs(length) + "px", _ref3;
|
64
68
|
}, [valueGroup, getLinePosition, min, max, isHorizontal]);
|
65
69
|
return {
|
66
70
|
heightStyle: heightStyle,
|
package/umd/slider/index.js
CHANGED
@@ -29,7 +29,8 @@
|
|
29
29
|
var Slider = /*#__PURE__*/(0, _react.forwardRef)(function (_, ref) {
|
30
30
|
var _useContext = (0, _react.useContext)(_contextProvider.GlobalContext),
|
31
31
|
_useContext$prefixCls = _useContext.prefixCls,
|
32
|
-
prefixCls = _useContext$prefixCls === void 0 ? '' : _useContext$prefixCls
|
32
|
+
prefixCls = _useContext$prefixCls === void 0 ? '' : _useContext$prefixCls,
|
33
|
+
useRtl = _useContext.useRtl;
|
33
34
|
|
34
35
|
var _useContext2 = (0, _react.useContext)(_hooks.SliderContext),
|
35
36
|
className = _useContext2.className,
|
@@ -80,9 +81,10 @@
|
|
80
81
|
top = _ref.top,
|
81
82
|
height = _ref.height;
|
82
83
|
|
84
|
+
var leftValue = useRtl ? left + width : left;
|
83
85
|
return {
|
84
86
|
length: isHorizontal ? width : height,
|
85
|
-
start: isHorizontal ?
|
87
|
+
start: isHorizontal ? leftValue : top
|
86
88
|
};
|
87
89
|
}, [isHorizontal, firstRender]);
|
88
90
|
|
package/umd/slider/marks.js
CHANGED
@@ -33,7 +33,8 @@
|
|
33
33
|
|
34
34
|
var _useContext = (0, _react.useContext)(_contextProvider.GlobalContext),
|
35
35
|
_useContext$prefixCls = _useContext.prefixCls,
|
36
|
-
prefixCls = _useContext$prefixCls === void 0 ? '' : _useContext$prefixCls
|
36
|
+
prefixCls = _useContext$prefixCls === void 0 ? '' : _useContext$prefixCls,
|
37
|
+
useRtl = _useContext.useRtl;
|
37
38
|
|
38
39
|
var _useContext2 = (0, _react.useContext)(_hooks.SliderContext),
|
39
40
|
type = _useContext2.type,
|
@@ -45,7 +46,8 @@
|
|
45
46
|
var genMarkStyle = (0, _react.useCallback)(function (value) {
|
46
47
|
var _ref2;
|
47
48
|
|
48
|
-
|
49
|
+
var leftStyle = useRtl ? 'right' : 'left';
|
50
|
+
return _ref2 = {}, _ref2[isHorizontal ? leftStyle : 'bottom'] = (value - min) / (max - min) * 100 + "%", _ref2;
|
49
51
|
}, [isHorizontal, min, max]);
|
50
52
|
return /*#__PURE__*/_react.default.createElement("div", {
|
51
53
|
className: prefixCls + "-slider-marks"
|
@@ -541,6 +541,10 @@
|
|
541
541
|
.is-horizontal .arco-slider-label {
|
542
542
|
margin-right: 0.24rem ;
|
543
543
|
}
|
544
|
+
[dir="rtl"] .is-horizontal .arco-slider-label {
|
545
|
+
margin-right: initial;
|
546
|
+
margin-left: 0.24rem ;
|
547
|
+
}
|
544
548
|
.is-vertical .arco-slider-label {
|
545
549
|
-webkit-box-orient: vertical;
|
546
550
|
-webkit-box-direction: normal;
|
@@ -552,6 +556,10 @@
|
|
552
556
|
margin-right: 0;
|
553
557
|
margin-left: 0.24rem ;
|
554
558
|
}
|
559
|
+
[dir="rtl"] .is-horizontal .arco-slider-wrapper + .arco-slider-label {
|
560
|
+
margin-left: initial;
|
561
|
+
margin-right: 0.24rem ;
|
562
|
+
}
|
555
563
|
.is-vertical .arco-slider-wrapper + .arco-slider-label {
|
556
564
|
margin-bottom: 0;
|
557
565
|
margin-top: 0.24rem ;
|
@@ -636,11 +644,27 @@
|
|
636
644
|
-webkit-transform: translateX(50%);
|
637
645
|
transform: translateX(50%);
|
638
646
|
}
|
647
|
+
[dir="rtl"] .is-horizontal .arco-slider-thumb-wrapper.is-end {
|
648
|
+
right: initial;
|
649
|
+
left: 0;
|
650
|
+
}
|
651
|
+
[dir="rtl"] .is-horizontal .arco-slider-thumb-wrapper.is-end {
|
652
|
+
-webkit-transform: translateX(-50%);
|
653
|
+
transform: translateX(-50%);
|
654
|
+
}
|
639
655
|
.is-horizontal .arco-slider-thumb-wrapper.is-start {
|
640
656
|
left: 0;
|
641
657
|
-webkit-transform: translateX(-50%);
|
642
658
|
transform: translateX(-50%);
|
643
659
|
}
|
660
|
+
[dir="rtl"] .is-horizontal .arco-slider-thumb-wrapper.is-start {
|
661
|
+
left: initial;
|
662
|
+
right: 0;
|
663
|
+
}
|
664
|
+
[dir="rtl"] .is-horizontal .arco-slider-thumb-wrapper.is-start {
|
665
|
+
-webkit-transform: translateX(50%);
|
666
|
+
transform: translateX(50%);
|
667
|
+
}
|
644
668
|
.arco-slider-popover-wrapper .arco-slider-thumb {
|
645
669
|
position: relative;
|
646
670
|
}
|
@@ -739,6 +763,10 @@
|
|
739
763
|
-webkit-transform: translateX(-50%);
|
740
764
|
transform: translateX(-50%);
|
741
765
|
}
|
766
|
+
[dir="rtl"] .arco-slider-marks-item {
|
767
|
+
-webkit-transform: translateX(50%);
|
768
|
+
transform: translateX(50%);
|
769
|
+
}
|
742
770
|
.arco-slider-marks-item.is-activated {
|
743
771
|
background: #165DFF ;
|
744
772
|
}
|
@@ -31,7 +31,7 @@
|
|
31
31
|
.use-var(color, slider-text-color);
|
32
32
|
|
33
33
|
.is-horizontal & {
|
34
|
-
.use-var(margin-right, slider-label-gutter);
|
34
|
+
.use-var-with-rtl(margin-right, slider-label-gutter);
|
35
35
|
}
|
36
36
|
|
37
37
|
.is-vertical & {
|
@@ -44,7 +44,7 @@
|
|
44
44
|
|
45
45
|
.is-horizontal & {
|
46
46
|
margin-right: 0;
|
47
|
-
.use-var(margin-left, slider-label-gutter);
|
47
|
+
.use-var-with-rtl(margin-left, slider-label-gutter);
|
48
48
|
}
|
49
49
|
|
50
50
|
.is-vertical & {
|
@@ -124,13 +124,19 @@
|
|
124
124
|
bottom: 0;
|
125
125
|
|
126
126
|
&.is-end {
|
127
|
-
right
|
127
|
+
.set-prop-with-rtl(right, 0);
|
128
128
|
transform: translateX(50%);
|
129
|
+
[dir="rtl"] & {
|
130
|
+
transform: translateX(-50%);
|
131
|
+
}
|
129
132
|
}
|
130
133
|
|
131
134
|
&.is-start {
|
132
|
-
left
|
135
|
+
.set-prop-with-rtl(left, 0);
|
133
136
|
transform: translateX(-50%);
|
137
|
+
[dir="rtl"] & {
|
138
|
+
transform: translateX(50%);
|
139
|
+
}
|
134
140
|
}
|
135
141
|
}
|
136
142
|
}
|
@@ -236,6 +242,9 @@
|
|
236
242
|
.use-var(border-radius, slider-mark-border-radius);
|
237
243
|
.use-var(background, slider-line-color);
|
238
244
|
transform: translateX(-50%);
|
245
|
+
[dir="rtl"] & {
|
246
|
+
transform: translateX(50%);
|
247
|
+
}
|
239
248
|
|
240
249
|
&.is-activated {
|
241
250
|
.use-var(background, slider-line-activated-color);
|