ng-inail-common 2.0.32-beta.3 → 2.0.32-beta.7
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/bundles/ng-inail-common.umd.js +79 -3
- package/bundles/ng-inail-common.umd.js.map +1 -1
- package/bundles/ng-inail-common.umd.min.js +2 -2
- package/bundles/ng-inail-common.umd.min.js.map +1 -1
- package/esm2015/lib/components/core/form/select/select.component.js +12 -2
- package/esm2015/lib/components/core/table/tr-accordion/tr-accordion.component.js +63 -0
- package/esm2015/lib/ng-inail-common.config.js +2 -2
- package/esm2015/lib/ng-inail-common.module.js +6 -3
- package/esm2015/public-api.js +2 -1
- package/fesm2015/ng-inail-common.js +75 -4
- package/fesm2015/ng-inail-common.js.map +1 -1
- package/lib/components/core/table/tr-accordion/tr-accordion.component.d.ts +19 -0
- package/lib/ng-inail-common.config.d.ts +5 -1
- package/ng-inail-common.metadata.json +1 -1
- package/package.json +1 -1
- package/public-api.d.ts +1 -0
|
@@ -3376,7 +3376,17 @@
|
|
|
3376
3376
|
_this.cdr.detectChanges();
|
|
3377
3377
|
_this.emitDebug("this.valueChange.emit(" + _this.selectedValue + ")");
|
|
3378
3378
|
_this.valueChange.emit(_this.selectedValue);
|
|
3379
|
-
|
|
3379
|
+
var optionToEmit;
|
|
3380
|
+
if (_this.options) {
|
|
3381
|
+
optionToEmit = _this.options.find(function (opt) { return (opt === null || opt === void 0 ? void 0 : opt.value) === _this.selectedValue; });
|
|
3382
|
+
// this.select.emit(this.options.find(opt => opt?.value === this.selectedValue));
|
|
3383
|
+
}
|
|
3384
|
+
if (!optionToEmit && _this.blankOption && _this.selectedValue === '') {
|
|
3385
|
+
optionToEmit = { value: '', label: _this.blankOptionText };
|
|
3386
|
+
}
|
|
3387
|
+
if (optionToEmit) {
|
|
3388
|
+
_this.select.emit(optionToEmit);
|
|
3389
|
+
}
|
|
3380
3390
|
if (_this.cleanErrorOnChange) {
|
|
3381
3391
|
_this.cleanError();
|
|
3382
3392
|
}
|
|
@@ -6836,6 +6846,69 @@
|
|
|
6836
6846
|
value: [{ type: core.Input }]
|
|
6837
6847
|
};
|
|
6838
6848
|
|
|
6849
|
+
var TrAccordionComponent = /** @class */ (function (_super) {
|
|
6850
|
+
__extends(TrAccordionComponent, _super);
|
|
6851
|
+
function TrAccordionComponent(elRef, cdr, libConfig) {
|
|
6852
|
+
var _this = this;
|
|
6853
|
+
var _a, _b;
|
|
6854
|
+
_this = _super.call(this, cdr, libConfig) || this;
|
|
6855
|
+
_this.elRef = elRef;
|
|
6856
|
+
_this.cdr = cdr;
|
|
6857
|
+
_this.libConfig = libConfig;
|
|
6858
|
+
_this.expanded = getConfigValue((_b = (_a = _this.libConfig) === null || _a === void 0 ? void 0 : _a.trAccordionComponent) === null || _b === void 0 ? void 0 : _b.expanded, false);
|
|
6859
|
+
_this.expandedChange = new core.EventEmitter();
|
|
6860
|
+
_this.isExpanded = function () { return _this.expanded === true; };
|
|
6861
|
+
_this.logPrefix = '[inail-tr-accordion]';
|
|
6862
|
+
_super.prototype.overrideConfig.call(_this, libConfig === null || libConfig === void 0 ? void 0 : libConfig.trAccordionComponent);
|
|
6863
|
+
_this.detach();
|
|
6864
|
+
return _this;
|
|
6865
|
+
}
|
|
6866
|
+
TrAccordionComponent.prototype.ngOnChanges = function (changes) {
|
|
6867
|
+
_super.prototype.ngOnChanges.call(this, changes);
|
|
6868
|
+
this.cdr.detectChanges();
|
|
6869
|
+
};
|
|
6870
|
+
TrAccordionComponent.prototype.ngOnInit = function () {
|
|
6871
|
+
_super.prototype.ngOnInit.call(this);
|
|
6872
|
+
};
|
|
6873
|
+
TrAccordionComponent.prototype.toggle = function (expanded) {
|
|
6874
|
+
if (this.trParent) {
|
|
6875
|
+
this.expanded = (expanded != undefined) ? expanded : this.trParent.hidden;
|
|
6876
|
+
this.trParent.hidden = !this.expanded;
|
|
6877
|
+
this.expandedChange.emit(this.expanded);
|
|
6878
|
+
this.cdr.detectChanges();
|
|
6879
|
+
}
|
|
6880
|
+
};
|
|
6881
|
+
TrAccordionComponent.prototype.ngOnDestroy = function () {
|
|
6882
|
+
_super.prototype.ngOnDestroy.call(this);
|
|
6883
|
+
};
|
|
6884
|
+
TrAccordionComponent.prototype.ngAfterViewInit = function () {
|
|
6885
|
+
var _a, _b, _c, _d;
|
|
6886
|
+
this.trParent = this.elRef.nativeElement;
|
|
6887
|
+
this.colspan = (_d = (_c = (_b = (_a = this.trParent) === null || _a === void 0 ? void 0 : _a.closest('table')) === null || _b === void 0 ? void 0 : _b.querySelector('thead')) === null || _c === void 0 ? void 0 : _c.querySelectorAll('tr th')) === null || _d === void 0 ? void 0 : _d.length;
|
|
6888
|
+
this.toggle(this.expanded);
|
|
6889
|
+
this.cdr.detectChanges();
|
|
6890
|
+
};
|
|
6891
|
+
return TrAccordionComponent;
|
|
6892
|
+
}(BasicUxElementComponent));
|
|
6893
|
+
TrAccordionComponent.decorators = [
|
|
6894
|
+
{ type: core.Component, args: [{
|
|
6895
|
+
selector: '.inail-tr-accordion',
|
|
6896
|
+
template: "<td [colSpan]=\"colspan\" class=\"accordionTab\">\n <form class=\"row form-grey pop\">\n <ng-content select=\"[content]\"></ng-content>\n </form>\n <div class=\"row baseFooter\">\n <ng-content select=\"[footer]\"></ng-content>\n </div>\n</td>\n",
|
|
6897
|
+
changeDetection: CHANGE_DETECTION_STRATEGY,
|
|
6898
|
+
encapsulation: core.ViewEncapsulation.None,
|
|
6899
|
+
styles: [""]
|
|
6900
|
+
},] }
|
|
6901
|
+
];
|
|
6902
|
+
TrAccordionComponent.ctorParameters = function () { return [
|
|
6903
|
+
{ type: core.ElementRef },
|
|
6904
|
+
{ type: core.ChangeDetectorRef },
|
|
6905
|
+
{ type: undefined, decorators: [{ type: core.Inject, args: [NG_INAIL_COMMON_CONFIG,] }] }
|
|
6906
|
+
]; };
|
|
6907
|
+
TrAccordionComponent.propDecorators = {
|
|
6908
|
+
expanded: [{ type: core.Input }],
|
|
6909
|
+
expandedChange: [{ type: core.Output }]
|
|
6910
|
+
};
|
|
6911
|
+
|
|
6839
6912
|
var NgInailCommonModule = /** @class */ (function () {
|
|
6840
6913
|
function NgInailCommonModule() {
|
|
6841
6914
|
}
|
|
@@ -6903,7 +6976,8 @@
|
|
|
6903
6976
|
TrCheckboxComponent,
|
|
6904
6977
|
ProgressBarComponent,
|
|
6905
6978
|
MultiSelectComponent,
|
|
6906
|
-
InputTimeComponent
|
|
6979
|
+
InputTimeComponent,
|
|
6980
|
+
TrAccordionComponent
|
|
6907
6981
|
],
|
|
6908
6982
|
imports: [
|
|
6909
6983
|
common.CommonModule,
|
|
@@ -6954,7 +7028,8 @@
|
|
|
6954
7028
|
TrCheckboxComponent,
|
|
6955
7029
|
ProgressBarComponent,
|
|
6956
7030
|
MultiSelectComponent,
|
|
6957
|
-
InputTimeComponent
|
|
7031
|
+
InputTimeComponent,
|
|
7032
|
+
TrAccordionComponent
|
|
6958
7033
|
],
|
|
6959
7034
|
providers: [common.DatePipe]
|
|
6960
7035
|
},] }
|
|
@@ -7018,6 +7093,7 @@
|
|
|
7018
7093
|
exports.TablePageLengthSelectorComponent = TablePageLengthSelectorComponent;
|
|
7019
7094
|
exports.TextareaComponent = TextareaComponent;
|
|
7020
7095
|
exports.ThLabelComponent = ThLabelComponent;
|
|
7096
|
+
exports.TrAccordionComponent = TrAccordionComponent;
|
|
7021
7097
|
exports.TrCheckboxComponent = TrCheckboxComponent;
|
|
7022
7098
|
exports.WizardComponent = WizardComponent;
|
|
7023
7099
|
exports.addZero = addZero;
|