@wizishop/angular-components 0.0.83 → 0.0.86
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/angular-components.scss +4893 -4893
- package/bundles/wizishop-angular-components.umd.js +14 -7
- package/bundles/wizishop-angular-components.umd.js.map +1 -1
- package/bundles/wizishop-angular-components.umd.min.js +2 -2
- package/bundles/wizishop-angular-components.umd.min.js.map +1 -1
- package/esm2015/lib/components/switch/switch.component.js +3 -3
- package/esm2015/lib/components/tab/tab.component.js +6 -5
- package/esm2015/lib/components/table/shared/filters-table.service.js +5 -2
- package/esm2015/lib/components/table/shared/table-filters-group.model.js +4 -0
- package/esm2015/lib/components/table/table.component.js +5 -2
- package/esm2015/lib/components/tag/tag.component.js +2 -1
- package/fesm2015/wizishop-angular-components.js +15 -8
- package/fesm2015/wizishop-angular-components.js.map +1 -1
- package/lib/components/tab/tab.component.d.ts +1 -1
- package/lib/components/table/shared/filters-table.service.d.ts +2 -1
- package/lib/components/table/shared/table-filters-group.model.d.ts +7 -0
- package/package.json +1 -1
- package/wizishop-angular-components-0.0.86.tgz +0 -0
- package/wizishop-angular-components.metadata.json +1 -1
- package/wizishop-angular-components-0.0.83.tgz +0 -0
|
@@ -698,6 +698,8 @@
|
|
|
698
698
|
currentPage: 0
|
|
699
699
|
};
|
|
700
700
|
var filterGroup = this.filterRoutingBuilder.group(dataTableFilters, dataTableName);
|
|
701
|
+
filterGroup.tableFiltersValuesChange$ = new rxjs.ReplaySubject(1);
|
|
702
|
+
filterGroup.tableFiltersValuesDebouncedChange$ = filterGroup.tableFiltersValuesChange$.pipe(operators.debounceTime(300));
|
|
701
703
|
this.filterGroups.set(dataTableName, filterGroup);
|
|
702
704
|
return filterGroup;
|
|
703
705
|
};
|
|
@@ -763,11 +765,12 @@
|
|
|
763
765
|
/* Handle routing filters */
|
|
764
766
|
if (this.tableRoutingName) {
|
|
765
767
|
this._filterGroup = this.filtersTableService.getTableFilterGroup(this.tableRoutingName);
|
|
768
|
+
this.setTablesFilters();
|
|
766
769
|
// Performe initial fetch data
|
|
767
770
|
this._filterGroup.valuesChange$.next([]);
|
|
768
|
-
this.setTablesFilters();
|
|
769
771
|
// Listen to filters changes with debounced time to limit multiple api calls
|
|
770
772
|
this.filterGroupChangeSub = this._filterGroup.valuesChange$.subscribe(function (filters) {
|
|
773
|
+
console.log('valuesChange', filters);
|
|
771
774
|
_this.setTablesFilters();
|
|
772
775
|
});
|
|
773
776
|
}
|
|
@@ -813,6 +816,8 @@
|
|
|
813
816
|
totalItems: this.tableFilters.totalItems
|
|
814
817
|
};
|
|
815
818
|
this.tableFiltersChange.emit(this.tableFilters);
|
|
819
|
+
console.log('tableFiltersValuesChange$.next');
|
|
820
|
+
this._filterGroup.tableFiltersValuesChange$.next(this.tableFilters);
|
|
816
821
|
};
|
|
817
822
|
TableComponent.prototype.ngDestroy = function () {
|
|
818
823
|
if (this.filterGroupChangeSub) {
|
|
@@ -845,6 +850,7 @@
|
|
|
845
850
|
|
|
846
851
|
var TagComponent = /** @class */ (function () {
|
|
847
852
|
function TagComponent() {
|
|
853
|
+
//todo Refacto, open/close should be handle outside this component
|
|
848
854
|
this.label = '';
|
|
849
855
|
this.hasClose = false;
|
|
850
856
|
this.big = false;
|
|
@@ -881,19 +887,19 @@
|
|
|
881
887
|
this.underline = false;
|
|
882
888
|
this.button = false;
|
|
883
889
|
this.tabs = [];
|
|
890
|
+
this.index = 0;
|
|
884
891
|
this.indexChange = new i0.EventEmitter();
|
|
885
|
-
this.currentIndex = 0;
|
|
886
892
|
}
|
|
887
893
|
TabComponent.prototype.valueChanged = function (i) {
|
|
888
|
-
this.
|
|
889
|
-
this.indexChange.emit(this.
|
|
894
|
+
this.index = i;
|
|
895
|
+
this.indexChange.emit(this.index);
|
|
890
896
|
};
|
|
891
897
|
return TabComponent;
|
|
892
898
|
}());
|
|
893
899
|
TabComponent.decorators = [
|
|
894
900
|
{ type: i0.Component, args: [{
|
|
895
901
|
selector: 'wac-tab',
|
|
896
|
-
template: "<div class=\"wac-tab\" [ngClass]=\"{'wac-tab--underline': underline, 'wac-tab--button' : button}\">\n <div class=\"wac-tab__wrapper\">\n <a\n *ngFor=\"let tab of tabs\"\n class=\"wac-tab__wrapper__tab\"\n [ngClass]=\"
|
|
902
|
+
template: "<div class=\"wac-tab\" [ngClass]=\"{'wac-tab--underline': underline, 'wac-tab--button' : button}\">\n <div class=\"wac-tab__wrapper\">\n <a\n *ngFor=\"let tab of tabs\"\n class=\"wac-tab__wrapper__tab\"\n [ngClass]=\"index === tab.index ? 'wac-tab__wrapper__tab--selected' : ''\"\n (click)=\"valueChanged(tab.index)\"\n >\n {{ tab.label }}\n </a>\n </div>\n</div>\n",
|
|
897
903
|
encapsulation: i0.ViewEncapsulation.None
|
|
898
904
|
},] }
|
|
899
905
|
];
|
|
@@ -902,6 +908,7 @@
|
|
|
902
908
|
underline: [{ type: i0.Input }],
|
|
903
909
|
button: [{ type: i0.Input }],
|
|
904
910
|
tabs: [{ type: i0.Input }],
|
|
911
|
+
index: [{ type: i0.Input }],
|
|
905
912
|
indexChange: [{ type: i0.Output }]
|
|
906
913
|
};
|
|
907
914
|
|
|
@@ -2006,8 +2013,8 @@
|
|
|
2006
2013
|
this.textStateDisable = '';
|
|
2007
2014
|
this.showInput = false;
|
|
2008
2015
|
this.danger = false;
|
|
2009
|
-
this.switchChange = new i0.EventEmitter();
|
|
2010
|
-
this.changeInput = new i0.EventEmitter();
|
|
2016
|
+
this.switchChange = new i0.EventEmitter(); // todo set emitted type
|
|
2017
|
+
this.changeInput = new i0.EventEmitter(); // todo set emitted type
|
|
2011
2018
|
}
|
|
2012
2019
|
SwitchComponent.prototype.ngOnInit = function () {
|
|
2013
2020
|
this.id = 'switch-' + Math.floor(Math.random() * Math.floor(1000));
|