@nutui/nutui-react-taro 2.3.11 → 2.4.0
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 +48 -0
- package/dist/esm/ActionSheet.js +1 -13
- package/dist/esm/Address.js +1 -21
- package/dist/esm/Animate.js +1 -4
- package/dist/esm/AnimatingNumbers/style/style.css +1 -1
- package/dist/esm/AnimatingNumbers.js +8 -22
- package/dist/esm/Audio.js +1 -15
- package/dist/esm/Avatar.js +1 -10
- package/dist/esm/AvatarCropper.js +1 -10
- package/dist/esm/AvatarGroup.js +1 -4
- package/dist/esm/BackTop.js +1 -6
- package/dist/esm/Badge/style/style.css +1 -1
- package/dist/esm/Badge.js +1 -4
- package/dist/esm/Barrage.js +1 -7
- package/dist/esm/Button.js +1 -6
- package/dist/esm/Calendar.js +1 -20
- package/dist/esm/CalendarCard.js +1 -8
- package/dist/esm/CalendarItem.js +1 -12
- package/dist/esm/Card.js +1 -7
- package/dist/esm/Cascader.js +1 -18
- package/dist/esm/Cell.js +1 -5
- package/dist/esm/CellGroup.js +1 -4
- package/dist/esm/Checkbox/style/style.css +1 -1
- package/dist/esm/Checkbox.js +1 -7
- package/dist/esm/CheckboxGroup/style/style.css +1 -1
- package/dist/esm/CheckboxGroup.js +1 -7
- package/dist/esm/CircleProgress.js +1 -6
- package/dist/esm/Col.js +1 -5
- package/dist/esm/Collapse/style/style.css +1 -1
- package/dist/esm/Collapse.js +1 -8
- package/dist/esm/CollapseItem/style/style.css +1 -1
- package/dist/esm/CollapseItem.js +1 -5
- package/dist/esm/ConfigProvider.js +4 -6
- package/dist/esm/CountDown.js +1 -7
- package/dist/esm/DatePicker.js +1 -21
- package/dist/esm/Dialog/style/style.css +1 -1
- package/dist/esm/Dialog.js +1 -16
- package/dist/esm/Divider.js +1 -4
- package/dist/esm/Drag.js +1 -4
- package/dist/esm/Elevator.js +1 -6
- package/dist/esm/Ellipsis.js +1 -7
- package/dist/esm/Empty.js +1 -9
- package/dist/esm/FixedNav.js +1 -13
- package/dist/esm/Form.js +7 -18
- package/dist/esm/FormItem.js +1 -6
- package/dist/esm/Grid.js +1 -7
- package/dist/esm/GridItem.js +1 -6
- package/dist/esm/Image.js +1 -7
- package/dist/esm/ImagePreview.js +1 -20
- package/dist/esm/Indicator.js +1 -3
- package/dist/esm/InfiniteLoading.js +1 -8
- package/dist/esm/Input.js +1 -11
- package/dist/esm/InputNumber/style/style.css +1 -1
- package/dist/esm/InputNumber.js +1 -7
- package/dist/esm/Layout.js +1 -2
- package/dist/esm/Loading.js +1 -5
- package/dist/esm/Menu.js +1 -15
- package/dist/esm/MenuItem.js +1 -14
- package/dist/esm/NavBar.js +1 -7
- package/dist/esm/NoticeBar/style/style.css +1 -1
- package/dist/esm/NoticeBar.js +1 -7
- package/dist/esm/Notify.js +1 -9
- package/dist/esm/NumberKeyboard.js +1 -15
- package/dist/esm/Overlay.js +1 -9
- package/dist/esm/Pagination.js +1 -8
- package/dist/esm/Picker.js +1 -19
- package/dist/esm/Popover/style/style.css +1 -1
- package/dist/esm/Popover.js +1 -14
- package/dist/esm/Popup.js +1 -12
- package/dist/esm/Price.js +1 -3
- package/dist/esm/Progress.js +1 -4
- package/dist/esm/PullToRefresh.js +1 -10
- package/dist/esm/Radio.js +1 -7
- package/dist/esm/RadioGroup.js +1 -7
- package/dist/esm/Range.js +1 -10
- package/dist/esm/Rate.js +1 -11
- package/dist/esm/Row.js +1 -5
- package/dist/esm/SafeArea.js +1 -3
- package/dist/esm/SearchBar.js +1 -7
- package/dist/esm/ShortPassword.js +1 -17
- package/dist/esm/SideNavBar.js +1 -14
- package/dist/esm/SideNavBarItem.js +1 -2
- package/dist/esm/Signature.js +1 -4
- package/dist/esm/Skeleton.js +1 -11
- package/dist/esm/Space.js +1 -3
- package/dist/esm/Step.js +1 -6
- package/dist/esm/Steps.js +1 -5
- package/dist/esm/Sticky.js +1 -7
- package/dist/esm/SubSideNavBar.js +1 -3
- package/dist/esm/Swipe/style/style.css +1 -1
- package/dist/esm/Swipe.js +1 -8
- package/dist/esm/Swiper.js +9 -11
- package/dist/esm/SwiperItem.js +1 -2
- package/dist/esm/Switch.js +1 -5
- package/dist/esm/TabPane.js +1 -3
- package/dist/esm/Tabbar/style/style.css +1 -1
- package/dist/esm/Tabbar.js +1 -8
- package/dist/esm/TabbarItem/style/style.css +1 -1
- package/dist/esm/TabbarItem.js +1 -5
- package/dist/esm/Table.js +1 -9
- package/dist/esm/Tabs.js +1 -11
- package/dist/esm/Tag.js +1 -5
- package/dist/esm/TextArea.js +1 -10
- package/dist/esm/TimeDetail.js +1 -4
- package/dist/esm/TimeSelect.js +1 -16
- package/dist/esm/Toast.js +1 -15
- package/dist/esm/Tour/style/style.css +1 -1
- package/dist/esm/Tour.js +1 -16
- package/dist/esm/TrendArrow.js +1 -4
- package/dist/esm/Uploader.js +1 -14
- package/dist/esm/Video.js +1 -4
- package/dist/esm/VirtualList.js +1 -6
- package/dist/esm/WaterMark.js +1 -7
- package/dist/esm/{actionsheet.taro-kKhb0Vwt.js → actionsheet.taro-C5BqWoML.js} +9 -17
- package/dist/esm/{address.taro-zQuxQEce.js → address.taro-CgkCHDYZ.js} +19 -44
- package/dist/esm/{animate.taro-m67VyUHP.js → animate.taro-Dg9jxZEu.js} +6 -14
- package/dist/esm/{audio.taro-dJgj5qIu.js → audio.taro-DXxWGngO.js} +14 -30
- package/dist/esm/avatar.taro-a6CX3kxV.js +86 -0
- package/dist/esm/{avatarcropper.taro-GIZxzMJ_.js → avatarcropper.taro-BFvFmK4t.js} +47 -90
- package/dist/esm/{avatargroup.taro-h6dpv6UX.js → avatargroup.taro-bpT5kPbf.js} +3 -11
- package/dist/esm/{backtop.taro-Cfld7ina.js → backtop.taro-B-zl6AEC.js} +4 -15
- package/dist/esm/{badge.taro-993L861f.js → badge.taro-D7Yn5zJi.js} +8 -16
- package/dist/esm/{barrage.taro-6nbq7wtt.js → barrage.taro-BNOcZsJ1.js} +18 -28
- package/dist/esm/{button.taro-3IIFy1M2.js → button.taro-OKGsDVW7.js} +8 -23
- package/dist/esm/{calendar.taro-iNNHje7V.js → calendar.taro-DbHJEx4G.js} +12 -39
- package/dist/esm/{calendarcard.taro-9s7naGmU.js → calendarcard.taro-BHGCq5zX.js} +10 -14
- package/dist/esm/{calendaritem.taro-o6Z8OOGY.js → calendaritem.taro-B8tN2DYa.js} +11 -36
- package/dist/esm/{card.taro-p4PTy-IU.js → card.taro-uLorQW97.js} +7 -22
- package/dist/esm/{cascader.taro-M2nZWxiB.js → cascader.taro-BMp2mI0W.js} +47 -83
- package/dist/esm/{cell.taro-jD6MoFTj.js → cell.taro-CCnLF6RC.js} +9 -23
- package/dist/esm/{cellgroup.taro-08A3XAze.js → cellgroup.taro-Dz69kT6e.js} +5 -12
- package/dist/esm/{checkbox.taro-xMxWdpyI.js → checkbox.taro-CUpF7Afr.js} +40 -32
- package/dist/esm/{circleprogress.taro-myZgamBw.js → circleprogress.taro-CKSrzt8Q.js} +8 -22
- package/dist/esm/{col.taro-5FMpttLE.js → col.taro-C8DUuJYh.js} +5 -13
- package/dist/esm/{collapse.taro-sZibDygv.js → collapse.taro-BM0BsN30.js} +5 -14
- package/dist/esm/{collapseitem.taro-AaQ_msgd.js → collapseitem.taro-D_m4VEdG.js} +7 -16
- package/dist/esm/configprovider.taro-CyU_tvNJ.js +202 -0
- package/dist/esm/{countdown.taro-XZlfWBrA.js → countdown.taro-D-H9erkV.js} +9 -19
- package/dist/esm/{datepicker.taro-DrXkqJkN.js → datepicker.taro-DqR52Ivo.js} +14 -26
- package/dist/esm/{dialog.taro-dmQGDu3o.js → dialog.taro-Dk0QQMn_.js} +31 -23
- package/dist/esm/{divider.taro-H5fKry4P.js → divider.taro-DRcO_m9e.js} +5 -11
- package/dist/esm/{drag.taro-BwcleRuB.js → drag.taro-CcHIO07Y.js} +10 -18
- package/dist/esm/{elevator.taro-2nbUM3vH.js → elevator.taro-uhrF7ChY.js} +5 -17
- package/dist/esm/{ellipsis.taro-VApVqS_j.js → ellipsis.taro-B_mTyNyk.js} +25 -34
- package/dist/esm/{empty.taro-gwvOr1xf.js → empty.taro-Brkv6B2Z.js} +8 -18
- package/dist/esm/{fixednav.taro-QVBXysDj.js → fixednav.taro-WTBxWxOo.js} +10 -21
- package/dist/esm/formitem.taro-Brz5dj_8.js +330 -0
- package/dist/esm/{get-rect-by-taro-piSHvCGp.js → get-rect-by-taro-CSN0TGnD.js} +3 -2
- package/dist/esm/{grid.taro-3X-_AhXw.js → grid.taro-BA76RrgT.js} +5 -4
- package/dist/esm/{griditem.taro-TJDJVeQy.js → griditem.taro-JLddv9zD.js} +6 -11
- package/dist/esm/{image.taro-FfeikBlO.js → image.taro-BLz2WCva.js} +5 -6
- package/dist/esm/{imagepreview.taro--fVrJUOE.js → imagepreview.taro-Bb1TkBCV.js} +13 -31
- package/dist/esm/{indicator.taro-ZH6MICsS.js → indicator.taro-CpHZtD9p.js} +3 -5
- package/dist/esm/{infiniteloading.taro-BO0_y46K.js → infiniteloading.taro-Ccq4bEzk.js} +14 -21
- package/dist/esm/{input.taro-xCoGdppk.js → input.taro-BVC8gEuk.js} +14 -31
- package/dist/esm/{inputnumber.taro-WPpS0Xl9.js → inputnumber.taro-CQiAPZgS.js} +17 -28
- package/dist/esm/{layout.taro-lnN-wB0Y.js → layout.taro-BE2868d6.js} +1 -1
- package/dist/esm/{loading.taro-aHN6xLIT.js → loading.taro-CRF1z5wQ.js} +5 -8
- package/dist/esm/{menu.taro-ODwHYGFM.js → menu.taro-BAiJPGR7.js} +12 -25
- package/dist/esm/{menuitem.taro-9nyTDLpt.js → menuitem.taro-oLv6ZYC5.js} +15 -36
- package/dist/esm/{navbar.taro-AuKPDCaW.js → navbar.taro-B8u3DOE4.js} +14 -29
- package/dist/esm/{noticebar.taro-bHnEzTvL.js → noticebar.taro-CRPbZenq.js} +40 -51
- package/dist/esm/{notify.taro-mA9KS8qh.js → notify.taro-jP7y9zMU.js} +6 -15
- package/dist/esm/{numberkeyboard.taro-bF6VCXry.js → numberkeyboard.taro-B9rMgy7D.js} +9 -16
- package/dist/esm/nutui-react.es.js +93 -118
- package/dist/esm/{overlay.taro-HsGeVyPh.js → overlay.taro-BaBu-3-F.js} +10 -22
- package/dist/esm/{pagination.taro-C4_Ey5KC.js → pagination.taro-DAK6ddag.js} +7 -19
- package/dist/esm/{picker.taro-csU3SZPF.js → picker.taro-Cmng9GW9.js} +34 -43
- package/dist/esm/{popover.taro-qldQwLPC.js → popover.taro-BsOaXoWp.js} +29 -45
- package/dist/esm/{popup.taro-ObEUml4r.js → popup.taro-Iy_WQZ-m.js} +8 -32
- package/dist/esm/{price.taro-Z1zR8YWV.js → price.taro-UVRHPHRD.js} +5 -16
- package/dist/esm/{progress.taro-pStvlrbA.js → progress.taro-BOHykt7X.js} +8 -14
- package/dist/esm/{pulltorefresh.taro-2jER8Mat.js → pulltorefresh.taro-BJdQj5sL.js} +31 -47
- package/dist/esm/{radio.taro-EKJXMjnX.js → radio.taro-CjJgX9o2.js} +20 -33
- package/dist/esm/{range.taro-mDYY3SXA.js → range.taro-BxMDs5Cy.js} +20 -22
- package/dist/esm/{rate.taro-_5Mjd_EO.js → rate.taro-BABLqt4h.js} +7 -20
- package/dist/esm/{row.taro-IxNlKKQM.js → row.taro-D8chDydP.js} +4 -14
- package/dist/esm/{searchbar.taro-hVzdT6nI.js → searchbar.taro-PfVx6o-6.js} +9 -26
- package/dist/esm/{shortpassword.taro-JBWXzk6I.js → shortpassword.taro-BXsxku33.js} +9 -19
- package/dist/esm/{sidenavbar.taro-8qoGZg5n.js → sidenavbar.taro-eK5vaZPR.js} +7 -13
- package/dist/esm/sidenavbaritem.taro-L7HbsCLn.js +14 -0
- package/dist/esm/{signature.taro-y3qxnKMv.js → signature.taro-KPm_xs66.js} +11 -19
- package/dist/esm/{skeleton.taro--AtiA7MK.js → skeleton.taro-BwIDIf2p.js} +6 -17
- package/dist/esm/{space.taro-q3R_yq79.js → space.taro-CZ999etm.js} +1 -4
- package/dist/esm/{step.taro-_DEZqFGb.js → step.taro-DLr2GzYk.js} +8 -16
- package/dist/esm/steps.taro-C8Yg1Sns.js +28 -0
- package/dist/esm/{sticky.taro-p-evMNR-.js → sticky.taro-DRBk3gkQ.js} +12 -15
- package/dist/esm/{subsidenavbar.taro-Zy52MDDG.js → subsidenavbar.taro-ByxYpgfP.js} +7 -9
- package/dist/esm/{swipe.taro-p2ONOq1o.js → swipe.taro-wm7YWwaj.js} +29 -31
- package/dist/esm/{swiperitem.taro-BC1CE0T-.js → swiperitem.taro-8JXI24f0.js} +3 -1
- package/dist/esm/{switch.taro-L0BAbMeu.js → switch.taro-D1HgJoJz.js} +6 -13
- package/dist/esm/{tabbar.taro-QE0rjSKE.js → tabbar.taro-LAPQoOva.js} +7 -18
- package/dist/esm/tabbaritem.taro-C4AZbQMG.js +58 -0
- package/dist/esm/{table.taro-0zRh2hq6.js → table.taro-ClLmfqz3.js} +14 -24
- package/dist/esm/{tabpane.taro-5k7wWimS.js → tabpane.taro-BAe86j3t.js} +1 -4
- package/dist/esm/{tabs.taro-Yj7vgtSg.js → tabs.taro-DRmZR3Xu.js} +19 -35
- package/dist/esm/{tag.taro-5KC_wObY.js → tag.taro-BsmY5QfN.js} +7 -22
- package/dist/esm/{textarea.taro-9zQLTCwU.js → textarea.taro-BJIFCpKb.js} +11 -20
- package/dist/esm/{timedetail.taro-TF9Wcblh.js → timedetail.taro-x6Zey1xi.js} +11 -21
- package/dist/esm/{timeselect.taro-j8LgSCe5.js → timeselect.taro-BXq4APSJ.js} +20 -33
- package/dist/esm/{toast.taro-xnEQSCDJ.js → toast.taro-BVXqvjNJ.js} +9 -27
- package/dist/esm/{tour.taro-CGEjzzN_.js → tour.taro-wfXuUebD.js} +7 -24
- package/dist/esm/{trendarrow.taro-hsM6-XsQ.js → trendarrow.taro-BHUetKSS.js} +6 -18
- package/dist/esm/tslib.es6-BZ8i9Q6l.js +47 -0
- package/dist/esm/types/src/packages/button/demos/h5/demo1.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/h5/demo2.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/h5/demo3.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/h5/demo4.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/h5/demo5.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/h5/demo6.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/h5/demo7.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/h5/demo8.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/h5/demo9.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/taro/demo1.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/taro/demo10.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/taro/demo2.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/taro/demo3.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/taro/demo4.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/taro/demo5.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/taro/demo6.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/taro/demo7.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/taro/demo8.d.ts +3 -0
- package/dist/esm/types/src/packages/button/demos/taro/demo9.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demo.d.ts +0 -1
- package/dist/esm/types/src/packages/cell/demo.taro.d.ts +0 -1
- package/dist/esm/types/src/packages/cell/demos/h5/demo1.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/h5/demo2.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/h5/demo3.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/h5/demo4.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/h5/demo5.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/h5/demo6.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/h5/demo7.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/taro/demo1.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/taro/demo2.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/taro/demo3.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/taro/demo4.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/taro/demo5.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/taro/demo6.d.ts +3 -0
- package/dist/esm/types/src/packages/cell/demos/taro/demo7.d.ts +3 -0
- package/dist/esm/types/src/packages/checkboxgroup/checkboxgroup.d.ts +1 -0
- package/dist/esm/types/src/packages/checkboxgroup/checkboxgroup.taro.d.ts +1 -0
- package/dist/esm/types/src/packages/checkboxgroup/context.d.ts +1 -0
- package/dist/esm/types/src/packages/configprovider/configprovider.d.ts +1 -0
- package/dist/esm/types/src/packages/configprovider/configprovider.taro.d.ts +1 -0
- package/dist/esm/types/src/packages/configprovider/index.d.ts +2 -2
- package/dist/esm/types/src/packages/configprovider/index.taro.d.ts +2 -2
- package/dist/esm/types/src/packages/configprovider/types.d.ts +1 -1
- package/dist/esm/types/src/packages/dialog/config.d.ts +3 -3
- package/dist/esm/types/src/packages/dialog/index.d.ts +1 -1
- package/dist/esm/types/src/packages/inputnumber/inputnumber.taro.d.ts +2 -0
- package/dist/esm/types/src/packages/noticebar/index.d.ts +1 -0
- package/dist/esm/types/src/packages/noticebar/noticebar.d.ts +2 -0
- package/dist/esm/types/src/packages/noticebar/noticebar.taro.d.ts +2 -0
- package/dist/esm/types/src/packages/noticebar/types.d.ts +1 -0
- package/dist/esm/types/src/packages/popover/index.d.ts +2 -1
- package/dist/esm/types/src/packages/popover/index.taro.d.ts +2 -1
- package/dist/esm/types/src/packages/popover/popover.d.ts +2 -12
- package/dist/esm/types/src/packages/popover/popover.taro.d.ts +2 -12
- package/dist/esm/types/src/packages/popover/types.d.ts +14 -0
- package/dist/esm/types/src/packages/table/useTableSticky.d.ts +1 -1
- package/dist/esm/types/src/packages/toast/toast.taro.d.ts +7 -3
- package/dist/esm/types/src/packages/tour/tour.d.ts +1 -1
- package/dist/esm/types/src/packages/tour/tour.taro.d.ts +1 -1
- package/dist/esm/{uploader.taro-bRF02TR9.js → uploader.taro-DdJ-sOK4.js} +49 -101
- package/dist/esm/{use-custom-event-XvsODK8c.js → use-custom-event-DuP4onEm.js} +5 -5
- package/dist/esm/{use-props-value-vKr0R0AX.js → use-props-value-SH9krhkx.js} +2 -2
- package/dist/esm/{video.taro-csvHwS2v.js → video.taro-CEMVfhCS.js} +3 -5
- package/dist/esm/{virtuallist.taro-AeTVtFFa.js → virtuallist.taro-Cl08vfdg.js} +10 -19
- package/dist/esm/{watermark.taro-nvSmcwu-.js → watermark.taro-BxM8VfXb.js} +5 -30
- package/dist/locales/base.js +1 -1
- package/dist/locales/en-US.js +1 -1
- package/dist/locales/id-ID.js +1 -1
- package/dist/locales/tr-TR.js +1 -1
- package/dist/locales/zh-CN.js +1 -1
- package/dist/locales/zh-TW.js +1 -1
- package/dist/locales/zh-UG.js +1 -1
- package/dist/nutui.react.es.js +403 -382
- package/dist/nutui.react.umd.js +404 -383
- package/dist/packages/animatingnumbers/countup.scss +1 -0
- package/dist/packages/badge/badge.scss +2 -0
- package/dist/packages/checkbox/checkbox.scss +19 -0
- package/dist/packages/checkboxgroup/checkboxgroup.scss +25 -0
- package/dist/packages/collapseitem/collapseitem.scss +1 -6
- package/dist/packages/dialog/dialog.scss +8 -1
- package/dist/packages/noticebar/noticebar.scss +19 -1
- package/dist/packages/popover/popover.scss +21 -0
- package/dist/packages/swipe/swipe.scss +2 -0
- package/dist/style.css +1 -1
- package/dist/style.mjs +1 -1
- package/dist/styles/variables-jmapp.scss +17 -0
- package/dist/styles/variables.scss +19 -12
- package/dist/types/packages/badge/badge.taro.d.ts +1 -1
- package/dist/types/packages/button/demos/h5/demo1.d.ts +3 -0
- package/dist/types/packages/button/demos/h5/demo2.d.ts +3 -0
- package/dist/types/packages/button/demos/h5/demo3.d.ts +3 -0
- package/dist/types/packages/button/demos/h5/demo4.d.ts +3 -0
- package/dist/types/packages/button/demos/h5/demo5.d.ts +3 -0
- package/dist/types/packages/button/demos/h5/demo6.d.ts +3 -0
- package/dist/types/packages/button/demos/h5/demo7.d.ts +3 -0
- package/dist/types/packages/button/demos/h5/demo8.d.ts +3 -0
- package/dist/types/packages/button/demos/h5/demo9.d.ts +3 -0
- package/dist/types/packages/button/demos/taro/demo1.d.ts +3 -0
- package/dist/types/packages/button/demos/taro/demo10.d.ts +3 -0
- package/dist/types/packages/button/demos/taro/demo2.d.ts +3 -0
- package/dist/types/packages/button/demos/taro/demo3.d.ts +3 -0
- package/dist/types/packages/button/demos/taro/demo4.d.ts +3 -0
- package/dist/types/packages/button/demos/taro/demo5.d.ts +3 -0
- package/dist/types/packages/button/demos/taro/demo6.d.ts +3 -0
- package/dist/types/packages/button/demos/taro/demo7.d.ts +3 -0
- package/dist/types/packages/button/demos/taro/demo8.d.ts +3 -0
- package/dist/types/packages/button/demos/taro/demo9.d.ts +3 -0
- package/dist/types/packages/cell/demos/h5/demo1.d.ts +3 -0
- package/dist/types/packages/cell/demos/h5/demo2.d.ts +3 -0
- package/dist/types/packages/cell/demos/h5/demo3.d.ts +3 -0
- package/dist/types/packages/cell/demos/h5/demo4.d.ts +3 -0
- package/dist/types/packages/cell/demos/h5/demo5.d.ts +3 -0
- package/dist/types/packages/cell/demos/h5/demo6.d.ts +3 -0
- package/dist/types/packages/cell/demos/h5/demo7.d.ts +3 -0
- package/dist/types/packages/cell/demos/taro/demo1.d.ts +3 -0
- package/dist/types/packages/cell/demos/taro/demo2.d.ts +3 -0
- package/dist/types/packages/cell/demos/taro/demo3.d.ts +3 -0
- package/dist/types/packages/cell/demos/taro/demo4.d.ts +3 -0
- package/dist/types/packages/cell/demos/taro/demo5.d.ts +3 -0
- package/dist/types/packages/cell/demos/taro/demo6.d.ts +3 -0
- package/dist/types/packages/cell/demos/taro/demo7.d.ts +3 -0
- package/dist/types/packages/checkboxgroup/checkboxgroup.d.ts +1 -0
- package/dist/types/packages/checkboxgroup/checkboxgroup.taro.d.ts +1 -0
- package/dist/types/packages/checkboxgroup/context.d.ts +1 -0
- package/dist/types/packages/configprovider/configprovider.d.ts +1 -0
- package/dist/types/packages/configprovider/configprovider.taro.d.ts +1 -0
- package/dist/types/packages/configprovider/index.d.ts +2 -2
- package/dist/types/packages/configprovider/index.taro.d.ts +2 -2
- package/dist/types/packages/configprovider/types.d.ts +1 -1
- package/dist/types/packages/dialog/config.d.ts +3 -3
- package/dist/types/packages/dialog/index.d.ts +1 -1
- package/dist/types/packages/empty/empty.taro.d.ts +15 -3
- package/dist/types/packages/inputnumber/inputnumber.taro.d.ts +6 -0
- package/dist/types/packages/noticebar/index.d.ts +1 -0
- package/dist/types/packages/noticebar/noticebar.d.ts +2 -0
- package/dist/types/packages/noticebar/noticebar.taro.d.ts +6 -0
- package/dist/types/packages/noticebar/types.d.ts +1 -0
- package/dist/types/packages/popover/index.d.ts +2 -1
- package/dist/types/packages/popover/index.taro.d.ts +2 -1
- package/dist/types/packages/popover/popover.d.ts +2 -12
- package/dist/types/packages/popover/popover.taro.d.ts +2 -12
- package/dist/types/packages/popover/types.d.ts +14 -0
- package/dist/types/packages/table/useTableSticky.d.ts +1 -1
- package/dist/types/packages/toast/toast.taro.d.ts +8 -4
- package/dist/types/packages/tour/tour.d.ts +1 -1
- package/dist/types/packages/tour/tour.taro.d.ts +1 -1
- package/package.json +5 -1
- package/dist/esm/avatar.taro-7ltbzIdY.js +0 -109
- package/dist/esm/configprovider.taro-q5J2gQbi.js +0 -486
- package/dist/esm/formitem.taro-viaUkMmm.js +0 -1435
- package/dist/esm/index-oitVOJp9.js +0 -661
- package/dist/esm/sidenavbaritem.taro-AxJNRAdi.js +0 -13
- package/dist/esm/steps.taro-PH0qWPla.js +0 -32
- package/dist/esm/tabbaritem.taro-t9C07OYX.js +0 -73
- /package/dist/esm/{UserContext-9BL0cq8w.js → UserContext-BlM0373q.js} +0 -0
- /package/dist/esm/{context-6mGEMLsx.js → context-4T-L2x0_.js} +0 -0
- /package/dist/esm/{context-9BL0cq8w.js → context-BlM0373q.js} +0 -0
- /package/dist/esm/{date-nxKOxj5-.js → date-D0pth0qC.js} +0 -0
- /package/dist/esm/{get-scroll-parent-uywvoQMl.js → get-scroll-parent-DB1VRg11.js} +0 -0
- /package/dist/esm/{index-YvHA__3D.js → index-DeNfBlua.js} +0 -0
- /package/dist/esm/{pad-zero-iY-0-oys.js → pad-zero-B2OUQfh7.js} +0 -0
- /package/dist/esm/{px-check-JiWLYN2v.js → px-check-D1Xbd9pj.js} +0 -0
- /package/dist/esm/{raf-UzmDvMUW.js → raf-zwv-SBjP.js} +0 -0
- /package/dist/esm/{safearea.taro-afu_mY7g.js → safearea.taro-BMQHr7tu.js} +0 -0
- /package/dist/esm/{typings-buMpDfSR.js → typings-DV9RBfhj.js} +0 -0
- /package/dist/esm/{use-force-update-0oEVD8Nr.js → use-force-update-CudFjCsy.js} +0 -0
- /package/dist/esm/{use-refs-IdrY0ww3.js → use-refs-BeEmziIR.js} +0 -0
- /package/dist/esm/{use-touch-BUFdkOSA.js → use-touch-OfEaR5qi.js} +0 -0
|
@@ -1,30 +1,18 @@
|
|
|
1
|
+
import { _ as __rest } from "./tslib.es6-BZ8i9Q6l.js";
|
|
1
2
|
import React__default, { useState, useEffect } from "react";
|
|
2
3
|
import { View } from "@tarojs/components";
|
|
3
|
-
import { P as Picker } from "./picker.taro-
|
|
4
|
-
import { u as useConfig } from "./configprovider.taro-
|
|
5
|
-
import { u as usePropsValue } from "./use-props-value-
|
|
6
|
-
import { C as ComponentDefaults } from "./typings-
|
|
7
|
-
import { p as padZero } from "./pad-zero-
|
|
4
|
+
import { P as Picker } from "./picker.taro-Cmng9GW9.js";
|
|
5
|
+
import { u as useConfig } from "./configprovider.taro-CyU_tvNJ.js";
|
|
6
|
+
import { u as usePropsValue } from "./use-props-value-SH9krhkx.js";
|
|
7
|
+
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
8
|
+
import { p as padZero } from "./pad-zero-B2OUQfh7.js";
|
|
8
9
|
const isDate = (val) => {
|
|
9
10
|
return Object.prototype.toString.call(val) === "[object Date]" && !Number.isNaN(val.getTime());
|
|
10
11
|
};
|
|
11
12
|
const currentYear = (/* @__PURE__ */ new Date()).getFullYear();
|
|
12
|
-
const defaultProps = {
|
|
13
|
-
...ComponentDefaults,
|
|
14
|
-
visible: false,
|
|
15
|
-
title: "",
|
|
16
|
-
type: "date",
|
|
17
|
-
showChinese: false,
|
|
18
|
-
threeDimensional: true,
|
|
19
|
-
minuteStep: 1,
|
|
20
|
-
startDate: new Date(currentYear - 10, 0, 1),
|
|
21
|
-
endDate: new Date(currentYear + 10, 11, 31)
|
|
22
|
-
};
|
|
13
|
+
const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { visible: false, title: "", type: "date", showChinese: false, threeDimensional: true, minuteStep: 1, startDate: new Date(currentYear - 10, 0, 1), endDate: new Date(currentYear + 10, 11, 31) });
|
|
23
14
|
const DatePicker = (props) => {
|
|
24
|
-
const { startDate, endDate, type, showChinese, minuteStep, visible, title, defaultValue, pickerProps = {}, formatter, onClose, onCancel, onConfirm, filter, onChange, threeDimensional, className, style,
|
|
25
|
-
...defaultProps,
|
|
26
|
-
...props
|
|
27
|
-
};
|
|
15
|
+
const _a = Object.assign(Object.assign({}, defaultProps), props), { startDate, endDate, type, showChinese, minuteStep, visible, title, defaultValue, pickerProps = {}, formatter, onClose, onCancel, onConfirm, filter, onChange, threeDimensional, className, style } = _a, rest = __rest(_a, ["startDate", "endDate", "type", "showChinese", "minuteStep", "visible", "title", "defaultValue", "pickerProps", "formatter", "onClose", "onCancel", "onConfirm", "filter", "onChange", "threeDimensional", "className", "style"]);
|
|
28
16
|
const { locale } = useConfig();
|
|
29
17
|
const lang = locale.datepicker;
|
|
30
18
|
const zhCNType = {
|
|
@@ -138,7 +126,7 @@ const DatePicker = (props) => {
|
|
|
138
126
|
}
|
|
139
127
|
};
|
|
140
128
|
const handlePickerChange = (selectedOptions, selectedValue, index) => {
|
|
141
|
-
var
|
|
129
|
+
var _a2;
|
|
142
130
|
const rangeType = type.toLocaleLowerCase();
|
|
143
131
|
if (["date", "datetime", "datehour", "month-day", "year-month"].includes(rangeType)) {
|
|
144
132
|
const formatDate = [];
|
|
@@ -162,7 +150,7 @@ const DatePicker = (props) => {
|
|
|
162
150
|
} else if (rangeType === "datehour") {
|
|
163
151
|
date = new Date(year, month, day, Number(formatDate[3]));
|
|
164
152
|
}
|
|
165
|
-
const isEqual = ((
|
|
153
|
+
const isEqual = ((_a2 = new Date(selectedDate)) === null || _a2 === void 0 ? void 0 : _a2.getTime()) === (date === null || date === void 0 ? void 0 : date.getTime());
|
|
166
154
|
date && isDate(date) && !isEqual && setSelectedDate(formatValue(date));
|
|
167
155
|
}
|
|
168
156
|
props.onChange && props.onChange(selectedOptions, selectedValue, index);
|
|
@@ -179,7 +167,7 @@ const DatePicker = (props) => {
|
|
|
179
167
|
return { text: padMin + fatter, value: padMin };
|
|
180
168
|
};
|
|
181
169
|
const generateColumn = (min, max, val, type2, columnIndex) => {
|
|
182
|
-
var
|
|
170
|
+
var _a2;
|
|
183
171
|
let cmin = min;
|
|
184
172
|
const arr = [];
|
|
185
173
|
let index = 0;
|
|
@@ -190,11 +178,11 @@ const DatePicker = (props) => {
|
|
|
190
178
|
} else {
|
|
191
179
|
cmin++;
|
|
192
180
|
}
|
|
193
|
-
if (cmin <= val) {
|
|
181
|
+
if (cmin <= Number(val)) {
|
|
194
182
|
index++;
|
|
195
183
|
}
|
|
196
184
|
}
|
|
197
|
-
pickerValue[columnIndex] = (
|
|
185
|
+
pickerValue[columnIndex] = (_a2 = arr[index]) === null || _a2 === void 0 ? void 0 : _a2.value;
|
|
198
186
|
setPickerValue([...pickerValue]);
|
|
199
187
|
if (props.filter && props.filter(type2, arr)) {
|
|
200
188
|
return props.filter(type2, arr);
|
|
@@ -234,7 +222,7 @@ const DatePicker = (props) => {
|
|
|
234
222
|
useEffect(() => {
|
|
235
223
|
setPickerOptions(columns());
|
|
236
224
|
}, [selectedDate, startDate, endDate]);
|
|
237
|
-
return React__default.createElement(View, { className: `nut-datepicker ${className}`, style, catchMove: true,
|
|
225
|
+
return React__default.createElement(View, Object.assign({ className: `nut-datepicker ${className}`, style, catchMove: true }, rest), pickerOptions.length && React__default.createElement(Picker, Object.assign({}, pickerProps, { title, visible, options: pickerOptions, onClose, onCancel, value: pickerValue, onConfirm: (options, value) => onConfirm && onConfirm(options, value), onChange: (options, value, index) => handlePickerChange(options, value, index), threeDimensional })));
|
|
238
226
|
};
|
|
239
227
|
DatePicker.defaultProps = defaultProps;
|
|
240
228
|
DatePicker.displayName = "NutDatePicker";
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { a as __awaiter } from "./tslib.es6-BZ8i9Q6l.js";
|
|
2
|
+
import React__default, { useState } from "react";
|
|
2
3
|
import classNames from "classnames";
|
|
3
4
|
import { CSSTransition } from "react-transition-group";
|
|
4
5
|
import { View } from "@tarojs/components";
|
|
5
6
|
import { Close } from "@nutui/icons-react-taro";
|
|
6
|
-
import { B as Button } from "./button.taro-
|
|
7
|
-
import { u as useConfig } from "./configprovider.taro-
|
|
8
|
-
import { u as useLockScrollTaro, O as Overlay } from "./overlay.taro-
|
|
9
|
-
import { b as useParams, u as useCustomEvent, a as useCustomEventsPath, c as customEvents } from "./use-custom-event-
|
|
7
|
+
import { B as Button } from "./button.taro-OKGsDVW7.js";
|
|
8
|
+
import { u as useConfig } from "./configprovider.taro-CyU_tvNJ.js";
|
|
9
|
+
import { u as useLockScrollTaro, O as Overlay } from "./overlay.taro-BaBu-3-F.js";
|
|
10
|
+
import { b as useParams, u as useCustomEvent, a as useCustomEventsPath, c as customEvents } from "./use-custom-event-DuP4onEm.js";
|
|
10
11
|
const Content = (props) => {
|
|
11
12
|
const { visible, title, header, footer, close: close2, footerDirection, onClick, children } = props;
|
|
12
13
|
const classPrefix = "nut-dialog";
|
|
@@ -63,12 +64,13 @@ const defaultProps = {
|
|
|
63
64
|
const BaseDialog = (props) => {
|
|
64
65
|
const classPrefix = "nut-dialog";
|
|
65
66
|
const { locale } = useConfig();
|
|
66
|
-
const
|
|
67
|
+
const [loading, setLoading] = useState(false);
|
|
68
|
+
const { params: { id, className, style, visible, footer, title, header, content, children, footerDirection, hideConfirmButton, hideCancelButton, lockScroll, disableConfirmButton, closeOnOverlayClick, onOverlayClick, confirmText, cancelText, overlay, closeIconPosition, closeIcon, onClose, onCancel, onConfirm, beforeCancel, beforeClose }, setParams } = useParams(Object.assign(Object.assign({}, defaultProps), props));
|
|
67
69
|
useCustomEvent(id, ({ status, options }) => {
|
|
68
70
|
if (status) {
|
|
69
|
-
setParams({
|
|
71
|
+
setParams(Object.assign(Object.assign({}, options), { visible: true }));
|
|
70
72
|
} else {
|
|
71
|
-
setParams({
|
|
73
|
+
setParams(Object.assign(Object.assign({}, options), { visible: false }));
|
|
72
74
|
}
|
|
73
75
|
});
|
|
74
76
|
const refObject = useLockScrollTaro(!!(visible && lockScroll));
|
|
@@ -77,37 +79,43 @@ const BaseDialog = (props) => {
|
|
|
77
79
|
return "";
|
|
78
80
|
const handleCancel = (e) => {
|
|
79
81
|
e.stopPropagation();
|
|
80
|
-
if (!(beforeCancel
|
|
82
|
+
if (!(beforeCancel === null || beforeCancel === void 0 ? void 0 : beforeCancel()))
|
|
81
83
|
return;
|
|
82
|
-
if (!(beforeClose
|
|
84
|
+
if (!(beforeClose === null || beforeClose === void 0 ? void 0 : beforeClose()))
|
|
83
85
|
return;
|
|
84
|
-
onClose
|
|
85
|
-
onCancel
|
|
86
|
+
onClose === null || onClose === void 0 ? void 0 : onClose();
|
|
87
|
+
onCancel === null || onCancel === void 0 ? void 0 : onCancel();
|
|
86
88
|
};
|
|
87
|
-
const handleOk = (e) => {
|
|
89
|
+
const handleOk = (e) => __awaiter(void 0, void 0, void 0, function* () {
|
|
88
90
|
e.stopPropagation();
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
91
|
+
setLoading(true);
|
|
92
|
+
try {
|
|
93
|
+
yield onConfirm === null || onConfirm === void 0 ? void 0 : onConfirm(e);
|
|
94
|
+
setLoading(false);
|
|
95
|
+
onClose === null || onClose === void 0 ? void 0 : onClose();
|
|
96
|
+
} catch (_a) {
|
|
97
|
+
setLoading(false);
|
|
98
|
+
}
|
|
99
|
+
});
|
|
92
100
|
return footer || React__default.createElement(
|
|
93
101
|
React__default.Fragment,
|
|
94
102
|
null,
|
|
95
103
|
!hideCancelButton && React__default.createElement(Button, { type: "default", className: `${classPrefix}-footer-cancel`, onClick: (e) => handleCancel(e) }, cancelText || locale.cancel),
|
|
96
104
|
!hideConfirmButton && React__default.createElement(Button, { type: "primary", className: classNames(`${classPrefix}-footer-ok`, {
|
|
97
105
|
disabled: disableConfirmButton
|
|
98
|
-
}), disabled: disableConfirmButton, onClick: (e) => handleOk(e) }, confirmText || locale.confirm)
|
|
106
|
+
}), disabled: disableConfirmButton, onClick: (e) => handleOk(e), loading }, confirmText || locale.confirm)
|
|
99
107
|
);
|
|
100
108
|
};
|
|
101
109
|
const renderCloseIcon = () => {
|
|
102
110
|
if (!closeIcon)
|
|
103
111
|
return null;
|
|
104
112
|
const handleCancel = () => {
|
|
105
|
-
if (!(beforeCancel
|
|
113
|
+
if (!(beforeCancel === null || beforeCancel === void 0 ? void 0 : beforeCancel()))
|
|
106
114
|
return;
|
|
107
|
-
if (!(beforeClose
|
|
115
|
+
if (!(beforeClose === null || beforeClose === void 0 ? void 0 : beforeClose()))
|
|
108
116
|
return;
|
|
109
|
-
onClose
|
|
110
|
-
onCancel
|
|
117
|
+
onClose === null || onClose === void 0 ? void 0 : onClose();
|
|
118
|
+
onCancel === null || onCancel === void 0 ? void 0 : onCancel();
|
|
111
119
|
};
|
|
112
120
|
const closeClasses = classNames({
|
|
113
121
|
[`${classPrefix}-close`]: true,
|
|
@@ -118,8 +126,8 @@ const BaseDialog = (props) => {
|
|
|
118
126
|
const onHandleClickOverlay = (e) => {
|
|
119
127
|
if (closeOnOverlayClick && visible && e.target === e.currentTarget) {
|
|
120
128
|
const closed = onOverlayClick && onOverlayClick();
|
|
121
|
-
closed && (onClose
|
|
122
|
-
closed && (onCancel
|
|
129
|
+
closed && (onClose === null || onClose === void 0 ? void 0 : onClose());
|
|
130
|
+
closed && (onCancel === null || onCancel === void 0 ? void 0 : onCancel());
|
|
123
131
|
}
|
|
124
132
|
};
|
|
125
133
|
return React__default.createElement(
|
|
@@ -1,17 +1,11 @@
|
|
|
1
|
+
import { _ as __rest } from "./tslib.es6-BZ8i9Q6l.js";
|
|
1
2
|
import React__default from "react";
|
|
2
3
|
import classNames from "classnames";
|
|
3
|
-
import { C as ComponentDefaults } from "./typings-
|
|
4
|
-
const defaultProps = {
|
|
5
|
-
...ComponentDefaults,
|
|
6
|
-
contentPosition: "center",
|
|
7
|
-
direction: "horizontal"
|
|
8
|
-
};
|
|
4
|
+
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
5
|
+
const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { contentPosition: "center", direction: "horizontal" });
|
|
9
6
|
const classPrefix = `nut-divider`;
|
|
10
7
|
const Divider = (props) => {
|
|
11
|
-
const { children, contentPosition, style, className, direction,
|
|
12
|
-
...defaultProps,
|
|
13
|
-
...props
|
|
14
|
-
};
|
|
8
|
+
const _a = Object.assign(Object.assign({}, defaultProps), props), { children, contentPosition, style, className, direction } = _a, rest = __rest(_a, ["children", "contentPosition", "style", "className", "direction"]);
|
|
15
9
|
const classes = direction === "horizontal" ? classNames({
|
|
16
10
|
[`${classPrefix}`]: true,
|
|
17
11
|
[`${classPrefix}-center`]: children,
|
|
@@ -22,7 +16,7 @@ const Divider = (props) => {
|
|
|
22
16
|
[`${classPrefix}`]: true,
|
|
23
17
|
[`${classPrefix}-vertical`]: direction === "vertical"
|
|
24
18
|
});
|
|
25
|
-
return React__default.createElement("div", { className: `${classes} ${className || ""}`, style,
|
|
19
|
+
return React__default.createElement("div", Object.assign({ className: `${classes} ${className || ""}`, style }, rest), children);
|
|
26
20
|
};
|
|
27
21
|
Divider.defaultProps = defaultProps;
|
|
28
22
|
Divider.displayName = "NutDivider";
|
|
@@ -1,23 +1,15 @@
|
|
|
1
|
+
import { _ as __rest } from "./tslib.es6-BZ8i9Q6l.js";
|
|
1
2
|
import React__default, { useState, useRef, useEffect } from "react";
|
|
2
3
|
import { getSystemInfoSync, createSelectorQuery } from "@tarojs/taro";
|
|
3
|
-
import { C as ComponentDefaults } from "./typings-
|
|
4
|
-
const defaultProps = {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
left: 0,
|
|
11
|
-
right: 0,
|
|
12
|
-
bottom: 0
|
|
13
|
-
},
|
|
14
|
-
className: "myDrag"
|
|
15
|
-
};
|
|
4
|
+
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
5
|
+
const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { attract: false, direction: void 0, boundary: {
|
|
6
|
+
top: 0,
|
|
7
|
+
left: 0,
|
|
8
|
+
right: 0,
|
|
9
|
+
bottom: 0
|
|
10
|
+
}, className: "myDrag" });
|
|
16
11
|
const Drag = (props) => {
|
|
17
|
-
const { attract, direction, boundary, children, className, style,
|
|
18
|
-
...defaultProps,
|
|
19
|
-
...props
|
|
20
|
-
};
|
|
12
|
+
const _a = Object.assign(Object.assign({}, defaultProps), props), { attract, direction, boundary, children, className, style } = _a, reset = __rest(_a, ["attract", "direction", "boundary", "children", "className", "style"]);
|
|
21
13
|
const classPrefix = "nut-drag";
|
|
22
14
|
const [boundaryState, setBoundaryState] = useState(boundary);
|
|
23
15
|
const myDrag = useRef(null);
|
|
@@ -93,7 +85,7 @@ const Drag = (props) => {
|
|
|
93
85
|
}, []);
|
|
94
86
|
return React__default.createElement(
|
|
95
87
|
"div",
|
|
96
|
-
{ style, className: `${classPrefix} ${className}
|
|
88
|
+
Object.assign({ style, className: `${classPrefix} ${className}` }, reset, { ref: myDrag }),
|
|
97
89
|
React__default.createElement("div", {
|
|
98
90
|
onTouchStart: (event) => touchStart(event),
|
|
99
91
|
ref: dragRef,
|
|
@@ -1,25 +1,13 @@
|
|
|
1
|
+
import { _ as __rest } from "./tslib.es6-BZ8i9Q6l.js";
|
|
1
2
|
import React__default, { createContext, useRef, useState, useEffect } from "react";
|
|
2
3
|
import Taro, { nextTick, createSelectorQuery } from "@tarojs/taro";
|
|
3
4
|
import { ScrollView } from "@tarojs/components";
|
|
4
5
|
import classNames from "classnames";
|
|
5
|
-
import { C as ComponentDefaults } from "./typings-
|
|
6
|
+
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
6
7
|
const elevatorContext = createContext({});
|
|
7
|
-
const defaultProps = {
|
|
8
|
-
...ComponentDefaults,
|
|
9
|
-
height: "200px",
|
|
10
|
-
floorKey: "title",
|
|
11
|
-
list: [],
|
|
12
|
-
sticky: false,
|
|
13
|
-
spaceHeight: 23,
|
|
14
|
-
titleHeight: 35,
|
|
15
|
-
showKeys: true,
|
|
16
|
-
className: "weapp-elevator"
|
|
17
|
-
};
|
|
8
|
+
const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { height: "200px", floorKey: "title", list: [], sticky: false, spaceHeight: 23, titleHeight: 35, showKeys: true, className: "weapp-elevator" });
|
|
18
9
|
const Elevator = (props) => {
|
|
19
|
-
const { height, floorKey, list, sticky, spaceHeight, titleHeight, showKeys, className, style, onItemClick, onIndexClick, children,
|
|
20
|
-
...defaultProps,
|
|
21
|
-
...props
|
|
22
|
-
};
|
|
10
|
+
const _a = Object.assign(Object.assign({}, defaultProps), props), { height, floorKey, list, sticky, spaceHeight, titleHeight, showKeys, className, style, onItemClick, onIndexClick, children } = _a, rest = __rest(_a, ["height", "floorKey", "list", "sticky", "spaceHeight", "titleHeight", "showKeys", "className", "style", "onItemClick", "onIndexClick", "children"]);
|
|
23
11
|
const classPrefix = "nut-elevator";
|
|
24
12
|
const listview = useRef(null);
|
|
25
13
|
const initData = {
|
|
@@ -151,7 +139,7 @@ const Elevator = (props) => {
|
|
|
151
139
|
}, [listview]);
|
|
152
140
|
return React__default.createElement(
|
|
153
141
|
"div",
|
|
154
|
-
{ className: `${classPrefix} ${className}`, style,
|
|
142
|
+
Object.assign({ className: `${classPrefix} ${className}`, style }, rest),
|
|
155
143
|
React__default.createElement(
|
|
156
144
|
"div",
|
|
157
145
|
{ className: `${classPrefix}-list`, style: { height: Number.isNaN(+height) ? height : `${height}px` } },
|
|
@@ -1,24 +1,15 @@
|
|
|
1
|
+
import { _ as __rest, a as __awaiter } from "./tslib.es6-BZ8i9Q6l.js";
|
|
1
2
|
import React__default, { useRef, useState, useEffect } from "react";
|
|
2
3
|
import { nextTick, createSelectorQuery } from "@tarojs/taro";
|
|
3
4
|
import classNames from "classnames";
|
|
4
5
|
import { View } from "@tarojs/components";
|
|
5
|
-
import { g as getRectByTaro } from "./get-rect-by-taro-
|
|
6
|
-
import { C as ComponentDefaults } from "./typings-
|
|
7
|
-
const defaultProps = {
|
|
8
|
-
...ComponentDefaults,
|
|
9
|
-
content: "",
|
|
10
|
-
direction: "end",
|
|
11
|
-
rows: 1,
|
|
12
|
-
expandText: "",
|
|
13
|
-
collapseText: "",
|
|
14
|
-
symbol: "...",
|
|
15
|
-
lineHeight: "20",
|
|
16
|
-
width: "auto"
|
|
17
|
-
};
|
|
6
|
+
import { g as getRectByTaro } from "./get-rect-by-taro-CSN0TGnD.js";
|
|
7
|
+
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
8
|
+
const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { content: "", direction: "end", rows: 1, expandText: "", collapseText: "", symbol: "...", lineHeight: "20", width: "auto" });
|
|
18
9
|
const classPrefix = `nut-ellipsis`;
|
|
19
10
|
const Ellipsis = (props) => {
|
|
20
11
|
var _a, _b, _c, _d;
|
|
21
|
-
const { children, content, direction, rows, className, expandText, collapseText, symbol, lineHeight, width, onClick, onChange,
|
|
12
|
+
const _e = Object.assign(Object.assign({}, defaultProps), props), { children, content, direction, rows, className, expandText, collapseText, symbol, lineHeight, width, onClick, onChange } = _e, rest = __rest(_e, ["children", "content", "direction", "rows", "className", "expandText", "collapseText", "symbol", "lineHeight", "width", "onClick", "onChange"]);
|
|
22
13
|
const maxHeight = useRef(0);
|
|
23
14
|
const [exceeded, setExceeded] = useState(false);
|
|
24
15
|
const [expanded, setExpanded] = useState(false);
|
|
@@ -48,17 +39,17 @@ const Ellipsis = (props) => {
|
|
|
48
39
|
getReference();
|
|
49
40
|
});
|
|
50
41
|
}, [content]);
|
|
51
|
-
const getSymbolInfo =
|
|
52
|
-
const refe =
|
|
42
|
+
const getSymbolInfo = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
43
|
+
const refe = yield getRectByTaro(symbolContain === null || symbolContain === void 0 ? void 0 : symbolContain.current);
|
|
53
44
|
symbolTextWidth.current = refe.width ? Math.ceil(refe.width) : Math.ceil(widthBase.current[0] * 0.7921);
|
|
54
|
-
};
|
|
45
|
+
});
|
|
55
46
|
const symbolText = () => {
|
|
56
47
|
if (direction === "end" || direction === "middle") {
|
|
57
48
|
return `${symbol}${expandText}`;
|
|
58
49
|
}
|
|
59
50
|
return `${symbol}${expandText}${symbol}`;
|
|
60
51
|
};
|
|
61
|
-
const getReference =
|
|
52
|
+
const getReference = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
62
53
|
const query = createSelectorQuery();
|
|
63
54
|
query.select(`#root${refRandomId.current}`) && query.select(`#root${refRandomId.current}`).fields({
|
|
64
55
|
computedStyle: [
|
|
@@ -86,9 +77,9 @@ const Ellipsis = (props) => {
|
|
|
86
77
|
];
|
|
87
78
|
calcEllipse();
|
|
88
79
|
}).exec();
|
|
89
|
-
};
|
|
90
|
-
const calcEllipse =
|
|
91
|
-
const refe =
|
|
80
|
+
});
|
|
81
|
+
const calcEllipse = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
82
|
+
const refe = yield getRectByTaro(rootContain.current);
|
|
92
83
|
if (refe.height <= maxHeight.current) {
|
|
93
84
|
setExceeded(false);
|
|
94
85
|
} else {
|
|
@@ -109,25 +100,25 @@ const Ellipsis = (props) => {
|
|
|
109
100
|
verifyEllipsis();
|
|
110
101
|
}, 100);
|
|
111
102
|
}
|
|
112
|
-
};
|
|
113
|
-
const verifyEllipsis =
|
|
114
|
-
var
|
|
115
|
-
const refe =
|
|
103
|
+
});
|
|
104
|
+
const verifyEllipsis = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
105
|
+
var _f, _g, _h, _j, _k, _l, _m;
|
|
106
|
+
const refe = yield getRectByTaro(rootContain.current);
|
|
116
107
|
if (refe && refe.height && refe.height > maxHeight.current) {
|
|
117
108
|
if (direction === "end") {
|
|
118
|
-
ellipsis.current.leading = (
|
|
109
|
+
ellipsis.current.leading = (_g = (_f = ellipsis.current) === null || _f === void 0 ? void 0 : _f.leading) === null || _g === void 0 ? void 0 : _g.slice(0, (((_j = (_h = ellipsis.current) === null || _h === void 0 ? void 0 : _h.leading) === null || _j === void 0 ? void 0 : _j.length) || 0) - 1);
|
|
119
110
|
} else {
|
|
120
|
-
ellipsis.current.tailing = (
|
|
111
|
+
ellipsis.current.tailing = (_l = (_k = ellipsis.current) === null || _k === void 0 ? void 0 : _k.tailing) === null || _l === void 0 ? void 0 : _l.slice(1, (_m = ellipsis.current) === null || _m === void 0 ? void 0 : _m.tailing.length);
|
|
121
112
|
}
|
|
122
113
|
assignContent();
|
|
123
114
|
setTimeout(() => {
|
|
124
115
|
verifyEllipsis();
|
|
125
116
|
}, 100);
|
|
126
117
|
}
|
|
127
|
-
};
|
|
118
|
+
});
|
|
128
119
|
const assignContent = () => {
|
|
129
120
|
var _a2, _b2, _c2, _d2;
|
|
130
|
-
const newContent = `${((_a2 = ellipsis.current)
|
|
121
|
+
const newContent = `${((_a2 = ellipsis.current) === null || _a2 === void 0 ? void 0 : _a2.leading) || ""}${((_b2 = ellipsis.current) === null || _b2 === void 0 ? void 0 : _b2.leading) ? symbol : ""}${expandText || ""}${((_c2 = ellipsis.current) === null || _c2 === void 0 ? void 0 : _c2.tailing) ? symbol : ""}${((_d2 = ellipsis.current) === null || _d2 === void 0 ? void 0 : _d2.tailing) || ""}`;
|
|
131
122
|
setContentCopy(newContent);
|
|
132
123
|
};
|
|
133
124
|
const tailorContent = (left, right, type = "") => {
|
|
@@ -192,7 +183,7 @@ const Ellipsis = (props) => {
|
|
|
192
183
|
null,
|
|
193
184
|
React__default.createElement(
|
|
194
185
|
"div",
|
|
195
|
-
{ className: classes, onClick: handleClick, ref: root, id: `root${refRandomId.current}
|
|
186
|
+
Object.assign({ className: classes, onClick: handleClick, ref: root, id: `root${refRandomId.current}` }, rest),
|
|
196
187
|
React__default.createElement(
|
|
197
188
|
View,
|
|
198
189
|
null,
|
|
@@ -206,14 +197,14 @@ const Ellipsis = (props) => {
|
|
|
206
197
|
{ className: "nut-ellipsis-wordbreak", style: {
|
|
207
198
|
width: `${!Number.isNaN(Number(width)) ? `${width}px` : "auto"}`
|
|
208
199
|
} },
|
|
209
|
-
(_a = ellipsis.current)
|
|
210
|
-
((_b = ellipsis.current)
|
|
200
|
+
(_a = ellipsis.current) === null || _a === void 0 ? void 0 : _a.leading,
|
|
201
|
+
((_b = ellipsis.current) === null || _b === void 0 ? void 0 : _b.leading) && symbol,
|
|
211
202
|
expandText ? React__default.createElement("span", { className: "nut-ellipsis-text", onClick: (e) => {
|
|
212
203
|
e.stopPropagation();
|
|
213
204
|
clickHandle(1);
|
|
214
205
|
} }, expandText) : null,
|
|
215
|
-
((_c = ellipsis.current)
|
|
216
|
-
(_d = ellipsis.current)
|
|
206
|
+
((_c = ellipsis.current) === null || _c === void 0 ? void 0 : _c.tailing) && symbol,
|
|
207
|
+
(_d = ellipsis.current) === null || _d === void 0 ? void 0 : _d.tailing
|
|
217
208
|
) : null,
|
|
218
209
|
exceeded && expanded ? React__default.createElement(
|
|
219
210
|
React__default.Fragment,
|
|
@@ -1,29 +1,19 @@
|
|
|
1
|
+
import { _ as __rest } from "./tslib.es6-BZ8i9Q6l.js";
|
|
1
2
|
import React__default, { useState, useEffect } from "react";
|
|
2
3
|
import classNames from "classnames";
|
|
3
|
-
import { u as useConfig } from "./configprovider.taro-
|
|
4
|
-
import { C as ComponentDefaults } from "./typings-
|
|
5
|
-
import { B as Button } from "./button.taro-
|
|
4
|
+
import { u as useConfig } from "./configprovider.taro-CyU_tvNJ.js";
|
|
5
|
+
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
6
|
+
import { B as Button } from "./button.taro-OKGsDVW7.js";
|
|
6
7
|
const defaultStatus = {
|
|
7
8
|
empty: "https://static-ftcms.jd.com/p/files/61a9e3183985005b3958672b.png",
|
|
8
9
|
error: "https://ftcms.jd.com/p/files/61a9e33ee7dcdbcc0ce62736.png",
|
|
9
10
|
network: "https://static-ftcms.jd.com/p/files/61a9e31de7dcdbcc0ce62734.png"
|
|
10
11
|
};
|
|
11
|
-
const defaultProps = {
|
|
12
|
-
...ComponentDefaults,
|
|
13
|
-
title: "",
|
|
14
|
-
description: "",
|
|
15
|
-
imageSize: "",
|
|
16
|
-
size: "base",
|
|
17
|
-
status: "empty",
|
|
18
|
-
actions: []
|
|
19
|
-
};
|
|
12
|
+
const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { title: "", description: "", imageSize: "", size: "base", status: "empty", actions: [] });
|
|
20
13
|
const classPrefix = `nut-empty`;
|
|
21
14
|
const Empty = (props) => {
|
|
22
15
|
useConfig();
|
|
23
|
-
const { image, imageSize, title, description, children, className, size, status, actions,
|
|
24
|
-
...defaultProps,
|
|
25
|
-
...props
|
|
26
|
-
};
|
|
16
|
+
const _a = Object.assign(Object.assign({}, defaultProps), props), { image, imageSize, title, description, children, className, size, status, actions } = _a, rest = __rest(_a, ["image", "imageSize", "title", "description", "children", "className", "size", "status", "actions"]);
|
|
27
17
|
const [imgStyle, setImgStyle] = useState({});
|
|
28
18
|
const imageUrl = image || defaultStatus[status];
|
|
29
19
|
const imageNode = typeof imageUrl === "string" ? React__default.createElement("img", { className: "img", src: imageUrl, alt: "empty" }) : imageUrl;
|
|
@@ -50,7 +40,7 @@ const Empty = (props) => {
|
|
|
50
40
|
const cls = classNames(classPrefix, classes, className);
|
|
51
41
|
return React__default.createElement(
|
|
52
42
|
"div",
|
|
53
|
-
{ className: cls,
|
|
43
|
+
Object.assign({ className: cls }, rest),
|
|
54
44
|
React__default.createElement("div", { className: `${classPrefix}-image`, style: imgStyle }, imageNode),
|
|
55
45
|
typeof title === "string" && title ? React__default.createElement("div", { className: `${classPrefix}-title` }, title) : title,
|
|
56
46
|
typeof description === "string" ? React__default.createElement("div", { className: `${classPrefix}-description` }, description) : description,
|
|
@@ -58,7 +48,7 @@ const Empty = (props) => {
|
|
|
58
48
|
return React__default.createElement(Button, { className: classNames({
|
|
59
49
|
[`${classPrefix}-actions-right`]: actions.length === 1,
|
|
60
50
|
[`${classPrefix}-actions-left`]: actions.length > 1 && index === 0
|
|
61
|
-
}), type: `${actions.length > 1 && index === 0 ? "default" : "primary"}`, size: "small", fill: "outline", key: `action-${index}` }, item
|
|
51
|
+
}), type: `${actions.length > 1 && index === 0 ? "default" : "primary"}`, size: "small", fill: "outline", key: `action-${index}` }, item === null || item === void 0 ? void 0 : item.text);
|
|
62
52
|
})),
|
|
63
53
|
children
|
|
64
54
|
);
|
|
@@ -1,25 +1,17 @@
|
|
|
1
|
+
import { _ as __rest } from "./tslib.es6-BZ8i9Q6l.js";
|
|
1
2
|
import React__default from "react";
|
|
2
3
|
import classNames from "classnames";
|
|
3
4
|
import { ArrowLeft } from "@nutui/icons-react-taro";
|
|
4
|
-
import { O as Overlay } from "./overlay.taro-
|
|
5
|
-
import { u as useConfig } from "./configprovider.taro-
|
|
6
|
-
import { C as ComponentDefaults } from "./typings-
|
|
7
|
-
const defaultProps = {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
type: "right",
|
|
12
|
-
position: {
|
|
13
|
-
top: "auto",
|
|
14
|
-
bottom: "auto"
|
|
15
|
-
}
|
|
16
|
-
};
|
|
5
|
+
import { O as Overlay } from "./overlay.taro-BaBu-3-F.js";
|
|
6
|
+
import { u as useConfig } from "./configprovider.taro-CyU_tvNJ.js";
|
|
7
|
+
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
8
|
+
const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { activeText: "", inactiveText: "", type: "right", position: {
|
|
9
|
+
top: "auto",
|
|
10
|
+
bottom: "auto"
|
|
11
|
+
} });
|
|
17
12
|
const FixedNav = (props) => {
|
|
18
13
|
const { locale } = useConfig();
|
|
19
|
-
const { className, overlay, visible, list, activeText, inactiveText, position, onChange, onSelect, type, children, style, content,
|
|
20
|
-
...defaultProps,
|
|
21
|
-
...props
|
|
22
|
-
};
|
|
14
|
+
const _a = Object.assign(Object.assign({}, defaultProps), props), { className, overlay, visible, list, activeText, inactiveText, position, onChange, onSelect, type, children, style, content } = _a, rest = __rest(_a, ["className", "overlay", "visible", "list", "activeText", "inactiveText", "position", "onChange", "onSelect", "type", "children", "style", "content"]);
|
|
23
15
|
const classPrefix = "nut-fixednav";
|
|
24
16
|
const classes = classNames(classPrefix, {
|
|
25
17
|
active: visible
|
|
@@ -32,10 +24,7 @@ const FixedNav = (props) => {
|
|
|
32
24
|
};
|
|
33
25
|
return React__default.createElement(
|
|
34
26
|
"div",
|
|
35
|
-
{ className: classes, style: {
|
|
36
|
-
...position,
|
|
37
|
-
...style
|
|
38
|
-
}, ...rest },
|
|
27
|
+
Object.assign({ className: classes, style: Object.assign(Object.assign({}, position), style) }, rest),
|
|
39
28
|
overlay && React__default.createElement(Overlay, { visible, style: { "--nutui-overlay-zIndex": 200 }, onClick: () => onUpdateValue(false) }),
|
|
40
29
|
React__default.createElement("div", { className: "list" }, children || React__default.createElement("div", { className: `${classPrefix}-list` }, list.map((item, index) => {
|
|
41
30
|
return React__default.createElement(
|