@nutui/nutui-react-taro 2.6.9 → 2.6.11
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 +19 -0
- package/dist/esm/ActionSheet.js +1 -1
- package/dist/esm/Address/style/style.css +1 -1
- package/dist/esm/Address.js +1 -1
- package/dist/esm/Animate/style/style.css +1 -1
- package/dist/esm/Animate.js +1 -1
- package/dist/esm/AnimatingNumbers.js +1 -1
- package/dist/esm/Audio/style/style.css +1 -1
- package/dist/esm/Audio.js +1 -1
- package/dist/esm/Avatar.js +1 -1
- package/dist/esm/AvatarCropper.js +1 -1
- package/dist/esm/BackTop.js +1 -1
- package/dist/esm/Badge.js +1 -1
- package/dist/esm/Barrage.js +1 -1
- package/dist/esm/Button.js +1 -1
- package/dist/esm/Calendar.js +1 -1
- package/dist/esm/CalendarCard.js +1 -1
- package/dist/esm/CalendarItem.js +1 -1
- package/dist/esm/Card.js +1 -1
- package/dist/esm/Cascader/style/style.css +1 -1
- package/dist/esm/Cascader.js +1 -1
- package/dist/esm/Cell.js +1 -1
- package/dist/esm/CellGroup.js +1 -1
- package/dist/esm/Checkbox.js +1 -1
- package/dist/esm/CheckboxGroup.js +1 -1
- package/dist/esm/CircleProgress.js +1 -1
- package/dist/esm/Collapse.js +1 -1
- package/dist/esm/CollapseItem.js +1 -1
- package/dist/esm/ConfigProvider.js +2 -2
- package/dist/esm/CountDown.js +1 -1
- package/dist/esm/DatePicker.js +1 -1
- package/dist/esm/Dialog.js +1 -1
- package/dist/esm/Divider.js +1 -1
- package/dist/esm/Drag.js +1 -1
- package/dist/esm/Elevator.js +1 -1
- package/dist/esm/Ellipsis.js +1 -1
- package/dist/esm/Empty.js +1 -1
- package/dist/esm/FixedNav/style/style.css +1 -1
- package/dist/esm/FixedNav.js +1 -1
- package/dist/esm/Form.js +2 -2
- package/dist/esm/FormItem.js +1 -1
- package/dist/esm/Grid.js +1 -1
- package/dist/esm/GridItem.js +1 -1
- package/dist/esm/Image.js +1 -1
- package/dist/esm/ImagePreview.js +1 -1
- package/dist/esm/Indicator.js +1 -1
- package/dist/esm/InfiniteLoading.js +1 -1
- package/dist/esm/Input.js +1 -1
- package/dist/esm/InputNumber.js +1 -1
- package/dist/esm/Loading.js +1 -1
- package/dist/esm/Menu.js +1 -1
- package/dist/esm/MenuItem.js +1 -1
- package/dist/esm/NavBar.js +1 -1
- package/dist/esm/NoticeBar.js +1 -1
- package/dist/esm/NumberKeyboard.js +1 -1
- package/dist/esm/Overlay.js +1 -1
- package/dist/esm/Pagination/style/style.css +1 -1
- package/dist/esm/Pagination.js +1 -1
- package/dist/esm/Picker.js +1 -1
- package/dist/esm/Popover.js +1 -1
- package/dist/esm/Popup.js +1 -1
- package/dist/esm/Price.js +1 -1
- package/dist/esm/Progress/style/style.css +1 -1
- package/dist/esm/Progress.js +1 -1
- package/dist/esm/PullToRefresh.js +1 -1
- package/dist/esm/Radio.js +1 -1
- package/dist/esm/RadioGroup.js +1 -1
- package/dist/esm/Range.js +1 -1
- package/dist/esm/Rate.js +1 -1
- package/dist/esm/SearchBar.js +1 -1
- package/dist/esm/ShortPassword/style/style.css +1 -1
- package/dist/esm/ShortPassword.js +1 -1
- package/dist/esm/SideNavBar.js +1 -1
- package/dist/esm/SideNavBarItem.js +1 -1
- package/dist/esm/Signature.js +1 -1
- package/dist/esm/Skeleton/style/style.css +1 -1
- package/dist/esm/Skeleton.js +1 -1
- package/dist/esm/Step.js +1 -1
- package/dist/esm/Steps.js +1 -1
- package/dist/esm/Sticky.js +1 -1
- package/dist/esm/SubSideNavBar.js +1 -1
- package/dist/esm/Swipe.js +1 -1
- package/dist/esm/Swiper.js +3 -3
- package/dist/esm/SwiperItem.js +1 -1
- package/dist/esm/Switch.js +1 -1
- package/dist/esm/TabPane/style/style.css +1 -1
- package/dist/esm/Tabbar.js +1 -1
- package/dist/esm/TabbarItem.js +1 -1
- package/dist/esm/Table.js +1 -1
- package/dist/esm/Tabs/style/style.css +1 -1
- package/dist/esm/Tabs.js +1 -1
- package/dist/esm/TextArea.js +1 -1
- package/dist/esm/TimeSelect.js +1 -1
- package/dist/esm/Toast.js +1 -1
- package/dist/esm/Tour.js +1 -1
- package/dist/esm/TrendArrow.js +1 -1
- package/dist/esm/Uploader/style/style.css +1 -1
- package/dist/esm/Uploader.js +1 -1
- package/dist/esm/Video.js +1 -1
- package/dist/esm/VirtualList.js +1 -1
- package/dist/esm/WaterMark.js +1 -1
- package/dist/esm/{actionsheet.taro-Cla34tFO.js → actionsheet.taro-CJjNsNrH.js} +2 -2
- package/dist/esm/{address.taro-D0tjP5C1.js → address.taro-CtVpobLw.js} +4 -4
- package/dist/esm/{animate.taro-D-A6ORRZ.js → animate.taro-CQVEyDKL.js} +1 -1
- package/dist/esm/{audio.taro-BlniN99d.js → audio.taro-DzSc40G9.js} +4 -4
- package/dist/esm/{avatar.taro-Dx8hhvFI.js → avatar.taro-DSL3ErmC.js} +2 -2
- package/dist/esm/{avatarcropper.taro-D6yiXZM5.js → avatarcropper.taro-R3OfWq1H.js} +2 -2
- package/dist/esm/{backtop.taro-YeEY7i4O.js → backtop.taro-jWlJ1ZWG.js} +1 -1
- package/dist/esm/{badge.taro-DK_UFQ5Y.js → badge.taro-BGaxpEYi.js} +1 -1
- package/dist/esm/{barrage.taro-DEJGSmY5.js → barrage.taro-CA-9uADD.js} +3 -3
- package/dist/esm/{button.taro-KHyp8jxX.js → button.taro-1kEru6r9.js} +1 -1
- package/dist/esm/{calendar.taro-CDZqFYlk.js → calendar.taro-DN6uEJw-.js} +4 -4
- package/dist/esm/{calendarcard.taro-CHDg3k5D.js → calendarcard.taro-CbvCWF1k.js} +2 -2
- package/dist/esm/{calendaritem.taro-DuEKmnsT.js → calendaritem.taro-CiGznRkW.js} +4 -6
- package/dist/esm/{card.taro-CC0SLA0p.js → card.taro-DxcIi5qH.js} +2 -2
- package/dist/esm/{cascader.taro-c6WPcYsc.js → cascader.taro-y9_hSUSJ.js} +3 -3
- package/dist/esm/{cell.taro-kOgCGbyn.js → cell.taro-CVFlcls2.js} +2 -2
- package/dist/esm/{cellgroup.taro-BskBIgql.js → cellgroup.taro-DTLGMR_c.js} +1 -1
- package/dist/esm/{checkbox.taro-DOSOI351.js → checkbox.taro-Dc054oRo.js} +3 -4
- package/dist/esm/{circleprogress.taro-BuVTD1iY.js → circleprogress.taro-BTRyQG5T.js} +1 -1
- package/dist/esm/{collapse.taro-CxDgckv5.js → collapse.taro-wqL6MWZr.js} +1 -1
- package/dist/esm/{collapseitem.taro-BY06WWvK.js → collapseitem.taro-DjUx5Nx8.js} +1 -1
- package/dist/esm/{configprovider.taro-CyU_tvNJ.js → configprovider.taro-DA4GDDFu.js} +1 -1
- package/dist/esm/{countdown.taro-CdEiAwr5.js → countdown.taro-mKXeisK0.js} +2 -2
- package/dist/esm/{date-D0pth0qC.js → date-CYwRNlGq.js} +1 -4
- package/dist/esm/{datepicker.taro-CcP4XLtj.js → datepicker.taro-DTyJrlhD.js} +3 -3
- package/dist/esm/{dialog.taro-jZ6_EUiF.js → dialog.taro-BW9D2Gsr.js} +4 -4
- package/dist/esm/{divider.taro-CijVuCyt.js → divider.taro-BuVR5t2X.js} +1 -1
- package/dist/esm/{drag.taro-CBNVFciU.js → drag.taro-CI7ZFwaM.js} +2 -2
- package/dist/esm/{elevator.taro-BzVoaYw6.js → elevator.taro-Bsc8PcT0.js} +1 -1
- package/dist/esm/{ellipsis.taro-dxOx8h7S.js → ellipsis.taro-cMTr1Wcw.js} +3 -3
- package/dist/esm/{empty.taro-ek_1_FoA.js → empty.taro-CnwDznke.js} +3 -3
- package/dist/esm/{fixednav.taro-CewDiT-u.js → fixednav.taro-D3KnhYoI.js} +3 -3
- package/dist/esm/{formitem.taro-CAib1i9_.js → formitem.taro-tLWeQ0P5.js} +2 -2
- package/dist/esm/{get-rect-by-taro-CSN0TGnD.js → get-rect-by-taro-THaHH07X.js} +1 -1
- package/dist/esm/{grid.taro-C4xSMhg4.js → grid.taro-ZJywVaVe.js} +2 -2
- package/dist/esm/{griditem.taro-DeXl7qNi.js → griditem.taro-CcWyYchl.js} +2 -2
- package/dist/esm/{image.taro-ESa7sdbM.js → image.taro-CyF6ujA7.js} +1 -1
- package/dist/esm/{imagepreview.taro-CBT7aS3-.js → imagepreview.taro-B7eJN5Hn.js} +3 -3
- package/dist/esm/{indicator.taro-Bmae9MdC.js → indicator.taro-k8bxJf86.js} +1 -1
- package/dist/esm/{infiniteloading.taro-Bnm-LVHC.js → infiniteloading.taro-g1RbqnSS.js} +2 -2
- package/dist/esm/{input.taro-CLMPZ7Wg.js → input.taro-B_B1lJq2.js} +2 -2
- package/dist/esm/{inputnumber.taro-CzuJKfES.js → inputnumber.taro-WN5Drnyz.js} +1 -1
- package/dist/esm/{loading.taro-BfHqvYhy.js → loading.taro-n_qoNgCW.js} +1 -1
- package/dist/esm/{menu.taro-DkKY62ym.js → menu.taro-JDg_-XpO.js} +2 -2
- package/dist/esm/{menuitem.taro-CKjl8_Cl.js → menuitem.taro-BFfGgTms.js} +3 -3
- package/dist/esm/{navbar.taro-COrKuU9p.js → navbar.taro-Dea0-s9Q.js} +2 -2
- package/dist/esm/{noticebar.taro-cjVGemZE.js → noticebar.taro-CGUTg60Q.js} +3 -3
- package/dist/esm/{numberkeyboard.taro-CFJtMOew.js → numberkeyboard.taro-BA0iCeGP.js} +3 -3
- package/dist/esm/nutui-react.es.js +83 -83
- package/dist/esm/{overlay.taro-BJ3twlP0.js → overlay.taro-C2t82CZz.js} +1 -1
- package/dist/esm/{pagination.taro-B8hmHNgf.js → pagination.taro-DdLO3OTc.js} +2 -2
- package/dist/esm/{picker.taro-D3G6mJ-I.js → picker.taro-CafNRRO5.js} +11 -14
- package/dist/esm/{popover.taro-Dve2UnRF.js → popover.taro-B_FJgU0z.js} +4 -4
- package/dist/esm/{popup.taro-cT6cbAxw.js → popup.taro-CR3JyuJV.js} +1 -1
- package/dist/esm/{price.taro-DdR5NSIA.js → price.taro-DUW-OR83.js} +1 -1
- package/dist/esm/{progress.taro-BFWQ2MvM.js → progress.taro-De9-206U.js} +2 -2
- package/dist/esm/{pulltorefresh.taro-Ck1i2xRr.js → pulltorefresh.taro-CZReoWwU.js} +4 -4
- package/dist/esm/{radio.taro-CjJgX9o2.js → radio.taro-BNSceequ.js} +1 -1
- package/dist/esm/{range.taro-BeVCaZ4r.js → range.taro-D_qsx_j6.js} +3 -3
- package/dist/esm/{rate.taro-lOoACxLq.js → rate.taro-CPGkjYYu.js} +1 -1
- package/dist/esm/{searchbar.taro-BptyG-eR.js → searchbar.taro-C8cg7NeJ.js} +1 -1
- package/dist/esm/{shortpassword.taro-BVp4BrTs.js → shortpassword.taro-DpdtRsQ-.js} +3 -3
- package/dist/esm/{sidenavbar.taro-DGnJgxEe.js → sidenavbar.taro-5BmrYFtP.js} +2 -2
- package/dist/esm/{sidenavbaritem.taro-L7HbsCLn.js → sidenavbaritem.taro-BKpzXpzG.js} +1 -1
- package/dist/esm/{signature.taro-Dq6JO2XJ.js → signature.taro-zgwaJkIE.js} +1 -1
- package/dist/esm/{skeleton.taro-C3vp7bWb.js → skeleton.taro-bD6fHZop.js} +2 -2
- package/dist/esm/{step.taro-CaRHnSOF.js → step.taro-Cc1dc5Qb.js} +1 -1
- package/dist/esm/{steps.taro-BoVGFMxx.js → steps.taro-CUEhZGfy.js} +1 -1
- package/dist/esm/{sticky.taro-CqiMtDv9.js → sticky.taro-DZzgkigZ.js} +2 -2
- package/dist/esm/{subsidenavbar.taro-ByxYpgfP.js → subsidenavbar.taro-CSU3DhNq.js} +1 -1
- package/dist/esm/{swipe.taro-CavqgBEb.js → swipe.taro-yUhne9XU.js} +4 -4
- package/dist/esm/{swiperitem.taro-8JXI24f0.js → swiperitem.taro-DeiNSrJV.js} +1 -1
- package/dist/esm/{switch.taro-Mq1wBEGz.js → switch.taro-CdBmDo18.js} +1 -1
- package/dist/esm/{tabbar.taro-DD5HcQgp.js → tabbar.taro-CXk0zLdz.js} +1 -1
- package/dist/esm/{tabbaritem.taro-ptdJI0xv.js → tabbaritem.taro-BZNabTBp.js} +2 -2
- package/dist/esm/{table.taro-EwAQJ6jp.js → table.taro-D2M3D2Vj.js} +6 -2
- package/dist/esm/{tabs.taro-gcyv8qGG.js → tabs.taro-B2D3AtVV.js} +2 -2
- package/dist/esm/{textarea.taro-DLS0EQeJ.js → textarea.taro-DuceTjAx.js} +2 -2
- package/dist/esm/{timeselect.taro-C64SUiXS.js → timeselect.taro-DncKbp3l.js} +3 -3
- package/dist/esm/{toast.taro-CSqE0aIO.js → toast.taro-CYk6UERn.js} +1 -1
- package/dist/esm/{tour.taro-DegQCG1T.js → tour.taro-SPMrhDA9.js} +2 -2
- package/dist/esm/{trendarrow.taro-B2QGvXG0.js → trendarrow.taro-DKx5cGIh.js} +1 -1
- package/dist/esm/{tslib.es6-BZ8i9Q6l.js → tslib.es6-iWu3F_1J.js} +2 -3
- package/dist/esm/{uploader.taro-CAKO74Mg.js → uploader.taro-E6R-Ow7M.js} +4 -4
- package/dist/esm/{video.taro-Bm5bDmIG.js → video.taro-CecLv4sr.js} +1 -1
- package/dist/esm/{virtuallist.taro-GLen2Ay5.js → virtuallist.taro-BlPW8ibd.js} +2 -9
- package/dist/esm/{watermark.taro-BL5bLewc.js → watermark.taro-BR12yZQt.js} +1 -1
- 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 +155 -306
- package/dist/nutui.react.umd.js +155 -306
- package/dist/packages/fixednav/fixednav.scss +2 -2
- package/dist/packages/tabpane/tabpane.scss +1 -1
- package/dist/style.css +1 -1
- package/dist/styles/variables-jmapp.scss +4 -1
- package/dist/styles/variables.scss +4 -1
- package/dist/types/packages/configprovider/types.d.ts +1 -1
- package/dist/types/packages/dialog/confirm.d.ts +1 -1
- package/dist/types/packages/table/index.d.ts +1 -0
- package/dist/types/packages/table/index.taro.d.ts +1 -0
- package/dist/types/packages/virtuallist/utils.d.ts +2 -2
- package/dist/types/utils/interceptor.d.ts +2 -2
- package/dist/types/utils/use-ref-state.d.ts +1 -1
- package/package.json +1 -1
- package/dist/style.mjs +0 -5
package/dist/nutui.react.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @nutui/nutui-react-taro v2.6.
|
|
2
|
+
* @nutui/nutui-react-taro v2.6.11 Fri Jun 28 2024 14:38:04 GMT+0800 (China Standard Time)
|
|
3
3
|
* (c) 2023 @jdf2e.
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
@@ -597,9 +597,6 @@ var freeSelf = typeof self == "object" && self && self.Object === Object && self
|
|
|
597
597
|
var root = freeGlobal || freeSelf || Function("return this")();
|
|
598
598
|
function arrayReduce(array4, iteratee, accumulator, initAccum) {
|
|
599
599
|
var index = -1, length = array4 ? array4.length : 0;
|
|
600
|
-
if (initAccum && length) {
|
|
601
|
-
accumulator = array4[++index];
|
|
602
|
-
}
|
|
603
600
|
while (++index < length) {
|
|
604
601
|
accumulator = iteratee(accumulator, array4[index], index, array4);
|
|
605
602
|
}
|
|
@@ -657,7 +654,7 @@ var kebabCase = createCompounder(function(result, word, index) {
|
|
|
657
654
|
});
|
|
658
655
|
function words(string3, pattern4, guard) {
|
|
659
656
|
string3 = toString(string3);
|
|
660
|
-
pattern4 =
|
|
657
|
+
pattern4 = pattern4;
|
|
661
658
|
if (pattern4 === void 0) {
|
|
662
659
|
return hasUnicodeWord(string3) ? unicodeWords(string3) : asciiWords(string3);
|
|
663
660
|
}
|
|
@@ -958,7 +955,7 @@ lodash_isequal.exports;
|
|
|
958
955
|
function arrayLikeKeys(value, inherited) {
|
|
959
956
|
var isArr = isArray(value), isArg = !isArr && isArguments(value), isBuff = !isArr && !isArg && isBuffer(value), isType = !isArr && !isArg && !isBuff && isTypedArray(value), skipIndexes = isArr || isArg || isBuff || isType, result = skipIndexes ? baseTimes(value.length, String) : [], length = result.length;
|
|
960
957
|
for (var key in value) {
|
|
961
|
-
if (
|
|
958
|
+
if (hasOwnProperty.call(value, key) && !(skipIndexes && // Safari 9 has enumerable `arguments.length` in strict mode.
|
|
962
959
|
(key == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
|
|
963
960
|
isBuff && (key == "offset" || key == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
|
|
964
961
|
isType && (key == "buffer" || key == "byteLength" || key == "byteOffset") || // Skip index properties.
|
|
@@ -1569,8 +1566,7 @@ const Image$1 = (props) => {
|
|
|
1569
1566
|
...style
|
|
1570
1567
|
};
|
|
1571
1568
|
const renderErrorImg = useCallback(() => {
|
|
1572
|
-
if (!isError)
|
|
1573
|
-
return null;
|
|
1569
|
+
if (!isError) return null;
|
|
1574
1570
|
if (typeof error === "boolean" && error === true && !innerLoading) {
|
|
1575
1571
|
return /* @__PURE__ */ React__default.createElement("div", { className: "nut-img-error" }, /* @__PURE__ */ React__default.createElement(N, null));
|
|
1576
1572
|
}
|
|
@@ -1580,8 +1576,7 @@ const Image$1 = (props) => {
|
|
|
1580
1576
|
return null;
|
|
1581
1577
|
}, [error, isError, innerLoading]);
|
|
1582
1578
|
const renderLoading = useCallback(() => {
|
|
1583
|
-
if (!loading)
|
|
1584
|
-
return null;
|
|
1579
|
+
if (!loading) return null;
|
|
1585
1580
|
if (typeof loading === "boolean" && loading === true && innerLoading) {
|
|
1586
1581
|
return /* @__PURE__ */ React__default.createElement("div", { className: "nut-img-loading" }, /* @__PURE__ */ React__default.createElement(j$2, null));
|
|
1587
1582
|
}
|
|
@@ -1604,44 +1599,30 @@ const Image$1 = (props) => {
|
|
|
1604
1599
|
};
|
|
1605
1600
|
Image$1.displayName = "NutImage";
|
|
1606
1601
|
function _extends$1() {
|
|
1607
|
-
_extends$1 = Object.assign ? Object.assign.bind() : function(
|
|
1608
|
-
for (var
|
|
1609
|
-
var
|
|
1610
|
-
for (var
|
|
1611
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
1612
|
-
target[key] = source[key];
|
|
1613
|
-
}
|
|
1614
|
-
}
|
|
1602
|
+
return _extends$1 = Object.assign ? Object.assign.bind() : function(n2) {
|
|
1603
|
+
for (var e2 = 1; e2 < arguments.length; e2++) {
|
|
1604
|
+
var t = arguments[e2];
|
|
1605
|
+
for (var r in t) ({}).hasOwnProperty.call(t, r) && (n2[r] = t[r]);
|
|
1615
1606
|
}
|
|
1616
|
-
return
|
|
1617
|
-
};
|
|
1618
|
-
return _extends$1.apply(this, arguments);
|
|
1607
|
+
return n2;
|
|
1608
|
+
}, _extends$1.apply(null, arguments);
|
|
1619
1609
|
}
|
|
1620
|
-
function _objectWithoutPropertiesLoose(
|
|
1621
|
-
if (
|
|
1622
|
-
|
|
1623
|
-
var
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
for (i = 0; i < sourceKeys.length; i++) {
|
|
1627
|
-
key = sourceKeys[i];
|
|
1628
|
-
if (excluded.indexOf(key) >= 0)
|
|
1629
|
-
continue;
|
|
1630
|
-
target[key] = source[key];
|
|
1610
|
+
function _objectWithoutPropertiesLoose(r, e2) {
|
|
1611
|
+
if (null == r) return {};
|
|
1612
|
+
var t = {};
|
|
1613
|
+
for (var n2 in r) if ({}.hasOwnProperty.call(r, n2)) {
|
|
1614
|
+
if (e2.indexOf(n2) >= 0) continue;
|
|
1615
|
+
t[n2] = r[n2];
|
|
1631
1616
|
}
|
|
1632
|
-
return
|
|
1617
|
+
return t;
|
|
1633
1618
|
}
|
|
1634
|
-
function _setPrototypeOf$1(
|
|
1635
|
-
_setPrototypeOf$1 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
};
|
|
1639
|
-
return _setPrototypeOf$1(o, p);
|
|
1619
|
+
function _setPrototypeOf$1(t, e2) {
|
|
1620
|
+
return _setPrototypeOf$1 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(t2, e3) {
|
|
1621
|
+
return t2.__proto__ = e3, t2;
|
|
1622
|
+
}, _setPrototypeOf$1(t, e2);
|
|
1640
1623
|
}
|
|
1641
|
-
function _inheritsLoose$1(
|
|
1642
|
-
|
|
1643
|
-
subClass.prototype.constructor = subClass;
|
|
1644
|
-
_setPrototypeOf$1(subClass, superClass);
|
|
1624
|
+
function _inheritsLoose$1(t, o) {
|
|
1625
|
+
t.prototype = Object.create(o.prototype), t.prototype.constructor = t, _setPrototypeOf$1(t, o);
|
|
1645
1626
|
}
|
|
1646
1627
|
var propTypes = { exports: {} };
|
|
1647
1628
|
var reactIs = { exports: {} };
|
|
@@ -1656,8 +1637,7 @@ var reactIs_production_min = {};
|
|
|
1656
1637
|
*/
|
|
1657
1638
|
var hasRequiredReactIs_production_min;
|
|
1658
1639
|
function requireReactIs_production_min() {
|
|
1659
|
-
if (hasRequiredReactIs_production_min)
|
|
1660
|
-
return reactIs_production_min;
|
|
1640
|
+
if (hasRequiredReactIs_production_min) return reactIs_production_min;
|
|
1661
1641
|
hasRequiredReactIs_production_min = 1;
|
|
1662
1642
|
var b = "function" === typeof Symbol && Symbol.for, c2 = b ? Symbol.for("react.element") : 60103, d = b ? Symbol.for("react.portal") : 60106, e2 = b ? Symbol.for("react.fragment") : 60107, f = b ? Symbol.for("react.strict_mode") : 60108, g2 = b ? Symbol.for("react.profiler") : 60114, h = b ? Symbol.for("react.provider") : 60109, k2 = b ? Symbol.for("react.context") : 60110, l = b ? Symbol.for("react.async_mode") : 60111, m2 = b ? Symbol.for("react.concurrent_mode") : 60111, n2 = b ? Symbol.for("react.forward_ref") : 60112, p = b ? Symbol.for("react.suspense") : 60113, q = b ? Symbol.for("react.suspense_list") : 60120, r = b ? Symbol.for("react.memo") : 60115, t = b ? Symbol.for("react.lazy") : 60116, v = b ? Symbol.for("react.block") : 60121, w = b ? Symbol.for("react.fundamental") : 60117, x = b ? Symbol.for("react.responder") : 60118, y = b ? Symbol.for("react.scope") : 60119;
|
|
1663
1643
|
function z2(a2) {
|
|
@@ -1760,8 +1740,7 @@ var reactIs_development = {};
|
|
|
1760
1740
|
*/
|
|
1761
1741
|
var hasRequiredReactIs_development;
|
|
1762
1742
|
function requireReactIs_development() {
|
|
1763
|
-
if (hasRequiredReactIs_development)
|
|
1764
|
-
return reactIs_development;
|
|
1743
|
+
if (hasRequiredReactIs_development) return reactIs_development;
|
|
1765
1744
|
hasRequiredReactIs_development = 1;
|
|
1766
1745
|
if (process.env.NODE_ENV !== "production") {
|
|
1767
1746
|
(function() {
|
|
@@ -1914,8 +1893,7 @@ function requireReactIs_development() {
|
|
|
1914
1893
|
}
|
|
1915
1894
|
var hasRequiredReactIs;
|
|
1916
1895
|
function requireReactIs() {
|
|
1917
|
-
if (hasRequiredReactIs)
|
|
1918
|
-
return reactIs.exports;
|
|
1896
|
+
if (hasRequiredReactIs) return reactIs.exports;
|
|
1919
1897
|
hasRequiredReactIs = 1;
|
|
1920
1898
|
if (process.env.NODE_ENV === "production") {
|
|
1921
1899
|
reactIs.exports = requireReactIs_production_min();
|
|
@@ -1932,8 +1910,7 @@ object-assign
|
|
|
1932
1910
|
var objectAssign;
|
|
1933
1911
|
var hasRequiredObjectAssign;
|
|
1934
1912
|
function requireObjectAssign() {
|
|
1935
|
-
if (hasRequiredObjectAssign)
|
|
1936
|
-
return objectAssign;
|
|
1913
|
+
if (hasRequiredObjectAssign) return objectAssign;
|
|
1937
1914
|
hasRequiredObjectAssign = 1;
|
|
1938
1915
|
var getOwnPropertySymbols = Object.getOwnPropertySymbols;
|
|
1939
1916
|
var hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
@@ -2003,8 +1980,7 @@ function requireObjectAssign() {
|
|
|
2003
1980
|
var ReactPropTypesSecret_1;
|
|
2004
1981
|
var hasRequiredReactPropTypesSecret;
|
|
2005
1982
|
function requireReactPropTypesSecret() {
|
|
2006
|
-
if (hasRequiredReactPropTypesSecret)
|
|
2007
|
-
return ReactPropTypesSecret_1;
|
|
1983
|
+
if (hasRequiredReactPropTypesSecret) return ReactPropTypesSecret_1;
|
|
2008
1984
|
hasRequiredReactPropTypesSecret = 1;
|
|
2009
1985
|
var ReactPropTypesSecret = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";
|
|
2010
1986
|
ReactPropTypesSecret_1 = ReactPropTypesSecret;
|
|
@@ -2013,8 +1989,7 @@ function requireReactPropTypesSecret() {
|
|
|
2013
1989
|
var has;
|
|
2014
1990
|
var hasRequiredHas;
|
|
2015
1991
|
function requireHas() {
|
|
2016
|
-
if (hasRequiredHas)
|
|
2017
|
-
return has;
|
|
1992
|
+
if (hasRequiredHas) return has;
|
|
2018
1993
|
hasRequiredHas = 1;
|
|
2019
1994
|
has = Function.call.bind(Object.prototype.hasOwnProperty);
|
|
2020
1995
|
return has;
|
|
@@ -2022,8 +1997,7 @@ function requireHas() {
|
|
|
2022
1997
|
var checkPropTypes_1;
|
|
2023
1998
|
var hasRequiredCheckPropTypes;
|
|
2024
1999
|
function requireCheckPropTypes() {
|
|
2025
|
-
if (hasRequiredCheckPropTypes)
|
|
2026
|
-
return checkPropTypes_1;
|
|
2000
|
+
if (hasRequiredCheckPropTypes) return checkPropTypes_1;
|
|
2027
2001
|
hasRequiredCheckPropTypes = 1;
|
|
2028
2002
|
var printWarning = function() {
|
|
2029
2003
|
};
|
|
@@ -2086,8 +2060,7 @@ function requireCheckPropTypes() {
|
|
|
2086
2060
|
var factoryWithTypeCheckers;
|
|
2087
2061
|
var hasRequiredFactoryWithTypeCheckers;
|
|
2088
2062
|
function requireFactoryWithTypeCheckers() {
|
|
2089
|
-
if (hasRequiredFactoryWithTypeCheckers)
|
|
2090
|
-
return factoryWithTypeCheckers;
|
|
2063
|
+
if (hasRequiredFactoryWithTypeCheckers) return factoryWithTypeCheckers;
|
|
2091
2064
|
hasRequiredFactoryWithTypeCheckers = 1;
|
|
2092
2065
|
var ReactIs = requireReactIs();
|
|
2093
2066
|
var assign = requireObjectAssign();
|
|
@@ -2530,8 +2503,7 @@ function requireFactoryWithTypeCheckers() {
|
|
|
2530
2503
|
var factoryWithThrowingShims;
|
|
2531
2504
|
var hasRequiredFactoryWithThrowingShims;
|
|
2532
2505
|
function requireFactoryWithThrowingShims() {
|
|
2533
|
-
if (hasRequiredFactoryWithThrowingShims)
|
|
2534
|
-
return factoryWithThrowingShims;
|
|
2506
|
+
if (hasRequiredFactoryWithThrowingShims) return factoryWithThrowingShims;
|
|
2535
2507
|
hasRequiredFactoryWithThrowingShims = 1;
|
|
2536
2508
|
var ReactPropTypesSecret = requireReactPropTypesSecret();
|
|
2537
2509
|
function emptyFunction() {
|
|
@@ -2592,18 +2564,13 @@ if (process.env.NODE_ENV !== "production") {
|
|
|
2592
2564
|
var propTypesExports = propTypes.exports;
|
|
2593
2565
|
const PropTypes = /* @__PURE__ */ getDefaultExportFromCjs(propTypesExports);
|
|
2594
2566
|
function hasClass(element, className) {
|
|
2595
|
-
if (element.classList)
|
|
2596
|
-
return !!className && element.classList.contains(className);
|
|
2567
|
+
if (element.classList) return !!className && element.classList.contains(className);
|
|
2597
2568
|
return (" " + (element.className.baseVal || element.className) + " ").indexOf(" " + className + " ") !== -1;
|
|
2598
2569
|
}
|
|
2599
2570
|
function addClass(element, className) {
|
|
2600
|
-
if (element.classList)
|
|
2601
|
-
|
|
2602
|
-
else
|
|
2603
|
-
if (typeof element.className === "string")
|
|
2604
|
-
element.className = element.className + " " + className;
|
|
2605
|
-
else
|
|
2606
|
-
element.setAttribute("class", (element.className && element.className.baseVal || "") + " " + className);
|
|
2571
|
+
if (element.classList) element.classList.add(className);
|
|
2572
|
+
else if (!hasClass(element, className)) if (typeof element.className === "string") element.className = element.className + " " + className;
|
|
2573
|
+
else element.setAttribute("class", (element.className && element.className.baseVal || "") + " " + className);
|
|
2607
2574
|
}
|
|
2608
2575
|
function replaceClassName(origClass, classToRemove) {
|
|
2609
2576
|
return origClass.replace(new RegExp("(^|\\s)" + classToRemove + "(?:\\s|$)", "g"), "$1").replace(/\s+/g, " ").replace(/^\s*|\s*$/g, "");
|
|
@@ -2731,8 +2698,7 @@ var Transition = /* @__PURE__ */ function(_React$Component) {
|
|
|
2731
2698
|
if (nextStatus === ENTERING) {
|
|
2732
2699
|
if (this.props.unmountOnExit || this.props.mountOnEnter) {
|
|
2733
2700
|
var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);
|
|
2734
|
-
if (node)
|
|
2735
|
-
forceReflow(node);
|
|
2701
|
+
if (node) forceReflow(node);
|
|
2736
2702
|
}
|
|
2737
2703
|
this.performEnter(mounting);
|
|
2738
2704
|
} else {
|
|
@@ -2970,8 +2936,7 @@ Transition.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
2970
2936
|
*/
|
|
2971
2937
|
timeout: function timeout(props) {
|
|
2972
2938
|
var pt = timeoutsShape;
|
|
2973
|
-
if (!props.addEndListener)
|
|
2974
|
-
pt = pt.isRequired;
|
|
2939
|
+
if (!props.addEndListener) pt = pt.isRequired;
|
|
2975
2940
|
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
2976
2941
|
args[_key - 1] = arguments[_key];
|
|
2977
2942
|
}
|
|
@@ -3065,7 +3030,6 @@ Transition.EXITED = EXITED;
|
|
|
3065
3030
|
Transition.ENTERING = ENTERING;
|
|
3066
3031
|
Transition.ENTERED = ENTERED;
|
|
3067
3032
|
Transition.EXITING = EXITING;
|
|
3068
|
-
const Transition$1 = Transition;
|
|
3069
3033
|
var _addClass = function addClass$1(node, classes) {
|
|
3070
3034
|
return node && classes && classes.split(" ").forEach(function(c2) {
|
|
3071
3035
|
return addClass(node, c2);
|
|
@@ -3164,8 +3128,7 @@ var CSSTransition = /* @__PURE__ */ function(_React$Component) {
|
|
|
3164
3128
|
className += " " + doneClassName;
|
|
3165
3129
|
}
|
|
3166
3130
|
if (phase === "active") {
|
|
3167
|
-
if (node)
|
|
3168
|
-
forceReflow(node);
|
|
3131
|
+
if (node) forceReflow(node);
|
|
3169
3132
|
}
|
|
3170
3133
|
if (className) {
|
|
3171
3134
|
this.appliedClasses[type4][phase] = className;
|
|
@@ -3189,7 +3152,7 @@ var CSSTransition = /* @__PURE__ */ function(_React$Component) {
|
|
|
3189
3152
|
var _this$props = this.props;
|
|
3190
3153
|
_this$props.classNames;
|
|
3191
3154
|
var props = _objectWithoutPropertiesLoose(_this$props, ["classNames"]);
|
|
3192
|
-
return /* @__PURE__ */ React__default.createElement(Transition
|
|
3155
|
+
return /* @__PURE__ */ React__default.createElement(Transition, _extends$1({}, props, {
|
|
3193
3156
|
onEnter: this.onEnter,
|
|
3194
3157
|
onEntered: this.onEntered,
|
|
3195
3158
|
onEntering: this.onEntering,
|
|
@@ -3203,7 +3166,7 @@ var CSSTransition = /* @__PURE__ */ function(_React$Component) {
|
|
|
3203
3166
|
CSSTransition.defaultProps = {
|
|
3204
3167
|
classNames: ""
|
|
3205
3168
|
};
|
|
3206
|
-
CSSTransition.propTypes = process.env.NODE_ENV !== "production" ? _extends$1({}, Transition
|
|
3169
|
+
CSSTransition.propTypes = process.env.NODE_ENV !== "production" ? _extends$1({}, Transition.propTypes, {
|
|
3207
3170
|
/**
|
|
3208
3171
|
* The animation classNames applied to the component as it appears, enters,
|
|
3209
3172
|
* exits or has finished the transition. A single name can be provided, which
|
|
@@ -3327,7 +3290,6 @@ CSSTransition.propTypes = process.env.NODE_ENV !== "production" ? _extends$1({},
|
|
|
3327
3290
|
*/
|
|
3328
3291
|
onExited: PropTypes.func
|
|
3329
3292
|
}) : {};
|
|
3330
|
-
const CSSTransition$1 = CSSTransition;
|
|
3331
3293
|
const MIN_DISTANCE = 10;
|
|
3332
3294
|
function getDirection(x, y) {
|
|
3333
3295
|
if (x > y && x > MIN_DISTANCE) {
|
|
@@ -3423,19 +3385,6 @@ function getScrollParent(el, root2 = defaultRoot) {
|
|
|
3423
3385
|
}
|
|
3424
3386
|
return root2;
|
|
3425
3387
|
}
|
|
3426
|
-
let passiveSupported = false;
|
|
3427
|
-
if (canUseDom) {
|
|
3428
|
-
try {
|
|
3429
|
-
const opts = Object.defineProperty({}, "passive", {
|
|
3430
|
-
get() {
|
|
3431
|
-
passiveSupported = true;
|
|
3432
|
-
}
|
|
3433
|
-
});
|
|
3434
|
-
window.addEventListener("test-passive-supported", null, opts);
|
|
3435
|
-
} catch (e2) {
|
|
3436
|
-
console.log(e2);
|
|
3437
|
-
}
|
|
3438
|
-
}
|
|
3439
3388
|
let totalLockCount = 0;
|
|
3440
3389
|
const BODY_LOCK_CLASS = "nut-overflow-hidden";
|
|
3441
3390
|
function getScrollableElement(el) {
|
|
@@ -3457,8 +3406,7 @@ function useLockScroll(rootRef, shouldLock) {
|
|
|
3457
3406
|
event.target,
|
|
3458
3407
|
rootRef.current
|
|
3459
3408
|
);
|
|
3460
|
-
if (!el)
|
|
3461
|
-
return;
|
|
3409
|
+
if (!el) return;
|
|
3462
3410
|
if (shouldLock === "strict") {
|
|
3463
3411
|
const scrollableParent = getScrollableElement(event.target);
|
|
3464
3412
|
if (scrollableParent === document.body || scrollableParent === document.documentElement) {
|
|
@@ -3484,7 +3432,7 @@ function useLockScroll(rootRef, shouldLock) {
|
|
|
3484
3432
|
document.addEventListener(
|
|
3485
3433
|
"touchmove",
|
|
3486
3434
|
onTouchMove,
|
|
3487
|
-
|
|
3435
|
+
false
|
|
3488
3436
|
);
|
|
3489
3437
|
if (!totalLockCount) {
|
|
3490
3438
|
document.body.classList.add(BODY_LOCK_CLASS);
|
|
@@ -3571,7 +3519,7 @@ const Overlay = (props) => {
|
|
|
3571
3519
|
afterClose && afterClose();
|
|
3572
3520
|
};
|
|
3573
3521
|
return /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement(
|
|
3574
|
-
CSSTransition
|
|
3522
|
+
CSSTransition,
|
|
3575
3523
|
{
|
|
3576
3524
|
nodeRef,
|
|
3577
3525
|
classNames: `${classPrefix2}-slide`,
|
|
@@ -4018,10 +3966,8 @@ const Sticky = (props) => {
|
|
|
4018
3966
|
};
|
|
4019
3967
|
}
|
|
4020
3968
|
const style2 = {};
|
|
4021
|
-
if (rootRect.height)
|
|
4022
|
-
|
|
4023
|
-
if (rootRect.width)
|
|
4024
|
-
style2.width = rootRect.width;
|
|
3969
|
+
if (rootRect.height) style2.height = rootRect.height;
|
|
3970
|
+
if (rootRect.width) style2.width = rootRect.width;
|
|
4025
3971
|
style2.transform = `translate3d(0, ${transform}px, 0)`;
|
|
4026
3972
|
style2[position] = threshold;
|
|
4027
3973
|
style2.zIndex = zIndex;
|
|
@@ -4225,8 +4171,7 @@ const Elevator = (props) => {
|
|
|
4225
4171
|
const query = createSelectorQuery();
|
|
4226
4172
|
query.selectAll(`.${className} .nut-elevator-item-${i}`).boundingClientRect();
|
|
4227
4173
|
query.exec((res) => {
|
|
4228
|
-
if (res[0][0])
|
|
4229
|
-
height2 += res[0][0].height;
|
|
4174
|
+
if (res[0][0]) height2 += res[0][0].height;
|
|
4230
4175
|
state.current.listHeight.push(height2);
|
|
4231
4176
|
});
|
|
4232
4177
|
}
|
|
@@ -4301,8 +4246,7 @@ const Elevator = (props) => {
|
|
|
4301
4246
|
if (sticky && scrollTop2 !== scrollY) {
|
|
4302
4247
|
setScrollY(Math.floor(scrollTop2) > 0 ? 1 : 0);
|
|
4303
4248
|
}
|
|
4304
|
-
if (scrolling.current)
|
|
4305
|
-
return;
|
|
4249
|
+
if (scrolling.current) return;
|
|
4306
4250
|
for (let i = 0; i < listHeight.length - 1; i++) {
|
|
4307
4251
|
const height1 = listHeight[i];
|
|
4308
4252
|
const height2 = listHeight[i + 1];
|
|
@@ -4732,7 +4676,7 @@ const Popup = (props) => {
|
|
|
4732
4676
|
};
|
|
4733
4677
|
const renderPop = () => {
|
|
4734
4678
|
return /* @__PURE__ */ React__default.createElement(
|
|
4735
|
-
CSSTransition
|
|
4679
|
+
CSSTransition,
|
|
4736
4680
|
{
|
|
4737
4681
|
classNames: transitionName,
|
|
4738
4682
|
mountOnEnter: true,
|
|
@@ -4974,24 +4918,20 @@ const Badge = (props) => {
|
|
|
4974
4918
|
[`${classPrefix2}-${fill}`]: fill === "outline"
|
|
4975
4919
|
});
|
|
4976
4920
|
function content() {
|
|
4977
|
-
if (dot || typeof value === "object" || value === 0)
|
|
4978
|
-
return null;
|
|
4921
|
+
if (dot || typeof value === "object" || value === 0) return null;
|
|
4979
4922
|
if (typeof value === "number" && typeof max === "number") {
|
|
4980
4923
|
return max < value ? `${max}+` : `${value}`;
|
|
4981
4924
|
}
|
|
4982
4925
|
return value;
|
|
4983
4926
|
}
|
|
4984
4927
|
function isIcon() {
|
|
4985
|
-
if (typeof value === "object" && value)
|
|
4986
|
-
return value;
|
|
4928
|
+
if (typeof value === "object" && value) return value;
|
|
4987
4929
|
}
|
|
4988
4930
|
function isNumber() {
|
|
4989
|
-
if (typeof value === "number" && value)
|
|
4990
|
-
return value;
|
|
4931
|
+
if (typeof value === "number" && value) return value;
|
|
4991
4932
|
}
|
|
4992
4933
|
function isString() {
|
|
4993
|
-
if (typeof value === "string" && value)
|
|
4994
|
-
return value;
|
|
4934
|
+
if (typeof value === "string" && value) return value;
|
|
4995
4935
|
}
|
|
4996
4936
|
const contentClasses = classNames(
|
|
4997
4937
|
{ [`${classPrefix2}-dot`]: dot },
|
|
@@ -5144,8 +5084,7 @@ const Tabbar = (props) => {
|
|
|
5144
5084
|
}
|
|
5145
5085
|
},
|
|
5146
5086
|
React__default.Children.map(children, (child, index) => {
|
|
5147
|
-
if (!React__default.isValidElement(child))
|
|
5148
|
-
return null;
|
|
5087
|
+
if (!React__default.isValidElement(child)) return null;
|
|
5149
5088
|
return React__default.cloneElement(child, { ...child.props, index });
|
|
5150
5089
|
})
|
|
5151
5090
|
)),
|
|
@@ -5333,8 +5272,7 @@ const Tabs = (props) => {
|
|
|
5333
5272
|
navRectRef.current = navRect;
|
|
5334
5273
|
titleRectRef.current = titleRects;
|
|
5335
5274
|
const titleRect = titleRectRef.current[index];
|
|
5336
|
-
if (!titleRect)
|
|
5337
|
-
return;
|
|
5275
|
+
if (!titleRect) return;
|
|
5338
5276
|
let to = 0;
|
|
5339
5277
|
if (direction === "vertical") {
|
|
5340
5278
|
const top = titleRects.slice(0, index).reduce((prev, curr) => prev + curr.height, 0);
|
|
@@ -6360,9 +6298,6 @@ const getCurrMonthData = (type4, year, month) => {
|
|
|
6360
6298
|
};
|
|
6361
6299
|
const getDaysStatus = (type4, year, month) => {
|
|
6362
6300
|
let days = Utils.getMonthDays(`${year}`, `${month}`);
|
|
6363
|
-
if (type4 === "prev" && days >= 7) {
|
|
6364
|
-
days -= 7;
|
|
6365
|
-
}
|
|
6366
6301
|
return Array.from(Array(days), (v, k2) => {
|
|
6367
6302
|
return {
|
|
6368
6303
|
day: k2 + 1,
|
|
@@ -6381,7 +6316,7 @@ const getPreMonthDates = (type4, year, month, firstDayOfWeek) => {
|
|
|
6381
6316
|
}
|
|
6382
6317
|
let days = Utils.getMonthPreDay(+year, +month);
|
|
6383
6318
|
days -= firstDayOfWeek;
|
|
6384
|
-
if (
|
|
6319
|
+
if (days >= 7) {
|
|
6385
6320
|
days -= 7;
|
|
6386
6321
|
}
|
|
6387
6322
|
const preDates = Utils.getMonthDays(`${preYear}`, `${preMonth}`);
|
|
@@ -6558,7 +6493,7 @@ const CalendarItem = React__default.forwardRef((props, ref) => {
|
|
|
6558
6493
|
cssHeight,
|
|
6559
6494
|
scrollTop: scrollTop2
|
|
6560
6495
|
};
|
|
6561
|
-
|
|
6496
|
+
{
|
|
6562
6497
|
if (!endDates || !Utils.compareDate(
|
|
6563
6498
|
`${endDates[0]}/${endDates[1]}/${Utils.getMonthDays(
|
|
6564
6499
|
endDates[0],
|
|
@@ -6568,11 +6503,6 @@ const CalendarItem = React__default.forwardRef((props, ref) => {
|
|
|
6568
6503
|
)) {
|
|
6569
6504
|
monthData.push(monthInfo);
|
|
6570
6505
|
}
|
|
6571
|
-
} else if (!startDates || !Utils.compareDate(
|
|
6572
|
-
`${curData[0]}/${curData[1]}/${curData[2]}`,
|
|
6573
|
-
`${startDates[0]}/${startDates[1]}/01`
|
|
6574
|
-
)) {
|
|
6575
|
-
monthData.unshift(monthInfo);
|
|
6576
6506
|
}
|
|
6577
6507
|
date4 = getCurrMonthData("next", y, m2);
|
|
6578
6508
|
} while (i++ < monthNum);
|
|
@@ -6581,8 +6511,7 @@ const CalendarItem = React__default.forwardRef((props, ref) => {
|
|
|
6581
6511
|
const setReachedYearMonthInfo = (current) => {
|
|
6582
6512
|
const currentMonthsData = monthsData[current];
|
|
6583
6513
|
const [year, month] = currentMonthsData.curData;
|
|
6584
|
-
if (currentMonthsData.title === yearMonthTitle)
|
|
6585
|
-
return;
|
|
6514
|
+
if (currentMonthsData.title === yearMonthTitle) return;
|
|
6586
6515
|
onPageChange && onPageChange([year, month, `${year}-${month}`]);
|
|
6587
6516
|
setYearMonthTitle(currentMonthsData.title);
|
|
6588
6517
|
};
|
|
@@ -6773,7 +6702,7 @@ const CalendarItem = React__default.forwardRef((props, ref) => {
|
|
|
6773
6702
|
};
|
|
6774
6703
|
const initData = () => {
|
|
6775
6704
|
const monthNum = getMonthNum();
|
|
6776
|
-
getMonthData(startDates, monthNum
|
|
6705
|
+
getMonthData(startDates, monthNum);
|
|
6777
6706
|
const current = renderCurrentDate();
|
|
6778
6707
|
setDefaultRange(monthNum, current);
|
|
6779
6708
|
requestAniFrameFunc(current, monthNum);
|
|
@@ -6833,8 +6762,7 @@ const CalendarItem = React__default.forwardRef((props, ref) => {
|
|
|
6833
6762
|
const scrollTop2 = e2.target.scrollTop;
|
|
6834
6763
|
Taro.getEnv() === "WEB" && setScrollTop(scrollTop2);
|
|
6835
6764
|
let current = Math.floor(scrollTop2 / avgHeight);
|
|
6836
|
-
if (!monthsData[current + 1])
|
|
6837
|
-
return;
|
|
6765
|
+
if (!monthsData[current + 1]) return;
|
|
6838
6766
|
const nextTop = monthsData[current + 1].scrollTop;
|
|
6839
6767
|
const nextHeight = monthsData[current + 1].cssHeight;
|
|
6840
6768
|
if (current === 0) {
|
|
@@ -7580,7 +7508,6 @@ const CalendarCard = React__default.forwardRef((props, ref) => {
|
|
|
7580
7508
|
});
|
|
7581
7509
|
CalendarCard.displayName = "NutCalendarCard";
|
|
7582
7510
|
const CheckboxGroupContext = createContext(null);
|
|
7583
|
-
const Context$1 = CheckboxGroupContext;
|
|
7584
7511
|
const defaultProps$10 = {
|
|
7585
7512
|
max: void 0,
|
|
7586
7513
|
min: void 0,
|
|
@@ -7658,7 +7585,7 @@ const CheckboxGroup = React__default.forwardRef(
|
|
|
7658
7585
|
});
|
|
7659
7586
|
}, [options, max, min]);
|
|
7660
7587
|
return /* @__PURE__ */ React__default.createElement(
|
|
7661
|
-
|
|
7588
|
+
CheckboxGroupContext.Provider,
|
|
7662
7589
|
{
|
|
7663
7590
|
value: {
|
|
7664
7591
|
labelPosition: labelPosition || "right",
|
|
@@ -7738,7 +7665,7 @@ const Checkbox = (props) => {
|
|
|
7738
7665
|
...others
|
|
7739
7666
|
} = props;
|
|
7740
7667
|
let { labelPosition, ...rest } = others;
|
|
7741
|
-
const ctx = useContext(
|
|
7668
|
+
const ctx = useContext(CheckboxGroupContext);
|
|
7742
7669
|
let [innerChecked, setChecked] = usePropsValue({
|
|
7743
7670
|
value: checked,
|
|
7744
7671
|
defaultValue: defaultChecked,
|
|
@@ -7760,12 +7687,9 @@ const Checkbox = (props) => {
|
|
|
7760
7687
|
innerDisabled = ctx.disabled !== void 0 ? ctx.disabled : innerDisabled;
|
|
7761
7688
|
innerChecked = ctx.value.includes(value);
|
|
7762
7689
|
setChecked = (checked2) => {
|
|
7763
|
-
if (ctx.disabled)
|
|
7764
|
-
|
|
7765
|
-
if (checked2)
|
|
7766
|
-
ctx.check(value);
|
|
7767
|
-
if (!checked2)
|
|
7768
|
-
ctx.uncheck(value);
|
|
7690
|
+
if (ctx.disabled) return;
|
|
7691
|
+
if (checked2) ctx.check(value);
|
|
7692
|
+
if (!checked2) ctx.uncheck(value);
|
|
7769
7693
|
};
|
|
7770
7694
|
}
|
|
7771
7695
|
const renderIcon = () => {
|
|
@@ -7817,8 +7741,7 @@ const Checkbox = (props) => {
|
|
|
7817
7741
|
);
|
|
7818
7742
|
};
|
|
7819
7743
|
const handleClick = () => {
|
|
7820
|
-
if (disabled)
|
|
7821
|
-
return;
|
|
7744
|
+
if (disabled) return;
|
|
7822
7745
|
const latestChecked = !innerChecked;
|
|
7823
7746
|
setChecked(latestChecked);
|
|
7824
7747
|
};
|
|
@@ -7946,14 +7869,13 @@ const InternalPickerPanel = (props, ref) => {
|
|
|
7946
7869
|
touch.move(event);
|
|
7947
7870
|
if (touch.isVertical) {
|
|
7948
7871
|
moving.current = true;
|
|
7949
|
-
preventDefault2(event
|
|
7872
|
+
preventDefault2(event);
|
|
7950
7873
|
}
|
|
7951
7874
|
const move = touch.deltaY.current - startY;
|
|
7952
7875
|
setMove(move);
|
|
7953
7876
|
};
|
|
7954
7877
|
const touchEnd = () => {
|
|
7955
|
-
if (!moving.current)
|
|
7956
|
-
return;
|
|
7878
|
+
if (!moving.current) return;
|
|
7957
7879
|
const move = touch.deltaY.current - startY;
|
|
7958
7880
|
const moveTime = Date.now() - startTime;
|
|
7959
7881
|
if (moveTime <= INERTIA_TIME && Math.abs(move) > INERTIA_DISTANCE) {
|
|
@@ -7973,7 +7895,7 @@ const InternalPickerPanel = (props, ref) => {
|
|
|
7973
7895
|
return nDistance;
|
|
7974
7896
|
};
|
|
7975
7897
|
const modifyStatus = (type4, val) => {
|
|
7976
|
-
const value =
|
|
7898
|
+
const value = defaultValue;
|
|
7977
7899
|
let index = -1;
|
|
7978
7900
|
if (value) {
|
|
7979
7901
|
options.some((item, idx) => {
|
|
@@ -7992,7 +7914,6 @@ const InternalPickerPanel = (props, ref) => {
|
|
|
7992
7914
|
}
|
|
7993
7915
|
setCurrIndex(index === -1 ? 1 : index + 1);
|
|
7994
7916
|
const move = index === -1 ? 0 : index * lineSpacing.current;
|
|
7995
|
-
type4 && setChooseValue(-move);
|
|
7996
7917
|
setMove(-move);
|
|
7997
7918
|
};
|
|
7998
7919
|
const stopMomentum = () => {
|
|
@@ -8002,7 +7923,7 @@ const InternalPickerPanel = (props, ref) => {
|
|
|
8002
7923
|
};
|
|
8003
7924
|
const preventDefault2 = (event, isStopPropagation) => {
|
|
8004
7925
|
event.preventDefault();
|
|
8005
|
-
|
|
7926
|
+
{
|
|
8006
7927
|
event.stopPropagation();
|
|
8007
7928
|
}
|
|
8008
7929
|
};
|
|
@@ -8025,7 +7946,7 @@ const InternalPickerPanel = (props, ref) => {
|
|
|
8025
7946
|
useEffect(() => {
|
|
8026
7947
|
setScrollDistance(0);
|
|
8027
7948
|
transformY.current = 0;
|
|
8028
|
-
modifyStatus(
|
|
7949
|
+
modifyStatus();
|
|
8029
7950
|
return () => {
|
|
8030
7951
|
clearTimeout(timer);
|
|
8031
7952
|
};
|
|
@@ -8042,7 +7963,7 @@ const InternalPickerPanel = (props, ref) => {
|
|
|
8042
7963
|
moving: moving.current
|
|
8043
7964
|
}));
|
|
8044
7965
|
useEffect(() => {
|
|
8045
|
-
const eventOptions =
|
|
7966
|
+
const eventOptions = false;
|
|
8046
7967
|
const element = pickerPanelRef.current;
|
|
8047
7968
|
element.addEventListener("touchstart", touchStart, eventOptions);
|
|
8048
7969
|
element.addEventListener("touchmove", touchMove, eventOptions);
|
|
@@ -8093,13 +8014,11 @@ const InternalPickerPanel = (props, ref) => {
|
|
|
8093
8014
|
), /* @__PURE__ */ React__default.createElement("div", { className: "nut-picker-mask" }), /* @__PURE__ */ React__default.createElement("div", { className: "nut-picker-indicator", ref: listRef }));
|
|
8094
8015
|
};
|
|
8095
8016
|
const PickerPanel = React__default.forwardRef(InternalPickerPanel);
|
|
8096
|
-
const PickerPanel$1 = PickerPanel;
|
|
8097
8017
|
function useRefs() {
|
|
8098
8018
|
const refs = React__default.useRef([]);
|
|
8099
8019
|
const setRefs = React__default.useCallback(
|
|
8100
8020
|
(index) => (el) => {
|
|
8101
|
-
if (el)
|
|
8102
|
-
refs.current[index] = el;
|
|
8021
|
+
if (el) refs.current[index] = el;
|
|
8103
8022
|
},
|
|
8104
8023
|
[]
|
|
8105
8024
|
);
|
|
@@ -8188,8 +8107,7 @@ const InternalPicker = (props, ref) => {
|
|
|
8188
8107
|
const options2 = columnOptions.children;
|
|
8189
8108
|
const value = values[columnIndex2];
|
|
8190
8109
|
let index = options2.findIndex((columnItem) => columnItem.value === value);
|
|
8191
|
-
if (index === -1)
|
|
8192
|
-
index = 0;
|
|
8110
|
+
if (index === -1) index = 0;
|
|
8193
8111
|
columnOptions = columnOptions.children[index];
|
|
8194
8112
|
columnIndex2++;
|
|
8195
8113
|
formatted.push(options2);
|
|
@@ -8322,8 +8240,7 @@ const InternalPicker = (props, ref) => {
|
|
|
8322
8240
|
const confirm = () => {
|
|
8323
8241
|
let moving = false;
|
|
8324
8242
|
refs.forEach((ref2) => {
|
|
8325
|
-
if (ref2.moving)
|
|
8326
|
-
moving = true;
|
|
8243
|
+
if (ref2.moving) moving = true;
|
|
8327
8244
|
ref2.stopMomentum();
|
|
8328
8245
|
});
|
|
8329
8246
|
if (moving) {
|
|
@@ -8401,7 +8318,7 @@ const InternalPicker = (props, ref) => {
|
|
|
8401
8318
|
},
|
|
8402
8319
|
/* @__PURE__ */ React__default.createElement(View, { className: classes, style, ...rest, catchMove: true }, renderTitleBar(), typeof children !== "function" && children, /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-panel`, ref: pickerRef }, Taro.getEnv() === "WEB" ? columnsList == null ? void 0 : columnsList.map((item, index) => {
|
|
8403
8320
|
return /* @__PURE__ */ React__default.createElement(
|
|
8404
|
-
PickerPanel
|
|
8321
|
+
PickerPanel,
|
|
8405
8322
|
{
|
|
8406
8323
|
ref: setRefs(index),
|
|
8407
8324
|
defaultValue: innerValue == null ? void 0 : innerValue[index],
|
|
@@ -8442,7 +8359,6 @@ const InternalPicker = (props, ref) => {
|
|
|
8442
8359
|
));
|
|
8443
8360
|
};
|
|
8444
8361
|
const Picker = React__default.forwardRef(InternalPicker);
|
|
8445
|
-
const Picker$1 = Picker;
|
|
8446
8362
|
const isDate = (val) => {
|
|
8447
8363
|
return Object.prototype.toString.call(val) === "[object Date]" && !Number.isNaN(val.getTime());
|
|
8448
8364
|
};
|
|
@@ -8556,8 +8472,7 @@ const DatePicker = (props) => {
|
|
|
8556
8472
|
};
|
|
8557
8473
|
const ranges = () => {
|
|
8558
8474
|
const selected = new Date(selectedDate);
|
|
8559
|
-
if (!selected)
|
|
8560
|
-
return [];
|
|
8475
|
+
if (!selected) return [];
|
|
8561
8476
|
const { maxYear, maxDate, maxMonth, maxHour, maxMinute, maxSeconds } = getBoundary("max", selected);
|
|
8562
8477
|
const { minYear, minDate, minMonth, minHour, minMinute, minSeconds } = getBoundary("min", selected);
|
|
8563
8478
|
const result = [
|
|
@@ -8716,8 +8631,7 @@ const DatePicker = (props) => {
|
|
|
8716
8631
|
};
|
|
8717
8632
|
const getDateIndex = (type22) => {
|
|
8718
8633
|
const date4 = new Date(selectedDate);
|
|
8719
|
-
if (!selectedDate)
|
|
8720
|
-
return 0;
|
|
8634
|
+
if (!selectedDate) return 0;
|
|
8721
8635
|
if (type22 === "year") {
|
|
8722
8636
|
return date4.getFullYear();
|
|
8723
8637
|
}
|
|
@@ -8762,7 +8676,7 @@ const DatePicker = (props) => {
|
|
|
8762
8676
|
...rest
|
|
8763
8677
|
},
|
|
8764
8678
|
pickerOptions.length && /* @__PURE__ */ React__default.createElement(
|
|
8765
|
-
Picker
|
|
8679
|
+
Picker,
|
|
8766
8680
|
{
|
|
8767
8681
|
...pickerProps,
|
|
8768
8682
|
title,
|
|
@@ -8814,12 +8728,9 @@ function _setPrototypeOf(o, p) {
|
|
|
8814
8728
|
return _setPrototypeOf(o, p);
|
|
8815
8729
|
}
|
|
8816
8730
|
function _isNativeReflectConstruct() {
|
|
8817
|
-
if (typeof Reflect === "undefined" || !Reflect.construct)
|
|
8818
|
-
|
|
8819
|
-
if (
|
|
8820
|
-
return false;
|
|
8821
|
-
if (typeof Proxy === "function")
|
|
8822
|
-
return true;
|
|
8731
|
+
if (typeof Reflect === "undefined" || !Reflect.construct) return false;
|
|
8732
|
+
if (Reflect.construct.sham) return false;
|
|
8733
|
+
if (typeof Proxy === "function") return true;
|
|
8823
8734
|
try {
|
|
8824
8735
|
Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
8825
8736
|
}));
|
|
@@ -8837,8 +8748,7 @@ function _construct(Parent, args, Class) {
|
|
|
8837
8748
|
a2.push.apply(a2, args2);
|
|
8838
8749
|
var Constructor = Function.bind.apply(Parent2, a2);
|
|
8839
8750
|
var instance = new Constructor();
|
|
8840
|
-
if (Class2)
|
|
8841
|
-
_setPrototypeOf(instance, Class2.prototype);
|
|
8751
|
+
if (Class2) _setPrototypeOf(instance, Class2.prototype);
|
|
8842
8752
|
return instance;
|
|
8843
8753
|
};
|
|
8844
8754
|
}
|
|
@@ -8850,14 +8760,12 @@ function _isNativeFunction(fn) {
|
|
|
8850
8760
|
function _wrapNativeSuper(Class) {
|
|
8851
8761
|
var _cache = typeof Map === "function" ? /* @__PURE__ */ new Map() : void 0;
|
|
8852
8762
|
_wrapNativeSuper = function _wrapNativeSuper2(Class2) {
|
|
8853
|
-
if (Class2 === null || !_isNativeFunction(Class2))
|
|
8854
|
-
return Class2;
|
|
8763
|
+
if (Class2 === null || !_isNativeFunction(Class2)) return Class2;
|
|
8855
8764
|
if (typeof Class2 !== "function") {
|
|
8856
8765
|
throw new TypeError("Super expression must either be null or a function");
|
|
8857
8766
|
}
|
|
8858
8767
|
if (typeof _cache !== "undefined") {
|
|
8859
|
-
if (_cache.has(Class2))
|
|
8860
|
-
return _cache.get(Class2);
|
|
8768
|
+
if (_cache.has(Class2)) return _cache.get(Class2);
|
|
8861
8769
|
_cache.set(Class2, Wrapper);
|
|
8862
8770
|
}
|
|
8863
8771
|
function Wrapper() {
|
|
@@ -8890,8 +8798,7 @@ if (typeof process !== "undefined" && process.env && process.env.NODE_ENV !== "p
|
|
|
8890
8798
|
};
|
|
8891
8799
|
}
|
|
8892
8800
|
function convertFieldsError(errors) {
|
|
8893
|
-
if (!errors || !errors.length)
|
|
8894
|
-
return null;
|
|
8801
|
+
if (!errors || !errors.length) return null;
|
|
8895
8802
|
var fields = {};
|
|
8896
8803
|
errors.forEach(function(error) {
|
|
8897
8804
|
var field = error.field;
|
|
@@ -10569,10 +10476,8 @@ const InputNumber = (props) => {
|
|
|
10569
10476
|
return res;
|
|
10570
10477
|
};
|
|
10571
10478
|
const format2 = (value2) => {
|
|
10572
|
-
if (value2 === null)
|
|
10573
|
-
|
|
10574
|
-
if (typeof value2 === "string")
|
|
10575
|
-
value2 = parseFloat(value2);
|
|
10479
|
+
if (value2 === null) return "";
|
|
10480
|
+
if (typeof value2 === "string") value2 = parseFloat(value2);
|
|
10576
10481
|
const fixedValue = bound2(value2, Number(min), Number(max));
|
|
10577
10482
|
if (formatter) {
|
|
10578
10483
|
return formatter(fixedValue);
|
|
@@ -10616,22 +10521,18 @@ const InputNumber = (props) => {
|
|
|
10616
10521
|
}
|
|
10617
10522
|
};
|
|
10618
10523
|
const handleReduce = (e2) => {
|
|
10619
|
-
if (disabled)
|
|
10620
|
-
return;
|
|
10524
|
+
if (disabled) return;
|
|
10621
10525
|
onMinus == null ? void 0 : onMinus(e2);
|
|
10622
10526
|
update(true, e2);
|
|
10623
10527
|
};
|
|
10624
10528
|
const handlePlus = (e2) => {
|
|
10625
|
-
if (disabled)
|
|
10626
|
-
return;
|
|
10529
|
+
if (disabled) return;
|
|
10627
10530
|
onPlus == null ? void 0 : onPlus(e2);
|
|
10628
10531
|
update(false, e2);
|
|
10629
10532
|
};
|
|
10630
10533
|
const parseValue = (text) => {
|
|
10631
|
-
if (text === "")
|
|
10632
|
-
|
|
10633
|
-
if (text === "-")
|
|
10634
|
-
return null;
|
|
10534
|
+
if (text === "") return null;
|
|
10535
|
+
if (text === "-") return null;
|
|
10635
10536
|
return text;
|
|
10636
10537
|
};
|
|
10637
10538
|
const handleInputChange = (e2) => {
|
|
@@ -10748,8 +10649,7 @@ const MenuItem = forwardRef((props, ref) => {
|
|
|
10748
10649
|
}, [showPopup]);
|
|
10749
10650
|
const windowHeight = useMemo$1(() => getSystemInfoSync().windowHeight, []);
|
|
10750
10651
|
const updateItemOffset = useCallback(() => {
|
|
10751
|
-
if (!parent.lockScroll)
|
|
10752
|
-
return;
|
|
10652
|
+
if (!parent.lockScroll) return;
|
|
10753
10653
|
const p = parent.menuRef.current;
|
|
10754
10654
|
getRectByTaro(p).then((rect) => {
|
|
10755
10655
|
if (rect) {
|
|
@@ -10798,8 +10698,7 @@ const MenuItem = forwardRef((props, ref) => {
|
|
|
10798
10698
|
}, 100);
|
|
10799
10699
|
};
|
|
10800
10700
|
const isShow = () => {
|
|
10801
|
-
if (showPopup)
|
|
10802
|
-
return {};
|
|
10701
|
+
if (showPopup) return {};
|
|
10803
10702
|
return { display: "none" };
|
|
10804
10703
|
};
|
|
10805
10704
|
const getPosition = () => {
|
|
@@ -10863,7 +10762,7 @@ const MenuItem = forwardRef((props, ref) => {
|
|
|
10863
10762
|
}
|
|
10864
10763
|
},
|
|
10865
10764
|
/* @__PURE__ */ React__default.createElement(
|
|
10866
|
-
CSSTransition
|
|
10765
|
+
CSSTransition,
|
|
10867
10766
|
{
|
|
10868
10767
|
in: showPopup,
|
|
10869
10768
|
timeout: 100,
|
|
@@ -11005,10 +10904,8 @@ const Menu = (props) => {
|
|
|
11005
10904
|
(option) => option.value === (value !== void 0 ? value : defaultValue)
|
|
11006
10905
|
);
|
|
11007
10906
|
const finallyTitle = () => {
|
|
11008
|
-
if (title)
|
|
11009
|
-
|
|
11010
|
-
if (menuItemTitle && menuItemTitle[index])
|
|
11011
|
-
return menuItemTitle[index];
|
|
10907
|
+
if (title) return title;
|
|
10908
|
+
if (menuItemTitle && menuItemTitle[index]) return menuItemTitle[index];
|
|
11012
10909
|
if (selected && selected.length && selected[0].text)
|
|
11013
10910
|
return selected[0].text;
|
|
11014
10911
|
return "";
|
|
@@ -11027,8 +10924,7 @@ const Menu = (props) => {
|
|
|
11027
10924
|
style: { color: showMenuItem[index] ? activeColor : "" },
|
|
11028
10925
|
key: index,
|
|
11029
10926
|
onClick: () => {
|
|
11030
|
-
if ((!options || !options.length) && !child.props.children)
|
|
11031
|
-
return;
|
|
10927
|
+
if ((!options || !options.length) && !child.props.children) return;
|
|
11032
10928
|
!disabled && toggleMenuItem(index);
|
|
11033
10929
|
}
|
|
11034
10930
|
},
|
|
@@ -11096,8 +10992,7 @@ const NumberKeyboard = (props) => {
|
|
|
11096
10992
|
{ id: "0", type: "num" },
|
|
11097
10993
|
{ id: "delete", type: "delete" }
|
|
11098
10994
|
];
|
|
11099
|
-
if (!custom)
|
|
11100
|
-
return customKeys;
|
|
10995
|
+
if (!custom) return customKeys;
|
|
11101
10996
|
if (custom.length > 0) {
|
|
11102
10997
|
customKeys[0] = { id: custom[0], type: "custom" };
|
|
11103
10998
|
}
|
|
@@ -11389,8 +11284,7 @@ const Radio = (props) => {
|
|
|
11389
11284
|
return renderByShape(context && context.shape ? context.shape : shape);
|
|
11390
11285
|
};
|
|
11391
11286
|
const handleClick = (e2) => {
|
|
11392
|
-
if (disabled || checkedStatement)
|
|
11393
|
-
return;
|
|
11287
|
+
if (disabled || checkedStatement) return;
|
|
11394
11288
|
setCheckedStatement(!checkedStatement);
|
|
11395
11289
|
};
|
|
11396
11290
|
return /* @__PURE__ */ React__default.createElement(
|
|
@@ -11634,8 +11528,7 @@ const Range = (props) => {
|
|
|
11634
11528
|
touch.move(event);
|
|
11635
11529
|
setDragStatus("draging");
|
|
11636
11530
|
const rect = await getRectByTaro(root2.current);
|
|
11637
|
-
if (!rect)
|
|
11638
|
-
return;
|
|
11531
|
+
if (!rect) return;
|
|
11639
11532
|
let delta = touch.deltaX.current;
|
|
11640
11533
|
let total = rect.width;
|
|
11641
11534
|
let diff = delta / total * scope();
|
|
@@ -11781,8 +11674,7 @@ const Rate = (props) => {
|
|
|
11781
11674
|
const onClick = (e2, index) => {
|
|
11782
11675
|
e2.preventDefault();
|
|
11783
11676
|
e2.stopPropagation();
|
|
11784
|
-
if (disabled || readOnly)
|
|
11785
|
-
return;
|
|
11677
|
+
if (disabled || readOnly) return;
|
|
11786
11678
|
let value2 = 0;
|
|
11787
11679
|
if (!(index === 1 && score === index)) {
|
|
11788
11680
|
value2 = index;
|
|
@@ -11962,8 +11854,7 @@ const SearchBar = (props) => {
|
|
|
11962
11854
|
searchSelf && searchSelf.focus();
|
|
11963
11855
|
};
|
|
11964
11856
|
const change = (event) => {
|
|
11965
|
-
if (value === event.target.value)
|
|
11966
|
-
return;
|
|
11857
|
+
if (value === event.target.value) return;
|
|
11967
11858
|
onChange && (onChange == null ? void 0 : onChange(event.target.value, event));
|
|
11968
11859
|
setValue(event.target.value);
|
|
11969
11860
|
event.target.value === "" && forceFocus();
|
|
@@ -12008,23 +11899,19 @@ const SearchBar = (props) => {
|
|
|
12008
11899
|
onInputClick && onInputClick(e2);
|
|
12009
11900
|
};
|
|
12010
11901
|
const renderLeftIn = () => {
|
|
12011
|
-
if (!leftIn)
|
|
12012
|
-
return null;
|
|
11902
|
+
if (!leftIn) return null;
|
|
12013
11903
|
return /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-leftin ${classPrefix2}-icon` }, leftIn);
|
|
12014
11904
|
};
|
|
12015
11905
|
const renderLeft = () => {
|
|
12016
|
-
if (!backable && !left2)
|
|
12017
|
-
return null;
|
|
11906
|
+
if (!backable && !left2) return null;
|
|
12018
11907
|
return /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-left` }, backable ? /* @__PURE__ */ React__default.createElement(g$5, { size: "16" }) : left2);
|
|
12019
11908
|
};
|
|
12020
11909
|
const renderRightIn = () => {
|
|
12021
|
-
if (!rightIn)
|
|
12022
|
-
return null;
|
|
11910
|
+
if (!rightIn) return null;
|
|
12023
11911
|
return /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-rightin ${classPrefix2}-icon` }, rightIn);
|
|
12024
11912
|
};
|
|
12025
11913
|
const renderRight = () => {
|
|
12026
|
-
if (!right2)
|
|
12027
|
-
return null;
|
|
11914
|
+
if (!right2) return null;
|
|
12028
11915
|
return /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right` }, right2);
|
|
12029
11916
|
};
|
|
12030
11917
|
const handleClear = () => {
|
|
@@ -12378,8 +12265,7 @@ const Switch = (props) => {
|
|
|
12378
12265
|
return `${classPrefix2} ${value ? "nut-switch-open" : "nut-switch-close"} ${disabled ? `${classPrefix2}-disabled` : ""} ${`${classPrefix2}-base`} ${className}`;
|
|
12379
12266
|
};
|
|
12380
12267
|
const onClick = (event) => {
|
|
12381
|
-
if (disabled)
|
|
12382
|
-
return;
|
|
12268
|
+
if (disabled) return;
|
|
12383
12269
|
onChange && onChange(!value, event);
|
|
12384
12270
|
setValue(!value);
|
|
12385
12271
|
};
|
|
@@ -12449,17 +12335,13 @@ const TextArea = (props) => {
|
|
|
12449
12335
|
}
|
|
12450
12336
|
};
|
|
12451
12337
|
const handleFocus = (event) => {
|
|
12452
|
-
if (disabled)
|
|
12453
|
-
|
|
12454
|
-
if (readOnly)
|
|
12455
|
-
return;
|
|
12338
|
+
if (disabled) return;
|
|
12339
|
+
if (readOnly) return;
|
|
12456
12340
|
onFocus && onFocus(event);
|
|
12457
12341
|
};
|
|
12458
12342
|
const handleBlur = (event) => {
|
|
12459
|
-
if (disabled)
|
|
12460
|
-
|
|
12461
|
-
if (readOnly)
|
|
12462
|
-
return;
|
|
12343
|
+
if (disabled) return;
|
|
12344
|
+
if (readOnly) return;
|
|
12463
12345
|
onBlur && onBlur(event);
|
|
12464
12346
|
};
|
|
12465
12347
|
return /* @__PURE__ */ React__default.createElement(
|
|
@@ -13487,14 +13369,11 @@ const BaseDialog = (props) => {
|
|
|
13487
13369
|
);
|
|
13488
13370
|
const refObject = useLockScrollTaro(!!(visible && lockScroll));
|
|
13489
13371
|
const renderFooter = () => {
|
|
13490
|
-
if (footer === null)
|
|
13491
|
-
return "";
|
|
13372
|
+
if (footer === null) return "";
|
|
13492
13373
|
const handleCancel = (e2) => {
|
|
13493
13374
|
e2.stopPropagation();
|
|
13494
|
-
if (!(beforeCancel == null ? void 0 : beforeCancel()))
|
|
13495
|
-
|
|
13496
|
-
if (!(beforeClose == null ? void 0 : beforeClose()))
|
|
13497
|
-
return;
|
|
13375
|
+
if (!(beforeCancel == null ? void 0 : beforeCancel())) return;
|
|
13376
|
+
if (!(beforeClose == null ? void 0 : beforeClose())) return;
|
|
13498
13377
|
onClose == null ? void 0 : onClose();
|
|
13499
13378
|
onCancel == null ? void 0 : onCancel();
|
|
13500
13379
|
};
|
|
@@ -13532,13 +13411,10 @@ const BaseDialog = (props) => {
|
|
|
13532
13411
|
));
|
|
13533
13412
|
};
|
|
13534
13413
|
const renderCloseIcon = () => {
|
|
13535
|
-
if (!closeIcon)
|
|
13536
|
-
return null;
|
|
13414
|
+
if (!closeIcon) return null;
|
|
13537
13415
|
const handleCancel = () => {
|
|
13538
|
-
if (!(beforeCancel == null ? void 0 : beforeCancel()))
|
|
13539
|
-
|
|
13540
|
-
if (!(beforeClose == null ? void 0 : beforeClose()))
|
|
13541
|
-
return;
|
|
13416
|
+
if (!(beforeCancel == null ? void 0 : beforeCancel())) return;
|
|
13417
|
+
if (!(beforeClose == null ? void 0 : beforeClose())) return;
|
|
13542
13418
|
onClose == null ? void 0 : onClose();
|
|
13543
13419
|
onCancel == null ? void 0 : onCancel();
|
|
13544
13420
|
};
|
|
@@ -13572,7 +13448,7 @@ const BaseDialog = (props) => {
|
|
|
13572
13448
|
className: classNames("nut-dialog-overlay")
|
|
13573
13449
|
}
|
|
13574
13450
|
) : null, /* @__PURE__ */ React__default.createElement(
|
|
13575
|
-
CSSTransition
|
|
13451
|
+
CSSTransition,
|
|
13576
13452
|
{
|
|
13577
13453
|
in: visible,
|
|
13578
13454
|
timeout: 300,
|
|
@@ -14044,8 +13920,7 @@ const NoticeBar = (props) => {
|
|
|
14044
13920
|
const { childs, childCount } = useMemo$1(() => {
|
|
14045
13921
|
let childCount2 = 0;
|
|
14046
13922
|
const childs2 = React__default.Children.map(children, (child) => {
|
|
14047
|
-
if (!React__default.isValidElement(child))
|
|
14048
|
-
return null;
|
|
13923
|
+
if (!React__default.isValidElement(child)) return null;
|
|
14049
13924
|
childCount2++;
|
|
14050
13925
|
return child;
|
|
14051
13926
|
});
|
|
@@ -14168,8 +14043,7 @@ const NoticeBar = (props) => {
|
|
|
14168
14043
|
marginTop: animate ? `-${height}px` : ""
|
|
14169
14044
|
};
|
|
14170
14045
|
const init = (active2 = 0) => {
|
|
14171
|
-
if (!(container == null ? void 0 : container.current))
|
|
14172
|
-
return;
|
|
14046
|
+
if (!(container == null ? void 0 : container.current)) return;
|
|
14173
14047
|
setTimeout(async () => {
|
|
14174
14048
|
const rects = await getRectByTaro(container == null ? void 0 : container.current);
|
|
14175
14049
|
const _active = Math.max(Math.min(childCount - 1, active2), 0);
|
|
@@ -14207,8 +14081,7 @@ const NoticeBar = (props) => {
|
|
|
14207
14081
|
swiperRef.current.autoplayTimer = null;
|
|
14208
14082
|
};
|
|
14209
14083
|
const autoplay = () => {
|
|
14210
|
-
if (childCount <= 1)
|
|
14211
|
-
return;
|
|
14084
|
+
if (childCount <= 1) return;
|
|
14212
14085
|
stopAutoPlay();
|
|
14213
14086
|
swiperRef.current.autoplayTimer = setTimeout(
|
|
14214
14087
|
() => {
|
|
@@ -14219,8 +14092,7 @@ const NoticeBar = (props) => {
|
|
|
14219
14092
|
);
|
|
14220
14093
|
};
|
|
14221
14094
|
const move = ({ pace = 0, offset: offset2 = 0 }) => {
|
|
14222
|
-
if (childCount <= 1)
|
|
14223
|
-
return;
|
|
14095
|
+
if (childCount <= 1) return;
|
|
14224
14096
|
const targetActive = getActive(pace);
|
|
14225
14097
|
const targetOffset = getOffset(targetActive, offset2);
|
|
14226
14098
|
if (Array.isArray(children) && children[0] && targetOffset !== minOffset) {
|
|
@@ -14455,7 +14327,7 @@ const Notify = (props) => {
|
|
|
14455
14327
|
[`${classPrefix$d}-${type4}`]: true
|
|
14456
14328
|
});
|
|
14457
14329
|
return /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement(
|
|
14458
|
-
CSSTransition
|
|
14330
|
+
CSSTransition,
|
|
14459
14331
|
{
|
|
14460
14332
|
in: showNotify,
|
|
14461
14333
|
timeout: 300,
|
|
@@ -14771,10 +14643,10 @@ const Popover = (props) => {
|
|
|
14771
14643
|
Popover.displayName = "NutPopover";
|
|
14772
14644
|
function bound(position, min, max) {
|
|
14773
14645
|
let ret = position;
|
|
14774
|
-
|
|
14646
|
+
{
|
|
14775
14647
|
ret = Math.max(position, min);
|
|
14776
14648
|
}
|
|
14777
|
-
|
|
14649
|
+
{
|
|
14778
14650
|
ret = Math.min(ret, max);
|
|
14779
14651
|
}
|
|
14780
14652
|
return ret;
|
|
@@ -14783,8 +14655,7 @@ function rubberband(distance, dimension, constant) {
|
|
|
14783
14655
|
return distance * dimension * constant / (dimension + constant * distance);
|
|
14784
14656
|
}
|
|
14785
14657
|
function rubberbandIfOutOfBounds(position, min, max, dimension, constant = 0.15) {
|
|
14786
|
-
if (constant === 0)
|
|
14787
|
-
return bound(position, min, max);
|
|
14658
|
+
if (constant === 0) return bound(position, min, max);
|
|
14788
14659
|
if (position < min)
|
|
14789
14660
|
return -rubberband(min - position, dimension, constant) + min;
|
|
14790
14661
|
if (position > max)
|
|
@@ -14846,14 +14717,10 @@ const PullToRefresh = (p) => {
|
|
|
14846
14717
|
if (props.renderText) {
|
|
14847
14718
|
return (_a = props.renderText) == null ? void 0 : _a.call(props, status);
|
|
14848
14719
|
}
|
|
14849
|
-
if (status === "pulling")
|
|
14850
|
-
|
|
14851
|
-
if (status === "
|
|
14852
|
-
|
|
14853
|
-
if (status === "refreshing")
|
|
14854
|
-
return props.refreshingText;
|
|
14855
|
-
if (status === "complete")
|
|
14856
|
-
return props.completeText;
|
|
14720
|
+
if (status === "pulling") return props.pullingText;
|
|
14721
|
+
if (status === "canRelease") return props.canReleaseText;
|
|
14722
|
+
if (status === "refreshing") return props.refreshingText;
|
|
14723
|
+
if (status === "complete") return props.completeText;
|
|
14857
14724
|
return "";
|
|
14858
14725
|
};
|
|
14859
14726
|
const handleTouchStart = (e2) => {
|
|
@@ -14863,8 +14730,7 @@ const PullToRefresh = (p) => {
|
|
|
14863
14730
|
if (props.scrollTop > 0) {
|
|
14864
14731
|
return;
|
|
14865
14732
|
}
|
|
14866
|
-
if (status === "refreshing" || status === "complete")
|
|
14867
|
-
return;
|
|
14733
|
+
if (status === "refreshing" || status === "complete") return;
|
|
14868
14734
|
touch.move(e2);
|
|
14869
14735
|
if (touch.isVertical()) {
|
|
14870
14736
|
pullingRef.current = true;
|
|
@@ -15145,7 +15011,7 @@ function preventDefault(event, isStopPropagation) {
|
|
|
15145
15011
|
if (typeof event.cancelable !== "boolean" || event.cancelable) {
|
|
15146
15012
|
event.preventDefault();
|
|
15147
15013
|
}
|
|
15148
|
-
|
|
15014
|
+
{
|
|
15149
15015
|
event.stopPropagation();
|
|
15150
15016
|
}
|
|
15151
15017
|
}
|
|
@@ -15217,7 +15083,7 @@ const Swipe = forwardRef((props, instanceRef) => {
|
|
|
15217
15083
|
const newState = { ...state, dragging: true };
|
|
15218
15084
|
const isEdge = !opened || touch.deltaX.current * startOffset.current < 0;
|
|
15219
15085
|
if (isEdge) {
|
|
15220
|
-
preventDefault(event
|
|
15086
|
+
preventDefault(event);
|
|
15221
15087
|
}
|
|
15222
15088
|
newState.offset = rangeCalculation(
|
|
15223
15089
|
touch.deltaX.current + startOffset.current,
|
|
@@ -16232,8 +16098,7 @@ const InternalCountDown = (props, ref) => {
|
|
|
16232
16098
|
// 设置了 startTime 时,与 date.now() 的差异
|
|
16233
16099
|
});
|
|
16234
16100
|
const getTimeStamp = (timeStr) => {
|
|
16235
|
-
if (!timeStr)
|
|
16236
|
-
return Date.now();
|
|
16101
|
+
if (!timeStr) return Date.now();
|
|
16237
16102
|
let t = timeStr;
|
|
16238
16103
|
t = Number(t) > 0 ? +t : t.toString().replace(/-/g, "/");
|
|
16239
16104
|
return new Date(t).getTime();
|
|
@@ -16245,8 +16110,7 @@ const InternalCountDown = (props, ref) => {
|
|
|
16245
16110
|
stateRef.current.handleEndTime = endTime;
|
|
16246
16111
|
stateRef.current.diffTime = Date.now() - getTimeStamp(startTime);
|
|
16247
16112
|
}
|
|
16248
|
-
if (!stateRef.current.counting)
|
|
16249
|
-
stateRef.current.counting = true;
|
|
16113
|
+
if (!stateRef.current.counting) stateRef.current.counting = true;
|
|
16250
16114
|
tick();
|
|
16251
16115
|
};
|
|
16252
16116
|
const tick = () => {
|
|
@@ -16515,8 +16379,7 @@ const Ellipsis = (props) => {
|
|
|
16515
16379
|
]
|
|
16516
16380
|
},
|
|
16517
16381
|
(res) => {
|
|
16518
|
-
if (!res)
|
|
16519
|
-
return;
|
|
16382
|
+
if (!res) return;
|
|
16520
16383
|
lineH.current = pxToNumber(
|
|
16521
16384
|
res.lineHeight === "normal" ? lineHeight : res.lineHeight
|
|
16522
16385
|
);
|
|
@@ -16640,8 +16503,7 @@ const Ellipsis = (props) => {
|
|
|
16640
16503
|
return content.slice(cutoff, end);
|
|
16641
16504
|
};
|
|
16642
16505
|
const pxToNumber = (value) => {
|
|
16643
|
-
if (!value)
|
|
16644
|
-
return 0;
|
|
16506
|
+
if (!value) return 0;
|
|
16645
16507
|
const match = value.match(/^\d*(\.\d*)?/);
|
|
16646
16508
|
return match ? Number(match[0]) : 0;
|
|
16647
16509
|
};
|
|
@@ -16814,8 +16676,7 @@ const Swiper = forwardRef((props, ref) => {
|
|
|
16814
16676
|
setCurrent(defaultValue);
|
|
16815
16677
|
}, [defaultValue]);
|
|
16816
16678
|
const renderIndicator = () => {
|
|
16817
|
-
if (React__default.isValidElement(indicator))
|
|
16818
|
-
return indicator;
|
|
16679
|
+
if (React__default.isValidElement(indicator)) return indicator;
|
|
16819
16680
|
if (indicator) {
|
|
16820
16681
|
return /* @__PURE__ */ React__default.createElement(
|
|
16821
16682
|
"div",
|
|
@@ -17255,8 +17116,7 @@ const Pagination = (props) => {
|
|
|
17255
17116
|
return items;
|
|
17256
17117
|
}, [currentPage, itemSize, pageCount]);
|
|
17257
17118
|
const handleSelectPage = (curPage) => {
|
|
17258
|
-
if (curPage > pageCount || curPage < 1)
|
|
17259
|
-
return;
|
|
17119
|
+
if (curPage > pageCount || curPage < 1) return;
|
|
17260
17120
|
setCurrentPage(curPage);
|
|
17261
17121
|
};
|
|
17262
17122
|
return /* @__PURE__ */ React__default.createElement("div", { className: classNames(classPrefix2, className), ...rest }, (mode === "multi" || mode === "simple") && /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement(
|
|
@@ -17415,8 +17275,7 @@ const Step = (props) => {
|
|
|
17415
17275
|
const dot = parent.propSteps.dot;
|
|
17416
17276
|
const getCurrentStatus = () => {
|
|
17417
17277
|
const index = value;
|
|
17418
|
-
if (index < +parent.propSteps.value)
|
|
17419
|
-
return "finish";
|
|
17278
|
+
if (index < +parent.propSteps.value) return "finish";
|
|
17420
17279
|
return index === +parent.propSteps.value ? "process" : "wait";
|
|
17421
17280
|
};
|
|
17422
17281
|
const handleClickStep = () => {
|
|
@@ -17647,6 +17506,10 @@ const Table = (props) => {
|
|
|
17647
17506
|
});
|
|
17648
17507
|
};
|
|
17649
17508
|
const renderBodyTds = (item, rowIndex) => {
|
|
17509
|
+
const { rowRender } = item;
|
|
17510
|
+
if (rowRender && typeof rowRender === "function") {
|
|
17511
|
+
return rowRender(item, rowIndex);
|
|
17512
|
+
}
|
|
17650
17513
|
return sortDataItem().map(([value, render]) => {
|
|
17651
17514
|
return /* @__PURE__ */ React__default.createElement(
|
|
17652
17515
|
"div",
|
|
@@ -18071,22 +17934,13 @@ const updateItemSize = (positions, items, sizeKey, margin) => {
|
|
|
18071
17934
|
Array.from(items).forEach((item) => {
|
|
18072
17935
|
const index = Number(item.getAttribute("data-index"));
|
|
18073
17936
|
const styleVal = item.getAttribute("style");
|
|
18074
|
-
if (styleVal && styleVal.includes("none"))
|
|
18075
|
-
return;
|
|
17937
|
+
if (styleVal && styleVal.includes("none")) return;
|
|
18076
17938
|
let nowSize = item.getBoundingClientRect()[sizeKey];
|
|
18077
|
-
if (margin)
|
|
18078
|
-
nowSize += margin;
|
|
17939
|
+
if (margin) nowSize += margin;
|
|
18079
17940
|
const oldSize = positions[index][sizeKey];
|
|
18080
17941
|
const dValue = oldSize - nowSize;
|
|
18081
17942
|
if (dValue) {
|
|
18082
|
-
|
|
18083
|
-
newPos[index].right -= dValue;
|
|
18084
|
-
newPos[index][sizeKey] = nowSize;
|
|
18085
|
-
for (let k2 = index + 1; k2 < positions.length; k2++) {
|
|
18086
|
-
newPos[k2].left = positions[k2 - 1].right;
|
|
18087
|
-
newPos[k2].right -= dValue;
|
|
18088
|
-
}
|
|
18089
|
-
} else if (sizeKey === "height") {
|
|
17943
|
+
{
|
|
18090
17944
|
newPos[index].bottom -= dValue;
|
|
18091
17945
|
newPos[index][sizeKey] = nowSize;
|
|
18092
17946
|
for (let k2 = index + 1; k2 < positions.length; k2++) {
|
|
@@ -18152,8 +18006,7 @@ const VirtualList = (props) => {
|
|
|
18152
18006
|
});
|
|
18153
18007
|
}, [itemHeight, overscan, offSetSize]);
|
|
18154
18008
|
useEffect(() => {
|
|
18155
|
-
if (containerHeight)
|
|
18156
|
-
return;
|
|
18009
|
+
if (containerHeight) return;
|
|
18157
18010
|
setOffSetSize(getContainerHeight());
|
|
18158
18011
|
}, [containerHeight]);
|
|
18159
18012
|
useEffect(() => {
|
|
@@ -18177,11 +18030,9 @@ const VirtualList = (props) => {
|
|
|
18177
18030
|
return list.slice(start.current, Math.min(end(), list.length));
|
|
18178
18031
|
};
|
|
18179
18032
|
const updateTotalSize = useCallback(() => {
|
|
18180
|
-
if (!itemsRef.current)
|
|
18181
|
-
return;
|
|
18033
|
+
if (!itemsRef.current) return;
|
|
18182
18034
|
const items = itemsRef.current.children;
|
|
18183
|
-
if (!items.length)
|
|
18184
|
-
return;
|
|
18035
|
+
if (!items.length) return;
|
|
18185
18036
|
updateItemSize(positions, items, "height", margin);
|
|
18186
18037
|
}, [positions]);
|
|
18187
18038
|
const listScroll = (e2) => {
|
|
@@ -18975,8 +18826,7 @@ const AvatarCropper = (props) => {
|
|
|
18975
18826
|
const canvas2dDraw = useCallback(
|
|
18976
18827
|
(ctx) => {
|
|
18977
18828
|
const { src, width, height, x, y } = drawImage;
|
|
18978
|
-
if (!ctx || !src)
|
|
18979
|
-
return;
|
|
18829
|
+
if (!ctx || !src) return;
|
|
18980
18830
|
const {
|
|
18981
18831
|
moveX,
|
|
18982
18832
|
moveY,
|
|
@@ -19044,8 +18894,7 @@ const AvatarCropper = (props) => {
|
|
|
19044
18894
|
} = state;
|
|
19045
18895
|
const { cropperCanvasContext } = canvasAll;
|
|
19046
18896
|
const ctx = cropperCanvasContext;
|
|
19047
|
-
if (!ctx)
|
|
19048
|
-
return;
|
|
18897
|
+
if (!ctx) return;
|
|
19049
18898
|
ctx.clearRect(0, 0, displayWidth, displayHeight);
|
|
19050
18899
|
ctx.fillStyle = "#666";
|
|
19051
18900
|
ctx.setFillStyle("#666");
|
|
@@ -19414,7 +19263,7 @@ export {
|
|
|
19414
19263
|
NumberKeyboard,
|
|
19415
19264
|
Overlay,
|
|
19416
19265
|
Pagination,
|
|
19417
|
-
Picker
|
|
19266
|
+
Picker,
|
|
19418
19267
|
Popover,
|
|
19419
19268
|
Popup,
|
|
19420
19269
|
Price,
|