shineout 3.1.16 → 3.1.18-fix.1

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/cjs/index.js CHANGED
@@ -476,5 +476,5 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
476
476
  // 此文件由脚本自动生成,请勿直接修改。
477
477
  // This file was generated automatically by a script. Please do not modify it directly.
478
478
  var _default = exports.default = {
479
- version: '3.1.16'
479
+ version: '3.1.18-fix.1'
480
480
  };
@@ -14,7 +14,8 @@ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key i
14
14
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
15
15
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
16
16
  var jssStyle = {
17
- button: _shineoutStyle.useButtonStyle
17
+ button: _shineoutStyle.useButtonStyle,
18
+ spin: _shineoutStyle.useSpinStyle
18
19
  };
19
20
  var Submit = function Submit(props) {
20
21
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(_base.ModalSubmit, _objectSpread({
package/dist/shineout.js CHANGED
@@ -11949,7 +11949,7 @@ var handleStyle = function handleStyle(style) {
11949
11949
  };
11950
11950
  /* harmony default export */ var jss_style_handleStyle = (handleStyle);
11951
11951
  ;// CONCATENATED MODULE: ../shineout-style/src/version.ts
11952
- /* harmony default export */ var version = ('3.1.16');
11952
+ /* harmony default export */ var version = ('3.1.18-fix.1');
11953
11953
  ;// CONCATENATED MODULE: ../shineout-style/src/jss-style/index.tsx
11954
11954
 
11955
11955
 
@@ -16336,7 +16336,7 @@ var cascaderStyle = objectSpread2_default()(objectSpread2_default()({
16336
16336
  },
16337
16337
  compressedWrapper: {
16338
16338
  width: 0,
16339
- overflow: 'hidden'
16339
+ overflow: 'auto'
16340
16340
  },
16341
16341
  controlMouse: {
16342
16342
  '& $optionInner:hover': {
@@ -16449,6 +16449,7 @@ var cascaderStyle = objectSpread2_default()(objectSpread2_default()({
16449
16449
  overflow: 'auto'
16450
16450
  },
16451
16451
  tag: {
16452
+ flexShrink: 0,
16452
16453
  '&$tag + &$tag': {
16453
16454
  marginLeft: 0
16454
16455
  },
@@ -16461,6 +16462,10 @@ var cascaderStyle = objectSpread2_default()(objectSpread2_default()({
16461
16462
  marginRight: 0
16462
16463
  }
16463
16464
  },
16465
+ tagOnly: {
16466
+ flexShrink: 1,
16467
+ minWidth: 42
16468
+ },
16464
16469
  space: {
16465
16470
  marginTop: src.cascaderPlaceholderMarginY,
16466
16471
  marginBottom: src.cascaderPlaceholderMarginY
@@ -21243,7 +21248,7 @@ var selectStyle = objectSpread2_default()(objectSpread2_default()({
21243
21248
  },
21244
21249
  compressedWrapper: {
21245
21250
  width: 0,
21246
- overflow: 'hidden'
21251
+ overflow: 'auto'
21247
21252
  },
21248
21253
  controlMouse: {
21249
21254
  '& $optionInner:not($optionDisabled):not($optionActive):hover': {
@@ -21383,6 +21388,7 @@ var selectStyle = objectSpread2_default()(objectSpread2_default()({
21383
21388
  }
21384
21389
  },
21385
21390
  tag: {
21391
+ flexShrink: 0,
21386
21392
  '&$tag + &$tag': {
21387
21393
  marginLeft: 0
21388
21394
  },
@@ -21395,6 +21401,10 @@ var selectStyle = objectSpread2_default()(objectSpread2_default()({
21395
21401
  marginRight: 0
21396
21402
  }
21397
21403
  },
21404
+ tagOnly: {
21405
+ flexShrink: 1,
21406
+ minWidth: 42
21407
+ },
21398
21408
  space: {
21399
21409
  marginTop: src.selectPlaceholderMarginY,
21400
21410
  marginBottom: src.selectPlaceholderMarginY
@@ -25983,7 +25993,7 @@ var treeSelectStyle = objectSpread2_default()(objectSpread2_default()({
25983
25993
  },
25984
25994
  compressedWrapper: {
25985
25995
  width: 0,
25986
- overflow: 'hidden'
25996
+ overflow: 'auto'
25987
25997
  },
25988
25998
  controlMouse: {
25989
25999
  '& $optionInner:hover': {
@@ -26102,6 +26112,7 @@ var treeSelectStyle = objectSpread2_default()(objectSpread2_default()({
26102
26112
  }
26103
26113
  },
26104
26114
  tag: {
26115
+ flexShrink: 0,
26105
26116
  '&$tag + &$tag': {
26106
26117
  marginLeft: 0
26107
26118
  },
@@ -26114,6 +26125,10 @@ var treeSelectStyle = objectSpread2_default()(objectSpread2_default()({
26114
26125
  marginRight: 0
26115
26126
  }
26116
26127
  },
26128
+ tagOnly: {
26129
+ flexShrink: 1,
26130
+ minWidth: 42
26131
+ },
26117
26132
  space: {
26118
26133
  marginTop: src.treeSelectPlaceholderMarginY,
26119
26134
  marginBottom: src.treeSelectPlaceholderMarginY
@@ -30400,7 +30415,8 @@ var ModalSubmit = function ModalSubmit(props) {
30400
30415
 
30401
30416
 
30402
30417
  var submit_jssStyle = {
30403
- button: useButtonStyle
30418
+ button: useButtonStyle,
30419
+ spin: useSpinStyle
30404
30420
  };
30405
30421
  var Submit = function Submit(props) {
30406
30422
  return /*#__PURE__*/(0,jsx_runtime.jsx)(modal_submit, objectSpread2_default()({
@@ -30900,19 +30916,18 @@ function useInputAble(props) {
30900
30916
  var render = useRender(syncValue);
30901
30917
  var shouldUseState = delay || !control;
30902
30918
  var value = shouldUseState ? stateValue : valuePo;
30903
- (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect)(function () {
30904
- if (context.timer) {
30905
- clearTimeout(context.timer);
30906
- context.timer = null;
30907
- }
30919
+ (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useLayoutEffect)(function () {
30908
30920
  if (delay && props.value !== stateValue) {
30909
30921
  changeStateValue(props.value);
30922
+ } else if (context.timer) {
30923
+ clearTimeout(context.timer);
30924
+ context.timer = null;
30910
30925
  }
30911
30926
  }, [props.value, delay]);
30912
30927
  var forceDelayChange = use_persist_fn(function () {
30913
- if (context.timer && context.delayChange) {
30928
+ if (context.delayChange) context.delayChange();
30929
+ if (context.timer) {
30914
30930
  clearTimeout(context.timer);
30915
- context.delayChange();
30916
30931
  context.timer = null;
30917
30932
  context.delayChange = null;
30918
30933
  }
@@ -32328,7 +32343,7 @@ var useInputCommon = function useInputCommon(props0) {
32328
32343
 
32329
32344
 
32330
32345
  var input_Input = function Input(props) {
32331
- var _ref, _commonProps$trim;
32346
+ var _ref, _commonProps$trim, _inputFormatProps$val;
32332
32347
  var commonProps = use_input_common(props);
32333
32348
  var config = useConfig();
32334
32349
  var inputFormatParams = {
@@ -32348,7 +32363,7 @@ var input_Input = function Input(props) {
32348
32363
  }, inputFormatParams));
32349
32364
  var forwardProps = removeProps(commonProps, objectSpread2_default()({}, inputFormatParams));
32350
32365
  return /*#__PURE__*/(0,jsx_runtime.jsx)(simple_input, objectSpread2_default()(objectSpread2_default()(objectSpread2_default()({}, forwardProps), inputFormatProps), {}, {
32351
- value: inputFormatProps.value || '',
32366
+ value: (_inputFormatProps$val = inputFormatProps.value) !== null && _inputFormatProps$val !== void 0 ? _inputFormatProps$val : '',
32352
32367
  hasSuffix: !!props.suffix
32353
32368
  }));
32354
32369
  };
@@ -35896,10 +35911,7 @@ var result_Result = function Result(props) {
35896
35911
  return /*#__PURE__*/(0,jsx_runtime.jsx)(base_src_tag_tag, objectSpread2_default()(objectSpread2_default()({
35897
35912
  disabled: isDisabled,
35898
35913
  size: size,
35899
- style: {
35900
- opacity: more === index ? 0 : 1
35901
- },
35902
- className: classnames_default()(styles.tag, resultClassName),
35914
+ className: classnames_default()(styles.tag, more === 1 && styles.tagOnly, resultClassName),
35903
35915
  closable: closeable && 'only',
35904
35916
  onClose: closeable && handleClose,
35905
35917
  onClick: handleClick,
@@ -36005,8 +36017,8 @@ var result_Result = function Result(props) {
36005
36017
  var handleResetMore = function handleResetMore() {
36006
36018
  if (!compressed) return;
36007
36019
  if (isCompressedBound()) return;
36008
- setShouldResetMore(true);
36009
36020
  setMore(-1);
36021
+ setShouldResetMore(true);
36010
36022
  };
36011
36023
  (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect)(function () {
36012
36024
  if (!focus && mounted.current) {
@@ -36018,7 +36030,7 @@ var result_Result = function Result(props) {
36018
36030
  mounted.current = true;
36019
36031
  }, [focus]);
36020
36032
  (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useLayoutEffect)(function () {
36021
- setTimeout(handleResetMore);
36033
+ handleResetMore();
36022
36034
  }, [valueProp, data]);
36023
36035
  (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useLayoutEffect)(function () {
36024
36036
  if (shouldResetMore && more === -1 && compressed && resultRef.current && (props.value || []).length) {
@@ -36031,7 +36043,7 @@ var result_Result = function Result(props) {
36031
36043
  } else {
36032
36044
  setShouldResetMore(false);
36033
36045
  }
36034
- } else {
36046
+ } else if (shouldResetMore) {
36035
36047
  setShouldResetMore(false);
36036
36048
  }
36037
36049
  }, [shouldResetMore]);
@@ -51547,6 +51559,8 @@ var Confirm = function Confirm(props) {
51547
51559
  callback.then(function () {
51548
51560
  close();
51549
51561
  setOk(false);
51562
+ }).catch(function () {
51563
+ setOk(false);
51550
51564
  });
51551
51565
  } else {
51552
51566
  close();
@@ -51561,6 +51575,8 @@ var Confirm = function Confirm(props) {
51561
51575
  callback.then(function () {
51562
51576
  close();
51563
51577
  setCancel(false);
51578
+ }).catch(function () {
51579
+ setCancel(false);
51564
51580
  });
51565
51581
  } else {
51566
51582
  close();
@@ -62335,7 +62351,7 @@ var upload_interface = __webpack_require__(4412);
62335
62351
 
62336
62352
 
62337
62353
  /* harmony default export */ var src_0 = ({
62338
- version: '3.1.16'
62354
+ version: '3.1.18-fix.1'
62339
62355
  });
62340
62356
  }();
62341
62357
  /******/ return __webpack_exports__;