tuain-ng-forms-lib 15.0.12 → 15.0.14
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/esm2020/lib/classes/forms/element.mjs +2 -1
- package/esm2020/lib/classes/forms/field.mjs +2 -1
- package/esm2020/lib/classes/forms/piece-propagate.mjs +3 -1
- package/fesm2015/tuain-ng-forms-lib.mjs +4 -0
- package/fesm2015/tuain-ng-forms-lib.mjs.map +1 -1
- package/fesm2020/tuain-ng-forms-lib.mjs +4 -0
- package/fesm2020/tuain-ng-forms-lib.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -652,12 +652,14 @@ class FormPiecePropagate extends FormPiece {
|
|
|
652
652
|
}
|
|
653
653
|
get attributeChange() { return this._attributeChange; }
|
|
654
654
|
propagateAttribute(name, value) {
|
|
655
|
+
console.log('propagateAttribute...');
|
|
655
656
|
this._attributeChange?.next({ name, value });
|
|
656
657
|
}
|
|
657
658
|
setCustomAttribute(name, value) {
|
|
658
659
|
super.setCustomAttribute(name, value);
|
|
659
660
|
if (this.propagationCustomAttributes?.includes(name)) {
|
|
660
661
|
const fullName = `customAttributes.${name}`;
|
|
662
|
+
console.log(`La propagación se origina en setCustomAttribute ${name} ${value}`);
|
|
661
663
|
this.propagateAttribute(fullName, value);
|
|
662
664
|
}
|
|
663
665
|
}
|
|
@@ -687,6 +689,7 @@ class FormElement extends FormPiecePropagate {
|
|
|
687
689
|
setAttr(attr, value) {
|
|
688
690
|
const { name: attrName, propagate: name } = attr;
|
|
689
691
|
this[attrName] = value;
|
|
692
|
+
console.log(`La propagacioón se origina en setAttr ${attrName} ${value} (propaga ${name})`);
|
|
690
693
|
name && this.propagateAttribute(name, value);
|
|
691
694
|
}
|
|
692
695
|
isField() { return this.elementType === elementTypes.field; }
|
|
@@ -972,6 +975,7 @@ class FieldDescriptor extends FormElement {
|
|
|
972
975
|
if (this._value) {
|
|
973
976
|
if (this._fieldType === this._formConfig.fieldTypes.array && Array.isArray(this._value)) {
|
|
974
977
|
const fieldValue = this._value?.filter(item => this.fieldOptions?.find(opt => opt.fieldOptionId === item));
|
|
978
|
+
console.log('SetAttr de valor....');
|
|
975
979
|
this.setAttr(attrs$1._value, fieldValue);
|
|
976
980
|
}
|
|
977
981
|
else {
|