@seniorsistemas/angular-components 17.8.13 → 17.8.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/bundles/seniorsistemas-angular-components.umd.js +28 -9
- package/bundles/seniorsistemas-angular-components.umd.js.map +1 -1
- package/bundles/seniorsistemas-angular-components.umd.min.js +1 -1
- package/bundles/seniorsistemas-angular-components.umd.min.js.map +1 -1
- package/components/navigation-button/index.d.ts +1 -1
- package/components/navigation-button/models/index.d.ts +2 -0
- package/components/navigation-button/models/navigation-button-step-changed-info.d.ts +5 -0
- package/components/navigation-button/navigation-button.component.d.ts +9 -6
- package/esm2015/components/navigation-button/index.js +1 -1
- package/esm2015/components/navigation-button/models/index.js +1 -0
- package/esm2015/components/navigation-button/models/navigation-button-step-changed-info.js +1 -0
- package/esm2015/components/navigation-button/navigation-button.component.js +29 -10
- package/esm5/components/navigation-button/index.js +1 -1
- package/esm5/components/navigation-button/models/index.js +1 -0
- package/esm5/components/navigation-button/models/navigation-button-step-changed-info.js +1 -0
- package/esm5/components/navigation-button/navigation-button.component.js +30 -11
- package/fesm2015/seniorsistemas-angular-components.js +27 -8
- package/fesm2015/seniorsistemas-angular-components.js.map +1 -1
- package/fesm5/seniorsistemas-angular-components.js +28 -9
- package/fesm5/seniorsistemas-angular-components.js.map +1 -1
- package/package.json +1 -1
- package/seniorsistemas-angular-components.metadata.json +1 -1
|
@@ -14899,7 +14899,9 @@
|
|
|
14899
14899
|
}());
|
|
14900
14900
|
|
|
14901
14901
|
var NavigationButtonComponent = /** @class */ (function () {
|
|
14902
|
-
function NavigationButtonComponent() {
|
|
14902
|
+
function NavigationButtonComponent(changeDetectorRef) {
|
|
14903
|
+
this.changeDetectorRef = changeDetectorRef;
|
|
14904
|
+
this.changeOnInit = false;
|
|
14903
14905
|
this.stepChanged = new core.EventEmitter();
|
|
14904
14906
|
this.currentIndex = 0;
|
|
14905
14907
|
this.isDisabled = false;
|
|
@@ -14907,14 +14909,25 @@
|
|
|
14907
14909
|
}
|
|
14908
14910
|
NavigationButtonComponent_1 = NavigationButtonComponent;
|
|
14909
14911
|
NavigationButtonComponent.prototype.ngOnInit = function () {
|
|
14910
|
-
var _this = this;
|
|
14911
|
-
var index = this.steps.findIndex(function (step) { return step.value === _this._value; });
|
|
14912
|
-
this.currentIndex = index !== -1 ? index : 0;
|
|
14913
|
-
this.stepChanged.emit({
|
|
14914
|
-
previous: undefined,
|
|
14915
|
-
current: this.steps[this.currentIndex],
|
|
14916
|
-
});
|
|
14917
14912
|
this._createTieredMenuItems();
|
|
14913
|
+
if (this.changeOnInit) {
|
|
14914
|
+
this.stepChanged.emit({
|
|
14915
|
+
previous: undefined,
|
|
14916
|
+
current: this.steps[this.currentIndex],
|
|
14917
|
+
});
|
|
14918
|
+
}
|
|
14919
|
+
};
|
|
14920
|
+
NavigationButtonComponent.prototype.ngAfterViewInit = function () {
|
|
14921
|
+
this._setDefaultValue();
|
|
14922
|
+
};
|
|
14923
|
+
NavigationButtonComponent.prototype._setDefaultValue = function () {
|
|
14924
|
+
var _this = this;
|
|
14925
|
+
if (this.defaultValue) {
|
|
14926
|
+
this._value = this.defaultValue;
|
|
14927
|
+
var index = this.steps.findIndex(function (step) { return step.value === _this._value; });
|
|
14928
|
+
this.currentIndex = index !== -1 ? index : 0;
|
|
14929
|
+
this.changeDetectorRef.detectChanges();
|
|
14930
|
+
}
|
|
14918
14931
|
};
|
|
14919
14932
|
NavigationButtonComponent.prototype.writeValue = function (value) {
|
|
14920
14933
|
var _this = this;
|
|
@@ -14960,11 +14973,14 @@
|
|
|
14960
14973
|
this.steps.forEach(function (step) {
|
|
14961
14974
|
_this.tieredMenuItems.push({
|
|
14962
14975
|
label: step.label,
|
|
14963
|
-
command: function () { return _this.currentIndex = _this.steps.findIndex(function (s) { return s === step; }); },
|
|
14976
|
+
command: function () { return (_this.currentIndex = _this.steps.findIndex(function (s) { return s === step; })); },
|
|
14964
14977
|
});
|
|
14965
14978
|
});
|
|
14966
14979
|
};
|
|
14967
14980
|
var NavigationButtonComponent_1;
|
|
14981
|
+
NavigationButtonComponent.ctorParameters = function () { return [
|
|
14982
|
+
{ type: core.ChangeDetectorRef }
|
|
14983
|
+
]; };
|
|
14968
14984
|
__decorate([
|
|
14969
14985
|
core.Input()
|
|
14970
14986
|
], NavigationButtonComponent.prototype, "steps", void 0);
|
|
@@ -14974,6 +14990,9 @@
|
|
|
14974
14990
|
__decorate([
|
|
14975
14991
|
core.Input()
|
|
14976
14992
|
], NavigationButtonComponent.prototype, "tooltip", void 0);
|
|
14993
|
+
__decorate([
|
|
14994
|
+
core.Input()
|
|
14995
|
+
], NavigationButtonComponent.prototype, "changeOnInit", void 0);
|
|
14977
14996
|
__decorate([
|
|
14978
14997
|
core.Output()
|
|
14979
14998
|
], NavigationButtonComponent.prototype, "stepChanged", void 0);
|