@pumpkin-tech/pumpkin-tech-ng 0.2.55 → 0.2.56
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.
|
@@ -2,7 +2,7 @@ import * as i0 from '@angular/core';
|
|
|
2
2
|
import { HostBinding, Input, Directive, Injectable, NgModule, Optional, Self, EventEmitter, ElementRef, forwardRef, Output, ContentChild, ViewChild, ChangeDetectionStrategy, Component, HostListener, Inject, InjectionToken, Pipe, ContentChildren, inject } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/cdk/layout';
|
|
4
4
|
import * as i2$5 from 'rxjs';
|
|
5
|
-
import { Subject, BehaviorSubject, takeUntil as takeUntil$1, filter, delay, debounceTime, distinctUntilChanged, tap, switchMap, of, isObservable, from, map } from 'rxjs';
|
|
5
|
+
import { Subject, BehaviorSubject, takeUntil as takeUntil$1, filter, delay, debounceTime, distinctUntilChanged, tap, switchMap, of, isObservable, from, interval, map } from 'rxjs';
|
|
6
6
|
import { takeUntil, filter as filter$1, switchMap as switchMap$1 } from 'rxjs/operators';
|
|
7
7
|
import { coerceBooleanProperty } from '@angular/cdk/coercion';
|
|
8
8
|
import * as i2 from '@angular/forms';
|
|
@@ -4181,303 +4181,191 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
|
|
|
4181
4181
|
type: Input
|
|
4182
4182
|
}] } });
|
|
4183
4183
|
|
|
4184
|
-
|
|
4185
|
-
|
|
4186
|
-
|
|
4187
|
-
|
|
4188
|
-
|
|
4189
|
-
|
|
4190
|
-
|
|
4191
|
-
|
|
4192
|
-
|
|
4193
|
-
|
|
4194
|
-
|
|
4195
|
-
|
|
4196
|
-
|
|
4197
|
-
|
|
4198
|
-
|
|
4199
|
-
|
|
4200
|
-
border: 1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, 0.12)));
|
|
4201
|
-
overflow: hidden;
|
|
4202
|
-
}
|
|
4203
|
-
|
|
4204
|
-
.ptech-dialog-header {
|
|
4205
|
-
display: grid;
|
|
4206
|
-
grid-template-columns: 52px 1fr 52px;
|
|
4207
|
-
align-items: center;
|
|
4208
|
-
gap: 12px;
|
|
4209
|
-
padding: 14px 16px;
|
|
4210
|
-
background: var(--ptech-dialog-header-bg, var(--app-surface-2, #f7f7f7));
|
|
4211
|
-
flex: 0 0 auto;
|
|
4212
|
-
}
|
|
4213
|
-
|
|
4214
|
-
.ptech-dialog-drag {
|
|
4215
|
-
width: 42px;
|
|
4216
|
-
height: 42px;
|
|
4217
|
-
border-radius: 12px;
|
|
4218
|
-
display: inline-flex;
|
|
4219
|
-
align-items: center;
|
|
4220
|
-
justify-content: center;
|
|
4221
|
-
border: 1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, 0.12)));
|
|
4222
|
-
color: var(--ptech-dialog-muted, var(--app-muted, #94a3b8));
|
|
4223
|
-
background: color-mix(in srgb, var(--app-surface, #fff) 92%, transparent);
|
|
4224
|
-
}
|
|
4225
|
-
|
|
4226
|
-
.ptech-dialog-heading h1[mat-dialog-title],
|
|
4227
|
-
.ptech-dialog-heading h2[mat-dialog-title] {
|
|
4228
|
-
margin: 0;
|
|
4229
|
-
line-height: 1.2;
|
|
4230
|
-
font-weight: 700;
|
|
4231
|
-
color: var(--ptech-dialog-text, var(--app-text, inherit));
|
|
4232
|
-
text-align: center;
|
|
4233
|
-
}
|
|
4234
|
-
|
|
4235
|
-
.ptech-dialog-heading {
|
|
4236
|
-
text-align: center;
|
|
4237
|
-
justify-self: center;
|
|
4238
|
-
width: 100%;
|
|
4239
|
-
}
|
|
4240
|
-
|
|
4241
|
-
.ptech-dialog-subtitle {
|
|
4242
|
-
margin: 2px 0 0;
|
|
4243
|
-
color: var(--ptech-dialog-muted, var(--app-muted, #94a3b8));
|
|
4244
|
-
font-size: 1rem;
|
|
4245
|
-
font-weight: 500;
|
|
4246
|
-
}
|
|
4247
|
-
|
|
4248
|
-
.ptech-dialog-close {
|
|
4249
|
-
width: 42px;
|
|
4250
|
-
height: 42px;
|
|
4251
|
-
border-radius: 12px;
|
|
4252
|
-
border: 1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, 0.12)));
|
|
4253
|
-
color: var(--ptech-dialog-text, var(--app-text, inherit));
|
|
4254
|
-
background: color-mix(in srgb, var(--app-surface, #fff) 92%, transparent);
|
|
4255
|
-
display: inline-flex;
|
|
4256
|
-
align-items: center;
|
|
4257
|
-
justify-content: center;
|
|
4258
|
-
padding: 0 !important;
|
|
4259
|
-
}
|
|
4260
|
-
|
|
4261
|
-
.ptech-dialog-close .mat-icon {
|
|
4262
|
-
margin: 0;
|
|
4263
|
-
width: 26px;
|
|
4264
|
-
height: 26px;
|
|
4265
|
-
font-size: 26px;
|
|
4266
|
-
line-height: 26px;
|
|
4267
|
-
}
|
|
4268
|
-
|
|
4269
|
-
.ptech-dialog-divider {
|
|
4270
|
-
border-top: 1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, 0.12)));
|
|
4271
|
-
}
|
|
4272
|
-
|
|
4273
|
-
.ptech-dialog-content {
|
|
4274
|
-
flex: 1 1 auto;
|
|
4275
|
-
min-height: 0;
|
|
4276
|
-
max-height: none;
|
|
4277
|
-
overflow-y: auto;
|
|
4278
|
-
overflow-x: hidden;
|
|
4279
|
-
padding: 16px;
|
|
4280
|
-
box-sizing: border-box;
|
|
4281
|
-
color: var(--ptech-dialog-content-text, var(--ptech-dialog-text, var(--app-text, inherit)));
|
|
4282
|
-
}
|
|
4283
|
-
|
|
4284
|
-
.ptech-dialog-content p,
|
|
4285
|
-
.ptech-dialog-content span,
|
|
4286
|
-
.ptech-dialog-content div,
|
|
4287
|
-
.ptech-dialog-content li,
|
|
4288
|
-
.ptech-dialog-content strong,
|
|
4289
|
-
.ptech-dialog-content em,
|
|
4290
|
-
.ptech-dialog-content small {
|
|
4291
|
-
color: var(--ptech-dialog-content-text, var(--ptech-dialog-text, var(--app-text, inherit)));
|
|
4292
|
-
}
|
|
4293
|
-
|
|
4294
|
-
.ptech-dialog-content::-webkit-scrollbar {
|
|
4295
|
-
width: 10px;
|
|
4296
|
-
height: 10px;
|
|
4297
|
-
}
|
|
4298
|
-
|
|
4299
|
-
.ptech-dialog-content::-webkit-scrollbar-track {
|
|
4300
|
-
background: var(--ptech-scroll-track, var(--app-scroll-track, color-mix(in srgb, var(--app-surface-2, #f7f7f7) 70%, transparent)));
|
|
4301
|
-
border-radius: 12px;
|
|
4302
|
-
}
|
|
4303
|
-
|
|
4304
|
-
.ptech-dialog-content::-webkit-scrollbar-thumb {
|
|
4305
|
-
background: var(--ptech-scroll-thumb, var(--app-scroll-thumb, color-mix(in srgb, var(--app-link-accent, #3b82f6) 70%, #6b7280 30%)));
|
|
4306
|
-
border-radius: 12px;
|
|
4307
|
-
border: 2px solid transparent;
|
|
4308
|
-
background-clip: padding-box;
|
|
4309
|
-
}
|
|
4310
|
-
|
|
4311
|
-
.ptech-dialog-content::-webkit-scrollbar-thumb:hover {
|
|
4312
|
-
background: var(--ptech-scroll-thumb-hover, var(--app-scroll-thumb-hover, var(--ptech-scroll-thumb, #60a5fa)));
|
|
4313
|
-
}
|
|
4314
|
-
|
|
4315
|
-
.ptech-dialog-content {
|
|
4316
|
-
scrollbar-width: thin;
|
|
4317
|
-
scrollbar-color: var(--ptech-scroll-thumb, var(--app-scroll-thumb, #60a5fa)) var(--ptech-scroll-track, var(--app-scroll-track, #1f2937));
|
|
4318
|
-
}
|
|
4319
|
-
|
|
4320
|
-
.ptech-dialog-actions {
|
|
4321
|
-
margin: 0;
|
|
4322
|
-
padding: 14px 16px 16px;
|
|
4323
|
-
border-top: 1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, 0.12)));
|
|
4324
|
-
background: var(--ptech-dialog-footer-bg, var(--app-surface-2, #f7f7f7));
|
|
4325
|
-
display: flex;
|
|
4326
|
-
justify-content: flex-end;
|
|
4327
|
-
gap: 8px;
|
|
4328
|
-
flex-wrap: wrap;
|
|
4329
|
-
flex: 0 0 auto;
|
|
4330
|
-
}
|
|
4331
|
-
|
|
4332
|
-
::ng-deep .ptech-dialog-panel .mat-mdc-dialog-surface {
|
|
4333
|
-
background: transparent !important;
|
|
4334
|
-
box-shadow: none !important;
|
|
4335
|
-
color: inherit;
|
|
4336
|
-
overflow: visible;
|
|
4337
|
-
border-radius: 16px;
|
|
4338
|
-
padding: 0;
|
|
4339
|
-
max-height: none !important;
|
|
4340
|
-
}
|
|
4341
|
-
|
|
4342
|
-
.ptech-dialog-content.mat-mdc-dialog-content {
|
|
4343
|
-
max-height: none !important;
|
|
4344
|
-
margin: 0;
|
|
4345
|
-
}
|
|
4346
|
-
|
|
4347
|
-
::ng-deep .cdk-overlay-pane.ptech-dialog-panel {
|
|
4348
|
-
display: flex !important;
|
|
4349
|
-
align-items: center !important;
|
|
4350
|
-
justify-content: center !important;
|
|
4351
|
-
max-width: 96vw !important;
|
|
4352
|
-
max-height: 96dvh !important;
|
|
4353
|
-
margin: 0 auto !important;
|
|
4354
|
-
z-index: var(--ptech-overlay-z-index, 10000) !important;
|
|
4355
|
-
}
|
|
4356
|
-
|
|
4357
|
-
::ng-deep .cdk-overlay-pane:not(.ptech-dialog-panel) {
|
|
4358
|
-
z-index: calc(var(--ptech-overlay-z-index, 10000) + 1) !important;
|
|
4359
|
-
}
|
|
4360
|
-
|
|
4361
|
-
::ng-deep .cdk-overlay-pane .mat-mdc-select-panel,
|
|
4362
|
-
::ng-deep .cdk-overlay-pane .ptech-select-enum-panel,
|
|
4363
|
-
::ng-deep .cdk-overlay-pane .ptech-select-entity-panel,
|
|
4364
|
-
::ng-deep .cdk-overlay-pane .ptech-select-quantity-panel {
|
|
4365
|
-
opacity: 1 !important;
|
|
4366
|
-
visibility: visible !important;
|
|
4367
|
-
pointer-events: auto !important;
|
|
4368
|
-
}
|
|
4369
|
-
|
|
4370
|
-
::ng-deep .cdk-overlay-pane .mat-mdc-tooltip-panel {
|
|
4371
|
-
z-index: var(--ptech-tooltip-z-index, 11000) !important;
|
|
4372
|
-
}
|
|
4373
|
-
|
|
4374
|
-
@media (max-width: 700px) {
|
|
4375
|
-
.ptech-dialog-shell {
|
|
4376
|
-
max-width: 94vw !important;
|
|
4377
|
-
max-height: calc(100dvh - 18px) !important;
|
|
4378
|
-
margin: 0 auto !important;
|
|
4379
|
-
}
|
|
4380
|
-
|
|
4381
|
-
::ng-deep .cdk-overlay-pane.ptech-dialog-panel {
|
|
4382
|
-
max-width: 96vw !important;
|
|
4383
|
-
max-height: calc(100dvh - 8px) !important;
|
|
4384
|
-
padding: 0 !important;
|
|
4385
|
-
}
|
|
4386
|
-
}
|
|
4387
|
-
`;
|
|
4388
|
-
|
|
4389
|
-
class ConfirmationDialogComponent {
|
|
4390
|
-
dialogRef;
|
|
4391
|
-
confirmation;
|
|
4392
|
-
constructor(dialogRef, confirmation) {
|
|
4393
|
-
this.dialogRef = dialogRef;
|
|
4394
|
-
this.confirmation = confirmation;
|
|
4395
|
-
}
|
|
4396
|
-
confirm() {
|
|
4397
|
-
this.confirmation.accept();
|
|
4398
|
-
this.dialogRef.close(true);
|
|
4399
|
-
}
|
|
4400
|
-
cancel() {
|
|
4401
|
-
this.dialogRef.close(false);
|
|
4402
|
-
}
|
|
4403
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: ConfirmationDialogComponent, deps: [{ token: i1$3.MatDialogRef }, { token: MAT_DIALOG_DATA }], target: i0.ɵɵFactoryTarget.Component });
|
|
4404
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.16", type: ConfirmationDialogComponent, isStandalone: true, selector: "ptech-confirmation-dialog", ngImport: i0, template: `
|
|
4405
|
-
<div class="ptech-dialog-shell" cdkDrag cdkDragRootElement=".cdk-overlay-pane">
|
|
4184
|
+
class DialogShellComponent {
|
|
4185
|
+
title = '';
|
|
4186
|
+
subtitle;
|
|
4187
|
+
draggable = true;
|
|
4188
|
+
showDrag = true;
|
|
4189
|
+
showClose = true;
|
|
4190
|
+
dragRootElement = '.cdk-overlay-pane';
|
|
4191
|
+
close = new EventEmitter();
|
|
4192
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: DialogShellComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
4193
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.16", type: DialogShellComponent, isStandalone: true, selector: "ptech-dialog-shell", inputs: { title: "title", subtitle: "subtitle", draggable: "draggable", showDrag: "showDrag", showClose: "showClose", dragRootElement: "dragRootElement" }, outputs: { close: "close" }, ngImport: i0, template: `
|
|
4194
|
+
<div
|
|
4195
|
+
class="ptech-dialog-shell"
|
|
4196
|
+
cdkDrag
|
|
4197
|
+
[cdkDragDisabled]="!draggable"
|
|
4198
|
+
[cdkDragRootElement]="dragRootElement"
|
|
4199
|
+
>
|
|
4406
4200
|
<div class="ptech-dialog-header">
|
|
4407
|
-
<div class="ptech-dialog-drag" cdkDragHandle aria-hidden="true">
|
|
4201
|
+
<div class="ptech-dialog-drag" *ngIf="showDrag" cdkDragHandle aria-hidden="true">
|
|
4408
4202
|
<mat-icon>drag_indicator</mat-icon>
|
|
4409
4203
|
</div>
|
|
4204
|
+
<div class="ptech-dialog-drag ptech-dialog-drag--spacer" *ngIf="!showDrag" aria-hidden="true"></div>
|
|
4410
4205
|
|
|
4411
4206
|
<div class="ptech-dialog-heading">
|
|
4412
|
-
<
|
|
4207
|
+
<h2 mat-dialog-title>{{ title }}</h2>
|
|
4208
|
+
<p class="ptech-dialog-subtitle" *ngIf="subtitle">{{ subtitle }}</p>
|
|
4413
4209
|
</div>
|
|
4414
4210
|
|
|
4415
4211
|
<button
|
|
4416
|
-
|
|
4212
|
+
*ngIf="showClose"
|
|
4417
4213
|
type="button"
|
|
4418
4214
|
class="ptech-dialog-close"
|
|
4419
4215
|
aria-label="Fechar"
|
|
4420
|
-
(click)="
|
|
4216
|
+
(click)="close.emit()"
|
|
4217
|
+
>
|
|
4421
4218
|
<mat-icon>close</mat-icon>
|
|
4422
4219
|
</button>
|
|
4220
|
+
<div *ngIf="!showClose" class="ptech-dialog-drag ptech-dialog-drag--spacer" aria-hidden="true"></div>
|
|
4423
4221
|
</div>
|
|
4424
4222
|
|
|
4425
4223
|
<div class="ptech-dialog-divider"></div>
|
|
4426
4224
|
|
|
4427
|
-
<div
|
|
4428
|
-
<
|
|
4429
|
-
</div>
|
|
4430
|
-
|
|
4431
|
-
<div class="ptech-dialog-actions">
|
|
4432
|
-
<button mat-flat-button color="primary" (click)="confirm()">
|
|
4433
|
-
{{ confirmation.confirmText || 'OK' }}
|
|
4434
|
-
</button>
|
|
4435
|
-
<button mat-flat-button color="warn" (click)="cancel()">
|
|
4436
|
-
{{ confirmation.cancelText || 'Cancelar' }}
|
|
4437
|
-
</button>
|
|
4225
|
+
<div class="ptech-dialog-content">
|
|
4226
|
+
<ng-content></ng-content>
|
|
4438
4227
|
</div>
|
|
4439
4228
|
</div>
|
|
4440
|
-
`, isInline: true, styles: [":host{display:block;color:var(--ptech-dialog-text, var(--app-text, inherit))}.ptech-dialog-shell{display:flex;flex-direction:column;max-width:92vw;width:100%;max-height:88vh;min-height:0;background:var(--ptech-dialog-bg, var(--app-surface, #fff));color:var(--ptech-dialog-text, var(--app-text, inherit));border-radius:16px;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));overflow:hidden}.ptech-dialog-header{display:grid;grid-template-columns:52px 1fr 52px;align-items:center;gap:12px;padding:14px 16px;background:var(--ptech-dialog-header-bg, var(--app-surface-2, #f7f7f7));flex:0 0 auto}.ptech-dialog-drag{width:42px;height:42px;border-radius:12px;display:inline-flex;align-items:center;justify-content:center;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));color:var(--ptech-dialog-muted, var(--app-muted, #94a3b8));background:color-mix(in srgb,var(--app-surface, #fff) 92%,transparent)}.ptech-dialog-heading h1[mat-dialog-title],.ptech-dialog-heading h2[mat-dialog-title]{margin:0;line-height:1.2;font-weight:700;color:var(--ptech-dialog-text, var(--app-text, inherit));text-align:center}.ptech-dialog-heading{text-align:center;justify-self:center;width:100%}.ptech-dialog-subtitle{margin:2px 0 0;color:var(--ptech-dialog-muted, var(--app-muted, #94a3b8));font-size:1rem;font-weight:500}.ptech-dialog-close{width:42px;height:42px;border-radius:12px;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));color:var(--ptech-dialog-text, var(--app-text, inherit));background:color-mix(in srgb,var(--app-surface, #fff) 92%,transparent);display:inline-flex;align-items:center;justify-content:center;padding:0!important}.ptech-dialog-close .mat-icon{margin:0;width:26px;height:26px;font-size:26px;line-height:26px}.ptech-dialog-divider{border-top:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)))}.ptech-dialog-content{flex:1 1 auto;min-height:0;max-height:none;overflow-y:auto;overflow-x:hidden;padding:16px;box-sizing:border-box;color:var(--ptech-dialog-content-text, var(--ptech-dialog-text, var(--app-text, inherit)))}.ptech-dialog-content
|
|
4229
|
+
`, isInline: true, styles: [":host{display:block;color:var(--ptech-dialog-text, var(--app-text, inherit))}.ptech-dialog-shell{display:flex;flex-direction:column;max-width:92vw;width:100%;max-height:88vh;min-height:0;background:var(--ptech-dialog-bg, var(--app-surface, #fff));color:var(--ptech-dialog-text, var(--app-text, inherit));border-radius:16px;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));overflow:hidden}.ptech-dialog-header{display:grid;grid-template-columns:52px 1fr 52px;align-items:center;gap:12px;padding:14px 16px;background:var(--ptech-dialog-header-bg, var(--app-surface-2, #f7f7f7));flex:0 0 auto}.ptech-dialog-drag{width:42px;height:42px;border-radius:12px;display:inline-flex;align-items:center;justify-content:center;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));color:var(--ptech-dialog-muted, var(--app-muted, #94a3b8));background:color-mix(in srgb,var(--app-surface, #fff) 92%,transparent)}.ptech-dialog-heading h1[mat-dialog-title],.ptech-dialog-heading h2[mat-dialog-title]{margin:0;line-height:1.2;font-weight:700;color:var(--ptech-dialog-text, var(--app-text, inherit));text-align:center}.ptech-dialog-heading{text-align:center;justify-self:center;width:100%}.ptech-dialog-subtitle{margin:2px 0 0;color:var(--ptech-dialog-muted, var(--app-muted, #94a3b8));font-size:1rem;font-weight:500}.ptech-dialog-close{width:42px;height:42px;border-radius:12px;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));color:var(--ptech-dialog-text, var(--app-text, inherit));background:color-mix(in srgb,var(--app-surface, #fff) 92%,transparent);display:inline-flex;align-items:center;justify-content:center;padding:0!important}.ptech-dialog-close .mat-icon{margin:0;width:26px;height:26px;font-size:26px;line-height:26px}.ptech-dialog-divider{border-top:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)))}.ptech-dialog-content{flex:1 1 auto;min-height:0;max-height:none;overflow-y:auto;overflow-x:hidden;padding:16px;box-sizing:border-box;color:var(--ptech-dialog-content-text, var(--ptech-dialog-text, var(--app-text, inherit)))}.ptech-dialog-content::-webkit-scrollbar{width:10px;height:10px}.ptech-dialog-content::-webkit-scrollbar-track{background:var(--ptech-scroll-track, var(--app-scroll-track, color-mix(in srgb, var(--app-surface-2, #f7f7f7) 70%, transparent)));border-radius:12px}.ptech-dialog-content::-webkit-scrollbar-thumb{background:var(--ptech-scroll-thumb, var(--app-scroll-thumb, color-mix(in srgb, var(--app-link-accent, #3b82f6) 70%, #6b7280 30%)));border-radius:12px;border:2px solid transparent;background-clip:padding-box}.ptech-dialog-content::-webkit-scrollbar-thumb:hover{background:var(--ptech-scroll-thumb-hover, var(--app-scroll-thumb-hover, var(--ptech-scroll-thumb, #60a5fa)))}.ptech-dialog-content{scrollbar-width:thin;scrollbar-color:var(--ptech-scroll-thumb, var(--app-scroll-thumb, #60a5fa)) var(--ptech-scroll-track, var(--app-scroll-track, #1f2937))}::ng-deep .ptech-dialog-panel .mat-mdc-dialog-surface{background:transparent!important;box-shadow:none!important;color:inherit;overflow:visible;border-radius:16px;padding:0;max-height:none!important}::ng-deep .cdk-overlay-pane.ptech-dialog-panel{display:flex!important;align-items:center!important;justify-content:center!important;max-width:96vw!important;max-height:96dvh!important;margin:0 auto!important}::ng-deep .cdk-overlay-pane .mat-mdc-tooltip-panel{z-index:var(--ptech-tooltip-z-index, 11000)!important}\n", ".ptech-dialog-drag--spacer{border-color:transparent!important;background:transparent!important}@media (max-width: 700px){.ptech-dialog-shell{max-width:94vw!important;max-height:calc(100dvh - 18px)!important;margin:0 auto!important}::ng-deep .cdk-overlay-pane.ptech-dialog-panel{max-width:96vw!important;max-height:calc(100dvh - 8px)!important;padding:0!important}}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer", "cdkDragScale"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3$1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }] });
|
|
4441
4230
|
}
|
|
4442
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type:
|
|
4231
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: DialogShellComponent, decorators: [{
|
|
4443
4232
|
type: Component,
|
|
4444
|
-
args: [{ selector: 'ptech-
|
|
4445
|
-
<div
|
|
4233
|
+
args: [{ selector: 'ptech-dialog-shell', standalone: true, imports: [NgIf, CdkDrag, CdkDragHandle, MatIconModule], template: `
|
|
4234
|
+
<div
|
|
4235
|
+
class="ptech-dialog-shell"
|
|
4236
|
+
cdkDrag
|
|
4237
|
+
[cdkDragDisabled]="!draggable"
|
|
4238
|
+
[cdkDragRootElement]="dragRootElement"
|
|
4239
|
+
>
|
|
4446
4240
|
<div class="ptech-dialog-header">
|
|
4447
|
-
<div class="ptech-dialog-drag" cdkDragHandle aria-hidden="true">
|
|
4241
|
+
<div class="ptech-dialog-drag" *ngIf="showDrag" cdkDragHandle aria-hidden="true">
|
|
4448
4242
|
<mat-icon>drag_indicator</mat-icon>
|
|
4449
4243
|
</div>
|
|
4244
|
+
<div class="ptech-dialog-drag ptech-dialog-drag--spacer" *ngIf="!showDrag" aria-hidden="true"></div>
|
|
4450
4245
|
|
|
4451
4246
|
<div class="ptech-dialog-heading">
|
|
4452
|
-
<
|
|
4247
|
+
<h2 mat-dialog-title>{{ title }}</h2>
|
|
4248
|
+
<p class="ptech-dialog-subtitle" *ngIf="subtitle">{{ subtitle }}</p>
|
|
4453
4249
|
</div>
|
|
4454
4250
|
|
|
4455
4251
|
<button
|
|
4456
|
-
|
|
4252
|
+
*ngIf="showClose"
|
|
4457
4253
|
type="button"
|
|
4458
4254
|
class="ptech-dialog-close"
|
|
4459
4255
|
aria-label="Fechar"
|
|
4460
|
-
(click)="
|
|
4256
|
+
(click)="close.emit()"
|
|
4257
|
+
>
|
|
4461
4258
|
<mat-icon>close</mat-icon>
|
|
4462
4259
|
</button>
|
|
4260
|
+
<div *ngIf="!showClose" class="ptech-dialog-drag ptech-dialog-drag--spacer" aria-hidden="true"></div>
|
|
4463
4261
|
</div>
|
|
4464
4262
|
|
|
4465
|
-
<div class="ptech-dialog-divider"></div>
|
|
4263
|
+
<div class="ptech-dialog-divider"></div>
|
|
4264
|
+
|
|
4265
|
+
<div class="ptech-dialog-content">
|
|
4266
|
+
<ng-content></ng-content>
|
|
4267
|
+
</div>
|
|
4268
|
+
</div>
|
|
4269
|
+
`, styles: [":host{display:block;color:var(--ptech-dialog-text, var(--app-text, inherit))}.ptech-dialog-shell{display:flex;flex-direction:column;max-width:92vw;width:100%;max-height:88vh;min-height:0;background:var(--ptech-dialog-bg, var(--app-surface, #fff));color:var(--ptech-dialog-text, var(--app-text, inherit));border-radius:16px;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));overflow:hidden}.ptech-dialog-header{display:grid;grid-template-columns:52px 1fr 52px;align-items:center;gap:12px;padding:14px 16px;background:var(--ptech-dialog-header-bg, var(--app-surface-2, #f7f7f7));flex:0 0 auto}.ptech-dialog-drag{width:42px;height:42px;border-radius:12px;display:inline-flex;align-items:center;justify-content:center;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));color:var(--ptech-dialog-muted, var(--app-muted, #94a3b8));background:color-mix(in srgb,var(--app-surface, #fff) 92%,transparent)}.ptech-dialog-heading h1[mat-dialog-title],.ptech-dialog-heading h2[mat-dialog-title]{margin:0;line-height:1.2;font-weight:700;color:var(--ptech-dialog-text, var(--app-text, inherit));text-align:center}.ptech-dialog-heading{text-align:center;justify-self:center;width:100%}.ptech-dialog-subtitle{margin:2px 0 0;color:var(--ptech-dialog-muted, var(--app-muted, #94a3b8));font-size:1rem;font-weight:500}.ptech-dialog-close{width:42px;height:42px;border-radius:12px;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));color:var(--ptech-dialog-text, var(--app-text, inherit));background:color-mix(in srgb,var(--app-surface, #fff) 92%,transparent);display:inline-flex;align-items:center;justify-content:center;padding:0!important}.ptech-dialog-close .mat-icon{margin:0;width:26px;height:26px;font-size:26px;line-height:26px}.ptech-dialog-divider{border-top:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)))}.ptech-dialog-content{flex:1 1 auto;min-height:0;max-height:none;overflow-y:auto;overflow-x:hidden;padding:16px;box-sizing:border-box;color:var(--ptech-dialog-content-text, var(--ptech-dialog-text, var(--app-text, inherit)))}.ptech-dialog-content::-webkit-scrollbar{width:10px;height:10px}.ptech-dialog-content::-webkit-scrollbar-track{background:var(--ptech-scroll-track, var(--app-scroll-track, color-mix(in srgb, var(--app-surface-2, #f7f7f7) 70%, transparent)));border-radius:12px}.ptech-dialog-content::-webkit-scrollbar-thumb{background:var(--ptech-scroll-thumb, var(--app-scroll-thumb, color-mix(in srgb, var(--app-link-accent, #3b82f6) 70%, #6b7280 30%)));border-radius:12px;border:2px solid transparent;background-clip:padding-box}.ptech-dialog-content::-webkit-scrollbar-thumb:hover{background:var(--ptech-scroll-thumb-hover, var(--app-scroll-thumb-hover, var(--ptech-scroll-thumb, #60a5fa)))}.ptech-dialog-content{scrollbar-width:thin;scrollbar-color:var(--ptech-scroll-thumb, var(--app-scroll-thumb, #60a5fa)) var(--ptech-scroll-track, var(--app-scroll-track, #1f2937))}::ng-deep .ptech-dialog-panel .mat-mdc-dialog-surface{background:transparent!important;box-shadow:none!important;color:inherit;overflow:visible;border-radius:16px;padding:0;max-height:none!important}::ng-deep .cdk-overlay-pane.ptech-dialog-panel{display:flex!important;align-items:center!important;justify-content:center!important;max-width:96vw!important;max-height:96dvh!important;margin:0 auto!important}::ng-deep .cdk-overlay-pane .mat-mdc-tooltip-panel{z-index:var(--ptech-tooltip-z-index, 11000)!important}\n", ".ptech-dialog-drag--spacer{border-color:transparent!important;background:transparent!important}@media (max-width: 700px){.ptech-dialog-shell{max-width:94vw!important;max-height:calc(100dvh - 18px)!important;margin:0 auto!important}::ng-deep .cdk-overlay-pane.ptech-dialog-panel{max-width:96vw!important;max-height:calc(100dvh - 8px)!important;padding:0!important}}\n"] }]
|
|
4270
|
+
}], propDecorators: { title: [{
|
|
4271
|
+
type: Input
|
|
4272
|
+
}], subtitle: [{
|
|
4273
|
+
type: Input
|
|
4274
|
+
}], draggable: [{
|
|
4275
|
+
type: Input
|
|
4276
|
+
}], showDrag: [{
|
|
4277
|
+
type: Input
|
|
4278
|
+
}], showClose: [{
|
|
4279
|
+
type: Input
|
|
4280
|
+
}], dragRootElement: [{
|
|
4281
|
+
type: Input
|
|
4282
|
+
}], close: [{
|
|
4283
|
+
type: Output
|
|
4284
|
+
}] } });
|
|
4285
|
+
|
|
4286
|
+
/**
|
|
4287
|
+
* Confirmation dialog built on the same ptech-dialog-shell/ptech-button chrome every other
|
|
4288
|
+
* dialog uses - it used to hand-roll its own header/footer markup (duplicating dialog-shell's
|
|
4289
|
+
* structure), which is exactly the per-dialog CSS this component now avoids by delegating the
|
|
4290
|
+
* shell entirely.
|
|
4291
|
+
*/
|
|
4292
|
+
class PtechConfirmationDialogComponent {
|
|
4293
|
+
dialogRef;
|
|
4294
|
+
data;
|
|
4295
|
+
constructor(dialogRef, data) {
|
|
4296
|
+
this.dialogRef = dialogRef;
|
|
4297
|
+
this.data = data;
|
|
4298
|
+
}
|
|
4299
|
+
get confirmColor() {
|
|
4300
|
+
return this.data.variant === 'danger' ? 'warn'
|
|
4301
|
+
: this.data.variant === 'warning' ? 'accent'
|
|
4302
|
+
: 'primary';
|
|
4303
|
+
}
|
|
4304
|
+
get confirmIcon() {
|
|
4305
|
+
return this.data.variant === 'danger' ? 'delete'
|
|
4306
|
+
: this.data.variant === 'warning' ? 'warning'
|
|
4307
|
+
: 'check';
|
|
4308
|
+
}
|
|
4309
|
+
confirm() {
|
|
4310
|
+
this.dialogRef.close(true);
|
|
4311
|
+
}
|
|
4312
|
+
cancel() {
|
|
4313
|
+
this.dialogRef.close(false);
|
|
4314
|
+
}
|
|
4315
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PtechConfirmationDialogComponent, deps: [{ token: i1$3.MatDialogRef }, { token: MAT_DIALOG_DATA }], target: i0.ɵɵFactoryTarget.Component });
|
|
4316
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.16", type: PtechConfirmationDialogComponent, isStandalone: true, selector: "ptech-confirmation-dialog", ngImport: i0, template: `
|
|
4317
|
+
<ptech-dialog-shell
|
|
4318
|
+
[title]="data.title"
|
|
4319
|
+
[showClose]="data.disableClose !== true"
|
|
4320
|
+
(close)="cancel()"
|
|
4321
|
+
>
|
|
4322
|
+
<p class="ptech-confirmation-message">{{ data.message }}</p>
|
|
4466
4323
|
|
|
4467
|
-
<div
|
|
4468
|
-
<
|
|
4324
|
+
<div class="ptech-confirmation-actions">
|
|
4325
|
+
<ptech-button
|
|
4326
|
+
[label]="data.cancelText || 'Cancelar'"
|
|
4327
|
+
type="stroked"
|
|
4328
|
+
color="primary"
|
|
4329
|
+
(buttonClick)="cancel()"
|
|
4330
|
+
></ptech-button>
|
|
4331
|
+
<ptech-button
|
|
4332
|
+
[label]="data.confirmText || 'Confirmar'"
|
|
4333
|
+
[icon]="confirmIcon"
|
|
4334
|
+
[color]="confirmColor"
|
|
4335
|
+
type="raised"
|
|
4336
|
+
(buttonClick)="confirm()"
|
|
4337
|
+
></ptech-button>
|
|
4469
4338
|
</div>
|
|
4339
|
+
</ptech-dialog-shell>
|
|
4340
|
+
`, isInline: true, styles: [".ptech-confirmation-message{margin:0;font-size:15px;line-height:1.5;color:var(--ptech-dialog-text, var(--app-text, inherit))}.ptech-confirmation-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:20px}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: DialogShellComponent, selector: "ptech-dialog-shell", inputs: ["title", "subtitle", "draggable", "showDrag", "showClose", "dragRootElement"], outputs: ["close"] }, { kind: "component", type: ButtonComponent, selector: "ptech-button", inputs: ["type", "size", "tooltip", "icon", "iconColor", "iconWidth", "iconHeight", "textColor", "link", "target", "shape", "color", "backgroundColor", "hoverBackgroundColor", "radius"], outputs: ["buttonClick"] }] });
|
|
4341
|
+
}
|
|
4342
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PtechConfirmationDialogComponent, decorators: [{
|
|
4343
|
+
type: Component,
|
|
4344
|
+
args: [{ selector: 'ptech-confirmation-dialog', imports: [CommonModule, DialogShellComponent, ButtonComponent], template: `
|
|
4345
|
+
<ptech-dialog-shell
|
|
4346
|
+
[title]="data.title"
|
|
4347
|
+
[showClose]="data.disableClose !== true"
|
|
4348
|
+
(close)="cancel()"
|
|
4349
|
+
>
|
|
4350
|
+
<p class="ptech-confirmation-message">{{ data.message }}</p>
|
|
4470
4351
|
|
|
4471
|
-
<div class="ptech-
|
|
4472
|
-
<
|
|
4473
|
-
|
|
4474
|
-
|
|
4475
|
-
|
|
4476
|
-
|
|
4477
|
-
|
|
4352
|
+
<div class="ptech-confirmation-actions">
|
|
4353
|
+
<ptech-button
|
|
4354
|
+
[label]="data.cancelText || 'Cancelar'"
|
|
4355
|
+
type="stroked"
|
|
4356
|
+
color="primary"
|
|
4357
|
+
(buttonClick)="cancel()"
|
|
4358
|
+
></ptech-button>
|
|
4359
|
+
<ptech-button
|
|
4360
|
+
[label]="data.confirmText || 'Confirmar'"
|
|
4361
|
+
[icon]="confirmIcon"
|
|
4362
|
+
[color]="confirmColor"
|
|
4363
|
+
type="raised"
|
|
4364
|
+
(buttonClick)="confirm()"
|
|
4365
|
+
></ptech-button>
|
|
4478
4366
|
</div>
|
|
4479
|
-
</
|
|
4480
|
-
`, styles: ["
|
|
4367
|
+
</ptech-dialog-shell>
|
|
4368
|
+
`, styles: [".ptech-confirmation-message{margin:0;font-size:15px;line-height:1.5;color:var(--ptech-dialog-text, var(--app-text, inherit))}.ptech-confirmation-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:20px}\n"] }]
|
|
4481
4369
|
}], ctorParameters: () => [{ type: i1$3.MatDialogRef }, { type: undefined, decorators: [{
|
|
4482
4370
|
type: Inject,
|
|
4483
4371
|
args: [MAT_DIALOG_DATA]
|
|
@@ -4730,56 +4618,264 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
|
|
|
4730
4618
|
<span *ngIf="required" aria-hidden="true">*</span>
|
|
4731
4619
|
</mat-label>
|
|
4732
4620
|
|
|
4733
|
-
<input
|
|
4734
|
-
matInput
|
|
4735
|
-
type="text"
|
|
4736
|
-
[style.text-align]="resolvedOptions.align || 'right'"
|
|
4737
|
-
[placeholder]="placeholder"
|
|
4738
|
-
[required]="required"
|
|
4739
|
-
[disabled]="disabled || loading"
|
|
4740
|
-
[attr.name]="name || null"
|
|
4741
|
-
[attr.aria-label]="ariaLabel || null"
|
|
4742
|
-
autocomplete="off"
|
|
4743
|
-
[value]="displayValue"
|
|
4744
|
-
(input)="onInput(($any($event.target).value))"
|
|
4745
|
-
(blur)="onBlur()"
|
|
4746
|
-
/>
|
|
4621
|
+
<input
|
|
4622
|
+
matInput
|
|
4623
|
+
type="text"
|
|
4624
|
+
[style.text-align]="resolvedOptions.align || 'right'"
|
|
4625
|
+
[placeholder]="placeholder"
|
|
4626
|
+
[required]="required"
|
|
4627
|
+
[disabled]="disabled || loading"
|
|
4628
|
+
[attr.name]="name || null"
|
|
4629
|
+
[attr.aria-label]="ariaLabel || null"
|
|
4630
|
+
autocomplete="off"
|
|
4631
|
+
[value]="displayValue"
|
|
4632
|
+
(input)="onInput(($any($event.target).value))"
|
|
4633
|
+
(blur)="onBlur()"
|
|
4634
|
+
/>
|
|
4635
|
+
|
|
4636
|
+
<mat-spinner
|
|
4637
|
+
matPrefix
|
|
4638
|
+
*ngIf="loading"
|
|
4639
|
+
mode="indeterminate"
|
|
4640
|
+
diameter="17">
|
|
4641
|
+
</mat-spinner>
|
|
4642
|
+
|
|
4643
|
+
<ng-content select="mat-hint, [mat-hint], mat-error, [mat-error]"></ng-content>
|
|
4644
|
+
</mat-form-field>
|
|
4645
|
+
</div>
|
|
4646
|
+
`, providers: [{
|
|
4647
|
+
provide: NG_VALUE_ACCESSOR,
|
|
4648
|
+
useExisting: forwardRef(() => InputCurrencyComponent),
|
|
4649
|
+
multi: true
|
|
4650
|
+
}], changeDetection: ChangeDetectionStrategy.OnPush, styles: [":host{display:block;width:100%;min-width:0;box-sizing:border-box}.ptech-currency-container{display:flex;flex-direction:column;width:100%;box-sizing:border-box;min-width:0}.ptech-form-field{width:100%}:host ::ng-deep .ptech-form-field{--mat-form-field-container-height: var(--ptech-field-height, 56px);--mat-form-field-container-vertical-padding: var(--ptech-field-vertical-padding, 16px)}:host ::ng-deep .ptech-form-field .mdc-text-field{background-color:var(--ptech-field-bg, var(--app-surface, transparent));color:var(--ptech-field-text, var(--app-text, inherit));--mdc-outlined-text-field-outline-color: var(--ptech-field-outline, var(--app-border-color, rgba(0,0,0,.38)));--mdc-outlined-text-field-hover-outline-color: var(--ptech-field-outline-hover, var(--app-text, rgba(0,0,0,.87)));--mdc-outlined-text-field-focus-outline-color: var(--ptech-field-outline-focus, var(--app-text, #3f51b5))}:host ::ng-deep .ptech-form-field .mdc-text-field .mdc-notched-outline__leading,:host ::ng-deep .ptech-form-field .mdc-text-field .mdc-notched-outline__notch,:host ::ng-deep .ptech-form-field .mdc-text-field .mdc-notched-outline__trailing{border-color:var(--ptech-field-outline, var(--app-border-color, rgba(0,0,0,.38)))!important}:host ::ng-deep .ptech-form-field .mdc-text-field.mdc-text-field--hover .mdc-notched-outline__leading,:host ::ng-deep .ptech-form-field .mdc-text-field.mdc-text-field--hover .mdc-notched-outline__notch,:host ::ng-deep .ptech-form-field .mdc-text-field.mdc-text-field--hover .mdc-notched-outline__trailing{border-color:var(--ptech-field-outline-hover, var(--app-text, rgba(0,0,0,.87)))!important}:host ::ng-deep .ptech-form-field .mdc-text-field.mdc-text-field--focused .mdc-notched-outline__leading,:host ::ng-deep .ptech-form-field .mdc-text-field.mdc-text-field--focused .mdc-notched-outline__notch,:host ::ng-deep .ptech-form-field .mdc-text-field.mdc-text-field--focused .mdc-notched-outline__trailing{border-color:var(--ptech-field-outline-focus, var(--app-text, #3f51b5))!important}:host ::ng-deep .ptech-form-field .mat-mdc-input-element,:host ::ng-deep .ptech-form-field .mdc-text-field__input{color:var(--ptech-field-text, var(--app-text, inherit))!important;caret-color:var(--ptech-field-text, var(--app-text, inherit))!important}:host ::ng-deep .ptech-form-field input::placeholder,:host ::ng-deep .ptech-form-field textarea::placeholder,:host ::ng-deep .ptech-form-field .mat-mdc-input-element::placeholder,:host ::ng-deep .ptech-form-field .mdc-text-field__input::placeholder{color:var(--ptech-field-placeholder, var(--app-text, inherit))!important}:host ::ng-deep .ptech-form-field .mdc-floating-label,:host ::ng-deep .ptech-form-field .mdc-floating-label--float-above{color:var(--ptech-field-label, var(--app-text, inherit))!important}mat-label span{color:var(--ptech-required-color, var(--app-status-error, #f44336))!important}:host ::ng-deep .ptech-form-field.mat-form-field-disabled .mdc-text-field__input,:host ::ng-deep .ptech-form-field.mat-form-field-disabled .mat-mdc-input-element,:host ::ng-deep .ptech-form-field.mat-form-field-disabled .mdc-floating-label{color:var(--ptech-field-disabled, var(--app-muted, rgba(0,0,0,.38)))!important;-webkit-text-fill-color:var(--ptech-field-disabled, var(--app-muted, rgba(0,0,0,.38)))!important}:host ::ng-deep .ptech-form-field.mat-form-field-disabled .mdc-notched-outline__leading,:host ::ng-deep .ptech-form-field.mat-form-field-disabled .mdc-notched-outline__notch,:host ::ng-deep .ptech-form-field.mat-form-field-disabled .mdc-notched-outline__trailing{border-color:var(--ptech-field-disabled, var(--app-border-color, rgba(0,0,0,.24)))!important}:host ::ng-deep .ptech-form-field .mat-mdc-form-field-hint{color:var(--ptech-field-hint, var(--app-muted, rgba(0,0,0,.6)))!important}:host ::ng-deep .ptech-form-field .mat-mdc-form-field-error{color:var(--ptech-field-error, var(--app-status-error, #f44336))!important}:host ::ng-deep .ptech-form-field.mat-form-field-invalid .mdc-notched-outline__leading,:host ::ng-deep .ptech-form-field.mat-form-field-invalid .mdc-notched-outline__notch,:host ::ng-deep .ptech-form-field.mat-form-field-invalid .mdc-notched-outline__trailing{border-color:var(--ptech-field-error, var(--app-status-error, #f44336))!important}\n"] }]
|
|
4651
|
+
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { options: [{
|
|
4652
|
+
type: Input
|
|
4653
|
+
}], valueChange: [{
|
|
4654
|
+
type: Output
|
|
4655
|
+
}] } });
|
|
4656
|
+
|
|
4657
|
+
// src/lib/services/message-token.ts
|
|
4658
|
+
const MESSAGE_SERVICE = new InjectionToken('MESSAGE_SERVICE');
|
|
4659
|
+
const DefaultConsoleMessageService = {
|
|
4660
|
+
successMessage: (title, message) => {
|
|
4661
|
+
console.log(`[Success] ${title}: ${message}`);
|
|
4662
|
+
},
|
|
4663
|
+
errorMessage: (title, message) => {
|
|
4664
|
+
console.error(`[Error] ${title}: ${message}`);
|
|
4665
|
+
},
|
|
4666
|
+
warnMessage: (title, message) => {
|
|
4667
|
+
console.warn(`[Warn] ${title}: ${message}`);
|
|
4668
|
+
},
|
|
4669
|
+
infoMessage: (title, message) => {
|
|
4670
|
+
console.info(`[Info] ${title}: ${message}`);
|
|
4671
|
+
},
|
|
4672
|
+
};
|
|
4673
|
+
const DefaultMessageService = DefaultConsoleMessageService;
|
|
4674
|
+
|
|
4675
|
+
const PTECH_DIALOG_SHARED_STYLES = `
|
|
4676
|
+
:host {
|
|
4677
|
+
display: block;
|
|
4678
|
+
color: var(--ptech-dialog-text, var(--app-text, inherit));
|
|
4679
|
+
}
|
|
4680
|
+
|
|
4681
|
+
.ptech-dialog-shell {
|
|
4682
|
+
display: flex;
|
|
4683
|
+
flex-direction: column;
|
|
4684
|
+
max-width: 92vw;
|
|
4685
|
+
width: 100%;
|
|
4686
|
+
max-height: 88vh;
|
|
4687
|
+
min-height: 0;
|
|
4688
|
+
background: var(--ptech-dialog-bg, var(--app-surface, #fff));
|
|
4689
|
+
color: var(--ptech-dialog-text, var(--app-text, inherit));
|
|
4690
|
+
border-radius: 16px;
|
|
4691
|
+
border: 1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, 0.12)));
|
|
4692
|
+
overflow: hidden;
|
|
4693
|
+
}
|
|
4694
|
+
|
|
4695
|
+
.ptech-dialog-header {
|
|
4696
|
+
display: grid;
|
|
4697
|
+
grid-template-columns: 52px 1fr 52px;
|
|
4698
|
+
align-items: center;
|
|
4699
|
+
gap: 12px;
|
|
4700
|
+
padding: 14px 16px;
|
|
4701
|
+
background: var(--ptech-dialog-header-bg, var(--app-surface-2, #f7f7f7));
|
|
4702
|
+
flex: 0 0 auto;
|
|
4703
|
+
}
|
|
4704
|
+
|
|
4705
|
+
.ptech-dialog-drag {
|
|
4706
|
+
width: 42px;
|
|
4707
|
+
height: 42px;
|
|
4708
|
+
border-radius: 12px;
|
|
4709
|
+
display: inline-flex;
|
|
4710
|
+
align-items: center;
|
|
4711
|
+
justify-content: center;
|
|
4712
|
+
border: 1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, 0.12)));
|
|
4713
|
+
color: var(--ptech-dialog-muted, var(--app-muted, #94a3b8));
|
|
4714
|
+
background: color-mix(in srgb, var(--app-surface, #fff) 92%, transparent);
|
|
4715
|
+
}
|
|
4716
|
+
|
|
4717
|
+
.ptech-dialog-heading h1[mat-dialog-title],
|
|
4718
|
+
.ptech-dialog-heading h2[mat-dialog-title] {
|
|
4719
|
+
margin: 0;
|
|
4720
|
+
line-height: 1.2;
|
|
4721
|
+
font-weight: 700;
|
|
4722
|
+
color: var(--ptech-dialog-text, var(--app-text, inherit));
|
|
4723
|
+
text-align: center;
|
|
4724
|
+
}
|
|
4725
|
+
|
|
4726
|
+
.ptech-dialog-heading {
|
|
4727
|
+
text-align: center;
|
|
4728
|
+
justify-self: center;
|
|
4729
|
+
width: 100%;
|
|
4730
|
+
}
|
|
4731
|
+
|
|
4732
|
+
.ptech-dialog-subtitle {
|
|
4733
|
+
margin: 2px 0 0;
|
|
4734
|
+
color: var(--ptech-dialog-muted, var(--app-muted, #94a3b8));
|
|
4735
|
+
font-size: 1rem;
|
|
4736
|
+
font-weight: 500;
|
|
4737
|
+
}
|
|
4738
|
+
|
|
4739
|
+
.ptech-dialog-close {
|
|
4740
|
+
width: 42px;
|
|
4741
|
+
height: 42px;
|
|
4742
|
+
border-radius: 12px;
|
|
4743
|
+
border: 1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, 0.12)));
|
|
4744
|
+
color: var(--ptech-dialog-text, var(--app-text, inherit));
|
|
4745
|
+
background: color-mix(in srgb, var(--app-surface, #fff) 92%, transparent);
|
|
4746
|
+
display: inline-flex;
|
|
4747
|
+
align-items: center;
|
|
4748
|
+
justify-content: center;
|
|
4749
|
+
padding: 0 !important;
|
|
4750
|
+
}
|
|
4751
|
+
|
|
4752
|
+
.ptech-dialog-close .mat-icon {
|
|
4753
|
+
margin: 0;
|
|
4754
|
+
width: 26px;
|
|
4755
|
+
height: 26px;
|
|
4756
|
+
font-size: 26px;
|
|
4757
|
+
line-height: 26px;
|
|
4758
|
+
}
|
|
4759
|
+
|
|
4760
|
+
.ptech-dialog-divider {
|
|
4761
|
+
border-top: 1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, 0.12)));
|
|
4762
|
+
}
|
|
4763
|
+
|
|
4764
|
+
.ptech-dialog-content {
|
|
4765
|
+
flex: 1 1 auto;
|
|
4766
|
+
min-height: 0;
|
|
4767
|
+
max-height: none;
|
|
4768
|
+
overflow-y: auto;
|
|
4769
|
+
overflow-x: hidden;
|
|
4770
|
+
padding: 16px;
|
|
4771
|
+
box-sizing: border-box;
|
|
4772
|
+
color: var(--ptech-dialog-content-text, var(--ptech-dialog-text, var(--app-text, inherit)));
|
|
4773
|
+
}
|
|
4774
|
+
|
|
4775
|
+
.ptech-dialog-content p,
|
|
4776
|
+
.ptech-dialog-content span,
|
|
4777
|
+
.ptech-dialog-content div,
|
|
4778
|
+
.ptech-dialog-content li,
|
|
4779
|
+
.ptech-dialog-content strong,
|
|
4780
|
+
.ptech-dialog-content em,
|
|
4781
|
+
.ptech-dialog-content small {
|
|
4782
|
+
color: var(--ptech-dialog-content-text, var(--ptech-dialog-text, var(--app-text, inherit)));
|
|
4783
|
+
}
|
|
4784
|
+
|
|
4785
|
+
.ptech-dialog-content::-webkit-scrollbar {
|
|
4786
|
+
width: 10px;
|
|
4787
|
+
height: 10px;
|
|
4788
|
+
}
|
|
4789
|
+
|
|
4790
|
+
.ptech-dialog-content::-webkit-scrollbar-track {
|
|
4791
|
+
background: var(--ptech-scroll-track, var(--app-scroll-track, color-mix(in srgb, var(--app-surface-2, #f7f7f7) 70%, transparent)));
|
|
4792
|
+
border-radius: 12px;
|
|
4793
|
+
}
|
|
4794
|
+
|
|
4795
|
+
.ptech-dialog-content::-webkit-scrollbar-thumb {
|
|
4796
|
+
background: var(--ptech-scroll-thumb, var(--app-scroll-thumb, color-mix(in srgb, var(--app-link-accent, #3b82f6) 70%, #6b7280 30%)));
|
|
4797
|
+
border-radius: 12px;
|
|
4798
|
+
border: 2px solid transparent;
|
|
4799
|
+
background-clip: padding-box;
|
|
4800
|
+
}
|
|
4801
|
+
|
|
4802
|
+
.ptech-dialog-content::-webkit-scrollbar-thumb:hover {
|
|
4803
|
+
background: var(--ptech-scroll-thumb-hover, var(--app-scroll-thumb-hover, var(--ptech-scroll-thumb, #60a5fa)));
|
|
4804
|
+
}
|
|
4805
|
+
|
|
4806
|
+
.ptech-dialog-content {
|
|
4807
|
+
scrollbar-width: thin;
|
|
4808
|
+
scrollbar-color: var(--ptech-scroll-thumb, var(--app-scroll-thumb, #60a5fa)) var(--ptech-scroll-track, var(--app-scroll-track, #1f2937));
|
|
4809
|
+
}
|
|
4810
|
+
|
|
4811
|
+
.ptech-dialog-actions {
|
|
4812
|
+
margin: 0;
|
|
4813
|
+
padding: 14px 16px 16px;
|
|
4814
|
+
border-top: 1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, 0.12)));
|
|
4815
|
+
background: var(--ptech-dialog-footer-bg, var(--app-surface-2, #f7f7f7));
|
|
4816
|
+
display: flex;
|
|
4817
|
+
justify-content: flex-end;
|
|
4818
|
+
gap: 8px;
|
|
4819
|
+
flex-wrap: wrap;
|
|
4820
|
+
flex: 0 0 auto;
|
|
4821
|
+
}
|
|
4822
|
+
|
|
4823
|
+
::ng-deep .ptech-dialog-panel .mat-mdc-dialog-surface {
|
|
4824
|
+
background: transparent !important;
|
|
4825
|
+
box-shadow: none !important;
|
|
4826
|
+
color: inherit;
|
|
4827
|
+
overflow: visible;
|
|
4828
|
+
border-radius: 16px;
|
|
4829
|
+
padding: 0;
|
|
4830
|
+
max-height: none !important;
|
|
4831
|
+
}
|
|
4832
|
+
|
|
4833
|
+
.ptech-dialog-content.mat-mdc-dialog-content {
|
|
4834
|
+
max-height: none !important;
|
|
4835
|
+
margin: 0;
|
|
4836
|
+
}
|
|
4837
|
+
|
|
4838
|
+
::ng-deep .cdk-overlay-pane.ptech-dialog-panel {
|
|
4839
|
+
display: flex !important;
|
|
4840
|
+
align-items: center !important;
|
|
4841
|
+
justify-content: center !important;
|
|
4842
|
+
max-width: 96vw !important;
|
|
4843
|
+
max-height: 96dvh !important;
|
|
4844
|
+
margin: 0 auto !important;
|
|
4845
|
+
z-index: var(--ptech-overlay-z-index, 10000) !important;
|
|
4846
|
+
}
|
|
4847
|
+
|
|
4848
|
+
::ng-deep .cdk-overlay-pane:not(.ptech-dialog-panel) {
|
|
4849
|
+
z-index: calc(var(--ptech-overlay-z-index, 10000) + 1) !important;
|
|
4850
|
+
}
|
|
4747
4851
|
|
|
4748
|
-
|
|
4749
|
-
|
|
4750
|
-
|
|
4751
|
-
|
|
4752
|
-
|
|
4753
|
-
|
|
4852
|
+
::ng-deep .cdk-overlay-pane .mat-mdc-select-panel,
|
|
4853
|
+
::ng-deep .cdk-overlay-pane .ptech-select-enum-panel,
|
|
4854
|
+
::ng-deep .cdk-overlay-pane .ptech-select-entity-panel,
|
|
4855
|
+
::ng-deep .cdk-overlay-pane .ptech-select-quantity-panel {
|
|
4856
|
+
opacity: 1 !important;
|
|
4857
|
+
visibility: visible !important;
|
|
4858
|
+
pointer-events: auto !important;
|
|
4859
|
+
}
|
|
4754
4860
|
|
|
4755
|
-
|
|
4756
|
-
|
|
4757
|
-
|
|
4758
|
-
`, providers: [{
|
|
4759
|
-
provide: NG_VALUE_ACCESSOR,
|
|
4760
|
-
useExisting: forwardRef(() => InputCurrencyComponent),
|
|
4761
|
-
multi: true
|
|
4762
|
-
}], changeDetection: ChangeDetectionStrategy.OnPush, styles: [":host{display:block;width:100%;min-width:0;box-sizing:border-box}.ptech-currency-container{display:flex;flex-direction:column;width:100%;box-sizing:border-box;min-width:0}.ptech-form-field{width:100%}:host ::ng-deep .ptech-form-field{--mat-form-field-container-height: var(--ptech-field-height, 56px);--mat-form-field-container-vertical-padding: var(--ptech-field-vertical-padding, 16px)}:host ::ng-deep .ptech-form-field .mdc-text-field{background-color:var(--ptech-field-bg, var(--app-surface, transparent));color:var(--ptech-field-text, var(--app-text, inherit));--mdc-outlined-text-field-outline-color: var(--ptech-field-outline, var(--app-border-color, rgba(0,0,0,.38)));--mdc-outlined-text-field-hover-outline-color: var(--ptech-field-outline-hover, var(--app-text, rgba(0,0,0,.87)));--mdc-outlined-text-field-focus-outline-color: var(--ptech-field-outline-focus, var(--app-text, #3f51b5))}:host ::ng-deep .ptech-form-field .mdc-text-field .mdc-notched-outline__leading,:host ::ng-deep .ptech-form-field .mdc-text-field .mdc-notched-outline__notch,:host ::ng-deep .ptech-form-field .mdc-text-field .mdc-notched-outline__trailing{border-color:var(--ptech-field-outline, var(--app-border-color, rgba(0,0,0,.38)))!important}:host ::ng-deep .ptech-form-field .mdc-text-field.mdc-text-field--hover .mdc-notched-outline__leading,:host ::ng-deep .ptech-form-field .mdc-text-field.mdc-text-field--hover .mdc-notched-outline__notch,:host ::ng-deep .ptech-form-field .mdc-text-field.mdc-text-field--hover .mdc-notched-outline__trailing{border-color:var(--ptech-field-outline-hover, var(--app-text, rgba(0,0,0,.87)))!important}:host ::ng-deep .ptech-form-field .mdc-text-field.mdc-text-field--focused .mdc-notched-outline__leading,:host ::ng-deep .ptech-form-field .mdc-text-field.mdc-text-field--focused .mdc-notched-outline__notch,:host ::ng-deep .ptech-form-field .mdc-text-field.mdc-text-field--focused .mdc-notched-outline__trailing{border-color:var(--ptech-field-outline-focus, var(--app-text, #3f51b5))!important}:host ::ng-deep .ptech-form-field .mat-mdc-input-element,:host ::ng-deep .ptech-form-field .mdc-text-field__input{color:var(--ptech-field-text, var(--app-text, inherit))!important;caret-color:var(--ptech-field-text, var(--app-text, inherit))!important}:host ::ng-deep .ptech-form-field input::placeholder,:host ::ng-deep .ptech-form-field textarea::placeholder,:host ::ng-deep .ptech-form-field .mat-mdc-input-element::placeholder,:host ::ng-deep .ptech-form-field .mdc-text-field__input::placeholder{color:var(--ptech-field-placeholder, var(--app-text, inherit))!important}:host ::ng-deep .ptech-form-field .mdc-floating-label,:host ::ng-deep .ptech-form-field .mdc-floating-label--float-above{color:var(--ptech-field-label, var(--app-text, inherit))!important}mat-label span{color:var(--ptech-required-color, var(--app-status-error, #f44336))!important}:host ::ng-deep .ptech-form-field.mat-form-field-disabled .mdc-text-field__input,:host ::ng-deep .ptech-form-field.mat-form-field-disabled .mat-mdc-input-element,:host ::ng-deep .ptech-form-field.mat-form-field-disabled .mdc-floating-label{color:var(--ptech-field-disabled, var(--app-muted, rgba(0,0,0,.38)))!important;-webkit-text-fill-color:var(--ptech-field-disabled, var(--app-muted, rgba(0,0,0,.38)))!important}:host ::ng-deep .ptech-form-field.mat-form-field-disabled .mdc-notched-outline__leading,:host ::ng-deep .ptech-form-field.mat-form-field-disabled .mdc-notched-outline__notch,:host ::ng-deep .ptech-form-field.mat-form-field-disabled .mdc-notched-outline__trailing{border-color:var(--ptech-field-disabled, var(--app-border-color, rgba(0,0,0,.24)))!important}:host ::ng-deep .ptech-form-field .mat-mdc-form-field-hint{color:var(--ptech-field-hint, var(--app-muted, rgba(0,0,0,.6)))!important}:host ::ng-deep .ptech-form-field .mat-mdc-form-field-error{color:var(--ptech-field-error, var(--app-status-error, #f44336))!important}:host ::ng-deep .ptech-form-field.mat-form-field-invalid .mdc-notched-outline__leading,:host ::ng-deep .ptech-form-field.mat-form-field-invalid .mdc-notched-outline__notch,:host ::ng-deep .ptech-form-field.mat-form-field-invalid .mdc-notched-outline__trailing{border-color:var(--ptech-field-error, var(--app-status-error, #f44336))!important}\n"] }]
|
|
4763
|
-
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { options: [{
|
|
4764
|
-
type: Input
|
|
4765
|
-
}], valueChange: [{
|
|
4766
|
-
type: Output
|
|
4767
|
-
}] } });
|
|
4861
|
+
::ng-deep .cdk-overlay-pane .mat-mdc-tooltip-panel {
|
|
4862
|
+
z-index: var(--ptech-tooltip-z-index, 11000) !important;
|
|
4863
|
+
}
|
|
4768
4864
|
|
|
4769
|
-
|
|
4770
|
-
|
|
4771
|
-
|
|
4772
|
-
|
|
4773
|
-
|
|
4774
|
-
}
|
|
4775
|
-
|
|
4776
|
-
|
|
4777
|
-
|
|
4778
|
-
|
|
4779
|
-
|
|
4780
|
-
}
|
|
4781
|
-
}
|
|
4782
|
-
|
|
4865
|
+
@media (max-width: 700px) {
|
|
4866
|
+
.ptech-dialog-shell {
|
|
4867
|
+
max-width: 94vw !important;
|
|
4868
|
+
max-height: calc(100dvh - 18px) !important;
|
|
4869
|
+
margin: 0 auto !important;
|
|
4870
|
+
}
|
|
4871
|
+
|
|
4872
|
+
::ng-deep .cdk-overlay-pane.ptech-dialog-panel {
|
|
4873
|
+
max-width: 96vw !important;
|
|
4874
|
+
max-height: calc(100dvh - 8px) !important;
|
|
4875
|
+
padding: 0 !important;
|
|
4876
|
+
}
|
|
4877
|
+
}
|
|
4878
|
+
`;
|
|
4783
4879
|
|
|
4784
4880
|
class ActionDialogComponent {
|
|
4785
4881
|
data;
|
|
@@ -5350,11 +5446,11 @@ class AlertComponent {
|
|
|
5350
5446
|
});
|
|
5351
5447
|
}
|
|
5352
5448
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: AlertComponent, deps: [{ token: MAT_SNACK_BAR_DATA }, { token: i1$4.MatSnackBarRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
5353
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.16", type: AlertComponent, isStandalone: true, selector: "ptech-alert", ngImport: i0, template: "<div class=\"alert\" [ngClass]=\"data.type\" role=\"alert\">\n <mat-icon\n *ngIf=\"data.icon\"\n class=\"icon\"\n [ngStyle]=\"{ color: getIconColor(data.type) }\"\n >{{ data.icon }}</mat-icon\n >\n <div class=\"text-content\">\n <div class=\"title\">\n {{ data.title }}\n </div>\n <span class=\"text-content-date-hour\">{{\n data.timestamp | date : \"dd/MM/yyyy HH:mm:ss\"\n }}</span>\n <span>{{ data.message }}</span>\n <span *ngFor=\"let detail of data.details\">{{ detail }}</span>\n </div>\n\n <button mat-icon-button class=\"close-button\" (click)=\"closeSnackbar()\">\n <mat-icon>close</mat-icon>\n </button>\n</div>\n", styles: [".alert{position:relative;display:flex;align-items:center;justify-content:space-between;background:var(--ptech-alert-bg, var(--app-surface, #fff));border-radius:3px;padding:30px;border-left:5px solid var(--ptech-alert-border, var(--app-border-color, #ddd));box-shadow:var(--ptech-alert-shadow, 0 2px 7px rgba(0, 0, 0, .27));max-width:350px}.close-button{position:relative;bottom:30px;left:15px;margin:0;padding:0;color:var(--ptech-alert-close, var(--app-muted, #aaa));border:none;background:none;cursor:pointer}.close-button mat-icon{font-size:26px!important;margin-top:10px!important;margin-left:-3px!important}.alert mat-icon{height:35px;width:55px;font-size:35px;display:contents}.text-content{margin-left:10px!important;display:flex;flex-direction:column}.text-content-date-hour{margin-left:0!important;margin-bottom:10px}.title{font-family:Roboto,Nunito,Helvetica Neue,sans-serif;font-size:16px;color:var(--ptech-alert-title, var(--app-text, #606267));font-weight:600;margin-bottom:3px}span{font-family:Roboto,Nunito,Helvetica Neue,sans-serif;font-size:14px;color:var(--ptech-alert-text, var(--app-muted, #9ea0a9));font-weight:400}.success{border-left-color:var(--ptech-alert-success, var(--app-status-success, #7fcb78))}.error{border-left-color:var(--ptech-alert-error, var(--app-status-error, #f25158))}.warn{border-left-color:var(--ptech-alert-warn, var(--app-status-warning, #f0c943))}.info{border-left-color:var(--ptech-alert-info, var(--app-link-accent, #2c80d2))}
|
|
5449
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.16", type: AlertComponent, isStandalone: true, selector: "ptech-alert", ngImport: i0, template: "<div class=\"alert\" [ngClass]=\"data.type\" role=\"alert\">\n <mat-icon\n *ngIf=\"data.icon\"\n class=\"icon\"\n [ngStyle]=\"{ color: getIconColor(data.type) }\"\n >{{ data.icon }}</mat-icon\n >\n <div class=\"text-content\">\n <div class=\"title\">\n {{ data.title }}\n </div>\n <span class=\"text-content-date-hour\">{{\n data.timestamp | date : \"dd/MM/yyyy HH:mm:ss\"\n }}</span>\n <span>{{ data.message }}</span>\n <span *ngFor=\"let detail of data.details\">{{ detail }}</span>\n </div>\n\n <button mat-icon-button class=\"close-button\" (click)=\"closeSnackbar()\">\n <mat-icon>close</mat-icon>\n </button>\n</div>\n", styles: [".alert{position:relative;display:flex;align-items:center;justify-content:space-between;background:var(--ptech-alert-bg, var(--app-surface, #fff));border-radius:3px;padding:30px;border-left:5px solid var(--ptech-alert-border, var(--app-border-color, #ddd));box-shadow:var(--ptech-alert-shadow, 0 2px 7px rgba(0, 0, 0, .27));max-width:350px}.close-button{position:relative;bottom:30px;left:15px;margin:0;padding:0;color:var(--ptech-alert-close, var(--app-muted, #aaa));border:none;background:none;cursor:pointer}.close-button mat-icon{font-size:26px!important;margin-top:10px!important;margin-left:-3px!important}.alert mat-icon{height:35px;width:55px;font-size:35px;display:contents}.text-content{margin-left:10px!important;display:flex;flex-direction:column}.text-content-date-hour{margin-left:0!important;margin-bottom:10px}.title{font-family:Roboto,Nunito,Helvetica Neue,sans-serif;font-size:16px;color:var(--ptech-alert-title, var(--app-text, #606267));font-weight:600;margin-bottom:3px}span{font-family:Roboto,Nunito,Helvetica Neue,sans-serif;font-size:14px;color:var(--ptech-alert-text, var(--app-muted, #9ea0a9));font-weight:400}.success{border-left-color:var(--ptech-alert-success, var(--app-status-success, #7fcb78))}.error{border-left-color:var(--ptech-alert-error, var(--app-status-error, #f25158))}.warn{border-left-color:var(--ptech-alert-warn, var(--app-status-warning, #f0c943))}.info{border-left-color:var(--ptech-alert-info, var(--app-link-accent, #2c80d2))}::ng-deep .mat-mdc-snack-bar-container.ptech-snackbar{z-index:var(--ptech-snackbar-z-index, 12000)!important}::ng-deep .mat-mdc-snack-bar-container.ptech-snackbar .mdc-snackbar__surface{background:transparent!important;box-shadow:none!important;padding:0!important;min-height:unset!important;min-width:unset!important;border-radius:0!important}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3$1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i2$1.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "pipe", type: i1$1.DatePipe, name: "date" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
5354
5450
|
}
|
|
5355
5451
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: AlertComponent, decorators: [{
|
|
5356
5452
|
type: Component,
|
|
5357
|
-
args: [{ selector: 'ptech-alert', imports: [CommonModule, MatIconModule, MatButtonModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"alert\" [ngClass]=\"data.type\" role=\"alert\">\n <mat-icon\n *ngIf=\"data.icon\"\n class=\"icon\"\n [ngStyle]=\"{ color: getIconColor(data.type) }\"\n >{{ data.icon }}</mat-icon\n >\n <div class=\"text-content\">\n <div class=\"title\">\n {{ data.title }}\n </div>\n <span class=\"text-content-date-hour\">{{\n data.timestamp | date : \"dd/MM/yyyy HH:mm:ss\"\n }}</span>\n <span>{{ data.message }}</span>\n <span *ngFor=\"let detail of data.details\">{{ detail }}</span>\n </div>\n\n <button mat-icon-button class=\"close-button\" (click)=\"closeSnackbar()\">\n <mat-icon>close</mat-icon>\n </button>\n</div>\n", styles: [".alert{position:relative;display:flex;align-items:center;justify-content:space-between;background:var(--ptech-alert-bg, var(--app-surface, #fff));border-radius:3px;padding:30px;border-left:5px solid var(--ptech-alert-border, var(--app-border-color, #ddd));box-shadow:var(--ptech-alert-shadow, 0 2px 7px rgba(0, 0, 0, .27));max-width:350px}.close-button{position:relative;bottom:30px;left:15px;margin:0;padding:0;color:var(--ptech-alert-close, var(--app-muted, #aaa));border:none;background:none;cursor:pointer}.close-button mat-icon{font-size:26px!important;margin-top:10px!important;margin-left:-3px!important}.alert mat-icon{height:35px;width:55px;font-size:35px;display:contents}.text-content{margin-left:10px!important;display:flex;flex-direction:column}.text-content-date-hour{margin-left:0!important;margin-bottom:10px}.title{font-family:Roboto,Nunito,Helvetica Neue,sans-serif;font-size:16px;color:var(--ptech-alert-title, var(--app-text, #606267));font-weight:600;margin-bottom:3px}span{font-family:Roboto,Nunito,Helvetica Neue,sans-serif;font-size:14px;color:var(--ptech-alert-text, var(--app-muted, #9ea0a9));font-weight:400}.success{border-left-color:var(--ptech-alert-success, var(--app-status-success, #7fcb78))}.error{border-left-color:var(--ptech-alert-error, var(--app-status-error, #f25158))}.warn{border-left-color:var(--ptech-alert-warn, var(--app-status-warning, #f0c943))}.info{border-left-color:var(--ptech-alert-info, var(--app-link-accent, #2c80d2))}
|
|
5453
|
+
args: [{ selector: 'ptech-alert', imports: [CommonModule, MatIconModule, MatButtonModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"alert\" [ngClass]=\"data.type\" role=\"alert\">\n <mat-icon\n *ngIf=\"data.icon\"\n class=\"icon\"\n [ngStyle]=\"{ color: getIconColor(data.type) }\"\n >{{ data.icon }}</mat-icon\n >\n <div class=\"text-content\">\n <div class=\"title\">\n {{ data.title }}\n </div>\n <span class=\"text-content-date-hour\">{{\n data.timestamp | date : \"dd/MM/yyyy HH:mm:ss\"\n }}</span>\n <span>{{ data.message }}</span>\n <span *ngFor=\"let detail of data.details\">{{ detail }}</span>\n </div>\n\n <button mat-icon-button class=\"close-button\" (click)=\"closeSnackbar()\">\n <mat-icon>close</mat-icon>\n </button>\n</div>\n", styles: [".alert{position:relative;display:flex;align-items:center;justify-content:space-between;background:var(--ptech-alert-bg, var(--app-surface, #fff));border-radius:3px;padding:30px;border-left:5px solid var(--ptech-alert-border, var(--app-border-color, #ddd));box-shadow:var(--ptech-alert-shadow, 0 2px 7px rgba(0, 0, 0, .27));max-width:350px}.close-button{position:relative;bottom:30px;left:15px;margin:0;padding:0;color:var(--ptech-alert-close, var(--app-muted, #aaa));border:none;background:none;cursor:pointer}.close-button mat-icon{font-size:26px!important;margin-top:10px!important;margin-left:-3px!important}.alert mat-icon{height:35px;width:55px;font-size:35px;display:contents}.text-content{margin-left:10px!important;display:flex;flex-direction:column}.text-content-date-hour{margin-left:0!important;margin-bottom:10px}.title{font-family:Roboto,Nunito,Helvetica Neue,sans-serif;font-size:16px;color:var(--ptech-alert-title, var(--app-text, #606267));font-weight:600;margin-bottom:3px}span{font-family:Roboto,Nunito,Helvetica Neue,sans-serif;font-size:14px;color:var(--ptech-alert-text, var(--app-muted, #9ea0a9));font-weight:400}.success{border-left-color:var(--ptech-alert-success, var(--app-status-success, #7fcb78))}.error{border-left-color:var(--ptech-alert-error, var(--app-status-error, #f25158))}.warn{border-left-color:var(--ptech-alert-warn, var(--app-status-warning, #f0c943))}.info{border-left-color:var(--ptech-alert-info, var(--app-link-accent, #2c80d2))}::ng-deep .mat-mdc-snack-bar-container.ptech-snackbar{z-index:var(--ptech-snackbar-z-index, 12000)!important}::ng-deep .mat-mdc-snack-bar-container.ptech-snackbar .mdc-snackbar__surface{background:transparent!important;box-shadow:none!important;padding:0!important;min-height:unset!important;min-width:unset!important;border-radius:0!important}\n"] }]
|
|
5358
5454
|
}], ctorParameters: () => [{ type: undefined, decorators: [{
|
|
5359
5455
|
type: Inject,
|
|
5360
5456
|
args: [MAT_SNACK_BAR_DATA]
|
|
@@ -8113,108 +8209,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
|
|
|
8113
8209
|
type: Output
|
|
8114
8210
|
}] } });
|
|
8115
8211
|
|
|
8116
|
-
class DialogShellComponent {
|
|
8117
|
-
title = '';
|
|
8118
|
-
subtitle;
|
|
8119
|
-
draggable = true;
|
|
8120
|
-
showDrag = true;
|
|
8121
|
-
showClose = true;
|
|
8122
|
-
dragRootElement = '.cdk-overlay-pane';
|
|
8123
|
-
close = new EventEmitter();
|
|
8124
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: DialogShellComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
8125
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.16", type: DialogShellComponent, isStandalone: true, selector: "ptech-dialog-shell", inputs: { title: "title", subtitle: "subtitle", draggable: "draggable", showDrag: "showDrag", showClose: "showClose", dragRootElement: "dragRootElement" }, outputs: { close: "close" }, ngImport: i0, template: `
|
|
8126
|
-
<div
|
|
8127
|
-
class="ptech-dialog-shell"
|
|
8128
|
-
cdkDrag
|
|
8129
|
-
[cdkDragDisabled]="!draggable"
|
|
8130
|
-
[cdkDragRootElement]="dragRootElement"
|
|
8131
|
-
>
|
|
8132
|
-
<div class="ptech-dialog-header">
|
|
8133
|
-
<div class="ptech-dialog-drag" *ngIf="showDrag" cdkDragHandle aria-hidden="true">
|
|
8134
|
-
<mat-icon>drag_indicator</mat-icon>
|
|
8135
|
-
</div>
|
|
8136
|
-
<div class="ptech-dialog-drag ptech-dialog-drag--spacer" *ngIf="!showDrag" aria-hidden="true"></div>
|
|
8137
|
-
|
|
8138
|
-
<div class="ptech-dialog-heading">
|
|
8139
|
-
<h2 mat-dialog-title>{{ title }}</h2>
|
|
8140
|
-
<p class="ptech-dialog-subtitle" *ngIf="subtitle">{{ subtitle }}</p>
|
|
8141
|
-
</div>
|
|
8142
|
-
|
|
8143
|
-
<button
|
|
8144
|
-
*ngIf="showClose"
|
|
8145
|
-
type="button"
|
|
8146
|
-
class="ptech-dialog-close"
|
|
8147
|
-
aria-label="Fechar"
|
|
8148
|
-
(click)="close.emit()"
|
|
8149
|
-
>
|
|
8150
|
-
<mat-icon>close</mat-icon>
|
|
8151
|
-
</button>
|
|
8152
|
-
<div *ngIf="!showClose" class="ptech-dialog-drag ptech-dialog-drag--spacer" aria-hidden="true"></div>
|
|
8153
|
-
</div>
|
|
8154
|
-
|
|
8155
|
-
<div class="ptech-dialog-divider"></div>
|
|
8156
|
-
|
|
8157
|
-
<div class="ptech-dialog-content">
|
|
8158
|
-
<ng-content></ng-content>
|
|
8159
|
-
</div>
|
|
8160
|
-
</div>
|
|
8161
|
-
`, isInline: true, styles: [":host{display:block;color:var(--ptech-dialog-text, var(--app-text, inherit))}.ptech-dialog-shell{display:flex;flex-direction:column;max-width:92vw;width:100%;max-height:88vh;min-height:0;background:var(--ptech-dialog-bg, var(--app-surface, #fff));color:var(--ptech-dialog-text, var(--app-text, inherit));border-radius:16px;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));overflow:hidden}.ptech-dialog-header{display:grid;grid-template-columns:52px 1fr 52px;align-items:center;gap:12px;padding:14px 16px;background:var(--ptech-dialog-header-bg, var(--app-surface-2, #f7f7f7));flex:0 0 auto}.ptech-dialog-drag{width:42px;height:42px;border-radius:12px;display:inline-flex;align-items:center;justify-content:center;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));color:var(--ptech-dialog-muted, var(--app-muted, #94a3b8));background:color-mix(in srgb,var(--app-surface, #fff) 92%,transparent)}.ptech-dialog-heading h1[mat-dialog-title],.ptech-dialog-heading h2[mat-dialog-title]{margin:0;line-height:1.2;font-weight:700;color:var(--ptech-dialog-text, var(--app-text, inherit));text-align:center}.ptech-dialog-heading{text-align:center;justify-self:center;width:100%}.ptech-dialog-subtitle{margin:2px 0 0;color:var(--ptech-dialog-muted, var(--app-muted, #94a3b8));font-size:1rem;font-weight:500}.ptech-dialog-close{width:42px;height:42px;border-radius:12px;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));color:var(--ptech-dialog-text, var(--app-text, inherit));background:color-mix(in srgb,var(--app-surface, #fff) 92%,transparent);display:inline-flex;align-items:center;justify-content:center;padding:0!important}.ptech-dialog-close .mat-icon{margin:0;width:26px;height:26px;font-size:26px;line-height:26px}.ptech-dialog-divider{border-top:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)))}.ptech-dialog-content{flex:1 1 auto;min-height:0;max-height:none;overflow-y:auto;overflow-x:hidden;padding:16px;box-sizing:border-box;color:var(--ptech-dialog-content-text, var(--ptech-dialog-text, var(--app-text, inherit)))}.ptech-dialog-content::-webkit-scrollbar{width:10px;height:10px}.ptech-dialog-content::-webkit-scrollbar-track{background:var(--ptech-scroll-track, var(--app-scroll-track, color-mix(in srgb, var(--app-surface-2, #f7f7f7) 70%, transparent)));border-radius:12px}.ptech-dialog-content::-webkit-scrollbar-thumb{background:var(--ptech-scroll-thumb, var(--app-scroll-thumb, color-mix(in srgb, var(--app-link-accent, #3b82f6) 70%, #6b7280 30%)));border-radius:12px;border:2px solid transparent;background-clip:padding-box}.ptech-dialog-content::-webkit-scrollbar-thumb:hover{background:var(--ptech-scroll-thumb-hover, var(--app-scroll-thumb-hover, var(--ptech-scroll-thumb, #60a5fa)))}.ptech-dialog-content{scrollbar-width:thin;scrollbar-color:var(--ptech-scroll-thumb, var(--app-scroll-thumb, #60a5fa)) var(--ptech-scroll-track, var(--app-scroll-track, #1f2937))}::ng-deep .ptech-dialog-panel .mat-mdc-dialog-surface{background:transparent!important;box-shadow:none!important;color:inherit;overflow:visible;border-radius:16px;padding:0;max-height:none!important}::ng-deep .cdk-overlay-pane.ptech-dialog-panel{display:flex!important;align-items:center!important;justify-content:center!important;max-width:96vw!important;max-height:96dvh!important;margin:0 auto!important}::ng-deep .cdk-overlay-pane .mat-mdc-tooltip-panel{z-index:var(--ptech-tooltip-z-index, 11000)!important}\n", ".ptech-dialog-drag--spacer{border-color:transparent!important;background:transparent!important}@media (max-width: 700px){.ptech-dialog-shell{max-width:94vw!important;max-height:calc(100dvh - 18px)!important;margin:0 auto!important}::ng-deep .cdk-overlay-pane.ptech-dialog-panel{max-width:96vw!important;max-height:calc(100dvh - 8px)!important;padding:0!important}}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer", "cdkDragScale"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3$1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }] });
|
|
8162
|
-
}
|
|
8163
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: DialogShellComponent, decorators: [{
|
|
8164
|
-
type: Component,
|
|
8165
|
-
args: [{ selector: 'ptech-dialog-shell', standalone: true, imports: [NgIf, CdkDrag, CdkDragHandle, MatIconModule], template: `
|
|
8166
|
-
<div
|
|
8167
|
-
class="ptech-dialog-shell"
|
|
8168
|
-
cdkDrag
|
|
8169
|
-
[cdkDragDisabled]="!draggable"
|
|
8170
|
-
[cdkDragRootElement]="dragRootElement"
|
|
8171
|
-
>
|
|
8172
|
-
<div class="ptech-dialog-header">
|
|
8173
|
-
<div class="ptech-dialog-drag" *ngIf="showDrag" cdkDragHandle aria-hidden="true">
|
|
8174
|
-
<mat-icon>drag_indicator</mat-icon>
|
|
8175
|
-
</div>
|
|
8176
|
-
<div class="ptech-dialog-drag ptech-dialog-drag--spacer" *ngIf="!showDrag" aria-hidden="true"></div>
|
|
8177
|
-
|
|
8178
|
-
<div class="ptech-dialog-heading">
|
|
8179
|
-
<h2 mat-dialog-title>{{ title }}</h2>
|
|
8180
|
-
<p class="ptech-dialog-subtitle" *ngIf="subtitle">{{ subtitle }}</p>
|
|
8181
|
-
</div>
|
|
8182
|
-
|
|
8183
|
-
<button
|
|
8184
|
-
*ngIf="showClose"
|
|
8185
|
-
type="button"
|
|
8186
|
-
class="ptech-dialog-close"
|
|
8187
|
-
aria-label="Fechar"
|
|
8188
|
-
(click)="close.emit()"
|
|
8189
|
-
>
|
|
8190
|
-
<mat-icon>close</mat-icon>
|
|
8191
|
-
</button>
|
|
8192
|
-
<div *ngIf="!showClose" class="ptech-dialog-drag ptech-dialog-drag--spacer" aria-hidden="true"></div>
|
|
8193
|
-
</div>
|
|
8194
|
-
|
|
8195
|
-
<div class="ptech-dialog-divider"></div>
|
|
8196
|
-
|
|
8197
|
-
<div class="ptech-dialog-content">
|
|
8198
|
-
<ng-content></ng-content>
|
|
8199
|
-
</div>
|
|
8200
|
-
</div>
|
|
8201
|
-
`, styles: [":host{display:block;color:var(--ptech-dialog-text, var(--app-text, inherit))}.ptech-dialog-shell{display:flex;flex-direction:column;max-width:92vw;width:100%;max-height:88vh;min-height:0;background:var(--ptech-dialog-bg, var(--app-surface, #fff));color:var(--ptech-dialog-text, var(--app-text, inherit));border-radius:16px;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));overflow:hidden}.ptech-dialog-header{display:grid;grid-template-columns:52px 1fr 52px;align-items:center;gap:12px;padding:14px 16px;background:var(--ptech-dialog-header-bg, var(--app-surface-2, #f7f7f7));flex:0 0 auto}.ptech-dialog-drag{width:42px;height:42px;border-radius:12px;display:inline-flex;align-items:center;justify-content:center;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));color:var(--ptech-dialog-muted, var(--app-muted, #94a3b8));background:color-mix(in srgb,var(--app-surface, #fff) 92%,transparent)}.ptech-dialog-heading h1[mat-dialog-title],.ptech-dialog-heading h2[mat-dialog-title]{margin:0;line-height:1.2;font-weight:700;color:var(--ptech-dialog-text, var(--app-text, inherit));text-align:center}.ptech-dialog-heading{text-align:center;justify-self:center;width:100%}.ptech-dialog-subtitle{margin:2px 0 0;color:var(--ptech-dialog-muted, var(--app-muted, #94a3b8));font-size:1rem;font-weight:500}.ptech-dialog-close{width:42px;height:42px;border-radius:12px;border:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)));color:var(--ptech-dialog-text, var(--app-text, inherit));background:color-mix(in srgb,var(--app-surface, #fff) 92%,transparent);display:inline-flex;align-items:center;justify-content:center;padding:0!important}.ptech-dialog-close .mat-icon{margin:0;width:26px;height:26px;font-size:26px;line-height:26px}.ptech-dialog-divider{border-top:1px solid var(--ptech-dialog-border, var(--app-border-color, rgba(0, 0, 0, .12)))}.ptech-dialog-content{flex:1 1 auto;min-height:0;max-height:none;overflow-y:auto;overflow-x:hidden;padding:16px;box-sizing:border-box;color:var(--ptech-dialog-content-text, var(--ptech-dialog-text, var(--app-text, inherit)))}.ptech-dialog-content::-webkit-scrollbar{width:10px;height:10px}.ptech-dialog-content::-webkit-scrollbar-track{background:var(--ptech-scroll-track, var(--app-scroll-track, color-mix(in srgb, var(--app-surface-2, #f7f7f7) 70%, transparent)));border-radius:12px}.ptech-dialog-content::-webkit-scrollbar-thumb{background:var(--ptech-scroll-thumb, var(--app-scroll-thumb, color-mix(in srgb, var(--app-link-accent, #3b82f6) 70%, #6b7280 30%)));border-radius:12px;border:2px solid transparent;background-clip:padding-box}.ptech-dialog-content::-webkit-scrollbar-thumb:hover{background:var(--ptech-scroll-thumb-hover, var(--app-scroll-thumb-hover, var(--ptech-scroll-thumb, #60a5fa)))}.ptech-dialog-content{scrollbar-width:thin;scrollbar-color:var(--ptech-scroll-thumb, var(--app-scroll-thumb, #60a5fa)) var(--ptech-scroll-track, var(--app-scroll-track, #1f2937))}::ng-deep .ptech-dialog-panel .mat-mdc-dialog-surface{background:transparent!important;box-shadow:none!important;color:inherit;overflow:visible;border-radius:16px;padding:0;max-height:none!important}::ng-deep .cdk-overlay-pane.ptech-dialog-panel{display:flex!important;align-items:center!important;justify-content:center!important;max-width:96vw!important;max-height:96dvh!important;margin:0 auto!important}::ng-deep .cdk-overlay-pane .mat-mdc-tooltip-panel{z-index:var(--ptech-tooltip-z-index, 11000)!important}\n", ".ptech-dialog-drag--spacer{border-color:transparent!important;background:transparent!important}@media (max-width: 700px){.ptech-dialog-shell{max-width:94vw!important;max-height:calc(100dvh - 18px)!important;margin:0 auto!important}::ng-deep .cdk-overlay-pane.ptech-dialog-panel{max-width:96vw!important;max-height:calc(100dvh - 8px)!important;padding:0!important}}\n"] }]
|
|
8202
|
-
}], propDecorators: { title: [{
|
|
8203
|
-
type: Input
|
|
8204
|
-
}], subtitle: [{
|
|
8205
|
-
type: Input
|
|
8206
|
-
}], draggable: [{
|
|
8207
|
-
type: Input
|
|
8208
|
-
}], showDrag: [{
|
|
8209
|
-
type: Input
|
|
8210
|
-
}], showClose: [{
|
|
8211
|
-
type: Input
|
|
8212
|
-
}], dragRootElement: [{
|
|
8213
|
-
type: Input
|
|
8214
|
-
}], close: [{
|
|
8215
|
-
type: Output
|
|
8216
|
-
}] } });
|
|
8217
|
-
|
|
8218
8212
|
class CardComponent {
|
|
8219
8213
|
title = '';
|
|
8220
8214
|
subtitle = '';
|
|
@@ -9965,6 +9959,99 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
|
|
|
9965
9959
|
type: Output
|
|
9966
9960
|
}] } });
|
|
9967
9961
|
|
|
9962
|
+
/**
|
|
9963
|
+
* Renders a local clock for a given IANA zone id - purely presentational, no business rule.
|
|
9964
|
+
* It does not know what a "user" or a "preference" is: the consuming app is responsible for
|
|
9965
|
+
* resolving zoneId (from wherever its own domain keeps it) and passing it in as a plain input.
|
|
9966
|
+
* Ticks its own internal timer (1s if seconds are shown, 30s otherwise) so it works standalone
|
|
9967
|
+
* with zero external services - OnPush requires an explicit markForCheck() on each tick since
|
|
9968
|
+
* the update originates outside any zone-triggered template event.
|
|
9969
|
+
*/
|
|
9970
|
+
class PtechTimezoneClockComponent {
|
|
9971
|
+
cdr;
|
|
9972
|
+
zoneId = null;
|
|
9973
|
+
compact = false;
|
|
9974
|
+
showTimezone = true;
|
|
9975
|
+
showSeconds = false;
|
|
9976
|
+
time = '';
|
|
9977
|
+
tickSubscription;
|
|
9978
|
+
constructor(cdr) {
|
|
9979
|
+
this.cdr = cdr;
|
|
9980
|
+
}
|
|
9981
|
+
ngOnInit() {
|
|
9982
|
+
this.startTicking();
|
|
9983
|
+
}
|
|
9984
|
+
ngOnChanges(changes) {
|
|
9985
|
+
if (changes['zoneId'] || changes['showSeconds']) {
|
|
9986
|
+
this.tick();
|
|
9987
|
+
if (changes['showSeconds'] && !changes['showSeconds'].firstChange) {
|
|
9988
|
+
this.startTicking();
|
|
9989
|
+
}
|
|
9990
|
+
}
|
|
9991
|
+
}
|
|
9992
|
+
ngOnDestroy() {
|
|
9993
|
+
this.tickSubscription?.unsubscribe();
|
|
9994
|
+
}
|
|
9995
|
+
startTicking() {
|
|
9996
|
+
this.tickSubscription?.unsubscribe();
|
|
9997
|
+
this.tick();
|
|
9998
|
+
this.tickSubscription = interval(this.showSeconds ? 1000 : 30000).subscribe(() => this.tick());
|
|
9999
|
+
}
|
|
10000
|
+
tick() {
|
|
10001
|
+
if (!this.zoneId) {
|
|
10002
|
+
this.time = '';
|
|
10003
|
+
this.cdr.markForCheck();
|
|
10004
|
+
return;
|
|
10005
|
+
}
|
|
10006
|
+
try {
|
|
10007
|
+
this.time = new Intl.DateTimeFormat('pt-BR', {
|
|
10008
|
+
timeZone: this.zoneId,
|
|
10009
|
+
hour: '2-digit',
|
|
10010
|
+
minute: '2-digit',
|
|
10011
|
+
second: this.showSeconds ? '2-digit' : undefined,
|
|
10012
|
+
}).format(new Date());
|
|
10013
|
+
}
|
|
10014
|
+
catch {
|
|
10015
|
+
this.time = '';
|
|
10016
|
+
}
|
|
10017
|
+
this.cdr.markForCheck();
|
|
10018
|
+
}
|
|
10019
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PtechTimezoneClockComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
10020
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.16", type: PtechTimezoneClockComponent, isStandalone: true, selector: "ptech-timezone-clock", inputs: { zoneId: "zoneId", compact: "compact", showTimezone: "showTimezone", showSeconds: "showSeconds" }, usesOnChanges: true, ngImport: i0, template: `
|
|
10021
|
+
<span
|
|
10022
|
+
class="ptech-timezone-clock"
|
|
10023
|
+
[class.compact]="compact"
|
|
10024
|
+
*ngIf="zoneId"
|
|
10025
|
+
[title]="showTimezone ? zoneId : ''"
|
|
10026
|
+
>
|
|
10027
|
+
<span class="ptech-timezone-clock-time">{{ time }}</span>
|
|
10028
|
+
<span class="ptech-timezone-clock-zone" *ngIf="showTimezone"> — {{ zoneId }}</span>
|
|
10029
|
+
</span>
|
|
10030
|
+
`, isInline: true, styles: [".ptech-timezone-clock{font-size:var(--ptech-timezone-clock-font-size, 12px);color:var(--ptech-timezone-clock-color, inherit);opacity:var(--ptech-timezone-clock-opacity, .85);white-space:nowrap;font-variant-numeric:tabular-nums}@media (max-width: 599.98px){.ptech-timezone-clock.compact .ptech-timezone-clock-zone{display:none}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
10031
|
+
}
|
|
10032
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PtechTimezoneClockComponent, decorators: [{
|
|
10033
|
+
type: Component,
|
|
10034
|
+
args: [{ selector: 'ptech-timezone-clock', standalone: true, imports: [CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, template: `
|
|
10035
|
+
<span
|
|
10036
|
+
class="ptech-timezone-clock"
|
|
10037
|
+
[class.compact]="compact"
|
|
10038
|
+
*ngIf="zoneId"
|
|
10039
|
+
[title]="showTimezone ? zoneId : ''"
|
|
10040
|
+
>
|
|
10041
|
+
<span class="ptech-timezone-clock-time">{{ time }}</span>
|
|
10042
|
+
<span class="ptech-timezone-clock-zone" *ngIf="showTimezone"> — {{ zoneId }}</span>
|
|
10043
|
+
</span>
|
|
10044
|
+
`, styles: [".ptech-timezone-clock{font-size:var(--ptech-timezone-clock-font-size, 12px);color:var(--ptech-timezone-clock-color, inherit);opacity:var(--ptech-timezone-clock-opacity, .85);white-space:nowrap;font-variant-numeric:tabular-nums}@media (max-width: 599.98px){.ptech-timezone-clock.compact .ptech-timezone-clock-zone{display:none}}\n"] }]
|
|
10045
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { zoneId: [{
|
|
10046
|
+
type: Input
|
|
10047
|
+
}], compact: [{
|
|
10048
|
+
type: Input
|
|
10049
|
+
}], showTimezone: [{
|
|
10050
|
+
type: Input
|
|
10051
|
+
}], showSeconds: [{
|
|
10052
|
+
type: Input
|
|
10053
|
+
}] } });
|
|
10054
|
+
|
|
9968
10055
|
class SnackbarMessageService {
|
|
9969
10056
|
snackBar;
|
|
9970
10057
|
constructor(snackBar) {
|
|
@@ -10012,6 +10099,17 @@ class SnackbarMessageService {
|
|
|
10012
10099
|
duration,
|
|
10013
10100
|
});
|
|
10014
10101
|
}
|
|
10102
|
+
infoMessage(title, message, details, timestamp, duration) {
|
|
10103
|
+
this.openSnackBar({
|
|
10104
|
+
title,
|
|
10105
|
+
message,
|
|
10106
|
+
details,
|
|
10107
|
+
icon: 'info',
|
|
10108
|
+
type: 'info',
|
|
10109
|
+
timestamp,
|
|
10110
|
+
duration,
|
|
10111
|
+
});
|
|
10112
|
+
}
|
|
10015
10113
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: SnackbarMessageService, deps: [{ token: i1$4.MatSnackBar }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
10016
10114
|
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: SnackbarMessageService });
|
|
10017
10115
|
}
|
|
@@ -10071,7 +10169,8 @@ class PumpkinTechModule {
|
|
|
10071
10169
|
PtechPopoverComponent,
|
|
10072
10170
|
PtechWidgetMenuComponent,
|
|
10073
10171
|
PtechCarouselComponent,
|
|
10074
|
-
PtechTimelineComponent
|
|
10172
|
+
PtechTimelineComponent,
|
|
10173
|
+
PtechTimezoneClockComponent], exports: [
|
|
10075
10174
|
// reexporta tudo junto
|
|
10076
10175
|
InputComponent,
|
|
10077
10176
|
TextareaComponent,
|
|
@@ -10120,6 +10219,7 @@ class PumpkinTechModule {
|
|
|
10120
10219
|
PtechWidgetMenuComponent,
|
|
10121
10220
|
PtechCarouselComponent,
|
|
10122
10221
|
PtechTimelineComponent,
|
|
10222
|
+
PtechTimezoneClockComponent,
|
|
10123
10223
|
CoreMaterialModule] });
|
|
10124
10224
|
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PumpkinTechModule, providers: [
|
|
10125
10225
|
{
|
|
@@ -10173,7 +10273,8 @@ class PumpkinTechModule {
|
|
|
10173
10273
|
PtechPopoverComponent,
|
|
10174
10274
|
PtechWidgetMenuComponent,
|
|
10175
10275
|
PtechCarouselComponent,
|
|
10176
|
-
PtechTimelineComponent,
|
|
10276
|
+
PtechTimelineComponent,
|
|
10277
|
+
PtechTimezoneClockComponent, CoreMaterialModule] });
|
|
10177
10278
|
}
|
|
10178
10279
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PumpkinTechModule, decorators: [{
|
|
10179
10280
|
type: NgModule,
|
|
@@ -10228,7 +10329,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
|
|
|
10228
10329
|
PtechPopoverComponent,
|
|
10229
10330
|
PtechWidgetMenuComponent,
|
|
10230
10331
|
PtechCarouselComponent,
|
|
10231
|
-
PtechTimelineComponent
|
|
10332
|
+
PtechTimelineComponent,
|
|
10333
|
+
PtechTimezoneClockComponent
|
|
10232
10334
|
],
|
|
10233
10335
|
exports: [
|
|
10234
10336
|
// reexporta tudo junto
|
|
@@ -10279,6 +10381,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
|
|
|
10279
10381
|
PtechWidgetMenuComponent,
|
|
10280
10382
|
PtechCarouselComponent,
|
|
10281
10383
|
PtechTimelineComponent,
|
|
10384
|
+
PtechTimezoneClockComponent,
|
|
10282
10385
|
CoreMaterialModule,
|
|
10283
10386
|
],
|
|
10284
10387
|
providers: [
|
|
@@ -11218,19 +11321,6 @@ class DialogService {
|
|
|
11218
11321
|
width,
|
|
11219
11322
|
});
|
|
11220
11323
|
}
|
|
11221
|
-
confirm(confirmation, width = '400px') {
|
|
11222
|
-
const ref = this.open({
|
|
11223
|
-
component: ConfirmationDialogComponent,
|
|
11224
|
-
data: confirmation,
|
|
11225
|
-
width,
|
|
11226
|
-
disableClose: true,
|
|
11227
|
-
});
|
|
11228
|
-
return ref.afterClosed().pipe(tap((isAccepted) => {
|
|
11229
|
-
if (isAccepted) {
|
|
11230
|
-
confirmation.accept();
|
|
11231
|
-
}
|
|
11232
|
-
}), map((isAccepted) => !!isAccepted));
|
|
11233
|
-
}
|
|
11234
11324
|
/**
|
|
11235
11325
|
* Abre um ActionDialog e, se houver resultado, usa o builder para criar
|
|
11236
11326
|
* o ActionResultData e abre o resultado.
|
|
@@ -11254,6 +11344,38 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
|
|
|
11254
11344
|
}]
|
|
11255
11345
|
}], ctorParameters: () => [{ type: i1$3.MatDialog }] });
|
|
11256
11346
|
|
|
11347
|
+
/**
|
|
11348
|
+
* The single entry point consuming apps use for a destructive/confirmation prompt - opens
|
|
11349
|
+
* PtechConfirmationDialogComponent (itself just ptech-dialog-shell + ptech-button) and hands
|
|
11350
|
+
* back an Observable<boolean> instead of taking an accept/cancel callback pair, so the dialog
|
|
11351
|
+
* carries no application logic and the caller reads the result the same way it would from
|
|
11352
|
+
* MatDialogRef.afterClosed().
|
|
11353
|
+
*/
|
|
11354
|
+
class PtechConfirmationService {
|
|
11355
|
+
dialog;
|
|
11356
|
+
constructor(dialog) {
|
|
11357
|
+
this.dialog = dialog;
|
|
11358
|
+
}
|
|
11359
|
+
confirm(options, width = '440px') {
|
|
11360
|
+
const ref = this.dialog.open(PtechConfirmationDialogComponent, {
|
|
11361
|
+
data: options,
|
|
11362
|
+
width,
|
|
11363
|
+
maxWidth: '96vw',
|
|
11364
|
+
panelClass: 'ptech-dialog-panel',
|
|
11365
|
+
disableClose: options.disableClose ?? false,
|
|
11366
|
+
autoFocus: false,
|
|
11367
|
+
restoreFocus: false,
|
|
11368
|
+
});
|
|
11369
|
+
return ref.afterClosed().pipe(map(confirmed => !!confirmed));
|
|
11370
|
+
}
|
|
11371
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PtechConfirmationService, deps: [{ token: i1$3.MatDialog }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
11372
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PtechConfirmationService, providedIn: 'root' });
|
|
11373
|
+
}
|
|
11374
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PtechConfirmationService, decorators: [{
|
|
11375
|
+
type: Injectable,
|
|
11376
|
+
args: [{ providedIn: 'root' }]
|
|
11377
|
+
}], ctorParameters: () => [{ type: i1$3.MatDialog }] });
|
|
11378
|
+
|
|
11257
11379
|
class ModuleChangeService {
|
|
11258
11380
|
moduleChangedSource = new BehaviorSubject('');
|
|
11259
11381
|
moduleChanged$ = this.moduleChangedSource.asObservable();
|
|
@@ -11723,5 +11845,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
|
|
|
11723
11845
|
* Generated bundle index. Do not edit.
|
|
11724
11846
|
*/
|
|
11725
11847
|
|
|
11726
|
-
export { ActionDialogComponent, ActionResultDialogComponent, ActionRowComponent, AlertComponent, ArrayUtil, BREADCRUMB_PREFIX$, BadgeComponent, BadgeStackComponent, BreadcrumbComponent, BreadcrumbService, ButtonComponent, CardComponent, CheckBoxComponent, ClickCatcherDirective,
|
|
11848
|
+
export { ActionDialogComponent, ActionResultDialogComponent, ActionRowComponent, AlertComponent, ArrayUtil, BREADCRUMB_PREFIX$, BadgeComponent, BadgeStackComponent, BreadcrumbComponent, BreadcrumbService, ButtonComponent, CardComponent, CheckBoxComponent, ClickCatcherDirective, CoreMaterialModule, CurrencyBrlPipe, CurrencyPreferenceService, CurrencyUtil, DateAgoPipe, DateMaskDirective, DateUtil, DefaultConsoleMessageService, DefaultMessageService, DialogService, DialogShellComponent, DirectivesModule, DocumentUtil, DynamicTabDirective, ExpansionPanelComponent, FakeDataService, FlagComponent, FooterComponent, ForDirective, GetFirstStringBeforeSpacePipe, HeaderComponent, IconComponent, InfoDetailComponent, InfoDetailDialogComponent, InputComponent, InputCurrencyComponent, InputDateComponent, InputDateRangeComponent, InputTimeComponent, IsLongerThanPipe, LineBreakAfterPeriodPipe, LineBreakAfterPipe, ListPaginationComponent, LoadingOverlayComponent, LoadingService, LowerCaseDirective, MESSAGE_SERVICE, MY_DATE_FORMATS, MemoryFormatPipe, ModuleChangeService, NavComponent, NavService, NumberUtil, ObjectUtil, PhoneBrazilPipe, PhoneMaskBrazilDirective, PhoneMaskSpainDirective, PhoneSpainPipe, PipesModule, ProfileMenuComponent, ProgressBarComponent, ProgressBarMultipleComponent, PtechAutocompleteComponent, PtechCarouselComponent, PtechColDirective, PtechConfirmationDialogComponent, PtechConfirmationService, PtechDualListboxComponent, PtechGridDirective, PtechInputFileComponent, PtechPopoverComponent, PtechTabComponent, PtechTableColumnBuilder, PtechTabsComponent, PtechTimelineComponent, PtechTimezoneClockComponent, PtechWidgetMenuComponent, PumpkinTechModule, QuantityItemsComponent, RadioGroupEntityComponent, RadioGroupEnumComponent, RedDirective, SelectEntityComponent, SelectEnumComponent, SelectQuantityItemsComponent, SlideToggleComponent, SnackbarMessageService, SpaceDropDirective, StringUtil, TableCellDirective, TableComponent, TextareaComponent, TimeDurationPipe, TitleComponent, UpperCaseDirective, UptimeFormatPipe, UuidUtil };
|
|
11727
11849
|
//# sourceMappingURL=pumpkin-tech-pumpkin-tech-ng.mjs.map
|