@trudb/tru-common-lib 0.0.205 → 0.0.207
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/tru-context-filter.mjs +2 -1
- package/esm2020/lib/components/desktop/menubar/tru-desktop-menubar.mjs +13 -11
- package/fesm2015/trudb-tru-common-lib.mjs +6 -4
- package/fesm2015/trudb-tru-common-lib.mjs.map +1 -1
- package/fesm2020/trudb-tru-common-lib.mjs +6 -4
- package/fesm2020/trudb-tru-common-lib.mjs.map +1 -1
- package/lib/components/desktop/menubar/tru-desktop-menubar.d.ts +3 -1
- package/package.json +1 -1
|
@@ -438,6 +438,7 @@ class TruContextFilter {
|
|
|
438
438
|
return o1 && o2 ? o1.label === o2.label : o2 === o2;
|
|
439
439
|
};
|
|
440
440
|
this.onChange = (choice) => {
|
|
441
|
+
this.selectedChoice = choice;
|
|
441
442
|
};
|
|
442
443
|
}
|
|
443
444
|
}
|
|
@@ -2427,7 +2428,8 @@ class ViewConfig {
|
|
|
2427
2428
|
;
|
|
2428
2429
|
|
|
2429
2430
|
class TruDesktopMenubar {
|
|
2430
|
-
constructor() {
|
|
2431
|
+
constructor(contextFilters) {
|
|
2432
|
+
this.contextFilters = contextFilters;
|
|
2431
2433
|
this.options = null;
|
|
2432
2434
|
this.configs = null;
|
|
2433
2435
|
this.filters = [];
|
|
@@ -2438,15 +2440,15 @@ class TruDesktopMenubar {
|
|
|
2438
2440
|
ngOnInit() {
|
|
2439
2441
|
this.options = this.desktopCtrl.getOptions();
|
|
2440
2442
|
this.configs = this.options.menubarConfig;
|
|
2441
|
-
this.filters = this.
|
|
2443
|
+
this.filters = this.contextFilters.filters;
|
|
2442
2444
|
}
|
|
2443
2445
|
}
|
|
2444
|
-
TruDesktopMenubar.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.2", ngImport: i0, type: TruDesktopMenubar, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2446
|
+
TruDesktopMenubar.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.2", ngImport: i0, type: TruDesktopMenubar, deps: [{ token: TruContextFilters }], target: i0.ɵɵFactoryTarget.Component });
|
|
2445
2447
|
TruDesktopMenubar.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.1.2", type: TruDesktopMenubar, selector: "tru-desktop-menubar", inputs: { desktopCtrl: "desktopCtrl" }, ngImport: i0, template: "<div class=\"desktop-main-menu\">\r\n <tru-toolbar>\r\n <tru-toolbar-menu *ngFor=\"let config of configs\" [config]=\"config\"></tru-toolbar-menu>\r\n <tru-toolbar-separator *ngIf=\"filters.length\"></tru-toolbar-separator>\r\n <tru-toolbar-context-filter></tru-toolbar-context-filter>\r\n </tru-toolbar>\r\n</div>\r\n", styles: [""], dependencies: [{ kind: "directive", type: i1$3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: TruToolbar, selector: "tru-toolbar", inputs: ["config"] }, { kind: "component", type: TruToolbarMenu, selector: "tru-toolbar-menu", inputs: ["config"] }, { kind: "component", type: TruToolbarSeparator, selector: "tru-toolbar-separator" }, { kind: "component", type: TruToolbarContextFilter, selector: "tru-toolbar-context-filter" }], encapsulation: i0.ViewEncapsulation.None });
|
|
2446
2448
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.2", ngImport: i0, type: TruDesktopMenubar, decorators: [{
|
|
2447
2449
|
type: Component,
|
|
2448
2450
|
args: [{ selector: 'tru-desktop-menubar', encapsulation: ViewEncapsulation.None, template: "<div class=\"desktop-main-menu\">\r\n <tru-toolbar>\r\n <tru-toolbar-menu *ngFor=\"let config of configs\" [config]=\"config\"></tru-toolbar-menu>\r\n <tru-toolbar-separator *ngIf=\"filters.length\"></tru-toolbar-separator>\r\n <tru-toolbar-context-filter></tru-toolbar-context-filter>\r\n </tru-toolbar>\r\n</div>\r\n" }]
|
|
2449
|
-
}], ctorParameters: function () { return []; }, propDecorators: { desktopCtrl: [{
|
|
2451
|
+
}], ctorParameters: function () { return [{ type: TruContextFilters }]; }, propDecorators: { desktopCtrl: [{
|
|
2450
2452
|
type: Input
|
|
2451
2453
|
}] } });
|
|
2452
2454
|
|