@nutui/nutui-react-taro 3.0.20-beta.0 → 3.0.20-cpp
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 +28 -70
- package/dist/cjs/hooks/taro/use-custom-event.js +5 -5
- package/dist/cjs/hooks/use-ref-state.js +3 -3
- package/dist/cjs/hooks/use-touch.js +1 -2
- package/dist/cjs/locales/base.d.ts +9 -0
- package/dist/cjs/locales/en-US.js +21 -2
- package/dist/cjs/locales/id-ID.js +21 -2
- package/dist/cjs/locales/ja-JP.js +19 -2
- package/dist/cjs/locales/tr-TR.js +21 -2
- package/dist/cjs/locales/zh-CN.js +19 -2
- package/dist/cjs/locales/zh-TW.js +19 -2
- package/dist/cjs/locales/zh-UG.js +21 -2
- package/dist/cjs/packages/actionsheet/style/style.harmony.css +38 -17
- package/dist/cjs/packages/address/address.d.ts +1 -1
- package/dist/cjs/packages/address/style/style.harmony.css +38 -17
- package/dist/cjs/packages/address/utils.js +3 -3
- package/dist/cjs/packages/animatingnumbers/countup.js +3 -1
- package/dist/cjs/packages/audio/style/style.harmony.css +0 -3
- package/dist/cjs/packages/avatar/avatar.js +32 -6
- package/dist/cjs/packages/avatarcropper/avatarcropper.js +18 -34
- package/dist/cjs/packages/badge/badge.js +20 -10
- package/dist/cjs/packages/barrage/barrage.js +14 -24
- package/dist/cjs/packages/button/button.d.ts +2 -24
- package/dist/cjs/packages/button/button.js +9 -12
- package/dist/cjs/packages/button/index.d.ts +0 -1
- package/dist/cjs/packages/button/style/button.scss +0 -3
- package/dist/cjs/packages/button/style/style.css +0 -3
- package/dist/cjs/packages/button/style/style.harmony.css +0 -3
- package/dist/cjs/packages/button/style-jmapp/button.scss +0 -3
- package/dist/cjs/packages/button/style-jmapp/style.css +0 -3
- package/dist/cjs/packages/button/style-jrkf/button.scss +0 -3
- package/dist/cjs/packages/button/style-jrkf/style.css +0 -3
- package/dist/cjs/packages/calendar/style/calendar.scss +32 -1
- package/dist/cjs/packages/calendar/style/style.css +21 -1
- package/dist/cjs/packages/calendar/style/style.harmony.css +59 -18
- package/dist/cjs/packages/calendar/style-jmapp/calendar.scss +32 -1
- package/dist/cjs/packages/calendar/style-jmapp/style.css +21 -1
- package/dist/cjs/packages/calendar/style-jrkf/calendar.scss +32 -1
- package/dist/cjs/packages/calendar/style-jrkf/style.css +21 -1
- package/dist/cjs/packages/calendar/utils.js +8 -8
- package/dist/cjs/packages/calendarcard/calendarcard.js +30 -8
- package/dist/cjs/packages/calendarcard/icon.js +17 -28
- package/dist/cjs/packages/calendarcard/style/calendarcard.scss +19 -0
- package/dist/cjs/packages/calendarcard/style/style.css +13 -0
- package/dist/cjs/packages/calendarcard/style/style.harmony.css +13 -0
- package/dist/cjs/packages/calendarcard/style-jmapp/calendarcard.scss +19 -0
- package/dist/cjs/packages/calendarcard/style-jmapp/style.css +13 -0
- package/dist/cjs/packages/calendarcard/style-jrkf/calendarcard.scss +19 -0
- package/dist/cjs/packages/calendarcard/style-jrkf/style.css +13 -0
- package/dist/cjs/packages/calendarcard/utils.js +6 -6
- package/dist/cjs/packages/card/style/style.harmony.css +1 -1
- package/dist/cjs/packages/cascader/cascader.js +12 -21
- package/dist/cjs/packages/cascader/style/style.harmony.css +38 -17
- package/dist/cjs/packages/cascader/utils.js +3 -3
- package/dist/cjs/packages/collapseitem/collapseitem.js +4 -7
- package/dist/cjs/packages/configprovider/configprovider.js +7 -7
- package/dist/cjs/packages/configprovider/index.js +6 -6
- package/dist/cjs/packages/configprovider/types.d.ts +1 -1
- package/dist/cjs/packages/countdown/countdown.js +1 -2
- package/dist/cjs/packages/datepicker/style/style.harmony.css +39 -18
- package/dist/cjs/packages/datepicker/utils.js +9 -9
- package/dist/cjs/packages/dialog/content.js +3 -3
- package/dist/cjs/packages/dialog/dialog.js +26 -23
- package/dist/cjs/packages/dialog/style/dialog.scss +1 -1
- package/dist/cjs/packages/dialog/style/style.css +1 -1
- package/dist/cjs/packages/dialog/style/style.harmony.css +1 -4
- package/dist/cjs/packages/dialog/style-jmapp/dialog.scss +1 -1
- package/dist/cjs/packages/dialog/style-jmapp/style.css +1 -1
- package/dist/cjs/packages/dialog/style-jrkf/dialog.scss +1 -1
- package/dist/cjs/packages/dialog/style-jrkf/style.css +1 -1
- package/dist/cjs/packages/divider/divider.js +2 -2
- package/dist/cjs/packages/drag/drag.js +4 -7
- package/dist/cjs/packages/elevator/elevator.js +7 -10
- package/dist/cjs/packages/ellipsis/ellipsis.js +17 -30
- package/dist/cjs/packages/empty/empty.d.ts +4 -4
- package/dist/cjs/packages/empty/style/style.harmony.css +0 -3
- package/dist/cjs/packages/form/index.js +0 -2
- package/dist/cjs/packages/form/style/style.harmony.css +0 -5
- package/dist/cjs/packages/form/useform.js +50 -57
- package/dist/cjs/packages/formitem/style/formitem.scss +4 -4
- package/dist/cjs/packages/formitem/style/style.css +0 -5
- package/dist/cjs/packages/formitem/style/style.harmony.css +0 -5
- package/dist/cjs/packages/formitem/style-jmapp/formitem.scss +4 -4
- package/dist/cjs/packages/formitem/style-jmapp/style.css +0 -5
- package/dist/cjs/packages/formitem/style-jrkf/formitem.scss +4 -4
- package/dist/cjs/packages/formitem/style-jrkf/style.css +0 -5
- package/dist/cjs/packages/image/image.js +11 -3
- package/dist/cjs/packages/imagepreview/style/style.harmony.css +38 -17
- package/dist/cjs/packages/infiniteloading/infiniteloading.js +8 -14
- package/dist/cjs/packages/input/input.js +10 -3
- package/dist/cjs/packages/inputnumber/inputnumber.js +17 -29
- package/dist/cjs/packages/lottie/lottiemp.js +10 -18
- package/dist/cjs/packages/lottie/types.js +0 -2
- package/dist/cjs/packages/menuitem/menuitem.js +24 -22
- package/dist/cjs/packages/noticebar/noticebar.js +74 -70
- package/dist/cjs/packages/notify/notify.js +4 -4
- package/dist/cjs/packages/numberkeyboard/style/style.css +1 -1
- package/dist/cjs/packages/numberkeyboard/style/style.harmony.css +39 -18
- package/dist/cjs/packages/nutui.react.build.d.ts +3 -1
- package/dist/cjs/packages/nutui.react.build.js +123 -119
- package/dist/cjs/packages/nutui.react.d.ts +4 -1
- package/dist/cjs/packages/nutui.react.js +124 -119
- package/dist/cjs/packages/nutui.react.scss.d.ts +1 -0
- package/dist/cjs/packages/nutui.react.scss.js +1 -0
- package/dist/cjs/packages/overlay/overlay.js +6 -6
- package/dist/cjs/packages/picker/style/style.css +1 -1
- package/dist/cjs/packages/picker/style/style.harmony.css +39 -18
- package/dist/cjs/packages/pickerview/pickerroller.js +4 -7
- package/dist/cjs/packages/pickerview/pickerview.js +1 -2
- package/dist/cjs/packages/pickerview/utils.js +3 -3
- package/dist/cjs/packages/popover/popover.js +75 -77
- package/dist/cjs/packages/popover/style/style.harmony.css +38 -17
- package/dist/cjs/packages/popup/popup.js +192 -113
- package/dist/cjs/packages/popup/style/popup.scss +22 -1
- package/dist/cjs/packages/popup/style/style.css +38 -17
- package/dist/cjs/packages/popup/style/style.harmony.css +38 -17
- package/dist/cjs/packages/popup/style-jmapp/popup.scss +22 -1
- package/dist/cjs/packages/popup/style-jmapp/style.css +22 -1
- package/dist/cjs/packages/popup/style-jrkf/popup.scss +22 -1
- package/dist/cjs/packages/popup/style-jrkf/style.css +22 -1
- package/dist/cjs/packages/price/price.js +52 -13
- package/dist/cjs/packages/progress/progress.js +2 -4
- package/dist/cjs/packages/pulltorefresh/pulltorefresh.js +52 -56
- package/dist/cjs/packages/quickenter/index.d.ts +3 -0
- package/dist/cjs/packages/quickenter/index.js +13 -0
- package/dist/cjs/packages/quickenter/quickenter.d.ts +4 -0
- package/dist/cjs/packages/quickenter/quickenter.js +153 -0
- package/dist/cjs/packages/quickenter/style/css.js +2 -0
- package/dist/cjs/packages/quickenter/style/index.js +2 -0
- package/dist/cjs/packages/quickenter/style/quickenter.scss +120 -0
- package/dist/cjs/packages/quickenter/style/style.css +106 -0
- package/dist/cjs/packages/quickenter/style/style.harmony.css +506 -0
- package/dist/cjs/packages/quickenter/style-jmapp/css.js +2 -0
- package/dist/cjs/packages/quickenter/style-jmapp/index.js +2 -0
- package/dist/cjs/packages/quickenter/style-jmapp/quickenter.scss +120 -0
- package/dist/cjs/packages/quickenter/style-jmapp/style.css +106 -0
- package/dist/cjs/packages/quickenter/style-jrkf/css.js +2 -0
- package/dist/cjs/packages/quickenter/style-jrkf/index.js +2 -0
- package/dist/cjs/packages/quickenter/style-jrkf/quickenter.scss +120 -0
- package/dist/cjs/packages/quickenter/style-jrkf/style.css +106 -0
- package/dist/cjs/packages/radio/index.js +0 -2
- package/dist/cjs/packages/range/range.js +44 -28
- package/dist/cjs/packages/rate/rate.js +5 -8
- package/dist/cjs/packages/resultpage/resultpage.js +2 -1
- package/dist/cjs/packages/resultpage/style/style.harmony.css +0 -3
- package/dist/cjs/packages/safearea/safearea.js +3 -12
- package/dist/cjs/packages/safearea/style/safearea.scss +0 -6
- package/dist/cjs/packages/safearea/style/style.css +0 -2
- package/dist/cjs/packages/safearea/style/style.harmony.css +0 -2
- package/dist/cjs/packages/safearea/style-jmapp/safearea.scss +0 -6
- package/dist/cjs/packages/safearea/style-jmapp/style.css +0 -2
- package/dist/cjs/packages/safearea/style-jrkf/safearea.scss +0 -6
- package/dist/cjs/packages/safearea/style-jrkf/style.css +0 -2
- package/dist/cjs/packages/searchbar/searchbar.js +23 -9
- package/dist/cjs/packages/shortpassword/shortpassword.js +3 -3
- package/dist/cjs/packages/shortpassword/style/style.harmony.css +38 -17
- package/dist/cjs/packages/step/step.js +3 -8
- package/dist/cjs/packages/step/style/step.scss +0 -2
- package/dist/cjs/packages/step/style/style.css +0 -2
- package/dist/cjs/packages/step/style/style.harmony.css +0 -2
- package/dist/cjs/packages/step/style-jmapp/step.scss +0 -2
- package/dist/cjs/packages/step/style-jmapp/style.css +0 -2
- package/dist/cjs/packages/step/style-jrkf/step.scss +0 -2
- package/dist/cjs/packages/step/style-jrkf/style.css +0 -2
- package/dist/cjs/packages/steps/style/steps.scss +10 -3
- package/dist/cjs/packages/steps/style/style.css +13 -7
- package/dist/cjs/packages/steps/style/style.harmony.css +13 -9
- package/dist/cjs/packages/steps/style-jmapp/steps.scss +10 -3
- package/dist/cjs/packages/steps/style-jmapp/style.css +9 -3
- package/dist/cjs/packages/steps/style-jrkf/steps.scss +10 -3
- package/dist/cjs/packages/steps/style-jrkf/style.css +9 -3
- package/dist/cjs/packages/sticky/sticky.js +4 -7
- package/dist/cjs/packages/swipe/swipe.js +84 -122
- package/dist/cjs/packages/swiper/index.js +0 -1
- package/dist/cjs/packages/switch/switch.js +4 -7
- package/dist/cjs/packages/table/style/style.css +1 -1
- package/dist/cjs/packages/table/style/style.harmony.css +1 -1
- package/dist/cjs/packages/table/style/table.scss +1 -1
- package/dist/cjs/packages/table/style-jmapp/style.css +1 -1
- package/dist/cjs/packages/table/style-jmapp/table.scss +1 -1
- package/dist/cjs/packages/table/style-jrkf/style.css +1 -1
- package/dist/cjs/packages/table/style-jrkf/table.scss +1 -1
- package/dist/cjs/packages/tabs/tabs.js +12 -5
- package/dist/cjs/packages/tag/style/style.css +1 -1
- package/dist/cjs/packages/tag/style/style.harmony.css +1 -1
- package/dist/cjs/packages/tag/style/tag.scss +1 -1
- package/dist/cjs/packages/tag/style-jmapp/style.css +1 -1
- package/dist/cjs/packages/tag/style-jmapp/tag.scss +1 -1
- package/dist/cjs/packages/tag/style-jrkf/style.css +1 -1
- package/dist/cjs/packages/tag/style-jrkf/tag.scss +1 -1
- package/dist/cjs/packages/timeselect/style/style.harmony.css +38 -17
- package/dist/cjs/packages/toast/style/style.css +2 -4
- package/dist/cjs/packages/toast/style/style.harmony.css +2 -4
- package/dist/cjs/packages/toast/style/toast.scss +2 -4
- package/dist/cjs/packages/toast/style-jmapp/style.css +2 -4
- package/dist/cjs/packages/toast/style-jmapp/toast.scss +2 -4
- package/dist/cjs/packages/toast/style-jrkf/style.css +2 -4
- package/dist/cjs/packages/toast/style-jrkf/toast.scss +2 -4
- package/dist/cjs/packages/toast/toast.js +5 -5
- package/dist/cjs/packages/tour/style/style.harmony.css +38 -17
- package/dist/cjs/packages/uploader/uploader.js +38 -51
- package/dist/cjs/packages/virtuallist/utils.js +6 -6
- package/dist/cjs/packages/watermark/watermark.js +4 -8
- package/dist/cjs/types/index.d.ts +3 -0
- package/dist/cjs/types/index.js +3 -0
- package/dist/cjs/types/spec/address/base.js +0 -2
- package/dist/cjs/types/spec/button/base.d.ts +2 -1
- package/dist/cjs/types/spec/button/taro.d.ts +5 -1
- package/dist/cjs/types/spec/calendarcard/base.d.ts +2 -0
- package/dist/cjs/types/spec/dialog/base.d.ts +1 -0
- package/dist/cjs/types/spec/dialog/h5.d.ts +2 -0
- package/dist/cjs/types/spec/dialog/taro.d.ts +2 -0
- package/dist/cjs/types/spec/overlay/base.d.ts +1 -0
- package/dist/cjs/types/spec/popup/base.d.ts +2 -0
- package/dist/cjs/types/spec/price/base.d.ts +1 -0
- package/dist/cjs/types/spec/quickenter/base.d.ts +27 -0
- package/dist/cjs/types/spec/quickenter/base.js +4 -0
- package/dist/cjs/types/spec/quickenter/h5.d.ts +5 -0
- package/dist/cjs/types/spec/quickenter/h5.js +4 -0
- package/dist/cjs/types/spec/quickenter/taro.d.ts +5 -0
- package/dist/cjs/types/spec/quickenter/taro.js +4 -0
- package/dist/cjs/utils/date.js +5 -5
- package/dist/cjs/utils/event-mocker.js +10 -18
- package/dist/cjs/utils/get-rect.js +4 -4
- package/dist/cjs/utils/get-scroll-parent.js +3 -3
- package/dist/cjs/utils/merge-props.js +3 -3
- package/dist/cjs/utils/merge.js +6 -6
- package/dist/cjs/utils/raf.js +3 -3
- package/dist/cjs/utils/render.js +5 -9
- package/dist/cjs/utils/rubberband.js +3 -3
- package/dist/cjs/utils/should-render-price-raw.d.ts +2 -0
- package/dist/cjs/utils/should-render-price-raw.js +46 -0
- package/dist/cjs/utils/taro/ConfigurableCSSTransition.d.ts +15 -0
- package/dist/cjs/utils/taro/ConfigurableCSSTransition.js +90 -0
- package/dist/cjs/utils/taro/get-rect.js +18 -26
- package/dist/cjs/utils/taro/get-system-info.d.ts +0 -5
- package/dist/cjs/utils/taro/get-system-info.js +5 -10
- package/dist/cjs/utils/taro/platform.js +5 -5
- package/dist/es/hooks/taro/use-custom-event.js +1 -0
- package/dist/es/hooks/use-touch.js +1 -1
- package/dist/es/locales/base.d.ts +9 -0
- package/dist/es/locales/en-US.js +21 -2
- package/dist/es/locales/id-ID.js +21 -2
- package/dist/es/locales/ja-JP.js +19 -2
- package/dist/es/locales/tr-TR.js +21 -2
- package/dist/es/locales/zh-CN.js +19 -2
- package/dist/es/locales/zh-TW.js +19 -2
- package/dist/es/locales/zh-UG.js +21 -2
- package/dist/es/packages/actionsheet/style/style.harmony.css +38 -17
- package/dist/es/packages/address/address.d.ts +1 -1
- package/dist/es/packages/address/style/style.harmony.css +38 -17
- package/dist/es/packages/animatingnumbers/countup.js +3 -1
- package/dist/es/packages/audio/style/style.harmony.css +0 -3
- package/dist/es/packages/avatar/avatar.js +32 -6
- package/dist/es/packages/avatarcropper/avatarcropper.js +20 -36
- package/dist/es/packages/badge/badge.js +20 -10
- package/dist/es/packages/barrage/barrage.js +14 -24
- package/dist/es/packages/button/button.d.ts +2 -24
- package/dist/es/packages/button/button.js +10 -12
- package/dist/es/packages/button/index.d.ts +0 -1
- package/dist/es/packages/button/style/button.scss +0 -3
- package/dist/es/packages/button/style/style.css +0 -3
- package/dist/es/packages/button/style/style.harmony.css +0 -3
- package/dist/es/packages/button/style-jmapp/button.scss +0 -3
- package/dist/es/packages/button/style-jmapp/style.css +0 -3
- package/dist/es/packages/button/style-jrkf/button.scss +0 -3
- package/dist/es/packages/button/style-jrkf/style.css +0 -3
- package/dist/es/packages/calendar/style/calendar.scss +32 -1
- package/dist/es/packages/calendar/style/style.css +21 -1
- package/dist/es/packages/calendar/style/style.harmony.css +59 -18
- package/dist/es/packages/calendar/style-jmapp/calendar.scss +32 -1
- package/dist/es/packages/calendar/style-jmapp/style.css +21 -1
- package/dist/es/packages/calendar/style-jrkf/calendar.scss +32 -1
- package/dist/es/packages/calendar/style-jrkf/style.css +21 -1
- package/dist/es/packages/calendarcard/calendarcard.js +31 -9
- package/dist/es/packages/calendarcard/icon.js +13 -24
- package/dist/es/packages/calendarcard/style/calendarcard.scss +19 -0
- package/dist/es/packages/calendarcard/style/style.css +13 -0
- package/dist/es/packages/calendarcard/style/style.harmony.css +13 -0
- package/dist/es/packages/calendarcard/style-jmapp/calendarcard.scss +19 -0
- package/dist/es/packages/calendarcard/style-jmapp/style.css +13 -0
- package/dist/es/packages/calendarcard/style-jrkf/calendarcard.scss +19 -0
- package/dist/es/packages/calendarcard/style-jrkf/style.css +13 -0
- package/dist/es/packages/card/style/style.harmony.css +1 -1
- package/dist/es/packages/cascader/cascader.js +12 -21
- package/dist/es/packages/cascader/style/style.harmony.css +38 -17
- package/dist/es/packages/collapseitem/collapseitem.js +4 -7
- package/dist/es/packages/configprovider/types.d.ts +1 -1
- package/dist/es/packages/countdown/countdown.js +1 -2
- package/dist/es/packages/datepicker/style/style.harmony.css +39 -18
- package/dist/es/packages/dialog/dialog.js +33 -28
- package/dist/es/packages/dialog/style/dialog.scss +1 -1
- package/dist/es/packages/dialog/style/style.css +1 -1
- package/dist/es/packages/dialog/style/style.harmony.css +1 -4
- package/dist/es/packages/dialog/style-jmapp/dialog.scss +1 -1
- package/dist/es/packages/dialog/style-jmapp/style.css +1 -1
- package/dist/es/packages/dialog/style-jrkf/dialog.scss +1 -1
- package/dist/es/packages/dialog/style-jrkf/style.css +1 -1
- package/dist/es/packages/divider/divider.js +1 -1
- package/dist/es/packages/drag/drag.js +4 -7
- package/dist/es/packages/elevator/elevator.js +4 -7
- package/dist/es/packages/ellipsis/ellipsis.js +17 -30
- package/dist/es/packages/empty/empty.d.ts +4 -4
- package/dist/es/packages/empty/style/style.harmony.css +0 -3
- package/dist/es/packages/form/index.js +0 -1
- package/dist/es/packages/form/style/style.harmony.css +0 -5
- package/dist/es/packages/form/useform.js +46 -53
- package/dist/es/packages/formitem/style/formitem.scss +4 -4
- package/dist/es/packages/formitem/style/style.css +0 -5
- package/dist/es/packages/formitem/style/style.harmony.css +0 -5
- package/dist/es/packages/formitem/style-jmapp/formitem.scss +4 -4
- package/dist/es/packages/formitem/style-jmapp/style.css +0 -5
- package/dist/es/packages/formitem/style-jrkf/formitem.scss +4 -4
- package/dist/es/packages/formitem/style-jrkf/style.css +0 -5
- package/dist/es/packages/image/image.js +11 -3
- package/dist/es/packages/imagepreview/style/style.harmony.css +38 -17
- package/dist/es/packages/infiniteloading/infiniteloading.js +8 -14
- package/dist/es/packages/input/input.js +10 -3
- package/dist/es/packages/inputnumber/inputnumber.js +17 -29
- package/dist/es/packages/lottie/lottiemp.js +12 -20
- package/dist/es/packages/lottie/types.js +1 -1
- package/dist/es/packages/menuitem/menuitem.js +24 -22
- package/dist/es/packages/noticebar/noticebar.js +74 -70
- package/dist/es/packages/numberkeyboard/style/style.css +1 -1
- package/dist/es/packages/numberkeyboard/style/style.harmony.css +39 -18
- package/dist/es/packages/nutui.react.build.d.ts +3 -1
- package/dist/es/packages/nutui.react.build.js +3 -1
- package/dist/es/packages/overlay/overlay.js +3 -3
- package/dist/es/packages/picker/style/style.css +1 -1
- package/dist/es/packages/picker/style/style.harmony.css +39 -18
- package/dist/es/packages/pickerview/pickerroller.js +4 -7
- package/dist/es/packages/pickerview/pickerview.js +1 -2
- package/dist/es/packages/popover/popover.js +75 -77
- package/dist/es/packages/popover/style/style.harmony.css +38 -17
- package/dist/es/packages/popup/popup.js +193 -114
- package/dist/es/packages/popup/style/popup.scss +22 -1
- package/dist/es/packages/popup/style/style.css +38 -17
- package/dist/es/packages/popup/style/style.harmony.css +38 -17
- package/dist/es/packages/popup/style-jmapp/popup.scss +22 -1
- package/dist/es/packages/popup/style-jmapp/style.css +22 -1
- package/dist/es/packages/popup/style-jrkf/popup.scss +22 -1
- package/dist/es/packages/popup/style-jrkf/style.css +22 -1
- package/dist/es/packages/price/price.js +53 -14
- package/dist/es/packages/progress/progress.js +2 -4
- package/dist/es/packages/pulltorefresh/pulltorefresh.js +52 -56
- package/dist/es/packages/quickenter/index.d.ts +3 -0
- package/dist/es/packages/quickenter/index.js +2 -0
- package/dist/es/packages/quickenter/quickenter.d.ts +4 -0
- package/dist/es/packages/quickenter/quickenter.js +141 -0
- package/dist/es/packages/quickenter/style/css.js +2 -0
- package/dist/es/packages/quickenter/style/index.js +2 -0
- package/dist/es/packages/quickenter/style/quickenter.scss +120 -0
- package/dist/es/packages/quickenter/style/style.css +106 -0
- package/dist/es/packages/quickenter/style/style.harmony.css +506 -0
- package/dist/es/packages/quickenter/style-jmapp/css.js +2 -0
- package/dist/es/packages/quickenter/style-jmapp/index.js +2 -0
- package/dist/es/packages/quickenter/style-jmapp/quickenter.scss +120 -0
- package/dist/es/packages/quickenter/style-jmapp/style.css +106 -0
- package/dist/es/packages/quickenter/style-jrkf/css.js +2 -0
- package/dist/es/packages/quickenter/style-jrkf/index.js +2 -0
- package/dist/es/packages/quickenter/style-jrkf/quickenter.scss +120 -0
- package/dist/es/packages/quickenter/style-jrkf/style.css +106 -0
- package/dist/es/packages/radio/index.js +0 -1
- package/dist/es/packages/range/range.js +45 -29
- package/dist/es/packages/rate/rate.js +6 -9
- package/dist/es/packages/resultpage/resultpage.js +2 -1
- package/dist/es/packages/resultpage/style/style.harmony.css +0 -3
- package/dist/es/packages/safearea/safearea.js +3 -12
- package/dist/es/packages/safearea/style/safearea.scss +0 -6
- package/dist/es/packages/safearea/style/style.css +0 -2
- package/dist/es/packages/safearea/style/style.harmony.css +0 -2
- package/dist/es/packages/safearea/style-jmapp/safearea.scss +0 -6
- package/dist/es/packages/safearea/style-jmapp/style.css +0 -2
- package/dist/es/packages/safearea/style-jrkf/safearea.scss +0 -6
- package/dist/es/packages/safearea/style-jrkf/style.css +0 -2
- package/dist/es/packages/searchbar/searchbar.js +23 -9
- package/dist/es/packages/shortpassword/style/style.harmony.css +38 -17
- package/dist/es/packages/step/step.js +3 -8
- package/dist/es/packages/step/style/step.scss +0 -2
- package/dist/es/packages/step/style/style.css +0 -2
- package/dist/es/packages/step/style/style.harmony.css +0 -2
- package/dist/es/packages/step/style-jmapp/step.scss +0 -2
- package/dist/es/packages/step/style-jmapp/style.css +0 -2
- package/dist/es/packages/step/style-jrkf/step.scss +0 -2
- package/dist/es/packages/step/style-jrkf/style.css +0 -2
- package/dist/es/packages/steps/style/steps.scss +10 -3
- package/dist/es/packages/steps/style/style.css +13 -7
- package/dist/es/packages/steps/style/style.harmony.css +13 -9
- package/dist/es/packages/steps/style-jmapp/steps.scss +10 -3
- package/dist/es/packages/steps/style-jmapp/style.css +9 -3
- package/dist/es/packages/steps/style-jrkf/steps.scss +10 -3
- package/dist/es/packages/steps/style-jrkf/style.css +9 -3
- package/dist/es/packages/sticky/sticky.js +4 -7
- package/dist/es/packages/swipe/swipe.js +85 -123
- package/dist/es/packages/swiper/index.js +0 -1
- package/dist/es/packages/switch/switch.js +4 -7
- package/dist/es/packages/table/style/style.css +1 -1
- package/dist/es/packages/table/style/style.harmony.css +1 -1
- package/dist/es/packages/table/style/table.scss +1 -1
- package/dist/es/packages/table/style-jmapp/style.css +1 -1
- package/dist/es/packages/table/style-jmapp/table.scss +1 -1
- package/dist/es/packages/table/style-jrkf/style.css +1 -1
- package/dist/es/packages/table/style-jrkf/table.scss +1 -1
- package/dist/es/packages/tabs/tabs.js +12 -5
- package/dist/es/packages/tag/style/style.css +1 -1
- package/dist/es/packages/tag/style/style.harmony.css +1 -1
- package/dist/es/packages/tag/style/tag.scss +1 -1
- package/dist/es/packages/tag/style-jmapp/style.css +1 -1
- package/dist/es/packages/tag/style-jmapp/tag.scss +1 -1
- package/dist/es/packages/tag/style-jrkf/style.css +1 -1
- package/dist/es/packages/tag/style-jrkf/tag.scss +1 -1
- package/dist/es/packages/timeselect/style/style.harmony.css +38 -17
- package/dist/es/packages/toast/style/style.css +2 -4
- package/dist/es/packages/toast/style/style.harmony.css +2 -4
- package/dist/es/packages/toast/style/toast.scss +2 -4
- package/dist/es/packages/toast/style-jmapp/style.css +2 -4
- package/dist/es/packages/toast/style-jmapp/toast.scss +2 -4
- package/dist/es/packages/toast/style-jrkf/style.css +2 -4
- package/dist/es/packages/toast/style-jrkf/toast.scss +2 -4
- package/dist/es/packages/toast/toast.js +1 -1
- package/dist/es/packages/tour/style/style.harmony.css +38 -17
- package/dist/es/packages/uploader/uploader.js +38 -51
- package/dist/es/packages/watermark/watermark.js +4 -8
- package/dist/es/types/index.d.ts +3 -0
- package/dist/es/types/index.js +3 -0
- package/dist/es/types/spec/address/base.js +1 -1
- package/dist/es/types/spec/button/base.d.ts +2 -1
- package/dist/es/types/spec/button/taro.d.ts +5 -1
- package/dist/es/types/spec/calendarcard/base.d.ts +2 -0
- package/dist/es/types/spec/dialog/base.d.ts +3 -8
- package/dist/es/types/spec/dialog/h5.d.ts +2 -0
- package/dist/es/types/spec/dialog/taro.d.ts +2 -0
- package/dist/es/types/spec/overlay/base.d.ts +1 -0
- package/dist/es/types/spec/popup/base.d.ts +4 -5
- package/dist/es/types/spec/price/base.d.ts +4 -0
- package/dist/es/types/spec/quickenter/base.d.ts +45 -0
- package/dist/es/types/spec/quickenter/base.js +1 -0
- package/dist/es/types/spec/quickenter/h5.d.ts +5 -0
- package/dist/es/types/spec/quickenter/h5.js +1 -0
- package/dist/es/types/spec/quickenter/taro.d.ts +5 -0
- package/dist/es/types/spec/quickenter/taro.js +1 -0
- package/dist/es/utils/event-mocker.js +4 -12
- package/dist/es/utils/render.js +2 -6
- package/dist/es/utils/should-render-price-raw.d.ts +2 -0
- package/dist/es/utils/should-render-price-raw.js +30 -0
- package/dist/es/utils/taro/ConfigurableCSSTransition.d.ts +15 -0
- package/dist/es/utils/taro/ConfigurableCSSTransition.js +79 -0
- package/dist/es/utils/taro/get-rect.js +14 -22
- package/dist/es/utils/taro/get-system-info.d.ts +0 -5
- package/dist/es/utils/taro/get-system-info.js +8 -7
- package/dist/nutui.react.umd.js +8698 -7529
- package/dist/style-jmapp.css +1 -1
- package/dist/style-jmapp.scss +47 -46
- package/dist/style-jrkf.css +1 -1
- package/dist/style-jrkf.scss +31 -30
- package/dist/style.css +1 -1
- package/dist/style.scss +34 -33
- package/dist/styles/jd-font.scss +2 -2
- package/dist/styles/theme-dark.scss +1 -2
- package/dist/styles/themes/daojia.css +1 -1
- package/dist/styles/themes/dark-daojia.css +1 -1
- package/dist/styles/themes/dark.css +1 -1
- package/dist/styles/themes/default.css +1 -1
- package/dist/styles/variables-daojia.scss +41 -0
- package/dist/styles/variables-jmapp.scss +41 -0
- package/dist/styles/variables-jrkf.scss +41 -0
- package/dist/styles/variables.scss +49 -4
- package/package.json +1 -1
- package/dist/cjs/locales/vi-VN.d.ts +0 -3
- package/dist/cjs/locales/vi-VN.js +0 -170
- package/dist/es/locales/vi-VN.d.ts +0 -3
- package/dist/es/locales/vi-VN.js +0 -160
- package/postinstall.js +0 -9
|
@@ -221,7 +221,7 @@
|
|
|
221
221
|
align-items: center;
|
|
222
222
|
justify-content: center;
|
|
223
223
|
border-bottom: var(--nutui-popup-title-border-bottom, 0);
|
|
224
|
-
padding: var(--nutui-popup-title-padding,
|
|
224
|
+
padding: var(--nutui-popup-title-padding, 11px);
|
|
225
225
|
position: relative;
|
|
226
226
|
}
|
|
227
227
|
.nut-popup-title-wrapper {
|
|
@@ -234,7 +234,6 @@
|
|
|
234
234
|
color: var(--nutui-color-title, #1a1a1a);
|
|
235
235
|
font-weight: var(--nutui-font-weight-bold, 600);
|
|
236
236
|
font-size: var(--nutui-popup-title-font-size, var(--nutui-font-size-xl, 18px));
|
|
237
|
-
line-height: var(--nutui-popup-title-font-size, var(--nutui-font-size-xl, 18px));
|
|
238
237
|
}
|
|
239
238
|
.nut-popup-title-description {
|
|
240
239
|
color: var(--nutui-color-text, #505259);
|
|
@@ -246,13 +245,13 @@
|
|
|
246
245
|
}
|
|
247
246
|
.nut-popup-title-left {
|
|
248
247
|
position: absolute;
|
|
249
|
-
top: var(--nutui-popup-title-padding,
|
|
250
|
-
left: var(--nutui-popup-title-padding,
|
|
248
|
+
top: var(--nutui-popup-title-padding, 11px);
|
|
249
|
+
left: var(--nutui-popup-title-padding, 11px);
|
|
251
250
|
}
|
|
252
251
|
.nut-popup-title-right {
|
|
253
252
|
position: absolute;
|
|
254
|
-
top: var(--nutui-popup-title-padding,
|
|
255
|
-
right: var(--nutui-popup-title-padding,
|
|
253
|
+
top: var(--nutui-popup-title-padding, 11px);
|
|
254
|
+
right: var(--nutui-popup-title-padding, 11px);
|
|
256
255
|
z-index: 1;
|
|
257
256
|
width: var(--nutui-popup-icon-size, 20px);
|
|
258
257
|
height: var(--nutui-popup-icon-size, 20px);
|
|
@@ -263,20 +262,22 @@
|
|
|
263
262
|
opacity: 0.7;
|
|
264
263
|
}
|
|
265
264
|
.nut-popup-title-right-top-left {
|
|
266
|
-
top: var(--nutui-popup-title-padding,
|
|
267
|
-
left: var(--nutui-popup-title-padding,
|
|
265
|
+
top: var(--nutui-popup-title-padding, 11px);
|
|
266
|
+
left: var(--nutui-popup-title-padding, 11px);
|
|
268
267
|
}
|
|
269
268
|
.nut-popup-title-right-bottom-left {
|
|
270
|
-
bottom: var(--nutui-popup-title-padding,
|
|
271
|
-
left: var(--nutui-popup-title-padding,
|
|
269
|
+
bottom: var(--nutui-popup-title-padding, 11px);
|
|
270
|
+
left: var(--nutui-popup-title-padding, 11px);
|
|
272
271
|
}
|
|
273
272
|
.nut-popup-title-right-bottom-right {
|
|
274
|
-
right: var(--nutui-popup-title-padding,
|
|
275
|
-
bottom: var(--nutui-popup-title-padding,
|
|
273
|
+
right: var(--nutui-popup-title-padding, 11px);
|
|
274
|
+
bottom: var(--nutui-popup-title-padding, 11px);
|
|
276
275
|
}
|
|
277
276
|
.nut-popup-center {
|
|
278
277
|
top: 50%;
|
|
279
278
|
left: 50%;
|
|
279
|
+
right: auto;
|
|
280
|
+
bottom: auto;
|
|
280
281
|
min-height: 10%;
|
|
281
282
|
max-width: 295px;
|
|
282
283
|
transform: translate(-50%, -50%);
|
|
@@ -287,6 +288,8 @@
|
|
|
287
288
|
.nut-popup-bottom {
|
|
288
289
|
bottom: 0;
|
|
289
290
|
left: 0;
|
|
291
|
+
right: auto;
|
|
292
|
+
top: auto;
|
|
290
293
|
width: 100%;
|
|
291
294
|
}
|
|
292
295
|
.nut-popup-bottom.nut-popup-round {
|
|
@@ -298,6 +301,8 @@
|
|
|
298
301
|
.nut-popup-right {
|
|
299
302
|
top: 0;
|
|
300
303
|
right: 0;
|
|
304
|
+
left: auto;
|
|
305
|
+
bottom: auto;
|
|
301
306
|
width: 100px;
|
|
302
307
|
height: 100%;
|
|
303
308
|
}
|
|
@@ -307,6 +312,8 @@
|
|
|
307
312
|
.nut-popup-left {
|
|
308
313
|
top: 0;
|
|
309
314
|
left: 0;
|
|
315
|
+
right: auto;
|
|
316
|
+
bottom: auto;
|
|
310
317
|
width: 100px;
|
|
311
318
|
height: 100%;
|
|
312
319
|
}
|
|
@@ -316,6 +323,8 @@
|
|
|
316
323
|
.nut-popup-top {
|
|
317
324
|
top: 0;
|
|
318
325
|
left: 0;
|
|
326
|
+
right: auto;
|
|
327
|
+
bottom: auto;
|
|
319
328
|
width: 100%;
|
|
320
329
|
}
|
|
321
330
|
.nut-popup-top.nut-popup-round {
|
|
@@ -392,6 +401,9 @@
|
|
|
392
401
|
}
|
|
393
402
|
}
|
|
394
403
|
@keyframes popup-slide-top-exit {
|
|
404
|
+
from {
|
|
405
|
+
transform: translate3d(0, 0%, 0);
|
|
406
|
+
}
|
|
395
407
|
to {
|
|
396
408
|
transform: translate3d(0, -100%, 0);
|
|
397
409
|
}
|
|
@@ -416,6 +428,9 @@
|
|
|
416
428
|
}
|
|
417
429
|
}
|
|
418
430
|
@keyframes popup-slide-right-exit {
|
|
431
|
+
from {
|
|
432
|
+
transform: translate3d(0%, 0, 0);
|
|
433
|
+
}
|
|
419
434
|
to {
|
|
420
435
|
transform: translate3d(100%, 0, 0);
|
|
421
436
|
}
|
|
@@ -440,6 +455,9 @@
|
|
|
440
455
|
}
|
|
441
456
|
}
|
|
442
457
|
@keyframes slide-bottom-exit {
|
|
458
|
+
from {
|
|
459
|
+
transform: translate3d(0, 0%, 0);
|
|
460
|
+
}
|
|
443
461
|
to {
|
|
444
462
|
transform: translate3d(0, 100%, 0);
|
|
445
463
|
}
|
|
@@ -464,6 +482,9 @@
|
|
|
464
482
|
}
|
|
465
483
|
}
|
|
466
484
|
@keyframes popup-slide-left-exit {
|
|
485
|
+
from {
|
|
486
|
+
transform: translate3d(0%, 0, 0);
|
|
487
|
+
}
|
|
467
488
|
to {
|
|
468
489
|
transform: translate3d(-100%, 0, 0);
|
|
469
490
|
}
|
|
@@ -489,27 +510,27 @@
|
|
|
489
510
|
[dir=rtl] .nut-popup-title-left,
|
|
490
511
|
.nut-rtl .nut-popup-title-left {
|
|
491
512
|
left: auto;
|
|
492
|
-
right: var(--nutui-popup-title-padding,
|
|
513
|
+
right: var(--nutui-popup-title-padding, 11px);
|
|
493
514
|
}
|
|
494
515
|
[dir=rtl] .nut-popup-title-right,
|
|
495
516
|
.nut-rtl .nut-popup-title-right {
|
|
496
517
|
right: auto;
|
|
497
|
-
left: var(--nutui-popup-title-padding,
|
|
518
|
+
left: var(--nutui-popup-title-padding, 11px);
|
|
498
519
|
}
|
|
499
520
|
[dir=rtl] .nut-popup-title-right-top-left,
|
|
500
521
|
.nut-rtl .nut-popup-title-right-top-left {
|
|
501
522
|
left: auto;
|
|
502
|
-
right: var(--nutui-popup-title-padding,
|
|
523
|
+
right: var(--nutui-popup-title-padding, 11px);
|
|
503
524
|
}
|
|
504
525
|
[dir=rtl] .nut-popup-title-right-bottom-left,
|
|
505
526
|
.nut-rtl .nut-popup-title-right-bottom-left {
|
|
506
527
|
left: auto;
|
|
507
|
-
right: var(--nutui-popup-title-padding,
|
|
528
|
+
right: var(--nutui-popup-title-padding, 11px);
|
|
508
529
|
}
|
|
509
530
|
[dir=rtl] .nut-popup-title-right-bottom-right,
|
|
510
531
|
.nut-rtl .nut-popup-title-right-bottom-right {
|
|
511
532
|
right: auto;
|
|
512
|
-
left: var(--nutui-popup-title-padding,
|
|
533
|
+
left: var(--nutui-popup-title-padding, 11px);
|
|
513
534
|
}
|
|
514
535
|
[dir=rtl] .nut-popup-title .nut-icon-ArrowLeft,
|
|
515
536
|
.nut-rtl .nut-popup-title .nut-icon-ArrowLeft {
|
|
@@ -5,14 +5,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
function _export(target, all) {
|
|
6
6
|
for(var name in all)Object.defineProperty(target, name, {
|
|
7
7
|
enumerable: true,
|
|
8
|
-
get: all
|
|
8
|
+
get: Object.getOwnPropertyDescriptor(all, name).get
|
|
9
9
|
});
|
|
10
10
|
}
|
|
11
11
|
_export(exports, {
|
|
12
|
-
findDataByName
|
|
12
|
+
get findDataByName () {
|
|
13
13
|
return findDataByName;
|
|
14
14
|
},
|
|
15
|
-
transformData
|
|
15
|
+
get transformData () {
|
|
16
16
|
return transformData;
|
|
17
17
|
}
|
|
18
18
|
});
|
|
@@ -59,7 +59,9 @@ var CountUp = function CountUp(props) {
|
|
|
59
59
|
var isLoaded = (0, _react.useRef)(false);
|
|
60
60
|
var setNumberTransform = (0, _react.useCallback)(function() {
|
|
61
61
|
if (countupRef.current && numberArr.length) {
|
|
62
|
-
|
|
62
|
+
var _countupRef_current;
|
|
63
|
+
(0, _taro.createSelectorQuery)() // @ts-ignore
|
|
64
|
+
.in(((_countupRef_current = countupRef.current) === null || _countupRef_current === void 0 ? void 0 : _countupRef_current._scope) || countupRef.current).selectAll('.nut-countup-listitem').node(function(numberItems) {
|
|
63
65
|
var transformArrCache = [];
|
|
64
66
|
Object.keys(numberItems).forEach(function(key) {
|
|
65
67
|
var elem = numberItems[Number(key)];
|
|
@@ -13,6 +13,7 @@ var _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcar
|
|
|
13
13
|
var _define_property = require("@swc/helpers/_/_define_property");
|
|
14
14
|
var _object_spread = require("@swc/helpers/_/_object_spread");
|
|
15
15
|
var _object_spread_props = require("@swc/helpers/_/_object_spread_props");
|
|
16
|
+
var _object_without_properties = require("@swc/helpers/_/_object_without_properties");
|
|
16
17
|
var _sliced_to_array = require("@swc/helpers/_/_sliced_to_array");
|
|
17
18
|
var _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
|
18
19
|
var _components = require("@tarojs/components");
|
|
@@ -37,7 +38,23 @@ var defaultProps = (0, _object_spread_props._)((0, _object_spread._)({}, _typing
|
|
|
37
38
|
});
|
|
38
39
|
var classPrefix = "nut-avatar";
|
|
39
40
|
var Avatar = function Avatar(props) {
|
|
40
|
-
var
|
|
41
|
+
var _ref = (0, _object_spread._)({}, defaultProps, props), children = _ref.children, size = _ref.size, shape = _ref.shape, background = _ref.background, color = _ref.color, src = _ref.src, alt = _ref.alt, icon = _ref.icon, mode = _ref.mode, fit = _ref.fit, avatarIndex = _ref.avatarIndex, className = _ref.className, style = _ref.style, onClick = _ref.onClick, onError = _ref.onError, rest = (0, _object_without_properties._)(_ref, [
|
|
42
|
+
"children",
|
|
43
|
+
"size",
|
|
44
|
+
"shape",
|
|
45
|
+
"background",
|
|
46
|
+
"color",
|
|
47
|
+
"src",
|
|
48
|
+
"alt",
|
|
49
|
+
"icon",
|
|
50
|
+
"mode",
|
|
51
|
+
"fit",
|
|
52
|
+
"avatarIndex",
|
|
53
|
+
"className",
|
|
54
|
+
"style",
|
|
55
|
+
"onClick",
|
|
56
|
+
"onError"
|
|
57
|
+
]);
|
|
41
58
|
var _useState // 是否显示的最大头像个数
|
|
42
59
|
= (0, _sliced_to_array._)((0, _react.useState)(false), 2), showMax = _useState[0], setShowMax = _useState[1];
|
|
43
60
|
var avatarRef = (0, _react.useRef)(null);
|
|
@@ -74,7 +91,8 @@ var Avatar = function Avatar(props) {
|
|
|
74
91
|
}
|
|
75
92
|
}, [
|
|
76
93
|
avatarIndex,
|
|
77
|
-
groupCount
|
|
94
|
+
groupCount,
|
|
95
|
+
groupMax
|
|
78
96
|
]);
|
|
79
97
|
var errorEvent = function errorEvent() {
|
|
80
98
|
onError && onError();
|
|
@@ -82,19 +100,26 @@ var Avatar = function Avatar(props) {
|
|
|
82
100
|
var clickAvatar = function clickAvatar(e) {
|
|
83
101
|
onClick && onClick(e);
|
|
84
102
|
};
|
|
85
|
-
return /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, null, (showMax || !groupMax || avatarIndex <= groupMax) && /*#__PURE__*/ _react.default.createElement(_components.View, {
|
|
103
|
+
return /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, null, (showMax || !groupMax || avatarIndex <= groupMax) && /*#__PURE__*/ _react.default.createElement(_components.View, (0, _object_spread._)({
|
|
86
104
|
className: cls,
|
|
87
105
|
style: !showMax ? styles : maxStyles,
|
|
88
106
|
onClick: clickAvatar,
|
|
89
|
-
ref: avatarRef
|
|
90
|
-
|
|
107
|
+
ref: avatarRef,
|
|
108
|
+
// @ts-ignore
|
|
109
|
+
ariaRole: onClick ? 'button' : undefined
|
|
110
|
+
}, rest), (!groupMax || avatarIndex <= groupMax) && /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, null, src && /*#__PURE__*/ _react.default.createElement(_components.Image, {
|
|
91
111
|
className: "nut-avatar-img nut-avatar-".concat(groupSize || size || 'normal', "-img"),
|
|
92
112
|
src: src,
|
|
113
|
+
nativeProps: {
|
|
114
|
+
alt: alt
|
|
115
|
+
},
|
|
93
116
|
style: {
|
|
94
117
|
objectFit: fit
|
|
95
118
|
},
|
|
96
119
|
mode: mode,
|
|
97
|
-
onError: errorEvent
|
|
120
|
+
onError: errorEvent,
|
|
121
|
+
// @ts-ignore
|
|
122
|
+
ariaHidden: true
|
|
98
123
|
}), /*#__PURE__*/ _react.default.isValidElement(icon) ? /*#__PURE__*/ _react.default.createElement(_components.View, {
|
|
99
124
|
className: "nut-avatar-text"
|
|
100
125
|
}, /*#__PURE__*/ _react.default.cloneElement(icon, (0, _object_spread_props._)((0, _object_spread._)({}, icon.props), {
|
|
@@ -108,6 +133,7 @@ var Avatar = function Avatar(props) {
|
|
|
108
133
|
}, children), !src && !icon && !children && /*#__PURE__*/ _react.default.createElement(_components.View, {
|
|
109
134
|
className: "nut-avatar-text"
|
|
110
135
|
}, /*#__PURE__*/ _react.default.createElement(_iconsreacttaro.User, {
|
|
136
|
+
ariaHidden: true,
|
|
111
137
|
style: {
|
|
112
138
|
color: color
|
|
113
139
|
},
|
|
@@ -129,7 +129,7 @@ var AvatarCropper = function AvatarCropper(props) {
|
|
|
129
129
|
cropperCanvas: null,
|
|
130
130
|
cropperCanvasContext: null
|
|
131
131
|
}), 2), canvasAll = _useState5[0], setCanvasAll = _useState5[1];
|
|
132
|
-
(0,
|
|
132
|
+
(0, _taro.useReady)(function() {
|
|
133
133
|
if (showAlipayCanvas2D) {
|
|
134
134
|
var canvasId = canvasAll.canvasId;
|
|
135
135
|
(0, _taro.createSelectorQuery)().select("#".concat(canvasId)).node(function(param) {
|
|
@@ -141,11 +141,7 @@ var AvatarCropper = function AvatarCropper(props) {
|
|
|
141
141
|
}));
|
|
142
142
|
}).exec();
|
|
143
143
|
}
|
|
144
|
-
}
|
|
145
|
-
showAlipayCanvas2D,
|
|
146
|
-
state.displayHeight,
|
|
147
|
-
state.displayWidth
|
|
148
|
-
]);
|
|
144
|
+
});
|
|
149
145
|
(0, _react.useEffect)(function() {
|
|
150
146
|
setCanvasAll((0, _object_spread_props._)((0, _object_spread._)({}, canvasAll), {
|
|
151
147
|
cropperCanvasContext: _taro.default.createCanvasContext(canvasAll.canvasId)
|
|
@@ -323,8 +319,8 @@ var AvatarCropper = function AvatarCropper(props) {
|
|
|
323
319
|
draw
|
|
324
320
|
]);
|
|
325
321
|
// 设置绘制图片
|
|
326
|
-
var setDrawImgInfo =
|
|
327
|
-
|
|
322
|
+
var setDrawImgInfo = function setDrawImgInfo(image) {
|
|
323
|
+
return (0, _async_to_generator._)(function() {
|
|
328
324
|
var displayWidth, cropperWidth, copyDrawImg, imgWidth, imgHeight, isPortrait, rate, scale;
|
|
329
325
|
return (0, _ts_generator._)(this, function(_state) {
|
|
330
326
|
switch(_state.label){
|
|
@@ -374,11 +370,8 @@ var AvatarCropper = function AvatarCropper(props) {
|
|
|
374
370
|
];
|
|
375
371
|
}
|
|
376
372
|
});
|
|
377
|
-
});
|
|
378
|
-
|
|
379
|
-
return _ref.apply(this, arguments);
|
|
380
|
-
};
|
|
381
|
-
}();
|
|
373
|
+
})();
|
|
374
|
+
};
|
|
382
375
|
var chooseImage = function chooseImage() {
|
|
383
376
|
_taro.default.chooseImage({
|
|
384
377
|
count: 1,
|
|
@@ -392,8 +385,8 @@ var AvatarCropper = function AvatarCropper(props) {
|
|
|
392
385
|
}
|
|
393
386
|
});
|
|
394
387
|
};
|
|
395
|
-
var imageChange =
|
|
396
|
-
|
|
388
|
+
var imageChange = function imageChange(file) {
|
|
389
|
+
return (0, _async_to_generator._)(function() {
|
|
397
390
|
return (0, _ts_generator._)(this, function(_state) {
|
|
398
391
|
_taro.default.getImageInfo({
|
|
399
392
|
src: file.path
|
|
@@ -405,11 +398,8 @@ var AvatarCropper = function AvatarCropper(props) {
|
|
|
405
398
|
2
|
|
406
399
|
];
|
|
407
400
|
});
|
|
408
|
-
});
|
|
409
|
-
|
|
410
|
-
return _ref.apply(this, arguments);
|
|
411
|
-
};
|
|
412
|
-
}();
|
|
401
|
+
})();
|
|
402
|
+
};
|
|
413
403
|
var resetScale = function resetScale(scale) {
|
|
414
404
|
setState((0, _object_spread_props._)((0, _object_spread._)({}, state), {
|
|
415
405
|
moveX: 0,
|
|
@@ -565,8 +555,8 @@ var AvatarCropper = function AvatarCropper(props) {
|
|
|
565
555
|
height: cropperWidth,
|
|
566
556
|
destWidth: cropperWidth,
|
|
567
557
|
destHeight: cropperWidth,
|
|
568
|
-
success:
|
|
569
|
-
|
|
558
|
+
success: function success(res) {
|
|
559
|
+
return (0, _async_to_generator._)(function() {
|
|
570
560
|
var filePath;
|
|
571
561
|
return (0, _ts_generator._)(this, function(_state) {
|
|
572
562
|
filePath = res.tempFilePath;
|
|
@@ -576,11 +566,8 @@ var AvatarCropper = function AvatarCropper(props) {
|
|
|
576
566
|
2
|
|
577
567
|
];
|
|
578
568
|
});
|
|
579
|
-
});
|
|
580
|
-
|
|
581
|
-
return _ref.apply(this, arguments);
|
|
582
|
-
};
|
|
583
|
-
}()
|
|
569
|
+
})();
|
|
570
|
+
}
|
|
584
571
|
});
|
|
585
572
|
};
|
|
586
573
|
// 裁剪图片
|
|
@@ -604,8 +591,8 @@ var AvatarCropper = function AvatarCropper(props) {
|
|
|
604
591
|
height: cropperWidth,
|
|
605
592
|
destWidth: cropperWidth * systemInfo.pixelRatio,
|
|
606
593
|
destHeight: cropperWidth * systemInfo.pixelRatio,
|
|
607
|
-
success:
|
|
608
|
-
|
|
594
|
+
success: function success(res) {
|
|
595
|
+
return (0, _async_to_generator._)(function() {
|
|
609
596
|
var filePath;
|
|
610
597
|
return (0, _ts_generator._)(this, function(_state) {
|
|
611
598
|
filePath = res.tempFilePath;
|
|
@@ -615,11 +602,8 @@ var AvatarCropper = function AvatarCropper(props) {
|
|
|
615
602
|
2
|
|
616
603
|
];
|
|
617
604
|
});
|
|
618
|
-
});
|
|
619
|
-
|
|
620
|
-
return _ref.apply(this, arguments);
|
|
621
|
-
};
|
|
622
|
-
}()
|
|
605
|
+
})();
|
|
606
|
+
}
|
|
623
607
|
});
|
|
624
608
|
};
|
|
625
609
|
var ToolBar = function ToolBar() {
|
|
@@ -14,6 +14,7 @@ var _async_to_generator = require("@swc/helpers/_/_async_to_generator");
|
|
|
14
14
|
var _define_property = require("@swc/helpers/_/_define_property");
|
|
15
15
|
var _object_spread = require("@swc/helpers/_/_object_spread");
|
|
16
16
|
var _object_spread_props = require("@swc/helpers/_/_object_spread_props");
|
|
17
|
+
var _object_without_properties = require("@swc/helpers/_/_object_without_properties");
|
|
17
18
|
var _sliced_to_array = require("@swc/helpers/_/_sliced_to_array");
|
|
18
19
|
var _type_of = require("@swc/helpers/_/_type_of");
|
|
19
20
|
var _ts_generator = require("@swc/helpers/_/_ts_generator");
|
|
@@ -53,7 +54,19 @@ var Badge = function Badge(props) {
|
|
|
53
54
|
};
|
|
54
55
|
var _this;
|
|
55
56
|
var rtl = (0, _index.useRtl)();
|
|
56
|
-
var
|
|
57
|
+
var _ref = (0, _object_spread._)({}, defaultProps, props), className = _ref.className, style = _ref.style, value = _ref.value, max = _ref.max, children = _ref.children, dot = _ref.dot, top = _ref.top, right = _ref.right, fill = _ref.fill, size = _ref.size, disabled = _ref.disabled, rest = (0, _object_without_properties._)(_ref, [
|
|
58
|
+
"className",
|
|
59
|
+
"style",
|
|
60
|
+
"value",
|
|
61
|
+
"max",
|
|
62
|
+
"children",
|
|
63
|
+
"dot",
|
|
64
|
+
"top",
|
|
65
|
+
"right",
|
|
66
|
+
"fill",
|
|
67
|
+
"size",
|
|
68
|
+
"disabled"
|
|
69
|
+
]);
|
|
57
70
|
var classPrefix = 'nut-badge';
|
|
58
71
|
var isHarmony = (0, _platform.harmony)();
|
|
59
72
|
var classes = (0, _classnames.default)(classPrefix, className);
|
|
@@ -66,8 +79,8 @@ var Badge = function Badge(props) {
|
|
|
66
79
|
getPositionStyle();
|
|
67
80
|
}
|
|
68
81
|
}, []);
|
|
69
|
-
var getPositionStyle =
|
|
70
|
-
|
|
82
|
+
var getPositionStyle = function getPositionStyle() {
|
|
83
|
+
return (0, _async_to_generator._)(function() {
|
|
71
84
|
var style;
|
|
72
85
|
return (0, _ts_generator._)(this, function(_state) {
|
|
73
86
|
style = (0, _define_property._)({
|
|
@@ -78,17 +91,14 @@ var Badge = function Badge(props) {
|
|
|
78
91
|
2
|
|
79
92
|
];
|
|
80
93
|
});
|
|
81
|
-
});
|
|
82
|
-
|
|
83
|
-
return _ref.apply(this, arguments);
|
|
84
|
-
};
|
|
85
|
-
}();
|
|
94
|
+
})();
|
|
95
|
+
};
|
|
86
96
|
var _obj1;
|
|
87
|
-
return /*#__PURE__*/ _react.default.createElement(_components.View, {
|
|
97
|
+
return /*#__PURE__*/ _react.default.createElement(_components.View, (0, _object_spread._)({
|
|
88
98
|
className: classes,
|
|
89
99
|
style: style,
|
|
90
100
|
ref: badgeRef
|
|
91
|
-
}, isIcon() && /*#__PURE__*/ _react.default.createElement(_components.View, {
|
|
101
|
+
}, rest), isIcon() && /*#__PURE__*/ _react.default.createElement(_components.View, {
|
|
92
102
|
className: (0, _classnames.default)("".concat(classPrefix, "-content"), (_obj1 = {}, (0, _define_property._)(_obj1, "".concat(classPrefix, "-icon"), true), (0, _define_property._)(_obj1, "".concat(classPrefix, "-icon-rtl"), rtl), _obj1)),
|
|
93
103
|
style: contentStyle
|
|
94
104
|
}, value), children, !isIcon() && (getContent() || dot) && /*#__PURE__*/ _react.default.createElement(_components.View, {
|
|
@@ -60,14 +60,13 @@ var InternalBarrage = function InternalBarrage(props, ref) {
|
|
|
60
60
|
}
|
|
61
61
|
};
|
|
62
62
|
});
|
|
63
|
-
var getNodeWidth =
|
|
64
|
-
var
|
|
65
|
-
|
|
66
|
-
var
|
|
63
|
+
var getNodeWidth = function getNodeWidth(node) {
|
|
64
|
+
var type = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 'width';
|
|
65
|
+
return (0, _async_to_generator._)(function() {
|
|
66
|
+
var refe;
|
|
67
67
|
return (0, _ts_generator._)(this, function(_state) {
|
|
68
68
|
switch(_state.label){
|
|
69
69
|
case 0:
|
|
70
|
-
type = _arguments.length > 1 && _arguments[1] !== void 0 ? _arguments[1] : 'width';
|
|
71
70
|
if (!node) return [
|
|
72
71
|
3,
|
|
73
72
|
2
|
|
@@ -89,11 +88,8 @@ var InternalBarrage = function InternalBarrage(props, ref) {
|
|
|
89
88
|
];
|
|
90
89
|
}
|
|
91
90
|
});
|
|
92
|
-
});
|
|
93
|
-
|
|
94
|
-
return _ref.apply(this, arguments);
|
|
95
|
-
};
|
|
96
|
-
}();
|
|
91
|
+
})();
|
|
92
|
+
};
|
|
97
93
|
var clearDomTimeout = function clearDomTimeout() {
|
|
98
94
|
if (domTimer.current) {
|
|
99
95
|
clearTimeout(domTimer.current);
|
|
@@ -101,8 +97,8 @@ var InternalBarrage = function InternalBarrage(props, ref) {
|
|
|
101
97
|
}
|
|
102
98
|
};
|
|
103
99
|
(0, _react.useEffect)(function() {
|
|
104
|
-
var init =
|
|
105
|
-
|
|
100
|
+
var init = function init() {
|
|
101
|
+
return (0, _async_to_generator._)(function() {
|
|
106
102
|
var _barrageBody_current;
|
|
107
103
|
return (0, _ts_generator._)(this, function(_state) {
|
|
108
104
|
switch(_state.label){
|
|
@@ -127,11 +123,8 @@ var InternalBarrage = function InternalBarrage(props, ref) {
|
|
|
127
123
|
];
|
|
128
124
|
}
|
|
129
125
|
});
|
|
130
|
-
});
|
|
131
|
-
|
|
132
|
-
return _ref.apply(this, arguments);
|
|
133
|
-
};
|
|
134
|
-
}();
|
|
126
|
+
})();
|
|
127
|
+
};
|
|
135
128
|
domTimer.current = window.setTimeout(function() {
|
|
136
129
|
init();
|
|
137
130
|
}, 300);
|
|
@@ -153,8 +146,8 @@ var InternalBarrage = function InternalBarrage(props, ref) {
|
|
|
153
146
|
play();
|
|
154
147
|
}, intervalCache);
|
|
155
148
|
};
|
|
156
|
-
var setStyle =
|
|
157
|
-
|
|
149
|
+
var setStyle = function setStyle(el, currentIndex) {
|
|
150
|
+
return (0, _async_to_generator._)(function() {
|
|
158
151
|
var refe, width, height, elScrollDuration, error;
|
|
159
152
|
return (0, _ts_generator._)(this, function(_state) {
|
|
160
153
|
switch(_state.label){
|
|
@@ -207,11 +200,8 @@ var InternalBarrage = function InternalBarrage(props, ref) {
|
|
|
207
200
|
];
|
|
208
201
|
}
|
|
209
202
|
});
|
|
210
|
-
});
|
|
211
|
-
|
|
212
|
-
return _ref.apply(this, arguments);
|
|
213
|
-
};
|
|
214
|
-
}();
|
|
203
|
+
})();
|
|
204
|
+
};
|
|
215
205
|
var play = function play() {
|
|
216
206
|
if (!loop && index.current >= list.length) {
|
|
217
207
|
return;
|
|
@@ -1,25 +1,3 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
import { BasicComponent } from "../../utils/typings";
|
|
5
|
-
type OmitMiniProgramButtonProps = Omit<MiniProgramButtonProps, 'size' | 'type' | 'onClick' | 'style'>;
|
|
6
|
-
export type ButtonType = 'default' | 'primary' | 'info' | 'success' | 'warning' | 'danger';
|
|
7
|
-
export type ButtonSize = 'xlarge' | 'large' | 'normal' | 'small' | 'mini';
|
|
8
|
-
export type ButtonShape = 'square' | 'round';
|
|
9
|
-
export type ButtonFill = 'solid' | 'outline' | 'dashed' | 'none';
|
|
10
|
-
export interface ButtonProps extends BasicComponent, OmitMiniProgramButtonProps {
|
|
11
|
-
color: string;
|
|
12
|
-
shape: ButtonShape;
|
|
13
|
-
type: ButtonType;
|
|
14
|
-
size: ButtonSize;
|
|
15
|
-
fill: ButtonFill;
|
|
16
|
-
block: boolean;
|
|
17
|
-
loading: boolean;
|
|
18
|
-
disabled: boolean;
|
|
19
|
-
icon: React.ReactNode;
|
|
20
|
-
rightIcon: React.ReactNode;
|
|
21
|
-
nativeType: 'submit' | 'reset';
|
|
22
|
-
onClick: (e: MouseEvent<HTMLButtonElement>) => void;
|
|
23
|
-
}
|
|
24
|
-
export declare const Button: React.ForwardRefExoticComponent<Omit<Partial<ButtonProps>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
25
|
-
export {};
|
|
2
|
+
import { TaroButtonProps } from "../../types";
|
|
3
|
+
export declare const Button: React.ForwardRefExoticComponent<Omit<Partial<TaroButtonProps>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
@@ -18,7 +18,6 @@ var _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
|
|
18
18
|
var _classnames = /*#__PURE__*/ _interop_require_default._(require("classnames"));
|
|
19
19
|
var _components = require("@tarojs/components");
|
|
20
20
|
var _iconsreacttaro = require("@nutui/icons-react-taro");
|
|
21
|
-
var _taro = require("@tarojs/taro");
|
|
22
21
|
var _typings = require("../../utils/typings");
|
|
23
22
|
var _platform = require("../../utils/taro/platform");
|
|
24
23
|
var prefixCls = 'nut-button';
|
|
@@ -36,7 +35,7 @@ var defaultProps = (0, _object_spread_props._)((0, _object_spread._)({}, _typing
|
|
|
36
35
|
onClick: function onClick(e) {}
|
|
37
36
|
});
|
|
38
37
|
var Button = /*#__PURE__*/ _react.default.forwardRef(function(props, ref) {
|
|
39
|
-
var _ref = (0, _object_spread._)({}, defaultProps, props), color = _ref.color, shape = _ref.shape, fill = _ref.fill, loading = _ref.loading, disabled = _ref.disabled, type = _ref.type, size = _ref.size, block = _ref.block, icon = _ref.icon, rightIcon = _ref.rightIcon, children = _ref.children, className = _ref.className, style = _ref.style,
|
|
38
|
+
var _ref = (0, _object_spread._)({}, defaultProps, props), color = _ref.color, shape = _ref.shape, fill = _ref.fill, loading = _ref.loading, disabled = _ref.disabled, type = _ref.type, size = _ref.size, block = _ref.block, icon = _ref.icon, rightIcon = _ref.rightIcon, children = _ref.children, className = _ref.className, style = _ref.style, nativeType = _ref.nativeType, onClick = _ref.onClick, rest = (0, _object_without_properties._)(_ref, [
|
|
40
39
|
"color",
|
|
41
40
|
"shape",
|
|
42
41
|
"fill",
|
|
@@ -50,7 +49,6 @@ var Button = /*#__PURE__*/ _react.default.forwardRef(function(props, ref) {
|
|
|
50
49
|
"children",
|
|
51
50
|
"className",
|
|
52
51
|
"style",
|
|
53
|
-
"formType",
|
|
54
52
|
"nativeType",
|
|
55
53
|
"onClick"
|
|
56
54
|
]);
|
|
@@ -104,16 +102,14 @@ var Button = /*#__PURE__*/ _react.default.forwardRef(function(props, ref) {
|
|
|
104
102
|
]);
|
|
105
103
|
var _obj;
|
|
106
104
|
var buttonClassNames = (0, _classnames.default)(prefixCls, "".concat(prefixCls, "-").concat(type), (_obj = {}, (0, _define_property._)(_obj, "".concat(prefixCls, "-").concat(type, "-solid"), type === 'primary' && !props.fill), (0, _define_property._)(_obj, "".concat(prefixCls, "-").concat(fill), props.fill), (0, _define_property._)(_obj, "".concat(prefixCls, "-").concat(type, "-").concat(fill), props.fill), (0, _define_property._)(_obj, "".concat(prefixCls, "-").concat(size), size), (0, _define_property._)(_obj, "".concat(prefixCls, "-").concat(shape), shape), (0, _define_property._)(_obj, "".concat(prefixCls, "-").concat(shape, "-").concat(size), shape && size), (0, _define_property._)(_obj, "".concat(prefixCls, "-block"), block), (0, _define_property._)(_obj, "".concat(prefixCls, "-disabled"), disabled || loading), (0, _define_property._)(_obj, "".concat(prefixCls, "-").concat(type).concat(props.fill ? "-".concat(fill) : '', "-disabled"), disabled || loading), (0, _define_property._)(_obj, "".concat(prefixCls, "-loading"), loading), (0, _define_property._)(_obj, "".concat(prefixCls, "-icononly"), !children), _obj), className);
|
|
107
|
-
if (
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
// eslint-disable-next-line react/button-has-type
|
|
114
|
-
/*#__PURE__*/ /*#__PURE__*/ _react.default.createElement(_components.Button, (0, _object_spread_props._)((0, _object_spread._)({}, rest), {
|
|
105
|
+
// if (getEnv() === 'WEB') {
|
|
106
|
+
// ;(rest as any).type = formType
|
|
107
|
+
// }
|
|
108
|
+
return(// @ts-ignore
|
|
109
|
+
// <TaroButton
|
|
110
|
+
/*#__PURE__*/ /*#__PURE__*/ _react.default.createElement(_components.View, (0, _object_spread_props._)((0, _object_spread._)({}, rest), {
|
|
115
111
|
ref: ref,
|
|
116
|
-
|
|
112
|
+
// formType={formType || nativeType}
|
|
117
113
|
className: buttonClassNames,
|
|
118
114
|
style: (0, _object_spread._)({}, getStyle, style),
|
|
119
115
|
onClick: function onClick(e) {
|
|
@@ -122,6 +118,7 @@ var Button = /*#__PURE__*/ _react.default.forwardRef(function(props, ref) {
|
|
|
122
118
|
}), /*#__PURE__*/ _react.default.createElement(_components.View, {
|
|
123
119
|
className: "nut-button-wrap"
|
|
124
120
|
}, loading && /*#__PURE__*/ _react.default.createElement(_iconsreacttaro.Loading, {
|
|
121
|
+
ariaHidden: true,
|
|
125
122
|
className: "nut-icon-loading"
|
|
126
123
|
}), !loading && icon, children && /*#__PURE__*/ _react.default.createElement(_components.View, {
|
|
127
124
|
className: "nut-button-children nut-button-".concat(size, "-children nut-button-").concat(type, "-children ").concat(!(props.fill || disabled || loading) ? '' : "nut-button-".concat(type).concat(props.fill ? "-".concat(fill) : '').concat(disabled || loading ? '-disabled' : '')).concat(icon || loading ? " nut-button-text" : '').concat(rightIcon ? ' nut-button-text-right' : ''),
|