@nutui/nutui-react-taro 3.0.20 → 3.0.22-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 +38 -68
- package/dist/cjs/hooks/use-props-value.js +1 -1
- package/dist/cjs/hooks/use-touch.js +4 -4
- 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/cascaderRender.js +1 -1
- package/dist/cjs/packages/address/existRender.js +1 -1
- package/dist/cjs/packages/address/style/style.harmony.css +38 -17
- package/dist/cjs/packages/animatingnumbers/countup.js +3 -1
- package/dist/cjs/packages/audio/audio.js +1 -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 +3 -7
- package/dist/cjs/packages/badge/badge.js +16 -3
- package/dist/cjs/packages/barrage/barrage.js +2 -1
- 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/calendarcard/calendarcard.js +30 -8
- package/dist/cjs/packages/calendarcard/icon.js +12 -23
- 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/card/card.js +1 -1
- package/dist/cjs/packages/card/style/style.harmony.css +1 -1
- package/dist/cjs/packages/cascader/style/style.harmony.css +38 -17
- package/dist/cjs/packages/cascader/utils.js +4 -4
- package/dist/cjs/packages/cellgroup/cellgroup.js +1 -1
- package/dist/cjs/packages/checkboxgroup/checkboxgroup.js +3 -3
- package/dist/cjs/packages/circleprogress/circleprogress.js +1 -1
- package/dist/cjs/packages/collapseitem/collapseitem.js +1 -1
- package/dist/cjs/packages/configprovider/types.d.ts +1 -1
- package/dist/cjs/packages/countdown/countdown.js +1 -1
- package/dist/cjs/packages/datepicker/datepicker.js +1 -1
- package/dist/cjs/packages/datepicker/style/style.harmony.css +39 -18
- package/dist/cjs/packages/dialog/dialog.js +20 -14
- 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 +3 -3
- package/dist/cjs/packages/elevator/elevator.js +1 -1
- package/dist/cjs/packages/ellipsis/ellipsis.js +1 -1
- 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/form.js +1 -1
- package/dist/cjs/packages/form/style/style.harmony.css +0 -5
- 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/grid/grid.js +1 -1
- package/dist/cjs/packages/griditem/griditem.js +1 -1
- package/dist/cjs/packages/image/image.js +12 -4
- package/dist/cjs/packages/imagepreview/imagepreview.js +3 -2
- package/dist/cjs/packages/imagepreview/style/style.harmony.css +38 -17
- package/dist/cjs/packages/indicator/indicator.js +1 -1
- package/dist/cjs/packages/infiniteloading/infiniteloading.js +3 -3
- package/dist/cjs/packages/input/input.js +11 -4
- package/dist/cjs/packages/inputnumber/inputnumber.js +2 -2
- package/dist/cjs/packages/loading/loading.js +1 -1
- package/dist/cjs/packages/lottie/lottiemp.js +10 -18
- package/dist/cjs/packages/menu/menu.js +1 -1
- 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 +18 -14
- package/dist/cjs/packages/nutui.react.d.ts +4 -1
- package/dist/cjs/packages/nutui.react.js +19 -14
- 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 +4 -4
- package/dist/cjs/packages/pagination/pagination.js +1 -1
- package/dist/cjs/packages/picker/picker.js +1 -1
- 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 +1 -1
- package/dist/cjs/packages/popover/popover.js +2 -2
- package/dist/cjs/packages/popover/style/style.harmony.css +38 -17
- package/dist/cjs/packages/popup/popup.js +188 -103
- 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 +7 -12
- 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/radio.js +1 -1
- package/dist/cjs/packages/radiogroup/radiogroup.js +3 -3
- package/dist/cjs/packages/range/range.js +35 -10
- 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 +1 -1
- package/dist/cjs/packages/shortpassword/style/style.harmony.css +38 -17
- package/dist/cjs/packages/sidebar/sidebar.js +1 -1
- package/dist/cjs/packages/signature/signature.js +2 -2
- package/dist/cjs/packages/skeleton/skeleton.js +1 -1
- 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 +3 -3
- package/dist/cjs/packages/swipe/swipe.js +84 -115
- package/dist/cjs/packages/swiper/swiper.js +1 -1
- package/dist/cjs/packages/switch/switch.js +1 -1
- package/dist/cjs/packages/tabbaritem/tabbaritem.js +1 -1
- 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/table/table.js +1 -1
- package/dist/cjs/packages/tabs/tabs.js +13 -6
- 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/textarea/textarea.js +1 -1
- package/dist/cjs/packages/timeselect/style/style.harmony.css +38 -17
- package/dist/cjs/packages/timeselect/timeselect.js +1 -1
- 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 +3 -3
- package/dist/cjs/packages/tour/style/style.harmony.css +38 -17
- package/dist/cjs/packages/trendarrow/trendarrow.js +1 -1
- package/dist/cjs/packages/uploader/uploader.js +1 -1
- package/dist/cjs/packages/video/video.js +2 -2
- package/dist/cjs/packages/virtuallist/utils.js +1 -1
- package/dist/cjs/packages/virtuallist/virtuallist.js +1 -1
- package/dist/cjs/types/index.d.ts +3 -0
- package/dist/cjs/types/index.js +3 -0
- 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/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 copy.js → ConfigurableCSSTransition.js} +13 -53
- package/dist/cjs/utils/taro/get-rect.js +4 -2
- package/dist/cjs/utils/taro/get-system-info.d.ts +0 -5
- package/dist/cjs/utils/taro/get-system-info.js +2 -7
- package/dist/es/hooks/taro/use-custom-event.js +4 -3
- package/dist/es/hooks/taro/use-lock-scoll.js +1 -1
- package/dist/es/hooks/use-click-away.js +2 -2
- package/dist/es/hooks/use-lock-scroll.js +3 -3
- package/dist/es/hooks/use-pagination.js +1 -1
- package/dist/es/hooks/use-ref-state.js +3 -3
- package/dist/es/hooks/use-touch.js +13 -13
- package/dist/es/hooks/use-watch.js +1 -1
- package/dist/es/locales/base.d.ts +9 -0
- package/dist/es/locales/en-US.js +24 -5
- package/dist/es/locales/id-ID.js +24 -5
- package/dist/es/locales/ja-JP.js +22 -5
- package/dist/es/locales/tr-TR.js +24 -5
- package/dist/es/locales/zh-CN.js +22 -5
- package/dist/es/locales/zh-TW.js +22 -5
- package/dist/es/locales/zh-UG.js +24 -5
- package/dist/es/packages/actionsheet/actionsheet.js +8 -8
- 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/address.js +10 -10
- package/dist/es/packages/address/cascaderRender.js +4 -4
- package/dist/es/packages/address/elevatorRender.js +17 -17
- package/dist/es/packages/address/existRender.js +5 -5
- package/dist/es/packages/address/style/style.harmony.css +38 -17
- package/dist/es/packages/address/utils.js +5 -5
- package/dist/es/packages/animate/animate.js +3 -3
- package/dist/es/packages/animatingnumbers/countup.js +4 -2
- package/dist/es/packages/audio/audio.js +16 -16
- package/dist/es/packages/audio/style/style.harmony.css +0 -3
- package/dist/es/packages/avatar/avatar.js +35 -9
- package/dist/es/packages/avatarcropper/avatarcropper.js +29 -33
- package/dist/es/packages/avatargroup/avatargroup.js +1 -1
- package/dist/es/packages/backtop/backtop.js +3 -3
- package/dist/es/packages/badge/badge.js +18 -5
- package/dist/es/packages/barrage/barrage.js +10 -9
- package/dist/es/packages/button/button.d.ts +2 -24
- package/dist/es/packages/button/button.js +12 -14
- 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/calendar.js +12 -12
- 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/calendar/utils.js +7 -7
- package/dist/es/packages/calendarcard/calendarcard.js +53 -31
- package/dist/es/packages/calendarcard/icon.js +18 -29
- 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/calendarcard/utils.js +5 -5
- package/dist/es/packages/calendaritem/calendaritem.js +32 -32
- package/dist/es/packages/card/card.js +2 -2
- package/dist/es/packages/card/style/style.harmony.css +1 -1
- package/dist/es/packages/cascader/cascader.js +15 -15
- package/dist/es/packages/cascader/style/style.harmony.css +38 -17
- package/dist/es/packages/cascader/utils.js +6 -6
- package/dist/es/packages/cell/cell.js +4 -4
- package/dist/es/packages/cellgroup/cellgroup.js +2 -2
- package/dist/es/packages/checkbox/checkbox.js +10 -10
- package/dist/es/packages/checkboxgroup/checkboxgroup.js +7 -7
- package/dist/es/packages/circleprogress/circleprogress.js +7 -7
- package/dist/es/packages/col/col.js +2 -2
- package/dist/es/packages/collapse/collapse.js +3 -3
- package/dist/es/packages/collapse/context.js +2 -2
- package/dist/es/packages/collapseitem/collapseitem.js +5 -5
- package/dist/es/packages/configprovider/configprovider.js +5 -5
- package/dist/es/packages/configprovider/types.d.ts +1 -1
- package/dist/es/packages/countdown/countdown.js +15 -15
- package/dist/es/packages/datepicker/datepicker.js +12 -12
- package/dist/es/packages/datepicker/style/style.harmony.css +39 -18
- package/dist/es/packages/datepicker/utils.js +7 -7
- package/dist/es/packages/datepickerview/datepickerview.js +5 -5
- package/dist/es/packages/dialog/content.js +6 -6
- package/dist/es/packages/dialog/dialog.js +53 -45
- 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 +4 -4
- package/dist/es/packages/drag/drag.js +5 -5
- package/dist/es/packages/elevator/elevator.js +17 -17
- package/dist/es/packages/ellipsis/ellipsis.js +14 -14
- package/dist/es/packages/empty/empty.d.ts +4 -4
- package/dist/es/packages/empty/empty.js +1 -1
- package/dist/es/packages/empty/style/style.harmony.css +0 -3
- package/dist/es/packages/fixednav/fixednav.js +7 -7
- package/dist/es/packages/form/form.js +7 -7
- package/dist/es/packages/form/style/style.harmony.css +0 -5
- package/dist/es/packages/form/useform.js +4 -4
- package/dist/es/packages/formitem/formitem.js +1 -1
- 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/grid/context.js +1 -1
- package/dist/es/packages/grid/grid.js +4 -4
- package/dist/es/packages/griditem/griditem.js +6 -6
- package/dist/es/packages/hoverbutton/hoverbutton.js +1 -1
- package/dist/es/packages/hoverbuttonitem/hoverbuttonitem.js +6 -6
- package/dist/es/packages/hoverbuttonitem/utils.js +1 -1
- package/dist/es/packages/image/image.js +18 -10
- package/dist/es/packages/imagepreview/imagepreview.js +16 -15
- package/dist/es/packages/imagepreview/style/style.harmony.css +38 -17
- package/dist/es/packages/indicator/indicator.js +5 -5
- package/dist/es/packages/infiniteloading/infiniteloading.js +14 -14
- package/dist/es/packages/input/input.js +23 -16
- package/dist/es/packages/inputnumber/inputnumber.js +13 -13
- package/dist/es/packages/layout/layout.js +1 -1
- package/dist/es/packages/loading/loading.js +3 -3
- package/dist/es/packages/lottie/index.js +1 -1
- package/dist/es/packages/lottie/lottiemp.js +12 -20
- package/dist/es/packages/menu/menu.js +13 -13
- package/dist/es/packages/menuitem/menuitem.js +12 -12
- package/dist/es/packages/navbar/navbar.js +7 -7
- package/dist/es/packages/noticebar/noticebar.js +22 -22
- package/dist/es/packages/notify/notify.js +8 -8
- package/dist/es/packages/numberkeyboard/numberkeyboard.js +12 -12
- 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 +10 -10
- package/dist/es/packages/pagination/pagination.js +8 -8
- package/dist/es/packages/picker/picker.js +15 -15
- 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 +12 -12
- package/dist/es/packages/pickerview/pickerview.js +3 -3
- package/dist/es/packages/pickerview/utils.js +6 -6
- package/dist/es/packages/popover/popover.js +16 -16
- package/dist/es/packages/popover/style/style.harmony.css +38 -17
- package/dist/es/packages/popup/popup.js +200 -115
- 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 +60 -21
- package/dist/es/packages/progress/progress.js +17 -22
- package/dist/es/packages/pulltorefresh/pulltorefresh.js +8 -8
- 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/radio.js +11 -11
- package/dist/es/packages/radiogroup/radiogroup.js +6 -6
- package/dist/es/packages/range/range.js +44 -19
- package/dist/es/packages/rate/rate.js +16 -19
- package/dist/es/packages/resultpage/resultpage.js +3 -2
- package/dist/es/packages/resultpage/style/style.harmony.css +0 -3
- package/dist/es/packages/row/row.js +4 -4
- package/dist/es/packages/safearea/safearea.js +4 -13
- 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 +27 -13
- package/dist/es/packages/segmented/segmented.js +4 -4
- package/dist/es/packages/shortpassword/shortpassword.js +7 -7
- package/dist/es/packages/shortpassword/style/style.harmony.css +38 -17
- package/dist/es/packages/sidebar/sidebar.js +11 -11
- package/dist/es/packages/sidebar/utils.js +1 -1
- package/dist/es/packages/sidebaritem/sidebaritem.js +1 -1
- package/dist/es/packages/signature/signature.js +15 -15
- package/dist/es/packages/skeleton/skeleton.js +4 -4
- package/dist/es/packages/space/space.js +1 -1
- package/dist/es/packages/step/step.js +4 -9
- 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/steps.js +1 -1
- 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 +5 -5
- package/dist/es/packages/swipe/swipe.js +98 -129
- package/dist/es/packages/swiper/swiper.js +7 -7
- package/dist/es/packages/swiperitem/swiperitem.js +1 -1
- package/dist/es/packages/switch/switch.js +6 -6
- package/dist/es/packages/tabbar/tabbar.js +2 -2
- package/dist/es/packages/tabbaritem/tabbaritem.js +10 -10
- 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/table/table.js +10 -10
- package/dist/es/packages/tabpane/tabpane.js +1 -1
- package/dist/es/packages/tabs/tabs.js +23 -16
- 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/tag/tag.js +10 -10
- package/dist/es/packages/textarea/textarea.js +11 -11
- package/dist/es/packages/timedetail/timedetail.js +3 -3
- package/dist/es/packages/timeselect/style/style.harmony.css +38 -17
- package/dist/es/packages/timeselect/timeselect.js +6 -6
- 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 +11 -11
- package/dist/es/packages/tour/style/style.harmony.css +38 -17
- package/dist/es/packages/tour/tour.js +10 -10
- package/dist/es/packages/trendarrow/trendarrow.js +4 -4
- package/dist/es/packages/uploader/preview.js +8 -8
- package/dist/es/packages/uploader/uploader.js +19 -19
- package/dist/es/packages/video/video.js +3 -3
- package/dist/es/packages/virtuallist/utils.js +5 -5
- package/dist/es/packages/virtuallist/virtuallist.js +8 -8
- package/dist/es/packages/watermark/watermark.js +2 -2
- package/dist/es/types/index.d.ts +3 -0
- package/dist/es/types/index.js +3 -0
- 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/clamp.js +1 -1
- package/dist/es/utils/date.js +3 -3
- package/dist/es/utils/get-rect.js +1 -1
- package/dist/es/utils/interceptor.js +1 -1
- package/dist/es/utils/is-date.js +1 -1
- package/dist/es/utils/is-empty.js +1 -1
- package/dist/es/utils/is-function.js +1 -1
- package/dist/es/utils/is-object.js +1 -1
- package/dist/es/utils/is-promise.js +1 -1
- package/dist/es/utils/pad-zero.js +1 -1
- package/dist/es/utils/px-check.js +1 -1
- 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/sleep.js +1 -1
- package/dist/es/utils/taro/{ConfigurableCSSTransition copy.js → ConfigurableCSSTransition.js} +14 -54
- package/dist/es/utils/taro/get-rect-by-id.js +1 -1
- package/dist/es/utils/taro/get-rect.js +6 -4
- package/dist/es/utils/taro/get-system-info.d.ts +0 -5
- package/dist/es/utils/taro/get-system-info.js +10 -9
- package/dist/es/utils/taro/platform.js +4 -4
- package/dist/es/utils/upper-case-first.js +1 -1
- package/dist/nutui.react.umd.js +11331 -10903
- package/dist/style-jmapp.css +1 -1
- package/dist/style-jmapp.scss +36 -35
- package/dist/style-jrkf.css +1 -1
- package/dist/style-jrkf.scss +32 -31
- package/dist/style.css +1 -1
- package/dist/style.scss +33 -32
- 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/dist/cjs/utils/taro/{ConfigurableCSSTransition copy.d.ts → ConfigurableCSSTransition.d.ts} +0 -0
- /package/dist/es/utils/taro/{ConfigurableCSSTransition copy.d.ts → ConfigurableCSSTransition.d.ts} +0 -0
|
@@ -28,17 +28,17 @@ var defaultProps = _object_spread_props(_object_spread({}, ComponentDefaults), {
|
|
|
28
28
|
showSubTitle: true,
|
|
29
29
|
scrollAnimation: true,
|
|
30
30
|
firstDayOfWeek: 0,
|
|
31
|
-
disableDate: function(date) {
|
|
31
|
+
disableDate: function disableDate(date) {
|
|
32
32
|
return false;
|
|
33
33
|
},
|
|
34
34
|
renderHeaderButtons: undefined,
|
|
35
35
|
renderDay: undefined,
|
|
36
36
|
renderDayTop: undefined,
|
|
37
37
|
renderDayBottom: undefined,
|
|
38
|
-
onConfirm: function() {},
|
|
39
|
-
onUpdate: function() {},
|
|
40
|
-
onDayClick: function() {},
|
|
41
|
-
onPageChange: function() {}
|
|
38
|
+
onConfirm: function onConfirm() {},
|
|
39
|
+
onUpdate: function onUpdate() {},
|
|
40
|
+
onDayClick: function onDayClick() {},
|
|
41
|
+
onPageChange: function onPageChange() {}
|
|
42
42
|
});
|
|
43
43
|
export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
44
44
|
var locale = useConfig().locale;
|
|
@@ -61,13 +61,13 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
61
61
|
var _useState7 = _sliced_to_array(useState({
|
|
62
62
|
currDateArray: []
|
|
63
63
|
}), 1), state = _useState7[0];
|
|
64
|
-
var getMonthsPanel = function() {
|
|
64
|
+
var getMonthsPanel = function getMonthsPanel() {
|
|
65
65
|
return monthsPanel.current;
|
|
66
66
|
};
|
|
67
|
-
var getMonthsRef = function() {
|
|
67
|
+
var getMonthsRef = function getMonthsRef() {
|
|
68
68
|
return monthsRef.current;
|
|
69
69
|
};
|
|
70
|
-
var resetDefaultValue = function() {
|
|
70
|
+
var resetDefaultValue = function resetDefaultValue() {
|
|
71
71
|
if (defaultValue || Array.isArray(defaultValue) && defaultValue.length > 0) {
|
|
72
72
|
return type !== 'single' ? _to_consumable_array(defaultValue) : defaultValue;
|
|
73
73
|
}
|
|
@@ -77,7 +77,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
77
77
|
value: value,
|
|
78
78
|
defaultValue: resetDefaultValue(),
|
|
79
79
|
finalValue: [],
|
|
80
|
-
onChange: function(val) {}
|
|
80
|
+
onChange: function onChange(val) {}
|
|
81
81
|
}), 2), currentDate = _usePropsValue[0], setCurrentDate = _usePropsValue[1];
|
|
82
82
|
var weeksPanel = useRef(null);
|
|
83
83
|
var monthsRef = useRef(null);
|
|
@@ -88,7 +88,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
88
88
|
var classPrefix = 'nut-calendar';
|
|
89
89
|
var dayPrefix = 'nut-calendar-day';
|
|
90
90
|
// 获取月数据
|
|
91
|
-
var getMonthData = function(curData, monthNum, type) {
|
|
91
|
+
var getMonthData = function getMonthData(curData, monthNum, type) {
|
|
92
92
|
var i = 0;
|
|
93
93
|
var date = curData;
|
|
94
94
|
var monthData = monthsData;
|
|
@@ -120,7 +120,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
120
120
|
}while (i++ < monthNum);
|
|
121
121
|
setMonthsData(monthData);
|
|
122
122
|
};
|
|
123
|
-
var setReachedYearMonthInfo = function(current) {
|
|
123
|
+
var setReachedYearMonthInfo = function setReachedYearMonthInfo(current) {
|
|
124
124
|
var currentMonthsData = monthsData[current];
|
|
125
125
|
var _currentMonthsData_curData = _sliced_to_array(currentMonthsData.curData, 2), year = _currentMonthsData_curData[0], month = _currentMonthsData_curData[1];
|
|
126
126
|
if (currentMonthsData.title === yearMonthTitle) return;
|
|
@@ -132,7 +132,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
132
132
|
setYearMonthTitle(currentMonthsData.title);
|
|
133
133
|
};
|
|
134
134
|
// 设置默认的范围
|
|
135
|
-
var setDefaultRange = function(monthNum, current) {
|
|
135
|
+
var setDefaultRange = function setDefaultRange(monthNum, current) {
|
|
136
136
|
var start = 0;
|
|
137
137
|
var end = 0;
|
|
138
138
|
if (monthNum >= 3) {
|
|
@@ -157,7 +157,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
157
157
|
setTranslateY(monthsData[start].scrollTop);
|
|
158
158
|
setReachedYearMonthInfo(current);
|
|
159
159
|
};
|
|
160
|
-
var getMonthNum = function() {
|
|
160
|
+
var getMonthNum = function getMonthNum() {
|
|
161
161
|
var monthNum = Number(endDates[1]) - Number(startDates[1]);
|
|
162
162
|
var yearNum = Number(endDates[0]) - Number(startDates[0]);
|
|
163
163
|
if (yearNum > 0) {
|
|
@@ -169,7 +169,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
169
169
|
setMonthsNum(monthNum);
|
|
170
170
|
return monthNum;
|
|
171
171
|
};
|
|
172
|
-
var setDefaultDate = function() {
|
|
172
|
+
var setDefaultDate = function setDefaultDate() {
|
|
173
173
|
var defaultData = [];
|
|
174
174
|
// 日期转化为数组,限制初始日期。判断时间范围
|
|
175
175
|
if (type === 'range' && Array.isArray(currentDate)) {
|
|
@@ -227,7 +227,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
227
227
|
}
|
|
228
228
|
return defaultData;
|
|
229
229
|
};
|
|
230
|
-
var getCurrentIndex = function(defaultData) {
|
|
230
|
+
var getCurrentIndex = function getCurrentIndex(defaultData) {
|
|
231
231
|
// 设置默认可见区域
|
|
232
232
|
var current = 0;
|
|
233
233
|
var lastCurrent = 0;
|
|
@@ -259,7 +259,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
259
259
|
lastCurrent: lastCurrent
|
|
260
260
|
};
|
|
261
261
|
};
|
|
262
|
-
var renderCurrentDate = function() {
|
|
262
|
+
var renderCurrentDate = function renderCurrentDate() {
|
|
263
263
|
var defaultData = setDefaultDate();
|
|
264
264
|
var current = getCurrentIndex(defaultData);
|
|
265
265
|
if (defaultData.length > 0) {
|
|
@@ -302,7 +302,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
302
302
|
}
|
|
303
303
|
return current.current;
|
|
304
304
|
};
|
|
305
|
-
var requestAniFrameFunc = function(current, monthNum) {
|
|
305
|
+
var requestAniFrameFunc = function requestAniFrameFunc(current, monthNum) {
|
|
306
306
|
var lastItem = monthsData[monthsData.length - 1];
|
|
307
307
|
var containerHeight = lastItem.cssHeight + lastItem.scrollTop;
|
|
308
308
|
requestAniFrame(function() {
|
|
@@ -319,7 +319,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
319
319
|
});
|
|
320
320
|
setAvgHeight(Math.floor(containerHeight / (monthNum + 1)));
|
|
321
321
|
};
|
|
322
|
-
var initData = function() {
|
|
322
|
+
var initData = function initData() {
|
|
323
323
|
// 判断时间范围内存在多少个月
|
|
324
324
|
var monthNum = getMonthNum();
|
|
325
325
|
// 设置月份数据,获取包含月份的所有数据,只需要 set 一次即可。
|
|
@@ -331,7 +331,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
331
331
|
useEffect(function() {
|
|
332
332
|
initData();
|
|
333
333
|
}, []);
|
|
334
|
-
var resetRender = function() {
|
|
334
|
+
var resetRender = function resetRender() {
|
|
335
335
|
state.currDateArray.splice(0);
|
|
336
336
|
monthsData.splice(0);
|
|
337
337
|
initData();
|
|
@@ -347,7 +347,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
347
347
|
currentDate
|
|
348
348
|
]);
|
|
349
349
|
// 暴露出的API
|
|
350
|
-
var scrollToDate = function(date) {
|
|
350
|
+
var scrollToDate = function scrollToDate(date) {
|
|
351
351
|
if (Utils.compareDate(date, propStartDate)) {
|
|
352
352
|
date = propStartDate;
|
|
353
353
|
} else if (!Utils.compareDate(date, propEndDate)) {
|
|
@@ -383,7 +383,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
383
383
|
}
|
|
384
384
|
});
|
|
385
385
|
};
|
|
386
|
-
var monthsViewScroll = function(e) {
|
|
386
|
+
var monthsViewScroll = function monthsViewScroll(e) {
|
|
387
387
|
if (monthsData.length <= 1) {
|
|
388
388
|
return;
|
|
389
389
|
}
|
|
@@ -421,7 +421,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
421
421
|
scrollToDate: scrollToDate
|
|
422
422
|
};
|
|
423
423
|
});
|
|
424
|
-
var getClasses = function(day, month) {
|
|
424
|
+
var getClasses = function getClasses(day, month) {
|
|
425
425
|
var dateStr = getCurrDate(day, month);
|
|
426
426
|
if (day.type === 'active') {
|
|
427
427
|
if (propStartDate && Utils.compareDate(dateStr, propStartDate) || propEndDate && Utils.compareDate(propEndDate, dateStr)) {
|
|
@@ -447,7 +447,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
447
447
|
}
|
|
448
448
|
return "".concat(dayPrefix, "-disabled");
|
|
449
449
|
};
|
|
450
|
-
var chooseDay = function(day, month, isFirst) {
|
|
450
|
+
var chooseDay = function chooseDay(day, month, isFirst) {
|
|
451
451
|
if (getClasses(day, month) === "".concat(dayPrefix, "-disabled")) {
|
|
452
452
|
return;
|
|
453
453
|
}
|
|
@@ -526,8 +526,8 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
526
526
|
}
|
|
527
527
|
setMonthsData(monthsData.slice());
|
|
528
528
|
};
|
|
529
|
-
var resetSelectedValue = function() {
|
|
530
|
-
var itemData = function(dateArr) {
|
|
529
|
+
var resetSelectedValue = function resetSelectedValue() {
|
|
530
|
+
var itemData = function itemData(dateArr) {
|
|
531
531
|
days = dateArr.split('/');
|
|
532
532
|
days[3] = "".concat(days[0], "/").concat(days[1], "/").concat(days[2]);
|
|
533
533
|
days[4] = Utils.getWhatDay(+days[0], +days[1], +days[2]);
|
|
@@ -543,7 +543,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
543
543
|
}
|
|
544
544
|
return days;
|
|
545
545
|
};
|
|
546
|
-
var confirm = function() {
|
|
546
|
+
var confirm = function confirm() {
|
|
547
547
|
if (type === 'range' && state.currDateArray.length === 2 || type !== 'range') {
|
|
548
548
|
var chooseData = state.currDateArray.slice(0);
|
|
549
549
|
onConfirm && onConfirm(chooseData);
|
|
@@ -557,14 +557,14 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
557
557
|
var _obj1;
|
|
558
558
|
var headerClasses = classNames((_obj1 = {}, _define_property(_obj1, "".concat(classPrefix, "-header"), true), _define_property(_obj1, "".concat(classPrefix, "-header-title"), !popup), _obj1));
|
|
559
559
|
// 是否有开始提示
|
|
560
|
-
var isStartTip = function(day, month) {
|
|
560
|
+
var isStartTip = function isStartTip(day, month) {
|
|
561
561
|
return (type === 'range' || type === 'week') && day.type === 'active' && isStart(getCurrDate(day, month), currentDate);
|
|
562
562
|
};
|
|
563
563
|
// 是否有结束提示
|
|
564
|
-
var isEndTip = function(day, month) {
|
|
564
|
+
var isEndTip = function isEndTip(day, month) {
|
|
565
565
|
return currentDate.length >= 2 && (type === 'range' || type === 'week') && day.type === 'active' && isEnd(getCurrDate(day, month), currentDate);
|
|
566
566
|
};
|
|
567
|
-
var renderHeader = function() {
|
|
567
|
+
var renderHeader = function renderHeader() {
|
|
568
568
|
return /*#__PURE__*/ React.createElement(View, {
|
|
569
569
|
className: headerClasses
|
|
570
570
|
}, showTitle && /*#__PURE__*/ React.createElement(View, {
|
|
@@ -583,7 +583,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
583
583
|
}, item);
|
|
584
584
|
})));
|
|
585
585
|
};
|
|
586
|
-
var renderContent = function() {
|
|
586
|
+
var renderContent = function renderContent() {
|
|
587
587
|
return /*#__PURE__*/ React.createElement(ScrollView, {
|
|
588
588
|
scrollTop: scrollTop,
|
|
589
589
|
scrollY: true,
|
|
@@ -615,7 +615,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
615
615
|
"".concat(classPrefix, "-day"),
|
|
616
616
|
getClasses(day, month)
|
|
617
617
|
].join(' '),
|
|
618
|
-
onClick: function() {
|
|
618
|
+
onClick: function onClick() {
|
|
619
619
|
chooseDay(day, month);
|
|
620
620
|
},
|
|
621
621
|
key: i
|
|
@@ -635,7 +635,7 @@ export var CalendarItem = /*#__PURE__*/ React.forwardRef(function(props, ref) {
|
|
|
635
635
|
})));
|
|
636
636
|
}))));
|
|
637
637
|
};
|
|
638
|
-
var renderFooter = function() {
|
|
638
|
+
var renderFooter = function renderFooter() {
|
|
639
639
|
return /*#__PURE__*/ React.createElement(View, {
|
|
640
640
|
className: "nut-calendar-footer"
|
|
641
641
|
}, children, /*#__PURE__*/ React.createElement(View, {
|
|
@@ -21,8 +21,8 @@ var defaultProps = _object_spread_props(_object_spread({}, ComponentDefaults), {
|
|
|
21
21
|
priceTag: '',
|
|
22
22
|
extra: ''
|
|
23
23
|
});
|
|
24
|
-
export var Card = function(props) {
|
|
25
|
-
var
|
|
24
|
+
export var Card = function Card(props) {
|
|
25
|
+
var _$_object_spread = _object_spread({}, defaultProps, props), className = _$_object_spread.className, style = _$_object_spread.style, src = _$_object_spread.src, title = _$_object_spread.title, price = _$_object_spread.price, vipPrice = _$_object_spread.vipPrice, shopDescription = _$_object_spread.shopDescription, delivery = _$_object_spread.delivery, shopName = _$_object_spread.shopName, tag = _$_object_spread.tag, priceTag = _$_object_spread.priceTag, description = _$_object_spread.description, extra = _$_object_spread.extra, rest = _object_without_properties(_$_object_spread, [
|
|
26
26
|
"className",
|
|
27
27
|
"style",
|
|
28
28
|
"src",
|
|
@@ -106,7 +106,7 @@
|
|
|
106
106
|
background: var(--nutui-tag-background-color, var(--nutui-color-title, #1a1a1a));
|
|
107
107
|
}
|
|
108
108
|
.nut-tag-primary {
|
|
109
|
-
background:
|
|
109
|
+
background: #fa2c19;
|
|
110
110
|
}
|
|
111
111
|
.nut-tag-info {
|
|
112
112
|
background: var(--nutui-tag-info-background-color, var(--nutui-color-info, #0073ff));
|
|
@@ -28,9 +28,9 @@ var defaultProps = _object_spread_props(_object_spread({}, ComponentDefaults), {
|
|
|
28
28
|
closeIconPosition: 'top-right',
|
|
29
29
|
closeIcon: 'close',
|
|
30
30
|
lazy: false,
|
|
31
|
-
onClose: function() {},
|
|
32
|
-
onChange: function() {},
|
|
33
|
-
onPathChange: function() {}
|
|
31
|
+
onClose: function onClose() {},
|
|
32
|
+
onChange: function onChange() {},
|
|
33
|
+
onPathChange: function onPathChange() {}
|
|
34
34
|
});
|
|
35
35
|
export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
36
36
|
var classPrefix = 'nut-cascader';
|
|
@@ -45,7 +45,7 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
45
45
|
value: outerValue,
|
|
46
46
|
defaultValue: outerDefaultValue,
|
|
47
47
|
finalValue: [],
|
|
48
|
-
onChange: function(value) {
|
|
48
|
+
onChange: function onChange(value) {
|
|
49
49
|
var _props_onChange, _props_onPathChange;
|
|
50
50
|
(_props_onChange = props.onChange) === null || _props_onChange === void 0 ? void 0 : _props_onChange.call(props, value, pathNodes.current);
|
|
51
51
|
(_props_onPathChange = props.onPathChange) === null || _props_onPathChange === void 0 ? void 0 : _props_onPathChange.call(props, value, pathNodes.current);
|
|
@@ -124,7 +124,7 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
124
124
|
var _usePropsValue1 = _sliced_to_array(usePropsValue({
|
|
125
125
|
value: outerVisible,
|
|
126
126
|
defaultValue: undefined,
|
|
127
|
-
onChange: function(value) {
|
|
127
|
+
onChange: function onChange(value) {
|
|
128
128
|
if (value === false) {
|
|
129
129
|
var _props_onClose;
|
|
130
130
|
(_props_onClose = props.onClose) === null || _props_onClose === void 0 ? void 0 : _props_onClose.call(props);
|
|
@@ -132,10 +132,10 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
132
132
|
}
|
|
133
133
|
}), 2), visible = _usePropsValue1[0], setVisible = _usePropsValue1[1];
|
|
134
134
|
var actions = {
|
|
135
|
-
open: function() {
|
|
135
|
+
open: function open() {
|
|
136
136
|
setVisible(true);
|
|
137
137
|
},
|
|
138
|
-
close: function() {
|
|
138
|
+
close: function close() {
|
|
139
139
|
setVisible(false);
|
|
140
140
|
}
|
|
141
141
|
};
|
|
@@ -174,7 +174,7 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
174
174
|
outerOptions
|
|
175
175
|
]);
|
|
176
176
|
useEffect(function() {
|
|
177
|
-
var load = function() {
|
|
177
|
+
var load = function load() {
|
|
178
178
|
return _async_to_generator(function() {
|
|
179
179
|
var parent, error;
|
|
180
180
|
return _ts_generator(this, function(_state) {
|
|
@@ -264,7 +264,7 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
264
264
|
}, [
|
|
265
265
|
lazy
|
|
266
266
|
]);
|
|
267
|
-
var chooseItem = function(pane, levelIndex) {
|
|
267
|
+
var chooseItem = function chooseItem(pane, levelIndex) {
|
|
268
268
|
return _async_to_generator(function() {
|
|
269
269
|
var nextValue, nextPathNodes, _props_onPathChange, asyncOptions;
|
|
270
270
|
return _ts_generator(this, function(_state) {
|
|
@@ -321,7 +321,7 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
321
321
|
});
|
|
322
322
|
})();
|
|
323
323
|
};
|
|
324
|
-
var renderCascaderItem = function(item, levelIndex) {
|
|
324
|
+
var renderCascaderItem = function renderCascaderItem(item, levelIndex) {
|
|
325
325
|
var _item_pane;
|
|
326
326
|
return (_item_pane = item.pane) === null || _item_pane === void 0 ? void 0 : _item_pane.map(function(pane, index) {
|
|
327
327
|
var active = item.selected === pane.value;
|
|
@@ -336,7 +336,7 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
336
336
|
color: active ? activeColor : ''
|
|
337
337
|
},
|
|
338
338
|
key: pane.value,
|
|
339
|
-
onClick: function() {
|
|
339
|
+
onClick: function onClick() {
|
|
340
340
|
chooseItem(pane, levelIndex);
|
|
341
341
|
}
|
|
342
342
|
}, /*#__PURE__*/ React.createElement(View, {
|
|
@@ -350,14 +350,14 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
350
350
|
})));
|
|
351
351
|
});
|
|
352
352
|
};
|
|
353
|
-
var renderTab = function() {
|
|
353
|
+
var renderTab = function renderTab() {
|
|
354
354
|
return /*#__PURE__*/ React.createElement(View, {
|
|
355
355
|
className: classNames(classPrefix, props.className),
|
|
356
356
|
style: props.style
|
|
357
357
|
}, /*#__PURE__*/ React.createElement(Tabs, {
|
|
358
358
|
align: "left",
|
|
359
359
|
value: tabActiveIndex,
|
|
360
|
-
onChange: function(index) {
|
|
360
|
+
onChange: function onChange(index) {
|
|
361
361
|
var _props_onTabsChange;
|
|
362
362
|
(_props_onTabsChange = props.onTabsChange) === null || _props_onTabsChange === void 0 ? void 0 : _props_onTabsChange.call(props, Number(index));
|
|
363
363
|
setTabActiveIndex(Number(index));
|
|
@@ -380,10 +380,10 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
380
380
|
closeIconPosition: closeIconPosition,
|
|
381
381
|
title: props.title,
|
|
382
382
|
left: props.left,
|
|
383
|
-
onOverlayClick: function() {
|
|
383
|
+
onOverlayClick: function onOverlayClick() {
|
|
384
384
|
return setVisible(false);
|
|
385
385
|
},
|
|
386
|
-
onCloseIconClick: function() {
|
|
386
|
+
onCloseIconClick: function onCloseIconClick() {
|
|
387
387
|
return setVisible(false);
|
|
388
388
|
}
|
|
389
389
|
}), renderTab()) : renderTab();
|
|
@@ -71,7 +71,7 @@
|
|
|
71
71
|
align-items: center;
|
|
72
72
|
justify-content: center;
|
|
73
73
|
border-bottom: var(--nutui-popup-title-border-bottom, 0);
|
|
74
|
-
padding: var(--nutui-popup-title-padding,
|
|
74
|
+
padding: var(--nutui-popup-title-padding, 11px);
|
|
75
75
|
position: relative;
|
|
76
76
|
}
|
|
77
77
|
.nut-popup-title-wrapper {
|
|
@@ -84,7 +84,6 @@
|
|
|
84
84
|
color: var(--nutui-color-title, #1a1a1a);
|
|
85
85
|
font-weight: var(--nutui-font-weight-bold, 600);
|
|
86
86
|
font-size: var(--nutui-popup-title-font-size, var(--nutui-font-size-xl, 18px));
|
|
87
|
-
line-height: var(--nutui-popup-title-font-size, var(--nutui-font-size-xl, 18px));
|
|
88
87
|
}
|
|
89
88
|
.nut-popup-title-description {
|
|
90
89
|
color: var(--nutui-color-text, #505259);
|
|
@@ -96,13 +95,13 @@
|
|
|
96
95
|
}
|
|
97
96
|
.nut-popup-title-left {
|
|
98
97
|
position: absolute;
|
|
99
|
-
top: var(--nutui-popup-title-padding,
|
|
100
|
-
left: var(--nutui-popup-title-padding,
|
|
98
|
+
top: var(--nutui-popup-title-padding, 11px);
|
|
99
|
+
left: var(--nutui-popup-title-padding, 11px);
|
|
101
100
|
}
|
|
102
101
|
.nut-popup-title-right {
|
|
103
102
|
position: absolute;
|
|
104
|
-
top: var(--nutui-popup-title-padding,
|
|
105
|
-
right: var(--nutui-popup-title-padding,
|
|
103
|
+
top: var(--nutui-popup-title-padding, 11px);
|
|
104
|
+
right: var(--nutui-popup-title-padding, 11px);
|
|
106
105
|
z-index: 1;
|
|
107
106
|
width: var(--nutui-popup-icon-size, 20px);
|
|
108
107
|
height: var(--nutui-popup-icon-size, 20px);
|
|
@@ -113,20 +112,22 @@
|
|
|
113
112
|
opacity: 0.7;
|
|
114
113
|
}
|
|
115
114
|
.nut-popup-title-right-top-left {
|
|
116
|
-
top: var(--nutui-popup-title-padding,
|
|
117
|
-
left: var(--nutui-popup-title-padding,
|
|
115
|
+
top: var(--nutui-popup-title-padding, 11px);
|
|
116
|
+
left: var(--nutui-popup-title-padding, 11px);
|
|
118
117
|
}
|
|
119
118
|
.nut-popup-title-right-bottom-left {
|
|
120
|
-
bottom: var(--nutui-popup-title-padding,
|
|
121
|
-
left: var(--nutui-popup-title-padding,
|
|
119
|
+
bottom: var(--nutui-popup-title-padding, 11px);
|
|
120
|
+
left: var(--nutui-popup-title-padding, 11px);
|
|
122
121
|
}
|
|
123
122
|
.nut-popup-title-right-bottom-right {
|
|
124
|
-
right: var(--nutui-popup-title-padding,
|
|
125
|
-
bottom: var(--nutui-popup-title-padding,
|
|
123
|
+
right: var(--nutui-popup-title-padding, 11px);
|
|
124
|
+
bottom: var(--nutui-popup-title-padding, 11px);
|
|
126
125
|
}
|
|
127
126
|
.nut-popup-center {
|
|
128
127
|
top: 50%;
|
|
129
128
|
left: 50%;
|
|
129
|
+
right: auto;
|
|
130
|
+
bottom: auto;
|
|
130
131
|
min-height: 10%;
|
|
131
132
|
max-width: 295px;
|
|
132
133
|
transform: translate(-50%, -50%);
|
|
@@ -137,6 +138,8 @@
|
|
|
137
138
|
.nut-popup-bottom {
|
|
138
139
|
bottom: 0;
|
|
139
140
|
left: 0;
|
|
141
|
+
right: auto;
|
|
142
|
+
top: auto;
|
|
140
143
|
width: 100%;
|
|
141
144
|
}
|
|
142
145
|
.nut-popup-bottom.nut-popup-round {
|
|
@@ -148,6 +151,8 @@
|
|
|
148
151
|
.nut-popup-right {
|
|
149
152
|
top: 0;
|
|
150
153
|
right: 0;
|
|
154
|
+
left: auto;
|
|
155
|
+
bottom: auto;
|
|
151
156
|
width: 100px;
|
|
152
157
|
height: 100%;
|
|
153
158
|
}
|
|
@@ -157,6 +162,8 @@
|
|
|
157
162
|
.nut-popup-left {
|
|
158
163
|
top: 0;
|
|
159
164
|
left: 0;
|
|
165
|
+
right: auto;
|
|
166
|
+
bottom: auto;
|
|
160
167
|
width: 100px;
|
|
161
168
|
height: 100%;
|
|
162
169
|
}
|
|
@@ -166,6 +173,8 @@
|
|
|
166
173
|
.nut-popup-top {
|
|
167
174
|
top: 0;
|
|
168
175
|
left: 0;
|
|
176
|
+
right: auto;
|
|
177
|
+
bottom: auto;
|
|
169
178
|
width: 100%;
|
|
170
179
|
}
|
|
171
180
|
.nut-popup-top.nut-popup-round {
|
|
@@ -242,6 +251,9 @@
|
|
|
242
251
|
}
|
|
243
252
|
}
|
|
244
253
|
@keyframes popup-slide-top-exit {
|
|
254
|
+
from {
|
|
255
|
+
transform: translate3d(0, 0%, 0);
|
|
256
|
+
}
|
|
245
257
|
to {
|
|
246
258
|
transform: translate3d(0, -100%, 0);
|
|
247
259
|
}
|
|
@@ -266,6 +278,9 @@
|
|
|
266
278
|
}
|
|
267
279
|
}
|
|
268
280
|
@keyframes popup-slide-right-exit {
|
|
281
|
+
from {
|
|
282
|
+
transform: translate3d(0%, 0, 0);
|
|
283
|
+
}
|
|
269
284
|
to {
|
|
270
285
|
transform: translate3d(100%, 0, 0);
|
|
271
286
|
}
|
|
@@ -290,6 +305,9 @@
|
|
|
290
305
|
}
|
|
291
306
|
}
|
|
292
307
|
@keyframes slide-bottom-exit {
|
|
308
|
+
from {
|
|
309
|
+
transform: translate3d(0, 0%, 0);
|
|
310
|
+
}
|
|
293
311
|
to {
|
|
294
312
|
transform: translate3d(0, 100%, 0);
|
|
295
313
|
}
|
|
@@ -314,6 +332,9 @@
|
|
|
314
332
|
}
|
|
315
333
|
}
|
|
316
334
|
@keyframes popup-slide-left-exit {
|
|
335
|
+
from {
|
|
336
|
+
transform: translate3d(0%, 0, 0);
|
|
337
|
+
}
|
|
317
338
|
to {
|
|
318
339
|
transform: translate3d(-100%, 0, 0);
|
|
319
340
|
}
|
|
@@ -339,27 +360,27 @@
|
|
|
339
360
|
[dir=rtl] .nut-popup-title-left,
|
|
340
361
|
.nut-rtl .nut-popup-title-left {
|
|
341
362
|
left: auto;
|
|
342
|
-
right: var(--nutui-popup-title-padding,
|
|
363
|
+
right: var(--nutui-popup-title-padding, 11px);
|
|
343
364
|
}
|
|
344
365
|
[dir=rtl] .nut-popup-title-right,
|
|
345
366
|
.nut-rtl .nut-popup-title-right {
|
|
346
367
|
right: auto;
|
|
347
|
-
left: var(--nutui-popup-title-padding,
|
|
368
|
+
left: var(--nutui-popup-title-padding, 11px);
|
|
348
369
|
}
|
|
349
370
|
[dir=rtl] .nut-popup-title-right-top-left,
|
|
350
371
|
.nut-rtl .nut-popup-title-right-top-left {
|
|
351
372
|
left: auto;
|
|
352
|
-
right: var(--nutui-popup-title-padding,
|
|
373
|
+
right: var(--nutui-popup-title-padding, 11px);
|
|
353
374
|
}
|
|
354
375
|
[dir=rtl] .nut-popup-title-right-bottom-left,
|
|
355
376
|
.nut-rtl .nut-popup-title-right-bottom-left {
|
|
356
377
|
left: auto;
|
|
357
|
-
right: var(--nutui-popup-title-padding,
|
|
378
|
+
right: var(--nutui-popup-title-padding, 11px);
|
|
358
379
|
}
|
|
359
380
|
[dir=rtl] .nut-popup-title-right-bottom-right,
|
|
360
381
|
.nut-rtl .nut-popup-title-right-bottom-right {
|
|
361
382
|
right: auto;
|
|
362
|
-
left: var(--nutui-popup-title-padding,
|
|
383
|
+
left: var(--nutui-popup-title-padding, 11px);
|
|
363
384
|
}
|
|
364
385
|
[dir=rtl] .nut-popup-title .nut-icon-ArrowLeft,
|
|
365
386
|
.nut-rtl .nut-popup-title .nut-icon-ArrowLeft {
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { _ as _object_spread } from "@swc/helpers/_/_object_spread";
|
|
2
2
|
import { _ as _object_without_properties } from "@swc/helpers/_/_object_without_properties";
|
|
3
3
|
import { _ as _to_property_key } from "@swc/helpers/_/_to_property_key";
|
|
4
|
-
export var normalizeOptions = function(options, keyMap) {
|
|
4
|
+
export var normalizeOptions = function normalizeOptions1(options, keyMap) {
|
|
5
5
|
if (!options) return undefined;
|
|
6
6
|
return options.map(function(opt) {
|
|
7
|
-
var
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
var _key = keyMap.textKey, _key1 = keyMap.valueKey, _key2 = keyMap.childrenKey, text = opt[_key], value = opt[_key1], children = opt[_key2], others = _object_without_properties(opt, [
|
|
8
|
+
_key,
|
|
9
|
+
_key1,
|
|
10
|
+
_key2
|
|
11
11
|
].map(_to_property_key));
|
|
12
12
|
return _object_spread({
|
|
13
13
|
text: text,
|
|
@@ -16,7 +16,7 @@ export var normalizeOptions = function(options, keyMap) {
|
|
|
16
16
|
}, others);
|
|
17
17
|
});
|
|
18
18
|
};
|
|
19
|
-
export var normalizeListOptions = function(options, format) {
|
|
19
|
+
export var normalizeListOptions = function normalizeListOptions(options, format) {
|
|
20
20
|
var defaultConvertConfig = {
|
|
21
21
|
topId: null,
|
|
22
22
|
idKey: 'id',
|
|
@@ -17,14 +17,14 @@ var defaultProps = _object_spread_props(_object_spread({}, ComponentDefaults), {
|
|
|
17
17
|
align: 'flex-start',
|
|
18
18
|
clickable: false,
|
|
19
19
|
isLast: false,
|
|
20
|
-
onClick: function(event) {}
|
|
20
|
+
onClick: function onClick(event) {}
|
|
21
21
|
});
|
|
22
22
|
var classPrefix = 'nut-cell';
|
|
23
|
-
export var Cell = function(props) {
|
|
23
|
+
export var Cell = function Cell(props) {
|
|
24
24
|
var ctx = useContext(CellGroupContext);
|
|
25
25
|
var _$_object_spread = _object_spread({}, defaultProps, props), children = _$_object_spread.children, onClick = _$_object_spread.onClick, title = _$_object_spread.title, description = _$_object_spread.description, extra = _$_object_spread.extra, radius = _$_object_spread.radius, align = _$_object_spread.align, isLast = _$_object_spread.isLast, className = _$_object_spread.className, style = _$_object_spread.style, clickable = _$_object_spread.clickable;
|
|
26
26
|
var rtl = useRtl();
|
|
27
|
-
var handleClick = function(event) {
|
|
27
|
+
var handleClick = function handleClick(event) {
|
|
28
28
|
onClick(event);
|
|
29
29
|
};
|
|
30
30
|
var radiusNumber = Number(String(radius).replace(/[^\d]/g, ''));
|
|
@@ -42,7 +42,7 @@ export var Cell = function(props) {
|
|
|
42
42
|
className,
|
|
43
43
|
_define_property({}, "".concat(classPrefix, "-group-item"), ctx === null || ctx === void 0 ? void 0 : ctx.group)
|
|
44
44
|
], clickable ? "".concat(classPrefix, "-clickable") : '')),
|
|
45
|
-
onClick: function(event) {
|
|
45
|
+
onClick: function onClick(event) {
|
|
46
46
|
return handleClick(event);
|
|
47
47
|
},
|
|
48
48
|
style: baseStyle
|
|
@@ -12,8 +12,8 @@ var defaultProps = _object_spread_props(_object_spread({}, ComponentDefaults), {
|
|
|
12
12
|
divider: true
|
|
13
13
|
});
|
|
14
14
|
var classPrefix = 'nut-cell-group';
|
|
15
|
-
export var CellGroup = function(props) {
|
|
16
|
-
var
|
|
15
|
+
export var CellGroup = function CellGroup(props) {
|
|
16
|
+
var _$_object_spread = _object_spread({}, defaultProps, props), children = _$_object_spread.children, className = _$_object_spread.className, title = _$_object_spread.title, description = _$_object_spread.description, divider = _$_object_spread.divider, rest = _object_without_properties(_$_object_spread, [
|
|
17
17
|
"children",
|
|
18
18
|
"className",
|
|
19
19
|
"title",
|
|
@@ -17,10 +17,10 @@ var defaultProps = _object_spread_props(_object_spread({}, ComponentDefaults), {
|
|
|
17
17
|
icon: null,
|
|
18
18
|
activeIcon: null,
|
|
19
19
|
indeterminateIcon: null,
|
|
20
|
-
onChange: function(value) {}
|
|
20
|
+
onChange: function onChange(value) {}
|
|
21
21
|
});
|
|
22
22
|
var classPrefix = 'nut-checkbox';
|
|
23
|
-
export var Checkbox = function(props) {
|
|
23
|
+
export var Checkbox = function Checkbox(props) {
|
|
24
24
|
var children = _object_spread({}, defaultProps, props).children;
|
|
25
25
|
var icon = props.icon, label = props.label, className = props.className, activeIcon = props.activeIcon, checked = props.checked, value = props.value, defaultChecked = props.defaultChecked, shape = props.shape, disabled = props.disabled, onChange = props.onChange, indeterminate = props.indeterminate, indeterminateIcon = props.indeterminateIcon, others = _object_without_properties(props, [
|
|
26
26
|
"icon",
|
|
@@ -66,13 +66,13 @@ export var Checkbox = function(props) {
|
|
|
66
66
|
}
|
|
67
67
|
innerDisabled = ctx.disabled !== undefined ? ctx.disabled : innerDisabled;
|
|
68
68
|
innerChecked = ctx.value.includes(value);
|
|
69
|
-
setChecked = function(checked) {
|
|
69
|
+
setChecked = function setChecked(checked) {
|
|
70
70
|
if (ctx.disabled) return;
|
|
71
71
|
if (checked) ctx.check(value);
|
|
72
72
|
if (!checked) ctx.uncheck(value);
|
|
73
73
|
};
|
|
74
74
|
}
|
|
75
|
-
var renderIcon = function() {
|
|
75
|
+
var renderIcon = function renderIcon() {
|
|
76
76
|
if (innerDisabled) {
|
|
77
77
|
if (innerIndeterminate) {
|
|
78
78
|
// @ts-ignore
|
|
@@ -115,7 +115,7 @@ export var Checkbox = function(props) {
|
|
|
115
115
|
ariaHidden: true
|
|
116
116
|
}));
|
|
117
117
|
};
|
|
118
|
-
var color = function() {
|
|
118
|
+
var color = function color() {
|
|
119
119
|
var cls = "".concat(classPrefix, "-icon ");
|
|
120
120
|
if (innerDisabled) {
|
|
121
121
|
if (innerChecked && !innerIndeterminate) {
|
|
@@ -134,19 +134,19 @@ export var Checkbox = function(props) {
|
|
|
134
134
|
}
|
|
135
135
|
return cls;
|
|
136
136
|
};
|
|
137
|
-
var renderLabel = function() {
|
|
137
|
+
var renderLabel = function renderLabel() {
|
|
138
138
|
return /*#__PURE__*/ React.createElement(View, {
|
|
139
139
|
className: classNames("".concat(classPrefix, "-label "), _define_property({}, "".concat(classPrefix, "-label-disabled"), innerDisabled))
|
|
140
140
|
}, children || label);
|
|
141
141
|
};
|
|
142
|
-
var handleClick = function() {
|
|
142
|
+
var handleClick = function handleClick() {
|
|
143
143
|
// 禁用的时候直接返回
|
|
144
144
|
if (disabled) return;
|
|
145
145
|
// 先转换状态
|
|
146
146
|
var latestChecked = !innerChecked;
|
|
147
147
|
setChecked(latestChecked);
|
|
148
148
|
};
|
|
149
|
-
var renderButton = function() {
|
|
149
|
+
var renderButton = function renderButton() {
|
|
150
150
|
var _obj;
|
|
151
151
|
return /*#__PURE__*/ React.createElement(View, {
|
|
152
152
|
className: classNames("".concat(classPrefix, "-button"), (_obj = {}, _define_property(_obj, "".concat(classPrefix, "-button-active"), innerChecked), _define_property(_obj, "".concat(classPrefix, "-button-disabled"), disabled), _obj))
|
|
@@ -154,10 +154,10 @@ export var Checkbox = function(props) {
|
|
|
154
154
|
className: classNames("".concat(classPrefix, "-button-icon"))
|
|
155
155
|
}), activeIcon) : null);
|
|
156
156
|
};
|
|
157
|
-
var renderListItem = function() {
|
|
157
|
+
var renderListItem = function renderListItem() {
|
|
158
158
|
return /*#__PURE__*/ React.createElement(React.Fragment, null, renderIcon(), renderLabel());
|
|
159
159
|
};
|
|
160
|
-
var renderCheckboxItem = function() {
|
|
160
|
+
var renderCheckboxItem = function renderCheckboxItem() {
|
|
161
161
|
if (ctx === null || ctx === void 0 ? void 0 : ctx.list) {
|
|
162
162
|
return /*#__PURE__*/ React.createElement(React.Fragment, null, renderListItem());
|
|
163
163
|
}
|