shineout 3.5.8-beta.16 → 3.5.8-beta.17

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
@@ -507,5 +507,5 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
507
507
  // 此文件由脚本自动生成,请勿直接修改。
508
508
  // This file was generated automatically by a script. Please do not modify it directly.
509
509
  var _default = exports.default = {
510
- version: '3.5.8-beta.16'
510
+ version: '3.5.8-beta.17'
511
511
  };
package/dist/shineout.js CHANGED
@@ -12115,7 +12115,7 @@ var handleStyle = function handleStyle(style) {
12115
12115
  };
12116
12116
  /* harmony default export */ var jss_style_handleStyle = (handleStyle);
12117
12117
  ;// CONCATENATED MODULE: ../shineout-style/src/version.ts
12118
- /* harmony default export */ var version = ('3.5.8-beta.16');
12118
+ /* harmony default export */ var version = ('3.5.8-beta.17');
12119
12119
  ;// CONCATENATED MODULE: ../shineout-style/src/jss-style/index.tsx
12120
12120
 
12121
12121
 
@@ -40904,6 +40904,7 @@ function useFormControl(props) {
40904
40904
  var formValue = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
40905
40905
  var errors = arguments.length > 1 ? arguments[1] : undefined;
40906
40906
  var severErrors = arguments.length > 2 ? arguments[2] : undefined;
40907
+ var names = arguments.length > 3 ? arguments[3] : undefined;
40907
40908
  if (!name) return;
40908
40909
  if (isArray(name)) {
40909
40910
  var _value = getValue(name, formValue);
@@ -40915,7 +40916,7 @@ function useFormControl(props) {
40915
40916
  var dv = isArray(defaultValue) ? defaultValue : [];
40916
40917
  var nextValue = [];
40917
40918
  name.forEach(function (n, index) {
40918
- if (_value[index] === undefined && dv[index] !== undefined) {
40919
+ if (!names.has(n) && _value[index] === undefined && dv[index] !== undefined) {
40919
40920
  nextValue[index] = dv[index];
40920
40921
  } else {
40921
40922
  nextValue[index] = _value[index];
@@ -40929,7 +40930,7 @@ function useFormControl(props) {
40929
40930
  setErrorState(_error2);
40930
40931
  }
40931
40932
  if (!shallowEqual(_value2, latestInfo.valueState)) {
40932
- if (_value2 === undefined && defaultValue !== undefined) {
40933
+ if (!names.has(name) && _value2 === undefined && defaultValue !== undefined) {
40933
40934
  setValueState(defaultValue);
40934
40935
  } else {
40935
40936
  setValueState(_value2);
@@ -48238,7 +48239,7 @@ var useForm = function useForm(props) {
48238
48239
  Object.keys(context.updateMap).forEach(function (key) {
48239
48240
  var _context$updateMap$ke;
48240
48241
  (_context$updateMap$ke = context.updateMap[key]) === null || _context$updateMap$ke === void 0 || _context$updateMap$ke.forEach(function (update) {
48241
- update(context.value, context.errors, context.serverErrors);
48242
+ update(context.value, context.errors, context.serverErrors, context.names);
48242
48243
  });
48243
48244
  });
48244
48245
  Object.keys(context.flowMap).forEach(function (key) {
@@ -48256,12 +48257,12 @@ var useForm = function useForm(props) {
48256
48257
  var _context$updateMap$pa;
48257
48258
  var parentKey = key.split('.')[0];
48258
48259
  (_context$updateMap$pa = context.updateMap[parentKey]) === null || _context$updateMap$pa === void 0 || _context$updateMap$pa.forEach(function (update) {
48259
- update(context.value, context.errors, context.serverErrors);
48260
+ update(context.value, context.errors, context.serverErrors, context.names);
48260
48261
  });
48261
48262
  } else {
48262
48263
  var _context$updateMap$ke2;
48263
48264
  (_context$updateMap$ke2 = context.updateMap[key]) === null || _context$updateMap$ke2 === void 0 || _context$updateMap$ke2.forEach(function (update) {
48264
- update(context.value, context.errors, context.serverErrors);
48265
+ update(context.value, context.errors, context.serverErrors, context.names);
48265
48266
  });
48266
48267
  }
48267
48268
  (_context$flowMap$key = context.flowMap[key]) === null || _context$flowMap$key === void 0 || _context$flowMap$key.forEach(function (update) {
@@ -67822,7 +67823,7 @@ var upload_interface = __webpack_require__(8821);
67822
67823
 
67823
67824
 
67824
67825
  /* harmony default export */ var src_0 = ({
67825
- version: '3.5.8-beta.16'
67826
+ version: '3.5.8-beta.17'
67826
67827
  });
67827
67828
  }();
67828
67829
  /******/ return __webpack_exports__;