@nutui/nutui-react-taro 1.5.11-beta.2 → 1.5.12-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -8,7 +8,7 @@ var __publicField = (obj, key, value) => {
8
8
  return value;
9
9
  };
10
10
  /*!
11
- * @nutui/nutui-react-taro v1.5.11 Thu Jul 06 2023 16:47:25 GMT+0800 (China Standard Time)
11
+ * @nutui/nutui-react-taro v1.5.12-beta.0 Wed Jul 12 2023 16:47:44 GMT+0800 (中国标准时间)
12
12
  * (c) 2023 @jdf2e.
13
13
  * Released under the MIT License.
14
14
  */
@@ -31,15 +31,10 @@ var __publicField = (obj, key, value) => {
31
31
  }
32
32
  const React__namespace = /* @__PURE__ */ _interopNamespaceDefault(React);
33
33
  var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
34
- var classnameExports = {};
35
- var classname = {
36
- get exports() {
37
- return classnameExports;
38
- },
39
- set exports(v) {
40
- classnameExports = v;
41
- }
42
- };
34
+ function getDefaultExportFromCjs(x) {
35
+ return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
36
+ }
37
+ var classname = { exports: {} };
43
38
  var classname_production_min = {};
44
39
  var hasRequiredClassname_production_min;
45
40
  function requireClassname_production_min() {
@@ -143,13 +138,12 @@ var __publicField = (obj, key, value) => {
143
138
  classname_development.withNaming = withNaming;
144
139
  return classname_development;
145
140
  }
146
- (function(module2) {
147
- if (process.env.NODE_ENV === "production") {
148
- module2.exports = requireClassname_production_min();
149
- } else {
150
- module2.exports = requireClassname_development();
151
- }
152
- })(classname);
141
+ if (process.env.NODE_ENV === "production") {
142
+ classname.exports = requireClassname_production_min();
143
+ } else {
144
+ classname.exports = requireClassname_development();
145
+ }
146
+ var classnameExports = classname.exports;
153
147
  const cn = classnameExports.withNaming({ n: "nut-", e: "__", m: "--", v: "-" });
154
148
  const defaultProps$1v = {
155
149
  name: "",
@@ -765,6 +759,7 @@ var __publicField = (obj, key, value) => {
765
759
  return string.match(pattern) || [];
766
760
  }
767
761
  var lodash_kebabcase = kebabCase;
762
+ const kebabCase$1 = /* @__PURE__ */ getDefaultExportFromCjs(lodash_kebabcase);
768
763
  const zhCN = {
769
764
  save: "保存",
770
765
  confirm: "确认",
@@ -912,7 +907,7 @@ var __publicField = (obj, key, value) => {
912
907
  function convertThemeVarsToCSSVars(themeVars) {
913
908
  const cssVars = {};
914
909
  Object.keys(themeVars).forEach((key) => {
915
- cssVars[`--${lodash_kebabcase(key)}`] = themeVars[key];
910
+ cssVars[`--${kebabCase$1(key)}`] = themeVars[key];
916
911
  });
917
912
  return cssVars;
918
913
  }
@@ -1029,15 +1024,7 @@ var __publicField = (obj, key, value) => {
1029
1024
  };
1030
1025
  Image$1.defaultProps = defaultProps$1q;
1031
1026
  Image$1.displayName = "NutImage";
1032
- var classnamesExports = {};
1033
- var classnames = {
1034
- get exports() {
1035
- return classnamesExports;
1036
- },
1037
- set exports(v) {
1038
- classnamesExports = v;
1039
- }
1040
- };
1027
+ var classnames = { exports: {} };
1041
1028
  /*!
1042
1029
  Copyright (c) 2018 Jed Watson.
1043
1030
  Licensed under the MIT License (MIT), see
@@ -1084,7 +1071,8 @@ var __publicField = (obj, key, value) => {
1084
1071
  }
1085
1072
  })();
1086
1073
  })(classnames);
1087
- const classNames = classnamesExports;
1074
+ var classnamesExports = classnames.exports;
1075
+ const classNames = /* @__PURE__ */ getDefaultExportFromCjs(classnamesExports);
1088
1076
  const defaultOverlayProps = {
1089
1077
  zIndex: 2e3,
1090
1078
  duration: 0.3,
@@ -1210,24 +1198,8 @@ var __publicField = (obj, key, value) => {
1210
1198
  subClass.prototype.constructor = subClass;
1211
1199
  _setPrototypeOf(subClass, superClass);
1212
1200
  }
1213
- var propTypesExports = {};
1214
- var propTypes = {
1215
- get exports() {
1216
- return propTypesExports;
1217
- },
1218
- set exports(v) {
1219
- propTypesExports = v;
1220
- }
1221
- };
1222
- var reactIsExports = {};
1223
- var reactIs = {
1224
- get exports() {
1225
- return reactIsExports;
1226
- },
1227
- set exports(v) {
1228
- reactIsExports = v;
1229
- }
1230
- };
1201
+ var propTypes = { exports: {} };
1202
+ var reactIs = { exports: {} };
1231
1203
  var reactIs_production_min = {};
1232
1204
  /** @license React v16.13.1
1233
1205
  * react-is.production.min.js
@@ -1498,16 +1470,14 @@ var __publicField = (obj, key, value) => {
1498
1470
  var hasRequiredReactIs;
1499
1471
  function requireReactIs() {
1500
1472
  if (hasRequiredReactIs)
1501
- return reactIsExports;
1473
+ return reactIs.exports;
1502
1474
  hasRequiredReactIs = 1;
1503
- (function(module2) {
1504
- if (process.env.NODE_ENV === "production") {
1505
- module2.exports = requireReactIs_production_min();
1506
- } else {
1507
- module2.exports = requireReactIs_development();
1508
- }
1509
- })(reactIs);
1510
- return reactIsExports;
1475
+ if (process.env.NODE_ENV === "production") {
1476
+ reactIs.exports = requireReactIs_production_min();
1477
+ } else {
1478
+ reactIs.exports = requireReactIs_development();
1479
+ }
1480
+ return reactIs.exports;
1511
1481
  }
1512
1482
  /*
1513
1483
  object-assign
@@ -2174,6 +2144,8 @@ var __publicField = (obj, key, value) => {
2174
2144
  } else {
2175
2145
  propTypes.exports = requireFactoryWithThrowingShims()();
2176
2146
  }
2147
+ var propTypesExports = propTypes.exports;
2148
+ const PropTypes = /* @__PURE__ */ getDefaultExportFromCjs(propTypesExports);
2177
2149
  function hasClass(element, className) {
2178
2150
  if (element.classList)
2179
2151
  return !!className && element.classList.contains(className);
@@ -2203,22 +2175,22 @@ var __publicField = (obj, key, value) => {
2203
2175
  const config$1 = {
2204
2176
  disabled: false
2205
2177
  };
2206
- var timeoutsShape = process.env.NODE_ENV !== "production" ? propTypesExports.oneOfType([propTypesExports.number, propTypesExports.shape({
2207
- enter: propTypesExports.number,
2208
- exit: propTypesExports.number,
2209
- appear: propTypesExports.number
2178
+ var timeoutsShape = process.env.NODE_ENV !== "production" ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({
2179
+ enter: PropTypes.number,
2180
+ exit: PropTypes.number,
2181
+ appear: PropTypes.number
2210
2182
  }).isRequired]) : null;
2211
- var classNamesShape = process.env.NODE_ENV !== "production" ? propTypesExports.oneOfType([propTypesExports.string, propTypesExports.shape({
2212
- enter: propTypesExports.string,
2213
- exit: propTypesExports.string,
2214
- active: propTypesExports.string
2215
- }), propTypesExports.shape({
2216
- enter: propTypesExports.string,
2217
- enterDone: propTypesExports.string,
2218
- enterActive: propTypesExports.string,
2219
- exit: propTypesExports.string,
2220
- exitDone: propTypesExports.string,
2221
- exitActive: propTypesExports.string
2183
+ var classNamesShape = process.env.NODE_ENV !== "production" ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({
2184
+ enter: PropTypes.string,
2185
+ exit: PropTypes.string,
2186
+ active: PropTypes.string
2187
+ }), PropTypes.shape({
2188
+ enter: PropTypes.string,
2189
+ enterDone: PropTypes.string,
2190
+ enterActive: PropTypes.string,
2191
+ exit: PropTypes.string,
2192
+ exitDone: PropTypes.string,
2193
+ exitActive: PropTypes.string
2222
2194
  })]) : null;
2223
2195
  const TransitionGroupContext = React.createContext(null);
2224
2196
  var forceReflow = function forceReflow2(node) {
@@ -2468,10 +2440,10 @@ var __publicField = (obj, key, value) => {
2468
2440
  * (see
2469
2441
  * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).
2470
2442
  */
2471
- nodeRef: propTypesExports.shape({
2472
- current: typeof Element === "undefined" ? propTypesExports.any : function(propValue, key, componentName, location, propFullName, secret) {
2443
+ nodeRef: PropTypes.shape({
2444
+ current: typeof Element === "undefined" ? PropTypes.any : function(propValue, key, componentName, location, propFullName, secret) {
2473
2445
  var value = propValue[key];
2474
- return propTypesExports.instanceOf(value && "ownerDocument" in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);
2446
+ return PropTypes.instanceOf(value && "ownerDocument" in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);
2475
2447
  }
2476
2448
  }),
2477
2449
  /**
@@ -2488,23 +2460,23 @@ var __publicField = (obj, key, value) => {
2488
2460
  * </Transition>
2489
2461
  * ```
2490
2462
  */
2491
- children: propTypesExports.oneOfType([propTypesExports.func.isRequired, propTypesExports.element.isRequired]).isRequired,
2463
+ children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,
2492
2464
  /**
2493
2465
  * Show the component; triggers the enter or exit states
2494
2466
  */
2495
- in: propTypesExports.bool,
2467
+ in: PropTypes.bool,
2496
2468
  /**
2497
2469
  * By default the child component is mounted immediately along with
2498
2470
  * the parent `Transition` component. If you want to "lazy mount" the component on the
2499
2471
  * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay
2500
2472
  * mounted, even on "exited", unless you also specify `unmountOnExit`.
2501
2473
  */
2502
- mountOnEnter: propTypesExports.bool,
2474
+ mountOnEnter: PropTypes.bool,
2503
2475
  /**
2504
2476
  * By default the child component stays mounted after it reaches the `'exited'` state.
2505
2477
  * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.
2506
2478
  */
2507
- unmountOnExit: propTypesExports.bool,
2479
+ unmountOnExit: PropTypes.bool,
2508
2480
  /**
2509
2481
  * By default the child component does not perform the enter transition when
2510
2482
  * it first mounts, regardless of the value of `in`. If you want this
@@ -2516,15 +2488,15 @@ var __publicField = (obj, key, value) => {
2516
2488
  * > additional `.appear-*` classes, that way you can choose to style it
2517
2489
  * > differently.
2518
2490
  */
2519
- appear: propTypesExports.bool,
2491
+ appear: PropTypes.bool,
2520
2492
  /**
2521
2493
  * Enable or disable enter transitions.
2522
2494
  */
2523
- enter: propTypesExports.bool,
2495
+ enter: PropTypes.bool,
2524
2496
  /**
2525
2497
  * Enable or disable exit transitions.
2526
2498
  */
2527
- exit: propTypesExports.bool,
2499
+ exit: PropTypes.bool,
2528
2500
  /**
2529
2501
  * The duration of the transition, in milliseconds.
2530
2502
  * Required unless `addEndListener` is provided.
@@ -2574,7 +2546,7 @@ var __publicField = (obj, key, value) => {
2574
2546
  * }}
2575
2547
  * ```
2576
2548
  */
2577
- addEndListener: propTypesExports.func,
2549
+ addEndListener: PropTypes.func,
2578
2550
  /**
2579
2551
  * Callback fired before the "entering" status is applied. An extra parameter
2580
2552
  * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount
@@ -2583,7 +2555,7 @@ var __publicField = (obj, key, value) => {
2583
2555
  *
2584
2556
  * @type Function(node: HtmlElement, isAppearing: bool) -> void
2585
2557
  */
2586
- onEnter: propTypesExports.func,
2558
+ onEnter: PropTypes.func,
2587
2559
  /**
2588
2560
  * Callback fired after the "entering" status is applied. An extra parameter
2589
2561
  * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount
@@ -2592,7 +2564,7 @@ var __publicField = (obj, key, value) => {
2592
2564
  *
2593
2565
  * @type Function(node: HtmlElement, isAppearing: bool)
2594
2566
  */
2595
- onEntering: propTypesExports.func,
2567
+ onEntering: PropTypes.func,
2596
2568
  /**
2597
2569
  * Callback fired after the "entered" status is applied. An extra parameter
2598
2570
  * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount
@@ -2601,7 +2573,7 @@ var __publicField = (obj, key, value) => {
2601
2573
  *
2602
2574
  * @type Function(node: HtmlElement, isAppearing: bool) -> void
2603
2575
  */
2604
- onEntered: propTypesExports.func,
2576
+ onEntered: PropTypes.func,
2605
2577
  /**
2606
2578
  * Callback fired before the "exiting" status is applied.
2607
2579
  *
@@ -2609,7 +2581,7 @@ var __publicField = (obj, key, value) => {
2609
2581
  *
2610
2582
  * @type Function(node: HtmlElement) -> void
2611
2583
  */
2612
- onExit: propTypesExports.func,
2584
+ onExit: PropTypes.func,
2613
2585
  /**
2614
2586
  * Callback fired after the "exiting" status is applied.
2615
2587
  *
@@ -2617,7 +2589,7 @@ var __publicField = (obj, key, value) => {
2617
2589
  *
2618
2590
  * @type Function(node: HtmlElement) -> void
2619
2591
  */
2620
- onExiting: propTypesExports.func,
2592
+ onExiting: PropTypes.func,
2621
2593
  /**
2622
2594
  * Callback fired after the "exited" status is applied.
2623
2595
  *
@@ -2625,7 +2597,7 @@ var __publicField = (obj, key, value) => {
2625
2597
  *
2626
2598
  * @type Function(node: HtmlElement) -> void
2627
2599
  */
2628
- onExited: propTypesExports.func
2600
+ onExited: PropTypes.func
2629
2601
  } : {};
2630
2602
  function noop$2() {
2631
2603
  }
@@ -2864,7 +2836,7 @@ var __publicField = (obj, key, value) => {
2864
2836
  *
2865
2837
  * @type Function(node: HtmlElement, isAppearing: bool)
2866
2838
  */
2867
- onEnter: propTypesExports.func,
2839
+ onEnter: PropTypes.func,
2868
2840
  /**
2869
2841
  * A `<Transition>` callback fired immediately after the 'enter-active' or
2870
2842
  * 'appear-active' class is applied.
@@ -2873,7 +2845,7 @@ var __publicField = (obj, key, value) => {
2873
2845
  *
2874
2846
  * @type Function(node: HtmlElement, isAppearing: bool)
2875
2847
  */
2876
- onEntering: propTypesExports.func,
2848
+ onEntering: PropTypes.func,
2877
2849
  /**
2878
2850
  * A `<Transition>` callback fired immediately after the 'enter' or
2879
2851
  * 'appear' classes are **removed** and the `done` class is added to the DOM node.
@@ -2882,7 +2854,7 @@ var __publicField = (obj, key, value) => {
2882
2854
  *
2883
2855
  * @type Function(node: HtmlElement, isAppearing: bool)
2884
2856
  */
2885
- onEntered: propTypesExports.func,
2857
+ onEntered: PropTypes.func,
2886
2858
  /**
2887
2859
  * A `<Transition>` callback fired immediately after the 'exit' class is
2888
2860
  * applied.
@@ -2891,7 +2863,7 @@ var __publicField = (obj, key, value) => {
2891
2863
  *
2892
2864
  * @type Function(node: HtmlElement)
2893
2865
  */
2894
- onExit: propTypesExports.func,
2866
+ onExit: PropTypes.func,
2895
2867
  /**
2896
2868
  * A `<Transition>` callback fired immediately after the 'exit-active' is applied.
2897
2869
  *
@@ -2899,7 +2871,7 @@ var __publicField = (obj, key, value) => {
2899
2871
  *
2900
2872
  * @type Function(node: HtmlElement)
2901
2873
  */
2902
- onExiting: propTypesExports.func,
2874
+ onExiting: PropTypes.func,
2903
2875
  /**
2904
2876
  * A `<Transition>` callback fired immediately after the 'exit' classes
2905
2877
  * are **removed** and the `exit-done` class is added to the DOM node.
@@ -2908,7 +2880,7 @@ var __publicField = (obj, key, value) => {
2908
2880
  *
2909
2881
  * @type Function(node: HtmlElement)
2910
2882
  */
2911
- onExited: propTypesExports.func
2883
+ onExited: PropTypes.func
2912
2884
  }) : {};
2913
2885
  const CSSTransition$1 = CSSTransition;
2914
2886
  const defaultProps$1p = {
@@ -3301,6 +3273,7 @@ var __publicField = (obj, key, value) => {
3301
3273
  iconFontClassName,
3302
3274
  className,
3303
3275
  onClick,
3276
+ style,
3304
3277
  ...rest
3305
3278
  } = {
3306
3279
  ...defaultProps$1l,
@@ -3313,18 +3286,18 @@ var __publicField = (obj, key, value) => {
3313
3286
  return Number.isNaN(Number(value)) ? String(value) : `${value}px`;
3314
3287
  };
3315
3288
  const rootStyle = () => {
3316
- const style = {
3289
+ const rootStyle2 = {
3317
3290
  flexBasis: `${100 / +columnNum}%`
3318
3291
  };
3319
3292
  if (square) {
3320
- style.paddingTop = `${100 / +columnNum}%`;
3293
+ rootStyle2.paddingTop = `${100 / +columnNum}%`;
3321
3294
  } else if (gutter) {
3322
- style.paddingRight = pxCheck2(gutter);
3295
+ rootStyle2.paddingRight = pxCheck2(gutter);
3323
3296
  if (index >= columnNum) {
3324
- style.marginTop = pxCheck2(gutter);
3297
+ rootStyle2.marginTop = pxCheck2(gutter);
3325
3298
  }
3326
3299
  }
3327
- return style;
3300
+ return { ...rootStyle2, ...style };
3328
3301
  };
3329
3302
  const contentClass = () => {
3330
3303
  return classNames(b2("content"), {