tuain-ng-forms-lib 12.0.15 → 12.0.16

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.
@@ -11,32 +11,32 @@
11
11
  }
12
12
  ActionComponent.prototype.ngOnInit = function () {
13
13
  var _a;
14
- this.formConfig = (_a = this.actionObject) === null || _a === void 0 ? void 0 : _a._formConfig;
14
+ this.formConfig = (_a = this.action) === null || _a === void 0 ? void 0 : _a._formConfig;
15
15
  this.start();
16
16
  };
17
17
  ActionComponent.prototype.start = function () { };
18
18
  ActionComponent.prototype.activate = function () {
19
19
  var _a;
20
- if ((_a = this.actionObject) === null || _a === void 0 ? void 0 : _a.notifyActivation) {
21
- this.actionObject.notifyActivation();
20
+ if ((_a = this.action) === null || _a === void 0 ? void 0 : _a.notifyActivation) {
21
+ this.action.notifyActivation();
22
22
  }
23
23
  };
24
24
  ActionComponent.prototype.visibleOnRestriction = function () {
25
25
  var _a, _b, _c, _d, _e;
26
- if (!((_a = this.actionObject) === null || _a === void 0 ? void 0 : _a.restrictedOnField)) {
26
+ if (!((_a = this.action) === null || _a === void 0 ? void 0 : _a.restrictedOnField)) {
27
27
  return true;
28
28
  }
29
- if ((((_b = this.actionObject) === null || _b === void 0 ? void 0 : _b.restrictedOnOperator) === '=='
30
- && this.relatedField === ((_c = this.actionObject) === null || _c === void 0 ? void 0 : _c.restrictedOnValue))
31
- || (((_d = this.actionObject) === null || _d === void 0 ? void 0 : _d.restrictedOnOperator) === '!='
32
- && this.relatedField !== ((_e = this.actionObject) === null || _e === void 0 ? void 0 : _e.restrictedOnValue))) {
29
+ if ((((_b = this.action) === null || _b === void 0 ? void 0 : _b.restrictedOnOperator) === '=='
30
+ && this.relatedField === ((_c = this.action) === null || _c === void 0 ? void 0 : _c.restrictedOnValue))
31
+ || (((_d = this.action) === null || _d === void 0 ? void 0 : _d.restrictedOnOperator) === '!='
32
+ && this.relatedField !== ((_e = this.action) === null || _e === void 0 ? void 0 : _e.restrictedOnValue))) {
33
33
  return true;
34
34
  }
35
35
  };
36
36
  Object.defineProperty(ActionComponent.prototype, "visible", {
37
37
  get: function () {
38
38
  var _a;
39
- return ((_a = this.actionObject) === null || _a === void 0 ? void 0 : _a.visibleOn(this.currentState)) && this.visibleOnRestriction();
39
+ return ((_a = this.action) === null || _a === void 0 ? void 0 : _a.visibleOn(this.currentState)) && this.visibleOnRestriction();
40
40
  },
41
41
  enumerable: false,
42
42
  configurable: true
@@ -44,7 +44,7 @@
44
44
  Object.defineProperty(ActionComponent.prototype, "disabled", {
45
45
  get: function () {
46
46
  var _a;
47
- return !((_a = this.actionObject) === null || _a === void 0 ? void 0 : _a.enabledOn(this.currentState));
47
+ return !((_a = this.action) === null || _a === void 0 ? void 0 : _a.enabledOn(this.currentState));
48
48
  },
49
49
  enumerable: false,
50
50
  configurable: true
@@ -58,7 +58,7 @@
58
58
  },] }
59
59
  ];
60
60
  ActionComponent.propDecorators = {
61
- actionObject: [{ type: core.Input }],
61
+ action: [{ type: core.Input }],
62
62
  busy: [{ type: core.Input }],
63
63
  relatedField: [{ type: core.Input }],
64
64
  currentState: [{ type: core.Input }],
@@ -391,8 +391,8 @@
391
391
  FieldComponent.prototype.ngOnInit = function () {
392
392
  var _this = this;
393
393
  var _a, _b;
394
- if (this.fieldObject) {
395
- this.formConfig = (_a = this.fieldObject) === null || _a === void 0 ? void 0 : _a._formConfig;
394
+ if (this.field) {
395
+ this.formConfig = (_a = this.field) === null || _a === void 0 ? void 0 : _a._formConfig;
396
396
  // Inicialización
397
397
  var mapping = Object.entries(this.formConfig.componentFieldAttrMap);
398
398
  for (var index = 0; index < mapping.length; index++) {
@@ -402,11 +402,11 @@
402
402
  this.updateValue();
403
403
  }
404
404
  else {
405
- this[compAttr] = (_b = this.fieldObject) === null || _b === void 0 ? void 0 : _b[fieldAttr.toString()];
405
+ this[compAttr] = (_b = this.field) === null || _b === void 0 ? void 0 : _b[fieldAttr.toString()];
406
406
  }
407
407
  }
408
408
  // Subscripción a cambios en atributos
409
- this.fieldObject.attributeChange.subscribe(function (event) {
409
+ this.field.attributeChange.subscribe(function (event) {
410
410
  var fieldAttr = event.name, value = event.value;
411
411
  var compAttr = _this.formConfig.componentFieldAttrMap[fieldAttr];
412
412
  if (compAttr === VALUE) {
@@ -425,15 +425,15 @@
425
425
  FieldComponent.prototype.updateObject = function () { };
426
426
  FieldComponent.prototype.onInputChange = function () {
427
427
  var _this = this;
428
- setTimeout(function () { return _this.fieldObject.notifyEditionPartial(); }, 50);
428
+ setTimeout(function () { return _this.field.notifyEditionPartial(); }, 50);
429
429
  };
430
430
  FieldComponent.prototype.onChangeContent = function () {
431
431
  var _this = this;
432
- setTimeout(function () { return _this.fieldObject.notifyEditionFinish(); }, 50);
432
+ setTimeout(function () { return _this.field.notifyEditionFinish(); }, 50);
433
433
  };
434
434
  FieldComponent.prototype.onShowInfo = function () {
435
435
  var _this = this;
436
- setTimeout(function () { return _this.fieldObject.notifyEditionDetailRequest(); }, 50);
436
+ setTimeout(function () { return _this.field.notifyEditionDetailRequest(); }, 50);
437
437
  };
438
438
  FieldComponent.prototype.numberInputValidation = function (event) {
439
439
  var k = event.charCode;
@@ -442,7 +442,7 @@
442
442
  Object.defineProperty(FieldComponent.prototype, "visible", {
443
443
  get: function () {
444
444
  var _a;
445
- return (_a = this.fieldObject) === null || _a === void 0 ? void 0 : _a.visibleOn(this.currentState);
445
+ return (_a = this.field) === null || _a === void 0 ? void 0 : _a.visibleOn(this.currentState);
446
446
  },
447
447
  enumerable: false,
448
448
  configurable: true
@@ -450,7 +450,7 @@
450
450
  Object.defineProperty(FieldComponent.prototype, "disabled", {
451
451
  get: function () {
452
452
  var _a;
453
- return !((_a = this.fieldObject) === null || _a === void 0 ? void 0 : _a.enabledOn(this.currentState));
453
+ return !((_a = this.field) === null || _a === void 0 ? void 0 : _a.enabledOn(this.currentState));
454
454
  },
455
455
  enumerable: false,
456
456
  configurable: true
@@ -464,7 +464,7 @@
464
464
  },] }
465
465
  ];
466
466
  FieldComponent.propDecorators = {
467
- fieldObject: [{ type: core.Input }],
467
+ field: [{ type: core.Input }],
468
468
  currentState: [{ type: core.Input }]
469
469
  };
470
470