@cauca-911/material 12.0.0 → 13.0.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 (38) hide show
  1. package/cauca-911-material.d.ts +5 -5
  2. package/{esm2015/cauca-911-material.js → esm2020/cauca-911-material.mjs} +4 -4
  3. package/esm2020/lib/cauca-input-file/cauca-input-file.component.mjs +148 -0
  4. package/esm2020/lib/cauca-input-multiple-langue/cauca-input-multiple-langue.component.mjs +88 -0
  5. package/{esm2015/lib/cauca-material.component.js → esm2020/lib/cauca-material.component.mjs} +23 -27
  6. package/{esm2015/lib/cauca-material.module.js → esm2020/lib/cauca-material.module.mjs} +91 -91
  7. package/{esm2015/lib/cauca-material.service.js → esm2020/lib/cauca-material.service.mjs} +14 -14
  8. package/esm2020/lib/cauca-menu-sidebar/cauca-menu-sidebar.component.mjs +144 -0
  9. package/{esm2015/lib/cauca-menu-vertical/cauca-menu-vertical.component.js → esm2020/lib/cauca-menu-vertical/cauca-menu-vertical.component.mjs} +172 -181
  10. package/{esm2015/lib/cauca-simple-dialog/cauca-simple-dialog.component.js → esm2020/lib/cauca-simple-dialog/cauca-simple-dialog.component.mjs} +62 -66
  11. package/esm2020/lib/cauca-slideshow/cauca-slideshow.component.mjs +139 -0
  12. package/{esm2015/lib/shared/models/menu-item.js → esm2020/lib/shared/models/menu-item.mjs} +8 -8
  13. package/{esm2015/lib/shared/models/simple-dialog-data.js → esm2020/lib/shared/models/simple-dialog-data.mjs} +5 -5
  14. package/{esm2015/public-api.js → esm2020/public-api.mjs} +13 -13
  15. package/fesm2015/cauca-911-material.mjs +984 -0
  16. package/fesm2015/cauca-911-material.mjs.map +1 -0
  17. package/{fesm2015/cauca-911-material.js → fesm2020/cauca-911-material.mjs} +814 -854
  18. package/fesm2020/cauca-911-material.mjs.map +1 -0
  19. package/lib/cauca-input-file/cauca-input-file.component.d.ts +23 -23
  20. package/lib/cauca-input-multiple-langue/cauca-input-multiple-langue.component.d.ts +19 -19
  21. package/lib/cauca-material.component.d.ts +8 -8
  22. package/lib/cauca-material.module.d.ts +22 -22
  23. package/lib/cauca-material.service.d.ts +6 -6
  24. package/lib/cauca-menu-sidebar/cauca-menu-sidebar.component.d.ts +23 -23
  25. package/lib/cauca-menu-vertical/cauca-menu-vertical.component.d.ts +15 -15
  26. package/lib/cauca-simple-dialog/cauca-simple-dialog.component.d.ts +13 -13
  27. package/lib/cauca-slideshow/cauca-slideshow.component.d.ts +21 -21
  28. package/lib/shared/models/menu-item.d.ts +8 -8
  29. package/lib/shared/models/simple-dialog-data.d.ts +5 -5
  30. package/package.json +26 -13
  31. package/public-api.d.ts +10 -10
  32. package/bundles/cauca-911-material.umd.js +0 -1078
  33. package/bundles/cauca-911-material.umd.js.map +0 -1
  34. package/esm2015/lib/cauca-input-file/cauca-input-file.component.js +0 -152
  35. package/esm2015/lib/cauca-input-multiple-langue/cauca-input-multiple-langue.component.js +0 -94
  36. package/esm2015/lib/cauca-menu-sidebar/cauca-menu-sidebar.component.js +0 -152
  37. package/esm2015/lib/cauca-slideshow/cauca-slideshow.component.js +0 -144
  38. package/fesm2015/cauca-911-material.js.map +0 -1
@@ -0,0 +1,144 @@
1
+ import { Component, HostListener, Input } from '@angular/core';
2
+ import * as i0 from "@angular/core";
3
+ import * as i1 from "@angular/material/button";
4
+ import * as i2 from "@angular/material/icon";
5
+ import * as i3 from "../cauca-menu-vertical/cauca-menu-vertical.component";
6
+ import * as i4 from "@angular/common";
7
+ import * as i5 from "@ngx-translate/core";
8
+ function CaucaMenuSidebarComponent_div_10_Template(rf, ctx) { if (rf & 1) {
9
+ const _r3 = i0.ɵɵgetCurrentView();
10
+ i0.ɵɵelementStart(0, "div", 4)(1, "div", 5);
11
+ i0.ɵɵlistener("click", function CaucaMenuSidebarComponent_div_10_Template_div_click_1_listener() { i0.ɵɵrestoreView(_r3); const ctx_r2 = i0.ɵɵnextContext(); return ctx_r2.onToggleCollapse(); });
12
+ i0.ɵɵelementEnd();
13
+ i0.ɵɵelementStart(2, "span", 6);
14
+ i0.ɵɵtext(3);
15
+ i0.ɵɵpipe(4, "translate");
16
+ i0.ɵɵelementEnd();
17
+ i0.ɵɵelementStart(5, "span", 7);
18
+ i0.ɵɵtext(6);
19
+ i0.ɵɵelementEnd()();
20
+ } if (rf & 2) {
21
+ const ctx_r1 = i0.ɵɵnextContext();
22
+ i0.ɵɵadvance(3);
23
+ i0.ɵɵtextInterpolate2("", i0.ɵɵpipeBind1(4, 3, "material.version"), " ", ctx_r1.version, "");
24
+ i0.ɵɵadvance(3);
25
+ i0.ɵɵtextInterpolate(ctx_r1.version);
26
+ } }
27
+ const _c0 = [[["", "header", ""]], [["", "beforeMenu", ""]], [["", "afterMenu", ""]]];
28
+ const _c1 = ["[header]", "[beforeMenu]", "[afterMenu]"];
29
+ export class CaucaMenuSidebarComponent {
30
+ constructor(element) {
31
+ this.menuItems = [];
32
+ this.version = '';
33
+ this.keepMenuExpanded = false;
34
+ this.hostElement = element.nativeElement;
35
+ this.hostElement.addEventListener('mouseover', (e) => this.onMouseOver(e));
36
+ this.hostElement.addEventListener('mouseout', (e) => this.onMouseOut(e));
37
+ this.setDisplayMenu();
38
+ }
39
+ onResize(e) {
40
+ this.setDisplayMenu();
41
+ }
42
+ ngOnInit() {
43
+ }
44
+ onMenuItemClick() {
45
+ if (window.innerWidth < 1000) {
46
+ this.hideOnMobile();
47
+ }
48
+ }
49
+ hideOnMobile() {
50
+ this.hostElement.classList.remove('mobile');
51
+ this.hostElement.classList.add('hidden');
52
+ }
53
+ showOnMobile() {
54
+ this.hostElement.classList.remove('hidden');
55
+ this.hostElement.classList.add('mobile');
56
+ }
57
+ onToggleCollapse() {
58
+ if (this.keepMenuExpanded) {
59
+ this.onCollapseMenu();
60
+ this.hostElement.classList.remove('keepExpanded');
61
+ }
62
+ else {
63
+ this.onExpandedMenu();
64
+ this.hostElement.classList.add('keepExpanded');
65
+ }
66
+ this.keepMenuExpanded = !this.keepMenuExpanded;
67
+ localStorage.setItem('cauca-menu-status', this.keepMenuExpanded ? 'expanded' : 'collapsed');
68
+ }
69
+ setDisplayMenu() {
70
+ this.hostElement.className = '';
71
+ if (window.innerWidth < 1000) {
72
+ this.hostElement.classList.add('hidden');
73
+ }
74
+ else {
75
+ if (localStorage.getItem('cauca-menu-status') === 'expanded') {
76
+ this.keepMenuExpanded = true;
77
+ this.hostElement.classList.add('keepExpanded');
78
+ }
79
+ this.hostElement.classList.add(this.keepMenuExpanded ? 'expanded' : 'collapsed');
80
+ }
81
+ }
82
+ onMouseOver(e) {
83
+ if (!this.keepMenuExpanded) {
84
+ this.onExpandedMenu();
85
+ }
86
+ e.stopPropagation();
87
+ }
88
+ onMouseOut(e) {
89
+ if (!this.keepMenuExpanded) {
90
+ this.onCollapseMenu();
91
+ }
92
+ e.stopPropagation();
93
+ }
94
+ onExpandedMenu() {
95
+ if (window.innerWidth >= 1000) {
96
+ this.hostElement.classList.remove('collapsed');
97
+ this.hostElement.classList.add('expanded');
98
+ }
99
+ }
100
+ onCollapseMenu() {
101
+ if (window.innerWidth >= 1000) {
102
+ this.hostElement.classList.remove('expanded');
103
+ this.hostElement.classList.add('collapsed');
104
+ }
105
+ }
106
+ }
107
+ CaucaMenuSidebarComponent.ɵfac = function CaucaMenuSidebarComponent_Factory(t) { return new (t || CaucaMenuSidebarComponent)(i0.ɵɵdirectiveInject(i0.ElementRef)); };
108
+ CaucaMenuSidebarComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: CaucaMenuSidebarComponent, selectors: [["cauca-menu-sidebar"]], hostBindings: function CaucaMenuSidebarComponent_HostBindings(rf, ctx) { if (rf & 1) {
109
+ i0.ɵɵlistener("resize", function CaucaMenuSidebarComponent_resize_HostBindingHandler($event) { return ctx.onResize($event); }, false, i0.ɵɵresolveWindow);
110
+ } }, inputs: { menuItems: "menuItems", version: "version" }, ngContentSelectors: _c1, decls: 11, vars: 2, consts: [["mat-icon-button", "", 1, "close", 3, "click"], [3, "menuItems", "itemClick"], ["menu", ""], ["class", "version", 4, "ngIf"], [1, "version"], [1, "double-arrow", 3, "click"], [1, "full"], [1, "abbr"]], template: function CaucaMenuSidebarComponent_Template(rf, ctx) { if (rf & 1) {
111
+ i0.ɵɵprojectionDef(_c0);
112
+ i0.ɵɵelementStart(0, "div")(1, "button", 0);
113
+ i0.ɵɵlistener("click", function CaucaMenuSidebarComponent_Template_button_click_1_listener() { return ctx.hideOnMobile(); });
114
+ i0.ɵɵelementStart(2, "mat-icon");
115
+ i0.ɵɵtext(3, "clear");
116
+ i0.ɵɵelementEnd()();
117
+ i0.ɵɵprojection(4);
118
+ i0.ɵɵelementEnd();
119
+ i0.ɵɵelementStart(5, "div");
120
+ i0.ɵɵprojection(6, 1);
121
+ i0.ɵɵelementStart(7, "cauca-menu-vertical", 1, 2);
122
+ i0.ɵɵlistener("itemClick", function CaucaMenuSidebarComponent_Template_cauca_menu_vertical_itemClick_7_listener() { return ctx.onMenuItemClick(); });
123
+ i0.ɵɵelementEnd();
124
+ i0.ɵɵprojection(9, 2);
125
+ i0.ɵɵelementEnd();
126
+ i0.ɵɵtemplate(10, CaucaMenuSidebarComponent_div_10_Template, 7, 5, "div", 3);
127
+ } if (rf & 2) {
128
+ i0.ɵɵadvance(7);
129
+ i0.ɵɵproperty("menuItems", ctx.menuItems);
130
+ i0.ɵɵadvance(3);
131
+ i0.ɵɵproperty("ngIf", ctx.version);
132
+ } }, directives: [i1.MatButton, i2.MatIcon, i3.CaucaMenuVerticalComponent, i4.NgIf], pipes: [i5.TranslatePipe], styles: ["[_nghost-%COMP%]{height:100%;flex-direction:column;display:flex;transition:all .1s ease-out;overflow:hidden;scrollbar-width:5px;scrollbar-color:rgba(0,0,0,.1) rgba(0,0,0,.2)}[_ngcontent-%COMP%]::-webkit-scrollbar{width:5px}[_ngcontent-%COMP%]::-webkit-scrollbar-track{border-radius:5px;-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.1)}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{border-radius:5px;background-color:#0003;outline:1px solid slategrey}[_nghost-%COMP%] > div[_ngcontent-%COMP%]{flex:1}[_nghost-%COMP%] > div[_ngcontent-%COMP%]:first-child{flex:0 0 auto}[_nghost-%COMP%] > div[_ngcontent-%COMP%]:nth-child(2){flex-grow:1;overflow:hidden auto}[_nghost-%COMP%] > div[_ngcontent-%COMP%]:last-child{max-height:1em}.hidden[_nghost-%COMP%]{width:0;min-width:0;max-width:0}.mobile[_nghost-%COMP%]{width:275px;min-width:275px;max-width:275px;position:absolute;z-index:10}.collapsed[_nghost-%COMP%]{width:75px;min-width:75px;max-width:75px}.expanded[_nghost-%COMP%]{width:275px;min-width:275px;max-width:275px}[_nghost-%COMP%] .close[_ngcontent-%COMP%]{display:none}.mobile[_nghost-%COMP%] .close[_ngcontent-%COMP%]{right:0;display:inline-block;position:absolute}.double-arrow[_ngcontent-%COMP%]{height:2.9em;line-height:2.9em;cursor:pointer;position:absolute;opacity:.25;margin-top:-1em}.double-arrow[_ngcontent-%COMP%]:hover{opacity:1}.expanded[_nghost-%COMP%] .double-arrow[_ngcontent-%COMP%]:before, .collapsed[_nghost-%COMP%] .double-arrow[_ngcontent-%COMP%]:before{font-family:Material Icons;content:\"double_arrow\";font-size:2.9em;text-align:right}.collapsed[_nghost-%COMP%] .double-arrow[_ngcontent-%COMP%]{margin-left:10px}.expanded[_nghost-%COMP%] .double-arrow[_ngcontent-%COMP%]{margin-left:200px}.collapsed[_nghost-%COMP%] .menu-caption, .collapsed[_nghost-%COMP%] .submenu{display:none}.keepExpanded[_nghost-%COMP%] .double-arrow[_ngcontent-%COMP%]{transform:rotate(180deg);opacity:1}.version[_ngcontent-%COMP%]{bottom:0;padding:1em}.full[_ngcontent-%COMP%], .abbr[_ngcontent-%COMP%]{display:none}.collapsed[_nghost-%COMP%] .abbr[_ngcontent-%COMP%]{display:inline}.mobile[_nghost-%COMP%] .full[_ngcontent-%COMP%], .expanded[_nghost-%COMP%] .full[_ngcontent-%COMP%]{display:inline}@media only screen and (max-width: 1000px){.double-arrow[_ngcontent-%COMP%]{display:none}}"] });
133
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(CaucaMenuSidebarComponent, [{
134
+ type: Component,
135
+ args: [{ selector: 'cauca-menu-sidebar', template: "<div>\n <button mat-icon-button class=\"close\" (click)=\"hideOnMobile()\">\n <mat-icon>clear</mat-icon>\n </button>\n <ng-content select=\"[header]\"></ng-content>\n</div>\n<div>\n <ng-content select=\"[beforeMenu]\"></ng-content>\n <cauca-menu-vertical #menu [menuItems]=\"menuItems\" (itemClick)=\"onMenuItemClick()\"></cauca-menu-vertical>\n <ng-content select=\"[afterMenu]\"></ng-content>\n</div>\n<div *ngIf=\"version\" class=\"version\">\n <div class=\"double-arrow\" (click)=\"onToggleCollapse()\"></div>\n <span class=\"full\">{{'material.version' | translate}} {{version}}</span>\n <span class=\"abbr\">{{version}}</span>\n</div>\n", styles: [":host{height:100%;flex-direction:column;display:flex;transition:all .1s ease-out;overflow:hidden;scrollbar-width:5px;scrollbar-color:rgba(0,0,0,.1) rgba(0,0,0,.2)}::-webkit-scrollbar{width:5px}::-webkit-scrollbar-track{border-radius:5px;-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.1)}::-webkit-scrollbar-thumb{border-radius:5px;background-color:#0003;outline:1px solid slategrey}:host>div{flex:1}:host>div:first-child{flex:0 0 auto}:host>div:nth-child(2){flex-grow:1;overflow:hidden auto}:host>div:last-child{max-height:1em}:host.hidden{width:0;min-width:0;max-width:0}:host.mobile{width:275px;min-width:275px;max-width:275px;position:absolute;z-index:10}:host.collapsed{width:75px;min-width:75px;max-width:75px}:host.expanded{width:275px;min-width:275px;max-width:275px}:host .close{display:none}:host.mobile .close{right:0;display:inline-block;position:absolute}.double-arrow{height:2.9em;line-height:2.9em;cursor:pointer;position:absolute;opacity:.25;margin-top:-1em}.double-arrow:hover{opacity:1}:host.expanded .double-arrow:before,:host.collapsed .double-arrow:before{font-family:Material Icons;content:\"double_arrow\";font-size:2.9em;text-align:right}:host.collapsed .double-arrow{margin-left:10px}:host.expanded .double-arrow{margin-left:200px}:host.collapsed ::ng-deep .menu-caption,:host.collapsed ::ng-deep .submenu{display:none}:host.keepExpanded .double-arrow{transform:rotate(180deg);opacity:1}.version{bottom:0;padding:1em}.full,.abbr{display:none}:host.collapsed .abbr{display:inline}:host.mobile .full,:host.expanded .full{display:inline}@media only screen and (max-width: 1000px){.double-arrow{display:none}}\n"] }]
136
+ }], function () { return [{ type: i0.ElementRef }]; }, { menuItems: [{
137
+ type: Input
138
+ }], version: [{
139
+ type: Input
140
+ }], onResize: [{
141
+ type: HostListener,
142
+ args: ['window:resize', ['$event']]
143
+ }] }); })();
144
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY2F1Y2EtbWVudS1zaWRlYmFyLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL2NhdWNhLW1hdGVyaWFsL3NyYy9saWIvY2F1Y2EtbWVudS1zaWRlYmFyL2NhdWNhLW1lbnUtc2lkZWJhci5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9jYXVjYS1tYXRlcmlhbC9zcmMvbGliL2NhdWNhLW1lbnUtc2lkZWJhci9jYXVjYS1tZW51LXNpZGViYXIuY29tcG9uZW50Lmh0bWwiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFNBQVMsRUFBYyxZQUFZLEVBQUUsS0FBSyxFQUFVLE1BQU0sZUFBZSxDQUFDOzs7Ozs7Ozs7SUNXbkYsOEJBQXFDLGFBQUE7SUFDUCxvS0FBUyx5QkFBa0IsSUFBQztJQUFDLGlCQUFNO0lBQzdELCtCQUFtQjtJQUFBLFlBQThDOztJQUFBLGlCQUFPO0lBQ3hFLCtCQUFtQjtJQ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ICA8Y2F1Y2EtbWVudS12ZXJ0aWNhbCAjbWVudSBbbWVudUl0ZW1zXT1cIm1lbnVJdGVtc1wiIChpdGVtQ2xpY2spPVwib25NZW51SXRlbUNsaWNrKClcIj48L2NhdWNhLW1lbnUtdmVydGljYWw+XG4gICAgPG5nLWNvbnRlbnQgc2VsZWN0PVwiW2FmdGVyTWVudV1cIj48L25nLWNvbnRlbnQ+XG48L2Rpdj5cbjxkaXYgKm5nSWY9XCJ2ZXJzaW9uXCIgY2xhc3M9XCJ2ZXJzaW9uXCI+XG4gICAgPGRpdiBjbGFzcz1cImRvdWJsZS1hcnJvd1wiIChjbGljayk9XCJvblRvZ2dsZUNvbGxhcHNlKClcIj48L2Rpdj5cbiAgICA8c3BhbiBjbGFzcz1cImZ1bGxcIj57eydtYXRlcmlhbC52ZXJzaW9uJyB8IHRyYW5zbGF0ZX19IHt7dmVyc2lvbn19PC9zcGFuPlxuICAgIDxzcGFuIGNsYXNzPVwiYWJiclwiPnt7dmVyc2lvbn19PC9zcGFuPlxuPC9kaXY+XG4iXX0=
@@ -1,181 +1,172 @@
1
- import { Component, EventEmitter, Input, Output } from '@angular/core';
2
- import { NavigationEnd } from '@angular/router';
3
- import * as i0 from "@angular/core";
4
- import * as i1 from "@angular/router";
5
- import * as i2 from "@angular/common";
6
- import * as i3 from "@fortawesome/angular-fontawesome";
7
- import * as i4 from "@ngx-translate/core";
8
- function CaucaMenuVerticalComponent_h4_0_div_2_fa_icon_1_Template(rf, ctx) { if (rf & 1) {
9
- i0.ɵɵelement(0, "fa-icon", 8);
10
- } if (rf & 2) {
11
- const menu_r1 = i0.ɵɵnextContext(2).$implicit;
12
- i0.ɵɵproperty("icon", menu_r1.icon);
13
- } }
14
- function CaucaMenuVerticalComponent_h4_0_div_2_img_2_Template(rf, ctx) { if (rf & 1) {
15
- i0.ɵɵelement(0, "img", 9);
16
- } if (rf & 2) {
17
- const menu_r1 = i0.ɵɵnextContext(2).$implicit;
18
- i0.ɵɵproperty("src", menu_r1.icon, i0.ɵɵsanitizeUrl);
19
- } }
20
- function CaucaMenuVerticalComponent_h4_0_div_2_Template(rf, ctx) { if (rf & 1) {
21
- i0.ɵɵelementStart(0, "div", 5);
22
- i0.ɵɵtemplate(1, CaucaMenuVerticalComponent_h4_0_div_2_fa_icon_1_Template, 1, 1, "fa-icon", 6);
23
- i0.ɵɵtemplate(2, CaucaMenuVerticalComponent_h4_0_div_2_img_2_Template, 1, 1, "img", 7);
24
- i0.ɵɵelementEnd();
25
- } if (rf & 2) {
26
- const menu_r1 = i0.ɵɵnextContext().$implicit;
27
- i0.ɵɵadvance(1);
28
- i0.ɵɵproperty("ngIf", menu_r1.icon.filter !== undefined);
29
- i0.ɵɵadvance(1);
30
- i0.ɵɵproperty("ngIf", menu_r1.icon.filter === undefined);
31
- } }
32
- function CaucaMenuVerticalComponent_h4_0_div_3_Template(rf, ctx) { if (rf & 1) {
33
- i0.ɵɵelementStart(0, "div", 10);
34
- i0.ɵɵelementStart(1, "span");
35
- i0.ɵɵtext(2);
36
- i0.ɵɵpipe(3, "translate");
37
- i0.ɵɵelementEnd();
38
- i0.ɵɵelementEnd();
39
- } if (rf & 2) {
40
- const menu_r1 = i0.ɵɵnextContext().$implicit;
41
- i0.ɵɵadvance(2);
42
- i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(3, 1, menu_r1.label));
43
- } }
44
- function CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_1_Template(rf, ctx) { if (rf & 1) {
45
- i0.ɵɵelementStart(0, "div", 15);
46
- i0.ɵɵtext(1, "\u2022");
47
- i0.ɵɵelementEnd();
48
- } }
49
- function CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_2_fa_icon_1_Template(rf, ctx) { if (rf & 1) {
50
- i0.ɵɵelement(0, "fa-icon", 8);
51
- } if (rf & 2) {
52
- const submenu_r12 = i0.ɵɵnextContext(2).$implicit;
53
- i0.ɵɵproperty("icon", submenu_r12.icon);
54
- } }
55
- function CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_2_img_2_Template(rf, ctx) { if (rf & 1) {
56
- i0.ɵɵelement(0, "img", 9);
57
- } if (rf & 2) {
58
- const submenu_r12 = i0.ɵɵnextContext(2).$implicit;
59
- i0.ɵɵproperty("src", submenu_r12.icon, i0.ɵɵsanitizeUrl);
60
- } }
61
- function CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_2_Template(rf, ctx) { if (rf & 1) {
62
- i0.ɵɵelementStart(0, "div", 5);
63
- i0.ɵɵtemplate(1, CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_2_fa_icon_1_Template, 1, 1, "fa-icon", 6);
64
- i0.ɵɵtemplate(2, CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_2_img_2_Template, 1, 1, "img", 7);
65
- i0.ɵɵelementEnd();
66
- } if (rf & 2) {
67
- const submenu_r12 = i0.ɵɵnextContext().$implicit;
68
- i0.ɵɵadvance(1);
69
- i0.ɵɵproperty("ngIf", submenu_r12.icon.filter !== undefined);
70
- i0.ɵɵadvance(1);
71
- i0.ɵɵproperty("ngIf", submenu_r12.icon.filter === undefined);
72
- } }
73
- function CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_3_Template(rf, ctx) { if (rf & 1) {
74
- i0.ɵɵelementStart(0, "div", 10);
75
- i0.ɵɵelementStart(1, "span");
76
- i0.ɵɵtext(2);
77
- i0.ɵɵpipe(3, "translate");
78
- i0.ɵɵelementEnd();
79
- i0.ɵɵelementEnd();
80
- } if (rf & 2) {
81
- const submenu_r12 = i0.ɵɵnextContext().$implicit;
82
- i0.ɵɵadvance(2);
83
- i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(3, 1, submenu_r12.label));
84
- } }
85
- function CaucaMenuVerticalComponent_h4_0_div_4_div_1_Template(rf, ctx) { if (rf & 1) {
86
- const _r23 = i0.ɵɵgetCurrentView();
87
- i0.ɵɵelementStart(0, "div", 13);
88
- i0.ɵɵlistener("click", function CaucaMenuVerticalComponent_h4_0_div_4_div_1_Template_div_click_0_listener($event) { const restoredCtx = i0.ɵɵrestoreView(_r23); const submenu_r12 = restoredCtx.$implicit; const ctx_r22 = i0.ɵɵnextContext(3); return ctx_r22.goTo(submenu_r12.path, $event); });
89
- i0.ɵɵtemplate(1, CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_1_Template, 2, 0, "div", 14);
90
- i0.ɵɵtemplate(2, CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_2_Template, 3, 2, "div", 2);
91
- i0.ɵɵtemplate(3, CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_3_Template, 4, 3, "div", 3);
92
- i0.ɵɵelementEnd();
93
- } if (rf & 2) {
94
- const submenu_r12 = ctx.$implicit;
95
- i0.ɵɵclassMap(submenu_r12.activated ? "menu selected" : "menu");
96
- i0.ɵɵadvance(1);
97
- i0.ɵɵproperty("ngIf", !submenu_r12.icon);
98
- i0.ɵɵadvance(1);
99
- i0.ɵɵproperty("ngIf", submenu_r12.icon);
100
- i0.ɵɵadvance(1);
101
- i0.ɵɵproperty("ngIf", submenu_r12.label);
102
- } }
103
- function CaucaMenuVerticalComponent_h4_0_div_4_Template(rf, ctx) { if (rf & 1) {
104
- i0.ɵɵelementStart(0, "div", 11);
105
- i0.ɵɵtemplate(1, CaucaMenuVerticalComponent_h4_0_div_4_div_1_Template, 4, 5, "div", 12);
106
- i0.ɵɵelementEnd();
107
- } if (rf & 2) {
108
- const menu_r1 = i0.ɵɵnextContext().$implicit;
109
- i0.ɵɵadvance(1);
110
- i0.ɵɵproperty("ngForOf", menu_r1.childs);
111
- } }
112
- function CaucaMenuVerticalComponent_h4_0_Template(rf, ctx) { if (rf & 1) {
113
- const _r26 = i0.ɵɵgetCurrentView();
114
- i0.ɵɵelementStart(0, "h4");
115
- i0.ɵɵelementStart(1, "div", 1);
116
- i0.ɵɵlistener("click", function CaucaMenuVerticalComponent_h4_0_Template_div_click_1_listener($event) { const restoredCtx = i0.ɵɵrestoreView(_r26); const menu_r1 = restoredCtx.$implicit; const ctx_r25 = i0.ɵɵnextContext(); return ctx_r25.goTo(menu_r1.path, $event); });
117
- i0.ɵɵtemplate(2, CaucaMenuVerticalComponent_h4_0_div_2_Template, 3, 2, "div", 2);
118
- i0.ɵɵtemplate(3, CaucaMenuVerticalComponent_h4_0_div_3_Template, 4, 3, "div", 3);
119
- i0.ɵɵelementEnd();
120
- i0.ɵɵtemplate(4, CaucaMenuVerticalComponent_h4_0_div_4_Template, 2, 1, "div", 4);
121
- i0.ɵɵelementEnd();
122
- } if (rf & 2) {
123
- const menu_r1 = ctx.$implicit;
124
- i0.ɵɵclassMap(menu_r1.activated ? "selected" : "");
125
- i0.ɵɵadvance(2);
126
- i0.ɵɵproperty("ngIf", menu_r1.icon);
127
- i0.ɵɵadvance(1);
128
- i0.ɵɵproperty("ngIf", menu_r1.label);
129
- i0.ɵɵadvance(1);
130
- i0.ɵɵproperty("ngIf", menu_r1.childs.length && menu_r1.activated);
131
- } }
132
- export class CaucaMenuVerticalComponent {
133
- constructor(router) {
134
- this.router = router;
135
- this.itemClick = new EventEmitter();
136
- this.menuItems = [];
137
- this.router.events.subscribe((route) => {
138
- if (route instanceof NavigationEnd) {
139
- this.selectActiveRoute(route);
140
- }
141
- });
142
- }
143
- ngOnInit() {
144
- }
145
- goTo(path, e) {
146
- this.router.navigate([path]);
147
- this.itemClick.emit();
148
- e.stopPropagation();
149
- }
150
- selectActiveRoute(route) {
151
- this.menuItems.forEach((menu) => {
152
- if (route.url) {
153
- menu.activated = (route.url === menu.path || (menu.childs.length && route.url.indexOf(menu.path) > -1));
154
- }
155
- menu.childs.forEach((subMenu) => {
156
- if (route.url) {
157
- subMenu.activated = (route.url === subMenu.path || route.urlAfterRedirects === subMenu.path);
158
- }
159
- });
160
- });
161
- }
162
- }
163
- CaucaMenuVerticalComponent.ɵfac = function CaucaMenuVerticalComponent_Factory(t) { return new (t || CaucaMenuVerticalComponent)(i0.ɵɵdirectiveInject(i1.Router)); };
164
- CaucaMenuVerticalComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: CaucaMenuVerticalComponent, selectors: [["cauca-menu-vertical"]], inputs: { menuItems: "menuItems" }, outputs: { itemClick: "itemClick" }, decls: 1, vars: 1, consts: [[3, "class", 4, "ngFor", "ngForOf"], [1, "menu", 3, "click"], ["class", "menu-icon", 4, "ngIf"], ["class", "menu-caption", 4, "ngIf"], ["class", "submenu", 4, "ngIf"], [1, "menu-icon"], [3, "icon", 4, "ngIf"], [3, "src", 4, "ngIf"], [3, "icon"], [3, "src"], [1, "menu-caption"], [1, "submenu"], [3, "class", "click", 4, "ngFor", "ngForOf"], [3, "click"], ["class", "menu-dot", 4, "ngIf"], [1, "menu-dot"]], template: function CaucaMenuVerticalComponent_Template(rf, ctx) { if (rf & 1) {
165
- i0.ɵɵtemplate(0, CaucaMenuVerticalComponent_h4_0_Template, 5, 5, "h4", 0);
166
- } if (rf & 2) {
167
- i0.ɵɵproperty("ngForOf", ctx.menuItems);
168
- } }, directives: [i2.NgForOf, i2.NgIf, i3.FaIconComponent], pipes: [i4.TranslatePipe], styles: [".menu[_ngcontent-%COMP%], .submenu[_ngcontent-%COMP%]{cursor:pointer}h4[_ngcontent-%COMP%]{margin:0;padding:0}h4[_ngcontent-%COMP%] .menu[_ngcontent-%COMP%]{padding:1em 0;display:flex;flex-direction:row}h4[_ngcontent-%COMP%] .menu[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{flex:1 1 auto;align-self:center}.menu-dot[_ngcontent-%COMP%]{max-width:1.1em;text-align:center;margin-right:.5em;font-size:2em}.menu-icon[_ngcontent-%COMP%]{max-width:60px;text-align:center;margin-right:.5em}.submenu[_ngcontent-%COMP%]{margin-left:1em}.submenu[_ngcontent-%COMP%] .menu[_ngcontent-%COMP%]{padding:0;font-size:.9em;line-height:2.2em}.submenu[_ngcontent-%COMP%] .menu[_ngcontent-%COMP%]:before{content:\"\";margin-left:1.1em;width:.1em;height:2.5em;position:relative;background:#ffffff;margin-right:-1.17em}"] });
169
- (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(CaucaMenuVerticalComponent, [{
170
- type: Component,
171
- args: [{
172
- selector: 'cauca-menu-vertical',
173
- templateUrl: './cauca-menu-vertical.component.html',
174
- styleUrls: ['./cauca-menu-vertical.component.scss']
175
- }]
176
- }], function () { return [{ type: i1.Router }]; }, { itemClick: [{
177
- type: Output
178
- }], menuItems: [{
179
- type: Input
180
- }] }); })();
181
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY2F1Y2EtbWVudS12ZXJ0aWNhbC5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9jYXVjYS1tYXRlcmlhbC9zcmMvbGliL2NhdWNhLW1lbnUtdmVydGljYWwvY2F1Y2EtbWVudS12ZXJ0aWNhbC5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9jYXVjYS1tYXRlcmlhbC9zcmMvbGliL2NhdWNhLW1lbnUtdmVydGljYWwvY2F1Y2EtbWVudS12ZXJ0aWNhbC5jb21wb25lbnQuaHRtbCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUMsU0FBUyxFQUFFLFlBQVksRUFBRSxLQUFLLEVBQVUsTUFBTSxFQUFDLE1BQU0sZUFBZSxDQUFDO0FBQzdFLE9BQU8sRUFBQyxhQUFhLEVBQVMsTUFBTSxpQkFBaUIsQ0FBQzs7Ozs7OztJQ0UxQyw2QkFBNkU7OztJQUE3QixtQ0FBa0I7OztJQUNsRSx5QkFBZ0U7OztJQUFwQixvREFBaUI7OztJQUZqRSw4QkFBeUM7SUFDckMsOEZBQTZFO0lBQzdFLHNGQUFnRTtJQUNwRSxpQkFBTTs7O0lBRlEsZUFBb0M7SUFBcEMsd0RBQW9DO0lBQ3hDLGVBQW9DO0lBQXBDLH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cbiAgICAgICAgICAgICAgICA8c3Bhbj57e3N1Ym1lbnUubGFiZWwgfCB0cmFuc2xhdGV9fTwvc3Bhbj5cbiAgICAgICAgICAgIDwvZGl2PlxuICAgICAgICA8L2Rpdj5cbiAgICA8L2Rpdj5cbjwvaDQ+XG4iXX0=
1
+ import { Component, EventEmitter, Input, Output } from '@angular/core';
2
+ import { NavigationEnd } from '@angular/router';
3
+ import * as i0 from "@angular/core";
4
+ import * as i1 from "@angular/router";
5
+ import * as i2 from "@angular/common";
6
+ import * as i3 from "@fortawesome/angular-fontawesome";
7
+ import * as i4 from "@ngx-translate/core";
8
+ function CaucaMenuVerticalComponent_h4_0_div_2_fa_icon_1_Template(rf, ctx) { if (rf & 1) {
9
+ i0.ɵɵelement(0, "fa-icon", 8);
10
+ } if (rf & 2) {
11
+ const menu_r1 = i0.ɵɵnextContext(2).$implicit;
12
+ i0.ɵɵproperty("icon", menu_r1.icon);
13
+ } }
14
+ function CaucaMenuVerticalComponent_h4_0_div_2_img_2_Template(rf, ctx) { if (rf & 1) {
15
+ i0.ɵɵelement(0, "img", 9);
16
+ } if (rf & 2) {
17
+ const menu_r1 = i0.ɵɵnextContext(2).$implicit;
18
+ i0.ɵɵproperty("src", menu_r1.icon, i0.ɵɵsanitizeUrl);
19
+ } }
20
+ function CaucaMenuVerticalComponent_h4_0_div_2_Template(rf, ctx) { if (rf & 1) {
21
+ i0.ɵɵelementStart(0, "div", 5);
22
+ i0.ɵɵtemplate(1, CaucaMenuVerticalComponent_h4_0_div_2_fa_icon_1_Template, 1, 1, "fa-icon", 6);
23
+ i0.ɵɵtemplate(2, CaucaMenuVerticalComponent_h4_0_div_2_img_2_Template, 1, 1, "img", 7);
24
+ i0.ɵɵelementEnd();
25
+ } if (rf & 2) {
26
+ const menu_r1 = i0.ɵɵnextContext().$implicit;
27
+ i0.ɵɵadvance(1);
28
+ i0.ɵɵproperty("ngIf", menu_r1.icon.filter !== undefined);
29
+ i0.ɵɵadvance(1);
30
+ i0.ɵɵproperty("ngIf", menu_r1.icon.filter === undefined);
31
+ } }
32
+ function CaucaMenuVerticalComponent_h4_0_div_3_Template(rf, ctx) { if (rf & 1) {
33
+ i0.ɵɵelementStart(0, "div", 10)(1, "span");
34
+ i0.ɵɵtext(2);
35
+ i0.ɵɵpipe(3, "translate");
36
+ i0.ɵɵelementEnd()();
37
+ } if (rf & 2) {
38
+ const menu_r1 = i0.ɵɵnextContext().$implicit;
39
+ i0.ɵɵadvance(2);
40
+ i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(3, 1, menu_r1.label));
41
+ } }
42
+ function CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_1_Template(rf, ctx) { if (rf & 1) {
43
+ i0.ɵɵelementStart(0, "div", 15);
44
+ i0.ɵɵtext(1, "\u2022");
45
+ i0.ɵɵelementEnd();
46
+ } }
47
+ function CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_2_fa_icon_1_Template(rf, ctx) { if (rf & 1) {
48
+ i0.ɵɵelement(0, "fa-icon", 8);
49
+ } if (rf & 2) {
50
+ const submenu_r12 = i0.ɵɵnextContext(2).$implicit;
51
+ i0.ɵɵproperty("icon", submenu_r12.icon);
52
+ } }
53
+ function CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_2_img_2_Template(rf, ctx) { if (rf & 1) {
54
+ i0.ɵɵelement(0, "img", 9);
55
+ } if (rf & 2) {
56
+ const submenu_r12 = i0.ɵɵnextContext(2).$implicit;
57
+ i0.ɵɵproperty("src", submenu_r12.icon, i0.ɵɵsanitizeUrl);
58
+ } }
59
+ function CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_2_Template(rf, ctx) { if (rf & 1) {
60
+ i0.ɵɵelementStart(0, "div", 5);
61
+ i0.ɵɵtemplate(1, CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_2_fa_icon_1_Template, 1, 1, "fa-icon", 6);
62
+ i0.ɵɵtemplate(2, CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_2_img_2_Template, 1, 1, "img", 7);
63
+ i0.ɵɵelementEnd();
64
+ } if (rf & 2) {
65
+ const submenu_r12 = i0.ɵɵnextContext().$implicit;
66
+ i0.ɵɵadvance(1);
67
+ i0.ɵɵproperty("ngIf", submenu_r12.icon.filter !== undefined);
68
+ i0.ɵɵadvance(1);
69
+ i0.ɵɵproperty("ngIf", submenu_r12.icon.filter === undefined);
70
+ } }
71
+ function CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_3_Template(rf, ctx) { if (rf & 1) {
72
+ i0.ɵɵelementStart(0, "div", 10)(1, "span");
73
+ i0.ɵɵtext(2);
74
+ i0.ɵɵpipe(3, "translate");
75
+ i0.ɵɵelementEnd()();
76
+ } if (rf & 2) {
77
+ const submenu_r12 = i0.ɵɵnextContext().$implicit;
78
+ i0.ɵɵadvance(2);
79
+ i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(3, 1, submenu_r12.label));
80
+ } }
81
+ function CaucaMenuVerticalComponent_h4_0_div_4_div_1_Template(rf, ctx) { if (rf & 1) {
82
+ const _r23 = i0.ɵɵgetCurrentView();
83
+ i0.ɵɵelementStart(0, "div", 13);
84
+ i0.ɵɵlistener("click", function CaucaMenuVerticalComponent_h4_0_div_4_div_1_Template_div_click_0_listener($event) { const restoredCtx = i0.ɵɵrestoreView(_r23); const submenu_r12 = restoredCtx.$implicit; const ctx_r22 = i0.ɵɵnextContext(3); return ctx_r22.goTo(submenu_r12.path, $event); });
85
+ i0.ɵɵtemplate(1, CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_1_Template, 2, 0, "div", 14);
86
+ i0.ɵɵtemplate(2, CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_2_Template, 3, 2, "div", 2);
87
+ i0.ɵɵtemplate(3, CaucaMenuVerticalComponent_h4_0_div_4_div_1_div_3_Template, 4, 3, "div", 3);
88
+ i0.ɵɵelementEnd();
89
+ } if (rf & 2) {
90
+ const submenu_r12 = ctx.$implicit;
91
+ i0.ɵɵclassMap(submenu_r12.activated ? "menu selected" : "menu");
92
+ i0.ɵɵadvance(1);
93
+ i0.ɵɵproperty("ngIf", !submenu_r12.icon);
94
+ i0.ɵɵadvance(1);
95
+ i0.ɵɵproperty("ngIf", submenu_r12.icon);
96
+ i0.ɵɵadvance(1);
97
+ i0.ɵɵproperty("ngIf", submenu_r12.label);
98
+ } }
99
+ function CaucaMenuVerticalComponent_h4_0_div_4_Template(rf, ctx) { if (rf & 1) {
100
+ i0.ɵɵelementStart(0, "div", 11);
101
+ i0.ɵɵtemplate(1, CaucaMenuVerticalComponent_h4_0_div_4_div_1_Template, 4, 5, "div", 12);
102
+ i0.ɵɵelementEnd();
103
+ } if (rf & 2) {
104
+ const menu_r1 = i0.ɵɵnextContext().$implicit;
105
+ i0.ɵɵadvance(1);
106
+ i0.ɵɵproperty("ngForOf", menu_r1.childs);
107
+ } }
108
+ function CaucaMenuVerticalComponent_h4_0_Template(rf, ctx) { if (rf & 1) {
109
+ const _r26 = i0.ɵɵgetCurrentView();
110
+ i0.ɵɵelementStart(0, "h4")(1, "div", 1);
111
+ i0.ɵɵlistener("click", function CaucaMenuVerticalComponent_h4_0_Template_div_click_1_listener($event) { const restoredCtx = i0.ɵɵrestoreView(_r26); const menu_r1 = restoredCtx.$implicit; const ctx_r25 = i0.ɵɵnextContext(); return ctx_r25.goTo(menu_r1.path, $event); });
112
+ i0.ɵɵtemplate(2, CaucaMenuVerticalComponent_h4_0_div_2_Template, 3, 2, "div", 2);
113
+ i0.ɵɵtemplate(3, CaucaMenuVerticalComponent_h4_0_div_3_Template, 4, 3, "div", 3);
114
+ i0.ɵɵelementEnd();
115
+ i0.ɵɵtemplate(4, CaucaMenuVerticalComponent_h4_0_div_4_Template, 2, 1, "div", 4);
116
+ i0.ɵɵelementEnd();
117
+ } if (rf & 2) {
118
+ const menu_r1 = ctx.$implicit;
119
+ i0.ɵɵclassMap(menu_r1.activated ? "selected" : "");
120
+ i0.ɵɵadvance(2);
121
+ i0.ɵɵproperty("ngIf", menu_r1.icon);
122
+ i0.ɵɵadvance(1);
123
+ i0.ɵɵproperty("ngIf", menu_r1.label);
124
+ i0.ɵɵadvance(1);
125
+ i0.ɵɵproperty("ngIf", menu_r1.childs.length && menu_r1.activated);
126
+ } }
127
+ export class CaucaMenuVerticalComponent {
128
+ constructor(router) {
129
+ this.router = router;
130
+ this.itemClick = new EventEmitter();
131
+ this.menuItems = [];
132
+ this.router.events.subscribe((route) => {
133
+ if (route instanceof NavigationEnd) {
134
+ this.selectActiveRoute(route);
135
+ }
136
+ });
137
+ }
138
+ ngOnInit() {
139
+ }
140
+ goTo(path, e) {
141
+ this.router.navigate([path]);
142
+ this.itemClick.emit();
143
+ e.stopPropagation();
144
+ }
145
+ selectActiveRoute(route) {
146
+ this.menuItems.forEach((menu) => {
147
+ if (route.url) {
148
+ menu.activated = (route.url === menu.path || (menu.childs.length && route.url.indexOf(menu.path) > -1));
149
+ }
150
+ menu.childs.forEach((subMenu) => {
151
+ if (route.url) {
152
+ subMenu.activated = (route.url === subMenu.path || route.urlAfterRedirects === subMenu.path);
153
+ }
154
+ });
155
+ });
156
+ }
157
+ }
158
+ CaucaMenuVerticalComponent.ɵfac = function CaucaMenuVerticalComponent_Factory(t) { return new (t || CaucaMenuVerticalComponent)(i0.ɵɵdirectiveInject(i1.Router)); };
159
+ CaucaMenuVerticalComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: CaucaMenuVerticalComponent, selectors: [["cauca-menu-vertical"]], inputs: { menuItems: "menuItems" }, outputs: { itemClick: "itemClick" }, decls: 1, vars: 1, consts: [[3, "class", 4, "ngFor", "ngForOf"], [1, "menu", 3, "click"], ["class", "menu-icon", 4, "ngIf"], ["class", "menu-caption", 4, "ngIf"], ["class", "submenu", 4, "ngIf"], [1, "menu-icon"], [3, "icon", 4, "ngIf"], [3, "src", 4, "ngIf"], [3, "icon"], [3, "src"], [1, "menu-caption"], [1, "submenu"], [3, "class", "click", 4, "ngFor", "ngForOf"], [3, "click"], ["class", "menu-dot", 4, "ngIf"], [1, "menu-dot"]], template: function CaucaMenuVerticalComponent_Template(rf, ctx) { if (rf & 1) {
160
+ i0.ɵɵtemplate(0, CaucaMenuVerticalComponent_h4_0_Template, 5, 5, "h4", 0);
161
+ } if (rf & 2) {
162
+ i0.ɵɵproperty("ngForOf", ctx.menuItems);
163
+ } }, directives: [i2.NgForOf, i2.NgIf, i3.FaIconComponent], pipes: [i4.TranslatePipe], styles: [".menu[_ngcontent-%COMP%], .submenu[_ngcontent-%COMP%]{cursor:pointer}h4[_ngcontent-%COMP%]{margin:0;padding:0}h4[_ngcontent-%COMP%] .menu[_ngcontent-%COMP%]{padding:1em 0;display:flex;flex-direction:row}h4[_ngcontent-%COMP%] .menu[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{flex:1 1 auto;align-self:center}.menu-dot[_ngcontent-%COMP%]{max-width:1.1em;text-align:center;margin-right:.5em;font-size:2em}.menu-icon[_ngcontent-%COMP%]{max-width:60px;text-align:center;margin-right:.5em}.submenu[_ngcontent-%COMP%]{margin-left:1em}.submenu[_ngcontent-%COMP%] .menu[_ngcontent-%COMP%]{padding:0;font-size:.9em;line-height:2.2em}.submenu[_ngcontent-%COMP%] .menu[_ngcontent-%COMP%]:before{content:\"\";margin-left:1.1em;width:.1em;height:2.5em;position:relative;background:#ffffff;margin-right:-1.17em}"] });
164
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(CaucaMenuVerticalComponent, [{
165
+ type: Component,
166
+ args: [{ selector: 'cauca-menu-vertical', template: "<h4 *ngFor=\"let menu of menuItems\" [class]=\"menu.activated ? 'selected' : ''\">\n <div (click)=\"goTo(menu.path, $event)\" class=\"menu\">\n <div *ngIf=\"menu.icon\" class=\"menu-icon\">\n <fa-icon *ngIf=\"menu.icon.filter !== undefined\" [icon]=\"menu.icon\"></fa-icon>\n <img *ngIf=\"menu.icon.filter === undefined\" [src]=\"menu.icon\" />\n </div>\n <div *ngIf=\"menu.label\" class=\"menu-caption\">\n <span>{{menu.label | translate}}</span>\n </div>\n </div>\n <div *ngIf=\"menu.childs.length && menu.activated\" class=\"submenu\">\n <div\n *ngFor=\"let submenu of menu.childs\"\n [class]=\"submenu.activated ? 'menu selected' : 'menu'\"\n (click)=\"goTo(submenu.path, $event)\">\n <div *ngIf=\"!submenu.icon\" class=\"menu-dot\">&bull;</div>\n <div *ngIf=\"submenu.icon\" class=\"menu-icon\">\n <fa-icon *ngIf=\"submenu.icon.filter !== undefined\" [icon]=\"submenu.icon\"></fa-icon>\n <img *ngIf=\"submenu.icon.filter === undefined\" [src]=\"submenu.icon\" />\n </div>\n <div *ngIf=\"submenu.label\" class=\"menu-caption\">\n <span>{{submenu.label | translate}}</span>\n </div>\n </div>\n </div>\n</h4>\n", styles: [".menu,.submenu{cursor:pointer}h4{margin:0;padding:0}h4 .menu{padding:1em 0;display:flex;flex-direction:row}h4 .menu>div{flex:1 1 auto;align-self:center}.menu-dot{max-width:1.1em;text-align:center;margin-right:.5em;font-size:2em}.menu-icon{max-width:60px;text-align:center;margin-right:.5em}.submenu{margin-left:1em}.submenu .menu{padding:0;font-size:.9em;line-height:2.2em}.submenu .menu:before{content:\"\";margin-left:1.1em;width:.1em;height:2.5em;position:relative;background:#ffffff;margin-right:-1.17em}\n"] }]
167
+ }], function () { return [{ type: i1.Router }]; }, { itemClick: [{
168
+ type: Output
169
+ }], menuItems: [{
170
+ type: Input
171
+ }] }); })();
172
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY2F1Y2EtbWVudS12ZXJ0aWNhbC5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9jYXVjYS1tYXRlcmlhbC9zcmMvbGliL2NhdWNhLW1lbnUtdmVydGljYWwvY2F1Y2EtbWVudS12ZXJ0aWNhbC5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi8uLi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