@rafaelaalmeidaa/primordash 0.0.1 → 0.0.2
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/dashboard/dashboard.component.mjs +5 -5
- package/esm2020/lib/components/modal-edit/modal-edit.component.mjs +3 -3
- package/esm2020/lib/primordash.module.mjs +5 -16
- package/fesm2015/rafaelaalmeidaa-primordash.mjs +15 -25
- package/fesm2015/rafaelaalmeidaa-primordash.mjs.map +1 -1
- package/fesm2020/rafaelaalmeidaa-primordash.mjs +15 -25
- package/fesm2020/rafaelaalmeidaa-primordash.mjs.map +1 -1
- package/lib/primordash.module.d.ts +8 -11
- package/package.json +1 -1
|
@@ -2,10 +2,10 @@ import { Component, HostListener, Input, ViewChild, ViewChildren } from '@angula
|
|
|
2
2
|
import { CdkDropList, moveItemInArray } from '@angular/cdk/drag-drop';
|
|
3
3
|
import * as i0 from "@angular/core";
|
|
4
4
|
import * as i1 from "ngx-bootstrap/modal";
|
|
5
|
-
import * as i2 from "@angular/
|
|
6
|
-
import * as i3 from "@angular/
|
|
7
|
-
import * as i4 from "@angular/material/
|
|
8
|
-
import * as i5 from "@angular/
|
|
5
|
+
import * as i2 from "@angular/cdk/drag-drop";
|
|
6
|
+
import * as i3 from "@angular/material/grid-list";
|
|
7
|
+
import * as i4 from "@angular/material/menu";
|
|
8
|
+
import * as i5 from "@angular/common";
|
|
9
9
|
import * as i6 from "../card/card.component";
|
|
10
10
|
import * as i7 from "../modal-edit/modal-edit.component";
|
|
11
11
|
import * as i8 from "../modal-edit-chart/modal-edit-chart.component";
|
|
@@ -205,7 +205,7 @@ export class DashboardComponent {
|
|
|
205
205
|
}
|
|
206
206
|
}
|
|
207
207
|
DashboardComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: DashboardComponent, deps: [{ token: i1.BsModalService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
208
|
-
DashboardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: DashboardComponent, selector: "lib-dashboard", inputs: { isDark: "isDark", isResponsive: "isResponsive", canEdit: "canEdit", cols: "cols", options: "options", cards: "cards", groupType: "groupType", modalData: "modalData", data: "data", debug: "debug" }, host: { listeners: { "window:resize": "onresize()" } }, viewQueries: [{ propertyName: "modalChart", first: true, predicate: ["modalChart"], descendants: true }, { propertyName: "modal", first: true, predicate: ["modal"], descendants: true }, { propertyName: "modalView", first: true, predicate: ["modalView"], descendants: true }, { propertyName: "modalCode", first: true, predicate: ["modalCode"], descendants: true }, { propertyName: "dropsQuery", predicate: CdkDropList, descendants: true }], ngImport: i0, template: "<main class=\"dashboard\" [class.responsive]=\"isResponsive\" [class.dark-class]=\"isDark\">\r\n <mat-grid-list [cols]=\"cols\" rowHeight=\"300px\" gutterSize=\"10px\">\r\n <mat-grid-tile\r\n *ngFor=\"let card of cards; let i = index\"\r\n [colspan]=\"card.cols > cols? cols : card.cols\"\r\n [rowspan]=\"card.rows\"\r\n [class.dark-class]=\"isDark\"\r\n class=\"card\"\r\n >\r\n <div cdkDropList [cdkDropListConnectedTo]=\"drops\" [cdkDropListData]=\"i\">\r\n <div\r\n [id]=\"'card_' + i\"\r\n cdkDrag\r\n (cdkDragEntered)=\"entered($event)\"\r\n [cdkDragData]=\"i\"\r\n class=\"card-body\"\r\n [cdkDragDisabled]=\"!canEdit\"\r\n [class.dark-class]=\"isDark\"\r\n [class.has-color]=\"card.backgroundColor\"\r\n [style.background-color]=\"card.backgroundColor\"\r\n [style.color]=\"card.fontColor\"\r\n >\r\n <nav class=\"nav-hover\">\r\n <button *ngIf=\"!canEdit\" class=\"btn font-icon\" title=\"Ampliar gr\u00E1fico\" (click)=\"openChart(card, i)\">search</button>\r\n <button *ngIf=\"!canEdit\" class=\"btn font-icon\" title=\"Baixar imagem\" (click)=\"downloadImage(i)\">download</button>\r\n </nav>\r\n <nav class=\"card-nav\" *ngIf=\"canEdit\">\r\n <div class=\"card-handle font-icon\" title=\"Mover\" cdkDragHandle>\r\n drag_pan\r\n </div>\r\n <button class=\"btn card-options font-icon\" title=\"Modificar tamanho\" mat-button [matMenuTriggerFor]=\"menu\">\r\n resize\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <ng-container *ngFor=\"let opt of orderOptions\">\r\n <button mat-menu-item (click)=\"card.cols = opt.cols; card.rows = opt.rows\" >{{opt.title}}</button>\r\n </ng-container>\r\n </mat-menu>\r\n <button class=\"btn font-icon\" title=\"Editar Tipo do Gr\u00E1fico\" (click)=\"openModalChart(card)\">{{'landscape_2_edit'}}</button>\r\n <button class=\"btn font-icon\" title=\"Editar fonte de dados\" (click)=\"openModalData(card)\">edit_note</button>\r\n <button class=\"btn font-icon\" *ngIf=\"debug\" title=\"Exibir c\u00F3digo de configura\u00E7\u00E3o\" (click)=\"openModalCode(card)\">code_blocks</button>\r\n </nav>\r\n <div class=\"custom-placeholder\" *cdkDragPlaceholder></div>\r\n <lib-card [data]=\"card\" [ngClass]=\"{'canEdit': canEdit}\" [isDark]=\"isDark\"></lib-card>\r\n </div>\r\n </div>\r\n </mat-grid-tile>\r\n <mat-grid-tile class=\"card\" [colspan]=\"1\" [rowspan]=\"1\" [class.dark-class]=\"isDark\" *ngIf=\"canEdit\">\r\n <lib-card [data]=\"emptyCard\" [ngClass]=\"{'canEdit': canEdit, cardEmpty:true}\" [isDark]=\"isDark\"\r\n (click)=\"addNewCard()\"\r\n ></lib-card>\r\n </mat-grid-tile>\r\n </mat-grid-list>\r\n</main>\r\n<ng-template #modal>\r\n <lib-modal-edit (closeModal)=\"closeModalData()\" (saveData)=\"saveData($event)\" [data]=\"modalData\" [groupType]=\"groupType\"></lib-modal-edit>\r\n</ng-template>\r\n<ng-template #modalView>\r\n <header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left mb-0\">{{currentCard.title}}</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"closeModalView()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n </header>\r\n <body id=\"modalViewBody\" class=\"modal-body py-2 overflow-auto\">\r\n <lib-card [data]=\"currentCard\" [ngClass]=\"{'canEdit': canEdit}\" [isDark]=\"isDark\"></lib-card>\r\n </body>\r\n</ng-template>\r\n<ng-template #modalCode>\r\n <header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left mb-0\">{{currentCard.title}}</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"closeModalCode()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n </header>\r\n <body id=\"modalCodeBody\" class=\"modal-body py-2 overflow-auto\">\r\n <pre class=\"code-area\">{{ currentCard | json }}</pre>\r\n <button class=\"font-icon code-copy\" title=\"Copiar json\" (click)=\"copyCode()\">content_copy</button>\r\n <span *ngIf=\"copyComplete\" class=\"copy-message\">Copiado!</span>\r\n </body>\r\n</ng-template>\r\n<ng-template #modalChart>\r\n <lib-modal-edit-chart (closeModal)=\"closeModalChart()\" [currentOption]=\"currentOption\" (saveData)=\"saveChartData($event)\"></lib-modal-edit-chart>\r\n</ng-template>", styles: [".dashboard{padding:5px;background-color:#e4e4e4}.copy-message{position:absolute;bottom:10px;left:45%;right:auto;color:#fff;padding:5px 25px;border-radius:20px;background:#1b1b1b}.code-area{background:black;color:#fff;padding:10px;line-height:1;border-radius:10px}.code-copy{top:15px;position:absolute;color:#fff;background:#3f3f3f;right:25px;display:hidden;display:none;border-radius:25px;padding:8px;border:none}.modal-body:hover .code-copy{display:inline}.card{box-sizing:border-box;color:#000000de;background:#fff;border-radius:4px;z-index:1;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f;transition:box-shadow .2s cubic-bezier(0,0,.2,1)}.card-body{border:solid 1px #ccc;height:100%}.card-body:active{border:solid 1px #ccc;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.card-body .card-nav{width:100%;height:30px;display:flex;border-bottom:1px solid gray}.card-body .card-nav .card-handle{cursor:move;width:24px;height:24px}.card-body .card-nav .card-options{border:none;display:flex;padding:0}.card-body .card-nav button,.card-body .card-nav .card-handle{font-size:18pt;display:flex;color:#898989;padding:0;margin-left:5px}.cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.more-button{float:right;font-size:2em}.cdk-drop-list{height:100%;width:100%}.cdk-drag-animating{transition:unset}.cdk-drag-placeholder{display:none}.mat-grid-tile{overflow:visible!important}.mat-grid-tile-content{height:100%!important;display:flex!important}.nav-hover{display:flex;right:10px;position:absolute;top:10px;display:none}::ng-deep .mat-grid-tile:hover .nav-hover{display:inherit}::ng-deep .dark-class:not(.has-color){background-color:#000!important;color:#fff!important}::ng-deep .dark-class.card-body:not(.has-color){background-color:#1a1a1a!important;color:#fff!important}::ng-deep .mat-grid-tile-content:has(lib-card.cardEmpty .empty-card:active){background-color:#c6c6c6}::ng-deep lib-card.cardEmpty{width:100%}::ng-deep lib-card.cardEmpty .empty-card{width:100%;height:100%;text-align:center;padding:auto;font-size:28pt}::ng-deep lib-card.cardEmpty .empty-card:active{border:none}::ng-deep lib-card.canEdit{display:block;height:calc(100% - 30px)}\n"], dependencies: [{ kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i3.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i3.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "directive", type: i3.CdkDragPlaceholder, selector: "ng-template[cdkDragPlaceholder]", inputs: ["data"] }, { kind: "component", type: i4.MatGridList, selector: "mat-grid-list", inputs: ["cols", "gutterSize", "rowHeight"], exportAs: ["matGridList"] }, { kind: "component", type: i4.MatGridTile, selector: "mat-grid-tile", inputs: ["rowspan", "colspan"], exportAs: ["matGridTile"] }, { kind: "component", type: i5.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "component", type: i5.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i5.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "component", type: i6.CardComponent, selector: "lib-card", inputs: ["data", "isDark"] }, { kind: "component", type: i7.ModalEditComponent, selector: "lib-modal-edit", inputs: ["data", "groupType"], outputs: ["closeModal", "saveData"] }, { kind: "component", type: i8.ModalEditChartComponent, selector: "lib-modal-edit-chart", inputs: ["currentOption"], outputs: ["closeModal", "saveData"] }, { kind: "pipe", type: i2.JsonPipe, name: "json" }] });
|
|
208
|
+
DashboardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: DashboardComponent, selector: "lib-dashboard", inputs: { isDark: "isDark", isResponsive: "isResponsive", canEdit: "canEdit", cols: "cols", options: "options", cards: "cards", groupType: "groupType", modalData: "modalData", data: "data", debug: "debug" }, host: { listeners: { "window:resize": "onresize()" } }, viewQueries: [{ propertyName: "modalChart", first: true, predicate: ["modalChart"], descendants: true }, { propertyName: "modal", first: true, predicate: ["modal"], descendants: true }, { propertyName: "modalView", first: true, predicate: ["modalView"], descendants: true }, { propertyName: "modalCode", first: true, predicate: ["modalCode"], descendants: true }, { propertyName: "dropsQuery", predicate: CdkDropList, descendants: true }], ngImport: i0, template: "<main class=\"dashboard\" [class.responsive]=\"isResponsive\" [class.dark-class]=\"isDark\">\r\n <mat-grid-list [cols]=\"cols\" rowHeight=\"300px\" gutterSize=\"10px\">\r\n <mat-grid-tile\r\n *ngFor=\"let card of cards; let i = index\"\r\n [colspan]=\"card.cols > cols? cols : card.cols\"\r\n [rowspan]=\"card.rows\"\r\n [class.dark-class]=\"isDark\"\r\n class=\"card\"\r\n >\r\n <div cdkDropList [cdkDropListConnectedTo]=\"drops\" [cdkDropListData]=\"i\">\r\n <div\r\n [id]=\"'card_' + i\"\r\n cdkDrag\r\n (cdkDragEntered)=\"entered($event)\"\r\n [cdkDragData]=\"i\"\r\n class=\"card-body\"\r\n [cdkDragDisabled]=\"!canEdit\"\r\n [class.dark-class]=\"isDark\"\r\n [class.has-color]=\"card.backgroundColor\"\r\n [style.background-color]=\"card.backgroundColor\"\r\n [style.color]=\"card.fontColor\"\r\n >\r\n <nav class=\"nav-hover\">\r\n <button *ngIf=\"!canEdit\" class=\"btn font-icon\" title=\"Ampliar gr\u00E1fico\" (click)=\"openChart(card, i)\">search</button>\r\n <button *ngIf=\"!canEdit\" class=\"btn font-icon\" title=\"Baixar imagem\" (click)=\"downloadImage(i)\">download</button>\r\n </nav>\r\n <nav class=\"card-nav\" *ngIf=\"canEdit\">\r\n <div class=\"card-handle font-icon\" title=\"Mover\" cdkDragHandle>\r\n drag_pan\r\n </div>\r\n <button class=\"btn card-options font-icon\" title=\"Modificar tamanho\" mat-button [matMenuTriggerFor]=\"menu\">\r\n resize\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <ng-container *ngFor=\"let opt of orderOptions\">\r\n <button mat-menu-item (click)=\"card.cols = opt.cols; card.rows = opt.rows\" >{{opt.title}}</button>\r\n </ng-container>\r\n </mat-menu>\r\n <button class=\"btn font-icon\" title=\"Editar Tipo do Gr\u00E1fico\" (click)=\"openModalChart(card)\">{{'landscape_2_edit'}}</button>\r\n <button class=\"btn font-icon\" title=\"Editar fonte de dados\" (click)=\"openModalData(card)\">edit_note</button>\r\n <button class=\"btn font-icon\" *ngIf=\"debug\" title=\"Exibir c\u00F3digo de configura\u00E7\u00E3o\" (click)=\"openModalCode(card)\">code_blocks</button>\r\n </nav>\r\n <div class=\"custom-placeholder\" *cdkDragPlaceholder></div>\r\n <lib-card [data]=\"card\" [ngClass]=\"{'canEdit': canEdit}\" [isDark]=\"isDark\"></lib-card>\r\n </div>\r\n </div>\r\n </mat-grid-tile>\r\n <mat-grid-tile class=\"card\" [colspan]=\"1\" [rowspan]=\"1\" [class.dark-class]=\"isDark\" *ngIf=\"canEdit\">\r\n <lib-card [data]=\"emptyCard\" [ngClass]=\"{'canEdit': canEdit, cardEmpty:true}\" [isDark]=\"isDark\"\r\n (click)=\"addNewCard()\"\r\n ></lib-card>\r\n </mat-grid-tile>\r\n </mat-grid-list>\r\n</main>\r\n<ng-template #modal>\r\n <lib-modal-edit (closeModal)=\"closeModalData()\" (saveData)=\"saveData($event)\" [data]=\"modalData\" [groupType]=\"groupType\"></lib-modal-edit>\r\n</ng-template>\r\n<ng-template #modalView>\r\n <header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left mb-0\">{{currentCard.title}}</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"closeModalView()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n </header>\r\n <body id=\"modalViewBody\" class=\"modal-body py-2 overflow-auto\">\r\n <lib-card [data]=\"currentCard\" [ngClass]=\"{'canEdit': canEdit}\" [isDark]=\"isDark\"></lib-card>\r\n </body>\r\n</ng-template>\r\n<ng-template #modalCode>\r\n <header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left mb-0\">{{currentCard.title}}</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"closeModalCode()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n </header>\r\n <body id=\"modalCodeBody\" class=\"modal-body py-2 overflow-auto\">\r\n <pre class=\"code-area\">{{ currentCard | json }}</pre>\r\n <button class=\"font-icon code-copy\" title=\"Copiar json\" (click)=\"copyCode()\">content_copy</button>\r\n <span *ngIf=\"copyComplete\" class=\"copy-message\">Copiado!</span>\r\n </body>\r\n</ng-template>\r\n<ng-template #modalChart>\r\n <lib-modal-edit-chart (closeModal)=\"closeModalChart()\" [currentOption]=\"currentOption\" (saveData)=\"saveChartData($event)\"></lib-modal-edit-chart>\r\n</ng-template>", styles: [".dashboard{padding:5px;background-color:#e4e4e4}.copy-message{position:absolute;bottom:10px;left:45%;right:auto;color:#fff;padding:5px 25px;border-radius:20px;background:#1b1b1b}.code-area{background:black;color:#fff;padding:10px;line-height:1;border-radius:10px}.code-copy{top:15px;position:absolute;color:#fff;background:#3f3f3f;right:25px;display:hidden;display:none;border-radius:25px;padding:8px;border:none}.modal-body:hover .code-copy{display:inline}.card{box-sizing:border-box;color:#000000de;background:#fff;border-radius:4px;z-index:1;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f;transition:box-shadow .2s cubic-bezier(0,0,.2,1)}.card-body{border:solid 1px #ccc;height:100%}.card-body:active{border:solid 1px #ccc;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.card-body .card-nav{width:100%;height:30px;display:flex;border-bottom:1px solid gray}.card-body .card-nav .card-handle{cursor:move;width:24px;height:24px}.card-body .card-nav .card-options{border:none;display:flex;padding:0}.card-body .card-nav button,.card-body .card-nav .card-handle{font-size:18pt;display:flex;color:#898989;padding:0;margin-left:5px}.cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.more-button{float:right;font-size:2em}.cdk-drop-list{height:100%;width:100%}.cdk-drag-animating{transition:unset}.cdk-drag-placeholder{display:none}.mat-grid-tile{overflow:visible!important}.mat-grid-tile-content{height:100%!important;display:flex!important}.nav-hover{display:flex;right:10px;position:absolute;top:10px;display:none}::ng-deep .mat-grid-tile:hover .nav-hover{display:inherit}::ng-deep .dark-class:not(.has-color){background-color:#000!important;color:#fff!important}::ng-deep .dark-class.card-body:not(.has-color){background-color:#1a1a1a!important;color:#fff!important}::ng-deep .mat-grid-tile-content:has(lib-card.cardEmpty .empty-card:active){background-color:#c6c6c6}::ng-deep lib-card.cardEmpty{width:100%}::ng-deep lib-card.cardEmpty .empty-card{width:100%;height:100%;text-align:center;padding:auto;font-size:28pt}::ng-deep lib-card.cardEmpty .empty-card:active{border:none}::ng-deep lib-card.canEdit{display:block;height:calc(100% - 30px)}\n"], dependencies: [{ kind: "directive", type: i2.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i2.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i2.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "directive", type: i2.CdkDragPlaceholder, selector: "ng-template[cdkDragPlaceholder]", inputs: ["data"] }, { kind: "component", type: i3.MatGridList, selector: "mat-grid-list", inputs: ["cols", "gutterSize", "rowHeight"], exportAs: ["matGridList"] }, { kind: "component", type: i3.MatGridTile, selector: "mat-grid-tile", inputs: ["rowspan", "colspan"], exportAs: ["matGridTile"] }, { kind: "component", type: i4.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "component", type: i4.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i4.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "directive", type: i5.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i5.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i6.CardComponent, selector: "lib-card", inputs: ["data", "isDark"] }, { kind: "component", type: i7.ModalEditComponent, selector: "lib-modal-edit", inputs: ["data", "groupType"], outputs: ["closeModal", "saveData"] }, { kind: "component", type: i8.ModalEditChartComponent, selector: "lib-modal-edit-chart", inputs: ["currentOption"], outputs: ["closeModal", "saveData"] }, { kind: "pipe", type: i5.JsonPipe, name: "json" }] });
|
|
209
209
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: DashboardComponent, decorators: [{
|
|
210
210
|
type: Component,
|
|
211
211
|
args: [{ selector: 'lib-dashboard', template: "<main class=\"dashboard\" [class.responsive]=\"isResponsive\" [class.dark-class]=\"isDark\">\r\n <mat-grid-list [cols]=\"cols\" rowHeight=\"300px\" gutterSize=\"10px\">\r\n <mat-grid-tile\r\n *ngFor=\"let card of cards; let i = index\"\r\n [colspan]=\"card.cols > cols? cols : card.cols\"\r\n [rowspan]=\"card.rows\"\r\n [class.dark-class]=\"isDark\"\r\n class=\"card\"\r\n >\r\n <div cdkDropList [cdkDropListConnectedTo]=\"drops\" [cdkDropListData]=\"i\">\r\n <div\r\n [id]=\"'card_' + i\"\r\n cdkDrag\r\n (cdkDragEntered)=\"entered($event)\"\r\n [cdkDragData]=\"i\"\r\n class=\"card-body\"\r\n [cdkDragDisabled]=\"!canEdit\"\r\n [class.dark-class]=\"isDark\"\r\n [class.has-color]=\"card.backgroundColor\"\r\n [style.background-color]=\"card.backgroundColor\"\r\n [style.color]=\"card.fontColor\"\r\n >\r\n <nav class=\"nav-hover\">\r\n <button *ngIf=\"!canEdit\" class=\"btn font-icon\" title=\"Ampliar gr\u00E1fico\" (click)=\"openChart(card, i)\">search</button>\r\n <button *ngIf=\"!canEdit\" class=\"btn font-icon\" title=\"Baixar imagem\" (click)=\"downloadImage(i)\">download</button>\r\n </nav>\r\n <nav class=\"card-nav\" *ngIf=\"canEdit\">\r\n <div class=\"card-handle font-icon\" title=\"Mover\" cdkDragHandle>\r\n drag_pan\r\n </div>\r\n <button class=\"btn card-options font-icon\" title=\"Modificar tamanho\" mat-button [matMenuTriggerFor]=\"menu\">\r\n resize\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <ng-container *ngFor=\"let opt of orderOptions\">\r\n <button mat-menu-item (click)=\"card.cols = opt.cols; card.rows = opt.rows\" >{{opt.title}}</button>\r\n </ng-container>\r\n </mat-menu>\r\n <button class=\"btn font-icon\" title=\"Editar Tipo do Gr\u00E1fico\" (click)=\"openModalChart(card)\">{{'landscape_2_edit'}}</button>\r\n <button class=\"btn font-icon\" title=\"Editar fonte de dados\" (click)=\"openModalData(card)\">edit_note</button>\r\n <button class=\"btn font-icon\" *ngIf=\"debug\" title=\"Exibir c\u00F3digo de configura\u00E7\u00E3o\" (click)=\"openModalCode(card)\">code_blocks</button>\r\n </nav>\r\n <div class=\"custom-placeholder\" *cdkDragPlaceholder></div>\r\n <lib-card [data]=\"card\" [ngClass]=\"{'canEdit': canEdit}\" [isDark]=\"isDark\"></lib-card>\r\n </div>\r\n </div>\r\n </mat-grid-tile>\r\n <mat-grid-tile class=\"card\" [colspan]=\"1\" [rowspan]=\"1\" [class.dark-class]=\"isDark\" *ngIf=\"canEdit\">\r\n <lib-card [data]=\"emptyCard\" [ngClass]=\"{'canEdit': canEdit, cardEmpty:true}\" [isDark]=\"isDark\"\r\n (click)=\"addNewCard()\"\r\n ></lib-card>\r\n </mat-grid-tile>\r\n </mat-grid-list>\r\n</main>\r\n<ng-template #modal>\r\n <lib-modal-edit (closeModal)=\"closeModalData()\" (saveData)=\"saveData($event)\" [data]=\"modalData\" [groupType]=\"groupType\"></lib-modal-edit>\r\n</ng-template>\r\n<ng-template #modalView>\r\n <header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left mb-0\">{{currentCard.title}}</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"closeModalView()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n </header>\r\n <body id=\"modalViewBody\" class=\"modal-body py-2 overflow-auto\">\r\n <lib-card [data]=\"currentCard\" [ngClass]=\"{'canEdit': canEdit}\" [isDark]=\"isDark\"></lib-card>\r\n </body>\r\n</ng-template>\r\n<ng-template #modalCode>\r\n <header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left mb-0\">{{currentCard.title}}</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"closeModalCode()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n </header>\r\n <body id=\"modalCodeBody\" class=\"modal-body py-2 overflow-auto\">\r\n <pre class=\"code-area\">{{ currentCard | json }}</pre>\r\n <button class=\"font-icon code-copy\" title=\"Copiar json\" (click)=\"copyCode()\">content_copy</button>\r\n <span *ngIf=\"copyComplete\" class=\"copy-message\">Copiado!</span>\r\n </body>\r\n</ng-template>\r\n<ng-template #modalChart>\r\n <lib-modal-edit-chart (closeModal)=\"closeModalChart()\" [currentOption]=\"currentOption\" (saveData)=\"saveChartData($event)\"></lib-modal-edit-chart>\r\n</ng-template>", styles: [".dashboard{padding:5px;background-color:#e4e4e4}.copy-message{position:absolute;bottom:10px;left:45%;right:auto;color:#fff;padding:5px 25px;border-radius:20px;background:#1b1b1b}.code-area{background:black;color:#fff;padding:10px;line-height:1;border-radius:10px}.code-copy{top:15px;position:absolute;color:#fff;background:#3f3f3f;right:25px;display:hidden;display:none;border-radius:25px;padding:8px;border:none}.modal-body:hover .code-copy{display:inline}.card{box-sizing:border-box;color:#000000de;background:#fff;border-radius:4px;z-index:1;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f;transition:box-shadow .2s cubic-bezier(0,0,.2,1)}.card-body{border:solid 1px #ccc;height:100%}.card-body:active{border:solid 1px #ccc;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.card-body .card-nav{width:100%;height:30px;display:flex;border-bottom:1px solid gray}.card-body .card-nav .card-handle{cursor:move;width:24px;height:24px}.card-body .card-nav .card-options{border:none;display:flex;padding:0}.card-body .card-nav button,.card-body .card-nav .card-handle{font-size:18pt;display:flex;color:#898989;padding:0;margin-left:5px}.cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.more-button{float:right;font-size:2em}.cdk-drop-list{height:100%;width:100%}.cdk-drag-animating{transition:unset}.cdk-drag-placeholder{display:none}.mat-grid-tile{overflow:visible!important}.mat-grid-tile-content{height:100%!important;display:flex!important}.nav-hover{display:flex;right:10px;position:absolute;top:10px;display:none}::ng-deep .mat-grid-tile:hover .nav-hover{display:inherit}::ng-deep .dark-class:not(.has-color){background-color:#000!important;color:#fff!important}::ng-deep .dark-class.card-body:not(.has-color){background-color:#1a1a1a!important;color:#fff!important}::ng-deep .mat-grid-tile-content:has(lib-card.cardEmpty .empty-card:active){background-color:#c6c6c6}::ng-deep lib-card.cardEmpty{width:100%}::ng-deep lib-card.cardEmpty .empty-card{width:100%;height:100%;text-align:center;padding:auto;font-size:28pt}::ng-deep lib-card.cardEmpty .empty-card:active{border:none}::ng-deep lib-card.canEdit{display:block;height:calc(100% - 30px)}\n"] }]
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Component, EventEmitter, Input, Output } from '@angular/core';
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
import * as i1 from "ngx-bootstrap/modal";
|
|
4
|
-
import * as i2 from "@angular/
|
|
5
|
-
import * as i3 from "@angular/
|
|
4
|
+
import * as i2 from "@angular/forms";
|
|
5
|
+
import * as i3 from "@angular/common";
|
|
6
6
|
import * as i4 from "@ng-select/ng-select";
|
|
7
7
|
export class ModalEditComponent {
|
|
8
8
|
constructor(modalService) {
|
|
@@ -117,7 +117,7 @@ export class ModalEditComponent {
|
|
|
117
117
|
}
|
|
118
118
|
}
|
|
119
119
|
ModalEditComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ModalEditComponent, deps: [{ token: i1.BsModalService }], target: i0.ɵɵFactoryTarget.Component });
|
|
120
|
-
ModalEditComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ModalEditComponent, selector: "lib-modal-edit", inputs: { data: "data", groupType: "groupType" }, outputs: { closeModal: "closeModal", saveData: "saveData" }, ngImport: i0, template: "<header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left\">Editar fonte dos dados</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"onCloseModal()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n</header>\r\n<body class=\"modal-body table-form py-2\">\r\n <label>Tipo de Agrupamento dos dados:</label>\r\n <ng-select\r\n class=\" col-12 col-sm-4 mb-1\"\r\n [items]=\"types\"\r\n bindValue=\"id\"\r\n bindLabel=\"label\"\r\n [clearable]=\"false\"\r\n placeholder=\"Selecione...\"\r\n [(ngModel)]=\"rowsType\">\r\n </ng-select>\r\n <article *ngFor=\"let row of rows; let rowIndex = index\" class=\"line mb-2\">\r\n <div class=\"d-flex\">\r\n <ng-container *ngFor=\"let level of row.levels; let levelIndex = index\">\r\n <ng-select class=\"me-1\"\r\n [items]=\"level\"\r\n bindLabel=\"label\"\r\n [clearable]=\"false\"\r\n [placeholder]=\"'Selecione...'\"\r\n [ngModel]=\"row.selectedPath[levelIndex]\"\r\n (change)=\"onSelect($event, rowIndex, levelIndex)\">\r\n </ng-select>\r\n </ng-container>\r\n </div>\r\n <div class=\"d-flex\">\r\n <div class=\"color-div me-2\" [style.background-color]=\"rows[rowIndex].finalBackgroudColor\">\r\n <button class=\"btn font-icon\" [style.color]=\"rows[rowIndex].finalFontColor\"\r\n title=\"Cor do texto\" (click)=\"fontColor.click()\">\r\n format_color_text\r\n </button>\r\n <input #fontColor class=\"hide\" type=\"color\" (change)=\"onFontColorChange($event, rowIndex)\">\r\n <hr class=\"divisor\">\r\n <button class=\"btn font-icon\" [style.color]=\"rows[rowIndex].finalFontColor\"\r\n title=\"Cor de fundo\" (click)=\"backgroundColor.click()\">\r\n colors\r\n </button>\r\n <input #backgroundColor class=\"hide\" type=\"color\" (change)=\"onBackgroundChange($event, rowIndex)\">\r\n </div>\r\n <button class=\"btn btn-basic font-icon me-2\" type=\"button\" (click)=\"cloneRow(rowIndex)\" title=\"Clonar linha\">\r\n copy_all\r\n </button>\r\n <button class=\"btn btn-danger font-icon\" type=\"button\" (click)=\"removeRow(rowIndex)\" title=\"Remover linha\">\r\n delete\r\n </button>\r\n </div>\r\n </article>\r\n <div class=\"d-flex mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"addRow()\" title=\"Adicionar linha\">+</button>\r\n </div>\r\n <div class=\"d-flex justify-content-end mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"onSaveData()\" title=\"Salvar\">Salvar</button>\r\n </div>\r\n</body>", styles: [".modal-body{overflow-x:scroll}.modal-body .line{display:flex;justify-content:space-between}.modal-body .ng-select-alternative{min-width:150px}.modal-body .hide{width:0;visibility:hidden}.modal-body .color-div,.modal-body .btn-basic{border:1px solid gray;border-radius:5px}.modal-body .color-div{display:flex}.modal-body .color-div .divisor{height:80%;margin:5% 0;border:1px solid black}\n"], dependencies: [{ kind: "directive", type: i2.
|
|
120
|
+
ModalEditComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ModalEditComponent, selector: "lib-modal-edit", inputs: { data: "data", groupType: "groupType" }, outputs: { closeModal: "closeModal", saveData: "saveData" }, ngImport: i0, template: "<header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left\">Editar fonte dos dados</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"onCloseModal()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n</header>\r\n<body class=\"modal-body table-form py-2\">\r\n <label>Tipo de Agrupamento dos dados:</label>\r\n <ng-select\r\n class=\" col-12 col-sm-4 mb-1\"\r\n [items]=\"types\"\r\n bindValue=\"id\"\r\n bindLabel=\"label\"\r\n [clearable]=\"false\"\r\n placeholder=\"Selecione...\"\r\n [(ngModel)]=\"rowsType\">\r\n </ng-select>\r\n <article *ngFor=\"let row of rows; let rowIndex = index\" class=\"line mb-2\">\r\n <div class=\"d-flex\">\r\n <ng-container *ngFor=\"let level of row.levels; let levelIndex = index\">\r\n <ng-select class=\"me-1\"\r\n [items]=\"level\"\r\n bindLabel=\"label\"\r\n [clearable]=\"false\"\r\n [placeholder]=\"'Selecione...'\"\r\n [ngModel]=\"row.selectedPath[levelIndex]\"\r\n (change)=\"onSelect($event, rowIndex, levelIndex)\">\r\n </ng-select>\r\n </ng-container>\r\n </div>\r\n <div class=\"d-flex\">\r\n <div class=\"color-div me-2\" [style.background-color]=\"rows[rowIndex].finalBackgroudColor\">\r\n <button class=\"btn font-icon\" [style.color]=\"rows[rowIndex].finalFontColor\"\r\n title=\"Cor do texto\" (click)=\"fontColor.click()\">\r\n format_color_text\r\n </button>\r\n <input #fontColor class=\"hide\" type=\"color\" (change)=\"onFontColorChange($event, rowIndex)\">\r\n <hr class=\"divisor\">\r\n <button class=\"btn font-icon\" [style.color]=\"rows[rowIndex].finalFontColor\"\r\n title=\"Cor de fundo\" (click)=\"backgroundColor.click()\">\r\n colors\r\n </button>\r\n <input #backgroundColor class=\"hide\" type=\"color\" (change)=\"onBackgroundChange($event, rowIndex)\">\r\n </div>\r\n <button class=\"btn btn-basic font-icon me-2\" type=\"button\" (click)=\"cloneRow(rowIndex)\" title=\"Clonar linha\">\r\n copy_all\r\n </button>\r\n <button class=\"btn btn-danger font-icon\" type=\"button\" (click)=\"removeRow(rowIndex)\" title=\"Remover linha\">\r\n delete\r\n </button>\r\n </div>\r\n </article>\r\n <div class=\"d-flex mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"addRow()\" title=\"Adicionar linha\">+</button>\r\n </div>\r\n <div class=\"d-flex justify-content-end mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"onSaveData()\" title=\"Salvar\">Salvar</button>\r\n </div>\r\n</body>", styles: [".modal-body{overflow-x:scroll}.modal-body .line{display:flex;justify-content:space-between}.modal-body .ng-select-alternative{min-width:150px}.modal-body .hide{width:0;visibility:hidden}.modal-body .color-div,.modal-body .btn-basic{border:1px solid gray;border-radius:5px}.modal-body .color-div{display:flex}.modal-body .color-div .divisor{height:80%;margin:5% 0;border:1px solid black}\n"], dependencies: [{ kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: i4.NgSelectComponent, selector: "ng-select", inputs: ["bindLabel", "bindValue", "markFirst", "placeholder", "notFoundText", "typeToSearchText", "addTagText", "loadingText", "clearAllText", "appearance", "dropdownPosition", "appendTo", "loading", "closeOnSelect", "hideSelected", "selectOnTab", "openOnEnter", "maxSelectedItems", "groupBy", "groupValue", "bufferAmount", "virtualScroll", "selectableGroup", "selectableGroupAsModel", "searchFn", "trackByFn", "clearOnBackspace", "labelForId", "inputAttrs", "tabIndex", "readonly", "searchWhileComposing", "minTermLength", "editableSearchTerm", "keyDownFn", "typeahead", "multiple", "addTag", "searchable", "clearable", "isOpen", "items", "compareWith", "clearSearchOnAdd"], outputs: ["blur", "focus", "change", "open", "close", "search", "clear", "add", "remove", "scroll", "scrollToEnd"] }] });
|
|
121
121
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ModalEditComponent, decorators: [{
|
|
122
122
|
type: Component,
|
|
123
123
|
args: [{ selector: 'lib-modal-edit', template: "<header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left\">Editar fonte dos dados</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"onCloseModal()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n</header>\r\n<body class=\"modal-body table-form py-2\">\r\n <label>Tipo de Agrupamento dos dados:</label>\r\n <ng-select\r\n class=\" col-12 col-sm-4 mb-1\"\r\n [items]=\"types\"\r\n bindValue=\"id\"\r\n bindLabel=\"label\"\r\n [clearable]=\"false\"\r\n placeholder=\"Selecione...\"\r\n [(ngModel)]=\"rowsType\">\r\n </ng-select>\r\n <article *ngFor=\"let row of rows; let rowIndex = index\" class=\"line mb-2\">\r\n <div class=\"d-flex\">\r\n <ng-container *ngFor=\"let level of row.levels; let levelIndex = index\">\r\n <ng-select class=\"me-1\"\r\n [items]=\"level\"\r\n bindLabel=\"label\"\r\n [clearable]=\"false\"\r\n [placeholder]=\"'Selecione...'\"\r\n [ngModel]=\"row.selectedPath[levelIndex]\"\r\n (change)=\"onSelect($event, rowIndex, levelIndex)\">\r\n </ng-select>\r\n </ng-container>\r\n </div>\r\n <div class=\"d-flex\">\r\n <div class=\"color-div me-2\" [style.background-color]=\"rows[rowIndex].finalBackgroudColor\">\r\n <button class=\"btn font-icon\" [style.color]=\"rows[rowIndex].finalFontColor\"\r\n title=\"Cor do texto\" (click)=\"fontColor.click()\">\r\n format_color_text\r\n </button>\r\n <input #fontColor class=\"hide\" type=\"color\" (change)=\"onFontColorChange($event, rowIndex)\">\r\n <hr class=\"divisor\">\r\n <button class=\"btn font-icon\" [style.color]=\"rows[rowIndex].finalFontColor\"\r\n title=\"Cor de fundo\" (click)=\"backgroundColor.click()\">\r\n colors\r\n </button>\r\n <input #backgroundColor class=\"hide\" type=\"color\" (change)=\"onBackgroundChange($event, rowIndex)\">\r\n </div>\r\n <button class=\"btn btn-basic font-icon me-2\" type=\"button\" (click)=\"cloneRow(rowIndex)\" title=\"Clonar linha\">\r\n copy_all\r\n </button>\r\n <button class=\"btn btn-danger font-icon\" type=\"button\" (click)=\"removeRow(rowIndex)\" title=\"Remover linha\">\r\n delete\r\n </button>\r\n </div>\r\n </article>\r\n <div class=\"d-flex mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"addRow()\" title=\"Adicionar linha\">+</button>\r\n </div>\r\n <div class=\"d-flex justify-content-end mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"onSaveData()\" title=\"Salvar\">Salvar</button>\r\n </div>\r\n</body>", styles: [".modal-body{overflow-x:scroll}.modal-body .line{display:flex;justify-content:space-between}.modal-body .ng-select-alternative{min-width:150px}.modal-body .hide{width:0;visibility:hidden}.modal-body .color-div,.modal-body .btn-basic{border:1px solid gray;border-radius:5px}.modal-body .color-div{display:flex}.modal-body .color-div .divisor{height:80%;margin:5% 0;border:1px solid black}\n"] }]
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import { NgModule } from '@angular/core';
|
|
2
|
-
import { BrowserModule } from '@angular/platform-browser';
|
|
3
2
|
import { DragDropModule } from '@angular/cdk/drag-drop';
|
|
4
3
|
import { MatGridListModule } from '@angular/material/grid-list';
|
|
5
4
|
import { MatMenuModule } from '@angular/material/menu';
|
|
6
|
-
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
|
7
5
|
import { NgChartsModule } from "ng2-charts";
|
|
8
6
|
import { CardComponent } from './components/card/card.component';
|
|
9
7
|
import { BarLineComponent } from './components/charts/bar-line/bar-line.component';
|
|
@@ -14,13 +12,11 @@ import { TableComponent } from './components/charts/table/table.component';
|
|
|
14
12
|
import { DashboardComponent } from './components/dashboard/dashboard.component';
|
|
15
13
|
import { ModalEditComponent } from './components/modal-edit/modal-edit.component';
|
|
16
14
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
|
|
17
|
-
import { ModalModule } from 'ngx-bootstrap/modal';
|
|
18
15
|
import { CommonModule } from '@angular/common';
|
|
19
16
|
import { NgSelectModule } from '@ng-select/ng-select';
|
|
20
17
|
import { PrimordashComponent } from './primordash.component';
|
|
21
18
|
import { ModalEditChartComponent } from './components/modal-edit-chart/modal-edit-chart.component';
|
|
22
19
|
import * as i0 from "@angular/core";
|
|
23
|
-
import * as i1 from "ngx-bootstrap/modal";
|
|
24
20
|
export class PrimordashModule {
|
|
25
21
|
}
|
|
26
22
|
PrimordashModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PrimordashModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
@@ -33,26 +29,22 @@ PrimordashModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", versio
|
|
|
33
29
|
TableComponent,
|
|
34
30
|
ModalEditComponent,
|
|
35
31
|
ModalEditChartComponent,
|
|
36
|
-
PrimordashComponent], imports: [
|
|
37
|
-
DragDropModule,
|
|
38
|
-
BrowserAnimationsModule,
|
|
32
|
+
PrimordashComponent], imports: [DragDropModule,
|
|
39
33
|
MatGridListModule,
|
|
40
34
|
MatMenuModule,
|
|
41
35
|
NgChartsModule,
|
|
42
36
|
ReactiveFormsModule,
|
|
43
37
|
FormsModule,
|
|
44
|
-
CommonModule,
|
|
38
|
+
CommonModule,
|
|
39
|
+
NgSelectModule], exports: [DashboardComponent,
|
|
45
40
|
PrimordashComponent] });
|
|
46
|
-
PrimordashModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PrimordashModule, imports: [
|
|
47
|
-
DragDropModule,
|
|
48
|
-
BrowserAnimationsModule,
|
|
41
|
+
PrimordashModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PrimordashModule, imports: [DragDropModule,
|
|
49
42
|
MatGridListModule,
|
|
50
43
|
MatMenuModule,
|
|
51
44
|
NgChartsModule,
|
|
52
45
|
ReactiveFormsModule,
|
|
53
46
|
FormsModule,
|
|
54
47
|
CommonModule,
|
|
55
|
-
ModalModule.forRoot(),
|
|
56
48
|
NgSelectModule] });
|
|
57
49
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PrimordashModule, decorators: [{
|
|
58
50
|
type: NgModule,
|
|
@@ -70,16 +62,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
70
62
|
PrimordashComponent
|
|
71
63
|
],
|
|
72
64
|
imports: [
|
|
73
|
-
BrowserModule,
|
|
74
65
|
DragDropModule,
|
|
75
|
-
BrowserAnimationsModule,
|
|
76
66
|
MatGridListModule,
|
|
77
67
|
MatMenuModule,
|
|
78
68
|
NgChartsModule,
|
|
79
69
|
ReactiveFormsModule,
|
|
80
70
|
FormsModule,
|
|
81
71
|
CommonModule,
|
|
82
|
-
ModalModule.forRoot(),
|
|
83
72
|
NgSelectModule
|
|
84
73
|
],
|
|
85
74
|
exports: [
|
|
@@ -89,4 +78,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
89
78
|
providers: []
|
|
90
79
|
}]
|
|
91
80
|
}] });
|
|
92
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
81
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHJpbW9yZGFzaC5tb2R1bGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wcm9qZWN0cy9wcmltb3JkYXNoL3NyYy9saWIvcHJpbW9yZGFzaC5tb2R1bGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFFBQVEsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUN6QyxPQUFPLEVBQUUsY0FBYyxFQUFFLE1BQU0sd0JBQXdCLENBQUM7QUFDeEQsT0FBTyxFQUFFLGlCQUFpQixFQUFFLE1BQU0sNkJBQTZCLENBQUM7QUFDaEUsT0FBTyxFQUFFLGFBQWEsRUFBRSxNQUFNLHdCQUF3QixDQUFDO0FBQ3ZELE9BQU8sRUFBRSxjQUFjLEVBQUUsTUFBTSxZQUFZLENBQUM7QUFDNUMsT0FBTyxFQUFFLGFBQWEsRUFBRSxNQUFNLGtDQUFrQyxDQUFDO0FBQ2pFLE9BQU8sRUFBRSxnQkFBZ0IsRUFBRSxNQUFNLGlEQUFpRCxDQUFDO0FBQ25GLE9BQU8sRUFBRSxlQUFlLEVBQUUsTUFBTSw2Q0FBNkMsQ0FBQztBQUM5RSxPQUFPLEVBQUUsWUFBWSxFQUFFLE1BQU0sdUNBQXVDLENBQUM7QUFDckUsT0FBTyxFQUFFLG1CQUFtQixFQUFFLE1BQU0sdURBQXVELENBQUM7QUFDNUYsT0FBTyxFQUFFLGNBQWMsRUFBRSxNQUFNLDJDQUEyQyxDQUFDO0FBQzNFLE9BQU8sRUFBRSxrQkFBa0IsRUFBRSxNQUFNLDRDQUE0QyxDQUFDO0FBQ2hGLE9BQU8sRUFBRSxrQkFBa0IsRUFBRSxNQUFNLDhDQUE4QyxDQUFDO0FBQ2xGLE9BQU8sRUFBRSxXQUFXLEVBQUUsbUJBQW1CLEVBQUUsTUFBTSxnQkFBZ0IsQ0FBQztBQUNsRSxPQUFPLEVBQUUsWUFBWSxFQUFFLE1BQU0saUJBQWlCLENBQUM7QUFDL0MsT0FBTyxFQUFFLGNBQWMsRUFBRSxNQUFNLHNCQUFzQixDQUFDO0FBQ3RELE9BQU8sRUFBRSxtQkFBbUIsRUFBRSxNQUFNLHdCQUF3QixDQUFDO0FBQzdELE9BQU8sRUFBRSx1QkFBdUIsRUFBRSxNQUFNLDBEQUEwRCxDQUFDOztBQWlDbkcsTUFBTSxPQUFPLGdCQUFnQjs7OEdBQWhCLGdCQUFnQjsrR0FBaEIsZ0JBQWdCLGlCQTdCekIsa0JBQWtCO1FBQ2xCLGFBQWE7UUFDYixnQkFBZ0I7UUFDaEIsZUFBZTtRQUNmLFlBQVk7UUFDWixtQkFBbUI7UUFDbkIsY0FBYztRQUNkLGtCQUFrQjtRQUNsQix1QkFBdUI7UUFDdkIsbUJBQW1CLGFBR25CLGNBQWM7UUFDZCxpQkFBaUI7UUFDakIsYUFBYTtRQUNiLGNBQWM7UUFDZCxtQkFBbUI7UUFDbkIsV0FBVztRQUNYLFlBQVk7UUFDWixjQUFjLGFBR2Qsa0JBQWtCO1FBQ2xCLG1CQUFtQjsrR0FNVixnQkFBZ0IsWUFqQnpCLGNBQWM7UUFDZCxpQkFBaUI7UUFDakIsYUFBYTtRQUNiLGNBQWM7UUFDZCxtQkFBbUI7UUFDbkIsV0FBVztRQUNYLFlBQVk7UUFDWixjQUFjOzRGQVVMLGdCQUFnQjtrQkEvQjVCLFFBQVE7bUJBQUM7b0JBQ1IsWUFBWSxFQUFFO3dCQUNaLGtCQUFrQjt3QkFDbEIsYUFBYTt3QkFDYixnQkFBZ0I7d0JBQ2hCLGVBQWU7d0JBQ2YsWUFBWTt3QkFDWixtQkFBbUI7d0JBQ25CLGNBQWM7d0JBQ2Qsa0JBQWtCO3dCQUNsQix1QkFBdUI7d0JBQ3ZCLG1CQUFtQjtxQkFDcEI7b0JBQ0QsT0FBTyxFQUFFO3dCQUNQLGNBQWM7d0JBQ2QsaUJBQWlCO3dCQUNqQixhQUFhO3dCQUNiLGNBQWM7d0JBQ2QsbUJBQW1CO3dCQUNuQixXQUFXO3dCQUNYLFlBQVk7d0JBQ1osY0FBYztxQkFDakI7b0JBQ0MsT0FBTyxFQUFDO3dCQUNOLGtCQUFrQjt3QkFDbEIsbUJBQW1CO3FCQUNwQjtvQkFDRCxTQUFTLEVBQUUsRUFDVjtpQkFDRiIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IE5nTW9kdWxlIH0gZnJvbSAnQGFuZ3VsYXIvY29yZSc7XHJcbmltcG9ydCB7IERyYWdEcm9wTW9kdWxlIH0gZnJvbSAnQGFuZ3VsYXIvY2RrL2RyYWctZHJvcCc7XHJcbmltcG9ydCB7IE1hdEdyaWRMaXN0TW9kdWxlIH0gZnJvbSAnQGFuZ3VsYXIvbWF0ZXJpYWwvZ3JpZC1saXN0JztcclxuaW1wb3J0IHsgTWF0TWVudU1vZHVsZSB9IGZyb20gJ0Bhbmd1bGFyL21hdGVyaWFsL21lbnUnO1xyXG5pbXBvcnQgeyBOZ0NoYXJ0c01vZHVsZSB9IGZyb20gXCJuZzItY2hhcnRzXCI7XHJcbmltcG9ydCB7IENhcmRDb21wb25lbnQgfSBmcm9tICcuL2NvbXBvbmVudHMvY2FyZC9jYXJkLmNvbXBvbmVudCc7XHJcbmltcG9ydCB7IEJhckxpbmVDb21wb25lbnQgfSBmcm9tICcuL2NvbXBvbmVudHMvY2hhcnRzL2Jhci1saW5lL2Jhci1saW5lLmNvbXBvbmVudCc7XHJcbmltcG9ydCB7IEJ1YmJsZUNvbXBvbmVudCB9IGZyb20gJy4vY29tcG9uZW50cy9jaGFydHMvYnViYmxlL2J1YmJsZS5jb21wb25lbnQnO1xyXG5pbXBvcnQgeyBQaWVDb21wb25lbnQgfSBmcm9tICcuL2NvbXBvbmVudHMvY2hhcnRzL3BpZS9waWUuY29tcG9uZW50JztcclxuaW1wb3J0IHsgU2ltcGxlQ2FyZENvbXBvbmVudCB9IGZyb20gJy4vY29tcG9uZW50cy9jaGFydHMvc2ltcGxlLWNhcmQvc2ltcGxlLWNhcmQuY29tcG9uZW50JztcclxuaW1wb3J0IHsgVGFibGVDb21wb25lbnQgfSBmcm9tICcuL2NvbXBvbmVudHMvY2hhcnRzL3RhYmxlL3RhYmxlLmNvbXBvbmVudCc7XHJcbmltcG9ydCB7IERhc2hib2FyZENvbXBvbmVudCB9IGZyb20gJy4vY29tcG9uZW50cy9kYXNoYm9hcmQvZGFzaGJvYXJkLmNvbXBvbmVudCc7XHJcbmltcG9ydCB7IE1vZGFsRWRpdENvbXBvbmVudCB9IGZyb20gJy4vY29tcG9uZW50cy9tb2RhbC1lZGl0L21vZGFsLWVkaXQuY29tcG9uZW50JztcclxuaW1wb3J0IHsgRm9ybXNNb2R1bGUsIFJlYWN0aXZlRm9ybXNNb2R1bGUgfSBmcm9tICdAYW5ndWxhci9mb3Jtcyc7XHJcbmltcG9ydCB7IENvbW1vbk1vZHVsZSB9IGZyb20gJ0Bhbmd1bGFyL2NvbW1vbic7XHJcbmltcG9ydCB7IE5nU2VsZWN0TW9kdWxlIH0gZnJvbSAnQG5nLXNlbGVjdC9uZy1zZWxlY3QnO1xyXG5pbXBvcnQgeyBQcmltb3JkYXNoQ29tcG9uZW50IH0gZnJvbSAnLi9wcmltb3JkYXNoLmNvbXBvbmVudCc7XHJcbmltcG9ydCB7IE1vZGFsRWRpdENoYXJ0Q29tcG9uZW50IH0gZnJvbSAnLi9jb21wb25lbnRzL21vZGFsLWVkaXQtY2hhcnQvbW9kYWwtZWRpdC1jaGFydC5jb21wb25lbnQnO1xyXG5cclxuQE5nTW9kdWxlKHtcclxuICBkZWNsYXJhdGlvbnM6IFtcclxuICAgIERhc2hib2FyZENvbXBvbmVudCxcclxuICAgIENhcmRDb21wb25lbnQsXHJcbiAgICBCYXJMaW5lQ29tcG9uZW50LFxyXG4gICAgQnViYmxlQ29tcG9uZW50LFxyXG4gICAgUGllQ29tcG9uZW50LFxyXG4gICAgU2ltcGxlQ2FyZENvbXBvbmVudCxcclxuICAgIFRhYmxlQ29tcG9uZW50LFxyXG4gICAgTW9kYWxFZGl0Q29tcG9uZW50LFxyXG4gICAgTW9kYWxFZGl0Q2hhcnRDb21wb25lbnQsXHJcbiAgICBQcmltb3JkYXNoQ29tcG9uZW50XHJcbiAgXSxcclxuICBpbXBvcnRzOiBbXHJcbiAgICBEcmFnRHJvcE1vZHVsZSxcclxuICAgIE1hdEdyaWRMaXN0TW9kdWxlLFxyXG4gICAgTWF0TWVudU1vZHVsZSxcclxuICAgIE5nQ2hhcnRzTW9kdWxlLFxyXG4gICAgUmVhY3RpdmVGb3Jtc01vZHVsZSxcclxuICAgIEZvcm1zTW9kdWxlLFxyXG4gICAgQ29tbW9uTW9kdWxlLFxyXG4gICAgTmdTZWxlY3RNb2R1bGVcclxuXSxcclxuICBleHBvcnRzOltcclxuICAgIERhc2hib2FyZENvbXBvbmVudCxcclxuICAgIFByaW1vcmRhc2hDb21wb25lbnRcclxuICBdLFxyXG4gIHByb3ZpZGVyczogW1xyXG4gIF1cclxufSlcclxuXHJcbmV4cG9ydCBjbGFzcyBQcmltb3JkYXNoTW9kdWxlIHsgfVxyXG4iXX0=
|
|
@@ -1,24 +1,21 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { Injectable, Component, Input, ViewChild, HostListener, EventEmitter, Output, ViewChildren, NgModule } from '@angular/core';
|
|
3
|
-
import * as
|
|
3
|
+
import * as i2$1 from '@angular/cdk/drag-drop';
|
|
4
4
|
import { moveItemInArray, CdkDropList, DragDropModule } from '@angular/cdk/drag-drop';
|
|
5
5
|
import * as i1$2 from 'ngx-bootstrap/modal';
|
|
6
|
-
import
|
|
7
|
-
import * as i2 from '@angular/common';
|
|
8
|
-
import { CommonModule } from '@angular/common';
|
|
9
|
-
import * as i4$1 from '@angular/material/grid-list';
|
|
6
|
+
import * as i3 from '@angular/material/grid-list';
|
|
10
7
|
import { MatGridListModule } from '@angular/material/grid-list';
|
|
11
|
-
import * as
|
|
8
|
+
import * as i4$1 from '@angular/material/menu';
|
|
12
9
|
import { MatMenuModule } from '@angular/material/menu';
|
|
10
|
+
import * as i5 from '@angular/common';
|
|
11
|
+
import { CommonModule } from '@angular/common';
|
|
13
12
|
import * as i1$1 from '@angular/platform-browser';
|
|
14
|
-
import { BrowserModule } from '@angular/platform-browser';
|
|
15
13
|
import * as i1 from 'ng2-charts';
|
|
16
14
|
import { BaseChartDirective, NgChartsModule } from 'ng2-charts';
|
|
17
|
-
import * as
|
|
15
|
+
import * as i2 from '@angular/forms';
|
|
18
16
|
import { ReactiveFormsModule, FormsModule } from '@angular/forms';
|
|
19
17
|
import * as i4 from '@ng-select/ng-select';
|
|
20
18
|
import { NgSelectModule } from '@ng-select/ng-select';
|
|
21
|
-
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
|
22
19
|
|
|
23
20
|
class PrimordashService {
|
|
24
21
|
constructor() { }
|
|
@@ -716,7 +713,7 @@ class TableComponent {
|
|
|
716
713
|
}
|
|
717
714
|
}
|
|
718
715
|
TableComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TableComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
719
|
-
TableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TableComponent, selector: "lib-table", inputs: { type: "type", isDark: "isDark", card: "card" }, ngImport: i0, template: "<div class=\"chart-div pt-2\" #container>\r\n <table class=\"table table-striped\" [class.table-dark]=\"isDark\">\r\n <thead>\r\n <tr>\r\n <th *ngFor=\"let key of card.keys\">{{key.label}}</th>\r\n </tr>\r\n </thead>\r\n <tbody class=\"table-group-divider\">\r\n <tr *ngFor=\"let data of card.data\">\r\n <td *ngFor=\"let key of card.keys\">{{data[key.key]}}</td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n</div>", styles: [""], dependencies: [{ kind: "directive", type:
|
|
716
|
+
TableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: TableComponent, selector: "lib-table", inputs: { type: "type", isDark: "isDark", card: "card" }, ngImport: i0, template: "<div class=\"chart-div pt-2\" #container>\r\n <table class=\"table table-striped\" [class.table-dark]=\"isDark\">\r\n <thead>\r\n <tr>\r\n <th *ngFor=\"let key of card.keys\">{{key.label}}</th>\r\n </tr>\r\n </thead>\r\n <tbody class=\"table-group-divider\">\r\n <tr *ngFor=\"let data of card.data\">\r\n <td *ngFor=\"let key of card.keys\">{{data[key.key]}}</td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n</div>", styles: [""], dependencies: [{ kind: "directive", type: i5.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
720
717
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: TableComponent, decorators: [{
|
|
721
718
|
type: Component,
|
|
722
719
|
args: [{ selector: 'lib-table', template: "<div class=\"chart-div pt-2\" #container>\r\n <table class=\"table table-striped\" [class.table-dark]=\"isDark\">\r\n <thead>\r\n <tr>\r\n <th *ngFor=\"let key of card.keys\">{{key.label}}</th>\r\n </tr>\r\n </thead>\r\n <tbody class=\"table-group-divider\">\r\n <tr *ngFor=\"let data of card.data\">\r\n <td *ngFor=\"let key of card.keys\">{{data[key.key]}}</td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n</div>" }]
|
|
@@ -782,7 +779,7 @@ class CardComponent {
|
|
|
782
779
|
}
|
|
783
780
|
}
|
|
784
781
|
CardComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CardComponent, deps: [{ token: i1$1.DomSanitizer }], target: i0.ɵɵFactoryTarget.Component });
|
|
785
|
-
CardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: CardComponent, selector: "lib-card", inputs: { data: "data", isDark: "isDark" }, ngImport: i0, template: "<section class=\"card-section\">\r\n {{data.title}}\r\n <div class=\"card-chart\">\r\n <lib-bar-line *ngIf=\"this.includeBarType(this.data)\" \r\n [card]=\"data\" [type]=\"barLineType\" [isDark]=\"isDark\"></lib-bar-line>\r\n\r\n <lib-pie *ngIf=\"['pie', 'doughnut', 'polarArea', 'halfDoughnut', 'multiPie'].includes(data.type ?? '')\" \r\n [card]=\"data\" [type]=\"pieType\" [isDark]=\"isDark\"></lib-pie>\r\n\r\n <lib-bubble *ngIf=\"['bubble'].includes(data.type ?? '')\" \r\n [card]=\"data\" [type]=\"bubbleType\" [isDark]=\"isDark\"></lib-bubble>\r\n\r\n <lib-simple-card *ngIf=\"['simpleCard'].includes(data.type ?? '')\" \r\n [card]=\"data\" [type]=\"cardType\" [isDark]=\"isDark\"></lib-simple-card>\r\n\r\n <lib-table *ngIf=\"['table'].includes(data.type ?? '')\" \r\n [card]=\"data\" [type]=\"tableType\" [isDark]=\"isDark\"></lib-table>\r\n\r\n <div class=\"card-html\" *ngIf=\"data.type == 'html'\" [innerHtml]=\"safeHtml\">\r\n </div>\r\n </div>\r\n</section>", styles: [".card-section{display:flex;flex-direction:column;height:100%}.card-section .card-chart{flex-grow:1;min-height:0}.card-section .card-chart .card-html{height:100%}\n"], dependencies: [{ kind: "directive", type:
|
|
782
|
+
CardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: CardComponent, selector: "lib-card", inputs: { data: "data", isDark: "isDark" }, ngImport: i0, template: "<section class=\"card-section\">\r\n {{data.title}}\r\n <div class=\"card-chart\">\r\n <lib-bar-line *ngIf=\"this.includeBarType(this.data)\" \r\n [card]=\"data\" [type]=\"barLineType\" [isDark]=\"isDark\"></lib-bar-line>\r\n\r\n <lib-pie *ngIf=\"['pie', 'doughnut', 'polarArea', 'halfDoughnut', 'multiPie'].includes(data.type ?? '')\" \r\n [card]=\"data\" [type]=\"pieType\" [isDark]=\"isDark\"></lib-pie>\r\n\r\n <lib-bubble *ngIf=\"['bubble'].includes(data.type ?? '')\" \r\n [card]=\"data\" [type]=\"bubbleType\" [isDark]=\"isDark\"></lib-bubble>\r\n\r\n <lib-simple-card *ngIf=\"['simpleCard'].includes(data.type ?? '')\" \r\n [card]=\"data\" [type]=\"cardType\" [isDark]=\"isDark\"></lib-simple-card>\r\n\r\n <lib-table *ngIf=\"['table'].includes(data.type ?? '')\" \r\n [card]=\"data\" [type]=\"tableType\" [isDark]=\"isDark\"></lib-table>\r\n\r\n <div class=\"card-html\" *ngIf=\"data.type == 'html'\" [innerHtml]=\"safeHtml\">\r\n </div>\r\n </div>\r\n</section>", styles: [".card-section{display:flex;flex-direction:column;height:100%}.card-section .card-chart{flex-grow:1;min-height:0}.card-section .card-chart .card-html{height:100%}\n"], dependencies: [{ kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: BarLineComponent, selector: "lib-bar-line", inputs: ["type", "isDark", "card"] }, { kind: "component", type: BubbleComponent, selector: "lib-bubble", inputs: ["type", "isDark", "card"] }, { kind: "component", type: PieComponent, selector: "lib-pie", inputs: ["type", "isDark", "card"] }, { kind: "component", type: SimpleCardComponent, selector: "lib-simple-card", inputs: ["type", "isDark", "card"] }, { kind: "component", type: TableComponent, selector: "lib-table", inputs: ["type", "isDark", "card"] }] });
|
|
786
783
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CardComponent, decorators: [{
|
|
787
784
|
type: Component,
|
|
788
785
|
args: [{ selector: 'lib-card', template: "<section class=\"card-section\">\r\n {{data.title}}\r\n <div class=\"card-chart\">\r\n <lib-bar-line *ngIf=\"this.includeBarType(this.data)\" \r\n [card]=\"data\" [type]=\"barLineType\" [isDark]=\"isDark\"></lib-bar-line>\r\n\r\n <lib-pie *ngIf=\"['pie', 'doughnut', 'polarArea', 'halfDoughnut', 'multiPie'].includes(data.type ?? '')\" \r\n [card]=\"data\" [type]=\"pieType\" [isDark]=\"isDark\"></lib-pie>\r\n\r\n <lib-bubble *ngIf=\"['bubble'].includes(data.type ?? '')\" \r\n [card]=\"data\" [type]=\"bubbleType\" [isDark]=\"isDark\"></lib-bubble>\r\n\r\n <lib-simple-card *ngIf=\"['simpleCard'].includes(data.type ?? '')\" \r\n [card]=\"data\" [type]=\"cardType\" [isDark]=\"isDark\"></lib-simple-card>\r\n\r\n <lib-table *ngIf=\"['table'].includes(data.type ?? '')\" \r\n [card]=\"data\" [type]=\"tableType\" [isDark]=\"isDark\"></lib-table>\r\n\r\n <div class=\"card-html\" *ngIf=\"data.type == 'html'\" [innerHtml]=\"safeHtml\">\r\n </div>\r\n </div>\r\n</section>", styles: [".card-section{display:flex;flex-direction:column;height:100%}.card-section .card-chart{flex-grow:1;min-height:0}.card-section .card-chart .card-html{height:100%}\n"] }]
|
|
@@ -908,7 +905,7 @@ class ModalEditComponent {
|
|
|
908
905
|
}
|
|
909
906
|
}
|
|
910
907
|
ModalEditComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ModalEditComponent, deps: [{ token: i1$2.BsModalService }], target: i0.ɵɵFactoryTarget.Component });
|
|
911
|
-
ModalEditComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ModalEditComponent, selector: "lib-modal-edit", inputs: { data: "data", groupType: "groupType" }, outputs: { closeModal: "closeModal", saveData: "saveData" }, ngImport: i0, template: "<header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left\">Editar fonte dos dados</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"onCloseModal()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n</header>\r\n<body class=\"modal-body table-form py-2\">\r\n <label>Tipo de Agrupamento dos dados:</label>\r\n <ng-select\r\n class=\" col-12 col-sm-4 mb-1\"\r\n [items]=\"types\"\r\n bindValue=\"id\"\r\n bindLabel=\"label\"\r\n [clearable]=\"false\"\r\n placeholder=\"Selecione...\"\r\n [(ngModel)]=\"rowsType\">\r\n </ng-select>\r\n <article *ngFor=\"let row of rows; let rowIndex = index\" class=\"line mb-2\">\r\n <div class=\"d-flex\">\r\n <ng-container *ngFor=\"let level of row.levels; let levelIndex = index\">\r\n <ng-select class=\"me-1\"\r\n [items]=\"level\"\r\n bindLabel=\"label\"\r\n [clearable]=\"false\"\r\n [placeholder]=\"'Selecione...'\"\r\n [ngModel]=\"row.selectedPath[levelIndex]\"\r\n (change)=\"onSelect($event, rowIndex, levelIndex)\">\r\n </ng-select>\r\n </ng-container>\r\n </div>\r\n <div class=\"d-flex\">\r\n <div class=\"color-div me-2\" [style.background-color]=\"rows[rowIndex].finalBackgroudColor\">\r\n <button class=\"btn font-icon\" [style.color]=\"rows[rowIndex].finalFontColor\"\r\n title=\"Cor do texto\" (click)=\"fontColor.click()\">\r\n format_color_text\r\n </button>\r\n <input #fontColor class=\"hide\" type=\"color\" (change)=\"onFontColorChange($event, rowIndex)\">\r\n <hr class=\"divisor\">\r\n <button class=\"btn font-icon\" [style.color]=\"rows[rowIndex].finalFontColor\"\r\n title=\"Cor de fundo\" (click)=\"backgroundColor.click()\">\r\n colors\r\n </button>\r\n <input #backgroundColor class=\"hide\" type=\"color\" (change)=\"onBackgroundChange($event, rowIndex)\">\r\n </div>\r\n <button class=\"btn btn-basic font-icon me-2\" type=\"button\" (click)=\"cloneRow(rowIndex)\" title=\"Clonar linha\">\r\n copy_all\r\n </button>\r\n <button class=\"btn btn-danger font-icon\" type=\"button\" (click)=\"removeRow(rowIndex)\" title=\"Remover linha\">\r\n delete\r\n </button>\r\n </div>\r\n </article>\r\n <div class=\"d-flex mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"addRow()\" title=\"Adicionar linha\">+</button>\r\n </div>\r\n <div class=\"d-flex justify-content-end mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"onSaveData()\" title=\"Salvar\">Salvar</button>\r\n </div>\r\n</body>", styles: [".modal-body{overflow-x:scroll}.modal-body .line{display:flex;justify-content:space-between}.modal-body .ng-select-alternative{min-width:150px}.modal-body .hide{width:0;visibility:hidden}.modal-body .color-div,.modal-body .btn-basic{border:1px solid gray;border-radius:5px}.modal-body .color-div{display:flex}.modal-body .color-div .divisor{height:80%;margin:5% 0;border:1px solid black}\n"], dependencies: [{ kind: "directive", type: i2.
|
|
908
|
+
ModalEditComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ModalEditComponent, selector: "lib-modal-edit", inputs: { data: "data", groupType: "groupType" }, outputs: { closeModal: "closeModal", saveData: "saveData" }, ngImport: i0, template: "<header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left\">Editar fonte dos dados</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"onCloseModal()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n</header>\r\n<body class=\"modal-body table-form py-2\">\r\n <label>Tipo de Agrupamento dos dados:</label>\r\n <ng-select\r\n class=\" col-12 col-sm-4 mb-1\"\r\n [items]=\"types\"\r\n bindValue=\"id\"\r\n bindLabel=\"label\"\r\n [clearable]=\"false\"\r\n placeholder=\"Selecione...\"\r\n [(ngModel)]=\"rowsType\">\r\n </ng-select>\r\n <article *ngFor=\"let row of rows; let rowIndex = index\" class=\"line mb-2\">\r\n <div class=\"d-flex\">\r\n <ng-container *ngFor=\"let level of row.levels; let levelIndex = index\">\r\n <ng-select class=\"me-1\"\r\n [items]=\"level\"\r\n bindLabel=\"label\"\r\n [clearable]=\"false\"\r\n [placeholder]=\"'Selecione...'\"\r\n [ngModel]=\"row.selectedPath[levelIndex]\"\r\n (change)=\"onSelect($event, rowIndex, levelIndex)\">\r\n </ng-select>\r\n </ng-container>\r\n </div>\r\n <div class=\"d-flex\">\r\n <div class=\"color-div me-2\" [style.background-color]=\"rows[rowIndex].finalBackgroudColor\">\r\n <button class=\"btn font-icon\" [style.color]=\"rows[rowIndex].finalFontColor\"\r\n title=\"Cor do texto\" (click)=\"fontColor.click()\">\r\n format_color_text\r\n </button>\r\n <input #fontColor class=\"hide\" type=\"color\" (change)=\"onFontColorChange($event, rowIndex)\">\r\n <hr class=\"divisor\">\r\n <button class=\"btn font-icon\" [style.color]=\"rows[rowIndex].finalFontColor\"\r\n title=\"Cor de fundo\" (click)=\"backgroundColor.click()\">\r\n colors\r\n </button>\r\n <input #backgroundColor class=\"hide\" type=\"color\" (change)=\"onBackgroundChange($event, rowIndex)\">\r\n </div>\r\n <button class=\"btn btn-basic font-icon me-2\" type=\"button\" (click)=\"cloneRow(rowIndex)\" title=\"Clonar linha\">\r\n copy_all\r\n </button>\r\n <button class=\"btn btn-danger font-icon\" type=\"button\" (click)=\"removeRow(rowIndex)\" title=\"Remover linha\">\r\n delete\r\n </button>\r\n </div>\r\n </article>\r\n <div class=\"d-flex mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"addRow()\" title=\"Adicionar linha\">+</button>\r\n </div>\r\n <div class=\"d-flex justify-content-end mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"onSaveData()\" title=\"Salvar\">Salvar</button>\r\n </div>\r\n</body>", styles: [".modal-body{overflow-x:scroll}.modal-body .line{display:flex;justify-content:space-between}.modal-body .ng-select-alternative{min-width:150px}.modal-body .hide{width:0;visibility:hidden}.modal-body .color-div,.modal-body .btn-basic{border:1px solid gray;border-radius:5px}.modal-body .color-div{display:flex}.modal-body .color-div .divisor{height:80%;margin:5% 0;border:1px solid black}\n"], dependencies: [{ kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: i4.NgSelectComponent, selector: "ng-select", inputs: ["bindLabel", "bindValue", "markFirst", "placeholder", "notFoundText", "typeToSearchText", "addTagText", "loadingText", "clearAllText", "appearance", "dropdownPosition", "appendTo", "loading", "closeOnSelect", "hideSelected", "selectOnTab", "openOnEnter", "maxSelectedItems", "groupBy", "groupValue", "bufferAmount", "virtualScroll", "selectableGroup", "selectableGroupAsModel", "searchFn", "trackByFn", "clearOnBackspace", "labelForId", "inputAttrs", "tabIndex", "readonly", "searchWhileComposing", "minTermLength", "editableSearchTerm", "keyDownFn", "typeahead", "multiple", "addTag", "searchable", "clearable", "isOpen", "items", "compareWith", "clearSearchOnAdd"], outputs: ["blur", "focus", "change", "open", "close", "search", "clear", "add", "remove", "scroll", "scrollToEnd"] }] });
|
|
912
909
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ModalEditComponent, decorators: [{
|
|
913
910
|
type: Component,
|
|
914
911
|
args: [{ selector: 'lib-modal-edit', template: "<header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left\">Editar fonte dos dados</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"onCloseModal()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n</header>\r\n<body class=\"modal-body table-form py-2\">\r\n <label>Tipo de Agrupamento dos dados:</label>\r\n <ng-select\r\n class=\" col-12 col-sm-4 mb-1\"\r\n [items]=\"types\"\r\n bindValue=\"id\"\r\n bindLabel=\"label\"\r\n [clearable]=\"false\"\r\n placeholder=\"Selecione...\"\r\n [(ngModel)]=\"rowsType\">\r\n </ng-select>\r\n <article *ngFor=\"let row of rows; let rowIndex = index\" class=\"line mb-2\">\r\n <div class=\"d-flex\">\r\n <ng-container *ngFor=\"let level of row.levels; let levelIndex = index\">\r\n <ng-select class=\"me-1\"\r\n [items]=\"level\"\r\n bindLabel=\"label\"\r\n [clearable]=\"false\"\r\n [placeholder]=\"'Selecione...'\"\r\n [ngModel]=\"row.selectedPath[levelIndex]\"\r\n (change)=\"onSelect($event, rowIndex, levelIndex)\">\r\n </ng-select>\r\n </ng-container>\r\n </div>\r\n <div class=\"d-flex\">\r\n <div class=\"color-div me-2\" [style.background-color]=\"rows[rowIndex].finalBackgroudColor\">\r\n <button class=\"btn font-icon\" [style.color]=\"rows[rowIndex].finalFontColor\"\r\n title=\"Cor do texto\" (click)=\"fontColor.click()\">\r\n format_color_text\r\n </button>\r\n <input #fontColor class=\"hide\" type=\"color\" (change)=\"onFontColorChange($event, rowIndex)\">\r\n <hr class=\"divisor\">\r\n <button class=\"btn font-icon\" [style.color]=\"rows[rowIndex].finalFontColor\"\r\n title=\"Cor de fundo\" (click)=\"backgroundColor.click()\">\r\n colors\r\n </button>\r\n <input #backgroundColor class=\"hide\" type=\"color\" (change)=\"onBackgroundChange($event, rowIndex)\">\r\n </div>\r\n <button class=\"btn btn-basic font-icon me-2\" type=\"button\" (click)=\"cloneRow(rowIndex)\" title=\"Clonar linha\">\r\n copy_all\r\n </button>\r\n <button class=\"btn btn-danger font-icon\" type=\"button\" (click)=\"removeRow(rowIndex)\" title=\"Remover linha\">\r\n delete\r\n </button>\r\n </div>\r\n </article>\r\n <div class=\"d-flex mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"addRow()\" title=\"Adicionar linha\">+</button>\r\n </div>\r\n <div class=\"d-flex justify-content-end mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"onSaveData()\" title=\"Salvar\">Salvar</button>\r\n </div>\r\n</body>", styles: [".modal-body{overflow-x:scroll}.modal-body .line{display:flex;justify-content:space-between}.modal-body .ng-select-alternative{min-width:150px}.modal-body .hide{width:0;visibility:hidden}.modal-body .color-div,.modal-body .btn-basic{border:1px solid gray;border-radius:5px}.modal-body .color-div{display:flex}.modal-body .color-div .divisor{height:80%;margin:5% 0;border:1px solid black}\n"] }]
|
|
@@ -963,7 +960,7 @@ class ModalEditChartComponent {
|
|
|
963
960
|
}
|
|
964
961
|
}
|
|
965
962
|
ModalEditChartComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ModalEditChartComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
966
|
-
ModalEditChartComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ModalEditChartComponent, selector: "lib-modal-edit-chart", inputs: { currentOption: "currentOption" }, outputs: { closeModal: "closeModal", saveData: "saveData" }, ngImport: i0, template: "<header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left\">Editar fonte dos dados</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"onCloseModal()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n</header>\r\n<body class=\"modal-body table-form py-2\">\r\n <section class=\"d-grid\">\r\n <label >Titulo:\r\n <input class=\"form-control\"/>\r\n </label>\r\n <label>\r\n <input type=\"checkbox\"> Mostrar legenda no Gr\u00E1fico\r\n </label>\r\n <label>\r\n <input type=\"checkbox\"> Mostrar simbolo '%' na legenda\r\n </label>\r\n </section>\r\n <hr>\r\n <h3>TIPO:</h3>\r\n <section class=\"row g-0\">\r\n <div class=\"card-chart col-12 col-sm-6 col-md-6 col-lg-4 col-xl-3\" *ngFor=\"let opt of options\">\r\n <b>{{opt.title}}</b>\r\n <img [src]=\"'assets/dashboard/images/' + opt.id +'.png'\" (click)=\"setCurrentOption(opt.id)\">\r\n </div>\r\n </section>\r\n <div class=\"d-flex justify-content-end mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"onSaveData()\" title=\"Salvar\">Salvar</button>\r\n </div>\r\n</body>", styles: [".card-chart{display:flex;flex-direction:column;border:1px solid gray;border-radius:5px;padding:5px;aspect-ratio:1/1;overflow:hidden}.card-chart img{object-fit:cover;width:100%;margin:auto}\n"], dependencies: [{ kind: "directive", type:
|
|
963
|
+
ModalEditChartComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ModalEditChartComponent, selector: "lib-modal-edit-chart", inputs: { currentOption: "currentOption" }, outputs: { closeModal: "closeModal", saveData: "saveData" }, ngImport: i0, template: "<header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left\">Editar fonte dos dados</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"onCloseModal()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n</header>\r\n<body class=\"modal-body table-form py-2\">\r\n <section class=\"d-grid\">\r\n <label >Titulo:\r\n <input class=\"form-control\"/>\r\n </label>\r\n <label>\r\n <input type=\"checkbox\"> Mostrar legenda no Gr\u00E1fico\r\n </label>\r\n <label>\r\n <input type=\"checkbox\"> Mostrar simbolo '%' na legenda\r\n </label>\r\n </section>\r\n <hr>\r\n <h3>TIPO:</h3>\r\n <section class=\"row g-0\">\r\n <div class=\"card-chart col-12 col-sm-6 col-md-6 col-lg-4 col-xl-3\" *ngFor=\"let opt of options\">\r\n <b>{{opt.title}}</b>\r\n <img [src]=\"'assets/dashboard/images/' + opt.id +'.png'\" (click)=\"setCurrentOption(opt.id)\">\r\n </div>\r\n </section>\r\n <div class=\"d-flex justify-content-end mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"onSaveData()\" title=\"Salvar\">Salvar</button>\r\n </div>\r\n</body>", styles: [".card-chart{display:flex;flex-direction:column;border:1px solid gray;border-radius:5px;padding:5px;aspect-ratio:1/1;overflow:hidden}.card-chart img{object-fit:cover;width:100%;margin:auto}\n"], dependencies: [{ kind: "directive", type: i5.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
967
964
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ModalEditChartComponent, decorators: [{
|
|
968
965
|
type: Component,
|
|
969
966
|
args: [{ selector: 'lib-modal-edit-chart', template: "<header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left\">Editar fonte dos dados</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"onCloseModal()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n</header>\r\n<body class=\"modal-body table-form py-2\">\r\n <section class=\"d-grid\">\r\n <label >Titulo:\r\n <input class=\"form-control\"/>\r\n </label>\r\n <label>\r\n <input type=\"checkbox\"> Mostrar legenda no Gr\u00E1fico\r\n </label>\r\n <label>\r\n <input type=\"checkbox\"> Mostrar simbolo '%' na legenda\r\n </label>\r\n </section>\r\n <hr>\r\n <h3>TIPO:</h3>\r\n <section class=\"row g-0\">\r\n <div class=\"card-chart col-12 col-sm-6 col-md-6 col-lg-4 col-xl-3\" *ngFor=\"let opt of options\">\r\n <b>{{opt.title}}</b>\r\n <img [src]=\"'assets/dashboard/images/' + opt.id +'.png'\" (click)=\"setCurrentOption(opt.id)\">\r\n </div>\r\n </section>\r\n <div class=\"d-flex justify-content-end mb-2\">\r\n <button class=\"btn btn-success\" type=\"button\" (click)=\"onSaveData()\" title=\"Salvar\">Salvar</button>\r\n </div>\r\n</body>", styles: [".card-chart{display:flex;flex-direction:column;border:1px solid gray;border-radius:5px;padding:5px;aspect-ratio:1/1;overflow:hidden}.card-chart img{object-fit:cover;width:100%;margin:auto}\n"] }]
|
|
@@ -1177,7 +1174,7 @@ class DashboardComponent {
|
|
|
1177
1174
|
}
|
|
1178
1175
|
}
|
|
1179
1176
|
DashboardComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: DashboardComponent, deps: [{ token: i1$2.BsModalService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
1180
|
-
DashboardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: DashboardComponent, selector: "lib-dashboard", inputs: { isDark: "isDark", isResponsive: "isResponsive", canEdit: "canEdit", cols: "cols", options: "options", cards: "cards", groupType: "groupType", modalData: "modalData", data: "data", debug: "debug" }, host: { listeners: { "window:resize": "onresize()" } }, viewQueries: [{ propertyName: "modalChart", first: true, predicate: ["modalChart"], descendants: true }, { propertyName: "modal", first: true, predicate: ["modal"], descendants: true }, { propertyName: "modalView", first: true, predicate: ["modalView"], descendants: true }, { propertyName: "modalCode", first: true, predicate: ["modalCode"], descendants: true }, { propertyName: "dropsQuery", predicate: CdkDropList, descendants: true }], ngImport: i0, template: "<main class=\"dashboard\" [class.responsive]=\"isResponsive\" [class.dark-class]=\"isDark\">\r\n <mat-grid-list [cols]=\"cols\" rowHeight=\"300px\" gutterSize=\"10px\">\r\n <mat-grid-tile\r\n *ngFor=\"let card of cards; let i = index\"\r\n [colspan]=\"card.cols > cols? cols : card.cols\"\r\n [rowspan]=\"card.rows\"\r\n [class.dark-class]=\"isDark\"\r\n class=\"card\"\r\n >\r\n <div cdkDropList [cdkDropListConnectedTo]=\"drops\" [cdkDropListData]=\"i\">\r\n <div\r\n [id]=\"'card_' + i\"\r\n cdkDrag\r\n (cdkDragEntered)=\"entered($event)\"\r\n [cdkDragData]=\"i\"\r\n class=\"card-body\"\r\n [cdkDragDisabled]=\"!canEdit\"\r\n [class.dark-class]=\"isDark\"\r\n [class.has-color]=\"card.backgroundColor\"\r\n [style.background-color]=\"card.backgroundColor\"\r\n [style.color]=\"card.fontColor\"\r\n >\r\n <nav class=\"nav-hover\">\r\n <button *ngIf=\"!canEdit\" class=\"btn font-icon\" title=\"Ampliar gr\u00E1fico\" (click)=\"openChart(card, i)\">search</button>\r\n <button *ngIf=\"!canEdit\" class=\"btn font-icon\" title=\"Baixar imagem\" (click)=\"downloadImage(i)\">download</button>\r\n </nav>\r\n <nav class=\"card-nav\" *ngIf=\"canEdit\">\r\n <div class=\"card-handle font-icon\" title=\"Mover\" cdkDragHandle>\r\n drag_pan\r\n </div>\r\n <button class=\"btn card-options font-icon\" title=\"Modificar tamanho\" mat-button [matMenuTriggerFor]=\"menu\">\r\n resize\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <ng-container *ngFor=\"let opt of orderOptions\">\r\n <button mat-menu-item (click)=\"card.cols = opt.cols; card.rows = opt.rows\" >{{opt.title}}</button>\r\n </ng-container>\r\n </mat-menu>\r\n <button class=\"btn font-icon\" title=\"Editar Tipo do Gr\u00E1fico\" (click)=\"openModalChart(card)\">{{'landscape_2_edit'}}</button>\r\n <button class=\"btn font-icon\" title=\"Editar fonte de dados\" (click)=\"openModalData(card)\">edit_note</button>\r\n <button class=\"btn font-icon\" *ngIf=\"debug\" title=\"Exibir c\u00F3digo de configura\u00E7\u00E3o\" (click)=\"openModalCode(card)\">code_blocks</button>\r\n </nav>\r\n <div class=\"custom-placeholder\" *cdkDragPlaceholder></div>\r\n <lib-card [data]=\"card\" [ngClass]=\"{'canEdit': canEdit}\" [isDark]=\"isDark\"></lib-card>\r\n </div>\r\n </div>\r\n </mat-grid-tile>\r\n <mat-grid-tile class=\"card\" [colspan]=\"1\" [rowspan]=\"1\" [class.dark-class]=\"isDark\" *ngIf=\"canEdit\">\r\n <lib-card [data]=\"emptyCard\" [ngClass]=\"{'canEdit': canEdit, cardEmpty:true}\" [isDark]=\"isDark\"\r\n (click)=\"addNewCard()\"\r\n ></lib-card>\r\n </mat-grid-tile>\r\n </mat-grid-list>\r\n</main>\r\n<ng-template #modal>\r\n <lib-modal-edit (closeModal)=\"closeModalData()\" (saveData)=\"saveData($event)\" [data]=\"modalData\" [groupType]=\"groupType\"></lib-modal-edit>\r\n</ng-template>\r\n<ng-template #modalView>\r\n <header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left mb-0\">{{currentCard.title}}</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"closeModalView()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n </header>\r\n <body id=\"modalViewBody\" class=\"modal-body py-2 overflow-auto\">\r\n <lib-card [data]=\"currentCard\" [ngClass]=\"{'canEdit': canEdit}\" [isDark]=\"isDark\"></lib-card>\r\n </body>\r\n</ng-template>\r\n<ng-template #modalCode>\r\n <header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left mb-0\">{{currentCard.title}}</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"closeModalCode()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n </header>\r\n <body id=\"modalCodeBody\" class=\"modal-body py-2 overflow-auto\">\r\n <pre class=\"code-area\">{{ currentCard | json }}</pre>\r\n <button class=\"font-icon code-copy\" title=\"Copiar json\" (click)=\"copyCode()\">content_copy</button>\r\n <span *ngIf=\"copyComplete\" class=\"copy-message\">Copiado!</span>\r\n </body>\r\n</ng-template>\r\n<ng-template #modalChart>\r\n <lib-modal-edit-chart (closeModal)=\"closeModalChart()\" [currentOption]=\"currentOption\" (saveData)=\"saveChartData($event)\"></lib-modal-edit-chart>\r\n</ng-template>", styles: [".dashboard{padding:5px;background-color:#e4e4e4}.copy-message{position:absolute;bottom:10px;left:45%;right:auto;color:#fff;padding:5px 25px;border-radius:20px;background:#1b1b1b}.code-area{background:black;color:#fff;padding:10px;line-height:1;border-radius:10px}.code-copy{top:15px;position:absolute;color:#fff;background:#3f3f3f;right:25px;display:hidden;display:none;border-radius:25px;padding:8px;border:none}.modal-body:hover .code-copy{display:inline}.card{box-sizing:border-box;color:#000000de;background:#fff;border-radius:4px;z-index:1;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f;transition:box-shadow .2s cubic-bezier(0,0,.2,1)}.card-body{border:solid 1px #ccc;height:100%}.card-body:active{border:solid 1px #ccc;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.card-body .card-nav{width:100%;height:30px;display:flex;border-bottom:1px solid gray}.card-body .card-nav .card-handle{cursor:move;width:24px;height:24px}.card-body .card-nav .card-options{border:none;display:flex;padding:0}.card-body .card-nav button,.card-body .card-nav .card-handle{font-size:18pt;display:flex;color:#898989;padding:0;margin-left:5px}.cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.more-button{float:right;font-size:2em}.cdk-drop-list{height:100%;width:100%}.cdk-drag-animating{transition:unset}.cdk-drag-placeholder{display:none}.mat-grid-tile{overflow:visible!important}.mat-grid-tile-content{height:100%!important;display:flex!important}.nav-hover{display:flex;right:10px;position:absolute;top:10px;display:none}::ng-deep .mat-grid-tile:hover .nav-hover{display:inherit}::ng-deep .dark-class:not(.has-color){background-color:#000!important;color:#fff!important}::ng-deep .dark-class.card-body:not(.has-color){background-color:#1a1a1a!important;color:#fff!important}::ng-deep .mat-grid-tile-content:has(lib-card.cardEmpty .empty-card:active){background-color:#c6c6c6}::ng-deep lib-card.cardEmpty{width:100%}::ng-deep lib-card.cardEmpty .empty-card{width:100%;height:100%;text-align:center;padding:auto;font-size:28pt}::ng-deep lib-card.cardEmpty .empty-card:active{border:none}::ng-deep lib-card.canEdit{display:block;height:calc(100% - 30px)}\n"], dependencies: [{ kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3$1.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i3$1.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i3$1.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "directive", type: i3$1.CdkDragPlaceholder, selector: "ng-template[cdkDragPlaceholder]", inputs: ["data"] }, { kind: "component", type: i4$1.MatGridList, selector: "mat-grid-list", inputs: ["cols", "gutterSize", "rowHeight"], exportAs: ["matGridList"] }, { kind: "component", type: i4$1.MatGridTile, selector: "mat-grid-tile", inputs: ["rowspan", "colspan"], exportAs: ["matGridTile"] }, { kind: "component", type: i5.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "component", type: i5.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i5.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "component", type: CardComponent, selector: "lib-card", inputs: ["data", "isDark"] }, { kind: "component", type: ModalEditComponent, selector: "lib-modal-edit", inputs: ["data", "groupType"], outputs: ["closeModal", "saveData"] }, { kind: "component", type: ModalEditChartComponent, selector: "lib-modal-edit-chart", inputs: ["currentOption"], outputs: ["closeModal", "saveData"] }, { kind: "pipe", type: i2.JsonPipe, name: "json" }] });
|
|
1177
|
+
DashboardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: DashboardComponent, selector: "lib-dashboard", inputs: { isDark: "isDark", isResponsive: "isResponsive", canEdit: "canEdit", cols: "cols", options: "options", cards: "cards", groupType: "groupType", modalData: "modalData", data: "data", debug: "debug" }, host: { listeners: { "window:resize": "onresize()" } }, viewQueries: [{ propertyName: "modalChart", first: true, predicate: ["modalChart"], descendants: true }, { propertyName: "modal", first: true, predicate: ["modal"], descendants: true }, { propertyName: "modalView", first: true, predicate: ["modalView"], descendants: true }, { propertyName: "modalCode", first: true, predicate: ["modalCode"], descendants: true }, { propertyName: "dropsQuery", predicate: CdkDropList, descendants: true }], ngImport: i0, template: "<main class=\"dashboard\" [class.responsive]=\"isResponsive\" [class.dark-class]=\"isDark\">\r\n <mat-grid-list [cols]=\"cols\" rowHeight=\"300px\" gutterSize=\"10px\">\r\n <mat-grid-tile\r\n *ngFor=\"let card of cards; let i = index\"\r\n [colspan]=\"card.cols > cols? cols : card.cols\"\r\n [rowspan]=\"card.rows\"\r\n [class.dark-class]=\"isDark\"\r\n class=\"card\"\r\n >\r\n <div cdkDropList [cdkDropListConnectedTo]=\"drops\" [cdkDropListData]=\"i\">\r\n <div\r\n [id]=\"'card_' + i\"\r\n cdkDrag\r\n (cdkDragEntered)=\"entered($event)\"\r\n [cdkDragData]=\"i\"\r\n class=\"card-body\"\r\n [cdkDragDisabled]=\"!canEdit\"\r\n [class.dark-class]=\"isDark\"\r\n [class.has-color]=\"card.backgroundColor\"\r\n [style.background-color]=\"card.backgroundColor\"\r\n [style.color]=\"card.fontColor\"\r\n >\r\n <nav class=\"nav-hover\">\r\n <button *ngIf=\"!canEdit\" class=\"btn font-icon\" title=\"Ampliar gr\u00E1fico\" (click)=\"openChart(card, i)\">search</button>\r\n <button *ngIf=\"!canEdit\" class=\"btn font-icon\" title=\"Baixar imagem\" (click)=\"downloadImage(i)\">download</button>\r\n </nav>\r\n <nav class=\"card-nav\" *ngIf=\"canEdit\">\r\n <div class=\"card-handle font-icon\" title=\"Mover\" cdkDragHandle>\r\n drag_pan\r\n </div>\r\n <button class=\"btn card-options font-icon\" title=\"Modificar tamanho\" mat-button [matMenuTriggerFor]=\"menu\">\r\n resize\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <ng-container *ngFor=\"let opt of orderOptions\">\r\n <button mat-menu-item (click)=\"card.cols = opt.cols; card.rows = opt.rows\" >{{opt.title}}</button>\r\n </ng-container>\r\n </mat-menu>\r\n <button class=\"btn font-icon\" title=\"Editar Tipo do Gr\u00E1fico\" (click)=\"openModalChart(card)\">{{'landscape_2_edit'}}</button>\r\n <button class=\"btn font-icon\" title=\"Editar fonte de dados\" (click)=\"openModalData(card)\">edit_note</button>\r\n <button class=\"btn font-icon\" *ngIf=\"debug\" title=\"Exibir c\u00F3digo de configura\u00E7\u00E3o\" (click)=\"openModalCode(card)\">code_blocks</button>\r\n </nav>\r\n <div class=\"custom-placeholder\" *cdkDragPlaceholder></div>\r\n <lib-card [data]=\"card\" [ngClass]=\"{'canEdit': canEdit}\" [isDark]=\"isDark\"></lib-card>\r\n </div>\r\n </div>\r\n </mat-grid-tile>\r\n <mat-grid-tile class=\"card\" [colspan]=\"1\" [rowspan]=\"1\" [class.dark-class]=\"isDark\" *ngIf=\"canEdit\">\r\n <lib-card [data]=\"emptyCard\" [ngClass]=\"{'canEdit': canEdit, cardEmpty:true}\" [isDark]=\"isDark\"\r\n (click)=\"addNewCard()\"\r\n ></lib-card>\r\n </mat-grid-tile>\r\n </mat-grid-list>\r\n</main>\r\n<ng-template #modal>\r\n <lib-modal-edit (closeModal)=\"closeModalData()\" (saveData)=\"saveData($event)\" [data]=\"modalData\" [groupType]=\"groupType\"></lib-modal-edit>\r\n</ng-template>\r\n<ng-template #modalView>\r\n <header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left mb-0\">{{currentCard.title}}</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"closeModalView()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n </header>\r\n <body id=\"modalViewBody\" class=\"modal-body py-2 overflow-auto\">\r\n <lib-card [data]=\"currentCard\" [ngClass]=\"{'canEdit': canEdit}\" [isDark]=\"isDark\"></lib-card>\r\n </body>\r\n</ng-template>\r\n<ng-template #modalCode>\r\n <header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left mb-0\">{{currentCard.title}}</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"closeModalCode()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n </header>\r\n <body id=\"modalCodeBody\" class=\"modal-body py-2 overflow-auto\">\r\n <pre class=\"code-area\">{{ currentCard | json }}</pre>\r\n <button class=\"font-icon code-copy\" title=\"Copiar json\" (click)=\"copyCode()\">content_copy</button>\r\n <span *ngIf=\"copyComplete\" class=\"copy-message\">Copiado!</span>\r\n </body>\r\n</ng-template>\r\n<ng-template #modalChart>\r\n <lib-modal-edit-chart (closeModal)=\"closeModalChart()\" [currentOption]=\"currentOption\" (saveData)=\"saveChartData($event)\"></lib-modal-edit-chart>\r\n</ng-template>", styles: [".dashboard{padding:5px;background-color:#e4e4e4}.copy-message{position:absolute;bottom:10px;left:45%;right:auto;color:#fff;padding:5px 25px;border-radius:20px;background:#1b1b1b}.code-area{background:black;color:#fff;padding:10px;line-height:1;border-radius:10px}.code-copy{top:15px;position:absolute;color:#fff;background:#3f3f3f;right:25px;display:hidden;display:none;border-radius:25px;padding:8px;border:none}.modal-body:hover .code-copy{display:inline}.card{box-sizing:border-box;color:#000000de;background:#fff;border-radius:4px;z-index:1;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f;transition:box-shadow .2s cubic-bezier(0,0,.2,1)}.card-body{border:solid 1px #ccc;height:100%}.card-body:active{border:solid 1px #ccc;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.card-body .card-nav{width:100%;height:30px;display:flex;border-bottom:1px solid gray}.card-body .card-nav .card-handle{cursor:move;width:24px;height:24px}.card-body .card-nav .card-options{border:none;display:flex;padding:0}.card-body .card-nav button,.card-body .card-nav .card-handle{font-size:18pt;display:flex;color:#898989;padding:0;margin-left:5px}.cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.more-button{float:right;font-size:2em}.cdk-drop-list{height:100%;width:100%}.cdk-drag-animating{transition:unset}.cdk-drag-placeholder{display:none}.mat-grid-tile{overflow:visible!important}.mat-grid-tile-content{height:100%!important;display:flex!important}.nav-hover{display:flex;right:10px;position:absolute;top:10px;display:none}::ng-deep .mat-grid-tile:hover .nav-hover{display:inherit}::ng-deep .dark-class:not(.has-color){background-color:#000!important;color:#fff!important}::ng-deep .dark-class.card-body:not(.has-color){background-color:#1a1a1a!important;color:#fff!important}::ng-deep .mat-grid-tile-content:has(lib-card.cardEmpty .empty-card:active){background-color:#c6c6c6}::ng-deep lib-card.cardEmpty{width:100%}::ng-deep lib-card.cardEmpty .empty-card{width:100%;height:100%;text-align:center;padding:auto;font-size:28pt}::ng-deep lib-card.cardEmpty .empty-card:active{border:none}::ng-deep lib-card.canEdit{display:block;height:calc(100% - 30px)}\n"], dependencies: [{ kind: "directive", type: i2$1.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i2$1.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i2$1.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "directive", type: i2$1.CdkDragPlaceholder, selector: "ng-template[cdkDragPlaceholder]", inputs: ["data"] }, { kind: "component", type: i3.MatGridList, selector: "mat-grid-list", inputs: ["cols", "gutterSize", "rowHeight"], exportAs: ["matGridList"] }, { kind: "component", type: i3.MatGridTile, selector: "mat-grid-tile", inputs: ["rowspan", "colspan"], exportAs: ["matGridTile"] }, { kind: "component", type: i4$1.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "component", type: i4$1.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i4$1.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "directive", type: i5.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i5.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: CardComponent, selector: "lib-card", inputs: ["data", "isDark"] }, { kind: "component", type: ModalEditComponent, selector: "lib-modal-edit", inputs: ["data", "groupType"], outputs: ["closeModal", "saveData"] }, { kind: "component", type: ModalEditChartComponent, selector: "lib-modal-edit-chart", inputs: ["currentOption"], outputs: ["closeModal", "saveData"] }, { kind: "pipe", type: i5.JsonPipe, name: "json" }] });
|
|
1181
1178
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: DashboardComponent, decorators: [{
|
|
1182
1179
|
type: Component,
|
|
1183
1180
|
args: [{ selector: 'lib-dashboard', template: "<main class=\"dashboard\" [class.responsive]=\"isResponsive\" [class.dark-class]=\"isDark\">\r\n <mat-grid-list [cols]=\"cols\" rowHeight=\"300px\" gutterSize=\"10px\">\r\n <mat-grid-tile\r\n *ngFor=\"let card of cards; let i = index\"\r\n [colspan]=\"card.cols > cols? cols : card.cols\"\r\n [rowspan]=\"card.rows\"\r\n [class.dark-class]=\"isDark\"\r\n class=\"card\"\r\n >\r\n <div cdkDropList [cdkDropListConnectedTo]=\"drops\" [cdkDropListData]=\"i\">\r\n <div\r\n [id]=\"'card_' + i\"\r\n cdkDrag\r\n (cdkDragEntered)=\"entered($event)\"\r\n [cdkDragData]=\"i\"\r\n class=\"card-body\"\r\n [cdkDragDisabled]=\"!canEdit\"\r\n [class.dark-class]=\"isDark\"\r\n [class.has-color]=\"card.backgroundColor\"\r\n [style.background-color]=\"card.backgroundColor\"\r\n [style.color]=\"card.fontColor\"\r\n >\r\n <nav class=\"nav-hover\">\r\n <button *ngIf=\"!canEdit\" class=\"btn font-icon\" title=\"Ampliar gr\u00E1fico\" (click)=\"openChart(card, i)\">search</button>\r\n <button *ngIf=\"!canEdit\" class=\"btn font-icon\" title=\"Baixar imagem\" (click)=\"downloadImage(i)\">download</button>\r\n </nav>\r\n <nav class=\"card-nav\" *ngIf=\"canEdit\">\r\n <div class=\"card-handle font-icon\" title=\"Mover\" cdkDragHandle>\r\n drag_pan\r\n </div>\r\n <button class=\"btn card-options font-icon\" title=\"Modificar tamanho\" mat-button [matMenuTriggerFor]=\"menu\">\r\n resize\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <ng-container *ngFor=\"let opt of orderOptions\">\r\n <button mat-menu-item (click)=\"card.cols = opt.cols; card.rows = opt.rows\" >{{opt.title}}</button>\r\n </ng-container>\r\n </mat-menu>\r\n <button class=\"btn font-icon\" title=\"Editar Tipo do Gr\u00E1fico\" (click)=\"openModalChart(card)\">{{'landscape_2_edit'}}</button>\r\n <button class=\"btn font-icon\" title=\"Editar fonte de dados\" (click)=\"openModalData(card)\">edit_note</button>\r\n <button class=\"btn font-icon\" *ngIf=\"debug\" title=\"Exibir c\u00F3digo de configura\u00E7\u00E3o\" (click)=\"openModalCode(card)\">code_blocks</button>\r\n </nav>\r\n <div class=\"custom-placeholder\" *cdkDragPlaceholder></div>\r\n <lib-card [data]=\"card\" [ngClass]=\"{'canEdit': canEdit}\" [isDark]=\"isDark\"></lib-card>\r\n </div>\r\n </div>\r\n </mat-grid-tile>\r\n <mat-grid-tile class=\"card\" [colspan]=\"1\" [rowspan]=\"1\" [class.dark-class]=\"isDark\" *ngIf=\"canEdit\">\r\n <lib-card [data]=\"emptyCard\" [ngClass]=\"{'canEdit': canEdit, cardEmpty:true}\" [isDark]=\"isDark\"\r\n (click)=\"addNewCard()\"\r\n ></lib-card>\r\n </mat-grid-tile>\r\n </mat-grid-list>\r\n</main>\r\n<ng-template #modal>\r\n <lib-modal-edit (closeModal)=\"closeModalData()\" (saveData)=\"saveData($event)\" [data]=\"modalData\" [groupType]=\"groupType\"></lib-modal-edit>\r\n</ng-template>\r\n<ng-template #modalView>\r\n <header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left mb-0\">{{currentCard.title}}</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"closeModalView()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n </header>\r\n <body id=\"modalViewBody\" class=\"modal-body py-2 overflow-auto\">\r\n <lib-card [data]=\"currentCard\" [ngClass]=\"{'canEdit': canEdit}\" [isDark]=\"isDark\"></lib-card>\r\n </body>\r\n</ng-template>\r\n<ng-template #modalCode>\r\n <header class=\"modal-header\">\r\n <h4 class=\"modal-title pull-left mb-0\">{{currentCard.title}}</h4>\r\n <button type=\"button\" class=\"btn-close close pull-right\" aria-label=\"Close\" (click)=\"closeModalCode()\">\r\n <span aria-hidden=\"true\" class=\"visually-hidden\">×</span>\r\n </button>\r\n </header>\r\n <body id=\"modalCodeBody\" class=\"modal-body py-2 overflow-auto\">\r\n <pre class=\"code-area\">{{ currentCard | json }}</pre>\r\n <button class=\"font-icon code-copy\" title=\"Copiar json\" (click)=\"copyCode()\">content_copy</button>\r\n <span *ngIf=\"copyComplete\" class=\"copy-message\">Copiado!</span>\r\n </body>\r\n</ng-template>\r\n<ng-template #modalChart>\r\n <lib-modal-edit-chart (closeModal)=\"closeModalChart()\" [currentOption]=\"currentOption\" (saveData)=\"saveChartData($event)\"></lib-modal-edit-chart>\r\n</ng-template>", styles: [".dashboard{padding:5px;background-color:#e4e4e4}.copy-message{position:absolute;bottom:10px;left:45%;right:auto;color:#fff;padding:5px 25px;border-radius:20px;background:#1b1b1b}.code-area{background:black;color:#fff;padding:10px;line-height:1;border-radius:10px}.code-copy{top:15px;position:absolute;color:#fff;background:#3f3f3f;right:25px;display:hidden;display:none;border-radius:25px;padding:8px;border:none}.modal-body:hover .code-copy{display:inline}.card{box-sizing:border-box;color:#000000de;background:#fff;border-radius:4px;z-index:1;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f;transition:box-shadow .2s cubic-bezier(0,0,.2,1)}.card-body{border:solid 1px #ccc;height:100%}.card-body:active{border:solid 1px #ccc;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.card-body .card-nav{width:100%;height:30px;display:flex;border-bottom:1px solid gray}.card-body .card-nav .card-handle{cursor:move;width:24px;height:24px}.card-body .card-nav .card-options{border:none;display:flex;padding:0}.card-body .card-nav button,.card-body .card-nav .card-handle{font-size:18pt;display:flex;color:#898989;padding:0;margin-left:5px}.cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.more-button{float:right;font-size:2em}.cdk-drop-list{height:100%;width:100%}.cdk-drag-animating{transition:unset}.cdk-drag-placeholder{display:none}.mat-grid-tile{overflow:visible!important}.mat-grid-tile-content{height:100%!important;display:flex!important}.nav-hover{display:flex;right:10px;position:absolute;top:10px;display:none}::ng-deep .mat-grid-tile:hover .nav-hover{display:inherit}::ng-deep .dark-class:not(.has-color){background-color:#000!important;color:#fff!important}::ng-deep .dark-class.card-body:not(.has-color){background-color:#1a1a1a!important;color:#fff!important}::ng-deep .mat-grid-tile-content:has(lib-card.cardEmpty .empty-card:active){background-color:#c6c6c6}::ng-deep lib-card.cardEmpty{width:100%}::ng-deep lib-card.cardEmpty .empty-card{width:100%;height:100%;text-align:center;padding:auto;font-size:28pt}::ng-deep lib-card.cardEmpty .empty-card:active{border:none}::ng-deep lib-card.canEdit{display:block;height:calc(100% - 30px)}\n"] }]
|
|
@@ -1305,26 +1302,22 @@ PrimordashModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", versio
|
|
|
1305
1302
|
TableComponent,
|
|
1306
1303
|
ModalEditComponent,
|
|
1307
1304
|
ModalEditChartComponent,
|
|
1308
|
-
PrimordashComponent], imports: [
|
|
1309
|
-
DragDropModule,
|
|
1310
|
-
BrowserAnimationsModule,
|
|
1305
|
+
PrimordashComponent], imports: [DragDropModule,
|
|
1311
1306
|
MatGridListModule,
|
|
1312
1307
|
MatMenuModule,
|
|
1313
1308
|
NgChartsModule,
|
|
1314
1309
|
ReactiveFormsModule,
|
|
1315
1310
|
FormsModule,
|
|
1316
|
-
CommonModule,
|
|
1311
|
+
CommonModule,
|
|
1312
|
+
NgSelectModule], exports: [DashboardComponent,
|
|
1317
1313
|
PrimordashComponent] });
|
|
1318
|
-
PrimordashModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PrimordashModule, imports: [
|
|
1319
|
-
DragDropModule,
|
|
1320
|
-
BrowserAnimationsModule,
|
|
1314
|
+
PrimordashModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PrimordashModule, imports: [DragDropModule,
|
|
1321
1315
|
MatGridListModule,
|
|
1322
1316
|
MatMenuModule,
|
|
1323
1317
|
NgChartsModule,
|
|
1324
1318
|
ReactiveFormsModule,
|
|
1325
1319
|
FormsModule,
|
|
1326
1320
|
CommonModule,
|
|
1327
|
-
ModalModule.forRoot(),
|
|
1328
1321
|
NgSelectModule] });
|
|
1329
1322
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PrimordashModule, decorators: [{
|
|
1330
1323
|
type: NgModule,
|
|
@@ -1342,16 +1335,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
1342
1335
|
PrimordashComponent
|
|
1343
1336
|
],
|
|
1344
1337
|
imports: [
|
|
1345
|
-
BrowserModule,
|
|
1346
1338
|
DragDropModule,
|
|
1347
|
-
BrowserAnimationsModule,
|
|
1348
1339
|
MatGridListModule,
|
|
1349
1340
|
MatMenuModule,
|
|
1350
1341
|
NgChartsModule,
|
|
1351
1342
|
ReactiveFormsModule,
|
|
1352
1343
|
FormsModule,
|
|
1353
1344
|
CommonModule,
|
|
1354
|
-
ModalModule.forRoot(),
|
|
1355
1345
|
NgSelectModule
|
|
1356
1346
|
],
|
|
1357
1347
|
exports: [
|