tuain-ng-forms-lib 12.0.31 → 12.0.32

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.
@@ -37,11 +37,11 @@ class ActionComponent {
37
37
  }
38
38
  get visible() {
39
39
  var _a;
40
- return ((_a = this.action) === null || _a === void 0 ? void 0 : _a.visibleOn(this.currentState)) && this.visibleOnRestriction();
40
+ return ((_a = this.action) === null || _a === void 0 ? void 0 : _a.visibleOn(this.state)) && this.visibleOnRestriction();
41
41
  }
42
42
  get disabled() {
43
43
  var _a;
44
- return !((_a = this.action) === null || _a === void 0 ? void 0 : _a.enabledOn(this.currentState));
44
+ return !((_a = this.action) === null || _a === void 0 ? void 0 : _a.enabledOn(this.state));
45
45
  }
46
46
  }
47
47
  ActionComponent.decorators = [
@@ -54,7 +54,7 @@ ActionComponent.propDecorators = {
54
54
  action: [{ type: Input }],
55
55
  busy: [{ type: Input }],
56
56
  relatedField: [{ type: Input }],
57
- currentState: [{ type: Input }],
57
+ state: [{ type: Input }],
58
58
  style: [{ type: Input }],
59
59
  showLabel: [{ type: Input }]
60
60
  };
@@ -122,11 +122,11 @@ class FieldComponent {
122
122
  }
123
123
  get visible() {
124
124
  var _a;
125
- return (_a = this.field) === null || _a === void 0 ? void 0 : _a.visibleOn(this.currentState);
125
+ return (_a = this.field) === null || _a === void 0 ? void 0 : _a.visibleOn(this.state);
126
126
  }
127
127
  get disabled() {
128
128
  var _a;
129
- return !((_a = this.field) === null || _a === void 0 ? void 0 : _a.enabledOn(this.currentState));
129
+ return !((_a = this.field) === null || _a === void 0 ? void 0 : _a.enabledOn(this.state));
130
130
  }
131
131
  }
132
132
  FieldComponent.decorators = [
@@ -137,7 +137,7 @@ FieldComponent.decorators = [
137
137
  ];
138
138
  FieldComponent.propDecorators = {
139
139
  field: [{ type: Input }],
140
- currentState: [{ type: Input }]
140
+ state: [{ type: Input }]
141
141
  };
142
142
 
143
143
  class ElementComponent {
@@ -149,11 +149,11 @@ class ElementComponent {
149
149
  start() { }
150
150
  get visible() {
151
151
  var _a;
152
- return (_a = this.element) === null || _a === void 0 ? void 0 : _a.visibleOn(this.currentState);
152
+ return (_a = this.element) === null || _a === void 0 ? void 0 : _a.visibleOn(this.state);
153
153
  }
154
154
  get disabled() {
155
155
  var _a;
156
- return !((_a = this.element) === null || _a === void 0 ? void 0 : _a.enabledOn(this.currentState));
156
+ return !((_a = this.element) === null || _a === void 0 ? void 0 : _a.enabledOn(this.state));
157
157
  }
158
158
  }
159
159
  ElementComponent.decorators = [
@@ -165,7 +165,7 @@ ElementComponent.decorators = [
165
165
  ElementComponent.propDecorators = {
166
166
  element: [{ type: Input }],
167
167
  form: [{ type: Input }],
168
- currentState: [{ type: Input }]
168
+ state: [{ type: Input }]
169
169
  };
170
170
 
171
171
  class FormErrorComponent {
@@ -1100,7 +1100,7 @@ LibTableComponent.propDecorators = {
1100
1100
  table: [{ type: Input }],
1101
1101
  tableRecords: [{ type: Input }],
1102
1102
  disabled: [{ type: Input }],
1103
- currentState: [{ type: Input }],
1103
+ state: [{ type: Input }],
1104
1104
  waiting: [{ type: Input }]
1105
1105
  };
1106
1106
 
@@ -2536,10 +2536,9 @@ class BasicFormComponent {
2536
2536
  set formCode(name) { this.name = name; }
2537
2537
  get inServerProcess() { return this.busy; }
2538
2538
  get form() { return this._formStructure; }
2539
- get state() { return this.getCurrentState(); }
2539
+ get state() { var _a; return (_a = this._formStructure) === null || _a === void 0 ? void 0 : _a.state; }
2540
2540
  get currentState() { var _a; return (_a = this._formStructure) === null || _a === void 0 ? void 0 : _a.state; }
2541
2541
  set currentState(state) { this._formStructure.changeState(state); }
2542
- get currentMode() { return this.currentState; }
2543
2542
  get immutableData() { var _a; return (_a = this._formStructure) === null || _a === void 0 ? void 0 : _a.immutableData; }
2544
2543
  get extraInfo() { var _a; return (_a = this._formStructure) === null || _a === void 0 ? void 0 : _a.extraInfo; }
2545
2544
  get visibleSections() { var _a; return (_a = this._formStructure) === null || _a === void 0 ? void 0 : _a.visibleSections; }
@@ -2601,7 +2600,7 @@ class BasicFormComponent {
2601
2600
  if (!cleanStack) {
2602
2601
  origin = Object.assign(Object.assign({}, backData), { name: this.name, url: this._formRoute, token: this._controlToken });
2603
2602
  origin.subject = (_a = origin === null || origin === void 0 ? void 0 : origin.subject) !== null && _a !== void 0 ? _a : this.formSubject;
2604
- origin.state = (_b = origin === null || origin === void 0 ? void 0 : origin.state) !== null && _b !== void 0 ? _b : this.currentState;
2603
+ origin.state = (_b = origin === null || origin === void 0 ? void 0 : origin.state) !== null && _b !== void 0 ? _b : this.state;
2605
2604
  origin.fields = (_c = origin === null || origin === void 0 ? void 0 : origin.fields) !== null && _c !== void 0 ? _c : {};
2606
2605
  origin.extra = (_d = origin === null || origin === void 0 ? void 0 : origin.extra) !== null && _d !== void 0 ? _d : {};
2607
2606
  }