keevo-components 1.8.80 → 1.8.81
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/esm2022/lib/components/kv-modal/kv-modal.component.mjs +37 -6
- package/fesm2022/keevo-components.mjs +36 -5
- package/fesm2022/keevo-components.mjs.map +1 -1
- package/lib/components/kv-modal/kv-modal.component.d.ts +11 -3
- package/lib/components/kv-table/kv-table.component.d.ts +1 -1
- package/package.json +1 -1
|
@@ -4,8 +4,9 @@ import * as i1 from "primeng/dynamicdialog";
|
|
|
4
4
|
import * as i2 from "@angular/common";
|
|
5
5
|
import * as i3 from "../kv-buttons/kv-button-personalize/kv-button-personalize.component";
|
|
6
6
|
export class KvModalComponent {
|
|
7
|
-
constructor(dynamicDialogRef) {
|
|
7
|
+
constructor(dynamicDialogRef, dynamicDialogConfig) {
|
|
8
8
|
this.dynamicDialogRef = dynamicDialogRef;
|
|
9
|
+
this.dynamicDialogConfig = dynamicDialogConfig;
|
|
9
10
|
/**
|
|
10
11
|
* Ações do Dialog
|
|
11
12
|
*/
|
|
@@ -14,12 +15,38 @@ export class KvModalComponent {
|
|
|
14
15
|
this.justify_content = 'justify-content-start';
|
|
15
16
|
}
|
|
16
17
|
ngOnInit() {
|
|
18
|
+
this.addSubTitle();
|
|
17
19
|
this.setMarginBottom();
|
|
18
20
|
this.defPositionButtons();
|
|
19
21
|
}
|
|
20
22
|
onWindowResize() {
|
|
21
23
|
this.setMarginBottom();
|
|
22
24
|
}
|
|
25
|
+
/**
|
|
26
|
+
* Adiciona sub-título à tela
|
|
27
|
+
*/
|
|
28
|
+
addSubTitle() {
|
|
29
|
+
if (this.subtitle) {
|
|
30
|
+
const headerElement = document.querySelector('.p-dialog .p-dialog-header');
|
|
31
|
+
if (headerElement) {
|
|
32
|
+
const subtitleElement = document.createElement('span');
|
|
33
|
+
subtitleElement.textContent = this.subtitle;
|
|
34
|
+
subtitleElement.style.fontSize = '0.75rem';
|
|
35
|
+
subtitleElement.style.width = '100%';
|
|
36
|
+
subtitleElement.style.marginLeft = '2px';
|
|
37
|
+
headerElement.appendChild(subtitleElement);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
if (this.subHeader) {
|
|
41
|
+
const headerElement = document.querySelector('.p-dialog .p-dialog-header');
|
|
42
|
+
const subHeader = this.subHeader.nativeElement;
|
|
43
|
+
if (headerElement && this.subHeader) {
|
|
44
|
+
subHeader.style.width = '100%';
|
|
45
|
+
subHeader.style.marginLeft = '2px';
|
|
46
|
+
headerElement.appendChild(this.subHeader.nativeElement);
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}
|
|
23
50
|
defPositionButtons() {
|
|
24
51
|
if (this.actionsPosition === 'right') {
|
|
25
52
|
this.justify_content = 'justify-content-end';
|
|
@@ -50,13 +77,17 @@ export class KvModalComponent {
|
|
|
50
77
|
this.dynamicDialogRef.close();
|
|
51
78
|
}
|
|
52
79
|
}
|
|
53
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.8", ngImport: i0, type: KvModalComponent, deps: [{ token: i1.DynamicDialogRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
54
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.8", type: KvModalComponent, selector: "kv-modal", inputs: { actions: "actions", actionsPosition: "actionsPosition" }, host: { listeners: { "window:resize": "onWindowResize($event)" } }, ngImport: i0, template: "<!-- RENDERIZA\u00C7\u00C3O DO MODAL -->\r\n<div class=\"col-12 mb-4\" id=\"content-modal\">\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n<!-- RENDERIZA\u00C7\u00C3O DOS BOT\u00D5ES -->\r\n\r\n<div class=\"bg-white flex flex-row flex-wrap gap-2 p-2 modal-barra-acoes {{justify_content}}\" *ngIf=\"actions\" id=\"actions-field\">\r\n <kv-button-personalize\r\n *ngFor=\" let action of actions\"\r\n [ngClass]=\"action.visible==false?'hidden':''\"\r\n color=\"{{action.color}}\"\r\n colorHover=\"{{action.colorHover}}\"\r\n textColor=\"{{action.textColor}}\"\r\n icon=\"{{action.icon}}\"\r\n label=\"{{action.label}}\"\r\n [disabled]=\"action.disabled || false\"\r\n (onClick)=\"clickExecute(action)\"\r\n />\r\n</div>", styles: ["::ng-deep .p-dialog .p-dialog-header{background:#002542!important;color:#fff
|
|
80
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.8", ngImport: i0, type: KvModalComponent, deps: [{ token: i1.DynamicDialogRef }, { token: i1.DynamicDialogConfig }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
81
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.8", type: KvModalComponent, selector: "kv-modal", inputs: { subHeader: "subHeader", subtitle: "subtitle", actions: "actions", actionsPosition: "actionsPosition" }, host: { listeners: { "window:resize": "onWindowResize($event)" } }, ngImport: i0, template: "<!-- RENDERIZA\u00C7\u00C3O DO MODAL -->\r\n<div class=\"col-12 mb-4\" id=\"content-modal\">\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n<!-- RENDERIZA\u00C7\u00C3O DOS BOT\u00D5ES -->\r\n\r\n<div class=\"bg-white flex flex-row flex-wrap gap-2 p-2 modal-barra-acoes {{justify_content}}\" *ngIf=\"actions\" id=\"actions-field\">\r\n <kv-button-personalize\r\n *ngFor=\" let action of actions\"\r\n [ngClass]=\"action.visible==false?'hidden':''\"\r\n color=\"{{action.color}}\"\r\n colorHover=\"{{action.colorHover}}\"\r\n textColor=\"{{action.textColor}}\"\r\n icon=\"{{action.icon}}\"\r\n label=\"{{action.label}}\"\r\n [disabled]=\"action.disabled || false\"\r\n (onClick)=\"clickExecute(action)\"\r\n />\r\n</div>", styles: ["::ng-deep .p-dialog .p-dialog-header{color:#fff!important;background:#002542!important;display:flex!important;flex-wrap:wrap}::ng-deep .p-dialog .p-dialog-content{padding-top:1rem}::ng-deep .p-dialog{min-width:320px}.sub-title{color:#ff0;position:relative;bottom:25px;z-index:1}::ng-deep .p-dialog-content{overflow-x:hidden}::ng-deep .p-dialog-content::-webkit-scrollbar{width:8px}::ng-deep .p-dialog-content::-webkit-scrollbar:hover{background-color:#dededebf}::ng-deep .p-dialog-content::-webkit-scrollbar-thumb{border-radius:4px;background-color:transparent}::ng-deep .p-dialog-content:hover::-webkit-scrollbar-thumb{border-left:2px solid white;background-color:#00000080}::ng-deep .p-dialog-content::-webkit-scrollbar-track{border-left:2px solid white;background-color:#dededebf}*{padding-bottom:0rem;padding-top:0rem}.barra-acoes{position:fixed;bottom:0;left:0;right:0;background-color:#fff;padding:10px;z-index:999}#page-form-container{padding-bottom:40px}@media screen and (max-width: 991px){#page-form-container{padding-bottom:100px}}.modal-barra-acoes{position:fixed;bottom:0;left:0;right:0;z-index:999;margin-right:1.5rem}\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: "component", type: i3.KvButtonPersonalizeComponent, selector: "kv-button-personalize", inputs: ["colorHover", "textColor"] }] }); }
|
|
55
82
|
}
|
|
56
83
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.8", ngImport: i0, type: KvModalComponent, decorators: [{
|
|
57
84
|
type: Component,
|
|
58
|
-
args: [{ selector: 'kv-modal', template: "<!-- RENDERIZA\u00C7\u00C3O DO MODAL -->\r\n<div class=\"col-12 mb-4\" id=\"content-modal\">\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n<!-- RENDERIZA\u00C7\u00C3O DOS BOT\u00D5ES -->\r\n\r\n<div class=\"bg-white flex flex-row flex-wrap gap-2 p-2 modal-barra-acoes {{justify_content}}\" *ngIf=\"actions\" id=\"actions-field\">\r\n <kv-button-personalize\r\n *ngFor=\" let action of actions\"\r\n [ngClass]=\"action.visible==false?'hidden':''\"\r\n color=\"{{action.color}}\"\r\n colorHover=\"{{action.colorHover}}\"\r\n textColor=\"{{action.textColor}}\"\r\n icon=\"{{action.icon}}\"\r\n label=\"{{action.label}}\"\r\n [disabled]=\"action.disabled || false\"\r\n (onClick)=\"clickExecute(action)\"\r\n />\r\n</div>", styles: ["::ng-deep .p-dialog .p-dialog-header{background:#002542!important;color:#fff
|
|
59
|
-
}], ctorParameters: () => [{ type: i1.DynamicDialogRef }], propDecorators: {
|
|
85
|
+
args: [{ selector: 'kv-modal', template: "<!-- RENDERIZA\u00C7\u00C3O DO MODAL -->\r\n<div class=\"col-12 mb-4\" id=\"content-modal\">\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n<!-- RENDERIZA\u00C7\u00C3O DOS BOT\u00D5ES -->\r\n\r\n<div class=\"bg-white flex flex-row flex-wrap gap-2 p-2 modal-barra-acoes {{justify_content}}\" *ngIf=\"actions\" id=\"actions-field\">\r\n <kv-button-personalize\r\n *ngFor=\" let action of actions\"\r\n [ngClass]=\"action.visible==false?'hidden':''\"\r\n color=\"{{action.color}}\"\r\n colorHover=\"{{action.colorHover}}\"\r\n textColor=\"{{action.textColor}}\"\r\n icon=\"{{action.icon}}\"\r\n label=\"{{action.label}}\"\r\n [disabled]=\"action.disabled || false\"\r\n (onClick)=\"clickExecute(action)\"\r\n />\r\n</div>", styles: ["::ng-deep .p-dialog .p-dialog-header{color:#fff!important;background:#002542!important;display:flex!important;flex-wrap:wrap}::ng-deep .p-dialog .p-dialog-content{padding-top:1rem}::ng-deep .p-dialog{min-width:320px}.sub-title{color:#ff0;position:relative;bottom:25px;z-index:1}::ng-deep .p-dialog-content{overflow-x:hidden}::ng-deep .p-dialog-content::-webkit-scrollbar{width:8px}::ng-deep .p-dialog-content::-webkit-scrollbar:hover{background-color:#dededebf}::ng-deep .p-dialog-content::-webkit-scrollbar-thumb{border-radius:4px;background-color:transparent}::ng-deep .p-dialog-content:hover::-webkit-scrollbar-thumb{border-left:2px solid white;background-color:#00000080}::ng-deep .p-dialog-content::-webkit-scrollbar-track{border-left:2px solid white;background-color:#dededebf}*{padding-bottom:0rem;padding-top:0rem}.barra-acoes{position:fixed;bottom:0;left:0;right:0;background-color:#fff;padding:10px;z-index:999}#page-form-container{padding-bottom:40px}@media screen and (max-width: 991px){#page-form-container{padding-bottom:100px}}.modal-barra-acoes{position:fixed;bottom:0;left:0;right:0;z-index:999;margin-right:1.5rem}\n"] }]
|
|
86
|
+
}], ctorParameters: () => [{ type: i1.DynamicDialogRef }, { type: i1.DynamicDialogConfig }], propDecorators: { subHeader: [{
|
|
87
|
+
type: Input
|
|
88
|
+
}], subtitle: [{
|
|
89
|
+
type: Input
|
|
90
|
+
}], onWindowResize: [{
|
|
60
91
|
type: HostListener,
|
|
61
92
|
args: ['window:resize', ['$event']]
|
|
62
93
|
}], actions: [{
|
|
@@ -64,4 +95,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.8", ngImpor
|
|
|
64
95
|
}], actionsPosition: [{
|
|
65
96
|
type: Input
|
|
66
97
|
}] } });
|
|
67
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
98
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoia3YtbW9kYWwuY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMva2Vldm8tY29tcG9uZW50cy9zcmMvbGliL2NvbXBvbmVudHMva3YtbW9kYWwva3YtbW9kYWwuY29tcG9uZW50LnRzIiwiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMva2Vldm8tY29tcG9uZW50cy9zcmMvbGliL2NvbXBvbmVudHMva3YtbW9kYWwva3YtbW9kYWwuY29tcG9uZW50Lmh0bWwiXSwibm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bjwvZGl2PlxyXG5cclxuPCEtLSBSRU5ERVJJWkHDh8ODTyBET1MgQk9Uw5VFUyAtLT5cclxuXHJcbjxkaXYgY2xhc3M9XCJiZy13aGl0ZSBmbGV4IGZsZXgtcm93IGZsZXgtd3JhcCBnYXAtMiBwLTIgbW9kYWwtYmFycmEtYWNvZXMge3tqdXN0aWZ5X2NvbnRlbnR9fVwiICpuZ0lmPVwiYWN0aW9uc1wiIGlkPVwiYWN0aW9ucy1maWVsZFwiPlxyXG4gICAgPGt2LWJ1dHRvbi1wZXJzb25hbGl6ZVxyXG4gICAgICAgICpuZ0Zvcj1cIiBsZXQgYWN0aW9uIG9mIGFjdGlvbnNcIlxyXG4gICAgICAgIFtuZ0NsYXNzXT1cImFjdGlvbi52aXNpYmxlPT1mYWxzZT8naGlkZGVuJzonJ1wiXHJcbiAgICAgICAgY29sb3I9XCJ7e2FjdGlvbi5jb2xvcn19XCJcclxuICAgICAgICBjb2xvckhvdmVyPVwie3thY3Rpb24uY29sb3JIb3Zlcn19XCJcclxuICAgICAgICB0ZXh0Q29sb3I9XCJ7e2FjdGlvbi50ZXh0Q29sb3J9fVwiXHJcbiAgICAgICAgaWNvbj1cInt7YWN0aW9uLmljb259fVwiXHJcbiAgICAgICAgbGFiZWw9XCJ7e2FjdGlvbi5sYWJlbH19XCJcclxuICAgICAgICBbZGlzYWJsZWRdPVwiYWN0aW9uLmRpc2FibGVkIHx8IGZhbHNlXCJcclxuICAgICAgICAob25DbGljayk9XCJjbGlja0V4ZWN1dGUoYWN0aW9uKVwiXHJcbiAgICAvPlxyXG48L2Rpdj4iXX0=
|
|
@@ -3592,8 +3592,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.8", ngImpor
|
|
|
3592
3592
|
}] });
|
|
3593
3593
|
|
|
3594
3594
|
class KvModalComponent {
|
|
3595
|
-
constructor(dynamicDialogRef) {
|
|
3595
|
+
constructor(dynamicDialogRef, dynamicDialogConfig) {
|
|
3596
3596
|
this.dynamicDialogRef = dynamicDialogRef;
|
|
3597
|
+
this.dynamicDialogConfig = dynamicDialogConfig;
|
|
3597
3598
|
/**
|
|
3598
3599
|
* Ações do Dialog
|
|
3599
3600
|
*/
|
|
@@ -3602,12 +3603,38 @@ class KvModalComponent {
|
|
|
3602
3603
|
this.justify_content = 'justify-content-start';
|
|
3603
3604
|
}
|
|
3604
3605
|
ngOnInit() {
|
|
3606
|
+
this.addSubTitle();
|
|
3605
3607
|
this.setMarginBottom();
|
|
3606
3608
|
this.defPositionButtons();
|
|
3607
3609
|
}
|
|
3608
3610
|
onWindowResize() {
|
|
3609
3611
|
this.setMarginBottom();
|
|
3610
3612
|
}
|
|
3613
|
+
/**
|
|
3614
|
+
* Adiciona sub-título à tela
|
|
3615
|
+
*/
|
|
3616
|
+
addSubTitle() {
|
|
3617
|
+
if (this.subtitle) {
|
|
3618
|
+
const headerElement = document.querySelector('.p-dialog .p-dialog-header');
|
|
3619
|
+
if (headerElement) {
|
|
3620
|
+
const subtitleElement = document.createElement('span');
|
|
3621
|
+
subtitleElement.textContent = this.subtitle;
|
|
3622
|
+
subtitleElement.style.fontSize = '0.75rem';
|
|
3623
|
+
subtitleElement.style.width = '100%';
|
|
3624
|
+
subtitleElement.style.marginLeft = '2px';
|
|
3625
|
+
headerElement.appendChild(subtitleElement);
|
|
3626
|
+
}
|
|
3627
|
+
}
|
|
3628
|
+
if (this.subHeader) {
|
|
3629
|
+
const headerElement = document.querySelector('.p-dialog .p-dialog-header');
|
|
3630
|
+
const subHeader = this.subHeader.nativeElement;
|
|
3631
|
+
if (headerElement && this.subHeader) {
|
|
3632
|
+
subHeader.style.width = '100%';
|
|
3633
|
+
subHeader.style.marginLeft = '2px';
|
|
3634
|
+
headerElement.appendChild(this.subHeader.nativeElement);
|
|
3635
|
+
}
|
|
3636
|
+
}
|
|
3637
|
+
}
|
|
3611
3638
|
defPositionButtons() {
|
|
3612
3639
|
if (this.actionsPosition === 'right') {
|
|
3613
3640
|
this.justify_content = 'justify-content-end';
|
|
@@ -3638,13 +3665,17 @@ class KvModalComponent {
|
|
|
3638
3665
|
this.dynamicDialogRef.close();
|
|
3639
3666
|
}
|
|
3640
3667
|
}
|
|
3641
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.8", ngImport: i0, type: KvModalComponent, deps: [{ token: i1$3.DynamicDialogRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
3642
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.8", type: KvModalComponent, selector: "kv-modal", inputs: { actions: "actions", actionsPosition: "actionsPosition" }, host: { listeners: { "window:resize": "onWindowResize($event)" } }, ngImport: i0, template: "<!-- RENDERIZA\u00C7\u00C3O DO MODAL -->\r\n<div class=\"col-12 mb-4\" id=\"content-modal\">\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n<!-- RENDERIZA\u00C7\u00C3O DOS BOT\u00D5ES -->\r\n\r\n<div class=\"bg-white flex flex-row flex-wrap gap-2 p-2 modal-barra-acoes {{justify_content}}\" *ngIf=\"actions\" id=\"actions-field\">\r\n <kv-button-personalize\r\n *ngFor=\" let action of actions\"\r\n [ngClass]=\"action.visible==false?'hidden':''\"\r\n color=\"{{action.color}}\"\r\n colorHover=\"{{action.colorHover}}\"\r\n textColor=\"{{action.textColor}}\"\r\n icon=\"{{action.icon}}\"\r\n label=\"{{action.label}}\"\r\n [disabled]=\"action.disabled || false\"\r\n (onClick)=\"clickExecute(action)\"\r\n />\r\n</div>", styles: ["::ng-deep .p-dialog .p-dialog-header{background:#002542!important;color:#fff
|
|
3668
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.8", ngImport: i0, type: KvModalComponent, deps: [{ token: i1$3.DynamicDialogRef }, { token: i1$3.DynamicDialogConfig }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
3669
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.8", type: KvModalComponent, selector: "kv-modal", inputs: { subHeader: "subHeader", subtitle: "subtitle", actions: "actions", actionsPosition: "actionsPosition" }, host: { listeners: { "window:resize": "onWindowResize($event)" } }, ngImport: i0, template: "<!-- RENDERIZA\u00C7\u00C3O DO MODAL -->\r\n<div class=\"col-12 mb-4\" id=\"content-modal\">\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n<!-- RENDERIZA\u00C7\u00C3O DOS BOT\u00D5ES -->\r\n\r\n<div class=\"bg-white flex flex-row flex-wrap gap-2 p-2 modal-barra-acoes {{justify_content}}\" *ngIf=\"actions\" id=\"actions-field\">\r\n <kv-button-personalize\r\n *ngFor=\" let action of actions\"\r\n [ngClass]=\"action.visible==false?'hidden':''\"\r\n color=\"{{action.color}}\"\r\n colorHover=\"{{action.colorHover}}\"\r\n textColor=\"{{action.textColor}}\"\r\n icon=\"{{action.icon}}\"\r\n label=\"{{action.label}}\"\r\n [disabled]=\"action.disabled || false\"\r\n (onClick)=\"clickExecute(action)\"\r\n />\r\n</div>", styles: ["::ng-deep .p-dialog .p-dialog-header{color:#fff!important;background:#002542!important;display:flex!important;flex-wrap:wrap}::ng-deep .p-dialog .p-dialog-content{padding-top:1rem}::ng-deep .p-dialog{min-width:320px}.sub-title{color:#ff0;position:relative;bottom:25px;z-index:1}::ng-deep .p-dialog-content{overflow-x:hidden}::ng-deep .p-dialog-content::-webkit-scrollbar{width:8px}::ng-deep .p-dialog-content::-webkit-scrollbar:hover{background-color:#dededebf}::ng-deep .p-dialog-content::-webkit-scrollbar-thumb{border-radius:4px;background-color:transparent}::ng-deep .p-dialog-content:hover::-webkit-scrollbar-thumb{border-left:2px solid white;background-color:#00000080}::ng-deep .p-dialog-content::-webkit-scrollbar-track{border-left:2px solid white;background-color:#dededebf}*{padding-bottom:0rem;padding-top:0rem}.barra-acoes{position:fixed;bottom:0;left:0;right:0;background-color:#fff;padding:10px;z-index:999}#page-form-container{padding-bottom:40px}@media screen and (max-width: 991px){#page-form-container{padding-bottom:100px}}.modal-barra-acoes{position:fixed;bottom:0;left:0;right:0;z-index:999;margin-right:1.5rem}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: KvButtonPersonalizeComponent, selector: "kv-button-personalize", inputs: ["colorHover", "textColor"] }] }); }
|
|
3643
3670
|
}
|
|
3644
3671
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.8", ngImport: i0, type: KvModalComponent, decorators: [{
|
|
3645
3672
|
type: Component,
|
|
3646
|
-
args: [{ selector: 'kv-modal', template: "<!-- RENDERIZA\u00C7\u00C3O DO MODAL -->\r\n<div class=\"col-12 mb-4\" id=\"content-modal\">\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n<!-- RENDERIZA\u00C7\u00C3O DOS BOT\u00D5ES -->\r\n\r\n<div class=\"bg-white flex flex-row flex-wrap gap-2 p-2 modal-barra-acoes {{justify_content}}\" *ngIf=\"actions\" id=\"actions-field\">\r\n <kv-button-personalize\r\n *ngFor=\" let action of actions\"\r\n [ngClass]=\"action.visible==false?'hidden':''\"\r\n color=\"{{action.color}}\"\r\n colorHover=\"{{action.colorHover}}\"\r\n textColor=\"{{action.textColor}}\"\r\n icon=\"{{action.icon}}\"\r\n label=\"{{action.label}}\"\r\n [disabled]=\"action.disabled || false\"\r\n (onClick)=\"clickExecute(action)\"\r\n />\r\n</div>", styles: ["::ng-deep .p-dialog .p-dialog-header{background:#002542!important;color:#fff
|
|
3647
|
-
}], ctorParameters: () => [{ type: i1$3.DynamicDialogRef }], propDecorators: {
|
|
3673
|
+
args: [{ selector: 'kv-modal', template: "<!-- RENDERIZA\u00C7\u00C3O DO MODAL -->\r\n<div class=\"col-12 mb-4\" id=\"content-modal\">\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n<!-- RENDERIZA\u00C7\u00C3O DOS BOT\u00D5ES -->\r\n\r\n<div class=\"bg-white flex flex-row flex-wrap gap-2 p-2 modal-barra-acoes {{justify_content}}\" *ngIf=\"actions\" id=\"actions-field\">\r\n <kv-button-personalize\r\n *ngFor=\" let action of actions\"\r\n [ngClass]=\"action.visible==false?'hidden':''\"\r\n color=\"{{action.color}}\"\r\n colorHover=\"{{action.colorHover}}\"\r\n textColor=\"{{action.textColor}}\"\r\n icon=\"{{action.icon}}\"\r\n label=\"{{action.label}}\"\r\n [disabled]=\"action.disabled || false\"\r\n (onClick)=\"clickExecute(action)\"\r\n />\r\n</div>", styles: ["::ng-deep .p-dialog .p-dialog-header{color:#fff!important;background:#002542!important;display:flex!important;flex-wrap:wrap}::ng-deep .p-dialog .p-dialog-content{padding-top:1rem}::ng-deep .p-dialog{min-width:320px}.sub-title{color:#ff0;position:relative;bottom:25px;z-index:1}::ng-deep .p-dialog-content{overflow-x:hidden}::ng-deep .p-dialog-content::-webkit-scrollbar{width:8px}::ng-deep .p-dialog-content::-webkit-scrollbar:hover{background-color:#dededebf}::ng-deep .p-dialog-content::-webkit-scrollbar-thumb{border-radius:4px;background-color:transparent}::ng-deep .p-dialog-content:hover::-webkit-scrollbar-thumb{border-left:2px solid white;background-color:#00000080}::ng-deep .p-dialog-content::-webkit-scrollbar-track{border-left:2px solid white;background-color:#dededebf}*{padding-bottom:0rem;padding-top:0rem}.barra-acoes{position:fixed;bottom:0;left:0;right:0;background-color:#fff;padding:10px;z-index:999}#page-form-container{padding-bottom:40px}@media screen and (max-width: 991px){#page-form-container{padding-bottom:100px}}.modal-barra-acoes{position:fixed;bottom:0;left:0;right:0;z-index:999;margin-right:1.5rem}\n"] }]
|
|
3674
|
+
}], ctorParameters: () => [{ type: i1$3.DynamicDialogRef }, { type: i1$3.DynamicDialogConfig }], propDecorators: { subHeader: [{
|
|
3675
|
+
type: Input
|
|
3676
|
+
}], subtitle: [{
|
|
3677
|
+
type: Input
|
|
3678
|
+
}], onWindowResize: [{
|
|
3648
3679
|
type: HostListener,
|
|
3649
3680
|
args: ['window:resize', ['$event']]
|
|
3650
3681
|
}], actions: [{
|