iptdevs-design-system 1.3.15 → 1.3.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2020/lib/components/atoms/aside-button/aside-button.component.mjs +8 -14
- package/esm2020/lib/components/molecules/sidenav/sidenav.component.mjs +111 -62
- package/fesm2015/iptdevs-design-system.mjs +115 -71
- package/fesm2015/iptdevs-design-system.mjs.map +1 -1
- package/fesm2020/iptdevs-design-system.mjs +115 -71
- package/fesm2020/iptdevs-design-system.mjs.map +1 -1
- package/lib/components/atoms/aside-button/aside-button.component.d.ts +1 -4
- package/lib/components/molecules/sidenav/sidenav.component.d.ts +7 -4
- package/package.json +1 -1
|
@@ -10,47 +10,41 @@ export class AsideButtonComponent {
|
|
|
10
10
|
}
|
|
11
11
|
}
|
|
12
12
|
AsideButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.3", ngImport: i0, type: AsideButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
13
|
-
AsideButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.3", type: AsideButtonComponent, selector: "ipt-aside-button", inputs: { icon: "icon", text: "text",
|
|
13
|
+
AsideButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.3", type: AsideButtonComponent, selector: "ipt-aside-button", inputs: { icon: "icon", text: "text", buttonActive: "buttonActive" }, outputs: { isClicked: "isClicked" }, ngImport: i0, template: `
|
|
14
14
|
<div [ngSwitch]="buttonActive">
|
|
15
15
|
<a *ngSwitchCase="0" class="flex-item-menu__link" (click)="clickAction()">
|
|
16
16
|
<img src="{{ icon }}" alt="icon_url" />
|
|
17
|
-
<p
|
|
17
|
+
<p>{{ text }}</p>
|
|
18
18
|
</a>
|
|
19
19
|
|
|
20
20
|
<a *ngSwitchCase="1" class="flex-item-menu__link flex-item-active" (click)="clickAction()">
|
|
21
21
|
<img src="{{ icon }}" alt="icon_url" />
|
|
22
|
-
<p
|
|
22
|
+
<p>{{ text }}</p>
|
|
23
23
|
</a>
|
|
24
24
|
</div>
|
|
25
|
-
`, isInline: true, styles: ["*{font-family:Poppins,sans-serif}@media (min-width: 320px){.flex-item-menu__link{cursor:pointer;width:-webkit-fill-available;width:-moz-available;text-decoration:none;display:flex;justify-items:center;padding:.4rem 1rem;transition:all .3s ease 0s;border-radius:30px;margin:15px}.flex-item-menu__link img{cursor:pointer;width:
|
|
25
|
+
`, isInline: true, styles: ["*{font-family:Poppins,sans-serif}@media (min-width: 320px){.flex-item-menu__link{cursor:pointer;width:-webkit-fill-available;width:-moz-available;text-decoration:none;display:flex;justify-items:center;padding:.4rem 1rem;transition:all .3s ease 0s;border-radius:30px;margin:15px}.flex-item-menu__link img{cursor:pointer;width:2.5rem;height:2.5rem;padding:.4rem}.flex-item-menu__link p{cursor:pointer;display:inline;font-weight:500;font-family:Poppins,sans-serif;font-size:16px;padding:0 .8rem;margin:auto 0}a:hover,a:focus,.flex-item-menu__link:hover,.flex-item-menu__link p:focus{color:#fff;background-color:#ffffff4f;-webkit-backdrop-filter:blur(100px);backdrop-filter:blur(100px);box-shadow:#0006 0 30px 90px;border-radius:50px;font-size:18px}.flex-item-img{width:2.5rem;height:2.5rem;padding:.4rem}.flex-item-active{box-shadow:#0006 0 30px 90px;background:transparent;border:1px solid white}}@media (min-width: 1024px){.flex-item-menu__link{padding:.4rem 1rem}.flex-item-menu__link:focus{border:1px solid white}.flex-item-menu__link img{cursor:pointer;width:2.5rem;height:2.5rem;padding:.4rem}.flex-item-menu__link p{font-size:16px}a:hover,a:focus,.flex-item-menu__link:hover,.flex-item-menu__link p:focus{color:#fff;background-color:#ffffff4f;-webkit-backdrop-filter:blur(100px);backdrop-filter:blur(100px);box-shadow:#0006 0 30px 90px;font-size:18px}.flex-item-img{width:2.5rem;height:2.5rem;padding:.4rem}}\n"], directives: [{ type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }] });
|
|
26
26
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.3", ngImport: i0, type: AsideButtonComponent, decorators: [{
|
|
27
27
|
type: Component,
|
|
28
28
|
args: [{ selector: 'ipt-aside-button', template: `
|
|
29
29
|
<div [ngSwitch]="buttonActive">
|
|
30
30
|
<a *ngSwitchCase="0" class="flex-item-menu__link" (click)="clickAction()">
|
|
31
31
|
<img src="{{ icon }}" alt="icon_url" />
|
|
32
|
-
<p
|
|
32
|
+
<p>{{ text }}</p>
|
|
33
33
|
</a>
|
|
34
34
|
|
|
35
35
|
<a *ngSwitchCase="1" class="flex-item-menu__link flex-item-active" (click)="clickAction()">
|
|
36
36
|
<img src="{{ icon }}" alt="icon_url" />
|
|
37
|
-
<p
|
|
37
|
+
<p>{{ text }}</p>
|
|
38
38
|
</a>
|
|
39
39
|
</div>
|
|
40
|
-
`, styles: ["*{font-family:Poppins,sans-serif}@media (min-width: 320px){.flex-item-menu__link{cursor:pointer;width:-webkit-fill-available;width:-moz-available;text-decoration:none;display:flex;justify-items:center;padding:.4rem 1rem;transition:all .3s ease 0s;border-radius:30px;margin:15px}.flex-item-menu__link img{cursor:pointer;width:
|
|
40
|
+
`, styles: ["*{font-family:Poppins,sans-serif}@media (min-width: 320px){.flex-item-menu__link{cursor:pointer;width:-webkit-fill-available;width:-moz-available;text-decoration:none;display:flex;justify-items:center;padding:.4rem 1rem;transition:all .3s ease 0s;border-radius:30px;margin:15px}.flex-item-menu__link img{cursor:pointer;width:2.5rem;height:2.5rem;padding:.4rem}.flex-item-menu__link p{cursor:pointer;display:inline;font-weight:500;font-family:Poppins,sans-serif;font-size:16px;padding:0 .8rem;margin:auto 0}a:hover,a:focus,.flex-item-menu__link:hover,.flex-item-menu__link p:focus{color:#fff;background-color:#ffffff4f;-webkit-backdrop-filter:blur(100px);backdrop-filter:blur(100px);box-shadow:#0006 0 30px 90px;border-radius:50px;font-size:18px}.flex-item-img{width:2.5rem;height:2.5rem;padding:.4rem}.flex-item-active{box-shadow:#0006 0 30px 90px;background:transparent;border:1px solid white}}@media (min-width: 1024px){.flex-item-menu__link{padding:.4rem 1rem}.flex-item-menu__link:focus{border:1px solid white}.flex-item-menu__link img{cursor:pointer;width:2.5rem;height:2.5rem;padding:.4rem}.flex-item-menu__link p{font-size:16px}a:hover,a:focus,.flex-item-menu__link:hover,.flex-item-menu__link p:focus{color:#fff;background-color:#ffffff4f;-webkit-backdrop-filter:blur(100px);backdrop-filter:blur(100px);box-shadow:#0006 0 30px 90px;font-size:18px}.flex-item-img{width:2.5rem;height:2.5rem;padding:.4rem}}\n"] }]
|
|
41
41
|
}], propDecorators: { icon: [{
|
|
42
42
|
type: Input
|
|
43
43
|
}], text: [{
|
|
44
44
|
type: Input
|
|
45
|
-
}], type: [{
|
|
46
|
-
type: Input
|
|
47
|
-
}], url: [{
|
|
48
|
-
type: Input
|
|
49
|
-
}], textColor: [{
|
|
50
|
-
type: Input
|
|
51
45
|
}], buttonActive: [{
|
|
52
46
|
type: Input
|
|
53
47
|
}], isClicked: [{
|
|
54
48
|
type: Output
|
|
55
49
|
}] } });
|
|
56
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
50
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXNpZGUtYnV0dG9uLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL2Rlc2lnbi1zeXN0ZW0vc3JjL2xpYi9jb21wb25lbnRzL2F0b21zL2FzaWRlLWJ1dHRvbi9hc2lkZS1idXR0b24uY29tcG9uZW50LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxTQUFTLEVBQUUsWUFBWSxFQUFFLEtBQUssR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z1cImZsZXgtaXRlbS1tZW51X19saW5rIGZsZXgtaXRlbS1hY3RpdmVcIiAoY2xpY2spPVwiY2xpY2tBY3Rpb24oKVwiPlxuICAgICAgICA8aW1nIHNyYz1cInt7IGljb24gfX1cIiBhbHQ9XCJpY29uX3VybFwiIC8+XG4gICAgICAgIDxwPnt7IHRleHQgfX08L3A+XG4gICAgICA8L2E+XG4gICAgPC9kaXY+XG4gIGAsXG4gIHN0eWxlVXJsczogWycuL2FzaWRlLWJ1dHRvbi5jc3MnXVxufSlcblxuZXhwb3J0IGNsYXNzIEFzaWRlQnV0dG9uQ29tcG9uZW50IHtcbiAgQElucHV0KCkgaWNvbiE6IHN0cmluZztcbiAgQElucHV0KCkgdGV4dCE6IHN0cmluZztcbiAgQElucHV0KCkgYnV0dG9uQWN0aXZlPzogYm9vbGVhbjtcbiAgQE91dHB1dCgpIGlzQ2xpY2tlZCA9IG5ldyBFdmVudEVtaXR0ZXI8Ym9vbGVhbj4oKTtcblxuICBjbGlja0FjdGlvbigpIHtcbiAgICB0aGlzLmlzQ2xpY2tlZC5lbWl0KHRydWUpO1xuICB9XG59XG4iXX0=
|
|
@@ -1,94 +1,143 @@
|
|
|
1
1
|
import { Component, Input, Output, EventEmitter } from '@angular/core';
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
import * as i1 from "../../../core/services/user-service/user-service";
|
|
4
|
-
import * as i2 from "../../../core/
|
|
5
|
-
import * as i3 from "
|
|
6
|
-
import * as i4 from "@angular/material/
|
|
7
|
-
import * as i5 from "@angular/material/
|
|
8
|
-
import * as i6 from "
|
|
9
|
-
import * as i7 from "@angular/
|
|
10
|
-
import * as i8 from "../../atoms/aside-button/aside-button.component";
|
|
11
|
-
import * as i9 from "@angular/common";
|
|
4
|
+
import * as i2 from "../../../core/services/storage-service/storage-service";
|
|
5
|
+
import * as i3 from "@angular/material/sidenav";
|
|
6
|
+
import * as i4 from "@angular/material/toolbar";
|
|
7
|
+
import * as i5 from "@angular/material/list";
|
|
8
|
+
import * as i6 from "../../atoms/aside-button/aside-button.component";
|
|
9
|
+
import * as i7 from "@angular/common";
|
|
12
10
|
export class SidenavComponent {
|
|
13
|
-
constructor(userService,
|
|
11
|
+
constructor(userService, storageService) {
|
|
14
12
|
this.userService = userService;
|
|
15
|
-
this.baseService = baseService;
|
|
16
13
|
this.storageService = storageService;
|
|
17
14
|
this.pageChangeEvent = new EventEmitter();
|
|
18
15
|
this.routes = [];
|
|
16
|
+
this.options = { weekday: 'long', month: 'long', day: 'numeric' };
|
|
17
|
+
this.currentDay = new Date().toLocaleDateString('en-EN', this.options);
|
|
18
|
+
this.hour = new Date().getHours();
|
|
19
19
|
}
|
|
20
20
|
ngOnInit() {
|
|
21
21
|
let user = this.storageService.getCurrentUser()?.token;
|
|
22
22
|
let token = user === undefined ? '' : user;
|
|
23
23
|
let request = {
|
|
24
|
-
token: token
|
|
24
|
+
token: token,
|
|
25
25
|
};
|
|
26
|
-
this.userService.getRoutesForRole(request).subscribe(response => {
|
|
26
|
+
this.userService.getRoutesForRole(request).subscribe((response) => {
|
|
27
27
|
this.routes = response.data;
|
|
28
28
|
});
|
|
29
29
|
}
|
|
30
30
|
clickPage(event) {
|
|
31
31
|
this.pageChangeEvent.emit(event);
|
|
32
32
|
}
|
|
33
|
+
logout() {
|
|
34
|
+
this.storageService.logout();
|
|
35
|
+
}
|
|
33
36
|
}
|
|
34
|
-
SidenavComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.3", ngImport: i0, type: SidenavComponent, deps: [{ token: i1.UserService }, { token: i2.
|
|
35
|
-
SidenavComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.3", type: SidenavComponent, selector: "ipt-sidenav", inputs: { department: "department", setPage: "setPage" }, outputs: { pageChangeEvent: "pageChangeEvent" }, ngImport: i0, template: `
|
|
36
|
-
<mat-sidenav #sidenav mode="push">
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
37
|
+
SidenavComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.3", ngImport: i0, type: SidenavComponent, deps: [{ token: i1.UserService }, { token: i2.StorageService }], target: i0.ɵɵFactoryTarget.Component });
|
|
38
|
+
SidenavComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.3", type: SidenavComponent, selector: "ipt-sidenav", inputs: { department: "department", setPage: "setPage", userName: "userName" }, outputs: { pageChangeEvent: "pageChangeEvent" }, ngImport: i0, template: `
|
|
39
|
+
<mat-sidenav #sidenav mode="push" >
|
|
40
|
+
<mat-toolbar color="primary" (click)="sidenav.toggle()">
|
|
41
|
+
<span style="font-size: 15px;">{{department}}</span>
|
|
42
|
+
<span class="menu-icon-close"></span>
|
|
43
|
+
</mat-toolbar>
|
|
44
|
+
|
|
45
|
+
<mat-nav-list *ngFor="let route of routes">
|
|
46
|
+
<nav class="flex-container-menu">
|
|
47
|
+
<ipt-aside-button
|
|
48
|
+
[buttonActive]="this.setPage === route.page"
|
|
49
|
+
[icon]="route.icon"
|
|
50
|
+
[text]="route.text"
|
|
51
|
+
(isClicked)="clickPage(route.page)"
|
|
52
|
+
>
|
|
53
|
+
</ipt-aside-button>
|
|
54
|
+
</nav>
|
|
55
|
+
</mat-nav-list>
|
|
56
|
+
</mat-sidenav>
|
|
57
|
+
|
|
58
|
+
<mat-toolbar class="header">
|
|
59
|
+
<div class="menu-container" (click)="sidenav.toggle()">
|
|
60
|
+
<p>Menu</p>
|
|
61
|
+
<div class="menu-icon"></div>
|
|
62
|
+
</div>
|
|
63
|
+
|
|
64
|
+
<img class="img-logo" src="/assets/logos/IPT-logo.png" alt="" />
|
|
65
|
+
|
|
66
|
+
<div class="text-container">
|
|
67
|
+
<span class="p1">{{ currentDay }}</span>
|
|
68
|
+
<span *ngIf="hour >= 0 && hour < 12" class="p2">
|
|
69
|
+
Hey {{ userName }}, Good moorning!
|
|
70
|
+
</span>
|
|
71
|
+
<p *ngIf="hour >= 12 && hour < 18" class="p2">
|
|
72
|
+
Hey {{ userName }}, Good afternoon!
|
|
73
|
+
</p>
|
|
74
|
+
<p *ngIf="hour >= 18 && hour < 24" class="p2">
|
|
75
|
+
Hey {{ userName }}, Good evening!
|
|
76
|
+
</p>
|
|
77
|
+
</div>
|
|
44
78
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
[icon]="route.icon"
|
|
52
|
-
[text]="route.text"
|
|
53
|
-
(isClicked)="clickPage(route.page)"
|
|
54
|
-
>
|
|
55
|
-
</ipt-aside-button>
|
|
56
|
-
</nav>
|
|
57
|
-
</mat-nav-list>
|
|
58
|
-
</mat-sidenav>
|
|
59
|
-
`, isInline: true, styles: [""], components: [{ type: i4.MatSidenav, selector: "mat-sidenav", inputs: ["fixedInViewport", "fixedTopGap", "fixedBottomGap"], exportAs: ["matSidenav"] }, { type: i5.MatToolbar, selector: "mat-toolbar", inputs: ["color"], exportAs: ["matToolbar"] }, { type: i6.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i7.MatNavList, selector: "mat-nav-list", inputs: ["disableRipple", "disabled"], exportAs: ["matNavList"] }, { type: i8.AsideButtonComponent, selector: "ipt-aside-button", inputs: ["icon", "text", "type", "url", "textColor", "buttonActive"], outputs: ["isClicked"] }], directives: [{ type: i9.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
79
|
+
<div class="logout-container" (click)="logout()">
|
|
80
|
+
<p class="logout-button">Cerrar sesión</p>
|
|
81
|
+
<div class="photo-logout"></div>
|
|
82
|
+
</div>
|
|
83
|
+
</mat-toolbar>
|
|
84
|
+
`, isInline: true, styles: ["*{font-family:Poppins,sans-serif}@media screen and (min-width: 320px){.header{background-color:#fff;display:flex;justify-content:space-between;filter:drop-shadow(0px -1px 7px #000)}mat-sidenav{width:-moz-fit-content!important;width:fit-content!important;background-color:#1c77f7!important}.img-logo,.text-container{display:none}.mat-toolbar.mat-primary{background-color:#fff!important;color:#003d99!important;filter:drop-shadow(0px -1px 7px #000)}.icon{background-image:url(/assets/icons/icono-buscador.png);background-size:cover;background-position:center;width:40px;height:40px}.icons-container{border-radius:30px;height:50px;display:flex;justify-content:center;align-items:center;gap:5%;width:auto}.notification-icon{height:35px;width:35px;background-image:url(/assets/icons/notification-icon.png);background-position:center;background-size:cover;background-repeat:no-repeat}.settings{height:35px;width:35px;background-image:url(/assets/icons/settings.png);background-position:center;background-size:cover;background-repeat:no-repeat}.help{background:url(/assets/icons/help.png);background-position:center;background-size:cover;background-repeat:no-repeat;width:35px;height:35px;border-radius:50%}.hr-icons{border:none;border-left:1px solid #1c77f7;height:70%;width:1px}.hr-icon-search{border:none;border-left:1px solid #1c77f7;height:100%;width:1px}.profile-container{box-shadow:#11111a1a 0 8px 24px,#11111a1a 0 16px 56px,#11111a1a 0 24px 80px;height:35px;width:auto;border-radius:30px;display:flex;margin-left:10px}.name-profile{display:flex;align-items:center;color:#1c77f7;font-weight:500;font-size:16px;margin-left:20px;text-align:center;width:150px}.photo-profile{background:url(/assets/icons/photo-profile.png);background-size:40px 40px;background-position:center;background-repeat:no-repeat}.main-search-container{display:none}}@media screen and (min-width: 768px){.img-logo{display:flex;width:120px;height:60px}.text-container{border-radius:40px;height:45px;width:100%;display:flex;gap:-100px;justify-content:center;flex-direction:column;align-items:flex-start}.p1{color:gray;margin-left:30px;font-size:13px;height:20px}.p2{margin-left:30px;font-size:14px;font-weight:600;color:#1c77f7}.main-search-container{display:flex;justify-content:flex-end;align-items:center;width:-moz-available}.search-container{margin-right:10px;height:20px;width:20px;border-radius:30px;padding:10px;display:flex;justify-content:center;align-items:center;cursor:pointer;transition:.4s;box-shadow:#11111a1a 0 8px 24px,#11111a1a 0 16px 56px,#11111a1a 0 24px 80px}.search-container:hover{width:300px;border-radius:30px;padding:10px 10px 10px 20px}.search-container:hover>.search-input{width:320px;border-radius:10px;padding-left:15px}.search-input{background:transparent;border:none;outline:none;width:0px;font-size:13px;transition:.8s}}\n"], components: [{ type: i3.MatSidenav, selector: "mat-sidenav", inputs: ["fixedInViewport", "fixedTopGap", "fixedBottomGap"], exportAs: ["matSidenav"] }, { type: i4.MatToolbar, selector: "mat-toolbar", inputs: ["color"], exportAs: ["matToolbar"] }, { type: i5.MatNavList, selector: "mat-nav-list", inputs: ["disableRipple", "disabled"], exportAs: ["matNavList"] }, { type: i6.AsideButtonComponent, selector: "ipt-aside-button", inputs: ["icon", "text", "buttonActive"], outputs: ["isClicked"] }], directives: [{ type: i7.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i7.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
60
85
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.3", ngImport: i0, type: SidenavComponent, decorators: [{
|
|
61
86
|
type: Component,
|
|
62
87
|
args: [{ selector: 'ipt-sidenav', template: `
|
|
63
|
-
<mat-sidenav #sidenav mode="push">
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
<mat-icon>Menu</mat-icon>
|
|
69
|
-
</button>
|
|
70
|
-
</mat-toolbar>
|
|
88
|
+
<mat-sidenav #sidenav mode="push" >
|
|
89
|
+
<mat-toolbar color="primary" (click)="sidenav.toggle()">
|
|
90
|
+
<span style="font-size: 15px;">{{department}}</span>
|
|
91
|
+
<span class="menu-icon-close"></span>
|
|
92
|
+
</mat-toolbar>
|
|
71
93
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
94
|
+
<mat-nav-list *ngFor="let route of routes">
|
|
95
|
+
<nav class="flex-container-menu">
|
|
96
|
+
<ipt-aside-button
|
|
97
|
+
[buttonActive]="this.setPage === route.page"
|
|
98
|
+
[icon]="route.icon"
|
|
99
|
+
[text]="route.text"
|
|
100
|
+
(isClicked)="clickPage(route.page)"
|
|
101
|
+
>
|
|
102
|
+
</ipt-aside-button>
|
|
103
|
+
</nav>
|
|
104
|
+
</mat-nav-list>
|
|
105
|
+
</mat-sidenav>
|
|
106
|
+
|
|
107
|
+
<mat-toolbar class="header">
|
|
108
|
+
<div class="menu-container" (click)="sidenav.toggle()">
|
|
109
|
+
<p>Menu</p>
|
|
110
|
+
<div class="menu-icon"></div>
|
|
111
|
+
</div>
|
|
112
|
+
|
|
113
|
+
<img class="img-logo" src="/assets/logos/IPT-logo.png" alt="" />
|
|
114
|
+
|
|
115
|
+
<div class="text-container">
|
|
116
|
+
<span class="p1">{{ currentDay }}</span>
|
|
117
|
+
<span *ngIf="hour >= 0 && hour < 12" class="p2">
|
|
118
|
+
Hey {{ userName }}, Good moorning!
|
|
119
|
+
</span>
|
|
120
|
+
<p *ngIf="hour >= 12 && hour < 18" class="p2">
|
|
121
|
+
Hey {{ userName }}, Good afternoon!
|
|
122
|
+
</p>
|
|
123
|
+
<p *ngIf="hour >= 18 && hour < 24" class="p2">
|
|
124
|
+
Hey {{ userName }}, Good evening!
|
|
125
|
+
</p>
|
|
126
|
+
</div>
|
|
127
|
+
|
|
128
|
+
<div class="logout-container" (click)="logout()">
|
|
129
|
+
<p class="logout-button">Cerrar sesión</p>
|
|
130
|
+
<div class="photo-logout"></div>
|
|
131
|
+
</div>
|
|
132
|
+
</mat-toolbar>
|
|
133
|
+
`, styles: ["*{font-family:Poppins,sans-serif}@media screen and (min-width: 320px){.header{background-color:#fff;display:flex;justify-content:space-between;filter:drop-shadow(0px -1px 7px #000)}mat-sidenav{width:-moz-fit-content!important;width:fit-content!important;background-color:#1c77f7!important}.img-logo,.text-container{display:none}.mat-toolbar.mat-primary{background-color:#fff!important;color:#003d99!important;filter:drop-shadow(0px -1px 7px #000)}.icon{background-image:url(/assets/icons/icono-buscador.png);background-size:cover;background-position:center;width:40px;height:40px}.icons-container{border-radius:30px;height:50px;display:flex;justify-content:center;align-items:center;gap:5%;width:auto}.notification-icon{height:35px;width:35px;background-image:url(/assets/icons/notification-icon.png);background-position:center;background-size:cover;background-repeat:no-repeat}.settings{height:35px;width:35px;background-image:url(/assets/icons/settings.png);background-position:center;background-size:cover;background-repeat:no-repeat}.help{background:url(/assets/icons/help.png);background-position:center;background-size:cover;background-repeat:no-repeat;width:35px;height:35px;border-radius:50%}.hr-icons{border:none;border-left:1px solid #1c77f7;height:70%;width:1px}.hr-icon-search{border:none;border-left:1px solid #1c77f7;height:100%;width:1px}.profile-container{box-shadow:#11111a1a 0 8px 24px,#11111a1a 0 16px 56px,#11111a1a 0 24px 80px;height:35px;width:auto;border-radius:30px;display:flex;margin-left:10px}.name-profile{display:flex;align-items:center;color:#1c77f7;font-weight:500;font-size:16px;margin-left:20px;text-align:center;width:150px}.photo-profile{background:url(/assets/icons/photo-profile.png);background-size:40px 40px;background-position:center;background-repeat:no-repeat}.main-search-container{display:none}}@media screen and (min-width: 768px){.img-logo{display:flex;width:120px;height:60px}.text-container{border-radius:40px;height:45px;width:100%;display:flex;gap:-100px;justify-content:center;flex-direction:column;align-items:flex-start}.p1{color:gray;margin-left:30px;font-size:13px;height:20px}.p2{margin-left:30px;font-size:14px;font-weight:600;color:#1c77f7}.main-search-container{display:flex;justify-content:flex-end;align-items:center;width:-moz-available}.search-container{margin-right:10px;height:20px;width:20px;border-radius:30px;padding:10px;display:flex;justify-content:center;align-items:center;cursor:pointer;transition:.4s;box-shadow:#11111a1a 0 8px 24px,#11111a1a 0 16px 56px,#11111a1a 0 24px 80px}.search-container:hover{width:300px;border-radius:30px;padding:10px 10px 10px 20px}.search-container:hover>.search-input{width:320px;border-radius:10px;padding-left:15px}.search-input{background:transparent;border:none;outline:none;width:0px;font-size:13px;transition:.8s}}\n"] }]
|
|
134
|
+
}], ctorParameters: function () { return [{ type: i1.UserService }, { type: i2.StorageService }]; }, propDecorators: { department: [{
|
|
88
135
|
type: Input
|
|
89
136
|
}], setPage: [{
|
|
90
137
|
type: Input
|
|
138
|
+
}], userName: [{
|
|
139
|
+
type: Input
|
|
91
140
|
}], pageChangeEvent: [{
|
|
92
141
|
type: Output
|
|
93
142
|
}] } });
|
|
94
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
143
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2lkZW5hdi5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9kZXNpZ24tc3lzdGVtL3NyYy9saWIvY29tcG9uZW50cy9tb2xlY3VsZXMvc2lkZW5hdi9zaWRlbmF2LmNvbXBvbmVudC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsU0FBUyxFQUFFLEtBQUssRUFBRSxNQUFNLEVBQUUsWUFBWSxFQUFVLE1BQU0sZUFBZSxDQUFDOzs7Ozs7Ozs7QUF3RC9FLE1BQU0sT0FBTyxnQkFBZ0I7SUFXM0IsWUFDVSxXQUF3QixFQUN4QixjQUE4QjtRQUQ5QixnQkFBVyxHQUFYLFdBQVcsQ0FBYTtRQUN4QixtQkFBYyxHQUFkLGNBQWMsQ0FBZ0I7UUFUOUIsb0JBQWUsR0FBRyxJQUFJLFlBQVksRUFBVSxDQUFDO1FBRXZELFdBQU0sR0FBVSxFQUFFLENBQUM7UUFDbkIsWUFBTyxHQUFRLEVBQUUsT0FBTyxFQUFFLE1BQU0sRUFBRSxLQUFLLEVBQUUsTUFBTSxFQUFFLEdBQUcsRUFBR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hbnkgPSB7IHdlZWtkYXk6ICdsb25nJywgbW9udGg6ICdsb25nJywgZGF5OiAnbnVtZXJpYycgfTtcbiAgY3VycmVudERheSA9IG5ldyBEYXRlKCkudG9Mb2NhbGVEYXRlU3RyaW5nKCdlbi1FTicsIHRoaXMub3B0aW9ucyk7XG4gIGhvdXIgPSBuZXcgRGF0ZSgpLmdldEhvdXJzKCk7XG5cbiAgY29uc3RydWN0b3IoXG4gICAgcHJpdmF0ZSB1c2VyU2VydmljZTogVXNlclNlcnZpY2UsXG4gICAgcHJpdmF0ZSBzdG9yYWdlU2VydmljZTogU3RvcmFnZVNlcnZpY2VcbiAgKSB7fVxuXG4gIG5nT25Jbml0KCk6IHZvaWQge1xuICAgIGxldCB1c2VyID0gdGhpcy5zdG9yYWdlU2VydmljZS5nZXRDdXJyZW50VXNlcigpPy50b2tlbjtcbiAgICBsZXQgdG9rZW46IHN0cmluZyA9IHVzZXIgPT09IHVuZGVmaW5lZCA/ICcnIDogdXNlcjtcblxuICAgIGxldCByZXF1ZXN0OiBVc2VyVG9rZW5ScSA9IHtcbiAgICAgIHRva2VuOiB0b2tlbixcbiAgICB9O1xuXG4gICAgdGhpcy51c2VyU2VydmljZS5nZXRSb3V0ZXNGb3JSb2xlKHJlcXVlc3QpLnN1YnNjcmliZSgocmVzcG9uc2UpID0+IHtcbiAgICAgIHRoaXMucm91dGVzID0gcmVzcG9uc2UuZGF0YTtcbiAgICB9KTtcbiAgfVxuXG4gIGNsaWNrUGFnZShldmVudDogc3RyaW5nKSB7XG4gICAgdGhpcy5wYWdlQ2hhbmdlRXZlbnQuZW1pdChldmVudCk7XG4gIH1cblxuICBsb2dvdXQoKSB7XG4gICAgdGhpcy5zdG9yYWdlU2VydmljZS5sb2dvdXQoKTtcbiAgfVxufVxuIl19
|
|
@@ -8,14 +8,13 @@ import { Validators, FormsModule, ReactiveFormsModule } from '@angular/forms';
|
|
|
8
8
|
import Swal from 'sweetalert2';
|
|
9
9
|
import * as i1$2 from '@angular/common/http';
|
|
10
10
|
import { HttpHeaders } from '@angular/common/http';
|
|
11
|
-
import * as
|
|
11
|
+
import * as i3 from '@angular/material/sidenav';
|
|
12
12
|
import { MatSidenavModule } from '@angular/material/sidenav';
|
|
13
|
-
import * as
|
|
13
|
+
import * as i4 from '@angular/material/toolbar';
|
|
14
14
|
import { MatToolbarModule } from '@angular/material/toolbar';
|
|
15
|
-
import * as
|
|
16
|
-
import { MatIconModule } from '@angular/material/icon';
|
|
17
|
-
import * as i7 from '@angular/material/list';
|
|
15
|
+
import * as i5 from '@angular/material/list';
|
|
18
16
|
import { MatListModule } from '@angular/material/list';
|
|
17
|
+
import { MatIconModule } from '@angular/material/icon';
|
|
19
18
|
import * as i1$3 from '@angular/router';
|
|
20
19
|
|
|
21
20
|
class AsideButtonComponent {
|
|
@@ -27,44 +26,38 @@ class AsideButtonComponent {
|
|
|
27
26
|
}
|
|
28
27
|
}
|
|
29
28
|
AsideButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.3", ngImport: i0, type: AsideButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
30
|
-
AsideButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.3", type: AsideButtonComponent, selector: "ipt-aside-button", inputs: { icon: "icon", text: "text",
|
|
29
|
+
AsideButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.3", type: AsideButtonComponent, selector: "ipt-aside-button", inputs: { icon: "icon", text: "text", buttonActive: "buttonActive" }, outputs: { isClicked: "isClicked" }, ngImport: i0, template: `
|
|
31
30
|
<div [ngSwitch]="buttonActive">
|
|
32
31
|
<a *ngSwitchCase="0" class="flex-item-menu__link" (click)="clickAction()">
|
|
33
32
|
<img src="{{ icon }}" alt="icon_url" />
|
|
34
|
-
<p
|
|
33
|
+
<p>{{ text }}</p>
|
|
35
34
|
</a>
|
|
36
35
|
|
|
37
36
|
<a *ngSwitchCase="1" class="flex-item-menu__link flex-item-active" (click)="clickAction()">
|
|
38
37
|
<img src="{{ icon }}" alt="icon_url" />
|
|
39
|
-
<p
|
|
38
|
+
<p>{{ text }}</p>
|
|
40
39
|
</a>
|
|
41
40
|
</div>
|
|
42
|
-
`, isInline: true, styles: ["*{font-family:Poppins,sans-serif}@media (min-width: 320px){.flex-item-menu__link{cursor:pointer;width:-webkit-fill-available;width:-moz-available;text-decoration:none;display:flex;justify-items:center;padding:.4rem 1rem;transition:all .3s ease 0s;border-radius:30px;margin:15px}.flex-item-menu__link img{cursor:pointer;width:
|
|
41
|
+
`, isInline: true, styles: ["*{font-family:Poppins,sans-serif}@media (min-width: 320px){.flex-item-menu__link{cursor:pointer;width:-webkit-fill-available;width:-moz-available;text-decoration:none;display:flex;justify-items:center;padding:.4rem 1rem;transition:all .3s ease 0s;border-radius:30px;margin:15px}.flex-item-menu__link img{cursor:pointer;width:2.5rem;height:2.5rem;padding:.4rem}.flex-item-menu__link p{cursor:pointer;display:inline;font-weight:500;font-family:Poppins,sans-serif;font-size:16px;padding:0 .8rem;margin:auto 0}a:hover,a:focus,.flex-item-menu__link:hover,.flex-item-menu__link p:focus{color:#fff;background-color:#ffffff4f;-webkit-backdrop-filter:blur(100px);backdrop-filter:blur(100px);box-shadow:#0006 0 30px 90px;border-radius:50px;font-size:18px}.flex-item-img{width:2.5rem;height:2.5rem;padding:.4rem}.flex-item-active{box-shadow:#0006 0 30px 90px;background:transparent;border:1px solid white}}@media (min-width: 1024px){.flex-item-menu__link{padding:.4rem 1rem}.flex-item-menu__link:focus{border:1px solid white}.flex-item-menu__link img{cursor:pointer;width:2.5rem;height:2.5rem;padding:.4rem}.flex-item-menu__link p{font-size:16px}a:hover,a:focus,.flex-item-menu__link:hover,.flex-item-menu__link p:focus{color:#fff;background-color:#ffffff4f;-webkit-backdrop-filter:blur(100px);backdrop-filter:blur(100px);box-shadow:#0006 0 30px 90px;font-size:18px}.flex-item-img{width:2.5rem;height:2.5rem;padding:.4rem}}\n"], directives: [{ type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }] });
|
|
43
42
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.3", ngImport: i0, type: AsideButtonComponent, decorators: [{
|
|
44
43
|
type: Component,
|
|
45
44
|
args: [{ selector: 'ipt-aside-button', template: `
|
|
46
45
|
<div [ngSwitch]="buttonActive">
|
|
47
46
|
<a *ngSwitchCase="0" class="flex-item-menu__link" (click)="clickAction()">
|
|
48
47
|
<img src="{{ icon }}" alt="icon_url" />
|
|
49
|
-
<p
|
|
48
|
+
<p>{{ text }}</p>
|
|
50
49
|
</a>
|
|
51
50
|
|
|
52
51
|
<a *ngSwitchCase="1" class="flex-item-menu__link flex-item-active" (click)="clickAction()">
|
|
53
52
|
<img src="{{ icon }}" alt="icon_url" />
|
|
54
|
-
<p
|
|
53
|
+
<p>{{ text }}</p>
|
|
55
54
|
</a>
|
|
56
55
|
</div>
|
|
57
|
-
`, styles: ["*{font-family:Poppins,sans-serif}@media (min-width: 320px){.flex-item-menu__link{cursor:pointer;width:-webkit-fill-available;width:-moz-available;text-decoration:none;display:flex;justify-items:center;padding:.4rem 1rem;transition:all .3s ease 0s;border-radius:30px;margin:15px}.flex-item-menu__link img{cursor:pointer;width:
|
|
56
|
+
`, styles: ["*{font-family:Poppins,sans-serif}@media (min-width: 320px){.flex-item-menu__link{cursor:pointer;width:-webkit-fill-available;width:-moz-available;text-decoration:none;display:flex;justify-items:center;padding:.4rem 1rem;transition:all .3s ease 0s;border-radius:30px;margin:15px}.flex-item-menu__link img{cursor:pointer;width:2.5rem;height:2.5rem;padding:.4rem}.flex-item-menu__link p{cursor:pointer;display:inline;font-weight:500;font-family:Poppins,sans-serif;font-size:16px;padding:0 .8rem;margin:auto 0}a:hover,a:focus,.flex-item-menu__link:hover,.flex-item-menu__link p:focus{color:#fff;background-color:#ffffff4f;-webkit-backdrop-filter:blur(100px);backdrop-filter:blur(100px);box-shadow:#0006 0 30px 90px;border-radius:50px;font-size:18px}.flex-item-img{width:2.5rem;height:2.5rem;padding:.4rem}.flex-item-active{box-shadow:#0006 0 30px 90px;background:transparent;border:1px solid white}}@media (min-width: 1024px){.flex-item-menu__link{padding:.4rem 1rem}.flex-item-menu__link:focus{border:1px solid white}.flex-item-menu__link img{cursor:pointer;width:2.5rem;height:2.5rem;padding:.4rem}.flex-item-menu__link p{font-size:16px}a:hover,a:focus,.flex-item-menu__link:hover,.flex-item-menu__link p:focus{color:#fff;background-color:#ffffff4f;-webkit-backdrop-filter:blur(100px);backdrop-filter:blur(100px);box-shadow:#0006 0 30px 90px;font-size:18px}.flex-item-img{width:2.5rem;height:2.5rem;padding:.4rem}}\n"] }]
|
|
58
57
|
}], propDecorators: { icon: [{
|
|
59
58
|
type: Input
|
|
60
59
|
}], text: [{
|
|
61
60
|
type: Input
|
|
62
|
-
}], type: [{
|
|
63
|
-
type: Input
|
|
64
|
-
}], url: [{
|
|
65
|
-
type: Input
|
|
66
|
-
}], textColor: [{
|
|
67
|
-
type: Input
|
|
68
61
|
}], buttonActive: [{
|
|
69
62
|
type: Input
|
|
70
63
|
}], isClicked: [{
|
|
@@ -896,85 +889,136 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.3", ngImpor
|
|
|
896
889
|
}] } });
|
|
897
890
|
|
|
898
891
|
class SidenavComponent {
|
|
899
|
-
constructor(userService,
|
|
892
|
+
constructor(userService, storageService) {
|
|
900
893
|
this.userService = userService;
|
|
901
|
-
this.baseService = baseService;
|
|
902
894
|
this.storageService = storageService;
|
|
903
895
|
this.pageChangeEvent = new EventEmitter();
|
|
904
896
|
this.routes = [];
|
|
897
|
+
this.options = { weekday: 'long', month: 'long', day: 'numeric' };
|
|
898
|
+
this.currentDay = new Date().toLocaleDateString('en-EN', this.options);
|
|
899
|
+
this.hour = new Date().getHours();
|
|
905
900
|
}
|
|
906
901
|
ngOnInit() {
|
|
907
902
|
var _a;
|
|
908
903
|
let user = (_a = this.storageService.getCurrentUser()) === null || _a === void 0 ? void 0 : _a.token;
|
|
909
904
|
let token = user === undefined ? '' : user;
|
|
910
905
|
let request = {
|
|
911
|
-
token: token
|
|
906
|
+
token: token,
|
|
912
907
|
};
|
|
913
|
-
this.userService.getRoutesForRole(request).subscribe(response => {
|
|
908
|
+
this.userService.getRoutesForRole(request).subscribe((response) => {
|
|
914
909
|
this.routes = response.data;
|
|
915
910
|
});
|
|
916
911
|
}
|
|
917
912
|
clickPage(event) {
|
|
918
913
|
this.pageChangeEvent.emit(event);
|
|
919
914
|
}
|
|
915
|
+
logout() {
|
|
916
|
+
this.storageService.logout();
|
|
917
|
+
}
|
|
920
918
|
}
|
|
921
|
-
SidenavComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.3", ngImport: i0, type: SidenavComponent, deps: [{ token: UserService }, { token:
|
|
922
|
-
SidenavComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.3", type: SidenavComponent, selector: "ipt-sidenav", inputs: { department: "department", setPage: "setPage" }, outputs: { pageChangeEvent: "pageChangeEvent" }, ngImport: i0, template: `
|
|
923
|
-
<mat-sidenav #sidenav mode="push">
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
919
|
+
SidenavComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.3", ngImport: i0, type: SidenavComponent, deps: [{ token: UserService }, { token: StorageService }], target: i0.ɵɵFactoryTarget.Component });
|
|
920
|
+
SidenavComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.3", type: SidenavComponent, selector: "ipt-sidenav", inputs: { department: "department", setPage: "setPage", userName: "userName" }, outputs: { pageChangeEvent: "pageChangeEvent" }, ngImport: i0, template: `
|
|
921
|
+
<mat-sidenav #sidenav mode="push" >
|
|
922
|
+
<mat-toolbar color="primary" (click)="sidenav.toggle()">
|
|
923
|
+
<span style="font-size: 15px;">{{department}}</span>
|
|
924
|
+
<span class="menu-icon-close"></span>
|
|
925
|
+
</mat-toolbar>
|
|
926
|
+
|
|
927
|
+
<mat-nav-list *ngFor="let route of routes">
|
|
928
|
+
<nav class="flex-container-menu">
|
|
929
|
+
<ipt-aside-button
|
|
930
|
+
[buttonActive]="this.setPage === route.page"
|
|
931
|
+
[icon]="route.icon"
|
|
932
|
+
[text]="route.text"
|
|
933
|
+
(isClicked)="clickPage(route.page)"
|
|
934
|
+
>
|
|
935
|
+
</ipt-aside-button>
|
|
936
|
+
</nav>
|
|
937
|
+
</mat-nav-list>
|
|
938
|
+
</mat-sidenav>
|
|
939
|
+
|
|
940
|
+
<mat-toolbar class="header">
|
|
941
|
+
<div class="menu-container" (click)="sidenav.toggle()">
|
|
942
|
+
<p>Menu</p>
|
|
943
|
+
<div class="menu-icon"></div>
|
|
944
|
+
</div>
|
|
945
|
+
|
|
946
|
+
<img class="img-logo" src="/assets/logos/IPT-logo.png" alt="" />
|
|
931
947
|
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
948
|
+
<div class="text-container">
|
|
949
|
+
<span class="p1">{{ currentDay }}</span>
|
|
950
|
+
<span *ngIf="hour >= 0 && hour < 12" class="p2">
|
|
951
|
+
Hey {{ userName }}, Good moorning!
|
|
952
|
+
</span>
|
|
953
|
+
<p *ngIf="hour >= 12 && hour < 18" class="p2">
|
|
954
|
+
Hey {{ userName }}, Good afternoon!
|
|
955
|
+
</p>
|
|
956
|
+
<p *ngIf="hour >= 18 && hour < 24" class="p2">
|
|
957
|
+
Hey {{ userName }}, Good evening!
|
|
958
|
+
</p>
|
|
959
|
+
</div>
|
|
960
|
+
|
|
961
|
+
<div class="logout-container" (click)="logout()">
|
|
962
|
+
<p class="logout-button">Cerrar sesión</p>
|
|
963
|
+
<div class="photo-logout"></div>
|
|
964
|
+
</div>
|
|
965
|
+
</mat-toolbar>
|
|
966
|
+
`, isInline: true, styles: ["*{font-family:Poppins,sans-serif}@media screen and (min-width: 320px){.header{background-color:#fff;display:flex;justify-content:space-between;filter:drop-shadow(0px -1px 7px #000)}mat-sidenav{width:-moz-fit-content!important;width:fit-content!important;background-color:#1c77f7!important}.img-logo,.text-container{display:none}.mat-toolbar.mat-primary{background-color:#fff!important;color:#003d99!important;filter:drop-shadow(0px -1px 7px #000)}.icon{background-image:url(/assets/icons/icono-buscador.png);background-size:cover;background-position:center;width:40px;height:40px}.icons-container{border-radius:30px;height:50px;display:flex;justify-content:center;align-items:center;gap:5%;width:auto}.notification-icon{height:35px;width:35px;background-image:url(/assets/icons/notification-icon.png);background-position:center;background-size:cover;background-repeat:no-repeat}.settings{height:35px;width:35px;background-image:url(/assets/icons/settings.png);background-position:center;background-size:cover;background-repeat:no-repeat}.help{background:url(/assets/icons/help.png);background-position:center;background-size:cover;background-repeat:no-repeat;width:35px;height:35px;border-radius:50%}.hr-icons{border:none;border-left:1px solid #1c77f7;height:70%;width:1px}.hr-icon-search{border:none;border-left:1px solid #1c77f7;height:100%;width:1px}.profile-container{box-shadow:#11111a1a 0 8px 24px,#11111a1a 0 16px 56px,#11111a1a 0 24px 80px;height:35px;width:auto;border-radius:30px;display:flex;margin-left:10px}.name-profile{display:flex;align-items:center;color:#1c77f7;font-weight:500;font-size:16px;margin-left:20px;text-align:center;width:150px}.photo-profile{background:url(/assets/icons/photo-profile.png);background-size:40px 40px;background-position:center;background-repeat:no-repeat}.main-search-container{display:none}}@media screen and (min-width: 768px){.img-logo{display:flex;width:120px;height:60px}.text-container{border-radius:40px;height:45px;width:100%;display:flex;gap:-100px;justify-content:center;flex-direction:column;align-items:flex-start}.p1{color:gray;margin-left:30px;font-size:13px;height:20px}.p2{margin-left:30px;font-size:14px;font-weight:600;color:#1c77f7}.main-search-container{display:flex;justify-content:flex-end;align-items:center;width:-moz-available}.search-container{margin-right:10px;height:20px;width:20px;border-radius:30px;padding:10px;display:flex;justify-content:center;align-items:center;cursor:pointer;transition:.4s;box-shadow:#11111a1a 0 8px 24px,#11111a1a 0 16px 56px,#11111a1a 0 24px 80px}.search-container:hover{width:300px;border-radius:30px;padding:10px 10px 10px 20px}.search-container:hover>.search-input{width:320px;border-radius:10px;padding-left:15px}.search-input{background:transparent;border:none;outline:none;width:0px;font-size:13px;transition:.8s}}\n"], components: [{ type: i3.MatSidenav, selector: "mat-sidenav", inputs: ["fixedInViewport", "fixedTopGap", "fixedBottomGap"], exportAs: ["matSidenav"] }, { type: i4.MatToolbar, selector: "mat-toolbar", inputs: ["color"], exportAs: ["matToolbar"] }, { type: i5.MatNavList, selector: "mat-nav-list", inputs: ["disableRipple", "disabled"], exportAs: ["matNavList"] }, { type: AsideButtonComponent, selector: "ipt-aside-button", inputs: ["icon", "text", "buttonActive"], outputs: ["isClicked"] }], directives: [{ type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
947
967
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.3", ngImport: i0, type: SidenavComponent, decorators: [{
|
|
948
968
|
type: Component,
|
|
949
969
|
args: [{ selector: 'ipt-sidenav', template: `
|
|
950
|
-
<mat-sidenav #sidenav mode="push">
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
<mat-icon>Menu</mat-icon>
|
|
956
|
-
</button>
|
|
957
|
-
</mat-toolbar>
|
|
970
|
+
<mat-sidenav #sidenav mode="push" >
|
|
971
|
+
<mat-toolbar color="primary" (click)="sidenav.toggle()">
|
|
972
|
+
<span style="font-size: 15px;">{{department}}</span>
|
|
973
|
+
<span class="menu-icon-close"></span>
|
|
974
|
+
</mat-toolbar>
|
|
958
975
|
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
976
|
+
<mat-nav-list *ngFor="let route of routes">
|
|
977
|
+
<nav class="flex-container-menu">
|
|
978
|
+
<ipt-aside-button
|
|
979
|
+
[buttonActive]="this.setPage === route.page"
|
|
980
|
+
[icon]="route.icon"
|
|
981
|
+
[text]="route.text"
|
|
982
|
+
(isClicked)="clickPage(route.page)"
|
|
983
|
+
>
|
|
984
|
+
</ipt-aside-button>
|
|
985
|
+
</nav>
|
|
986
|
+
</mat-nav-list>
|
|
987
|
+
</mat-sidenav>
|
|
988
|
+
|
|
989
|
+
<mat-toolbar class="header">
|
|
990
|
+
<div class="menu-container" (click)="sidenav.toggle()">
|
|
991
|
+
<p>Menu</p>
|
|
992
|
+
<div class="menu-icon"></div>
|
|
993
|
+
</div>
|
|
994
|
+
|
|
995
|
+
<img class="img-logo" src="/assets/logos/IPT-logo.png" alt="" />
|
|
996
|
+
|
|
997
|
+
<div class="text-container">
|
|
998
|
+
<span class="p1">{{ currentDay }}</span>
|
|
999
|
+
<span *ngIf="hour >= 0 && hour < 12" class="p2">
|
|
1000
|
+
Hey {{ userName }}, Good moorning!
|
|
1001
|
+
</span>
|
|
1002
|
+
<p *ngIf="hour >= 12 && hour < 18" class="p2">
|
|
1003
|
+
Hey {{ userName }}, Good afternoon!
|
|
1004
|
+
</p>
|
|
1005
|
+
<p *ngIf="hour >= 18 && hour < 24" class="p2">
|
|
1006
|
+
Hey {{ userName }}, Good evening!
|
|
1007
|
+
</p>
|
|
1008
|
+
</div>
|
|
1009
|
+
|
|
1010
|
+
<div class="logout-container" (click)="logout()">
|
|
1011
|
+
<p class="logout-button">Cerrar sesión</p>
|
|
1012
|
+
<div class="photo-logout"></div>
|
|
1013
|
+
</div>
|
|
1014
|
+
</mat-toolbar>
|
|
1015
|
+
`, styles: ["*{font-family:Poppins,sans-serif}@media screen and (min-width: 320px){.header{background-color:#fff;display:flex;justify-content:space-between;filter:drop-shadow(0px -1px 7px #000)}mat-sidenav{width:-moz-fit-content!important;width:fit-content!important;background-color:#1c77f7!important}.img-logo,.text-container{display:none}.mat-toolbar.mat-primary{background-color:#fff!important;color:#003d99!important;filter:drop-shadow(0px -1px 7px #000)}.icon{background-image:url(/assets/icons/icono-buscador.png);background-size:cover;background-position:center;width:40px;height:40px}.icons-container{border-radius:30px;height:50px;display:flex;justify-content:center;align-items:center;gap:5%;width:auto}.notification-icon{height:35px;width:35px;background-image:url(/assets/icons/notification-icon.png);background-position:center;background-size:cover;background-repeat:no-repeat}.settings{height:35px;width:35px;background-image:url(/assets/icons/settings.png);background-position:center;background-size:cover;background-repeat:no-repeat}.help{background:url(/assets/icons/help.png);background-position:center;background-size:cover;background-repeat:no-repeat;width:35px;height:35px;border-radius:50%}.hr-icons{border:none;border-left:1px solid #1c77f7;height:70%;width:1px}.hr-icon-search{border:none;border-left:1px solid #1c77f7;height:100%;width:1px}.profile-container{box-shadow:#11111a1a 0 8px 24px,#11111a1a 0 16px 56px,#11111a1a 0 24px 80px;height:35px;width:auto;border-radius:30px;display:flex;margin-left:10px}.name-profile{display:flex;align-items:center;color:#1c77f7;font-weight:500;font-size:16px;margin-left:20px;text-align:center;width:150px}.photo-profile{background:url(/assets/icons/photo-profile.png);background-size:40px 40px;background-position:center;background-repeat:no-repeat}.main-search-container{display:none}}@media screen and (min-width: 768px){.img-logo{display:flex;width:120px;height:60px}.text-container{border-radius:40px;height:45px;width:100%;display:flex;gap:-100px;justify-content:center;flex-direction:column;align-items:flex-start}.p1{color:gray;margin-left:30px;font-size:13px;height:20px}.p2{margin-left:30px;font-size:14px;font-weight:600;color:#1c77f7}.main-search-container{display:flex;justify-content:flex-end;align-items:center;width:-moz-available}.search-container{margin-right:10px;height:20px;width:20px;border-radius:30px;padding:10px;display:flex;justify-content:center;align-items:center;cursor:pointer;transition:.4s;box-shadow:#11111a1a 0 8px 24px,#11111a1a 0 16px 56px,#11111a1a 0 24px 80px}.search-container:hover{width:300px;border-radius:30px;padding:10px 10px 10px 20px}.search-container:hover>.search-input{width:320px;border-radius:10px;padding-left:15px}.search-input{background:transparent;border:none;outline:none;width:0px;font-size:13px;transition:.8s}}\n"] }]
|
|
1016
|
+
}], ctorParameters: function () { return [{ type: UserService }, { type: StorageService }]; }, propDecorators: { department: [{
|
|
975
1017
|
type: Input
|
|
976
1018
|
}], setPage: [{
|
|
977
1019
|
type: Input
|
|
1020
|
+
}], userName: [{
|
|
1021
|
+
type: Input
|
|
978
1022
|
}], pageChangeEvent: [{
|
|
979
1023
|
type: Output
|
|
980
1024
|
}] } });
|