@rxap/layout 15.0.0 → 16.0.0-dev.0

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.
Files changed (92) hide show
  1. package/{esm2020 → esm2022}/lib/footer/footer.component.mjs +10 -9
  2. package/esm2022/lib/footer/footer.component.module.mjs +30 -0
  3. package/esm2022/lib/footer.directive.mjs +54 -0
  4. package/{esm2020 → esm2022}/lib/header/apps-button/apps-button.component.mjs +15 -14
  5. package/esm2022/lib/header/apps-button/apps-button.component.module.mjs +46 -0
  6. package/esm2022/lib/header/header.component.mjs +131 -0
  7. package/esm2022/lib/header/header.component.module.mjs +70 -0
  8. package/esm2022/lib/header/language-selector/language-selector.component.mjs +113 -0
  9. package/{esm2020 → esm2022}/lib/header/language-selector/language-selector.component.module.mjs +8 -7
  10. package/esm2022/lib/header/navigation-progress-bar/navigation-progress-bar.component.mjs +34 -0
  11. package/esm2022/lib/header/navigation-progress-bar/navigation-progress-bar.component.module.mjs +26 -0
  12. package/esm2022/lib/header/reset-button/reset-button.component.mjs +28 -0
  13. package/esm2022/lib/header/reset-button/reset-button.component.module.mjs +26 -0
  14. package/esm2022/lib/header/sidenav-toggle-button/sidenav-toggle-button.component.mjs +45 -0
  15. package/{esm2020 → esm2022}/lib/header/sidenav-toggle-button/sidenav-toggle-button.component.module.mjs +8 -7
  16. package/esm2022/lib/header/sign-out/sign-out.component.mjs +32 -0
  17. package/esm2022/lib/header/sign-out/sign-out.component.module.mjs +30 -0
  18. package/{esm2020 → esm2022}/lib/header/user-profile-icon/user-profile-icon.component.mjs +21 -20
  19. package/esm2022/lib/header/user-profile-icon/user-profile-icon.component.module.mjs +38 -0
  20. package/esm2022/lib/layout/layout.component.mjs +79 -0
  21. package/esm2022/lib/layout/layout.component.module.mjs +70 -0
  22. package/esm2022/lib/layout/layout.component.service.mjs +44 -0
  23. package/esm2022/lib/navigation/navigation-item/navigation-item.component.mjs +287 -0
  24. package/esm2022/lib/navigation/navigation.component.mjs +131 -0
  25. package/{esm2020 → esm2022}/lib/navigation/navigation.component.module.mjs +16 -15
  26. package/esm2022/lib/navigation/navigation.service.mjs +144 -0
  27. package/esm2022/lib/navigation/replace-router-paths.pipe.mjs +36 -0
  28. package/esm2022/lib/navigation/replace-router-paths.service.mjs +16 -0
  29. package/esm2022/lib/sidenav/sidenav-footer.directive.mjs +20 -0
  30. package/esm2022/lib/sidenav/sidenav-header.directive.mjs +20 -0
  31. package/esm2022/lib/sidenav/sidenav.component.mjs +121 -0
  32. package/esm2022/lib/sidenav/sidenav.component.module.mjs +44 -0
  33. package/esm2022/lib/sidenav/sidenav.component.service.mjs +23 -0
  34. package/esm2022/lib/sidenav/version/version.component.mjs +63 -0
  35. package/{esm2020 → esm2022}/lib/sidenav/version/version.component.module.mjs +7 -6
  36. package/esm2022/lib/sidenav-content/sidenav-content.component.mjs +46 -0
  37. package/{esm2020 → esm2022}/lib/sidenav-content/sidenav-content.component.module.mjs +7 -6
  38. package/esm2022/lib/sidenav-content/sidenav-content.component.service.mjs +37 -0
  39. package/esm2022/lib/toggle-window-sidenav-button/toggle-window-sidenav-button.component.mjs +51 -0
  40. package/{esm2020 → esm2022}/lib/toggle-window-sidenav-button/toggle-window-sidenav-button.component.module.mjs +8 -7
  41. package/esm2022/lib/window-container-sidenav/window-container-sidenav.component.mjs +74 -0
  42. package/{esm2020 → esm2022}/lib/window-container-sidenav/window-container-sidenav.component.module.mjs +8 -7
  43. package/{fesm2020 → fesm2022}/rxap-layout.mjs +436 -437
  44. package/fesm2022/rxap-layout.mjs.map +1 -0
  45. package/lib/header/header.component.d.ts +1 -1
  46. package/lib/header/sidenav-toggle-button/sidenav-toggle-button.component.d.ts +1 -1
  47. package/lib/navigation/navigation-item/navigation-item.component.d.ts +1 -1
  48. package/lib/navigation/navigation-item.d.ts +2 -2
  49. package/lib/navigation/navigation.component.d.ts +1 -1
  50. package/lib/sidenav-content/sidenav-content.component.d.ts +1 -1
  51. package/lib/toggle-window-sidenav-button/toggle-window-sidenav-button.component.d.ts +1 -1
  52. package/package.json +26 -32
  53. package/esm2020/lib/footer/footer.component.module.mjs +0 -29
  54. package/esm2020/lib/footer.directive.mjs +0 -52
  55. package/esm2020/lib/header/apps-button/apps-button.component.module.mjs +0 -45
  56. package/esm2020/lib/header/header.component.mjs +0 -130
  57. package/esm2020/lib/header/header.component.module.mjs +0 -69
  58. package/esm2020/lib/header/language-selector/language-selector.component.mjs +0 -111
  59. package/esm2020/lib/header/navigation-progress-bar/navigation-progress-bar.component.mjs +0 -33
  60. package/esm2020/lib/header/navigation-progress-bar/navigation-progress-bar.component.module.mjs +0 -25
  61. package/esm2020/lib/header/reset-button/reset-button.component.mjs +0 -27
  62. package/esm2020/lib/header/reset-button/reset-button.component.module.mjs +0 -25
  63. package/esm2020/lib/header/sidenav-toggle-button/sidenav-toggle-button.component.mjs +0 -44
  64. package/esm2020/lib/header/sign-out/sign-out.component.mjs +0 -31
  65. package/esm2020/lib/header/sign-out/sign-out.component.module.mjs +0 -29
  66. package/esm2020/lib/header/user-profile-icon/user-profile-icon.component.module.mjs +0 -37
  67. package/esm2020/lib/layout/layout.component.mjs +0 -78
  68. package/esm2020/lib/layout/layout.component.module.mjs +0 -69
  69. package/esm2020/lib/layout/layout.component.service.mjs +0 -43
  70. package/esm2020/lib/navigation/navigation-item/navigation-item.component.mjs +0 -286
  71. package/esm2020/lib/navigation/navigation.component.mjs +0 -130
  72. package/esm2020/lib/navigation/navigation.service.mjs +0 -143
  73. package/esm2020/lib/navigation/replace-router-paths.pipe.mjs +0 -34
  74. package/esm2020/lib/navigation/replace-router-paths.service.mjs +0 -15
  75. package/esm2020/lib/sidenav/sidenav-footer.directive.mjs +0 -19
  76. package/esm2020/lib/sidenav/sidenav-header.directive.mjs +0 -19
  77. package/esm2020/lib/sidenav/sidenav.component.mjs +0 -120
  78. package/esm2020/lib/sidenav/sidenav.component.module.mjs +0 -43
  79. package/esm2020/lib/sidenav/sidenav.component.service.mjs +0 -22
  80. package/esm2020/lib/sidenav/version/version.component.mjs +0 -62
  81. package/esm2020/lib/sidenav-content/sidenav-content.component.mjs +0 -45
  82. package/esm2020/lib/sidenav-content/sidenav-content.component.service.mjs +0 -36
  83. package/esm2020/lib/toggle-window-sidenav-button/toggle-window-sidenav-button.component.mjs +0 -50
  84. package/esm2020/lib/window-container-sidenav/window-container-sidenav.component.mjs +0 -73
  85. package/fesm2015/rxap-layout.mjs +0 -2543
  86. package/fesm2015/rxap-layout.mjs.map +0 -1
  87. package/fesm2020/rxap-layout.mjs.map +0 -1
  88. /package/{esm2020 → esm2022}/index.mjs +0 -0
  89. /package/{esm2020 → esm2022}/lib/navigation/navigation-item.mjs +0 -0
  90. /package/{esm2020 → esm2022}/lib/tokens.mjs +0 -0
  91. /package/{esm2020 → esm2022}/lib/types.mjs +0 -0
  92. /package/{esm2020 → esm2022}/rxap-layout.mjs +0 -0
@@ -1,2543 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { InjectionToken, Component, ChangeDetectionStrategy, NgModule, Inject, Input, Optional, Injectable, TemplateRef, Directive, INJECTOR, ElementRef, Renderer2, ViewContainerRef, ViewEncapsulation, ViewChild, HostBinding, HostListener, ChangeDetectorRef, ContentChild, EventEmitter, Output, Pipe } from '@angular/core';
3
- import * as i1 from '@rxap/services';
4
- import { HeaderService, ResetService, FooterService, WindowContainerSidenavService, VersionService } from '@rxap/services';
5
- import * as i2 from '@angular/material/toolbar';
6
- import { MatToolbarModule } from '@angular/material/toolbar';
7
- import * as i2$1 from '@angular/common';
8
- import { CommonModule } from '@angular/common';
9
- import * as i4 from '@angular/cdk/portal';
10
- import { PortalModule, TemplatePortal, ComponentPortal } from '@angular/cdk/portal';
11
- import { Subscription, BehaviorSubject, ReplaySubject, of, from, combineLatest } from 'rxjs';
12
- import { map, filter, tap, switchMap, catchError, startWith, delay, skip, distinctUntilChanged } from 'rxjs/operators';
13
- import * as i3 from '@rxap/authentication';
14
- import { UserService, SignOutDirectiveModule } from '@rxap/authentication';
15
- import * as i3$1 from '@angular/router';
16
- import { Router, NavigationStart, NavigationEnd, NavigationCancel, RouterModule, RouterLinkActive } from '@angular/router';
17
- import * as i1$1 from '@angular/material/legacy-button';
18
- import { MatLegacyButtonModule } from '@angular/material/legacy-button';
19
- import * as i2$2 from '@angular/material/icon';
20
- import { MatIconModule } from '@angular/material/icon';
21
- import { isDefined } from '@rxap/utilities/rxjs';
22
- import * as i1$2 from '@angular/material/legacy-menu';
23
- import { MatLegacyMenuModule } from '@angular/material/legacy-menu';
24
- import * as i1$3 from '@angular/flex-layout/flex';
25
- import * as i5 from '@rxap/directives';
26
- import { AvatarBackgroundImageDirectiveModule, StopPropagationDirectiveModule } from '@rxap/directives';
27
- import * as i1$4 from '@angular/material/legacy-progress-bar';
28
- import { MatLegacyProgressBarModule } from '@angular/material/legacy-progress-bar';
29
- import { __decorate, __metadata } from 'tslib';
30
- import * as i2$4 from '@angular/material/sidenav';
31
- import { MatSidenav, MatSidenavModule } from '@angular/material/sidenav';
32
- import { Required, DebounceCall, coerceBoolean } from '@rxap/utilities';
33
- import * as i5$1 from '@angular/flex-layout/extended';
34
- import * as i1$5 from '@rxap/config';
35
- import { ConfigService } from '@rxap/config';
36
- import * as i3$2 from '@angular/cdk/overlay';
37
- import { OverlayModule, Overlay } from '@angular/cdk/overlay';
38
- import * as i2$3 from '@angular/material/legacy-form-field';
39
- import * as i3$3 from '@angular/material/legacy-select';
40
- import { MatLegacySelectModule } from '@angular/material/legacy-select';
41
- import * as i4$1 from '@angular/material/legacy-core';
42
- import * as i6 from '@angular/forms';
43
- import { FormsModule } from '@angular/forms';
44
- import { FlexLayoutModule } from '@angular/flex-layout';
45
- import { MatGridListModule } from '@angular/material/grid-list';
46
- import * as i3$4 from '@angular/material/divider';
47
- import { MatDividerModule } from '@angular/material/divider';
48
- import { trigger, transition, style, animate } from '@angular/animations';
49
- import * as i5$2 from '@rxap/material-directives/icon';
50
- import { IconDirectiveModule } from '@rxap/material-directives/icon';
51
- import * as i6$1 from '@angular/material/core';
52
- import { MatRippleModule } from '@angular/material/core';
53
- import * as i7 from '@angular/material/legacy-tooltip';
54
- import { MatLegacyTooltipModule } from '@angular/material/legacy-tooltip';
55
-
56
- const RXAP_NAVIGATION_CONFIG = new InjectionToken('rxap/layout/navigation-config');
57
- const RXAP_NAVIGATION_CONFIG_INSERTS = new InjectionToken('rxap/layout/navigation-config-inserts');
58
- const RXAP_FOOTER_COMPONENT = new InjectionToken('rxap/layout/footer-component');
59
- const RXAP_HEADER_COMPONENT = new InjectionToken('rxap/layout/header-component');
60
- const RXAP_LOGO_CONFIG = new InjectionToken('rxap/layout/logo-config');
61
- const RXAP_LAYOUT_APPS_GRID = new InjectionToken('rxap/layout/apps-grid');
62
-
63
- function FooterComponent_ng_template_0_mat_toolbar_0_mat_toolbar_row_1_ng_template_1_Template(rf, ctx) { }
64
- function FooterComponent_ng_template_0_mat_toolbar_0_mat_toolbar_row_1_Template(rf, ctx) {
65
- if (rf & 1) {
66
- i0.ɵɵelementStart(0, "mat-toolbar-row");
67
- i0.ɵɵtemplate(1, FooterComponent_ng_template_0_mat_toolbar_0_mat_toolbar_row_1_ng_template_1_Template, 0, 0, "ng-template", 4);
68
- i0.ɵɵelementEnd();
69
- }
70
- if (rf & 2) {
71
- const portal_r4 = ctx.$implicit;
72
- i0.ɵɵadvance(1);
73
- i0.ɵɵproperty("cdkPortalOutlet", portal_r4);
74
- }
75
- }
76
- function FooterComponent_ng_template_0_mat_toolbar_0_Template(rf, ctx) {
77
- if (rf & 1) {
78
- i0.ɵɵelementStart(0, "mat-toolbar", 2);
79
- i0.ɵɵtemplate(1, FooterComponent_ng_template_0_mat_toolbar_0_mat_toolbar_row_1_Template, 2, 1, "mat-toolbar-row", 3);
80
- i0.ɵɵelementEnd();
81
- }
82
- if (rf & 2) {
83
- const portals_r1 = i0.ɵɵnextContext().$implicit;
84
- i0.ɵɵadvance(1);
85
- i0.ɵɵproperty("ngForOf", portals_r1);
86
- }
87
- }
88
- function FooterComponent_ng_template_0_Template(rf, ctx) {
89
- if (rf & 1) {
90
- i0.ɵɵtemplate(0, FooterComponent_ng_template_0_mat_toolbar_0_Template, 2, 1, "mat-toolbar", 1);
91
- }
92
- if (rf & 2) {
93
- const portals_r1 = ctx.$implicit;
94
- i0.ɵɵproperty("ngIf", portals_r1.length);
95
- }
96
- }
97
- class FooterComponent {
98
- constructor(footerService) {
99
- this.footerService = footerService;
100
- }
101
- }
102
- FooterComponent.ɵfac = function FooterComponent_Factory(t) { return new (t || FooterComponent)(i0.ɵɵdirectiveInject(i1.FooterService)); };
103
- FooterComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: FooterComponent, selectors: [["rxap-footer"]], decls: 2, vars: 3, consts: [[3, "ngIf"], ["class", "footer mat-elevation-z1", 4, "ngIf"], [1, "footer", "mat-elevation-z1"], [4, "ngFor", "ngForOf"], [3, "cdkPortalOutlet"]], template: function FooterComponent_Template(rf, ctx) {
104
- if (rf & 1) {
105
- i0.ɵɵtemplate(0, FooterComponent_ng_template_0_Template, 1, 1, "ng-template", 0);
106
- i0.ɵɵpipe(1, "async");
107
- }
108
- if (rf & 2) {
109
- i0.ɵɵproperty("ngIf", i0.ɵɵpipeBind1(1, 1, ctx.footerService.portals$));
110
- }
111
- }, dependencies: [i2.MatToolbar, i2.MatToolbarRow, i2$1.NgForOf, i2$1.NgIf, i4.CdkPortalOutlet, i2$1.AsyncPipe], changeDetection: 0 });
112
- (function () {
113
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(FooterComponent, [{
114
- type: Component,
115
- args: [{ selector: 'rxap-footer', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-template [ngIf]=\"footerService.portals$ | async\" let-portals>\n <mat-toolbar *ngIf=\"portals.length\" class=\"footer mat-elevation-z1\">\n <mat-toolbar-row *ngFor=\"let portal of portals\">\n <ng-template [cdkPortalOutlet]=\"portal\"></ng-template>\n </mat-toolbar-row>\n </mat-toolbar>\n</ng-template>\n" }]
116
- }], function () { return [{ type: i1.FooterService }]; }, null);
117
- })();
118
-
119
- class FooterModule {
120
- }
121
- FooterModule.ɵfac = function FooterModule_Factory(t) { return new (t || FooterModule)(); };
122
- FooterModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: FooterModule });
123
- FooterModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [MatToolbarModule,
124
- CommonModule,
125
- PortalModule] });
126
- (function () {
127
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(FooterModule, [{
128
- type: NgModule,
129
- args: [{
130
- declarations: [FooterComponent],
131
- imports: [
132
- MatToolbarModule,
133
- CommonModule,
134
- PortalModule
135
- ],
136
- exports: [FooterComponent]
137
- }]
138
- }], null, null);
139
- })();
140
- (function () {
141
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(FooterModule, { declarations: [FooterComponent], imports: [MatToolbarModule,
142
- CommonModule,
143
- PortalModule], exports: [FooterComponent] });
144
- })();
145
-
146
- class SignOutComponent {
147
- constructor(router) {
148
- this.router = router;
149
- }
150
- redirectToRoot() {
151
- this.router.navigate(['/']);
152
- }
153
- }
154
- SignOutComponent.ɵfac = function SignOutComponent_Factory(t) { return new (t || SignOutComponent)(i0.ɵɵdirectiveInject(Router)); };
155
- SignOutComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SignOutComponent, selectors: [["rxap-sign-out"]], hostAttrs: [1, "rxap-sign-out"], decls: 3, vars: 0, consts: [["rxapSignOut", "", "mat-icon-button", "", 3, "successful"]], template: function SignOutComponent_Template(rf, ctx) {
156
- if (rf & 1) {
157
- i0.ɵɵelementStart(0, "button", 0);
158
- i0.ɵɵlistener("successful", function SignOutComponent_Template_button_successful_0_listener() { return ctx.redirectToRoot(); });
159
- i0.ɵɵelementStart(1, "mat-icon");
160
- i0.ɵɵtext(2, "login");
161
- i0.ɵɵelementEnd()();
162
- }
163
- }, dependencies: [i1$1.MatLegacyButton, i2$2.MatIcon, i3.SignOutDirective], changeDetection: 0 });
164
- (function () {
165
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SignOutComponent, [{
166
- type: Component,
167
- args: [{ selector: 'rxap-sign-out', changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'rxap-sign-out' }, template: "<button\n rxapSignOut\n (successful)=\"redirectToRoot()\"\n mat-icon-button\n>\n <mat-icon>login</mat-icon>\n</button>\n" }]
168
- }], function () {
169
- return [{ type: i3$1.Router, decorators: [{
170
- type: Inject,
171
- args: [Router]
172
- }] }];
173
- }, null);
174
- })();
175
-
176
- function UserProfileIconComponent_ng_template_5_button_0_Template(rf, ctx) {
177
- if (rf & 1) {
178
- i0.ɵɵelementStart(0, "button", 5)(1, "mat-icon");
179
- i0.ɵɵtext(2, "person");
180
- i0.ɵɵelementEnd();
181
- i0.ɵɵelementStart(3, "span");
182
- i0.ɵɵtext(4);
183
- i0.ɵɵelementEnd()();
184
- }
185
- if (rf & 2) {
186
- const user_r2 = i0.ɵɵnextContext().$implicit;
187
- i0.ɵɵadvance(4);
188
- i0.ɵɵtextInterpolate2("", user_r2.firstname, " ", user_r2.lastname, "");
189
- }
190
- }
191
- function UserProfileIconComponent_ng_template_5_button_1_Template(rf, ctx) {
192
- if (rf & 1) {
193
- i0.ɵɵelementStart(0, "button", 5)(1, "mat-icon");
194
- i0.ɵɵtext(2, "person");
195
- i0.ɵɵelementEnd();
196
- i0.ɵɵelementStart(3, "span");
197
- i0.ɵɵtext(4);
198
- i0.ɵɵelementEnd()();
199
- }
200
- if (rf & 2) {
201
- const user_r2 = i0.ɵɵnextContext().$implicit;
202
- i0.ɵɵadvance(4);
203
- i0.ɵɵtextInterpolate(user_r2.name);
204
- }
205
- }
206
- function UserProfileIconComponent_ng_template_5_button_2_Template(rf, ctx) {
207
- if (rf & 1) {
208
- i0.ɵɵelementStart(0, "button", 5)(1, "mat-icon");
209
- i0.ɵɵtext(2, "account_circle");
210
- i0.ɵɵelementEnd();
211
- i0.ɵɵelementStart(3, "span");
212
- i0.ɵɵtext(4);
213
- i0.ɵɵelementEnd()();
214
- }
215
- if (rf & 2) {
216
- const user_r2 = i0.ɵɵnextContext().$implicit;
217
- i0.ɵɵadvance(4);
218
- i0.ɵɵtextInterpolate(user_r2.username);
219
- }
220
- }
221
- function UserProfileIconComponent_ng_template_5_button_3_Template(rf, ctx) {
222
- if (rf & 1) {
223
- i0.ɵɵelementStart(0, "button", 5)(1, "mat-icon");
224
- i0.ɵɵtext(2, "email");
225
- i0.ɵɵelementEnd();
226
- i0.ɵɵelementStart(3, "span");
227
- i0.ɵɵtext(4);
228
- i0.ɵɵelementEnd()();
229
- }
230
- if (rf & 2) {
231
- const user_r2 = i0.ɵɵnextContext().$implicit;
232
- i0.ɵɵadvance(4);
233
- i0.ɵɵtextInterpolate(user_r2.email);
234
- }
235
- }
236
- function UserProfileIconComponent_ng_template_5_Template(rf, ctx) {
237
- if (rf & 1) {
238
- i0.ɵɵtemplate(0, UserProfileIconComponent_ng_template_5_button_0_Template, 5, 2, "button", 4);
239
- i0.ɵɵtemplate(1, UserProfileIconComponent_ng_template_5_button_1_Template, 5, 1, "button", 4);
240
- i0.ɵɵtemplate(2, UserProfileIconComponent_ng_template_5_button_2_Template, 5, 1, "button", 4);
241
- i0.ɵɵtemplate(3, UserProfileIconComponent_ng_template_5_button_3_Template, 5, 1, "button", 4);
242
- }
243
- if (rf & 2) {
244
- const user_r2 = ctx.$implicit;
245
- i0.ɵɵproperty("ngIf", user_r2.firstname && user_r2.lastname);
246
- i0.ɵɵadvance(1);
247
- i0.ɵɵproperty("ngIf", user_r2.name);
248
- i0.ɵɵadvance(1);
249
- i0.ɵɵproperty("ngIf", user_r2.username);
250
- i0.ɵɵadvance(1);
251
- i0.ɵɵproperty("ngIf", user_r2.email);
252
- }
253
- }
254
- class UserProfileIconComponent {
255
- constructor(userService) {
256
- this.userService = userService;
257
- this.userProfileUrl$ = this.userService.user$.pipe(isDefined(), map((user) => { var _a; return (_a = user.photoURL) !== null && _a !== void 0 ? _a : user.avatarUrl; }));
258
- this.userName$ = this.userService.user$.pipe(isDefined(), map((user) => {
259
- var _a, _b;
260
- return (_b = (_a = user.name) !== null && _a !== void 0 ? _a : (user.firstname || user.lastname
261
- ? [user.firstname, user.lastname].join(' ').trim()
262
- : null)) !== null && _b !== void 0 ? _b : user.username;
263
- }));
264
- }
265
- }
266
- UserProfileIconComponent.ɵfac = function UserProfileIconComponent_Factory(t) { return new (t || UserProfileIconComponent)(i0.ɵɵdirectiveInject(UserService)); };
267
- UserProfileIconComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: UserProfileIconComponent, selectors: [["rxap-user-profile-icon"]], hostAttrs: [1, "rxap-user-profile-icon"], decls: 7, vars: 11, consts: [["fxLayout", "row", "fxLayoutAlign", "center center", 1, "profile-icon", 3, "matMenuTriggerFor", "rxapAvatarBackgroundImage", "name"], [3, "yPosition"], ["menu", "matMenu"], [3, "ngIf"], ["mat-menu-item", "", 4, "ngIf"], ["mat-menu-item", ""]], template: function UserProfileIconComponent_Template(rf, ctx) {
268
- if (rf & 1) {
269
- i0.ɵɵelement(0, "button", 0);
270
- i0.ɵɵpipe(1, "async");
271
- i0.ɵɵpipe(2, "async");
272
- i0.ɵɵelementStart(3, "mat-menu", 1, 2);
273
- i0.ɵɵtemplate(5, UserProfileIconComponent_ng_template_5_Template, 4, 4, "ng-template", 3);
274
- i0.ɵɵpipe(6, "async");
275
- i0.ɵɵelementEnd();
276
- }
277
- if (rf & 2) {
278
- const _r0 = i0.ɵɵreference(4);
279
- let tmp_2_0;
280
- i0.ɵɵproperty("matMenuTriggerFor", _r0)("rxapAvatarBackgroundImage", i0.ɵɵpipeBind1(1, 5, ctx.userProfileUrl$))("name", (tmp_2_0 = i0.ɵɵpipeBind1(2, 7, ctx.userName$)) !== null && tmp_2_0 !== undefined ? tmp_2_0 : "");
281
- i0.ɵɵadvance(3);
282
- i0.ɵɵproperty("yPosition", "below");
283
- i0.ɵɵadvance(2);
284
- i0.ɵɵproperty("ngIf", i0.ɵɵpipeBind1(6, 9, ctx.userService.user$));
285
- }
286
- }, dependencies: [i1$2.MatLegacyMenu, i1$2.MatLegacyMenuItem, i1$2.MatLegacyMenuTrigger, i2$2.MatIcon, i2$1.NgIf, i1$3.DefaultLayoutDirective, i1$3.DefaultLayoutAlignDirective, i5.AvatarBackgroundImageDirective, i2$1.AsyncPipe], styles: [".profile-icon[_ngcontent-%COMP%]{border-radius:100%;border:none;height:32px;width:32px;overflow:hidden;background-position:center center;background-repeat:no-repeat;background-size:cover}.profile-icon[_ngcontent-%COMP%]:hover{cursor:pointer}.profile-icon[_ngcontent-%COMP%]:focus{outline:none}"], changeDetection: 0 });
287
- (function () {
288
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(UserProfileIconComponent, [{
289
- type: Component,
290
- args: [{ selector: 'rxap-user-profile-icon', changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'rxap-user-profile-icon' }, template: "<button [matMenuTriggerFor]=\"menu\"\n [rxapAvatarBackgroundImage]=\"userProfileUrl$ | async\"\n [name]=\"(userName$ | async) ?? ''\"\n class=\"profile-icon\"\n fxLayout=\"row\"\n fxLayoutAlign=\"center center\">\n</button>\n\n<mat-menu #menu=\"matMenu\" [yPosition]=\"'below'\">\n <ng-template [ngIf]=\"userService.user$ | async\" let-user>\n <button *ngIf=\"user.firstname && user.lastname\" mat-menu-item>\n <mat-icon>person</mat-icon>\n <span>{{user.firstname}} {{user.lastname}}</span>\n </button>\n <button *ngIf=\"user.name\" mat-menu-item>\n <mat-icon>person</mat-icon>\n <span>{{user.name}}</span>\n </button>\n <button *ngIf=\"user.username\" mat-menu-item>\n <mat-icon>account_circle</mat-icon>\n <span>{{user.username}}</span>\n </button>\n <button *ngIf=\"user.email\" mat-menu-item>\n <mat-icon>email</mat-icon>\n <span>{{user.email}}</span>\n </button>\n </ng-template>\n</mat-menu>\n", styles: [".profile-icon{border-radius:100%;border:none;height:32px;width:32px;overflow:hidden;background-position:center center;background-repeat:no-repeat;background-size:cover}.profile-icon:hover{cursor:pointer}.profile-icon:focus{outline:none}\n"] }]
291
- }], function () {
292
- return [{ type: i3.UserService, decorators: [{
293
- type: Inject,
294
- args: [UserService]
295
- }] }];
296
- }, null);
297
- })();
298
-
299
- function NavigationProgressBarComponent_mat_progress_bar_0_Template(rf, ctx) {
300
- if (rf & 1) {
301
- i0.ɵɵelement(0, "mat-progress-bar", 1);
302
- }
303
- }
304
- class NavigationProgressBarComponent {
305
- constructor(router) {
306
- this.router = router;
307
- this.navigating$ = this.router.events.pipe(filter(event => event instanceof NavigationStart ||
308
- event instanceof NavigationEnd ||
309
- event instanceof NavigationCancel), map(event => event instanceof NavigationStart));
310
- }
311
- }
312
- NavigationProgressBarComponent.ɵfac = function NavigationProgressBarComponent_Factory(t) { return new (t || NavigationProgressBarComponent)(i0.ɵɵdirectiveInject(Router)); };
313
- NavigationProgressBarComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: NavigationProgressBarComponent, selectors: [["rxap-navigation-progress-bar"]], hostAttrs: [1, "rxap-navigation-progress-bar"], decls: 2, vars: 3, consts: [["mode", "indeterminate", "color", "accent", 4, "ngIf"], ["mode", "indeterminate", "color", "accent"]], template: function NavigationProgressBarComponent_Template(rf, ctx) {
314
- if (rf & 1) {
315
- i0.ɵɵtemplate(0, NavigationProgressBarComponent_mat_progress_bar_0_Template, 1, 0, "mat-progress-bar", 0);
316
- i0.ɵɵpipe(1, "async");
317
- }
318
- if (rf & 2) {
319
- i0.ɵɵproperty("ngIf", i0.ɵɵpipeBind1(1, 1, ctx.navigating$));
320
- }
321
- }, dependencies: [i1$4.MatLegacyProgressBar, i2$1.NgIf, i2$1.AsyncPipe], changeDetection: 0 });
322
- (function () {
323
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(NavigationProgressBarComponent, [{
324
- type: Component,
325
- args: [{ selector: 'rxap-navigation-progress-bar', changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'rxap-navigation-progress-bar' }, template: "<mat-progress-bar\n *ngIf=\"navigating$ | async\"\n mode=\"indeterminate\"\n color=\"accent\"\n></mat-progress-bar>\n" }]
326
- }], function () {
327
- return [{ type: i3$1.Router, decorators: [{
328
- type: Inject,
329
- args: [Router]
330
- }] }];
331
- }, null);
332
- })();
333
-
334
- function SidenavToggleButtonComponent_mat_icon_1_Template(rf, ctx) {
335
- if (rf & 1) {
336
- i0.ɵɵelementStart(0, "mat-icon");
337
- i0.ɵɵtext(1, "menu");
338
- i0.ɵɵelementEnd();
339
- }
340
- }
341
- function SidenavToggleButtonComponent_mat_icon_2_Template(rf, ctx) {
342
- if (rf & 1) {
343
- i0.ɵɵelementStart(0, "mat-icon");
344
- i0.ɵɵtext(1, "menu_open");
345
- i0.ɵɵelementEnd();
346
- }
347
- }
348
- class SidenavToggleButtonComponent {
349
- }
350
- SidenavToggleButtonComponent.ɵfac = function SidenavToggleButtonComponent_Factory(t) { return new (t || SidenavToggleButtonComponent)(); };
351
- SidenavToggleButtonComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SidenavToggleButtonComponent, selectors: [["rxap-sidenav-toggle-button"]], hostAttrs: [1, "rxap-sidenav-toggle-button"], inputs: { sidenav: "sidenav" }, decls: 3, vars: 2, consts: [["mat-icon-button", "", 3, "click"], [4, "ngIf"]], template: function SidenavToggleButtonComponent_Template(rf, ctx) {
352
- if (rf & 1) {
353
- i0.ɵɵelementStart(0, "button", 0);
354
- i0.ɵɵlistener("click", function SidenavToggleButtonComponent_Template_button_click_0_listener() { return ctx.sidenav.toggle(); });
355
- i0.ɵɵtemplate(1, SidenavToggleButtonComponent_mat_icon_1_Template, 2, 0, "mat-icon", 1);
356
- i0.ɵɵtemplate(2, SidenavToggleButtonComponent_mat_icon_2_Template, 2, 0, "mat-icon", 1);
357
- i0.ɵɵelementEnd();
358
- }
359
- if (rf & 2) {
360
- i0.ɵɵadvance(1);
361
- i0.ɵɵproperty("ngIf", !ctx.sidenav.opened);
362
- i0.ɵɵadvance(1);
363
- i0.ɵɵproperty("ngIf", ctx.sidenav.opened);
364
- }
365
- }, dependencies: [i2$2.MatIcon, i2$1.NgIf, i1$1.MatLegacyButton], changeDetection: 0 });
366
- __decorate([
367
- Required,
368
- __metadata("design:type", MatSidenav)
369
- ], SidenavToggleButtonComponent.prototype, "sidenav", void 0);
370
- (function () {
371
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SidenavToggleButtonComponent, [{
372
- type: Component,
373
- args: [{ selector: 'rxap-sidenav-toggle-button', changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'rxap-sidenav-toggle-button' }, template: "<button (click)=\"sidenav.toggle()\" mat-icon-button>\n <mat-icon *ngIf=\"!sidenav.opened\">menu</mat-icon>\n <mat-icon *ngIf=\"sidenav.opened\">menu_open</mat-icon>\n</button>\n" }]
374
- }], null, { sidenav: [{
375
- type: Input
376
- }] });
377
- })();
378
-
379
- function AppsButtonComponent_ng_template_0_ng_template_4_li_2_a_1_Template(rf, ctx) {
380
- if (rf & 1) {
381
- i0.ɵɵelementStart(0, "a", 9)(1, "span", 10);
382
- i0.ɵɵelement(2, "img", 11);
383
- i0.ɵɵelementStart(3, "span");
384
- i0.ɵɵtext(4);
385
- i0.ɵɵelementEnd()()();
386
- }
387
- if (rf & 2) {
388
- const item_r4 = i0.ɵɵnextContext().$implicit;
389
- i0.ɵɵproperty("href", item_r4.href, i0.ɵɵsanitizeUrl);
390
- i0.ɵɵadvance(2);
391
- i0.ɵɵproperty("src", item_r4.image, i0.ɵɵsanitizeUrl);
392
- i0.ɵɵadvance(2);
393
- i0.ɵɵtextInterpolate(item_r4.label);
394
- }
395
- }
396
- const _c0$5 = function (a0) { return { empty: a0 }; };
397
- function AppsButtonComponent_ng_template_0_ng_template_4_li_2_Template(rf, ctx) {
398
- if (rf & 1) {
399
- i0.ɵɵelementStart(0, "li", 7);
400
- i0.ɵɵtemplate(1, AppsButtonComponent_ng_template_0_ng_template_4_li_2_a_1_Template, 5, 3, "a", 8);
401
- i0.ɵɵelementEnd();
402
- }
403
- if (rf & 2) {
404
- const item_r4 = ctx.$implicit;
405
- i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(2, _c0$5, item_r4.empty));
406
- i0.ɵɵadvance(1);
407
- i0.ɵɵproperty("ngIf", !item_r4.empty);
408
- }
409
- }
410
- const _c1$4 = function (a0) { return { columns: a0 }; };
411
- function AppsButtonComponent_ng_template_0_ng_template_4_Template(rf, ctx) {
412
- if (rf & 1) {
413
- i0.ɵɵelementStart(0, "div", 4)(1, "ul", 5);
414
- i0.ɵɵtemplate(2, AppsButtonComponent_ng_template_0_ng_template_4_li_2_Template, 2, 4, "li", 6);
415
- i0.ɵɵelementEnd()();
416
- }
417
- if (rf & 2) {
418
- const ctx_r2 = i0.ɵɵnextContext(2);
419
- i0.ɵɵadvance(1);
420
- i0.ɵɵproperty("ngStyle", i0.ɵɵpureFunction1(2, _c1$4, ctx_r2.columns));
421
- i0.ɵɵadvance(1);
422
- i0.ɵɵproperty("ngForOf", ctx_r2.gridWithPadding);
423
- }
424
- }
425
- function AppsButtonComponent_ng_template_0_Template(rf, ctx) {
426
- if (rf & 1) {
427
- const _r8 = i0.ɵɵgetCurrentView();
428
- i0.ɵɵelementStart(0, "button", 1, 2);
429
- i0.ɵɵlistener("click", function AppsButtonComponent_ng_template_0_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r8); const ctx_r7 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r7.isOpen = !ctx_r7.isOpen); });
430
- i0.ɵɵelementStart(2, "mat-icon");
431
- i0.ɵɵtext(3, "apps");
432
- i0.ɵɵelementEnd()();
433
- i0.ɵɵtemplate(4, AppsButtonComponent_ng_template_0_ng_template_4_Template, 3, 4, "ng-template", 3);
434
- i0.ɵɵlistener("overlayOutsideClick", function AppsButtonComponent_ng_template_0_Template_ng_template_overlayOutsideClick_4_listener() { i0.ɵɵrestoreView(_r8); const ctx_r9 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r9.isOpen = false); });
435
- }
436
- if (rf & 2) {
437
- const _r1 = i0.ɵɵreference(1);
438
- const ctx_r0 = i0.ɵɵnextContext();
439
- i0.ɵɵadvance(4);
440
- i0.ɵɵproperty("cdkConnectedOverlayOpen", ctx_r0.isOpen)("cdkConnectedOverlayOrigin", _r1);
441
- }
442
- }
443
- class AppsButtonComponent {
444
- constructor(grid, config) {
445
- var _a;
446
- this.config = config;
447
- this.isOpen = false;
448
- this.grid = [];
449
- this.grid = (_a = grid !== null && grid !== void 0 ? grid : this.config.get('navigation.apps')) !== null && _a !== void 0 ? _a : [];
450
- }
451
- get gridWithPadding() {
452
- const gridWithPadding = this.grid.slice();
453
- while (gridWithPadding.length % this.columns !== 0) {
454
- gridWithPadding.push({ empty: true });
455
- }
456
- return gridWithPadding;
457
- }
458
- get columns() {
459
- if (this.grid.length < 4) {
460
- return 1;
461
- }
462
- if (this.grid.length < 6) {
463
- return 2;
464
- }
465
- return 3;
466
- }
467
- }
468
- AppsButtonComponent.ɵfac = function AppsButtonComponent_Factory(t) { return new (t || AppsButtonComponent)(i0.ɵɵdirectiveInject(RXAP_LAYOUT_APPS_GRID, 8), i0.ɵɵdirectiveInject(ConfigService)); };
469
- AppsButtonComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: AppsButtonComponent, selectors: [["rxap-apps-button"]], hostAttrs: [1, "rxap-apps-button"], decls: 1, vars: 1, consts: [[3, "ngIf"], ["cdkOverlayOrigin", "", "mat-icon-button", "", 3, "click"], ["trigger", "cdkOverlayOrigin"], ["cdkConnectedOverlay", "", 3, "cdkConnectedOverlayOpen", "cdkConnectedOverlayOrigin", "overlayOutsideClick"], [1, "grid-container"], [1, "grid", 3, "ngStyle"], [3, "ngClass", 4, "ngFor", "ngForOf"], [3, "ngClass"], [3, "href", 4, "ngIf"], [3, "href"], ["fxLayout", "column", "fxLayoutAlign", "start center", "fxLayoutGap", "12px"], ["width", "53px", 3, "src"]], template: function AppsButtonComponent_Template(rf, ctx) {
470
- if (rf & 1) {
471
- i0.ɵɵtemplate(0, AppsButtonComponent_ng_template_0_Template, 5, 2, "ng-template", 0);
472
- }
473
- if (rf & 2) {
474
- i0.ɵɵproperty("ngIf", ctx.grid && ctx.grid.length);
475
- }
476
- }, dependencies: [i1$1.MatLegacyButton, i2$2.MatIcon, i3$2.CdkConnectedOverlay, i3$2.CdkOverlayOrigin, i1$3.DefaultLayoutDirective, i1$3.DefaultLayoutGapDirective, i1$3.DefaultLayoutAlignDirective, i5$1.DefaultClassDirective, i5$1.DefaultStyleDirective, i2$1.NgClass, i2$1.NgForOf, i2$1.NgIf, i2$1.NgStyle], styles: [".grid-container[_ngcontent-%COMP%]{padding:8px;border:1px solid rgba(0,0,0,.2);border-radius:8px;box-shadow:0 1px 2px #3c40434d,0 2px 6px 2px #3c404326}.grid[_ngcontent-%COMP%]{list-style-type:none;margin:0;padding:0}.grid[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{border-radius:8px;padding:6px;height:84px;width:84px;transition-delay:0s;transition-duration:.2s;transition-property:tramsform;transition-timing-function:cubic-bezier(.333,0,0,1);position:relative}.grid[_ngcontent-%COMP%] li[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{position:absolute;inset:6px;text-align:center;text-decoration:none;color:#000}"], changeDetection: 0 });
477
- (function () {
478
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(AppsButtonComponent, [{
479
- type: Component,
480
- args: [{ selector: 'rxap-apps-button', changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'rxap-apps-button' }, template: "<ng-template [ngIf]=\"grid && grid.length\">\n <button #trigger=\"cdkOverlayOrigin\" (click)=\"isOpen = !isOpen\" cdkOverlayOrigin mat-icon-button>\n <mat-icon>apps</mat-icon>\n </button>\n\n <ng-template (overlayOutsideClick)=\"isOpen = false\"\n [cdkConnectedOverlayOpen]=\"isOpen\"\n [cdkConnectedOverlayOrigin]=\"trigger\"\n cdkConnectedOverlay>\n\n <div class=\"grid-container\">\n\n <ul [ngStyle]=\"{ columns: columns }\" class=\"grid\">\n <li *ngFor=\"let item of gridWithPadding\" [ngClass]=\"{ empty: item.empty }\">\n <a *ngIf=\"!item.empty\" [href]=\"item.href\">\n\n <span fxLayout=\"column\" fxLayoutAlign=\"start center\" fxLayoutGap=\"12px\">\n <img [src]=\"item.image\" width=\"53px\">\n <span>{{item.label}}</span>\n </span>\n\n </a>\n </li>\n </ul>\n\n </div>\n\n </ng-template>\n</ng-template>\n", styles: [".grid-container{padding:8px;border:1px solid rgba(0,0,0,.2);border-radius:8px;box-shadow:0 1px 2px #3c40434d,0 2px 6px 2px #3c404326}.grid{list-style-type:none;margin:0;padding:0}.grid li{border-radius:8px;padding:6px;height:84px;width:84px;transition-delay:0s;transition-duration:.2s;transition-property:tramsform;transition-timing-function:cubic-bezier(.333,0,0,1);position:relative}.grid li a{position:absolute;inset:6px;text-align:center;text-decoration:none;color:#000}\n"] }]
481
- }], function () {
482
- return [{ type: undefined, decorators: [{
483
- type: Optional
484
- }, {
485
- type: Inject,
486
- args: [RXAP_LAYOUT_APPS_GRID]
487
- }] }, { type: i1$5.ConfigService, decorators: [{
488
- type: Inject,
489
- args: [ConfigService]
490
- }] }];
491
- }, null);
492
- })();
493
-
494
- function LanguageSelectorComponent_ng_template_0_mat_option_3_Template(rf, ctx) {
495
- if (rf & 1) {
496
- i0.ɵɵelementStart(0, "mat-option", 4);
497
- i0.ɵɵtext(1);
498
- i0.ɵɵelementEnd();
499
- }
500
- if (rf & 2) {
501
- const item_r2 = ctx.$implicit;
502
- i0.ɵɵproperty("value", item_r2.key);
503
- i0.ɵɵadvance(1);
504
- i0.ɵɵtextInterpolate(item_r2.value);
505
- }
506
- }
507
- function LanguageSelectorComponent_ng_template_0_Template(rf, ctx) {
508
- if (rf & 1) {
509
- const _r4 = i0.ɵɵgetCurrentView();
510
- i0.ɵɵelementStart(0, "div")(1, "mat-form-field", 1)(2, "mat-select", 2);
511
- i0.ɵɵlistener("ngModelChange", function LanguageSelectorComponent_ng_template_0_Template_mat_select_ngModelChange_2_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r3 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r3.language.setLanguage($event)); });
512
- i0.ɵɵtemplate(3, LanguageSelectorComponent_ng_template_0_mat_option_3_Template, 2, 2, "mat-option", 3);
513
- i0.ɵɵpipe(4, "keyvalue");
514
- i0.ɵɵelementEnd()()();
515
- }
516
- if (rf & 2) {
517
- const ctx_r0 = i0.ɵɵnextContext();
518
- i0.ɵɵadvance(2);
519
- i0.ɵɵproperty("ngModel", ctx_r0.language.selectedLanguage);
520
- i0.ɵɵadvance(1);
521
- i0.ɵɵproperty("ngForOf", i0.ɵɵpipeBind1(4, 2, ctx_r0.language.languages));
522
- }
523
- }
524
- const RXAP_SELECTED_LANGUAGE_LOCAL_STORAGE_KEY = 'rxap__selected_language';
525
- const RXAP_SELECTED_LANGUAGE_CHANGE_LOCAL_STORAGE_KEY = 'rxap__selected_language_last_change';
526
- class LanguageSelectorService {
527
- constructor(config) {
528
- var _a, _b, _c, _d;
529
- this.config = config;
530
- this.languages = (_a = this.config.get('i18n.languages')) !== null && _a !== void 0 ? _a : {};
531
- this.defaultLanguage =
532
- (_c = (_b = this.config.get('i18n.defaultLanguage')) !== null && _b !== void 0 ? _b : Object.keys(this.languages)[0]) !== null && _c !== void 0 ? _c : 'en';
533
- this.selectedLanguage =
534
- (_d = localStorage.getItem(RXAP_SELECTED_LANGUAGE_LOCAL_STORAGE_KEY)) !== null && _d !== void 0 ? _d : this.defaultLanguage;
535
- }
536
- setLanguage(language) {
537
- if (language !== this.selectedLanguage) {
538
- this.redirect(language);
539
- }
540
- }
541
- autoRedirect() {
542
- if (localStorage.getItem(RXAP_SELECTED_LANGUAGE_LOCAL_STORAGE_KEY)) {
543
- this.redirect(localStorage.getItem(RXAP_SELECTED_LANGUAGE_LOCAL_STORAGE_KEY));
544
- }
545
- }
546
- redirect(language) {
547
- const currentUrl = location.origin + location.pathname + location.search;
548
- const redirectUrl = location.origin +
549
- `/${language}` +
550
- location.pathname.replace(new RegExp(`^\/${this.selectedLanguage}`), '') +
551
- location.search;
552
- this.selectedLanguage = language;
553
- localStorage.setItem(RXAP_SELECTED_LANGUAGE_LOCAL_STORAGE_KEY, language);
554
- if (currentUrl !== redirectUrl) {
555
- if (this.checkLastChange()) {
556
- location.replace(redirectUrl);
557
- }
558
- }
559
- else {
560
- console.log('Redirect not required');
561
- }
562
- }
563
- checkLastChange() {
564
- const lastChangeString = localStorage.getItem(RXAP_SELECTED_LANGUAGE_CHANGE_LOCAL_STORAGE_KEY);
565
- if (lastChangeString) {
566
- if (Date.now() - parseInt(lastChangeString, 10) < 1000) {
567
- return false;
568
- }
569
- }
570
- localStorage.setItem(RXAP_SELECTED_LANGUAGE_CHANGE_LOCAL_STORAGE_KEY, Date.now().toFixed(0));
571
- return true;
572
- }
573
- }
574
- LanguageSelectorService.ɵfac = function LanguageSelectorService_Factory(t) { return new (t || LanguageSelectorService)(i0.ɵɵinject(ConfigService)); };
575
- LanguageSelectorService.ɵprov = /*@__PURE__*/ i0.ɵɵdefineInjectable({ token: LanguageSelectorService, factory: LanguageSelectorService.ɵfac, providedIn: 'root' });
576
- (function () {
577
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LanguageSelectorService, [{
578
- type: Injectable,
579
- args: [{ providedIn: 'root' }]
580
- }], function () {
581
- return [{ type: i1$5.ConfigService, decorators: [{
582
- type: Inject,
583
- args: [ConfigService]
584
- }] }];
585
- }, null);
586
- })();
587
- class LanguageSelectorComponent {
588
- constructor(language) {
589
- this.language = language;
590
- }
591
- }
592
- LanguageSelectorComponent.ɵfac = function LanguageSelectorComponent_Factory(t) { return new (t || LanguageSelectorComponent)(i0.ɵɵdirectiveInject(LanguageSelectorService)); };
593
- LanguageSelectorComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: LanguageSelectorComponent, selectors: [["rxap-language-selector"]], hostAttrs: [1, "rxap-language-selector"], decls: 2, vars: 3, consts: [[3, "ngIf"], ["appearance", "outline", 1, "language-selector"], [3, "ngModel", "ngModelChange"], [3, "value", 4, "ngFor", "ngForOf"], [3, "value"]], template: function LanguageSelectorComponent_Template(rf, ctx) {
594
- if (rf & 1) {
595
- i0.ɵɵtemplate(0, LanguageSelectorComponent_ng_template_0_Template, 5, 4, "ng-template", 0);
596
- i0.ɵɵpipe(1, "keyvalue");
597
- }
598
- if (rf & 2) {
599
- i0.ɵɵproperty("ngIf", i0.ɵɵpipeBind1(1, 1, ctx.language.languages).length);
600
- }
601
- }, dependencies: [i2$3.MatLegacyFormField, i3$3.MatLegacySelect, i4$1.MatLegacyOption, i2$1.NgForOf, i2$1.NgIf, i6.NgControlStatus, i6.NgModel, i2$1.KeyValuePipe], styles: [".language-selector[_ngcontent-%COMP%]{width:142px}.language-selector[_ngcontent-%COMP%] .mat-form-field-wrapper{padding-bottom:0}.language-selector[_ngcontent-%COMP%] .mat-form-field-wrapper .mat-form-field-infix{padding:12px 0;border-width:6px}.language-selector[_ngcontent-%COMP%] .mat-form-field-wrapper .mat-form-field-infix .mat-select-arrow-wrapper{transform:translateY(0)}"], changeDetection: 0 });
602
- (function () {
603
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LanguageSelectorComponent, [{
604
- type: Component,
605
- args: [{ selector: 'rxap-language-selector', changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'rxap-language-selector' }, template: "<ng-template [ngIf]=\"(language.languages | keyvalue).length\">\n <div>\n <mat-form-field appearance=\"outline\" class=\"language-selector\">\n <mat-select (ngModelChange)=\"language.setLanguage($event)\" [ngModel]=\"language.selectedLanguage\">\n <mat-option *ngFor=\"let item of language.languages | keyvalue\" [value]=\"item.key\">{{item.value}}</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n</ng-template>\n", styles: [".language-selector{width:142px}.language-selector ::ng-deep .mat-form-field-wrapper{padding-bottom:0}.language-selector ::ng-deep .mat-form-field-wrapper .mat-form-field-infix{padding:12px 0;border-width:6px}.language-selector ::ng-deep .mat-form-field-wrapper .mat-form-field-infix .mat-select-arrow-wrapper{transform:translateY(0)}\n"] }]
606
- }], function () { return [{ type: LanguageSelectorService }]; }, null);
607
- })();
608
-
609
- function HeaderComponent_mat_toolbar_row_1_ng_container_1_Template(rf, ctx) {
610
- if (rf & 1) {
611
- i0.ɵɵelementContainer(0);
612
- }
613
- }
614
- function HeaderComponent_mat_toolbar_row_1_Template(rf, ctx) {
615
- if (rf & 1) {
616
- i0.ɵɵelementStart(0, "mat-toolbar-row");
617
- i0.ɵɵtemplate(1, HeaderComponent_mat_toolbar_row_1_ng_container_1_Template, 1, 0, "ng-container", 7);
618
- i0.ɵɵelementEnd();
619
- }
620
- if (rf & 2) {
621
- const headerComponent_r4 = ctx.$implicit;
622
- i0.ɵɵadvance(1);
623
- i0.ɵɵproperty("ngComponentOutlet", headerComponent_r4);
624
- }
625
- }
626
- function HeaderComponent_rxap_sidenav_toggle_button_4_Template(rf, ctx) {
627
- if (rf & 1) {
628
- i0.ɵɵelement(0, "rxap-sidenav-toggle-button", 8);
629
- }
630
- if (rf & 2) {
631
- const ctx_r1 = i0.ɵɵnextContext();
632
- i0.ɵɵproperty("sidenav", ctx_r1.sidenav);
633
- }
634
- }
635
- function HeaderComponent_rxap_user_profile_icon_9_Template(rf, ctx) {
636
- if (rf & 1) {
637
- i0.ɵɵelement(0, "rxap-user-profile-icon", 5);
638
- }
639
- }
640
- function HeaderComponent_div_11_Template(rf, ctx) {
641
- if (rf & 1) {
642
- i0.ɵɵelementStart(0, "div", 5)(1, "button", 9)(2, "mat-icon");
643
- i0.ɵɵtext(3, "settings");
644
- i0.ɵɵelementEnd()()();
645
- }
646
- if (rf & 2) {
647
- const ctx_r3 = i0.ɵɵnextContext();
648
- i0.ɵɵadvance(1);
649
- i0.ɵɵproperty("matMenuTriggerFor", ctx_r3.settingsMenuPanel);
650
- }
651
- }
652
- const _c0$4 = function (a0) { return { open: a0 }; };
653
- const _c1$3 = ["*"];
654
- class HeaderComponent {
655
- constructor(headerComponentService, userService, headerComponent) {
656
- this.headerComponentService = headerComponentService;
657
- this.userService = userService;
658
- this.headerComponent = headerComponent;
659
- this.components = [];
660
- this.subscriptions = new Subscription();
661
- this.color = 'primary';
662
- this.hasUser$ = this.userService.user$.pipe(map(Boolean));
663
- }
664
- ngOnInit() {
665
- this.updateComponents();
666
- this.subscriptions.add(this.headerComponentService.update$
667
- .pipe(tap(() => this.updateComponents()))
668
- .subscribe());
669
- }
670
- updateComponents() {
671
- this.components = this.headerComponentService.getComponents();
672
- }
673
- ngOnDestroy() {
674
- this.subscriptions.unsubscribe();
675
- }
676
- }
677
- HeaderComponent.ɵfac = function HeaderComponent_Factory(t) { return new (t || HeaderComponent)(i0.ɵɵdirectiveInject(HeaderService), i0.ɵɵdirectiveInject(UserService), i0.ɵɵdirectiveInject(RXAP_HEADER_COMPONENT, 8)); };
678
- HeaderComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: HeaderComponent, selectors: [["rxap-header"]], hostAttrs: [1, "rxap-layout-header"], inputs: { sidenav: "sidenav", color: "color", settingsMenuPanel: "settingsMenuPanel" }, ngContentSelectors: _c1$3, decls: 14, vars: 10, consts: [[1, "mat-elevation-z3", 3, "ngClass", "color"], [4, "ngFor", "ngForOf"], ["fxLayout", "row", "fxLayoutAlign", "space-between center", "fxLayoutGap", "16px", 1, "content"], ["fxFlex", "nogrow", 3, "sidenav", 4, "ngIf"], ["fxFlex", "grow"], ["fxFlex", "nogrow"], ["fxFlex", "nogrow", 4, "ngIf"], [4, "ngComponentOutlet"], ["fxFlex", "nogrow", 3, "sidenav"], ["mat-icon-button", "", 3, "matMenuTriggerFor"]], template: function HeaderComponent_Template(rf, ctx) {
679
- if (rf & 1) {
680
- i0.ɵɵprojectionDef();
681
- i0.ɵɵelementStart(0, "mat-toolbar", 0);
682
- i0.ɵɵtemplate(1, HeaderComponent_mat_toolbar_row_1_Template, 2, 1, "mat-toolbar-row", 1);
683
- i0.ɵɵelementStart(2, "mat-toolbar-row")(3, "div", 2);
684
- i0.ɵɵtemplate(4, HeaderComponent_rxap_sidenav_toggle_button_4_Template, 1, 1, "rxap-sidenav-toggle-button", 3);
685
- i0.ɵɵelementStart(5, "div", 4);
686
- i0.ɵɵprojection(6);
687
- i0.ɵɵelementEnd();
688
- i0.ɵɵelement(7, "rxap-language-selector", 5)(8, "rxap-apps-button", 5);
689
- i0.ɵɵtemplate(9, HeaderComponent_rxap_user_profile_icon_9_Template, 1, 0, "rxap-user-profile-icon", 6);
690
- i0.ɵɵpipe(10, "async");
691
- i0.ɵɵtemplate(11, HeaderComponent_div_11_Template, 4, 1, "div", 6);
692
- i0.ɵɵelement(12, "rxap-sign-out", 5);
693
- i0.ɵɵelementEnd()()();
694
- i0.ɵɵelement(13, "rxap-navigation-progress-bar");
695
- }
696
- if (rf & 2) {
697
- i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(8, _c0$4, ctx.sidenav == null ? null : ctx.sidenav.opened))("color", ctx.color);
698
- i0.ɵɵadvance(1);
699
- i0.ɵɵproperty("ngForOf", ctx.components);
700
- i0.ɵɵadvance(3);
701
- i0.ɵɵproperty("ngIf", ctx.sidenav);
702
- i0.ɵɵadvance(5);
703
- i0.ɵɵproperty("ngIf", i0.ɵɵpipeBind1(10, 6, ctx.hasUser$));
704
- i0.ɵɵadvance(2);
705
- i0.ɵɵproperty("ngIf", ctx.settingsMenuPanel);
706
- }
707
- }, dependencies: [i2.MatToolbar, i2.MatToolbarRow, SignOutComponent, UserProfileIconComponent, NavigationProgressBarComponent, SidenavToggleButtonComponent, i1$3.DefaultLayoutDirective, i1$3.DefaultLayoutGapDirective, i1$3.DefaultLayoutAlignDirective, i1$3.DefaultFlexDirective, i5$1.DefaultClassDirective, i2$1.NgClass, i2$1.NgComponentOutlet, i2$1.NgForOf, i2$1.NgIf, i1$1.MatLegacyButton, i2$2.MatIcon, i1$2.MatLegacyMenuTrigger, AppsButtonComponent, LanguageSelectorComponent, i2$1.AsyncPipe], styles: [".content[_ngcontent-%COMP%]{width:100%;height:64px}"], changeDetection: 0 });
708
- (function () {
709
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(HeaderComponent, [{
710
- type: Component,
711
- args: [{ selector: 'rxap-header', changeDetection: ChangeDetectionStrategy.OnPush, host: {
712
- class: 'rxap-layout-header',
713
- }, template: "<mat-toolbar [ngClass]=\"{ open: sidenav?.opened }\" [color]=\"color\" class=\"mat-elevation-z3\">\n <mat-toolbar-row *ngFor=\"let headerComponent of components\">\n <ng-container *ngComponentOutlet=\"headerComponent\"></ng-container>\n </mat-toolbar-row>\n <mat-toolbar-row>\n <div\n fxLayout=\"row\"\n fxLayoutAlign=\"space-between center\"\n fxLayoutGap=\"16px\"\n class=\"content\"\n >\n <rxap-sidenav-toggle-button *ngIf=\"sidenav\" fxFlex=\"nogrow\" [sidenav]=\"sidenav\"></rxap-sidenav-toggle-button>\n <div fxFlex=\"grow\">\n <ng-content></ng-content>\n </div>\n <rxap-language-selector fxFlex=\"nogrow\"></rxap-language-selector>\n <rxap-apps-button fxFlex=\"nogrow\"></rxap-apps-button>\n <rxap-user-profile-icon *ngIf=\"hasUser$ | async\" fxFlex=\"nogrow\"></rxap-user-profile-icon>\n <div fxFlex=\"nogrow\" *ngIf=\"settingsMenuPanel\">\n <button mat-icon-button [matMenuTriggerFor]=\"settingsMenuPanel\">\n <mat-icon>settings</mat-icon>\n </button>\n </div>\n <rxap-sign-out fxFlex=\"nogrow\"></rxap-sign-out>\n </div>\n </mat-toolbar-row>\n</mat-toolbar>\n<rxap-navigation-progress-bar></rxap-navigation-progress-bar>\n", styles: [".content{width:100%;height:64px}\n"] }]
714
- }], function () {
715
- return [{ type: i1.HeaderService, decorators: [{
716
- type: Inject,
717
- args: [HeaderService]
718
- }] }, { type: i3.UserService, decorators: [{
719
- type: Inject,
720
- args: [UserService]
721
- }] }, { type: undefined, decorators: [{
722
- type: Optional
723
- }, {
724
- type: Inject,
725
- args: [RXAP_HEADER_COMPONENT]
726
- }] }];
727
- }, { sidenav: [{
728
- type: Input
729
- }], color: [{
730
- type: Input
731
- }], settingsMenuPanel: [{
732
- type: Input
733
- }] });
734
- })();
735
-
736
- class SignOutComponentModule {
737
- }
738
- SignOutComponentModule.ɵfac = function SignOutComponentModule_Factory(t) { return new (t || SignOutComponentModule)(); };
739
- SignOutComponentModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: SignOutComponentModule });
740
- SignOutComponentModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [MatLegacyButtonModule,
741
- MatIconModule,
742
- SignOutDirectiveModule] });
743
- (function () {
744
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SignOutComponentModule, [{
745
- type: NgModule,
746
- args: [{
747
- declarations: [SignOutComponent],
748
- imports: [
749
- MatLegacyButtonModule,
750
- MatIconModule,
751
- SignOutDirectiveModule,
752
- ],
753
- exports: [SignOutComponent]
754
- }]
755
- }], null, null);
756
- })();
757
- (function () {
758
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(SignOutComponentModule, { declarations: [SignOutComponent], imports: [MatLegacyButtonModule,
759
- MatIconModule,
760
- SignOutDirectiveModule], exports: [SignOutComponent] });
761
- })();
762
-
763
- class UserProfileIconComponentModule {
764
- }
765
- UserProfileIconComponentModule.ɵfac = function UserProfileIconComponentModule_Factory(t) { return new (t || UserProfileIconComponentModule)(); };
766
- UserProfileIconComponentModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: UserProfileIconComponentModule });
767
- UserProfileIconComponentModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [MatLegacyMenuModule,
768
- MatIconModule,
769
- CommonModule,
770
- FlexLayoutModule,
771
- AvatarBackgroundImageDirectiveModule] });
772
- (function () {
773
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(UserProfileIconComponentModule, [{
774
- type: NgModule,
775
- args: [{
776
- declarations: [UserProfileIconComponent],
777
- imports: [
778
- MatLegacyMenuModule,
779
- MatIconModule,
780
- CommonModule,
781
- FlexLayoutModule,
782
- AvatarBackgroundImageDirectiveModule,
783
- ],
784
- exports: [UserProfileIconComponent]
785
- }]
786
- }], null, null);
787
- })();
788
- (function () {
789
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(UserProfileIconComponentModule, { declarations: [UserProfileIconComponent], imports: [MatLegacyMenuModule,
790
- MatIconModule,
791
- CommonModule,
792
- FlexLayoutModule,
793
- AvatarBackgroundImageDirectiveModule], exports: [UserProfileIconComponent] });
794
- })();
795
-
796
- class NavigationProgressBarComponentModule {
797
- }
798
- NavigationProgressBarComponentModule.ɵfac = function NavigationProgressBarComponentModule_Factory(t) { return new (t || NavigationProgressBarComponentModule)(); };
799
- NavigationProgressBarComponentModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: NavigationProgressBarComponentModule });
800
- NavigationProgressBarComponentModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [MatLegacyProgressBarModule,
801
- CommonModule] });
802
- (function () {
803
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(NavigationProgressBarComponentModule, [{
804
- type: NgModule,
805
- args: [{
806
- declarations: [NavigationProgressBarComponent],
807
- imports: [
808
- MatLegacyProgressBarModule,
809
- CommonModule
810
- ],
811
- exports: [NavigationProgressBarComponent]
812
- }]
813
- }], null, null);
814
- })();
815
- (function () {
816
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(NavigationProgressBarComponentModule, { declarations: [NavigationProgressBarComponent], imports: [MatLegacyProgressBarModule,
817
- CommonModule], exports: [NavigationProgressBarComponent] });
818
- })();
819
-
820
- class SidenavToggleButtonComponentModule {
821
- }
822
- SidenavToggleButtonComponentModule.ɵfac = function SidenavToggleButtonComponentModule_Factory(t) { return new (t || SidenavToggleButtonComponentModule)(); };
823
- SidenavToggleButtonComponentModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: SidenavToggleButtonComponentModule });
824
- SidenavToggleButtonComponentModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [MatIconModule,
825
- CommonModule,
826
- MatLegacyButtonModule] });
827
- (function () {
828
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SidenavToggleButtonComponentModule, [{
829
- type: NgModule,
830
- args: [{
831
- declarations: [SidenavToggleButtonComponent],
832
- imports: [
833
- MatIconModule,
834
- CommonModule,
835
- MatLegacyButtonModule
836
- ],
837
- exports: [SidenavToggleButtonComponent]
838
- }]
839
- }], null, null);
840
- })();
841
- (function () {
842
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(SidenavToggleButtonComponentModule, { declarations: [SidenavToggleButtonComponent], imports: [MatIconModule,
843
- CommonModule,
844
- MatLegacyButtonModule], exports: [SidenavToggleButtonComponent] });
845
- })();
846
-
847
- class ResetButtonComponent {
848
- constructor(resetService) {
849
- this.resetService = resetService;
850
- }
851
- }
852
- ResetButtonComponent.ɵfac = function ResetButtonComponent_Factory(t) { return new (t || ResetButtonComponent)(i0.ɵɵdirectiveInject(ResetService)); };
853
- ResetButtonComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ResetButtonComponent, selectors: [["rxap-reset-button"]], hostAttrs: [1, "rxap-reset-button"], decls: 3, vars: 0, consts: [["mat-icon-button", "", 3, "click"]], template: function ResetButtonComponent_Template(rf, ctx) {
854
- if (rf & 1) {
855
- i0.ɵɵelementStart(0, "button", 0);
856
- i0.ɵɵlistener("click", function ResetButtonComponent_Template_button_click_0_listener() { return ctx.resetService.resetAll(); });
857
- i0.ɵɵelementStart(1, "mat-icon");
858
- i0.ɵɵtext(2, "refresh");
859
- i0.ɵɵelementEnd()();
860
- }
861
- }, dependencies: [i2$2.MatIcon, i1$1.MatLegacyButton], changeDetection: 0 });
862
- (function () {
863
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ResetButtonComponent, [{
864
- type: Component,
865
- args: [{ selector: 'rxap-reset-button', changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'rxap-reset-button' }, template: "<button (click)=\"resetService.resetAll()\" mat-icon-button>\n <mat-icon>refresh</mat-icon>\n</button>\n" }]
866
- }], function () {
867
- return [{ type: i1.ResetService, decorators: [{
868
- type: Inject,
869
- args: [ResetService]
870
- }] }];
871
- }, null);
872
- })();
873
-
874
- class ResetButtonComponentModule {
875
- }
876
- ResetButtonComponentModule.ɵfac = function ResetButtonComponentModule_Factory(t) { return new (t || ResetButtonComponentModule)(); };
877
- ResetButtonComponentModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: ResetButtonComponentModule });
878
- ResetButtonComponentModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [MatIconModule,
879
- MatLegacyButtonModule] });
880
- (function () {
881
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ResetButtonComponentModule, [{
882
- type: NgModule,
883
- args: [{
884
- declarations: [ResetButtonComponent],
885
- imports: [
886
- MatIconModule,
887
- MatLegacyButtonModule
888
- ],
889
- exports: [ResetButtonComponent]
890
- }]
891
- }], null, null);
892
- })();
893
- (function () {
894
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(ResetButtonComponentModule, { declarations: [ResetButtonComponent], imports: [MatIconModule,
895
- MatLegacyButtonModule], exports: [ResetButtonComponent] });
896
- })();
897
-
898
- class AppsButtonComponentModule {
899
- }
900
- AppsButtonComponentModule.ɵfac = function AppsButtonComponentModule_Factory(t) { return new (t || AppsButtonComponentModule)(); };
901
- AppsButtonComponentModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: AppsButtonComponentModule });
902
- AppsButtonComponentModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [MatLegacyButtonModule,
903
- MatIconModule,
904
- MatGridListModule,
905
- OverlayModule,
906
- FlexLayoutModule,
907
- CommonModule,
908
- RouterModule] });
909
- (function () {
910
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(AppsButtonComponentModule, [{
911
- type: NgModule,
912
- args: [{
913
- declarations: [AppsButtonComponent],
914
- imports: [
915
- MatLegacyButtonModule,
916
- MatIconModule,
917
- MatGridListModule,
918
- OverlayModule,
919
- FlexLayoutModule,
920
- CommonModule,
921
- RouterModule
922
- ],
923
- exports: [AppsButtonComponent]
924
- }]
925
- }], null, null);
926
- })();
927
- (function () {
928
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(AppsButtonComponentModule, { declarations: [AppsButtonComponent], imports: [MatLegacyButtonModule,
929
- MatIconModule,
930
- MatGridListModule,
931
- OverlayModule,
932
- FlexLayoutModule,
933
- CommonModule,
934
- RouterModule], exports: [AppsButtonComponent] });
935
- })();
936
-
937
- class LanguageSelectorComponentModule {
938
- }
939
- LanguageSelectorComponentModule.ɵfac = function LanguageSelectorComponentModule_Factory(t) { return new (t || LanguageSelectorComponentModule)(); };
940
- LanguageSelectorComponentModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: LanguageSelectorComponentModule });
941
- LanguageSelectorComponentModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [MatLegacySelectModule,
942
- CommonModule,
943
- FormsModule] });
944
- (function () {
945
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LanguageSelectorComponentModule, [{
946
- type: NgModule,
947
- args: [{
948
- declarations: [LanguageSelectorComponent],
949
- imports: [
950
- MatLegacySelectModule,
951
- CommonModule,
952
- FormsModule
953
- ],
954
- exports: [LanguageSelectorComponent]
955
- }]
956
- }], null, null);
957
- })();
958
- (function () {
959
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(LanguageSelectorComponentModule, { declarations: [LanguageSelectorComponent], imports: [MatLegacySelectModule,
960
- CommonModule,
961
- FormsModule], exports: [LanguageSelectorComponent] });
962
- })();
963
-
964
- class HeaderModule {
965
- }
966
- HeaderModule.ɵfac = function HeaderModule_Factory(t) { return new (t || HeaderModule)(); };
967
- HeaderModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: HeaderModule });
968
- HeaderModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [MatToolbarModule,
969
- SignOutComponentModule,
970
- UserProfileIconComponentModule,
971
- NavigationProgressBarComponentModule,
972
- SidenavToggleButtonComponentModule,
973
- ResetButtonComponentModule,
974
- FlexLayoutModule,
975
- CommonModule,
976
- MatLegacyButtonModule,
977
- MatIconModule,
978
- MatLegacyMenuModule,
979
- AppsButtonComponentModule,
980
- LanguageSelectorComponentModule] });
981
- (function () {
982
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(HeaderModule, [{
983
- type: NgModule,
984
- args: [{
985
- declarations: [HeaderComponent],
986
- imports: [
987
- MatToolbarModule,
988
- SignOutComponentModule,
989
- UserProfileIconComponentModule,
990
- NavigationProgressBarComponentModule,
991
- SidenavToggleButtonComponentModule,
992
- ResetButtonComponentModule,
993
- FlexLayoutModule,
994
- CommonModule,
995
- MatLegacyButtonModule,
996
- MatIconModule,
997
- MatLegacyMenuModule,
998
- AppsButtonComponentModule,
999
- LanguageSelectorComponentModule
1000
- ],
1001
- exports: [HeaderComponent]
1002
- }]
1003
- }], null, null);
1004
- })();
1005
- (function () {
1006
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(HeaderModule, { declarations: [HeaderComponent], imports: [MatToolbarModule,
1007
- SignOutComponentModule,
1008
- UserProfileIconComponentModule,
1009
- NavigationProgressBarComponentModule,
1010
- SidenavToggleButtonComponentModule,
1011
- ResetButtonComponentModule,
1012
- FlexLayoutModule,
1013
- CommonModule,
1014
- MatLegacyButtonModule,
1015
- MatIconModule,
1016
- MatLegacyMenuModule,
1017
- AppsButtonComponentModule,
1018
- LanguageSelectorComponentModule], exports: [HeaderComponent] });
1019
- })();
1020
-
1021
- class LayoutComponentService {
1022
- constructor(footerComponentService, headerComponentService, logoConfig = null, config) {
1023
- this.footerComponentService = footerComponentService;
1024
- this.headerComponentService = headerComponentService;
1025
- this.config = config;
1026
- this.opened$ = new BehaviorSubject(true);
1027
- this.mode$ = new BehaviorSubject('side');
1028
- this.fixedTopGap$ = new BehaviorSubject(64);
1029
- this.mode$.next(this.config.get('navigation.mode', this.mode$.value));
1030
- this.opened$.next(this.config.get('navigation.open', this.opened$.value));
1031
- this.fixedBottomGap$ = this.footerComponentService.portalCount$.pipe(map(count => count * 64));
1032
- this.fixedTopGap$.next(this.headerComponentService.countComponent * 64);
1033
- this.headerComponentService.update$.pipe(tap(() => this.fixedTopGap$.next(this.headerComponentService.countComponent * 64))).subscribe();
1034
- this.logo = logoConfig !== null && logoConfig !== void 0 ? logoConfig : {
1035
- src: '/assets/logo.png',
1036
- width: '192'
1037
- };
1038
- }
1039
- }
1040
- LayoutComponentService.ɵfac = function LayoutComponentService_Factory(t) { return new (t || LayoutComponentService)(i0.ɵɵinject(i1.FooterService), i0.ɵɵinject(i1.HeaderService), i0.ɵɵinject(RXAP_LOGO_CONFIG, 8), i0.ɵɵinject(ConfigService)); };
1041
- LayoutComponentService.ɵprov = /*@__PURE__*/ i0.ɵɵdefineInjectable({ token: LayoutComponentService, factory: LayoutComponentService.ɵfac, providedIn: 'root' });
1042
- (function () {
1043
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LayoutComponentService, [{
1044
- type: Injectable,
1045
- args: [{ providedIn: 'root' }]
1046
- }], function () {
1047
- return [{ type: i1.FooterService }, { type: i1.HeaderService }, { type: undefined, decorators: [{
1048
- type: Optional
1049
- }, {
1050
- type: Inject,
1051
- args: [RXAP_LOGO_CONFIG]
1052
- }] }, { type: i1$5.ConfigService, decorators: [{
1053
- type: Inject,
1054
- args: [ConfigService]
1055
- }] }];
1056
- }, null);
1057
- })();
1058
-
1059
- class SidenavFooterDirective {
1060
- constructor(template) {
1061
- this.template = template;
1062
- }
1063
- }
1064
- SidenavFooterDirective.ɵfac = function SidenavFooterDirective_Factory(t) { return new (t || SidenavFooterDirective)(i0.ɵɵdirectiveInject(TemplateRef)); };
1065
- SidenavFooterDirective.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: SidenavFooterDirective, selectors: [["", "rxapSidenavFooter", ""]] });
1066
- (function () {
1067
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SidenavFooterDirective, [{
1068
- type: Directive,
1069
- args: [{
1070
- selector: '[rxapSidenavFooter]',
1071
- }]
1072
- }], function () {
1073
- return [{ type: i0.TemplateRef, decorators: [{
1074
- type: Inject,
1075
- args: [TemplateRef]
1076
- }] }];
1077
- }, null);
1078
- })();
1079
-
1080
- class SidenavHeaderDirective {
1081
- constructor(template) {
1082
- this.template = template;
1083
- }
1084
- }
1085
- SidenavHeaderDirective.ɵfac = function SidenavHeaderDirective_Factory(t) { return new (t || SidenavHeaderDirective)(i0.ɵɵdirectiveInject(TemplateRef)); };
1086
- SidenavHeaderDirective.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: SidenavHeaderDirective, selectors: [["", "rxapSidenavHeader", ""]] });
1087
- (function () {
1088
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SidenavHeaderDirective, [{
1089
- type: Directive,
1090
- args: [{
1091
- selector: '[rxapSidenavHeader]',
1092
- }]
1093
- }], function () {
1094
- return [{ type: i0.TemplateRef, decorators: [{
1095
- type: Inject,
1096
- args: [TemplateRef]
1097
- }] }];
1098
- }, null);
1099
- })();
1100
-
1101
- class SidenavComponentService {
1102
- constructor(config) {
1103
- this.config = config;
1104
- this.collapsed$ = new BehaviorSubject(true);
1105
- this.collapsed$.next(this.config.get('navigation.collapsed', this.collapsed$.value));
1106
- }
1107
- toggleNavigationCollapse() {
1108
- this.collapsed$.next(!this.collapsed$.value);
1109
- }
1110
- }
1111
- SidenavComponentService.ɵfac = function SidenavComponentService_Factory(t) { return new (t || SidenavComponentService)(i0.ɵɵinject(i1$5.ConfigService)); };
1112
- SidenavComponentService.ɵprov = /*@__PURE__*/ i0.ɵɵdefineInjectable({ token: SidenavComponentService, factory: SidenavComponentService.ɵfac, providedIn: 'root' });
1113
- (function () {
1114
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SidenavComponentService, [{
1115
- type: Injectable,
1116
- args: [{ providedIn: 'root' }]
1117
- }], function () { return [{ type: i1$5.ConfigService }]; }, null);
1118
- })();
1119
-
1120
- function IsNavigationDividerItem(item) {
1121
- return item && item.hasOwnProperty('divider') && item.divider;
1122
- }
1123
- function IsNavigationInsertItem(item) {
1124
- return item && item.hasOwnProperty('insert');
1125
- }
1126
- function IsNavigationItem(item) {
1127
- return (item && item.hasOwnProperty('routerLink') && item.hasOwnProperty('label'));
1128
- }
1129
-
1130
- class NavigationService {
1131
- constructor(navigation, injector, inserts = null) {
1132
- this.injector = injector;
1133
- this.inserts = new Map();
1134
- this.navigation$ = new ReplaySubject(1);
1135
- if (typeof navigation === 'function') {
1136
- this.navigation = navigation();
1137
- }
1138
- else {
1139
- this.navigation = navigation;
1140
- }
1141
- if (inserts) {
1142
- Object.entries(inserts).forEach(([id, insert]) => this.insert(id, insert, false));
1143
- }
1144
- this.updateNavigation();
1145
- this.config$ = this.navigation$.pipe(switchMap((navigationWithoutStatusCheck) => this.checkNavigationStatusProviders(navigationWithoutStatusCheck)));
1146
- }
1147
- /**
1148
- * @deprecated use add instead
1149
- * @param id
1150
- * @param value
1151
- * @param update
1152
- */
1153
- insert(id, value, update = true) {
1154
- this.add(id, value, update);
1155
- }
1156
- add(id, value, update = true) {
1157
- this.inserts.set(id, value);
1158
- if (update) {
1159
- this.updateNavigation();
1160
- }
1161
- }
1162
- has(id) {
1163
- return this.inserts.has(id);
1164
- }
1165
- get(id) {
1166
- return this.inserts.get(id);
1167
- }
1168
- remove(id, update = true) {
1169
- this.inserts.delete(id);
1170
- if (update) {
1171
- this.updateNavigation();
1172
- }
1173
- }
1174
- updateNavigation() {
1175
- this.navigation$.next(this.replaceInserts(this.navigation));
1176
- }
1177
- /**
1178
- * @internal
1179
- * @param navigationItem
1180
- */
1181
- checkNavigationItemStatusProviders(navigationItem) {
1182
- if (IsNavigationDividerItem(navigationItem) || !navigationItem.status) {
1183
- return of(navigationItem);
1184
- }
1185
- const isVisibleArray$ = navigationItem.status
1186
- .map((statusToken) => this.injector.get(statusToken))
1187
- .map((status) => {
1188
- const isVisible = status.isVisible(navigationItem);
1189
- if (typeof isVisible === 'boolean') {
1190
- return of(isVisible);
1191
- }
1192
- else {
1193
- return from(isVisible);
1194
- }
1195
- }).map(isVisible$ => isVisible$.pipe(catchError(e => {
1196
- console.error('isVisible method failed: ' + e.message);
1197
- return of(false);
1198
- })));
1199
- // TODO : dont wait for all status services to complete, but cancel waiting if one returns false
1200
- return combineLatest(isVisibleArray$).pipe(map((isVisibleArray) => isVisibleArray.reduce((acc, isVisible) => acc && isVisible, true)), map((isVisible) => (isVisible ? navigationItem : null)), switchMap((navigationItemOrNull) => {
1201
- var _a;
1202
- if (navigationItemOrNull) {
1203
- if ((_a = navigationItemOrNull.children) === null || _a === void 0 ? void 0 : _a.length) {
1204
- return this.checkNavigationStatusProviders(navigationItemOrNull.children).pipe(map((children) => (Object.assign(Object.assign({}, navigationItemOrNull), { children }))));
1205
- }
1206
- return of(navigationItemOrNull);
1207
- }
1208
- return of(null);
1209
- }));
1210
- }
1211
- /**
1212
- * @internal
1213
- * @param navigationItem
1214
- */
1215
- checkNavigationStatusProviders(navigation) {
1216
- return combineLatest(navigation.map((navigationItem) => this.checkNavigationItemStatusProviders(navigationItem))).pipe(map((navigationWithNullItems) => {
1217
- const cleanNavigation = [];
1218
- for (const navigationItem of navigationWithNullItems) {
1219
- if (navigationItem !== null) {
1220
- cleanNavigation.push(navigationItem);
1221
- }
1222
- }
1223
- return cleanNavigation;
1224
- }));
1225
- }
1226
- replaceInserts(navigationWithInserts) {
1227
- var _a;
1228
- const navigation = [];
1229
- for (const navigationItem of navigationWithInserts) {
1230
- if (IsNavigationInsertItem(navigationItem)) {
1231
- if (this.inserts.has(navigationItem.insert)) {
1232
- navigation.push(...this.replaceInserts(this.inserts.get(navigationItem.insert)));
1233
- }
1234
- }
1235
- else if (IsNavigationItem(navigationItem)) {
1236
- navigation.push(Object.assign(Object.assign({}, navigationItem), { children: this.replaceInserts((_a = navigationItem.children) !== null && _a !== void 0 ? _a : []) }));
1237
- }
1238
- else if (IsNavigationDividerItem(navigationItem)) {
1239
- navigation.push(navigationItem);
1240
- }
1241
- }
1242
- return navigation;
1243
- }
1244
- }
1245
- NavigationService.ɵfac = function NavigationService_Factory(t) { return new (t || NavigationService)(i0.ɵɵinject(RXAP_NAVIGATION_CONFIG), i0.ɵɵinject(INJECTOR), i0.ɵɵinject(RXAP_NAVIGATION_CONFIG_INSERTS, 8)); };
1246
- NavigationService.ɵprov = /*@__PURE__*/ i0.ɵɵdefineInjectable({ token: NavigationService, factory: NavigationService.ɵfac, providedIn: 'root' });
1247
- (function () {
1248
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(NavigationService, [{
1249
- type: Injectable,
1250
- args: [{ providedIn: 'root' }]
1251
- }], function () {
1252
- return [{ type: undefined, decorators: [{
1253
- type: Inject,
1254
- args: [RXAP_NAVIGATION_CONFIG]
1255
- }] }, { type: undefined, decorators: [{
1256
- type: Inject,
1257
- args: [INJECTOR]
1258
- }] }, { type: undefined, decorators: [{
1259
- type: Optional
1260
- }, {
1261
- type: Inject,
1262
- args: [RXAP_NAVIGATION_CONFIG_INSERTS]
1263
- }] }];
1264
- }, null);
1265
- })();
1266
-
1267
- const _c0$3 = ["navigationOverlay"];
1268
- const _c1$2 = ["rxap-navigation-item", ""];
1269
- function NavigationItemComponent_mat_icon_2_Template(rf, ctx) {
1270
- if (rf & 1) {
1271
- i0.ɵɵelement(0, "mat-icon", 5);
1272
- }
1273
- if (rf & 2) {
1274
- const ctx_r0 = i0.ɵɵnextContext();
1275
- i0.ɵɵproperty("rxapIcon", ctx_r0.item.icon);
1276
- }
1277
- }
1278
- function NavigationItemComponent_ng_template_3_Template(rf, ctx) {
1279
- if (rf & 1) {
1280
- i0.ɵɵelementStart(0, "span", 6);
1281
- i0.ɵɵtext(1);
1282
- i0.ɵɵelementEnd();
1283
- }
1284
- if (rf & 2) {
1285
- const ctx_r1 = i0.ɵɵnextContext();
1286
- i0.ɵɵadvance(1);
1287
- i0.ɵɵtextInterpolate(ctx_r1.item.label);
1288
- }
1289
- }
1290
- function NavigationItemComponent_ul_5_Template(rf, ctx) {
1291
- if (rf & 1) {
1292
- i0.ɵɵelement(0, "ul", 7);
1293
- }
1294
- if (rf & 2) {
1295
- const ctx_r2 = i0.ɵɵnextContext();
1296
- i0.ɵɵproperty("@sub-nav", undefined)("items", ctx_r2.children)("level", ctx_r2.level + 1);
1297
- }
1298
- }
1299
- function NavigationItemComponent_ng_template_7_li_2_a_1_mat_icon_1_Template(rf, ctx) {
1300
- if (rf & 1) {
1301
- i0.ɵɵelement(0, "mat-icon", 5);
1302
- }
1303
- if (rf & 2) {
1304
- const child_r6 = i0.ɵɵnextContext(2).$implicit;
1305
- const ctx_r8 = i0.ɵɵnextContext(2);
1306
- i0.ɵɵproperty("rxapIcon", ctx_r8.asNavigationItem(child_r6).icon);
1307
- }
1308
- }
1309
- function NavigationItemComponent_ng_template_7_li_2_a_1_Template(rf, ctx) {
1310
- if (rf & 1) {
1311
- i0.ɵɵelementStart(0, "a", 11);
1312
- i0.ɵɵtemplate(1, NavigationItemComponent_ng_template_7_li_2_a_1_mat_icon_1_Template, 1, 1, "mat-icon", 1);
1313
- i0.ɵɵelementStart(2, "span", 6);
1314
- i0.ɵɵtext(3);
1315
- i0.ɵɵelementEnd()();
1316
- }
1317
- if (rf & 2) {
1318
- const child_r6 = i0.ɵɵnextContext().$implicit;
1319
- const ctx_r7 = i0.ɵɵnextContext(2);
1320
- i0.ɵɵproperty("routerLink", ctx_r7.asNavigationItem(child_r6).routerLink);
1321
- i0.ɵɵadvance(1);
1322
- i0.ɵɵproperty("ngIf", ctx_r7.asNavigationItem(child_r6).icon);
1323
- i0.ɵɵadvance(2);
1324
- i0.ɵɵtextInterpolate(ctx_r7.asNavigationItem(child_r6).label);
1325
- }
1326
- }
1327
- function NavigationItemComponent_ng_template_7_li_2_Template(rf, ctx) {
1328
- if (rf & 1) {
1329
- i0.ɵɵelementStart(0, "li");
1330
- i0.ɵɵtemplate(1, NavigationItemComponent_ng_template_7_li_2_a_1_Template, 4, 3, "a", 10);
1331
- i0.ɵɵelementEnd();
1332
- }
1333
- if (rf & 2) {
1334
- const child_r6 = ctx.$implicit;
1335
- const ctx_r5 = i0.ɵɵnextContext(2);
1336
- i0.ɵɵadvance(1);
1337
- i0.ɵɵproperty("ngIf", ctx_r5.isNavigationItem(child_r6));
1338
- }
1339
- }
1340
- function NavigationItemComponent_ng_template_7_Template(rf, ctx) {
1341
- if (rf & 1) {
1342
- const _r12 = i0.ɵɵgetCurrentView();
1343
- i0.ɵɵelementStart(0, "div", 8);
1344
- i0.ɵɵlistener("mouseenter", function NavigationItemComponent_ng_template_7_Template_div_mouseenter_0_listener() { i0.ɵɵrestoreView(_r12); const ctx_r11 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r11.lockeOverlay = true); })("mouseleave", function NavigationItemComponent_ng_template_7_Template_div_mouseleave_0_listener() { i0.ɵɵrestoreView(_r12); const ctx_r13 = i0.ɵɵnextContext(); ctx_r13.lockeOverlay = false; return i0.ɵɵresetView(ctx_r13.onMouseleave()); });
1345
- i0.ɵɵelementStart(1, "ul");
1346
- i0.ɵɵtemplate(2, NavigationItemComponent_ng_template_7_li_2_Template, 2, 1, "li", 9);
1347
- i0.ɵɵelementEnd()();
1348
- }
1349
- if (rf & 2) {
1350
- const ctx_r4 = i0.ɵɵnextContext();
1351
- i0.ɵɵadvance(2);
1352
- i0.ɵɵproperty("ngForOf", ctx_r4.children);
1353
- }
1354
- }
1355
- class NavigationItemComponent {
1356
- constructor(router, sidenav, elementRef, renderer, overlay, viewContainerRef) {
1357
- this.router = router;
1358
- this.sidenav = sidenav;
1359
- this.elementRef = elementRef;
1360
- this.renderer = renderer;
1361
- this.overlay = overlay;
1362
- this.viewContainerRef = viewContainerRef;
1363
- this.children = null;
1364
- this.level = 0;
1365
- this.isActive = false;
1366
- this._subscription = new Subscription();
1367
- /**
1368
- * indicates the mouse is over the
1369
- */
1370
- this.lockeOverlay = false;
1371
- }
1372
- ngOnChanges(changes) {
1373
- if (changes.item) {
1374
- const item = changes.item.currentValue;
1375
- this.children =
1376
- item.children && item.children.length ? item.children : null;
1377
- }
1378
- }
1379
- ngAfterViewInit() {
1380
- this._subscription.add(this.router.events
1381
- .pipe(filter((event) => event instanceof NavigationEnd), startWith(true), delay(100), tap(() => {
1382
- var _a;
1383
- if (this.routerLinkActive.isActive) {
1384
- if (!this.sidenav.collapsed$.value) {
1385
- // only close the overlay if sidenav collapsed
1386
- (_a = this._overlayRef) === null || _a === void 0 ? void 0 : _a.detach();
1387
- }
1388
- this.renderer.addClass(this.elementRef.nativeElement, 'active');
1389
- }
1390
- else {
1391
- this.renderer.removeClass(this.elementRef.nativeElement, 'active');
1392
- }
1393
- }))
1394
- .subscribe());
1395
- }
1396
- ngOnInit() {
1397
- // detach the navigation overlay if the sidenav collapsed
1398
- // state is changed
1399
- this._subscription.add(this.sidenav.collapsed$
1400
- .pipe(skip(1), distinctUntilChanged(), tap(() => { var _a; return (_a = this._overlayRef) === null || _a === void 0 ? void 0 : _a.detach(); }))
1401
- .subscribe());
1402
- }
1403
- ngOnDestroy() {
1404
- var _a, _b;
1405
- (_a = this._subscription) === null || _a === void 0 ? void 0 : _a.unsubscribe();
1406
- (_b = this._overlayRef) === null || _b === void 0 ? void 0 : _b.dispose();
1407
- }
1408
- onMouseenter() {
1409
- if (this.children) {
1410
- if (!this.routerLinkActive.isActive || this.sidenav.collapsed$.value) {
1411
- if (!this._overlayRef) {
1412
- this._overlayRef = this.overlay.create({
1413
- positionStrategy: this.overlay
1414
- .position()
1415
- .flexibleConnectedTo(this.elementRef)
1416
- .withPositions([
1417
- {
1418
- originY: 'top',
1419
- originX: 'end',
1420
- overlayY: 'top',
1421
- overlayX: 'start',
1422
- },
1423
- ]),
1424
- });
1425
- }
1426
- if (!this._overlayRef.hasAttached()) {
1427
- this._embeddedViewRef = this._overlayRef.attach(new TemplatePortal(this._navigationOverlay, this.viewContainerRef));
1428
- }
1429
- }
1430
- }
1431
- }
1432
- onMouseleave() {
1433
- var _a;
1434
- if (!this.lockeOverlay) {
1435
- (_a = this._overlayRef) === null || _a === void 0 ? void 0 : _a.detach();
1436
- }
1437
- }
1438
- // region type save item property
1439
- // required to check the type of the item property in the ngFor loop
1440
- isNavigationDividerItem(item) {
1441
- return item['divider'];
1442
- }
1443
- isNavigationItem(item) {
1444
- return !this.isNavigationDividerItem(item);
1445
- }
1446
- asNavigationItem(item) {
1447
- if (!this.isNavigationItem(item)) {
1448
- throw new Error('The item is not a NavigationItem');
1449
- }
1450
- return item;
1451
- }
1452
- }
1453
- NavigationItemComponent.ɵfac = function NavigationItemComponent_Factory(t) { return new (t || NavigationItemComponent)(i0.ɵɵdirectiveInject(Router), i0.ɵɵdirectiveInject(SidenavComponentService), i0.ɵɵdirectiveInject(ElementRef), i0.ɵɵdirectiveInject(Renderer2), i0.ɵɵdirectiveInject(Overlay), i0.ɵɵdirectiveInject(ViewContainerRef)); };
1454
- NavigationItemComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: NavigationItemComponent, selectors: [["li", "rxap-navigation-item", ""]], viewQuery: function NavigationItemComponent_Query(rf, ctx) {
1455
- if (rf & 1) {
1456
- i0.ɵɵviewQuery(RouterLinkActive, 7);
1457
- i0.ɵɵviewQuery(_c0$3, 5);
1458
- }
1459
- if (rf & 2) {
1460
- let _t;
1461
- i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.routerLinkActive = _t.first);
1462
- i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx._navigationOverlay = _t.first);
1463
- }
1464
- }, hostAttrs: [1, "rxap-navigation-item"], hostVars: 2, hostBindings: function NavigationItemComponent_HostBindings(rf, ctx) {
1465
- if (rf & 1) {
1466
- i0.ɵɵlistener("mouseenter", function NavigationItemComponent_mouseenter_HostBindingHandler() { return ctx.onMouseenter(); })("mouseleave", function NavigationItemComponent_mouseleave_HostBindingHandler() { return ctx.onMouseleave(); });
1467
- }
1468
- if (rf & 2) {
1469
- i0.ɵɵclassProp("active", ctx.isActive);
1470
- }
1471
- }, inputs: { item: "item", level: "level" }, features: [i0.ɵɵNgOnChangesFeature], attrs: _c1$2, decls: 9, vars: 15, consts: [["routerLinkActive", "link-active", "matRipple", "", 3, "routerLink", "matTooltipDisabled", "matTooltip"], ["class", "icon", 3, "rxapIcon", 4, "ngIf"], [3, "ngIf"], ["rxap-navigation", "", "class", "sub-items", "fxFlex", "nogrow", 3, "items", "level", 4, "ngIf"], ["navigationOverlay", ""], [1, "icon", 3, "rxapIcon"], [1, "label"], ["rxap-navigation", "", "fxFlex", "nogrow", 1, "sub-items", 3, "items", "level"], [1, "navigation-overlay-container", "mat-elevation-z1", 3, "mouseenter", "mouseleave"], [4, "ngFor", "ngForOf"], ["class", "navigation-link mat-body-2 mat-body-strong", "matRipple", "", 3, "routerLink", 4, "ngIf"], ["matRipple", "", 1, "navigation-link", "mat-body-2", "mat-body-strong", 3, "routerLink"]], template: function NavigationItemComponent_Template(rf, ctx) {
1472
- if (rf & 1) {
1473
- i0.ɵɵelementStart(0, "a", 0);
1474
- i0.ɵɵpipe(1, "async");
1475
- i0.ɵɵtemplate(2, NavigationItemComponent_mat_icon_2_Template, 1, 1, "mat-icon", 1);
1476
- i0.ɵɵtemplate(3, NavigationItemComponent_ng_template_3_Template, 2, 1, "ng-template", 2);
1477
- i0.ɵɵpipe(4, "async");
1478
- i0.ɵɵelementEnd();
1479
- i0.ɵɵtemplate(5, NavigationItemComponent_ul_5_Template, 1, 3, "ul", 3);
1480
- i0.ɵɵpipe(6, "async");
1481
- i0.ɵɵtemplate(7, NavigationItemComponent_ng_template_7_Template, 3, 1, "ng-template", null, 4, i0.ɵɵtemplateRefExtractor);
1482
- }
1483
- if (rf & 2) {
1484
- i0.ɵɵclassMapInterpolate1("navigation-link mat-body-2 mat-body-strong navigation-level-", ctx.level, "");
1485
- i0.ɵɵproperty("routerLink", ctx.item.routerLink)("matTooltipDisabled", !i0.ɵɵpipeBind1(1, 9, ctx.sidenav.collapsed$))("matTooltip", ctx.item.label);
1486
- i0.ɵɵadvance(2);
1487
- i0.ɵɵproperty("ngIf", ctx.item.icon);
1488
- i0.ɵɵadvance(1);
1489
- i0.ɵɵproperty("ngIf", !i0.ɵɵpipeBind1(4, 11, ctx.sidenav.collapsed$));
1490
- i0.ɵɵadvance(2);
1491
- i0.ɵɵproperty("ngIf", ctx.routerLinkActive.isActive && !i0.ɵɵpipeBind1(6, 13, ctx.sidenav.collapsed$) && ctx.children);
1492
- }
1493
- }, styles: [".rxap-navigation-item,.navigation-overlay-container{display:flex;flex-direction:column;min-height:48px}.rxap-navigation-item .navigation-link,.navigation-overlay-container .navigation-link{display:flex;flex-direction:row;align-items:center;text-decoration:none;height:48px}.rxap-navigation-item .navigation-link .icon,.navigation-overlay-container .navigation-link .icon{margin:0 16px}.rxap-navigation-item .navigation-link .label,.navigation-overlay-container .navigation-link .label{padding-right:12px}.rxap-navigation-item .navigation-link.navigation-level-1,.navigation-overlay-container .navigation-link.navigation-level-1{padding-left:52px}.rxap-navigation-item .navigation-link.navigation-level-1 .icon,.navigation-overlay-container .navigation-link.navigation-level-1 .icon{padding-left:0}.rxap-navigation-item .navigation-link.navigation-level-2,.navigation-overlay-container .navigation-link.navigation-level-2{padding-left:88px}.rxap-navigation-item .navigation-link.navigation-level-2 .icon,.navigation-overlay-container .navigation-link.navigation-level-2 .icon{padding-left:0}.navigation-overlay-container{padding:0 16px}.navigation-overlay-container ul{list-style-type:none;margin:0;padding:0}.navigation-overlay-container ul .navigation-link .label{padding-right:0}.navigation-overlay-container ul .navigation-link .icon{margin-left:0}\n"], encapsulation: 2, data: { animation: [
1494
- trigger('sub-nav', [
1495
- transition(':enter', [
1496
- style({ display: 'block', height: '0', overflow: 'hidden' }),
1497
- animate(150, style({ height: '*' })),
1498
- ]),
1499
- transition(':leave', [
1500
- style({ overflow: 'hidden' }),
1501
- animate(300, style({ height: '0' })),
1502
- style({ display: 'none' }),
1503
- ]),
1504
- ]),
1505
- ] }, changeDetection: 0 });
1506
- __decorate([
1507
- Required,
1508
- __metadata("design:type", Object)
1509
- ], NavigationItemComponent.prototype, "item", void 0);
1510
- __decorate([
1511
- DebounceCall(100),
1512
- __metadata("design:type", Function),
1513
- __metadata("design:paramtypes", []),
1514
- __metadata("design:returntype", void 0)
1515
- ], NavigationItemComponent.prototype, "onMouseleave", null);
1516
- (function () {
1517
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(NavigationItemComponent, [{
1518
- type: Component,
1519
- args: [{ selector: 'li[rxap-navigation-item]', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: {
1520
- class: 'rxap-navigation-item',
1521
- }, animations: [
1522
- trigger('sub-nav', [
1523
- transition(':enter', [
1524
- style({ display: 'block', height: '0', overflow: 'hidden' }),
1525
- animate(150, style({ height: '*' })),
1526
- ]),
1527
- transition(':leave', [
1528
- style({ overflow: 'hidden' }),
1529
- animate(300, style({ height: '0' })),
1530
- style({ display: 'none' }),
1531
- ]),
1532
- ]),
1533
- ], template: "<a [routerLink]=\"item.routerLink\"\n routerLinkActive=\"link-active\"\n [matTooltipDisabled]=\"!(sidenav.collapsed$ | async)\"\n [matTooltip]=\"item.label\"\n class=\"navigation-link mat-body-2 mat-body-strong navigation-level-{{level}}\" matRipple>\n <mat-icon *ngIf=\"item.icon\" [rxapIcon]=\"item.icon\" class=\"icon\"></mat-icon>\n <ng-template [ngIf]=\"!(sidenav.collapsed$ | async)\">\n <span class=\"label\">{{ item.label }}</span>\n </ng-template>\n</a>\n\n<ul rxap-navigation\n *ngIf=\"routerLinkActive.isActive && !(sidenav.collapsed$ | async) && children\"\n [@sub-nav]\n [items]=\"children\"\n [level]=\"level + 1\"\n class=\"sub-items\"\n fxFlex=\"nogrow\"\n>\n</ul>\n\n<ng-template #navigationOverlay>\n <div class=\"navigation-overlay-container mat-elevation-z1\"\n (mouseenter)=\"lockeOverlay = true\" (mouseleave)=\"lockeOverlay = false; onMouseleave()\">\n <ul>\n <li *ngFor=\"let child of children\">\n <a *ngIf=\"isNavigationItem(child)\" [routerLink]=\"asNavigationItem(child).routerLink\"\n class=\"navigation-link mat-body-2 mat-body-strong\" matRipple>\n <mat-icon *ngIf=\"asNavigationItem(child).icon\" [rxapIcon]=\"asNavigationItem(child).icon\" class=\"icon\"></mat-icon>\n <span class=\"label\">{{ asNavigationItem(child).label }}</span>\n </a>\n </li>\n </ul>\n </div>\n</ng-template>\n", styles: [".rxap-navigation-item,.navigation-overlay-container{display:flex;flex-direction:column;min-height:48px}.rxap-navigation-item .navigation-link,.navigation-overlay-container .navigation-link{display:flex;flex-direction:row;align-items:center;text-decoration:none;height:48px}.rxap-navigation-item .navigation-link .icon,.navigation-overlay-container .navigation-link .icon{margin:0 16px}.rxap-navigation-item .navigation-link .label,.navigation-overlay-container .navigation-link .label{padding-right:12px}.rxap-navigation-item .navigation-link.navigation-level-1,.navigation-overlay-container .navigation-link.navigation-level-1{padding-left:52px}.rxap-navigation-item .navigation-link.navigation-level-1 .icon,.navigation-overlay-container .navigation-link.navigation-level-1 .icon{padding-left:0}.rxap-navigation-item .navigation-link.navigation-level-2,.navigation-overlay-container .navigation-link.navigation-level-2{padding-left:88px}.rxap-navigation-item .navigation-link.navigation-level-2 .icon,.navigation-overlay-container .navigation-link.navigation-level-2 .icon{padding-left:0}.navigation-overlay-container{padding:0 16px}.navigation-overlay-container ul{list-style-type:none;margin:0;padding:0}.navigation-overlay-container ul .navigation-link .label{padding-right:0}.navigation-overlay-container ul .navigation-link .icon{margin-left:0}\n"] }]
1534
- }], function () {
1535
- return [{ type: i3$1.Router, decorators: [{
1536
- type: Inject,
1537
- args: [Router]
1538
- }] }, { type: SidenavComponentService, decorators: [{
1539
- type: Inject,
1540
- args: [SidenavComponentService]
1541
- }] }, { type: i0.ElementRef, decorators: [{
1542
- type: Inject,
1543
- args: [ElementRef]
1544
- }] }, { type: i0.Renderer2, decorators: [{
1545
- type: Inject,
1546
- args: [Renderer2]
1547
- }] }, { type: i3$2.Overlay, decorators: [{
1548
- type: Inject,
1549
- args: [Overlay]
1550
- }] }, { type: i0.ViewContainerRef, decorators: [{
1551
- type: Inject,
1552
- args: [ViewContainerRef]
1553
- }] }];
1554
- }, { routerLinkActive: [{
1555
- type: ViewChild,
1556
- args: [RouterLinkActive, { static: true }]
1557
- }], item: [{
1558
- type: Input
1559
- }], level: [{
1560
- type: Input
1561
- }], isActive: [{
1562
- type: HostBinding,
1563
- args: ['class.active']
1564
- }], _navigationOverlay: [{
1565
- type: ViewChild,
1566
- args: ['navigationOverlay']
1567
- }], onMouseenter: [{
1568
- type: HostListener,
1569
- args: ['mouseenter']
1570
- }], onMouseleave: [{
1571
- type: HostListener,
1572
- args: ['mouseleave']
1573
- }] });
1574
- })();
1575
-
1576
- const _c0$2 = ["rxap-navigation", ""];
1577
- function NavigationComponent_ng_template_0_ng_template_0_div_1_span_1_Template(rf, ctx) {
1578
- if (rf & 1) {
1579
- i0.ɵɵelementStart(0, "span", 2);
1580
- i0.ɵɵtext(1);
1581
- i0.ɵɵelementEnd();
1582
- }
1583
- if (rf & 2) {
1584
- const item_r1 = i0.ɵɵnextContext(3).$implicit;
1585
- i0.ɵɵadvance(1);
1586
- i0.ɵɵtextInterpolate(item_r1.title);
1587
- }
1588
- }
1589
- function NavigationComponent_ng_template_0_ng_template_0_div_1_Template(rf, ctx) {
1590
- if (rf & 1) {
1591
- i0.ɵɵelementStart(0, "div", 4);
1592
- i0.ɵɵtemplate(1, NavigationComponent_ng_template_0_ng_template_0_div_1_span_1_Template, 2, 1, "span", 5);
1593
- i0.ɵɵelementEnd();
1594
- }
1595
- if (rf & 2) {
1596
- const item_r1 = i0.ɵɵnextContext(2).$implicit;
1597
- i0.ɵɵadvance(1);
1598
- i0.ɵɵproperty("ngIf", item_r1.title);
1599
- }
1600
- }
1601
- function NavigationComponent_ng_template_0_ng_template_0_Template(rf, ctx) {
1602
- if (rf & 1) {
1603
- i0.ɵɵelement(0, "mat-divider", 2);
1604
- i0.ɵɵtemplate(1, NavigationComponent_ng_template_0_ng_template_0_div_1_Template, 2, 1, "div", 3);
1605
- i0.ɵɵpipe(2, "async");
1606
- }
1607
- if (rf & 2) {
1608
- const ctx_r2 = i0.ɵɵnextContext(2);
1609
- i0.ɵɵadvance(1);
1610
- i0.ɵɵproperty("ngIf", !i0.ɵɵpipeBind1(2, 1, ctx_r2.sidenav.collapsed$));
1611
- }
1612
- }
1613
- function NavigationComponent_ng_template_0_ng_template_1_Template(rf, ctx) {
1614
- if (rf & 1) {
1615
- i0.ɵɵelement(0, "li", 6);
1616
- }
1617
- if (rf & 2) {
1618
- const item_r1 = i0.ɵɵnextContext().$implicit;
1619
- const ctx_r3 = i0.ɵɵnextContext();
1620
- i0.ɵɵproperty("level", ctx_r3.level)("item", ctx_r3.asNavigationItem(item_r1));
1621
- }
1622
- }
1623
- function NavigationComponent_ng_template_0_Template(rf, ctx) {
1624
- if (rf & 1) {
1625
- i0.ɵɵtemplate(0, NavigationComponent_ng_template_0_ng_template_0_Template, 3, 3, "ng-template", 1);
1626
- i0.ɵɵtemplate(1, NavigationComponent_ng_template_0_ng_template_1_Template, 1, 2, "ng-template", 1);
1627
- }
1628
- if (rf & 2) {
1629
- const item_r1 = ctx.$implicit;
1630
- const ctx_r0 = i0.ɵɵnextContext();
1631
- i0.ɵɵproperty("ngIf", ctx_r0.isNavigationDividerItem(item_r1));
1632
- i0.ɵɵadvance(1);
1633
- i0.ɵɵproperty("ngIf", ctx_r0.isNavigationItem(item_r1));
1634
- }
1635
- }
1636
- class NavigationComponent {
1637
- constructor(navigationService, cdr, sidenav) {
1638
- this.navigationService = navigationService;
1639
- this.cdr = cdr;
1640
- this.sidenav = sidenav;
1641
- this._root = false;
1642
- this.level = 0;
1643
- }
1644
- set root(value) {
1645
- this._root = coerceBoolean(value);
1646
- }
1647
- ngOnInit() {
1648
- if (this._root) {
1649
- this.items = [];
1650
- this.subscription = this.navigationService.config$
1651
- .pipe(tap((navigation) => (this.items = navigation)), tap(() => this.cdr.detectChanges()))
1652
- .subscribe();
1653
- }
1654
- }
1655
- ngOnDestroy() {
1656
- var _a;
1657
- (_a = this.subscription) === null || _a === void 0 ? void 0 : _a.unsubscribe();
1658
- }
1659
- // region type save item property
1660
- // required to check the type of the item property in the ngFor loop
1661
- isNavigationDividerItem(item) {
1662
- return item['divider'];
1663
- }
1664
- isNavigationItem(item) {
1665
- return !this.isNavigationDividerItem(item);
1666
- }
1667
- asNavigationItem(item) {
1668
- if (!this.isNavigationItem(item)) {
1669
- throw new Error('The item is not a NavigationItem');
1670
- }
1671
- return item;
1672
- }
1673
- }
1674
- NavigationComponent.ɵfac = function NavigationComponent_Factory(t) { return new (t || NavigationComponent)(i0.ɵɵdirectiveInject(NavigationService), i0.ɵɵdirectiveInject(ChangeDetectorRef), i0.ɵɵdirectiveInject(SidenavComponentService)); };
1675
- NavigationComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: NavigationComponent, selectors: [["ul", "rxap-navigation", ""]], hostAttrs: [1, "rxap-navigation"], hostVars: 2, hostBindings: function NavigationComponent_HostBindings(rf, ctx) {
1676
- if (rf & 2) {
1677
- i0.ɵɵclassProp("rxap-root-navigation", ctx._root);
1678
- }
1679
- }, inputs: { root: "root", items: "items", level: "level" }, attrs: _c0$2, decls: 1, vars: 1, consts: [["ngFor", "", 3, "ngForOf"], [3, "ngIf"], ["fxFlex", "nogrow"], ["class", "divider-title", "fxFlex", "nogrow", "fxLayout", "row", "fxLayoutAlign", "start end", 4, "ngIf"], ["fxFlex", "nogrow", "fxLayout", "row", "fxLayoutAlign", "start end", 1, "divider-title"], ["fxFlex", "nogrow", 4, "ngIf"], ["rxap-navigation-item", "", 1, "item", 3, "level", "item"]], template: function NavigationComponent_Template(rf, ctx) {
1680
- if (rf & 1) {
1681
- i0.ɵɵtemplate(0, NavigationComponent_ng_template_0_Template, 2, 2, "ng-template", 0);
1682
- }
1683
- if (rf & 2) {
1684
- i0.ɵɵproperty("ngForOf", ctx.items);
1685
- }
1686
- }, dependencies: [i1$3.DefaultLayoutDirective, i1$3.DefaultLayoutAlignDirective, i1$3.DefaultFlexDirective, i2$1.NgForOf, i2$1.NgIf, i3$4.MatDivider, NavigationItemComponent, i2$1.AsyncPipe], styles: [".rxap-navigation{list-style-type:none;padding:0}.rxap-navigation .divider-title{padding-left:18px;height:28px;align-content:center}\n"], encapsulation: 2, changeDetection: 0 });
1687
- __decorate([
1688
- Required,
1689
- __metadata("design:type", Array)
1690
- ], NavigationComponent.prototype, "items", void 0);
1691
- (function () {
1692
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(NavigationComponent, [{
1693
- type: Component,
1694
- args: [{ selector: 'ul[rxap-navigation]', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: { class: 'rxap-navigation' }, template: "<ng-template [ngForOf]=\"items\" let-item ngFor>\n <ng-template [ngIf]=\"isNavigationDividerItem(item)\">\n <mat-divider fxFlex=\"nogrow\"></mat-divider>\n <div *ngIf=\"!(sidenav.collapsed$ | async)\" class=\"divider-title\" fxFlex=\"nogrow\" fxLayout=\"row\" fxLayoutAlign=\"start end\">\n <span fxFlex=\"nogrow\" *ngIf=\"item.title\">{{item.title}}</span>\n </div>\n </ng-template>\n <ng-template [ngIf]=\"isNavigationItem(item)\">\n <li class=\"item\" rxap-navigation-item [level]=\"level\" [item]=\"asNavigationItem(item)\"></li>\n </ng-template>\n</ng-template>\n", styles: [".rxap-navigation{list-style-type:none;padding:0}.rxap-navigation .divider-title{padding-left:18px;height:28px;align-content:center}\n"] }]
1695
- }], function () {
1696
- return [{ type: NavigationService, decorators: [{
1697
- type: Inject,
1698
- args: [NavigationService]
1699
- }] }, { type: i0.ChangeDetectorRef, decorators: [{
1700
- type: Inject,
1701
- args: [ChangeDetectorRef]
1702
- }] }, { type: SidenavComponentService, decorators: [{
1703
- type: Inject,
1704
- args: [SidenavComponentService]
1705
- }] }];
1706
- }, { _root: [{
1707
- type: HostBinding,
1708
- args: ['class.rxap-root-navigation']
1709
- }], root: [{
1710
- type: Input
1711
- }], items: [{
1712
- type: Input
1713
- }], level: [{
1714
- type: Input
1715
- }] });
1716
- })();
1717
-
1718
- function SidenavComponent_ng_template_3_ng_container_2_Template(rf, ctx) {
1719
- if (rf & 1) {
1720
- i0.ɵɵelementContainer(0);
1721
- }
1722
- }
1723
- function SidenavComponent_ng_template_3_Template(rf, ctx) {
1724
- if (rf & 1) {
1725
- i0.ɵɵelementStart(0, "div", 11);
1726
- i0.ɵɵpipe(1, "async");
1727
- i0.ɵɵtemplate(2, SidenavComponent_ng_template_3_ng_container_2_Template, 1, 0, "ng-container", 12);
1728
- i0.ɵɵelementEnd();
1729
- i0.ɵɵelement(3, "mat-divider", 13);
1730
- i0.ɵɵpipe(4, "async");
1731
- }
1732
- if (rf & 2) {
1733
- const ctx_r0 = i0.ɵɵnextContext();
1734
- let tmp_1_0;
1735
- i0.ɵɵproperty("fxHide", i0.ɵɵpipeBind1(1, 3, ctx_r0.sidenav.collapsed$));
1736
- i0.ɵɵadvance(2);
1737
- i0.ɵɵproperty("ngTemplateOutlet", (tmp_1_0 = ctx_r0.sidenavHeaderDirective == null ? null : ctx_r0.sidenavHeaderDirective.template) !== null && tmp_1_0 !== undefined ? tmp_1_0 : null);
1738
- i0.ɵɵadvance(1);
1739
- i0.ɵɵproperty("fxHide", i0.ɵɵpipeBind1(4, 5, ctx_r0.sidenav.collapsed$));
1740
- }
1741
- }
1742
- function SidenavComponent_ng_template_15_ng_container_4_Template(rf, ctx) {
1743
- if (rf & 1) {
1744
- i0.ɵɵelementContainer(0);
1745
- }
1746
- }
1747
- function SidenavComponent_ng_template_15_Template(rf, ctx) {
1748
- if (rf & 1) {
1749
- i0.ɵɵelement(0, "mat-divider", 13);
1750
- i0.ɵɵpipe(1, "async");
1751
- i0.ɵɵelementStart(2, "div", 14);
1752
- i0.ɵɵpipe(3, "async");
1753
- i0.ɵɵtemplate(4, SidenavComponent_ng_template_15_ng_container_4_Template, 1, 0, "ng-container", 12);
1754
- i0.ɵɵelementEnd();
1755
- }
1756
- if (rf & 2) {
1757
- const ctx_r1 = i0.ɵɵnextContext();
1758
- let tmp_2_0;
1759
- i0.ɵɵproperty("fxHide", i0.ɵɵpipeBind1(1, 3, ctx_r1.sidenav.collapsed$));
1760
- i0.ɵɵadvance(2);
1761
- i0.ɵɵproperty("fxHide", i0.ɵɵpipeBind1(3, 5, ctx_r1.sidenav.collapsed$));
1762
- i0.ɵɵadvance(2);
1763
- i0.ɵɵproperty("ngTemplateOutlet", (tmp_2_0 = ctx_r1.sidenavFooterDirective == null ? null : ctx_r1.sidenavFooterDirective.template) !== null && tmp_2_0 !== undefined ? tmp_2_0 : null);
1764
- }
1765
- }
1766
- const _c2$1 = function (a0) { return { "collapsed": a0 }; };
1767
- class SidenavComponent {
1768
- constructor(sidenav) {
1769
- this.sidenav = sidenav;
1770
- }
1771
- }
1772
- SidenavComponent.ɵfac = function SidenavComponent_Factory(t) { return new (t || SidenavComponent)(i0.ɵɵdirectiveInject(SidenavComponentService)); };
1773
- SidenavComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SidenavComponent, selectors: [["rxap-sidenav"]], contentQueries: function SidenavComponent_ContentQueries(rf, ctx, dirIndex) {
1774
- if (rf & 1) {
1775
- i0.ɵɵcontentQuery(dirIndex, SidenavFooterDirective, 5);
1776
- i0.ɵɵcontentQuery(dirIndex, SidenavHeaderDirective, 5);
1777
- }
1778
- if (rf & 2) {
1779
- let _t;
1780
- i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.sidenavFooterDirective = _t.first);
1781
- i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.sidenavHeaderDirective = _t.first);
1782
- }
1783
- }, hostAttrs: [1, "rxap-layout-sidenav"], decls: 16, vars: 15, consts: function () {
1784
- let i18n_0;
1785
- if (typeof ngI18nClosureMode !== "undefined" && ngI18nClosureMode) {
1786
- /**
1787
- * @suppress {msgDescriptions}
1788
- */
1789
- const MSG_EXTERNAL_1144722711335201698$$LIB_SIDENAV_SIDENAV_COMPONENT_TS_1 = goog.getMsg("Collapse sidebar");
1790
- i18n_0 = MSG_EXTERNAL_1144722711335201698$$LIB_SIDENAV_SIDENAV_COMPONENT_TS_1;
1791
- }
1792
- else {
1793
- i18n_0 = $localize `:␟98effe6eb558f87ab061ab608a31b44adec4e2ae␟1144722711335201698:Collapse sidebar`;
1794
- }
1795
- return [[1, "container", 3, "ngClass"], ["fxLayout", "column", "fxLayoutAlign", "space-between stretch", 1, "inner"], [3, "ngIf"], ["fxFlex", "grow", 1, "nav-container"], ["fxLayout", "column", "root", "", "rxap-navigation", ""], ["fxFlex", "nogrow"], ["mat-button", "", "fxFlex", "nogrow", 1, "sidebar-toggle", 3, "ngClass", "click"], ["fxLayout", "row", "fxLayoutAlign", "start center", "fxLayoutGap", "16px", 1, "sidebar-toggle-inner"], ["fxFlex", "nogrow", 1, "arrow"], ["fxFlex", "grow", 1, "label", 3, "fxHide"], i18n_0, ["fxFlex", "nogrow", 1, "header", 3, "fxHide"], [4, "ngTemplateOutlet"], ["fxFlex", "nogrow", 3, "fxHide"], ["fxFlex", "nogrow", 1, "footer", 3, "fxHide"]];
1796
- }, template: function SidenavComponent_Template(rf, ctx) {
1797
- if (rf & 1) {
1798
- i0.ɵɵelementStart(0, "div", 0);
1799
- i0.ɵɵpipe(1, "async");
1800
- i0.ɵɵelementStart(2, "div", 1);
1801
- i0.ɵɵtemplate(3, SidenavComponent_ng_template_3_Template, 5, 7, "ng-template", 2);
1802
- i0.ɵɵelementStart(4, "div", 3);
1803
- i0.ɵɵelement(5, "ul", 4);
1804
- i0.ɵɵelementEnd();
1805
- i0.ɵɵelement(6, "mat-divider", 5);
1806
- i0.ɵɵelementStart(7, "button", 6);
1807
- i0.ɵɵlistener("click", function SidenavComponent_Template_button_click_7_listener() { return ctx.sidenav.toggleNavigationCollapse(); });
1808
- i0.ɵɵpipe(8, "async");
1809
- i0.ɵɵelementStart(9, "span", 7)(10, "mat-icon", 8);
1810
- i0.ɵɵtext(11, "double_arrow");
1811
- i0.ɵɵelementEnd();
1812
- i0.ɵɵelementStart(12, "span", 9);
1813
- i0.ɵɵi18n(13, 10);
1814
- i0.ɵɵpipe(14, "async");
1815
- i0.ɵɵelementEnd()()();
1816
- i0.ɵɵtemplate(15, SidenavComponent_ng_template_15_Template, 5, 7, "ng-template", 2);
1817
- i0.ɵɵelementEnd()();
1818
- }
1819
- if (rf & 2) {
1820
- let tmp_4_0;
1821
- i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(11, _c2$1, i0.ɵɵpipeBind1(1, 5, ctx.sidenav.collapsed$)));
1822
- i0.ɵɵadvance(3);
1823
- i0.ɵɵproperty("ngIf", ctx.sidenavHeaderDirective == null ? null : ctx.sidenavHeaderDirective.template);
1824
- i0.ɵɵadvance(4);
1825
- i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(13, _c2$1, i0.ɵɵpipeBind1(8, 7, ctx.sidenav.collapsed$)));
1826
- i0.ɵɵadvance(5);
1827
- i0.ɵɵproperty("fxHide", i0.ɵɵpipeBind1(14, 9, ctx.sidenav.collapsed$));
1828
- i0.ɵɵadvance(3);
1829
- i0.ɵɵproperty("ngIf", (tmp_4_0 = ctx.sidenavFooterDirective == null ? null : ctx.sidenavFooterDirective.template) !== null && tmp_4_0 !== undefined ? tmp_4_0 : null);
1830
- }
1831
- }, dependencies: [i1$3.DefaultLayoutDirective, i1$3.DefaultLayoutGapDirective, i1$3.DefaultLayoutAlignDirective, i1$3.DefaultFlexDirective, i5$1.DefaultShowHideDirective, i5$1.DefaultClassDirective, NavigationComponent, i2$1.NgClass, i2$1.NgIf, i2$1.NgTemplateOutlet, i3$4.MatDivider, i2$2.MatIcon, i1$1.MatLegacyButton, i2$1.AsyncPipe], styles: [".container[_ngcontent-%COMP%], .container[_ngcontent-%COMP%] .inner[_ngcontent-%COMP%]{height:100%}.container[_ngcontent-%COMP%] .inner[_ngcontent-%COMP%] .header[_ngcontent-%COMP%]{padding-bottom:12px}.container[_ngcontent-%COMP%] .inner[_ngcontent-%COMP%] .footer[_ngcontent-%COMP%]{padding-top:12px}.container[_ngcontent-%COMP%] .inner[_ngcontent-%COMP%] .nav-container[_ngcontent-%COMP%]{overflow-y:scroll;padding-top:12px}.container[_ngcontent-%COMP%] .inner[_ngcontent-%COMP%] .nav-container[_ngcontent-%COMP%]::-webkit-scrollbar{width:6px}.container[_ngcontent-%COMP%] .inner[_ngcontent-%COMP%] .nav-container[_ngcontent-%COMP%]::-webkit-scrollbar-track{border-radius:2px}.container[_ngcontent-%COMP%] .inner[_ngcontent-%COMP%] .nav-container[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{border-radius:10px}.container[_ngcontent-%COMP%] .sidebar-toggle[_ngcontent-%COMP%]{min-height:48px}.container[_ngcontent-%COMP%] .sidebar-toggle[_ngcontent-%COMP%] .sidebar-toggle-inner[_ngcontent-%COMP%]{padding:0}.container[_ngcontent-%COMP%] .sidebar-toggle[_ngcontent-%COMP%] .arrow[_ngcontent-%COMP%]{transform:rotate(180deg)}.container[_ngcontent-%COMP%] .sidebar-toggle.collapsed[_ngcontent-%COMP%] .arrow[_ngcontent-%COMP%]{transform:initial}.container[_ngcontent-%COMP%] .sidebar-toggle.collapsed[_ngcontent-%COMP%] .sidebar-toggle-inner[_ngcontent-%COMP%]{justify-content:space-around!important}"], changeDetection: 0 });
1832
- (function () {
1833
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SidenavComponent, [{
1834
- type: Component,
1835
- args: [{ selector: 'rxap-sidenav', changeDetection: ChangeDetectionStrategy.OnPush, host: {
1836
- class: 'rxap-layout-sidenav'
1837
- }, template: "<div class=\"container\" [ngClass]=\"{ 'collapsed': sidenav.collapsed$ | async }\">\n <div class=\"inner\"\n fxLayout=\"column\"\n fxLayoutAlign=\"space-between stretch\">\n <ng-template [ngIf]=\"sidenavHeaderDirective?.template\">\n <div fxFlex=\"nogrow\" class=\"header\" [fxHide]=\"sidenav.collapsed$ | async\">\n <ng-container *ngTemplateOutlet=\"sidenavHeaderDirective?.template ?? null\"></ng-container>\n </div>\n <mat-divider fxFlex=\"nogrow\" [fxHide]=\"sidenav.collapsed$ | async\"></mat-divider>\n </ng-template>\n <div fxFlex=\"grow\" class=\"nav-container\">\n <ul fxLayout=\"column\" root rxap-navigation></ul>\n </div>\n <mat-divider fxFlex=\"nogrow\"></mat-divider>\n <button mat-button class=\"sidebar-toggle\" [ngClass]=\"{ 'collapsed': sidenav.collapsed$ | async }\" fxFlex=\"nogrow\"\n (click)=\"sidenav.toggleNavigationCollapse()\">\n <span class=\"sidebar-toggle-inner\" fxLayout=\"row\" fxLayoutAlign=\"start center\" fxLayoutGap=\"16px\">\n <mat-icon fxFlex=\"nogrow\" class=\"arrow\">double_arrow</mat-icon>\n <span [fxHide]=\"sidenav.collapsed$ | async\" class=\"label\" fxFlex=\"grow\" i18n>Collapse sidebar</span>\n </span>\n </button>\n <ng-template [ngIf]=\"sidenavFooterDirective?.template ?? null\">\n <mat-divider fxFlex=\"nogrow\" [fxHide]=\"sidenav.collapsed$ | async\"></mat-divider>\n <div fxFlex=\"nogrow\" class=\"footer\" [fxHide]=\"sidenav.collapsed$ | async\">\n <ng-container *ngTemplateOutlet=\"sidenavFooterDirective?.template ?? null\"></ng-container>\n </div>\n </ng-template>\n </div>\n</div>\n", styles: [".container,.container .inner{height:100%}.container .inner .header{padding-bottom:12px}.container .inner .footer{padding-top:12px}.container .inner .nav-container{overflow-y:scroll;padding-top:12px}.container .inner .nav-container::-webkit-scrollbar{width:6px}.container .inner .nav-container::-webkit-scrollbar-track{border-radius:2px}.container .inner .nav-container::-webkit-scrollbar-thumb{border-radius:10px}.container .sidebar-toggle{min-height:48px}.container .sidebar-toggle .sidebar-toggle-inner{padding:0}.container .sidebar-toggle .arrow{transform:rotate(180deg)}.container .sidebar-toggle.collapsed .arrow{transform:initial}.container .sidebar-toggle.collapsed .sidebar-toggle-inner{justify-content:space-around!important}\n"] }]
1838
- }], function () { return [{ type: SidenavComponentService }]; }, { sidenavFooterDirective: [{
1839
- type: ContentChild,
1840
- args: [SidenavFooterDirective]
1841
- }], sidenavHeaderDirective: [{
1842
- type: ContentChild,
1843
- args: [SidenavHeaderDirective]
1844
- }] });
1845
- })();
1846
-
1847
- class SidenavContentComponentService {
1848
- constructor(footerComponentService, headerComponentService) {
1849
- this.footerComponentService = footerComponentService;
1850
- this.headerComponentService = headerComponentService;
1851
- this.headerRows$ = new BehaviorSubject(1);
1852
- this.headerRows$.next(this.headerComponentService.countComponent);
1853
- this.footerComponentService.portalCount$.pipe().subscribe();
1854
- this.footerRows$ = this.footerComponentService.portalCount$;
1855
- this.headerComponentService.update$.pipe(tap(() => this.headerRows$.next(this.headerComponentService.countComponent))).subscribe();
1856
- this.innerHeight$ = combineLatest([
1857
- this.headerRows$,
1858
- this.footerRows$
1859
- ]).pipe(map(([headerRows, footerRows]) => `calc(100% - ${64 * (headerRows + footerRows)}px)`));
1860
- this.marginTop$ = this.headerRows$.pipe(map(headerRows => `${headerRows * 64}px`));
1861
- this.marginBottom$ = this.footerRows$.pipe(map(footerRows => `${footerRows * 64}px`));
1862
- }
1863
- }
1864
- SidenavContentComponentService.ɵfac = function SidenavContentComponentService_Factory(t) { return new (t || SidenavContentComponentService)(i0.ɵɵinject(FooterService), i0.ɵɵinject(HeaderService)); };
1865
- SidenavContentComponentService.ɵprov = /*@__PURE__*/ i0.ɵɵdefineInjectable({ token: SidenavContentComponentService, factory: SidenavContentComponentService.ɵfac, providedIn: 'root' });
1866
- (function () {
1867
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SidenavContentComponentService, [{
1868
- type: Injectable,
1869
- args: [{ providedIn: 'root' }]
1870
- }], function () {
1871
- return [{ type: i1.FooterService, decorators: [{
1872
- type: Inject,
1873
- args: [FooterService]
1874
- }] }, { type: i1.HeaderService, decorators: [{
1875
- type: Inject,
1876
- args: [HeaderService]
1877
- }] }];
1878
- }, null);
1879
- })();
1880
-
1881
- const _c0$1 = function (a0) { return { "open": a0 }; };
1882
- const _c1$1 = function (a0, a1, a2) { return { height: a0, marginTop: a1, marginBottom: a2 }; };
1883
- const _c2 = ["*"];
1884
- class SidenavContentComponent {
1885
- constructor(sccs) {
1886
- this.sccs = sccs;
1887
- }
1888
- ngOnInit() {
1889
- }
1890
- }
1891
- SidenavContentComponent.ɵfac = function SidenavContentComponent_Factory(t) { return new (t || SidenavContentComponent)(i0.ɵɵdirectiveInject(SidenavContentComponentService)); };
1892
- SidenavContentComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SidenavContentComponent, selectors: [["rxap-sidenav-content"]], inputs: { sidenav: "sidenav" }, ngContentSelectors: _c2, decls: 8, vars: 16, consts: [[1, "container", 3, "ngClass", "ngStyle"], [1, "inner"]], template: function SidenavContentComponent_Template(rf, ctx) {
1893
- if (rf & 1) {
1894
- i0.ɵɵprojectionDef();
1895
- i0.ɵɵelementStart(0, "div", 0);
1896
- i0.ɵɵpipe(1, "async");
1897
- i0.ɵɵpipe(2, "async");
1898
- i0.ɵɵpipe(3, "async");
1899
- i0.ɵɵpipe(4, "async");
1900
- i0.ɵɵelementStart(5, "div", 1);
1901
- i0.ɵɵelement(6, "router-outlet");
1902
- i0.ɵɵprojection(7);
1903
- i0.ɵɵelementEnd()();
1904
- }
1905
- if (rf & 2) {
1906
- i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(10, _c0$1, i0.ɵɵpipeBind1(1, 2, ctx.sidenav.openedChange)))("ngStyle", i0.ɵɵpureFunction3(12, _c1$1, i0.ɵɵpipeBind1(2, 4, ctx.sccs.innerHeight$), i0.ɵɵpipeBind1(3, 6, ctx.sccs.marginTop$), i0.ɵɵpipeBind1(4, 8, ctx.sccs.marginBottom$)));
1907
- }
1908
- }, dependencies: [i2$1.NgClass, i2$1.NgStyle, i3$1.RouterOutlet, i2$1.AsyncPipe], styles: [".container[_ngcontent-%COMP%] .inner[_ngcontent-%COMP%]{padding:0;overflow:auto;height:100%}"], changeDetection: 0 });
1909
- __decorate([
1910
- Required,
1911
- __metadata("design:type", MatSidenav)
1912
- ], SidenavContentComponent.prototype, "sidenav", void 0);
1913
- (function () {
1914
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SidenavContentComponent, [{
1915
- type: Component,
1916
- args: [{ selector: 'rxap-sidenav-content', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div [ngClass]=\"{ 'open': (sidenav.openedChange | async) }\" [ngStyle]=\"{\n height: sccs.innerHeight$ | async,\n marginTop: sccs.marginTop$ | async,\n marginBottom: sccs.marginBottom$ | async\n}\" class=\"container\">\n <!-- <dx-breadcrumb></dx-breadcrumb>-->\n <div class=\"inner\">\n <router-outlet></router-outlet>\n <ng-content></ng-content>\n </div>\n</div>\n", styles: [".container .inner{padding:0;overflow:auto;height:100%}\n"] }]
1917
- }], function () { return [{ type: SidenavContentComponentService }]; }, { sidenav: [{
1918
- type: Input
1919
- }] });
1920
- })();
1921
-
1922
- function WindowContainerSidenavComponent_div_1_ng_template_1_Template(rf, ctx) { }
1923
- function WindowContainerSidenavComponent_div_1_Template(rf, ctx) {
1924
- if (rf & 1) {
1925
- i0.ɵɵelementStart(0, "div", 2);
1926
- i0.ɵɵtemplate(1, WindowContainerSidenavComponent_div_1_ng_template_1_Template, 0, 0, "ng-template", 3);
1927
- i0.ɵɵelementEnd();
1928
- }
1929
- if (rf & 2) {
1930
- const portalId_r1 = ctx.$implicit;
1931
- const ctx_r0 = i0.ɵɵnextContext();
1932
- i0.ɵɵadvance(1);
1933
- i0.ɵɵproperty("cdkPortalOutlet", ctx_r0.portals.get(portalId_r1));
1934
- }
1935
- }
1936
- class WindowContainerSidenavComponent {
1937
- constructor(service) {
1938
- this.service = service;
1939
- this.portals = new Map();
1940
- this.subscription = new Subscription();
1941
- }
1942
- ngOnInit() {
1943
- const components = this.service.getAll();
1944
- for (const component of components) {
1945
- this.add(component);
1946
- }
1947
- this.subscription.add(this.service.add$.pipe(tap(component => this.add(component))).subscribe());
1948
- this.subscription.add(this.service.remove$.pipe(tap(component => this.remove(component))).subscribe());
1949
- }
1950
- ngOnDestroy() {
1951
- this.subscription.unsubscribe();
1952
- }
1953
- trackBy(index, id) {
1954
- return id;
1955
- }
1956
- add(component) {
1957
- if (this.portals.has(component.id)) {
1958
- throw new Error(`Component portal with id ${component.id} already exists`);
1959
- }
1960
- const portal = new ComponentPortal(component.component, component.viewContainerRef, component.injector, component.componentFactoryResolver);
1961
- this.portals.set(component.id, portal);
1962
- }
1963
- remove(component) {
1964
- if (this.portals.has(component.id)) {
1965
- const portal = this.portals.get(component.id);
1966
- this.portals.delete(component.id);
1967
- portal.detach();
1968
- }
1969
- }
1970
- }
1971
- WindowContainerSidenavComponent.ɵfac = function WindowContainerSidenavComponent_Factory(t) { return new (t || WindowContainerSidenavComponent)(i0.ɵɵdirectiveInject(WindowContainerSidenavService)); };
1972
- WindowContainerSidenavComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: WindowContainerSidenavComponent, selectors: [["rxap-window-container-sidenav"]], decls: 2, vars: 2, consts: [["fxLayout", "column", "fxLayoutGap", "16px", 1, "container"], ["fxFlex", "nogrow", 4, "ngFor", "ngForOf", "ngForTrackBy"], ["fxFlex", "nogrow"], [3, "cdkPortalOutlet"]], template: function WindowContainerSidenavComponent_Template(rf, ctx) {
1973
- if (rf & 1) {
1974
- i0.ɵɵelementStart(0, "div", 0);
1975
- i0.ɵɵtemplate(1, WindowContainerSidenavComponent_div_1_Template, 2, 1, "div", 1);
1976
- i0.ɵɵelementEnd();
1977
- }
1978
- if (rf & 2) {
1979
- i0.ɵɵadvance(1);
1980
- i0.ɵɵproperty("ngForOf", ctx.portals.keys())("ngForTrackBy", ctx.trackBy);
1981
- }
1982
- }, dependencies: [i1$3.DefaultLayoutDirective, i1$3.DefaultLayoutGapDirective, i1$3.DefaultFlexDirective, i2$1.NgForOf, i4.CdkPortalOutlet], styles: [".container[_ngcontent-%COMP%]{padding:8px}"], changeDetection: 0 });
1983
- (function () {
1984
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(WindowContainerSidenavComponent, [{
1985
- type: Component,
1986
- args: [{ selector: 'rxap-window-container-sidenav', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div fxLayout=\"column\" fxLayoutGap=\"16px\" class=\"container\">\n\n <div fxFlex=\"nogrow\" *ngFor=\"let portalId of portals.keys(); trackBy: trackBy\">\n <ng-template [cdkPortalOutlet]=\"portals.get(portalId)\"></ng-template>\n </div>\n\n</div>\n", styles: [".container{padding:8px}\n"] }]
1987
- }], function () {
1988
- return [{ type: i1.WindowContainerSidenavService, decorators: [{
1989
- type: Inject,
1990
- args: [WindowContainerSidenavService]
1991
- }] }];
1992
- }, null);
1993
- })();
1994
-
1995
- function ToggleWindowSidenavButtonComponent_ng_template_2_Template(rf, ctx) {
1996
- if (rf & 1) {
1997
- i0.ɵɵelementStart(0, "mat-icon");
1998
- i0.ɵɵtext(1, "keyboard_arrow_left");
1999
- i0.ɵɵelementEnd();
2000
- }
2001
- }
2002
- function ToggleWindowSidenavButtonComponent_ng_template_3_Template(rf, ctx) {
2003
- if (rf & 1) {
2004
- i0.ɵɵelementStart(0, "mat-icon");
2005
- i0.ɵɵtext(1, "keyboard_arrow_right");
2006
- i0.ɵɵelementEnd();
2007
- }
2008
- }
2009
- class ToggleWindowSidenavButtonComponent {
2010
- constructor() {
2011
- this.openWindowSidenav = false;
2012
- this.openWindowSidenavChange = new EventEmitter();
2013
- }
2014
- ngOnInit() {
2015
- }
2016
- toggle() {
2017
- this.openWindowSidenav = !this.openWindowSidenav;
2018
- this.openWindowSidenavChange.emit(this.openWindowSidenav);
2019
- }
2020
- }
2021
- ToggleWindowSidenavButtonComponent.ɵfac = function ToggleWindowSidenavButtonComponent_Factory(t) { return new (t || ToggleWindowSidenavButtonComponent)(); };
2022
- ToggleWindowSidenavButtonComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ToggleWindowSidenavButtonComponent, selectors: [["rxap-toggle-window-sidenav-button"]], hostAttrs: [1, "rxap-toggle-window-sidenav-button"], inputs: { openWindowSidenav: "openWindowSidenav" }, outputs: { openWindowSidenavChange: "openWindowSidenavChange" }, decls: 5, vars: 2, consts: [[1, "toggle-button"], ["mat-icon-button", "", 3, "click"], [3, "ngIfElse", "ngIf"], ["hide", ""]], template: function ToggleWindowSidenavButtonComponent_Template(rf, ctx) {
2023
- if (rf & 1) {
2024
- i0.ɵɵelementStart(0, "div", 0)(1, "button", 1);
2025
- i0.ɵɵlistener("click", function ToggleWindowSidenavButtonComponent_Template_button_click_1_listener() { return ctx.toggle(); });
2026
- i0.ɵɵtemplate(2, ToggleWindowSidenavButtonComponent_ng_template_2_Template, 2, 0, "ng-template", 2);
2027
- i0.ɵɵtemplate(3, ToggleWindowSidenavButtonComponent_ng_template_3_Template, 2, 0, "ng-template", null, 3, i0.ɵɵtemplateRefExtractor);
2028
- i0.ɵɵelementEnd()();
2029
- }
2030
- if (rf & 2) {
2031
- const _r1 = i0.ɵɵreference(4);
2032
- i0.ɵɵadvance(2);
2033
- i0.ɵɵproperty("ngIfElse", _r1)("ngIf", !ctx.openWindowSidenav);
2034
- }
2035
- }, dependencies: [i1$1.MatLegacyButton, i2$2.MatIcon, i2$1.NgIf], styles: [".toggle-button[_ngcontent-%COMP%]{position:absolute;top:70px;right:0;z-index:10000;border-radius:15px 0 0 15px;border:1px solid black;background:black}"], changeDetection: 0 });
2036
- (function () {
2037
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ToggleWindowSidenavButtonComponent, [{
2038
- type: Component,
2039
- args: [{ selector: 'rxap-toggle-window-sidenav-button', changeDetection: ChangeDetectionStrategy.OnPush, host: {
2040
- class: 'rxap-toggle-window-sidenav-button'
2041
- }, template: "<div class=\"toggle-button\">\n <button (click)=\"toggle()\" mat-icon-button>\n <ng-template [ngIfElse]=\"hide\" [ngIf]=\"!openWindowSidenav\">\n <mat-icon>keyboard_arrow_left</mat-icon>\n </ng-template>\n <ng-template #hide>\n <mat-icon>keyboard_arrow_right</mat-icon>\n </ng-template>\n </button>\n</div>\n", styles: [".toggle-button{position:absolute;top:70px;right:0;z-index:10000;border-radius:15px 0 0 15px;border:1px solid black;background:black}\n"] }]
2042
- }], function () { return []; }, { openWindowSidenav: [{
2043
- type: Input
2044
- }], openWindowSidenavChange: [{
2045
- type: Output
2046
- }] });
2047
- })();
2048
-
2049
- const _c0 = function () { return ["/"]; };
2050
- function LayoutComponent_ng_template_8_Template(rf, ctx) {
2051
- if (rf & 1) {
2052
- i0.ɵɵelement(0, "img", 9);
2053
- }
2054
- if (rf & 2) {
2055
- const ctx_r0 = i0.ɵɵnextContext();
2056
- i0.ɵɵproperty("routerLink", i0.ɵɵpureFunction0(3, _c0))("width", ctx_r0.layoutComponentService.logo.width)("src", ctx_r0.layoutComponentService.logo.src, i0.ɵɵsanitizeUrl);
2057
- }
2058
- }
2059
- const _c1 = ["*"];
2060
- class LayoutComponent {
2061
- constructor(layoutComponentService) {
2062
- this.layoutComponentService = layoutComponentService;
2063
- this.openWindowSidenav = false;
2064
- }
2065
- }
2066
- LayoutComponent.ɵfac = function LayoutComponent_Factory(t) { return new (t || LayoutComponent)(i0.ɵɵdirectiveInject(LayoutComponentService)); };
2067
- LayoutComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: LayoutComponent, selectors: [["rxap-layout"]], viewQuery: function LayoutComponent_Query(rf, ctx) {
2068
- if (rf & 1) {
2069
- i0.ɵɵviewQuery(MatSidenav, 7);
2070
- }
2071
- if (rf & 2) {
2072
- let _t;
2073
- i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.sidenav = _t.first);
2074
- }
2075
- }, ngContentSelectors: _c1, decls: 18, vars: 24, consts: [[1, "header", 3, "sidenav"], ["autosize", "", 1, "container"], [1, "sidenav", 3, "fixedBottomGap", "fixedInViewport", "fixedTopGap", "mode", "opened"], ["rxapSidenavHeader", ""], [1, "content"], [3, "sidenav"], [3, "openWindowSidenav", "openWindowSidenavChange"], ["mode", "side", "position", "end", 1, "window-container-sidenav", 3, "fixedBottomGap", "fixedInViewport", "fixedTopGap", "opened"], [1, "footer"], ["alt", "logo", 1, "logo", 3, "routerLink", "width", "src"]], template: function LayoutComponent_Template(rf, ctx) {
2076
- if (rf & 1) {
2077
- i0.ɵɵprojectionDef();
2078
- i0.ɵɵelement(0, "rxap-header", 0);
2079
- i0.ɵɵelementStart(1, "mat-sidenav-container", 1)(2, "mat-sidenav", 2);
2080
- i0.ɵɵpipe(3, "async");
2081
- i0.ɵɵpipe(4, "async");
2082
- i0.ɵɵpipe(5, "async");
2083
- i0.ɵɵpipe(6, "async");
2084
- i0.ɵɵelementStart(7, "rxap-sidenav");
2085
- i0.ɵɵtemplate(8, LayoutComponent_ng_template_8_Template, 1, 4, "ng-template", 3);
2086
- i0.ɵɵelementEnd()();
2087
- i0.ɵɵelementStart(9, "mat-sidenav-content", 4)(10, "rxap-sidenav-content", 5);
2088
- i0.ɵɵprojection(11);
2089
- i0.ɵɵelementStart(12, "rxap-toggle-window-sidenav-button", 6);
2090
- i0.ɵɵlistener("openWindowSidenavChange", function LayoutComponent_Template_rxap_toggle_window_sidenav_button_openWindowSidenavChange_12_listener($event) { return ctx.openWindowSidenav = $event; });
2091
- i0.ɵɵelementEnd()()();
2092
- i0.ɵɵelementStart(13, "mat-sidenav", 7);
2093
- i0.ɵɵpipe(14, "async");
2094
- i0.ɵɵpipe(15, "async");
2095
- i0.ɵɵelement(16, "rxap-window-container-sidenav");
2096
- i0.ɵɵelementEnd()();
2097
- i0.ɵɵelement(17, "rxap-footer", 8);
2098
- }
2099
- if (rf & 2) {
2100
- let tmp_4_0;
2101
- let tmp_5_0;
2102
- i0.ɵɵproperty("sidenav", ctx.sidenav);
2103
- i0.ɵɵadvance(2);
2104
- i0.ɵɵproperty("fixedBottomGap", i0.ɵɵpipeBind1(3, 12, ctx.layoutComponentService.fixedBottomGap$))("fixedInViewport", true)("fixedTopGap", i0.ɵɵpipeBind1(4, 14, ctx.layoutComponentService.fixedTopGap$))("mode", (tmp_4_0 = i0.ɵɵpipeBind1(5, 16, ctx.layoutComponentService.mode$)) !== null && tmp_4_0 !== undefined ? tmp_4_0 : "side")("opened", (tmp_5_0 = i0.ɵɵpipeBind1(6, 18, ctx.layoutComponentService.opened$)) !== null && tmp_5_0 !== undefined ? tmp_5_0 : true);
2105
- i0.ɵɵadvance(8);
2106
- i0.ɵɵproperty("sidenav", ctx.sidenav);
2107
- i0.ɵɵadvance(2);
2108
- i0.ɵɵproperty("openWindowSidenav", ctx.openWindowSidenav);
2109
- i0.ɵɵadvance(1);
2110
- i0.ɵɵproperty("fixedBottomGap", i0.ɵɵpipeBind1(14, 20, ctx.layoutComponentService.fixedBottomGap$))("fixedInViewport", true)("fixedTopGap", i0.ɵɵpipeBind1(15, 22, ctx.layoutComponentService.fixedTopGap$))("opened", ctx.openWindowSidenav);
2111
- }
2112
- }, dependencies: [i2$4.MatSidenav, i2$4.MatSidenavContainer, i2$4.MatSidenavContent, FooterComponent, HeaderComponent, SidenavComponent, SidenavHeaderDirective, SidenavContentComponent, WindowContainerSidenavComponent, ToggleWindowSidenavButtonComponent, i3$1.RouterLink, i2$1.AsyncPipe], styles: [".container[_ngcontent-%COMP%], .content[_ngcontent-%COMP%]{height:100%}.sidenav[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;width:auto}.sidenav[_ngcontent-%COMP%] .logo[_ngcontent-%COMP%]{padding:16px}.footer[_ngcontent-%COMP%]{position:fixed;bottom:0;left:0;right:0;z-index:100}.header[_ngcontent-%COMP%]{position:fixed;top:0;left:0;right:0;z-index:100}"], changeDetection: 0 });
2113
- (function () {
2114
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LayoutComponent, [{
2115
- type: Component,
2116
- args: [{ selector: 'rxap-layout', changeDetection: ChangeDetectionStrategy.OnPush, template: "<rxap-header [sidenav]=\"sidenav\" class=\"header\"></rxap-header>\n<mat-sidenav-container autosize class=\"container\">\n <mat-sidenav\n [fixedBottomGap]=\"layoutComponentService.fixedBottomGap$ | async\"\n [fixedInViewport]=\"true\"\n [fixedTopGap]=\"layoutComponentService.fixedTopGap$ | async\"\n [mode]=\"(layoutComponentService.mode$ | async) ?? 'side'\"\n [opened]=\"(layoutComponentService.opened$ | async) ?? true\"\n class=\"sidenav\"\n >\n <rxap-sidenav>\n <ng-template rxapSidenavHeader>\n <img\n [routerLink]=\"['/']\"\n alt=\"logo\"\n class=\"logo\"\n [width]=\"layoutComponentService.logo.width\"\n [src]=\"layoutComponentService.logo.src\"\n />\n </ng-template>\n </rxap-sidenav>\n </mat-sidenav>\n <mat-sidenav-content class=\"content\">\n <rxap-sidenav-content [sidenav]=\"sidenav\">\n <ng-content></ng-content>\n <rxap-toggle-window-sidenav-button [(openWindowSidenav)]=\"openWindowSidenav\"></rxap-toggle-window-sidenav-button>\n </rxap-sidenav-content>\n </mat-sidenav-content>\n <mat-sidenav\n [fixedBottomGap]=\"layoutComponentService.fixedBottomGap$ | async\"\n [fixedInViewport]=\"true\"\n [fixedTopGap]=\"layoutComponentService.fixedTopGap$ | async\"\n [opened]=\"openWindowSidenav\"\n mode=\"side\"\n class=\"window-container-sidenav\"\n position=\"end\"\n >\n <rxap-window-container-sidenav></rxap-window-container-sidenav>\n </mat-sidenav>\n</mat-sidenav-container>\n<rxap-footer class=\"footer\"></rxap-footer>\n", styles: [".container,.content{height:100%}.sidenav{display:flex;align-items:center;justify-content:center;width:auto}.sidenav .logo{padding:16px}.footer{position:fixed;bottom:0;left:0;right:0;z-index:100}.header{position:fixed;top:0;left:0;right:0;z-index:100}\n"] }]
2117
- }], function () { return [{ type: LayoutComponentService }]; }, { sidenav: [{
2118
- type: ViewChild,
2119
- args: [MatSidenav, { static: true }]
2120
- }] });
2121
- })();
2122
-
2123
- class ReplaceRouterPathsService {
2124
- transform(routerLink) {
2125
- return of(routerLink);
2126
- }
2127
- }
2128
- ReplaceRouterPathsService.ɵfac = function ReplaceRouterPathsService_Factory(t) { return new (t || ReplaceRouterPathsService)(); };
2129
- ReplaceRouterPathsService.ɵprov = /*@__PURE__*/ i0.ɵɵdefineInjectable({ token: ReplaceRouterPathsService, factory: ReplaceRouterPathsService.ɵfac, providedIn: 'root' });
2130
- (function () {
2131
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ReplaceRouterPathsService, [{
2132
- type: Injectable,
2133
- args: [{ providedIn: 'root' }]
2134
- }], null, null);
2135
- })();
2136
-
2137
- class ReplaceRouterPathsPipe {
2138
- constructor(rrp) {
2139
- this.rrp = rrp;
2140
- }
2141
- transform(routerLink) {
2142
- return this.rrp.transform(routerLink);
2143
- }
2144
- }
2145
- ReplaceRouterPathsPipe.ɵfac = function ReplaceRouterPathsPipe_Factory(t) { return new (t || ReplaceRouterPathsPipe)(i0.ɵɵdirectiveInject(ReplaceRouterPathsService, 16)); };
2146
- ReplaceRouterPathsPipe.ɵpipe = /*@__PURE__*/ i0.ɵɵdefinePipe({ name: "replaceRouterPaths", type: ReplaceRouterPathsPipe, pure: true });
2147
- (function () {
2148
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ReplaceRouterPathsPipe, [{
2149
- type: Pipe,
2150
- args: [{
2151
- name: 'replaceRouterPaths'
2152
- }]
2153
- }], function () { return [{ type: ReplaceRouterPathsService }]; }, null);
2154
- })();
2155
- class ReplaceRouterPathsPipeModule {
2156
- }
2157
- ReplaceRouterPathsPipeModule.ɵfac = function ReplaceRouterPathsPipeModule_Factory(t) { return new (t || ReplaceRouterPathsPipeModule)(); };
2158
- ReplaceRouterPathsPipeModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: ReplaceRouterPathsPipeModule });
2159
- ReplaceRouterPathsPipeModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({});
2160
- (function () {
2161
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ReplaceRouterPathsPipeModule, [{
2162
- type: NgModule,
2163
- args: [{
2164
- declarations: [ReplaceRouterPathsPipe],
2165
- exports: [ReplaceRouterPathsPipe]
2166
- }]
2167
- }], null, null);
2168
- })();
2169
- (function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(ReplaceRouterPathsPipeModule, { declarations: [ReplaceRouterPathsPipe], exports: [ReplaceRouterPathsPipe] }); })();
2170
-
2171
- class NavigationComponentModule {
2172
- }
2173
- NavigationComponentModule.ɵfac = function NavigationComponentModule_Factory(t) { return new (t || NavigationComponentModule)(); };
2174
- NavigationComponentModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: NavigationComponentModule });
2175
- NavigationComponentModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [MatIconModule,
2176
- MatLegacyButtonModule,
2177
- FlexLayoutModule,
2178
- RouterModule,
2179
- CommonModule,
2180
- IconDirectiveModule,
2181
- MatRippleModule,
2182
- MatDividerModule,
2183
- StopPropagationDirectiveModule,
2184
- MatLegacyTooltipModule,
2185
- ReplaceRouterPathsPipeModule] });
2186
- (function () {
2187
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(NavigationComponentModule, [{
2188
- type: NgModule,
2189
- args: [{
2190
- declarations: [NavigationComponent, NavigationItemComponent],
2191
- imports: [
2192
- MatIconModule,
2193
- MatLegacyButtonModule,
2194
- FlexLayoutModule,
2195
- RouterModule,
2196
- CommonModule,
2197
- IconDirectiveModule,
2198
- MatRippleModule,
2199
- MatDividerModule,
2200
- StopPropagationDirectiveModule,
2201
- MatLegacyTooltipModule,
2202
- ReplaceRouterPathsPipeModule
2203
- ],
2204
- exports: [NavigationComponent]
2205
- }]
2206
- }], null, null);
2207
- })();
2208
- (function () {
2209
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(NavigationComponentModule, { declarations: [NavigationComponent, NavigationItemComponent], imports: [MatIconModule,
2210
- MatLegacyButtonModule,
2211
- FlexLayoutModule,
2212
- RouterModule,
2213
- CommonModule,
2214
- IconDirectiveModule,
2215
- MatRippleModule,
2216
- MatDividerModule,
2217
- StopPropagationDirectiveModule,
2218
- MatLegacyTooltipModule,
2219
- ReplaceRouterPathsPipeModule], exports: [NavigationComponent] });
2220
- })();
2221
- i0.ɵɵsetComponentScope(NavigationItemComponent, [i2$2.MatIcon, i1$3.DefaultFlexDirective, i3$1.RouterLink, i3$1.RouterLinkActive, i2$1.NgForOf, i2$1.NgIf, i5$2.IconDirective, i6$1.MatRipple, i7.MatLegacyTooltip, NavigationComponent], [i2$1.AsyncPipe]);
2222
-
2223
- class SidenavModule {
2224
- }
2225
- SidenavModule.ɵfac = function SidenavModule_Factory(t) { return new (t || SidenavModule)(); };
2226
- SidenavModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: SidenavModule });
2227
- SidenavModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [FlexLayoutModule,
2228
- NavigationComponentModule,
2229
- CommonModule,
2230
- MatDividerModule,
2231
- MatIconModule,
2232
- MatLegacyButtonModule] });
2233
- (function () {
2234
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SidenavModule, [{
2235
- type: NgModule,
2236
- args: [{
2237
- declarations: [SidenavComponent, SidenavHeaderDirective, SidenavFooterDirective],
2238
- imports: [
2239
- FlexLayoutModule,
2240
- NavigationComponentModule,
2241
- CommonModule,
2242
- MatDividerModule,
2243
- MatIconModule,
2244
- MatLegacyButtonModule
2245
- ],
2246
- exports: [SidenavComponent, SidenavHeaderDirective, SidenavFooterDirective],
2247
- }]
2248
- }], null, null);
2249
- })();
2250
- (function () {
2251
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(SidenavModule, { declarations: [SidenavComponent, SidenavHeaderDirective, SidenavFooterDirective], imports: [FlexLayoutModule,
2252
- NavigationComponentModule,
2253
- CommonModule,
2254
- MatDividerModule,
2255
- MatIconModule,
2256
- MatLegacyButtonModule], exports: [SidenavComponent, SidenavHeaderDirective, SidenavFooterDirective] });
2257
- })();
2258
-
2259
- class SidenavContentModule {
2260
- }
2261
- SidenavContentModule.ɵfac = function SidenavContentModule_Factory(t) { return new (t || SidenavContentModule)(); };
2262
- SidenavContentModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: SidenavContentModule });
2263
- SidenavContentModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [CommonModule,
2264
- RouterModule] });
2265
- (function () {
2266
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SidenavContentModule, [{
2267
- type: NgModule,
2268
- args: [{
2269
- declarations: [SidenavContentComponent],
2270
- imports: [
2271
- CommonModule,
2272
- RouterModule
2273
- ],
2274
- exports: [SidenavContentComponent]
2275
- }]
2276
- }], null, null);
2277
- })();
2278
- (function () {
2279
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(SidenavContentModule, { declarations: [SidenavContentComponent], imports: [CommonModule,
2280
- RouterModule], exports: [SidenavContentComponent] });
2281
- })();
2282
-
2283
- class WindowContainerSidenavModule {
2284
- }
2285
- WindowContainerSidenavModule.ɵfac = function WindowContainerSidenavModule_Factory(t) { return new (t || WindowContainerSidenavModule)(); };
2286
- WindowContainerSidenavModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: WindowContainerSidenavModule });
2287
- WindowContainerSidenavModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [FlexLayoutModule,
2288
- CommonModule,
2289
- PortalModule] });
2290
- (function () {
2291
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(WindowContainerSidenavModule, [{
2292
- type: NgModule,
2293
- args: [{
2294
- declarations: [WindowContainerSidenavComponent],
2295
- imports: [
2296
- FlexLayoutModule,
2297
- CommonModule,
2298
- PortalModule,
2299
- ],
2300
- exports: [WindowContainerSidenavComponent],
2301
- }]
2302
- }], null, null);
2303
- })();
2304
- (function () {
2305
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(WindowContainerSidenavModule, { declarations: [WindowContainerSidenavComponent], imports: [FlexLayoutModule,
2306
- CommonModule,
2307
- PortalModule], exports: [WindowContainerSidenavComponent] });
2308
- })();
2309
-
2310
- class ToggleWindowSidenavButtonModule {
2311
- }
2312
- ToggleWindowSidenavButtonModule.ɵfac = function ToggleWindowSidenavButtonModule_Factory(t) { return new (t || ToggleWindowSidenavButtonModule)(); };
2313
- ToggleWindowSidenavButtonModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: ToggleWindowSidenavButtonModule });
2314
- ToggleWindowSidenavButtonModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [MatLegacyButtonModule,
2315
- MatIconModule,
2316
- CommonModule] });
2317
- (function () {
2318
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ToggleWindowSidenavButtonModule, [{
2319
- type: NgModule,
2320
- args: [{
2321
- declarations: [ToggleWindowSidenavButtonComponent],
2322
- imports: [
2323
- MatLegacyButtonModule,
2324
- MatIconModule,
2325
- CommonModule,
2326
- ],
2327
- exports: [ToggleWindowSidenavButtonComponent],
2328
- }]
2329
- }], null, null);
2330
- })();
2331
- (function () {
2332
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(ToggleWindowSidenavButtonModule, { declarations: [ToggleWindowSidenavButtonComponent], imports: [MatLegacyButtonModule,
2333
- MatIconModule,
2334
- CommonModule], exports: [ToggleWindowSidenavButtonComponent] });
2335
- })();
2336
-
2337
- class LayoutModule {
2338
- static withNavigation(navigation) {
2339
- return {
2340
- ngModule: LayoutModule,
2341
- providers: [
2342
- {
2343
- provide: RXAP_NAVIGATION_CONFIG,
2344
- useValue: navigation
2345
- }
2346
- ]
2347
- };
2348
- }
2349
- }
2350
- LayoutModule.ɵfac = function LayoutModule_Factory(t) { return new (t || LayoutModule)(); };
2351
- LayoutModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: LayoutModule });
2352
- LayoutModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [MatSidenavModule,
2353
- FooterModule,
2354
- HeaderModule,
2355
- CommonModule,
2356
- SidenavModule,
2357
- SidenavContentModule,
2358
- WindowContainerSidenavModule,
2359
- ToggleWindowSidenavButtonModule,
2360
- FlexLayoutModule,
2361
- RouterModule] });
2362
- (function () {
2363
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LayoutModule, [{
2364
- type: NgModule,
2365
- args: [{
2366
- declarations: [LayoutComponent],
2367
- imports: [
2368
- MatSidenavModule,
2369
- FooterModule,
2370
- HeaderModule,
2371
- CommonModule,
2372
- SidenavModule,
2373
- SidenavContentModule,
2374
- WindowContainerSidenavModule,
2375
- ToggleWindowSidenavButtonModule,
2376
- FlexLayoutModule,
2377
- RouterModule
2378
- ],
2379
- exports: [LayoutComponent]
2380
- }]
2381
- }], null, null);
2382
- })();
2383
- (function () {
2384
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(LayoutModule, { declarations: [LayoutComponent], imports: [MatSidenavModule,
2385
- FooterModule,
2386
- HeaderModule,
2387
- CommonModule,
2388
- SidenavModule,
2389
- SidenavContentModule,
2390
- WindowContainerSidenavModule,
2391
- ToggleWindowSidenavButtonModule,
2392
- FlexLayoutModule,
2393
- RouterModule], exports: [LayoutComponent] });
2394
- })();
2395
-
2396
- function VersionComponent_div_1_Template(rf, ctx) {
2397
- if (rf & 1) {
2398
- i0.ɵɵelementStart(0, "div", 2)(1, "span", 3);
2399
- i0.ɵɵtext(2);
2400
- i0.ɵɵelementEnd();
2401
- i0.ɵɵelementStart(3, "span", 4);
2402
- i0.ɵɵtext(4);
2403
- i0.ɵɵelementEnd();
2404
- i0.ɵɵelementStart(5, "span", 5);
2405
- i0.ɵɵtext(6);
2406
- i0.ɵɵelementEnd()();
2407
- }
2408
- if (rf & 2) {
2409
- const module_r1 = ctx.$implicit;
2410
- i0.ɵɵadvance(2);
2411
- i0.ɵɵtextInterpolate(module_r1.value.name);
2412
- i0.ɵɵadvance(2);
2413
- i0.ɵɵtextInterpolate(module_r1.value.semantic);
2414
- i0.ɵɵadvance(2);
2415
- i0.ɵɵtextInterpolate(module_r1.value.hash);
2416
- }
2417
- }
2418
- class VersionComponent {
2419
- constructor(version) {
2420
- this.version = version;
2421
- }
2422
- ngOnInit() {
2423
- this.modules = this.version.get();
2424
- this.subscription = this.version.update$.pipe(tap(() => this.modules = this.version.get())).subscribe();
2425
- }
2426
- ngOnDestroy() {
2427
- var _a;
2428
- (_a = this.subscription) === null || _a === void 0 ? void 0 : _a.unsubscribe();
2429
- }
2430
- }
2431
- VersionComponent.ɵfac = function VersionComponent_Factory(t) { return new (t || VersionComponent)(i0.ɵɵdirectiveInject(VersionService)); };
2432
- VersionComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: VersionComponent, selectors: [["rxap-version"]], decls: 3, vars: 3, consts: [["fxFlex", "nogrow", "fxLayout", "column", "fxLayoutAlign", "start start", "fxLayoutGap", "8px", 1, "version"], ["fxFlex", "nogrow", "fxLayout", "column", 4, "ngFor", "ngForOf"], ["fxFlex", "nogrow", "fxLayout", "column"], ["fxFlex", "nogrow", 1, "name"], ["fxFlex", "nogrow", 1, "semantic"], ["fxFlex", "nogrow", 1, "hash"]], template: function VersionComponent_Template(rf, ctx) {
2433
- if (rf & 1) {
2434
- i0.ɵɵelementStart(0, "div", 0);
2435
- i0.ɵɵtemplate(1, VersionComponent_div_1_Template, 7, 3, "div", 1);
2436
- i0.ɵɵpipe(2, "keyvalue");
2437
- i0.ɵɵelementEnd();
2438
- }
2439
- if (rf & 2) {
2440
- i0.ɵɵadvance(1);
2441
- i0.ɵɵproperty("ngForOf", i0.ɵɵpipeBind1(2, 1, ctx.modules));
2442
- }
2443
- }, dependencies: [i1$3.DefaultLayoutDirective, i1$3.DefaultLayoutGapDirective, i1$3.DefaultLayoutAlignDirective, i1$3.DefaultFlexDirective, i2$1.NgForOf, i2$1.KeyValuePipe], styles: [".version[_ngcontent-%COMP%]{width:100%;font-size:9px;padding:8px}.version[_ngcontent-%COMP%] .name[_ngcontent-%COMP%]{padding-bottom:12px;font-size:10px}"], changeDetection: 0 });
2444
- __decorate([
2445
- Required,
2446
- __metadata("design:type", Object)
2447
- ], VersionComponent.prototype, "modules", void 0);
2448
- (function () {
2449
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(VersionComponent, [{
2450
- type: Component,
2451
- args: [{ selector: 'rxap-version', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"version\" fxFlex=\"nogrow\" fxLayout=\"column\" fxLayoutAlign=\"start start\" fxLayoutGap=\"8px\">\n <div *ngFor=\"let module of modules | keyvalue\" fxFlex=\"nogrow\" fxLayout=\"column\">\n <span class=\"name\" fxFlex=\"nogrow\">{{module.value.name}}</span>\n <span class=\"semantic\" fxFlex=\"nogrow\">{{module.value.semantic}}</span>\n <span class=\"hash\" fxFlex=\"nogrow\">{{module.value.hash}}</span>\n </div>\n</div>\n", styles: [".version{width:100%;font-size:9px;padding:8px}.version .name{padding-bottom:12px;font-size:10px}\n"] }]
2452
- }], function () {
2453
- return [{ type: i1.VersionService, decorators: [{
2454
- type: Inject,
2455
- args: [VersionService]
2456
- }] }];
2457
- }, { modules: [] });
2458
- })();
2459
-
2460
- class VersionComponentModule {
2461
- }
2462
- VersionComponentModule.ɵfac = function VersionComponentModule_Factory(t) { return new (t || VersionComponentModule)(); };
2463
- VersionComponentModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: VersionComponentModule });
2464
- VersionComponentModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [FlexLayoutModule,
2465
- CommonModule] });
2466
- (function () {
2467
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(VersionComponentModule, [{
2468
- type: NgModule,
2469
- args: [{
2470
- declarations: [VersionComponent],
2471
- imports: [
2472
- FlexLayoutModule,
2473
- CommonModule
2474
- ],
2475
- exports: [VersionComponent]
2476
- }]
2477
- }], null, null);
2478
- })();
2479
- (function () {
2480
- (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(VersionComponentModule, { declarations: [VersionComponent], imports: [FlexLayoutModule,
2481
- CommonModule], exports: [VersionComponent] });
2482
- })();
2483
-
2484
- class FooterDirective {
2485
- constructor(footerService, template, viewContainerRef) {
2486
- this.footerService = footerService;
2487
- this.template = template;
2488
- this.viewContainerRef = viewContainerRef;
2489
- }
2490
- ngOnInit() {
2491
- this._portal = new TemplatePortal(this.template, this.viewContainerRef);
2492
- this.footerService.pushPortal(this._portal);
2493
- }
2494
- ngOnDestroy() {
2495
- if (this._portal) {
2496
- this.footerService.removePortal(this._portal);
2497
- }
2498
- }
2499
- }
2500
- FooterDirective.ɵfac = function FooterDirective_Factory(t) { return new (t || FooterDirective)(i0.ɵɵdirectiveInject(FooterService), i0.ɵɵdirectiveInject(TemplateRef), i0.ɵɵdirectiveInject(ViewContainerRef)); };
2501
- FooterDirective.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: FooterDirective, selectors: [["", "rxapFooter", ""]] });
2502
- (function () {
2503
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(FooterDirective, [{
2504
- type: Directive,
2505
- args: [{
2506
- selector: '[rxapFooter]',
2507
- }]
2508
- }], function () {
2509
- return [{ type: i1.FooterService, decorators: [{
2510
- type: Inject,
2511
- args: [FooterService]
2512
- }] }, { type: i0.TemplateRef, decorators: [{
2513
- type: Inject,
2514
- args: [TemplateRef]
2515
- }] }, { type: i0.ViewContainerRef, decorators: [{
2516
- type: Inject,
2517
- args: [ViewContainerRef]
2518
- }] }];
2519
- }, null);
2520
- })();
2521
- class FooterDirectiveModule {
2522
- }
2523
- FooterDirectiveModule.ɵfac = function FooterDirectiveModule_Factory(t) { return new (t || FooterDirectiveModule)(); };
2524
- FooterDirectiveModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: FooterDirectiveModule });
2525
- FooterDirectiveModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({});
2526
- (function () {
2527
- (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(FooterDirectiveModule, [{
2528
- type: NgModule,
2529
- args: [{
2530
- declarations: [FooterDirective],
2531
- exports: [FooterDirective],
2532
- }]
2533
- }], null, null);
2534
- })();
2535
- (function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(FooterDirectiveModule, { declarations: [FooterDirective], exports: [FooterDirective] }); })();
2536
-
2537
- /**
2538
- * Generated bundle index. Do not edit.
2539
- */
2540
-
2541
- export { AppsButtonComponent, AppsButtonComponentModule, FooterComponent, FooterDirective, FooterDirectiveModule, FooterModule, HeaderComponent, HeaderModule, IsNavigationDividerItem, IsNavigationInsertItem, IsNavigationItem, LayoutComponent, LayoutComponentService, LayoutModule, NavigationComponent, NavigationComponentModule, NavigationItemComponent, NavigationProgressBarComponent, NavigationProgressBarComponentModule, NavigationService, RXAP_FOOTER_COMPONENT, RXAP_HEADER_COMPONENT, RXAP_LAYOUT_APPS_GRID, RXAP_LOGO_CONFIG, RXAP_NAVIGATION_CONFIG, RXAP_NAVIGATION_CONFIG_INSERTS, ReplaceRouterPathsService, ResetButtonComponent, ResetButtonComponentModule, SidenavComponent, SidenavComponentService, SidenavContentComponent, SidenavContentComponentService, SidenavContentModule, SidenavFooterDirective, SidenavHeaderDirective, SidenavModule, SidenavToggleButtonComponent, SidenavToggleButtonComponentModule, SignOutComponent, SignOutComponentModule, ToggleWindowSidenavButtonComponent, ToggleWindowSidenavButtonModule, UserProfileIconComponent, UserProfileIconComponentModule, VersionComponent, VersionComponentModule, WindowContainerSidenavComponent, WindowContainerSidenavModule };
2542
- //# sourceMappingURL=rxap-layout.mjs.map
2543
- //# sourceMappingURL=rxap-layout.mjs.map