]>
Commit | Line | Data |
---|---|---|
d363ef53 K |
1 | <div class="sub-menu" [ngClass]="{ 'no-scroll': isModalOpened }"> |
2 | <ng-container *ngFor="let menuEntry of menuEntries; index as id"> | |
ddb83e49 | 3 | |
482fa503 | 4 | <a *ngIf="menuEntry.routerLink" [routerLink]="menuEntry.routerLink" routerLinkActive="active" class="title-page title-page-settings">{{ menuEntry.label }}</a> |
ddb83e49 | 5 | |
3b072f5a | 6 | <div *ngIf="!menuEntry.routerLink" ngbDropdown class="parent-entry" |
d363ef53 | 7 | #dropdown="ngbDropdown" (mouseleave)="closeDropdownIfHovered(dropdown)"> |
80bfd33c | 8 | <span |
d363ef53 K |
9 | *ngIf="isInSmallView" |
10 | [ngClass]="{ active: !!suffixLabels[menuEntry.label] }" | |
11 | (click)="openModal(id)" role="button" class="title-page title-page-settings"> | |
12 | <ng-container i18n>{{ menuEntry.label }}</ng-container> | |
13 | <ng-container *ngIf="!!suffixLabels[menuEntry.label]"> - {{ suffixLabels[menuEntry.label] }}</ng-container> | |
14 | </span> | |
15 | ||
16 | <span | |
17 | *ngIf="!isInSmallView" | |
80bfd33c | 18 | (mouseenter)="openDropdownOnHover(dropdown)" [ngClass]="{ active: !!suffixLabels[menuEntry.label] }" ngbDropdownAnchor |
482fa503 | 19 | (click)="dropdownAnchorClicked(dropdown)" role="button" class="title-page title-page-settings" |
80bfd33c | 20 | > |
ddb83e49 C |
21 | <ng-container i18n>{{ menuEntry.label }}</ng-container> |
22 | <ng-container *ngIf="!!suffixLabels[menuEntry.label]"> - {{ suffixLabels[menuEntry.label] }}</ng-container> | |
23 | </span> | |
24 | ||
25 | <div ngbDropdownMenu> | |
a55052c9 C |
26 | <a *ngFor="let menuChild of menuEntry.children" class="dropdown-item" [ngClass]="{ icon: hasIcons }" [routerLink]="menuChild.routerLink"> |
27 | <my-global-icon *ngIf="menuChild.iconName" [iconName]="menuChild.iconName"></my-global-icon> | |
28 | ||
29 | {{ menuChild.label }} | |
30 | </a> | |
ddb83e49 C |
31 | </div> |
32 | </div> | |
ddb83e49 C |
33 | </ng-container> |
34 | </div> | |
d363ef53 K |
35 | |
36 | <ng-template #modal let-close="close" let-dismiss="dismiss"> | |
37 | <div class="modal-body"> | |
38 | <ng-container *ngFor="let menuEntry of menuEntries; index as id"> | |
39 | <div [ngClass]="{ hidden: id !== currentMenuEntryIndex }"> | |
40 | <a *ngFor="let menuChild of menuEntry.children" | |
41 | [ngClass]="{ icon: hasIcons }" | |
42 | [routerLink]="menuChild.routerLink" routerLinkActive="active" (click)="dismissOtherModals()"> | |
43 | <my-global-icon *ngIf="menuChild.iconName" [iconName]="menuChild.iconName"></my-global-icon> | |
44 | ||
45 | {{ menuChild.label }} | |
46 | </a> | |
47 | </div> | |
48 | </ng-container> | |
49 | </div> | |
50 | </ng-template> |