@tilde-nlp/ngx-menu 6.1.6 → 6.1.8
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/esm2022/lib/components/menu-columns/menu-columns.component.mjs +14 -11
- package/esm2022/lib/components/menu-item-list/menu-item-list.component.mjs +6 -6
- package/esm2022/lib/components/side-nav-menu/side-nav-menu.component.mjs +160 -105
- package/esm2022/lib/menu.module.mjs +1 -11
- package/esm2022/public-api.mjs +1 -4
- package/fesm2022/tilde-nlp-ngx-menu.mjs +182 -323
- package/fesm2022/tilde-nlp-ngx-menu.mjs.map +1 -1
- package/lib/components/menu-columns/menu-columns.component.d.ts +5 -6
- package/lib/components/side-nav-menu/side-nav-menu.component.d.ts +3 -1
- package/lib/menu.module.d.ts +17 -19
- package/package.json +1 -1
- package/public-api.d.ts +0 -3
- package/esm2022/lib/assets/menu-logo.svg.mjs +0 -7
- package/esm2022/lib/components/menu-item-icon/menu-item-icon.component.mjs +0 -115
- package/esm2022/lib/components/menu-item-icon/menu.model.mjs +0 -4
- package/esm2022/lib/components/menu-item-icon/models/menu-dialog-settings.model.mjs +0 -2
- package/esm2022/lib/components/menu-item-icon/models/menu-item-settings.model.mjs +0 -2
- package/esm2022/lib/components/menu-item-icon/models/menu-title-placement.model.mjs +0 -7
- package/esm2022/lib/components/modal-nav-menu/modal-nav-menu.component.mjs +0 -82
- package/lib/assets/menu-logo.svg.d.ts +0 -1
- package/lib/components/menu-item-icon/menu-item-icon.component.d.ts +0 -28
- package/lib/components/menu-item-icon/menu.model.d.ts +0 -3
- package/lib/components/menu-item-icon/models/menu-dialog-settings.model.d.ts +0 -8
- package/lib/components/menu-item-icon/models/menu-item-settings.model.d.ts +0 -6
- package/lib/components/menu-item-icon/models/menu-title-placement.model.d.ts +0 -5
- package/lib/components/modal-nav-menu/modal-nav-menu.component.d.ts +0 -14
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Injectable, Optional, Inject, Component, Input, EventEmitter, Output,
|
|
2
|
+
import { Injectable, Optional, Inject, Component, Input, EventEmitter, Output, NgModule } from '@angular/core';
|
|
3
|
+
import * as i2 from '@tilde-nlp/ngx-common';
|
|
4
|
+
import { ResolutionHelper, PlausibleModule } from '@tilde-nlp/ngx-common';
|
|
3
5
|
import * as i1$1 from '@angular/router';
|
|
4
6
|
import { NavigationEnd, RouterModule } from '@angular/router';
|
|
5
7
|
import { map, BehaviorSubject, filter } from 'rxjs';
|
|
6
8
|
import * as i1 from '@tilde-nlp/ngx-strapi';
|
|
7
9
|
import { STRAPI_API_CONFIG_TOKEN } from '@tilde-nlp/ngx-strapi';
|
|
8
10
|
import { CollectionTypes } from '@tilde-nlp/strapi-models';
|
|
9
|
-
import * as
|
|
10
|
-
import
|
|
11
|
-
import * as i2$2 from '@ngbracket/ngx-layout/flex';
|
|
11
|
+
import * as i4 from '@ngbracket/ngx-layout/flex';
|
|
12
|
+
import * as i5 from '@ngbracket/ngx-layout/extended';
|
|
12
13
|
import * as i3 from '@angular/common';
|
|
13
14
|
import { CommonModule } from '@angular/common';
|
|
14
15
|
import * as i2$1 from '@angular/material/icon';
|
|
15
16
|
import { MatIconModule } from '@angular/material/icon';
|
|
16
|
-
import * as
|
|
17
|
+
import * as i9 from '@angular/material/button';
|
|
17
18
|
import { MatButtonModule } from '@angular/material/button';
|
|
18
|
-
import * as
|
|
19
|
+
import * as i10 from '@angular/material/menu';
|
|
19
20
|
import { MatMenuModule } from '@angular/material/menu';
|
|
20
|
-
import * as i4 from '@angular/material/divider';
|
|
21
|
-
import * as
|
|
22
|
-
import * as i5 from '@angular/material/tooltip';
|
|
21
|
+
import * as i4$1 from '@angular/material/divider';
|
|
22
|
+
import * as i5$1 from '@angular/material/tooltip';
|
|
23
23
|
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
24
24
|
import * as i8 from '@ngx-translate/core';
|
|
25
25
|
import { TranslateModule } from '@ngx-translate/core';
|
|
@@ -388,7 +388,7 @@ class MenuItemLinkComponent {
|
|
|
388
388
|
i0.ɵɵproperty("ngIf", ctx.showIcons && ctx.menuItem.icon);
|
|
389
389
|
i0.ɵɵadvance();
|
|
390
390
|
i0.ɵɵproperty("ngIf", ctx.labelsVisible);
|
|
391
|
-
} }, dependencies: [
|
|
391
|
+
} }, dependencies: [i4.DefaultLayoutDirective, i4.DefaultLayoutAlignDirective, i5.DefaultClassDirective, i3.NgIf, i5$1.MatTooltip, i2.PlausibleEventDirective, MenuIconComponent, i8.TranslatePipe], styles: ["[_nghost-%COMP%]{width:100%}.mobile[_ngcontent-%COMP%] .menu-item-title[_ngcontent-%COMP%]{margin-left:5px}"] }); }
|
|
392
392
|
}
|
|
393
393
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(MenuItemLinkComponent, [{
|
|
394
394
|
type: Component,
|
|
@@ -406,7 +406,7 @@ class MenuItemLinkComponent {
|
|
|
406
406
|
}] }); })();
|
|
407
407
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(MenuItemLinkComponent, { className: "MenuItemLinkComponent", filePath: "lib\\components\\menu-item-link\\menu-item-link.component.ts", lineNumber: 10 }); })();
|
|
408
408
|
|
|
409
|
-
const _c0$
|
|
409
|
+
const _c0$1 = a0 => ({ menuItem: a0 });
|
|
410
410
|
function MenuItemListComponent_div_1_Template(rf, ctx) { if (rf & 1) {
|
|
411
411
|
i0.ɵɵelementStart(0, "div", 6);
|
|
412
412
|
i0.ɵɵtext(1);
|
|
@@ -430,7 +430,7 @@ function MenuItemListComponent_ng_container_3_Template(rf, ctx) { if (rf & 1) {
|
|
|
430
430
|
const itemWithChildren_r3 = i0.ɵɵreference(5);
|
|
431
431
|
const menuItemLink_r4 = i0.ɵɵreference(7);
|
|
432
432
|
i0.ɵɵadvance();
|
|
433
|
-
i0.ɵɵproperty("ngTemplateOutlet", !menuItem_r2.showChildren || !menuItem_r2.children || (menuItem_r2 == null ? null : menuItem_r2.children == null ? null : menuItem_r2.children.length) === 0 ? menuItemLink_r4 : itemWithChildren_r3)("ngTemplateOutletContext", i0.ɵɵpureFunction1(2, _c0$
|
|
433
|
+
i0.ɵɵproperty("ngTemplateOutlet", !menuItem_r2.showChildren || !menuItem_r2.children || (menuItem_r2 == null ? null : menuItem_r2.children == null ? null : menuItem_r2.children.length) === 0 ? menuItemLink_r4 : itemWithChildren_r3)("ngTemplateOutletContext", i0.ɵɵpureFunction1(2, _c0$1, menuItem_r2));
|
|
434
434
|
} }
|
|
435
435
|
function MenuItemListComponent_ng_template_4_ng_container_2_Template(rf, ctx) { if (rf & 1) {
|
|
436
436
|
i0.ɵɵelementContainerStart(0);
|
|
@@ -470,11 +470,11 @@ function MenuItemListComponent_ng_template_4_ng_container_4_menu_item_list_1_Tem
|
|
|
470
470
|
} if (rf & 2) {
|
|
471
471
|
const menuItem_r6 = i0.ɵɵnextContext(2).menuItem;
|
|
472
472
|
const ctx_r0 = i0.ɵɵnextContext();
|
|
473
|
-
i0.ɵɵproperty("
|
|
473
|
+
i0.ɵɵproperty("items", menuItem_r6.children)("direction", ctx_r0.direction)("labelsVisible", ctx_r0.labelsVisible)("activeItem", ctx_r0.activeItem);
|
|
474
474
|
} }
|
|
475
475
|
function MenuItemListComponent_ng_template_4_ng_container_4_Template(rf, ctx) { if (rf & 1) {
|
|
476
476
|
i0.ɵɵelementContainerStart(0);
|
|
477
|
-
i0.ɵɵtemplate(1, MenuItemListComponent_ng_template_4_ng_container_4_menu_item_list_1_Template, 1,
|
|
477
|
+
i0.ɵɵtemplate(1, MenuItemListComponent_ng_template_4_ng_container_4_menu_item_list_1_Template, 1, 4, "menu-item-list", 15);
|
|
478
478
|
i0.ɵɵelementContainerEnd();
|
|
479
479
|
} if (rf & 2) {
|
|
480
480
|
const menuItem_r6 = i0.ɵɵnextContext().menuItem;
|
|
@@ -539,7 +539,7 @@ class MenuItemListComponent {
|
|
|
539
539
|
this.toggleExpand.next(menuItem);
|
|
540
540
|
}
|
|
541
541
|
static { this.ɵfac = function MenuItemListComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || MenuItemListComponent)(); }; }
|
|
542
|
-
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: MenuItemListComponent, selectors: [["menu-item-list"]], inputs: { direction: "direction", labelsVisible: "labelsVisible", activeItem: "activeItem", showIcons: "showIcons", items: "items", menuItemGroup: "menuItemGroup" }, outputs: { toggleExpand: "toggleExpand" }, decls: 8, vars: 3, consts: [["itemWithChildren", ""], ["menuItemLink", ""], [1, "menu-list-wrapper"], ["fxLayoutAlign", "start center", "class", "menu-item-list-title", 4, "ngIf"], ["fxLayout", "column", 1, "menu-item-list", 3, "fxLayoutAlign"], [4, "ngFor", "ngForOf"], ["fxLayoutAlign", "start center", 1, "menu-item-list-title"], [4, "ngTemplateOutlet", "ngTemplateOutletContext"], ["matTooltipPosition", "after", "matTooltipClass", "menu-tooltip", "fxLayoutGap", "0.375rem", 1, "text-m", "menu-item", 3, "click", "ngClass.lt-md", "fxLayout", "matTooltip", "fxLayoutAlign"], [4, "ngIf"], [3, "menuItem"], [1, "menu-item-title"], [1, "title-content"], ["class", "material-icons", 4, "ngIf"], [1, "material-icons"], ["class", "child-list", 3, "
|
|
542
|
+
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: MenuItemListComponent, selectors: [["menu-item-list"]], inputs: { direction: "direction", labelsVisible: "labelsVisible", activeItem: "activeItem", showIcons: "showIcons", items: "items", menuItemGroup: "menuItemGroup" }, outputs: { toggleExpand: "toggleExpand" }, decls: 8, vars: 3, consts: [["itemWithChildren", ""], ["menuItemLink", ""], [1, "menu-list-wrapper"], ["fxLayoutAlign", "start center", "class", "menu-item-list-title", 4, "ngIf"], ["fxLayout", "column", 1, "menu-item-list", 3, "fxLayoutAlign"], [4, "ngFor", "ngForOf"], ["fxLayoutAlign", "start center", 1, "menu-item-list-title"], [4, "ngTemplateOutlet", "ngTemplateOutletContext"], ["matTooltipPosition", "after", "matTooltipClass", "menu-tooltip", "fxLayoutGap", "0.375rem", 1, "text-m", "menu-item", 3, "click", "ngClass.lt-md", "fxLayout", "matTooltip", "fxLayoutAlign"], [4, "ngIf"], [3, "menuItem"], [1, "menu-item-title"], [1, "title-content"], ["class", "material-icons", 4, "ngIf"], [1, "material-icons"], ["class", "child-list", 3, "items", "direction", "labelsVisible", "activeItem", 4, "ngIf"], [1, "child-list", 3, "items", "direction", "labelsVisible", "activeItem"], [3, "ngClass.lt-md", "menuItem", "direction", "labelsVisible", "activeItem", "showIcons"]], template: function MenuItemListComponent_Template(rf, ctx) { if (rf & 1) {
|
|
543
543
|
i0.ɵɵelementStart(0, "div", 2);
|
|
544
544
|
i0.ɵɵtemplate(1, MenuItemListComponent_div_1_Template, 3, 3, "div", 3);
|
|
545
545
|
i0.ɵɵelementStart(2, "div", 4);
|
|
@@ -553,11 +553,11 @@ class MenuItemListComponent {
|
|
|
553
553
|
i0.ɵɵproperty("fxLayoutAlign", ctx.menuLayoutDirection);
|
|
554
554
|
i0.ɵɵadvance();
|
|
555
555
|
i0.ɵɵproperty("ngForOf", ctx.items);
|
|
556
|
-
} }, dependencies: [
|
|
556
|
+
} }, dependencies: [i4.DefaultLayoutDirective, i4.DefaultLayoutGapDirective, i4.DefaultLayoutAlignDirective, i5.DefaultClassDirective, i3.NgForOf, i3.NgIf, i3.NgTemplateOutlet, i5$1.MatTooltip, MenuItemListComponent, MenuIconComponent, MenuItemLinkComponent, i8.TranslatePipe], styles: ["[_nghost-%COMP%]{display:inline-block} .collapsed .menu-item-list{display:flex!important;justify-content:center!important;align-items:center!important} .collapsed .menu-list-wrapper, .collapsed tld-menu-item-link{display:flex!important;justify-content:center!important} .collapsed .menu-item{display:flex!important;place-content:center center!important} .collapsed tld-menu-item-link:not(:first-child){margin-top:16px!important}[_nghost-%COMP%] .menu-list-wrapper .menu-item{cursor:pointer;font-style:normal;color:var(--base-30);text-decoration:none;align-items:center!important;font-weight:400;background:none;border:none}[_nghost-%COMP%] .menu-list-wrapper .menu-item:not(button):not(.active-menu-item):hover{background-color:var(--base-70)!important}[_nghost-%COMP%] .menu-list-wrapper .menu-item.active-menu-item, [_nghost-%COMP%] .menu-list-wrapper .menu-item.active-menu-item mat-icon, [_nghost-%COMP%] .menu-list-wrapper .menu-item.active-menu-item:hover{font-weight:600}[_nghost-%COMP%] .menu-list-wrapper .menu-item span{display:inline-block}[_nghost-%COMP%] .menu-list-wrapper .menu-item .menu-item-title{display:flex;flex-direction:row;align-items:start;width:100%}[_nghost-%COMP%] .menu-list-wrapper .menu-item .menu-item-title .title-content{display:block}[_nghost-%COMP%] .menu-list-wrapper .menu-item .menu-item-title .title-content:before{display:block;content:attr(content);font-weight:600;height:0;overflow:hidden;visibility:hidden}.child-list[_nghost-%COMP%]{margin-bottom:1rem}.child-list[_nghost-%COMP%] .menu-item[_ngcontent-%COMP%] + .menu-item[_ngcontent-%COMP%]{margin-top:.5rem} .menu-tooltip{left:.625rem;font-family:Roboto;font-style:normal;font-weight:400;font-size:.75rem;line-height:1.25rem;color:var(--base-70);border-radius:.25rem;position:relative} .menu-tooltip:after{width:0;height:0;content:\"\";position:absolute;border-left:.5rem solid transparent;border-right:.5rem solid transparent;border-bottom:.5rem solid var(--menu-border-dark-color);left:-.75rem;top:calc(50% - .25rem);transform:rotate(270deg);overflow:initial}"] }); }
|
|
557
557
|
}
|
|
558
558
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(MenuItemListComponent, [{
|
|
559
559
|
type: Component,
|
|
560
|
-
args: [{ selector: 'menu-item-list', template: "<div class=\"menu-list-wrapper\">\r\n <div *ngIf=\"titleKey && showTitle && labelsVisible\" fxLayoutAlign=\"start center\" class=\"menu-item-list-title\">\r\n {{ titleKey | translate }}\r\n </div>\r\n <div fxLayout=\"column\" [fxLayoutAlign]=\"menuLayoutDirection\" class=\"menu-item-list\">\r\n <ng-container *ngFor=\"let menuItem of items\">\r\n <ng-container\r\n *ngTemplateOutlet=\"!menuItem.showChildren || !menuItem.children || menuItem?.children?.length === 0 ? menuItemLink : itemWithChildren; context: {menuItem: menuItem}\">\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n</div>\r\n\r\n<ng-template #itemWithChildren let-menuItem=\"menuItem\">\r\n <button [attr.id]=\"menuItem.customId\" [ngClass.lt-md]=\"'mob-menu-item'\" [fxLayout]=\"menuItemLayout\" class=\"text-m menu-item\"\r\n [matTooltip]=\"!labelsVisible ? (menuItem.title | translate) : ''\" matTooltipPosition=\"after\" [class.menu-labels-visible]=\"labelsVisible\"\r\n [fxLayoutAlign]=\"menuLayoutDirection\" matTooltipClass=\"menu-tooltip\" fxLayoutGap=\"0.375rem\"\r\n [class.active-menu-item]=\"activeItem?.link && menuItem === activeItem\" (click)=\"toggleItemExpand($event,menuItem)\">\r\n <ng-container *ngIf=\"showIcons && menuItem.icon\">\r\n <tld-menu-icon [menuItem]=\"menuItem\"></tld-menu-icon>\r\n </ng-container>\r\n <ng-container *ngIf=\"labelsVisible\">\r\n <span class=\"menu-item-title\">\r\n <span class=\"title-content\">{{ menuItem.title | translate }}</span></span>\r\n <span class=\"material-icons\" *ngIf=\"menuItem.showChildren && menuItem.children\">\r\n {{ menuItem.expanded ? 'arrow_drop_up' : 'arrow_drop_down' }}\r\n </span>\r\n </ng-container>\r\n </button>\r\n <ng-container *ngIf=\"menuItem.showChildren && menuItem.expanded && labelsVisible\">\r\n <menu-item-list
|
|
560
|
+
args: [{ selector: 'menu-item-list', template: "<div class=\"menu-list-wrapper\">\r\n <div *ngIf=\"titleKey && showTitle && labelsVisible\" fxLayoutAlign=\"start center\" class=\"menu-item-list-title\">\r\n {{ titleKey | translate }}\r\n </div>\r\n <div fxLayout=\"column\" [fxLayoutAlign]=\"menuLayoutDirection\" class=\"menu-item-list\">\r\n <ng-container *ngFor=\"let menuItem of items\">\r\n <ng-container\r\n *ngTemplateOutlet=\"!menuItem.showChildren || !menuItem.children || menuItem?.children?.length === 0 ? menuItemLink : itemWithChildren; context: {menuItem: menuItem}\">\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n</div>\r\n\r\n<ng-template #itemWithChildren let-menuItem=\"menuItem\">\r\n <button [attr.id]=\"menuItem.customId\" [ngClass.lt-md]=\"'mob-menu-item'\" [fxLayout]=\"menuItemLayout\" class=\"text-m menu-item\"\r\n [matTooltip]=\"!labelsVisible ? (menuItem.title | translate) : ''\" matTooltipPosition=\"after\" [class.menu-labels-visible]=\"labelsVisible\"\r\n [fxLayoutAlign]=\"menuLayoutDirection\" matTooltipClass=\"menu-tooltip\" fxLayoutGap=\"0.375rem\"\r\n [class.active-menu-item]=\"activeItem?.link && menuItem === activeItem\" (click)=\"toggleItemExpand($event,menuItem)\">\r\n <ng-container *ngIf=\"showIcons && menuItem.icon\">\r\n <tld-menu-icon [menuItem]=\"menuItem\"></tld-menu-icon>\r\n </ng-container>\r\n <ng-container *ngIf=\"labelsVisible\">\r\n <span class=\"menu-item-title\">\r\n <span class=\"title-content\">{{ menuItem.title | translate }}</span></span>\r\n <span class=\"material-icons\" *ngIf=\"menuItem.showChildren && menuItem.children\">\r\n {{ menuItem.expanded ? 'arrow_drop_up' : 'arrow_drop_down' }}\r\n </span>\r\n </ng-container>\r\n </button>\r\n <ng-container *ngIf=\"menuItem.showChildren && menuItem.expanded && labelsVisible\">\r\n <menu-item-list class=\"child-list\" *ngIf=\"menuItem.children && menuItem.children.length\" [items]=\"menuItem.children\"\r\n [direction]=\"direction\" [labelsVisible]=\"labelsVisible\" [activeItem]=\"activeItem\">\r\n </menu-item-list>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<ng-template #menuItemLink let-menuItem=\"menuItem\">\r\n <tld-menu-item-link [ngClass.lt-md]=\"'mob-menu-item'\" [menuItem]=\"menuItem\" [direction]=\"direction\" [labelsVisible]=\"labelsVisible\"\r\n [activeItem]=\"activeItem\" [showIcons]=\"showIcons\"></tld-menu-item-link>\r\n</ng-template>", styles: [":host{display:inline-block}::ng-deep .collapsed .menu-item-list{display:flex!important;justify-content:center!important;align-items:center!important}::ng-deep .collapsed .menu-list-wrapper,::ng-deep .collapsed tld-menu-item-link{display:flex!important;justify-content:center!important}::ng-deep .collapsed .menu-item{display:flex!important;place-content:center center!important}::ng-deep .collapsed tld-menu-item-link:not(:first-child){margin-top:16px!important}:host ::ng-deep .menu-list-wrapper .menu-item{cursor:pointer;font-style:normal;color:var(--base-30);text-decoration:none;align-items:center!important;font-weight:400;background:none;border:none}:host ::ng-deep .menu-list-wrapper .menu-item:not(button):not(.active-menu-item):hover{background-color:var(--base-70)!important}:host ::ng-deep .menu-list-wrapper .menu-item.active-menu-item,:host ::ng-deep .menu-list-wrapper .menu-item.active-menu-item mat-icon,:host ::ng-deep .menu-list-wrapper .menu-item.active-menu-item:hover{font-weight:600}:host ::ng-deep .menu-list-wrapper .menu-item span{display:inline-block}:host ::ng-deep .menu-list-wrapper .menu-item .menu-item-title{display:flex;flex-direction:row;align-items:start;width:100%}:host ::ng-deep .menu-list-wrapper .menu-item .menu-item-title .title-content{display:block}:host ::ng-deep .menu-list-wrapper .menu-item .menu-item-title .title-content:before{display:block;content:attr(content);font-weight:600;height:0;overflow:hidden;visibility:hidden}:host.child-list{margin-bottom:1rem}:host.child-list .menu-item+.menu-item{margin-top:.5rem}::ng-deep .menu-tooltip{left:.625rem;font-family:Roboto;font-style:normal;font-weight:400;font-size:.75rem;line-height:1.25rem;color:var(--base-70);border-radius:.25rem;position:relative}::ng-deep .menu-tooltip:after{width:0;height:0;content:\"\";position:absolute;border-left:.5rem solid transparent;border-right:.5rem solid transparent;border-bottom:.5rem solid var(--menu-border-dark-color);left:-.75rem;top:calc(50% - .25rem);transform:rotate(270deg);overflow:initial}\n"] }]
|
|
561
561
|
}], null, { direction: [{
|
|
562
562
|
type: Input
|
|
563
563
|
}], labelsVisible: [{
|
|
@@ -583,7 +583,7 @@ function MenuColumnsComponent_ng_container_0_menu_item_list_1_Template(rf, ctx)
|
|
|
583
583
|
} if (rf & 2) {
|
|
584
584
|
const group_r3 = i0.ɵɵnextContext().$implicit;
|
|
585
585
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
586
|
-
i0.ɵɵproperty("activeItem", ctx_r1.activeItem)("direction", ctx_r1.direction)("labelsVisible", ctx_r1.
|
|
586
|
+
i0.ɵɵproperty("activeItem", ctx_r1.activeItem)("direction", ctx_r1.direction)("labelsVisible", ctx_r1.isOpen)("menuItemGroup", group_r3)("items", group_r3.items);
|
|
587
587
|
} }
|
|
588
588
|
function MenuColumnsComponent_ng_container_0_div_2_Template(rf, ctx) { if (rf & 1) {
|
|
589
589
|
i0.ɵɵelementStart(0, "div", 4);
|
|
@@ -604,6 +604,9 @@ function MenuColumnsComponent_ng_container_0_Template(rf, ctx) { if (rf & 1) {
|
|
|
604
604
|
class MenuColumnsComponent {
|
|
605
605
|
get active() { return this._active; }
|
|
606
606
|
set active(value) {
|
|
607
|
+
if (this.toggleOnMobileSelect()) {
|
|
608
|
+
this.toggleCollapseEvent.emit();
|
|
609
|
+
}
|
|
607
610
|
this._active = value;
|
|
608
611
|
if (!value) {
|
|
609
612
|
this.activeItem = undefined;
|
|
@@ -617,23 +620,19 @@ class MenuColumnsComponent {
|
|
|
617
620
|
this.menuSharedConfig = menuSharedConfig;
|
|
618
621
|
this.menuItemsService = menuItemsService;
|
|
619
622
|
this.direction = MenuLayoutDirection.column;
|
|
620
|
-
this.
|
|
623
|
+
this.isOpen = true;
|
|
621
624
|
this.toggleCollapseEvent = new EventEmitter();
|
|
622
|
-
this.subscriptions = [];
|
|
623
625
|
}
|
|
624
626
|
ngOnInit() {
|
|
625
627
|
this.activeItem = this.active.root;
|
|
626
628
|
}
|
|
627
|
-
ngOnDestroy() {
|
|
628
|
-
this.subscriptions.forEach(sub => sub.unsubscribe());
|
|
629
|
-
}
|
|
630
629
|
elementExpanded(element) {
|
|
631
630
|
if (!this.active || !element) {
|
|
632
631
|
this.activeItem = undefined;
|
|
633
632
|
return;
|
|
634
633
|
}
|
|
635
634
|
// if menu is collapsed and chilren are expandable, we should open menu
|
|
636
|
-
if (element.showChildren && !this.
|
|
635
|
+
if (element.showChildren && !this.isOpen) {
|
|
637
636
|
this.toggleCollapseEvent.emit();
|
|
638
637
|
}
|
|
639
638
|
if (element.showChildren && element.expanded && element === this.active.root) {
|
|
@@ -643,16 +642,19 @@ class MenuColumnsComponent {
|
|
|
643
642
|
this.activeItem = this.active.root;
|
|
644
643
|
}
|
|
645
644
|
}
|
|
645
|
+
toggleOnMobileSelect() {
|
|
646
|
+
return this.isOpen && ResolutionHelper.isMobileRes() && (this.active && Object.values(this.active)?.length > 0);
|
|
647
|
+
}
|
|
646
648
|
static { this.ɵfac = function MenuColumnsComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || MenuColumnsComponent)(i0.ɵɵdirectiveInject(i1$1.Router), i0.ɵɵdirectiveInject(MENU_SHARED_CONFIG, 8), i0.ɵɵdirectiveInject(MenuItemsService)); }; }
|
|
647
|
-
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: MenuColumnsComponent, selectors: [["menu-columns"]], inputs: { direction: "direction",
|
|
649
|
+
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: MenuColumnsComponent, selectors: [["menu-columns"]], inputs: { direction: "direction", isOpen: "isOpen", active: "active" }, outputs: { toggleCollapseEvent: "toggleCollapseEvent" }, decls: 1, vars: 1, consts: [[4, "ngFor", "ngForOf"], [3, "activeItem", "direction", "labelsVisible", "menuItemGroup", "items", "toggleExpand", 4, "ngIf"], ["class", "divider", 4, "ngIf"], [3, "toggleExpand", "activeItem", "direction", "labelsVisible", "menuItemGroup", "items"], [1, "divider"]], template: function MenuColumnsComponent_Template(rf, ctx) { if (rf & 1) {
|
|
648
650
|
i0.ɵɵtemplate(0, MenuColumnsComponent_ng_container_0_Template, 3, 2, "ng-container", 0);
|
|
649
651
|
} if (rf & 2) {
|
|
650
652
|
i0.ɵɵproperty("ngForOf", ctx.mergedGroups);
|
|
651
|
-
} }, dependencies: [i3.NgForOf, i3.NgIf, i4.MatDivider, MenuItemListComponent], styles: ["[_nghost-%COMP%]{display:inline-block}[_nghost-%COMP%] menu-item-list[_ngcontent-%COMP%]{display:block}.divider[_ngcontent-%COMP%]{margin:10px 0}"] }); }
|
|
653
|
+
} }, dependencies: [i3.NgForOf, i3.NgIf, i4$1.MatDivider, MenuItemListComponent], styles: ["[_nghost-%COMP%]{display:inline-block}[_nghost-%COMP%] menu-item-list[_ngcontent-%COMP%]{display:block}.divider[_ngcontent-%COMP%]{margin:10px 0}"] }); }
|
|
652
654
|
}
|
|
653
655
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(MenuColumnsComponent, [{
|
|
654
656
|
type: Component,
|
|
655
|
-
args: [{ selector: 'menu-columns', template: "<ng-container *ngFor=\"let group of mergedGroups\">\r\n <menu-item-list *ngIf=\"group.items.length\" [activeItem]=\"activeItem\" [direction]=\"direction\"\r\n (toggleExpand)=\"elementExpanded($event)\" [labelsVisible]=\"
|
|
657
|
+
args: [{ selector: 'menu-columns', template: "<ng-container *ngFor=\"let group of mergedGroups\">\r\n <menu-item-list *ngIf=\"group.items.length\" [activeItem]=\"activeItem\" [direction]=\"direction\"\r\n (toggleExpand)=\"elementExpanded($event)\" [labelsVisible]=\"isOpen\" [menuItemGroup]=\"group\"\r\n [items]=\"group.items\">\r\n </menu-item-list>\r\n <div class=\"divider\" *ngIf=\"group.bottomDivider && group.items.length\">\r\n <mat-divider></mat-divider>\r\n </div>\r\n</ng-container>", styles: [":host{display:inline-block}:host menu-item-list{display:block}.divider{margin:10px 0}\n"] }]
|
|
656
658
|
}], () => [{ type: i1$1.Router }, { type: undefined, decorators: [{
|
|
657
659
|
type: Optional
|
|
658
660
|
}, {
|
|
@@ -660,7 +662,7 @@ class MenuColumnsComponent {
|
|
|
660
662
|
args: [MENU_SHARED_CONFIG]
|
|
661
663
|
}] }, { type: MenuItemsService }], { direction: [{
|
|
662
664
|
type: Input
|
|
663
|
-
}],
|
|
665
|
+
}], isOpen: [{
|
|
664
666
|
type: Input
|
|
665
667
|
}], toggleCollapseEvent: [{
|
|
666
668
|
type: Output
|
|
@@ -670,161 +672,208 @@ class MenuColumnsComponent {
|
|
|
670
672
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(MenuColumnsComponent, { className: "MenuColumnsComponent", filePath: "lib\\components\\menu-columns\\menu-columns.component.ts", lineNumber: 16 }); })();
|
|
671
673
|
|
|
672
674
|
const _forTrack0 = ($index, $item) => $item.label;
|
|
673
|
-
const _c0
|
|
674
|
-
function
|
|
675
|
+
const _c0 = (a0, a1, a2, a3) => ({ icon: a0, isIconCustom: a1, isIconOutlined: a2, label: a3 });
|
|
676
|
+
function SideNavMenuComponent_div_0_Template(rf, ctx) { if (rf & 1) {
|
|
675
677
|
const _r2 = i0.ɵɵgetCurrentView();
|
|
676
|
-
i0.ɵɵelementStart(0, "a",
|
|
678
|
+
i0.ɵɵelementStart(0, "div", 14)(1, "a", 15);
|
|
679
|
+
i0.ɵɵpipe(2, "translate");
|
|
680
|
+
i0.ɵɵlistener("click", function SideNavMenuComponent_div_0_Template_a_click_1_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.logoClick($event)); });
|
|
681
|
+
i0.ɵɵelement(3, "img", 16);
|
|
682
|
+
i0.ɵɵelementStart(4, "span", 17);
|
|
683
|
+
i0.ɵɵtext(5);
|
|
684
|
+
i0.ɵɵelementEnd()();
|
|
685
|
+
i0.ɵɵelementStart(6, "button", 9);
|
|
686
|
+
i0.ɵɵpipe(7, "translate");
|
|
687
|
+
i0.ɵɵlistener("click", function SideNavMenuComponent_div_0_Template_button_click_6_listener() { i0.ɵɵrestoreView(_r2); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.toggleCollapse()); });
|
|
688
|
+
i0.ɵɵelementStart(8, "mat-icon");
|
|
689
|
+
i0.ɵɵtext(9, "menu");
|
|
690
|
+
i0.ɵɵelementEnd()()();
|
|
691
|
+
} if (rf & 2) {
|
|
692
|
+
const ctx_r2 = i0.ɵɵnextContext();
|
|
693
|
+
i0.ɵɵproperty("fxHide", !ctx_r2.collapsed);
|
|
694
|
+
i0.ɵɵadvance();
|
|
695
|
+
i0.ɵɵproperty("libPlausibleEvent", ctx_r2.LOGOCLICK_PLAUSIBLE_EVENT)("href", ctx_r2.baseUrl, i0.ɵɵsanitizeUrl);
|
|
696
|
+
i0.ɵɵattribute("aria-label", i0.ɵɵpipeBind1(2, 8, "MENU.ARIA_LABELS.LOGO"));
|
|
697
|
+
i0.ɵɵadvance(2);
|
|
698
|
+
i0.ɵɵproperty("src", ctx_r2.menuLogoImage, i0.ɵɵsanitizeUrl);
|
|
699
|
+
i0.ɵɵadvance(2);
|
|
700
|
+
i0.ɵɵtextInterpolate1(" ", ctx_r2.productName, " ");
|
|
701
|
+
i0.ɵɵadvance();
|
|
702
|
+
i0.ɵɵproperty("libPlausibleEvent", ctx_r2.collapsed ? ctx_r2.EXPAND_PLAUSIBLE_EVENT : ctx_r2.COLLAPSE_PLAUSIBLE_EVENT);
|
|
703
|
+
i0.ɵɵattribute("aria-label", i0.ɵɵpipeBind1(7, 10, "ARIA_LABELS.MENU_TOGGLER"));
|
|
704
|
+
} }
|
|
705
|
+
function SideNavMenuComponent_a_4_Template(rf, ctx) { if (rf & 1) {
|
|
706
|
+
const _r4 = i0.ɵɵgetCurrentView();
|
|
707
|
+
i0.ɵɵelementStart(0, "a", 15);
|
|
677
708
|
i0.ɵɵpipe(1, "translate");
|
|
678
|
-
i0.ɵɵlistener("click", function
|
|
679
|
-
i0.ɵɵelement(2, "img",
|
|
680
|
-
i0.ɵɵ
|
|
709
|
+
i0.ɵɵlistener("click", function SideNavMenuComponent_a_4_Template_a_click_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.logoClick($event)); });
|
|
710
|
+
i0.ɵɵelement(2, "img", 16);
|
|
711
|
+
i0.ɵɵelementStart(3, "span", 17);
|
|
712
|
+
i0.ɵɵtext(4);
|
|
713
|
+
i0.ɵɵelementEnd()();
|
|
681
714
|
} if (rf & 2) {
|
|
682
715
|
const ctx_r2 = i0.ɵɵnextContext();
|
|
683
716
|
i0.ɵɵproperty("libPlausibleEvent", ctx_r2.LOGOCLICK_PLAUSIBLE_EVENT)("href", ctx_r2.baseUrl, i0.ɵɵsanitizeUrl);
|
|
684
|
-
i0.ɵɵattribute("aria-label", i0.ɵɵpipeBind1(1,
|
|
717
|
+
i0.ɵɵattribute("aria-label", i0.ɵɵpipeBind1(1, 5, "MENU.ARIA_LABELS.LOGO"));
|
|
685
718
|
i0.ɵɵadvance(2);
|
|
686
719
|
i0.ɵɵproperty("src", ctx_r2.menuLogoImage, i0.ɵɵsanitizeUrl);
|
|
720
|
+
i0.ɵɵadvance(2);
|
|
721
|
+
i0.ɵɵtextInterpolate1(" ", ctx_r2.productName, " ");
|
|
722
|
+
} }
|
|
723
|
+
function SideNavMenuComponent_Conditional_7_Template(rf, ctx) { if (rf & 1) {
|
|
724
|
+
i0.ɵɵelementStart(0, "mat-icon");
|
|
725
|
+
i0.ɵɵtext(1, "close");
|
|
726
|
+
i0.ɵɵelementEnd();
|
|
687
727
|
} }
|
|
688
|
-
function
|
|
689
|
-
i0.ɵɵelementStart(0, "mat-icon"
|
|
728
|
+
function SideNavMenuComponent_Conditional_8_Template(rf, ctx) { if (rf & 1) {
|
|
729
|
+
i0.ɵɵelementStart(0, "mat-icon");
|
|
730
|
+
i0.ɵɵtext(1);
|
|
731
|
+
i0.ɵɵelementEnd();
|
|
732
|
+
} if (rf & 2) {
|
|
733
|
+
const ctx_r2 = i0.ɵɵnextContext();
|
|
734
|
+
i0.ɵɵadvance();
|
|
735
|
+
i0.ɵɵtextInterpolate(ctx_r2.collapsed ? "keyboard_double_arrow_right" : "keyboard_double_arrow_left");
|
|
736
|
+
} }
|
|
737
|
+
function SideNavMenuComponent_button_11_ng_container_4_mat_icon_3_Template(rf, ctx) { if (rf & 1) {
|
|
738
|
+
i0.ɵɵelementStart(0, "mat-icon", 23);
|
|
690
739
|
i0.ɵɵtext(1);
|
|
691
740
|
i0.ɵɵelementEnd();
|
|
692
741
|
} if (rf & 2) {
|
|
693
742
|
i0.ɵɵadvance();
|
|
694
743
|
i0.ɵɵtextInterpolate("keyboard_arrow_down");
|
|
695
744
|
} }
|
|
696
|
-
function
|
|
697
|
-
i0.ɵɵelementStart(0, "mat-icon",
|
|
745
|
+
function SideNavMenuComponent_button_11_ng_container_4_ng_template_4_Template(rf, ctx) { if (rf & 1) {
|
|
746
|
+
i0.ɵɵelementStart(0, "mat-icon", 23);
|
|
698
747
|
i0.ɵɵtext(1);
|
|
699
748
|
i0.ɵɵelementEnd();
|
|
700
749
|
} if (rf & 2) {
|
|
701
750
|
i0.ɵɵadvance();
|
|
702
751
|
i0.ɵɵtextInterpolate("keyboard_arrow_up");
|
|
703
752
|
} }
|
|
704
|
-
function
|
|
753
|
+
function SideNavMenuComponent_button_11_ng_container_4_Template(rf, ctx) { if (rf & 1) {
|
|
705
754
|
i0.ɵɵelementContainerStart(0);
|
|
706
|
-
i0.ɵɵelementStart(1, "span",
|
|
755
|
+
i0.ɵɵelementStart(1, "span", 21);
|
|
707
756
|
i0.ɵɵtext(2);
|
|
708
757
|
i0.ɵɵelementEnd();
|
|
709
|
-
i0.ɵɵtemplate(3,
|
|
758
|
+
i0.ɵɵtemplate(3, SideNavMenuComponent_button_11_ng_container_4_mat_icon_3_Template, 2, 1, "mat-icon", 22)(4, SideNavMenuComponent_button_11_ng_container_4_ng_template_4_Template, 2, 1, "ng-template", null, 3, i0.ɵɵtemplateRefExtractor);
|
|
710
759
|
i0.ɵɵelementContainerEnd();
|
|
711
760
|
} if (rf & 2) {
|
|
712
|
-
const
|
|
761
|
+
const iconDown_r5 = i0.ɵɵreference(5);
|
|
713
762
|
i0.ɵɵnextContext();
|
|
714
|
-
const
|
|
763
|
+
const state_r6 = i0.ɵɵreference(1);
|
|
715
764
|
const ctx_r2 = i0.ɵɵnextContext();
|
|
716
765
|
i0.ɵɵadvance(2);
|
|
717
766
|
i0.ɵɵtextInterpolate1(" ", ctx_r2.username, " ");
|
|
718
767
|
i0.ɵɵadvance();
|
|
719
|
-
i0.ɵɵproperty("ngIf",
|
|
768
|
+
i0.ɵɵproperty("ngIf", state_r6.menuOpen)("ngIfElse", iconDown_r5);
|
|
720
769
|
} }
|
|
721
|
-
function
|
|
722
|
-
i0.ɵɵelementStart(0, "button",
|
|
770
|
+
function SideNavMenuComponent_button_11_Template(rf, ctx) { if (rf & 1) {
|
|
771
|
+
i0.ɵɵelementStart(0, "button", 18, 2)(2, "div", 19);
|
|
723
772
|
i0.ɵɵtext(3);
|
|
724
773
|
i0.ɵɵelementEnd();
|
|
725
|
-
i0.ɵɵtemplate(4,
|
|
774
|
+
i0.ɵɵtemplate(4, SideNavMenuComponent_button_11_ng_container_4_Template, 6, 3, "ng-container", 20);
|
|
726
775
|
i0.ɵɵelementEnd();
|
|
727
776
|
} if (rf & 2) {
|
|
728
777
|
const ctx_r2 = i0.ɵɵnextContext();
|
|
729
|
-
const
|
|
730
|
-
i0.ɵɵproperty("matMenuTriggerFor",
|
|
778
|
+
const menu_r7 = i0.ɵɵreference(13);
|
|
779
|
+
i0.ɵɵproperty("matMenuTriggerFor", menu_r7);
|
|
731
780
|
i0.ɵɵadvance(3);
|
|
732
781
|
i0.ɵɵtextInterpolate1(" ", ctx_r2.userInitials, " ");
|
|
733
782
|
i0.ɵɵadvance();
|
|
734
783
|
i0.ɵɵproperty("ngIf", !ctx_r2.collapsed);
|
|
735
784
|
} }
|
|
736
|
-
function
|
|
785
|
+
function SideNavMenuComponent_For_15_Conditional_0_Conditional_0_ng_container_1_Template(rf, ctx) { if (rf & 1) {
|
|
737
786
|
i0.ɵɵelementContainer(0);
|
|
738
787
|
} }
|
|
739
|
-
function
|
|
740
|
-
i0.ɵɵelementStart(0, "a",
|
|
741
|
-
i0.ɵɵtemplate(1,
|
|
788
|
+
function SideNavMenuComponent_For_15_Conditional_0_Conditional_0_Template(rf, ctx) { if (rf & 1) {
|
|
789
|
+
i0.ɵɵelementStart(0, "a", 25);
|
|
790
|
+
i0.ɵɵtemplate(1, SideNavMenuComponent_For_15_Conditional_0_Conditional_0_ng_container_1_Template, 1, 0, "ng-container", 27);
|
|
742
791
|
i0.ɵɵelementEnd();
|
|
743
792
|
} if (rf & 2) {
|
|
744
|
-
const
|
|
793
|
+
const item_r8 = i0.ɵɵnextContext(2).$implicit;
|
|
745
794
|
i0.ɵɵnextContext();
|
|
746
|
-
const
|
|
747
|
-
i0.ɵɵproperty("href",
|
|
795
|
+
const profileMenuItem_r9 = i0.ɵɵreference(17);
|
|
796
|
+
i0.ɵɵproperty("href", item_r8.href, i0.ɵɵsanitizeUrl);
|
|
748
797
|
i0.ɵɵadvance();
|
|
749
|
-
i0.ɵɵproperty("ngTemplateOutlet",
|
|
798
|
+
i0.ɵɵproperty("ngTemplateOutlet", profileMenuItem_r9)("ngTemplateOutletContext", i0.ɵɵpureFunction4(3, _c0, item_r8.icon, item_r8.isIconCustom, item_r8.isIconOutlined, item_r8.label));
|
|
750
799
|
} }
|
|
751
|
-
function
|
|
800
|
+
function SideNavMenuComponent_For_15_Conditional_0_Conditional_1_ng_container_1_Template(rf, ctx) { if (rf & 1) {
|
|
752
801
|
i0.ɵɵelementContainer(0);
|
|
753
802
|
} }
|
|
754
|
-
function
|
|
755
|
-
i0.ɵɵelementStart(0, "a",
|
|
756
|
-
i0.ɵɵtemplate(1,
|
|
803
|
+
function SideNavMenuComponent_For_15_Conditional_0_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
804
|
+
i0.ɵɵelementStart(0, "a", 26);
|
|
805
|
+
i0.ɵɵtemplate(1, SideNavMenuComponent_For_15_Conditional_0_Conditional_1_ng_container_1_Template, 1, 0, "ng-container", 27);
|
|
757
806
|
i0.ɵɵelementEnd();
|
|
758
807
|
} if (rf & 2) {
|
|
759
|
-
const
|
|
808
|
+
const item_r8 = i0.ɵɵnextContext(2).$implicit;
|
|
760
809
|
i0.ɵɵnextContext();
|
|
761
|
-
const
|
|
762
|
-
i0.ɵɵproperty("routerLink",
|
|
810
|
+
const profileMenuItem_r9 = i0.ɵɵreference(17);
|
|
811
|
+
i0.ɵɵproperty("routerLink", item_r8.href);
|
|
763
812
|
i0.ɵɵadvance();
|
|
764
|
-
i0.ɵɵproperty("ngTemplateOutlet",
|
|
813
|
+
i0.ɵɵproperty("ngTemplateOutlet", profileMenuItem_r9)("ngTemplateOutletContext", i0.ɵɵpureFunction4(3, _c0, item_r8.icon, item_r8.isIconCustom, item_r8.isIconOutlined, item_r8.label));
|
|
765
814
|
} }
|
|
766
|
-
function
|
|
767
|
-
i0.ɵɵtemplate(0,
|
|
815
|
+
function SideNavMenuComponent_For_15_Conditional_0_Template(rf, ctx) { if (rf & 1) {
|
|
816
|
+
i0.ɵɵtemplate(0, SideNavMenuComponent_For_15_Conditional_0_Conditional_0_Template, 2, 8, "a", 25)(1, SideNavMenuComponent_For_15_Conditional_0_Conditional_1_Template, 2, 8, "a", 26);
|
|
768
817
|
} if (rf & 2) {
|
|
769
|
-
const
|
|
770
|
-
i0.ɵɵconditional(
|
|
818
|
+
const item_r8 = i0.ɵɵnextContext().$implicit;
|
|
819
|
+
i0.ɵɵconditional(item_r8.openInNewTab ? 0 : 1);
|
|
771
820
|
} }
|
|
772
|
-
function
|
|
821
|
+
function SideNavMenuComponent_For_15_Conditional_1_ng_container_1_Template(rf, ctx) { if (rf & 1) {
|
|
773
822
|
i0.ɵɵelementContainer(0);
|
|
774
823
|
} }
|
|
775
|
-
function
|
|
776
|
-
const
|
|
777
|
-
i0.ɵɵelementStart(0, "button",
|
|
778
|
-
i0.ɵɵlistener("click", function
|
|
779
|
-
i0.ɵɵtemplate(1,
|
|
824
|
+
function SideNavMenuComponent_For_15_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
825
|
+
const _r10 = i0.ɵɵgetCurrentView();
|
|
826
|
+
i0.ɵɵelementStart(0, "button", 28);
|
|
827
|
+
i0.ɵɵlistener("click", function SideNavMenuComponent_For_15_Conditional_1_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r10); const item_r8 = i0.ɵɵnextContext().$implicit; return i0.ɵɵresetView(item_r8 == null ? null : item_r8.callback()); });
|
|
828
|
+
i0.ɵɵtemplate(1, SideNavMenuComponent_For_15_Conditional_1_ng_container_1_Template, 1, 0, "ng-container", 27);
|
|
780
829
|
i0.ɵɵelementEnd();
|
|
781
830
|
} if (rf & 2) {
|
|
782
|
-
const
|
|
831
|
+
const item_r8 = i0.ɵɵnextContext().$implicit;
|
|
783
832
|
i0.ɵɵnextContext();
|
|
784
|
-
const
|
|
833
|
+
const profileMenuItem_r9 = i0.ɵɵreference(17);
|
|
785
834
|
i0.ɵɵadvance();
|
|
786
|
-
i0.ɵɵproperty("ngTemplateOutlet",
|
|
835
|
+
i0.ɵɵproperty("ngTemplateOutlet", profileMenuItem_r9)("ngTemplateOutletContext", i0.ɵɵpureFunction4(2, _c0, item_r8.icon, item_r8.isIconCustom, item_r8.isIconOutlined, item_r8.label));
|
|
787
836
|
} }
|
|
788
|
-
function
|
|
789
|
-
i0.ɵɵtemplate(0,
|
|
837
|
+
function SideNavMenuComponent_For_15_Template(rf, ctx) { if (rf & 1) {
|
|
838
|
+
i0.ɵɵtemplate(0, SideNavMenuComponent_For_15_Conditional_0_Template, 2, 1)(1, SideNavMenuComponent_For_15_Conditional_1_Template, 2, 7, "button", 24);
|
|
790
839
|
} if (rf & 2) {
|
|
791
|
-
const
|
|
792
|
-
i0.ɵɵconditional(
|
|
840
|
+
const item_r8 = ctx.$implicit;
|
|
841
|
+
i0.ɵɵconditional(item_r8.isLink ? 0 : 1);
|
|
793
842
|
} }
|
|
794
|
-
function
|
|
795
|
-
i0.ɵɵelementStart(0, "span",
|
|
843
|
+
function SideNavMenuComponent_ng_template_16_Conditional_0_Conditional_0_Template(rf, ctx) { if (rf & 1) {
|
|
844
|
+
i0.ɵɵelementStart(0, "span", 31);
|
|
796
845
|
i0.ɵɵtext(1);
|
|
797
846
|
i0.ɵɵelementEnd();
|
|
798
847
|
} if (rf & 2) {
|
|
799
|
-
const
|
|
800
|
-
const
|
|
801
|
-
const
|
|
802
|
-
i0.ɵɵclassProp("material-icons-outlined",
|
|
848
|
+
const ctx_r10 = i0.ɵɵnextContext(2);
|
|
849
|
+
const icon_r12 = ctx_r10.icon;
|
|
850
|
+
const isIconOutlined_r13 = ctx_r10.isIconOutlined;
|
|
851
|
+
i0.ɵɵclassProp("material-icons-outlined", isIconOutlined_r13);
|
|
803
852
|
i0.ɵɵadvance();
|
|
804
|
-
i0.ɵɵtextInterpolate1(" ",
|
|
853
|
+
i0.ɵɵtextInterpolate1(" ", icon_r12, " ");
|
|
805
854
|
} }
|
|
806
|
-
function
|
|
807
|
-
i0.ɵɵelement(0, "mat-icon",
|
|
855
|
+
function SideNavMenuComponent_ng_template_16_Conditional_0_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
856
|
+
i0.ɵɵelement(0, "mat-icon", 30);
|
|
808
857
|
} if (rf & 2) {
|
|
809
|
-
const
|
|
810
|
-
i0.ɵɵproperty("svgIcon",
|
|
858
|
+
const icon_r12 = i0.ɵɵnextContext(2).icon;
|
|
859
|
+
i0.ɵɵproperty("svgIcon", icon_r12);
|
|
811
860
|
} }
|
|
812
|
-
function
|
|
813
|
-
i0.ɵɵtemplate(0,
|
|
861
|
+
function SideNavMenuComponent_ng_template_16_Conditional_0_Template(rf, ctx) { if (rf & 1) {
|
|
862
|
+
i0.ɵɵtemplate(0, SideNavMenuComponent_ng_template_16_Conditional_0_Conditional_0_Template, 2, 3, "span", 29)(1, SideNavMenuComponent_ng_template_16_Conditional_0_Conditional_1_Template, 1, 1, "mat-icon", 30);
|
|
814
863
|
} if (rf & 2) {
|
|
815
|
-
const
|
|
816
|
-
i0.ɵɵconditional(!
|
|
864
|
+
const isIconCustom_r14 = i0.ɵɵnextContext().isIconCustom;
|
|
865
|
+
i0.ɵɵconditional(!isIconCustom_r14 ? 0 : 1);
|
|
817
866
|
} }
|
|
818
|
-
function
|
|
819
|
-
i0.ɵɵtemplate(0,
|
|
867
|
+
function SideNavMenuComponent_ng_template_16_Template(rf, ctx) { if (rf & 1) {
|
|
868
|
+
i0.ɵɵtemplate(0, SideNavMenuComponent_ng_template_16_Conditional_0_Template, 2, 1);
|
|
820
869
|
i0.ɵɵtext(1);
|
|
821
870
|
i0.ɵɵpipe(2, "translate");
|
|
822
871
|
} if (rf & 2) {
|
|
823
|
-
const
|
|
824
|
-
const
|
|
825
|
-
i0.ɵɵconditional(
|
|
872
|
+
const icon_r12 = ctx.icon;
|
|
873
|
+
const label_r15 = ctx.label;
|
|
874
|
+
i0.ɵɵconditional(icon_r12 ? 0 : -1);
|
|
826
875
|
i0.ɵɵadvance();
|
|
827
|
-
i0.ɵɵtextInterpolate1(" ", i0.ɵɵpipeBind1(2, 2,
|
|
876
|
+
i0.ɵɵtextInterpolate1(" ", i0.ɵɵpipeBind1(2, 2, label_r15), "\n");
|
|
828
877
|
} }
|
|
829
878
|
class SideNavMenuComponent extends NavBaseComponent {
|
|
830
879
|
#username;
|
|
@@ -854,6 +903,7 @@ class SideNavMenuComponent extends NavBaseComponent {
|
|
|
854
903
|
disableStrapi: false
|
|
855
904
|
};
|
|
856
905
|
this.collapsed = false;
|
|
906
|
+
this.isMobile = ResolutionHelper.isMobileRes();
|
|
857
907
|
this.COLLAPSED_LOCAL_STORAGE_KEY = "TLD_MENU_SIDE_NAV_COLLAPSED";
|
|
858
908
|
//#region Plausible event variables for collapse button
|
|
859
909
|
this.COLLAPSE_PLAUSIBLE_EVENT_ID = "collapseMenu";
|
|
@@ -889,7 +939,7 @@ class SideNavMenuComponent extends NavBaseComponent {
|
|
|
889
939
|
if (!this.domService.localStorage) {
|
|
890
940
|
return;
|
|
891
941
|
}
|
|
892
|
-
this.collapsed = this.domService.localStorage.getItem(this.COLLAPSED_LOCAL_STORAGE_KEY) == 'true' ? true : false;
|
|
942
|
+
this.collapsed = (this.domService.localStorage.getItem(this.COLLAPSED_LOCAL_STORAGE_KEY) == 'true' || this.isMobile) ? true : false;
|
|
893
943
|
}
|
|
894
944
|
setColapsedFromLocalStorage() {
|
|
895
945
|
if (!this.domService.localStorage) {
|
|
@@ -912,48 +962,51 @@ class SideNavMenuComponent extends NavBaseComponent {
|
|
|
912
962
|
this.userInitials = splittedUsername[0][0] + splittedUsername[1][0];
|
|
913
963
|
}
|
|
914
964
|
static { this.ɵfac = function SideNavMenuComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || SideNavMenuComponent)(i0.ɵɵdirectiveInject(i1.StrapiLinkService), i0.ɵɵdirectiveInject(i2.DOMService), i0.ɵɵdirectiveInject(MenuItemsService), i0.ɵɵdirectiveInject(MENU_SHARED_CONFIG, 8)); }; }
|
|
915
|
-
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SideNavMenuComponent, selectors: [["lib-side-nav-menu"]], inputs: { username: "username", menuSettings: "menuSettings" }, features: [i0.ɵɵInheritDefinitionFeature], decls:
|
|
965
|
+
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SideNavMenuComponent, selectors: [["lib-side-nav-menu"]], inputs: { username: "username", menuSettings: "menuSettings", productName: "productName" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 18, vars: 17, consts: [["menu", "matMenu"], ["profileMenuItem", ""], ["state", "matMenuTrigger"], ["iconDown", ""], ["class", "mobile-header", 3, "fxHide", 4, "ngIf"], ["fxLayout", "column", 1, "menu-container", 3, "ngClass.lt-sm"], ["fxLayout", "column", "fxFlexFill", "", 1, "content"], ["fxLayout", "row", 1, "menu-container-header", 3, "fxLayoutAlign"], ["fxFlex", "3.125em", "fxLayoutAlign", "start center", 3, "libPlausibleEvent", "href", "click", 4, "ngIf"], ["mat-icon-button", "", 1, "toggler", 3, "click", "libPlausibleEvent"], ["fxLayout", "column", "fxFlex", "", 1, "menu-wrapper"], ["role", "navigation", "fxFlex", "", 3, "toggleCollapseEvent", "direction", "isOpen", "active"], ["class", "profile-wrapper", 3, "matMenuTriggerFor", 4, "ngIf"], [1, "profile-menu"], [1, "mobile-header", 3, "fxHide"], ["fxFlex", "3.125em", "fxLayoutAlign", "start center", 3, "click", "libPlausibleEvent", "href"], ["height", "40", "width", "40", "alt", "logo", 1, "menu-logo", 3, "src"], [1, "menu-product-name"], [1, "profile-wrapper", 3, "matMenuTriggerFor"], [1, "profile-icon"], [4, "ngIf"], [1, "profile-name"], ["class", "spin", 4, "ngIf", "ngIfElse"], [1, "spin"], ["mat-menu-item", "", 1, "profile-option"], ["target", "_blank", 1, "mat-mdc-menu-item", 3, "href"], [1, "mat-mdc-menu-item", 3, "routerLink"], [4, "ngTemplateOutlet", "ngTemplateOutletContext"], ["mat-menu-item", "", 1, "profile-option", 3, "click"], [1, "material-icons", "profile-option-icon", 3, "material-icons-outlined"], [1, "profile-option-icon", 3, "svgIcon"], [1, "material-icons", "profile-option-icon"]], template: function SideNavMenuComponent_Template(rf, ctx) { if (rf & 1) {
|
|
916
966
|
const _r1 = i0.ɵɵgetCurrentView();
|
|
917
|
-
i0.ɵɵ
|
|
918
|
-
i0.ɵɵ
|
|
919
|
-
i0.ɵɵ
|
|
920
|
-
i0.ɵɵ
|
|
921
|
-
i0.ɵɵ
|
|
922
|
-
i0.ɵɵ
|
|
923
|
-
i0.ɵɵ
|
|
924
|
-
i0.ɵɵelementEnd()()
|
|
925
|
-
i0.ɵɵelementStart(
|
|
926
|
-
i0.ɵɵlistener("toggleCollapseEvent", function
|
|
967
|
+
i0.ɵɵtemplate(0, SideNavMenuComponent_div_0_Template, 10, 12, "div", 4);
|
|
968
|
+
i0.ɵɵelementStart(1, "div", 5)(2, "div", 6)(3, "div", 7);
|
|
969
|
+
i0.ɵɵtemplate(4, SideNavMenuComponent_a_4_Template, 5, 7, "a", 8);
|
|
970
|
+
i0.ɵɵelementStart(5, "button", 9);
|
|
971
|
+
i0.ɵɵpipe(6, "translate");
|
|
972
|
+
i0.ɵɵlistener("click", function SideNavMenuComponent_Template_button_click_5_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.toggleCollapse()); });
|
|
973
|
+
i0.ɵɵtemplate(7, SideNavMenuComponent_Conditional_7_Template, 2, 0, "mat-icon")(8, SideNavMenuComponent_Conditional_8_Template, 2, 1, "mat-icon");
|
|
974
|
+
i0.ɵɵelementEnd()();
|
|
975
|
+
i0.ɵɵelementStart(9, "div", 10)(10, "menu-columns", 11);
|
|
976
|
+
i0.ɵɵlistener("toggleCollapseEvent", function SideNavMenuComponent_Template_menu_columns_toggleCollapseEvent_10_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.toggleCollapse()); });
|
|
927
977
|
i0.ɵɵelementEnd()();
|
|
928
|
-
i0.ɵɵtemplate(
|
|
929
|
-
i0.ɵɵelementStart(
|
|
930
|
-
i0.ɵɵrepeaterCreate(
|
|
978
|
+
i0.ɵɵtemplate(11, SideNavMenuComponent_button_11_Template, 5, 3, "button", 12);
|
|
979
|
+
i0.ɵɵelementStart(12, "mat-menu", 13, 0);
|
|
980
|
+
i0.ɵɵrepeaterCreate(14, SideNavMenuComponent_For_15_Template, 2, 1, null, null, _forTrack0);
|
|
931
981
|
i0.ɵɵelementEnd()();
|
|
932
|
-
i0.ɵɵtemplate(
|
|
982
|
+
i0.ɵɵtemplate(16, SideNavMenuComponent_ng_template_16_Template, 3, 4, "ng-template", null, 1, i0.ɵɵtemplateRefExtractor);
|
|
933
983
|
i0.ɵɵelementEnd();
|
|
934
984
|
} if (rf & 2) {
|
|
985
|
+
i0.ɵɵproperty("ngIf", ctx.isMobile);
|
|
986
|
+
i0.ɵɵadvance();
|
|
935
987
|
i0.ɵɵstyleProp("width", ctx.sideNavWidth);
|
|
936
988
|
i0.ɵɵclassProp("collapsed", ctx.collapsed);
|
|
989
|
+
i0.ɵɵproperty("ngClass.lt-sm", "mobile");
|
|
937
990
|
i0.ɵɵadvance(2);
|
|
938
991
|
i0.ɵɵproperty("fxLayoutAlign", ctx.collapsed ? "center center" : "space-between center");
|
|
939
992
|
i0.ɵɵadvance();
|
|
940
993
|
i0.ɵɵproperty("ngIf", !ctx.collapsed);
|
|
941
994
|
i0.ɵɵadvance();
|
|
942
995
|
i0.ɵɵproperty("libPlausibleEvent", ctx.collapsed ? ctx.EXPAND_PLAUSIBLE_EVENT : ctx.COLLAPSE_PLAUSIBLE_EVENT);
|
|
943
|
-
i0.ɵɵattribute("aria-label", i0.ɵɵpipeBind1(
|
|
944
|
-
i0.ɵɵadvance(3);
|
|
945
|
-
i0.ɵɵtextInterpolate(ctx.collapsed ? "keyboard_double_arrow_right" : "keyboard_double_arrow_left");
|
|
996
|
+
i0.ɵɵattribute("aria-label", i0.ɵɵpipeBind1(6, 15, "ARIA_LABELS.MENU_TOGGLER"));
|
|
946
997
|
i0.ɵɵadvance(2);
|
|
947
|
-
i0.ɵɵ
|
|
998
|
+
i0.ɵɵconditional(ctx.isMobile ? 7 : 8);
|
|
999
|
+
i0.ɵɵadvance(3);
|
|
1000
|
+
i0.ɵɵproperty("direction", ctx.direction)("isOpen", !ctx.collapsed)("active", ctx.active);
|
|
948
1001
|
i0.ɵɵadvance();
|
|
949
1002
|
i0.ɵɵproperty("ngIf", ctx.userInitials);
|
|
950
1003
|
i0.ɵɵadvance(3);
|
|
951
1004
|
i0.ɵɵrepeater(ctx.menuSettings.userOptions);
|
|
952
|
-
} }, dependencies: [
|
|
1005
|
+
} }, dependencies: [i4.DefaultLayoutDirective, i4.DefaultLayoutAlignDirective, i4.FlexFillDirective, i4.DefaultFlexDirective, i5.DefaultShowHideDirective, i5.DefaultClassDirective, i1$1.RouterLink, i3.NgIf, i3.NgTemplateOutlet, i2$1.MatIcon, i9.MatIconButton, i10.MatMenu, i10.MatMenuItem, i10.MatMenuTrigger, i2.PlausibleEventDirective, MenuColumnsComponent, i8.TranslatePipe], styles: ["a[_ngcontent-%COMP%]{text-decoration:none}.mobile-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:23px 27px;background-color:#fcfcfc;border:1px solid var(--base-70)}.mobile.menu-container.collapsed[_ngcontent-%COMP%]{display:none!important}.mobile.menu-container[_ngcontent-%COMP%]:not(.collapsed){display:block!important;position:absolute;min-width:100vw;min-height:100vh;z-index:1000}.mobile[_ngcontent-%COMP%] .profile-wrapper[_ngcontent-%COMP%]{position:relative}.mobile[_ngcontent-%COMP%] .profile-wrapper[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{position:absolute!important;right:0}.menu-product-name[_ngcontent-%COMP%]{white-space:nowrap;margin-left:12px;font-weight:600;color:var(--primary-accent-darker)}.menu-container[_ngcontent-%COMP%]{max-height:100vh;white-space:nowrap;height:100%;transition:width .2s ease;min-height:100vh;overflow:auto;background:var(--base-100);border-right:2px solid var(--base-95)}.menu-container[_ngcontent-%COMP%] .menu-container-header[_ngcontent-%COMP%]{margin:24px 0;max-height:40px}.menu-container.collapsed[_ngcontent-%COMP%] .menu-container-header[_ngcontent-%COMP%]{margin:24px 0 32px!important}.menu-container[_ngcontent-%COMP%] .content[_ngcontent-%COMP%]:not(.collapsed){overflow-x:hidden;padding:0 12px}.menu-container[_ngcontent-%COMP%] .content[_ngcontent-%COMP%]:not(.collapsed) .menu-logo[_ngcontent-%COMP%]{margin-left:16px;max-width:100%}.menu-container[_ngcontent-%COMP%] .divider[_ngcontent-%COMP%]{width:100%}.menu-container[_ngcontent-%COMP%] .profile-wrapper[_ngcontent-%COMP%]{background:none;color:var(--base-30);display:flex;align-items:center;justify-content:start;margin:32px 16px}.menu-container[_ngcontent-%COMP%] .profile-icon[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center;min-width:40px;height:40px;border-radius:100%;color:var(--base-0);background-color:var(--base-70);font-size:16px;font-weight:600}.menu-container[_ngcontent-%COMP%] .profile-name[_ngcontent-%COMP%]{max-width:145px;overflow:hidden;margin-left:12px}.profile-option-icon[_ngcontent-%COMP%]{vertical-align:middle;margin:0 5px 5px 0}[_nghost-%COMP%] .collapsed .profile-wrapper{left:8px!important}[_nghost-%COMP%] .menu-item{display:flex;padding:16px!important;border-radius:4px!important}[_nghost-%COMP%] .child-list .menu-item{padding:8px 46px!important}[_nghost-%COMP%] .collapsed .menu-item{padding:0!important;width:40px;height:40px;border-radius:50%!important}[_nghost-%COMP%] .active-menu-item{background-color:var(--base-95)!important}[_nghost-%COMP%] .menu-item-title{margin-left:12px}tld-menu-icon[_ngcontent-%COMP%]{margin-right:10px}.spin[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_spinArrow .3s forwards}[_nghost-%COMP%] button.collapse-btn .mat-mdc-button-persistent-ripple, [_nghost-%COMP%] button.toggler .mat-mdc-button-persistent-ripple{display:none}[_nghost-%COMP%] .mobile .child-list .menu-item{padding:8px 54px!important} .cdk-overlay-container .profile-menu{margin:10px 0!important} .mat-mdc-menu-item .mat-icon{margin-right:5px!important} .collapsed .profile-wrapper{justify-content:center!important} .profile-menu a{font-weight:400!important;display:flex;align-items:center;gap:5px} .profile-menu a:hover{color:var(--mat-menu-item-label-text-color, var(--mat-app-on-surface))!important;text-decoration:inherit}@keyframes _ngcontent-%COMP%_spinArrow{to{transform:rotate(180deg)}}"] }); }
|
|
953
1006
|
}
|
|
954
1007
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SideNavMenuComponent, [{
|
|
955
1008
|
type: Component,
|
|
956
|
-
args: [{ selector: 'lib-side-nav-menu', template: "<div class=\"menu-container\" [style.width]=\"sideNavWidth\" fxLayout=\"column\" [class.collapsed]=\"collapsed\">\r\n <div class=\"content\" fxLayout=\"column\" fxFlexFill>\r\n <div class=\"menu-container-header\" fxLayout=\"row\" [fxLayoutAlign]=\"collapsed ? 'center center' : 'space-between center'\">\r\n <a *ngIf=\"!collapsed\" [libPlausibleEvent]=\"LOGOCLICK_PLAUSIBLE_EVENT\" fxFlex=\"3.125em\" [href]=\"baseUrl\"\r\n [attr.aria-label]=\"'MENU.ARIA_LABELS.LOGO' | translate\" (click)=\"logoClick($event)\" fxLayoutAlign=\"start center\"\r\n >\r\n <img height=\"40\" class=\"menu-logo\" [src]=\"menuLogoImage\" alt=\"logo\" />\r\n </a>\r\n \r\n <button\r\n mat-icon-button\r\n class=\"toggler\"\r\n [attr.aria-label]=\"'ARIA_LABELS.MENU_TOGGLER' | translate\"\r\n [libPlausibleEvent]=\"collapsed ? EXPAND_PLAUSIBLE_EVENT : COLLAPSE_PLAUSIBLE_EVENT\"\r\n (click)=\"toggleCollapse()\"\r\n >\r\n <mat-icon>{{ collapsed ? 'keyboard_double_arrow_right' : 'keyboard_double_arrow_left' }}</mat-icon>\r\n </button>\r\n </div>\r\n \r\n <div class=\"menu-wrapper\" fxLayout=\"column\" fxFlex>\r\n <menu-columns (toggleCollapseEvent)=\"toggleCollapse()\" [direction]=\"direction\" role=\"navigation\" fxFlex [
|
|
1009
|
+
args: [{ selector: 'lib-side-nav-menu', template: "<div *ngIf=\"isMobile\" [fxHide]=\"!collapsed\" class=\"mobile-header\">\r\n <a [libPlausibleEvent]=\"LOGOCLICK_PLAUSIBLE_EVENT\" fxFlex=\"3.125em\" [href]=\"baseUrl\"\r\n [attr.aria-label]=\"'MENU.ARIA_LABELS.LOGO' | translate\" (click)=\"logoClick($event)\" fxLayoutAlign=\"start center\"\r\n >\r\n <img height=\"40\" width=\"40\" class=\"menu-logo\" [src]=\"menuLogoImage\" alt=\"logo\" />\r\n <span class=\"menu-product-name\">\r\n {{ productName }}\r\n </span>\r\n </a>\r\n \r\n <button\r\n mat-icon-button\r\n class=\"toggler\"\r\n [attr.aria-label]=\"'ARIA_LABELS.MENU_TOGGLER' | translate\"\r\n [libPlausibleEvent]=\"collapsed ? EXPAND_PLAUSIBLE_EVENT : COLLAPSE_PLAUSIBLE_EVENT\"\r\n (click)=\"toggleCollapse()\"\r\n >\r\n <mat-icon>menu</mat-icon>\r\n </button>\r\n</div>\r\n\r\n<div [ngClass.lt-sm]=\"'mobile'\" class=\"menu-container\" [style.width]=\"sideNavWidth\" fxLayout=\"column\" [class.collapsed]=\"collapsed\">\r\n <div class=\"content\" fxLayout=\"column\" fxFlexFill>\r\n <div class=\"menu-container-header\" fxLayout=\"row\" [fxLayoutAlign]=\"collapsed ? 'center center' : 'space-between center'\">\r\n <a *ngIf=\"!collapsed\" [libPlausibleEvent]=\"LOGOCLICK_PLAUSIBLE_EVENT\" fxFlex=\"3.125em\" [href]=\"baseUrl\"\r\n [attr.aria-label]=\"'MENU.ARIA_LABELS.LOGO' | translate\" (click)=\"logoClick($event)\" fxLayoutAlign=\"start center\"\r\n >\r\n <img height=\"40\" width=\"40\" class=\"menu-logo\" [src]=\"menuLogoImage\" alt=\"logo\" />\r\n <span class=\"menu-product-name\">\r\n {{ productName }}\r\n </span>\r\n </a>\r\n \r\n <button\r\n mat-icon-button\r\n class=\"toggler\"\r\n [attr.aria-label]=\"'ARIA_LABELS.MENU_TOGGLER' | translate\"\r\n [libPlausibleEvent]=\"collapsed ? EXPAND_PLAUSIBLE_EVENT : COLLAPSE_PLAUSIBLE_EVENT\"\r\n (click)=\"toggleCollapse()\"\r\n >\r\n @if (isMobile) {\r\n <mat-icon>close</mat-icon>\r\n } @else {\r\n <mat-icon>{{ collapsed ? 'keyboard_double_arrow_right' : 'keyboard_double_arrow_left' }}</mat-icon>\r\n }\r\n </button>\r\n </div>\r\n \r\n <div class=\"menu-wrapper\" fxLayout=\"column\" fxFlex>\r\n <menu-columns (toggleCollapseEvent)=\"toggleCollapse()\" [direction]=\"direction\" role=\"navigation\" fxFlex [isOpen]=\"!collapsed\"\r\n [active]=\"active\"></menu-columns>\r\n </div>\r\n\r\n\r\n <button *ngIf=\"userInitials\" #state=\"matMenuTrigger\" [matMenuTriggerFor]=\"menu\" class=\"profile-wrapper\">\r\n <div class=\"profile-icon\">\r\n {{userInitials}}\r\n </div>\r\n\r\n <ng-container *ngIf=\"!collapsed\">\r\n <span class=\"profile-name\">\r\n {{ username }}\r\n </span>\r\n \r\n <mat-icon *ngIf=\"state.menuOpen; else iconDown\" class=\"spin\">{{\"keyboard_arrow_down\"}}</mat-icon>\r\n\r\n <ng-template #iconDown>\r\n <mat-icon class=\"spin\">{{\"keyboard_arrow_up\" }}</mat-icon>\r\n </ng-template>\r\n </ng-container>\r\n </button>\r\n\r\n <mat-menu #menu=\"matMenu\" class=\"profile-menu\">\r\n @for (item of menuSettings.userOptions; track item.label) {\r\n @if (item.isLink) {\r\n @if (item.openInNewTab) {\r\n <a class=\"mat-mdc-menu-item\" [href]=\"item.href\" target=\"_blank\">\r\n <ng-container\r\n *ngTemplateOutlet=\"profileMenuItem; context: { icon: item.icon, isIconCustom: item.isIconCustom, isIconOutlined: item.isIconOutlined, label: item.label }\">\r\n </ng-container>\r\n </a>\r\n } @else {\r\n <a class=\"mat-mdc-menu-item\" [routerLink]=\"item.href\">\r\n <ng-container\r\n *ngTemplateOutlet=\"profileMenuItem; context: { icon: item.icon, isIconCustom: item.isIconCustom, isIconOutlined: item.isIconOutlined, label: item.label }\">\r\n </ng-container>\r\n </a>\r\n }\r\n } @else {\r\n <button\r\n mat-menu-item\r\n class=\"profile-option\"\r\n (click)=\"item?.callback()\"\r\n >\r\n <ng-container\r\n *ngTemplateOutlet=\"profileMenuItem; context: { icon: item.icon, isIconCustom: item.isIconCustom, isIconOutlined: item.isIconOutlined, label: item.label }\">\r\n </ng-container>\r\n </button>\r\n }\r\n }\r\n </mat-menu>\r\n </div>\r\n\r\n<ng-template #profileMenuItem let-icon=\"icon\" let-isIconCustom=\"isIconCustom\" let-isIconOutlined=\"isIconOutlined\" let-label=\"label\">\r\n @if (icon) {\r\n @if (!isIconCustom) {\r\n <span class=\"material-icons profile-option-icon\" [class.material-icons-outlined]=\"isIconOutlined\">\r\n {{icon}}\r\n </span>\r\n } @else {\r\n <mat-icon class=\"profile-option-icon\" [svgIcon]=\"icon\"></mat-icon>\r\n }\r\n }\r\n {{ label | translate }}\r\n</ng-template>", styles: ["a{text-decoration:none}.mobile-header{display:flex;justify-content:space-between;padding:23px 27px;background-color:#fcfcfc;border:1px solid var(--base-70)}.mobile.menu-container.collapsed{display:none!important}.mobile.menu-container:not(.collapsed){display:block!important;position:absolute;min-width:100vw;min-height:100vh;z-index:1000}.mobile .profile-wrapper{position:relative}.mobile .profile-wrapper mat-icon{position:absolute!important;right:0}.menu-product-name{white-space:nowrap;margin-left:12px;font-weight:600;color:var(--primary-accent-darker)}.menu-container{max-height:100vh;white-space:nowrap;height:100%;transition:width .2s ease;min-height:100vh;overflow:auto;background:var(--base-100);border-right:2px solid var(--base-95)}.menu-container .menu-container-header{margin:24px 0;max-height:40px}.menu-container.collapsed .menu-container-header{margin:24px 0 32px!important}.menu-container .content:not(.collapsed){overflow-x:hidden;padding:0 12px}.menu-container .content:not(.collapsed) .menu-logo{margin-left:16px;max-width:100%}.menu-container .divider{width:100%}.menu-container .profile-wrapper{background:none;color:var(--base-30);display:flex;align-items:center;justify-content:start;margin:32px 16px}.menu-container .profile-icon{display:flex;justify-content:center;align-items:center;min-width:40px;height:40px;border-radius:100%;color:var(--base-0);background-color:var(--base-70);font-size:16px;font-weight:600}.menu-container .profile-name{max-width:145px;overflow:hidden;margin-left:12px}.profile-option-icon{vertical-align:middle;margin:0 5px 5px 0}:host ::ng-deep .collapsed .profile-wrapper{left:8px!important}:host ::ng-deep .menu-item{display:flex;padding:16px!important;border-radius:4px!important}:host ::ng-deep .child-list .menu-item{padding:8px 46px!important}:host ::ng-deep .collapsed .menu-item{padding:0!important;width:40px;height:40px;border-radius:50%!important}:host ::ng-deep .active-menu-item{background-color:var(--base-95)!important}:host ::ng-deep .menu-item-title{margin-left:12px}tld-menu-icon{margin-right:10px}.spin{animation:spinArrow .3s forwards}:host::ng-deep button.collapse-btn .mat-mdc-button-persistent-ripple,:host::ng-deep button.toggler .mat-mdc-button-persistent-ripple{display:none}:host ::ng-deep .mobile .child-list .menu-item{padding:8px 54px!important}::ng-deep .cdk-overlay-container .profile-menu{margin:10px 0!important}::ng-deep .mat-mdc-menu-item .mat-icon{margin-right:5px!important}::ng-deep .collapsed .profile-wrapper{justify-content:center!important}::ng-deep .profile-menu a{font-weight:400!important;display:flex;align-items:center;gap:5px}::ng-deep .profile-menu a:hover{color:var(--mat-menu-item-label-text-color, var(--mat-app-on-surface))!important;text-decoration:inherit}@keyframes spinArrow{to{transform:rotate(180deg)}}\n"] }]
|
|
957
1010
|
}], () => [{ type: i1.StrapiLinkService }, { type: i2.DOMService }, { type: MenuItemsService }, { type: undefined, decorators: [{
|
|
958
1011
|
type: Optional
|
|
959
1012
|
}, {
|
|
@@ -963,196 +1016,10 @@ class SideNavMenuComponent extends NavBaseComponent {
|
|
|
963
1016
|
type: Input
|
|
964
1017
|
}], menuSettings: [{
|
|
965
1018
|
type: Input
|
|
966
|
-
}]
|
|
967
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(SideNavMenuComponent, { className: "SideNavMenuComponent", filePath: "lib\\components\\side-nav-menu\\side-nav-menu.component.ts", lineNumber: 16 }); })();
|
|
968
|
-
|
|
969
|
-
const _c0$1 = [[["", "top", ""]], [["", "bottom", ""]]];
|
|
970
|
-
const _c1$1 = ["[top]", "[bottom]"];
|
|
971
|
-
function ModalNavMenuComponent_img_3_Template(rf, ctx) { if (rf & 1) {
|
|
972
|
-
i0.ɵɵelement(0, "img", 7);
|
|
973
|
-
} if (rf & 2) {
|
|
974
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
975
|
-
i0.ɵɵproperty("src", ctx_r0.menuDialogSettings.logo, i0.ɵɵsanitizeUrl);
|
|
976
|
-
} }
|
|
977
|
-
function ModalNavMenuComponent_span_4_Template(rf, ctx) { if (rf & 1) {
|
|
978
|
-
i0.ɵɵelementStart(0, "span", 8);
|
|
979
|
-
i0.ɵɵtext(1);
|
|
980
|
-
i0.ɵɵpipe(2, "translate");
|
|
981
|
-
i0.ɵɵelementEnd();
|
|
982
|
-
} if (rf & 2) {
|
|
983
|
-
i0.ɵɵadvance();
|
|
984
|
-
i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(2, 1, "MENU.MENU"));
|
|
985
|
-
} }
|
|
986
|
-
function ModalNavMenuComponent_span_5_Template(rf, ctx) { if (rf & 1) {
|
|
987
|
-
const _r2 = i0.ɵɵgetCurrentView();
|
|
988
|
-
i0.ɵɵelementStart(0, "span", 9);
|
|
989
|
-
i0.ɵɵlistener("click", function ModalNavMenuComponent_span_5_Template_span_click_0_listener() { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.close()); });
|
|
990
|
-
i0.ɵɵelementStart(1, "mat-icon");
|
|
991
|
-
i0.ɵɵtext(2, "close");
|
|
992
|
-
i0.ɵɵelementEnd()();
|
|
993
|
-
} }
|
|
994
|
-
class ModalNavMenuComponent extends NavBaseComponent {
|
|
995
|
-
constructor(menuItems) {
|
|
996
|
-
super(menuItems);
|
|
997
|
-
this.menuItems = menuItems;
|
|
998
|
-
this.menuDialogSettings = {
|
|
999
|
-
showMenuTitle: false,
|
|
1000
|
-
fullScreen: true
|
|
1001
|
-
};
|
|
1002
|
-
// any type because emitter doesn't really need a value
|
|
1003
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
1004
|
-
this.closeButtonClick = new EventEmitter();
|
|
1005
|
-
}
|
|
1006
|
-
close() {
|
|
1007
|
-
this.closeButtonClick.emit(null);
|
|
1008
|
-
}
|
|
1009
|
-
static { this.ɵfac = function ModalNavMenuComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || ModalNavMenuComponent)(i0.ɵɵdirectiveInject(MenuItemsService)); }; }
|
|
1010
|
-
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ModalNavMenuComponent, selectors: [["lib-modal-nav-menu"]], inputs: { menuDialogSettings: "menuDialogSettings" }, outputs: { closeButtonClick: "closeButtonClick" }, features: [i0.ɵɵInheritDefinitionFeature], ngContentSelectors: _c1$1, decls: 9, vars: 7, consts: [["fxLayout", "row", "fxFlexFill", "", 1, "content", "menu-modal"], ["fxLayout", "column"], ["fxLayout", "row", 1, "menu-header"], ["width", "75", "alt", "", 3, "src", 4, "ngIf"], ["fxLayoutAlign", "start center", "fxFlex", "", 4, "ngIf"], ["class", "close-icon", "fxFlex", "", "fxLayoutAlign", "end center", 3, "click", 4, "ngIf"], [3, "direction", "active"], ["width", "75", "alt", "", 3, "src"], ["fxLayoutAlign", "start center", "fxFlex", ""], ["fxFlex", "", "fxLayoutAlign", "end center", 1, "close-icon", 3, "click"]], template: function ModalNavMenuComponent_Template(rf, ctx) { if (rf & 1) {
|
|
1011
|
-
i0.ɵɵprojectionDef(_c0$1);
|
|
1012
|
-
i0.ɵɵelementStart(0, "div", 0)(1, "div", 1)(2, "div", 2);
|
|
1013
|
-
i0.ɵɵtemplate(3, ModalNavMenuComponent_img_3_Template, 1, 1, "img", 3)(4, ModalNavMenuComponent_span_4_Template, 3, 3, "span", 4)(5, ModalNavMenuComponent_span_5_Template, 3, 0, "span", 5);
|
|
1014
|
-
i0.ɵɵelementEnd();
|
|
1015
|
-
i0.ɵɵprojection(6);
|
|
1016
|
-
i0.ɵɵelement(7, "menu-columns", 6);
|
|
1017
|
-
i0.ɵɵprojection(8, 1);
|
|
1018
|
-
i0.ɵɵelementEnd()();
|
|
1019
|
-
} if (rf & 2) {
|
|
1020
|
-
i0.ɵɵadvance();
|
|
1021
|
-
i0.ɵɵclassProp("full-screen", ctx.menuDialogSettings.fullScreen);
|
|
1022
|
-
i0.ɵɵadvance(2);
|
|
1023
|
-
i0.ɵɵproperty("ngIf", ctx.menuDialogSettings.logo);
|
|
1024
|
-
i0.ɵɵadvance();
|
|
1025
|
-
i0.ɵɵproperty("ngIf", ctx.menuDialogSettings.showMenuTitle);
|
|
1026
|
-
i0.ɵɵadvance();
|
|
1027
|
-
i0.ɵɵproperty("ngIf", ctx.menuDialogSettings.showCloseMenuButton);
|
|
1028
|
-
i0.ɵɵadvance(2);
|
|
1029
|
-
i0.ɵɵproperty("direction", ctx.direction)("active", ctx.active);
|
|
1030
|
-
} }, dependencies: [i2$2.DefaultLayoutDirective, i2$2.DefaultLayoutAlignDirective, i2$2.FlexFillDirective, i2$2.DefaultFlexDirective, i3.NgIf, i2$1.MatIcon, MenuColumnsComponent, i8.TranslatePipe], styles: [".menu-modal[_ngcontent-%COMP%]{background-color:var(--base-100);padding:1.375rem 1.5rem}.close-icon[_ngcontent-%COMP%]{cursor:pointer}.menu-header[_ngcontent-%COMP%]{font-style:normal;font-weight:500;font-size:1.3125rem;line-height:1.75rem;text-align:center;margin:1em 0;color:var(--menu-dark-color)}.close-icon[_ngcontent-%COMP%] > mat-icon[_ngcontent-%COMP%]{transform:scale(1.5)}"] }); }
|
|
1031
|
-
}
|
|
1032
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ModalNavMenuComponent, [{
|
|
1033
|
-
type: Component,
|
|
1034
|
-
args: [{ selector: 'lib-modal-nav-menu', template: "<div class=\"content menu-modal\" fxLayout=\"row\" fxFlexFill>\r\n <div fxLayout=\"column\" [class.full-screen]=\"menuDialogSettings.fullScreen\">\r\n <div fxLayout=\"row\" class=\"menu-header\">\r\n <img [src]=\"menuDialogSettings.logo\" *ngIf=\"menuDialogSettings.logo\" width=\"75\" alt=\"\">\r\n <span *ngIf=\"menuDialogSettings.showMenuTitle\" fxLayoutAlign=\"start center\" fxFlex>{{\r\n \"MENU.MENU\" | translate\r\n }}</span>\r\n <span *ngIf=\"menuDialogSettings.showCloseMenuButton\" (click)=\"close()\" class=\"close-icon\" fxFlex\r\n fxLayoutAlign=\"end center\">\r\n <mat-icon>close</mat-icon>\r\n </span>\r\n </div>\r\n <ng-content select=\"[top]\"></ng-content>\r\n <menu-columns [direction]=\"direction\" [active]=\"active\">\r\n </menu-columns>\r\n <ng-content select=\"[bottom]\"></ng-content>\r\n </div>\r\n</div>", styles: [".menu-modal{background-color:var(--base-100);padding:1.375rem 1.5rem}.close-icon{cursor:pointer}.menu-header{font-style:normal;font-weight:500;font-size:1.3125rem;line-height:1.75rem;text-align:center;margin:1em 0;color:var(--menu-dark-color)}.close-icon>mat-icon{transform:scale(1.5)}\n"] }]
|
|
1035
|
-
}], () => [{ type: MenuItemsService }], { menuDialogSettings: [{
|
|
1036
|
-
type: Input
|
|
1037
|
-
}], closeButtonClick: [{
|
|
1038
|
-
type: Output
|
|
1039
|
-
}] }); })();
|
|
1040
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ModalNavMenuComponent, { className: "ModalNavMenuComponent", filePath: "lib\\components\\modal-nav-menu\\modal-nav-menu.component.ts", lineNumber: 11 }); })();
|
|
1041
|
-
|
|
1042
|
-
const menuLogo = `
|
|
1043
|
-
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
1044
|
-
<path d="M3.3 6.6C2.36667 6.6 1.58333 6.28333 0.95 5.65C0.316666 5.01667 0 4.23333 0 3.3C0 2.36667 0.316666 1.58333 0.95 0.95C1.58333 0.316666 2.36667 0 3.3 0C4.23333 0 5.01667 0.316666 5.65 0.95C6.28333 1.58333 6.6 2.36667 6.6 3.3C6.6 4.23333 6.28333 5.01667 5.65 5.65C5.01667 6.28333 4.23333 6.6 3.3 6.6ZM16 32C15.0667 32 14.2833 31.6833 13.65 31.05C13.0167 30.4167 12.7 29.6333 12.7 28.7C12.7 27.7667 13.0167 26.9833 13.65 26.35C14.2833 25.7167 15.0667 25.4 16 25.4C16.9333 25.4 17.7167 25.7167 18.35 26.35C18.9833 26.9833 19.3 27.7667 19.3 28.7C19.3 29.6333 18.9833 30.4167 18.35 31.05C17.7167 31.6833 16.9333 32 16 32ZM3.3 32C2.36667 32 1.58333 31.6833 0.95 31.05C0.316666 30.4167 0 29.6333 0 28.7C0 27.7667 0.316666 26.9833 0.95 26.35C1.58333 25.7167 2.36667 25.4 3.3 25.4C4.23333 25.4 5.01667 25.7167 5.65 26.35C6.28333 26.9833 6.6 27.7667 6.6 28.7C6.6 29.6333 6.28333 30.4167 5.65 31.05C5.01667 31.6833 4.23333 32 3.3 32ZM3.3 19.3C2.36667 19.3 1.58333 18.9833 0.95 18.35C0.316666 17.7167 0 16.9333 0 16C0 15.0667 0.316666 14.2833 0.95 13.65C1.58333 13.0167 2.36667 12.7 3.3 12.7C4.23333 12.7 5.01667 13.0167 5.65 13.65C6.28333 14.2833 6.6 15.0667 6.6 16C6.6 16.9333 6.28333 17.7167 5.65 18.35C5.01667 18.9833 4.23333 19.3 3.3 19.3ZM16 19.3C15.0667 19.3 14.2833 18.9833 13.65 18.35C13.0167 17.7167 12.7 16.9333 12.7 16C12.7 15.0667 13.0167 14.2833 13.65 13.65C14.2833 13.0167 15.0667 12.7 16 12.7C16.9333 12.7 17.7167 13.0167 18.35 13.65C18.9833 14.2833 19.3 15.0667 19.3 16C19.3 16.9333 18.9833 17.7167 18.35 18.35C17.7167 18.9833 16.9333 19.3 16 19.3ZM28.7 6.6C27.7667 6.6 26.9833 6.28333 26.35 5.65C25.7167 5.01667 25.4 4.23333 25.4 3.3C25.4 2.36667 25.7167 1.58333 26.35 0.95C26.9833 0.316666 27.7667 0 28.7 0C29.6333 0 30.4167 0.316666 31.05 0.95C31.6833 1.58333 32 2.36667 32 3.3C32 4.23333 31.6833 5.01667 31.05 5.65C30.4167 6.28333 29.6333 6.6 28.7 6.6ZM16 6.6C15.0667 6.6 14.2833 6.28333 13.65 5.65C13.0167 5.01667 12.7 4.23333 12.7 3.3C12.7 2.36667 13.0167 1.58333 13.65 0.95C14.2833 0.316666 15.0667 0 16 0C16.9333 0 17.7167 0.316666 18.35 0.95C18.9833 1.58333 19.3 2.36667 19.3 3.3C19.3 4.23333 18.9833 5.01667 18.35 5.65C17.7167 6.28333 16.9333 6.6 16 6.6ZM28.7 19.3C27.7667 19.3 26.9833 18.9833 26.35 18.35C25.7167 17.7167 25.4 16.9333 25.4 16C25.4 15.0667 25.7167 14.2833 26.35 13.65C26.9833 13.0167 27.7667 12.7 28.7 12.7C29.6333 12.7 30.4167 13.0167 31.05 13.65C31.6833 14.2833 32 15.0667 32 16C32 16.9333 31.6833 17.7167 31.05 18.35C30.4167 18.9833 29.6333 19.3 28.7 19.3ZM28.7 32C27.7667 32 26.9833 31.6833 26.35 31.05C25.7167 30.4167 25.4 29.6333 25.4 28.7C25.4 27.7667 25.7167 26.9833 26.35 26.35C26.9833 25.7167 27.7667 25.4 28.7 25.4C29.6333 25.4 30.4167 25.7167 31.05 26.35C31.6833 26.9833 32 27.7667 32 28.7C32 29.6333 31.6833 30.4167 31.05 31.05C30.4167 31.6833 29.6333 32 28.7 32Z" fill="#434C56"/>
|
|
1045
|
-
</svg>
|
|
1046
|
-
|
|
1047
|
-
`;
|
|
1048
|
-
|
|
1049
|
-
var TitlePlacement;
|
|
1050
|
-
(function (TitlePlacement) {
|
|
1051
|
-
TitlePlacement["none"] = "none";
|
|
1052
|
-
TitlePlacement["left"] = "left";
|
|
1053
|
-
TitlePlacement["right"] = "right";
|
|
1054
|
-
})(TitlePlacement || (TitlePlacement = {}));
|
|
1055
|
-
|
|
1056
|
-
const _c0 = ["menuTrigger"];
|
|
1057
|
-
const _c1 = [[["", "top", ""]], [["", "bottom", ""]]];
|
|
1058
|
-
const _c2 = ["[top]", "[bottom]"];
|
|
1059
|
-
function MenuItemIconComponent_span_3_Template(rf, ctx) { if (rf & 1) {
|
|
1060
|
-
i0.ɵɵelementStart(0, "span", 8);
|
|
1061
|
-
i0.ɵɵtext(1);
|
|
1062
|
-
i0.ɵɵpipe(2, "translate");
|
|
1063
|
-
i0.ɵɵelementEnd();
|
|
1064
|
-
} if (rf & 2) {
|
|
1065
|
-
const ctx_r1 = i0.ɵɵnextContext();
|
|
1066
|
-
i0.ɵɵproperty("fxFlexOrder", ctx_r1.menuSettings.titlePlacement === ctx_r1.TITLE_PLACEMENT_LEFT ? 1 : 2);
|
|
1067
|
-
i0.ɵɵadvance();
|
|
1068
|
-
i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(2, 2, "MENU.MENU"));
|
|
1069
|
-
} }
|
|
1070
|
-
class MenuItemIconComponent {
|
|
1071
|
-
constructor(iconService, router) {
|
|
1072
|
-
this.iconService = iconService;
|
|
1073
|
-
this.router = router;
|
|
1074
|
-
this.menuSettings = {
|
|
1075
|
-
titlePlacement: TitlePlacement.left
|
|
1076
|
-
};
|
|
1077
|
-
this.menuDialogSettings = {
|
|
1078
|
-
showMenuTitle: true,
|
|
1079
|
-
disableStrapi: true,
|
|
1080
|
-
fullScreen: true
|
|
1081
|
-
};
|
|
1082
|
-
this.direction = MenuLayoutDirection.row;
|
|
1083
|
-
this.subscription = [];
|
|
1084
|
-
this.iconName = 'tld-menu-icon';
|
|
1085
|
-
this.TITLE_PLACEMENT_NONE = TitlePlacement.none;
|
|
1086
|
-
this.TITLE_PLACEMENT_LEFT = TitlePlacement.left;
|
|
1087
|
-
this.PLAUSIBLE_EVENT = {
|
|
1088
|
-
eventId: "burger_click"
|
|
1089
|
-
};
|
|
1090
|
-
}
|
|
1091
|
-
ngOnInit() {
|
|
1092
|
-
const routeChangeSub = this.router.events.subscribe(() => this.closeMenu());
|
|
1093
|
-
this.subscription.push(routeChangeSub);
|
|
1094
|
-
this.registerIcon();
|
|
1095
|
-
}
|
|
1096
|
-
closeMenu() {
|
|
1097
|
-
this.menuTrigger?.closeMenu();
|
|
1098
|
-
}
|
|
1099
|
-
ngOnDestroy() {
|
|
1100
|
-
this.subscription.forEach(e => e.unsubscribe());
|
|
1101
|
-
}
|
|
1102
|
-
registerIcon() {
|
|
1103
|
-
if (this.menuSettings.iconPath) {
|
|
1104
|
-
this.iconService.registerIconFromUrl(this.iconName, this.menuSettings.iconPath);
|
|
1105
|
-
}
|
|
1106
|
-
else {
|
|
1107
|
-
this.iconService.registerIcons({ [this.iconName]: menuLogo });
|
|
1108
|
-
}
|
|
1109
|
-
}
|
|
1110
|
-
static { this.ɵfac = function MenuItemIconComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || MenuItemIconComponent)(i0.ɵɵdirectiveInject(i2.IconService), i0.ɵɵdirectiveInject(i1$1.Router)); }; }
|
|
1111
|
-
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: MenuItemIconComponent, selectors: [["lib-menu-item-icon"]], viewQuery: function MenuItemIconComponent_Query(rf, ctx) { if (rf & 1) {
|
|
1112
|
-
i0.ɵɵviewQuery(_c0, 5);
|
|
1113
|
-
} if (rf & 2) {
|
|
1114
|
-
let _t;
|
|
1115
|
-
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.menuTrigger = _t.first);
|
|
1116
|
-
} }, inputs: { menuSettings: "menuSettings", menuDialogSettings: "menuDialogSettings", direction: "direction" }, ngContentSelectors: _c2, decls: 10, vars: 12, consts: [["menuTrigger", "matMenuTrigger"], ["menu", ""], ["mat-button", "", 1, "content", "text-l", 3, "disableRipple", "matMenuTriggerFor", "libPlausibleEvent"], ["fxLayout", "row", "fxLayoutGap", "1.5em", "fxLayoutAlign", "center center"], ["class", "menu-label", 3, "fxFlexOrder", 4, "ngIf"], [3, "fxFlexOrder", "svgIcon"], [3, "hasBackdrop"], [3, "click", "closeButtonClick", "menuDialogSettings", "direction"], [1, "menu-label", 3, "fxFlexOrder"]], template: function MenuItemIconComponent_Template(rf, ctx) { if (rf & 1) {
|
|
1117
|
-
const _r1 = i0.ɵɵgetCurrentView();
|
|
1118
|
-
i0.ɵɵprojectionDef(_c1);
|
|
1119
|
-
i0.ɵɵelementStart(0, "button", 2, 0)(2, "span", 3);
|
|
1120
|
-
i0.ɵɵtemplate(3, MenuItemIconComponent_span_3_Template, 3, 4, "span", 4);
|
|
1121
|
-
i0.ɵɵelement(4, "mat-icon", 5);
|
|
1122
|
-
i0.ɵɵelementEnd()();
|
|
1123
|
-
i0.ɵɵelementStart(5, "mat-menu", 6, 1)(7, "lib-modal-nav-menu", 7);
|
|
1124
|
-
i0.ɵɵlistener("click", function MenuItemIconComponent_Template_lib_modal_nav_menu_click_7_listener($event) { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView($event.stopPropagation()); })("closeButtonClick", function MenuItemIconComponent_Template_lib_modal_nav_menu_closeButtonClick_7_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.closeMenu()); });
|
|
1125
|
-
i0.ɵɵprojection(8, 0, ["top", ""]);
|
|
1126
|
-
i0.ɵɵprojection(9, 1, ["bottom", ""]);
|
|
1127
|
-
i0.ɵɵelementEnd()();
|
|
1128
|
-
} if (rf & 2) {
|
|
1129
|
-
const menu_r3 = i0.ɵɵreference(6);
|
|
1130
|
-
i0.ɵɵproperty("disableRipple", true)("matMenuTriggerFor", menu_r3)("libPlausibleEvent", ctx.PLAUSIBLE_EVENT);
|
|
1131
|
-
i0.ɵɵadvance(3);
|
|
1132
|
-
i0.ɵɵproperty("ngIf", ctx.menuSettings.titlePlacement !== ctx.TITLE_PLACEMENT_NONE);
|
|
1133
|
-
i0.ɵɵadvance();
|
|
1134
|
-
i0.ɵɵproperty("fxFlexOrder", ctx.menuSettings.titlePlacement === ctx.TITLE_PLACEMENT_LEFT ? 2 : 1)("svgIcon", ctx.iconName);
|
|
1135
|
-
i0.ɵɵadvance();
|
|
1136
|
-
i0.ɵɵclassMapInterpolate1("mobile-menu-dialog ", ctx.menuDialogSettings.fullScreen ? "full-screen" : "minimized-screen", "");
|
|
1137
|
-
i0.ɵɵproperty("hasBackdrop", true);
|
|
1138
|
-
i0.ɵɵadvance(2);
|
|
1139
|
-
i0.ɵɵproperty("menuDialogSettings", ctx.menuDialogSettings)("direction", ctx.direction);
|
|
1140
|
-
} }, dependencies: [i2$2.DefaultLayoutDirective, i2$2.DefaultLayoutGapDirective, i2$2.DefaultLayoutAlignDirective, i2$2.DefaultFlexOrderDirective, i3.NgIf, i2$1.MatIcon, i8$1.MatButton, i9.MatMenu, i9.MatMenuTrigger, i2.PlausibleEventDirective, ModalNavMenuComponent, i8.TranslatePipe], styles: [".content[_ngcontent-%COMP%]{gap:1.5em;cursor:pointer}button.mat-mdc-icon-button[_ngcontent-%COMP%]{width:inherit} lib-modal-nav-menu>.content.menu-modal>div.full-screen{width:100%} lib-modal-nav-menu>.content.menu-modal>div.full-screen .menu-list-wrapper .menu-item{width:100%} div:has(.mat-mdc-menu-panel.mobile-menu-dialog.full-screen){width:100%;max-width:100%} .mat-mdc-menu-panel.mobile-menu-dialog.full-screen{width:100vw;margin-top:-2.5em;max-width:none}"] }); }
|
|
1141
|
-
}
|
|
1142
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(MenuItemIconComponent, [{
|
|
1143
|
-
type: Component,
|
|
1144
|
-
args: [{ selector: 'lib-menu-item-icon', template: "<button class=\"content text-l\" mat-button [disableRipple]=\"true\" #menuTrigger=\"matMenuTrigger\"\r\n [matMenuTriggerFor]=\"menu\" [libPlausibleEvent]=\"PLAUSIBLE_EVENT\">\r\n <span fxLayout=\"row\" fxLayoutGap=\"1.5em\" fxLayoutAlign=\"center center\">\r\n <span *ngIf=\"menuSettings.titlePlacement !== TITLE_PLACEMENT_NONE\" [fxFlexOrder]=\"\r\n menuSettings.titlePlacement === TITLE_PLACEMENT_LEFT ? 1 : 2\r\n \" class=\"menu-label\">{{ \"MENU.MENU\" | translate }}</span>\r\n <mat-icon [fxFlexOrder]=\"\r\n menuSettings.titlePlacement === TITLE_PLACEMENT_LEFT ? 2 : 1\r\n \" [svgIcon]=\"iconName\">\r\n </mat-icon>\r\n </span>\r\n</button>\r\n\r\n<mat-menu [hasBackdrop]=\"true\" #menu class=\"mobile-menu-dialog {{\r\n menuDialogSettings.fullScreen ? 'full-screen' : 'minimized-screen'\r\n }}\">\r\n <!-- Click method so that menu does not get closed when clicking outside of items-->\r\n <lib-modal-nav-menu (click)=\"$event.stopPropagation()\" (closeButtonClick)=\"closeMenu()\"\r\n [menuDialogSettings]=\"menuDialogSettings\" [direction]=\"direction\">\r\n <ng-content top select=\"[top]\"></ng-content>\r\n <ng-content bottom select=\"[bottom]\"></ng-content>\r\n </lib-modal-nav-menu>\r\n</mat-menu>", styles: [".content{gap:1.5em;cursor:pointer}button.mat-mdc-icon-button{width:inherit}::ng-deep lib-modal-nav-menu>.content.menu-modal>div.full-screen{width:100%}::ng-deep lib-modal-nav-menu>.content.menu-modal>div.full-screen .menu-list-wrapper .menu-item{width:100%}::ng-deep div:has(.mat-mdc-menu-panel.mobile-menu-dialog.full-screen){width:100%;max-width:100%}::ng-deep .mat-mdc-menu-panel.mobile-menu-dialog.full-screen{width:100vw;margin-top:-2.5em;max-width:none}\n"] }]
|
|
1145
|
-
}], () => [{ type: i2.IconService }, { type: i1$1.Router }], { menuTrigger: [{
|
|
1146
|
-
type: ViewChild,
|
|
1147
|
-
args: ['menuTrigger']
|
|
1148
|
-
}], menuSettings: [{
|
|
1149
|
-
type: Input
|
|
1150
|
-
}], menuDialogSettings: [{
|
|
1151
|
-
type: Input
|
|
1152
|
-
}], direction: [{
|
|
1019
|
+
}], productName: [{
|
|
1153
1020
|
type: Input
|
|
1154
1021
|
}] }); })();
|
|
1155
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(
|
|
1022
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(SideNavMenuComponent, { className: "SideNavMenuComponent", filePath: "lib\\components\\side-nav-menu\\side-nav-menu.component.ts", lineNumber: 16 }); })();
|
|
1156
1023
|
|
|
1157
1024
|
class MenuModule {
|
|
1158
1025
|
static forRoot(config) {
|
|
@@ -1181,8 +1048,6 @@ class MenuModule {
|
|
|
1181
1048
|
args: [{
|
|
1182
1049
|
declarations: [
|
|
1183
1050
|
SideNavMenuComponent,
|
|
1184
|
-
ModalNavMenuComponent,
|
|
1185
|
-
MenuItemIconComponent,
|
|
1186
1051
|
NavBaseComponent,
|
|
1187
1052
|
MenuItemListComponent,
|
|
1188
1053
|
MenuColumnsComponent,
|
|
@@ -1191,8 +1056,6 @@ class MenuModule {
|
|
|
1191
1056
|
],
|
|
1192
1057
|
exports: [
|
|
1193
1058
|
SideNavMenuComponent,
|
|
1194
|
-
ModalNavMenuComponent,
|
|
1195
|
-
MenuItemIconComponent,
|
|
1196
1059
|
MenuColumnsComponent,
|
|
1197
1060
|
],
|
|
1198
1061
|
imports: [
|
|
@@ -1213,8 +1076,6 @@ class MenuModule {
|
|
|
1213
1076
|
}]
|
|
1214
1077
|
}], null, null); })();
|
|
1215
1078
|
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(MenuModule, { declarations: [SideNavMenuComponent,
|
|
1216
|
-
ModalNavMenuComponent,
|
|
1217
|
-
MenuItemIconComponent,
|
|
1218
1079
|
NavBaseComponent,
|
|
1219
1080
|
MenuItemListComponent,
|
|
1220
1081
|
MenuColumnsComponent,
|
|
@@ -1231,8 +1092,6 @@ class MenuModule {
|
|
|
1231
1092
|
MatIconModule,
|
|
1232
1093
|
TranslateModule,
|
|
1233
1094
|
PlausibleModule], exports: [SideNavMenuComponent,
|
|
1234
|
-
ModalNavMenuComponent,
|
|
1235
|
-
MenuItemIconComponent,
|
|
1236
1095
|
MenuColumnsComponent] }); })();
|
|
1237
1096
|
|
|
1238
1097
|
/*
|
|
@@ -1243,5 +1102,5 @@ class MenuModule {
|
|
|
1243
1102
|
* Generated bundle index. Do not edit.
|
|
1244
1103
|
*/
|
|
1245
1104
|
|
|
1246
|
-
export { MENU_ICON_STRAPI_EXTENSION, MENU_SHARED_CONFIG, MenuColumnsComponent,
|
|
1105
|
+
export { MENU_ICON_STRAPI_EXTENSION, MENU_SHARED_CONFIG, MenuColumnsComponent, MenuItemsService, MenuLayoutDirection, MenuModule, NavBaseComponent, SideNavMenuComponent, StarpiMenuService, StrapiDataLocation };
|
|
1247
1106
|
//# sourceMappingURL=tilde-nlp-ngx-menu.mjs.map
|