kui-utils 0.0.22 → 0.0.23
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 +5 -3
- package/cjs/index.js.map +1 -1
- package/index.d.ts +4 -1
- package/index.js +5 -3
- package/index.js.map +1 -1
- package/package.json +1 -1
package/cjs/index.js
CHANGED
|
@@ -2264,8 +2264,9 @@ var MultistepForm = /** @class */ (function () {
|
|
|
2264
2264
|
this.addValueToField = function (valueName, value, fieldName) {
|
|
2265
2265
|
if (!_this.fields)
|
|
2266
2266
|
_this.fields = {};
|
|
2267
|
-
var
|
|
2267
|
+
var _a = _this.getNestedField(fieldName), path = _a.path, fields = _a.fields;
|
|
2268
2268
|
path[valueName] = value;
|
|
2269
|
+
_this.fields = fields;
|
|
2269
2270
|
};
|
|
2270
2271
|
this.getNestedField = function (fieldName) {
|
|
2271
2272
|
if (!_this.fields)
|
|
@@ -2277,11 +2278,12 @@ var MultistepForm = /** @class */ (function () {
|
|
|
2277
2278
|
// @ts-ignore
|
|
2278
2279
|
_this.fields[fieldParts[0]] = [];
|
|
2279
2280
|
}
|
|
2280
|
-
var
|
|
2281
|
+
var fields = _this.fields;
|
|
2282
|
+
var path = fields;
|
|
2281
2283
|
fieldParts === null || fieldParts === void 0 ? void 0 : fieldParts.forEach(function (part) {
|
|
2282
2284
|
path = path[part];
|
|
2283
2285
|
});
|
|
2284
|
-
return path;
|
|
2286
|
+
return { path: path, fields: fields };
|
|
2285
2287
|
};
|
|
2286
2288
|
this.nextStep = function () {
|
|
2287
2289
|
_this.step += 1;
|