uiw 4.21.14 → 4.21.15

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/dist/uiw.css CHANGED
@@ -30,6 +30,7 @@
30
30
  }
31
31
  .w-overlay-inline {
32
32
  position: absolute;
33
+ overflow: visible;
33
34
  overflow: initial;
34
35
  }
35
36
  .w-overlay-inline .w-overlay-container {
@@ -980,7 +981,9 @@ sup.w-badge-count {
980
981
  right: auto;
981
982
  bottom: auto;
982
983
  overflow: inherit;
984
+ width: auto;
983
985
  width: initial;
986
+ height: auto;
984
987
  height: initial;
985
988
  }
986
989
  .w-overlay.w-overlay-trigger .w-overlay-container {
@@ -1284,6 +1287,7 @@ sup.w-badge-count {
1284
1287
  }
1285
1288
  .w-timepicker-input .w-timepicker-close-btn {
1286
1289
  display: none;
1290
+ min-height: 0;
1287
1291
  min-height: initial;
1288
1292
  color: #a5a5a5;
1289
1293
  }
@@ -1756,9 +1760,13 @@ sup.w-badge-count {
1756
1760
  .w-menu-subitem-collapse {
1757
1761
  transition: height 300ms;
1758
1762
  position: relative !important;
1763
+ top: auto !important;
1759
1764
  top: initial !important;
1765
+ left: auto !important;
1760
1766
  left: initial !important;
1767
+ right: auto !important;
1761
1768
  right: initial !important;
1769
+ bottom: auto !important;
1762
1770
  bottom: initial !important;
1763
1771
  width: auto !important;
1764
1772
  overflow: hidden !important;
@@ -1868,6 +1876,7 @@ sup.w-badge-count {
1868
1876
  color: rgba(255, 255, 255, 0.65);
1869
1877
  }
1870
1878
  .w-menu-dark.w-bordered {
1879
+ box-shadow: none;
1871
1880
  box-shadow: initial;
1872
1881
  }
1873
1882
  .w-menu-dark .active {
@@ -3316,6 +3325,7 @@ a.w-list-item:hover:not(.w-disabled) {
3316
3325
  display: none !important;
3317
3326
  }
3318
3327
  .w-monthpicker .w-monthpicker-close-btn {
3328
+ min-height: 0;
3319
3329
  min-height: initial;
3320
3330
  color: #a5a5a5;
3321
3331
  cursor: pointer;
@@ -4276,6 +4286,7 @@ a.w-list-item:hover:not(.w-disabled) {
4276
4286
  padding-top: 5px;
4277
4287
  }
4278
4288
  .w-steps-dot .w-steps-item-description {
4289
+ max-width: none;
4279
4290
  max-width: initial;
4280
4291
  }
4281
4292
  .w-steps-dot .w-steps-item-error .w-steps-item-tail i:after {
@@ -4313,6 +4324,7 @@ a.w-list-item:hover:not(.w-disabled) {
4313
4324
  .w-steps-dot .w-steps-item-tail {
4314
4325
  padding: 0;
4315
4326
  width: 100%;
4327
+ position: static;
4316
4328
  position: initial;
4317
4329
  height: 2px;
4318
4330
  }
@@ -4496,6 +4508,7 @@ a.w-list-item:hover:not(.w-disabled) {
4496
4508
  }
4497
4509
  .w-slider-vertical .w-slider-bar {
4498
4510
  width: 4px;
4511
+ height: auto;
4499
4512
  height: initial;
4500
4513
  }
4501
4514
  .w-slider-vertical .w-slider-handle {
@@ -5000,6 +5013,7 @@ a.w-list-item:hover:not(.w-disabled) {
5000
5013
  display: none;
5001
5014
  }
5002
5015
  .w-tree-label {
5016
+ line-height: normal;
5003
5017
  line-height: initial;
5004
5018
  }
5005
5019
  .w-tree-label > * {
package/dist/uiw.js CHANGED
@@ -421,7 +421,7 @@ function _objectWithoutPropertiesLoose(source, excluded) {
421
421
  }
422
422
  ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/extends.js
423
423
  function _extends() {
424
- _extends = Object.assign || function (target) {
424
+ _extends = Object.assign ? Object.assign.bind() : function (target) {
425
425
  for (var i = 1; i < arguments.length; i++) {
426
426
  var source = arguments[i];
427
427
 
@@ -434,7 +434,6 @@ function _extends() {
434
434
 
435
435
  return target;
436
436
  };
437
-
438
437
  return _extends.apply(this, arguments);
439
438
  }
440
439
  // EXTERNAL MODULE: external {"root":"React","commonjs2":"react","commonjs":"react","amd":"react"}
@@ -697,11 +696,10 @@ function _asyncToGenerator(fn) {
697
696
  }
698
697
  ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js
699
698
  function _setPrototypeOf(o, p) {
700
- _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
699
+ _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
701
700
  o.__proto__ = p;
702
701
  return o;
703
702
  };
704
-
705
703
  return _setPrototypeOf(o, p);
706
704
  }
707
705
  ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js
@@ -765,6 +763,10 @@ var external_root_ReactDOM_commonjs2_react_dom_commonjs_react_dom_amd_react_dom_
765
763
  ;// CONCATENATED MODULE: ../../node_modules/react-transition-group/esm/TransitionGroupContext.js
766
764
 
767
765
  /* harmony default export */ const TransitionGroupContext = (external_root_React_commonjs2_react_commonjs_react_amd_react_default().createContext(null));
766
+ ;// CONCATENATED MODULE: ../../node_modules/react-transition-group/esm/utils/reflow.js
767
+ var forceReflow = function forceReflow(node) {
768
+ return node.scrollTop;
769
+ };
768
770
  ;// CONCATENATED MODULE: ../../node_modules/react-transition-group/esm/Transition.js
769
771
 
770
772
 
@@ -774,6 +776,7 @@ var external_root_ReactDOM_commonjs2_react_dom_commonjs_react_dom_amd_react_dom_
774
776
 
775
777
 
776
778
 
779
+
777
780
  var UNMOUNTED = 'unmounted';
778
781
  var EXITED = 'exited';
779
782
  var ENTERING = 'entering';
@@ -993,6 +996,14 @@ var Transition = /*#__PURE__*/function (_React$Component) {
993
996
  this.cancelNextCallback();
994
997
 
995
998
  if (nextStatus === ENTERING) {
999
+ if (this.props.unmountOnExit || this.props.mountOnEnter) {
1000
+ var node = this.props.nodeRef ? this.props.nodeRef.current : external_root_ReactDOM_commonjs2_react_dom_commonjs_react_dom_amd_react_dom_default().findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749
1001
+ // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.
1002
+ // To make the animation happen, we have to separate each rendering and avoid being processed as batched.
1003
+
1004
+ if (node) forceReflow(node);
1005
+ }
1006
+
996
1007
  this.performEnter(mounting);
997
1008
  } else {
998
1009
  this.performExit();
@@ -1207,6 +1218,7 @@ Transition.EXITING = EXITING;
1207
1218
 
1208
1219
 
1209
1220
 
1221
+
1210
1222
  var _addClass = function addClass(node, classes) {
1211
1223
  return node && classes && classes.split(' ').forEach(function (c) {
1212
1224
  return addClass_addClass(node, c);
@@ -1426,8 +1438,7 @@ var CSSTransition = /*#__PURE__*/function (_React$Component) {
1426
1438
 
1427
1439
 
1428
1440
  if (phase === 'active') {
1429
- /* eslint-disable no-unused-expressions */
1430
- node && node.scrollTop;
1441
+ if (node) forceReflow(node);
1431
1442
  }
1432
1443
 
1433
1444
  if (className) {
@@ -6703,6 +6714,7 @@ var Form_excluded = ["prefixCls", "className", "fields", "children", "resetOnSub
6703
6714
 
6704
6715
 
6705
6716
 
6717
+
6706
6718
  function newFormState(fields, cb) {
6707
6719
  var state = {
6708
6720
  initial: {},
@@ -6733,8 +6745,7 @@ function newInitialValue(value) {
6733
6745
 
6734
6746
  var isPromise = promise => promise && typeof promise.then === 'function';
6735
6747
 
6736
- function Form(_ref, ref //| React.RefObject<FormRefType>,
6737
- ) {
6748
+ function Form(props, ref) {
6738
6749
  var {
6739
6750
  prefixCls = 'w-form',
6740
6751
  className,
@@ -6745,13 +6756,13 @@ function Form(_ref, ref //| React.RefObject<FormRefType>,
6745
6756
  onChange,
6746
6757
  onSubmit,
6747
6758
  afterSubmit
6748
- } = _ref,
6749
- others = _objectWithoutPropertiesLoose(_ref, Form_excluded);
6759
+ } = props,
6760
+ others = _objectWithoutPropertiesLoose(props, Form_excluded);
6750
6761
 
6751
- var initData = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useMemo)(() => newFormState(fields, _ref2 => {
6762
+ var initData = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useMemo)(() => newFormState(fields, _ref => {
6752
6763
  var {
6753
6764
  initialValue
6754
- } = _ref2;
6765
+ } = _ref;
6755
6766
  initialValue = newInitialValue(initialValue);
6756
6767
  return {
6757
6768
  initialValue,
@@ -6770,28 +6781,27 @@ function Form(_ref, ref //| React.RefObject<FormRefType>,
6770
6781
  var formUnits = {};
6771
6782
 
6772
6783
  for (var name in fields) {
6773
- var props = fields[name];
6774
- if (!props) continue;
6784
+ var itemProps = fields[name];
6785
+ if (!itemProps) continue;
6775
6786
  var error = data.errors[name];
6776
6787
 
6777
- if (typeof props.initialValue === 'boolean') {
6778
- props.checked = props.initialValue;
6788
+ if (typeof itemProps.initialValue === 'boolean') {
6789
+ itemProps.checked = itemProps.initialValue;
6779
6790
  }
6780
6791
 
6781
- var childField = controlField(_extends({}, props, {
6792
+ var childField = controlField(_extends({}, itemProps, {
6782
6793
  name
6783
6794
  }));
6784
- var help = error || props.help;
6785
- var labelFor = props.labelFor;
6786
- formUnits[name] = /*#__PURE__*/(0,jsx_runtime.jsx)(FormItem, _extends({}, _extends({}, props, {
6795
+ var help = error || itemProps.help;
6796
+ var labelFor = itemProps.labelFor;
6797
+ formUnits[name] = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.createElement)(FormItem, _extends({}, itemProps, {
6787
6798
  key: name,
6788
6799
  children: childField,
6789
- help,
6790
- labelFor,
6791
- state: data,
6792
- name,
6800
+ help: help,
6801
+ labelFor: labelFor,
6802
+ name: name,
6793
6803
  hasError: !!error
6794
- })));
6804
+ }));
6795
6805
  }
6796
6806
 
6797
6807
  function setFields(fields) {
@@ -6908,10 +6918,10 @@ function Form(_ref, ref //| React.RefObject<FormRefType>,
6908
6918
 
6909
6919
  for (var _name in fields) {
6910
6920
  if (Object.prototype.hasOwnProperty.call(fields, _name)) {
6911
- var _props = fields[_name];
6912
- if (!_props) continue;
6921
+ var fieldsProps = fields[_name];
6922
+ if (!fieldsProps) continue;
6913
6923
 
6914
- if (_props.validator && _props.validator(current[_name])) {
6924
+ if (fieldsProps.validator && fieldsProps.validator(current[_name])) {
6915
6925
  passesValidators = false;
6916
6926
  break;
6917
6927
  }
@@ -6928,8 +6938,8 @@ function Form(_ref, ref //| React.RefObject<FormRefType>,
6928
6938
 
6929
6939
  var initials = _extends({}, initial);
6930
6940
 
6931
- Object.entries(initials).map(_ref3 => {
6932
- var [key, value] = _ref3;
6941
+ Object.entries(initials).map(_ref2 => {
6942
+ var [key, value] = _ref2;
6933
6943
 
6934
6944
  if (Array.isArray(value)) {
6935
6945
  initials[key] = [...value];
@@ -6942,13 +6952,13 @@ function Form(_ref, ref //| React.RefObject<FormRefType>,
6942
6952
  }));
6943
6953
  }
6944
6954
 
6945
- function controlField(_ref4) {
6955
+ function controlField(_ref3) {
6946
6956
  var {
6947
6957
  children,
6948
6958
  validator,
6949
6959
  name
6950
- } = _ref4,
6951
- other = _objectWithoutPropertiesLoose(_ref4, Form_excluded2);
6960
+ } = _ref3,
6961
+ other = _objectWithoutPropertiesLoose(_ref3, Form_excluded2);
6952
6962
 
6953
6963
  var element = typeof children !== 'function' ? children : children({
6954
6964
  onChange: handleChange(name, validator),
@@ -6965,7 +6975,7 @@ function Form(_ref, ref //| React.RefObject<FormRefType>,
6965
6975
  props.id = element.props.id;
6966
6976
  props.value = hasCurrentValue ? data.current && data.current[name] : props.value; // : element.props.value;
6967
6977
 
6968
- var type = element.props.type; // console.log('type', element)
6978
+ var type = element.props.type;
6969
6979
 
6970
6980
  if (type === 'checkbox' || type === 'switch' || typeof props.value === 'boolean') {
6971
6981
  props.checked = !!props.value;
@@ -6976,10 +6986,9 @@ function Form(_ref, ref //| React.RefObject<FormRefType>,
6976
6986
  return /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().cloneElement(element, props);
6977
6987
  }
6978
6988
 
6979
- return /*#__PURE__*/(0,jsx_runtime.jsx)("form", _extends({}, _extends({}, others, {
6989
+ return /*#__PURE__*/(0,jsx_runtime.jsx)("form", _extends({}, others, {
6980
6990
  className: [prefixCls, className].filter(Boolean).join(' ').trim(),
6981
- onSubmit: handleSubmit
6982
- }), {
6991
+ onSubmit: handleSubmit,
6983
6992
  children: /*#__PURE__*/(0,jsx_runtime.jsx)("fieldset", {
6984
6993
  disabled: data.submitting,
6985
6994
  children: typeof children === 'function' ? children({
@@ -7050,7 +7059,6 @@ var react_list_esm_excluded = ["prefixCls", "bordered", "striped", "noHover", "a
7050
7059
 
7051
7060
 
7052
7061
 
7053
-
7054
7062
  function InternalList(props, ref) {
7055
7063
  var {
7056
7064
  prefixCls = 'w-list',
@@ -7059,7 +7067,7 @@ function InternalList(props, ref) {
7059
7067
  noHover = false,
7060
7068
  active = false,
7061
7069
  size = 'default',
7062
- renderItem = noop,
7070
+ renderItem,
7063
7071
  className,
7064
7072
  children,
7065
7073
  header,
@@ -7071,7 +7079,7 @@ function InternalList(props, ref) {
7071
7079
  var items;
7072
7080
 
7073
7081
  if (dataSource && dataSource.length > 0) {
7074
- items = dataSource.map((item, index) => renderItem(item, index));
7082
+ items = dataSource.map((item, index) => renderItem && renderItem(item, index));
7075
7083
  } else {
7076
7084
  items = children;
7077
7085
  }
@@ -7859,7 +7867,8 @@ var react_select_esm_excluded = ["prefixCls", "className", "size"];
7859
7867
 
7860
7868
 
7861
7869
 
7862
- var Select = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().forwardRef((props, ref) => {
7870
+
7871
+ var InternalSelect = (props, ref) => {
7863
7872
  var {
7864
7873
  prefixCls = 'w-select',
7865
7874
  className,
@@ -7871,7 +7880,9 @@ var Select = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd
7871
7880
  ref: ref,
7872
7881
  className: [prefixCls, className, size ? prefixCls + "-" + size : null].filter(Boolean).join(' ').trim()
7873
7882
  }));
7874
- });
7883
+ };
7884
+
7885
+ var Select = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().forwardRef(InternalSelect);
7875
7886
  Select.Option = Option;
7876
7887
  Select.Group = Group;
7877
7888
  /* harmony default export */ const react_select_esm = (Select);