@nutui/nutui-react-taro 2.6.19 → 2.6.21
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 +25 -9
- package/dist/esm/Address.js +1 -1
- package/dist/esm/Audio.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/Calendar.js +1 -1
- package/dist/esm/CalendarCard.js +1 -1
- package/dist/esm/CalendarItem.js +1 -1
- package/dist/esm/Cascader.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/Ellipsis.js +1 -1
- package/dist/esm/Empty.js +1 -1
- package/dist/esm/FixedNav.js +1 -1
- package/dist/esm/Grid.js +1 -1
- package/dist/esm/GridItem.js +1 -1
- package/dist/esm/InfiniteLoading.js +1 -1
- package/dist/esm/Input.js +1 -1
- package/dist/esm/NoticeBar.js +1 -1
- package/dist/esm/NumberKeyboard.js +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/Progress.js +1 -1
- package/dist/esm/PullToRefresh.js +1 -1
- package/dist/esm/Range.js +1 -1
- package/dist/esm/SearchBar.js +1 -1
- package/dist/esm/ShortPassword.js +1 -1
- package/dist/esm/Signature.js +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.js +1 -1
- package/dist/esm/TextArea.js +1 -1
- package/dist/esm/TimeSelect.js +1 -1
- package/dist/esm/Tour.js +1 -1
- package/dist/esm/Uploader.js +1 -1
- package/dist/esm/WaterMark.js +1 -1
- package/dist/esm/{address.taro-DErzR2nE.js → address.taro-CWr6jIYg.js} +2 -2
- package/dist/esm/{audio.taro-C8UEIiBR.js → audio.taro--yoX2oyx.js} +2 -2
- package/dist/esm/{avatarcropper.taro-Bmx6gexj.js → avatarcropper.taro-B0I9uLNp.js} +14 -5
- package/dist/esm/{backtop.taro-jWlJ1ZWG.js → backtop.taro-CpzSXDW3.js} +1 -1
- package/dist/esm/{badge.taro-BGaxpEYi.js → badge.taro-B42_7q8v.js} +1 -1
- package/dist/esm/{barrage.taro-CA-9uADD.js → barrage.taro-D2lmvcB-.js} +40 -26
- package/dist/esm/{calendar.taro-CuPrPO_2.js → calendar.taro-Csq-7imv.js} +2 -2
- package/dist/esm/{calendarcard.taro-CbvCWF1k.js → calendarcard.taro-CvWyBqnr.js} +1 -1
- package/dist/esm/{calendaritem.taro-DbaK10II.js → calendaritem.taro-BOMJjsx9.js} +1 -1
- package/dist/esm/{cascader.taro-Cad_4Sqw.js → cascader.taro-DZ_oBTm0.js} +4 -2
- package/dist/esm/{configprovider.taro-DA4GDDFu.js → configprovider.taro-C3WyeHSO.js} +4 -0
- package/dist/esm/{countdown.taro-mKXeisK0.js → countdown.taro-Dyryl4pq.js} +0 -3
- package/dist/esm/{datepicker.taro-DjTr__43.js → datepicker.taro-DibmSueg.js} +2 -2
- package/dist/esm/{dialog.taro-CzGba5-2.js → dialog.taro-Bg730q8d.js} +1 -1
- package/dist/esm/{ellipsis.taro-Ba2Kokb7.js → ellipsis.taro-fvcP85Ir.js} +1 -1
- package/dist/esm/{empty.taro-CnwDznke.js → empty.taro-Dr4eSaDg.js} +0 -2
- package/dist/esm/{fixednav.taro-eCRdeuqJ.js → fixednav.taro-BodErnYy.js} +1 -1
- package/dist/esm/{grid.taro-ZJywVaVe.js → grid.taro-Bi-DXjbo.js} +1 -1
- package/dist/esm/{griditem.taro-CcWyYchl.js → griditem.taro-DMvds46i.js} +0 -2
- package/dist/esm/{infiniteloading.taro-TbcBB0Qr.js → infiniteloading.taro-DzIrZvc0.js} +1 -1
- package/dist/esm/{input.taro-DbAbbzIX.js → input.taro-CA9ZpM9a.js} +1 -1
- package/dist/esm/{noticebar.taro-CGUTg60Q.js → noticebar.taro-BjKDC7We.js} +1 -1
- package/dist/esm/{numberkeyboard.taro-B1LfptyA.js → numberkeyboard.taro-CIlStObb.js} +1 -1
- package/dist/esm/nutui-react.es.js +41 -41
- package/dist/esm/{pagination.taro-D0HOQwW2.js → pagination.taro-BSwytb0-.js} +1 -1
- package/dist/esm/{picker.taro-D9CKPl5K.js → picker.taro-mCnxpFCY.js} +1 -1
- package/dist/esm/{popover.taro-BvMcsCRf.js → popover.taro-BHcidbZG.js} +1 -1
- package/dist/esm/{progress.taro-De9-206U.js → progress.taro-CaIUT9Uo.js} +1 -1
- package/dist/esm/{pulltorefresh.taro-DSr2dBjM.js → pulltorefresh.taro-BiSDwLpA.js} +1 -1
- package/dist/esm/{range.taro-D_qsx_j6.js → range.taro-BilM3sMH.js} +1 -1
- package/dist/esm/{searchbar.taro-C8cg7NeJ.js → searchbar.taro-LaO2Xr2t.js} +1 -1
- package/dist/esm/{shortpassword.taro-DPmvilhN.js → shortpassword.taro-ByEtEDDl.js} +1 -1
- package/dist/esm/{signature.taro-zgwaJkIE.js → signature.taro-BW4eiGIR.js} +1 -1
- package/dist/esm/{tabbar.taro-CXk0zLdz.js → tabbar.taro-BiQDgZQF.js} +1 -1
- package/dist/esm/{tabbaritem.taro-BZNabTBp.js → tabbaritem.taro-BiIVucQz.js} +1 -1
- package/dist/esm/{table.taro-B6WCKTkO.js → table.taro-1nFkDxbh.js} +1 -1
- package/dist/esm/{tabs.taro-8X51sTol.js → tabs.taro-CJiI4q_-.js} +1 -1
- package/dist/esm/{textarea.taro-DuceTjAx.js → textarea.taro-EJQxRHZR.js} +1 -1
- package/dist/esm/{timeselect.taro-BqP2APht.js → timeselect.taro-DE_a87DT.js} +1 -1
- package/dist/esm/{tour.taro-XysJDnqf.js → tour.taro-BvBZa8nq.js} +1 -1
- package/dist/esm/{uploader.taro-Do8LZqUn.js → uploader.taro-DZyZiEi2.js} +11 -14
- package/dist/esm/{watermark.taro-CZ6R5FlJ.js → watermark.taro-CbO7mKFD.js} +1 -1
- package/dist/locales/base.d.ts +7 -0
- package/dist/locales/base.js +1 -1
- package/dist/locales/en-US.js +5 -1
- package/dist/locales/id-ID.js +5 -1
- package/dist/locales/tr-TR.js +5 -1
- package/dist/locales/zh-CN.js +5 -1
- package/dist/locales/zh-TW.js +5 -1
- package/dist/locales/zh-UG.js +5 -1
- package/dist/nutui.react.es.js +74 -52
- package/dist/nutui.react.umd.js +74 -52
- package/dist/types/index.d.ts +196 -196
- package/dist/types/locales/base.d.ts +7 -0
- package/dist/types/packages/searchbar/searchbar.d.ts +0 -14
- package/dist/types/packages/searchbar/searchbar.taro.d.ts +14 -14
- package/dist/types/packages/uploader/uploader.d.ts +1 -0
- package/dist/types/packages/uploader/uploader.taro.d.ts +5 -3
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,15 +1,31 @@
|
|
|
1
|
-
# v2.6.
|
|
2
|
-
`2024-09-
|
|
1
|
+
# v2.6.21
|
|
2
|
+
`2024-09-27`
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
* 🏡 chore: update dependency linguist-languages to be included within package (#2607)
|
|
6
|
+
* :sparkles: feat(Uploader): add support for deleteIcon prop customization (#2618)
|
|
7
|
+
* :bug: fix: 修改jd小程序高版本弹幕不滚动问题 (#2612)
|
|
8
|
+
|
|
3
9
|
|
|
10
|
+
# v2.6.20
|
|
4
11
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
+
`2024-09-20`
|
|
13
|
+
|
|
14
|
+
- :bug: fix: i18n (#2597)
|
|
15
|
+
- :bug: fix: 类型构建错误 (#2605)
|
|
16
|
+
- 🏡 chore: replace local prettier plugin with npm package (#2603)
|
|
17
|
+
|
|
18
|
+
# v2.6.19
|
|
19
|
+
|
|
20
|
+
`2024-09-13`
|
|
12
21
|
|
|
22
|
+
- 🏡 chore(deps): update dependency vite-plugin-dts to v4 (#2533)
|
|
23
|
+
- :bug: fix(cascader): 受控状态下 value 变化时同步组件选中状态 (#2591)
|
|
24
|
+
- :bug: fix: 移除不必要的 fragment 元素 (#2587)
|
|
25
|
+
- :bug: fix(datepicker): show zero on page (#2582)
|
|
26
|
+
- :bug: fix: findDomNode from transition (#2525)
|
|
27
|
+
- :bug: fix(props): add mergeProps utility to resolve all defaultProps warnings (#2581)
|
|
28
|
+
- 🪵 refactor: resolve sass nested rules warning (#2579)
|
|
13
29
|
|
|
14
30
|
# v2.6.18
|
|
15
31
|
|
package/dist/esm/Address.js
CHANGED
package/dist/esm/Audio.js
CHANGED
package/dist/esm/BackTop.js
CHANGED
package/dist/esm/Badge.js
CHANGED
package/dist/esm/Barrage.js
CHANGED
package/dist/esm/Calendar.js
CHANGED
package/dist/esm/CalendarCard.js
CHANGED
package/dist/esm/CalendarItem.js
CHANGED
package/dist/esm/Cascader.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as ConfigProvider } from "./configprovider.taro-
|
|
2
|
-
import { g, s, u, a } from "./configprovider.taro-
|
|
1
|
+
import { C as ConfigProvider } from "./configprovider.taro-C3WyeHSO.js";
|
|
2
|
+
import { g, s, u, a } from "./configprovider.taro-C3WyeHSO.js";
|
|
3
3
|
export {
|
|
4
4
|
ConfigProvider as default,
|
|
5
5
|
g as getDefaultConfig,
|
package/dist/esm/CountDown.js
CHANGED
package/dist/esm/DatePicker.js
CHANGED
package/dist/esm/Dialog.js
CHANGED
package/dist/esm/Ellipsis.js
CHANGED
package/dist/esm/Empty.js
CHANGED
package/dist/esm/FixedNav.js
CHANGED
package/dist/esm/Grid.js
CHANGED
package/dist/esm/GridItem.js
CHANGED
package/dist/esm/Input.js
CHANGED
package/dist/esm/NoticeBar.js
CHANGED
package/dist/esm/Pagination.js
CHANGED
package/dist/esm/Picker.js
CHANGED
package/dist/esm/Popover.js
CHANGED
package/dist/esm/Progress.js
CHANGED
package/dist/esm/Range.js
CHANGED
package/dist/esm/SearchBar.js
CHANGED
package/dist/esm/Signature.js
CHANGED
package/dist/esm/Tabbar.js
CHANGED
package/dist/esm/TabbarItem.js
CHANGED
package/dist/esm/Table.js
CHANGED
package/dist/esm/Tabs.js
CHANGED
package/dist/esm/TextArea.js
CHANGED
package/dist/esm/TimeSelect.js
CHANGED
package/dist/esm/Tour.js
CHANGED
package/dist/esm/Uploader.js
CHANGED
package/dist/esm/WaterMark.js
CHANGED
|
@@ -3,8 +3,8 @@ import React__default, { forwardRef, useState, useImperativeHandle } from "react
|
|
|
3
3
|
import { Check, Location, ArrowLeft } from "@nutui/icons-react-taro";
|
|
4
4
|
import { P as Popup } from "./popup.taro-DV32k5dP.js";
|
|
5
5
|
import { ScrollView } from "@tarojs/components";
|
|
6
|
-
import { u as useConfig } from "./configprovider.taro-
|
|
7
|
-
import { C as Cascader } from "./cascader.taro-
|
|
6
|
+
import { u as useConfig } from "./configprovider.taro-C3WyeHSO.js";
|
|
7
|
+
import { C as Cascader } from "./cascader.taro-DZ_oBTm0.js";
|
|
8
8
|
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
9
9
|
import { u as usePropsValue } from "./use-props-value-SH9krhkx.js";
|
|
10
10
|
const defaultProps$2 = {
|
|
@@ -2,9 +2,9 @@ import { _ as __rest } from "./tslib.es6-iWu3F_1J.js";
|
|
|
2
2
|
import React__default, { useState, useRef } from "react";
|
|
3
3
|
import { createInnerAudioContext } from "@tarojs/taro";
|
|
4
4
|
import { Service } from "@nutui/icons-react-taro";
|
|
5
|
-
import { R as Range } from "./range.taro-
|
|
5
|
+
import { R as Range } from "./range.taro-BilM3sMH.js";
|
|
6
6
|
import { B as Button } from "./button.taro-1kEru6r9.js";
|
|
7
|
-
import { u as useConfig } from "./configprovider.taro-
|
|
7
|
+
import { u as useConfig } from "./configprovider.taro-C3WyeHSO.js";
|
|
8
8
|
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
9
9
|
const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { className: "", url: "", style: {}, autoplay: false, loop: false, type: "progress", onFastBack: (ctx) => {
|
|
10
10
|
}, onForward: (ctx) => {
|
|
@@ -4,17 +4,26 @@ import Taro, { useReady, createSelectorQuery } from "@tarojs/taro";
|
|
|
4
4
|
import classNames from "classnames";
|
|
5
5
|
import { Canvas } from "@tarojs/components";
|
|
6
6
|
import { B as Button } from "./button.taro-1kEru6r9.js";
|
|
7
|
+
import { u as useConfig } from "./configprovider.taro-C3WyeHSO.js";
|
|
7
8
|
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
8
9
|
import { u as useTouch } from "./use-touch-BeiLHDO9.js";
|
|
9
10
|
import { p as preventDefault, c as clamp } from "./index-DeNfBlua.js";
|
|
10
11
|
const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { maxZoom: 3, space: 10, toolbar: [
|
|
11
|
-
React__default.createElement(Button, { type: "danger", key: "cancel" }, "
|
|
12
|
-
React__default.createElement(Button, { key: "reset" }, "
|
|
13
|
-
React__default.createElement(Button, { key: "rotate" }, "
|
|
14
|
-
React__default.createElement(Button, { type: "success", key: "confirm" }, "
|
|
15
|
-
], toolbarPosition: "bottom", editText: "
|
|
12
|
+
React__default.createElement(Button, { type: "danger", key: "cancel" }, "Cancel"),
|
|
13
|
+
React__default.createElement(Button, { key: "reset" }, "Reset"),
|
|
14
|
+
React__default.createElement(Button, { key: "rotate" }, "Rotate"),
|
|
15
|
+
React__default.createElement(Button, { type: "success", key: "confirm" }, "Confirm")
|
|
16
|
+
], toolbarPosition: "bottom", editText: "Edit", sizeType: ["original", "compressed"], sourceType: ["album", "camera"], shape: "square" });
|
|
16
17
|
const classPrefix = `nut-avatar-cropper`;
|
|
17
18
|
const AvatarCropper = (props) => {
|
|
19
|
+
const { locale } = useConfig();
|
|
20
|
+
defaultProps.toolbar = [
|
|
21
|
+
React__default.createElement(Button, { type: "danger", key: "cancel" }, locale.cancel),
|
|
22
|
+
React__default.createElement(Button, { key: "reset" }, locale.reset),
|
|
23
|
+
React__default.createElement(Button, { key: "rotate" }, locale.avatarCropper.rotate),
|
|
24
|
+
React__default.createElement(Button, { type: "success", key: "confirm" }, locale.confirm)
|
|
25
|
+
];
|
|
26
|
+
defaultProps.editText = locale.edit;
|
|
18
27
|
const _a = Object.assign(Object.assign({}, defaultProps), props), { children, toolbar, maxZoom, space, toolbarPosition, editText, sizeType, sourceType, shape, className, style, onConfirm, onCancel } = _a, rest = __rest(_a, ["children", "toolbar", "maxZoom", "space", "toolbarPosition", "editText", "sizeType", "sourceType", "shape", "className", "style", "onConfirm", "onCancel"]);
|
|
19
28
|
const cls = classNames(classPrefix, "taro", className, shape === "round" && "round");
|
|
20
29
|
const toolbarPositionCls = classNames(`${classPrefix}-popup-toolbar`, toolbarPosition);
|
|
@@ -3,7 +3,7 @@ import { usePageScroll, pageScrollTo } from "@tarojs/taro";
|
|
|
3
3
|
import { Top } from "@nutui/icons-react-taro";
|
|
4
4
|
import classNames from "classnames";
|
|
5
5
|
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
6
|
-
import { a as useRtl } from "./configprovider.taro-
|
|
6
|
+
import { a as useRtl } from "./configprovider.taro-C3WyeHSO.js";
|
|
7
7
|
const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { threshold: 200, zIndex: 900, duration: 1e3 });
|
|
8
8
|
const BackTop = (props) => {
|
|
9
9
|
const rtl = useRtl();
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React__default from "react";
|
|
2
2
|
import classNames from "classnames";
|
|
3
3
|
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
4
|
-
import { a as useRtl } from "./configprovider.taro-
|
|
4
|
+
import { a as useRtl } from "./configprovider.taro-C3WyeHSO.js";
|
|
5
5
|
const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { value: "", dot: false, max: 99, top: "4", right: "8", color: "", fill: "solid" });
|
|
6
6
|
const Badge = (props) => {
|
|
7
7
|
var _a;
|
|
@@ -12,6 +12,7 @@ const InternalBarrage = (props, ref) => {
|
|
|
12
12
|
const barrageContainer = useRef(null);
|
|
13
13
|
const barrageCWidth = useRef(0);
|
|
14
14
|
const timer = useRef(0);
|
|
15
|
+
const domTimer = useRef(0);
|
|
15
16
|
const index = useRef(0);
|
|
16
17
|
const times = useRef([]);
|
|
17
18
|
const historyIndex = useRef(-1);
|
|
@@ -33,25 +34,31 @@ const InternalBarrage = (props, ref) => {
|
|
|
33
34
|
}
|
|
34
35
|
return 0;
|
|
35
36
|
});
|
|
37
|
+
const clearDomTimeout = () => {
|
|
38
|
+
if (domTimer.current) {
|
|
39
|
+
clearTimeout(domTimer.current);
|
|
40
|
+
domTimer.current = 0;
|
|
41
|
+
}
|
|
42
|
+
};
|
|
36
43
|
useEffect(() => {
|
|
37
44
|
const init = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
45
|
+
var _a2;
|
|
38
46
|
if (barrageBody.current) {
|
|
39
47
|
barrageCWidth.current = yield getNodeWidth(barrageBody.current);
|
|
48
|
+
(_a2 = barrageBody.current) === null || _a2 === void 0 ? void 0 : _a2.style.setProperty("--move-distance", `-${barrageCWidth.current}px`);
|
|
49
|
+
index.current = 0;
|
|
50
|
+
run();
|
|
40
51
|
}
|
|
41
52
|
});
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
var _a2;
|
|
45
|
-
(_a2 = barrageBody.current) === null || _a2 === void 0 ? void 0 : _a2.style.setProperty("--move-distance", `-${barrageCWidth.current}px`);
|
|
46
|
-
index.current = 0;
|
|
47
|
-
run();
|
|
53
|
+
domTimer.current = window.setTimeout(() => {
|
|
54
|
+
init();
|
|
48
55
|
}, 300);
|
|
49
56
|
return () => {
|
|
50
|
-
|
|
57
|
+
clearDomTimeout();
|
|
51
58
|
};
|
|
52
59
|
}, [list]);
|
|
53
60
|
const run = () => {
|
|
54
|
-
|
|
61
|
+
clearTimeout(timer.current);
|
|
55
62
|
let intervalCache = interval;
|
|
56
63
|
const _index = (loop ? index.current % list.length : index.current) % rows;
|
|
57
64
|
const result = times.current[_index] - rows * interval;
|
|
@@ -62,7 +69,28 @@ const InternalBarrage = (props, ref) => {
|
|
|
62
69
|
play();
|
|
63
70
|
}, intervalCache);
|
|
64
71
|
};
|
|
65
|
-
const
|
|
72
|
+
const setStyle = (el, currentIndex) => __awaiter(void 0, void 0, void 0, function* () {
|
|
73
|
+
try {
|
|
74
|
+
if (el) {
|
|
75
|
+
const refe = yield getRectByTaro(el);
|
|
76
|
+
const width = refe.width;
|
|
77
|
+
const height = refe.height;
|
|
78
|
+
el.classList.add("move");
|
|
79
|
+
const elScrollDuration = Math.round(width / barrageCWidth.current * duration);
|
|
80
|
+
times.current[currentIndex] = elScrollDuration;
|
|
81
|
+
el.style.animationDuration = `${duration + elScrollDuration}ms`;
|
|
82
|
+
el.style.top = `${currentIndex * (height + gapY) + 20}px`;
|
|
83
|
+
el.style.width = `${width}px`;
|
|
84
|
+
}
|
|
85
|
+
} catch (error) {
|
|
86
|
+
console.log("异常自动流转到下一个", error);
|
|
87
|
+
barrageContainer.current.removeChild(el);
|
|
88
|
+
}
|
|
89
|
+
el.addEventListener("animationend", () => {
|
|
90
|
+
barrageContainer.current.removeChild(el);
|
|
91
|
+
});
|
|
92
|
+
});
|
|
93
|
+
const play = () => {
|
|
66
94
|
if (!loop && index.current >= list.length) {
|
|
67
95
|
return;
|
|
68
96
|
}
|
|
@@ -74,26 +102,12 @@ const InternalBarrage = (props, ref) => {
|
|
|
74
102
|
}
|
|
75
103
|
historyIndex.current = currentIndex;
|
|
76
104
|
el.innerHTML = list[_index];
|
|
77
|
-
el.classList.add("barrage-item");
|
|
78
105
|
barrageContainer.current.appendChild(el);
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
const height = yield getNodeWidth(el, "height");
|
|
82
|
-
el.classList.add("move");
|
|
83
|
-
const elScrollDuration = width / barrageCWidth.current * duration;
|
|
84
|
-
times.current[currentIndex] = Math.ceil(elScrollDuration);
|
|
85
|
-
el.style.animationDuration = `${(duration + elScrollDuration).toFixed(2)}ms`;
|
|
86
|
-
el.style.top = `${currentIndex * (height + gapY) + 20}px`;
|
|
87
|
-
el.style.width = `${width}px`;
|
|
88
|
-
} catch (error) {
|
|
89
|
-
console.log("异常自动流转到下一个");
|
|
90
|
-
}
|
|
91
|
-
el.addEventListener("animationend", () => {
|
|
92
|
-
barrageContainer.current.removeChild(el);
|
|
93
|
-
});
|
|
106
|
+
el.classList.add("barrage-item");
|
|
107
|
+
requestAnimationFrame(() => setStyle(el, currentIndex));
|
|
94
108
|
index.current++;
|
|
95
109
|
run();
|
|
96
|
-
}
|
|
110
|
+
};
|
|
97
111
|
return React__default.createElement(
|
|
98
112
|
View,
|
|
99
113
|
Object.assign({ className: classes, ref: barrageBody }, restProps),
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React__default, { useRef } from "react";
|
|
2
2
|
import { P as Popup } from "./popup.taro-DV32k5dP.js";
|
|
3
|
-
import { C as CalendarItem } from "./calendaritem.taro-
|
|
3
|
+
import { C as CalendarItem } from "./calendaritem.taro-BOMJjsx9.js";
|
|
4
4
|
import { U as Utils } from "./date-CYwRNlGq.js";
|
|
5
|
-
import { u as useConfig } from "./configprovider.taro-
|
|
5
|
+
import { u as useConfig } from "./configprovider.taro-C3WyeHSO.js";
|
|
6
6
|
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
7
7
|
const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { type: "single", autoBackfill: false, popup: true, visible: false, title: "", defaultValue: "", startDate: Utils.getDay(0), endDate: Utils.getDay(365), showToday: true, startText: "", endText: "", confirmText: "", showTitle: true, showSubTitle: true, scrollAnimation: true, firstDayOfWeek: 0, disableDate: (date) => false, renderHeaderButtons: void 0, renderDay: void 0, renderDayTop: void 0, renderDayBottom: void 0, onClose: () => {
|
|
8
8
|
}, onConfirm: (param) => {
|
|
@@ -3,7 +3,7 @@ import classNames from "classnames";
|
|
|
3
3
|
import { View } from "@tarojs/components";
|
|
4
4
|
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
5
5
|
import { U as Utils } from "./date-CYwRNlGq.js";
|
|
6
|
-
import { u as useConfig } from "./configprovider.taro-
|
|
6
|
+
import { u as useConfig } from "./configprovider.taro-C3WyeHSO.js";
|
|
7
7
|
import { u as usePropsValue } from "./use-props-value-SH9krhkx.js";
|
|
8
8
|
const left = "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxOCIgaGVpZ2h0PSIxOCIgdmlld0JveD0iMCAwIDE4IDE4Ij48cGF0aCBkPSJNNi42MDUgOS40OWEuNzcxLjc3MSAwIDAgMSAwLS45OGwzLjYtNC4zNzJhLjc3MS43NzEgMCAwIDEgMS4xOS45ODFMOC4yIDlsMy4xOTcgMy44ODFhLjc3MS43NzEgMCAxIDEtMS4xOTEuOThsLTMuNi00LjM3eiIvPjwvc3ZnPg==";
|
|
9
9
|
const right = "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxOCIgaGVpZ2h0PSIxOCIgdmlld0JveD0iMCAwIDE4IDE4Ij48cGF0aCBkPSJNMTEuMzk2IDkuNDlhLjc3MS43NzEgMCAwIDAgMC0uOThsLTMuNi00LjM3MmEuNzcxLjc3MSAwIDAgMC0xLjE5MS45ODFMOS44IDlsLTMuMTk2IDMuODgxYS43NzEuNzcxIDAgMCAwIDEuMTkuOThsMy42LTQuMzd6Ii8+PC9zdmc+";
|
|
@@ -5,7 +5,7 @@ import Taro, { nextTick } from "@tarojs/taro";
|
|
|
5
5
|
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
6
6
|
import { U as Utils, g as getPreMonthDates, a as getDaysStatus, b as getCurrMonthData } from "./date-CYwRNlGq.js";
|
|
7
7
|
import { r as requestAniFrame } from "./raf-zwv-SBjP.js";
|
|
8
|
-
import { u as useConfig } from "./configprovider.taro-
|
|
8
|
+
import { u as useConfig } from "./configprovider.taro-C3WyeHSO.js";
|
|
9
9
|
import { u as usePropsValue } from "./use-props-value-SH9krhkx.js";
|
|
10
10
|
const splitDate = (date) => {
|
|
11
11
|
const split = date.indexOf("-") !== -1 ? "-" : "/";
|
|
@@ -4,9 +4,10 @@ import classNames from "classnames";
|
|
|
4
4
|
import { Loading, Checklist } from "@nutui/icons-react-taro";
|
|
5
5
|
import { ScrollView } from "@tarojs/components";
|
|
6
6
|
import { P as Popup } from "./popup.taro-DV32k5dP.js";
|
|
7
|
-
import { T as Tabs } from "./tabs.taro-
|
|
7
|
+
import { T as Tabs } from "./tabs.taro-CJiI4q_-.js";
|
|
8
8
|
import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
|
|
9
9
|
import { u as usePropsValue } from "./use-props-value-SH9krhkx.js";
|
|
10
|
+
import { u as useConfig } from "./configprovider.taro-C3WyeHSO.js";
|
|
10
11
|
const formatTree = (tree, parent, config) => tree.map((node) => {
|
|
11
12
|
const { value: valueKey = "value", text: textKey = "text", children: childrenKey = "children" } = config;
|
|
12
13
|
const _a = node, _b = valueKey, value = _a[_b], _c = textKey, text = _a[_c], _d = childrenKey, children = _a[_d], others = __rest(_a, [typeof _b === "symbol" ? _b : _b + "", typeof _c === "symbol" ? _c : _c + "", typeof _d === "symbol" ? _d : _d + ""]);
|
|
@@ -125,6 +126,7 @@ const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { activ
|
|
|
125
126
|
}, onPathChange: () => {
|
|
126
127
|
} });
|
|
127
128
|
const InternalCascader = (props, ref) => {
|
|
129
|
+
const { locale } = useConfig();
|
|
128
130
|
const { className, style, activeColor, activeIcon, popup, popupProps = {}, visible, options, value, defaultValue, optionKey, format, closeable, closeIconPosition, closeIcon, lazy, title, left, onLoad, onClose, onChange, onPathChange } = Object.assign(Object.assign({}, defaultProps), props);
|
|
129
131
|
const [tabvalue, setTabvalue] = useState("c1");
|
|
130
132
|
const [optionsData, setOptionsData] = useState([]);
|
|
@@ -380,7 +382,7 @@ const InternalCascader = (props, ref) => {
|
|
|
380
382
|
"span",
|
|
381
383
|
{ className: "nut-tabs-titles-item-text" },
|
|
382
384
|
!state.initLoading && state.panes.length && ((_a = pane === null || pane === void 0 ? void 0 : pane.selectedNode) === null || _a === void 0 ? void 0 : _a.text),
|
|
383
|
-
!state.initLoading && state.panes.length && !((_b = pane === null || pane === void 0 ? void 0 : pane.selectedNode) === null || _b === void 0 ? void 0 : _b.text) &&
|
|
385
|
+
!state.initLoading && state.panes.length && !((_b = pane === null || pane === void 0 ? void 0 : pane.selectedNode) === null || _b === void 0 ? void 0 : _b.text) && `${locale.select}`,
|
|
384
386
|
!(!state.initLoading && state.panes.length) && "Loading..."
|
|
385
387
|
),
|
|
386
388
|
React__default.createElement("span", { className: "nut-tabs-titles-item-line" })
|
|
@@ -20,6 +20,8 @@ const zhCN = {
|
|
|
20
20
|
noData: "暂无数据",
|
|
21
21
|
placeholder: "请输入内容",
|
|
22
22
|
select: "请选择",
|
|
23
|
+
edit: "编辑",
|
|
24
|
+
reset: "重置",
|
|
23
25
|
video: {
|
|
24
26
|
errorTip: "视频加载失败",
|
|
25
27
|
clickRetry: "点击重试"
|
|
@@ -57,6 +59,7 @@ const zhCN = {
|
|
|
57
59
|
tips: "忘记密码"
|
|
58
60
|
},
|
|
59
61
|
uploader: {
|
|
62
|
+
list: "上传文件",
|
|
60
63
|
ready: "准备完成",
|
|
61
64
|
readyUpload: "准备上传",
|
|
62
65
|
waitingUpload: "等待上传",
|
|
@@ -123,6 +126,7 @@ const zhCN = {
|
|
|
123
126
|
mute: "静音",
|
|
124
127
|
tips: "onPlayEnd事件在loop=false时才会触发"
|
|
125
128
|
},
|
|
129
|
+
avatarCropper: { rotate: "旋转", selectImage: "选择图片" },
|
|
126
130
|
datepicker: {
|
|
127
131
|
year: "年",
|
|
128
132
|
month: "月",
|