@nutui/nutui-react-taro 2.6.18 → 2.6.19

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.
Files changed (75) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/dist/esm/ActionSheet.js +1 -1
  3. package/dist/esm/Address.js +1 -1
  4. package/dist/esm/AnimatingNumbers.js +2 -2
  5. package/dist/esm/Audio.js +1 -1
  6. package/dist/esm/AvatarCropper.js +1 -1
  7. package/dist/esm/Calendar.js +1 -1
  8. package/dist/esm/CalendarItem.js +1 -1
  9. package/dist/esm/Cascader.js +1 -1
  10. package/dist/esm/DatePicker.js +1 -1
  11. package/dist/esm/Dialog.js +1 -1
  12. package/dist/esm/Ellipsis.js +1 -1
  13. package/dist/esm/FixedNav.js +1 -1
  14. package/dist/esm/ImagePreview.js +1 -1
  15. package/dist/esm/InputNumber.js +1 -1
  16. package/dist/esm/Layout.js +1 -1
  17. package/dist/esm/Menu.js +1 -1
  18. package/dist/esm/MenuItem.js +1 -1
  19. package/dist/esm/Notify.js +1 -1
  20. package/dist/esm/NumberKeyboard.js +1 -1
  21. package/dist/esm/Overlay.js +1 -1
  22. package/dist/esm/Pagination.js +1 -1
  23. package/dist/esm/Picker.js +1 -1
  24. package/dist/esm/Popover.js +1 -1
  25. package/dist/esm/Popup.js +1 -1
  26. package/dist/esm/ShortPassword.js +1 -1
  27. package/dist/esm/SideNavBar.js +1 -1
  28. package/dist/esm/TimeSelect.js +1 -1
  29. package/dist/esm/Toast.js +1 -1
  30. package/dist/esm/Tour.js +1 -1
  31. package/dist/esm/{actionsheet.taro-CJjNsNrH.js → actionsheet.taro-CgfXnK1M.js} +3 -2
  32. package/dist/esm/{address.taro-CH4lcI54.js → address.taro-DErzR2nE.js} +2 -2
  33. package/dist/esm/{audio.taro-CD-vP_u0.js → audio.taro-C8UEIiBR.js} +4 -8
  34. package/dist/esm/{avatarcropper.taro-CAVcFvKC.js → avatarcropper.taro-Bmx6gexj.js} +11 -19
  35. package/dist/esm/{calendar.taro-BXrHr8bg.js → calendar.taro-CuPrPO_2.js} +2 -2
  36. package/dist/esm/{calendaritem.taro-CRultyrO.js → calendaritem.taro-DbaK10II.js} +5 -9
  37. package/dist/esm/{cascader.taro-4QSI_vGC.js → cascader.taro-Cad_4Sqw.js} +4 -1
  38. package/dist/esm/{datepicker.taro-BxaZ3Fjv.js → datepicker.taro-DjTr__43.js} +2 -2
  39. package/dist/esm/{dialog.taro-BW9D2Gsr.js → dialog.taro-CzGba5-2.js} +3 -3
  40. package/dist/esm/{ellipsis.taro-Ck2rumQ6.js → ellipsis.taro-Ba2Kokb7.js} +9 -13
  41. package/dist/esm/{fixednav.taro-D3KnhYoI.js → fixednav.taro-eCRdeuqJ.js} +1 -1
  42. package/dist/esm/{imagepreview.taro-0D3hjS6s.js → imagepreview.taro-C0yMREHT.js} +1 -1
  43. package/dist/esm/{inputnumber.taro-D9mteLSI.js → inputnumber.taro-DPRZtV42.js} +1 -5
  44. package/dist/esm/{layout.taro-C-aUcOOE.js → layout.taro-DpiuZLLE.js} +1 -3
  45. package/dist/esm/{menu.taro-CLbOM_Z4.js → menu.taro-BFc4uUxG.js} +1 -1
  46. package/dist/esm/{menuitem.taro-CNaseNcY.js → menuitem.taro-D6KQvdRw.js} +4 -3
  47. package/dist/esm/merge-props-2rRqFlJz.js +16 -0
  48. package/dist/esm/{notify.taro-jP7y9zMU.js → notify.taro-BVXg7xTI.js} +5 -4
  49. package/dist/esm/{numberkeyboard.taro-Cz6rKxk3.js → numberkeyboard.taro-B1LfptyA.js} +1 -1
  50. package/dist/esm/nutui-react.es.js +28 -28
  51. package/dist/esm/{overlay.taro-C2t82CZz.js → overlay.taro-C8eXSsJH.js} +3 -7
  52. package/dist/esm/{pagination.taro-DdLO3OTc.js → pagination.taro-D0HOQwW2.js} +4 -8
  53. package/dist/esm/{picker.taro-CafNRRO5.js → picker.taro-D9CKPl5K.js} +2 -2
  54. package/dist/esm/{popover.taro-B_FJgU0z.js → popover.taro-BvMcsCRf.js} +1 -1
  55. package/dist/esm/{popup.taro-CR3JyuJV.js → popup.taro-DV32k5dP.js} +6 -6
  56. package/dist/esm/{shortpassword.taro-DpdtRsQ-.js → shortpassword.taro-DPmvilhN.js} +1 -1
  57. package/dist/esm/{sidenavbar.taro-5BmrYFtP.js → sidenavbar.taro-DNwoQw9u.js} +1 -1
  58. package/dist/esm/{timeselect.taro-DncKbp3l.js → timeselect.taro-BqP2APht.js} +1 -1
  59. package/dist/esm/{toast.taro-CYk6UERn.js → toast.taro-Tx0IHbsl.js} +3 -3
  60. package/dist/esm/{tour.taro-SPMrhDA9.js → tour.taro-XysJDnqf.js} +1 -1
  61. package/dist/locales/base.js +1 -1
  62. package/dist/locales/en-US.js +1 -1
  63. package/dist/locales/id-ID.js +1 -1
  64. package/dist/locales/tr-TR.js +1 -1
  65. package/dist/locales/zh-CN.js +1 -1
  66. package/dist/locales/zh-TW.js +1 -1
  67. package/dist/locales/zh-UG.js +1 -1
  68. package/dist/nutui.react.es.js +61 -49
  69. package/dist/nutui.react.umd.js +61 -49
  70. package/dist/packages/elevator/elevator.scss +1 -2
  71. package/dist/packages/popover/popover.scss +3 -3
  72. package/dist/packages/tabs/tabs.scss +3 -3
  73. package/dist/packages/uploader/uploader.scss +1 -2
  74. package/dist/types/utils/merge-props.d.ts +9 -5
  75. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,3 +1,16 @@
1
+ # v2.6.19
2
+ `2024-09-13`
3
+
4
+
5
+ * 🏡 chore(deps): update dependency vite-plugin-dts to v4 (#2533)
6
+ * :bug: fix(cascader): 受控状态下 value 变化时同步组件选中状态 (#2591)
7
+ * :bug: fix: 移除不必要的 fragment 元素 (#2587)
8
+ * :bug: fix(datepicker): show zero on page (#2582)
9
+ * :bug: fix: findDomNode from transition (#2525)
10
+ * :bug: fix(props): add mergeProps utility to resolve all defaultProps warnings (#2581)
11
+ * 🪵 refactor: resolve sass nested rules warning (#2579)
12
+
13
+
1
14
  # v2.6.18
2
15
 
3
16
  `2024-09-06`
@@ -1,4 +1,4 @@
1
- import { A as ActionSheet } from "./actionsheet.taro-CJjNsNrH.js";
1
+ import { A as ActionSheet } from "./actionsheet.taro-CgfXnK1M.js";
2
2
  export {
3
3
  ActionSheet as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { A as Address } from "./address.taro-CH4lcI54.js";
1
+ import { A as Address } from "./address.taro-DErzR2nE.js";
2
2
  export {
3
3
  Address as default
4
4
  };
@@ -2,9 +2,10 @@ import React__default, { useRef, useState, useEffect, Component } from "react";
2
2
  import { _ as __rest } from "./tslib.es6-iWu3F_1J.js";
3
3
  import { createSelectorQuery } from "@tarojs/taro";
4
4
  import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
5
+ import { m as mergeProps } from "./merge-props-2rRqFlJz.js";
5
6
  const defaultProps$1 = Object.assign(Object.assign({}, ComponentDefaults), { length: 0, value: "", delay: 300, duration: 1, thousands: false });
6
7
  const CountUp = (props) => {
7
- const _a = Object.assign(Object.assign({}, defaultProps$1), props), { length, value, delay, duration, className, thousands, style } = _a;
8
+ const _a = mergeProps(defaultProps$1, props), { length, value, delay, duration, className, thousands, style } = _a;
8
9
  __rest(_a, ["length", "value", "delay", "duration", "className", "thousands", "style"]);
9
10
  const classPrefix = "nut-countup";
10
11
  const countupRef = useRef(null);
@@ -67,7 +68,6 @@ const CountUp = (props) => {
67
68
  }))
68
69
  );
69
70
  };
70
- CountUp.defaultProps = defaultProps$1;
71
71
  CountUp.displayName = "NutCountUp";
72
72
  const defaultProps = {};
73
73
  class AnimatingNumbers extends Component {
package/dist/esm/Audio.js CHANGED
@@ -1,4 +1,4 @@
1
- import { A as Audio } from "./audio.taro-CD-vP_u0.js";
1
+ import { A as Audio } from "./audio.taro-C8UEIiBR.js";
2
2
  export {
3
3
  Audio as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { A as AvatarCropper } from "./avatarcropper.taro-CAVcFvKC.js";
1
+ import { A as AvatarCropper } from "./avatarcropper.taro-Bmx6gexj.js";
2
2
  export {
3
3
  AvatarCropper as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { C as Calendar } from "./calendar.taro-BXrHr8bg.js";
1
+ import { C as Calendar } from "./calendar.taro-CuPrPO_2.js";
2
2
  export {
3
3
  Calendar as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { C as CalendarItem } from "./calendaritem.taro-CRultyrO.js";
1
+ import { C as CalendarItem } from "./calendaritem.taro-DbaK10II.js";
2
2
  export {
3
3
  CalendarItem as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { C as Cascader } from "./cascader.taro-4QSI_vGC.js";
1
+ import { C as Cascader } from "./cascader.taro-Cad_4Sqw.js";
2
2
  export {
3
3
  Cascader as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { D as DatePicker } from "./datepicker.taro-BxaZ3Fjv.js";
1
+ import { D as DatePicker } from "./datepicker.taro-DjTr__43.js";
2
2
  export {
3
3
  DatePicker as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { B as BaseDialog } from "./dialog.taro-BW9D2Gsr.js";
1
+ import { B as BaseDialog } from "./dialog.taro-CzGba5-2.js";
2
2
  export {
3
3
  BaseDialog as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { E as Ellipsis } from "./ellipsis.taro-Ck2rumQ6.js";
1
+ import { E as Ellipsis } from "./ellipsis.taro-Ba2Kokb7.js";
2
2
  export {
3
3
  Ellipsis as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { F as FixedNav } from "./fixednav.taro-D3KnhYoI.js";
1
+ import { F as FixedNav } from "./fixednav.taro-eCRdeuqJ.js";
2
2
  export {
3
3
  FixedNav as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { I as ImagePreview } from "./imagepreview.taro-0D3hjS6s.js";
1
+ import { I as ImagePreview } from "./imagepreview.taro-C0yMREHT.js";
2
2
  export {
3
3
  ImagePreview as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { I as InputNumber } from "./inputnumber.taro-D9mteLSI.js";
1
+ import { I as InputNumber } from "./inputnumber.taro-DPRZtV42.js";
2
2
  export {
3
3
  InputNumber as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { L as Layout } from "./layout.taro-C-aUcOOE.js";
1
+ import { L as Layout } from "./layout.taro-DpiuZLLE.js";
2
2
  export {
3
3
  Layout as default
4
4
  };
package/dist/esm/Menu.js CHANGED
@@ -1,4 +1,4 @@
1
- import { M as Menu } from "./menu.taro-CLbOM_Z4.js";
1
+ import { M as Menu } from "./menu.taro-BFc4uUxG.js";
2
2
  export {
3
3
  Menu as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { M as MenuItem } from "./menuitem.taro-CNaseNcY.js";
1
+ import { M as MenuItem } from "./menuitem.taro-D6KQvdRw.js";
2
2
  export {
3
3
  MenuItem as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { N as Notify } from "./notify.taro-jP7y9zMU.js";
1
+ import { N as Notify } from "./notify.taro-BVXg7xTI.js";
2
2
  export {
3
3
  Notify as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { N as NumberKeyboard } from "./numberkeyboard.taro-Cz6rKxk3.js";
1
+ import { N as NumberKeyboard } from "./numberkeyboard.taro-B1LfptyA.js";
2
2
  export {
3
3
  NumberKeyboard as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { O as Overlay } from "./overlay.taro-C2t82CZz.js";
1
+ import { O as Overlay } from "./overlay.taro-C8eXSsJH.js";
2
2
  export {
3
3
  Overlay as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { P as Pagination } from "./pagination.taro-DdLO3OTc.js";
1
+ import { P as Pagination } from "./pagination.taro-D0HOQwW2.js";
2
2
  export {
3
3
  Pagination as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { P as Picker } from "./picker.taro-CafNRRO5.js";
1
+ import { P as Picker } from "./picker.taro-D9CKPl5K.js";
2
2
  export {
3
3
  Picker as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { P as Popover } from "./popover.taro-B_FJgU0z.js";
1
+ import { P as Popover } from "./popover.taro-BvMcsCRf.js";
2
2
  export {
3
3
  Popover as default
4
4
  };
package/dist/esm/Popup.js CHANGED
@@ -1,4 +1,4 @@
1
- import { P as Popup } from "./popup.taro-CR3JyuJV.js";
1
+ import { P as Popup } from "./popup.taro-DV32k5dP.js";
2
2
  export {
3
3
  Popup as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { S as ShortPassword } from "./shortpassword.taro-DpdtRsQ-.js";
1
+ import { S as ShortPassword } from "./shortpassword.taro-DPmvilhN.js";
2
2
  export {
3
3
  ShortPassword as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { S as SideNavBar } from "./sidenavbar.taro-5BmrYFtP.js";
1
+ import { S as SideNavBar } from "./sidenavbar.taro-DNwoQw9u.js";
2
2
  export {
3
3
  SideNavBar as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { T as TimeSelect } from "./timeselect.taro-DncKbp3l.js";
1
+ import { T as TimeSelect } from "./timeselect.taro-BqP2APht.js";
2
2
  export {
3
3
  TimeSelect as default
4
4
  };
package/dist/esm/Toast.js CHANGED
@@ -1,4 +1,4 @@
1
- import { T as Toast } from "./toast.taro-CYk6UERn.js";
1
+ import { T as Toast } from "./toast.taro-Tx0IHbsl.js";
2
2
  export {
3
3
  Toast as default
4
4
  };
package/dist/esm/Tour.js CHANGED
@@ -1,4 +1,4 @@
1
- import { T as Tour } from "./tour.taro-SPMrhDA9.js";
1
+ import { T as Tour } from "./tour.taro-XysJDnqf.js";
2
2
  export {
3
3
  Tour as default
4
4
  };
@@ -1,12 +1,13 @@
1
1
  import { _ as __rest } from "./tslib.es6-iWu3F_1J.js";
2
2
  import React__default from "react";
3
- import { P as Popup } from "./popup.taro-CR3JyuJV.js";
3
+ import { P as Popup } from "./popup.taro-DV32k5dP.js";
4
4
  import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
5
+ import { m as mergeProps } from "./merge-props-2rRqFlJz.js";
5
6
  const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { visible: false, description: "", options: [], optionKey: { name: "name", description: "description" }, cancelText: "", onCancel: () => {
6
7
  }, onSelect: () => {
7
8
  } });
8
9
  const ActionSheet = (props) => {
9
- const _a = Object.assign(Object.assign({}, defaultProps), props), { children, cancelText, optionKey, title, description, options, onCancel, onSelect, visible, className, style } = _a, rest = __rest(_a, ["children", "cancelText", "optionKey", "title", "description", "options", "onCancel", "onSelect", "visible", "className", "style"]);
10
+ const _a = mergeProps(defaultProps, props), { children, cancelText, optionKey, title, description, options, onCancel, onSelect, visible, className, style } = _a, rest = __rest(_a, ["children", "cancelText", "optionKey", "title", "description", "options", "onCancel", "onSelect", "visible", "className", "style"]);
10
11
  const classPrefix = "nut-actionsheet";
11
12
  const cancelActionSheet = () => {
12
13
  onCancel && onCancel();
@@ -1,10 +1,10 @@
1
1
  import { _ as __rest } from "./tslib.es6-iWu3F_1J.js";
2
2
  import React__default, { forwardRef, useState, useImperativeHandle } from "react";
3
3
  import { Check, Location, ArrowLeft } from "@nutui/icons-react-taro";
4
- import { P as Popup } from "./popup.taro-CR3JyuJV.js";
4
+ import { P as Popup } from "./popup.taro-DV32k5dP.js";
5
5
  import { ScrollView } from "@tarojs/components";
6
6
  import { u as useConfig } from "./configprovider.taro-DA4GDDFu.js";
7
- import { C as Cascader } from "./cascader.taro-4QSI_vGC.js";
7
+ import { C as Cascader } from "./cascader.taro-Cad_4Sqw.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 = {
@@ -106,16 +106,12 @@ const Audio = (props) => {
106
106
  };
107
107
  const renderIcon = () => {
108
108
  return React__default.createElement(
109
- React__default.Fragment,
110
- null,
109
+ "div",
110
+ { className: `${classPrefix}-icon` },
111
111
  React__default.createElement(
112
112
  "div",
113
- { className: `${classPrefix}-icon` },
114
- React__default.createElement(
115
- "div",
116
- { className: `${classPrefix}-icon-box} ${playing ? `${classPrefix}-icon-play}` : `${classPrefix}-icon-stop}`}`, onClick: handleStatusChange },
117
- React__default.createElement(Service, { className: playing ? "nut-icon-loading" : "" })
118
- )
113
+ { className: `${classPrefix}-icon-box} ${playing ? `${classPrefix}-icon-play}` : `${classPrefix}-icon-stop}`}`, onClick: handleStatusChange },
114
+ React__default.createElement(Service, { className: playing ? "nut-icon-loading" : "" })
119
115
  )
120
116
  );
121
117
  };
@@ -380,31 +380,23 @@ const AvatarCropper = (props) => {
380
380
  };
381
381
  const ToolBar = () => {
382
382
  const actions = [cancel, reset, rotate, confirm];
383
- return React__default.createElement(
384
- React__default.Fragment,
385
- null,
386
- React__default.createElement("div", { className: `${classPrefix}-popup-toolbar-flex` }, actions.map((action, index) => React__default.createElement("div", { key: index, className: `${classPrefix}-popup-toolbar-item`, onClick: (_e) => action() }, toolbar[index])))
387
- );
383
+ return React__default.createElement("div", { className: `${classPrefix}-popup-toolbar-flex` }, actions.map((action, index) => React__default.createElement("div", { key: index, className: `${classPrefix}-popup-toolbar-item`, onClick: (_e) => action() }, toolbar[index])));
388
384
  };
389
385
  const CropperPopup = () => {
390
386
  const { canvasId } = canvasAll;
391
387
  return React__default.createElement(
392
- React__default.Fragment,
393
- null,
388
+ "div",
389
+ { className: `${classPrefix}-popup`, style: { display: visible ? "block" : "none" } },
390
+ React__default.createElement(Canvas, { id: canvasId, "canvas-id": canvasId, type: showAlipayCanvas2D ? "2d" : void 0, style: canvasStyle, className: `${classPrefix}-popup-canvas` }),
391
+ React__default.createElement(
392
+ "div",
393
+ { className: `${classPrefix}-popup-highlight`, onTouchStart, onTouchMove, onTouchEnd },
394
+ React__default.createElement("div", { className: "highlight", style: highlightStyle })
395
+ ),
394
396
  React__default.createElement(
395
397
  "div",
396
- { className: `${classPrefix}-popup`, style: { display: visible ? "block" : "none" } },
397
- React__default.createElement(Canvas, { id: canvasId, "canvas-id": canvasId, type: showAlipayCanvas2D ? "2d" : void 0, style: canvasStyle, className: `${classPrefix}-popup-canvas` }),
398
- React__default.createElement(
399
- "div",
400
- { className: `${classPrefix}-popup-highlight`, onTouchStart, onTouchMove, onTouchEnd },
401
- React__default.createElement("div", { className: "highlight", style: highlightStyle })
402
- ),
403
- React__default.createElement(
404
- "div",
405
- { className: toolbarPositionCls },
406
- React__default.createElement(ToolBar, null)
407
- )
398
+ { className: toolbarPositionCls },
399
+ React__default.createElement(ToolBar, null)
408
400
  )
409
401
  );
410
402
  };
@@ -1,6 +1,6 @@
1
1
  import React__default, { useRef } from "react";
2
- import { P as Popup } from "./popup.taro-CR3JyuJV.js";
3
- import { C as CalendarItem } from "./calendaritem.taro-CRultyrO.js";
2
+ import { P as Popup } from "./popup.taro-DV32k5dP.js";
3
+ import { C as CalendarItem } from "./calendaritem.taro-DbaK10II.js";
4
4
  import { U as Utils } from "./date-CYwRNlGq.js";
5
5
  import { u as useConfig } from "./configprovider.taro-DA4GDDFu.js";
6
6
  import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
@@ -558,15 +558,11 @@ const CalendarItem = React__default.forwardRef((props, ref) => {
558
558
  );
559
559
  };
560
560
  return React__default.createElement(
561
- React__default.Fragment,
562
- null,
563
- React__default.createElement(
564
- "div",
565
- { className: classes, style },
566
- renderHeader(),
567
- renderContent(),
568
- popup && !autoBackfill ? renderFooter() : ""
569
- )
561
+ "div",
562
+ { className: classes, style },
563
+ renderHeader(),
564
+ renderContent(),
565
+ popup && !autoBackfill ? renderFooter() : ""
570
566
  );
571
567
  });
572
568
  CalendarItem.displayName = "NutCalendarItem";
@@ -3,7 +3,7 @@ import React__default, { useState, useImperativeHandle, useEffect, isValidElemen
3
3
  import classNames from "classnames";
4
4
  import { Loading, Checklist } from "@nutui/icons-react-taro";
5
5
  import { ScrollView } from "@tarojs/components";
6
- import { P as Popup } from "./popup.taro-CR3JyuJV.js";
6
+ import { P as Popup } from "./popup.taro-DV32k5dP.js";
7
7
  import { T as Tabs } from "./tabs.taro-8X51sTol.js";
8
8
  import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
9
9
  import { u as usePropsValue } from "./use-props-value-SH9krhkx.js";
@@ -177,6 +177,9 @@ const InternalCascader = (props, ref) => {
177
177
  useEffect(() => {
178
178
  initData();
179
179
  }, [options, format]);
180
+ useEffect(() => {
181
+ syncValue();
182
+ }, [value]);
180
183
  const initData = () => __awaiter(void 0, void 0, void 0, function* () {
181
184
  state.lazyLoadMap.clear();
182
185
  if (format && Object.keys(format).length > 0) {
@@ -1,7 +1,7 @@
1
1
  import { _ as __rest } from "./tslib.es6-iWu3F_1J.js";
2
2
  import React__default, { useState, useEffect } from "react";
3
3
  import { View } from "@tarojs/components";
4
- import { P as Picker } from "./picker.taro-CafNRRO5.js";
4
+ import { P as Picker } from "./picker.taro-D9CKPl5K.js";
5
5
  import { u as useConfig } from "./configprovider.taro-DA4GDDFu.js";
6
6
  import { u as usePropsValue } from "./use-props-value-SH9krhkx.js";
7
7
  import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
@@ -241,7 +241,7 @@ const DatePicker = (props) => {
241
241
  useEffect(() => {
242
242
  setPickerOptions(columns());
243
243
  }, [selectedDate, startDate, endDate]);
244
- return React__default.createElement(View, Object.assign({ className: `nut-datepicker ${className}`, style, catchMove: true }, rest), pickerOptions.length && React__default.createElement(Picker, Object.assign({}, pickerProps, { title, visible, options: pickerOptions, onClose, onCancel, value: pickerValue, onConfirm: (options, value) => onConfirm && onConfirm(options, value), onChange: (options, value, index) => handlePickerChange(options, value, index), threeDimensional })));
244
+ return React__default.createElement(View, Object.assign({ className: `nut-datepicker ${className}`, style, catchMove: true }, rest), pickerOptions.length > 0 && React__default.createElement(Picker, Object.assign({}, pickerProps, { title, visible, options: pickerOptions, onClose, onCancel, value: pickerValue, onConfirm: (options, value) => onConfirm && onConfirm(options, value), onChange: (options, value, index) => handlePickerChange(options, value, index), threeDimensional })));
245
245
  };
246
246
  DatePicker.displayName = "NutDatePicker";
247
247
  export {
@@ -6,8 +6,9 @@ import { View } from "@tarojs/components";
6
6
  import { Close } from "@nutui/icons-react-taro";
7
7
  import { B as Button } from "./button.taro-1kEru6r9.js";
8
8
  import { u as useConfig } from "./configprovider.taro-DA4GDDFu.js";
9
- import { u as useLockScrollTaro, O as Overlay } from "./overlay.taro-C2t82CZz.js";
9
+ import { u as useLockScrollTaro, O as Overlay } from "./overlay.taro-C8eXSsJH.js";
10
10
  import { b as useParams, u as useCustomEvent, a as useCustomEventsPath, c as customEvents } from "./use-custom-event-DuP4onEm.js";
11
+ import { m as mergeProps } from "./merge-props-2rRqFlJz.js";
11
12
  const Content = (props) => {
12
13
  const { visible, title, header, footer, close: close2, footerDirection, onClick, children } = props;
13
14
  const classPrefix = "nut-dialog";
@@ -65,7 +66,7 @@ const BaseDialog = (props) => {
65
66
  const classPrefix = "nut-dialog";
66
67
  const { locale } = useConfig();
67
68
  const [loading, setLoading] = useState(false);
68
- const { params: { id, className, style, visible, footer, title, header, content, children, footerDirection, hideConfirmButton, hideCancelButton, lockScroll, disableConfirmButton, closeOnOverlayClick, onOverlayClick, confirmText, cancelText, overlay, closeIconPosition, closeIcon, onClose, onCancel, onConfirm, beforeCancel, beforeClose }, setParams } = useParams(Object.assign(Object.assign({}, defaultProps), props));
69
+ const { params: { id, className, style, visible, footer, title, header, content, children, footerDirection, hideConfirmButton, hideCancelButton, lockScroll, disableConfirmButton, closeOnOverlayClick, onOverlayClick, confirmText, cancelText, overlay, closeIconPosition, closeIcon, onClose, onCancel, onConfirm, beforeCancel, beforeClose }, setParams } = useParams(mergeProps(defaultProps, props));
69
70
  useCustomEvent(id, ({ status, options }) => {
70
71
  if (status) {
71
72
  setParams(Object.assign(Object.assign({}, options), { visible: true }));
@@ -153,7 +154,6 @@ function close(selector) {
153
154
  const path = useCustomEventsPath(selector);
154
155
  customEvents.trigger(path, { status: false });
155
156
  }
156
- BaseDialog.defaultProps = defaultProps;
157
157
  BaseDialog.displayName = "NutDialog";
158
158
  BaseDialog.open = open;
159
159
  BaseDialog.close = close;
@@ -221,19 +221,15 @@ const Ellipsis = (props) => {
221
221
  (_d = ellipsis.current) === null || _d === void 0 ? void 0 : _d.tailing
222
222
  ) : null,
223
223
  exceeded && expanded ? React__default.createElement(
224
- React__default.Fragment,
225
- null,
226
- React__default.createElement(
227
- View,
228
- { style: {
229
- width: `${!Number.isNaN(Number(width)) ? `${width}px` : "auto"}`
230
- } },
231
- content,
232
- expandText ? React__default.createElement("span", { className: "nut-ellipsis-text", onClick: (e) => {
233
- e.stopPropagation();
234
- clickHandle(2);
235
- } }, collapseText) : null
236
- )
224
+ View,
225
+ { style: {
226
+ width: `${!Number.isNaN(Number(width)) ? `${width}px` : "auto"}`
227
+ } },
228
+ content,
229
+ expandText ? React__default.createElement("span", { className: "nut-ellipsis-text", onClick: (e) => {
230
+ e.stopPropagation();
231
+ clickHandle(2);
232
+ } }, collapseText) : null
237
233
  ) : null
238
234
  )
239
235
  ),
@@ -2,7 +2,7 @@ import { _ as __rest } from "./tslib.es6-iWu3F_1J.js";
2
2
  import React__default from "react";
3
3
  import classNames from "classnames";
4
4
  import { ArrowLeft } from "@nutui/icons-react-taro";
5
- import { O as Overlay } from "./overlay.taro-C2t82CZz.js";
5
+ import { O as Overlay } from "./overlay.taro-C8eXSsJH.js";
6
6
  import { u as useConfig } from "./configprovider.taro-DA4GDDFu.js";
7
7
  import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
8
8
  const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { activeText: "", inactiveText: "", type: "right", position: {
@@ -3,7 +3,7 @@ import Taro from "@tarojs/taro";
3
3
  import { Video, Image } from "@tarojs/components";
4
4
  import classNames from "classnames";
5
5
  import { Close } from "@nutui/icons-react-taro";
6
- import { P as Popup } from "./popup.taro-CR3JyuJV.js";
6
+ import { P as Popup } from "./popup.taro-DV32k5dP.js";
7
7
  import InnerSwiper from "./Swiper.js";
8
8
  import { S as SwiperItem } from "./swiperitem.taro-BleF1EOs.js";
9
9
  import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
@@ -154,11 +154,7 @@ const InputNumber = (props) => {
154
154
  [`${classPrefix}-icon-disabled`]: shadowValue === min || disabled
155
155
  }) })
156
156
  ),
157
- React__default.createElement(
158
- React__default.Fragment,
159
- null,
160
- React__default.createElement("input", { className: "nut-number-input", type, ref: inputRef, inputMode: type === "digit" ? "decimal" : "numeric", disabled, readOnly, value: inputValue, onInput: handleInputChange, onBlur: handleBlur, onFocus: handleFocus })
161
- ),
157
+ React__default.createElement("input", { className: "nut-number-input", type, ref: inputRef, inputMode: type === "digit" ? "decimal" : "numeric", disabled, readOnly, value: inputValue, onInput: handleInputChange, onBlur: handleBlur, onFocus: handleFocus }),
162
158
  React__default.createElement(
163
159
  "div",
164
160
  { className: "nut-input-add", onClick: handlePlus },
@@ -1,7 +1,5 @@
1
1
  import React__default from "react";
2
- const defaultProps = {};
3
- const Layout = (props) => {
4
- Object.assign(Object.assign({}, defaultProps), props);
2
+ const Layout = () => {
5
3
  return React__default.createElement("div", { className: "nut-layout" }, "Layout");
6
4
  };
7
5
  Layout.displayName = "NutLayout";
@@ -2,7 +2,7 @@ import { _ as __rest } from "./tslib.es6-iWu3F_1J.js";
2
2
  import React__default, { useRef, useState, useEffect } from "react";
3
3
  import classNames from "classnames";
4
4
  import { ArrowUp, ArrowDown } from "@nutui/icons-react-taro";
5
- import { M as MenuItem } from "./menuitem.taro-CNaseNcY.js";
5
+ import { M as MenuItem } from "./menuitem.taro-D6KQvdRw.js";
6
6
  import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
7
7
  const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { activeColor: "", closeOnOverlayClick: true, scrollFixed: false, lockScroll: true, overlay: true, icon: null, onOpen: (index, from) => {
8
8
  }, onClose: (index, from) => {
@@ -1,11 +1,11 @@
1
1
  import { a as __awaiter } from "./tslib.es6-iWu3F_1J.js";
2
- import React__default, { forwardRef, useState, useEffect, useMemo, useCallback, useImperativeHandle } from "react";
2
+ import React__default, { forwardRef, useState, useRef, useEffect, useMemo, useCallback, useImperativeHandle } from "react";
3
3
  import classNames from "classnames";
4
4
  import { getSystemInfoSync, usePageScroll } from "@tarojs/taro";
5
5
  import { View } from "@tarojs/components";
6
6
  import { CSSTransition } from "react-transition-group";
7
7
  import { Check } from "@nutui/icons-react-taro";
8
- import { O as Overlay } from "./overlay.taro-C2t82CZz.js";
8
+ import { O as Overlay } from "./overlay.taro-C8eXSsJH.js";
9
9
  import { g as getRectByTaro } from "./get-rect-by-taro-THaHH07X.js";
10
10
  import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
11
11
  import { u as usePropsValue } from "./use-props-value-SH9krhkx.js";
@@ -22,6 +22,7 @@ const MenuItem = forwardRef((props, ref) => {
22
22
  onChange === null || onChange === void 0 ? void 0 : onChange(option);
23
23
  }
24
24
  });
25
+ const cssRef = useRef(null);
25
26
  useEffect(() => {
26
27
  setShowPopup(show);
27
28
  }, [show]);
@@ -118,7 +119,7 @@ const MenuItem = forwardRef((props, ref) => {
118
119
  }, className), style: Object.assign(Object.assign({}, style), isShow()) },
119
120
  React__default.createElement(
120
121
  CSSTransition,
121
- { in: showPopup, timeout: 100, classNames: direction === "down" ? "nut-menu-container-down" : "nut-menu-container-up" },
122
+ { nodeRef: cssRef, in: showPopup, timeout: 100, classNames: direction === "down" ? "nut-menu-container-down" : "nut-menu-container-up" },
122
123
  React__default.createElement(
123
124
  View,
124
125
  { className: "nut-menu-container-content" },
@@ -0,0 +1,16 @@
1
+ function mergeProps(...items) {
2
+ const ret = {};
3
+ items.forEach((item) => {
4
+ if (item) {
5
+ Object.keys(item).forEach((key) => {
6
+ if (item[key] !== void 0) {
7
+ ret[key] = item[key];
8
+ }
9
+ });
10
+ }
11
+ });
12
+ return ret;
13
+ }
14
+ export {
15
+ mergeProps as m
16
+ };
@@ -1,19 +1,21 @@
1
- import React__default, { useState, useEffect } from "react";
1
+ import React__default, { useState, useRef, useEffect } from "react";
2
2
  import classNames from "classnames";
3
3
  import { CSSTransition } from "react-transition-group";
4
4
  import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
5
5
  import { u as useCustomEvent, a as useCustomEventsPath, c as customEvents } from "./use-custom-event-DuP4onEm.js";
6
+ import { m as mergeProps } from "./merge-props-2rRqFlJz.js";
6
7
  const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { id: "", duration: 3e3, type: "danger", position: "top", visible: false, onClose: () => {
7
8
  }, onClick: () => {
8
9
  } });
9
10
  const classPrefix = "nut-notify";
10
11
  const Notify = (props) => {
11
- const { id, children, style, type, className, position, visible, duration, onClose, onClick } = Object.assign(Object.assign({}, defaultProps), props);
12
+ const { id, children, style, type, className, position, visible, duration, onClose, onClick } = mergeProps(defaultProps, props);
12
13
  useCustomEvent(id, (status) => {
13
14
  status ? show() : hide();
14
15
  });
15
16
  let timer;
16
17
  const [showNotify, setShowNotify] = useState(false);
18
+ const cssRef = useRef(null);
17
19
  useEffect(() => {
18
20
  if (visible) {
19
21
  show();
@@ -54,7 +56,7 @@ const Notify = (props) => {
54
56
  null,
55
57
  React__default.createElement(
56
58
  CSSTransition,
57
- { in: showNotify, timeout: 300, classNames: "fade", unmountOnExit: true, appear: true, position, id },
59
+ { nodeRef: cssRef, in: showNotify, timeout: 300, classNames: "fade", unmountOnExit: true, appear: true, position, id },
58
60
  React__default.createElement("div", { className: `${classes} ${className}`, style, onClick: clickHandle }, children)
59
61
  )
60
62
  );
@@ -67,7 +69,6 @@ function close(selector) {
67
69
  const path = useCustomEventsPath(selector);
68
70
  customEvents.trigger(path, false);
69
71
  }
70
- Notify.defaultProps = defaultProps;
71
72
  Notify.displayName = "NutNotify";
72
73
  Notify.open = open;
73
74
  Notify.close = close;
@@ -3,7 +3,7 @@ import React__default, { useMemo, useState } from "react";
3
3
  import classNames from "classnames";
4
4
  import { ArrowDown } from "@nutui/icons-react-taro";
5
5
  import { View } from "@tarojs/components";
6
- import { P as Popup } from "./popup.taro-CR3JyuJV.js";
6
+ import { P as Popup } from "./popup.taro-DV32k5dP.js";
7
7
  import { u as useConfig } from "./configprovider.taro-DA4GDDFu.js";
8
8
  import { C as ComponentDefaults } from "./typings-DV9RBfhj.js";
9
9
  const defaultProps = Object.assign(Object.assign({}, ComponentDefaults), { visible: false, rightActions: "", type: "default", custom: [], random: false, onClose: () => {