@ngx-smz/core 21.9.0-next.8 → 21.10.0-next.1
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.
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { signal, Injectable, InjectionToken, provideAppInitializer, inject, makeEnvironmentProviders, computed, Pipe, Input, Component, ChangeDetectorRef, effect, DestroyRef, EventEmitter, HostListener, Output, HostBinding, Directive, ChangeDetectionStrategy, ViewEncapsulation, Optional, NgModule, ViewChild, ElementRef, Renderer2, forwardRef, Inject, LOCALE_ID, ContentChildren, Self, ErrorHandler, DEFAULT_CURRENCY_CODE, DOCUMENT, PLATFORM_ID } from '@angular/core';
|
|
2
|
+
import { signal, Injectable, InjectionToken, provideAppInitializer, inject, makeEnvironmentProviders, computed, Pipe, Input, Component, ChangeDetectorRef, effect, DestroyRef, EventEmitter, HostListener, Output, HostBinding, Directive, ChangeDetectionStrategy, ViewEncapsulation, Optional, NgModule, ViewChild, ElementRef, Renderer2, forwardRef, Inject, NgZone, LOCALE_ID, ContentChildren, Self, ErrorHandler, DEFAULT_CURRENCY_CODE, DOCUMENT, PLATFORM_ID } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/common';
|
|
4
4
|
import { CommonModule, getCurrencySymbol, getLocaleCurrencyCode, NgStyle, LocationStrategy, registerLocaleData, isPlatformBrowser as isPlatformBrowser$1, formatDate } from '@angular/common';
|
|
5
5
|
import * as i1$1 from '@angular/forms';
|
|
@@ -2490,9 +2490,7 @@ class SmzFormsManagerService {
|
|
|
2490
2490
|
// USING BUILT-IN PRESET
|
|
2491
2491
|
return {
|
|
2492
2492
|
extraSmall: {
|
|
2493
|
-
row:
|
|
2494
|
-
horizontalAlignment: 'justify-start',
|
|
2495
|
-
verticalAlignment: 'items-start'
|
|
2493
|
+
row: 12
|
|
2496
2494
|
}
|
|
2497
2495
|
};
|
|
2498
2496
|
}
|
|
@@ -2816,11 +2814,11 @@ class CalendarComponent {
|
|
|
2816
2814
|
ngOnInit() {
|
|
2817
2815
|
}
|
|
2818
2816
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: CalendarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2819
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.1", type: CalendarComponent, isStandalone: false, selector: "smz-calendar", inputs: { input: "input", control: "control", behaviors: "behaviors" }, ngImport: i0, template: "<div class=\"input_inner__wrapper flex flex-col flex-auto p-0 gap-1\">\
|
|
2817
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.1", type: CalendarComponent, isStandalone: false, selector: "smz-calendar", inputs: { input: "input", control: "control", behaviors: "behaviors" }, ngImport: i0, template: "<div class=\"input_inner__wrapper flex flex-col flex-auto p-0 gap-1\">\n <smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n </smz-label>\n <ui-date-picker class=\"w-full smz__input_value\" styleClass=\"w-full\" appendTo=\"body\" [dateFormat]=\"input.dateFormat != null ? input.dateFormat : 'dd/mm/yy'\" [touchUI]=\"input.touchUI != null ? input.touchUI : false\" [focusTrap]=\"input.focusTrap != null ? input.focusTrap : true\" [keepInvalid]=\"input.keepInvalid != null? input.keepInvalid : false\" [showButtonBar]=\"input.showButtonBar != null ? input.showButtonBar : false\" [showOnFocus]=\"input.showOnFocus != null ? input.showOnFocus : true\" [showIcon]=\"input.showIcon != null ? input.showIcon : false\" [timeOnly]=\"input.timeOnly\" [showTime]=\"input.showTime\" [inputId]=\"input.propertyName\" [formControl]=\"control\">\n </ui-date-picker>\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\n</div>", dependencies: [{ kind: "component", type: i2.SmzDatePickerComponent, selector: "ui-date-picker", inputs: ["selectionMode", "dateFormat", "showTime", "timeOnly", "showSeconds", "hourFormat", "minDate", "maxDate", "showButtonBar", "showIcon", "showOnFocus", "keepInvalid", "readonlyInput", "placeholder", "inputId", "styleClass", "appendTo", "touchUI", "focusTrap"], outputs: ["selected", "cleared", "opened", "closed", "blurred"] }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: LabelComponent, selector: "smz-label", inputs: ["text", "propertyName", "showLabel", "warning", "help", "popover"] }, { kind: "component", type: ValidationMessagesComponent, selector: "smz-validation-messages", inputs: ["input", "control", "behaviors", "extraMessages"] }] });
|
|
2820
2818
|
}
|
|
2821
2819
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: CalendarComponent, decorators: [{
|
|
2822
2820
|
type: Component,
|
|
2823
|
-
args: [{ selector: 'smz-calendar', standalone: false, template: "<div class=\"input_inner__wrapper flex flex-col flex-auto p-0 gap-1\">\
|
|
2821
|
+
args: [{ selector: 'smz-calendar', standalone: false, template: "<div class=\"input_inner__wrapper flex flex-col flex-auto p-0 gap-1\">\n <smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n </smz-label>\n <ui-date-picker class=\"w-full smz__input_value\" styleClass=\"w-full\" appendTo=\"body\" [dateFormat]=\"input.dateFormat != null ? input.dateFormat : 'dd/mm/yy'\" [touchUI]=\"input.touchUI != null ? input.touchUI : false\" [focusTrap]=\"input.focusTrap != null ? input.focusTrap : true\" [keepInvalid]=\"input.keepInvalid != null? input.keepInvalid : false\" [showButtonBar]=\"input.showButtonBar != null ? input.showButtonBar : false\" [showOnFocus]=\"input.showOnFocus != null ? input.showOnFocus : true\" [showIcon]=\"input.showIcon != null ? input.showIcon : false\" [timeOnly]=\"input.timeOnly\" [showTime]=\"input.showTime\" [inputId]=\"input.propertyName\" [formControl]=\"control\">\n </ui-date-picker>\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\n</div>" }]
|
|
2824
2822
|
}], propDecorators: { input: [{
|
|
2825
2823
|
type: Input
|
|
2826
2824
|
}], control: [{
|
|
@@ -4085,7 +4083,7 @@ class InputListComponent {
|
|
|
4085
4083
|
return form;
|
|
4086
4084
|
}
|
|
4087
4085
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: InputListComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i1$3.Store }, { token: i1$3.Actions }, { token: i1$1.UntypedFormBuilder }], target: i0.ɵɵFactoryTarget.Component });
|
|
4088
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: InputListComponent, isStandalone: false, selector: "smz-input-list", inputs: { input: "input", control: "control", behaviors: "behaviors" }, ngImport: i0, template: "<smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideName == false && input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n</smz-label>\n\n<div class=\"input_inner__wrapper\">\n <ui-listbox [options]=\"input.listBoxOptions\" [metaKeySelection]=\"false\" [checkbox]=\"false\" [filter]=\"input.showFilter\" optionLabel=\"name\" dataKey=\"id\" [listStyle]=\"{'height': input.height ? input.height : '200px'}\" [style]=\"{'width':'100%'}\" [styleClass]=\"input.styleClass\" [disabled]=\"input.isDisabled\" (clicked)=\"onClick($event)\" [readonly]=\"isInlineEditingEnabled\" [emptyMessage]=\"input.emptyMessage\" [(ngModel)]=\"current\">\n\n <ng-template smzTemplate=\"header\">\n <div class=\"smz__list-header\">\n @if (input.showAddButton && !input.allowBatchCreation) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-plus\" clickStopPropagation class=\"p-nocustom\" (click)=\"onAdd()\" [disabled]=\"input.limitCount != null && input.listBoxOptions?.length >= input.limitCount\" smzTooltip=\"Adicionar novo item\" [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (input.showAddButton && input.allowBatchCreation) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-plus\" clickStopPropagation class=\"p-nocustom\" (click)=\"onAddInBatch()\" smzTooltip=\"Adicionar novos itens\" [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (input.showSortButton) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-arrow-down-a-z\" clickStopPropagation class=\"p-nocustom\" (click)=\"onSort()\" smzTooltip=\"Reordenar\" [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (input.showClearButton) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-trash\" clickStopPropagation class=\"p-nocustom\" (click)=\"onClear()\" smzTooltip=\"Limpar a lista\" [rounded]=\"true\" variant=\"text\"></button>\n }\n </div>\n </ng-template>\n\n <ng-template let-item smzTemplate=\"item\">\n <div class=\"grid grid-nogutter items-center w-full justify-between\">\n @if (!isInlineEditingEnabled || (isInlineEditingEnabled && current !== item)) {\n @if (input.crud?.inputType === 'float') {\n <div class=\"smz__list_item-title\">{{ item.name | number : input.crud.digitsInfo : input.crud.labelLocale }}</div>\n } @else {\n <div class=\"smz__list_item-title\">{{ item.name }}</div>\n }\n }\n\n @if (isInlineEditingEnabled && current === item) {\n @if (editForm != null) {\n <div class=\"col grid grid-nogutter items-center justify-center flex-gap-2 py-3 px-0\" clickStopPropagation>\n <form #form [formGroup]=\"editForm\" class=\"col relative\">\n <input type=\"text\" clickStopPropagation smzInputText formControlName=\"value\"/>\n @if (editForm.get('value'); as valueInput) {\n @if (valueInput.touched && valueInput.hasError('required')) {\n <div class=\"text-xs text-red-500 absolute right-3 my-1\">Campo Obrigat\u00F3rio.</div>\n }\n @if (valueInput.touched && valueInput.hasError('unique')) {\n <div class=\"text-xs text-red-500 absolute right-3 my-1\">J\u00E1 existe um item com esse nome.</div>\n }\n }\n </form>\n <button smzButton type=\"button\" icon=\"fa-solid fa-check\" clickStopPropagation [disabled]=\"!editForm.valid\" class=\"p-nocustom inline_action_button\" (click)=\"onConfirmInlineEditing(item)\" [rounded]=\"true\" severity=\"success\" variant=\"text\"></button>\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" clickStopPropagation class=\"p-nocustom inline_action_button\" (click)=\"cancelEdit()\" [rounded]=\"true\" severity=\"danger\" variant=\"text\"></button>\n </div>\n }\n }\n\n @if (current === item && !isInlineEditingEnabled) {\n <div class=\"smz__list_item-actions\" clickStopPropagation>\n @if (input.showEditButton) {\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-pencil\" class=\"p-nocustom\" (click)=\"onEdit(item)\" [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (input.showRemoveButton) {\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-trash\" class=\"p-nocustom\" (click)=\"input.askBeforeRemoveItem ? askBeforeRemove(item) : remove(item)\" [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (input.showMoveButton) {\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-arrow-up\" class=\"p-nocustom\" (click)=\"moveUp(item)\" [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (input.showMoveButton) {\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-arrow-down\" class=\"p-nocustom\" (click)=\"moveDown(item)\" [rounded]=\"true\" variant=\"text\"></button>\n }\n </div>\n }\n\n </div>\n </ng-template>\n\n <ng-template smzTemplate=\"footer\">\n @if (input.listBoxOptions.length === 0 && input.validatorsPreset?.isRequired) {\n <span class=\"col-12 smz__footer-message\">*Campo obrigat\u00F3rio</span>\n }\n @if (input.limitCount != null && input.listBoxOptions?.length === input.limitCount) {\n <span class=\"col-12 smz__footer-message text-blue-300\">*Limite atingido.</span>\n }\n @if (input.limitCount != null && input.listBoxOptions?.length > input.limitCount) {\n <span class=\"col-12 smz__footer-message\">*Limite ultrapassado</span>\n }\n </ng-template>\n </ui-listbox>\n</div>", dependencies: [{ kind: "directive", type: ClickStopPropagationDirective, selector: "[clickStopPropagation]" }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2.SmzInputTextDirective, selector: "input[smzInputText]", inputs: ["size", "invalid"] }, { kind: "component", type: i2.SmzListboxComponent, selector: "ui-listbox", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "multiple", "checkbox", "filter", "filterBy", "filterMatchMode", "metaKeySelection", "readonly", "emptyMessage", "emptyFilterMessage", "listStyle", "style", "styleClass"], outputs: ["changed", "clicked"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i2.SmzTooltipDirective, selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "component", type: LabelComponent, selector: "smz-label", inputs: ["text", "propertyName", "showLabel", "warning", "help", "popover"] }, { kind: "pipe", type: i1.DecimalPipe, name: "number" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
4086
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: InputListComponent, isStandalone: false, selector: "smz-input-list", inputs: { input: "input", control: "control", behaviors: "behaviors" }, ngImport: i0, template: "<smz-label\r\n class=\"smz__input_name\"\r\n [text]=\"input.name\"\r\n [propertyName]=\"input.propertyName\"\r\n [showLabel]=\"input.hideName == false && input.hideLabel != true\"\r\n [warning]=\"input.warning?.()\"\r\n [help]=\"input.tooltip?.()\"\r\n [popover]=\"input.popover?.()\">\r\n</smz-label>\r\n\r\n<div class=\"input_inner__wrapper\">\r\n <ui-listbox [options]=\"input.listBoxOptions\" [metaKeySelection]=\"false\" [checkbox]=\"false\" [filter]=\"input.showFilter\" optionLabel=\"name\" dataKey=\"id\" [listStyle]=\"{'height': input.height ? input.height : '200px'}\" [style]=\"{'width':'100%'}\" [styleClass]=\"input.styleClass\" [disabled]=\"input.isDisabled\" (clicked)=\"onClick($event)\" [readonly]=\"isInlineEditingEnabled\" [emptyMessage]=\"input.emptyMessage\" [(ngModel)]=\"current\">\r\n\r\n <ng-template smzTemplate=\"header\">\r\n <div class=\"smz__list-header\">\r\n @if (input.showAddButton && !input.allowBatchCreation) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-plus\" clickStopPropagation class=\"p-nocustom\" (click)=\"onAdd()\" [disabled]=\"input.limitCount != null && input.listBoxOptions?.length >= input.limitCount\" smzTooltip=\"Adicionar novo item\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (input.showAddButton && input.allowBatchCreation) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-plus\" clickStopPropagation class=\"p-nocustom\" (click)=\"onAddInBatch()\" smzTooltip=\"Adicionar novos itens\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (input.showSortButton) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-arrow-down-a-z\" clickStopPropagation class=\"p-nocustom\" (click)=\"onSort()\" smzTooltip=\"Reordenar\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (input.showClearButton) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-trash\" clickStopPropagation class=\"p-nocustom\" (click)=\"onClear()\" smzTooltip=\"Limpar a lista\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template let-item smzTemplate=\"item\">\r\n <div class=\"grid grid-nogutter items-center w-full justify-between\">\r\n @if (!isInlineEditingEnabled || (isInlineEditingEnabled && current !== item)) {\r\n @if (input.crud?.inputType === 'float') {\r\n <div class=\"smz__list_item-title\">{{ item.name | number : input.crud.digitsInfo : input.crud.labelLocale }}</div>\r\n } @else {\r\n <div class=\"smz__list_item-title\">{{ item.name }}</div>\r\n }\r\n }\r\n\r\n @if (isInlineEditingEnabled && current === item) {\r\n @if (editForm != null) {\r\n <div class=\"col grid grid-nogutter items-center justify-center flex-gap-2 py-3 px-0\" clickStopPropagation>\r\n <form #form [formGroup]=\"editForm\" class=\"col relative\">\r\n <input type=\"text\" clickStopPropagation smzInputText formControlName=\"value\"/>\r\n @if (editForm.get('value'); as valueInput) {\r\n @if (valueInput.touched && valueInput.hasError('required')) {\r\n <div class=\"text-xs text-red-500 absolute right-3 my-1\">Campo Obrigat\u00F3rio.</div>\r\n }\r\n @if (valueInput.touched && valueInput.hasError('unique')) {\r\n <div class=\"text-xs text-red-500 absolute right-3 my-1\">J\u00E1 existe um item com esse nome.</div>\r\n }\r\n }\r\n </form>\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-check\" clickStopPropagation [disabled]=\"!editForm.valid\" class=\"p-nocustom inline_action_button\" (click)=\"onConfirmInlineEditing(item)\" [rounded]=\"true\" severity=\"success\" variant=\"text\"></button>\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" clickStopPropagation class=\"p-nocustom inline_action_button\" (click)=\"cancelEdit()\" [rounded]=\"true\" severity=\"danger\" variant=\"text\"></button>\r\n </div>\r\n }\r\n }\r\n\r\n @if (current === item && !isInlineEditingEnabled) {\r\n <div class=\"smz__list_item-actions\" clickStopPropagation>\r\n @if (input.showEditButton) {\r\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-pencil\" class=\"p-nocustom\" (click)=\"onEdit(item)\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (input.showRemoveButton) {\r\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-trash\" class=\"p-nocustom\" (click)=\"input.askBeforeRemoveItem ? askBeforeRemove(item) : remove(item)\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (input.showMoveButton) {\r\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-arrow-up\" class=\"p-nocustom\" (click)=\"moveUp(item)\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (input.showMoveButton) {\r\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-arrow-down\" class=\"p-nocustom\" (click)=\"moveDown(item)\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n </div>\r\n }\r\n\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template smzTemplate=\"footer\">\r\n @if (input.listBoxOptions.length === 0 && input.validatorsPreset?.isRequired) {\r\n <span class=\"col-12 smz__footer-message\">*Campo obrigat\u00F3rio</span>\r\n }\r\n @if (input.limitCount != null && input.listBoxOptions?.length === input.limitCount) {\r\n <span class=\"col-12 smz__footer-message text-blue-300\">*Limite atingido.</span>\r\n }\r\n @if (input.limitCount != null && input.listBoxOptions?.length > input.limitCount) {\r\n <span class=\"col-12 smz__footer-message\">*Limite ultrapassado</span>\r\n }\r\n </ng-template>\r\n </ui-listbox>\r\n</div>", dependencies: [{ kind: "directive", type: ClickStopPropagationDirective, selector: "[clickStopPropagation]" }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2.SmzInputTextDirective, selector: "input[smzInputText]", inputs: ["size", "invalid"] }, { kind: "component", type: i2.SmzListboxComponent, selector: "ui-listbox", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "multiple", "checkbox", "filter", "filterBy", "filterMatchMode", "metaKeySelection", "readonly", "emptyMessage", "emptyFilterMessage", "listStyle", "style", "styleClass"], outputs: ["changed", "clicked"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i2.SmzTooltipDirective, selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "component", type: LabelComponent, selector: "smz-label", inputs: ["text", "propertyName", "showLabel", "warning", "help", "popover"] }, { kind: "pipe", type: i1.DecimalPipe, name: "number" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
4089
4087
|
}
|
|
4090
4088
|
__decorate([
|
|
4091
4089
|
Confirmable('Deseja realmente excluir esse item ?', 'Exclusão')
|
|
@@ -4095,7 +4093,7 @@ __decorate([
|
|
|
4095
4093
|
], InputListComponent.prototype, "onClear", null);
|
|
4096
4094
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: InputListComponent, decorators: [{
|
|
4097
4095
|
type: Component,
|
|
4098
|
-
args: [{ selector: 'smz-input-list', changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, template: "<smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideName == false && input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n</smz-label>\n\n<div class=\"input_inner__wrapper\">\n <ui-listbox [options]=\"input.listBoxOptions\" [metaKeySelection]=\"false\" [checkbox]=\"false\" [filter]=\"input.showFilter\" optionLabel=\"name\" dataKey=\"id\" [listStyle]=\"{'height': input.height ? input.height : '200px'}\" [style]=\"{'width':'100%'}\" [styleClass]=\"input.styleClass\" [disabled]=\"input.isDisabled\" (clicked)=\"onClick($event)\" [readonly]=\"isInlineEditingEnabled\" [emptyMessage]=\"input.emptyMessage\" [(ngModel)]=\"current\">\n\n <ng-template smzTemplate=\"header\">\n <div class=\"smz__list-header\">\n @if (input.showAddButton && !input.allowBatchCreation) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-plus\" clickStopPropagation class=\"p-nocustom\" (click)=\"onAdd()\" [disabled]=\"input.limitCount != null && input.listBoxOptions?.length >= input.limitCount\" smzTooltip=\"Adicionar novo item\" [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (input.showAddButton && input.allowBatchCreation) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-plus\" clickStopPropagation class=\"p-nocustom\" (click)=\"onAddInBatch()\" smzTooltip=\"Adicionar novos itens\" [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (input.showSortButton) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-arrow-down-a-z\" clickStopPropagation class=\"p-nocustom\" (click)=\"onSort()\" smzTooltip=\"Reordenar\" [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (input.showClearButton) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-trash\" clickStopPropagation class=\"p-nocustom\" (click)=\"onClear()\" smzTooltip=\"Limpar a lista\" [rounded]=\"true\" variant=\"text\"></button>\n }\n </div>\n </ng-template>\n\n <ng-template let-item smzTemplate=\"item\">\n <div class=\"grid grid-nogutter items-center w-full justify-between\">\n @if (!isInlineEditingEnabled || (isInlineEditingEnabled && current !== item)) {\n @if (input.crud?.inputType === 'float') {\n <div class=\"smz__list_item-title\">{{ item.name | number : input.crud.digitsInfo : input.crud.labelLocale }}</div>\n } @else {\n <div class=\"smz__list_item-title\">{{ item.name }}</div>\n }\n }\n\n @if (isInlineEditingEnabled && current === item) {\n @if (editForm != null) {\n <div class=\"col grid grid-nogutter items-center justify-center flex-gap-2 py-3 px-0\" clickStopPropagation>\n <form #form [formGroup]=\"editForm\" class=\"col relative\">\n <input type=\"text\" clickStopPropagation smzInputText formControlName=\"value\"/>\n @if (editForm.get('value'); as valueInput) {\n @if (valueInput.touched && valueInput.hasError('required')) {\n <div class=\"text-xs text-red-500 absolute right-3 my-1\">Campo Obrigat\u00F3rio.</div>\n }\n @if (valueInput.touched && valueInput.hasError('unique')) {\n <div class=\"text-xs text-red-500 absolute right-3 my-1\">J\u00E1 existe um item com esse nome.</div>\n }\n }\n </form>\n <button smzButton type=\"button\" icon=\"fa-solid fa-check\" clickStopPropagation [disabled]=\"!editForm.valid\" class=\"p-nocustom inline_action_button\" (click)=\"onConfirmInlineEditing(item)\" [rounded]=\"true\" severity=\"success\" variant=\"text\"></button>\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" clickStopPropagation class=\"p-nocustom inline_action_button\" (click)=\"cancelEdit()\" [rounded]=\"true\" severity=\"danger\" variant=\"text\"></button>\n </div>\n }\n }\n\n @if (current === item && !isInlineEditingEnabled) {\n <div class=\"smz__list_item-actions\" clickStopPropagation>\n @if (input.showEditButton) {\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-pencil\" class=\"p-nocustom\" (click)=\"onEdit(item)\" [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (input.showRemoveButton) {\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-trash\" class=\"p-nocustom\" (click)=\"input.askBeforeRemoveItem ? askBeforeRemove(item) : remove(item)\" [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (input.showMoveButton) {\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-arrow-up\" class=\"p-nocustom\" (click)=\"moveUp(item)\" [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (input.showMoveButton) {\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-arrow-down\" class=\"p-nocustom\" (click)=\"moveDown(item)\" [rounded]=\"true\" variant=\"text\"></button>\n }\n </div>\n }\n\n </div>\n </ng-template>\n\n <ng-template smzTemplate=\"footer\">\n @if (input.listBoxOptions.length === 0 && input.validatorsPreset?.isRequired) {\n <span class=\"col-12 smz__footer-message\">*Campo obrigat\u00F3rio</span>\n }\n @if (input.limitCount != null && input.listBoxOptions?.length === input.limitCount) {\n <span class=\"col-12 smz__footer-message text-blue-300\">*Limite atingido.</span>\n }\n @if (input.limitCount != null && input.listBoxOptions?.length > input.limitCount) {\n <span class=\"col-12 smz__footer-message\">*Limite ultrapassado</span>\n }\n </ng-template>\n </ui-listbox>\n</div>" }]
|
|
4096
|
+
args: [{ selector: 'smz-input-list', changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, template: "<smz-label\r\n class=\"smz__input_name\"\r\n [text]=\"input.name\"\r\n [propertyName]=\"input.propertyName\"\r\n [showLabel]=\"input.hideName == false && input.hideLabel != true\"\r\n [warning]=\"input.warning?.()\"\r\n [help]=\"input.tooltip?.()\"\r\n [popover]=\"input.popover?.()\">\r\n</smz-label>\r\n\r\n<div class=\"input_inner__wrapper\">\r\n <ui-listbox [options]=\"input.listBoxOptions\" [metaKeySelection]=\"false\" [checkbox]=\"false\" [filter]=\"input.showFilter\" optionLabel=\"name\" dataKey=\"id\" [listStyle]=\"{'height': input.height ? input.height : '200px'}\" [style]=\"{'width':'100%'}\" [styleClass]=\"input.styleClass\" [disabled]=\"input.isDisabled\" (clicked)=\"onClick($event)\" [readonly]=\"isInlineEditingEnabled\" [emptyMessage]=\"input.emptyMessage\" [(ngModel)]=\"current\">\r\n\r\n <ng-template smzTemplate=\"header\">\r\n <div class=\"smz__list-header\">\r\n @if (input.showAddButton && !input.allowBatchCreation) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-plus\" clickStopPropagation class=\"p-nocustom\" (click)=\"onAdd()\" [disabled]=\"input.limitCount != null && input.listBoxOptions?.length >= input.limitCount\" smzTooltip=\"Adicionar novo item\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (input.showAddButton && input.allowBatchCreation) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-plus\" clickStopPropagation class=\"p-nocustom\" (click)=\"onAddInBatch()\" smzTooltip=\"Adicionar novos itens\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (input.showSortButton) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-arrow-down-a-z\" clickStopPropagation class=\"p-nocustom\" (click)=\"onSort()\" smzTooltip=\"Reordenar\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (input.showClearButton) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-trash\" clickStopPropagation class=\"p-nocustom\" (click)=\"onClear()\" smzTooltip=\"Limpar a lista\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template let-item smzTemplate=\"item\">\r\n <div class=\"grid grid-nogutter items-center w-full justify-between\">\r\n @if (!isInlineEditingEnabled || (isInlineEditingEnabled && current !== item)) {\r\n @if (input.crud?.inputType === 'float') {\r\n <div class=\"smz__list_item-title\">{{ item.name | number : input.crud.digitsInfo : input.crud.labelLocale }}</div>\r\n } @else {\r\n <div class=\"smz__list_item-title\">{{ item.name }}</div>\r\n }\r\n }\r\n\r\n @if (isInlineEditingEnabled && current === item) {\r\n @if (editForm != null) {\r\n <div class=\"col grid grid-nogutter items-center justify-center flex-gap-2 py-3 px-0\" clickStopPropagation>\r\n <form #form [formGroup]=\"editForm\" class=\"col relative\">\r\n <input type=\"text\" clickStopPropagation smzInputText formControlName=\"value\"/>\r\n @if (editForm.get('value'); as valueInput) {\r\n @if (valueInput.touched && valueInput.hasError('required')) {\r\n <div class=\"text-xs text-red-500 absolute right-3 my-1\">Campo Obrigat\u00F3rio.</div>\r\n }\r\n @if (valueInput.touched && valueInput.hasError('unique')) {\r\n <div class=\"text-xs text-red-500 absolute right-3 my-1\">J\u00E1 existe um item com esse nome.</div>\r\n }\r\n }\r\n </form>\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-check\" clickStopPropagation [disabled]=\"!editForm.valid\" class=\"p-nocustom inline_action_button\" (click)=\"onConfirmInlineEditing(item)\" [rounded]=\"true\" severity=\"success\" variant=\"text\"></button>\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" clickStopPropagation class=\"p-nocustom inline_action_button\" (click)=\"cancelEdit()\" [rounded]=\"true\" severity=\"danger\" variant=\"text\"></button>\r\n </div>\r\n }\r\n }\r\n\r\n @if (current === item && !isInlineEditingEnabled) {\r\n <div class=\"smz__list_item-actions\" clickStopPropagation>\r\n @if (input.showEditButton) {\r\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-pencil\" class=\"p-nocustom\" (click)=\"onEdit(item)\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (input.showRemoveButton) {\r\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-trash\" class=\"p-nocustom\" (click)=\"input.askBeforeRemoveItem ? askBeforeRemove(item) : remove(item)\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (input.showMoveButton) {\r\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-arrow-up\" class=\"p-nocustom\" (click)=\"moveUp(item)\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (input.showMoveButton) {\r\n <button clickStopPropagation smzButton type=\"button\" icon=\"fa-solid fa-arrow-down\" class=\"p-nocustom\" (click)=\"moveDown(item)\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n </div>\r\n }\r\n\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template smzTemplate=\"footer\">\r\n @if (input.listBoxOptions.length === 0 && input.validatorsPreset?.isRequired) {\r\n <span class=\"col-12 smz__footer-message\">*Campo obrigat\u00F3rio</span>\r\n }\r\n @if (input.limitCount != null && input.listBoxOptions?.length === input.limitCount) {\r\n <span class=\"col-12 smz__footer-message text-blue-300\">*Limite atingido.</span>\r\n }\r\n @if (input.limitCount != null && input.listBoxOptions?.length > input.limitCount) {\r\n <span class=\"col-12 smz__footer-message\">*Limite ultrapassado</span>\r\n }\r\n </ng-template>\r\n </ui-listbox>\r\n</div>" }]
|
|
4099
4097
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i1$3.Store }, { type: i1$3.Actions }, { type: i1$1.UntypedFormBuilder }], propDecorators: { input: [{
|
|
4100
4098
|
type: Input
|
|
4101
4099
|
}], control: [{
|
|
@@ -4115,11 +4113,11 @@ class InputMaskComponent {
|
|
|
4115
4113
|
control;
|
|
4116
4114
|
behaviors;
|
|
4117
4115
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: InputMaskComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
4118
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.1", type: InputMaskComponent, isStandalone: false, selector: "smz-input-mask", inputs: { input: "input", control: "control", behaviors: "behaviors" }, ngImport: i0, template: "<smz-label\
|
|
4116
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.1", type: InputMaskComponent, isStandalone: false, selector: "smz-input-mask", inputs: { input: "input", control: "control", behaviors: "behaviors" }, ngImport: i0, template: "<smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n</smz-label>\n\n<div class=\"input_inner__wrapper\">\n <ui-input-mask class=\"smz__input_value flex-1\" [mask]=\"input.mask\" [characterPattern]=\"input.characterPattern\" [unmask]=\"input.unmask\" [inputId]=\"input.propertyName\" [name]=\"input.propertyName\" type=\"text\" [formControl]=\"control\">\n </ui-input-mask>\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\n</div>", dependencies: [{ kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "component", type: i2.SmzInputMaskComponent, selector: "ui-input-mask", inputs: ["mask", "slotChar", "characterPattern", "unmask", "autoClear", "placeholder", "readonly", "inputId", "name", "type"], outputs: ["inputed", "blurred", "completed"] }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: LabelComponent, selector: "smz-label", inputs: ["text", "propertyName", "showLabel", "warning", "help", "popover"] }, { kind: "component", type: ValidationMessagesComponent, selector: "smz-validation-messages", inputs: ["input", "control", "behaviors", "extraMessages"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
4119
4117
|
}
|
|
4120
4118
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: InputMaskComponent, decorators: [{
|
|
4121
4119
|
type: Component,
|
|
4122
|
-
args: [{ selector: 'smz-input-mask', encapsulation: ViewEncapsulation.None, standalone: false, template: "<smz-label\
|
|
4120
|
+
args: [{ selector: 'smz-input-mask', encapsulation: ViewEncapsulation.None, standalone: false, template: "<smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n</smz-label>\n\n<div class=\"input_inner__wrapper\">\n <ui-input-mask class=\"smz__input_value flex-1\" [mask]=\"input.mask\" [characterPattern]=\"input.characterPattern\" [unmask]=\"input.unmask\" [inputId]=\"input.propertyName\" [name]=\"input.propertyName\" type=\"text\" [formControl]=\"control\">\n </ui-input-mask>\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\n</div>" }]
|
|
4123
4121
|
}], propDecorators: { input: [{
|
|
4124
4122
|
type: Input
|
|
4125
4123
|
}], control: [{
|
|
@@ -4151,11 +4149,11 @@ class InputNumberComponent {
|
|
|
4151
4149
|
}
|
|
4152
4150
|
}
|
|
4153
4151
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: InputNumberComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
4154
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: InputNumberComponent, isStandalone: false, selector: "smz-input-number", inputs: { input: "input", control: "control", behaviors: "behaviors", form: "form" }, ngImport: i0, template: "<smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n</smz-label>\n\n<div class=\"input_inner__wrapper\">\n @if (!input.useFraction) {\n <ui-input-mask class=\"smz__input_value flex-1\" slotChar=\"\" [autoClear]=\"false\" mask=\"9?9999999999999999999999999999999\" characterPattern=\"([0-9])\" [
|
|
4152
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: InputNumberComponent, isStandalone: false, selector: "smz-input-number", inputs: { input: "input", control: "control", behaviors: "behaviors", form: "form" }, ngImport: i0, template: "<smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n</smz-label>\n\n<div class=\"input_inner__wrapper\">\n @if (!input.useFraction) {\n <ui-input-mask class=\"smz__input_value flex-1\" slotChar=\"\" [autoClear]=\"false\" mask=\"9?9999999999999999999999999999999\" characterPattern=\"([0-9])\" [inputId]=\"input.propertyName\" [name]=\"input.propertyName\" [smzAutoFocus]=\"input.autoFocus\" [formControl]=\"control\" (blurred)=\"onInputMaskBlur()\" (inputed)=\"onInputMaskInput()\">\n </ui-input-mask>\n }\n @if (input.useFraction) {\n <ui-input-number class=\"smz__input_value flex-1\" [formControl]=\"control\" [locale]=\"input.locale\" [minFractionDigits]=\"input.minFractionDigits\" [maxFractionDigits]=\"input.maxFractionDigits\" [useGrouping]=\"input.useGrouping\" [inputId]=\"input.propertyName\" [name]=\"input.propertyName\" [smzAutoFocus]=\"input.autoFocus\" (inputed)=\"onInput($event)\">\n </ui-input-number>\n }\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\n</div>", dependencies: [{ kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "component", type: i2.SmzInputMaskComponent, selector: "ui-input-mask", inputs: ["mask", "slotChar", "characterPattern", "unmask", "autoClear", "placeholder", "readonly", "inputId", "name", "type"], outputs: ["inputed", "blurred", "completed"] }, { kind: "component", type: i2.SmzInputNumberComponent, selector: "ui-input-number", inputs: ["mode", "locale", "localeMatcher", "currency", "currencyDisplay", "useGrouping", "minFractionDigits", "maxFractionDigits", "min", "max", "step", "prefix", "suffix", "showButtons", "showClear", "allowEmpty", "placeholder", "readonly", "inputId", "name"], outputs: ["inputed", "keyDown", "blurred", "focused"] }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.SmzAutoFocusDirective, selector: "[smzAutoFocus]", inputs: ["smzAutoFocus"] }, { kind: "component", type: LabelComponent, selector: "smz-label", inputs: ["text", "propertyName", "showLabel", "warning", "help", "popover"] }, { kind: "component", type: ValidationMessagesComponent, selector: "smz-validation-messages", inputs: ["input", "control", "behaviors", "extraMessages"] }] });
|
|
4155
4153
|
}
|
|
4156
4154
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: InputNumberComponent, decorators: [{
|
|
4157
4155
|
type: Component,
|
|
4158
|
-
args: [{ selector: 'smz-input-number', standalone: false, template: "<smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n</smz-label>\n\n<div class=\"input_inner__wrapper\">\n @if (!input.useFraction) {\n <ui-input-mask class=\"smz__input_value flex-1\" slotChar=\"\" [autoClear]=\"false\" mask=\"9?9999999999999999999999999999999\" characterPattern=\"([0-9])\" [
|
|
4156
|
+
args: [{ selector: 'smz-input-number', standalone: false, template: "<smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n</smz-label>\n\n<div class=\"input_inner__wrapper\">\n @if (!input.useFraction) {\n <ui-input-mask class=\"smz__input_value flex-1\" slotChar=\"\" [autoClear]=\"false\" mask=\"9?9999999999999999999999999999999\" characterPattern=\"([0-9])\" [inputId]=\"input.propertyName\" [name]=\"input.propertyName\" [smzAutoFocus]=\"input.autoFocus\" [formControl]=\"control\" (blurred)=\"onInputMaskBlur()\" (inputed)=\"onInputMaskInput()\">\n </ui-input-mask>\n }\n @if (input.useFraction) {\n <ui-input-number class=\"smz__input_value flex-1\" [formControl]=\"control\" [locale]=\"input.locale\" [minFractionDigits]=\"input.minFractionDigits\" [maxFractionDigits]=\"input.maxFractionDigits\" [useGrouping]=\"input.useGrouping\" [inputId]=\"input.propertyName\" [name]=\"input.propertyName\" [smzAutoFocus]=\"input.autoFocus\" (inputed)=\"onInput($event)\">\n </ui-input-number>\n }\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\n</div>" }]
|
|
4159
4157
|
}], propDecorators: { input: [{
|
|
4160
4158
|
type: Input
|
|
4161
4159
|
}], control: [{
|
|
@@ -4325,18 +4323,18 @@ class SmzAutocompleteSelectorComponent {
|
|
|
4325
4323
|
}
|
|
4326
4324
|
}
|
|
4327
4325
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzAutocompleteSelectorComponent, deps: [{ token: i0.ElementRef }, { token: i1$3.Store }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
4328
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzAutocompleteSelectorComponent, isStandalone: true, selector: "smz-autocomplete-selector", inputs: { isRequired: "isRequired", allowCustomValues: "allowCustomValues", option: "option", suggestions: "suggestions" }, outputs: { selectedChange: "selectedChange", suggestionsChanged: "suggestionsChanged", finished: "finished" }, ngImport: i0, template: `
|
|
4329
|
-
<div class="col-12 px-0 grid grid-nogutter items-center justify-start gap-2">
|
|
4330
|
-
<ui-auto-complete class="col" styleClass="w-full" [(ngModel)]="option.selected" [suggestions]="suggestions" [dropdown]="true" [emptyMessage]="option.emptyMessage" (completeMethod)="search($event)" (cleared)="onClear()" (blurred)="handleSelection()" (selectedItem)="onSelect()" (keydown)="handleKeyDown($event)">
|
|
4331
|
-
|
|
4332
|
-
<ng-template smzTemplate="header">
|
|
4333
|
-
@if (option.dataSourceDisplayName != null) {
|
|
4334
|
-
<div class="text-blue-500 font-bold text-lg mx-5 mt-4 mb-0">{{ option.dataSourceDisplayName }}</div>
|
|
4335
|
-
}
|
|
4336
|
-
</ng-template>
|
|
4337
|
-
|
|
4338
|
-
</ui-auto-complete>
|
|
4339
|
-
</div>
|
|
4326
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzAutocompleteSelectorComponent, isStandalone: true, selector: "smz-autocomplete-selector", inputs: { isRequired: "isRequired", allowCustomValues: "allowCustomValues", option: "option", suggestions: "suggestions" }, outputs: { selectedChange: "selectedChange", suggestionsChanged: "suggestionsChanged", finished: "finished" }, ngImport: i0, template: `
|
|
4327
|
+
<div class="col-12 px-0 grid grid-nogutter items-center justify-start gap-2">
|
|
4328
|
+
<ui-auto-complete class="col" styleClass="w-full" [(ngModel)]="option.selected" [suggestions]="suggestions" [dropdown]="true" [emptyMessage]="option.emptyMessage" (completeMethod)="search($event)" (cleared)="onClear()" (blurred)="handleSelection()" (selectedItem)="onSelect()" (keydown)="handleKeyDown($event)">
|
|
4329
|
+
|
|
4330
|
+
<ng-template smzTemplate="header">
|
|
4331
|
+
@if (option.dataSourceDisplayName != null) {
|
|
4332
|
+
<div class="text-blue-500 font-bold text-lg mx-5 mt-4 mb-0">{{ option.dataSourceDisplayName }}</div>
|
|
4333
|
+
}
|
|
4334
|
+
</ng-template>
|
|
4335
|
+
|
|
4336
|
+
</ui-auto-complete>
|
|
4337
|
+
</div>
|
|
4340
4338
|
`, isInline: true, dependencies: [{ kind: "component", type: SmzAutoCompleteComponent, selector: "ui-auto-complete", inputs: ["suggestions", "field", "dropdown", "emptyMessage", "minLength", "delay", "forceSelection", "showClear", "placeholder", "inputId", "styleClass", "appendTo"], outputs: ["completeMethod", "selectedItem", "cleared", "blurred", "focused"] }, { kind: "directive", type: SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
4341
4339
|
}
|
|
4342
4340
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzAutocompleteSelectorComponent, decorators: [{
|
|
@@ -4350,18 +4348,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImpor
|
|
|
4350
4348
|
FormsModule
|
|
4351
4349
|
],
|
|
4352
4350
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
4353
|
-
template: `
|
|
4354
|
-
<div class="col-12 px-0 grid grid-nogutter items-center justify-start gap-2">
|
|
4355
|
-
<ui-auto-complete class="col" styleClass="w-full" [(ngModel)]="option.selected" [suggestions]="suggestions" [dropdown]="true" [emptyMessage]="option.emptyMessage" (completeMethod)="search($event)" (cleared)="onClear()" (blurred)="handleSelection()" (selectedItem)="onSelect()" (keydown)="handleKeyDown($event)">
|
|
4356
|
-
|
|
4357
|
-
<ng-template smzTemplate="header">
|
|
4358
|
-
@if (option.dataSourceDisplayName != null) {
|
|
4359
|
-
<div class="text-blue-500 font-bold text-lg mx-5 mt-4 mb-0">{{ option.dataSourceDisplayName }}</div>
|
|
4360
|
-
}
|
|
4361
|
-
</ng-template>
|
|
4362
|
-
|
|
4363
|
-
</ui-auto-complete>
|
|
4364
|
-
</div>
|
|
4351
|
+
template: `
|
|
4352
|
+
<div class="col-12 px-0 grid grid-nogutter items-center justify-start gap-2">
|
|
4353
|
+
<ui-auto-complete class="col" styleClass="w-full" [(ngModel)]="option.selected" [suggestions]="suggestions" [dropdown]="true" [emptyMessage]="option.emptyMessage" (completeMethod)="search($event)" (cleared)="onClear()" (blurred)="handleSelection()" (selectedItem)="onSelect()" (keydown)="handleKeyDown($event)">
|
|
4354
|
+
|
|
4355
|
+
<ng-template smzTemplate="header">
|
|
4356
|
+
@if (option.dataSourceDisplayName != null) {
|
|
4357
|
+
<div class="text-blue-500 font-bold text-lg mx-5 mt-4 mb-0">{{ option.dataSourceDisplayName }}</div>
|
|
4358
|
+
}
|
|
4359
|
+
</ng-template>
|
|
4360
|
+
|
|
4361
|
+
</ui-auto-complete>
|
|
4362
|
+
</div>
|
|
4365
4363
|
`
|
|
4366
4364
|
}]
|
|
4367
4365
|
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: i1$3.Store }, { type: i0.ChangeDetectorRef }], propDecorators: { isRequired: [{
|
|
@@ -4632,56 +4630,56 @@ class SmzInputAutocompleteTagArea {
|
|
|
4632
4630
|
};
|
|
4633
4631
|
};
|
|
4634
4632
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzInputAutocompleteTagArea, deps: [{ token: i1$1.NgModel, optional: true }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
4635
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzInputAutocompleteTagArea, isStandalone: false, selector: "smz-input-autocomplete-tag-area", inputs: { input: "input", control: "control", behaviors: "behaviors" }, viewQueries: [{ propertyName: "overlay", first: true, predicate: SmzPopoverComponent, descendants: true }, { propertyName: "inputElement", first: true, predicate: ["inputArea"], descendants: true }, { propertyName: "selectorElement", first: true, predicate: ["elementSelector"], descendants: true }], ngImport: i0, template: `
|
|
4636
|
-
@if (input.hideLabel != true) {
|
|
4637
|
-
<label class="smz__input_name" [innerHTML]="input.name"></label>
|
|
4638
|
-
}
|
|
4639
|
-
<div class="input_inner__wrapper" [id]="input.propertyName">
|
|
4640
|
-
<textarea #inputArea id="inputArea" smzTextarea smzSmartAutocompleteTag [formControl]="$any(control)" [options]="input.config.options" [rows]="input.textAreaRows" (tagTyped)="onTag($event)" class="col-12"></textarea>
|
|
4641
|
-
<smz-validation-messages [input]="input" [control]="$any(control)" [behaviors]="behaviors"></smz-validation-messages>
|
|
4642
|
-
</div>
|
|
4643
|
-
|
|
4644
|
-
<ui-popover #overlay appendTo="body" [style]="{width: '450px'}" (hidden)="onHideOverlay()" styleClass="tag-overlay">
|
|
4645
|
-
<ng-template pTemplate>
|
|
4646
|
-
@if (currentOption) {
|
|
4647
|
-
<smz-autocomplete-selector
|
|
4648
|
-
#elementSelector
|
|
4649
|
-
styleClass="tag-dropdown"
|
|
4650
|
-
[option]="currentOption"
|
|
4651
|
-
[allowCustomValues]="input.allowCustomValues"
|
|
4652
|
-
(finished)="hide()"
|
|
4653
|
-
>
|
|
4654
|
-
</smz-autocomplete-selector>
|
|
4655
|
-
}
|
|
4656
|
-
</ng-template>
|
|
4657
|
-
</ui-popover>
|
|
4633
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzInputAutocompleteTagArea, isStandalone: false, selector: "smz-input-autocomplete-tag-area", inputs: { input: "input", control: "control", behaviors: "behaviors" }, viewQueries: [{ propertyName: "overlay", first: true, predicate: SmzPopoverComponent, descendants: true }, { propertyName: "inputElement", first: true, predicate: ["inputArea"], descendants: true }, { propertyName: "selectorElement", first: true, predicate: ["elementSelector"], descendants: true }], ngImport: i0, template: `
|
|
4634
|
+
@if (input.hideLabel != true) {
|
|
4635
|
+
<label class="smz__input_name" [innerHTML]="input.name"></label>
|
|
4636
|
+
}
|
|
4637
|
+
<div class="input_inner__wrapper" [id]="input.propertyName">
|
|
4638
|
+
<textarea #inputArea id="inputArea" smzTextarea smzSmartAutocompleteTag [formControl]="$any(control)" [options]="input.config.options" [rows]="input.textAreaRows" (tagTyped)="onTag($event)" class="col-12"></textarea>
|
|
4639
|
+
<smz-validation-messages [input]="input" [control]="$any(control)" [behaviors]="behaviors"></smz-validation-messages>
|
|
4640
|
+
</div>
|
|
4641
|
+
|
|
4642
|
+
<ui-popover #overlay appendTo="body" [style]="{width: '450px'}" (hidden)="onHideOverlay()" styleClass="tag-overlay">
|
|
4643
|
+
<ng-template pTemplate>
|
|
4644
|
+
@if (currentOption) {
|
|
4645
|
+
<smz-autocomplete-selector
|
|
4646
|
+
#elementSelector
|
|
4647
|
+
styleClass="tag-dropdown"
|
|
4648
|
+
[option]="currentOption"
|
|
4649
|
+
[allowCustomValues]="input.allowCustomValues"
|
|
4650
|
+
(finished)="hide()"
|
|
4651
|
+
>
|
|
4652
|
+
</smz-autocomplete-selector>
|
|
4653
|
+
}
|
|
4654
|
+
</ng-template>
|
|
4655
|
+
</ui-popover>
|
|
4658
4656
|
`, isInline: true, styles: [".p-overlaypanel.autocomplete-tag-overlay{box-shadow:unset}\n", ".p-overlaypanel.autocomplete-tag-overlay .p-overlaypanel-content{padding:0}\n", ".tag-dropdown.p-dropdown{width:100%}\n"], dependencies: [{ kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.SmzTextareaDirective, selector: "textarea[smzTextarea]", inputs: ["invalid", "autoResize"] }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: SmzAutocompleteSelectorComponent, selector: "smz-autocomplete-selector", inputs: ["isRequired", "allowCustomValues", "option", "suggestions"], outputs: ["selectedChange", "suggestionsChanged", "finished"] }, { kind: "directive", type: SmzSmartAutocompleteTagDirective, selector: "[smzSmartAutocompleteTag]", inputs: ["options"], outputs: ["tagTyped"] }, { kind: "component", type: i2.SmzPopoverComponent, selector: "ui-popover", inputs: ["style", "styleClass", "dismissable", "autoZIndex", "appendTo"], outputs: ["shown", "hidden"] }, { kind: "component", type: ValidationMessagesComponent, selector: "smz-validation-messages", inputs: ["input", "control", "behaviors", "extraMessages"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
4659
4657
|
}
|
|
4660
4658
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzInputAutocompleteTagArea, decorators: [{
|
|
4661
4659
|
type: Component,
|
|
4662
|
-
args: [{ selector: 'smz-input-autocomplete-tag-area', template: `
|
|
4663
|
-
@if (input.hideLabel != true) {
|
|
4664
|
-
<label class="smz__input_name" [innerHTML]="input.name"></label>
|
|
4665
|
-
}
|
|
4666
|
-
<div class="input_inner__wrapper" [id]="input.propertyName">
|
|
4667
|
-
<textarea #inputArea id="inputArea" smzTextarea smzSmartAutocompleteTag [formControl]="$any(control)" [options]="input.config.options" [rows]="input.textAreaRows" (tagTyped)="onTag($event)" class="col-12"></textarea>
|
|
4668
|
-
<smz-validation-messages [input]="input" [control]="$any(control)" [behaviors]="behaviors"></smz-validation-messages>
|
|
4669
|
-
</div>
|
|
4670
|
-
|
|
4671
|
-
<ui-popover #overlay appendTo="body" [style]="{width: '450px'}" (hidden)="onHideOverlay()" styleClass="tag-overlay">
|
|
4672
|
-
<ng-template pTemplate>
|
|
4673
|
-
@if (currentOption) {
|
|
4674
|
-
<smz-autocomplete-selector
|
|
4675
|
-
#elementSelector
|
|
4676
|
-
styleClass="tag-dropdown"
|
|
4677
|
-
[option]="currentOption"
|
|
4678
|
-
[allowCustomValues]="input.allowCustomValues"
|
|
4679
|
-
(finished)="hide()"
|
|
4680
|
-
>
|
|
4681
|
-
</smz-autocomplete-selector>
|
|
4682
|
-
}
|
|
4683
|
-
</ng-template>
|
|
4684
|
-
</ui-popover>
|
|
4660
|
+
args: [{ selector: 'smz-input-autocomplete-tag-area', template: `
|
|
4661
|
+
@if (input.hideLabel != true) {
|
|
4662
|
+
<label class="smz__input_name" [innerHTML]="input.name"></label>
|
|
4663
|
+
}
|
|
4664
|
+
<div class="input_inner__wrapper" [id]="input.propertyName">
|
|
4665
|
+
<textarea #inputArea id="inputArea" smzTextarea smzSmartAutocompleteTag [formControl]="$any(control)" [options]="input.config.options" [rows]="input.textAreaRows" (tagTyped)="onTag($event)" class="col-12"></textarea>
|
|
4666
|
+
<smz-validation-messages [input]="input" [control]="$any(control)" [behaviors]="behaviors"></smz-validation-messages>
|
|
4667
|
+
</div>
|
|
4668
|
+
|
|
4669
|
+
<ui-popover #overlay appendTo="body" [style]="{width: '450px'}" (hidden)="onHideOverlay()" styleClass="tag-overlay">
|
|
4670
|
+
<ng-template pTemplate>
|
|
4671
|
+
@if (currentOption) {
|
|
4672
|
+
<smz-autocomplete-selector
|
|
4673
|
+
#elementSelector
|
|
4674
|
+
styleClass="tag-dropdown"
|
|
4675
|
+
[option]="currentOption"
|
|
4676
|
+
[allowCustomValues]="input.allowCustomValues"
|
|
4677
|
+
(finished)="hide()"
|
|
4678
|
+
>
|
|
4679
|
+
</smz-autocomplete-selector>
|
|
4680
|
+
}
|
|
4681
|
+
</ng-template>
|
|
4682
|
+
</ui-popover>
|
|
4685
4683
|
`, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, standalone: false, styles: [".p-overlaypanel.autocomplete-tag-overlay{box-shadow:unset}\n", ".p-overlaypanel.autocomplete-tag-overlay .p-overlaypanel-content{padding:0}\n", ".tag-dropdown.p-dropdown{width:100%}\n"] }]
|
|
4686
4684
|
}], ctorParameters: () => [{ type: i1$1.NgModel, decorators: [{
|
|
4687
4685
|
type: Optional
|
|
@@ -4708,11 +4706,11 @@ class InputTextComponent {
|
|
|
4708
4706
|
control;
|
|
4709
4707
|
behaviors;
|
|
4710
4708
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: InputTextComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
4711
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.1", type: InputTextComponent, isStandalone: false, selector: "smz-input-text", inputs: { input: "input", control: "control", behaviors: "behaviors" }, ngImport: i0, template: "<smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideName == false && input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n</smz-label>\n\n<div class=\"input_inner__wrapper\">\n <input\n smzInputText\n class=\"col-12 smz__input_value flex-1\"\n [id]=\"input.propertyName\"\n type=\"text\"\n [formControl]=\"control\"\n [smzAutoFocus]=\"input.autoFocus\">\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\n</div>", dependencies: [{ kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.SmzInputTextDirective, selector: "input[smzInputText]", inputs: ["size", "invalid"] }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.SmzAutoFocusDirective, selector: "[smzAutoFocus]", inputs: ["smzAutoFocus"] }, { kind: "component", type: LabelComponent, selector: "smz-label", inputs: ["text", "propertyName", "showLabel", "warning", "help", "popover"] }, { kind: "component", type: ValidationMessagesComponent, selector: "smz-validation-messages", inputs: ["input", "control", "behaviors", "extraMessages"] }] });
|
|
4709
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.1", type: InputTextComponent, isStandalone: false, selector: "smz-input-text", inputs: { input: "input", control: "control", behaviors: "behaviors" }, ngImport: i0, template: "<smz-label\r\n class=\"smz__input_name\"\r\n [text]=\"input.name\"\r\n [propertyName]=\"input.propertyName\"\r\n [showLabel]=\"input.hideName == false && input.hideLabel != true\"\r\n [warning]=\"input.warning?.()\"\r\n [help]=\"input.tooltip?.()\"\r\n [popover]=\"input.popover?.()\">\r\n</smz-label>\r\n\r\n<div class=\"input_inner__wrapper\">\r\n <input\r\n smzInputText\r\n class=\"col-12 smz__input_value flex-1\"\r\n [id]=\"input.propertyName\"\r\n type=\"text\"\r\n [formControl]=\"control\"\r\n [smzAutoFocus]=\"input.autoFocus\">\r\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\r\n</div>", dependencies: [{ kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.SmzInputTextDirective, selector: "input[smzInputText]", inputs: ["size", "invalid"] }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.SmzAutoFocusDirective, selector: "[smzAutoFocus]", inputs: ["smzAutoFocus"] }, { kind: "component", type: LabelComponent, selector: "smz-label", inputs: ["text", "propertyName", "showLabel", "warning", "help", "popover"] }, { kind: "component", type: ValidationMessagesComponent, selector: "smz-validation-messages", inputs: ["input", "control", "behaviors", "extraMessages"] }] });
|
|
4712
4710
|
}
|
|
4713
4711
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: InputTextComponent, decorators: [{
|
|
4714
4712
|
type: Component,
|
|
4715
|
-
args: [{ selector: 'smz-input-text', standalone: false, template: "<smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideName == false && input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n</smz-label>\n\n<div class=\"input_inner__wrapper\">\n <input\n smzInputText\n class=\"col-12 smz__input_value flex-1\"\n [id]=\"input.propertyName\"\n type=\"text\"\n [formControl]=\"control\"\n [smzAutoFocus]=\"input.autoFocus\">\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\n</div>" }]
|
|
4713
|
+
args: [{ selector: 'smz-input-text', standalone: false, template: "<smz-label\r\n class=\"smz__input_name\"\r\n [text]=\"input.name\"\r\n [propertyName]=\"input.propertyName\"\r\n [showLabel]=\"input.hideName == false && input.hideLabel != true\"\r\n [warning]=\"input.warning?.()\"\r\n [help]=\"input.tooltip?.()\"\r\n [popover]=\"input.popover?.()\">\r\n</smz-label>\r\n\r\n<div class=\"input_inner__wrapper\">\r\n <input\r\n smzInputText\r\n class=\"col-12 smz__input_value flex-1\"\r\n [id]=\"input.propertyName\"\r\n type=\"text\"\r\n [formControl]=\"control\"\r\n [smzAutoFocus]=\"input.autoFocus\">\r\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\r\n</div>" }]
|
|
4716
4714
|
}], propDecorators: { input: [{
|
|
4717
4715
|
type: Input
|
|
4718
4716
|
}], control: [{
|
|
@@ -4779,11 +4777,11 @@ class InputTreeComponent {
|
|
|
4779
4777
|
}
|
|
4780
4778
|
}
|
|
4781
4779
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: InputTreeComponent, deps: [{ token: SmzFormsDropdownService }], target: i0.ɵɵFactoryTarget.Component });
|
|
4782
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: InputTreeComponent, isStandalone: false, selector: "smz-input-tree", inputs: { input: "input", formId: "formId", control: "control", behaviors: "behaviors" }, ngImport: i0, template: "@if (nodes$ | async; as nodes) {\n <smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n </smz-label>\n <div class=\"input_inner__wrapper grid grid-nogutter\">\n <ui-tree-select class=\"col-12 grid-nogutter smz__input_value flex-1\" containerStyleClass=\"w-full\" [formControl]=\"control\" [options]=\"nodes\" [placeholder]=\"input.name\" appendTo=\"body\" [filter]=\"input.showFilter ? true : false\" [selectionMode]=\"input.selectionMode\" [filterInputAutoFocus]=\"input.autofocusFilter\" [emptyMessage]=\"input.emptyMessage\" [showClear]=\"input.showClear\" [filterPlaceholder]=\"input.emptyFilterMessage\" [scrollHeight]=\"input.scrollHeight\" [display]=\"input.display\">\n @for (inputType of input.allTypes; track inputType) {\n <ng-template let-node [smzTemplate]=\"inputType\">\n @if (node != null) {\n <div [innerHTML]=\"node.label | safeHtml\" [smzTooltip]=\"node.tooltip\"></div>\n }\n </ng-template>\n }\n </ui-tree-select>\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\n </div>\n}", dependencies: [{ kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.SmzTooltipDirective, selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "component", type: i2.SmzTreeSelectComponent, selector: "ui-tree-select", inputs: ["options", "selectionMode", "placeholder", "filter", "filterPlaceholder", "emptyMessage", "showClear", "scrollHeight", "styleClass", "containerStyleClass", "appendTo", "display", "filterInputAutoFocus"] }, { kind: "component", type: LabelComponent, selector: "smz-label", inputs: ["text", "propertyName", "showLabel", "warning", "help", "popover"] }, { kind: "component", type: ValidationMessagesComponent, selector: "smz-validation-messages", inputs: ["input", "control", "behaviors", "extraMessages"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: SafeHtmlPipe$2, name: "safeHtml" }] });
|
|
4780
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: InputTreeComponent, isStandalone: false, selector: "smz-input-tree", inputs: { input: "input", formId: "formId", control: "control", behaviors: "behaviors" }, ngImport: i0, template: "@if (nodes$ | async; as nodes) {\r\n <smz-label\r\n class=\"smz__input_name\"\r\n [text]=\"input.name\"\r\n [propertyName]=\"input.propertyName\"\r\n [showLabel]=\"input.hideLabel != true\"\r\n [warning]=\"input.warning?.()\"\r\n [help]=\"input.tooltip?.()\"\r\n [popover]=\"input.popover?.()\">\r\n </smz-label>\r\n <div class=\"input_inner__wrapper grid grid-nogutter\">\r\n <ui-tree-select class=\"col-12 grid-nogutter smz__input_value flex-1\" containerStyleClass=\"w-full\" [formControl]=\"control\" [options]=\"nodes\" [placeholder]=\"input.name\" appendTo=\"body\" [filter]=\"input.showFilter ? true : false\" [selectionMode]=\"input.selectionMode\" [filterInputAutoFocus]=\"input.autofocusFilter\" [emptyMessage]=\"input.emptyMessage\" [showClear]=\"input.showClear\" [filterPlaceholder]=\"input.emptyFilterMessage\" [scrollHeight]=\"input.scrollHeight\" [display]=\"input.display\">\r\n @for (inputType of input.allTypes; track inputType) {\r\n <ng-template let-node [smzTemplate]=\"inputType\">\r\n @if (node != null) {\r\n <div [innerHTML]=\"node.label | safeHtml\" [smzTooltip]=\"node.tooltip\"></div>\r\n }\r\n </ng-template>\r\n }\r\n </ui-tree-select>\r\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\r\n </div>\r\n}", dependencies: [{ kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.SmzTooltipDirective, selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "component", type: i2.SmzTreeSelectComponent, selector: "ui-tree-select", inputs: ["options", "selectionMode", "placeholder", "filter", "filterPlaceholder", "emptyMessage", "showClear", "scrollHeight", "styleClass", "containerStyleClass", "appendTo", "display", "filterInputAutoFocus"] }, { kind: "component", type: LabelComponent, selector: "smz-label", inputs: ["text", "propertyName", "showLabel", "warning", "help", "popover"] }, { kind: "component", type: ValidationMessagesComponent, selector: "smz-validation-messages", inputs: ["input", "control", "behaviors", "extraMessages"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: SafeHtmlPipe$2, name: "safeHtml" }] });
|
|
4783
4781
|
}
|
|
4784
4782
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: InputTreeComponent, decorators: [{
|
|
4785
4783
|
type: Component,
|
|
4786
|
-
args: [{ selector: 'smz-input-tree', standalone: false, template: "@if (nodes$ | async; as nodes) {\n <smz-label\n class=\"smz__input_name\"\n [text]=\"input.name\"\n [propertyName]=\"input.propertyName\"\n [showLabel]=\"input.hideLabel != true\"\n [warning]=\"input.warning?.()\"\n [help]=\"input.tooltip?.()\"\n [popover]=\"input.popover?.()\">\n </smz-label>\n <div class=\"input_inner__wrapper grid grid-nogutter\">\n <ui-tree-select class=\"col-12 grid-nogutter smz__input_value flex-1\" containerStyleClass=\"w-full\" [formControl]=\"control\" [options]=\"nodes\" [placeholder]=\"input.name\" appendTo=\"body\" [filter]=\"input.showFilter ? true : false\" [selectionMode]=\"input.selectionMode\" [filterInputAutoFocus]=\"input.autofocusFilter\" [emptyMessage]=\"input.emptyMessage\" [showClear]=\"input.showClear\" [filterPlaceholder]=\"input.emptyFilterMessage\" [scrollHeight]=\"input.scrollHeight\" [display]=\"input.display\">\n @for (inputType of input.allTypes; track inputType) {\n <ng-template let-node [smzTemplate]=\"inputType\">\n @if (node != null) {\n <div [innerHTML]=\"node.label | safeHtml\" [smzTooltip]=\"node.tooltip\"></div>\n }\n </ng-template>\n }\n </ui-tree-select>\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\n </div>\n}" }]
|
|
4784
|
+
args: [{ selector: 'smz-input-tree', standalone: false, template: "@if (nodes$ | async; as nodes) {\r\n <smz-label\r\n class=\"smz__input_name\"\r\n [text]=\"input.name\"\r\n [propertyName]=\"input.propertyName\"\r\n [showLabel]=\"input.hideLabel != true\"\r\n [warning]=\"input.warning?.()\"\r\n [help]=\"input.tooltip?.()\"\r\n [popover]=\"input.popover?.()\">\r\n </smz-label>\r\n <div class=\"input_inner__wrapper grid grid-nogutter\">\r\n <ui-tree-select class=\"col-12 grid-nogutter smz__input_value flex-1\" containerStyleClass=\"w-full\" [formControl]=\"control\" [options]=\"nodes\" [placeholder]=\"input.name\" appendTo=\"body\" [filter]=\"input.showFilter ? true : false\" [selectionMode]=\"input.selectionMode\" [filterInputAutoFocus]=\"input.autofocusFilter\" [emptyMessage]=\"input.emptyMessage\" [showClear]=\"input.showClear\" [filterPlaceholder]=\"input.emptyFilterMessage\" [scrollHeight]=\"input.scrollHeight\" [display]=\"input.display\">\r\n @for (inputType of input.allTypes; track inputType) {\r\n <ng-template let-node [smzTemplate]=\"inputType\">\r\n @if (node != null) {\r\n <div [innerHTML]=\"node.label | safeHtml\" [smzTooltip]=\"node.tooltip\"></div>\r\n }\r\n </ng-template>\r\n }\r\n </ui-tree-select>\r\n <smz-validation-messages [input]=\"input\" [control]=\"control\" [behaviors]=\"behaviors\"></smz-validation-messages>\r\n </div>\r\n}" }]
|
|
4787
4785
|
}], ctorParameters: () => [{ type: SmzFormsDropdownService }], propDecorators: { input: [{
|
|
4788
4786
|
type: Input
|
|
4789
4787
|
}], formId: [{
|
|
@@ -5630,6 +5628,7 @@ var SmzBreakpoints;
|
|
|
5630
5628
|
LARGE: 'large',
|
|
5631
5629
|
EXTRA_LARGE: 'extraLarge',
|
|
5632
5630
|
};
|
|
5631
|
+
/** Prefixos de variante do Tailwind; os limites (576/768/992/1200px) sao os `screens` do preset. */
|
|
5633
5632
|
SmzBreakpoints.Tags = {
|
|
5634
5633
|
[SmzBreakpoints.Breakpoint.EXTRA_SMALL]: '',
|
|
5635
5634
|
[SmzBreakpoints.Breakpoint.SMALL]: 'sm:',
|
|
@@ -5637,46 +5636,40 @@ var SmzBreakpoints;
|
|
|
5637
5636
|
[SmzBreakpoints.Breakpoint.LARGE]: 'lg:',
|
|
5638
5637
|
[SmzBreakpoints.Breakpoint.EXTRA_LARGE]: 'xl:',
|
|
5639
5638
|
};
|
|
5640
|
-
SmzBreakpoints.ReplacePositions = {
|
|
5641
|
-
row: 4,
|
|
5642
|
-
verticalAlignment: 12,
|
|
5643
|
-
horizontalAlignment: 16,
|
|
5644
|
-
};
|
|
5645
|
-
SmzBreakpoints.ResponsiveGeneralTag = {
|
|
5646
|
-
row: {
|
|
5647
|
-
['col-1']: '1',
|
|
5648
|
-
['col-2']: '2',
|
|
5649
|
-
['col-3']: '3',
|
|
5650
|
-
['col-4']: '4',
|
|
5651
|
-
['col-5']: '5',
|
|
5652
|
-
['col-6']: '6',
|
|
5653
|
-
['col-7']: '7',
|
|
5654
|
-
['col-8']: '8',
|
|
5655
|
-
['col-9']: '9',
|
|
5656
|
-
['col-10']: '10',
|
|
5657
|
-
['col-11']: '11',
|
|
5658
|
-
['col-12']: '12',
|
|
5659
|
-
},
|
|
5660
|
-
verticalAlignment: {
|
|
5661
|
-
['items-start']: 'start',
|
|
5662
|
-
['items-center']: 'center',
|
|
5663
|
-
['items-end']: 'end',
|
|
5664
|
-
},
|
|
5665
|
-
horizontalAlignment: {
|
|
5666
|
-
['justify-start']: 'start',
|
|
5667
|
-
['justify-center']: 'center',
|
|
5668
|
-
['justify-end']: 'end',
|
|
5669
|
-
['justify-around']: 'around',
|
|
5670
|
-
['justify-between']: 'between',
|
|
5671
|
-
}
|
|
5672
|
-
};
|
|
5673
|
-
SmzBreakpoints.ResponsivePrimeTag = {
|
|
5674
|
-
row: { withTag: '', emptyTag: 'col-' },
|
|
5675
|
-
verticalAlignment: { withTag: 'items-', emptyTag: 'items-' },
|
|
5676
|
-
horizontalAlignment: { withTag: 'justify-', emptyTag: 'justify-' }
|
|
5677
|
-
};
|
|
5678
5639
|
})(SmzBreakpoints || (SmzBreakpoints = {}));
|
|
5679
5640
|
|
|
5641
|
+
const ORDER = ['extraSmall', 'small', 'medium', 'large', 'extraLarge'];
|
|
5642
|
+
/**
|
|
5643
|
+
* Classes de layout de um template responsivo. Funcao pura (sem Angular) para ser testavel em vitest.
|
|
5644
|
+
*
|
|
5645
|
+
* - `span` (padrao): filhos de `grid grid-cols-12` -> `col-span-N`, `sm:col-span-N`, ...
|
|
5646
|
+
* - `width`: elementos fora de uma grade (o proprio dialog, filho flex da mascara) -> `w-N/12` (`w-full` para 12).
|
|
5647
|
+
*
|
|
5648
|
+
* As classes sao montadas em runtime, por isso o preset do ui-kit as publica em `safelist`.
|
|
5649
|
+
*/
|
|
5650
|
+
function SetTemplateClasses(template, properties = ['row'], variant = 'span') {
|
|
5651
|
+
if (template == null || !properties.includes('row')) {
|
|
5652
|
+
return '';
|
|
5653
|
+
}
|
|
5654
|
+
const classes = [];
|
|
5655
|
+
for (const breakpoint of ORDER) {
|
|
5656
|
+
const columns = template[breakpoint]?.row;
|
|
5657
|
+
if (columns == null) {
|
|
5658
|
+
continue;
|
|
5659
|
+
}
|
|
5660
|
+
const prefix = SmzBreakpoints.Tags[breakpoint];
|
|
5661
|
+
classes.push(`${prefix}${columnsClass(columns, variant)}`);
|
|
5662
|
+
}
|
|
5663
|
+
return classes.join(' ');
|
|
5664
|
+
}
|
|
5665
|
+
function columnsClass(columns, variant) {
|
|
5666
|
+
const value = Math.min(12, Math.max(1, Math.round(Number(columns))));
|
|
5667
|
+
if (variant === 'width') {
|
|
5668
|
+
return value === 12 ? 'w-full' : `w-${value}/12`;
|
|
5669
|
+
}
|
|
5670
|
+
return `col-span-${value}`;
|
|
5671
|
+
}
|
|
5672
|
+
|
|
5680
5673
|
class SetTemplateClassesPipe {
|
|
5681
5674
|
transform(template, properties, append = []) {
|
|
5682
5675
|
const stylesToAppend = append == null ? '' : append.filter(x => x != null).join(' ');
|
|
@@ -5705,35 +5698,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImpor
|
|
|
5705
5698
|
exports: [SetTemplateClassesPipe],
|
|
5706
5699
|
}]
|
|
5707
5700
|
}] });
|
|
5708
|
-
function SetTemplateClasses(template, properties) {
|
|
5709
|
-
let response = '';
|
|
5710
|
-
if (template == null) {
|
|
5711
|
-
return response;
|
|
5712
|
-
}
|
|
5713
|
-
const tagKeys = Object.keys(template);
|
|
5714
|
-
for (const tag of tagKeys) {
|
|
5715
|
-
const tagConfig = template[tag];
|
|
5716
|
-
if (tagConfig == null) {
|
|
5717
|
-
continue;
|
|
5718
|
-
}
|
|
5719
|
-
const tagsMap = SmzBreakpoints.Tags;
|
|
5720
|
-
const prefix = `${tagsMap[tag]}col-`;
|
|
5721
|
-
for (const property of properties) {
|
|
5722
|
-
const propValue = tagConfig[property];
|
|
5723
|
-
if (propValue != null) {
|
|
5724
|
-
const replacePositions = SmzBreakpoints.ReplacePositions;
|
|
5725
|
-
const position = replacePositions[property];
|
|
5726
|
-
const value = String(propValue);
|
|
5727
|
-
const columns = value.slice(position, value.length);
|
|
5728
|
-
const responsivePrimeTag = SmzBreakpoints.ResponsivePrimeTag;
|
|
5729
|
-
const primeTag = responsivePrimeTag[property];
|
|
5730
|
-
const responsiveTag = prefix.length === 0 ? primeTag.emptyTag : primeTag.withTag;
|
|
5731
|
-
response += ` ${responsiveTag}${prefix}${columns}`;
|
|
5732
|
-
}
|
|
5733
|
-
}
|
|
5734
|
-
}
|
|
5735
|
-
return response;
|
|
5736
|
-
}
|
|
5737
5701
|
|
|
5738
5702
|
/* eslint-disable @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-unsafe-member-access, @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-return, @typescript-eslint/explicit-module-boundary-types, @typescript-eslint/explicit-function-return-type, @typescript-eslint/typedef, no-console, no-underscore-dangle, eqeqeq, @typescript-eslint/no-unused-vars, @typescript-eslint/explicit-member-accessibility, local-rules/no-unknown-member-access, max-len */
|
|
5739
5703
|
class FormGroupComponent {
|
|
@@ -6165,11 +6129,11 @@ class FormGroupComponent {
|
|
|
6165
6129
|
this.repository.remove(this.config);
|
|
6166
6130
|
}
|
|
6167
6131
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: FormGroupComponent, deps: [{ token: i1$1.UntypedFormBuilder }, { token: i0.ChangeDetectorRef }, { token: SmzFormsManagerService }, { token: SmzFormsRepositoryService }, { token: SmzFormValidationMessagesService }], target: i0.ɵɵFactoryTarget.Component });
|
|
6168
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: FormGroupComponent, isStandalone: false, selector: "smz-form-group", inputs: { config: "config" }, outputs: { statusChanges: "statusChanges", initialStateChanged: "initialStateChanged", previousStateChanged: "previousStateChanged", submit: "submit" }, providers: [SmzFormValidationMessagesService], usesOnChanges: true, ngImport: i0, template: "@if (config != null) {\n <div class=\"smz_form_grid_container\">\n @if (viewdata?.form != null && !configHasErrors) {\n <form focusFirstInput [focus]=\"!config.behaviors.avoidFocusOnLoad\" [formGroup]=\"viewdata.form\" class=\"smz_form__wrapper\" [attr.data-testid]=\"config.formTestId ?? null\" (submit)=\"$event.preventDefault()\" (keydown.enter)=\"onEnter($event)\">\n <ng-container *ngTemplateOutlet=\"groupTemplate\"></ng-container>\n </form>\n }\n @if (configHasErrors) {\n <div>Error</div>\n }\n </div>\n}\n\n<ng-template #groupTemplate>\n\n <div class=\"w-full px-0 mx-auto\">\n <div class=\"grid grid-nogutter flex-wrap items-start justify-start flex-gap-2\" [ngClass]=\"config.template | setTemplateClasses : ['horizontalAlignment', 'verticalAlignment']\">\n @for (group of config.groups; track group) {\n @if (!group.isHide) {\n <div class=\"col\" [ngClass]=\"group.template | setTemplateClasses : ['row']\">\n @if (group.showName) {\n <div class=\"smz__group_name\">{{ group.name }}</div>\n }\n <div [ngClass]=\"group.styleClass ?? 'grid grid-nogutter flex-wrap items-start justify-start flex-gap-2'\">\n @for (input of group.children; track input) {\n @if (input.isVisible) {\n <div class=\"input__control__wrapper col relative\" [ngClass]=\"input.template | setTemplateClasses : ['row'] : [input.styleClass, group.inputStyleClass]\">\n <ng-container *ngTemplateOutlet=\"inputTemplate; context: { $implicit: input }\"></ng-container>\n </div>\n }\n }\n </div>\n </div>\n }\n }\n </div>\n </div>\n\n</ng-template>\n\n<ng-template #inputTemplate let-input>\n\n @if (input.type == controlTypes.PASSWORD) {\n <smz-input-password [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-password>\n }\n\n @if (input.type == controlTypes.TEXT_MASK) {\n <smz-input-mask [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-mask>\n }\n\n @if (input.type == controlTypes.TEXT) {\n <smz-input-text [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-text>\n }\n\n @if (input.type == controlTypes.LIST) {\n <smz-input-list [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-list>\n }\n\n @if (input.type == controlTypes.NUMBER) {\n <smz-input-number [input]=\"input\" [form]=\"viewdata.form\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-number>\n }\n\n @if (input.type == controlTypes.TEXT_AREA) {\n <smz-input-text-area [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-text-area>\n }\n\n @if (input.type == controlTypes.CONTENT_MASK) {\n <smz-input-content-mask [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-content-mask>\n }\n\n @if (input.type == controlTypes.TAG_AREA) {\n <input-tag-area [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></input-tag-area>\n }\n\n @if (input.type == controlTypes.AUTOCOMPLETE_TAG_AREA) {\n <smz-input-autocomplete-tag-area [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-autocomplete-tag-area>\n }\n\n @if (input.type == controlTypes.RADIO) {\n <smz-radio-button [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-radio-button>\n }\n\n @if (input.type == controlTypes.SWITCH) {\n <smz-input-switch [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-switch>\n }\n\n @if (input.type == controlTypes.CHECKBOX) {\n <smz-checkbox [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-checkbox>\n }\n\n @if (input.type == controlTypes.CHECKBOX_GROUP) {\n <smz-checkbox-group [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-checkbox-group>\n }\n\n @if (input.type == controlTypes.CALENDAR) {\n <smz-calendar [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-calendar>\n }\n\n @if (input.type == controlTypes.DROPDOWN) {\n <smz-dropdown [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-dropdown>\n }\n\n @if (input.type == controlTypes.LINKED_DROPDOWN) {\n <smz-linked-dropdown [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-linked-dropdown>\n }\n\n @if (input.type == controlTypes.FILE) {\n <smz-file-upload [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [form]=\"viewdata.form\" [behaviors]=\"config.behaviors\"></smz-file-upload>\n }\n\n @if (input.type == controlTypes.CURRENCY) {\n <smz-input-currency [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-currency>\n }\n\n @if (input.type == controlTypes.MULTI_SELECT) {\n <smz-multi-select [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-multi-select>\n }\n\n @if (input.type == controlTypes.LINKED_MULTISELECT) {\n <smz-linked-multi-select [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-linked-multi-select>\n }\n\n @if (input.type == controlTypes.COLOR_PICKER) {\n <smz-color-picker [input]=\"input\" [control]=\"$any(viewdata.form.controls[input.propertyName])\" [behaviors]=\"config.behaviors\"></smz-color-picker>\n }\n\n @if (input.type == controlTypes.TEXT_BUTTON) {\n <smz-input-text-button [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [viewdata]=\"viewdata\" [behaviors]=\"config.behaviors\"></smz-input-text-button>\n }\n\n @if (input.type == controlTypes.TREE) {\n <smz-input-tree [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-input-tree>\n }\n\n</ng-template>\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: CalendarComponent, selector: "smz-calendar", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: CheckBoxComponent, selector: "smz-checkbox", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: CheckBoxGroupComponent, selector: "smz-checkbox-group", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: ColorPickerComponent, selector: "smz-color-picker", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: DropdownComponent, selector: "smz-dropdown", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: FileUploadComponent, selector: "smz-file-upload", inputs: ["input", "form", "control", "behaviors"], outputs: ["selectChange"] }, { kind: "directive", type: FormFocusFirstInputDirective, selector: "[focusFirstInput]", inputs: ["focus"] }, { kind: "component", type: InputCurrencyComponent, selector: "smz-input-currency", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputListComponent, selector: "smz-input-list", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputMaskComponent, selector: "smz-input-mask", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputNumberComponent, selector: "smz-input-number", inputs: ["input", "control", "behaviors", "form"] }, { kind: "component", type: InputPasswordComponent, selector: "smz-input-password", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputSwitchComponent, selector: "smz-input-switch", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputTextAreaComponent, selector: "smz-input-text-area", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: SmzInputAutocompleteTagArea, selector: "smz-input-autocomplete-tag-area", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputTextComponent, selector: "smz-input-text", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputTreeComponent, selector: "smz-input-tree", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: LinkedDropdownComponent, selector: "smz-linked-dropdown", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: LinkedMultiSelectComponent, selector: "smz-linked-multi-select", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: MultiSelectComponent, selector: "smz-multi-select", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: RadioButtonComponent, selector: "smz-radio-button", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: InputTagAreaComponent, selector: "input-tag-area", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputContentMaskComponent, selector: "smz-input-content-mask", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputTextButtonComponent, selector: "smz-input-text-button", inputs: ["input", "control", "viewdata", "behaviors"] }, { kind: "pipe", type: SetTemplateClassesPipe, name: "setTemplateClasses" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
6132
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: FormGroupComponent, isStandalone: false, selector: "smz-form-group", inputs: { config: "config" }, outputs: { statusChanges: "statusChanges", initialStateChanged: "initialStateChanged", previousStateChanged: "previousStateChanged", submit: "submit" }, providers: [SmzFormValidationMessagesService], usesOnChanges: true, ngImport: i0, template: "@if (config != null) {\r\n <div class=\"smz_form_grid_container\">\r\n @if (viewdata?.form != null && !configHasErrors) {\r\n <form focusFirstInput [focus]=\"!config.behaviors.avoidFocusOnLoad\" [formGroup]=\"viewdata.form\" class=\"smz_form__wrapper\" [attr.data-testid]=\"config.formTestId ?? null\" (submit)=\"$event.preventDefault()\" (keydown.enter)=\"onEnter($event)\">\r\n <ng-container *ngTemplateOutlet=\"groupTemplate\"></ng-container>\r\n </form>\r\n }\r\n @if (configHasErrors) {\r\n <div>Error</div>\r\n }\r\n </div>\r\n}\r\n\r\n<ng-template #groupTemplate>\r\n\r\n <div class=\"w-full px-0 mx-auto\">\r\n <div class=\"grid grid-cols-12 gap-4 items-start\">\r\n @for (group of config.groups; track group) {\r\n @if (!group.isHide) {\r\n <div class=\"min-w-0\" [ngClass]=\"group.template | setTemplateClasses : ['row']\">\r\n @if (group.showName) {\r\n <div class=\"smz__group_name\">{{ group.name }}</div>\r\n }\r\n <div [ngClass]=\"group.styleClass ?? 'grid grid-cols-12 gap-4 items-start'\">\r\n @for (input of group.children; track input) {\r\n @if (input.isVisible) {\r\n <div class=\"input__control__wrapper relative min-w-0\" [ngClass]=\"input.template | setTemplateClasses : ['row'] : [input.styleClass, group.inputStyleClass]\">\r\n <ng-container *ngTemplateOutlet=\"inputTemplate; context: { $implicit: input }\"></ng-container>\r\n </div>\r\n }\r\n }\r\n </div>\r\n </div>\r\n }\r\n }\r\n </div>\r\n </div>\r\n\r\n</ng-template>\r\n\r\n<ng-template #inputTemplate let-input>\r\n\r\n @if (input.type == controlTypes.PASSWORD) {\r\n <smz-input-password [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-password>\r\n }\r\n\r\n @if (input.type == controlTypes.TEXT_MASK) {\r\n <smz-input-mask [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-mask>\r\n }\r\n\r\n @if (input.type == controlTypes.TEXT) {\r\n <smz-input-text [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-text>\r\n }\r\n\r\n @if (input.type == controlTypes.LIST) {\r\n <smz-input-list [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-list>\r\n }\r\n\r\n @if (input.type == controlTypes.NUMBER) {\r\n <smz-input-number [input]=\"input\" [form]=\"viewdata.form\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-number>\r\n }\r\n\r\n @if (input.type == controlTypes.TEXT_AREA) {\r\n <smz-input-text-area [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-text-area>\r\n }\r\n\r\n @if (input.type == controlTypes.CONTENT_MASK) {\r\n <smz-input-content-mask [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-content-mask>\r\n }\r\n\r\n @if (input.type == controlTypes.TAG_AREA) {\r\n <input-tag-area [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></input-tag-area>\r\n }\r\n\r\n @if (input.type == controlTypes.AUTOCOMPLETE_TAG_AREA) {\r\n <smz-input-autocomplete-tag-area [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-autocomplete-tag-area>\r\n }\r\n\r\n @if (input.type == controlTypes.RADIO) {\r\n <smz-radio-button [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-radio-button>\r\n }\r\n\r\n @if (input.type == controlTypes.SWITCH) {\r\n <smz-input-switch [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-switch>\r\n }\r\n\r\n @if (input.type == controlTypes.CHECKBOX) {\r\n <smz-checkbox [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-checkbox>\r\n }\r\n\r\n @if (input.type == controlTypes.CHECKBOX_GROUP) {\r\n <smz-checkbox-group [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-checkbox-group>\r\n }\r\n\r\n @if (input.type == controlTypes.CALENDAR) {\r\n <smz-calendar [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-calendar>\r\n }\r\n\r\n @if (input.type == controlTypes.DROPDOWN) {\r\n <smz-dropdown [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-dropdown>\r\n }\r\n\r\n @if (input.type == controlTypes.LINKED_DROPDOWN) {\r\n <smz-linked-dropdown [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-linked-dropdown>\r\n }\r\n\r\n @if (input.type == controlTypes.FILE) {\r\n <smz-file-upload [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [form]=\"viewdata.form\" [behaviors]=\"config.behaviors\"></smz-file-upload>\r\n }\r\n\r\n @if (input.type == controlTypes.CURRENCY) {\r\n <smz-input-currency [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-currency>\r\n }\r\n\r\n @if (input.type == controlTypes.MULTI_SELECT) {\r\n <smz-multi-select [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-multi-select>\r\n }\r\n\r\n @if (input.type == controlTypes.LINKED_MULTISELECT) {\r\n <smz-linked-multi-select [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-linked-multi-select>\r\n }\r\n\r\n @if (input.type == controlTypes.COLOR_PICKER) {\r\n <smz-color-picker [input]=\"input\" [control]=\"$any(viewdata.form.controls[input.propertyName])\" [behaviors]=\"config.behaviors\"></smz-color-picker>\r\n }\r\n\r\n @if (input.type == controlTypes.TEXT_BUTTON) {\r\n <smz-input-text-button [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [viewdata]=\"viewdata\" [behaviors]=\"config.behaviors\"></smz-input-text-button>\r\n }\r\n\r\n @if (input.type == controlTypes.TREE) {\r\n <smz-input-tree [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-input-tree>\r\n }\r\n\r\n</ng-template>\r\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: CalendarComponent, selector: "smz-calendar", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: CheckBoxComponent, selector: "smz-checkbox", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: CheckBoxGroupComponent, selector: "smz-checkbox-group", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: ColorPickerComponent, selector: "smz-color-picker", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: DropdownComponent, selector: "smz-dropdown", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: FileUploadComponent, selector: "smz-file-upload", inputs: ["input", "form", "control", "behaviors"], outputs: ["selectChange"] }, { kind: "directive", type: FormFocusFirstInputDirective, selector: "[focusFirstInput]", inputs: ["focus"] }, { kind: "component", type: InputCurrencyComponent, selector: "smz-input-currency", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputListComponent, selector: "smz-input-list", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputMaskComponent, selector: "smz-input-mask", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputNumberComponent, selector: "smz-input-number", inputs: ["input", "control", "behaviors", "form"] }, { kind: "component", type: InputPasswordComponent, selector: "smz-input-password", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputSwitchComponent, selector: "smz-input-switch", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputTextAreaComponent, selector: "smz-input-text-area", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: SmzInputAutocompleteTagArea, selector: "smz-input-autocomplete-tag-area", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputTextComponent, selector: "smz-input-text", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputTreeComponent, selector: "smz-input-tree", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: LinkedDropdownComponent, selector: "smz-linked-dropdown", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: LinkedMultiSelectComponent, selector: "smz-linked-multi-select", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: MultiSelectComponent, selector: "smz-multi-select", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: RadioButtonComponent, selector: "smz-radio-button", inputs: ["input", "formId", "control", "behaviors"] }, { kind: "component", type: InputTagAreaComponent, selector: "input-tag-area", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputContentMaskComponent, selector: "smz-input-content-mask", inputs: ["input", "control", "behaviors"] }, { kind: "component", type: InputTextButtonComponent, selector: "smz-input-text-button", inputs: ["input", "control", "viewdata", "behaviors"] }, { kind: "pipe", type: SetTemplateClassesPipe, name: "setTemplateClasses" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
6169
6133
|
}
|
|
6170
6134
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: FormGroupComponent, decorators: [{
|
|
6171
6135
|
type: Component,
|
|
6172
|
-
args: [{ selector: 'smz-form-group', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [SmzFormValidationMessagesService], standalone: false, template: "@if (config != null) {\n <div class=\"smz_form_grid_container\">\n @if (viewdata?.form != null && !configHasErrors) {\n <form focusFirstInput [focus]=\"!config.behaviors.avoidFocusOnLoad\" [formGroup]=\"viewdata.form\" class=\"smz_form__wrapper\" [attr.data-testid]=\"config.formTestId ?? null\" (submit)=\"$event.preventDefault()\" (keydown.enter)=\"onEnter($event)\">\n <ng-container *ngTemplateOutlet=\"groupTemplate\"></ng-container>\n </form>\n }\n @if (configHasErrors) {\n <div>Error</div>\n }\n </div>\n}\n\n<ng-template #groupTemplate>\n\n <div class=\"w-full px-0 mx-auto\">\n <div class=\"grid grid-
|
|
6136
|
+
args: [{ selector: 'smz-form-group', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [SmzFormValidationMessagesService], standalone: false, template: "@if (config != null) {\r\n <div class=\"smz_form_grid_container\">\r\n @if (viewdata?.form != null && !configHasErrors) {\r\n <form focusFirstInput [focus]=\"!config.behaviors.avoidFocusOnLoad\" [formGroup]=\"viewdata.form\" class=\"smz_form__wrapper\" [attr.data-testid]=\"config.formTestId ?? null\" (submit)=\"$event.preventDefault()\" (keydown.enter)=\"onEnter($event)\">\r\n <ng-container *ngTemplateOutlet=\"groupTemplate\"></ng-container>\r\n </form>\r\n }\r\n @if (configHasErrors) {\r\n <div>Error</div>\r\n }\r\n </div>\r\n}\r\n\r\n<ng-template #groupTemplate>\r\n\r\n <div class=\"w-full px-0 mx-auto\">\r\n <div class=\"grid grid-cols-12 gap-4 items-start\">\r\n @for (group of config.groups; track group) {\r\n @if (!group.isHide) {\r\n <div class=\"min-w-0\" [ngClass]=\"group.template | setTemplateClasses : ['row']\">\r\n @if (group.showName) {\r\n <div class=\"smz__group_name\">{{ group.name }}</div>\r\n }\r\n <div [ngClass]=\"group.styleClass ?? 'grid grid-cols-12 gap-4 items-start'\">\r\n @for (input of group.children; track input) {\r\n @if (input.isVisible) {\r\n <div class=\"input__control__wrapper relative min-w-0\" [ngClass]=\"input.template | setTemplateClasses : ['row'] : [input.styleClass, group.inputStyleClass]\">\r\n <ng-container *ngTemplateOutlet=\"inputTemplate; context: { $implicit: input }\"></ng-container>\r\n </div>\r\n }\r\n }\r\n </div>\r\n </div>\r\n }\r\n }\r\n </div>\r\n </div>\r\n\r\n</ng-template>\r\n\r\n<ng-template #inputTemplate let-input>\r\n\r\n @if (input.type == controlTypes.PASSWORD) {\r\n <smz-input-password [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-password>\r\n }\r\n\r\n @if (input.type == controlTypes.TEXT_MASK) {\r\n <smz-input-mask [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-mask>\r\n }\r\n\r\n @if (input.type == controlTypes.TEXT) {\r\n <smz-input-text [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-text>\r\n }\r\n\r\n @if (input.type == controlTypes.LIST) {\r\n <smz-input-list [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-list>\r\n }\r\n\r\n @if (input.type == controlTypes.NUMBER) {\r\n <smz-input-number [input]=\"input\" [form]=\"viewdata.form\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-number>\r\n }\r\n\r\n @if (input.type == controlTypes.TEXT_AREA) {\r\n <smz-input-text-area [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-text-area>\r\n }\r\n\r\n @if (input.type == controlTypes.CONTENT_MASK) {\r\n <smz-input-content-mask [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-content-mask>\r\n }\r\n\r\n @if (input.type == controlTypes.TAG_AREA) {\r\n <input-tag-area [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></input-tag-area>\r\n }\r\n\r\n @if (input.type == controlTypes.AUTOCOMPLETE_TAG_AREA) {\r\n <smz-input-autocomplete-tag-area [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-autocomplete-tag-area>\r\n }\r\n\r\n @if (input.type == controlTypes.RADIO) {\r\n <smz-radio-button [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-radio-button>\r\n }\r\n\r\n @if (input.type == controlTypes.SWITCH) {\r\n <smz-input-switch [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-switch>\r\n }\r\n\r\n @if (input.type == controlTypes.CHECKBOX) {\r\n <smz-checkbox [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-checkbox>\r\n }\r\n\r\n @if (input.type == controlTypes.CHECKBOX_GROUP) {\r\n <smz-checkbox-group [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-checkbox-group>\r\n }\r\n\r\n @if (input.type == controlTypes.CALENDAR) {\r\n <smz-calendar [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-calendar>\r\n }\r\n\r\n @if (input.type == controlTypes.DROPDOWN) {\r\n <smz-dropdown [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-dropdown>\r\n }\r\n\r\n @if (input.type == controlTypes.LINKED_DROPDOWN) {\r\n <smz-linked-dropdown [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-linked-dropdown>\r\n }\r\n\r\n @if (input.type == controlTypes.FILE) {\r\n <smz-file-upload [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [form]=\"viewdata.form\" [behaviors]=\"config.behaviors\"></smz-file-upload>\r\n }\r\n\r\n @if (input.type == controlTypes.CURRENCY) {\r\n <smz-input-currency [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [behaviors]=\"config.behaviors\"></smz-input-currency>\r\n }\r\n\r\n @if (input.type == controlTypes.MULTI_SELECT) {\r\n <smz-multi-select [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-multi-select>\r\n }\r\n\r\n @if (input.type == controlTypes.LINKED_MULTISELECT) {\r\n <smz-linked-multi-select [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-linked-multi-select>\r\n }\r\n\r\n @if (input.type == controlTypes.COLOR_PICKER) {\r\n <smz-color-picker [input]=\"input\" [control]=\"$any(viewdata.form.controls[input.propertyName])\" [behaviors]=\"config.behaviors\"></smz-color-picker>\r\n }\r\n\r\n @if (input.type == controlTypes.TEXT_BUTTON) {\r\n <smz-input-text-button [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [viewdata]=\"viewdata\" [behaviors]=\"config.behaviors\"></smz-input-text-button>\r\n }\r\n\r\n @if (input.type == controlTypes.TREE) {\r\n <smz-input-tree [input]=\"input\" [control]=\"getFormControl(input.propertyName)\" [formId]=\"config.formId\" [behaviors]=\"config.behaviors\"></smz-input-tree>\r\n }\r\n\r\n</ng-template>\r\n" }]
|
|
6173
6137
|
}], ctorParameters: () => [{ type: i1$1.UntypedFormBuilder }, { type: i0.ChangeDetectorRef }, { type: SmzFormsManagerService }, { type: SmzFormsRepositoryService }, { type: SmzFormValidationMessagesService }], propDecorators: { config: [{
|
|
6174
6138
|
type: Input
|
|
6175
6139
|
}], statusChanges: [{
|
|
@@ -7113,7 +7077,7 @@ class InputListDialogCrudComponent {
|
|
|
7113
7077
|
propertyName: 'name', name: 'nome', type: SmzControlType.TEXT, hideName: true,
|
|
7114
7078
|
validatorsPreset: { isRequired: true },
|
|
7115
7079
|
advancedSettings: { validators: [MustBeUnique(this.config.data.input.options)], validationMessages: [{ type: 'unique', message: 'Já existe um item com esse dado.' }] },
|
|
7116
|
-
template: { large: { row:
|
|
7080
|
+
template: { large: { row: 12 } },
|
|
7117
7081
|
defaultValue: defaultValue,
|
|
7118
7082
|
autoFocus: true
|
|
7119
7083
|
};
|
|
@@ -7132,7 +7096,7 @@ class InputListDialogCrudComponent {
|
|
|
7132
7096
|
{
|
|
7133
7097
|
name: '', showName: false,
|
|
7134
7098
|
children: [input ?? textInput],
|
|
7135
|
-
template: { large: { row:
|
|
7099
|
+
template: { large: { row: 12 } }
|
|
7136
7100
|
}
|
|
7137
7101
|
],
|
|
7138
7102
|
};
|
|
@@ -7189,7 +7153,7 @@ class InputListInlineCrudComponent {
|
|
|
7189
7153
|
propertyName: 'name', name: 'nome', type: SmzControlType.TEXT, hideName: true,
|
|
7190
7154
|
validatorsPreset: { isRequired: true },
|
|
7191
7155
|
advancedSettings: { validators: [MustBeUnique(this.input.options)], validationMessages: [{ type: 'unique', message: 'Já existe um item com esse dado.' }] },
|
|
7192
|
-
template: { large: { row:
|
|
7156
|
+
template: { large: { row: 12 } },
|
|
7193
7157
|
defaultValue: this.defaultValue,
|
|
7194
7158
|
};
|
|
7195
7159
|
const input = this.input.crud?.inputData != null ? {
|
|
@@ -7207,7 +7171,7 @@ class InputListInlineCrudComponent {
|
|
|
7207
7171
|
{
|
|
7208
7172
|
name: '', showName: false,
|
|
7209
7173
|
children: [input ?? textInput],
|
|
7210
|
-
template: { large: { row:
|
|
7174
|
+
template: { large: { row: 12 } }
|
|
7211
7175
|
}
|
|
7212
7176
|
],
|
|
7213
7177
|
};
|
|
@@ -7265,7 +7229,7 @@ class InputListBatchCrudComponent {
|
|
|
7265
7229
|
propertyName: 'names', name: 'Nomes', type: SmzControlType.TEXT_AREA, hideName: true,
|
|
7266
7230
|
validatorsPreset: { isRequired: true },
|
|
7267
7231
|
advancedSettings: { validators: [unique(this.config.data.input.options)], validationMessages: [{ type: 'unique', message: 'Já existe um item com esse nome.' }] },
|
|
7268
|
-
template: { large: { row:
|
|
7232
|
+
template: { large: { row: 12 } },
|
|
7269
7233
|
defaultValue: defaultValue,
|
|
7270
7234
|
};
|
|
7271
7235
|
const form = {
|
|
@@ -7275,7 +7239,7 @@ class InputListBatchCrudComponent {
|
|
|
7275
7239
|
{
|
|
7276
7240
|
name: '', showName: false,
|
|
7277
7241
|
children: [input],
|
|
7278
|
-
template: { large: { row:
|
|
7242
|
+
template: { large: { row: 12 } }
|
|
7279
7243
|
}
|
|
7280
7244
|
],
|
|
7281
7245
|
};
|
|
@@ -7840,11 +7804,11 @@ class DialogContentManagerComponent {
|
|
|
7840
7804
|
ngOnInit() {
|
|
7841
7805
|
}
|
|
7842
7806
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: DialogContentManagerComponent, deps: [{ token: DynamicDialogRef }, { token: SmzDynamicDialogConfig }, { token: SmzDialogsVisibilityService }], target: i0.ɵɵFactoryTarget.Component });
|
|
7843
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: DialogContentManagerComponent, isStandalone: false, selector: "smz-dialog-content-manager", ngImport: i0, template: "<div class=\"smz-dialog-content smz_form_grid_container\" [ngClass]=\"config.data.contentClass\">\r\n\r\n <div class=\"smz-dialog-container\">\r\n <div [ngClass]=\"config.data.featureContainerClass ?? 'grid grid-
|
|
7807
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: DialogContentManagerComponent, isStandalone: false, selector: "smz-dialog-content-manager", ngImport: i0, template: "<div class=\"smz-dialog-content smz_form_grid_container\" [ngClass]=\"config.data.contentClass\">\r\n\r\n <div class=\"smz-dialog-container\">\r\n <div [ngClass]=\"config.data.featureContainerClass ?? 'grid grid-cols-12 items-start'\">\r\n\r\n <!-- <ui-progress-bar *ngIf=\"config.data._context.isLoading\" mode=\"indeterminate\" [ngStyle]=\"{ 'width': '100%;' }\" class=\"dialog-loading\"></ui-progress-bar> -->\r\n @for (error of config.data._context.apiErrors; track error) {\r\n <ui-message class=\"dialog-messages col-span-full w-full\">\r\n {{error}}\r\n </ui-message>\r\n }\r\n\r\n @for (feature of config.data._context.injectables; track feature) {\r\n <div class=\"min-w-0\" [ngClass]=\"(feature.template != null ? feature.template : config.data._context.featureTemplate) | setTemplateClasses : ['row']\">\r\n @if (feature.visibilityDependsOn != null) {\r\n @if ((visibility.observers[feature.componentId + feature.component.name].visibility$ | async); as visibilityState) {\r\n @if (!feature.visibilityDependsOn.reversed === visibilityState.state || feature.visibilityDependsOn.reversed === !visibilityState.state) {\r\n <ng-template [appInjectComponent]=\"feature\" [context]=\"config.data._context\"></ng-template>\r\n }\r\n }\r\n }\r\n @if (feature.visibilityDependsOn == null) {\r\n <ng-template [appInjectComponent]=\"feature\" [context]=\"config.data._context\"></ng-template>\r\n }\r\n </div>\r\n }\r\n\r\n </div>\r\n </div>\r\n\r\n</div>", styles: [":root{--smz-dialog-padding: 1em}smz-general-dialog p-toolbar .ui-toolbar{background-color:unset;border:unset;padding:var(--smz-dialog-padding)}smz-general-dialog .smz-dialog-container{position:absolute;top:var(--smz-dialog-padding);left:var(--smz-dialog-padding);right:var(--smz-dialog-padding);bottom:calc(var(--smz-dialog-padding) * 4);overflow:scroll}smz-general-dialog .smz-dialog-footer{position:absolute;bottom:0;left:0;right:0;z-index:auto}smz-general-dialog .smz_dialog_disabled{-webkit-user-select:none!important;user-select:none!important;pointer-events:none!important;filter:brightness(70%)!important}smz-general-dialog .smz-group-right{float:right}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: i2.SmzMessageComponent, selector: "ui-message", inputs: ["severity", "text", "icon"] }, { kind: "directive", type: InjectComponentDirective, selector: "[appInjectComponent]", inputs: ["appInjectComponent", "context"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: SetTemplateClassesPipe, name: "setTemplateClasses" }], encapsulation: i0.ViewEncapsulation.None });
|
|
7844
7808
|
}
|
|
7845
7809
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: DialogContentManagerComponent, decorators: [{
|
|
7846
7810
|
type: Component,
|
|
7847
|
-
args: [{ selector: 'smz-dialog-content-manager', encapsulation: ViewEncapsulation.None, standalone: false, template: "<div class=\"smz-dialog-content smz_form_grid_container\" [ngClass]=\"config.data.contentClass\">\r\n\r\n <div class=\"smz-dialog-container\">\r\n <div [ngClass]=\"config.data.featureContainerClass ?? 'grid grid-
|
|
7811
|
+
args: [{ selector: 'smz-dialog-content-manager', encapsulation: ViewEncapsulation.None, standalone: false, template: "<div class=\"smz-dialog-content smz_form_grid_container\" [ngClass]=\"config.data.contentClass\">\r\n\r\n <div class=\"smz-dialog-container\">\r\n <div [ngClass]=\"config.data.featureContainerClass ?? 'grid grid-cols-12 items-start'\">\r\n\r\n <!-- <ui-progress-bar *ngIf=\"config.data._context.isLoading\" mode=\"indeterminate\" [ngStyle]=\"{ 'width': '100%;' }\" class=\"dialog-loading\"></ui-progress-bar> -->\r\n @for (error of config.data._context.apiErrors; track error) {\r\n <ui-message class=\"dialog-messages col-span-full w-full\">\r\n {{error}}\r\n </ui-message>\r\n }\r\n\r\n @for (feature of config.data._context.injectables; track feature) {\r\n <div class=\"min-w-0\" [ngClass]=\"(feature.template != null ? feature.template : config.data._context.featureTemplate) | setTemplateClasses : ['row']\">\r\n @if (feature.visibilityDependsOn != null) {\r\n @if ((visibility.observers[feature.componentId + feature.component.name].visibility$ | async); as visibilityState) {\r\n @if (!feature.visibilityDependsOn.reversed === visibilityState.state || feature.visibilityDependsOn.reversed === !visibilityState.state) {\r\n <ng-template [appInjectComponent]=\"feature\" [context]=\"config.data._context\"></ng-template>\r\n }\r\n }\r\n }\r\n @if (feature.visibilityDependsOn == null) {\r\n <ng-template [appInjectComponent]=\"feature\" [context]=\"config.data._context\"></ng-template>\r\n }\r\n </div>\r\n }\r\n\r\n </div>\r\n </div>\r\n\r\n</div>", styles: [":root{--smz-dialog-padding: 1em}smz-general-dialog p-toolbar .ui-toolbar{background-color:unset;border:unset;padding:var(--smz-dialog-padding)}smz-general-dialog .smz-dialog-container{position:absolute;top:var(--smz-dialog-padding);left:var(--smz-dialog-padding);right:var(--smz-dialog-padding);bottom:calc(var(--smz-dialog-padding) * 4);overflow:scroll}smz-general-dialog .smz-dialog-footer{position:absolute;bottom:0;left:0;right:0;z-index:auto}smz-general-dialog .smz_dialog_disabled{-webkit-user-select:none!important;user-select:none!important;pointer-events:none!important;filter:brightness(70%)!important}smz-general-dialog .smz-group-right{float:right}\n"] }]
|
|
7848
7812
|
}], ctorParameters: () => [{ type: DynamicDialogRef }, { type: SmzDynamicDialogConfig }, { type: SmzDialogsVisibilityService }] });
|
|
7849
7813
|
|
|
7850
7814
|
class MessageContentComponent {
|
|
@@ -8248,6 +8212,7 @@ class DynamicDialogComponent {
|
|
|
8248
8212
|
this.container = event.element;
|
|
8249
8213
|
this.wrapper = this.container.parentElement;
|
|
8250
8214
|
this.moveOnTop();
|
|
8215
|
+
this.promoteToTopLayer();
|
|
8251
8216
|
this.bindGlobalListeners();
|
|
8252
8217
|
if (this.config.modal !== false) {
|
|
8253
8218
|
this.enableModality();
|
|
@@ -8261,6 +8226,25 @@ class DynamicDialogComponent {
|
|
|
8261
8226
|
break;
|
|
8262
8227
|
}
|
|
8263
8228
|
}
|
|
8229
|
+
/**
|
|
8230
|
+
* Overlays do CDK (ui-drawer, ui-dialog, menus...) vivem na top layer do navegador (Popover API), onde `z-index` nao
|
|
8231
|
+
* adianta: um dialog fora dela fica SEMPRE atras do backdrop deles. Promove a mascara do dialog a `popover="manual"`:
|
|
8232
|
+
* a top layer empilha pela ordem de abertura, entao um dialog aberto depois aparece acima do que ja estava aberto.
|
|
8233
|
+
* Sem suporte a Popover API, segue so com z-index.
|
|
8234
|
+
*/
|
|
8235
|
+
promoteToTopLayer() {
|
|
8236
|
+
const mask = this.maskViewChild?.nativeElement;
|
|
8237
|
+
if (!mask || typeof mask.showPopover !== 'function') {
|
|
8238
|
+
return;
|
|
8239
|
+
}
|
|
8240
|
+
try {
|
|
8241
|
+
mask.setAttribute('popover', 'manual');
|
|
8242
|
+
mask.showPopover();
|
|
8243
|
+
}
|
|
8244
|
+
catch {
|
|
8245
|
+
mask.removeAttribute('popover');
|
|
8246
|
+
}
|
|
8247
|
+
}
|
|
8264
8248
|
onAnimationEnd(event) {
|
|
8265
8249
|
if (event.toState === 'void') {
|
|
8266
8250
|
this.onContainerDestroy();
|
|
@@ -8298,6 +8282,7 @@ class DynamicDialogComponent {
|
|
|
8298
8282
|
}
|
|
8299
8283
|
maximize() {
|
|
8300
8284
|
this.maximized = !this.maximized;
|
|
8285
|
+
this.syncSizeAroundMaximize();
|
|
8301
8286
|
if (!this.config.modal) {
|
|
8302
8287
|
if (this.maximized) {
|
|
8303
8288
|
SmzDomHandler.addClass(document.body, 'p-overflow-hidden');
|
|
@@ -8308,6 +8293,32 @@ class DynamicDialogComponent {
|
|
|
8308
8293
|
}
|
|
8309
8294
|
this.onMaximize.emit({ maximized: this.maximized });
|
|
8310
8295
|
}
|
|
8296
|
+
/**
|
|
8297
|
+
* O dialog tem tamanho automatico (segue o conteudo). Conteudo que fixa tamanho em px enquanto o dialog esta
|
|
8298
|
+
* maximizado (tabelas, graficos, componentes que medem o contentor) o deixaria maior ao restaurar. Guarda o
|
|
8299
|
+
* tamanho de antes de maximizar e, ao restaurar, o usa como teto (max-width/max-height): o dialog volta ao
|
|
8300
|
+
* tamanho original e ainda pode encolher se o conteudo encolher. Tamanhos definidos pelo consumidor (`width`,
|
|
8301
|
+
* `height`, `style`) sao respeitados e nao sao tocados.
|
|
8302
|
+
*/
|
|
8303
|
+
syncSizeAroundMaximize() {
|
|
8304
|
+
const container = this.container;
|
|
8305
|
+
if (!container)
|
|
8306
|
+
return;
|
|
8307
|
+
container.style.removeProperty('max-width');
|
|
8308
|
+
container.style.removeProperty('max-height');
|
|
8309
|
+
if (this.maximized) {
|
|
8310
|
+
this.preMaximizeContainerWidth = container.offsetWidth;
|
|
8311
|
+
this.preMaximizeContainerHeight = container.offsetHeight;
|
|
8312
|
+
return;
|
|
8313
|
+
}
|
|
8314
|
+
const style = (this.config.style ?? {});
|
|
8315
|
+
if (this.preMaximizeContainerWidth > 0 && !this.config.width && style['width'] == null && style['maxWidth'] == null) {
|
|
8316
|
+
container.style.maxWidth = `${this.preMaximizeContainerWidth}px`;
|
|
8317
|
+
}
|
|
8318
|
+
if (this.preMaximizeContainerHeight > 0 && !this.config.height && style['height'] == null && style['maxHeight'] == null) {
|
|
8319
|
+
container.style.maxHeight = `${this.preMaximizeContainerHeight}px`;
|
|
8320
|
+
}
|
|
8321
|
+
}
|
|
8311
8322
|
enableModality() {
|
|
8312
8323
|
if (this.config.closable !== false && this.config.dismissableMask) {
|
|
8313
8324
|
this.maskClickListener = this.renderer.listen(this.wrapper, 'mousedown', (event) => {
|
|
@@ -8403,16 +8414,24 @@ class DynamicDialogComponent {
|
|
|
8403
8414
|
}
|
|
8404
8415
|
}
|
|
8405
8416
|
bindDocumentEscapeListener() {
|
|
8406
|
-
|
|
8407
|
-
|
|
8408
|
-
const
|
|
8409
|
-
if (event.
|
|
8410
|
-
|
|
8411
|
-
this.hide();
|
|
8412
|
-
}
|
|
8417
|
+
// Captura na `window` (antes do listener no `body` do CDK): o ESC do dialog do topo fecha so ele e nao chega a um
|
|
8418
|
+
// overlay do CDK aberto por baixo (ex.: ui-drawer), que fecharia junto.
|
|
8419
|
+
const listener = (event) => {
|
|
8420
|
+
if (event.key !== 'Escape' || !this.container) {
|
|
8421
|
+
return;
|
|
8413
8422
|
}
|
|
8414
|
-
|
|
8415
|
-
|
|
8423
|
+
if (parseInt(this.container.style.zIndex, 10) !== SmzZIndex.getCurrent()) {
|
|
8424
|
+
return;
|
|
8425
|
+
}
|
|
8426
|
+
event.stopPropagation();
|
|
8427
|
+
const data = this.dialogConfig.data;
|
|
8428
|
+
const dialogContext = data.context ?? data['_context'];
|
|
8429
|
+
if (!dialogContext?.isLoading) {
|
|
8430
|
+
this.zone.run(() => this.hide());
|
|
8431
|
+
}
|
|
8432
|
+
};
|
|
8433
|
+
window.addEventListener('keydown', listener, true);
|
|
8434
|
+
this.documentEscapeListener = () => window.removeEventListener('keydown', listener, true);
|
|
8416
8435
|
}
|
|
8417
8436
|
unbindDocumentEscapeListener() {
|
|
8418
8437
|
if (this.documentEscapeListener) {
|
|
@@ -8434,69 +8453,69 @@ class DynamicDialogComponent {
|
|
|
8434
8453
|
this.overlayPanel?.kill();
|
|
8435
8454
|
}
|
|
8436
8455
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: DynamicDialogComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.Renderer2 }, { token: DynamicDialogConfig }, { token: DynamicDialogRef }, { token: i0.NgZone }, { token: SmzDynamicDialogConfig }, { token: SmzDockService }], target: i0.ɵɵFactoryTarget.Component });
|
|
8437
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: DynamicDialogComponent, isStandalone: false, selector: "smz-dynamicDialog", outputs: { onMaximize: "onMaximize", onMinimize: "onMinimize" }, host: { listeners: { "document:keydown.escape": "onEscapeHandler($event)" }, properties: { "attr.id": "this.domId" }, classAttribute: "p-element" }, viewQueries: [{ propertyName: "insertionPoint", first: true, predicate: DynamicDialogContent, descendants: true }, { propertyName: "insertionFooter", first: true, predicate: DynamicDialogFooter, descendants: true }, { propertyName: "maskViewChild", first: true, predicate: ["mask"], descendants: true }, { propertyName: "containerViewChild", first: true, predicate: ["dialogContainer"], descendants: true }, { propertyName: "highlightPanelViewChild", first: true, predicate: ["highlightPanel"], descendants: true }, { propertyName: "overlayPanelClipViewChild", first: true, predicate: ["overlayPanelClip"], descendants: true }, { propertyName: "overlayBlendClipViewChild", first: true, predicate: ["overlayBlendClip"], descendants: true }], ngImport: i0, template: `
|
|
8438
|
-
|
|
8439
|
-
@if (dialogConfig.data.behaviors.showAsLinkedOverlayPanel) {
|
|
8440
|
-
<div #overlayBlendClip id="blend-clip" class="fixed inset-0" [ngClass]="dialogConfig.data.overlayPanel?.overlayBlendStylesClass"></div>
|
|
8441
|
-
}
|
|
8442
|
-
@if (dialogConfig.data.behaviors.showAsLinkedOverlayPanel) {
|
|
8443
|
-
<div #overlayPanelClip id="overlay-clip" class="fixed inset-0 p-component-overlay p-component-overlay-enter" [ngClass]="dialogConfig.data.overlayPanel?.overlayPanelStylesClass"></div>
|
|
8444
|
-
}
|
|
8445
|
-
@if (dialogConfig.data.behaviors.showAsLinkedOverlayPanel) {
|
|
8446
|
-
<div #highlightPanel id="highlight-clip" class="fixed inset-0" [ngClass]="dialogConfig.data.overlayPanel?.hightlightStyleClass"></div>
|
|
8447
|
-
}
|
|
8448
|
-
<div #mask id="dialog-mask" [attr.data-testid]="buildDialogTestId('mask')" [ngClass]="{'p-dialog-mask-free': dialogConfig.data.behaviors.showAsLinkedOverlayPanel, 'p-component-overlay p-component-overlay-enter' : config.modal !== false && !dialogConfig.data.behaviors.showAsLinkedOverlayPanel, 'p-dialog-mask-scrollblocker': config.modal !== false, 'smz-dialog-minimized': minimized }" class="smz_form_grid_container p-dialog-mask">
|
|
8449
|
-
@if (visible) {
|
|
8450
|
-
<div #dialogContainer id="dialog-container" [attr.data-testid]="buildDialogTestId()" [smzAutoFocus]="config.autoFocus" [ngClass]="{'p-dialog p-dynamic-dialog p-component': true, 'p-dialog-rtl': config.rtl, 'p-dialog-maximized': maximized}" [ngStyle]="config.style" class="{{ config.styleClass }} {{ dialogConfig?.data?.containerStyleClass }}"
|
|
8451
|
-
[@animation]="{value: 'visible', params: {transform: transformOptions, transition: config.transitionOptions || '150ms cubic-bezier(0, 0, 0.2, 1)'}}"
|
|
8452
|
-
(@animation.start)="onAnimationStart($event)" (@animation.done)="onAnimationEnd($event)" role="dialog"
|
|
8453
|
-
[style.width]="config.width" [style.height]="config.height">
|
|
8454
|
-
@if (config.showHeader === false ? false: true) {
|
|
8455
|
-
<div class="p-dialog-header" [attr.data-testid]="buildDialogTestId('header')" [ngStyle]="config.headerStyle">
|
|
8456
|
-
<div class="p-dialog-title w-full" [attr.data-testid]="buildDialogTestId('title')" [innerHTML]="config.header | safeHtml"></div>
|
|
8457
|
-
<div class="p-dialog-header-icons flex gap-3" [ngClass]="{ 'disable-a': dialogConfig.data._context.isGlobalDisabled }">
|
|
8458
|
-
@for (topbarButton of dialogConfig.data.topbarButtons; track $index) {
|
|
8459
|
-
@if (topbarButton.visible) {
|
|
8460
|
-
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildTopbarButtonTestId(topbarButton, $index)" (click)="topbarButton.onClick()" [smzTooltip]="topbarButton.tooltip">
|
|
8461
|
-
<span [ngClass]="topbarButton.class"></span>
|
|
8462
|
-
</button>
|
|
8463
|
-
}
|
|
8464
|
-
}
|
|
8465
|
-
@if (config.minimizable !== false) {
|
|
8466
|
-
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('minimize')" (click)="minimize()" (keydown.enter)="minimize()">
|
|
8467
|
-
<span class="p-dialog-header-close-icon fa-solid fa-minus"></span>
|
|
8468
|
-
</button>
|
|
8469
|
-
}
|
|
8470
|
-
@if (config.maximizable !== false && !maximized) {
|
|
8471
|
-
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('maximize')" (click)="maximize()" (keydown.enter)="maximize()">
|
|
8472
|
-
<span class="p-dialog-header-close-icon" [ngClass]="maximizeIcon"></span>
|
|
8473
|
-
</button>
|
|
8474
|
-
}
|
|
8475
|
-
@if (maximized && !config.blockRestoreButton) {
|
|
8476
|
-
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('restore')" (click)="maximize()" (keydown.enter)="maximize()">
|
|
8477
|
-
<span class="p-dialog-header-close-icon" [ngClass]="minimizeIcon"></span>
|
|
8478
|
-
</button>
|
|
8479
|
-
}
|
|
8480
|
-
@if (config.closable !== false) {
|
|
8481
|
-
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('close')" (click)="hide()" (keydown.enter)="hide()">
|
|
8482
|
-
<span class="p-dialog-header-close-icon fa-solid fa-xmark"></span>
|
|
8483
|
-
</button>
|
|
8484
|
-
}
|
|
8485
|
-
</div>
|
|
8486
|
-
</div>
|
|
8487
|
-
}
|
|
8488
|
-
<div class="p-dialog-content {{ dialogConfig?.data?.contentStyleClass }}" [attr.data-testid]="buildDialogTestId('content')" [ngStyle]="config.contentStyle" [ngClass]="{ 'disable-ui-dialog-content': dialogConfig.data._context.isGlobalDisabled }">
|
|
8489
|
-
<ng-template pDynamicDialogContent></ng-template>
|
|
8490
|
-
</div>
|
|
8491
|
-
@if (config.footer) {
|
|
8492
|
-
<div class="p-dialog-footer" [attr.data-testid]="buildDialogTestId('footer')" [ngStyle]="config.footerStyle" [ngClass]="{ 'disable-container': dialogConfig.data._context.isGlobalDisabled }">
|
|
8493
|
-
<ng-template pDynamicDialogFooter></ng-template>
|
|
8494
|
-
</div>
|
|
8495
|
-
}
|
|
8496
|
-
</div>
|
|
8497
|
-
}
|
|
8498
|
-
</div>
|
|
8499
|
-
`, isInline: true, styles: [".p-dialog-mask{position:fixed;top:0;left:0;width:100%;height:100%;display:flex;justify-content:center;align-items:center;pointer-events:none}.p-dialog-mask.p-component-overlay{pointer-events:auto}.p-dialog-mask-free{position:fixed;top:0;left:0;width:100%;height:100%;display:block!important;pointer-events:none}.p-dialog{display:flex;flex-direction:column;pointer-events:auto;max-height:90%;transform:scale(1);position:relative;padding:unset}.p-dialog-content{overflow-y:auto;flex-grow:1}.p-dialog-header{display:flex;align-items:center;justify-content:space-between;flex-shrink:0}.p-dialog-footer{flex-shrink:0}.p-dialog .p-dialog-header-icons{display:flex;align-items:center}.p-dialog .p-dialog-header-icon{display:flex;align-items:center;justify-content:center;overflow:hidden;position:relative}.p-fluid .p-dialog-footer .p-button{width:auto}.p-dialog-top .p-dialog,.p-dialog-bottom .p-dialog,.p-dialog-left .p-dialog,.p-dialog-right .p-dialog,.p-dialog-top-left .p-dialog,.p-dialog-top-right .p-dialog,.p-dialog-bottom-left .p-dialog,.p-dialog-bottom-right .p-dialog{margin:.75rem;transform:translateZ(0)}.p-dialog-maximized{-webkit-transition:none;transition:none;transform:none;width:100vw!important;height:100vh!important;top:0!important;left:0!important;max-height:100%;height:100%}.p-dialog-maximized .p-dialog-content{flex-grow:1}.p-dialog-left{justify-content:flex-start}.p-dialog-right{justify-content:flex-end}.p-dialog-top{align-items:flex-start}.p-dialog-top-left{justify-content:flex-start;align-items:flex-start}.p-dialog-top-right{justify-content:flex-end;align-items:flex-start}.p-dialog-bottom{align-items:flex-end}.p-dialog-bottom-left{justify-content:flex-start;align-items:flex-end}.p-dialog-bottom-right{justify-content:flex-end;align-items:flex-end}.p-dialog .p-resizable-handle{position:absolute;font-size:.1px;display:block;cursor:se-resize;width:12px;height:12px;right:1px;bottom:1px}.p-confirm-dialog .p-dialog-content{display:flex;align-items:center}.p-component-overlay{background-color:#0006}.p-component-overlay-enter{animation:smz-dialog-mask-enter var(--smz-duration, .15s) forwards}.p-component-overlay-leave{animation:smz-dialog-mask-leave var(--smz-duration, .15s) forwards}@keyframes smz-dialog-mask-enter{0%{background-color:transparent}to{background-color:#0006}}@keyframes smz-dialog-mask-leave{0%{background-color:#0006}to{background-color:transparent}}.p-dialog{background:rgb(var(--smz-color-surface-2));color:rgb(var(--smz-color-fg));font-family:var(--smz-font-sans);font-size:var(--smz-text-md);border:1px solid rgb(var(--smz-color-line));border-radius:var(--smz-radius-overlay);box-shadow:var(--smz-shadow-overlay)}.p-dialog-header{padding:1.25rem;gap:.5rem;background:transparent;color:inherit;border-top-left-radius:var(--smz-radius-overlay);border-top-right-radius:var(--smz-radius-overlay)}.p-dialog-title{font-size:1.25rem;font-weight:600}.p-dialog-content{padding:0 1.25rem 1.25rem;background:transparent;color:inherit}.p-dialog-footer{display:flex;justify-content:flex-end;gap:.5rem;padding:0 1.25rem 1.25rem;background:transparent;border-bottom-left-radius:var(--smz-radius-overlay);border-bottom-right-radius:var(--smz-radius-overlay)}.p-dialog-footer button{width:auto}.p-dialog .p-dialog-header-icon{width:2rem;height:2rem;border:0;border-radius:9999px;background:transparent;color:rgb(var(--smz-color-fg-muted));cursor:pointer;transition:background-color var(--smz-duration)}.p-dialog .p-dialog-header-icon:hover{background:rgb(var(--smz-color-surface-3));color:rgb(var(--smz-color-fg))}.p-dialog .p-dialog-header-icon:focus-visible{outline:2px solid rgb(var(--smz-color-focus))}.p-dialog-footer .p-toolbar,.p-dialog-footer [class*=toolbar],.p-dialog-footer ui-toolbar{border:0!important;background:transparent!important;padding:0!important}\n"], dependencies: [{ kind: "directive", type: i0.forwardRef(() => i1.NgClass), selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i0.forwardRef(() => i1.NgStyle), selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i0.forwardRef(() => SmzTooltipDirective), selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "directive", type: i0.forwardRef(() => SmzAutoFocusDirective), selector: "[smzAutoFocus]", inputs: ["smzAutoFocus"] }, { kind: "directive", type: i0.forwardRef(() => DynamicDialogContent), selector: "[pDynamicDialogContent]" }, { kind: "directive", type: i0.forwardRef(() => DynamicDialogFooter), selector: "[pDynamicDialogFooter]" }, { kind: "pipe", type: i0.forwardRef(() => SafeHtmlPipe$1), name: "safeHtml" }], animations: [
|
|
8456
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: DynamicDialogComponent, isStandalone: false, selector: "smz-dynamicDialog", outputs: { onMaximize: "onMaximize", onMinimize: "onMinimize" }, host: { listeners: { "document:keydown.escape": "onEscapeHandler($event)" }, properties: { "attr.id": "this.domId" }, classAttribute: "p-element" }, viewQueries: [{ propertyName: "insertionPoint", first: true, predicate: DynamicDialogContent, descendants: true }, { propertyName: "insertionFooter", first: true, predicate: DynamicDialogFooter, descendants: true }, { propertyName: "maskViewChild", first: true, predicate: ["mask"], descendants: true }, { propertyName: "containerViewChild", first: true, predicate: ["dialogContainer"], descendants: true }, { propertyName: "highlightPanelViewChild", first: true, predicate: ["highlightPanel"], descendants: true }, { propertyName: "overlayPanelClipViewChild", first: true, predicate: ["overlayPanelClip"], descendants: true }, { propertyName: "overlayBlendClipViewChild", first: true, predicate: ["overlayBlendClip"], descendants: true }], ngImport: i0, template: `
|
|
8457
|
+
|
|
8458
|
+
@if (dialogConfig.data.behaviors.showAsLinkedOverlayPanel) {
|
|
8459
|
+
<div #overlayBlendClip id="blend-clip" class="fixed inset-0" [ngClass]="dialogConfig.data.overlayPanel?.overlayBlendStylesClass"></div>
|
|
8460
|
+
}
|
|
8461
|
+
@if (dialogConfig.data.behaviors.showAsLinkedOverlayPanel) {
|
|
8462
|
+
<div #overlayPanelClip id="overlay-clip" class="fixed inset-0 p-component-overlay p-component-overlay-enter" [ngClass]="dialogConfig.data.overlayPanel?.overlayPanelStylesClass"></div>
|
|
8463
|
+
}
|
|
8464
|
+
@if (dialogConfig.data.behaviors.showAsLinkedOverlayPanel) {
|
|
8465
|
+
<div #highlightPanel id="highlight-clip" class="fixed inset-0" [ngClass]="dialogConfig.data.overlayPanel?.hightlightStyleClass"></div>
|
|
8466
|
+
}
|
|
8467
|
+
<div #mask id="dialog-mask" [attr.data-testid]="buildDialogTestId('mask')" [ngClass]="{'p-dialog-mask-free': dialogConfig.data.behaviors.showAsLinkedOverlayPanel, 'p-component-overlay p-component-overlay-enter' : config.modal !== false && !dialogConfig.data.behaviors.showAsLinkedOverlayPanel, 'p-dialog-mask-scrollblocker': config.modal !== false, 'smz-dialog-minimized': minimized }" class="smz_form_grid_container p-dialog-mask">
|
|
8468
|
+
@if (visible) {
|
|
8469
|
+
<div #dialogContainer id="dialog-container" [attr.data-testid]="buildDialogTestId()" [smzAutoFocus]="config.autoFocus" [ngClass]="{'p-dialog p-dynamic-dialog p-component': true, 'p-dialog-rtl': config.rtl, 'p-dialog-maximized': maximized}" [ngStyle]="config.style" class="{{ config.styleClass }} {{ dialogConfig?.data?.containerStyleClass }}"
|
|
8470
|
+
[@animation]="{value: 'visible', params: {transform: transformOptions, transition: config.transitionOptions || '150ms cubic-bezier(0, 0, 0.2, 1)'}}"
|
|
8471
|
+
(@animation.start)="onAnimationStart($event)" (@animation.done)="onAnimationEnd($event)" role="dialog"
|
|
8472
|
+
[style.width]="config.width" [style.height]="config.height">
|
|
8473
|
+
@if (config.showHeader === false ? false: true) {
|
|
8474
|
+
<div class="p-dialog-header" [attr.data-testid]="buildDialogTestId('header')" [ngStyle]="config.headerStyle">
|
|
8475
|
+
<div class="p-dialog-title w-full" [attr.data-testid]="buildDialogTestId('title')" [innerHTML]="config.header | safeHtml"></div>
|
|
8476
|
+
<div class="p-dialog-header-icons flex gap-3" [ngClass]="{ 'disable-a': dialogConfig.data._context.isGlobalDisabled }">
|
|
8477
|
+
@for (topbarButton of dialogConfig.data.topbarButtons; track $index) {
|
|
8478
|
+
@if (topbarButton.visible) {
|
|
8479
|
+
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildTopbarButtonTestId(topbarButton, $index)" (click)="topbarButton.onClick()" [smzTooltip]="topbarButton.tooltip">
|
|
8480
|
+
<span [ngClass]="topbarButton.class"></span>
|
|
8481
|
+
</button>
|
|
8482
|
+
}
|
|
8483
|
+
}
|
|
8484
|
+
@if (config.minimizable !== false) {
|
|
8485
|
+
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('minimize')" (click)="minimize()" (keydown.enter)="minimize()">
|
|
8486
|
+
<span class="p-dialog-header-close-icon fa-solid fa-minus"></span>
|
|
8487
|
+
</button>
|
|
8488
|
+
}
|
|
8489
|
+
@if (config.maximizable !== false && !maximized) {
|
|
8490
|
+
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('maximize')" (click)="maximize()" (keydown.enter)="maximize()">
|
|
8491
|
+
<span class="p-dialog-header-close-icon" [ngClass]="maximizeIcon"></span>
|
|
8492
|
+
</button>
|
|
8493
|
+
}
|
|
8494
|
+
@if (maximized && !config.blockRestoreButton) {
|
|
8495
|
+
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('restore')" (click)="maximize()" (keydown.enter)="maximize()">
|
|
8496
|
+
<span class="p-dialog-header-close-icon" [ngClass]="minimizeIcon"></span>
|
|
8497
|
+
</button>
|
|
8498
|
+
}
|
|
8499
|
+
@if (config.closable !== false) {
|
|
8500
|
+
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('close')" (click)="hide()" (keydown.enter)="hide()">
|
|
8501
|
+
<span class="p-dialog-header-close-icon fa-solid fa-xmark"></span>
|
|
8502
|
+
</button>
|
|
8503
|
+
}
|
|
8504
|
+
</div>
|
|
8505
|
+
</div>
|
|
8506
|
+
}
|
|
8507
|
+
<div class="p-dialog-content {{ dialogConfig?.data?.contentStyleClass }}" [attr.data-testid]="buildDialogTestId('content')" [ngStyle]="config.contentStyle" [ngClass]="{ 'disable-ui-dialog-content': dialogConfig.data._context.isGlobalDisabled }">
|
|
8508
|
+
<ng-template pDynamicDialogContent></ng-template>
|
|
8509
|
+
</div>
|
|
8510
|
+
@if (config.footer) {
|
|
8511
|
+
<div class="p-dialog-footer" [attr.data-testid]="buildDialogTestId('footer')" [ngStyle]="config.footerStyle" [ngClass]="{ 'disable-container': dialogConfig.data._context.isGlobalDisabled }">
|
|
8512
|
+
<ng-template pDynamicDialogFooter></ng-template>
|
|
8513
|
+
</div>
|
|
8514
|
+
}
|
|
8515
|
+
</div>
|
|
8516
|
+
}
|
|
8517
|
+
</div>
|
|
8518
|
+
`, isInline: true, styles: [".p-dialog-mask{position:fixed;top:0;left:0;width:100%;height:100%;display:flex;justify-content:center;align-items:center;pointer-events:none}.p-dialog-mask.p-component-overlay{pointer-events:auto}.p-dialog-mask-free{position:fixed;top:0;left:0;width:100%;height:100%;display:block!important;pointer-events:none}.p-dialog{display:flex;flex-direction:column;pointer-events:auto;max-height:90%;transform:scale(1);position:relative;padding:unset}.p-dialog-content{overflow-y:auto;flex-grow:1}.p-dialog-header{display:flex;align-items:center;justify-content:space-between;flex-shrink:0}.p-dialog-footer{flex-shrink:0}.p-dialog .p-dialog-header-icons{display:flex;align-items:center}.p-dialog .p-dialog-header-icon{display:flex;align-items:center;justify-content:center;overflow:hidden;position:relative}.p-fluid .p-dialog-footer .p-button{width:auto}.p-dialog-top .p-dialog,.p-dialog-bottom .p-dialog,.p-dialog-left .p-dialog,.p-dialog-right .p-dialog,.p-dialog-top-left .p-dialog,.p-dialog-top-right .p-dialog,.p-dialog-bottom-left .p-dialog,.p-dialog-bottom-right .p-dialog{margin:.75rem;transform:translateZ(0)}.p-dialog-maximized{-webkit-transition:none;transition:none;transform:none;width:100vw!important;height:100vh!important;top:0!important;left:0!important;max-height:100%;height:100%}.p-dialog-maximized .p-dialog-content{flex-grow:1}.p-dialog-left{justify-content:flex-start}.p-dialog-right{justify-content:flex-end}.p-dialog-top{align-items:flex-start}.p-dialog-top-left{justify-content:flex-start;align-items:flex-start}.p-dialog-top-right{justify-content:flex-end;align-items:flex-start}.p-dialog-bottom{align-items:flex-end}.p-dialog-bottom-left{justify-content:flex-start;align-items:flex-end}.p-dialog-bottom-right{justify-content:flex-end;align-items:flex-end}.p-dialog .p-resizable-handle{position:absolute;font-size:.1px;display:block;cursor:se-resize;width:12px;height:12px;right:1px;bottom:1px}.p-confirm-dialog .p-dialog-content{display:flex;align-items:center}.p-component-overlay{background-color:#0006}.p-component-overlay-enter{animation:smz-dialog-mask-enter var(--smz-duration, .15s) forwards}.p-component-overlay-leave{animation:smz-dialog-mask-leave var(--smz-duration, .15s) forwards}@keyframes smz-dialog-mask-enter{0%{background-color:transparent}to{background-color:#0006}}@keyframes smz-dialog-mask-leave{0%{background-color:#0006}to{background-color:transparent}}.p-dialog{background:rgb(var(--smz-color-surface-2));color:rgb(var(--smz-color-fg));font-family:var(--smz-font-sans);font-size:var(--smz-text-md);border:1px solid rgb(var(--smz-color-line));border-radius:var(--smz-radius-overlay);box-shadow:var(--smz-shadow-overlay)}.p-dialog-header{padding:1.25rem;gap:.5rem;background:transparent;color:inherit;border-top-left-radius:var(--smz-radius-overlay);border-top-right-radius:var(--smz-radius-overlay)}.p-dialog-title{font-size:1.25rem;font-weight:600}.p-dialog-content{padding:0 1.25rem 1.25rem;background:transparent;color:inherit}.p-dialog-footer{display:flex;justify-content:flex-end;gap:.5rem;padding:0 1.25rem 1.25rem;background:transparent;border-bottom-left-radius:var(--smz-radius-overlay);border-bottom-right-radius:var(--smz-radius-overlay)}.p-dialog-footer button{width:auto}.p-dialog .p-dialog-header-icon{width:2rem;height:2rem;border:0;border-radius:9999px;background:transparent;color:rgb(var(--smz-color-fg-muted));cursor:pointer;transition:background-color var(--smz-duration)}.p-dialog .p-dialog-header-icon:hover{background:rgb(var(--smz-color-surface-3));color:rgb(var(--smz-color-fg))}.p-dialog .p-dialog-header-icon:focus-visible{outline:2px solid rgb(var(--smz-color-focus))}.p-dialog-footer .p-toolbar,.p-dialog-footer [class*=toolbar],.p-dialog-footer ui-toolbar{border:0!important;background:transparent!important;padding:0!important}.p-dialog-mask[popover]{margin:0;padding:0;border:0;background:transparent;color:inherit;overflow:visible;inset:0;max-width:none;max-height:none;width:100%;height:100%}.p-dialog-mask[popover]::backdrop{display:none}\n"], dependencies: [{ kind: "directive", type: i0.forwardRef(() => i1.NgClass), selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i0.forwardRef(() => i1.NgStyle), selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i0.forwardRef(() => SmzTooltipDirective), selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "directive", type: i0.forwardRef(() => SmzAutoFocusDirective), selector: "[smzAutoFocus]", inputs: ["smzAutoFocus"] }, { kind: "directive", type: i0.forwardRef(() => DynamicDialogContent), selector: "[pDynamicDialogContent]" }, { kind: "directive", type: i0.forwardRef(() => DynamicDialogFooter), selector: "[pDynamicDialogFooter]" }, { kind: "pipe", type: i0.forwardRef(() => SafeHtmlPipe$1), name: "safeHtml" }], animations: [
|
|
8500
8519
|
trigger('animation', [
|
|
8501
8520
|
transition('void => visible', [
|
|
8502
8521
|
useAnimation(showAnimation)
|
|
@@ -8509,68 +8528,68 @@ class DynamicDialogComponent {
|
|
|
8509
8528
|
}
|
|
8510
8529
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: DynamicDialogComponent, decorators: [{
|
|
8511
8530
|
type: Component,
|
|
8512
|
-
args: [{ selector: 'smz-dynamicDialog', template: `
|
|
8513
|
-
|
|
8514
|
-
@if (dialogConfig.data.behaviors.showAsLinkedOverlayPanel) {
|
|
8515
|
-
<div #overlayBlendClip id="blend-clip" class="fixed inset-0" [ngClass]="dialogConfig.data.overlayPanel?.overlayBlendStylesClass"></div>
|
|
8516
|
-
}
|
|
8517
|
-
@if (dialogConfig.data.behaviors.showAsLinkedOverlayPanel) {
|
|
8518
|
-
<div #overlayPanelClip id="overlay-clip" class="fixed inset-0 p-component-overlay p-component-overlay-enter" [ngClass]="dialogConfig.data.overlayPanel?.overlayPanelStylesClass"></div>
|
|
8519
|
-
}
|
|
8520
|
-
@if (dialogConfig.data.behaviors.showAsLinkedOverlayPanel) {
|
|
8521
|
-
<div #highlightPanel id="highlight-clip" class="fixed inset-0" [ngClass]="dialogConfig.data.overlayPanel?.hightlightStyleClass"></div>
|
|
8522
|
-
}
|
|
8523
|
-
<div #mask id="dialog-mask" [attr.data-testid]="buildDialogTestId('mask')" [ngClass]="{'p-dialog-mask-free': dialogConfig.data.behaviors.showAsLinkedOverlayPanel, 'p-component-overlay p-component-overlay-enter' : config.modal !== false && !dialogConfig.data.behaviors.showAsLinkedOverlayPanel, 'p-dialog-mask-scrollblocker': config.modal !== false, 'smz-dialog-minimized': minimized }" class="smz_form_grid_container p-dialog-mask">
|
|
8524
|
-
@if (visible) {
|
|
8525
|
-
<div #dialogContainer id="dialog-container" [attr.data-testid]="buildDialogTestId()" [smzAutoFocus]="config.autoFocus" [ngClass]="{'p-dialog p-dynamic-dialog p-component': true, 'p-dialog-rtl': config.rtl, 'p-dialog-maximized': maximized}" [ngStyle]="config.style" class="{{ config.styleClass }} {{ dialogConfig?.data?.containerStyleClass }}"
|
|
8526
|
-
[@animation]="{value: 'visible', params: {transform: transformOptions, transition: config.transitionOptions || '150ms cubic-bezier(0, 0, 0.2, 1)'}}"
|
|
8527
|
-
(@animation.start)="onAnimationStart($event)" (@animation.done)="onAnimationEnd($event)" role="dialog"
|
|
8528
|
-
[style.width]="config.width" [style.height]="config.height">
|
|
8529
|
-
@if (config.showHeader === false ? false: true) {
|
|
8530
|
-
<div class="p-dialog-header" [attr.data-testid]="buildDialogTestId('header')" [ngStyle]="config.headerStyle">
|
|
8531
|
-
<div class="p-dialog-title w-full" [attr.data-testid]="buildDialogTestId('title')" [innerHTML]="config.header | safeHtml"></div>
|
|
8532
|
-
<div class="p-dialog-header-icons flex gap-3" [ngClass]="{ 'disable-a': dialogConfig.data._context.isGlobalDisabled }">
|
|
8533
|
-
@for (topbarButton of dialogConfig.data.topbarButtons; track $index) {
|
|
8534
|
-
@if (topbarButton.visible) {
|
|
8535
|
-
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildTopbarButtonTestId(topbarButton, $index)" (click)="topbarButton.onClick()" [smzTooltip]="topbarButton.tooltip">
|
|
8536
|
-
<span [ngClass]="topbarButton.class"></span>
|
|
8537
|
-
</button>
|
|
8538
|
-
}
|
|
8539
|
-
}
|
|
8540
|
-
@if (config.minimizable !== false) {
|
|
8541
|
-
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('minimize')" (click)="minimize()" (keydown.enter)="minimize()">
|
|
8542
|
-
<span class="p-dialog-header-close-icon fa-solid fa-minus"></span>
|
|
8543
|
-
</button>
|
|
8544
|
-
}
|
|
8545
|
-
@if (config.maximizable !== false && !maximized) {
|
|
8546
|
-
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('maximize')" (click)="maximize()" (keydown.enter)="maximize()">
|
|
8547
|
-
<span class="p-dialog-header-close-icon" [ngClass]="maximizeIcon"></span>
|
|
8548
|
-
</button>
|
|
8549
|
-
}
|
|
8550
|
-
@if (maximized && !config.blockRestoreButton) {
|
|
8551
|
-
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('restore')" (click)="maximize()" (keydown.enter)="maximize()">
|
|
8552
|
-
<span class="p-dialog-header-close-icon" [ngClass]="minimizeIcon"></span>
|
|
8553
|
-
</button>
|
|
8554
|
-
}
|
|
8555
|
-
@if (config.closable !== false) {
|
|
8556
|
-
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('close')" (click)="hide()" (keydown.enter)="hide()">
|
|
8557
|
-
<span class="p-dialog-header-close-icon fa-solid fa-xmark"></span>
|
|
8558
|
-
</button>
|
|
8559
|
-
}
|
|
8560
|
-
</div>
|
|
8561
|
-
</div>
|
|
8562
|
-
}
|
|
8563
|
-
<div class="p-dialog-content {{ dialogConfig?.data?.contentStyleClass }}" [attr.data-testid]="buildDialogTestId('content')" [ngStyle]="config.contentStyle" [ngClass]="{ 'disable-ui-dialog-content': dialogConfig.data._context.isGlobalDisabled }">
|
|
8564
|
-
<ng-template pDynamicDialogContent></ng-template>
|
|
8565
|
-
</div>
|
|
8566
|
-
@if (config.footer) {
|
|
8567
|
-
<div class="p-dialog-footer" [attr.data-testid]="buildDialogTestId('footer')" [ngStyle]="config.footerStyle" [ngClass]="{ 'disable-container': dialogConfig.data._context.isGlobalDisabled }">
|
|
8568
|
-
<ng-template pDynamicDialogFooter></ng-template>
|
|
8569
|
-
</div>
|
|
8570
|
-
}
|
|
8571
|
-
</div>
|
|
8572
|
-
}
|
|
8573
|
-
</div>
|
|
8531
|
+
args: [{ selector: 'smz-dynamicDialog', template: `
|
|
8532
|
+
|
|
8533
|
+
@if (dialogConfig.data.behaviors.showAsLinkedOverlayPanel) {
|
|
8534
|
+
<div #overlayBlendClip id="blend-clip" class="fixed inset-0" [ngClass]="dialogConfig.data.overlayPanel?.overlayBlendStylesClass"></div>
|
|
8535
|
+
}
|
|
8536
|
+
@if (dialogConfig.data.behaviors.showAsLinkedOverlayPanel) {
|
|
8537
|
+
<div #overlayPanelClip id="overlay-clip" class="fixed inset-0 p-component-overlay p-component-overlay-enter" [ngClass]="dialogConfig.data.overlayPanel?.overlayPanelStylesClass"></div>
|
|
8538
|
+
}
|
|
8539
|
+
@if (dialogConfig.data.behaviors.showAsLinkedOverlayPanel) {
|
|
8540
|
+
<div #highlightPanel id="highlight-clip" class="fixed inset-0" [ngClass]="dialogConfig.data.overlayPanel?.hightlightStyleClass"></div>
|
|
8541
|
+
}
|
|
8542
|
+
<div #mask id="dialog-mask" [attr.data-testid]="buildDialogTestId('mask')" [ngClass]="{'p-dialog-mask-free': dialogConfig.data.behaviors.showAsLinkedOverlayPanel, 'p-component-overlay p-component-overlay-enter' : config.modal !== false && !dialogConfig.data.behaviors.showAsLinkedOverlayPanel, 'p-dialog-mask-scrollblocker': config.modal !== false, 'smz-dialog-minimized': minimized }" class="smz_form_grid_container p-dialog-mask">
|
|
8543
|
+
@if (visible) {
|
|
8544
|
+
<div #dialogContainer id="dialog-container" [attr.data-testid]="buildDialogTestId()" [smzAutoFocus]="config.autoFocus" [ngClass]="{'p-dialog p-dynamic-dialog p-component': true, 'p-dialog-rtl': config.rtl, 'p-dialog-maximized': maximized}" [ngStyle]="config.style" class="{{ config.styleClass }} {{ dialogConfig?.data?.containerStyleClass }}"
|
|
8545
|
+
[@animation]="{value: 'visible', params: {transform: transformOptions, transition: config.transitionOptions || '150ms cubic-bezier(0, 0, 0.2, 1)'}}"
|
|
8546
|
+
(@animation.start)="onAnimationStart($event)" (@animation.done)="onAnimationEnd($event)" role="dialog"
|
|
8547
|
+
[style.width]="config.width" [style.height]="config.height">
|
|
8548
|
+
@if (config.showHeader === false ? false: true) {
|
|
8549
|
+
<div class="p-dialog-header" [attr.data-testid]="buildDialogTestId('header')" [ngStyle]="config.headerStyle">
|
|
8550
|
+
<div class="p-dialog-title w-full" [attr.data-testid]="buildDialogTestId('title')" [innerHTML]="config.header | safeHtml"></div>
|
|
8551
|
+
<div class="p-dialog-header-icons flex gap-3" [ngClass]="{ 'disable-a': dialogConfig.data._context.isGlobalDisabled }">
|
|
8552
|
+
@for (topbarButton of dialogConfig.data.topbarButtons; track $index) {
|
|
8553
|
+
@if (topbarButton.visible) {
|
|
8554
|
+
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildTopbarButtonTestId(topbarButton, $index)" (click)="topbarButton.onClick()" [smzTooltip]="topbarButton.tooltip">
|
|
8555
|
+
<span [ngClass]="topbarButton.class"></span>
|
|
8556
|
+
</button>
|
|
8557
|
+
}
|
|
8558
|
+
}
|
|
8559
|
+
@if (config.minimizable !== false) {
|
|
8560
|
+
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('minimize')" (click)="minimize()" (keydown.enter)="minimize()">
|
|
8561
|
+
<span class="p-dialog-header-close-icon fa-solid fa-minus"></span>
|
|
8562
|
+
</button>
|
|
8563
|
+
}
|
|
8564
|
+
@if (config.maximizable !== false && !maximized) {
|
|
8565
|
+
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('maximize')" (click)="maximize()" (keydown.enter)="maximize()">
|
|
8566
|
+
<span class="p-dialog-header-close-icon" [ngClass]="maximizeIcon"></span>
|
|
8567
|
+
</button>
|
|
8568
|
+
}
|
|
8569
|
+
@if (maximized && !config.blockRestoreButton) {
|
|
8570
|
+
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('restore')" (click)="maximize()" (keydown.enter)="maximize()">
|
|
8571
|
+
<span class="p-dialog-header-close-icon" [ngClass]="minimizeIcon"></span>
|
|
8572
|
+
</button>
|
|
8573
|
+
}
|
|
8574
|
+
@if (config.closable !== false) {
|
|
8575
|
+
<button [ngClass]="'p-dialog-header-icon p-dialog-header-maximize p-link'" type="button" [attr.data-testid]="buildDialogTestId('close')" (click)="hide()" (keydown.enter)="hide()">
|
|
8576
|
+
<span class="p-dialog-header-close-icon fa-solid fa-xmark"></span>
|
|
8577
|
+
</button>
|
|
8578
|
+
}
|
|
8579
|
+
</div>
|
|
8580
|
+
</div>
|
|
8581
|
+
}
|
|
8582
|
+
<div class="p-dialog-content {{ dialogConfig?.data?.contentStyleClass }}" [attr.data-testid]="buildDialogTestId('content')" [ngStyle]="config.contentStyle" [ngClass]="{ 'disable-ui-dialog-content': dialogConfig.data._context.isGlobalDisabled }">
|
|
8583
|
+
<ng-template pDynamicDialogContent></ng-template>
|
|
8584
|
+
</div>
|
|
8585
|
+
@if (config.footer) {
|
|
8586
|
+
<div class="p-dialog-footer" [attr.data-testid]="buildDialogTestId('footer')" [ngStyle]="config.footerStyle" [ngClass]="{ 'disable-container': dialogConfig.data._context.isGlobalDisabled }">
|
|
8587
|
+
<ng-template pDynamicDialogFooter></ng-template>
|
|
8588
|
+
</div>
|
|
8589
|
+
}
|
|
8590
|
+
</div>
|
|
8591
|
+
}
|
|
8592
|
+
</div>
|
|
8574
8593
|
`, animations: [
|
|
8575
8594
|
trigger('animation', [
|
|
8576
8595
|
transition('void => visible', [
|
|
@@ -8582,7 +8601,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImpor
|
|
|
8582
8601
|
])
|
|
8583
8602
|
], changeDetection: ChangeDetectionStrategy.Default, encapsulation: ViewEncapsulation.None, host: {
|
|
8584
8603
|
'class': 'p-element'
|
|
8585
|
-
}, standalone: false, styles: [".p-dialog-mask{position:fixed;top:0;left:0;width:100%;height:100%;display:flex;justify-content:center;align-items:center;pointer-events:none}.p-dialog-mask.p-component-overlay{pointer-events:auto}.p-dialog-mask-free{position:fixed;top:0;left:0;width:100%;height:100%;display:block!important;pointer-events:none}.p-dialog{display:flex;flex-direction:column;pointer-events:auto;max-height:90%;transform:scale(1);position:relative;padding:unset}.p-dialog-content{overflow-y:auto;flex-grow:1}.p-dialog-header{display:flex;align-items:center;justify-content:space-between;flex-shrink:0}.p-dialog-footer{flex-shrink:0}.p-dialog .p-dialog-header-icons{display:flex;align-items:center}.p-dialog .p-dialog-header-icon{display:flex;align-items:center;justify-content:center;overflow:hidden;position:relative}.p-fluid .p-dialog-footer .p-button{width:auto}.p-dialog-top .p-dialog,.p-dialog-bottom .p-dialog,.p-dialog-left .p-dialog,.p-dialog-right .p-dialog,.p-dialog-top-left .p-dialog,.p-dialog-top-right .p-dialog,.p-dialog-bottom-left .p-dialog,.p-dialog-bottom-right .p-dialog{margin:.75rem;transform:translateZ(0)}.p-dialog-maximized{-webkit-transition:none;transition:none;transform:none;width:100vw!important;height:100vh!important;top:0!important;left:0!important;max-height:100%;height:100%}.p-dialog-maximized .p-dialog-content{flex-grow:1}.p-dialog-left{justify-content:flex-start}.p-dialog-right{justify-content:flex-end}.p-dialog-top{align-items:flex-start}.p-dialog-top-left{justify-content:flex-start;align-items:flex-start}.p-dialog-top-right{justify-content:flex-end;align-items:flex-start}.p-dialog-bottom{align-items:flex-end}.p-dialog-bottom-left{justify-content:flex-start;align-items:flex-end}.p-dialog-bottom-right{justify-content:flex-end;align-items:flex-end}.p-dialog .p-resizable-handle{position:absolute;font-size:.1px;display:block;cursor:se-resize;width:12px;height:12px;right:1px;bottom:1px}.p-confirm-dialog .p-dialog-content{display:flex;align-items:center}.p-component-overlay{background-color:#0006}.p-component-overlay-enter{animation:smz-dialog-mask-enter var(--smz-duration, .15s) forwards}.p-component-overlay-leave{animation:smz-dialog-mask-leave var(--smz-duration, .15s) forwards}@keyframes smz-dialog-mask-enter{0%{background-color:transparent}to{background-color:#0006}}@keyframes smz-dialog-mask-leave{0%{background-color:#0006}to{background-color:transparent}}.p-dialog{background:rgb(var(--smz-color-surface-2));color:rgb(var(--smz-color-fg));font-family:var(--smz-font-sans);font-size:var(--smz-text-md);border:1px solid rgb(var(--smz-color-line));border-radius:var(--smz-radius-overlay);box-shadow:var(--smz-shadow-overlay)}.p-dialog-header{padding:1.25rem;gap:.5rem;background:transparent;color:inherit;border-top-left-radius:var(--smz-radius-overlay);border-top-right-radius:var(--smz-radius-overlay)}.p-dialog-title{font-size:1.25rem;font-weight:600}.p-dialog-content{padding:0 1.25rem 1.25rem;background:transparent;color:inherit}.p-dialog-footer{display:flex;justify-content:flex-end;gap:.5rem;padding:0 1.25rem 1.25rem;background:transparent;border-bottom-left-radius:var(--smz-radius-overlay);border-bottom-right-radius:var(--smz-radius-overlay)}.p-dialog-footer button{width:auto}.p-dialog .p-dialog-header-icon{width:2rem;height:2rem;border:0;border-radius:9999px;background:transparent;color:rgb(var(--smz-color-fg-muted));cursor:pointer;transition:background-color var(--smz-duration)}.p-dialog .p-dialog-header-icon:hover{background:rgb(var(--smz-color-surface-3));color:rgb(var(--smz-color-fg))}.p-dialog .p-dialog-header-icon:focus-visible{outline:2px solid rgb(var(--smz-color-focus))}.p-dialog-footer .p-toolbar,.p-dialog-footer [class*=toolbar],.p-dialog-footer ui-toolbar{border:0!important;background:transparent!important;padding:0!important}\n"] }]
|
|
8604
|
+
}, standalone: false, styles: [".p-dialog-mask{position:fixed;top:0;left:0;width:100%;height:100%;display:flex;justify-content:center;align-items:center;pointer-events:none}.p-dialog-mask.p-component-overlay{pointer-events:auto}.p-dialog-mask-free{position:fixed;top:0;left:0;width:100%;height:100%;display:block!important;pointer-events:none}.p-dialog{display:flex;flex-direction:column;pointer-events:auto;max-height:90%;transform:scale(1);position:relative;padding:unset}.p-dialog-content{overflow-y:auto;flex-grow:1}.p-dialog-header{display:flex;align-items:center;justify-content:space-between;flex-shrink:0}.p-dialog-footer{flex-shrink:0}.p-dialog .p-dialog-header-icons{display:flex;align-items:center}.p-dialog .p-dialog-header-icon{display:flex;align-items:center;justify-content:center;overflow:hidden;position:relative}.p-fluid .p-dialog-footer .p-button{width:auto}.p-dialog-top .p-dialog,.p-dialog-bottom .p-dialog,.p-dialog-left .p-dialog,.p-dialog-right .p-dialog,.p-dialog-top-left .p-dialog,.p-dialog-top-right .p-dialog,.p-dialog-bottom-left .p-dialog,.p-dialog-bottom-right .p-dialog{margin:.75rem;transform:translateZ(0)}.p-dialog-maximized{-webkit-transition:none;transition:none;transform:none;width:100vw!important;height:100vh!important;top:0!important;left:0!important;max-height:100%;height:100%}.p-dialog-maximized .p-dialog-content{flex-grow:1}.p-dialog-left{justify-content:flex-start}.p-dialog-right{justify-content:flex-end}.p-dialog-top{align-items:flex-start}.p-dialog-top-left{justify-content:flex-start;align-items:flex-start}.p-dialog-top-right{justify-content:flex-end;align-items:flex-start}.p-dialog-bottom{align-items:flex-end}.p-dialog-bottom-left{justify-content:flex-start;align-items:flex-end}.p-dialog-bottom-right{justify-content:flex-end;align-items:flex-end}.p-dialog .p-resizable-handle{position:absolute;font-size:.1px;display:block;cursor:se-resize;width:12px;height:12px;right:1px;bottom:1px}.p-confirm-dialog .p-dialog-content{display:flex;align-items:center}.p-component-overlay{background-color:#0006}.p-component-overlay-enter{animation:smz-dialog-mask-enter var(--smz-duration, .15s) forwards}.p-component-overlay-leave{animation:smz-dialog-mask-leave var(--smz-duration, .15s) forwards}@keyframes smz-dialog-mask-enter{0%{background-color:transparent}to{background-color:#0006}}@keyframes smz-dialog-mask-leave{0%{background-color:#0006}to{background-color:transparent}}.p-dialog{background:rgb(var(--smz-color-surface-2));color:rgb(var(--smz-color-fg));font-family:var(--smz-font-sans);font-size:var(--smz-text-md);border:1px solid rgb(var(--smz-color-line));border-radius:var(--smz-radius-overlay);box-shadow:var(--smz-shadow-overlay)}.p-dialog-header{padding:1.25rem;gap:.5rem;background:transparent;color:inherit;border-top-left-radius:var(--smz-radius-overlay);border-top-right-radius:var(--smz-radius-overlay)}.p-dialog-title{font-size:1.25rem;font-weight:600}.p-dialog-content{padding:0 1.25rem 1.25rem;background:transparent;color:inherit}.p-dialog-footer{display:flex;justify-content:flex-end;gap:.5rem;padding:0 1.25rem 1.25rem;background:transparent;border-bottom-left-radius:var(--smz-radius-overlay);border-bottom-right-radius:var(--smz-radius-overlay)}.p-dialog-footer button{width:auto}.p-dialog .p-dialog-header-icon{width:2rem;height:2rem;border:0;border-radius:9999px;background:transparent;color:rgb(var(--smz-color-fg-muted));cursor:pointer;transition:background-color var(--smz-duration)}.p-dialog .p-dialog-header-icon:hover{background:rgb(var(--smz-color-surface-3));color:rgb(var(--smz-color-fg))}.p-dialog .p-dialog-header-icon:focus-visible{outline:2px solid rgb(var(--smz-color-focus))}.p-dialog-footer .p-toolbar,.p-dialog-footer [class*=toolbar],.p-dialog-footer ui-toolbar{border:0!important;background:transparent!important;padding:0!important}.p-dialog-mask[popover]{margin:0;padding:0;border:0;background:transparent;color:inherit;overflow:visible;inset:0;max-width:none;max-height:none;width:100%;height:100%}.p-dialog-mask[popover]::backdrop{display:none}\n"] }]
|
|
8586
8605
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.Renderer2 }, { type: DynamicDialogConfig }, { type: DynamicDialogRef }, { type: i0.NgZone }, { type: SmzDynamicDialogConfig }, { type: SmzDockService }], propDecorators: { insertionPoint: [{
|
|
8587
8606
|
type: ViewChild,
|
|
8588
8607
|
args: [DynamicDialogContent]
|
|
@@ -8822,7 +8841,35 @@ class DialogFooterComponent {
|
|
|
8822
8841
|
this.actions$ = actions$;
|
|
8823
8842
|
this.store = store;
|
|
8824
8843
|
}
|
|
8844
|
+
ngZone = inject(NgZone);
|
|
8825
8845
|
ngOnInit() {
|
|
8846
|
+
this.watchValidity();
|
|
8847
|
+
}
|
|
8848
|
+
/**
|
|
8849
|
+
* `isValid` dos componentes injetados e um campo comum (nao signal): sem zone.js (zoneless) mudar `instance.isValid`
|
|
8850
|
+
* nao agenda deteccao de mudancas, e o `[disabled]` dos botoes `dependsOnValidation` ficava defasado ate a proxima
|
|
8851
|
+
* interacao. Enquanto houver botao que depende de validacao, a validade e amostrada e o footer e marcado quando muda.
|
|
8852
|
+
*/
|
|
8853
|
+
watchValidity() {
|
|
8854
|
+
const context = this.dialogConfig.data?._context;
|
|
8855
|
+
const dependsOnValidation = (context?.customButtons ?? []).some((button) => button.dependsOnValidation)
|
|
8856
|
+
|| context?.builtInButtons?.confirmDependsOnValidation
|
|
8857
|
+
|| context?.builtInButtons?.okDependsOnValidation
|
|
8858
|
+
|| context?.builtInButtons?.saveDependsOnValidation;
|
|
8859
|
+
if (!dependsOnValidation) {
|
|
8860
|
+
return;
|
|
8861
|
+
}
|
|
8862
|
+
let last = this.isValid();
|
|
8863
|
+
this.ngZone.runOutsideAngular(() => {
|
|
8864
|
+
const handle = setInterval(() => {
|
|
8865
|
+
const current = this.isValid();
|
|
8866
|
+
if (current !== last) {
|
|
8867
|
+
last = current;
|
|
8868
|
+
this.ngZone.run(() => this.cdf.markForCheck());
|
|
8869
|
+
}
|
|
8870
|
+
}, 150);
|
|
8871
|
+
this.destroyRef.onDestroy(() => clearInterval(handle));
|
|
8872
|
+
});
|
|
8826
8873
|
}
|
|
8827
8874
|
buildDialogTestId(suffix) {
|
|
8828
8875
|
return buildSmzDialogTestId(this.dialogConfig.data?.dialogTestId, suffix);
|
|
@@ -9177,11 +9224,11 @@ class DialogFooterComponent {
|
|
|
9177
9224
|
return response;
|
|
9178
9225
|
}
|
|
9179
9226
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: DialogFooterComponent, deps: [{ token: DynamicDialogRef }, { token: SmzDynamicDialogConfig }, { token: SmzDialogsVisibilityService }, { token: InjectComponentService }, { token: i0.ChangeDetectorRef }, { token: i1$3.Actions }, { token: i1$3.Store }], target: i0.ɵɵFactoryTarget.Component });
|
|
9180
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: DialogFooterComponent, isStandalone: false, selector: "smz-dialog-footer", ngImport: i0, template: "@if (dialogConfig.data._context; as context) {\r\n <ui-toolbar class=\"smz-dialog-footer\">\r\n <div class=\"grid grid-nogutter items-center justify-end gap-2\">\r\n @if (context.customButtonsOrder == null || context.customButtonsOrder === 'first') {\r\n @for (customButton of context.customButtons; track customButton) {\r\n @if (customButton.visible == null || customButton.visible) {\r\n <button smzButton [attr.data-testid]=\"buildCustomButtonTestId(customButton)\" [label]=\"customButton.name\" [styleClass]=\"customButton.class\" [disabled]=\"context.isGlobalDisabled || customButton.dependsOnValidation && !isValid() || customButton.disabled\" [smzTooltip]=\"customButton.tooltip\" tooltipPosition=\"top\" (click)=\"customClick(customButton)\">\r\n </button>\r\n }\r\n }\r\n }\r\n @if (context.behaviors.showCancelButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('cancel')\" [label]=\"context.builtInButtons.cancelName\" [styleClass]=\"context.builtInButtons.cancelClass\" (click)=\"close()\">\r\n </button>\r\n }\r\n <!-- DependsOnValidation -->\r\n @if (context.behaviors.showConfirmButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('confirm')\" [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\" [dialogId]=\"context.id\" [label]=\"context.builtInButtons.confirmName\" [styleClass]=\"context.builtInButtons.confirmClass\" [disabled]=\"context.isGlobalDisabled\" (click)=\"confirm()\">\r\n </button>\r\n }\r\n <!-- DependsOnValidation -->\r\n @if (context.behaviors.showOkButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('ok')\" [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\" [dialogId]=\"context.id\" [label]=\"context.builtInButtons.okName\" [styleClass]=\"context.builtInButtons.okClass\" [disabled]=\"context.isGlobalDisabled\" (click)=\"ok()\">\r\n </button>\r\n }\r\n <!-- DependsOnValidation -->\r\n @if (context.behaviors.showSaveButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('save')\" [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\" [dialogId]=\"context.id\" [label]=\"context.builtInButtons.saveName\" [styleClass]=\"context.builtInButtons.saveClass\" [icon]=\"context.isLoading ? 'fa-solid fa-spinner fa-spin' : ''\" [disabled]=\"context.isGlobalDisabled\" (click)=\"save()\">\r\n </button>\r\n }\r\n @if (context.customButtonsOrder === 'last') {\r\n @for (customButton of context.customButtons; track customButton) {\r\n <!-- DependsOnValidation -->\r\n @if (customButton.visible == null || customButton.visible) {\r\n <button smzButton [attr.data-testid]=\"buildCustomButtonTestId(customButton)\" [label]=\"customButton.name\" [styleClass]=\"customButton.class\" [disabled]=\"context.isGlobalDisabled || customButton.disabled\" [smzTooltip]=\"customButton.tooltip\" tooltipPosition=\"top\" (click)=\"customClick(customButton)\">\r\n </button>\r\n }\r\n }\r\n }\r\n </div>\r\n </ui-toolbar>\r\n}\r\n", styles: [""], dependencies: [{ kind: "component", type: i0.forwardRef(() => i2.SmzButtonComponent), selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "component", type: i0.forwardRef(() => i2.SmzToolbarComponent), selector: "ui-toolbar" }, { kind: "directive", type: i0.forwardRef(() => i2.SmzTooltipDirective), selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "directive", type: i0.forwardRef(() => ConfirmOnEnterDirective), selector: "[confirmOnEnter]", inputs: ["confirmOnEnter", "clickEvent", "delayConfirmation", "disabled", "dialogId"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
9227
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: DialogFooterComponent, isStandalone: false, selector: "smz-dialog-footer", ngImport: i0, template: "@if (dialogConfig.data._context; as context) {\r\n <ui-toolbar class=\"smz-dialog-footer\">\r\n <div class=\"grid grid-nogutter items-center justify-end gap-2\">\r\n @if (context.customButtonsOrder == null || context.customButtonsOrder === 'first') {\r\n @for (customButton of context.customButtons; track customButton) {\r\n @if (customButton.visible == null || customButton.visible) {\r\n <button smzButton [attr.data-testid]=\"buildCustomButtonTestId(customButton)\" [label]=\"customButton.name\" [styleClass]=\"customButton.class\" [disabled]=\"context.isGlobalDisabled || customButton.dependsOnValidation && !isValid() || customButton.disabled\" [smzTooltip]=\"customButton.tooltip\" tooltipPosition=\"top\" (click)=\"customClick(customButton)\">\r\n </button>\r\n }\r\n }\r\n }\r\n @if (context.behaviors.showCancelButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('cancel')\" [label]=\"context.builtInButtons.cancelName\" [styleClass]=\"context.builtInButtons.cancelClass\" (click)=\"close()\">\r\n </button>\r\n }\r\n <!-- DependsOnValidation -->\r\n @if (context.behaviors.showConfirmButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('confirm')\" [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\" [dialogId]=\"context.id\" [label]=\"context.builtInButtons.confirmName\" [styleClass]=\"context.builtInButtons.confirmClass\" [disabled]=\"context.isGlobalDisabled\" (click)=\"confirm()\">\r\n </button>\r\n }\r\n <!-- DependsOnValidation -->\r\n @if (context.behaviors.showOkButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('ok')\" [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\" [dialogId]=\"context.id\" [label]=\"context.builtInButtons.okName\" [styleClass]=\"context.builtInButtons.okClass\" [disabled]=\"context.isGlobalDisabled\" (click)=\"ok()\">\r\n </button>\r\n }\r\n <!-- DependsOnValidation -->\r\n @if (context.behaviors.showSaveButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('save')\" [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\" [dialogId]=\"context.id\" [label]=\"context.builtInButtons.saveName\" [styleClass]=\"context.builtInButtons.saveClass\" [icon]=\"context.isLoading ? 'fa-solid fa-spinner fa-spin' : ''\" [disabled]=\"context.isGlobalDisabled\" (click)=\"save()\">\r\n </button>\r\n }\r\n @if (context.customButtonsOrder === 'last') {\r\n @for (customButton of context.customButtons; track customButton) {\r\n <!-- DependsOnValidation -->\r\n @if (customButton.visible == null || customButton.visible) {\r\n <button smzButton [attr.data-testid]=\"buildCustomButtonTestId(customButton)\" [label]=\"customButton.name\" [styleClass]=\"customButton.class\" [disabled]=\"context.isGlobalDisabled || customButton.dependsOnValidation && !isValid() || customButton.disabled\" [smzTooltip]=\"customButton.tooltip\" tooltipPosition=\"top\" (click)=\"customClick(customButton)\">\r\n </button>\r\n }\r\n }\r\n }\r\n </div>\r\n </ui-toolbar>\r\n}\r\n", styles: [""], dependencies: [{ kind: "component", type: i0.forwardRef(() => i2.SmzButtonComponent), selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "component", type: i0.forwardRef(() => i2.SmzToolbarComponent), selector: "ui-toolbar" }, { kind: "directive", type: i0.forwardRef(() => i2.SmzTooltipDirective), selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "directive", type: i0.forwardRef(() => ConfirmOnEnterDirective), selector: "[confirmOnEnter]", inputs: ["confirmOnEnter", "clickEvent", "delayConfirmation", "disabled", "dialogId"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
9181
9228
|
}
|
|
9182
9229
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: DialogFooterComponent, decorators: [{
|
|
9183
9230
|
type: Component,
|
|
9184
|
-
args: [{ selector: 'smz-dialog-footer', encapsulation: ViewEncapsulation.None, standalone: false, template: "@if (dialogConfig.data._context; as context) {\r\n <ui-toolbar class=\"smz-dialog-footer\">\r\n <div class=\"grid grid-nogutter items-center justify-end gap-2\">\r\n @if (context.customButtonsOrder == null || context.customButtonsOrder === 'first') {\r\n @for (customButton of context.customButtons; track customButton) {\r\n @if (customButton.visible == null || customButton.visible) {\r\n <button smzButton [attr.data-testid]=\"buildCustomButtonTestId(customButton)\" [label]=\"customButton.name\" [styleClass]=\"customButton.class\" [disabled]=\"context.isGlobalDisabled || customButton.dependsOnValidation && !isValid() || customButton.disabled\" [smzTooltip]=\"customButton.tooltip\" tooltipPosition=\"top\" (click)=\"customClick(customButton)\">\r\n </button>\r\n }\r\n }\r\n }\r\n @if (context.behaviors.showCancelButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('cancel')\" [label]=\"context.builtInButtons.cancelName\" [styleClass]=\"context.builtInButtons.cancelClass\" (click)=\"close()\">\r\n </button>\r\n }\r\n <!-- DependsOnValidation -->\r\n @if (context.behaviors.showConfirmButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('confirm')\" [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\" [dialogId]=\"context.id\" [label]=\"context.builtInButtons.confirmName\" [styleClass]=\"context.builtInButtons.confirmClass\" [disabled]=\"context.isGlobalDisabled\" (click)=\"confirm()\">\r\n </button>\r\n }\r\n <!-- DependsOnValidation -->\r\n @if (context.behaviors.showOkButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('ok')\" [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\" [dialogId]=\"context.id\" [label]=\"context.builtInButtons.okName\" [styleClass]=\"context.builtInButtons.okClass\" [disabled]=\"context.isGlobalDisabled\" (click)=\"ok()\">\r\n </button>\r\n }\r\n <!-- DependsOnValidation -->\r\n @if (context.behaviors.showSaveButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('save')\" [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\" [dialogId]=\"context.id\" [label]=\"context.builtInButtons.saveName\" [styleClass]=\"context.builtInButtons.saveClass\" [icon]=\"context.isLoading ? 'fa-solid fa-spinner fa-spin' : ''\" [disabled]=\"context.isGlobalDisabled\" (click)=\"save()\">\r\n </button>\r\n }\r\n @if (context.customButtonsOrder === 'last') {\r\n @for (customButton of context.customButtons; track customButton) {\r\n <!-- DependsOnValidation -->\r\n @if (customButton.visible == null || customButton.visible) {\r\n <button smzButton [attr.data-testid]=\"buildCustomButtonTestId(customButton)\" [label]=\"customButton.name\" [styleClass]=\"customButton.class\" [disabled]=\"context.isGlobalDisabled || customButton.disabled\" [smzTooltip]=\"customButton.tooltip\" tooltipPosition=\"top\" (click)=\"customClick(customButton)\">\r\n </button>\r\n }\r\n }\r\n }\r\n </div>\r\n </ui-toolbar>\r\n}\r\n" }]
|
|
9231
|
+
args: [{ selector: 'smz-dialog-footer', encapsulation: ViewEncapsulation.None, standalone: false, template: "@if (dialogConfig.data._context; as context) {\r\n <ui-toolbar class=\"smz-dialog-footer\">\r\n <div class=\"grid grid-nogutter items-center justify-end gap-2\">\r\n @if (context.customButtonsOrder == null || context.customButtonsOrder === 'first') {\r\n @for (customButton of context.customButtons; track customButton) {\r\n @if (customButton.visible == null || customButton.visible) {\r\n <button smzButton [attr.data-testid]=\"buildCustomButtonTestId(customButton)\" [label]=\"customButton.name\" [styleClass]=\"customButton.class\" [disabled]=\"context.isGlobalDisabled || customButton.dependsOnValidation && !isValid() || customButton.disabled\" [smzTooltip]=\"customButton.tooltip\" tooltipPosition=\"top\" (click)=\"customClick(customButton)\">\r\n </button>\r\n }\r\n }\r\n }\r\n @if (context.behaviors.showCancelButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('cancel')\" [label]=\"context.builtInButtons.cancelName\" [styleClass]=\"context.builtInButtons.cancelClass\" (click)=\"close()\">\r\n </button>\r\n }\r\n <!-- DependsOnValidation -->\r\n @if (context.behaviors.showConfirmButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('confirm')\" [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\" [dialogId]=\"context.id\" [label]=\"context.builtInButtons.confirmName\" [styleClass]=\"context.builtInButtons.confirmClass\" [disabled]=\"context.isGlobalDisabled\" (click)=\"confirm()\">\r\n </button>\r\n }\r\n <!-- DependsOnValidation -->\r\n @if (context.behaviors.showOkButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('ok')\" [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\" [dialogId]=\"context.id\" [label]=\"context.builtInButtons.okName\" [styleClass]=\"context.builtInButtons.okClass\" [disabled]=\"context.isGlobalDisabled\" (click)=\"ok()\">\r\n </button>\r\n }\r\n <!-- DependsOnValidation -->\r\n @if (context.behaviors.showSaveButton) {\r\n <button smzButton [attr.data-testid]=\"buildDialogTestId('save')\" [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\" [dialogId]=\"context.id\" [label]=\"context.builtInButtons.saveName\" [styleClass]=\"context.builtInButtons.saveClass\" [icon]=\"context.isLoading ? 'fa-solid fa-spinner fa-spin' : ''\" [disabled]=\"context.isGlobalDisabled\" (click)=\"save()\">\r\n </button>\r\n }\r\n @if (context.customButtonsOrder === 'last') {\r\n @for (customButton of context.customButtons; track customButton) {\r\n <!-- DependsOnValidation -->\r\n @if (customButton.visible == null || customButton.visible) {\r\n <button smzButton [attr.data-testid]=\"buildCustomButtonTestId(customButton)\" [label]=\"customButton.name\" [styleClass]=\"customButton.class\" [disabled]=\"context.isGlobalDisabled || customButton.dependsOnValidation && !isValid() || customButton.disabled\" [smzTooltip]=\"customButton.tooltip\" tooltipPosition=\"top\" (click)=\"customClick(customButton)\">\r\n </button>\r\n }\r\n }\r\n }\r\n </div>\r\n </ui-toolbar>\r\n}\r\n" }]
|
|
9185
9232
|
}], ctorParameters: () => [{ type: DynamicDialogRef }, { type: SmzDynamicDialogConfig }, { type: SmzDialogsVisibilityService }, { type: InjectComponentService }, { type: i0.ChangeDetectorRef }, { type: i1$3.Actions }, { type: i1$3.Store }] });
|
|
9186
9233
|
class ConfirmOnEnterDirective {
|
|
9187
9234
|
el;
|
|
@@ -17448,7 +17495,7 @@ class ColumnFilterFormElement {
|
|
|
17448
17495
|
}
|
|
17449
17496
|
}
|
|
17450
17497
|
}
|
|
17451
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i0.forwardRef(() => i1.NgTemplateOutlet), selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i0.forwardRef(() => SmzInputTextDirective), selector: "input[smzInputText]", inputs: ["size", "invalid"] }, { kind: "component", type: i0.forwardRef(() => SmzCheckboxComponent), selector: "ui-checkbox", inputs: ["label", "inputId", "value", "binary", "name"], outputs: ["changed"] }, { kind: "directive", type: i0.forwardRef(() => i1$1.NgControlStatus), selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i0.forwardRef(() => i1$1.NgModel), selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i0.forwardRef(() => SmzDatePickerComponent), selector: "ui-date-picker", inputs: ["selectionMode", "dateFormat", "showTime", "timeOnly", "showSeconds", "hourFormat", "minDate", "maxDate", "showButtonBar", "showIcon", "showOnFocus", "keepInvalid", "readonlyInput", "placeholder", "inputId", "styleClass", "appendTo", "touchUI", "focusTrap"], outputs: ["selected", "cleared", "opened", "closed", "blurred"] }, { kind: "component", type: i0.forwardRef(() => SmzInputNumberComponent), selector: "ui-input-number", inputs: ["mode", "locale", "localeMatcher", "currency", "currencyDisplay", "useGrouping", "minFractionDigits", "maxFractionDigits", "min", "max", "step", "prefix", "suffix", "showButtons", "showClear", "allowEmpty", "placeholder", "readonly", "inputId"], outputs: ["inputed", "keyDown", "blurred", "focused"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
17498
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i0.forwardRef(() => i1.NgTemplateOutlet), selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i0.forwardRef(() => SmzInputTextDirective), selector: "input[smzInputText]", inputs: ["size", "invalid"] }, { kind: "component", type: i0.forwardRef(() => SmzCheckboxComponent), selector: "ui-checkbox", inputs: ["label", "inputId", "value", "binary", "name"], outputs: ["changed"] }, { kind: "directive", type: i0.forwardRef(() => i1$1.NgControlStatus), selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i0.forwardRef(() => i1$1.NgModel), selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i0.forwardRef(() => SmzDatePickerComponent), selector: "ui-date-picker", inputs: ["selectionMode", "dateFormat", "showTime", "timeOnly", "showSeconds", "hourFormat", "minDate", "maxDate", "showButtonBar", "showIcon", "showOnFocus", "keepInvalid", "readonlyInput", "placeholder", "inputId", "styleClass", "appendTo", "touchUI", "focusTrap"], outputs: ["selected", "cleared", "opened", "closed", "blurred"] }, { kind: "component", type: i0.forwardRef(() => SmzInputNumberComponent), selector: "ui-input-number", inputs: ["mode", "locale", "localeMatcher", "currency", "currencyDisplay", "useGrouping", "minFractionDigits", "maxFractionDigits", "min", "max", "step", "prefix", "suffix", "showButtons", "showClear", "allowEmpty", "placeholder", "readonly", "inputId", "name"], outputs: ["inputed", "keyDown", "blurred", "focused"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
17452
17499
|
}
|
|
17453
17500
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: ColumnFilterFormElement, decorators: [{
|
|
17454
17501
|
type: Component,
|
|
@@ -21906,6 +21953,8 @@ class SmzTableComponent {
|
|
|
21906
21953
|
return this.buildTableTestId();
|
|
21907
21954
|
}
|
|
21908
21955
|
selectionChange = new EventEmitter();
|
|
21956
|
+
/** Validade da tabela (selecao obrigatoria). O `state` pode ser substituido por uma copia internamente, entao a validade tambem sai por aqui. */
|
|
21957
|
+
validChange = new EventEmitter();
|
|
21909
21958
|
filterChange = new EventEmitter();
|
|
21910
21959
|
columnVisibilityChange = new EventEmitter();
|
|
21911
21960
|
create = new EventEmitter();
|
|
@@ -22497,6 +22546,7 @@ class SmzTableComponent {
|
|
|
22497
22546
|
}
|
|
22498
22547
|
if (this.state.caption.rowSelection.validationMode === 'required') {
|
|
22499
22548
|
this.state.isValid = event.length > 0;
|
|
22549
|
+
this.validChange.emit(this.state.isValid);
|
|
22500
22550
|
}
|
|
22501
22551
|
}
|
|
22502
22552
|
onFilter(event) {
|
|
@@ -22559,11 +22609,11 @@ class SmzTableComponent {
|
|
|
22559
22609
|
this.tableHelper.clear(this.tableKey);
|
|
22560
22610
|
}
|
|
22561
22611
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzTableComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: TableEditableService }, { token: TableFormsService }, { token: TableHelperService }, { token: i1$3.Store }, { token: SmzExcelService }], target: i0.ɵɵFactoryTarget.Component });
|
|
22562
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzTableComponent, isStandalone: false, selector: "smz-ui-table", inputs: { state: "state", items: "items", loading: "loading" }, outputs: { selectionChange: "selectionChange", filterChange: "filterChange", columnVisibilityChange: "columnVisibilityChange", create: "create", update: "update", delete: "delete" }, host: { properties: { "attr.data-testid": "this.hostTestId" } }, providers: [TableEditableService, TableFormsService], queries: [{ propertyName: "templates", predicate: SmzTemplateDirective }], viewQueries: [{ propertyName: "table", first: true, predicate: ["dt"], descendants: true }, { propertyName: "columnMultiselect", first: true, predicate: ["columnMultiselect"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "@if (state | tableContext; as context) {\n @if ((context.state.emptyFeedback != null && (context.state.emptyFeedback.extraInfo || context.state.emptyFeedback.image || context.state.emptyFeedback.actionButtons)) && (items != null && items.length === 0) && context.state.emptyFeedback.isFeatured) {\n <smz-data-info\n [attr.data-testid]=\"buildTableTestId('empty')\"\n [image]=\"context.state.emptyFeedback.image\"\n [message]=\"context.state.emptyFeedback.message\"\n [callbackInfo]=\"context.state.emptyFeedback.extraInfo\"\n [actions]=\"context.state.emptyFeedback.actionButtons\">\n <ng-template smzTemplate=\"actions\">\n <ng-container *ngTemplateOutlet=\"emptyActionsTemplate; context: { $implicit: {} }\"></ng-container>\n </ng-template>\n </smz-data-info>\n } @else {\n <ng-container *ngVar=\"state.source?.items$ != null ? (state.source.items$ | async) : null as observableSource\">\n <ng-container *ngVar=\"state.source?.signalItems != null ? state.source.signalItems() : null as signalSource\">\n @if (((observableSource ?? signalSource ?? items) | cloneTableItems : context: tableKey: context.state.rowExpansion.sincronize); as clonedData) {\n <p-table #dt\n dataKey=\"id\"\n editMode=\"row\"\n [stripedRows]=\"context.state.styles.striped\"\n [value]=\"clonedData.items\"\n [(selection)]=\"selectedItems\"\n [tableStyleClass]=\"context.state.styles.tableStyleClass\"\n [size]=\"context.state.styles.size === 'extra-small' ? 'small' : context.state.styles.size === 'small' ? 'small' : context.state.styles.size === 'large' ? 'large' : undefined\"\n [class]=\"'p-datatable-smz-ui-table' + (context.state.styles.showGrid ? ' p-datatable-gridlines' : '') + (context.state.styles.size === 'extra-small' ? ' p-datatable-xs' : '') + (context.state.styles.size === 'small' ? ' p-datatable-sm' : '') + (context.state.styles.size === 'large' ? ' p-datatable-lg' : '')\"\n [rowHover]=\"context.state.actions.rowBehavior.hoverable\"\n [rows]=\"context.state.pagination.rows\"\n [first]=\"context.state.pagination.state.first\"\n [showCurrentPageReport]=\"context.state.pagination.pageReport.isVisible\"\n [rowsPerPageOptions]=\"context.state.pagination.rowsPerPageOptions\"\n [loading]=\"loading || isViewportInitializing\"\n [style.visibility]=\"isViewportInitializing ? 'hidden' : null\"\n [paginator]=\"context.state.pagination.isVisible\"\n paginatorDropdownAppendTo=\"body\"\n [currentPageReportTemplate]=\"context.state.locale.paginator.template\"\n [sortField]=\"context.state.sort.field\"\n [sortMode]=\"context.state.sort.mode\"\n [sortOrder]=\"context.state.sort.order\"\n [multiSortMeta]=\"context.state.sort.multiSortMeta\"\n [scrollable]=\"context.state.viewport.scrollable\"\n [scrollHeight]=\"context.state.viewport.scrollHeight\"\n [filterDelay]=\"0\"\n [globalFilterFields]=\"context.globalFilter\"\n [columns]=\"context.visibleColumns\"\n [frozenColumns]=\"context.frozenColumns\"\n [frozenWidth]=\"context.state.frozen.isEnabled ? context.state.frozen.width : null\"\n [resizableColumns]=\"context.state.viewport.resizableColumns\"\n [columnResizeMode]=\"context.state.viewport.columnResizeMode\"\n (onPage)=\"onPage($event)\"\n (onFilter)=\"onFilter($event)\"\n (selectionChange)=\"emitSelection($event)\"\n >\n @if (context.state.caption.isVisible) {\n <ng-template smzTemplate=\"caption\">\n <div class=\"grid grid-nogutter items-center gap-2\" [attr.data-testid]=\"buildTableTestId('caption')\" [ngClass]=\"'justify-' + context.state.caption.toolbarAlignment\">\n @if (context.state.caption.title != null) {\n <div class=\"col database-title\" [attr.data-testid]=\"buildTableTestId('title')\" [innerHTML]=\"context.state.caption.title\"></div>\n }\n <ng-container *ngTemplateOutlet=\"captionTemplate; context: { $implicit: dt }\"></ng-container>\n <smz-table-caption-buttons [buttons]=\"context.state.caption.buttons\" [tableTestId]=\"state.tableTestId\"></smz-table-caption-buttons>\n @if (context.state.caption.exportToPdf.isButtonVisible) {\n <button smzButton [attr.data-testid]=\"buildTableTestId('export-pdf')\" [label]=\"context.state.locale.exportToPdf.label\" icon=\"fa-solid fa-file-pdf\" (click)=\"exportToPdf(context, clonedData.items)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\n }\n @if (context.state.caption.exportToExcel.isButtonVisible) {\n <button smzButton [attr.data-testid]=\"buildTableTestId('export-excel')\" [label]=\"context.state.locale.exportToExcel.label\" icon=\"fa-solid fa-file-excel\" (click)=\"exportToExcel(table, context, clonedData.items)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\n }\n @if (context.state.editable.creation.isButtonVisible) {\n <button smzButton [attr.data-testid]=\"buildTableTestId('create')\" [label]=\"context.state.editable.creation.buttonLabel\" icon=\"fa-solid fa-plus\" (click)=\"editableService.onRowCreateInit(table, context.columns)\" [disabled]=\"clonedData.showSkeleton || editableService.isEditing || editableService.isCreating || context.state.editable.creation.isButtonDisabled\" variant=\"outlined\"></button>\n }\n @if (context.state.caption.rowSelection.isButtonVisible) {\n <button smzButton [attr.data-testid]=\"buildTableTestId('row-selection')\" [label]=\"context.state.locale.rowSelection.label\" icon=\"fa-solid fa-check-double\" (click)=\"onRowSelection(context)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\n }\n @if (context.state.rowExpansion.isButtonVisible) {\n <button smzButton [attr.data-testid]=\"buildTableTestId('row-expansion')\" [label]=\"context.state.rowExpansion.label\" icon=\"fa-solid fa-list\" (click)=\"onRowExpansion(context)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\n }\n @if (context.state.caption.clearFilters.isButtonVisible) {\n <button smzButton [attr.data-testid]=\"buildTableTestId('clear-filters')\" [label]=\"context.state.locale.clearFilters.label\" icon=\"fa-solid fa-filter-circle-xmark\" (click)=\"clear(table, context)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\n }\n @if (context.state.caption.columnVisibility.showDropdownSelector) {\n <ui-multi-select #columnMultiselect [attr.data-testid]=\"buildTableTestId('column-visibility')\" class=\"ml-2 col-12 md:col-2\" styleClass=\"w-full\" appendTo=\"body\" [options]=\"context.hideableColumns\" [(ngModel)]=\"selectedColumns\" [placeholder]=\"context.state.locale.columnVisibility.placeholder\" [selectedItemsLabel]=\"context.state.locale.columnVisibility.selectedItemsLabel\" optionLabel=\"name\" dataKey=\"field\" optionLabel=\"header\" [filter]=\"true\" (panelHide)=\"updateColumnsVisibility(true)\" [smzTooltip]=\"context.state.locale.columnVisibility.pTooltip\">\n </ui-multi-select>\n }\n @if (context.state.caption.globalFilter.isVisible) {\n <ui-icon-field class=\"col-12\" [ngClass]=\"{ 'md:col-2': !context.state.caption.globalFilter.expanded }\">\n <ui-input-icon styleClass=\"fa-solid fa-magnifying-glass\"></ui-input-icon>\n <input #inputGlobal [(ngModel)]=\"globalSearchInput\" smzInputText type=\"text\" styleClass=\"database-global-search\" (input)=\"updateGlobalFilter(inputGlobal.value)\" [disabled]=\"clonedData.showSkeleton\" [placeholder]=\"context.state.locale.globalFilter.placeholder\" [attr.data-testid]=\"buildTableTestId('search')\" />\n </ui-icon-field>\n }\n </div>\n @if (toolbarTemplate != null) {\n <div class=\"grid grid-nogutter items-center mt-2\" [ngClass]=\"'justify-' + context.state.caption.toolbarAlignment\">\n <ng-container *ngTemplateOutlet=\"toolbarTemplate; context: { $implicit: dt }\"></ng-container>\n </div>\n }\n </ng-template>\n }\n <ng-template smzTemplate=\"header\" let-columns>\n <tr [ngClass]=\"{ 'invisible-header': !context.state.header.isVisible }\">\n @if (context.state.caption.rowSelection.isEnabled) {\n <th [ngStyle]=\"context.state.caption.rowSelection.ngStyle\">\n @if (!context.state.actions.batchActions.isVisible) {\n <p-tableHeaderCheckbox></p-tableHeaderCheckbox>\n }\n </th>\n }\n @if (context.state.rowExpansion.isEnabled) {\n <th [ngStyle]=\"context.state.rowExpansion.ngStyle\"></th>\n }\n @for (col of columns; track col.field) {\n @if (context.state.viewport.resizableColumns) {\n @if (col.isOrderable) {\n <th [pSortableColumn]=\"col.sortField\" pResizableColumn [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\n </th>\n }\n @if (!col.isOrderable) {\n <th pResizableColumn [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\n </th>\n }\n } @else {\n @if (col.isOrderable) {\n <th [pSortableColumn]=\"col.sortField\" [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\n </th>\n }\n @if (!col.isOrderable) {\n <th [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\n </th>\n }\n }\n <ng-template #headerContent>\n <div class=\"flex justify-start items-center\">\n <span class=\"mr-1\">{{ col.header }}</span>\n @if (col.showHeaderActions) {\n <smz-table-header-actions clickStopPropagation class=\"ml-1 mt-1\" [col]=\"col\"></smz-table-header-actions>\n }\n @if (!clonedData.showSkeleton && col.isOrderable) {\n <p-sortIcon [field]=\"col.sortField\"></p-sortIcon>\n }\n @if (!clonedData.showSkeleton) {\n @switch (col.filter.type) {\n @case (filterTypes.currency) {\n <smz-column-filter type=\"numeric\" currency=\"BRL\" [field]=\"col.filterField\"></smz-column-filter>\n }\n @case (filterTypes.numeric) {\n <smz-column-filter type=\"numeric\" [field]=\"col.filterField\"></smz-column-filter>\n }\n @case (filterTypes.date) {\n <smz-column-filter type=\"date\" [field]=\"col.filterField\" [showTime]=\"col.filter.showTime\"></smz-column-filter>\n }\n @case (filterTypes.text) {\n <smz-column-filter type=\"text\" [field]=\"col.filterField\"></smz-column-filter>\n }\n @case (filterTypes.boolean) {\n <smz-column-filter type=\"boolean\" [field]=\"col.filterField\"></smz-column-filter>\n }\n @case (filterTypes.dropdown) {\n @if (col.filterField | filterObject; as filterField) {\n <smz-column-filter [field]=\"filterField + '.id'\" matchMode=\"dropdown\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\n <ng-template smzTemplate=\"header\">\n <div class=\"px-3 pt-3 pb-0\">\n <span class=\"p-text-bold\">{{ col.header }}</span>\n </div>\n </ng-template>\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\n <ui-select appendTo=\"body\" [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField + '.id' : filterField : null : 'name' : false\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" optionLabel=\"name\" dataKey=\"id\"></ui-select>\n </ng-template>\n </smz-column-filter>\n }\n }\n @case (filterTypes.multiselect) {\n @if (col.filterField | filterObject; as filterField) {\n <smz-column-filter [field]=\"filterField\" matchMode=\"in\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\n <ng-template smzTemplate=\"header\">\n <div class=\"px-3 pt-3 pb-0\">\n <span class=\"p-text-bold\">{{ col.header }}</span>\n </div>\n </ng-template>\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\n <ui-multi-select [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField + '.id' : filterField : null : 'name' : false\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" optionLabel=\"name\" dataKey=\"id\"></ui-multi-select>\n </ng-template>\n </smz-column-filter>\n }\n }\n @case (filterTypes.multiselect_array) {\n @if (col.filterField | filterObject; as filterField) {\n <smz-column-filter [field]=\"filterField\" matchMode=\"array-some\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\n <ng-template smzTemplate=\"header\">\n <div class=\"px-3 pt-3 pb-0\">\n <span class=\"p-text-bold\">{{ col.header }}</span>\n </div>\n </ng-template>\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\n <ui-multi-select [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField + '.id' : filterField : null : 'name' : true\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" optionLabel=\"name\" dataKey=\"id\" [maxSelectedLabels]=\"2\" [selectedItemsLabel]=\"'{0}'\"></ui-multi-select>\n </ng-template>\n </smz-column-filter>\n }\n }\n @case (filterTypes.multiselect_string) {\n @if (col.filterField | filterObject; as filterField) {\n <smz-column-filter [field]=\"filterField\" matchMode=\"multiselectByString\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\n <ng-template smzTemplate=\"header\">\n <div class=\"px-3 pt-3 pb-0\">\n <span class=\"p-text-bold\">{{ col.header }}</span>\n </div>\n </ng-template>\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\n <ui-multi-select [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField : filterField : null : true : false : false\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" [maxSelectedLabels]=\"2\" [selectedItemsLabel]=\"'{0}'\"></ui-multi-select>\n </ng-template>\n </smz-column-filter>\n }\n }\n }\n }\n @if (context.state.caption.columnVisibility.showColumnHideButton) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-eye-slash\" (click)=\"hideColumn(col, context)\" [rounded]=\"true\" variant=\"text\" styleClass=\"p-button-plain\"></button>\n }\n </div>\n </ng-template>\n }\n @if (context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible|| context.state.editable.isEditable) {\n <th [ngStyle]=\"context.state.editable.isEditable ? context.state.editable.ngStyle : context.state.actions.customActions.ngStyle\"></th>\n }\n </tr>\n @if (context.state.actions.batchActions.isVisible) {\n <tr>\n <th [attr.colspan]=\"columns.length + ((context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) ? 1 : 0) + (context.state.caption.rowSelection.isEnabled ? 1 : 0) + (context.state.rowExpansion.isEnabled ? 1 : 0)\"\n [ngStyle]=\"context.state.actions.customActions.ngStyle\" class=\"px-0\">\n <div class=\"grid grid-nogutter items-center justify-start\">\n <p-tableHeaderCheckbox class=\"mr-4\"></p-tableHeaderCheckbox>\n @if (selectedItems?.length > 0) {\n @for (batchItem of context.state.actions.batchActions.items; track batchItem.label) {\n @if (batchItem.visible) {\n <button smzButton [label]=\"batchItem.label\" class=\"animate__animated animate__fadeIn\" [styleClass]=\"'p-button-plain ' + (batchItem.styleClass)\" [icon]=\"batchItem.icon\" (click)=\"batchItem.command(selectedItems); selectedItems = [];\" [disabled]=\"batchItem.disabled\" [smzTooltip]=\"batchItem.tooltip\" [rounded]=\"true\" variant=\"text\"></button>\n }\n }\n }\n </div>\n </th>\n </tr>\n }\n </ng-template>\n <ng-template smzTemplate=\"body\" let-item let-editing=\"editing\" let-rowIndex=\"rowIndex\" let-columns=\"columns\">\n <tr #editableRowElement\n [pEditableRow]=\"item\"\n tableItemAction\n [isClickable]=\"context.state.actions.rowBehavior.isClickable\"\n [callback]=\"context.state.actions.rowBehavior.clickCallback\"\n [expandRowOnClick]=\"context.state.actions.rowBehavior.expandRowOnClick\"\n [item]=\"item\"\n class=\"p-selectable-row\"\n [attr.data-testid]=\"buildRowTestId(item, rowIndex)\"\n [ngClass]=\"{ 'highlight-row': item?.id === state.actions.rowBehavior.highlights, 'preserve-in-small': state.actions.rowBehavior.preserveLayoutInSmallDevices }\"\n >\n @if (context.state.caption.rowSelection.isEnabled && !clonedData.showSkeleton) {\n <td\n clickStopPropagation\n class=\"{{ state.actions.rowBehavior.cellStyleClass }}\"\n [ngClass]=\"{ 'opacity-50 pointer-events-none': editableService.context[item.id]?.hasErrors || editableService.context[item.id]?.isLoading }\"\n [ngStyle]=\"context.state.caption.rowSelection.ngStyle\"\n >\n <p-tableCheckbox [value]=\"item\"></p-tableCheckbox>\n </td>\n }\n @if (context.state.rowExpansion.isEnabled && !clonedData.showSkeleton) {\n <td\n clickStopPropagation\n class=\"{{ state.actions.rowBehavior.cellStyleClass }}\"\n [ngClass]=\"{ 'opacity-50 pointer-events-none': editableService.context[item.id]?.hasErrors || editableService.context[item.id]?.isLoading, 'grid grid-nogutter justify-start items-center gap-2': context.state.rowExpansion.highlightNewItems && item._isNew }\"\n [ngStyle]=\"context.state.rowExpansion.ngStyle\"\n >\n <button smzButton type=\"button\" class=\"smz-table-row-expansion-toggle\" [icon]=\"item._isExpanded ? 'fa-solid fa-chevron-down' : 'fa-solid fa-chevron-right'\" (click)=\"item._isExpanded = !item._isExpanded; item._isNew = false\" variant=\"text\" [rounded]=\"true\" size=\"sm\"></button>\n @if (context.state.rowExpansion.highlightNewItems && item._isNew) {\n <div class=\"rounded bg-cyan-400 text-sm text-white px-2 py-0 smz-table-new-tag\" (click)=\"item._isNew = false\">{{ context.state.rowExpansion.highlightLabel }}</div>\n }\n </td>\n }\n @for (col of columns; track col.field) {\n @if (clonedData.showSkeleton) {\n <td class=\"{{ state.actions.rowBehavior.cellStyleClass }}\" [ngStyle]=\"col.content.ngStyle\"><ui-skeleton width=\"100%\" height=\"1rem\"></ui-skeleton></td>\n } @else {\n <td class=\"{{ state.actions.rowBehavior.cellStyleClass }}\" [attr.data-testid]=\"buildCellTestId(item, rowIndex, col.field)\" [ngClass]=\"{ 'opacity-50 pointer-events-none': editableService.context[item.id]?.hasErrors || editableService.context[item.id]?.isLoading }\" [ngStyle]=\"col.content.ngStyle\">\n <span class=\"p-column-title\">{{ col.header }}</span>\n <p-cellEditor>\n <!-- CELULAR COM EDITOR -->\n <ng-template smzTemplate=\"input\">\n @switch (col.editable.type) {\n @case (editableTypes.none) {\n <smz-table-content class=\"cursor-default\" [ngClass]=\"col.content.contentStyleClass\" [col]=\"col\" [contentTypes]=\"contentTypes\" [item]=\"item\" [rowIndex]=\"rowIndex\" [contentTemplate]=\"contentTemplate\"></smz-table-content>\n }\n @case (editableTypes.custom) {\n <ng-container *ngTemplateOutlet=\"editableTemplate; context: { $implicit: item, col: col }\"></ng-container>\n }\n <!-- INPUT TEXT -->\n @case (editableTypes.text) {\n @if (editableService.context[item.id]?.form; as form) {\n @if (form.controls[col.editable.property]; as control) {\n <div class=\"relative w-full\">\n <input smzInputText type=\"text\" [formControl]=\"$any(control)\" style=\"width: 100%;\">\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\n </div>\n }\n }\n }\n <!-- INPUT NUMBER -->\n @case (editableTypes.number) {\n @if (editableService.context[item.id]?.form; as form) {\n @if (form.controls[col.editable.property]; as control) {\n <div class=\"relative w-full\">\n <ui-input-number *ngVar=\"col.editable.data as numberData\" [formControl]=\"$any(control)\" [mode]=\"numberData.mode\" [minFractionDigits]=\"numberData.minFractionDigits\" [maxFractionDigits]=\"numberData.maxFractionDigits\" [currency]=\"numberData.currency\" [useGrouping]=\"numberData.useGrouping\" [allowEmpty]=\"numberData.allowEmpty\" [showClear]=\"numberData.showClear\" [showButtons]=\"numberData.showButtons\" [prefix]=\"numberData.prefix\" [suffix]=\"numberData.suffix\">\n </ui-input-number>\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\n </div>\n }\n }\n }\n <!-- INPUT SWITCH -->\n @case (editableTypes.switch) {\n @if (editableService.context[item.id]?.form; as form) {\n @if (form.controls[col.editable.property]; as control) {\n <div class=\"relative w-full\">\n <ui-toggle-switch [formControl]=\"$any(control)\"></ui-toggle-switch>\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\n </div>\n }\n }\n }\n <!-- INPUT TEXT AREA -->\n @case (editableTypes.area) {\n @if (editableService.context[item.id]?.form; as form) {\n @if (form.controls[col.editable.property]; as control) {\n <div class=\"relative w-full\">\n <textarea smzTextarea type=\"text\" [formControl]=\"$any(control)\" [rows]=\"$any(col.editable.data).rows\" required style=\"width: 100%;\"></textarea>\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\n </div>\n }\n }\n }\n <!-- INPUT DROPDOWN -->\n @case (editableTypes.dropdown) {\n @if (editableService.context[item.id]?.form; as form) {\n @if (form.controls[col.editable.property]; as control) {\n <div class=\"relative w-full\">\n <ui-select appendTo=\"body\" [formControl]=\"$any(control)\" styleClass=\"w-full\" [options]=\"col.editable.data | editableSource\" optionLabel=\"name\" dataKey=\"id\" [placeholder]=\"$any(col.editable.data).placeholder\" [showClear]=\"!col.editable.validatorsPreset?.isRequired\" [filter]=\"true\"></ui-select>\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\n </div>\n }\n }\n }\n <!-- INPUT CALENDAR -->\n @case (editableTypes.calendar) {\n @if (editableService.context[item.id]?.form; as form) {\n @if (form.controls[col.editable.property]; as control) {\n <div class=\"relative w-full\">\n <ui-date-picker [formControl]=\"$any(control)\" appendTo=\"body\" styleClass=\"w-full\" [ngClass]=\"{ 'pl-5': !control.valid }\"></ui-date-picker>\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\n </div>\n }\n }\n }\n }\n </ng-template>\n <!-- CELULAR COM CONTE\u00DADO -->\n <ng-template smzTemplate=\"output\">\n <smz-table-content\n [col]=\"col\"\n [smzTooltip]=\"col.content.tooltip != null ? col.content.tooltip(item) : null\"\n tooltipPosition=\"left\"\n [ngClass]=\"col.content.contentStyleClass\" [contentTypes]=\"contentTypes\" [item]=\"item\" [rowIndex]=\"rowIndex\" [contentTemplate]=\"contentTemplate\">\n </smz-table-content>\n </ng-template>\n </p-cellEditor>\n </td>\n }\n }\n @if (context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) {\n <td [ngStyle]=\"context.state.actions.customActions.ngStyle\" class=\"px-0\">\n <div class=\"grid grid-nogutter items-center justify-center\">\n @if (clonedData.showSkeleton) {\n <div class=\"w-full\">\n <ui-skeleton width=\"100%\" height=\"1rem\"></ui-skeleton>\n </div>\n } @else {\n <!-- SEM EDITAR -->\n @if (!editing) {\n @if (context.state.editable.update.isButtonVisible) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-pencil\" (click)=\"editableService.onRowEditInit(item)\" class=\"mx-1\" [disabled]=\"editableService.isEditing || editableService.isCreating || context.state.editable.update.isButtonDisabled || (!context.state.editable.update.condition(item))\" pInitEditableRow [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (context.state.editable.remove.isButtonVisible) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-trash\" (click)=\"editableService.onRowRemove($event, table, item)\" class=\"mx-1\" [disabled]=\"editableService.isEditing || editableService.isCreating || context.state.editable.remove.isButtonDisabled || (!context.state.editable.remove.condition(item))\" [rounded]=\"true\" variant=\"text\" severity=\"secondary\"></button>\n }\n }\n <!-- EDITANDO -->\n @if (editing) {\n @if (editableService.context[item.id]; as editableContext) {\n <!-- COM LOADING -->\n @if (editableContext.isLoading) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-rotate fa-spin\" [disabled]=\"true\" class=\"mr-2\" [rounded]=\"true\" variant=\"text\" styleClass=\"p-button-info\"></button>\n }\n <!-- SEM LOADING -->\n @if (!editableContext.isLoading) {\n <!-- EDITANDO -->\n @if (!editableContext.hasErrors) {\n <!-- CRIANDO -->\n @if (item._context?.isCreating) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-check\" (click)=\"editableService.onRowCreateSave($event, table, editableRowElement, item)\" [disabled]=\"!editableContext.hasChanged || !editableService.context[item.id]?.form.valid\" class=\"mr-2\" [rounded]=\"true\" variant=\"text\" severity=\"success\"></button>\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowCreateCancel($event, table, item)\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\n }\n <!-- ATUALIZANDO -->\n @if (item._context?.isUpdating) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-check\" (click)=\"editableService.onRowEditSave($event, table, editableRowElement, item)\" [disabled]=\"!editableContext.hasChanged || !editableService.context[item.id]?.form.valid\" class=\"mr-2\" [rounded]=\"true\" variant=\"text\" severity=\"success\"></button>\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowEditCancel($event, table, item)\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\n }\n }\n <!-- COM ERRORS -->\n @if (editableContext.hasErrors) {\n <ui-popover #errorsOverlay appendTo=\"body\" [style]=\"{ width: '450px' }\">\n <div [innerHtml]=\"editableContext.errors | contentErrors\"></div>\n </ui-popover>\n <button smzButton type=\"button\" icon=\"fas fa-exclamation-triangle\" [disabled]=\"false\" class=\"mr-2\" (click)=\"errorsOverlay.toggle($event)\" size=\"sm\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\n <!-- CRIANDO -->\n @if (item._context?.isCreating) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowCreateCancel($event, table, item)\" size=\"sm\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\n }\n <!-- ATUALIZANDO -->\n @if (item._context?.isUpdating) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowEditCancel($event, table, item)\" size=\"sm\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\n }\n }\n }\n }\n }\n <!-- CUSTOM MENU -->\n @if (context.state.actions.customActions.isVisible && !editing) {\n <ng-container *ngTemplateOutlet=\"actionsTemplate; context: { $implicit: item }\"></ng-container>\n }\n <!-- MENU -->\n @if (context.state.actions.menu.isVisible && !editing) {\n <smz-menu [callback]=\"context.state.actions.menu.callback\" [items]=\"context.state.actions.menu.items\" [data]=\"item\" [behavior]=\"context.state.actions.menu.behavior\" [ngClass]=\"{ 'ml-2': context.state.actions.customActions.isVisible }\" [icon]=\"context.state.actions.menu.styles.icon\" [styleClass]=\"context.state.actions.menu.styles.styleClass\" [buttonClass]=\"context.state.actions.menu.styles.buttonClass\" [testId]=\"buildRowMenuTestId(item, rowIndex)\"></smz-menu>\n }\n }\n </div>\n </td>\n }\n </tr>\n @if (item?._isExpanded) {\n <tr>\n <td [attr.colspan]=\"columns.length + ((context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) ? 1 : 0) + (context.state.caption.rowSelection.isEnabled ? 1 : 0) + (context.state.rowExpansion.isEnabled ? 1 : 0)\">\n <ng-container *ngTemplateOutlet=\"rowContentTemplate; context: { $implicit: item }\"></ng-container>\n </td>\n </tr>\n }\n </ng-template>\n <ng-template smzTemplate=\"emptymessage\" let-columns>\n <tr>\n <td [attr.colspan]=\"columns.length + ((context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) ? 1 : 0) + (context.state.caption.rowSelection.isEnabled ? 1 : 0) + (context.state.rowExpansion.isEnabled ? 1 : 0)\" [ngStyle]=\"{ 'text-align': 'center' }\">\n <div [innerHtml]=\"context.state.emptyFeedback.message\"></div>\n @if (context.state.caption.clearFilters.isButtonVisible && hasFilters()) {\n <button smzButton [label]=\"context.state.locale.clearFilters.label\" class=\"mt-3\" icon=\"fa-solid fa-filter-circle-xmark\" (click)=\"clear(table, context)\" variant=\"outlined\"></button>\n }\n </td>\n </tr>\n </ng-template>\n </p-table>\n }\n </ng-container>\n </ng-container>\n }\n} @else {\n @if (emptyStateTemplate != null) {\n <ng-container *ngTemplateOutlet=\"emptyStateTemplate; context: { $implicit: {} }\"></ng-container>\n }\n}\n\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "stripedRows", "size", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "virtualRowHeight", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll"], outputs: ["selectAllChange", "selectionChange", "contextMenuSelectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "directive", type: ResizableColumn, selector: "[pResizableColumn]", inputs: ["pResizableColumnDisabled"] }, { kind: "component", type: CellEditor, selector: "p-cellEditor" }, { kind: "component", type: SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: TableCheckbox, selector: "p-tableCheckbox", inputs: ["disabled", "value", "index", "inputId", "name", "required", "ariaLabel"] }, { kind: "component", type: TableHeaderCheckbox, selector: "p-tableHeaderCheckbox", inputs: ["disabled", "inputId", "name", "ariaLabel"] }, { kind: "directive", type: EditableRow, selector: "[pEditableRow]", inputs: ["pEditableRow", "pEditableRowDisabled"] }, { kind: "directive", type: InitEditableRow, selector: "[pInitEditableRow]" }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "directive", type: i2.SmzInputTextDirective, selector: "input[smzInputText]", inputs: ["size", "invalid"] }, { kind: "component", type: i2.SmzMultiSelectComponent, selector: "ui-multi-select", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "placeholder", "filter", "filterBy", "filterMatchMode", "filterPlaceholder", "showClear", "showToggleAll", "emptyMessage", "emptyFilterMessage", "maxSelectedLabels", "selectedItemsLabel", "panelStyle", "styleClass", "inputId", "autofocusFilter", "appendTo", "display"], outputs: ["changed", "panelHide", "panelShow"] }, { kind: "component", type: i2.SmzSelectComponent, selector: "ui-select", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "placeholder", "filter", "filterBy", "filterMatchMode", "filterPlaceholder", "showClear", "emptyMessage", "emptyFilterMessage", "styleClass", "inputId", "ariaLabel", "appendTo"], outputs: ["changed", "showed", "hidden"] }, { kind: "component", type: i2.SmzDatePickerComponent, selector: "ui-date-picker", inputs: ["selectionMode", "dateFormat", "showTime", "timeOnly", "showSeconds", "hourFormat", "minDate", "maxDate", "showButtonBar", "showIcon", "showOnFocus", "keepInvalid", "readonlyInput", "placeholder", "inputId", "styleClass", "appendTo", "touchUI", "focusTrap"], outputs: ["selected", "cleared", "opened", "closed", "blurred"] }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: TableItemActionsDirective, selector: "[tableItemAction]", inputs: ["isClickable", "item", "callback", "expandRowOnClick"] }, { kind: "directive", type: ClickStopPropagationDirective, selector: "[clickStopPropagation]" }, { kind: "component", type: SmzDataInfoComponent, selector: "smz-data-info", inputs: ["image", "message", "actions", "callbackInfo", "callbackLabel"], outputs: ["clicked"] }, { kind: "directive", type: i2.SmzTooltipDirective, selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "component", type: i2.SmzSkeletonComponent, selector: "ui-skeleton", inputs: ["shape", "width", "height"] }, { kind: "directive", type: i2.SmzTextareaDirective, selector: "textarea[smzTextarea]", inputs: ["invalid", "autoResize"] }, { kind: "component", type: i2.SmzPopoverComponent, selector: "ui-popover", inputs: ["style", "styleClass", "dismissable", "autoZIndex", "appendTo"], outputs: ["shown", "hidden"] }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i2.SmzToggleSwitchComponent, selector: "ui-toggle-switch", inputs: ["name"], outputs: ["changed"] }, { kind: "component", type: i2.SmzInputNumberComponent, selector: "ui-input-number", inputs: ["mode", "locale", "localeMatcher", "currency", "currencyDisplay", "useGrouping", "minFractionDigits", "maxFractionDigits", "min", "max", "step", "prefix", "suffix", "showButtons", "showClear", "allowEmpty", "placeholder", "readonly", "inputId"], outputs: ["inputed", "keyDown", "blurred", "focused"] }, { kind: "component", type: SmzMenuComponent, selector: "smz-menu", inputs: ["items", "callback", "data", "buttonClass", "styleClass", "icon", "behavior", "testId"] }, { kind: "directive", type: NgVar, selector: "[ngVar]", inputs: ["ngVar"] }, { kind: "component", type: i2.SmzIconFieldComponent, selector: "ui-icon-field" }, { kind: "component", type: i2.SmzInputIconComponent, selector: "ui-input-icon", inputs: ["styleClass"] }, { kind: "component", type: SmzColumnFilterComponent, selector: "smz-column-filter", inputs: ["currency", "display", "field", "matchMode", "showAddButton", "showMatchModes", "showOperator", "showApplyButton", "type", "showTime"] }, { kind: "component", type: SmzTableValidationMessagesComponent, selector: "smz-table-validation-messages", inputs: ["errors", "messages", "isFormInvalid", "isFormDirty"] }, { kind: "component", type: SmzTableContentComponent, selector: "smz-table-content", inputs: ["col", "contentTypes", "item", "rowIndex", "contentTemplate"] }, { kind: "component", type: SmzTableCaptionButtonsComponent, selector: "smz-table-caption-buttons", inputs: ["buttons", "tableTestId"] }, { kind: "component", type: SmzTableHeaderActionsComponent, selector: "smz-table-header-actions", inputs: ["col"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: UniqueFilterPipe, name: "uniqueFilter" }, { kind: "pipe", type: SmzTableContextPipe, name: "tableContext" }, { kind: "pipe", type: SmzFilterObjectPipe, name: "filterObject" }, { kind: "pipe", type: SmzCloneTableItemsPipe, name: "cloneTableItems" }, { kind: "pipe", type: SmzEditableSourcePipe, name: "editableSource" }, { kind: "pipe", type: SmzContentErrorsPipe, name: "contentErrors" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
22612
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzTableComponent, isStandalone: false, selector: "smz-ui-table", inputs: { state: "state", items: "items", loading: "loading" }, outputs: { selectionChange: "selectionChange", validChange: "validChange", filterChange: "filterChange", columnVisibilityChange: "columnVisibilityChange", create: "create", update: "update", delete: "delete" }, host: { properties: { "attr.data-testid": "this.hostTestId" } }, providers: [TableEditableService, TableFormsService], queries: [{ propertyName: "templates", predicate: SmzTemplateDirective }], viewQueries: [{ propertyName: "table", first: true, predicate: ["dt"], descendants: true }, { propertyName: "columnMultiselect", first: true, predicate: ["columnMultiselect"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "@if (state | tableContext; as context) {\r\n @if ((context.state.emptyFeedback != null && (context.state.emptyFeedback.extraInfo || context.state.emptyFeedback.image || context.state.emptyFeedback.actionButtons)) && (items != null && items.length === 0) && context.state.emptyFeedback.isFeatured) {\r\n <smz-data-info\r\n [attr.data-testid]=\"buildTableTestId('empty')\"\r\n [image]=\"context.state.emptyFeedback.image\"\r\n [message]=\"context.state.emptyFeedback.message\"\r\n [callbackInfo]=\"context.state.emptyFeedback.extraInfo\"\r\n [actions]=\"context.state.emptyFeedback.actionButtons\">\r\n <ng-template smzTemplate=\"actions\">\r\n <ng-container *ngTemplateOutlet=\"emptyActionsTemplate; context: { $implicit: {} }\"></ng-container>\r\n </ng-template>\r\n </smz-data-info>\r\n } @else {\r\n <ng-container *ngVar=\"state.source?.items$ != null ? (state.source.items$ | async) : null as observableSource\">\r\n <ng-container *ngVar=\"state.source?.signalItems != null ? state.source.signalItems() : null as signalSource\">\r\n @if (((observableSource ?? signalSource ?? items) | cloneTableItems : context: tableKey: context.state.rowExpansion.sincronize); as clonedData) {\r\n <p-table #dt\r\n dataKey=\"id\"\r\n editMode=\"row\"\r\n [stripedRows]=\"context.state.styles.striped\"\r\n [value]=\"clonedData.items\"\r\n [(selection)]=\"selectedItems\"\r\n [tableStyleClass]=\"context.state.styles.tableStyleClass\"\r\n [size]=\"context.state.styles.size === 'extra-small' ? 'small' : context.state.styles.size === 'small' ? 'small' : context.state.styles.size === 'large' ? 'large' : undefined\"\r\n [class]=\"'p-datatable-smz-ui-table' + (context.state.styles.showGrid ? ' p-datatable-gridlines' : '') + (context.state.styles.size === 'extra-small' ? ' p-datatable-xs' : '') + (context.state.styles.size === 'small' ? ' p-datatable-sm' : '') + (context.state.styles.size === 'large' ? ' p-datatable-lg' : '')\"\r\n [rowHover]=\"context.state.actions.rowBehavior.hoverable\"\r\n [rows]=\"context.state.pagination.rows\"\r\n [first]=\"context.state.pagination.state.first\"\r\n [showCurrentPageReport]=\"context.state.pagination.pageReport.isVisible\"\r\n [rowsPerPageOptions]=\"context.state.pagination.rowsPerPageOptions\"\r\n [loading]=\"loading || isViewportInitializing\"\r\n [style.visibility]=\"isViewportInitializing ? 'hidden' : null\"\r\n [paginator]=\"context.state.pagination.isVisible\"\r\n paginatorDropdownAppendTo=\"body\"\r\n [currentPageReportTemplate]=\"context.state.locale.paginator.template\"\r\n [sortField]=\"context.state.sort.field\"\r\n [sortMode]=\"context.state.sort.mode\"\r\n [sortOrder]=\"context.state.sort.order\"\r\n [multiSortMeta]=\"context.state.sort.multiSortMeta\"\r\n [scrollable]=\"context.state.viewport.scrollable\"\r\n [scrollHeight]=\"context.state.viewport.scrollHeight\"\r\n [filterDelay]=\"0\"\r\n [globalFilterFields]=\"context.globalFilter\"\r\n [columns]=\"context.visibleColumns\"\r\n [frozenColumns]=\"context.frozenColumns\"\r\n [frozenWidth]=\"context.state.frozen.isEnabled ? context.state.frozen.width : null\"\r\n [resizableColumns]=\"context.state.viewport.resizableColumns\"\r\n [columnResizeMode]=\"context.state.viewport.columnResizeMode\"\r\n (onPage)=\"onPage($event)\"\r\n (onFilter)=\"onFilter($event)\"\r\n (selectionChange)=\"emitSelection($event)\"\r\n >\r\n @if (context.state.caption.isVisible) {\r\n <ng-template smzTemplate=\"caption\">\r\n <div class=\"grid grid-nogutter items-center gap-2\" [attr.data-testid]=\"buildTableTestId('caption')\" [ngClass]=\"'justify-' + context.state.caption.toolbarAlignment\">\r\n @if (context.state.caption.title != null) {\r\n <div class=\"col database-title\" [attr.data-testid]=\"buildTableTestId('title')\" [innerHTML]=\"context.state.caption.title\"></div>\r\n }\r\n <ng-container *ngTemplateOutlet=\"captionTemplate; context: { $implicit: dt }\"></ng-container>\r\n <smz-table-caption-buttons [buttons]=\"context.state.caption.buttons\" [tableTestId]=\"state.tableTestId\"></smz-table-caption-buttons>\r\n @if (context.state.caption.exportToPdf.isButtonVisible) {\r\n <button smzButton [attr.data-testid]=\"buildTableTestId('export-pdf')\" [label]=\"context.state.locale.exportToPdf.label\" icon=\"fa-solid fa-file-pdf\" (click)=\"exportToPdf(context, clonedData.items)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\r\n }\r\n @if (context.state.caption.exportToExcel.isButtonVisible) {\r\n <button smzButton [attr.data-testid]=\"buildTableTestId('export-excel')\" [label]=\"context.state.locale.exportToExcel.label\" icon=\"fa-solid fa-file-excel\" (click)=\"exportToExcel(table, context, clonedData.items)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\r\n }\r\n @if (context.state.editable.creation.isButtonVisible) {\r\n <button smzButton [attr.data-testid]=\"buildTableTestId('create')\" [label]=\"context.state.editable.creation.buttonLabel\" icon=\"fa-solid fa-plus\" (click)=\"editableService.onRowCreateInit(table, context.columns)\" [disabled]=\"clonedData.showSkeleton || editableService.isEditing || editableService.isCreating || context.state.editable.creation.isButtonDisabled\" variant=\"outlined\"></button>\r\n }\r\n @if (context.state.caption.rowSelection.isButtonVisible) {\r\n <button smzButton [attr.data-testid]=\"buildTableTestId('row-selection')\" [label]=\"context.state.locale.rowSelection.label\" icon=\"fa-solid fa-check-double\" (click)=\"onRowSelection(context)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\r\n }\r\n @if (context.state.rowExpansion.isButtonVisible) {\r\n <button smzButton [attr.data-testid]=\"buildTableTestId('row-expansion')\" [label]=\"context.state.rowExpansion.label\" icon=\"fa-solid fa-list\" (click)=\"onRowExpansion(context)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\r\n }\r\n @if (context.state.caption.clearFilters.isButtonVisible) {\r\n <button smzButton [attr.data-testid]=\"buildTableTestId('clear-filters')\" [label]=\"context.state.locale.clearFilters.label\" icon=\"fa-solid fa-filter-circle-xmark\" (click)=\"clear(table, context)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\r\n }\r\n @if (context.state.caption.columnVisibility.showDropdownSelector) {\r\n <ui-multi-select #columnMultiselect [attr.data-testid]=\"buildTableTestId('column-visibility')\" class=\"ml-2 col-12 md:col-2\" styleClass=\"w-full\" appendTo=\"body\" [options]=\"context.hideableColumns\" [(ngModel)]=\"selectedColumns\" [placeholder]=\"context.state.locale.columnVisibility.placeholder\" [selectedItemsLabel]=\"context.state.locale.columnVisibility.selectedItemsLabel\" optionLabel=\"name\" dataKey=\"field\" optionLabel=\"header\" [filter]=\"true\" (panelHide)=\"updateColumnsVisibility(true)\" [smzTooltip]=\"context.state.locale.columnVisibility.pTooltip\">\r\n </ui-multi-select>\r\n }\r\n @if (context.state.caption.globalFilter.isVisible) {\r\n <ui-icon-field class=\"col-12\" [ngClass]=\"{ 'md:col-2': !context.state.caption.globalFilter.expanded }\">\r\n <ui-input-icon styleClass=\"fa-solid fa-magnifying-glass\"></ui-input-icon>\r\n <input #inputGlobal [(ngModel)]=\"globalSearchInput\" smzInputText type=\"text\" styleClass=\"database-global-search\" (input)=\"updateGlobalFilter(inputGlobal.value)\" [disabled]=\"clonedData.showSkeleton\" [placeholder]=\"context.state.locale.globalFilter.placeholder\" [attr.data-testid]=\"buildTableTestId('search')\" />\r\n </ui-icon-field>\r\n }\r\n </div>\r\n @if (toolbarTemplate != null) {\r\n <div class=\"grid grid-nogutter items-center mt-2\" [ngClass]=\"'justify-' + context.state.caption.toolbarAlignment\">\r\n <ng-container *ngTemplateOutlet=\"toolbarTemplate; context: { $implicit: dt }\"></ng-container>\r\n </div>\r\n }\r\n </ng-template>\r\n }\r\n <ng-template smzTemplate=\"header\" let-columns>\r\n <tr [ngClass]=\"{ 'invisible-header': !context.state.header.isVisible }\">\r\n @if (context.state.caption.rowSelection.isEnabled) {\r\n <th [ngStyle]=\"context.state.caption.rowSelection.ngStyle\">\r\n @if (!context.state.actions.batchActions.isVisible) {\r\n <p-tableHeaderCheckbox></p-tableHeaderCheckbox>\r\n }\r\n </th>\r\n }\r\n @if (context.state.rowExpansion.isEnabled) {\r\n <th [ngStyle]=\"context.state.rowExpansion.ngStyle\"></th>\r\n }\r\n @for (col of columns; track col.field) {\r\n @if (context.state.viewport.resizableColumns) {\r\n @if (col.isOrderable) {\r\n <th [pSortableColumn]=\"col.sortField\" pResizableColumn [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\r\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\r\n </th>\r\n }\r\n @if (!col.isOrderable) {\r\n <th pResizableColumn [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\r\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\r\n </th>\r\n }\r\n } @else {\r\n @if (col.isOrderable) {\r\n <th [pSortableColumn]=\"col.sortField\" [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\r\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\r\n </th>\r\n }\r\n @if (!col.isOrderable) {\r\n <th [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\r\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\r\n </th>\r\n }\r\n }\r\n <ng-template #headerContent>\r\n <div class=\"flex justify-start items-center\">\r\n <span class=\"mr-1\">{{ col.header }}</span>\r\n @if (col.showHeaderActions) {\r\n <smz-table-header-actions clickStopPropagation class=\"ml-1 mt-1\" [col]=\"col\"></smz-table-header-actions>\r\n }\r\n @if (!clonedData.showSkeleton && col.isOrderable) {\r\n <p-sortIcon [field]=\"col.sortField\"></p-sortIcon>\r\n }\r\n @if (!clonedData.showSkeleton) {\r\n @switch (col.filter.type) {\r\n @case (filterTypes.currency) {\r\n <smz-column-filter type=\"numeric\" currency=\"BRL\" [field]=\"col.filterField\"></smz-column-filter>\r\n }\r\n @case (filterTypes.numeric) {\r\n <smz-column-filter type=\"numeric\" [field]=\"col.filterField\"></smz-column-filter>\r\n }\r\n @case (filterTypes.date) {\r\n <smz-column-filter type=\"date\" [field]=\"col.filterField\" [showTime]=\"col.filter.showTime\"></smz-column-filter>\r\n }\r\n @case (filterTypes.text) {\r\n <smz-column-filter type=\"text\" [field]=\"col.filterField\"></smz-column-filter>\r\n }\r\n @case (filterTypes.boolean) {\r\n <smz-column-filter type=\"boolean\" [field]=\"col.filterField\"></smz-column-filter>\r\n }\r\n @case (filterTypes.dropdown) {\r\n @if (col.filterField | filterObject; as filterField) {\r\n <smz-column-filter [field]=\"filterField + '.id'\" matchMode=\"dropdown\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\r\n <ng-template smzTemplate=\"header\">\r\n <div class=\"px-3 pt-3 pb-0\">\r\n <span class=\"p-text-bold\">{{ col.header }}</span>\r\n </div>\r\n </ng-template>\r\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\r\n <ui-select appendTo=\"body\" [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField + '.id' : filterField : null : 'name' : false\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" optionLabel=\"name\" dataKey=\"id\"></ui-select>\r\n </ng-template>\r\n </smz-column-filter>\r\n }\r\n }\r\n @case (filterTypes.multiselect) {\r\n @if (col.filterField | filterObject; as filterField) {\r\n <smz-column-filter [field]=\"filterField\" matchMode=\"in\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\r\n <ng-template smzTemplate=\"header\">\r\n <div class=\"px-3 pt-3 pb-0\">\r\n <span class=\"p-text-bold\">{{ col.header }}</span>\r\n </div>\r\n </ng-template>\r\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\r\n <ui-multi-select [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField + '.id' : filterField : null : 'name' : false\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" optionLabel=\"name\" dataKey=\"id\"></ui-multi-select>\r\n </ng-template>\r\n </smz-column-filter>\r\n }\r\n }\r\n @case (filterTypes.multiselect_array) {\r\n @if (col.filterField | filterObject; as filterField) {\r\n <smz-column-filter [field]=\"filterField\" matchMode=\"array-some\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\r\n <ng-template smzTemplate=\"header\">\r\n <div class=\"px-3 pt-3 pb-0\">\r\n <span class=\"p-text-bold\">{{ col.header }}</span>\r\n </div>\r\n </ng-template>\r\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\r\n <ui-multi-select [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField + '.id' : filterField : null : 'name' : true\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" optionLabel=\"name\" dataKey=\"id\" [maxSelectedLabels]=\"2\" [selectedItemsLabel]=\"'{0}'\"></ui-multi-select>\r\n </ng-template>\r\n </smz-column-filter>\r\n }\r\n }\r\n @case (filterTypes.multiselect_string) {\r\n @if (col.filterField | filterObject; as filterField) {\r\n <smz-column-filter [field]=\"filterField\" matchMode=\"multiselectByString\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\r\n <ng-template smzTemplate=\"header\">\r\n <div class=\"px-3 pt-3 pb-0\">\r\n <span class=\"p-text-bold\">{{ col.header }}</span>\r\n </div>\r\n </ng-template>\r\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\r\n <ui-multi-select [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField : filterField : null : true : false : false\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" [maxSelectedLabels]=\"2\" [selectedItemsLabel]=\"'{0}'\"></ui-multi-select>\r\n </ng-template>\r\n </smz-column-filter>\r\n }\r\n }\r\n }\r\n }\r\n @if (context.state.caption.columnVisibility.showColumnHideButton) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-eye-slash\" (click)=\"hideColumn(col, context)\" [rounded]=\"true\" variant=\"text\" styleClass=\"p-button-plain\"></button>\r\n }\r\n </div>\r\n </ng-template>\r\n }\r\n @if (context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible|| context.state.editable.isEditable) {\r\n <th [ngStyle]=\"context.state.editable.isEditable ? context.state.editable.ngStyle : context.state.actions.customActions.ngStyle\"></th>\r\n }\r\n </tr>\r\n @if (context.state.actions.batchActions.isVisible) {\r\n <tr>\r\n <th [attr.colspan]=\"columns.length + ((context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) ? 1 : 0) + (context.state.caption.rowSelection.isEnabled ? 1 : 0) + (context.state.rowExpansion.isEnabled ? 1 : 0)\"\r\n [ngStyle]=\"context.state.actions.customActions.ngStyle\" class=\"px-0\">\r\n <div class=\"grid grid-nogutter items-center justify-start\">\r\n <p-tableHeaderCheckbox class=\"mr-4\"></p-tableHeaderCheckbox>\r\n @if (selectedItems?.length > 0) {\r\n @for (batchItem of context.state.actions.batchActions.items; track batchItem.label) {\r\n @if (batchItem.visible) {\r\n <button smzButton [label]=\"batchItem.label\" class=\"animate__animated animate__fadeIn\" [styleClass]=\"'p-button-plain ' + (batchItem.styleClass)\" [icon]=\"batchItem.icon\" (click)=\"batchItem.command(selectedItems); selectedItems = [];\" [disabled]=\"batchItem.disabled\" [smzTooltip]=\"batchItem.tooltip\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n }\r\n }\r\n </div>\r\n </th>\r\n </tr>\r\n }\r\n </ng-template>\r\n <ng-template smzTemplate=\"body\" let-item let-editing=\"editing\" let-rowIndex=\"rowIndex\" let-columns=\"columns\">\r\n <tr #editableRowElement\r\n [pEditableRow]=\"item\"\r\n tableItemAction\r\n [isClickable]=\"context.state.actions.rowBehavior.isClickable\"\r\n [callback]=\"context.state.actions.rowBehavior.clickCallback\"\r\n [expandRowOnClick]=\"context.state.actions.rowBehavior.expandRowOnClick\"\r\n [item]=\"item\"\r\n class=\"p-selectable-row\"\r\n [attr.data-testid]=\"buildRowTestId(item, rowIndex)\"\r\n [ngClass]=\"{ 'highlight-row': item?.id === state.actions.rowBehavior.highlights, 'preserve-in-small': state.actions.rowBehavior.preserveLayoutInSmallDevices }\"\r\n >\r\n @if (context.state.caption.rowSelection.isEnabled && !clonedData.showSkeleton) {\r\n <td\r\n clickStopPropagation\r\n class=\"{{ state.actions.rowBehavior.cellStyleClass }}\"\r\n [ngClass]=\"{ 'opacity-50 pointer-events-none': editableService.context[item.id]?.hasErrors || editableService.context[item.id]?.isLoading }\"\r\n [ngStyle]=\"context.state.caption.rowSelection.ngStyle\"\r\n >\r\n <p-tableCheckbox [value]=\"item\"></p-tableCheckbox>\r\n </td>\r\n }\r\n @if (context.state.rowExpansion.isEnabled && !clonedData.showSkeleton) {\r\n <td\r\n clickStopPropagation\r\n class=\"{{ state.actions.rowBehavior.cellStyleClass }}\"\r\n [ngClass]=\"{ 'opacity-50 pointer-events-none': editableService.context[item.id]?.hasErrors || editableService.context[item.id]?.isLoading, 'grid grid-nogutter justify-start items-center gap-2': context.state.rowExpansion.highlightNewItems && item._isNew }\"\r\n [ngStyle]=\"context.state.rowExpansion.ngStyle\"\r\n >\r\n <button smzButton type=\"button\" class=\"smz-table-row-expansion-toggle\" [icon]=\"item._isExpanded ? 'fa-solid fa-chevron-down' : 'fa-solid fa-chevron-right'\" (click)=\"item._isExpanded = !item._isExpanded; item._isNew = false\" variant=\"text\" [rounded]=\"true\" size=\"sm\"></button>\r\n @if (context.state.rowExpansion.highlightNewItems && item._isNew) {\r\n <div class=\"rounded bg-cyan-400 text-sm text-white px-2 py-0 smz-table-new-tag\" (click)=\"item._isNew = false\">{{ context.state.rowExpansion.highlightLabel }}</div>\r\n }\r\n </td>\r\n }\r\n @for (col of columns; track col.field) {\r\n @if (clonedData.showSkeleton) {\r\n <td class=\"{{ state.actions.rowBehavior.cellStyleClass }}\" [ngStyle]=\"col.content.ngStyle\"><ui-skeleton width=\"100%\" height=\"1rem\"></ui-skeleton></td>\r\n } @else {\r\n <td class=\"{{ state.actions.rowBehavior.cellStyleClass }}\" [attr.data-testid]=\"buildCellTestId(item, rowIndex, col.field)\" [ngClass]=\"{ 'opacity-50 pointer-events-none': editableService.context[item.id]?.hasErrors || editableService.context[item.id]?.isLoading }\" [ngStyle]=\"col.content.ngStyle\">\r\n <span class=\"p-column-title\">{{ col.header }}</span>\r\n <p-cellEditor>\r\n <!-- CELULAR COM EDITOR -->\r\n <ng-template smzTemplate=\"input\">\r\n @switch (col.editable.type) {\r\n @case (editableTypes.none) {\r\n <smz-table-content class=\"cursor-default\" [ngClass]=\"col.content.contentStyleClass\" [col]=\"col\" [contentTypes]=\"contentTypes\" [item]=\"item\" [rowIndex]=\"rowIndex\" [contentTemplate]=\"contentTemplate\"></smz-table-content>\r\n }\r\n @case (editableTypes.custom) {\r\n <ng-container *ngTemplateOutlet=\"editableTemplate; context: { $implicit: item, col: col }\"></ng-container>\r\n }\r\n <!-- INPUT TEXT -->\r\n @case (editableTypes.text) {\r\n @if (editableService.context[item.id]?.form; as form) {\r\n @if (form.controls[col.editable.property]; as control) {\r\n <div class=\"relative w-full\">\r\n <input smzInputText type=\"text\" [formControl]=\"$any(control)\" style=\"width: 100%;\">\r\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\r\n </div>\r\n }\r\n }\r\n }\r\n <!-- INPUT NUMBER -->\r\n @case (editableTypes.number) {\r\n @if (editableService.context[item.id]?.form; as form) {\r\n @if (form.controls[col.editable.property]; as control) {\r\n <div class=\"relative w-full\">\r\n <ui-input-number *ngVar=\"col.editable.data as numberData\" [formControl]=\"$any(control)\" [mode]=\"numberData.mode\" [minFractionDigits]=\"numberData.minFractionDigits\" [maxFractionDigits]=\"numberData.maxFractionDigits\" [currency]=\"numberData.currency\" [useGrouping]=\"numberData.useGrouping\" [allowEmpty]=\"numberData.allowEmpty\" [showClear]=\"numberData.showClear\" [showButtons]=\"numberData.showButtons\" [prefix]=\"numberData.prefix\" [suffix]=\"numberData.suffix\">\r\n </ui-input-number>\r\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\r\n </div>\r\n }\r\n }\r\n }\r\n <!-- INPUT SWITCH -->\r\n @case (editableTypes.switch) {\r\n @if (editableService.context[item.id]?.form; as form) {\r\n @if (form.controls[col.editable.property]; as control) {\r\n <div class=\"relative w-full\">\r\n <ui-toggle-switch [formControl]=\"$any(control)\"></ui-toggle-switch>\r\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\r\n </div>\r\n }\r\n }\r\n }\r\n <!-- INPUT TEXT AREA -->\r\n @case (editableTypes.area) {\r\n @if (editableService.context[item.id]?.form; as form) {\r\n @if (form.controls[col.editable.property]; as control) {\r\n <div class=\"relative w-full\">\r\n <textarea smzTextarea type=\"text\" [formControl]=\"$any(control)\" [rows]=\"$any(col.editable.data).rows\" required style=\"width: 100%;\"></textarea>\r\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\r\n </div>\r\n }\r\n }\r\n }\r\n <!-- INPUT DROPDOWN -->\r\n @case (editableTypes.dropdown) {\r\n @if (editableService.context[item.id]?.form; as form) {\r\n @if (form.controls[col.editable.property]; as control) {\r\n <div class=\"relative w-full\">\r\n <ui-select appendTo=\"body\" [formControl]=\"$any(control)\" styleClass=\"w-full\" [options]=\"col.editable.data | editableSource\" optionLabel=\"name\" dataKey=\"id\" [placeholder]=\"$any(col.editable.data).placeholder\" [showClear]=\"!col.editable.validatorsPreset?.isRequired\" [filter]=\"true\"></ui-select>\r\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\r\n </div>\r\n }\r\n }\r\n }\r\n <!-- INPUT CALENDAR -->\r\n @case (editableTypes.calendar) {\r\n @if (editableService.context[item.id]?.form; as form) {\r\n @if (form.controls[col.editable.property]; as control) {\r\n <div class=\"relative w-full\">\r\n <ui-date-picker [formControl]=\"$any(control)\" appendTo=\"body\" styleClass=\"w-full\" [ngClass]=\"{ 'pl-5': !control.valid }\"></ui-date-picker>\r\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\r\n </div>\r\n }\r\n }\r\n }\r\n }\r\n </ng-template>\r\n <!-- CELULAR COM CONTE\u00DADO -->\r\n <ng-template smzTemplate=\"output\">\r\n <smz-table-content\r\n [col]=\"col\"\r\n [smzTooltip]=\"col.content.tooltip != null ? col.content.tooltip(item) : null\"\r\n tooltipPosition=\"left\"\r\n [ngClass]=\"col.content.contentStyleClass\" [contentTypes]=\"contentTypes\" [item]=\"item\" [rowIndex]=\"rowIndex\" [contentTemplate]=\"contentTemplate\">\r\n </smz-table-content>\r\n </ng-template>\r\n </p-cellEditor>\r\n </td>\r\n }\r\n }\r\n @if (context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) {\r\n <td [ngStyle]=\"context.state.actions.customActions.ngStyle\" class=\"px-0\">\r\n <div class=\"grid grid-nogutter items-center justify-center\">\r\n @if (clonedData.showSkeleton) {\r\n <div class=\"w-full\">\r\n <ui-skeleton width=\"100%\" height=\"1rem\"></ui-skeleton>\r\n </div>\r\n } @else {\r\n <!-- SEM EDITAR -->\r\n @if (!editing) {\r\n @if (context.state.editable.update.isButtonVisible) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-pencil\" (click)=\"editableService.onRowEditInit(item)\" class=\"mx-1\" [disabled]=\"editableService.isEditing || editableService.isCreating || context.state.editable.update.isButtonDisabled || (!context.state.editable.update.condition(item))\" pInitEditableRow [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (context.state.editable.remove.isButtonVisible) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-trash\" (click)=\"editableService.onRowRemove($event, table, item)\" class=\"mx-1\" [disabled]=\"editableService.isEditing || editableService.isCreating || context.state.editable.remove.isButtonDisabled || (!context.state.editable.remove.condition(item))\" [rounded]=\"true\" variant=\"text\" severity=\"secondary\"></button>\r\n }\r\n }\r\n <!-- EDITANDO -->\r\n @if (editing) {\r\n @if (editableService.context[item.id]; as editableContext) {\r\n <!-- COM LOADING -->\r\n @if (editableContext.isLoading) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-rotate fa-spin\" [disabled]=\"true\" class=\"mr-2\" [rounded]=\"true\" variant=\"text\" styleClass=\"p-button-info\"></button>\r\n }\r\n <!-- SEM LOADING -->\r\n @if (!editableContext.isLoading) {\r\n <!-- EDITANDO -->\r\n @if (!editableContext.hasErrors) {\r\n <!-- CRIANDO -->\r\n @if (item._context?.isCreating) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-check\" (click)=\"editableService.onRowCreateSave($event, table, editableRowElement, item)\" [disabled]=\"!editableContext.hasChanged || !editableService.context[item.id]?.form.valid\" class=\"mr-2\" [rounded]=\"true\" variant=\"text\" severity=\"success\"></button>\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowCreateCancel($event, table, item)\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\r\n }\r\n <!-- ATUALIZANDO -->\r\n @if (item._context?.isUpdating) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-check\" (click)=\"editableService.onRowEditSave($event, table, editableRowElement, item)\" [disabled]=\"!editableContext.hasChanged || !editableService.context[item.id]?.form.valid\" class=\"mr-2\" [rounded]=\"true\" variant=\"text\" severity=\"success\"></button>\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowEditCancel($event, table, item)\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\r\n }\r\n }\r\n <!-- COM ERRORS -->\r\n @if (editableContext.hasErrors) {\r\n <ui-popover #errorsOverlay appendTo=\"body\" [style]=\"{ width: '450px' }\">\r\n <div [innerHtml]=\"editableContext.errors | contentErrors\"></div>\r\n </ui-popover>\r\n <button smzButton type=\"button\" icon=\"fas fa-exclamation-triangle\" [disabled]=\"false\" class=\"mr-2\" (click)=\"errorsOverlay.toggle($event)\" size=\"sm\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\r\n <!-- CRIANDO -->\r\n @if (item._context?.isCreating) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowCreateCancel($event, table, item)\" size=\"sm\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\r\n }\r\n <!-- ATUALIZANDO -->\r\n @if (item._context?.isUpdating) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowEditCancel($event, table, item)\" size=\"sm\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\r\n }\r\n }\r\n }\r\n }\r\n }\r\n <!-- CUSTOM MENU -->\r\n @if (context.state.actions.customActions.isVisible && !editing) {\r\n <ng-container *ngTemplateOutlet=\"actionsTemplate; context: { $implicit: item }\"></ng-container>\r\n }\r\n <!-- MENU -->\r\n @if (context.state.actions.menu.isVisible && !editing) {\r\n <smz-menu [callback]=\"context.state.actions.menu.callback\" [items]=\"context.state.actions.menu.items\" [data]=\"item\" [behavior]=\"context.state.actions.menu.behavior\" [ngClass]=\"{ 'ml-2': context.state.actions.customActions.isVisible }\" [icon]=\"context.state.actions.menu.styles.icon\" [styleClass]=\"context.state.actions.menu.styles.styleClass\" [buttonClass]=\"context.state.actions.menu.styles.buttonClass\" [testId]=\"buildRowMenuTestId(item, rowIndex)\"></smz-menu>\r\n }\r\n }\r\n </div>\r\n </td>\r\n }\r\n </tr>\r\n @if (item?._isExpanded) {\r\n <tr>\r\n <td [attr.colspan]=\"columns.length + ((context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) ? 1 : 0) + (context.state.caption.rowSelection.isEnabled ? 1 : 0) + (context.state.rowExpansion.isEnabled ? 1 : 0)\">\r\n <ng-container *ngTemplateOutlet=\"rowContentTemplate; context: { $implicit: item }\"></ng-container>\r\n </td>\r\n </tr>\r\n }\r\n </ng-template>\r\n <ng-template smzTemplate=\"emptymessage\" let-columns>\r\n <tr>\r\n <td [attr.colspan]=\"columns.length + ((context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) ? 1 : 0) + (context.state.caption.rowSelection.isEnabled ? 1 : 0) + (context.state.rowExpansion.isEnabled ? 1 : 0)\" [ngStyle]=\"{ 'text-align': 'center' }\">\r\n <div [innerHtml]=\"context.state.emptyFeedback.message\"></div>\r\n @if (context.state.caption.clearFilters.isButtonVisible && hasFilters()) {\r\n <button smzButton [label]=\"context.state.locale.clearFilters.label\" class=\"mt-3\" icon=\"fa-solid fa-filter-circle-xmark\" (click)=\"clear(table, context)\" variant=\"outlined\"></button>\r\n }\r\n </td>\r\n </tr>\r\n </ng-template>\r\n </p-table>\r\n }\r\n </ng-container>\r\n </ng-container>\r\n }\r\n} @else {\r\n @if (emptyStateTemplate != null) {\r\n <ng-container *ngTemplateOutlet=\"emptyStateTemplate; context: { $implicit: {} }\"></ng-container>\r\n }\r\n}\r\n\r\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "stripedRows", "size", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "virtualRowHeight", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll"], outputs: ["selectAllChange", "selectionChange", "contextMenuSelectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "directive", type: ResizableColumn, selector: "[pResizableColumn]", inputs: ["pResizableColumnDisabled"] }, { kind: "component", type: CellEditor, selector: "p-cellEditor" }, { kind: "component", type: SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: TableCheckbox, selector: "p-tableCheckbox", inputs: ["disabled", "value", "index", "inputId", "name", "required", "ariaLabel"] }, { kind: "component", type: TableHeaderCheckbox, selector: "p-tableHeaderCheckbox", inputs: ["disabled", "inputId", "name", "ariaLabel"] }, { kind: "directive", type: EditableRow, selector: "[pEditableRow]", inputs: ["pEditableRow", "pEditableRowDisabled"] }, { kind: "directive", type: InitEditableRow, selector: "[pInitEditableRow]" }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "directive", type: i2.SmzInputTextDirective, selector: "input[smzInputText]", inputs: ["size", "invalid"] }, { kind: "component", type: i2.SmzMultiSelectComponent, selector: "ui-multi-select", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "placeholder", "filter", "filterBy", "filterMatchMode", "filterPlaceholder", "showClear", "showToggleAll", "emptyMessage", "emptyFilterMessage", "maxSelectedLabels", "selectedItemsLabel", "panelStyle", "styleClass", "inputId", "autofocusFilter", "appendTo", "display"], outputs: ["changed", "panelHide", "panelShow"] }, { kind: "component", type: i2.SmzSelectComponent, selector: "ui-select", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "placeholder", "filter", "filterBy", "filterMatchMode", "filterPlaceholder", "showClear", "emptyMessage", "emptyFilterMessage", "styleClass", "inputId", "ariaLabel", "appendTo"], outputs: ["changed", "showed", "hidden"] }, { kind: "component", type: i2.SmzDatePickerComponent, selector: "ui-date-picker", inputs: ["selectionMode", "dateFormat", "showTime", "timeOnly", "showSeconds", "hourFormat", "minDate", "maxDate", "showButtonBar", "showIcon", "showOnFocus", "keepInvalid", "readonlyInput", "placeholder", "inputId", "styleClass", "appendTo", "touchUI", "focusTrap"], outputs: ["selected", "cleared", "opened", "closed", "blurred"] }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: TableItemActionsDirective, selector: "[tableItemAction]", inputs: ["isClickable", "item", "callback", "expandRowOnClick"] }, { kind: "directive", type: ClickStopPropagationDirective, selector: "[clickStopPropagation]" }, { kind: "component", type: SmzDataInfoComponent, selector: "smz-data-info", inputs: ["image", "message", "actions", "callbackInfo", "callbackLabel"], outputs: ["clicked"] }, { kind: "directive", type: i2.SmzTooltipDirective, selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "component", type: i2.SmzSkeletonComponent, selector: "ui-skeleton", inputs: ["shape", "width", "height"] }, { kind: "directive", type: i2.SmzTextareaDirective, selector: "textarea[smzTextarea]", inputs: ["invalid", "autoResize"] }, { kind: "component", type: i2.SmzPopoverComponent, selector: "ui-popover", inputs: ["style", "styleClass", "dismissable", "autoZIndex", "appendTo"], outputs: ["shown", "hidden"] }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i2.SmzToggleSwitchComponent, selector: "ui-toggle-switch", inputs: ["name"], outputs: ["changed"] }, { kind: "component", type: i2.SmzInputNumberComponent, selector: "ui-input-number", inputs: ["mode", "locale", "localeMatcher", "currency", "currencyDisplay", "useGrouping", "minFractionDigits", "maxFractionDigits", "min", "max", "step", "prefix", "suffix", "showButtons", "showClear", "allowEmpty", "placeholder", "readonly", "inputId", "name"], outputs: ["inputed", "keyDown", "blurred", "focused"] }, { kind: "component", type: SmzMenuComponent, selector: "smz-menu", inputs: ["items", "callback", "data", "buttonClass", "styleClass", "icon", "behavior", "testId"] }, { kind: "directive", type: NgVar, selector: "[ngVar]", inputs: ["ngVar"] }, { kind: "component", type: i2.SmzIconFieldComponent, selector: "ui-icon-field" }, { kind: "component", type: i2.SmzInputIconComponent, selector: "ui-input-icon", inputs: ["styleClass"] }, { kind: "component", type: SmzColumnFilterComponent, selector: "smz-column-filter", inputs: ["currency", "display", "field", "matchMode", "showAddButton", "showMatchModes", "showOperator", "showApplyButton", "type", "showTime"] }, { kind: "component", type: SmzTableValidationMessagesComponent, selector: "smz-table-validation-messages", inputs: ["errors", "messages", "isFormInvalid", "isFormDirty"] }, { kind: "component", type: SmzTableContentComponent, selector: "smz-table-content", inputs: ["col", "contentTypes", "item", "rowIndex", "contentTemplate"] }, { kind: "component", type: SmzTableCaptionButtonsComponent, selector: "smz-table-caption-buttons", inputs: ["buttons", "tableTestId"] }, { kind: "component", type: SmzTableHeaderActionsComponent, selector: "smz-table-header-actions", inputs: ["col"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: UniqueFilterPipe, name: "uniqueFilter" }, { kind: "pipe", type: SmzTableContextPipe, name: "tableContext" }, { kind: "pipe", type: SmzFilterObjectPipe, name: "filterObject" }, { kind: "pipe", type: SmzCloneTableItemsPipe, name: "cloneTableItems" }, { kind: "pipe", type: SmzEditableSourcePipe, name: "editableSource" }, { kind: "pipe", type: SmzContentErrorsPipe, name: "contentErrors" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
22563
22613
|
}
|
|
22564
22614
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzTableComponent, decorators: [{
|
|
22565
22615
|
type: Component,
|
|
22566
|
-
args: [{ selector: 'smz-ui-table', changeDetection: ChangeDetectionStrategy.OnPush, providers: [TableEditableService, TableFormsService], standalone: false, template: "@if (state | tableContext; as context) {\n @if ((context.state.emptyFeedback != null && (context.state.emptyFeedback.extraInfo || context.state.emptyFeedback.image || context.state.emptyFeedback.actionButtons)) && (items != null && items.length === 0) && context.state.emptyFeedback.isFeatured) {\n <smz-data-info\n [attr.data-testid]=\"buildTableTestId('empty')\"\n [image]=\"context.state.emptyFeedback.image\"\n [message]=\"context.state.emptyFeedback.message\"\n [callbackInfo]=\"context.state.emptyFeedback.extraInfo\"\n [actions]=\"context.state.emptyFeedback.actionButtons\">\n <ng-template smzTemplate=\"actions\">\n <ng-container *ngTemplateOutlet=\"emptyActionsTemplate; context: { $implicit: {} }\"></ng-container>\n </ng-template>\n </smz-data-info>\n } @else {\n <ng-container *ngVar=\"state.source?.items$ != null ? (state.source.items$ | async) : null as observableSource\">\n <ng-container *ngVar=\"state.source?.signalItems != null ? state.source.signalItems() : null as signalSource\">\n @if (((observableSource ?? signalSource ?? items) | cloneTableItems : context: tableKey: context.state.rowExpansion.sincronize); as clonedData) {\n <p-table #dt\n dataKey=\"id\"\n editMode=\"row\"\n [stripedRows]=\"context.state.styles.striped\"\n [value]=\"clonedData.items\"\n [(selection)]=\"selectedItems\"\n [tableStyleClass]=\"context.state.styles.tableStyleClass\"\n [size]=\"context.state.styles.size === 'extra-small' ? 'small' : context.state.styles.size === 'small' ? 'small' : context.state.styles.size === 'large' ? 'large' : undefined\"\n [class]=\"'p-datatable-smz-ui-table' + (context.state.styles.showGrid ? ' p-datatable-gridlines' : '') + (context.state.styles.size === 'extra-small' ? ' p-datatable-xs' : '') + (context.state.styles.size === 'small' ? ' p-datatable-sm' : '') + (context.state.styles.size === 'large' ? ' p-datatable-lg' : '')\"\n [rowHover]=\"context.state.actions.rowBehavior.hoverable\"\n [rows]=\"context.state.pagination.rows\"\n [first]=\"context.state.pagination.state.first\"\n [showCurrentPageReport]=\"context.state.pagination.pageReport.isVisible\"\n [rowsPerPageOptions]=\"context.state.pagination.rowsPerPageOptions\"\n [loading]=\"loading || isViewportInitializing\"\n [style.visibility]=\"isViewportInitializing ? 'hidden' : null\"\n [paginator]=\"context.state.pagination.isVisible\"\n paginatorDropdownAppendTo=\"body\"\n [currentPageReportTemplate]=\"context.state.locale.paginator.template\"\n [sortField]=\"context.state.sort.field\"\n [sortMode]=\"context.state.sort.mode\"\n [sortOrder]=\"context.state.sort.order\"\n [multiSortMeta]=\"context.state.sort.multiSortMeta\"\n [scrollable]=\"context.state.viewport.scrollable\"\n [scrollHeight]=\"context.state.viewport.scrollHeight\"\n [filterDelay]=\"0\"\n [globalFilterFields]=\"context.globalFilter\"\n [columns]=\"context.visibleColumns\"\n [frozenColumns]=\"context.frozenColumns\"\n [frozenWidth]=\"context.state.frozen.isEnabled ? context.state.frozen.width : null\"\n [resizableColumns]=\"context.state.viewport.resizableColumns\"\n [columnResizeMode]=\"context.state.viewport.columnResizeMode\"\n (onPage)=\"onPage($event)\"\n (onFilter)=\"onFilter($event)\"\n (selectionChange)=\"emitSelection($event)\"\n >\n @if (context.state.caption.isVisible) {\n <ng-template smzTemplate=\"caption\">\n <div class=\"grid grid-nogutter items-center gap-2\" [attr.data-testid]=\"buildTableTestId('caption')\" [ngClass]=\"'justify-' + context.state.caption.toolbarAlignment\">\n @if (context.state.caption.title != null) {\n <div class=\"col database-title\" [attr.data-testid]=\"buildTableTestId('title')\" [innerHTML]=\"context.state.caption.title\"></div>\n }\n <ng-container *ngTemplateOutlet=\"captionTemplate; context: { $implicit: dt }\"></ng-container>\n <smz-table-caption-buttons [buttons]=\"context.state.caption.buttons\" [tableTestId]=\"state.tableTestId\"></smz-table-caption-buttons>\n @if (context.state.caption.exportToPdf.isButtonVisible) {\n <button smzButton [attr.data-testid]=\"buildTableTestId('export-pdf')\" [label]=\"context.state.locale.exportToPdf.label\" icon=\"fa-solid fa-file-pdf\" (click)=\"exportToPdf(context, clonedData.items)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\n }\n @if (context.state.caption.exportToExcel.isButtonVisible) {\n <button smzButton [attr.data-testid]=\"buildTableTestId('export-excel')\" [label]=\"context.state.locale.exportToExcel.label\" icon=\"fa-solid fa-file-excel\" (click)=\"exportToExcel(table, context, clonedData.items)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\n }\n @if (context.state.editable.creation.isButtonVisible) {\n <button smzButton [attr.data-testid]=\"buildTableTestId('create')\" [label]=\"context.state.editable.creation.buttonLabel\" icon=\"fa-solid fa-plus\" (click)=\"editableService.onRowCreateInit(table, context.columns)\" [disabled]=\"clonedData.showSkeleton || editableService.isEditing || editableService.isCreating || context.state.editable.creation.isButtonDisabled\" variant=\"outlined\"></button>\n }\n @if (context.state.caption.rowSelection.isButtonVisible) {\n <button smzButton [attr.data-testid]=\"buildTableTestId('row-selection')\" [label]=\"context.state.locale.rowSelection.label\" icon=\"fa-solid fa-check-double\" (click)=\"onRowSelection(context)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\n }\n @if (context.state.rowExpansion.isButtonVisible) {\n <button smzButton [attr.data-testid]=\"buildTableTestId('row-expansion')\" [label]=\"context.state.rowExpansion.label\" icon=\"fa-solid fa-list\" (click)=\"onRowExpansion(context)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\n }\n @if (context.state.caption.clearFilters.isButtonVisible) {\n <button smzButton [attr.data-testid]=\"buildTableTestId('clear-filters')\" [label]=\"context.state.locale.clearFilters.label\" icon=\"fa-solid fa-filter-circle-xmark\" (click)=\"clear(table, context)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\n }\n @if (context.state.caption.columnVisibility.showDropdownSelector) {\n <ui-multi-select #columnMultiselect [attr.data-testid]=\"buildTableTestId('column-visibility')\" class=\"ml-2 col-12 md:col-2\" styleClass=\"w-full\" appendTo=\"body\" [options]=\"context.hideableColumns\" [(ngModel)]=\"selectedColumns\" [placeholder]=\"context.state.locale.columnVisibility.placeholder\" [selectedItemsLabel]=\"context.state.locale.columnVisibility.selectedItemsLabel\" optionLabel=\"name\" dataKey=\"field\" optionLabel=\"header\" [filter]=\"true\" (panelHide)=\"updateColumnsVisibility(true)\" [smzTooltip]=\"context.state.locale.columnVisibility.pTooltip\">\n </ui-multi-select>\n }\n @if (context.state.caption.globalFilter.isVisible) {\n <ui-icon-field class=\"col-12\" [ngClass]=\"{ 'md:col-2': !context.state.caption.globalFilter.expanded }\">\n <ui-input-icon styleClass=\"fa-solid fa-magnifying-glass\"></ui-input-icon>\n <input #inputGlobal [(ngModel)]=\"globalSearchInput\" smzInputText type=\"text\" styleClass=\"database-global-search\" (input)=\"updateGlobalFilter(inputGlobal.value)\" [disabled]=\"clonedData.showSkeleton\" [placeholder]=\"context.state.locale.globalFilter.placeholder\" [attr.data-testid]=\"buildTableTestId('search')\" />\n </ui-icon-field>\n }\n </div>\n @if (toolbarTemplate != null) {\n <div class=\"grid grid-nogutter items-center mt-2\" [ngClass]=\"'justify-' + context.state.caption.toolbarAlignment\">\n <ng-container *ngTemplateOutlet=\"toolbarTemplate; context: { $implicit: dt }\"></ng-container>\n </div>\n }\n </ng-template>\n }\n <ng-template smzTemplate=\"header\" let-columns>\n <tr [ngClass]=\"{ 'invisible-header': !context.state.header.isVisible }\">\n @if (context.state.caption.rowSelection.isEnabled) {\n <th [ngStyle]=\"context.state.caption.rowSelection.ngStyle\">\n @if (!context.state.actions.batchActions.isVisible) {\n <p-tableHeaderCheckbox></p-tableHeaderCheckbox>\n }\n </th>\n }\n @if (context.state.rowExpansion.isEnabled) {\n <th [ngStyle]=\"context.state.rowExpansion.ngStyle\"></th>\n }\n @for (col of columns; track col.field) {\n @if (context.state.viewport.resizableColumns) {\n @if (col.isOrderable) {\n <th [pSortableColumn]=\"col.sortField\" pResizableColumn [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\n </th>\n }\n @if (!col.isOrderable) {\n <th pResizableColumn [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\n </th>\n }\n } @else {\n @if (col.isOrderable) {\n <th [pSortableColumn]=\"col.sortField\" [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\n </th>\n }\n @if (!col.isOrderable) {\n <th [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\n </th>\n }\n }\n <ng-template #headerContent>\n <div class=\"flex justify-start items-center\">\n <span class=\"mr-1\">{{ col.header }}</span>\n @if (col.showHeaderActions) {\n <smz-table-header-actions clickStopPropagation class=\"ml-1 mt-1\" [col]=\"col\"></smz-table-header-actions>\n }\n @if (!clonedData.showSkeleton && col.isOrderable) {\n <p-sortIcon [field]=\"col.sortField\"></p-sortIcon>\n }\n @if (!clonedData.showSkeleton) {\n @switch (col.filter.type) {\n @case (filterTypes.currency) {\n <smz-column-filter type=\"numeric\" currency=\"BRL\" [field]=\"col.filterField\"></smz-column-filter>\n }\n @case (filterTypes.numeric) {\n <smz-column-filter type=\"numeric\" [field]=\"col.filterField\"></smz-column-filter>\n }\n @case (filterTypes.date) {\n <smz-column-filter type=\"date\" [field]=\"col.filterField\" [showTime]=\"col.filter.showTime\"></smz-column-filter>\n }\n @case (filterTypes.text) {\n <smz-column-filter type=\"text\" [field]=\"col.filterField\"></smz-column-filter>\n }\n @case (filterTypes.boolean) {\n <smz-column-filter type=\"boolean\" [field]=\"col.filterField\"></smz-column-filter>\n }\n @case (filterTypes.dropdown) {\n @if (col.filterField | filterObject; as filterField) {\n <smz-column-filter [field]=\"filterField + '.id'\" matchMode=\"dropdown\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\n <ng-template smzTemplate=\"header\">\n <div class=\"px-3 pt-3 pb-0\">\n <span class=\"p-text-bold\">{{ col.header }}</span>\n </div>\n </ng-template>\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\n <ui-select appendTo=\"body\" [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField + '.id' : filterField : null : 'name' : false\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" optionLabel=\"name\" dataKey=\"id\"></ui-select>\n </ng-template>\n </smz-column-filter>\n }\n }\n @case (filterTypes.multiselect) {\n @if (col.filterField | filterObject; as filterField) {\n <smz-column-filter [field]=\"filterField\" matchMode=\"in\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\n <ng-template smzTemplate=\"header\">\n <div class=\"px-3 pt-3 pb-0\">\n <span class=\"p-text-bold\">{{ col.header }}</span>\n </div>\n </ng-template>\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\n <ui-multi-select [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField + '.id' : filterField : null : 'name' : false\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" optionLabel=\"name\" dataKey=\"id\"></ui-multi-select>\n </ng-template>\n </smz-column-filter>\n }\n }\n @case (filterTypes.multiselect_array) {\n @if (col.filterField | filterObject; as filterField) {\n <smz-column-filter [field]=\"filterField\" matchMode=\"array-some\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\n <ng-template smzTemplate=\"header\">\n <div class=\"px-3 pt-3 pb-0\">\n <span class=\"p-text-bold\">{{ col.header }}</span>\n </div>\n </ng-template>\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\n <ui-multi-select [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField + '.id' : filterField : null : 'name' : true\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" optionLabel=\"name\" dataKey=\"id\" [maxSelectedLabels]=\"2\" [selectedItemsLabel]=\"'{0}'\"></ui-multi-select>\n </ng-template>\n </smz-column-filter>\n }\n }\n @case (filterTypes.multiselect_string) {\n @if (col.filterField | filterObject; as filterField) {\n <smz-column-filter [field]=\"filterField\" matchMode=\"multiselectByString\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\n <ng-template smzTemplate=\"header\">\n <div class=\"px-3 pt-3 pb-0\">\n <span class=\"p-text-bold\">{{ col.header }}</span>\n </div>\n </ng-template>\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\n <ui-multi-select [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField : filterField : null : true : false : false\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" [maxSelectedLabels]=\"2\" [selectedItemsLabel]=\"'{0}'\"></ui-multi-select>\n </ng-template>\n </smz-column-filter>\n }\n }\n }\n }\n @if (context.state.caption.columnVisibility.showColumnHideButton) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-eye-slash\" (click)=\"hideColumn(col, context)\" [rounded]=\"true\" variant=\"text\" styleClass=\"p-button-plain\"></button>\n }\n </div>\n </ng-template>\n }\n @if (context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible|| context.state.editable.isEditable) {\n <th [ngStyle]=\"context.state.editable.isEditable ? context.state.editable.ngStyle : context.state.actions.customActions.ngStyle\"></th>\n }\n </tr>\n @if (context.state.actions.batchActions.isVisible) {\n <tr>\n <th [attr.colspan]=\"columns.length + ((context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) ? 1 : 0) + (context.state.caption.rowSelection.isEnabled ? 1 : 0) + (context.state.rowExpansion.isEnabled ? 1 : 0)\"\n [ngStyle]=\"context.state.actions.customActions.ngStyle\" class=\"px-0\">\n <div class=\"grid grid-nogutter items-center justify-start\">\n <p-tableHeaderCheckbox class=\"mr-4\"></p-tableHeaderCheckbox>\n @if (selectedItems?.length > 0) {\n @for (batchItem of context.state.actions.batchActions.items; track batchItem.label) {\n @if (batchItem.visible) {\n <button smzButton [label]=\"batchItem.label\" class=\"animate__animated animate__fadeIn\" [styleClass]=\"'p-button-plain ' + (batchItem.styleClass)\" [icon]=\"batchItem.icon\" (click)=\"batchItem.command(selectedItems); selectedItems = [];\" [disabled]=\"batchItem.disabled\" [smzTooltip]=\"batchItem.tooltip\" [rounded]=\"true\" variant=\"text\"></button>\n }\n }\n }\n </div>\n </th>\n </tr>\n }\n </ng-template>\n <ng-template smzTemplate=\"body\" let-item let-editing=\"editing\" let-rowIndex=\"rowIndex\" let-columns=\"columns\">\n <tr #editableRowElement\n [pEditableRow]=\"item\"\n tableItemAction\n [isClickable]=\"context.state.actions.rowBehavior.isClickable\"\n [callback]=\"context.state.actions.rowBehavior.clickCallback\"\n [expandRowOnClick]=\"context.state.actions.rowBehavior.expandRowOnClick\"\n [item]=\"item\"\n class=\"p-selectable-row\"\n [attr.data-testid]=\"buildRowTestId(item, rowIndex)\"\n [ngClass]=\"{ 'highlight-row': item?.id === state.actions.rowBehavior.highlights, 'preserve-in-small': state.actions.rowBehavior.preserveLayoutInSmallDevices }\"\n >\n @if (context.state.caption.rowSelection.isEnabled && !clonedData.showSkeleton) {\n <td\n clickStopPropagation\n class=\"{{ state.actions.rowBehavior.cellStyleClass }}\"\n [ngClass]=\"{ 'opacity-50 pointer-events-none': editableService.context[item.id]?.hasErrors || editableService.context[item.id]?.isLoading }\"\n [ngStyle]=\"context.state.caption.rowSelection.ngStyle\"\n >\n <p-tableCheckbox [value]=\"item\"></p-tableCheckbox>\n </td>\n }\n @if (context.state.rowExpansion.isEnabled && !clonedData.showSkeleton) {\n <td\n clickStopPropagation\n class=\"{{ state.actions.rowBehavior.cellStyleClass }}\"\n [ngClass]=\"{ 'opacity-50 pointer-events-none': editableService.context[item.id]?.hasErrors || editableService.context[item.id]?.isLoading, 'grid grid-nogutter justify-start items-center gap-2': context.state.rowExpansion.highlightNewItems && item._isNew }\"\n [ngStyle]=\"context.state.rowExpansion.ngStyle\"\n >\n <button smzButton type=\"button\" class=\"smz-table-row-expansion-toggle\" [icon]=\"item._isExpanded ? 'fa-solid fa-chevron-down' : 'fa-solid fa-chevron-right'\" (click)=\"item._isExpanded = !item._isExpanded; item._isNew = false\" variant=\"text\" [rounded]=\"true\" size=\"sm\"></button>\n @if (context.state.rowExpansion.highlightNewItems && item._isNew) {\n <div class=\"rounded bg-cyan-400 text-sm text-white px-2 py-0 smz-table-new-tag\" (click)=\"item._isNew = false\">{{ context.state.rowExpansion.highlightLabel }}</div>\n }\n </td>\n }\n @for (col of columns; track col.field) {\n @if (clonedData.showSkeleton) {\n <td class=\"{{ state.actions.rowBehavior.cellStyleClass }}\" [ngStyle]=\"col.content.ngStyle\"><ui-skeleton width=\"100%\" height=\"1rem\"></ui-skeleton></td>\n } @else {\n <td class=\"{{ state.actions.rowBehavior.cellStyleClass }}\" [attr.data-testid]=\"buildCellTestId(item, rowIndex, col.field)\" [ngClass]=\"{ 'opacity-50 pointer-events-none': editableService.context[item.id]?.hasErrors || editableService.context[item.id]?.isLoading }\" [ngStyle]=\"col.content.ngStyle\">\n <span class=\"p-column-title\">{{ col.header }}</span>\n <p-cellEditor>\n <!-- CELULAR COM EDITOR -->\n <ng-template smzTemplate=\"input\">\n @switch (col.editable.type) {\n @case (editableTypes.none) {\n <smz-table-content class=\"cursor-default\" [ngClass]=\"col.content.contentStyleClass\" [col]=\"col\" [contentTypes]=\"contentTypes\" [item]=\"item\" [rowIndex]=\"rowIndex\" [contentTemplate]=\"contentTemplate\"></smz-table-content>\n }\n @case (editableTypes.custom) {\n <ng-container *ngTemplateOutlet=\"editableTemplate; context: { $implicit: item, col: col }\"></ng-container>\n }\n <!-- INPUT TEXT -->\n @case (editableTypes.text) {\n @if (editableService.context[item.id]?.form; as form) {\n @if (form.controls[col.editable.property]; as control) {\n <div class=\"relative w-full\">\n <input smzInputText type=\"text\" [formControl]=\"$any(control)\" style=\"width: 100%;\">\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\n </div>\n }\n }\n }\n <!-- INPUT NUMBER -->\n @case (editableTypes.number) {\n @if (editableService.context[item.id]?.form; as form) {\n @if (form.controls[col.editable.property]; as control) {\n <div class=\"relative w-full\">\n <ui-input-number *ngVar=\"col.editable.data as numberData\" [formControl]=\"$any(control)\" [mode]=\"numberData.mode\" [minFractionDigits]=\"numberData.minFractionDigits\" [maxFractionDigits]=\"numberData.maxFractionDigits\" [currency]=\"numberData.currency\" [useGrouping]=\"numberData.useGrouping\" [allowEmpty]=\"numberData.allowEmpty\" [showClear]=\"numberData.showClear\" [showButtons]=\"numberData.showButtons\" [prefix]=\"numberData.prefix\" [suffix]=\"numberData.suffix\">\n </ui-input-number>\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\n </div>\n }\n }\n }\n <!-- INPUT SWITCH -->\n @case (editableTypes.switch) {\n @if (editableService.context[item.id]?.form; as form) {\n @if (form.controls[col.editable.property]; as control) {\n <div class=\"relative w-full\">\n <ui-toggle-switch [formControl]=\"$any(control)\"></ui-toggle-switch>\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\n </div>\n }\n }\n }\n <!-- INPUT TEXT AREA -->\n @case (editableTypes.area) {\n @if (editableService.context[item.id]?.form; as form) {\n @if (form.controls[col.editable.property]; as control) {\n <div class=\"relative w-full\">\n <textarea smzTextarea type=\"text\" [formControl]=\"$any(control)\" [rows]=\"$any(col.editable.data).rows\" required style=\"width: 100%;\"></textarea>\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\n </div>\n }\n }\n }\n <!-- INPUT DROPDOWN -->\n @case (editableTypes.dropdown) {\n @if (editableService.context[item.id]?.form; as form) {\n @if (form.controls[col.editable.property]; as control) {\n <div class=\"relative w-full\">\n <ui-select appendTo=\"body\" [formControl]=\"$any(control)\" styleClass=\"w-full\" [options]=\"col.editable.data | editableSource\" optionLabel=\"name\" dataKey=\"id\" [placeholder]=\"$any(col.editable.data).placeholder\" [showClear]=\"!col.editable.validatorsPreset?.isRequired\" [filter]=\"true\"></ui-select>\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\n </div>\n }\n }\n }\n <!-- INPUT CALENDAR -->\n @case (editableTypes.calendar) {\n @if (editableService.context[item.id]?.form; as form) {\n @if (form.controls[col.editable.property]; as control) {\n <div class=\"relative w-full\">\n <ui-date-picker [formControl]=\"$any(control)\" appendTo=\"body\" styleClass=\"w-full\" [ngClass]=\"{ 'pl-5': !control.valid }\"></ui-date-picker>\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\n </div>\n }\n }\n }\n }\n </ng-template>\n <!-- CELULAR COM CONTE\u00DADO -->\n <ng-template smzTemplate=\"output\">\n <smz-table-content\n [col]=\"col\"\n [smzTooltip]=\"col.content.tooltip != null ? col.content.tooltip(item) : null\"\n tooltipPosition=\"left\"\n [ngClass]=\"col.content.contentStyleClass\" [contentTypes]=\"contentTypes\" [item]=\"item\" [rowIndex]=\"rowIndex\" [contentTemplate]=\"contentTemplate\">\n </smz-table-content>\n </ng-template>\n </p-cellEditor>\n </td>\n }\n }\n @if (context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) {\n <td [ngStyle]=\"context.state.actions.customActions.ngStyle\" class=\"px-0\">\n <div class=\"grid grid-nogutter items-center justify-center\">\n @if (clonedData.showSkeleton) {\n <div class=\"w-full\">\n <ui-skeleton width=\"100%\" height=\"1rem\"></ui-skeleton>\n </div>\n } @else {\n <!-- SEM EDITAR -->\n @if (!editing) {\n @if (context.state.editable.update.isButtonVisible) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-pencil\" (click)=\"editableService.onRowEditInit(item)\" class=\"mx-1\" [disabled]=\"editableService.isEditing || editableService.isCreating || context.state.editable.update.isButtonDisabled || (!context.state.editable.update.condition(item))\" pInitEditableRow [rounded]=\"true\" variant=\"text\"></button>\n }\n @if (context.state.editable.remove.isButtonVisible) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-trash\" (click)=\"editableService.onRowRemove($event, table, item)\" class=\"mx-1\" [disabled]=\"editableService.isEditing || editableService.isCreating || context.state.editable.remove.isButtonDisabled || (!context.state.editable.remove.condition(item))\" [rounded]=\"true\" variant=\"text\" severity=\"secondary\"></button>\n }\n }\n <!-- EDITANDO -->\n @if (editing) {\n @if (editableService.context[item.id]; as editableContext) {\n <!-- COM LOADING -->\n @if (editableContext.isLoading) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-rotate fa-spin\" [disabled]=\"true\" class=\"mr-2\" [rounded]=\"true\" variant=\"text\" styleClass=\"p-button-info\"></button>\n }\n <!-- SEM LOADING -->\n @if (!editableContext.isLoading) {\n <!-- EDITANDO -->\n @if (!editableContext.hasErrors) {\n <!-- CRIANDO -->\n @if (item._context?.isCreating) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-check\" (click)=\"editableService.onRowCreateSave($event, table, editableRowElement, item)\" [disabled]=\"!editableContext.hasChanged || !editableService.context[item.id]?.form.valid\" class=\"mr-2\" [rounded]=\"true\" variant=\"text\" severity=\"success\"></button>\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowCreateCancel($event, table, item)\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\n }\n <!-- ATUALIZANDO -->\n @if (item._context?.isUpdating) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-check\" (click)=\"editableService.onRowEditSave($event, table, editableRowElement, item)\" [disabled]=\"!editableContext.hasChanged || !editableService.context[item.id]?.form.valid\" class=\"mr-2\" [rounded]=\"true\" variant=\"text\" severity=\"success\"></button>\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowEditCancel($event, table, item)\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\n }\n }\n <!-- COM ERRORS -->\n @if (editableContext.hasErrors) {\n <ui-popover #errorsOverlay appendTo=\"body\" [style]=\"{ width: '450px' }\">\n <div [innerHtml]=\"editableContext.errors | contentErrors\"></div>\n </ui-popover>\n <button smzButton type=\"button\" icon=\"fas fa-exclamation-triangle\" [disabled]=\"false\" class=\"mr-2\" (click)=\"errorsOverlay.toggle($event)\" size=\"sm\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\n <!-- CRIANDO -->\n @if (item._context?.isCreating) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowCreateCancel($event, table, item)\" size=\"sm\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\n }\n <!-- ATUALIZANDO -->\n @if (item._context?.isUpdating) {\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowEditCancel($event, table, item)\" size=\"sm\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\n }\n }\n }\n }\n }\n <!-- CUSTOM MENU -->\n @if (context.state.actions.customActions.isVisible && !editing) {\n <ng-container *ngTemplateOutlet=\"actionsTemplate; context: { $implicit: item }\"></ng-container>\n }\n <!-- MENU -->\n @if (context.state.actions.menu.isVisible && !editing) {\n <smz-menu [callback]=\"context.state.actions.menu.callback\" [items]=\"context.state.actions.menu.items\" [data]=\"item\" [behavior]=\"context.state.actions.menu.behavior\" [ngClass]=\"{ 'ml-2': context.state.actions.customActions.isVisible }\" [icon]=\"context.state.actions.menu.styles.icon\" [styleClass]=\"context.state.actions.menu.styles.styleClass\" [buttonClass]=\"context.state.actions.menu.styles.buttonClass\" [testId]=\"buildRowMenuTestId(item, rowIndex)\"></smz-menu>\n }\n }\n </div>\n </td>\n }\n </tr>\n @if (item?._isExpanded) {\n <tr>\n <td [attr.colspan]=\"columns.length + ((context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) ? 1 : 0) + (context.state.caption.rowSelection.isEnabled ? 1 : 0) + (context.state.rowExpansion.isEnabled ? 1 : 0)\">\n <ng-container *ngTemplateOutlet=\"rowContentTemplate; context: { $implicit: item }\"></ng-container>\n </td>\n </tr>\n }\n </ng-template>\n <ng-template smzTemplate=\"emptymessage\" let-columns>\n <tr>\n <td [attr.colspan]=\"columns.length + ((context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) ? 1 : 0) + (context.state.caption.rowSelection.isEnabled ? 1 : 0) + (context.state.rowExpansion.isEnabled ? 1 : 0)\" [ngStyle]=\"{ 'text-align': 'center' }\">\n <div [innerHtml]=\"context.state.emptyFeedback.message\"></div>\n @if (context.state.caption.clearFilters.isButtonVisible && hasFilters()) {\n <button smzButton [label]=\"context.state.locale.clearFilters.label\" class=\"mt-3\" icon=\"fa-solid fa-filter-circle-xmark\" (click)=\"clear(table, context)\" variant=\"outlined\"></button>\n }\n </td>\n </tr>\n </ng-template>\n </p-table>\n }\n </ng-container>\n </ng-container>\n }\n} @else {\n @if (emptyStateTemplate != null) {\n <ng-container *ngTemplateOutlet=\"emptyStateTemplate; context: { $implicit: {} }\"></ng-container>\n }\n}\n\n" }]
|
|
22616
|
+
args: [{ selector: 'smz-ui-table', changeDetection: ChangeDetectionStrategy.OnPush, providers: [TableEditableService, TableFormsService], standalone: false, template: "@if (state | tableContext; as context) {\r\n @if ((context.state.emptyFeedback != null && (context.state.emptyFeedback.extraInfo || context.state.emptyFeedback.image || context.state.emptyFeedback.actionButtons)) && (items != null && items.length === 0) && context.state.emptyFeedback.isFeatured) {\r\n <smz-data-info\r\n [attr.data-testid]=\"buildTableTestId('empty')\"\r\n [image]=\"context.state.emptyFeedback.image\"\r\n [message]=\"context.state.emptyFeedback.message\"\r\n [callbackInfo]=\"context.state.emptyFeedback.extraInfo\"\r\n [actions]=\"context.state.emptyFeedback.actionButtons\">\r\n <ng-template smzTemplate=\"actions\">\r\n <ng-container *ngTemplateOutlet=\"emptyActionsTemplate; context: { $implicit: {} }\"></ng-container>\r\n </ng-template>\r\n </smz-data-info>\r\n } @else {\r\n <ng-container *ngVar=\"state.source?.items$ != null ? (state.source.items$ | async) : null as observableSource\">\r\n <ng-container *ngVar=\"state.source?.signalItems != null ? state.source.signalItems() : null as signalSource\">\r\n @if (((observableSource ?? signalSource ?? items) | cloneTableItems : context: tableKey: context.state.rowExpansion.sincronize); as clonedData) {\r\n <p-table #dt\r\n dataKey=\"id\"\r\n editMode=\"row\"\r\n [stripedRows]=\"context.state.styles.striped\"\r\n [value]=\"clonedData.items\"\r\n [(selection)]=\"selectedItems\"\r\n [tableStyleClass]=\"context.state.styles.tableStyleClass\"\r\n [size]=\"context.state.styles.size === 'extra-small' ? 'small' : context.state.styles.size === 'small' ? 'small' : context.state.styles.size === 'large' ? 'large' : undefined\"\r\n [class]=\"'p-datatable-smz-ui-table' + (context.state.styles.showGrid ? ' p-datatable-gridlines' : '') + (context.state.styles.size === 'extra-small' ? ' p-datatable-xs' : '') + (context.state.styles.size === 'small' ? ' p-datatable-sm' : '') + (context.state.styles.size === 'large' ? ' p-datatable-lg' : '')\"\r\n [rowHover]=\"context.state.actions.rowBehavior.hoverable\"\r\n [rows]=\"context.state.pagination.rows\"\r\n [first]=\"context.state.pagination.state.first\"\r\n [showCurrentPageReport]=\"context.state.pagination.pageReport.isVisible\"\r\n [rowsPerPageOptions]=\"context.state.pagination.rowsPerPageOptions\"\r\n [loading]=\"loading || isViewportInitializing\"\r\n [style.visibility]=\"isViewportInitializing ? 'hidden' : null\"\r\n [paginator]=\"context.state.pagination.isVisible\"\r\n paginatorDropdownAppendTo=\"body\"\r\n [currentPageReportTemplate]=\"context.state.locale.paginator.template\"\r\n [sortField]=\"context.state.sort.field\"\r\n [sortMode]=\"context.state.sort.mode\"\r\n [sortOrder]=\"context.state.sort.order\"\r\n [multiSortMeta]=\"context.state.sort.multiSortMeta\"\r\n [scrollable]=\"context.state.viewport.scrollable\"\r\n [scrollHeight]=\"context.state.viewport.scrollHeight\"\r\n [filterDelay]=\"0\"\r\n [globalFilterFields]=\"context.globalFilter\"\r\n [columns]=\"context.visibleColumns\"\r\n [frozenColumns]=\"context.frozenColumns\"\r\n [frozenWidth]=\"context.state.frozen.isEnabled ? context.state.frozen.width : null\"\r\n [resizableColumns]=\"context.state.viewport.resizableColumns\"\r\n [columnResizeMode]=\"context.state.viewport.columnResizeMode\"\r\n (onPage)=\"onPage($event)\"\r\n (onFilter)=\"onFilter($event)\"\r\n (selectionChange)=\"emitSelection($event)\"\r\n >\r\n @if (context.state.caption.isVisible) {\r\n <ng-template smzTemplate=\"caption\">\r\n <div class=\"grid grid-nogutter items-center gap-2\" [attr.data-testid]=\"buildTableTestId('caption')\" [ngClass]=\"'justify-' + context.state.caption.toolbarAlignment\">\r\n @if (context.state.caption.title != null) {\r\n <div class=\"col database-title\" [attr.data-testid]=\"buildTableTestId('title')\" [innerHTML]=\"context.state.caption.title\"></div>\r\n }\r\n <ng-container *ngTemplateOutlet=\"captionTemplate; context: { $implicit: dt }\"></ng-container>\r\n <smz-table-caption-buttons [buttons]=\"context.state.caption.buttons\" [tableTestId]=\"state.tableTestId\"></smz-table-caption-buttons>\r\n @if (context.state.caption.exportToPdf.isButtonVisible) {\r\n <button smzButton [attr.data-testid]=\"buildTableTestId('export-pdf')\" [label]=\"context.state.locale.exportToPdf.label\" icon=\"fa-solid fa-file-pdf\" (click)=\"exportToPdf(context, clonedData.items)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\r\n }\r\n @if (context.state.caption.exportToExcel.isButtonVisible) {\r\n <button smzButton [attr.data-testid]=\"buildTableTestId('export-excel')\" [label]=\"context.state.locale.exportToExcel.label\" icon=\"fa-solid fa-file-excel\" (click)=\"exportToExcel(table, context, clonedData.items)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\r\n }\r\n @if (context.state.editable.creation.isButtonVisible) {\r\n <button smzButton [attr.data-testid]=\"buildTableTestId('create')\" [label]=\"context.state.editable.creation.buttonLabel\" icon=\"fa-solid fa-plus\" (click)=\"editableService.onRowCreateInit(table, context.columns)\" [disabled]=\"clonedData.showSkeleton || editableService.isEditing || editableService.isCreating || context.state.editable.creation.isButtonDisabled\" variant=\"outlined\"></button>\r\n }\r\n @if (context.state.caption.rowSelection.isButtonVisible) {\r\n <button smzButton [attr.data-testid]=\"buildTableTestId('row-selection')\" [label]=\"context.state.locale.rowSelection.label\" icon=\"fa-solid fa-check-double\" (click)=\"onRowSelection(context)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\r\n }\r\n @if (context.state.rowExpansion.isButtonVisible) {\r\n <button smzButton [attr.data-testid]=\"buildTableTestId('row-expansion')\" [label]=\"context.state.rowExpansion.label\" icon=\"fa-solid fa-list\" (click)=\"onRowExpansion(context)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\r\n }\r\n @if (context.state.caption.clearFilters.isButtonVisible) {\r\n <button smzButton [attr.data-testid]=\"buildTableTestId('clear-filters')\" [label]=\"context.state.locale.clearFilters.label\" icon=\"fa-solid fa-filter-circle-xmark\" (click)=\"clear(table, context)\" [disabled]=\"clonedData.showSkeleton\" variant=\"outlined\"></button>\r\n }\r\n @if (context.state.caption.columnVisibility.showDropdownSelector) {\r\n <ui-multi-select #columnMultiselect [attr.data-testid]=\"buildTableTestId('column-visibility')\" class=\"ml-2 col-12 md:col-2\" styleClass=\"w-full\" appendTo=\"body\" [options]=\"context.hideableColumns\" [(ngModel)]=\"selectedColumns\" [placeholder]=\"context.state.locale.columnVisibility.placeholder\" [selectedItemsLabel]=\"context.state.locale.columnVisibility.selectedItemsLabel\" optionLabel=\"name\" dataKey=\"field\" optionLabel=\"header\" [filter]=\"true\" (panelHide)=\"updateColumnsVisibility(true)\" [smzTooltip]=\"context.state.locale.columnVisibility.pTooltip\">\r\n </ui-multi-select>\r\n }\r\n @if (context.state.caption.globalFilter.isVisible) {\r\n <ui-icon-field class=\"col-12\" [ngClass]=\"{ 'md:col-2': !context.state.caption.globalFilter.expanded }\">\r\n <ui-input-icon styleClass=\"fa-solid fa-magnifying-glass\"></ui-input-icon>\r\n <input #inputGlobal [(ngModel)]=\"globalSearchInput\" smzInputText type=\"text\" styleClass=\"database-global-search\" (input)=\"updateGlobalFilter(inputGlobal.value)\" [disabled]=\"clonedData.showSkeleton\" [placeholder]=\"context.state.locale.globalFilter.placeholder\" [attr.data-testid]=\"buildTableTestId('search')\" />\r\n </ui-icon-field>\r\n }\r\n </div>\r\n @if (toolbarTemplate != null) {\r\n <div class=\"grid grid-nogutter items-center mt-2\" [ngClass]=\"'justify-' + context.state.caption.toolbarAlignment\">\r\n <ng-container *ngTemplateOutlet=\"toolbarTemplate; context: { $implicit: dt }\"></ng-container>\r\n </div>\r\n }\r\n </ng-template>\r\n }\r\n <ng-template smzTemplate=\"header\" let-columns>\r\n <tr [ngClass]=\"{ 'invisible-header': !context.state.header.isVisible }\">\r\n @if (context.state.caption.rowSelection.isEnabled) {\r\n <th [ngStyle]=\"context.state.caption.rowSelection.ngStyle\">\r\n @if (!context.state.actions.batchActions.isVisible) {\r\n <p-tableHeaderCheckbox></p-tableHeaderCheckbox>\r\n }\r\n </th>\r\n }\r\n @if (context.state.rowExpansion.isEnabled) {\r\n <th [ngStyle]=\"context.state.rowExpansion.ngStyle\"></th>\r\n }\r\n @for (col of columns; track col.field) {\r\n @if (context.state.viewport.resizableColumns) {\r\n @if (col.isOrderable) {\r\n <th [pSortableColumn]=\"col.sortField\" pResizableColumn [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\r\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\r\n </th>\r\n }\r\n @if (!col.isOrderable) {\r\n <th pResizableColumn [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\r\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\r\n </th>\r\n }\r\n } @else {\r\n @if (col.isOrderable) {\r\n <th [pSortableColumn]=\"col.sortField\" [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\r\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\r\n </th>\r\n }\r\n @if (!col.isOrderable) {\r\n <th [attr.data-testid]=\"buildColumnTestId(col.field)\" [ngStyle]=\"col.content.ngStyle\" [ngClass]=\"col.headerStyleClass\">\r\n <ng-container *ngTemplateOutlet=\"headerContent\"></ng-container>\r\n </th>\r\n }\r\n }\r\n <ng-template #headerContent>\r\n <div class=\"flex justify-start items-center\">\r\n <span class=\"mr-1\">{{ col.header }}</span>\r\n @if (col.showHeaderActions) {\r\n <smz-table-header-actions clickStopPropagation class=\"ml-1 mt-1\" [col]=\"col\"></smz-table-header-actions>\r\n }\r\n @if (!clonedData.showSkeleton && col.isOrderable) {\r\n <p-sortIcon [field]=\"col.sortField\"></p-sortIcon>\r\n }\r\n @if (!clonedData.showSkeleton) {\r\n @switch (col.filter.type) {\r\n @case (filterTypes.currency) {\r\n <smz-column-filter type=\"numeric\" currency=\"BRL\" [field]=\"col.filterField\"></smz-column-filter>\r\n }\r\n @case (filterTypes.numeric) {\r\n <smz-column-filter type=\"numeric\" [field]=\"col.filterField\"></smz-column-filter>\r\n }\r\n @case (filterTypes.date) {\r\n <smz-column-filter type=\"date\" [field]=\"col.filterField\" [showTime]=\"col.filter.showTime\"></smz-column-filter>\r\n }\r\n @case (filterTypes.text) {\r\n <smz-column-filter type=\"text\" [field]=\"col.filterField\"></smz-column-filter>\r\n }\r\n @case (filterTypes.boolean) {\r\n <smz-column-filter type=\"boolean\" [field]=\"col.filterField\"></smz-column-filter>\r\n }\r\n @case (filterTypes.dropdown) {\r\n @if (col.filterField | filterObject; as filterField) {\r\n <smz-column-filter [field]=\"filterField + '.id'\" matchMode=\"dropdown\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\r\n <ng-template smzTemplate=\"header\">\r\n <div class=\"px-3 pt-3 pb-0\">\r\n <span class=\"p-text-bold\">{{ col.header }}</span>\r\n </div>\r\n </ng-template>\r\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\r\n <ui-select appendTo=\"body\" [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField + '.id' : filterField : null : 'name' : false\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" optionLabel=\"name\" dataKey=\"id\"></ui-select>\r\n </ng-template>\r\n </smz-column-filter>\r\n }\r\n }\r\n @case (filterTypes.multiselect) {\r\n @if (col.filterField | filterObject; as filterField) {\r\n <smz-column-filter [field]=\"filterField\" matchMode=\"in\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\r\n <ng-template smzTemplate=\"header\">\r\n <div class=\"px-3 pt-3 pb-0\">\r\n <span class=\"p-text-bold\">{{ col.header }}</span>\r\n </div>\r\n </ng-template>\r\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\r\n <ui-multi-select [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField + '.id' : filterField : null : 'name' : false\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" optionLabel=\"name\" dataKey=\"id\"></ui-multi-select>\r\n </ng-template>\r\n </smz-column-filter>\r\n }\r\n }\r\n @case (filterTypes.multiselect_array) {\r\n @if (col.filterField | filterObject; as filterField) {\r\n <smz-column-filter [field]=\"filterField\" matchMode=\"array-some\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\r\n <ng-template smzTemplate=\"header\">\r\n <div class=\"px-3 pt-3 pb-0\">\r\n <span class=\"p-text-bold\">{{ col.header }}</span>\r\n </div>\r\n </ng-template>\r\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\r\n <ui-multi-select [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField + '.id' : filterField : null : 'name' : true\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" optionLabel=\"name\" dataKey=\"id\" [maxSelectedLabels]=\"2\" [selectedItemsLabel]=\"'{0}'\"></ui-multi-select>\r\n </ng-template>\r\n </smz-column-filter>\r\n }\r\n }\r\n @case (filterTypes.multiselect_string) {\r\n @if (col.filterField | filterObject; as filterField) {\r\n <smz-column-filter [field]=\"filterField\" matchMode=\"multiselectByString\" [showMatchModes]=\"false\" [showOperator]=\"false\" [showAddButton]=\"false\">\r\n <ng-template smzTemplate=\"header\">\r\n <div class=\"px-3 pt-3 pb-0\">\r\n <span class=\"p-text-bold\">{{ col.header }}</span>\r\n </div>\r\n </ng-template>\r\n <ng-template smzTemplate=\"filter\" let-value let-filter=\"filter\">\r\n <ui-multi-select [ngModel]=\"value\" [options]=\"(clonedData.items != null ? clonedData.items : []) | uniqueFilter : filterField : filterField : null : true : false : false\" [placeholder]=\"context.state.locale.dropdownFilter.placeholder\" (changed)=\"filter($event.value)\" [maxSelectedLabels]=\"2\" [selectedItemsLabel]=\"'{0}'\"></ui-multi-select>\r\n </ng-template>\r\n </smz-column-filter>\r\n }\r\n }\r\n }\r\n }\r\n @if (context.state.caption.columnVisibility.showColumnHideButton) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-eye-slash\" (click)=\"hideColumn(col, context)\" [rounded]=\"true\" variant=\"text\" styleClass=\"p-button-plain\"></button>\r\n }\r\n </div>\r\n </ng-template>\r\n }\r\n @if (context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible|| context.state.editable.isEditable) {\r\n <th [ngStyle]=\"context.state.editable.isEditable ? context.state.editable.ngStyle : context.state.actions.customActions.ngStyle\"></th>\r\n }\r\n </tr>\r\n @if (context.state.actions.batchActions.isVisible) {\r\n <tr>\r\n <th [attr.colspan]=\"columns.length + ((context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) ? 1 : 0) + (context.state.caption.rowSelection.isEnabled ? 1 : 0) + (context.state.rowExpansion.isEnabled ? 1 : 0)\"\r\n [ngStyle]=\"context.state.actions.customActions.ngStyle\" class=\"px-0\">\r\n <div class=\"grid grid-nogutter items-center justify-start\">\r\n <p-tableHeaderCheckbox class=\"mr-4\"></p-tableHeaderCheckbox>\r\n @if (selectedItems?.length > 0) {\r\n @for (batchItem of context.state.actions.batchActions.items; track batchItem.label) {\r\n @if (batchItem.visible) {\r\n <button smzButton [label]=\"batchItem.label\" class=\"animate__animated animate__fadeIn\" [styleClass]=\"'p-button-plain ' + (batchItem.styleClass)\" [icon]=\"batchItem.icon\" (click)=\"batchItem.command(selectedItems); selectedItems = [];\" [disabled]=\"batchItem.disabled\" [smzTooltip]=\"batchItem.tooltip\" [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n }\r\n }\r\n </div>\r\n </th>\r\n </tr>\r\n }\r\n </ng-template>\r\n <ng-template smzTemplate=\"body\" let-item let-editing=\"editing\" let-rowIndex=\"rowIndex\" let-columns=\"columns\">\r\n <tr #editableRowElement\r\n [pEditableRow]=\"item\"\r\n tableItemAction\r\n [isClickable]=\"context.state.actions.rowBehavior.isClickable\"\r\n [callback]=\"context.state.actions.rowBehavior.clickCallback\"\r\n [expandRowOnClick]=\"context.state.actions.rowBehavior.expandRowOnClick\"\r\n [item]=\"item\"\r\n class=\"p-selectable-row\"\r\n [attr.data-testid]=\"buildRowTestId(item, rowIndex)\"\r\n [ngClass]=\"{ 'highlight-row': item?.id === state.actions.rowBehavior.highlights, 'preserve-in-small': state.actions.rowBehavior.preserveLayoutInSmallDevices }\"\r\n >\r\n @if (context.state.caption.rowSelection.isEnabled && !clonedData.showSkeleton) {\r\n <td\r\n clickStopPropagation\r\n class=\"{{ state.actions.rowBehavior.cellStyleClass }}\"\r\n [ngClass]=\"{ 'opacity-50 pointer-events-none': editableService.context[item.id]?.hasErrors || editableService.context[item.id]?.isLoading }\"\r\n [ngStyle]=\"context.state.caption.rowSelection.ngStyle\"\r\n >\r\n <p-tableCheckbox [value]=\"item\"></p-tableCheckbox>\r\n </td>\r\n }\r\n @if (context.state.rowExpansion.isEnabled && !clonedData.showSkeleton) {\r\n <td\r\n clickStopPropagation\r\n class=\"{{ state.actions.rowBehavior.cellStyleClass }}\"\r\n [ngClass]=\"{ 'opacity-50 pointer-events-none': editableService.context[item.id]?.hasErrors || editableService.context[item.id]?.isLoading, 'grid grid-nogutter justify-start items-center gap-2': context.state.rowExpansion.highlightNewItems && item._isNew }\"\r\n [ngStyle]=\"context.state.rowExpansion.ngStyle\"\r\n >\r\n <button smzButton type=\"button\" class=\"smz-table-row-expansion-toggle\" [icon]=\"item._isExpanded ? 'fa-solid fa-chevron-down' : 'fa-solid fa-chevron-right'\" (click)=\"item._isExpanded = !item._isExpanded; item._isNew = false\" variant=\"text\" [rounded]=\"true\" size=\"sm\"></button>\r\n @if (context.state.rowExpansion.highlightNewItems && item._isNew) {\r\n <div class=\"rounded bg-cyan-400 text-sm text-white px-2 py-0 smz-table-new-tag\" (click)=\"item._isNew = false\">{{ context.state.rowExpansion.highlightLabel }}</div>\r\n }\r\n </td>\r\n }\r\n @for (col of columns; track col.field) {\r\n @if (clonedData.showSkeleton) {\r\n <td class=\"{{ state.actions.rowBehavior.cellStyleClass }}\" [ngStyle]=\"col.content.ngStyle\"><ui-skeleton width=\"100%\" height=\"1rem\"></ui-skeleton></td>\r\n } @else {\r\n <td class=\"{{ state.actions.rowBehavior.cellStyleClass }}\" [attr.data-testid]=\"buildCellTestId(item, rowIndex, col.field)\" [ngClass]=\"{ 'opacity-50 pointer-events-none': editableService.context[item.id]?.hasErrors || editableService.context[item.id]?.isLoading }\" [ngStyle]=\"col.content.ngStyle\">\r\n <span class=\"p-column-title\">{{ col.header }}</span>\r\n <p-cellEditor>\r\n <!-- CELULAR COM EDITOR -->\r\n <ng-template smzTemplate=\"input\">\r\n @switch (col.editable.type) {\r\n @case (editableTypes.none) {\r\n <smz-table-content class=\"cursor-default\" [ngClass]=\"col.content.contentStyleClass\" [col]=\"col\" [contentTypes]=\"contentTypes\" [item]=\"item\" [rowIndex]=\"rowIndex\" [contentTemplate]=\"contentTemplate\"></smz-table-content>\r\n }\r\n @case (editableTypes.custom) {\r\n <ng-container *ngTemplateOutlet=\"editableTemplate; context: { $implicit: item, col: col }\"></ng-container>\r\n }\r\n <!-- INPUT TEXT -->\r\n @case (editableTypes.text) {\r\n @if (editableService.context[item.id]?.form; as form) {\r\n @if (form.controls[col.editable.property]; as control) {\r\n <div class=\"relative w-full\">\r\n <input smzInputText type=\"text\" [formControl]=\"$any(control)\" style=\"width: 100%;\">\r\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\r\n </div>\r\n }\r\n }\r\n }\r\n <!-- INPUT NUMBER -->\r\n @case (editableTypes.number) {\r\n @if (editableService.context[item.id]?.form; as form) {\r\n @if (form.controls[col.editable.property]; as control) {\r\n <div class=\"relative w-full\">\r\n <ui-input-number *ngVar=\"col.editable.data as numberData\" [formControl]=\"$any(control)\" [mode]=\"numberData.mode\" [minFractionDigits]=\"numberData.minFractionDigits\" [maxFractionDigits]=\"numberData.maxFractionDigits\" [currency]=\"numberData.currency\" [useGrouping]=\"numberData.useGrouping\" [allowEmpty]=\"numberData.allowEmpty\" [showClear]=\"numberData.showClear\" [showButtons]=\"numberData.showButtons\" [prefix]=\"numberData.prefix\" [suffix]=\"numberData.suffix\">\r\n </ui-input-number>\r\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\r\n </div>\r\n }\r\n }\r\n }\r\n <!-- INPUT SWITCH -->\r\n @case (editableTypes.switch) {\r\n @if (editableService.context[item.id]?.form; as form) {\r\n @if (form.controls[col.editable.property]; as control) {\r\n <div class=\"relative w-full\">\r\n <ui-toggle-switch [formControl]=\"$any(control)\"></ui-toggle-switch>\r\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\r\n </div>\r\n }\r\n }\r\n }\r\n <!-- INPUT TEXT AREA -->\r\n @case (editableTypes.area) {\r\n @if (editableService.context[item.id]?.form; as form) {\r\n @if (form.controls[col.editable.property]; as control) {\r\n <div class=\"relative w-full\">\r\n <textarea smzTextarea type=\"text\" [formControl]=\"$any(control)\" [rows]=\"$any(col.editable.data).rows\" required style=\"width: 100%;\"></textarea>\r\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\r\n </div>\r\n }\r\n }\r\n }\r\n <!-- INPUT DROPDOWN -->\r\n @case (editableTypes.dropdown) {\r\n @if (editableService.context[item.id]?.form; as form) {\r\n @if (form.controls[col.editable.property]; as control) {\r\n <div class=\"relative w-full\">\r\n <ui-select appendTo=\"body\" [formControl]=\"$any(control)\" styleClass=\"w-full\" [options]=\"col.editable.data | editableSource\" optionLabel=\"name\" dataKey=\"id\" [placeholder]=\"$any(col.editable.data).placeholder\" [showClear]=\"!col.editable.validatorsPreset?.isRequired\" [filter]=\"true\"></ui-select>\r\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\r\n </div>\r\n }\r\n }\r\n }\r\n <!-- INPUT CALENDAR -->\r\n @case (editableTypes.calendar) {\r\n @if (editableService.context[item.id]?.form; as form) {\r\n @if (form.controls[col.editable.property]; as control) {\r\n <div class=\"relative w-full\">\r\n <ui-date-picker [formControl]=\"$any(control)\" appendTo=\"body\" styleClass=\"w-full\" [ngClass]=\"{ 'pl-5': !control.valid }\"></ui-date-picker>\r\n <smz-table-validation-messages [errors]=\"control.errors\" [messages]=\"uiConfig.dialogs.forms.validationMessages\" [isFormInvalid]=\"form.invalid\" [isFormDirty]=\"form.dirty\"></smz-table-validation-messages>\r\n </div>\r\n }\r\n }\r\n }\r\n }\r\n </ng-template>\r\n <!-- CELULAR COM CONTE\u00DADO -->\r\n <ng-template smzTemplate=\"output\">\r\n <smz-table-content\r\n [col]=\"col\"\r\n [smzTooltip]=\"col.content.tooltip != null ? col.content.tooltip(item) : null\"\r\n tooltipPosition=\"left\"\r\n [ngClass]=\"col.content.contentStyleClass\" [contentTypes]=\"contentTypes\" [item]=\"item\" [rowIndex]=\"rowIndex\" [contentTemplate]=\"contentTemplate\">\r\n </smz-table-content>\r\n </ng-template>\r\n </p-cellEditor>\r\n </td>\r\n }\r\n }\r\n @if (context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) {\r\n <td [ngStyle]=\"context.state.actions.customActions.ngStyle\" class=\"px-0\">\r\n <div class=\"grid grid-nogutter items-center justify-center\">\r\n @if (clonedData.showSkeleton) {\r\n <div class=\"w-full\">\r\n <ui-skeleton width=\"100%\" height=\"1rem\"></ui-skeleton>\r\n </div>\r\n } @else {\r\n <!-- SEM EDITAR -->\r\n @if (!editing) {\r\n @if (context.state.editable.update.isButtonVisible) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-pencil\" (click)=\"editableService.onRowEditInit(item)\" class=\"mx-1\" [disabled]=\"editableService.isEditing || editableService.isCreating || context.state.editable.update.isButtonDisabled || (!context.state.editable.update.condition(item))\" pInitEditableRow [rounded]=\"true\" variant=\"text\"></button>\r\n }\r\n @if (context.state.editable.remove.isButtonVisible) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-trash\" (click)=\"editableService.onRowRemove($event, table, item)\" class=\"mx-1\" [disabled]=\"editableService.isEditing || editableService.isCreating || context.state.editable.remove.isButtonDisabled || (!context.state.editable.remove.condition(item))\" [rounded]=\"true\" variant=\"text\" severity=\"secondary\"></button>\r\n }\r\n }\r\n <!-- EDITANDO -->\r\n @if (editing) {\r\n @if (editableService.context[item.id]; as editableContext) {\r\n <!-- COM LOADING -->\r\n @if (editableContext.isLoading) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-rotate fa-spin\" [disabled]=\"true\" class=\"mr-2\" [rounded]=\"true\" variant=\"text\" styleClass=\"p-button-info\"></button>\r\n }\r\n <!-- SEM LOADING -->\r\n @if (!editableContext.isLoading) {\r\n <!-- EDITANDO -->\r\n @if (!editableContext.hasErrors) {\r\n <!-- CRIANDO -->\r\n @if (item._context?.isCreating) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-check\" (click)=\"editableService.onRowCreateSave($event, table, editableRowElement, item)\" [disabled]=\"!editableContext.hasChanged || !editableService.context[item.id]?.form.valid\" class=\"mr-2\" [rounded]=\"true\" variant=\"text\" severity=\"success\"></button>\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowCreateCancel($event, table, item)\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\r\n }\r\n <!-- ATUALIZANDO -->\r\n @if (item._context?.isUpdating) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-check\" (click)=\"editableService.onRowEditSave($event, table, editableRowElement, item)\" [disabled]=\"!editableContext.hasChanged || !editableService.context[item.id]?.form.valid\" class=\"mr-2\" [rounded]=\"true\" variant=\"text\" severity=\"success\"></button>\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowEditCancel($event, table, item)\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\r\n }\r\n }\r\n <!-- COM ERRORS -->\r\n @if (editableContext.hasErrors) {\r\n <ui-popover #errorsOverlay appendTo=\"body\" [style]=\"{ width: '450px' }\">\r\n <div [innerHtml]=\"editableContext.errors | contentErrors\"></div>\r\n </ui-popover>\r\n <button smzButton type=\"button\" icon=\"fas fa-exclamation-triangle\" [disabled]=\"false\" class=\"mr-2\" (click)=\"errorsOverlay.toggle($event)\" size=\"sm\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\r\n <!-- CRIANDO -->\r\n @if (item._context?.isCreating) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowCreateCancel($event, table, item)\" size=\"sm\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\r\n }\r\n <!-- ATUALIZANDO -->\r\n @if (item._context?.isUpdating) {\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" (click)=\"editableService.onRowEditCancel($event, table, item)\" size=\"sm\" [rounded]=\"true\" variant=\"text\" severity=\"danger\"></button>\r\n }\r\n }\r\n }\r\n }\r\n }\r\n <!-- CUSTOM MENU -->\r\n @if (context.state.actions.customActions.isVisible && !editing) {\r\n <ng-container *ngTemplateOutlet=\"actionsTemplate; context: { $implicit: item }\"></ng-container>\r\n }\r\n <!-- MENU -->\r\n @if (context.state.actions.menu.isVisible && !editing) {\r\n <smz-menu [callback]=\"context.state.actions.menu.callback\" [items]=\"context.state.actions.menu.items\" [data]=\"item\" [behavior]=\"context.state.actions.menu.behavior\" [ngClass]=\"{ 'ml-2': context.state.actions.customActions.isVisible }\" [icon]=\"context.state.actions.menu.styles.icon\" [styleClass]=\"context.state.actions.menu.styles.styleClass\" [buttonClass]=\"context.state.actions.menu.styles.buttonClass\" [testId]=\"buildRowMenuTestId(item, rowIndex)\"></smz-menu>\r\n }\r\n }\r\n </div>\r\n </td>\r\n }\r\n </tr>\r\n @if (item?._isExpanded) {\r\n <tr>\r\n <td [attr.colspan]=\"columns.length + ((context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) ? 1 : 0) + (context.state.caption.rowSelection.isEnabled ? 1 : 0) + (context.state.rowExpansion.isEnabled ? 1 : 0)\">\r\n <ng-container *ngTemplateOutlet=\"rowContentTemplate; context: { $implicit: item }\"></ng-container>\r\n </td>\r\n </tr>\r\n }\r\n </ng-template>\r\n <ng-template smzTemplate=\"emptymessage\" let-columns>\r\n <tr>\r\n <td [attr.colspan]=\"columns.length + ((context.state.actions.menu.isVisible || context.state.actions.customActions.isVisible || context.state.editable.isEditable) ? 1 : 0) + (context.state.caption.rowSelection.isEnabled ? 1 : 0) + (context.state.rowExpansion.isEnabled ? 1 : 0)\" [ngStyle]=\"{ 'text-align': 'center' }\">\r\n <div [innerHtml]=\"context.state.emptyFeedback.message\"></div>\r\n @if (context.state.caption.clearFilters.isButtonVisible && hasFilters()) {\r\n <button smzButton [label]=\"context.state.locale.clearFilters.label\" class=\"mt-3\" icon=\"fa-solid fa-filter-circle-xmark\" (click)=\"clear(table, context)\" variant=\"outlined\"></button>\r\n }\r\n </td>\r\n </tr>\r\n </ng-template>\r\n </p-table>\r\n }\r\n </ng-container>\r\n </ng-container>\r\n }\r\n} @else {\r\n @if (emptyStateTemplate != null) {\r\n <ng-container *ngTemplateOutlet=\"emptyStateTemplate; context: { $implicit: {} }\"></ng-container>\r\n }\r\n}\r\n\r\n" }]
|
|
22567
22617
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: TableEditableService }, { type: TableFormsService }, { type: TableHelperService }, { type: i1$3.Store }, { type: SmzExcelService }], propDecorators: { templates: [{
|
|
22568
22618
|
type: ContentChildren,
|
|
22569
22619
|
args: [SmzTemplateDirective]
|
|
@@ -22584,6 +22634,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImpor
|
|
|
22584
22634
|
args: ['attr.data-testid']
|
|
22585
22635
|
}], selectionChange: [{
|
|
22586
22636
|
type: Output
|
|
22637
|
+
}], validChange: [{
|
|
22638
|
+
type: Output
|
|
22587
22639
|
}], filterChange: [{
|
|
22588
22640
|
type: Output
|
|
22589
22641
|
}], columnVisibilityChange: [{
|
|
@@ -23063,16 +23115,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImpor
|
|
|
23063
23115
|
class TableContentComponent {
|
|
23064
23116
|
items$;
|
|
23065
23117
|
state;
|
|
23118
|
+
/** Validade informada pela tabela (que pode trabalhar com uma copia de `state`); `null` ate a primeira mudanca. */
|
|
23119
|
+
tableValid = null;
|
|
23066
23120
|
get isValid() {
|
|
23067
|
-
return this.state == null ? true : this.state.isValid;
|
|
23121
|
+
return this.state == null ? true : (this.tableValid ?? this.state.isValid);
|
|
23068
23122
|
}
|
|
23069
23123
|
onValidationError$ = new BehaviorSubject(null);
|
|
23070
23124
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: TableContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
23071
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: TableContentComponent, isStandalone: false, selector: "smz-table-content", inputs: { items$: "items$", state: "state" }, ngImport: i0, template: "@if (onValidationError$ | async; as onValidationError) {\r\n <div class=\"grid grid-nogutter items-center justify-end w-full\">\r\n @if (onValidationError) {\r\n <span style=\"color: red\">* Precisa selecionar pelo menos um item</span>\r\n }\r\n </div>\r\n}\r\n<smz-ui-table #smzdt [items]=\"items$ | async\" [state]=\"state\"></smz-ui-table>", styles: [""], dependencies: [{ kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
23125
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: TableContentComponent, isStandalone: false, selector: "smz-table-content", inputs: { items$: "items$", state: "state" }, ngImport: i0, template: "@if (onValidationError$ | async; as onValidationError) {\r\n <div class=\"grid grid-nogutter items-center justify-end w-full\">\r\n @if (onValidationError) {\r\n <span style=\"color: red\">* Precisa selecionar pelo menos um item</span>\r\n }\r\n </div>\r\n}\r\n<smz-ui-table #smzdt [items]=\"items$ | async\" [state]=\"state\" (validChange)=\"tableValid = $event\"></smz-ui-table>", styles: [""], dependencies: [{ kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "validChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
23072
23126
|
}
|
|
23073
23127
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: TableContentComponent, decorators: [{
|
|
23074
23128
|
type: Component,
|
|
23075
|
-
args: [{ selector: 'smz-table-content', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, template: "@if (onValidationError$ | async; as onValidationError) {\r\n <div class=\"grid grid-nogutter items-center justify-end w-full\">\r\n @if (onValidationError) {\r\n <span style=\"color: red\">* Precisa selecionar pelo menos um item</span>\r\n }\r\n </div>\r\n}\r\n<smz-ui-table #smzdt [items]=\"items$ | async\" [state]=\"state\"></smz-ui-table>" }]
|
|
23129
|
+
args: [{ selector: 'smz-table-content', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, template: "@if (onValidationError$ | async; as onValidationError) {\r\n <div class=\"grid grid-nogutter items-center justify-end w-full\">\r\n @if (onValidationError) {\r\n <span style=\"color: red\">* Precisa selecionar pelo menos um item</span>\r\n }\r\n </div>\r\n}\r\n<smz-ui-table #smzdt [items]=\"items$ | async\" [state]=\"state\" (validChange)=\"tableValid = $event\"></smz-ui-table>" }]
|
|
23076
23130
|
}], propDecorators: { items$: [{
|
|
23077
23131
|
type: Input
|
|
23078
23132
|
}], state: [{
|
|
@@ -24581,8 +24635,8 @@ class SmzFormGroupBuilder extends SmzBuilderUtilities {
|
|
|
24581
24635
|
this.formBuilderRef = formBuilderRef;
|
|
24582
24636
|
this.group = group;
|
|
24583
24637
|
}
|
|
24584
|
-
setLayout(breakpoint,
|
|
24585
|
-
const template = getSmzTemplate(breakpoint,
|
|
24638
|
+
setLayout(breakpoint, columns) {
|
|
24639
|
+
const template = getSmzTemplate(breakpoint, columns);
|
|
24586
24640
|
this.group.template = { ...this.group.template, ...template };
|
|
24587
24641
|
return this;
|
|
24588
24642
|
}
|
|
@@ -25178,8 +25232,8 @@ class SmzFormInputBuilder {
|
|
|
25178
25232
|
this.inputRef.advancedSettings = {};
|
|
25179
25233
|
}
|
|
25180
25234
|
}
|
|
25181
|
-
setLayout(breakpoint,
|
|
25182
|
-
const template = getSmzTemplate(breakpoint,
|
|
25235
|
+
setLayout(breakpoint, columns) {
|
|
25236
|
+
const template = getSmzTemplate(breakpoint, columns);
|
|
25183
25237
|
this.inputRef.template = { ...this.inputRef.template, ...template };
|
|
25184
25238
|
return this.that;
|
|
25185
25239
|
}
|
|
@@ -25862,7 +25916,7 @@ class SmzFormListBuilder extends SmzFormInputBuilder {
|
|
|
25862
25916
|
propertyName: 'name', name: 'nome', type: SmzControlType.TEXT, hideName: true,
|
|
25863
25917
|
validatorsPreset: { isRequired: true },
|
|
25864
25918
|
advancedSettings: { validators: [MustBeUnique(this._listInput.options)], validationMessages: [{ type: 'unique', message: 'Já existe um item com esse dado.' }] },
|
|
25865
|
-
template: { large: { row:
|
|
25919
|
+
template: { large: { row: 12 } },
|
|
25866
25920
|
};
|
|
25867
25921
|
this._listInput.crud.inputData = textInput;
|
|
25868
25922
|
}
|
|
@@ -25913,7 +25967,7 @@ class SmzFormListBuilder extends SmzFormInputBuilder {
|
|
|
25913
25967
|
useFractionNumberInput(label = 'Dado', digits = 2) {
|
|
25914
25968
|
const numberInput = {
|
|
25915
25969
|
propertyName: 'name', name: label, type: SmzControlType.NUMBER,
|
|
25916
|
-
template: { large: { row:
|
|
25970
|
+
template: { large: { row: 12 } },
|
|
25917
25971
|
locale: this._listInput.crud.inputLocale,
|
|
25918
25972
|
useFraction: true,
|
|
25919
25973
|
minFractionDigits: digits,
|
|
@@ -25928,7 +25982,7 @@ class SmzFormListBuilder extends SmzFormInputBuilder {
|
|
|
25928
25982
|
useNumberInput(label = 'Dado') {
|
|
25929
25983
|
const numberInput = {
|
|
25930
25984
|
propertyName: 'name', name: label, type: SmzControlType.NUMBER,
|
|
25931
|
-
template: { large: { row:
|
|
25985
|
+
template: { large: { row: 12 } },
|
|
25932
25986
|
useFraction: false,
|
|
25933
25987
|
autoFocus: true
|
|
25934
25988
|
};
|
|
@@ -26135,18 +26189,20 @@ class SmzFormInputValidatorBuilder extends SmzBuilderUtilities {
|
|
|
26135
26189
|
return this.inputRefBuilder;
|
|
26136
26190
|
}
|
|
26137
26191
|
}
|
|
26138
|
-
|
|
26192
|
+
/** Template de um breakpoint. Sem numero de colunas assume 12 (largura toda), o que o legado `col-auto` fazia na pratica. */
|
|
26193
|
+
function getSmzTemplate(breakpoint, columns) {
|
|
26194
|
+
const row = columns ?? 12;
|
|
26139
26195
|
switch (breakpoint) {
|
|
26140
26196
|
case 'EXTRA_SMALL':
|
|
26141
|
-
return { extraSmall: { row
|
|
26197
|
+
return { extraSmall: { row } };
|
|
26142
26198
|
case 'SMALL':
|
|
26143
|
-
return { small: { row
|
|
26199
|
+
return { small: { row } };
|
|
26144
26200
|
case 'MEDIUM':
|
|
26145
|
-
return { medium: { row
|
|
26201
|
+
return { medium: { row } };
|
|
26146
26202
|
case 'LARGE':
|
|
26147
|
-
return { large: { row
|
|
26203
|
+
return { large: { row } };
|
|
26148
26204
|
case 'EXTRA_LARGE':
|
|
26149
|
-
return { extraLarge: { row
|
|
26205
|
+
return { extraLarge: { row } };
|
|
26150
26206
|
default:
|
|
26151
26207
|
return {};
|
|
26152
26208
|
}
|
|
@@ -26508,8 +26564,8 @@ class SmzBaseUiDefinitionBuilder {
|
|
|
26508
26564
|
this.uiDefinitionOptions.fieldsToOverwriteOrder = properties;
|
|
26509
26565
|
return this.that;
|
|
26510
26566
|
}
|
|
26511
|
-
useLayout(field, breakpoint,
|
|
26512
|
-
const template = getSmzTemplate(breakpoint,
|
|
26567
|
+
useLayout(field, breakpoint, columns = null) {
|
|
26568
|
+
const template = getSmzTemplate(breakpoint, columns);
|
|
26513
26569
|
this.uiDefinitionOptions.fieldsWithLayoutTemplates.push({ propertyName: field, template: template });
|
|
26514
26570
|
return this.that;
|
|
26515
26571
|
}
|
|
@@ -26562,8 +26618,6 @@ class SmzFormBuilder {
|
|
|
26562
26618
|
formId: generateGUID(),
|
|
26563
26619
|
groups: [],
|
|
26564
26620
|
template: {
|
|
26565
|
-
extraSmall: { horizontalAlignment: 'justify-between', verticalAlignment: 'items-start' },
|
|
26566
|
-
small: { horizontalAlignment: 'justify-between', verticalAlignment: 'items-start' },
|
|
26567
26621
|
...this.defaultConfig?.forms?.formTemplates
|
|
26568
26622
|
},
|
|
26569
26623
|
behaviors: {
|
|
@@ -26849,21 +26903,21 @@ const SmzPreset = {
|
|
|
26849
26903
|
okDependsOnValidation: false
|
|
26850
26904
|
},
|
|
26851
26905
|
dialogTemplate: {
|
|
26852
|
-
extraSmall: { row:
|
|
26853
|
-
small: { row:
|
|
26854
|
-
medium: { row:
|
|
26855
|
-
large: { row:
|
|
26856
|
-
extraLarge: { row:
|
|
26906
|
+
extraSmall: { row: 12 },
|
|
26907
|
+
small: { row: 10 },
|
|
26908
|
+
medium: { row: 8 },
|
|
26909
|
+
large: { row: 8 },
|
|
26910
|
+
extraLarge: { row: 6 },
|
|
26857
26911
|
}
|
|
26858
26912
|
},
|
|
26859
26913
|
features: {
|
|
26860
26914
|
formBehaviors: {},
|
|
26861
26915
|
featureTemplate: {
|
|
26862
|
-
extraSmall: { row:
|
|
26863
|
-
small: { row:
|
|
26864
|
-
medium: { row:
|
|
26865
|
-
large: { row:
|
|
26866
|
-
extraLarge: { row:
|
|
26916
|
+
extraSmall: { row: 12 },
|
|
26917
|
+
small: { row: 12 },
|
|
26918
|
+
medium: { row: 12 },
|
|
26919
|
+
large: { row: 12 },
|
|
26920
|
+
extraLarge: { row: 12 },
|
|
26867
26921
|
},
|
|
26868
26922
|
formGroupTemplate: {},
|
|
26869
26923
|
formControlTemplate: {}
|
|
@@ -26891,21 +26945,21 @@ const SmzPreset = {
|
|
|
26891
26945
|
okDependsOnValidation: false
|
|
26892
26946
|
},
|
|
26893
26947
|
dialogTemplate: {
|
|
26894
|
-
extraSmall: { row:
|
|
26895
|
-
small: { row:
|
|
26896
|
-
medium: { row:
|
|
26897
|
-
large: { row:
|
|
26898
|
-
extraLarge: { row:
|
|
26948
|
+
extraSmall: { row: 12 },
|
|
26949
|
+
small: { row: 10 },
|
|
26950
|
+
medium: { row: 8 },
|
|
26951
|
+
large: { row: 8 },
|
|
26952
|
+
extraLarge: { row: 6 },
|
|
26899
26953
|
}
|
|
26900
26954
|
},
|
|
26901
26955
|
features: {
|
|
26902
26956
|
formBehaviors: {},
|
|
26903
26957
|
featureTemplate: {
|
|
26904
|
-
extraSmall: { row:
|
|
26905
|
-
small: { row:
|
|
26906
|
-
medium: { row:
|
|
26907
|
-
large: { row:
|
|
26908
|
-
extraLarge: { row:
|
|
26958
|
+
extraSmall: { row: 12 },
|
|
26959
|
+
small: { row: 12 },
|
|
26960
|
+
medium: { row: 12 },
|
|
26961
|
+
large: { row: 12 },
|
|
26962
|
+
extraLarge: { row: 12 },
|
|
26909
26963
|
},
|
|
26910
26964
|
formGroupTemplate: {},
|
|
26911
26965
|
formControlTemplate: {}
|
|
@@ -26933,21 +26987,21 @@ const SmzPreset = {
|
|
|
26933
26987
|
okDependsOnValidation: false
|
|
26934
26988
|
},
|
|
26935
26989
|
dialogTemplate: {
|
|
26936
|
-
extraSmall: { row:
|
|
26937
|
-
small: { row:
|
|
26938
|
-
medium: { row:
|
|
26939
|
-
large: { row:
|
|
26940
|
-
extraLarge: { row:
|
|
26990
|
+
extraSmall: { row: 12 },
|
|
26991
|
+
small: { row: 12 },
|
|
26992
|
+
medium: { row: 10 },
|
|
26993
|
+
large: { row: 10 },
|
|
26994
|
+
extraLarge: { row: 10 },
|
|
26941
26995
|
}
|
|
26942
26996
|
},
|
|
26943
26997
|
features: {
|
|
26944
26998
|
formBehaviors: {},
|
|
26945
26999
|
featureTemplate: {
|
|
26946
|
-
extraSmall: { row:
|
|
26947
|
-
small: { row:
|
|
26948
|
-
medium: { row:
|
|
26949
|
-
large: { row:
|
|
26950
|
-
extraLarge: { row:
|
|
27000
|
+
extraSmall: { row: 12 },
|
|
27001
|
+
small: { row: 12 },
|
|
27002
|
+
medium: { row: 12 },
|
|
27003
|
+
large: { row: 12 },
|
|
27004
|
+
extraLarge: { row: 12 },
|
|
26951
27005
|
},
|
|
26952
27006
|
formGroupTemplate: {},
|
|
26953
27007
|
formControlTemplate: {}
|
|
@@ -26975,11 +27029,11 @@ const SmzPreset = {
|
|
|
26975
27029
|
okDependsOnValidation: false
|
|
26976
27030
|
},
|
|
26977
27031
|
dialogTemplate: {
|
|
26978
|
-
extraSmall: { row:
|
|
26979
|
-
small: { row:
|
|
26980
|
-
medium: { row:
|
|
26981
|
-
large: { row:
|
|
26982
|
-
extraLarge: { row:
|
|
27032
|
+
extraSmall: { row: 12 },
|
|
27033
|
+
small: { row: 10 },
|
|
27034
|
+
medium: { row: 8 },
|
|
27035
|
+
large: { row: 8 },
|
|
27036
|
+
extraLarge: { row: 6 },
|
|
26983
27037
|
}
|
|
26984
27038
|
},
|
|
26985
27039
|
features: {
|
|
@@ -26992,25 +27046,25 @@ const SmzPreset = {
|
|
|
26992
27046
|
showErrorsMethod: 'touched',
|
|
26993
27047
|
},
|
|
26994
27048
|
featureTemplate: {
|
|
26995
|
-
extraSmall: { row:
|
|
26996
|
-
small: { row:
|
|
26997
|
-
medium: { row:
|
|
26998
|
-
large: { row:
|
|
26999
|
-
extraLarge: { row:
|
|
27049
|
+
extraSmall: { row: 12 },
|
|
27050
|
+
small: { row: 12 },
|
|
27051
|
+
medium: { row: 12 },
|
|
27052
|
+
large: { row: 12 },
|
|
27053
|
+
extraLarge: { row: 12 },
|
|
27000
27054
|
},
|
|
27001
27055
|
formGroupTemplate: {
|
|
27002
|
-
extraSmall: { row:
|
|
27003
|
-
small: { row:
|
|
27004
|
-
medium: { row:
|
|
27005
|
-
large: { row:
|
|
27006
|
-
extraLarge: { row:
|
|
27056
|
+
extraSmall: { row: 12 },
|
|
27057
|
+
small: { row: 12 },
|
|
27058
|
+
medium: { row: 12 },
|
|
27059
|
+
large: { row: 12 },
|
|
27060
|
+
extraLarge: { row: 12 },
|
|
27007
27061
|
},
|
|
27008
27062
|
formControlTemplate: {
|
|
27009
|
-
extraSmall: { row:
|
|
27010
|
-
small: { row:
|
|
27011
|
-
medium: { row:
|
|
27012
|
-
large: { row:
|
|
27013
|
-
extraLarge: { row:
|
|
27063
|
+
extraSmall: { row: 12 },
|
|
27064
|
+
small: { row: 12 },
|
|
27065
|
+
medium: { row: 12 },
|
|
27066
|
+
large: { row: 12 },
|
|
27067
|
+
extraLarge: { row: 12 },
|
|
27014
27068
|
}
|
|
27015
27069
|
},
|
|
27016
27070
|
globals: {
|
|
@@ -27040,11 +27094,11 @@ const SmzPreset = {
|
|
|
27040
27094
|
saveName: 'SALVAR'
|
|
27041
27095
|
},
|
|
27042
27096
|
dialogTemplate: {
|
|
27043
|
-
extraSmall: { row:
|
|
27044
|
-
small: { row:
|
|
27045
|
-
medium: { row:
|
|
27046
|
-
large: { row:
|
|
27047
|
-
extraLarge: { row:
|
|
27097
|
+
extraSmall: { row: 12 },
|
|
27098
|
+
small: { row: 10 },
|
|
27099
|
+
medium: { row: 8 },
|
|
27100
|
+
large: { row: 8 },
|
|
27101
|
+
extraLarge: { row: 6 },
|
|
27048
27102
|
}
|
|
27049
27103
|
},
|
|
27050
27104
|
features: {
|
|
@@ -27057,25 +27111,25 @@ const SmzPreset = {
|
|
|
27057
27111
|
showErrorsMethod: 'dirty',
|
|
27058
27112
|
},
|
|
27059
27113
|
featureTemplate: {
|
|
27060
|
-
extraSmall: { row:
|
|
27061
|
-
small: { row:
|
|
27062
|
-
medium: { row:
|
|
27063
|
-
large: { row:
|
|
27064
|
-
extraLarge: { row:
|
|
27114
|
+
extraSmall: { row: 12 },
|
|
27115
|
+
small: { row: 12 },
|
|
27116
|
+
medium: { row: 12 },
|
|
27117
|
+
large: { row: 12 },
|
|
27118
|
+
extraLarge: { row: 12 },
|
|
27065
27119
|
},
|
|
27066
27120
|
formGroupTemplate: {
|
|
27067
|
-
extraSmall: { row:
|
|
27068
|
-
small: { row:
|
|
27069
|
-
medium: { row:
|
|
27070
|
-
large: { row:
|
|
27071
|
-
extraLarge: { row:
|
|
27121
|
+
extraSmall: { row: 12 },
|
|
27122
|
+
small: { row: 12 },
|
|
27123
|
+
medium: { row: 12 },
|
|
27124
|
+
large: { row: 12 },
|
|
27125
|
+
extraLarge: { row: 12 },
|
|
27072
27126
|
},
|
|
27073
27127
|
formControlTemplate: {
|
|
27074
|
-
extraSmall: { row:
|
|
27075
|
-
small: { row:
|
|
27076
|
-
medium: { row:
|
|
27077
|
-
large: { row:
|
|
27078
|
-
extraLarge: { row:
|
|
27128
|
+
extraSmall: { row: 12 },
|
|
27129
|
+
small: { row: 12 },
|
|
27130
|
+
medium: { row: 12 },
|
|
27131
|
+
large: { row: 12 },
|
|
27132
|
+
extraLarge: { row: 12 },
|
|
27079
27133
|
}
|
|
27080
27134
|
},
|
|
27081
27135
|
globals: {
|
|
@@ -27105,11 +27159,11 @@ const SmzPreset = {
|
|
|
27105
27159
|
okDependsOnValidation: false
|
|
27106
27160
|
},
|
|
27107
27161
|
dialogTemplate: {
|
|
27108
|
-
extraSmall: { row:
|
|
27109
|
-
small: { row:
|
|
27110
|
-
medium: { row:
|
|
27111
|
-
large: { row:
|
|
27112
|
-
extraLarge: { row:
|
|
27162
|
+
extraSmall: { row: 12 },
|
|
27163
|
+
small: { row: 10 },
|
|
27164
|
+
medium: { row: 8 },
|
|
27165
|
+
large: { row: 8 },
|
|
27166
|
+
extraLarge: { row: 6 },
|
|
27113
27167
|
}
|
|
27114
27168
|
},
|
|
27115
27169
|
features: {
|
|
@@ -27122,25 +27176,25 @@ const SmzPreset = {
|
|
|
27122
27176
|
showErrorsMethod: 'touched',
|
|
27123
27177
|
},
|
|
27124
27178
|
featureTemplate: {
|
|
27125
|
-
extraSmall: { row:
|
|
27126
|
-
small: { row:
|
|
27127
|
-
medium: { row:
|
|
27128
|
-
large: { row:
|
|
27129
|
-
extraLarge: { row:
|
|
27179
|
+
extraSmall: { row: 12 },
|
|
27180
|
+
small: { row: 12 },
|
|
27181
|
+
medium: { row: 12 },
|
|
27182
|
+
large: { row: 12 },
|
|
27183
|
+
extraLarge: { row: 12 },
|
|
27130
27184
|
},
|
|
27131
27185
|
formGroupTemplate: {
|
|
27132
|
-
extraSmall: { row:
|
|
27133
|
-
small: { row:
|
|
27134
|
-
medium: { row:
|
|
27135
|
-
large: { row:
|
|
27136
|
-
extraLarge: { row:
|
|
27186
|
+
extraSmall: { row: 12 },
|
|
27187
|
+
small: { row: 12 },
|
|
27188
|
+
medium: { row: 12 },
|
|
27189
|
+
large: { row: 12 },
|
|
27190
|
+
extraLarge: { row: 12 },
|
|
27137
27191
|
},
|
|
27138
27192
|
formControlTemplate: {
|
|
27139
|
-
extraSmall: { row:
|
|
27140
|
-
small: { row:
|
|
27141
|
-
medium: { row:
|
|
27142
|
-
large: { row:
|
|
27143
|
-
extraLarge: { row:
|
|
27193
|
+
extraSmall: { row: 12 },
|
|
27194
|
+
small: { row: 12 },
|
|
27195
|
+
medium: { row: 12 },
|
|
27196
|
+
large: { row: 12 },
|
|
27197
|
+
extraLarge: { row: 12 },
|
|
27144
27198
|
}
|
|
27145
27199
|
},
|
|
27146
27200
|
globals: {
|
|
@@ -27172,21 +27226,21 @@ const SmzPreset = {
|
|
|
27172
27226
|
cancelName: 'Não'
|
|
27173
27227
|
},
|
|
27174
27228
|
dialogTemplate: {
|
|
27175
|
-
extraSmall: { row:
|
|
27176
|
-
small: { row:
|
|
27177
|
-
medium: { row:
|
|
27178
|
-
large: { row:
|
|
27179
|
-
extraLarge: { row:
|
|
27229
|
+
extraSmall: { row: 12 },
|
|
27230
|
+
small: { row: 10 },
|
|
27231
|
+
medium: { row: 8 },
|
|
27232
|
+
large: { row: 8 },
|
|
27233
|
+
extraLarge: { row: 6 },
|
|
27180
27234
|
}
|
|
27181
27235
|
},
|
|
27182
27236
|
features: {
|
|
27183
27237
|
formBehaviors: {},
|
|
27184
27238
|
featureTemplate: {
|
|
27185
|
-
extraSmall: { row:
|
|
27186
|
-
small: { row:
|
|
27187
|
-
medium: { row:
|
|
27188
|
-
large: { row:
|
|
27189
|
-
extraLarge: { row:
|
|
27239
|
+
extraSmall: { row: 12 },
|
|
27240
|
+
small: { row: 12 },
|
|
27241
|
+
medium: { row: 12 },
|
|
27242
|
+
large: { row: 12 },
|
|
27243
|
+
extraLarge: { row: 12 },
|
|
27190
27244
|
},
|
|
27191
27245
|
formGroupTemplate: {},
|
|
27192
27246
|
formControlTemplate: {}
|
|
@@ -27218,21 +27272,21 @@ const SmzPreset = {
|
|
|
27218
27272
|
cancelClass: 'p-button-outlined',
|
|
27219
27273
|
},
|
|
27220
27274
|
dialogTemplate: {
|
|
27221
|
-
extraSmall: { row:
|
|
27222
|
-
small: { row:
|
|
27223
|
-
medium: { row:
|
|
27224
|
-
large: { row:
|
|
27225
|
-
extraLarge: { row:
|
|
27275
|
+
extraSmall: { row: 12 },
|
|
27276
|
+
small: { row: 10 },
|
|
27277
|
+
medium: { row: 8 },
|
|
27278
|
+
large: { row: 8 },
|
|
27279
|
+
extraLarge: { row: 6 },
|
|
27226
27280
|
}
|
|
27227
27281
|
},
|
|
27228
27282
|
features: {
|
|
27229
27283
|
formBehaviors: {},
|
|
27230
27284
|
featureTemplate: {
|
|
27231
|
-
extraSmall: { row:
|
|
27232
|
-
small: { row:
|
|
27233
|
-
medium: { row:
|
|
27234
|
-
large: { row:
|
|
27235
|
-
extraLarge: { row:
|
|
27285
|
+
extraSmall: { row: 12 },
|
|
27286
|
+
small: { row: 12 },
|
|
27287
|
+
medium: { row: 12 },
|
|
27288
|
+
large: { row: 12 },
|
|
27289
|
+
extraLarge: { row: 12 },
|
|
27236
27290
|
},
|
|
27237
27291
|
formGroupTemplate: {},
|
|
27238
27292
|
formControlTemplate: {}
|
|
@@ -27522,7 +27576,7 @@ class SmzDialogsService {
|
|
|
27522
27576
|
contentStyle: { 'overflow': 'auto', ...paddingStyle },
|
|
27523
27577
|
headerStyle: { ...paddingStyle, 'padding-bottom': '0em' },
|
|
27524
27578
|
footerStyle: { ...paddingStyle, 'padding-top': '0em' },
|
|
27525
|
-
styleClass: data.behaviors.showAsLinkedOverlayPanel ? data.overlayPanel.styleClass : SetTemplateClasses(data._context.dialogTemplate, ['row']),
|
|
27579
|
+
styleClass: data.behaviors.showAsLinkedOverlayPanel ? data.overlayPanel.styleClass : SetTemplateClasses(data._context.dialogTemplate, ['row'], 'width'),
|
|
27526
27580
|
footer: behaviors.showFooter ? '-' : null,
|
|
27527
27581
|
closable: behaviors.showCloseButton === true,
|
|
27528
27582
|
minimizable: behaviors.showMinimizeButton === true,
|
|
@@ -28034,8 +28088,8 @@ class SmzDialogHelpButtonBuilder {
|
|
|
28034
28088
|
.setTitle(this.helpTitle)
|
|
28035
28089
|
.allowMaximize()
|
|
28036
28090
|
.html([data])
|
|
28037
|
-
.setLayout('EXTRA_SMALL',
|
|
28038
|
-
.setLayout('EXTRA_LARGE',
|
|
28091
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
28092
|
+
.setLayout('EXTRA_LARGE', 6)
|
|
28039
28093
|
.hideFooter()
|
|
28040
28094
|
.build());
|
|
28041
28095
|
});
|
|
@@ -28045,8 +28099,8 @@ class SmzDialogHelpButtonBuilder {
|
|
|
28045
28099
|
.setTitle(this.helpTitle)
|
|
28046
28100
|
.allowMaximize()
|
|
28047
28101
|
.html([this.helpData])
|
|
28048
|
-
.setLayout('EXTRA_SMALL',
|
|
28049
|
-
.setLayout('EXTRA_LARGE',
|
|
28102
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
28103
|
+
.setLayout('EXTRA_LARGE', 6)
|
|
28050
28104
|
.hideFooter()
|
|
28051
28105
|
.build());
|
|
28052
28106
|
}
|
|
@@ -28266,9 +28320,9 @@ class SmzDialogBuilder extends SmzBuilderUtilities {
|
|
|
28266
28320
|
...this.defaultConfig?.dialogs?.builtInButtons
|
|
28267
28321
|
},
|
|
28268
28322
|
dialogTemplate: {
|
|
28269
|
-
extraSmall: { row:
|
|
28270
|
-
large: { row:
|
|
28271
|
-
extraLarge: { row:
|
|
28323
|
+
extraSmall: { row: 12 },
|
|
28324
|
+
large: { row: 8 },
|
|
28325
|
+
extraLarge: { row: 6 },
|
|
28272
28326
|
...this.defaultConfig?.dialogs?.dialogTemplate
|
|
28273
28327
|
},
|
|
28274
28328
|
presetId: null,
|
|
@@ -28381,8 +28435,8 @@ class SmzDialogBuilder extends SmzBuilderUtilities {
|
|
|
28381
28435
|
this.dialogState.callbacks.postProcessResponse = callback;
|
|
28382
28436
|
return this;
|
|
28383
28437
|
}
|
|
28384
|
-
setLayout(breakpoint,
|
|
28385
|
-
const template = getSmzTemplate(breakpoint,
|
|
28438
|
+
setLayout(breakpoint, columns = null) {
|
|
28439
|
+
const template = getSmzTemplate(breakpoint, columns);
|
|
28386
28440
|
this.dialogState.dialogTemplate = { ...this.dialogState.dialogTemplate, ...template };
|
|
28387
28441
|
return this;
|
|
28388
28442
|
}
|
|
@@ -28534,8 +28588,8 @@ class SmzDialogComponentBuilder {
|
|
|
28534
28588
|
this.feature.data.outputs.push({ output, callback });
|
|
28535
28589
|
return this;
|
|
28536
28590
|
}
|
|
28537
|
-
setLayout(breakpoint,
|
|
28538
|
-
const template = getSmzTemplate(breakpoint,
|
|
28591
|
+
setLayout(breakpoint, columns = null) {
|
|
28592
|
+
const template = getSmzTemplate(breakpoint, columns);
|
|
28539
28593
|
this.feature.template = { ...this.feature.template, ...template };
|
|
28540
28594
|
return this;
|
|
28541
28595
|
}
|
|
@@ -28550,8 +28604,8 @@ class SmzDialogFormBuilder {
|
|
|
28550
28604
|
this.dialogBuilderRef = dialogBuilderRef;
|
|
28551
28605
|
this.feature = feature;
|
|
28552
28606
|
}
|
|
28553
|
-
setLayout(breakpoint,
|
|
28554
|
-
const template = getSmzTemplate(breakpoint,
|
|
28607
|
+
setLayout(breakpoint, columns = null) {
|
|
28608
|
+
const template = getSmzTemplate(breakpoint, columns);
|
|
28555
28609
|
this.feature.template = { ...this.feature.template, ...template };
|
|
28556
28610
|
return this;
|
|
28557
28611
|
}
|
|
@@ -28571,8 +28625,8 @@ class SmzDialogTableBuilder {
|
|
|
28571
28625
|
this.dialogBuilderRef = dialogBuilderRef;
|
|
28572
28626
|
this.feature = feature;
|
|
28573
28627
|
}
|
|
28574
|
-
setLayout(breakpoint,
|
|
28575
|
-
const template = getSmzTemplate(breakpoint,
|
|
28628
|
+
setLayout(breakpoint, columns = null) {
|
|
28629
|
+
const template = getSmzTemplate(breakpoint, columns);
|
|
28576
28630
|
this.feature.template = { ...this.feature.template, ...template };
|
|
28577
28631
|
return this;
|
|
28578
28632
|
}
|
|
@@ -28778,8 +28832,8 @@ class SmzHelpDialogService {
|
|
|
28778
28832
|
.setTitle('Ajuda')
|
|
28779
28833
|
.allowMaximize()
|
|
28780
28834
|
.html([data])
|
|
28781
|
-
.setLayout('EXTRA_SMALL',
|
|
28782
|
-
.setLayout('EXTRA_LARGE',
|
|
28835
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
28836
|
+
.setLayout('EXTRA_LARGE', 6)
|
|
28783
28837
|
.hideFooter()
|
|
28784
28838
|
.build());
|
|
28785
28839
|
});
|
|
@@ -28908,10 +28962,10 @@ function showObjectDialog(title, event, confirmCallback = () => { }) {
|
|
|
28908
28962
|
GlobalInjector.instance.get(SmzDialogsService)
|
|
28909
28963
|
.open(new SmzDialogBuilder()
|
|
28910
28964
|
.setTitle(title)
|
|
28911
|
-
.setLayout('EXTRA_SMALL',
|
|
28912
|
-
.setLayout('MEDIUM',
|
|
28913
|
-
.setLayout('LARGE',
|
|
28914
|
-
.setLayout('EXTRA_LARGE',
|
|
28965
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
28966
|
+
.setLayout('MEDIUM', 6)
|
|
28967
|
+
.setLayout('LARGE', 6)
|
|
28968
|
+
.setLayout('EXTRA_LARGE', 6)
|
|
28915
28969
|
.closeOnEscape()
|
|
28916
28970
|
.html([new PrettyJsonPipe$1().transform(JSON.stringify(event), [true, 3])])
|
|
28917
28971
|
.buttons()
|
|
@@ -28926,10 +28980,10 @@ function showMarkdownDialog(title, message) {
|
|
|
28926
28980
|
GlobalInjector.instance.get(SmzDialogsService)
|
|
28927
28981
|
.open(new SmzDialogBuilder()
|
|
28928
28982
|
.setTitle(title)
|
|
28929
|
-
.setLayout('EXTRA_SMALL',
|
|
28930
|
-
.setLayout('MEDIUM',
|
|
28931
|
-
.setLayout('LARGE',
|
|
28932
|
-
.setLayout('EXTRA_LARGE',
|
|
28983
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
28984
|
+
.setLayout('MEDIUM', 6)
|
|
28985
|
+
.setLayout('LARGE', 6)
|
|
28986
|
+
.setLayout('EXTRA_LARGE', 6)
|
|
28933
28987
|
.closeOnEscape()
|
|
28934
28988
|
.markdown(message)
|
|
28935
28989
|
.hideFooter()
|
|
@@ -31756,9 +31810,9 @@ function buildShowSetUserRoleDialog(user, success) {
|
|
|
31756
31810
|
const roles = store.selectSnapshot(RolesSelectors.all);
|
|
31757
31811
|
dialogs.open(new SmzDialogBuilder()
|
|
31758
31812
|
.setTitle('Edição de Perfil')
|
|
31759
|
-
.setLayout('EXTRA_LARGE',
|
|
31760
|
-
.setLayout('MEDIUM',
|
|
31761
|
-
.setLayout('EXTRA_SMALL',
|
|
31813
|
+
.setLayout('EXTRA_LARGE', 4)
|
|
31814
|
+
.setLayout('MEDIUM', 6)
|
|
31815
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
31762
31816
|
.postProcessResponse(data => ({ ...data, roleIds: [data['roleId']] }))
|
|
31763
31817
|
.form()
|
|
31764
31818
|
.group()
|
|
@@ -31770,7 +31824,7 @@ function buildShowSetUserRoleDialog(user, success) {
|
|
|
31770
31824
|
.disable()
|
|
31771
31825
|
.group
|
|
31772
31826
|
.dropdown('role', 'Perfil', roles, getFirst(user.roles)?.id)
|
|
31773
|
-
.setLayout('EXTRA_SMALL',
|
|
31827
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
31774
31828
|
.validators().required().input
|
|
31775
31829
|
.group
|
|
31776
31830
|
.form
|
|
@@ -31796,9 +31850,9 @@ function buildShowSetUserRolesDialog(user, success) {
|
|
|
31796
31850
|
const roles = store.selectSnapshot(RolesSelectors.all);
|
|
31797
31851
|
dialogs.open(new SmzDialogBuilder()
|
|
31798
31852
|
.setTitle('Edição de Perfis')
|
|
31799
|
-
.setLayout('EXTRA_LARGE',
|
|
31800
|
-
.setLayout('MEDIUM',
|
|
31801
|
-
.setLayout('EXTRA_SMALL',
|
|
31853
|
+
.setLayout('EXTRA_LARGE', 4)
|
|
31854
|
+
.setLayout('MEDIUM', 6)
|
|
31855
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
31802
31856
|
.form()
|
|
31803
31857
|
.group()
|
|
31804
31858
|
.text('id', '', user.id).hide().group
|
|
@@ -31809,7 +31863,7 @@ function buildShowSetUserRolesDialog(user, success) {
|
|
|
31809
31863
|
.disable()
|
|
31810
31864
|
.group
|
|
31811
31865
|
.multiselect('role', 'Perfil', roles, user.roles.map(x => x.id))
|
|
31812
|
-
.setLayout('EXTRA_SMALL',
|
|
31866
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
31813
31867
|
.validators().required().input
|
|
31814
31868
|
.group
|
|
31815
31869
|
.form
|
|
@@ -31872,8 +31926,8 @@ class UserClaimsComponent {
|
|
|
31872
31926
|
addItemToTarget(event) {
|
|
31873
31927
|
this.dialogs.open(new SmzDialogBuilder()
|
|
31874
31928
|
.setTitle('Nível de Acesso')
|
|
31875
|
-
.setLayout('MEDIUM',
|
|
31876
|
-
.setLayout('EXTRA_SMALL',
|
|
31929
|
+
.setLayout('MEDIUM', 4)
|
|
31930
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
31877
31931
|
.message('Que tipo de acesso deseja dar para o claim(s) escolhido(s) ?')
|
|
31878
31932
|
.buttons()
|
|
31879
31933
|
.confirm('Permitir')
|
|
@@ -31907,11 +31961,11 @@ class UserClaimsComponent {
|
|
|
31907
31961
|
this.claims = claims.filter(claim => this.user?.claims.findIndex(u => u.id === claim.id) !== -1 ? false : true);
|
|
31908
31962
|
}
|
|
31909
31963
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: UserClaimsComponent, deps: [{ token: i1$3.Store }, { token: SmzDialogsService }], target: i0.ɵɵFactoryTarget.Component });
|
|
31910
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: UserClaimsComponent, isStandalone: false, selector: "app-user-claims", inputs: { username: "username" }, outputs: { desassociateClaim: "desassociateClaim" }, ngImport: i0, template: "<div class=\"ui-g form-group\">\n <div class=\"ui-g-12 ui-md-12\">\n <ui-pick-list [source]=\"claims\" [target]=\"targetClaims\" [responsive]=\"true\" sourceHeader=\"Claims dispon\u00EDveis\" targetHeader=\"Claims associados\" sourceFilterPlaceholder=\"Filtrar claims\" targetFilterPlaceholder=\"Filtrar claims\" filterBy=\"name\" [showSourceControls]=\"false\" [showTargetControls]=\"false\" [dragdrop]=\"true\" (movedToTarget)=\"addItemToTarget($event)\" (movedToSource)=\"addItemToSource($event)\" (movedAllToTarget)=\"addItemToTarget($event)\" (movedAllToSource)=\"addItemToSource($event)\">\n <ng-template let-item smzTemplate=\"item\">\n\n <!-- TARGET -->\n @if (item.access != null) {\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\n <div class=\"claim-access-type-indicator\">\n @if (item.access.id === 0) {\n <strong class=\"block-text\"><i class=\"fa-solid fa-lock\" [title]=\"item.access.name\"></i></strong>\n }\n @if (item.access.id === 1) {\n <strong class=\"allow-text\"><i class=\"fa-solid fa-lock-open\" [title]=\"item.access.name\"></i></strong>\n }\n </div>\n <div>{{ item.claim.name }}</div>\n </div>\n <div></div>\n } @else {\n {{ item.description }}\n }\n\n <!-- SOURCE -->\n\n </ng-template>\n </ui-pick-list>\n </div>\n</div>", styles: ["app-user-claims .nameInput{height:60px}app-user-claims .p-picklist .p-picklist-filter-container{padding-right:30px!important}app-user-claims .p-picklist .p-picklist-filter-container .p-picklist-filter-icon{right:10px!important;left:unset}app-user-claims .p-picklist .p-picklist-list{height:300px}app-user-claims .p-picklist.p-picklist-responsive .p-picklist-listwrapper.p-picklist-listwrapper-nocontrols{width:50%}app-user-claims .claim-access-type-indicator{float:right}app-user-claims .allow-text{color:#1a9c2a}app-user-claims .block-text{color:#9c1a1a}\n"], dependencies: [{ kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: i2.SmzPickListComponent, selector: "ui-pick-list", inputs: ["source", "target", "sourceHeader", "targetHeader", "sourceFilterPlaceholder", "targetFilterPlaceholder", "filterBy", "dragdrop", "responsive", "listStyle", "showSourceControls", "showTargetControls"], outputs: ["movedToTarget", "movedToSource", "movedAllToTarget", "movedAllToSource"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
31964
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: UserClaimsComponent, isStandalone: false, selector: "app-user-claims", inputs: { username: "username" }, outputs: { desassociateClaim: "desassociateClaim" }, ngImport: i0, template: "<div class=\"ui-g form-group\">\r\n <div class=\"ui-g-12 ui-md-12\">\r\n <ui-pick-list [source]=\"claims\" [target]=\"targetClaims\" [responsive]=\"true\" sourceHeader=\"Claims dispon\u00EDveis\" targetHeader=\"Claims associados\" sourceFilterPlaceholder=\"Filtrar claims\" targetFilterPlaceholder=\"Filtrar claims\" filterBy=\"name\" [showSourceControls]=\"false\" [showTargetControls]=\"false\" [dragdrop]=\"true\" (movedToTarget)=\"addItemToTarget($event)\" (movedToSource)=\"addItemToSource($event)\" (movedAllToTarget)=\"addItemToTarget($event)\" (movedAllToSource)=\"addItemToSource($event)\">\r\n <ng-template let-item smzTemplate=\"item\">\r\n\r\n <!-- TARGET -->\r\n @if (item.access != null) {\r\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\r\n <div class=\"claim-access-type-indicator\">\r\n @if (item.access.id === 0) {\r\n <strong class=\"block-text\"><i class=\"fa-solid fa-lock\" [title]=\"item.access.name\"></i></strong>\r\n }\r\n @if (item.access.id === 1) {\r\n <strong class=\"allow-text\"><i class=\"fa-solid fa-lock-open\" [title]=\"item.access.name\"></i></strong>\r\n }\r\n </div>\r\n <div>{{ item.claim.name }}</div>\r\n </div>\r\n <div></div>\r\n } @else {\r\n {{ item.description }}\r\n }\r\n\r\n <!-- SOURCE -->\r\n\r\n </ng-template>\r\n </ui-pick-list>\r\n </div>\r\n</div>", styles: ["app-user-claims .nameInput{height:60px}app-user-claims .p-picklist .p-picklist-filter-container{padding-right:30px!important}app-user-claims .p-picklist .p-picklist-filter-container .p-picklist-filter-icon{right:10px!important;left:unset}app-user-claims .p-picklist .p-picklist-list{height:300px}app-user-claims .p-picklist.p-picklist-responsive .p-picklist-listwrapper.p-picklist-listwrapper-nocontrols{width:50%}app-user-claims .claim-access-type-indicator{float:right}app-user-claims .allow-text{color:#1a9c2a}app-user-claims .block-text{color:#9c1a1a}\n"], dependencies: [{ kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: i2.SmzPickListComponent, selector: "ui-pick-list", inputs: ["source", "target", "sourceHeader", "targetHeader", "sourceFilterPlaceholder", "targetFilterPlaceholder", "filterBy", "dragdrop", "responsive", "listStyle", "showSourceControls", "showTargetControls"], outputs: ["movedToTarget", "movedToSource", "movedAllToTarget", "movedAllToSource"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
31911
31965
|
}
|
|
31912
31966
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: UserClaimsComponent, decorators: [{
|
|
31913
31967
|
type: Component,
|
|
31914
|
-
args: [{ selector: 'app-user-claims', encapsulation: ViewEncapsulation.None, standalone: false, template: "<div class=\"ui-g form-group\">\n <div class=\"ui-g-12 ui-md-12\">\n <ui-pick-list [source]=\"claims\" [target]=\"targetClaims\" [responsive]=\"true\" sourceHeader=\"Claims dispon\u00EDveis\" targetHeader=\"Claims associados\" sourceFilterPlaceholder=\"Filtrar claims\" targetFilterPlaceholder=\"Filtrar claims\" filterBy=\"name\" [showSourceControls]=\"false\" [showTargetControls]=\"false\" [dragdrop]=\"true\" (movedToTarget)=\"addItemToTarget($event)\" (movedToSource)=\"addItemToSource($event)\" (movedAllToTarget)=\"addItemToTarget($event)\" (movedAllToSource)=\"addItemToSource($event)\">\n <ng-template let-item smzTemplate=\"item\">\n\n <!-- TARGET -->\n @if (item.access != null) {\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\n <div class=\"claim-access-type-indicator\">\n @if (item.access.id === 0) {\n <strong class=\"block-text\"><i class=\"fa-solid fa-lock\" [title]=\"item.access.name\"></i></strong>\n }\n @if (item.access.id === 1) {\n <strong class=\"allow-text\"><i class=\"fa-solid fa-lock-open\" [title]=\"item.access.name\"></i></strong>\n }\n </div>\n <div>{{ item.claim.name }}</div>\n </div>\n <div></div>\n } @else {\n {{ item.description }}\n }\n\n <!-- SOURCE -->\n\n </ng-template>\n </ui-pick-list>\n </div>\n</div>", styles: ["app-user-claims .nameInput{height:60px}app-user-claims .p-picklist .p-picklist-filter-container{padding-right:30px!important}app-user-claims .p-picklist .p-picklist-filter-container .p-picklist-filter-icon{right:10px!important;left:unset}app-user-claims .p-picklist .p-picklist-list{height:300px}app-user-claims .p-picklist.p-picklist-responsive .p-picklist-listwrapper.p-picklist-listwrapper-nocontrols{width:50%}app-user-claims .claim-access-type-indicator{float:right}app-user-claims .allow-text{color:#1a9c2a}app-user-claims .block-text{color:#9c1a1a}\n"] }]
|
|
31968
|
+
args: [{ selector: 'app-user-claims', encapsulation: ViewEncapsulation.None, standalone: false, template: "<div class=\"ui-g form-group\">\r\n <div class=\"ui-g-12 ui-md-12\">\r\n <ui-pick-list [source]=\"claims\" [target]=\"targetClaims\" [responsive]=\"true\" sourceHeader=\"Claims dispon\u00EDveis\" targetHeader=\"Claims associados\" sourceFilterPlaceholder=\"Filtrar claims\" targetFilterPlaceholder=\"Filtrar claims\" filterBy=\"name\" [showSourceControls]=\"false\" [showTargetControls]=\"false\" [dragdrop]=\"true\" (movedToTarget)=\"addItemToTarget($event)\" (movedToSource)=\"addItemToSource($event)\" (movedAllToTarget)=\"addItemToTarget($event)\" (movedAllToSource)=\"addItemToSource($event)\">\r\n <ng-template let-item smzTemplate=\"item\">\r\n\r\n <!-- TARGET -->\r\n @if (item.access != null) {\r\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\r\n <div class=\"claim-access-type-indicator\">\r\n @if (item.access.id === 0) {\r\n <strong class=\"block-text\"><i class=\"fa-solid fa-lock\" [title]=\"item.access.name\"></i></strong>\r\n }\r\n @if (item.access.id === 1) {\r\n <strong class=\"allow-text\"><i class=\"fa-solid fa-lock-open\" [title]=\"item.access.name\"></i></strong>\r\n }\r\n </div>\r\n <div>{{ item.claim.name }}</div>\r\n </div>\r\n <div></div>\r\n } @else {\r\n {{ item.description }}\r\n }\r\n\r\n <!-- SOURCE -->\r\n\r\n </ng-template>\r\n </ui-pick-list>\r\n </div>\r\n</div>", styles: ["app-user-claims .nameInput{height:60px}app-user-claims .p-picklist .p-picklist-filter-container{padding-right:30px!important}app-user-claims .p-picklist .p-picklist-filter-container .p-picklist-filter-icon{right:10px!important;left:unset}app-user-claims .p-picklist .p-picklist-list{height:300px}app-user-claims .p-picklist.p-picklist-responsive .p-picklist-listwrapper.p-picklist-listwrapper-nocontrols{width:50%}app-user-claims .claim-access-type-indicator{float:right}app-user-claims .allow-text{color:#1a9c2a}app-user-claims .block-text{color:#9c1a1a}\n"] }]
|
|
31915
31969
|
}], ctorParameters: () => [{ type: i1$3.Store }, { type: SmzDialogsService }], propDecorators: { username: [{
|
|
31916
31970
|
type: Input
|
|
31917
31971
|
}], desassociateClaim: [{
|
|
@@ -31924,9 +31978,9 @@ function showUpdateUserClaimsDialog(user) {
|
|
|
31924
31978
|
const helpService = GlobalInjector.instance.get(SmzHelpDialogService);
|
|
31925
31979
|
dialogs.open(new SmzDialogBuilder()
|
|
31926
31980
|
.setTitle('Edição de Permissões de Acesso')
|
|
31927
|
-
.setLayout('EXTRA_LARGE',
|
|
31928
|
-
.setLayout('MEDIUM',
|
|
31929
|
-
.setLayout('EXTRA_SMALL',
|
|
31981
|
+
.setLayout('EXTRA_LARGE', 8)
|
|
31982
|
+
.setLayout('MEDIUM', 10)
|
|
31983
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
31930
31984
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any -- builder accepts ComponentDataBase | Record; component class is Type
|
|
31931
31985
|
.component(UserClaimsComponent)
|
|
31932
31986
|
.addInput('username', user.username)
|
|
@@ -32134,11 +32188,11 @@ class UsersPageComponent {
|
|
|
32134
32188
|
this.cdr.markForCheck();
|
|
32135
32189
|
}
|
|
32136
32190
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: UsersPageComponent, deps: [{ token: i1$3.Store }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
32137
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: UsersPageComponent, isStandalone: false, selector: "smz-ui-users-page", ngImport: i0, template: "\n<ng-container *ngVar=\"(users$ | async) as users\">\n\n <smz-ui-table #smzdt [items]=\"users\" [state]=\"tableState\" [loading]=\"false\">\n\n <ng-template smzTemplate=\"caption\" let-primeTable>\n @for (action of (uiConfig.rbkUtils.authorization.users.pageActions | smzFlattenMenu : null); track action) {\n @if (action.visible) {\n <button smzButton type=\"button\" smzMenuItemAction [item]=\"action\" [label]=\"action.label\" [icon]=\"action.icon\" [styleClass]=\"action.styleClass\" [disabled]=\"action.disabled\"></button>\n }\n }\n\n @if (uiConfig.rbkUtils.authorization.users.removalBehavior === 'deactivation') {\n <ui-select-button appendTo=\"body\" [options]=\"viewOptions\" [(ngModel)]=\"selectedView\" (changed)=\"handleViewOptionChange($event.value)\" optionLabel=\"label\" optionValue=\"value\">\n </ui-select-button>\n }\n\n </ng-template>\n\n <!-- CONTE\u00DADOS COM OVERRIDE -->\n <ng-template smzTemplate=\"content\" let-item let-col=\"col\">\n\n @switch (col.field) {\n @case ('displayName') {\n <div class=\"grid grid-nogutter items-center gap-3 justify-start\">\n <!-- CONTROLE DE ACESSO N\u00C3O ENCONTROU O IDENTIFICADOR DO USU\u00C1RIO -->\n @if (item.avatar == null) {\n <img\n [src]=\"uiConfig.rbkUtils.authorization.users.avatarPlaceholderPath\"\n class=\"w-14 align-middle\"\n />\n }\n <!-- USU\u00C1RIO COM AVATAR INFORMADO PELO CONTROLE DE ACESSO -->\n @if (item.avatar != null) {\n <img\n [src]=\"item.avatar\"\n (error)=\"handleMissingImage($event, item.name, item.avatar)\"\n class=\"w-14 align-middle\"\n />\n }\n <span>{{ item.displayName }}</span>\n </div>\n }\n @case ('role.name') {\n {{ item.role?.name }}\n }\n }\n\n </ng-template>\n\n </smz-ui-table>\n\n</ng-container>", dependencies: [{ kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "component", type: i2.SmzSelectButtonComponent, selector: "ui-select-button", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "multiple", "allowEmpty", "size", "styleClass", "appendTo"], outputs: ["changed"] }, { kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "directive", type: SmzMenuItemActionsDirective, selector: "[smzMenuItemAction]", inputs: ["item", "data"], outputs: ["collapse"] }, { kind: "directive", type: NgVar, selector: "[ngVar]", inputs: ["ngVar"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: SmzFlattenMenuPipe, name: "smzFlattenMenu" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
32191
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: UsersPageComponent, isStandalone: false, selector: "smz-ui-users-page", ngImport: i0, template: "\r\n<ng-container *ngVar=\"(users$ | async) as users\">\r\n\r\n <smz-ui-table #smzdt [items]=\"users\" [state]=\"tableState\" [loading]=\"false\">\r\n\r\n <ng-template smzTemplate=\"caption\" let-primeTable>\r\n @for (action of (uiConfig.rbkUtils.authorization.users.pageActions | smzFlattenMenu : null); track action) {\r\n @if (action.visible) {\r\n <button smzButton type=\"button\" smzMenuItemAction [item]=\"action\" [label]=\"action.label\" [icon]=\"action.icon\" [styleClass]=\"action.styleClass\" [disabled]=\"action.disabled\"></button>\r\n }\r\n }\r\n\r\n @if (uiConfig.rbkUtils.authorization.users.removalBehavior === 'deactivation') {\r\n <ui-select-button appendTo=\"body\" [options]=\"viewOptions\" [(ngModel)]=\"selectedView\" (changed)=\"handleViewOptionChange($event.value)\" optionLabel=\"label\" optionValue=\"value\">\r\n </ui-select-button>\r\n }\r\n\r\n </ng-template>\r\n\r\n <!-- CONTE\u00DADOS COM OVERRIDE -->\r\n <ng-template smzTemplate=\"content\" let-item let-col=\"col\">\r\n\r\n @switch (col.field) {\r\n @case ('displayName') {\r\n <div class=\"grid grid-nogutter items-center gap-3 justify-start\">\r\n <!-- CONTROLE DE ACESSO N\u00C3O ENCONTROU O IDENTIFICADOR DO USU\u00C1RIO -->\r\n @if (item.avatar == null) {\r\n <img\r\n [src]=\"uiConfig.rbkUtils.authorization.users.avatarPlaceholderPath\"\r\n class=\"w-14 align-middle\"\r\n />\r\n }\r\n <!-- USU\u00C1RIO COM AVATAR INFORMADO PELO CONTROLE DE ACESSO -->\r\n @if (item.avatar != null) {\r\n <img\r\n [src]=\"item.avatar\"\r\n (error)=\"handleMissingImage($event, item.name, item.avatar)\"\r\n class=\"w-14 align-middle\"\r\n />\r\n }\r\n <span>{{ item.displayName }}</span>\r\n </div>\r\n }\r\n @case ('role.name') {\r\n {{ item.role?.name }}\r\n }\r\n }\r\n\r\n </ng-template>\r\n\r\n </smz-ui-table>\r\n\r\n</ng-container>", dependencies: [{ kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "component", type: i2.SmzSelectButtonComponent, selector: "ui-select-button", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "multiple", "allowEmpty", "size", "styleClass", "appendTo"], outputs: ["changed"] }, { kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "validChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "directive", type: SmzMenuItemActionsDirective, selector: "[smzMenuItemAction]", inputs: ["item", "data"], outputs: ["collapse"] }, { kind: "directive", type: NgVar, selector: "[ngVar]", inputs: ["ngVar"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: SmzFlattenMenuPipe, name: "smzFlattenMenu" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
32138
32192
|
}
|
|
32139
32193
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: UsersPageComponent, decorators: [{
|
|
32140
32194
|
type: Component,
|
|
32141
|
-
args: [{ selector: 'smz-ui-users-page', changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, template: "\n<ng-container *ngVar=\"(users$ | async) as users\">\n\n <smz-ui-table #smzdt [items]=\"users\" [state]=\"tableState\" [loading]=\"false\">\n\n <ng-template smzTemplate=\"caption\" let-primeTable>\n @for (action of (uiConfig.rbkUtils.authorization.users.pageActions | smzFlattenMenu : null); track action) {\n @if (action.visible) {\n <button smzButton type=\"button\" smzMenuItemAction [item]=\"action\" [label]=\"action.label\" [icon]=\"action.icon\" [styleClass]=\"action.styleClass\" [disabled]=\"action.disabled\"></button>\n }\n }\n\n @if (uiConfig.rbkUtils.authorization.users.removalBehavior === 'deactivation') {\n <ui-select-button appendTo=\"body\" [options]=\"viewOptions\" [(ngModel)]=\"selectedView\" (changed)=\"handleViewOptionChange($event.value)\" optionLabel=\"label\" optionValue=\"value\">\n </ui-select-button>\n }\n\n </ng-template>\n\n <!-- CONTE\u00DADOS COM OVERRIDE -->\n <ng-template smzTemplate=\"content\" let-item let-col=\"col\">\n\n @switch (col.field) {\n @case ('displayName') {\n <div class=\"grid grid-nogutter items-center gap-3 justify-start\">\n <!-- CONTROLE DE ACESSO N\u00C3O ENCONTROU O IDENTIFICADOR DO USU\u00C1RIO -->\n @if (item.avatar == null) {\n <img\n [src]=\"uiConfig.rbkUtils.authorization.users.avatarPlaceholderPath\"\n class=\"w-14 align-middle\"\n />\n }\n <!-- USU\u00C1RIO COM AVATAR INFORMADO PELO CONTROLE DE ACESSO -->\n @if (item.avatar != null) {\n <img\n [src]=\"item.avatar\"\n (error)=\"handleMissingImage($event, item.name, item.avatar)\"\n class=\"w-14 align-middle\"\n />\n }\n <span>{{ item.displayName }}</span>\n </div>\n }\n @case ('role.name') {\n {{ item.role?.name }}\n }\n }\n\n </ng-template>\n\n </smz-ui-table>\n\n</ng-container>" }]
|
|
32195
|
+
args: [{ selector: 'smz-ui-users-page', changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, template: "\r\n<ng-container *ngVar=\"(users$ | async) as users\">\r\n\r\n <smz-ui-table #smzdt [items]=\"users\" [state]=\"tableState\" [loading]=\"false\">\r\n\r\n <ng-template smzTemplate=\"caption\" let-primeTable>\r\n @for (action of (uiConfig.rbkUtils.authorization.users.pageActions | smzFlattenMenu : null); track action) {\r\n @if (action.visible) {\r\n <button smzButton type=\"button\" smzMenuItemAction [item]=\"action\" [label]=\"action.label\" [icon]=\"action.icon\" [styleClass]=\"action.styleClass\" [disabled]=\"action.disabled\"></button>\r\n }\r\n }\r\n\r\n @if (uiConfig.rbkUtils.authorization.users.removalBehavior === 'deactivation') {\r\n <ui-select-button appendTo=\"body\" [options]=\"viewOptions\" [(ngModel)]=\"selectedView\" (changed)=\"handleViewOptionChange($event.value)\" optionLabel=\"label\" optionValue=\"value\">\r\n </ui-select-button>\r\n }\r\n\r\n </ng-template>\r\n\r\n <!-- CONTE\u00DADOS COM OVERRIDE -->\r\n <ng-template smzTemplate=\"content\" let-item let-col=\"col\">\r\n\r\n @switch (col.field) {\r\n @case ('displayName') {\r\n <div class=\"grid grid-nogutter items-center gap-3 justify-start\">\r\n <!-- CONTROLE DE ACESSO N\u00C3O ENCONTROU O IDENTIFICADOR DO USU\u00C1RIO -->\r\n @if (item.avatar == null) {\r\n <img\r\n [src]=\"uiConfig.rbkUtils.authorization.users.avatarPlaceholderPath\"\r\n class=\"w-14 align-middle\"\r\n />\r\n }\r\n <!-- USU\u00C1RIO COM AVATAR INFORMADO PELO CONTROLE DE ACESSO -->\r\n @if (item.avatar != null) {\r\n <img\r\n [src]=\"item.avatar\"\r\n (error)=\"handleMissingImage($event, item.name, item.avatar)\"\r\n class=\"w-14 align-middle\"\r\n />\r\n }\r\n <span>{{ item.displayName }}</span>\r\n </div>\r\n }\r\n @case ('role.name') {\r\n {{ item.role?.name }}\r\n }\r\n }\r\n\r\n </ng-template>\r\n\r\n </smz-ui-table>\r\n\r\n</ng-container>" }]
|
|
32142
32196
|
}], ctorParameters: () => [{ type: i1$3.Store }, { type: i0.ChangeDetectorRef }] });
|
|
32143
32197
|
|
|
32144
32198
|
const routes$7 = [
|
|
@@ -32216,9 +32270,9 @@ function UpdateClaimDialog(claim) {
|
|
|
32216
32270
|
const store = GlobalInjector.instance.get(Store);
|
|
32217
32271
|
return new SmzDialogBuilder()
|
|
32218
32272
|
.setTitle('Renomear Permissão de Acesso')
|
|
32219
|
-
.setLayout('LARGE',
|
|
32220
|
-
.setLayout('MEDIUM',
|
|
32221
|
-
.setLayout('SMALL',
|
|
32273
|
+
.setLayout('LARGE', 4)
|
|
32274
|
+
.setLayout('MEDIUM', 6)
|
|
32275
|
+
.setLayout('SMALL', 12)
|
|
32222
32276
|
.confirmOnEnter()
|
|
32223
32277
|
.closeOnEscape()
|
|
32224
32278
|
.form()
|
|
@@ -32247,9 +32301,9 @@ function CreateClaimDialog() {
|
|
|
32247
32301
|
const store = GlobalInjector.instance.get(Store);
|
|
32248
32302
|
return new SmzDialogBuilder()
|
|
32249
32303
|
.setTitle('Criar Permissão de Acesso')
|
|
32250
|
-
.setLayout('LARGE',
|
|
32251
|
-
.setLayout('MEDIUM',
|
|
32252
|
-
.setLayout('SMALL',
|
|
32304
|
+
.setLayout('LARGE', 4)
|
|
32305
|
+
.setLayout('MEDIUM', 6)
|
|
32306
|
+
.setLayout('SMALL', 12)
|
|
32253
32307
|
.confirmOnEnter()
|
|
32254
32308
|
.closeOnEscape()
|
|
32255
32309
|
.form()
|
|
@@ -32344,7 +32398,7 @@ class ClaimsPageComponent {
|
|
|
32344
32398
|
this.dialogs.open(CreateClaimDialog());
|
|
32345
32399
|
}
|
|
32346
32400
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: ClaimsPageComponent, deps: [{ token: i1$3.Store }, { token: SmzDialogsService }], target: i0.ɵɵFactoryTarget.Component });
|
|
32347
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.1", type: ClaimsPageComponent, isStandalone: false, selector: "app-claims-page", ngImport: i0, template: "<smz-ui-table [items]=\"claims$ | async\" [state]=\"tableState\">\n\n <ng-template smzTemplate=\"caption\">\n <button smzButton type=\"button\" class=\"mx-1\" label=\"CRIAR\" (click)=\"showCreationDialog()\" severity=\"primary\"></button>\n </ng-template>\n\n</smz-ui-table>\n", dependencies: [{ kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
32401
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.1", type: ClaimsPageComponent, isStandalone: false, selector: "app-claims-page", ngImport: i0, template: "<smz-ui-table [items]=\"claims$ | async\" [state]=\"tableState\">\n\n <ng-template smzTemplate=\"caption\">\n <button smzButton type=\"button\" class=\"mx-1\" label=\"CRIAR\" (click)=\"showCreationDialog()\" severity=\"primary\"></button>\n </ng-template>\n\n</smz-ui-table>\n", dependencies: [{ kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "validChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
32348
32402
|
}
|
|
32349
32403
|
__decorate([
|
|
32350
32404
|
Confirmable('Tem certeza de que deseja excluir essa permissão de acesso ?', 'Atenção', true)
|
|
@@ -32410,9 +32464,9 @@ function UpdateRoleDialog(claim) {
|
|
|
32410
32464
|
const store = GlobalInjector.instance.get(Store);
|
|
32411
32465
|
return new SmzDialogBuilder()
|
|
32412
32466
|
.setTitle('Renomea Perfil')
|
|
32413
|
-
.setLayout('LARGE',
|
|
32414
|
-
.setLayout('MEDIUM',
|
|
32415
|
-
.setLayout('SMALL',
|
|
32467
|
+
.setLayout('LARGE', 4)
|
|
32468
|
+
.setLayout('MEDIUM', 6)
|
|
32469
|
+
.setLayout('SMALL', 12)
|
|
32416
32470
|
.confirmOnEnter()
|
|
32417
32471
|
.closeOnEscape()
|
|
32418
32472
|
.form()
|
|
@@ -32443,9 +32497,9 @@ function UpdateRoleClaimsDialog(role) {
|
|
|
32443
32497
|
const claims = store.selectSnapshot(ClaimsSelectors.all).map(x => ({ id: x.id, name: x.description }));
|
|
32444
32498
|
return new SmzDialogBuilder()
|
|
32445
32499
|
.setTitle('Editar permissões de acesso do perfil')
|
|
32446
|
-
.setLayout('LARGE',
|
|
32447
|
-
.setLayout('MEDIUM',
|
|
32448
|
-
.setLayout('SMALL',
|
|
32500
|
+
.setLayout('LARGE', 4)
|
|
32501
|
+
.setLayout('MEDIUM', 6)
|
|
32502
|
+
.setLayout('SMALL', 12)
|
|
32449
32503
|
.confirmOnEnter()
|
|
32450
32504
|
.closeOnEscape()
|
|
32451
32505
|
.form()
|
|
@@ -32478,9 +32532,9 @@ function CreateRoleDialog() {
|
|
|
32478
32532
|
const store = GlobalInjector.instance.get(Store);
|
|
32479
32533
|
return new SmzDialogBuilder()
|
|
32480
32534
|
.setTitle('Criar Perfil')
|
|
32481
|
-
.setLayout('LARGE',
|
|
32482
|
-
.setLayout('MEDIUM',
|
|
32483
|
-
.setLayout('SMALL',
|
|
32535
|
+
.setLayout('LARGE', 4)
|
|
32536
|
+
.setLayout('MEDIUM', 6)
|
|
32537
|
+
.setLayout('SMALL', 12)
|
|
32484
32538
|
.confirmOnEnter()
|
|
32485
32539
|
.closeOnEscape()
|
|
32486
32540
|
.form()
|
|
@@ -32514,9 +32568,9 @@ function showRoleClaimsDialog(role) {
|
|
|
32514
32568
|
`;
|
|
32515
32569
|
dialogs.open(new SmzDialogBuilder()
|
|
32516
32570
|
.setTitle('Permissões')
|
|
32517
|
-
.setLayout('LARGE',
|
|
32518
|
-
.setLayout('MEDIUM',
|
|
32519
|
-
.setLayout('SMALL',
|
|
32571
|
+
.setLayout('LARGE', 4)
|
|
32572
|
+
.setLayout('MEDIUM', 6)
|
|
32573
|
+
.setLayout('SMALL', 12)
|
|
32520
32574
|
.confirmOnEnter()
|
|
32521
32575
|
.closeOnEscape()
|
|
32522
32576
|
.message(html)
|
|
@@ -32615,14 +32669,14 @@ class RolesPageComponent {
|
|
|
32615
32669
|
this.dialogs.open(CreateRoleDialog());
|
|
32616
32670
|
}
|
|
32617
32671
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: RolesPageComponent, deps: [{ token: i1$3.Store }, { token: SmzDialogsService }], target: i0.ɵɵFactoryTarget.Component });
|
|
32618
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: RolesPageComponent, isStandalone: false, selector: "app-roles-page", ngImport: i0, template: "<smz-ui-table [items]=\"roles$ | async\" [state]=\"tableState\">\n\n <ng-template smzTemplate=\"caption\">\n <button smzButton type=\"button\" class=\"mx-1\" label=\"CRIAR\" (click)=\"showCreationDialog()\" [disabled]=\"!(canCreateClaims | rbkCanAccessAny)\" severity=\"primary\"></button>\n </ng-template>\n\n <!-- CONTE\u00DADOS COM OVERRIDE -->\n <ng-template smzTemplate=\"content\" let-item let-col=\"col\">\n\n @switch (col.field) {\n @case ('claims') {\n <div class=\"grid grid-nogutter items-start justify-start flex-col gap-1\">\n <ng-container *ngVar=\"(item.claims | smzInitial : 3) as limitedClaims\">\n <!-- <div [innerHTML]=\"limitedClaims | prettyjson\"></div> -->\n <ul class=\"list-disc\">\n @for (claim of limitedClaims; track claim) {\n <li class=\"\">{{ $any(claim).name }}</li>\n }\n @if (item.claims.length > 3) {\n <li>(...)</li>\n }\n </ul>\n @if (item.claims.length > 3) {\n <button\n type=\"button\"\n (click)=\"onShowRoleClaimsDialog(item)\"\n class=\"block rounded-md bg-amber-400 px-2.5 py-1.5 text-center text-sm font-semibold text-black shadow-sm hover:bg-amber-300 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-amber-500\">\n <i class=\"fa-solid fa-circle-info mr-2\"></i>Ver mais\n </button>\n }\n </ng-container>\n </div>\n }\n }\n\n </ng-template>\n\n</smz-ui-table>\n", dependencies: [{ kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "directive", type: NgVar, selector: "[ngVar]", inputs: ["ngVar"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: SmzInitialPipe, name: "smzInitial" }, { kind: "pipe", type: RbkCanAccessAnyPipe, name: "rbkCanAccessAny" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
32672
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: RolesPageComponent, isStandalone: false, selector: "app-roles-page", ngImport: i0, template: "<smz-ui-table [items]=\"roles$ | async\" [state]=\"tableState\">\r\n\r\n <ng-template smzTemplate=\"caption\">\r\n <button smzButton type=\"button\" class=\"mx-1\" label=\"CRIAR\" (click)=\"showCreationDialog()\" [disabled]=\"!(canCreateClaims | rbkCanAccessAny)\" severity=\"primary\"></button>\r\n </ng-template>\r\n\r\n <!-- CONTE\u00DADOS COM OVERRIDE -->\r\n <ng-template smzTemplate=\"content\" let-item let-col=\"col\">\r\n\r\n @switch (col.field) {\r\n @case ('claims') {\r\n <div class=\"grid grid-nogutter items-start justify-start flex-col gap-1\">\r\n <ng-container *ngVar=\"(item.claims | smzInitial : 3) as limitedClaims\">\r\n <!-- <div [innerHTML]=\"limitedClaims | prettyjson\"></div> -->\r\n <ul class=\"list-disc\">\r\n @for (claim of limitedClaims; track claim) {\r\n <li class=\"\">{{ $any(claim).name }}</li>\r\n }\r\n @if (item.claims.length > 3) {\r\n <li>(...)</li>\r\n }\r\n </ul>\r\n @if (item.claims.length > 3) {\r\n <button\r\n type=\"button\"\r\n (click)=\"onShowRoleClaimsDialog(item)\"\r\n class=\"block rounded-md bg-amber-400 px-2.5 py-1.5 text-center text-sm font-semibold text-black shadow-sm hover:bg-amber-300 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-amber-500\">\r\n <i class=\"fa-solid fa-circle-info mr-2\"></i>Ver mais\r\n </button>\r\n }\r\n </ng-container>\r\n </div>\r\n }\r\n }\r\n\r\n </ng-template>\r\n\r\n</smz-ui-table>\r\n", dependencies: [{ kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "validChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "directive", type: NgVar, selector: "[ngVar]", inputs: ["ngVar"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: SmzInitialPipe, name: "smzInitial" }, { kind: "pipe", type: RbkCanAccessAnyPipe, name: "rbkCanAccessAny" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
32619
32673
|
}
|
|
32620
32674
|
__decorate([
|
|
32621
32675
|
Confirmable('Tem certeza de que deseja excluir esse perfil ?', 'Atenção', true)
|
|
32622
32676
|
], RolesPageComponent.prototype, "showDeleteConfirmation", null);
|
|
32623
32677
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: RolesPageComponent, decorators: [{
|
|
32624
32678
|
type: Component,
|
|
32625
|
-
args: [{ selector: 'app-roles-page', changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, template: "<smz-ui-table [items]=\"roles$ | async\" [state]=\"tableState\">\n\n <ng-template smzTemplate=\"caption\">\n <button smzButton type=\"button\" class=\"mx-1\" label=\"CRIAR\" (click)=\"showCreationDialog()\" [disabled]=\"!(canCreateClaims | rbkCanAccessAny)\" severity=\"primary\"></button>\n </ng-template>\n\n <!-- CONTE\u00DADOS COM OVERRIDE -->\n <ng-template smzTemplate=\"content\" let-item let-col=\"col\">\n\n @switch (col.field) {\n @case ('claims') {\n <div class=\"grid grid-nogutter items-start justify-start flex-col gap-1\">\n <ng-container *ngVar=\"(item.claims | smzInitial : 3) as limitedClaims\">\n <!-- <div [innerHTML]=\"limitedClaims | prettyjson\"></div> -->\n <ul class=\"list-disc\">\n @for (claim of limitedClaims; track claim) {\n <li class=\"\">{{ $any(claim).name }}</li>\n }\n @if (item.claims.length > 3) {\n <li>(...)</li>\n }\n </ul>\n @if (item.claims.length > 3) {\n <button\n type=\"button\"\n (click)=\"onShowRoleClaimsDialog(item)\"\n class=\"block rounded-md bg-amber-400 px-2.5 py-1.5 text-center text-sm font-semibold text-black shadow-sm hover:bg-amber-300 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-amber-500\">\n <i class=\"fa-solid fa-circle-info mr-2\"></i>Ver mais\n </button>\n }\n </ng-container>\n </div>\n }\n }\n\n </ng-template>\n\n</smz-ui-table>\n" }]
|
|
32679
|
+
args: [{ selector: 'app-roles-page', changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, template: "<smz-ui-table [items]=\"roles$ | async\" [state]=\"tableState\">\r\n\r\n <ng-template smzTemplate=\"caption\">\r\n <button smzButton type=\"button\" class=\"mx-1\" label=\"CRIAR\" (click)=\"showCreationDialog()\" [disabled]=\"!(canCreateClaims | rbkCanAccessAny)\" severity=\"primary\"></button>\r\n </ng-template>\r\n\r\n <!-- CONTE\u00DADOS COM OVERRIDE -->\r\n <ng-template smzTemplate=\"content\" let-item let-col=\"col\">\r\n\r\n @switch (col.field) {\r\n @case ('claims') {\r\n <div class=\"grid grid-nogutter items-start justify-start flex-col gap-1\">\r\n <ng-container *ngVar=\"(item.claims | smzInitial : 3) as limitedClaims\">\r\n <!-- <div [innerHTML]=\"limitedClaims | prettyjson\"></div> -->\r\n <ul class=\"list-disc\">\r\n @for (claim of limitedClaims; track claim) {\r\n <li class=\"\">{{ $any(claim).name }}</li>\r\n }\r\n @if (item.claims.length > 3) {\r\n <li>(...)</li>\r\n }\r\n </ul>\r\n @if (item.claims.length > 3) {\r\n <button\r\n type=\"button\"\r\n (click)=\"onShowRoleClaimsDialog(item)\"\r\n class=\"block rounded-md bg-amber-400 px-2.5 py-1.5 text-center text-sm font-semibold text-black shadow-sm hover:bg-amber-300 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-amber-500\">\r\n <i class=\"fa-solid fa-circle-info mr-2\"></i>Ver mais\r\n </button>\r\n }\r\n </ng-container>\r\n </div>\r\n }\r\n }\r\n\r\n </ng-template>\r\n\r\n</smz-ui-table>\r\n" }]
|
|
32626
32680
|
}], ctorParameters: () => [{ type: i1$3.Store }, { type: SmzDialogsService }], propDecorators: { showDeleteConfirmation: [] } });
|
|
32627
32681
|
|
|
32628
32682
|
const data$4 = {
|
|
@@ -32715,9 +32769,9 @@ function showUpdateTenantDialog(tenant) {
|
|
|
32715
32769
|
const displayName = GlobalInjector.config.locale.authorization.tenant.displayName;
|
|
32716
32770
|
dialogs.open(new SmzDialogBuilder()
|
|
32717
32771
|
.setTitle(`Renomear ${displayName}`)
|
|
32718
|
-
.setLayout('LARGE',
|
|
32719
|
-
.setLayout('MEDIUM',
|
|
32720
|
-
.setLayout('SMALL',
|
|
32772
|
+
.setLayout('LARGE', 4)
|
|
32773
|
+
.setLayout('MEDIUM', 6)
|
|
32774
|
+
.setLayout('SMALL', 12)
|
|
32721
32775
|
.confirmOnEnter()
|
|
32722
32776
|
.closeOnEscape()
|
|
32723
32777
|
.form()
|
|
@@ -32748,28 +32802,28 @@ function showCreateTenantDialog() {
|
|
|
32748
32802
|
const dialogs = GlobalInjector.instance.get(SmzDialogsService);
|
|
32749
32803
|
dialogs.open(new SmzDialogBuilder()
|
|
32750
32804
|
.setTitle(`Criar ${displayName}`)
|
|
32751
|
-
.setLayout('EXTRA_SMALL',
|
|
32752
|
-
.setLayout('SMALL',
|
|
32753
|
-
.setLayout('MEDIUM',
|
|
32754
|
-
.setLayout('LARGE',
|
|
32755
|
-
.setLayout('EXTRA_LARGE',
|
|
32805
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
32806
|
+
.setLayout('SMALL', 12)
|
|
32807
|
+
.setLayout('MEDIUM', 12)
|
|
32808
|
+
.setLayout('LARGE', 8)
|
|
32809
|
+
.setLayout('EXTRA_LARGE', 6)
|
|
32756
32810
|
.form()
|
|
32757
32811
|
.group(`${displayName}`)
|
|
32758
32812
|
.text(nameof('alias'), 'Identificador')
|
|
32759
|
-
.setLayout('EXTRA_SMALL',
|
|
32760
|
-
.setLayout('SMALL',
|
|
32761
|
-
.setLayout('MEDIUM',
|
|
32762
|
-
.setLayout('LARGE',
|
|
32763
|
-
.setLayout('EXTRA_LARGE',
|
|
32813
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
32814
|
+
.setLayout('SMALL', 12)
|
|
32815
|
+
.setLayout('MEDIUM', 12)
|
|
32816
|
+
.setLayout('LARGE', 6)
|
|
32817
|
+
.setLayout('EXTRA_LARGE', 6)
|
|
32764
32818
|
.setSaveFormat(SmzTextPattern.CLAIM_PATTERN)
|
|
32765
32819
|
.validators().required().input
|
|
32766
32820
|
.group
|
|
32767
32821
|
.text(nameof('name'), 'Nome')
|
|
32768
|
-
.setLayout('EXTRA_SMALL',
|
|
32769
|
-
.setLayout('SMALL',
|
|
32770
|
-
.setLayout('MEDIUM',
|
|
32771
|
-
.setLayout('LARGE',
|
|
32772
|
-
.setLayout('EXTRA_LARGE',
|
|
32822
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
32823
|
+
.setLayout('SMALL', 12)
|
|
32824
|
+
.setLayout('MEDIUM', 12)
|
|
32825
|
+
.setLayout('LARGE', 6)
|
|
32826
|
+
.setLayout('EXTRA_LARGE', 6)
|
|
32773
32827
|
.validators().required().input
|
|
32774
32828
|
.group
|
|
32775
32829
|
.textArea(nameof('metadata'), 'Metadado')
|
|
@@ -32778,43 +32832,43 @@ function showCreateTenantDialog() {
|
|
|
32778
32832
|
.form
|
|
32779
32833
|
.group('Usuário Admin')
|
|
32780
32834
|
.text(namesof('adminInfo', 'username'), 'Usuário')
|
|
32781
|
-
.setLayout('EXTRA_SMALL',
|
|
32782
|
-
.setLayout('SMALL',
|
|
32783
|
-
.setLayout('MEDIUM',
|
|
32784
|
-
.setLayout('LARGE',
|
|
32785
|
-
.setLayout('EXTRA_LARGE',
|
|
32835
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
32836
|
+
.setLayout('SMALL', 12)
|
|
32837
|
+
.setLayout('MEDIUM', 12)
|
|
32838
|
+
.setLayout('LARGE', 6)
|
|
32839
|
+
.setLayout('EXTRA_LARGE', 4)
|
|
32786
32840
|
.validators().required().input
|
|
32787
32841
|
.group
|
|
32788
32842
|
.text(namesof('adminInfo', 'displayName'), 'Nome')
|
|
32789
|
-
.setLayout('EXTRA_SMALL',
|
|
32790
|
-
.setLayout('SMALL',
|
|
32791
|
-
.setLayout('MEDIUM',
|
|
32792
|
-
.setLayout('LARGE',
|
|
32793
|
-
.setLayout('EXTRA_LARGE',
|
|
32843
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
32844
|
+
.setLayout('SMALL', 12)
|
|
32845
|
+
.setLayout('MEDIUM', 12)
|
|
32846
|
+
.setLayout('LARGE', 6)
|
|
32847
|
+
.setLayout('EXTRA_LARGE', 4)
|
|
32794
32848
|
.validators().required().input
|
|
32795
32849
|
.group
|
|
32796
32850
|
.text(namesof('adminInfo', 'email'), 'Email')
|
|
32797
|
-
.setLayout('EXTRA_SMALL',
|
|
32798
|
-
.setLayout('SMALL',
|
|
32799
|
-
.setLayout('MEDIUM',
|
|
32800
|
-
.setLayout('LARGE',
|
|
32801
|
-
.setLayout('EXTRA_LARGE',
|
|
32851
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
32852
|
+
.setLayout('SMALL', 12)
|
|
32853
|
+
.setLayout('MEDIUM', 12)
|
|
32854
|
+
.setLayout('LARGE', 6)
|
|
32855
|
+
.setLayout('EXTRA_LARGE', 4)
|
|
32802
32856
|
.validators().email().required().input
|
|
32803
32857
|
.group
|
|
32804
32858
|
.password(namesof('adminInfo', 'password'), 'Senha')
|
|
32805
|
-
.setLayout('EXTRA_SMALL',
|
|
32806
|
-
.setLayout('SMALL',
|
|
32807
|
-
.setLayout('MEDIUM',
|
|
32808
|
-
.setLayout('LARGE',
|
|
32809
|
-
.setLayout('EXTRA_LARGE',
|
|
32859
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
32860
|
+
.setLayout('SMALL', 12)
|
|
32861
|
+
.setLayout('MEDIUM', 12)
|
|
32862
|
+
.setLayout('LARGE', 6)
|
|
32863
|
+
.setLayout('EXTRA_LARGE', 6)
|
|
32810
32864
|
.validators().required().input
|
|
32811
32865
|
.group
|
|
32812
32866
|
.addPasswordConfirmation(namesof('adminInfo', 'password'), 'Confirmação')
|
|
32813
|
-
.setLayout('EXTRA_SMALL',
|
|
32814
|
-
.setLayout('SMALL',
|
|
32815
|
-
.setLayout('MEDIUM',
|
|
32816
|
-
.setLayout('LARGE',
|
|
32817
|
-
.setLayout('EXTRA_LARGE',
|
|
32867
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
32868
|
+
.setLayout('SMALL', 12)
|
|
32869
|
+
.setLayout('MEDIUM', 12)
|
|
32870
|
+
.setLayout('LARGE', 6)
|
|
32871
|
+
.setLayout('EXTRA_LARGE', 6)
|
|
32818
32872
|
.validators().required().input
|
|
32819
32873
|
.group
|
|
32820
32874
|
.form
|
|
@@ -32871,7 +32925,7 @@ class TenantsPageComponent {
|
|
|
32871
32925
|
showCreateTenantDialog();
|
|
32872
32926
|
}
|
|
32873
32927
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: TenantsPageComponent, deps: [{ token: i1$3.Store }, { token: SmzDialogsService }], target: i0.ɵɵFactoryTarget.Component });
|
|
32874
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.1", type: TenantsPageComponent, isStandalone: false, selector: "app-tenants-page", ngImport: i0, template: "<smz-ui-table [items]=\"tenants$ | async\" [state]=\"tableState\">\n\n <ng-template smzTemplate=\"caption\">\n <button smzButton type=\"button\" class=\"mx-1\" label=\"CRIAR\" (click)=\"showCreationDialog()\" severity=\"primary\"></button>\n </ng-template>\n\n</smz-ui-table>\n", dependencies: [{ kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
32928
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.1", type: TenantsPageComponent, isStandalone: false, selector: "app-tenants-page", ngImport: i0, template: "<smz-ui-table [items]=\"tenants$ | async\" [state]=\"tableState\">\n\n <ng-template smzTemplate=\"caption\">\n <button smzButton type=\"button\" class=\"mx-1\" label=\"CRIAR\" (click)=\"showCreationDialog()\" severity=\"primary\"></button>\n </ng-template>\n\n</smz-ui-table>\n", dependencies: [{ kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "validChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
32875
32929
|
}
|
|
32876
32930
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: TenantsPageComponent, decorators: [{
|
|
32877
32931
|
type: Component,
|
|
@@ -33873,7 +33927,7 @@ class SmzLoginBuilder {
|
|
|
33873
33927
|
{
|
|
33874
33928
|
propertyName: 'username', type: SmzControlType.TEXT, name: 'Usuário',
|
|
33875
33929
|
validatorsPreset: { isRequired: true },
|
|
33876
|
-
template: { extraSmall: { row:
|
|
33930
|
+
template: { extraSmall: { row: 12 } }
|
|
33877
33931
|
},
|
|
33878
33932
|
{
|
|
33879
33933
|
propertyName: 'password', type: SmzControlType.PASSWORD, name: 'Senha',
|
|
@@ -33886,10 +33940,10 @@ class SmzLoginBuilder {
|
|
|
33886
33940
|
mediumRegex: '^(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.{8,})',
|
|
33887
33941
|
strongRegex: '^(((?=.*[a-z])(?=.*[A-Z]))|((?=.*[a-z])(?=.*[0-9]))|((?=.*[A-Z])(?=.*[0-9])))(?=.{6,}).',
|
|
33888
33942
|
validatorsPreset: { isRequired: true },
|
|
33889
|
-
template: { extraSmall: { row:
|
|
33943
|
+
template: { extraSmall: { row: 12 } }
|
|
33890
33944
|
}
|
|
33891
33945
|
],
|
|
33892
|
-
template: { extraSmall: { row:
|
|
33946
|
+
template: { extraSmall: { row: 12 } }
|
|
33893
33947
|
}
|
|
33894
33948
|
],
|
|
33895
33949
|
},
|
|
@@ -34130,7 +34184,7 @@ class LoginComponent {
|
|
|
34130
34184
|
.enableSubmitOnEnter()
|
|
34131
34185
|
.disableFlattenResponse()
|
|
34132
34186
|
.group()
|
|
34133
|
-
.setLayout('EXTRA_SMALL',
|
|
34187
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
34134
34188
|
.if(authConfig.login.showTenantSelector)
|
|
34135
34189
|
.dropdown('tenant', config.locale.authorization.tenant.displayName, tenants, defaultTenant)
|
|
34136
34190
|
.validators().required().input
|
|
@@ -34269,7 +34323,7 @@ class SuperuserLoginComponent {
|
|
|
34269
34323
|
.enableSubmitOnEnter()
|
|
34270
34324
|
.disableFlattenResponse()
|
|
34271
34325
|
.group()
|
|
34272
|
-
.setLayout('EXTRA_SMALL',
|
|
34326
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
34273
34327
|
.text(nameof('username'), 'Usuário Adminstrativo')
|
|
34274
34328
|
.validators().required().input
|
|
34275
34329
|
.group
|
|
@@ -35389,7 +35443,7 @@ var FaqsForms;
|
|
|
35389
35443
|
const questionInput = {
|
|
35390
35444
|
propertyName: 'question', name: 'Escreva a pergunta', type: SmzControlType.TEXT,
|
|
35391
35445
|
defaultValue: question,
|
|
35392
|
-
template: { large: { row:
|
|
35446
|
+
template: { large: { row: 12 } },
|
|
35393
35447
|
validatorsPreset: { isRequired: true, minLength: 5 },
|
|
35394
35448
|
isDisabled: false,
|
|
35395
35449
|
advancedSettings: {
|
|
@@ -35401,7 +35455,7 @@ var FaqsForms;
|
|
|
35401
35455
|
const answerInput = {
|
|
35402
35456
|
propertyName: 'answer', name: 'Resposta...', type: SmzControlType.TEXT_AREA,
|
|
35403
35457
|
defaultValue: answer,
|
|
35404
|
-
template: { large: { row:
|
|
35458
|
+
template: { large: { row: 12 } },
|
|
35405
35459
|
validatorsPreset: { isRequired: true, minLength: 5 },
|
|
35406
35460
|
isDisabled: false,
|
|
35407
35461
|
textAreaRows: 10,
|
|
@@ -35568,7 +35622,7 @@ class FaqsContentComponent {
|
|
|
35568
35622
|
this.manager.delete(data.id);
|
|
35569
35623
|
}
|
|
35570
35624
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: FaqsContentComponent, deps: [{ token: FaqsManagerService }, { token: i0.ChangeDetectorRef }, { token: SmzDialogsService }], target: i0.ɵɵFactoryTarget.Component });
|
|
35571
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: FaqsContentComponent, isStandalone: false, selector: "smz-faqs-content", inputs: { items: "items" }, ngImport: i0, template: "<div class=\"grid\">\n\n <div class=\"col-12\">\n <h3>{{ manager.config.placeholders.searchTitle }}</h3>\n\n <ui-input-group>\n <ui-input-group-addon>\n <i class=\"fa-solid fa-magnifying-glass\"></i>\n </ui-input-group-addon>\n\n <input\n type=\"text\"\n smzInputText\n [(ngModel)]=\"keywords\"\n [placeholder]=\"manager.config.placeholders.searchPlaceholder\"\n />\n\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" [disabled]=\"keywords === ''\" (click)=\"keywords = ''\" styleClass=\"p-button-warn\"></button>\n </ui-input-group>\n </div>\n\n <div class=\"col-12\">\n @if ((items | searchFaqs : keywords); as filtered) {\n @if (filtered.length > 0) {\n <h3>{{ manager.config.placeholders.contentTitle }}</h3>\n <ui-accordion [multiple]=\"true\">\n @for (item of filtered; track item.id) {\n <ui-accordion-panel [value]=\"item.id\">\n <ui-accordion-header>{{ item.question }}</ui-accordion-header>\n\n <ui-accordion-content>\n @if (manager.config.creationClaim | rbkCanAccess) {\n <div class=\"faqs__actions\">\n <a class=\"clickable hvr-icon-push mr-2\" (click)=\"update(item)\"><i class=\"far fa-edit hvr-icon\"></i></a>\n <a class=\"clickable hvr-icon-push\" (click)=\"delete(item)\"><i class=\"far fa-trash-alt hvr-icon\"></i></a>\n </div>\n }\n\n <div class=\"faqs__answer\" [innerHTML]=\"(item.answer | highlight : keywords) | safeHtml\"></div>\n </ui-accordion-content>\n </ui-accordion-panel>\n }\n </ui-accordion>\n } @else {\n <smz-icon-message\n [message]=\"manager.config.placeholders.emptyMessage\"\n [comment]=\"(manager.config.creationClaim | rbkCanAccess) ?\n manager.config.placeholders.creationMessage :\n (keywords === '') ?\n manager.config.placeholders.supportMessage :\n manager.config.placeholders.noSearchResultsMessage\"\n >\n </smz-icon-message>\n }\n }\n </div>\n\n <div class=\"col-12\">\n @if ((manager.config.creationClaim | rbkCanAccess) && formConfig != null) {\n <h3>{{ manager.config.placeholders.creationTitle }}</h3>\n <smz-form-group #creationComponent [config]=\"formConfig\"></smz-form-group>\n <button smzButton type=\"button\" label=\"ENVIAR\" [disabled]=\"!creationComponent.isValid\" (click)=\"create(creationComponent)\" styleClass=\"p-button-ghost\"></button>\n }\n </div>\n</div>\n", styles: [".faqs__answer{white-space:pre-wrap}.faqs__actions{width:100%;text-align:right;padding:0 0 10px}.p-input-icon-left,.p-input-icon-right{position:relative}.ui-float-icon{position:absolute;top:50%;margin-top:-.5rem;left:.5rem;color:#6c757d}.p-input-icon-left>.ui-inputtext{padding-left:2rem;border-left-width:1px}\n"], dependencies: [{ kind: "component", type: SmzIconMessageComponent, selector: "smz-icon-message", inputs: ["icon", "message", "comment"] }, { kind: "component", type: FormGroupComponent, selector: "smz-form-group", inputs: ["config"], outputs: ["statusChanges", "initialStateChanged", "previousStateChanged", "submit"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "component", type: i2.SmzAccordionComponent, selector: "ui-accordion", inputs: ["value", "multiple", "transitionOptions"], outputs: ["valueChange", "opened", "closed"] }, { kind: "component", type: i2.SmzAccordionPanelComponent, selector: "ui-accordion-panel", inputs: ["value"] }, { kind: "component", type: i2.SmzAccordionHeaderComponent, selector: "ui-accordion-header" }, { kind: "component", type: i2.SmzAccordionContentComponent, selector: "ui-accordion-content" }, { kind: "directive", type: i2.SmzInputTextDirective, selector: "input[smzInputText]", inputs: ["size", "invalid"] }, { kind: "component", type: i2.SmzInputGroupComponent, selector: "ui-input-group" }, { kind: "component", type: i2.SmzInputGroupAddonComponent, selector: "ui-input-group-addon" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "pipe", type: RbkCanAccessPipe, name: "rbkCanAccess" }, { kind: "pipe", type: SearchFaqsPipe, name: "searchFaqs" }, { kind: "pipe", type: HighlightSearch, name: "highlight" }, { kind: "pipe", type: SafeHtmlPipe, name: "safeHtml" }] });
|
|
35625
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: FaqsContentComponent, isStandalone: false, selector: "smz-faqs-content", inputs: { items: "items" }, ngImport: i0, template: "<div class=\"grid\">\r\n\r\n <div class=\"col-12\">\r\n <h3>{{ manager.config.placeholders.searchTitle }}</h3>\r\n\r\n <ui-input-group>\r\n <ui-input-group-addon>\r\n <i class=\"fa-solid fa-magnifying-glass\"></i>\r\n </ui-input-group-addon>\r\n\r\n <input\r\n type=\"text\"\r\n smzInputText\r\n [(ngModel)]=\"keywords\"\r\n [placeholder]=\"manager.config.placeholders.searchPlaceholder\"\r\n />\r\n\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" [disabled]=\"keywords === ''\" (click)=\"keywords = ''\" styleClass=\"p-button-warn\"></button>\r\n </ui-input-group>\r\n </div>\r\n\r\n <div class=\"col-12\">\r\n @if ((items | searchFaqs : keywords); as filtered) {\r\n @if (filtered.length > 0) {\r\n <h3>{{ manager.config.placeholders.contentTitle }}</h3>\r\n <ui-accordion [multiple]=\"true\">\r\n @for (item of filtered; track item.id) {\r\n <ui-accordion-panel [value]=\"item.id\">\r\n <ui-accordion-header>{{ item.question }}</ui-accordion-header>\r\n\r\n <ui-accordion-content>\r\n @if (manager.config.creationClaim | rbkCanAccess) {\r\n <div class=\"faqs__actions\">\r\n <a class=\"clickable hvr-icon-push mr-2\" (click)=\"update(item)\"><i class=\"far fa-edit hvr-icon\"></i></a>\r\n <a class=\"clickable hvr-icon-push\" (click)=\"delete(item)\"><i class=\"far fa-trash-alt hvr-icon\"></i></a>\r\n </div>\r\n }\r\n\r\n <div class=\"faqs__answer\" [innerHTML]=\"(item.answer | highlight : keywords) | safeHtml\"></div>\r\n </ui-accordion-content>\r\n </ui-accordion-panel>\r\n }\r\n </ui-accordion>\r\n } @else {\r\n <smz-icon-message\r\n [message]=\"manager.config.placeholders.emptyMessage\"\r\n [comment]=\"(manager.config.creationClaim | rbkCanAccess) ?\r\n manager.config.placeholders.creationMessage :\r\n (keywords === '') ?\r\n manager.config.placeholders.supportMessage :\r\n manager.config.placeholders.noSearchResultsMessage\"\r\n >\r\n </smz-icon-message>\r\n }\r\n }\r\n </div>\r\n\r\n <div class=\"col-12\">\r\n @if ((manager.config.creationClaim | rbkCanAccess) && formConfig != null) {\r\n <h3>{{ manager.config.placeholders.creationTitle }}</h3>\r\n <smz-form-group #creationComponent [config]=\"formConfig\"></smz-form-group>\r\n <button smzButton type=\"button\" label=\"ENVIAR\" [disabled]=\"!creationComponent.isValid\" (click)=\"create(creationComponent)\" styleClass=\"p-button-ghost\"></button>\r\n }\r\n </div>\r\n</div>\r\n", styles: [".faqs__answer{white-space:pre-wrap}.faqs__actions{width:100%;text-align:right;padding:0 0 10px}.p-input-icon-left,.p-input-icon-right{position:relative}.ui-float-icon{position:absolute;top:50%;margin-top:-.5rem;left:.5rem;color:#6c757d}.p-input-icon-left>.ui-inputtext{padding-left:2rem;border-left-width:1px}\n"], dependencies: [{ kind: "component", type: SmzIconMessageComponent, selector: "smz-icon-message", inputs: ["icon", "message", "comment"] }, { kind: "component", type: FormGroupComponent, selector: "smz-form-group", inputs: ["config"], outputs: ["statusChanges", "initialStateChanged", "previousStateChanged", "submit"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "component", type: i2.SmzAccordionComponent, selector: "ui-accordion", inputs: ["value", "multiple", "transitionOptions"], outputs: ["valueChange", "opened", "closed"] }, { kind: "component", type: i2.SmzAccordionPanelComponent, selector: "ui-accordion-panel", inputs: ["value"] }, { kind: "component", type: i2.SmzAccordionHeaderComponent, selector: "ui-accordion-header" }, { kind: "component", type: i2.SmzAccordionContentComponent, selector: "ui-accordion-content" }, { kind: "directive", type: i2.SmzInputTextDirective, selector: "input[smzInputText]", inputs: ["size", "invalid"] }, { kind: "component", type: i2.SmzInputGroupComponent, selector: "ui-input-group" }, { kind: "component", type: i2.SmzInputGroupAddonComponent, selector: "ui-input-group-addon" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "pipe", type: RbkCanAccessPipe, name: "rbkCanAccess" }, { kind: "pipe", type: SearchFaqsPipe, name: "searchFaqs" }, { kind: "pipe", type: HighlightSearch, name: "highlight" }, { kind: "pipe", type: SafeHtmlPipe, name: "safeHtml" }] });
|
|
35572
35626
|
}
|
|
35573
35627
|
__decorate([
|
|
35574
35628
|
Confirmable('Confirma a criação desta pergunta/resposta ?', 'Aviso')
|
|
@@ -35578,7 +35632,7 @@ __decorate([
|
|
|
35578
35632
|
], FaqsContentComponent.prototype, "delete", null);
|
|
35579
35633
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: FaqsContentComponent, decorators: [{
|
|
35580
35634
|
type: Component,
|
|
35581
|
-
args: [{ selector: 'smz-faqs-content', standalone: false, template: "<div class=\"grid\">\n\n <div class=\"col-12\">\n <h3>{{ manager.config.placeholders.searchTitle }}</h3>\n\n <ui-input-group>\n <ui-input-group-addon>\n <i class=\"fa-solid fa-magnifying-glass\"></i>\n </ui-input-group-addon>\n\n <input\n type=\"text\"\n smzInputText\n [(ngModel)]=\"keywords\"\n [placeholder]=\"manager.config.placeholders.searchPlaceholder\"\n />\n\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" [disabled]=\"keywords === ''\" (click)=\"keywords = ''\" styleClass=\"p-button-warn\"></button>\n </ui-input-group>\n </div>\n\n <div class=\"col-12\">\n @if ((items | searchFaqs : keywords); as filtered) {\n @if (filtered.length > 0) {\n <h3>{{ manager.config.placeholders.contentTitle }}</h3>\n <ui-accordion [multiple]=\"true\">\n @for (item of filtered; track item.id) {\n <ui-accordion-panel [value]=\"item.id\">\n <ui-accordion-header>{{ item.question }}</ui-accordion-header>\n\n <ui-accordion-content>\n @if (manager.config.creationClaim | rbkCanAccess) {\n <div class=\"faqs__actions\">\n <a class=\"clickable hvr-icon-push mr-2\" (click)=\"update(item)\"><i class=\"far fa-edit hvr-icon\"></i></a>\n <a class=\"clickable hvr-icon-push\" (click)=\"delete(item)\"><i class=\"far fa-trash-alt hvr-icon\"></i></a>\n </div>\n }\n\n <div class=\"faqs__answer\" [innerHTML]=\"(item.answer | highlight : keywords) | safeHtml\"></div>\n </ui-accordion-content>\n </ui-accordion-panel>\n }\n </ui-accordion>\n } @else {\n <smz-icon-message\n [message]=\"manager.config.placeholders.emptyMessage\"\n [comment]=\"(manager.config.creationClaim | rbkCanAccess) ?\n manager.config.placeholders.creationMessage :\n (keywords === '') ?\n manager.config.placeholders.supportMessage :\n manager.config.placeholders.noSearchResultsMessage\"\n >\n </smz-icon-message>\n }\n }\n </div>\n\n <div class=\"col-12\">\n @if ((manager.config.creationClaim | rbkCanAccess) && formConfig != null) {\n <h3>{{ manager.config.placeholders.creationTitle }}</h3>\n <smz-form-group #creationComponent [config]=\"formConfig\"></smz-form-group>\n <button smzButton type=\"button\" label=\"ENVIAR\" [disabled]=\"!creationComponent.isValid\" (click)=\"create(creationComponent)\" styleClass=\"p-button-ghost\"></button>\n }\n </div>\n</div>\n", styles: [".faqs__answer{white-space:pre-wrap}.faqs__actions{width:100%;text-align:right;padding:0 0 10px}.p-input-icon-left,.p-input-icon-right{position:relative}.ui-float-icon{position:absolute;top:50%;margin-top:-.5rem;left:.5rem;color:#6c757d}.p-input-icon-left>.ui-inputtext{padding-left:2rem;border-left-width:1px}\n"] }]
|
|
35635
|
+
args: [{ selector: 'smz-faqs-content', standalone: false, template: "<div class=\"grid\">\r\n\r\n <div class=\"col-12\">\r\n <h3>{{ manager.config.placeholders.searchTitle }}</h3>\r\n\r\n <ui-input-group>\r\n <ui-input-group-addon>\r\n <i class=\"fa-solid fa-magnifying-glass\"></i>\r\n </ui-input-group-addon>\r\n\r\n <input\r\n type=\"text\"\r\n smzInputText\r\n [(ngModel)]=\"keywords\"\r\n [placeholder]=\"manager.config.placeholders.searchPlaceholder\"\r\n />\r\n\r\n <button smzButton type=\"button\" icon=\"fa-solid fa-xmark\" [disabled]=\"keywords === ''\" (click)=\"keywords = ''\" styleClass=\"p-button-warn\"></button>\r\n </ui-input-group>\r\n </div>\r\n\r\n <div class=\"col-12\">\r\n @if ((items | searchFaqs : keywords); as filtered) {\r\n @if (filtered.length > 0) {\r\n <h3>{{ manager.config.placeholders.contentTitle }}</h3>\r\n <ui-accordion [multiple]=\"true\">\r\n @for (item of filtered; track item.id) {\r\n <ui-accordion-panel [value]=\"item.id\">\r\n <ui-accordion-header>{{ item.question }}</ui-accordion-header>\r\n\r\n <ui-accordion-content>\r\n @if (manager.config.creationClaim | rbkCanAccess) {\r\n <div class=\"faqs__actions\">\r\n <a class=\"clickable hvr-icon-push mr-2\" (click)=\"update(item)\"><i class=\"far fa-edit hvr-icon\"></i></a>\r\n <a class=\"clickable hvr-icon-push\" (click)=\"delete(item)\"><i class=\"far fa-trash-alt hvr-icon\"></i></a>\r\n </div>\r\n }\r\n\r\n <div class=\"faqs__answer\" [innerHTML]=\"(item.answer | highlight : keywords) | safeHtml\"></div>\r\n </ui-accordion-content>\r\n </ui-accordion-panel>\r\n }\r\n </ui-accordion>\r\n } @else {\r\n <smz-icon-message\r\n [message]=\"manager.config.placeholders.emptyMessage\"\r\n [comment]=\"(manager.config.creationClaim | rbkCanAccess) ?\r\n manager.config.placeholders.creationMessage :\r\n (keywords === '') ?\r\n manager.config.placeholders.supportMessage :\r\n manager.config.placeholders.noSearchResultsMessage\"\r\n >\r\n </smz-icon-message>\r\n }\r\n }\r\n </div>\r\n\r\n <div class=\"col-12\">\r\n @if ((manager.config.creationClaim | rbkCanAccess) && formConfig != null) {\r\n <h3>{{ manager.config.placeholders.creationTitle }}</h3>\r\n <smz-form-group #creationComponent [config]=\"formConfig\"></smz-form-group>\r\n <button smzButton type=\"button\" label=\"ENVIAR\" [disabled]=\"!creationComponent.isValid\" (click)=\"create(creationComponent)\" styleClass=\"p-button-ghost\"></button>\r\n }\r\n </div>\r\n</div>\r\n", styles: [".faqs__answer{white-space:pre-wrap}.faqs__actions{width:100%;text-align:right;padding:0 0 10px}.p-input-icon-left,.p-input-icon-right{position:relative}.ui-float-icon{position:absolute;top:50%;margin-top:-.5rem;left:.5rem;color:#6c757d}.p-input-icon-left>.ui-inputtext{padding-left:2rem;border-left-width:1px}\n"] }]
|
|
35582
35636
|
}], ctorParameters: () => [{ type: FaqsManagerService }, { type: i0.ChangeDetectorRef }, { type: SmzDialogsService }], propDecorators: { items: [{
|
|
35583
35637
|
type: Input
|
|
35584
35638
|
}], create: [], delete: [] } });
|
|
@@ -36466,11 +36520,11 @@ class SmzDockComponent {
|
|
|
36466
36520
|
}
|
|
36467
36521
|
}
|
|
36468
36522
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzDockComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
36469
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzDockComponent, isStandalone: false, selector: "smz-ui-dock", ngImport: i0, template: "<div class=\"dock-window fixed bottom-0 left-0 right-0 z-50\" [class.hidden]=\"dockService.dockItems().length === 0\">\n <div class=\"flex items-end justify-center gap-2 px-4 py-2\" role=\"toolbar\" aria-label=\"Janelas minimizadas\">\n @for (item of dockService.dockItems(); track item.id) {\n <div class=\"relative w-16 cursor-pointer transition-transform duration-ui hover:-translate-y-1\" role=\"button\" tabindex=\"0\" (click)=\"execute(item)\" (keydown.enter)=\"execute(item)\">\n <img [src]=\"item.icon\" width=\"100%\" [alt]=\"item.label ?? ''\">\n @if (item.label != null) {\n <div class=\"absolute inset-0 grid grid-nogutter items-center justify-center flex-col\">\n <div class=\"text-center font-medium my-auto pt-2 select-none text-black text-xs\">{{ item.label }}</div>\n </div>\n }\n </div>\n }\n </div>\n</div>\n" });
|
|
36523
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzDockComponent, isStandalone: false, selector: "smz-ui-dock", ngImport: i0, template: "<div class=\"dock-window fixed bottom-0 left-0 right-0 z-50\" [class.hidden]=\"dockService.dockItems().length === 0\">\r\n <div class=\"flex items-end justify-center gap-2 px-4 py-2\" role=\"toolbar\" aria-label=\"Janelas minimizadas\">\r\n @for (item of dockService.dockItems(); track item.id) {\r\n <div class=\"relative w-16 cursor-pointer transition-transform duration-ui hover:-translate-y-1\" role=\"button\" tabindex=\"0\" (click)=\"execute(item)\" (keydown.enter)=\"execute(item)\">\r\n <img [src]=\"item.icon\" width=\"100%\" [alt]=\"item.label ?? ''\">\r\n @if (item.label != null) {\r\n <div class=\"absolute inset-0 grid grid-nogutter items-center justify-center flex-col\">\r\n <div class=\"text-center font-medium my-auto pt-2 select-none text-black text-xs\">{{ item.label }}</div>\r\n </div>\r\n }\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n" });
|
|
36470
36524
|
}
|
|
36471
36525
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzDockComponent, decorators: [{
|
|
36472
36526
|
type: Component,
|
|
36473
|
-
args: [{ selector: 'smz-ui-dock', standalone: false, template: "<div class=\"dock-window fixed bottom-0 left-0 right-0 z-50\" [class.hidden]=\"dockService.dockItems().length === 0\">\n <div class=\"flex items-end justify-center gap-2 px-4 py-2\" role=\"toolbar\" aria-label=\"Janelas minimizadas\">\n @for (item of dockService.dockItems(); track item.id) {\n <div class=\"relative w-16 cursor-pointer transition-transform duration-ui hover:-translate-y-1\" role=\"button\" tabindex=\"0\" (click)=\"execute(item)\" (keydown.enter)=\"execute(item)\">\n <img [src]=\"item.icon\" width=\"100%\" [alt]=\"item.label ?? ''\">\n @if (item.label != null) {\n <div class=\"absolute inset-0 grid grid-nogutter items-center justify-center flex-col\">\n <div class=\"text-center font-medium my-auto pt-2 select-none text-black text-xs\">{{ item.label }}</div>\n </div>\n }\n </div>\n }\n </div>\n</div>\n" }]
|
|
36527
|
+
args: [{ selector: 'smz-ui-dock', standalone: false, template: "<div class=\"dock-window fixed bottom-0 left-0 right-0 z-50\" [class.hidden]=\"dockService.dockItems().length === 0\">\r\n <div class=\"flex items-end justify-center gap-2 px-4 py-2\" role=\"toolbar\" aria-label=\"Janelas minimizadas\">\r\n @for (item of dockService.dockItems(); track item.id) {\r\n <div class=\"relative w-16 cursor-pointer transition-transform duration-ui hover:-translate-y-1\" role=\"button\" tabindex=\"0\" (click)=\"execute(item)\" (keydown.enter)=\"execute(item)\">\r\n <img [src]=\"item.icon\" width=\"100%\" [alt]=\"item.label ?? ''\">\r\n @if (item.label != null) {\r\n <div class=\"absolute inset-0 grid grid-nogutter items-center justify-center flex-col\">\r\n <div class=\"text-center font-medium my-auto pt-2 select-none text-black text-xs\">{{ item.label }}</div>\r\n </div>\r\n }\r\n </div>\r\n }\r\n </div>\r\n</div>\r\n" }]
|
|
36474
36528
|
}] });
|
|
36475
36529
|
|
|
36476
36530
|
/* eslint-disable @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-unsafe-member-access, @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-return, @typescript-eslint/explicit-module-boundary-types, @typescript-eslint/explicit-function-return-type, @typescript-eslint/typedef, no-underscore-dangle, no-console, eqeqeq, @typescript-eslint/no-unused-vars, @typescript-eslint/no-useless-constructor, @typescript-eslint/explicit-member-accessibility, max-len, no-prototype-builtins, @typescript-eslint/no-shadow, @typescript-eslint/no-empty-object-type */
|
|
@@ -37843,9 +37897,9 @@ class SmzExportDialogService {
|
|
|
37843
37897
|
const documentState = this.buildDocumentState(data, plainItems);
|
|
37844
37898
|
this.dialogs.open(new SmzDialogBuilder()
|
|
37845
37899
|
.setTitle(data.title)
|
|
37846
|
-
.setLayout('EXTRA_SMALL',
|
|
37847
|
-
.setLayout('LARGE',
|
|
37848
|
-
.setLayout('EXTRA_LARGE',
|
|
37900
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
37901
|
+
.setLayout('LARGE', 10)
|
|
37902
|
+
.setLayout('EXTRA_LARGE', 10)
|
|
37849
37903
|
.closeOnEscape()
|
|
37850
37904
|
.allowMaximize()
|
|
37851
37905
|
.dismissableMask()
|
|
@@ -38427,11 +38481,11 @@ function showSwitchTenantDialog() {
|
|
|
38427
38481
|
.map(x => ({ id: x.alias, name: x.name }));
|
|
38428
38482
|
dialogs.open(new SmzDialogBuilder()
|
|
38429
38483
|
.setTitle(`Alterar ${tenantDisplayName}`)
|
|
38430
|
-
.setLayout('EXTRA_LARGE',
|
|
38431
|
-
.setLayout('LARGE',
|
|
38432
|
-
.setLayout('MEDIUM',
|
|
38433
|
-
.setLayout('SMALL',
|
|
38434
|
-
.setLayout('EXTRA_SMALL',
|
|
38484
|
+
.setLayout('EXTRA_LARGE', 12)
|
|
38485
|
+
.setLayout('LARGE', 12)
|
|
38486
|
+
.setLayout('MEDIUM', 12)
|
|
38487
|
+
.setLayout('SMALL', 12)
|
|
38488
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
38435
38489
|
.form()
|
|
38436
38490
|
.disableFlattenResponse()
|
|
38437
38491
|
.group()
|
|
@@ -38439,19 +38493,19 @@ function showSwitchTenantDialog() {
|
|
|
38439
38493
|
// TENANT ATUAL
|
|
38440
38494
|
.text('currentTenant', `${tenantDisplayName} atual`, currentTenant.name)
|
|
38441
38495
|
.disable()
|
|
38442
|
-
.setLayout('EXTRA_LARGE',
|
|
38443
|
-
.setLayout('LARGE',
|
|
38444
|
-
.setLayout('MEDIUM',
|
|
38445
|
-
.setLayout('SMALL',
|
|
38446
|
-
.setLayout('EXTRA_SMALL',
|
|
38496
|
+
.setLayout('EXTRA_LARGE', 12)
|
|
38497
|
+
.setLayout('LARGE', 12)
|
|
38498
|
+
.setLayout('MEDIUM', 12)
|
|
38499
|
+
.setLayout('SMALL', 12)
|
|
38500
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
38447
38501
|
.group
|
|
38448
38502
|
// SELETOR DE TENANT
|
|
38449
38503
|
.dropdown('tenant', 'Alterar para', allowedTenants)
|
|
38450
|
-
.setLayout('EXTRA_LARGE',
|
|
38451
|
-
.setLayout('LARGE',
|
|
38452
|
-
.setLayout('MEDIUM',
|
|
38453
|
-
.setLayout('SMALL',
|
|
38454
|
-
.setLayout('EXTRA_SMALL',
|
|
38504
|
+
.setLayout('EXTRA_LARGE', 12)
|
|
38505
|
+
.setLayout('LARGE', 12)
|
|
38506
|
+
.setLayout('MEDIUM', 12)
|
|
38507
|
+
.setLayout('SMALL', 12)
|
|
38508
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
38455
38509
|
.validators().required().input
|
|
38456
38510
|
.group
|
|
38457
38511
|
.form
|
|
@@ -38695,11 +38749,11 @@ function showSwitchLocalizationDialog() {
|
|
|
38695
38749
|
.map(x => ({ id: x.alias, name: x.name }));
|
|
38696
38750
|
dialogs.open(new SmzDialogBuilder()
|
|
38697
38751
|
.setTitle(`Alterar ${tenantDisplayName}`)
|
|
38698
|
-
.setLayout('EXTRA_LARGE',
|
|
38699
|
-
.setLayout('LARGE',
|
|
38700
|
-
.setLayout('MEDIUM',
|
|
38701
|
-
.setLayout('SMALL',
|
|
38702
|
-
.setLayout('EXTRA_SMALL',
|
|
38752
|
+
.setLayout('EXTRA_LARGE', 12)
|
|
38753
|
+
.setLayout('LARGE', 12)
|
|
38754
|
+
.setLayout('MEDIUM', 12)
|
|
38755
|
+
.setLayout('SMALL', 12)
|
|
38756
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
38703
38757
|
.form()
|
|
38704
38758
|
.disableFlattenResponse()
|
|
38705
38759
|
.group()
|
|
@@ -38707,19 +38761,19 @@ function showSwitchLocalizationDialog() {
|
|
|
38707
38761
|
// TENANT ATUAL
|
|
38708
38762
|
.text('currentTenant', `${tenantDisplayName} atual`, currentTenant.name)
|
|
38709
38763
|
.disable()
|
|
38710
|
-
.setLayout('EXTRA_LARGE',
|
|
38711
|
-
.setLayout('LARGE',
|
|
38712
|
-
.setLayout('MEDIUM',
|
|
38713
|
-
.setLayout('SMALL',
|
|
38714
|
-
.setLayout('EXTRA_SMALL',
|
|
38764
|
+
.setLayout('EXTRA_LARGE', 12)
|
|
38765
|
+
.setLayout('LARGE', 12)
|
|
38766
|
+
.setLayout('MEDIUM', 12)
|
|
38767
|
+
.setLayout('SMALL', 12)
|
|
38768
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
38715
38769
|
.group
|
|
38716
38770
|
// SELETOR DE TENANT
|
|
38717
38771
|
.dropdown('tenant', 'Alterar para', allowedTenants)
|
|
38718
|
-
.setLayout('EXTRA_LARGE',
|
|
38719
|
-
.setLayout('LARGE',
|
|
38720
|
-
.setLayout('MEDIUM',
|
|
38721
|
-
.setLayout('SMALL',
|
|
38722
|
-
.setLayout('EXTRA_SMALL',
|
|
38772
|
+
.setLayout('EXTRA_LARGE', 12)
|
|
38773
|
+
.setLayout('LARGE', 12)
|
|
38774
|
+
.setLayout('MEDIUM', 12)
|
|
38775
|
+
.setLayout('SMALL', 12)
|
|
38776
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
38723
38777
|
.validators().required().input
|
|
38724
38778
|
.group
|
|
38725
38779
|
.form
|
|
@@ -38777,72 +38831,72 @@ class SmzLocalizationSwitchComponent {
|
|
|
38777
38831
|
showSwitchLocalizationDialog();
|
|
38778
38832
|
}
|
|
38779
38833
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzLocalizationSwitchComponent, deps: [{ token: i1$3.Store }], target: i0.ɵɵFactoryTarget.Component });
|
|
38780
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzLocalizationSwitchComponent, isStandalone: true, selector: "smz-localization-switch", host: { classAttribute: "h-full relative" }, ngImport: i0, template: `
|
|
38781
|
-
@if (showLocalizationSwitch) {
|
|
38782
|
-
<smz-responsive class="col grid grid-nogutter w-full items-center justify-start">
|
|
38783
|
-
<!-- LANDSCAPE -->
|
|
38784
|
-
<ng-template smzTemplate="landscape">
|
|
38785
|
-
<div class="h-full grid grid-nogutter items-center justify-center">
|
|
38786
|
-
<ui-select appendTo="body" [options]="locales$ | async" styleClass="smz-tenant-switch-small" optionLabel="alias" dataKey="name" [(ngModel)]="selected" (changed)="onSelectorChange($event.value)">
|
|
38787
|
-
<ng-template smzTemplate="selectedItem">
|
|
38788
|
-
@if (selected) {
|
|
38789
|
-
<div class="flex align-items-center gap-2">
|
|
38790
|
-
<img src="https://primefaces.org/cdn/primeng/images/demo/flag/flag_placeholder.png" [class]="'flag flag-' + selected.country.toLowerCase()" style="width: 18px"/>
|
|
38791
|
-
<div>{{ selected.name }}</div>
|
|
38792
|
-
</div>
|
|
38793
|
-
}
|
|
38794
|
-
</ng-template>
|
|
38795
|
-
<ng-template let-locale smzTemplate="item">
|
|
38796
|
-
<div class="flex align-items-center gap-2">
|
|
38797
|
-
<img src="https://primefaces.org/cdn/primeng/images/demo/flag/flag_placeholder.png" [class]="'flag flag-' + locale.country.toLowerCase()" style="width: 18px"/>
|
|
38798
|
-
<div>{{ locale.name }}</div>
|
|
38799
|
-
</div>
|
|
38800
|
-
</ng-template>
|
|
38801
|
-
</ui-select>
|
|
38802
|
-
</div>
|
|
38803
|
-
</ng-template>
|
|
38804
|
-
<!-- PORTRAIT -->
|
|
38805
|
-
<ng-template smzTemplate="portrait">
|
|
38806
|
-
<i class="fa-solid fa-repeat cursor-pointer text-2xl text-text-color switch-tenant" (click)="showSwitchDialog()">
|
|
38807
|
-
</i>
|
|
38808
|
-
</ng-template>
|
|
38809
|
-
</smz-responsive>
|
|
38810
|
-
}
|
|
38834
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzLocalizationSwitchComponent, isStandalone: true, selector: "smz-localization-switch", host: { classAttribute: "h-full relative" }, ngImport: i0, template: `
|
|
38835
|
+
@if (showLocalizationSwitch) {
|
|
38836
|
+
<smz-responsive class="col grid grid-nogutter w-full items-center justify-start">
|
|
38837
|
+
<!-- LANDSCAPE -->
|
|
38838
|
+
<ng-template smzTemplate="landscape">
|
|
38839
|
+
<div class="h-full grid grid-nogutter items-center justify-center">
|
|
38840
|
+
<ui-select appendTo="body" [options]="locales$ | async" styleClass="smz-tenant-switch-small" optionLabel="alias" dataKey="name" [(ngModel)]="selected" (changed)="onSelectorChange($event.value)">
|
|
38841
|
+
<ng-template smzTemplate="selectedItem">
|
|
38842
|
+
@if (selected) {
|
|
38843
|
+
<div class="flex align-items-center gap-2">
|
|
38844
|
+
<img src="https://primefaces.org/cdn/primeng/images/demo/flag/flag_placeholder.png" [class]="'flag flag-' + selected.country.toLowerCase()" style="width: 18px"/>
|
|
38845
|
+
<div>{{ selected.name }}</div>
|
|
38846
|
+
</div>
|
|
38847
|
+
}
|
|
38848
|
+
</ng-template>
|
|
38849
|
+
<ng-template let-locale smzTemplate="item">
|
|
38850
|
+
<div class="flex align-items-center gap-2">
|
|
38851
|
+
<img src="https://primefaces.org/cdn/primeng/images/demo/flag/flag_placeholder.png" [class]="'flag flag-' + locale.country.toLowerCase()" style="width: 18px"/>
|
|
38852
|
+
<div>{{ locale.name }}</div>
|
|
38853
|
+
</div>
|
|
38854
|
+
</ng-template>
|
|
38855
|
+
</ui-select>
|
|
38856
|
+
</div>
|
|
38857
|
+
</ng-template>
|
|
38858
|
+
<!-- PORTRAIT -->
|
|
38859
|
+
<ng-template smzTemplate="portrait">
|
|
38860
|
+
<i class="fa-solid fa-repeat cursor-pointer text-2xl text-text-color switch-tenant" (click)="showSwitchDialog()">
|
|
38861
|
+
</i>
|
|
38862
|
+
</ng-template>
|
|
38863
|
+
</smz-responsive>
|
|
38864
|
+
}
|
|
38811
38865
|
`, isInline: true, styles: [".smz-localization-switch-small .p-inputtext{padding:.5rem .75rem!important}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: SmzSelectComponent, selector: "ui-select", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "placeholder", "filter", "filterBy", "filterMatchMode", "filterPlaceholder", "showClear", "emptyMessage", "emptyFilterMessage", "styleClass", "inputId", "ariaLabel", "appendTo"], outputs: ["changed", "showed", "hidden"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: SmzResponsiveComponent, selector: "smz-responsive" }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.Eager, encapsulation: i0.ViewEncapsulation.None });
|
|
38812
38866
|
}
|
|
38813
38867
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzLocalizationSwitchComponent, decorators: [{
|
|
38814
38868
|
type: Component,
|
|
38815
|
-
args: [{ selector: 'smz-localization-switch', imports: [CommonModule, SmzSelectComponent, FormsModule, SmzTemplateDirective, SmzResponsiveComponent], host: { class: 'h-full relative' }, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.Default, template: `
|
|
38816
|
-
@if (showLocalizationSwitch) {
|
|
38817
|
-
<smz-responsive class="col grid grid-nogutter w-full items-center justify-start">
|
|
38818
|
-
<!-- LANDSCAPE -->
|
|
38819
|
-
<ng-template smzTemplate="landscape">
|
|
38820
|
-
<div class="h-full grid grid-nogutter items-center justify-center">
|
|
38821
|
-
<ui-select appendTo="body" [options]="locales$ | async" styleClass="smz-tenant-switch-small" optionLabel="alias" dataKey="name" [(ngModel)]="selected" (changed)="onSelectorChange($event.value)">
|
|
38822
|
-
<ng-template smzTemplate="selectedItem">
|
|
38823
|
-
@if (selected) {
|
|
38824
|
-
<div class="flex align-items-center gap-2">
|
|
38825
|
-
<img src="https://primefaces.org/cdn/primeng/images/demo/flag/flag_placeholder.png" [class]="'flag flag-' + selected.country.toLowerCase()" style="width: 18px"/>
|
|
38826
|
-
<div>{{ selected.name }}</div>
|
|
38827
|
-
</div>
|
|
38828
|
-
}
|
|
38829
|
-
</ng-template>
|
|
38830
|
-
<ng-template let-locale smzTemplate="item">
|
|
38831
|
-
<div class="flex align-items-center gap-2">
|
|
38832
|
-
<img src="https://primefaces.org/cdn/primeng/images/demo/flag/flag_placeholder.png" [class]="'flag flag-' + locale.country.toLowerCase()" style="width: 18px"/>
|
|
38833
|
-
<div>{{ locale.name }}</div>
|
|
38834
|
-
</div>
|
|
38835
|
-
</ng-template>
|
|
38836
|
-
</ui-select>
|
|
38837
|
-
</div>
|
|
38838
|
-
</ng-template>
|
|
38839
|
-
<!-- PORTRAIT -->
|
|
38840
|
-
<ng-template smzTemplate="portrait">
|
|
38841
|
-
<i class="fa-solid fa-repeat cursor-pointer text-2xl text-text-color switch-tenant" (click)="showSwitchDialog()">
|
|
38842
|
-
</i>
|
|
38843
|
-
</ng-template>
|
|
38844
|
-
</smz-responsive>
|
|
38845
|
-
}
|
|
38869
|
+
args: [{ selector: 'smz-localization-switch', imports: [CommonModule, SmzSelectComponent, FormsModule, SmzTemplateDirective, SmzResponsiveComponent], host: { class: 'h-full relative' }, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.Default, template: `
|
|
38870
|
+
@if (showLocalizationSwitch) {
|
|
38871
|
+
<smz-responsive class="col grid grid-nogutter w-full items-center justify-start">
|
|
38872
|
+
<!-- LANDSCAPE -->
|
|
38873
|
+
<ng-template smzTemplate="landscape">
|
|
38874
|
+
<div class="h-full grid grid-nogutter items-center justify-center">
|
|
38875
|
+
<ui-select appendTo="body" [options]="locales$ | async" styleClass="smz-tenant-switch-small" optionLabel="alias" dataKey="name" [(ngModel)]="selected" (changed)="onSelectorChange($event.value)">
|
|
38876
|
+
<ng-template smzTemplate="selectedItem">
|
|
38877
|
+
@if (selected) {
|
|
38878
|
+
<div class="flex align-items-center gap-2">
|
|
38879
|
+
<img src="https://primefaces.org/cdn/primeng/images/demo/flag/flag_placeholder.png" [class]="'flag flag-' + selected.country.toLowerCase()" style="width: 18px"/>
|
|
38880
|
+
<div>{{ selected.name }}</div>
|
|
38881
|
+
</div>
|
|
38882
|
+
}
|
|
38883
|
+
</ng-template>
|
|
38884
|
+
<ng-template let-locale smzTemplate="item">
|
|
38885
|
+
<div class="flex align-items-center gap-2">
|
|
38886
|
+
<img src="https://primefaces.org/cdn/primeng/images/demo/flag/flag_placeholder.png" [class]="'flag flag-' + locale.country.toLowerCase()" style="width: 18px"/>
|
|
38887
|
+
<div>{{ locale.name }}</div>
|
|
38888
|
+
</div>
|
|
38889
|
+
</ng-template>
|
|
38890
|
+
</ui-select>
|
|
38891
|
+
</div>
|
|
38892
|
+
</ng-template>
|
|
38893
|
+
<!-- PORTRAIT -->
|
|
38894
|
+
<ng-template smzTemplate="portrait">
|
|
38895
|
+
<i class="fa-solid fa-repeat cursor-pointer text-2xl text-text-color switch-tenant" (click)="showSwitchDialog()">
|
|
38896
|
+
</i>
|
|
38897
|
+
</ng-template>
|
|
38898
|
+
</smz-responsive>
|
|
38899
|
+
}
|
|
38846
38900
|
`, styles: [".smz-localization-switch-small .p-inputtext{padding:.5rem .75rem!important}\n"] }]
|
|
38847
38901
|
}], ctorParameters: () => [{ type: i1$3.Store }] });
|
|
38848
38902
|
|
|
@@ -40534,38 +40588,38 @@ class AthenaNotificationItemsComponent {
|
|
|
40534
40588
|
}
|
|
40535
40589
|
}
|
|
40536
40590
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: AthenaNotificationItemsComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
40537
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: AthenaNotificationItemsComponent, isStandalone: false, selector: "[smz-ui-athena-notification-items]", inputs: { items: "items" }, outputs: { onClose: "onClose" }, host: { listeners: { "document:click": "collapse($event)" } }, ngImport: i0, template: `
|
|
40538
|
-
@for (item of items; track item; let index = $index) {
|
|
40539
|
-
<li role="menuitem">
|
|
40540
|
-
<a menuItemAction class="grid grid-nogutter items-center justify-start" style="display: flex;" [item]="item" [parent]="null" [breadcrumbs]="false" [tabindex]="index">
|
|
40541
|
-
@if (item.icon != null) {
|
|
40542
|
-
<i class="fa-solid mr-3" [ngClass]="item.icon"></i>
|
|
40543
|
-
}
|
|
40544
|
-
<div class="notification-item">
|
|
40545
|
-
<div class="notification-summary">{{ item.summary }}</div>
|
|
40546
|
-
<div class="notification-detail" [innerHtml]="item.details"></div>
|
|
40547
|
-
</div>
|
|
40548
|
-
</a>
|
|
40549
|
-
</li>
|
|
40550
|
-
}
|
|
40591
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: AthenaNotificationItemsComponent, isStandalone: false, selector: "[smz-ui-athena-notification-items]", inputs: { items: "items" }, outputs: { onClose: "onClose" }, host: { listeners: { "document:click": "collapse($event)" } }, ngImport: i0, template: `
|
|
40592
|
+
@for (item of items; track item; let index = $index) {
|
|
40593
|
+
<li role="menuitem">
|
|
40594
|
+
<a menuItemAction class="grid grid-nogutter items-center justify-start" style="display: flex;" [item]="item" [parent]="null" [breadcrumbs]="false" [tabindex]="index">
|
|
40595
|
+
@if (item.icon != null) {
|
|
40596
|
+
<i class="fa-solid mr-3" [ngClass]="item.icon"></i>
|
|
40597
|
+
}
|
|
40598
|
+
<div class="notification-item">
|
|
40599
|
+
<div class="notification-summary">{{ item.summary }}</div>
|
|
40600
|
+
<div class="notification-detail" [innerHtml]="item.details"></div>
|
|
40601
|
+
</div>
|
|
40602
|
+
</a>
|
|
40603
|
+
</li>
|
|
40604
|
+
}
|
|
40551
40605
|
`, isInline: true, styles: [".notification-summary{font-weight:600}.notification-detail{font-weight:400}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: MenuItemActionsDirective, selector: "[menuItemAction]", inputs: ["item", "parent", "breadcrumbs"], outputs: ["collapse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
40552
40606
|
}
|
|
40553
40607
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: AthenaNotificationItemsComponent, decorators: [{
|
|
40554
40608
|
type: Component,
|
|
40555
|
-
args: [{ selector: '[smz-ui-athena-notification-items]', host: { '(document:click)': 'collapse($event)' }, changeDetection: ChangeDetectionStrategy.OnPush, template: `
|
|
40556
|
-
@for (item of items; track item; let index = $index) {
|
|
40557
|
-
<li role="menuitem">
|
|
40558
|
-
<a menuItemAction class="grid grid-nogutter items-center justify-start" style="display: flex;" [item]="item" [parent]="null" [breadcrumbs]="false" [tabindex]="index">
|
|
40559
|
-
@if (item.icon != null) {
|
|
40560
|
-
<i class="fa-solid mr-3" [ngClass]="item.icon"></i>
|
|
40561
|
-
}
|
|
40562
|
-
<div class="notification-item">
|
|
40563
|
-
<div class="notification-summary">{{ item.summary }}</div>
|
|
40564
|
-
<div class="notification-detail" [innerHtml]="item.details"></div>
|
|
40565
|
-
</div>
|
|
40566
|
-
</a>
|
|
40567
|
-
</li>
|
|
40568
|
-
}
|
|
40609
|
+
args: [{ selector: '[smz-ui-athena-notification-items]', host: { '(document:click)': 'collapse($event)' }, changeDetection: ChangeDetectionStrategy.OnPush, template: `
|
|
40610
|
+
@for (item of items; track item; let index = $index) {
|
|
40611
|
+
<li role="menuitem">
|
|
40612
|
+
<a menuItemAction class="grid grid-nogutter items-center justify-start" style="display: flex;" [item]="item" [parent]="null" [breadcrumbs]="false" [tabindex]="index">
|
|
40613
|
+
@if (item.icon != null) {
|
|
40614
|
+
<i class="fa-solid mr-3" [ngClass]="item.icon"></i>
|
|
40615
|
+
}
|
|
40616
|
+
<div class="notification-item">
|
|
40617
|
+
<div class="notification-summary">{{ item.summary }}</div>
|
|
40618
|
+
<div class="notification-detail" [innerHtml]="item.details"></div>
|
|
40619
|
+
</div>
|
|
40620
|
+
</a>
|
|
40621
|
+
</li>
|
|
40622
|
+
}
|
|
40569
40623
|
`, standalone: false, styles: [".notification-summary{font-weight:600}.notification-detail{font-weight:400}\n"] }]
|
|
40570
40624
|
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { items: [{
|
|
40571
40625
|
type: Input
|
|
@@ -41226,7 +41280,7 @@ class NotificationsListComponent {
|
|
|
41226
41280
|
}
|
|
41227
41281
|
}
|
|
41228
41282
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: NotificationsListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
41229
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: NotificationsListComponent, isStandalone: false, selector: "smz-notifications-list", ngImport: i0, template: "<ng-container *ngVar=\"hasRuningRequest$ | async as hasRuningRequest\">\n\n <smz-ui-table #smzTable [items]=\"(notifications$ | async) | filterBy : ['status'] : currentFolder.status\" [state]=\"tableState\" [loading]=\"hasRuningRequest\" (selectionChange)=\"onSelect($event)\">\n\n <ng-template smzTemplate=\"caption\" let-primeTable>\n @if (uiConfig.rbkUtils.notifications.showRefreshButton) {\n <button smzButton smzRipple type=\"button\" icon=\"fa-solid fa-rotate\" smzTooltip=\"Atualizar\" class=\"mr-3\" (click)=\"refresh()\" [rounded]=\"true\" variant=\"text\" styleClass=\"p-button-plain\"></button>\n }\n <ui-select-button appendTo=\"body\" [options]=\"folders\" [(ngModel)]=\"currentFolder\" optionLabel=\"icon\" (changed)=\"currentFolder.rebuild()\">\n <ng-template #item let-item>\n <i [ngClass]=\"item.icon\" [smzTooltip]=\"item.tooltip\"></i>\n <span class=\"ml-1 text-sm\">({{ item.count$ | async }})</span>\n </ng-template>\n </ui-select-button>\n </ng-template>\n\n <!-- CONTE\u00DADOS COM OVERRIDE -->\n <ng-template smzTemplate=\"content\" let-item let-col=\"col\">\n\n @switch (col.field) {\n @case ('searchData') {\n <div class=\"grid grid-nogutter items-center justify-between\" (mouseenter)=\"item._showActions = true\" (mouseleave)=\"item._showActions = false\">\n <div class=\"col\">\n <smz-notification-item [item]=\"item\" [showDate]=\"true\"></smz-notification-item>\n </div>\n @if (item._showActions) {\n <div class=\"grid grid-nogutter items-center justify-start gap-4 flex-col pl-4 animate__animated animate__fadeIn relative\" clickStopPropagation>\n @if (item.status !== status.ARCHIVED) {\n <i #archiveButton smzTooltip=\"Arquivar\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-box-archive p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"archive([item])\"></i>\n }\n @if (item.status === status.ARCHIVED) {\n <i #inboxButton smzTooltip=\"Desarquivar\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-inbox p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"moveToInbox([item])\"></i>\n }\n @if (item.route != '') {\n <i #routeButton smzTooltip=\"Navegar\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-share p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"navigate(item)\"></i>\n }\n @if (item.link != '') {\n <i #linkButton smzTooltip=\"Abrir Link\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-up-right-from-square p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"openLink(item)\"></i>\n }\n <i #trashButton smzTooltip=\"Excluir\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-trash p-button-rounded p-button-text p-button-plain relative text-gray-500\" styleClass=\"relative\" (click)=\"remove(item)\"></i>\n </div>\n }\n </div>\n }\n }\n\n </ng-template>\n\n </smz-ui-table>\n\n</ng-container>", styles: ["smz-notifications-list .database-title{font-size:1.2rem}smz-notifications-list i .p-tooltip .p-tooltip-text{word-break:normal}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "directive", type: i2.SmzTooltipDirective, selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "component", type: i2.SmzSelectButtonComponent, selector: "ui-select-button", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "multiple", "allowEmpty", "size", "styleClass", "appendTo"], outputs: ["changed"] }, { kind: "directive", type: NgVar, selector: "[ngVar]", inputs: ["ngVar"] }, { kind: "directive", type: ClickStopPropagationDirective, selector: "[clickStopPropagation]" }, { kind: "component", type: NotificationItemComponent, selector: "smz-notification-item", inputs: ["item", "charactersLimit", "showDate"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: FilterByPipe, name: "filterBy" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
41283
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: NotificationsListComponent, isStandalone: false, selector: "smz-notifications-list", ngImport: i0, template: "<ng-container *ngVar=\"hasRuningRequest$ | async as hasRuningRequest\">\r\n\r\n <smz-ui-table #smzTable [items]=\"(notifications$ | async) | filterBy : ['status'] : currentFolder.status\" [state]=\"tableState\" [loading]=\"hasRuningRequest\" (selectionChange)=\"onSelect($event)\">\r\n\r\n <ng-template smzTemplate=\"caption\" let-primeTable>\r\n @if (uiConfig.rbkUtils.notifications.showRefreshButton) {\r\n <button smzButton smzRipple type=\"button\" icon=\"fa-solid fa-rotate\" smzTooltip=\"Atualizar\" class=\"mr-3\" (click)=\"refresh()\" [rounded]=\"true\" variant=\"text\" styleClass=\"p-button-plain\"></button>\r\n }\r\n <ui-select-button appendTo=\"body\" [options]=\"folders\" [(ngModel)]=\"currentFolder\" optionLabel=\"icon\" (changed)=\"currentFolder.rebuild()\">\r\n <ng-template #item let-item>\r\n <i [ngClass]=\"item.icon\" [smzTooltip]=\"item.tooltip\"></i>\r\n <span class=\"ml-1 text-sm\">({{ item.count$ | async }})</span>\r\n </ng-template>\r\n </ui-select-button>\r\n </ng-template>\r\n\r\n <!-- CONTE\u00DADOS COM OVERRIDE -->\r\n <ng-template smzTemplate=\"content\" let-item let-col=\"col\">\r\n\r\n @switch (col.field) {\r\n @case ('searchData') {\r\n <div class=\"grid grid-nogutter items-center justify-between\" (mouseenter)=\"item._showActions = true\" (mouseleave)=\"item._showActions = false\">\r\n <div class=\"col\">\r\n <smz-notification-item [item]=\"item\" [showDate]=\"true\"></smz-notification-item>\r\n </div>\r\n @if (item._showActions) {\r\n <div class=\"grid grid-nogutter items-center justify-start gap-4 flex-col pl-4 animate__animated animate__fadeIn relative\" clickStopPropagation>\r\n @if (item.status !== status.ARCHIVED) {\r\n <i #archiveButton smzTooltip=\"Arquivar\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-box-archive p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"archive([item])\"></i>\r\n }\r\n @if (item.status === status.ARCHIVED) {\r\n <i #inboxButton smzTooltip=\"Desarquivar\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-inbox p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"moveToInbox([item])\"></i>\r\n }\r\n @if (item.route != '') {\r\n <i #routeButton smzTooltip=\"Navegar\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-share p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"navigate(item)\"></i>\r\n }\r\n @if (item.link != '') {\r\n <i #linkButton smzTooltip=\"Abrir Link\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-up-right-from-square p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"openLink(item)\"></i>\r\n }\r\n <i #trashButton smzTooltip=\"Excluir\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-trash p-button-rounded p-button-text p-button-plain relative text-gray-500\" styleClass=\"relative\" (click)=\"remove(item)\"></i>\r\n </div>\r\n }\r\n </div>\r\n }\r\n }\r\n\r\n </ng-template>\r\n\r\n </smz-ui-table>\r\n\r\n</ng-container>", styles: ["smz-notifications-list .database-title{font-size:1.2rem}smz-notifications-list i .p-tooltip .p-tooltip-text{word-break:normal}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "validChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "directive", type: i2.SmzTooltipDirective, selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "component", type: i2.SmzSelectButtonComponent, selector: "ui-select-button", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "multiple", "allowEmpty", "size", "styleClass", "appendTo"], outputs: ["changed"] }, { kind: "directive", type: NgVar, selector: "[ngVar]", inputs: ["ngVar"] }, { kind: "directive", type: ClickStopPropagationDirective, selector: "[clickStopPropagation]" }, { kind: "component", type: NotificationItemComponent, selector: "smz-notification-item", inputs: ["item", "charactersLimit", "showDate"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: FilterByPipe, name: "filterBy" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
41230
41284
|
}
|
|
41231
41285
|
__decorate([
|
|
41232
41286
|
Confirmable('Deseja realmente excluir as notificações selecionadas ?<br>Está operação não poderá ser desfeita.', 'Exclusão', true)
|
|
@@ -41236,18 +41290,18 @@ __decorate([
|
|
|
41236
41290
|
], NotificationsListComponent.prototype, "remove", null);
|
|
41237
41291
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: NotificationsListComponent, decorators: [{
|
|
41238
41292
|
type: Component,
|
|
41239
|
-
args: [{ selector: 'smz-notifications-list', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, standalone: false, template: "<ng-container *ngVar=\"hasRuningRequest$ | async as hasRuningRequest\">\n\n <smz-ui-table #smzTable [items]=\"(notifications$ | async) | filterBy : ['status'] : currentFolder.status\" [state]=\"tableState\" [loading]=\"hasRuningRequest\" (selectionChange)=\"onSelect($event)\">\n\n <ng-template smzTemplate=\"caption\" let-primeTable>\n @if (uiConfig.rbkUtils.notifications.showRefreshButton) {\n <button smzButton smzRipple type=\"button\" icon=\"fa-solid fa-rotate\" smzTooltip=\"Atualizar\" class=\"mr-3\" (click)=\"refresh()\" [rounded]=\"true\" variant=\"text\" styleClass=\"p-button-plain\"></button>\n }\n <ui-select-button appendTo=\"body\" [options]=\"folders\" [(ngModel)]=\"currentFolder\" optionLabel=\"icon\" (changed)=\"currentFolder.rebuild()\">\n <ng-template #item let-item>\n <i [ngClass]=\"item.icon\" [smzTooltip]=\"item.tooltip\"></i>\n <span class=\"ml-1 text-sm\">({{ item.count$ | async }})</span>\n </ng-template>\n </ui-select-button>\n </ng-template>\n\n <!-- CONTE\u00DADOS COM OVERRIDE -->\n <ng-template smzTemplate=\"content\" let-item let-col=\"col\">\n\n @switch (col.field) {\n @case ('searchData') {\n <div class=\"grid grid-nogutter items-center justify-between\" (mouseenter)=\"item._showActions = true\" (mouseleave)=\"item._showActions = false\">\n <div class=\"col\">\n <smz-notification-item [item]=\"item\" [showDate]=\"true\"></smz-notification-item>\n </div>\n @if (item._showActions) {\n <div class=\"grid grid-nogutter items-center justify-start gap-4 flex-col pl-4 animate__animated animate__fadeIn relative\" clickStopPropagation>\n @if (item.status !== status.ARCHIVED) {\n <i #archiveButton smzTooltip=\"Arquivar\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-box-archive p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"archive([item])\"></i>\n }\n @if (item.status === status.ARCHIVED) {\n <i #inboxButton smzTooltip=\"Desarquivar\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-inbox p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"moveToInbox([item])\"></i>\n }\n @if (item.route != '') {\n <i #routeButton smzTooltip=\"Navegar\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-share p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"navigate(item)\"></i>\n }\n @if (item.link != '') {\n <i #linkButton smzTooltip=\"Abrir Link\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-up-right-from-square p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"openLink(item)\"></i>\n }\n <i #trashButton smzTooltip=\"Excluir\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-trash p-button-rounded p-button-text p-button-plain relative text-gray-500\" styleClass=\"relative\" (click)=\"remove(item)\"></i>\n </div>\n }\n </div>\n }\n }\n\n </ng-template>\n\n </smz-ui-table>\n\n</ng-container>", styles: ["smz-notifications-list .database-title{font-size:1.2rem}smz-notifications-list i .p-tooltip .p-tooltip-text{word-break:normal}\n"] }]
|
|
41293
|
+
args: [{ selector: 'smz-notifications-list', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, standalone: false, template: "<ng-container *ngVar=\"hasRuningRequest$ | async as hasRuningRequest\">\r\n\r\n <smz-ui-table #smzTable [items]=\"(notifications$ | async) | filterBy : ['status'] : currentFolder.status\" [state]=\"tableState\" [loading]=\"hasRuningRequest\" (selectionChange)=\"onSelect($event)\">\r\n\r\n <ng-template smzTemplate=\"caption\" let-primeTable>\r\n @if (uiConfig.rbkUtils.notifications.showRefreshButton) {\r\n <button smzButton smzRipple type=\"button\" icon=\"fa-solid fa-rotate\" smzTooltip=\"Atualizar\" class=\"mr-3\" (click)=\"refresh()\" [rounded]=\"true\" variant=\"text\" styleClass=\"p-button-plain\"></button>\r\n }\r\n <ui-select-button appendTo=\"body\" [options]=\"folders\" [(ngModel)]=\"currentFolder\" optionLabel=\"icon\" (changed)=\"currentFolder.rebuild()\">\r\n <ng-template #item let-item>\r\n <i [ngClass]=\"item.icon\" [smzTooltip]=\"item.tooltip\"></i>\r\n <span class=\"ml-1 text-sm\">({{ item.count$ | async }})</span>\r\n </ng-template>\r\n </ui-select-button>\r\n </ng-template>\r\n\r\n <!-- CONTE\u00DADOS COM OVERRIDE -->\r\n <ng-template smzTemplate=\"content\" let-item let-col=\"col\">\r\n\r\n @switch (col.field) {\r\n @case ('searchData') {\r\n <div class=\"grid grid-nogutter items-center justify-between\" (mouseenter)=\"item._showActions = true\" (mouseleave)=\"item._showActions = false\">\r\n <div class=\"col\">\r\n <smz-notification-item [item]=\"item\" [showDate]=\"true\"></smz-notification-item>\r\n </div>\r\n @if (item._showActions) {\r\n <div class=\"grid grid-nogutter items-center justify-start gap-4 flex-col pl-4 animate__animated animate__fadeIn relative\" clickStopPropagation>\r\n @if (item.status !== status.ARCHIVED) {\r\n <i #archiveButton smzTooltip=\"Arquivar\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-box-archive p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"archive([item])\"></i>\r\n }\r\n @if (item.status === status.ARCHIVED) {\r\n <i #inboxButton smzTooltip=\"Desarquivar\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-inbox p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"moveToInbox([item])\"></i>\r\n }\r\n @if (item.route != '') {\r\n <i #routeButton smzTooltip=\"Navegar\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-share p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"navigate(item)\"></i>\r\n }\r\n @if (item.link != '') {\r\n <i #linkButton smzTooltip=\"Abrir Link\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-up-right-from-square p-button-rounded p-button-text p-button-plain relative text-gray-500\" (click)=\"openLink(item)\"></i>\r\n }\r\n <i #trashButton smzTooltip=\"Excluir\" appendTo=\"body\" tooltipZIndex=\"9999\" tooltipPosition=\"bottom\" class=\"fa-solid fa-trash p-button-rounded p-button-text p-button-plain relative text-gray-500\" styleClass=\"relative\" (click)=\"remove(item)\"></i>\r\n </div>\r\n }\r\n </div>\r\n }\r\n }\r\n\r\n </ng-template>\r\n\r\n </smz-ui-table>\r\n\r\n</ng-container>", styles: ["smz-notifications-list .database-title{font-size:1.2rem}smz-notifications-list i .p-tooltip .p-tooltip-text{word-break:normal}\n"] }]
|
|
41240
41294
|
}], ctorParameters: () => [], propDecorators: { batchRemove: [], remove: [] } });
|
|
41241
41295
|
|
|
41242
41296
|
function showNotificationsDialog() {
|
|
41243
41297
|
const dialogs = GlobalInjector.instance.get(SmzDialogsService);
|
|
41244
41298
|
dialogs.open(new SmzDialogBuilder()
|
|
41245
41299
|
.setTitle('Notificações')
|
|
41246
|
-
.setLayout('EXTRA_LARGE',
|
|
41247
|
-
.setLayout('LARGE',
|
|
41248
|
-
.setLayout('MEDIUM',
|
|
41249
|
-
.setLayout('SMALL',
|
|
41250
|
-
.setLayout('EXTRA_SMALL',
|
|
41300
|
+
.setLayout('EXTRA_LARGE', 12)
|
|
41301
|
+
.setLayout('LARGE', 12)
|
|
41302
|
+
.setLayout('MEDIUM', 12)
|
|
41303
|
+
.setLayout('SMALL', 12)
|
|
41304
|
+
.setLayout('EXTRA_SMALL', 12)
|
|
41251
41305
|
.hideFooter()
|
|
41252
41306
|
.openMaximized()
|
|
41253
41307
|
.setMinHeight(80)
|
|
@@ -41269,11 +41323,11 @@ class SmzNotificationsComponent {
|
|
|
41269
41323
|
showNotificationsDialog();
|
|
41270
41324
|
}
|
|
41271
41325
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzNotificationsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
41272
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzNotificationsComponent, isStandalone: false, selector: "smz-ui-notifications", ngImport: i0, template: "@if (notifications$ | async; as notifications) {\n <smz-responsive class=\"col grid grid-nogutter w-full items-center justify-start\">\n <!-- LANDSCAPE -->\n <ng-template smzTemplate=\"landscape\">\n <i class=\"fa-solid fa-bell badge-color regular-badge\" smzBadge [value]=\"(newCount$ | async).toString()\">\n <div class=\"absolute inset-0 notification-container cursor-pointer\" (click)=\"op.toggle($event)\"></div>\n </i>\n <ui-popover #op [style]=\"{ 'width': uiConfig.rbkUtils.notifications.width, 'z-index': uiConfig.rbkUtils.notifications.zIndex }\" [styleClass]=\"uiConfig.rbkUtils.notifications.styleClass\" appendTo=\"body\" [autoZIndex]=\"false\">\n <smz-notifications-list></smz-notifications-list>\n </ui-popover>\n </ng-template>\n <!-- PORTRAIT -->\n <ng-template smzTemplate=\"portrait\">\n <i class=\"fa-solid fa-bell badge-color regular-badge\" smzBadge [value]=\"(newCount$ | async).toString()\">\n <div class=\"absolute inset-0 notification-container cursor-pointer\" (click)=\"showDialog()\"></div>\n </i>\n </ng-template>\n </smz-responsive>\n}", styles: ["smz-ui-notifications .notification-container{min-width:40px}smz-ui-notifications .badge-color{color:var(--text-color-secondary)}smz-ui-notifications .p-badge{background:var(--surface-a);color:var(--primary-color)}smz-ui-notifications .regular-badge{font-size:1.6rem;line-height:1.6rem}smz-ui-notifications .regular-badge .p-badge{font-size:.8rem;font-weight:700;min-width:1.1rem;height:1.1rem;line-height:1.1rem}\n"], dependencies: [{ kind: "directive", type: i2.SmzBadgeDirective, selector: "[smzBadge]", inputs: ["value", "severity"] }, { kind: "component", type: i2.SmzPopoverComponent, selector: "ui-popover", inputs: ["style", "styleClass", "dismissable", "autoZIndex", "appendTo"], outputs: ["shown", "hidden"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: SmzResponsiveComponent, selector: "smz-responsive" }, { kind: "component", type: NotificationsListComponent, selector: "smz-notifications-list" }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
41326
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzNotificationsComponent, isStandalone: false, selector: "smz-ui-notifications", ngImport: i0, template: "@if (notifications$ | async; as notifications) {\r\n <smz-responsive class=\"col grid grid-nogutter w-full items-center justify-start\">\r\n <!-- LANDSCAPE -->\r\n <ng-template smzTemplate=\"landscape\">\r\n <i class=\"fa-solid fa-bell badge-color regular-badge\" smzBadge [value]=\"(newCount$ | async).toString()\">\r\n <div class=\"absolute inset-0 notification-container cursor-pointer\" (click)=\"op.toggle($event)\"></div>\r\n </i>\r\n <ui-popover #op [style]=\"{ 'width': uiConfig.rbkUtils.notifications.width, 'z-index': uiConfig.rbkUtils.notifications.zIndex }\" [styleClass]=\"uiConfig.rbkUtils.notifications.styleClass\" appendTo=\"body\" [autoZIndex]=\"false\">\r\n <smz-notifications-list></smz-notifications-list>\r\n </ui-popover>\r\n </ng-template>\r\n <!-- PORTRAIT -->\r\n <ng-template smzTemplate=\"portrait\">\r\n <i class=\"fa-solid fa-bell badge-color regular-badge\" smzBadge [value]=\"(newCount$ | async).toString()\">\r\n <div class=\"absolute inset-0 notification-container cursor-pointer\" (click)=\"showDialog()\"></div>\r\n </i>\r\n </ng-template>\r\n </smz-responsive>\r\n}", styles: ["smz-ui-notifications .notification-container{min-width:40px}smz-ui-notifications .badge-color{color:var(--text-color-secondary)}smz-ui-notifications .p-badge{background:var(--surface-a);color:var(--primary-color)}smz-ui-notifications .regular-badge{font-size:1.6rem;line-height:1.6rem}smz-ui-notifications .regular-badge .p-badge{font-size:.8rem;font-weight:700;min-width:1.1rem;height:1.1rem;line-height:1.1rem}\n"], dependencies: [{ kind: "directive", type: i2.SmzBadgeDirective, selector: "[smzBadge]", inputs: ["value", "severity"] }, { kind: "component", type: i2.SmzPopoverComponent, selector: "ui-popover", inputs: ["style", "styleClass", "dismissable", "autoZIndex", "appendTo"], outputs: ["shown", "hidden"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: SmzResponsiveComponent, selector: "smz-responsive" }, { kind: "component", type: NotificationsListComponent, selector: "smz-notifications-list" }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
41273
41327
|
}
|
|
41274
41328
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzNotificationsComponent, decorators: [{
|
|
41275
41329
|
type: Component,
|
|
41276
|
-
args: [{ selector: 'smz-ui-notifications', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, standalone: false, template: "@if (notifications$ | async; as notifications) {\n <smz-responsive class=\"col grid grid-nogutter w-full items-center justify-start\">\n <!-- LANDSCAPE -->\n <ng-template smzTemplate=\"landscape\">\n <i class=\"fa-solid fa-bell badge-color regular-badge\" smzBadge [value]=\"(newCount$ | async).toString()\">\n <div class=\"absolute inset-0 notification-container cursor-pointer\" (click)=\"op.toggle($event)\"></div>\n </i>\n <ui-popover #op [style]=\"{ 'width': uiConfig.rbkUtils.notifications.width, 'z-index': uiConfig.rbkUtils.notifications.zIndex }\" [styleClass]=\"uiConfig.rbkUtils.notifications.styleClass\" appendTo=\"body\" [autoZIndex]=\"false\">\n <smz-notifications-list></smz-notifications-list>\n </ui-popover>\n </ng-template>\n <!-- PORTRAIT -->\n <ng-template smzTemplate=\"portrait\">\n <i class=\"fa-solid fa-bell badge-color regular-badge\" smzBadge [value]=\"(newCount$ | async).toString()\">\n <div class=\"absolute inset-0 notification-container cursor-pointer\" (click)=\"showDialog()\"></div>\n </i>\n </ng-template>\n </smz-responsive>\n}", styles: ["smz-ui-notifications .notification-container{min-width:40px}smz-ui-notifications .badge-color{color:var(--text-color-secondary)}smz-ui-notifications .p-badge{background:var(--surface-a);color:var(--primary-color)}smz-ui-notifications .regular-badge{font-size:1.6rem;line-height:1.6rem}smz-ui-notifications .regular-badge .p-badge{font-size:.8rem;font-weight:700;min-width:1.1rem;height:1.1rem;line-height:1.1rem}\n"] }]
|
|
41330
|
+
args: [{ selector: 'smz-ui-notifications', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, standalone: false, template: "@if (notifications$ | async; as notifications) {\r\n <smz-responsive class=\"col grid grid-nogutter w-full items-center justify-start\">\r\n <!-- LANDSCAPE -->\r\n <ng-template smzTemplate=\"landscape\">\r\n <i class=\"fa-solid fa-bell badge-color regular-badge\" smzBadge [value]=\"(newCount$ | async).toString()\">\r\n <div class=\"absolute inset-0 notification-container cursor-pointer\" (click)=\"op.toggle($event)\"></div>\r\n </i>\r\n <ui-popover #op [style]=\"{ 'width': uiConfig.rbkUtils.notifications.width, 'z-index': uiConfig.rbkUtils.notifications.zIndex }\" [styleClass]=\"uiConfig.rbkUtils.notifications.styleClass\" appendTo=\"body\" [autoZIndex]=\"false\">\r\n <smz-notifications-list></smz-notifications-list>\r\n </ui-popover>\r\n </ng-template>\r\n <!-- PORTRAIT -->\r\n <ng-template smzTemplate=\"portrait\">\r\n <i class=\"fa-solid fa-bell badge-color regular-badge\" smzBadge [value]=\"(newCount$ | async).toString()\">\r\n <div class=\"absolute inset-0 notification-container cursor-pointer\" (click)=\"showDialog()\"></div>\r\n </i>\r\n </ng-template>\r\n </smz-responsive>\r\n}", styles: ["smz-ui-notifications .notification-container{min-width:40px}smz-ui-notifications .badge-color{color:var(--text-color-secondary)}smz-ui-notifications .p-badge{background:var(--surface-a);color:var(--primary-color)}smz-ui-notifications .regular-badge{font-size:1.6rem;line-height:1.6rem}smz-ui-notifications .regular-badge .p-badge{font-size:.8rem;font-weight:700;min-width:1.1rem;height:1.1rem;line-height:1.1rem}\n"] }]
|
|
41277
41331
|
}], ctorParameters: () => [] });
|
|
41278
41332
|
|
|
41279
41333
|
/* eslint-disable @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-unsafe-member-access, @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-return, @typescript-eslint/explicit-module-boundary-types, @typescript-eslint/explicit-function-return-type, @typescript-eslint/typedef, no-underscore-dangle, no-console, eqeqeq, @typescript-eslint/no-unused-vars, @typescript-eslint/no-useless-constructor, @typescript-eslint/explicit-member-accessibility, max-len, no-prototype-builtins, @typescript-eslint/no-shadow, @typescript-eslint/no-empty-object-type */
|
|
@@ -42655,38 +42709,38 @@ class NewAthenaNotificationItemsComponent {
|
|
|
42655
42709
|
}
|
|
42656
42710
|
}
|
|
42657
42711
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: NewAthenaNotificationItemsComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
42658
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: NewAthenaNotificationItemsComponent, isStandalone: false, selector: "[smz-ui-new-athena-notification-items]", inputs: { items: "items" }, outputs: { onClose: "onClose" }, host: { listeners: { "document:click": "collapse($event)" } }, ngImport: i0, template: `
|
|
42659
|
-
@for (item of items; track item; let index = $index) {
|
|
42660
|
-
<li role="menuitem">
|
|
42661
|
-
<a menuItemAction class="grid grid-nogutter items-center justify-start" style="display: flex;" [item]="item" [parent]="null" [breadcrumbs]="false" [tabindex]="index">
|
|
42662
|
-
@if (item.icon != null) {
|
|
42663
|
-
<i class="fa-solid mr-3" [ngClass]="item.icon"></i>
|
|
42664
|
-
}
|
|
42665
|
-
<div class="notification-item">
|
|
42666
|
-
<div class="notification-summary">{{ item.summary }}</div>
|
|
42667
|
-
<div class="notification-detail" [innerHtml]="item.details"></div>
|
|
42668
|
-
</div>
|
|
42669
|
-
</a>
|
|
42670
|
-
</li>
|
|
42671
|
-
}
|
|
42712
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: NewAthenaNotificationItemsComponent, isStandalone: false, selector: "[smz-ui-new-athena-notification-items]", inputs: { items: "items" }, outputs: { onClose: "onClose" }, host: { listeners: { "document:click": "collapse($event)" } }, ngImport: i0, template: `
|
|
42713
|
+
@for (item of items; track item; let index = $index) {
|
|
42714
|
+
<li role="menuitem">
|
|
42715
|
+
<a menuItemAction class="grid grid-nogutter items-center justify-start" style="display: flex;" [item]="item" [parent]="null" [breadcrumbs]="false" [tabindex]="index">
|
|
42716
|
+
@if (item.icon != null) {
|
|
42717
|
+
<i class="fa-solid mr-3" [ngClass]="item.icon"></i>
|
|
42718
|
+
}
|
|
42719
|
+
<div class="notification-item">
|
|
42720
|
+
<div class="notification-summary">{{ item.summary }}</div>
|
|
42721
|
+
<div class="notification-detail" [innerHtml]="item.details"></div>
|
|
42722
|
+
</div>
|
|
42723
|
+
</a>
|
|
42724
|
+
</li>
|
|
42725
|
+
}
|
|
42672
42726
|
`, isInline: true, styles: [".notification-summary{font-weight:600}.notification-detail{font-weight:400}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: MenuItemActionsDirective, selector: "[menuItemAction]", inputs: ["item", "parent", "breadcrumbs"], outputs: ["collapse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
42673
42727
|
}
|
|
42674
42728
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: NewAthenaNotificationItemsComponent, decorators: [{
|
|
42675
42729
|
type: Component,
|
|
42676
|
-
args: [{ selector: '[smz-ui-new-athena-notification-items]', host: { '(document:click)': 'collapse($event)' }, changeDetection: ChangeDetectionStrategy.OnPush, template: `
|
|
42677
|
-
@for (item of items; track item; let index = $index) {
|
|
42678
|
-
<li role="menuitem">
|
|
42679
|
-
<a menuItemAction class="grid grid-nogutter items-center justify-start" style="display: flex;" [item]="item" [parent]="null" [breadcrumbs]="false" [tabindex]="index">
|
|
42680
|
-
@if (item.icon != null) {
|
|
42681
|
-
<i class="fa-solid mr-3" [ngClass]="item.icon"></i>
|
|
42682
|
-
}
|
|
42683
|
-
<div class="notification-item">
|
|
42684
|
-
<div class="notification-summary">{{ item.summary }}</div>
|
|
42685
|
-
<div class="notification-detail" [innerHtml]="item.details"></div>
|
|
42686
|
-
</div>
|
|
42687
|
-
</a>
|
|
42688
|
-
</li>
|
|
42689
|
-
}
|
|
42730
|
+
args: [{ selector: '[smz-ui-new-athena-notification-items]', host: { '(document:click)': 'collapse($event)' }, changeDetection: ChangeDetectionStrategy.OnPush, template: `
|
|
42731
|
+
@for (item of items; track item; let index = $index) {
|
|
42732
|
+
<li role="menuitem">
|
|
42733
|
+
<a menuItemAction class="grid grid-nogutter items-center justify-start" style="display: flex;" [item]="item" [parent]="null" [breadcrumbs]="false" [tabindex]="index">
|
|
42734
|
+
@if (item.icon != null) {
|
|
42735
|
+
<i class="fa-solid mr-3" [ngClass]="item.icon"></i>
|
|
42736
|
+
}
|
|
42737
|
+
<div class="notification-item">
|
|
42738
|
+
<div class="notification-summary">{{ item.summary }}</div>
|
|
42739
|
+
<div class="notification-detail" [innerHtml]="item.details"></div>
|
|
42740
|
+
</div>
|
|
42741
|
+
</a>
|
|
42742
|
+
</li>
|
|
42743
|
+
}
|
|
42690
42744
|
`, standalone: false, styles: [".notification-summary{font-weight:600}.notification-detail{font-weight:400}\n"] }]
|
|
42691
42745
|
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { items: [{
|
|
42692
42746
|
type: Input
|
|
@@ -42760,148 +42814,148 @@ class AthenaTopbarActionsComponent {
|
|
|
42760
42814
|
showLocalizationSwitch = GlobalInjector.config.rbkUtils.uiLocalization.allowLocalizationSwitching;
|
|
42761
42815
|
showTenantSwitch = GlobalInjector.config.rbkUtils.authentication.allowTenantSwitching;
|
|
42762
42816
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: AthenaTopbarActionsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
42763
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: AthenaTopbarActionsComponent, isStandalone: false, selector: "[smz-ui-new-athena-topbar-actions]", inputs: { profile: "profile", notifications: "notifications", headerExtrasTemplate: "headerExtrasTemplate" }, ngImport: i0, template: `
|
|
42764
|
-
<ng-content></ng-content>
|
|
42765
|
-
|
|
42766
|
-
<div id="smz-ui-topbar"></div>
|
|
42767
|
-
|
|
42768
|
-
<smz-responsive class="col grid grid-nogutter w-full items-center justify-start gap-5">
|
|
42769
|
-
|
|
42770
|
-
<!-- LANDSCAPE -->
|
|
42771
|
-
<ng-template smzTemplate="landscape">
|
|
42772
|
-
|
|
42773
|
-
<span class="col extras-container justify-end extras-container">
|
|
42774
|
-
@if (headerExtrasTemplate != null) {
|
|
42775
|
-
<ng-container *ngTemplateOutlet="headerExtrasTemplate"></ng-container>
|
|
42776
|
-
}
|
|
42777
|
-
</span>
|
|
42778
|
-
|
|
42779
|
-
@if (uiConfig.rbkUtils.notifications.url != null) {
|
|
42780
|
-
<smz-ui-notifications id="smz-ui-notifications" class="mt-2"></smz-ui-notifications>
|
|
42781
|
-
} @else {
|
|
42782
|
-
@if (notifications != null) {
|
|
42783
|
-
<span class="notification-container" smz-ui-new-athena-notifications [items]="notifications"></span>
|
|
42784
|
-
}
|
|
42785
|
-
}
|
|
42786
|
-
|
|
42787
|
-
|
|
42788
|
-
@if (showLocalizationSwitch) {
|
|
42789
|
-
<smz-localization-switch></smz-localization-switch>
|
|
42790
|
-
}
|
|
42791
|
-
|
|
42792
|
-
@if (showTenantSwitch) {
|
|
42793
|
-
<smz-tenant-switch></smz-tenant-switch>
|
|
42794
|
-
}
|
|
42795
|
-
|
|
42796
|
-
@if (profile != null) {
|
|
42797
|
-
<span id="smz-ui-profile-menu" smz-ui-new-athena-profile-menu [profile]="profile"></span>
|
|
42798
|
-
}
|
|
42799
|
-
|
|
42800
|
-
</ng-template>
|
|
42801
|
-
|
|
42802
|
-
<!-- PORTRAIT -->
|
|
42803
|
-
<ng-template smzTemplate="portrait">
|
|
42804
|
-
|
|
42805
|
-
<span class="col extras-container justify-end extras-container">
|
|
42806
|
-
@if (headerExtrasTemplate != null) {
|
|
42807
|
-
<ng-container *ngTemplateOutlet="headerExtrasTemplate"></ng-container>
|
|
42808
|
-
}
|
|
42809
|
-
</span>
|
|
42810
|
-
|
|
42811
|
-
@if (uiConfig.rbkUtils.notifications.url != null) {
|
|
42812
|
-
<smz-ui-notifications id="smz-ui-notifications" class="mt-2"></smz-ui-notifications>
|
|
42813
|
-
} @else {
|
|
42814
|
-
@if (notifications != null) {
|
|
42815
|
-
<span class="notification-container" smz-ui-new-athena-notifications [items]="notifications"></span>
|
|
42816
|
-
}
|
|
42817
|
-
}
|
|
42818
|
-
|
|
42819
|
-
|
|
42820
|
-
@if (showTenantSwitch) {
|
|
42821
|
-
<smz-tenant-switch></smz-tenant-switch>
|
|
42822
|
-
}
|
|
42823
|
-
|
|
42824
|
-
@if (profile != null) {
|
|
42825
|
-
<span id="smz-ui-profile-menu" smz-ui-new-athena-profile-menu [profile]="profile"></span>
|
|
42826
|
-
}
|
|
42827
|
-
|
|
42828
|
-
</ng-template>
|
|
42829
|
-
|
|
42830
|
-
</smz-responsive>
|
|
42831
|
-
|
|
42817
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: AthenaTopbarActionsComponent, isStandalone: false, selector: "[smz-ui-new-athena-topbar-actions]", inputs: { profile: "profile", notifications: "notifications", headerExtrasTemplate: "headerExtrasTemplate" }, ngImport: i0, template: `
|
|
42818
|
+
<ng-content></ng-content>
|
|
42819
|
+
|
|
42820
|
+
<div id="smz-ui-topbar"></div>
|
|
42821
|
+
|
|
42822
|
+
<smz-responsive class="col grid grid-nogutter w-full items-center justify-start gap-5">
|
|
42823
|
+
|
|
42824
|
+
<!-- LANDSCAPE -->
|
|
42825
|
+
<ng-template smzTemplate="landscape">
|
|
42826
|
+
|
|
42827
|
+
<span class="col extras-container justify-end extras-container">
|
|
42828
|
+
@if (headerExtrasTemplate != null) {
|
|
42829
|
+
<ng-container *ngTemplateOutlet="headerExtrasTemplate"></ng-container>
|
|
42830
|
+
}
|
|
42831
|
+
</span>
|
|
42832
|
+
|
|
42833
|
+
@if (uiConfig.rbkUtils.notifications.url != null) {
|
|
42834
|
+
<smz-ui-notifications id="smz-ui-notifications" class="mt-2"></smz-ui-notifications>
|
|
42835
|
+
} @else {
|
|
42836
|
+
@if (notifications != null) {
|
|
42837
|
+
<span class="notification-container" smz-ui-new-athena-notifications [items]="notifications"></span>
|
|
42838
|
+
}
|
|
42839
|
+
}
|
|
42840
|
+
|
|
42841
|
+
|
|
42842
|
+
@if (showLocalizationSwitch) {
|
|
42843
|
+
<smz-localization-switch></smz-localization-switch>
|
|
42844
|
+
}
|
|
42845
|
+
|
|
42846
|
+
@if (showTenantSwitch) {
|
|
42847
|
+
<smz-tenant-switch></smz-tenant-switch>
|
|
42848
|
+
}
|
|
42849
|
+
|
|
42850
|
+
@if (profile != null) {
|
|
42851
|
+
<span id="smz-ui-profile-menu" smz-ui-new-athena-profile-menu [profile]="profile"></span>
|
|
42852
|
+
}
|
|
42853
|
+
|
|
42854
|
+
</ng-template>
|
|
42855
|
+
|
|
42856
|
+
<!-- PORTRAIT -->
|
|
42857
|
+
<ng-template smzTemplate="portrait">
|
|
42858
|
+
|
|
42859
|
+
<span class="col extras-container justify-end extras-container">
|
|
42860
|
+
@if (headerExtrasTemplate != null) {
|
|
42861
|
+
<ng-container *ngTemplateOutlet="headerExtrasTemplate"></ng-container>
|
|
42862
|
+
}
|
|
42863
|
+
</span>
|
|
42864
|
+
|
|
42865
|
+
@if (uiConfig.rbkUtils.notifications.url != null) {
|
|
42866
|
+
<smz-ui-notifications id="smz-ui-notifications" class="mt-2"></smz-ui-notifications>
|
|
42867
|
+
} @else {
|
|
42868
|
+
@if (notifications != null) {
|
|
42869
|
+
<span class="notification-container" smz-ui-new-athena-notifications [items]="notifications"></span>
|
|
42870
|
+
}
|
|
42871
|
+
}
|
|
42872
|
+
|
|
42873
|
+
|
|
42874
|
+
@if (showTenantSwitch) {
|
|
42875
|
+
<smz-tenant-switch></smz-tenant-switch>
|
|
42876
|
+
}
|
|
42877
|
+
|
|
42878
|
+
@if (profile != null) {
|
|
42879
|
+
<span id="smz-ui-profile-menu" smz-ui-new-athena-profile-menu [profile]="profile"></span>
|
|
42880
|
+
}
|
|
42881
|
+
|
|
42882
|
+
</ng-template>
|
|
42883
|
+
|
|
42884
|
+
</smz-responsive>
|
|
42885
|
+
|
|
42832
42886
|
`, isInline: true, styles: [".notification-container{position:relative;font-weight:700;margin-top:0;margin-right:30px;color:var(--text-color-secondary)}.extras-container{position:relative;height:100%;display:flex;align-items:center;color:var(--text-color-secondary)}\n"], dependencies: [{ kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: NewAthenaProfileMenuComponent, selector: "[smz-ui-new-athena-profile-menu]", inputs: ["profile"] }, { kind: "component", type: NewAthenaNotificationsComponent, selector: "[smz-ui-new-athena-notifications]", inputs: ["items"] }, { kind: "component", type: SmzNotificationsComponent, selector: "smz-ui-notifications" }, { kind: "component", type: SmzTenantSwitchComponent, selector: "smz-tenant-switch" }, { kind: "component", type: SmzLocalizationSwitchComponent, selector: "smz-localization-switch" }, { kind: "component", type: SmzResponsiveComponent, selector: "smz-responsive" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
42833
42887
|
}
|
|
42834
42888
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: AthenaTopbarActionsComponent, decorators: [{
|
|
42835
42889
|
type: Component,
|
|
42836
|
-
args: [{ selector: '[smz-ui-new-athena-topbar-actions]', changeDetection: ChangeDetectionStrategy.Default, template: `
|
|
42837
|
-
<ng-content></ng-content>
|
|
42838
|
-
|
|
42839
|
-
<div id="smz-ui-topbar"></div>
|
|
42840
|
-
|
|
42841
|
-
<smz-responsive class="col grid grid-nogutter w-full items-center justify-start gap-5">
|
|
42842
|
-
|
|
42843
|
-
<!-- LANDSCAPE -->
|
|
42844
|
-
<ng-template smzTemplate="landscape">
|
|
42845
|
-
|
|
42846
|
-
<span class="col extras-container justify-end extras-container">
|
|
42847
|
-
@if (headerExtrasTemplate != null) {
|
|
42848
|
-
<ng-container *ngTemplateOutlet="headerExtrasTemplate"></ng-container>
|
|
42849
|
-
}
|
|
42850
|
-
</span>
|
|
42851
|
-
|
|
42852
|
-
@if (uiConfig.rbkUtils.notifications.url != null) {
|
|
42853
|
-
<smz-ui-notifications id="smz-ui-notifications" class="mt-2"></smz-ui-notifications>
|
|
42854
|
-
} @else {
|
|
42855
|
-
@if (notifications != null) {
|
|
42856
|
-
<span class="notification-container" smz-ui-new-athena-notifications [items]="notifications"></span>
|
|
42857
|
-
}
|
|
42858
|
-
}
|
|
42859
|
-
|
|
42860
|
-
|
|
42861
|
-
@if (showLocalizationSwitch) {
|
|
42862
|
-
<smz-localization-switch></smz-localization-switch>
|
|
42863
|
-
}
|
|
42864
|
-
|
|
42865
|
-
@if (showTenantSwitch) {
|
|
42866
|
-
<smz-tenant-switch></smz-tenant-switch>
|
|
42867
|
-
}
|
|
42868
|
-
|
|
42869
|
-
@if (profile != null) {
|
|
42870
|
-
<span id="smz-ui-profile-menu" smz-ui-new-athena-profile-menu [profile]="profile"></span>
|
|
42871
|
-
}
|
|
42872
|
-
|
|
42873
|
-
</ng-template>
|
|
42874
|
-
|
|
42875
|
-
<!-- PORTRAIT -->
|
|
42876
|
-
<ng-template smzTemplate="portrait">
|
|
42877
|
-
|
|
42878
|
-
<span class="col extras-container justify-end extras-container">
|
|
42879
|
-
@if (headerExtrasTemplate != null) {
|
|
42880
|
-
<ng-container *ngTemplateOutlet="headerExtrasTemplate"></ng-container>
|
|
42881
|
-
}
|
|
42882
|
-
</span>
|
|
42883
|
-
|
|
42884
|
-
@if (uiConfig.rbkUtils.notifications.url != null) {
|
|
42885
|
-
<smz-ui-notifications id="smz-ui-notifications" class="mt-2"></smz-ui-notifications>
|
|
42886
|
-
} @else {
|
|
42887
|
-
@if (notifications != null) {
|
|
42888
|
-
<span class="notification-container" smz-ui-new-athena-notifications [items]="notifications"></span>
|
|
42889
|
-
}
|
|
42890
|
-
}
|
|
42891
|
-
|
|
42892
|
-
|
|
42893
|
-
@if (showTenantSwitch) {
|
|
42894
|
-
<smz-tenant-switch></smz-tenant-switch>
|
|
42895
|
-
}
|
|
42896
|
-
|
|
42897
|
-
@if (profile != null) {
|
|
42898
|
-
<span id="smz-ui-profile-menu" smz-ui-new-athena-profile-menu [profile]="profile"></span>
|
|
42899
|
-
}
|
|
42900
|
-
|
|
42901
|
-
</ng-template>
|
|
42902
|
-
|
|
42903
|
-
</smz-responsive>
|
|
42904
|
-
|
|
42890
|
+
args: [{ selector: '[smz-ui-new-athena-topbar-actions]', changeDetection: ChangeDetectionStrategy.Default, template: `
|
|
42891
|
+
<ng-content></ng-content>
|
|
42892
|
+
|
|
42893
|
+
<div id="smz-ui-topbar"></div>
|
|
42894
|
+
|
|
42895
|
+
<smz-responsive class="col grid grid-nogutter w-full items-center justify-start gap-5">
|
|
42896
|
+
|
|
42897
|
+
<!-- LANDSCAPE -->
|
|
42898
|
+
<ng-template smzTemplate="landscape">
|
|
42899
|
+
|
|
42900
|
+
<span class="col extras-container justify-end extras-container">
|
|
42901
|
+
@if (headerExtrasTemplate != null) {
|
|
42902
|
+
<ng-container *ngTemplateOutlet="headerExtrasTemplate"></ng-container>
|
|
42903
|
+
}
|
|
42904
|
+
</span>
|
|
42905
|
+
|
|
42906
|
+
@if (uiConfig.rbkUtils.notifications.url != null) {
|
|
42907
|
+
<smz-ui-notifications id="smz-ui-notifications" class="mt-2"></smz-ui-notifications>
|
|
42908
|
+
} @else {
|
|
42909
|
+
@if (notifications != null) {
|
|
42910
|
+
<span class="notification-container" smz-ui-new-athena-notifications [items]="notifications"></span>
|
|
42911
|
+
}
|
|
42912
|
+
}
|
|
42913
|
+
|
|
42914
|
+
|
|
42915
|
+
@if (showLocalizationSwitch) {
|
|
42916
|
+
<smz-localization-switch></smz-localization-switch>
|
|
42917
|
+
}
|
|
42918
|
+
|
|
42919
|
+
@if (showTenantSwitch) {
|
|
42920
|
+
<smz-tenant-switch></smz-tenant-switch>
|
|
42921
|
+
}
|
|
42922
|
+
|
|
42923
|
+
@if (profile != null) {
|
|
42924
|
+
<span id="smz-ui-profile-menu" smz-ui-new-athena-profile-menu [profile]="profile"></span>
|
|
42925
|
+
}
|
|
42926
|
+
|
|
42927
|
+
</ng-template>
|
|
42928
|
+
|
|
42929
|
+
<!-- PORTRAIT -->
|
|
42930
|
+
<ng-template smzTemplate="portrait">
|
|
42931
|
+
|
|
42932
|
+
<span class="col extras-container justify-end extras-container">
|
|
42933
|
+
@if (headerExtrasTemplate != null) {
|
|
42934
|
+
<ng-container *ngTemplateOutlet="headerExtrasTemplate"></ng-container>
|
|
42935
|
+
}
|
|
42936
|
+
</span>
|
|
42937
|
+
|
|
42938
|
+
@if (uiConfig.rbkUtils.notifications.url != null) {
|
|
42939
|
+
<smz-ui-notifications id="smz-ui-notifications" class="mt-2"></smz-ui-notifications>
|
|
42940
|
+
} @else {
|
|
42941
|
+
@if (notifications != null) {
|
|
42942
|
+
<span class="notification-container" smz-ui-new-athena-notifications [items]="notifications"></span>
|
|
42943
|
+
}
|
|
42944
|
+
}
|
|
42945
|
+
|
|
42946
|
+
|
|
42947
|
+
@if (showTenantSwitch) {
|
|
42948
|
+
<smz-tenant-switch></smz-tenant-switch>
|
|
42949
|
+
}
|
|
42950
|
+
|
|
42951
|
+
@if (profile != null) {
|
|
42952
|
+
<span id="smz-ui-profile-menu" smz-ui-new-athena-profile-menu [profile]="profile"></span>
|
|
42953
|
+
}
|
|
42954
|
+
|
|
42955
|
+
</ng-template>
|
|
42956
|
+
|
|
42957
|
+
</smz-responsive>
|
|
42958
|
+
|
|
42905
42959
|
`, standalone: false, styles: [".notification-container{position:relative;font-weight:700;margin-top:0;margin-right:30px;color:var(--text-color-secondary)}.extras-container{position:relative;height:100%;display:flex;align-items:center;color:var(--text-color-secondary)}\n"] }]
|
|
42906
42960
|
}], propDecorators: { profile: [{
|
|
42907
42961
|
type: Input
|
|
@@ -42949,11 +43003,11 @@ class NewAthenaTopbarComponent {
|
|
|
42949
43003
|
this.store.dispatch(new UiAthenaActions.ToggleSidebar);
|
|
42950
43004
|
}
|
|
42951
43005
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: NewAthenaTopbarComponent, deps: [{ token: i1$3.Store }], target: i0.ɵɵFactoryTarget.Component });
|
|
42952
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: NewAthenaTopbarComponent, isStandalone: false, selector: "smz-ui-new-athena-topbar", inputs: { notifications: "notifications", profile: "profile" }, queries: [{ propertyName: "templates", predicate: SmzTemplateDirective }], ngImport: i0, template: "@if (layout$ | async; as layout) {\n <smz-responsive class=\"grid grid-nogutter w-full items-center justify-start\">\n <!-- LANDSCAPE -->\n <ng-template smzTemplate=\"landscape\">\n <div class=\"topbar clearfix\">\n <div class=\"w-full h-full grid grid-nogutter items-center justify-start flex-nowrap\" smz-ui-new-athena-topbar-actions [headerExtrasTemplate]=\"headerLandscapeTemplate\" [profile]=\"profile\" [notifications]=\"notifications\">\n <a class=\"topbar-logo\">\n @if ((appLogo$ | async); as appLogo) {\n <img routerlink=\"/\" [src]=\"appLogo.horizontal\" [routerLink]=\"uiConfig.rbkUtils.authentication.authenticatedRoot\"\n [ngClass]=\"{ 'logo': !layout.enlargeTopbarLogo, 'enlarged-logo': layout.enlargeTopbarLogo }\"\n class=\"cursor-pointer outline-none\" tabindex=\"0\"\n >\n }\n </a>\n @if (!layout.hideResponsiveMenuButton) {\n <a id=\"menu-button\" class=\"clickable\" (click)=\"toggle()\">\n <i class=\"fa-solid fa-align-left\"></i>\n </a>\n }\n </div>\n </div>\n </ng-template>\n <!-- PORTRAIT -->\n <ng-template smzTemplate=\"portrait\">\n <div class=\"topbar clearfix\">\n <div class=\"w-full h-full grid grid-nogutter items-center justify-start flex-nowrap\" smz-ui-new-athena-topbar-actions [headerExtrasTemplate]=\"headerPortraitTemplate\" [profile]=\"profile\" [notifications]=\"notifications\">\n <a class=\"topbar-logo max-w-[100px]\">\n @if ((appLogo$ | async); as appLogo) {\n <img routerlink=\"/\" [src]=\"appLogo.horizontal\" [routerLink]=\"uiConfig.rbkUtils.authentication.authenticatedRoot\"\n class=\"w-full h-full cursor-pointer outline-none\" tabindex=\"0\"\n >\n }\n </a>\n @if (!layout.hideResponsiveMenuButton) {\n <a id=\"menu-button\" class=\"clickable\" (click)=\"toggle()\">\n <i class=\"fa-solid fa-align-left\"></i>\n </a>\n }\n </div>\n </div>\n </ng-template>\n </smz-responsive>\n }", styles: [""], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$5.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: AthenaTopbarActionsComponent, selector: "[smz-ui-new-athena-topbar-actions]", inputs: ["profile", "notifications", "headerExtrasTemplate"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: SmzResponsiveComponent, selector: "smz-responsive" }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
43006
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: NewAthenaTopbarComponent, isStandalone: false, selector: "smz-ui-new-athena-topbar", inputs: { notifications: "notifications", profile: "profile" }, queries: [{ propertyName: "templates", predicate: SmzTemplateDirective }], ngImport: i0, template: "@if (layout$ | async; as layout) {\r\n <smz-responsive class=\"grid grid-nogutter w-full items-center justify-start\">\r\n <!-- LANDSCAPE -->\r\n <ng-template smzTemplate=\"landscape\">\r\n <div class=\"topbar clearfix\">\r\n <div class=\"w-full h-full grid grid-nogutter items-center justify-start flex-nowrap\" smz-ui-new-athena-topbar-actions [headerExtrasTemplate]=\"headerLandscapeTemplate\" [profile]=\"profile\" [notifications]=\"notifications\">\r\n <a class=\"topbar-logo\">\r\n @if ((appLogo$ | async); as appLogo) {\r\n <img routerlink=\"/\" [src]=\"appLogo.horizontal\" [routerLink]=\"uiConfig.rbkUtils.authentication.authenticatedRoot\"\r\n [ngClass]=\"{ 'logo': !layout.enlargeTopbarLogo, 'enlarged-logo': layout.enlargeTopbarLogo }\"\r\n class=\"cursor-pointer outline-none\" tabindex=\"0\"\r\n >\r\n }\r\n </a>\r\n @if (!layout.hideResponsiveMenuButton) {\r\n <a id=\"menu-button\" class=\"clickable\" (click)=\"toggle()\">\r\n <i class=\"fa-solid fa-align-left\"></i>\r\n </a>\r\n }\r\n </div>\r\n </div>\r\n </ng-template>\r\n <!-- PORTRAIT -->\r\n <ng-template smzTemplate=\"portrait\">\r\n <div class=\"topbar clearfix\">\r\n <div class=\"w-full h-full grid grid-nogutter items-center justify-start flex-nowrap\" smz-ui-new-athena-topbar-actions [headerExtrasTemplate]=\"headerPortraitTemplate\" [profile]=\"profile\" [notifications]=\"notifications\">\r\n <a class=\"topbar-logo max-w-[100px]\">\r\n @if ((appLogo$ | async); as appLogo) {\r\n <img routerlink=\"/\" [src]=\"appLogo.horizontal\" [routerLink]=\"uiConfig.rbkUtils.authentication.authenticatedRoot\"\r\n class=\"w-full h-full cursor-pointer outline-none\" tabindex=\"0\"\r\n >\r\n }\r\n </a>\r\n @if (!layout.hideResponsiveMenuButton) {\r\n <a id=\"menu-button\" class=\"clickable\" (click)=\"toggle()\">\r\n <i class=\"fa-solid fa-align-left\"></i>\r\n </a>\r\n }\r\n </div>\r\n </div>\r\n </ng-template>\r\n </smz-responsive>\r\n }", styles: [""], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$5.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: AthenaTopbarActionsComponent, selector: "[smz-ui-new-athena-topbar-actions]", inputs: ["profile", "notifications", "headerExtrasTemplate"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: SmzResponsiveComponent, selector: "smz-responsive" }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
42953
43007
|
}
|
|
42954
43008
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: NewAthenaTopbarComponent, decorators: [{
|
|
42955
43009
|
type: Component,
|
|
42956
|
-
args: [{ selector: 'smz-ui-new-athena-topbar', changeDetection: ChangeDetectionStrategy.Default, standalone: false, template: "@if (layout$ | async; as layout) {\n <smz-responsive class=\"grid grid-nogutter w-full items-center justify-start\">\n <!-- LANDSCAPE -->\n <ng-template smzTemplate=\"landscape\">\n <div class=\"topbar clearfix\">\n <div class=\"w-full h-full grid grid-nogutter items-center justify-start flex-nowrap\" smz-ui-new-athena-topbar-actions [headerExtrasTemplate]=\"headerLandscapeTemplate\" [profile]=\"profile\" [notifications]=\"notifications\">\n <a class=\"topbar-logo\">\n @if ((appLogo$ | async); as appLogo) {\n <img routerlink=\"/\" [src]=\"appLogo.horizontal\" [routerLink]=\"uiConfig.rbkUtils.authentication.authenticatedRoot\"\n [ngClass]=\"{ 'logo': !layout.enlargeTopbarLogo, 'enlarged-logo': layout.enlargeTopbarLogo }\"\n class=\"cursor-pointer outline-none\" tabindex=\"0\"\n >\n }\n </a>\n @if (!layout.hideResponsiveMenuButton) {\n <a id=\"menu-button\" class=\"clickable\" (click)=\"toggle()\">\n <i class=\"fa-solid fa-align-left\"></i>\n </a>\n }\n </div>\n </div>\n </ng-template>\n <!-- PORTRAIT -->\n <ng-template smzTemplate=\"portrait\">\n <div class=\"topbar clearfix\">\n <div class=\"w-full h-full grid grid-nogutter items-center justify-start flex-nowrap\" smz-ui-new-athena-topbar-actions [headerExtrasTemplate]=\"headerPortraitTemplate\" [profile]=\"profile\" [notifications]=\"notifications\">\n <a class=\"topbar-logo max-w-[100px]\">\n @if ((appLogo$ | async); as appLogo) {\n <img routerlink=\"/\" [src]=\"appLogo.horizontal\" [routerLink]=\"uiConfig.rbkUtils.authentication.authenticatedRoot\"\n class=\"w-full h-full cursor-pointer outline-none\" tabindex=\"0\"\n >\n }\n </a>\n @if (!layout.hideResponsiveMenuButton) {\n <a id=\"menu-button\" class=\"clickable\" (click)=\"toggle()\">\n <i class=\"fa-solid fa-align-left\"></i>\n </a>\n }\n </div>\n </div>\n </ng-template>\n </smz-responsive>\n }" }]
|
|
43010
|
+
args: [{ selector: 'smz-ui-new-athena-topbar', changeDetection: ChangeDetectionStrategy.Default, standalone: false, template: "@if (layout$ | async; as layout) {\r\n <smz-responsive class=\"grid grid-nogutter w-full items-center justify-start\">\r\n <!-- LANDSCAPE -->\r\n <ng-template smzTemplate=\"landscape\">\r\n <div class=\"topbar clearfix\">\r\n <div class=\"w-full h-full grid grid-nogutter items-center justify-start flex-nowrap\" smz-ui-new-athena-topbar-actions [headerExtrasTemplate]=\"headerLandscapeTemplate\" [profile]=\"profile\" [notifications]=\"notifications\">\r\n <a class=\"topbar-logo\">\r\n @if ((appLogo$ | async); as appLogo) {\r\n <img routerlink=\"/\" [src]=\"appLogo.horizontal\" [routerLink]=\"uiConfig.rbkUtils.authentication.authenticatedRoot\"\r\n [ngClass]=\"{ 'logo': !layout.enlargeTopbarLogo, 'enlarged-logo': layout.enlargeTopbarLogo }\"\r\n class=\"cursor-pointer outline-none\" tabindex=\"0\"\r\n >\r\n }\r\n </a>\r\n @if (!layout.hideResponsiveMenuButton) {\r\n <a id=\"menu-button\" class=\"clickable\" (click)=\"toggle()\">\r\n <i class=\"fa-solid fa-align-left\"></i>\r\n </a>\r\n }\r\n </div>\r\n </div>\r\n </ng-template>\r\n <!-- PORTRAIT -->\r\n <ng-template smzTemplate=\"portrait\">\r\n <div class=\"topbar clearfix\">\r\n <div class=\"w-full h-full grid grid-nogutter items-center justify-start flex-nowrap\" smz-ui-new-athena-topbar-actions [headerExtrasTemplate]=\"headerPortraitTemplate\" [profile]=\"profile\" [notifications]=\"notifications\">\r\n <a class=\"topbar-logo max-w-[100px]\">\r\n @if ((appLogo$ | async); as appLogo) {\r\n <img routerlink=\"/\" [src]=\"appLogo.horizontal\" [routerLink]=\"uiConfig.rbkUtils.authentication.authenticatedRoot\"\r\n class=\"w-full h-full cursor-pointer outline-none\" tabindex=\"0\"\r\n >\r\n }\r\n </a>\r\n @if (!layout.hideResponsiveMenuButton) {\r\n <a id=\"menu-button\" class=\"clickable\" (click)=\"toggle()\">\r\n <i class=\"fa-solid fa-align-left\"></i>\r\n </a>\r\n }\r\n </div>\r\n </div>\r\n </ng-template>\r\n </smz-responsive>\r\n }" }]
|
|
42957
43011
|
}], ctorParameters: () => [{ type: i1$3.Store }], propDecorators: { templates: [{
|
|
42958
43012
|
type: ContentChildren,
|
|
42959
43013
|
args: [SmzTemplateDirective]
|
|
@@ -44682,11 +44736,11 @@ class SmzTreeComponent {
|
|
|
44682
44736
|
}
|
|
44683
44737
|
}
|
|
44684
44738
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzTreeComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: TreeHelperService }], target: i0.ɵɵFactoryTarget.Component });
|
|
44685
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzTreeComponent, isStandalone: false, selector: "smz-ui-tree", inputs: { state: "state", items: "items", loading: "loading", styleClass: "styleClass", inlineStyle: "inlineStyle", appendTo: "appendTo", selection: "selection", selectionKey: "selectionKey" }, outputs: { selectedNodes: "selectedNodes", selectionChange: "selectionChange", parentChange: "parentChange", reorder: "reorder", blockedDrop: "blockedDrop", nodeExpanded: "nodeExpanded", nodeCollapsed: "nodeCollapsed", treeExpanded: "treeExpanded", nodeDropped: "nodeDropped" }, queries: [{ propertyName: "templates", predicate: SmzTemplateDirective }], viewQueries: [{ propertyName: "dt", first: true, predicate: SmzUiTreeComponent, descendants: true }], usesOnChanges: true, ngImport: i0, template: "@if (state) {\n @if ((state.emptyFeedback?.isFeatured) && (treeItems != null && treeItems.length === 0)) {\n <smz-data-info\n [image]=\"state.emptyFeedback.image\"\n [message]=\"state.emptyFeedback.message\"\n [callbackInfo]=\"state.emptyFeedback.extraInfo\"\n [callbackLabel]=\"state.emptyFeedback.actionButton?.label\"\n (clicked)=\"state.emptyFeedback.actionButton?.callback($event)\">\n <ng-template smzTemplate=\"actions\">\n <ng-container *ngTemplateOutlet=\"emptyActionsTemplate; context: { $implicit: {} }\"></ng-container>\n </ng-template>\n </smz-data-info>\n } @else {\n @if (treeItems != null) {\n <ui-menu #cm [model]=\"menuItems\" [popup]=\"true\" [styleClass]=\"menuItems == null || menuItems?.length === 0 ? 'invisible-important' : ''\"></ui-menu>\n <ui-menu #rowMenu [model]=\"menuItems\" [popup]=\"true\" appendTo=\"body\"></ui-menu>\n <ui-tree #dt [value]=\"treeItems\" scrollHeight=\"flex\" [contextMenu]=\"state.menu.behavior === 'context-menu' ? cm : null\" [selectionMode]=\"state.selection.mode\" [(selection)]=\"primeSelection\" layout=\"vertical\" [style]=\"inlineStyle\" [styleClass]=\"styleClass\" [propagateSelectionUp]=\"state.selection.propagateUp\" [propagateSelectionDown]=\"state.selection.propagateDown\" [loading]=\"state.loading.isLoading\" [loadingIcon]=\"state.loading.icon\" [filter]=\"false\" [filterMode]=\"state.filter.mode\" [filterPlaceholder]=\"state.filter.textPlaceholder\" [draggableNodes]=\"state.dragAndDrop.draggable\" [droppableNodes]=\"state.dragAndDrop.droppable\" [validateDrop]=\"state.dragAndDrop.validateDrop\" (nodeContextMenuSelect)=\"onContextMenuOpen($event)\" (nodeSelect)=\"onSelected($event)\" (nodeUnselect)=\"onUnselected($event)\" (nodeExpand)=\"onExpanded($event)\" (nodeCollapse)=\"onCollapsed($event)\" (nodeDrop)=\"onDropped($event)\" (filtered)=\"onFiltered($event)\">\n @if (state.header.isVisible) {\n <ng-template smzTemplate=\"header\">\n @if (state.header.toolbar; as toolbar) {\n @if (headerTemplate != null) {\n <div class=\"grid grid-nogutter items-center w-full justify-start\">\n <ng-container *ngTemplateOutlet=\"headerTemplate; context: { $implicit: dt }\"></ng-container>\n </div>\n }\n <div class=\"grid grid-nogutter justify-start items-center mb-2 gap-2\">\n @if (state.header.title != null) {\n <h3 class=\"m-2 col\">{{state.header.title}}</h3>\n }\n <div class=\"grid grid-nogutter justify-start items-center gap-2\">\n @for (button of state.header.toolbar.items; track button; let i = $index) {\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': button.color === 'secondary', 'p-button-success': button.color === 'success', 'p-button-info': button.color === 'info', 'p-button-warning': button.color === 'warning', 'p-button-help': button.color === 'help', 'p-button-danger': button.color === 'danger' }\" [label]=\"button.label\" [icon]=\"button.icon\" (click)=\"onToolbarButtonClick($event, button, treeItems)\" [smzTooltip]=\"button.tooltip\">\n </button>\n }\n @if (toolbar.nodeExpandButtons.isVisible === true) {\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.nodeExpandButtons.expandLabel\" icon=\"fa-solid fa-angle-down\" (click)=\"expandNode()\" [smzTooltip]=\"selection != null ? toolbar.nodeExpandButtons.expandTooltip : toolbar.nodeExpandButtons.disabledTooltip\" [disabled]=\"selection == null\">\n </button>\n }\n @if (toolbar.nodeExpandButtons.isVisible === true) {\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.nodeExpandButtons.collapseLabel\" icon=\"fa-solid fa-angle-up\" (click)=\"collapseNode()\" [smzTooltip]=\"selection != null ? toolbar.nodeExpandButtons.collapseTooltip : toolbar.nodeExpandButtons.disabledTooltip\" [disabled]=\"selection == null\">\n </button>\n }\n @if (toolbar.treeExpandButtons.isVisible === true) {\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeExpandButtons.expandLabel\" icon=\"fa-solid fa-angles-down\" (click)=\"expandAll()\" [smzTooltip]=\"toolbar.treeExpandButtons.expandLabel != null && toolbar.treeExpandButtons.expandLabel !== '' \n ? toolbar.treeExpandButtons.expandLabel \n : 'Expandir \u00E1rvore'\">\n </button>\n }\n @if (toolbar.treeExpandButtons.isVisible === true) {\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeExpandButtons.collapseLabel\" icon=\"fa-solid fa-angles-up\" (click)=\"collapseAll()\" [smzTooltip]=\"toolbar.treeExpandButtons.collapseLabel != null && toolbar.treeExpandButtons.collapseLabel !== '' \n ? toolbar.treeExpandButtons.collapseLabel \n : 'Colapsar \u00E1rvore'\">\n </button>\n }\n @if (toolbar.treeSelectionButtons?.isVisible === true) {\n\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeSelectionButtons.selectAllLabel\" icon=\"fa-solid fa-check-double\" (click)=\"selectAll()\" [disabled]=\"state.selection?.mode === 'single'\" [smzTooltip]=\"state.selection?.mode === 'single' \n ? 'Dispon\u00EDvel apenas em sele\u00E7\u00E3o m\u00FAltipla' \n : (toolbar.treeSelectionButtons.selectAllLabel != null && toolbar.treeSelectionButtons.selectAllLabel !== '' ? toolbar.treeSelectionButtons.selectAllLabel : 'Selecionar tudo')\">\n </button>\n\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeSelectionButtons.clearSelectionLabel\" icon=\"fa-solid fa-eraser\" (click)=\"clearSelection()\" [disabled]=\"!hasSelection\" [smzTooltip]=\"toolbar.treeSelectionButtons.clearSelectionLabel != null && toolbar.treeSelectionButtons.clearSelectionLabel !== '' \n ? toolbar.treeSelectionButtons.clearSelectionLabel \n : 'Limpar sele\u00E7\u00E3o'\">\n </button>\n }\n\n @if (actionsTemplate != null) {\n <div class=\"grid grid-nogutter items-center justify-start\">\n <ng-container *ngTemplateOutlet=\"actionsTemplate; context: { $implicit: dt }\"></ng-container>\n </div>\n }\n </div>\n @if (state.filter.show) {\n <ui-icon-field class=\"col-12\" [ngClass]=\"state.filter.styleClass\">\n <ui-input-icon styleClass=\"fa-solid fa-magnifying-glass\"></ui-input-icon>\n <input #inputGlobal smzInputText type=\"text\" (input)=\"dt._filter(inputGlobal.value)\" [placeholder]=\"state.filter.textPlaceholder\" />\n </ui-icon-field>\n }\n </div>\n @if (toolbarTemplate != null) {\n <div class=\"grid grid-nogutter items-center mt-2\"\n [ngClass]=\"'justify-' + state.header.toolbar.alignment\">\n <ng-container *ngTemplateOutlet=\"toolbarTemplate; context: { $implicit: dt }\"></ng-container>\n </div>\n }\n }\n </ng-template>\n }\n @if (state.footer.isVisible) {\n <ng-template smzTemplate=\"footer\">\n <div class=\"grid grid-nogutter justify-start items-center\">\n <span class=\"col mr-2\">FOOTER</span>\n </div>\n </ng-template>\n }\n @for (content of contentTemplates; track content) {\n <ng-template let-node [smzTemplate]=\"content.type\">\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\n @if (content.template != null) {\n <ng-container *ngTemplateOutlet=\"content.template; context: { $implicit: node }\"></ng-container>\n } @else {\n <div>{{ node.label }}</div>\n }\n @if (state.menu.behavior === 'row-menu') {\n <button smzButton clickStopPropagation (click)=\"onRowMenuOpen(node, rowMenu, $event)\" [icon]=\"state.menu.rowMenuIcon\" [rounded]=\"true\" [text]=\"true\" [severity]=\"state.menu.rowMenuIconSeverity\"></button>\n }\n </div>\n </ng-template>\n }\n <ng-template let-node smzTemplate=\"Check\">\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\n <div>{{ node.label }}</div>\n @if (state.menu.behavior === 'row-menu') {\n <button smzButton clickStopPropagation (click)=\"onRowMenuOpen(node, rowMenu, $event)\" [icon]=\"state.menu.rowMenuIcon\" [rounded]=\"true\" [text]=\"true\" [severity]=\"state.menu.rowMenuIconSeverity\"></button>\n }\n </div>\n </ng-template>\n <ng-template smzTemplate=\"empty\">\n @if (!state.emptyFeedback.isFeatured) {\n <div>{{ state.emptyFeedback.message }}</div>\n }\n </ng-template>\n </ui-tree>\n }\n }\n} @else {\n @if (emptyStateTemplate != null) {\n <ng-container *ngTemplateOutlet=\"emptyStateTemplate; context: { $implicit: {} }\"></ng-container>\n }\n}\n\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "directive", type: ClickStopPropagationDirective, selector: "[clickStopPropagation]" }, { kind: "component", type: SmzDataInfoComponent, selector: "smz-data-info", inputs: ["image", "message", "actions", "callbackInfo", "callbackLabel"], outputs: ["clicked"] }, { kind: "directive", type: i2.SmzTooltipDirective, selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "component", type: i2.SmzMenuListComponent, selector: "ui-menu", inputs: ["model", "popup", "style", "styleClass", "autoZIndex", "appendTo", "baseZIndex"], outputs: ["shown", "hidden"] }, { kind: "component", type: i2.SmzUiTreeComponent, selector: "ui-tree", inputs: ["value", "selectionMode", "selection", "metaKeySelection", "propagateSelectionUp", "propagateSelectionDown", "loading", "loadingIcon", "filter", "filterMode", "filterPlaceholder", "filterBy", "emptyMessage", "draggableNodes", "droppableNodes", "validateDrop", "scrollHeight", "style", "styleClass", "contextMenu", "templateOverride", "layout", "virtualScroll"], outputs: ["selectionChange", "nodeSelect", "nodeUnselect", "nodeExpand", "nodeCollapse", "nodeContextMenuSelect", "nodeDblClick", "nodeDrop", "filtered"] }, { kind: "directive", type: i2.SmzInputTextDirective, selector: "input[smzInputText]", inputs: ["size", "invalid"] }, { kind: "component", type: i2.SmzIconFieldComponent, selector: "ui-icon-field" }, { kind: "component", type: i2.SmzInputIconComponent, selector: "ui-input-icon", inputs: ["styleClass"] }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
44739
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzTreeComponent, isStandalone: false, selector: "smz-ui-tree", inputs: { state: "state", items: "items", loading: "loading", styleClass: "styleClass", inlineStyle: "inlineStyle", appendTo: "appendTo", selection: "selection", selectionKey: "selectionKey" }, outputs: { selectedNodes: "selectedNodes", selectionChange: "selectionChange", parentChange: "parentChange", reorder: "reorder", blockedDrop: "blockedDrop", nodeExpanded: "nodeExpanded", nodeCollapsed: "nodeCollapsed", treeExpanded: "treeExpanded", nodeDropped: "nodeDropped" }, queries: [{ propertyName: "templates", predicate: SmzTemplateDirective }], viewQueries: [{ propertyName: "dt", first: true, predicate: SmzUiTreeComponent, descendants: true }], usesOnChanges: true, ngImport: i0, template: "@if (state) {\r\n @if ((state.emptyFeedback?.isFeatured) && (treeItems != null && treeItems.length === 0)) {\r\n <smz-data-info\r\n [image]=\"state.emptyFeedback.image\"\r\n [message]=\"state.emptyFeedback.message\"\r\n [callbackInfo]=\"state.emptyFeedback.extraInfo\"\r\n [callbackLabel]=\"state.emptyFeedback.actionButton?.label\"\r\n (clicked)=\"state.emptyFeedback.actionButton?.callback($event)\">\r\n <ng-template smzTemplate=\"actions\">\r\n <ng-container *ngTemplateOutlet=\"emptyActionsTemplate; context: { $implicit: {} }\"></ng-container>\r\n </ng-template>\r\n </smz-data-info>\r\n } @else {\r\n @if (treeItems != null) {\r\n <ui-menu #cm [model]=\"menuItems\" [popup]=\"true\" [styleClass]=\"menuItems == null || menuItems?.length === 0 ? 'invisible-important' : ''\"></ui-menu>\r\n <ui-menu #rowMenu [model]=\"menuItems\" [popup]=\"true\" appendTo=\"body\"></ui-menu>\r\n <ui-tree #dt [value]=\"treeItems\" scrollHeight=\"flex\" [contextMenu]=\"state.menu.behavior === 'context-menu' ? cm : null\" [selectionMode]=\"state.selection.mode\" [(selection)]=\"primeSelection\" layout=\"vertical\" [style]=\"inlineStyle\" [styleClass]=\"styleClass\" [propagateSelectionUp]=\"state.selection.propagateUp\" [propagateSelectionDown]=\"state.selection.propagateDown\" [loading]=\"state.loading.isLoading\" [loadingIcon]=\"state.loading.icon\" [filter]=\"false\" [filterMode]=\"state.filter.mode\" [filterPlaceholder]=\"state.filter.textPlaceholder\" [draggableNodes]=\"state.dragAndDrop.draggable\" [droppableNodes]=\"state.dragAndDrop.droppable\" [validateDrop]=\"state.dragAndDrop.validateDrop\" (nodeContextMenuSelect)=\"onContextMenuOpen($event)\" (nodeSelect)=\"onSelected($event)\" (nodeUnselect)=\"onUnselected($event)\" (nodeExpand)=\"onExpanded($event)\" (nodeCollapse)=\"onCollapsed($event)\" (nodeDrop)=\"onDropped($event)\" (filtered)=\"onFiltered($event)\">\r\n @if (state.header.isVisible) {\r\n <ng-template smzTemplate=\"header\">\r\n @if (state.header.toolbar; as toolbar) {\r\n @if (headerTemplate != null) {\r\n <div class=\"grid grid-nogutter items-center w-full justify-start\">\r\n <ng-container *ngTemplateOutlet=\"headerTemplate; context: { $implicit: dt }\"></ng-container>\r\n </div>\r\n }\r\n <div class=\"grid grid-nogutter justify-start items-center mb-2 gap-2\">\r\n @if (state.header.title != null) {\r\n <h3 class=\"m-2 col\">{{state.header.title}}</h3>\r\n }\r\n <div class=\"grid grid-nogutter justify-start items-center gap-2\">\r\n @for (button of state.header.toolbar.items; track button; let i = $index) {\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': button.color === 'secondary', 'p-button-success': button.color === 'success', 'p-button-info': button.color === 'info', 'p-button-warning': button.color === 'warning', 'p-button-help': button.color === 'help', 'p-button-danger': button.color === 'danger' }\" [label]=\"button.label\" [icon]=\"button.icon\" (click)=\"onToolbarButtonClick($event, button, treeItems)\" [smzTooltip]=\"button.tooltip\">\r\n </button>\r\n }\r\n @if (toolbar.nodeExpandButtons.isVisible === true) {\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.nodeExpandButtons.expandLabel\" icon=\"fa-solid fa-angle-down\" (click)=\"expandNode()\" [smzTooltip]=\"selection != null ? toolbar.nodeExpandButtons.expandTooltip : toolbar.nodeExpandButtons.disabledTooltip\" [disabled]=\"selection == null\">\r\n </button>\r\n }\r\n @if (toolbar.nodeExpandButtons.isVisible === true) {\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.nodeExpandButtons.collapseLabel\" icon=\"fa-solid fa-angle-up\" (click)=\"collapseNode()\" [smzTooltip]=\"selection != null ? toolbar.nodeExpandButtons.collapseTooltip : toolbar.nodeExpandButtons.disabledTooltip\" [disabled]=\"selection == null\">\r\n </button>\r\n }\r\n @if (toolbar.treeExpandButtons.isVisible === true) {\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeExpandButtons.expandLabel\" icon=\"fa-solid fa-angles-down\" (click)=\"expandAll()\" [smzTooltip]=\"toolbar.treeExpandButtons.expandLabel != null && toolbar.treeExpandButtons.expandLabel !== '' \r\n ? toolbar.treeExpandButtons.expandLabel \r\n : 'Expandir \u00E1rvore'\">\r\n </button>\r\n }\r\n @if (toolbar.treeExpandButtons.isVisible === true) {\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeExpandButtons.collapseLabel\" icon=\"fa-solid fa-angles-up\" (click)=\"collapseAll()\" [smzTooltip]=\"toolbar.treeExpandButtons.collapseLabel != null && toolbar.treeExpandButtons.collapseLabel !== '' \r\n ? toolbar.treeExpandButtons.collapseLabel \r\n : 'Colapsar \u00E1rvore'\">\r\n </button>\r\n }\r\n @if (toolbar.treeSelectionButtons?.isVisible === true) {\r\n\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeSelectionButtons.selectAllLabel\" icon=\"fa-solid fa-check-double\" (click)=\"selectAll()\" [disabled]=\"state.selection?.mode === 'single'\" [smzTooltip]=\"state.selection?.mode === 'single' \r\n ? 'Dispon\u00EDvel apenas em sele\u00E7\u00E3o m\u00FAltipla' \r\n : (toolbar.treeSelectionButtons.selectAllLabel != null && toolbar.treeSelectionButtons.selectAllLabel !== '' ? toolbar.treeSelectionButtons.selectAllLabel : 'Selecionar tudo')\">\r\n </button>\r\n\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeSelectionButtons.clearSelectionLabel\" icon=\"fa-solid fa-eraser\" (click)=\"clearSelection()\" [disabled]=\"!hasSelection\" [smzTooltip]=\"toolbar.treeSelectionButtons.clearSelectionLabel != null && toolbar.treeSelectionButtons.clearSelectionLabel !== '' \r\n ? toolbar.treeSelectionButtons.clearSelectionLabel \r\n : 'Limpar sele\u00E7\u00E3o'\">\r\n </button>\r\n }\r\n\r\n @if (actionsTemplate != null) {\r\n <div class=\"grid grid-nogutter items-center justify-start\">\r\n <ng-container *ngTemplateOutlet=\"actionsTemplate; context: { $implicit: dt }\"></ng-container>\r\n </div>\r\n }\r\n </div>\r\n @if (state.filter.show) {\r\n <ui-icon-field class=\"col-12\" [ngClass]=\"state.filter.styleClass\">\r\n <ui-input-icon styleClass=\"fa-solid fa-magnifying-glass\"></ui-input-icon>\r\n <input #inputGlobal smzInputText type=\"text\" (input)=\"dt._filter(inputGlobal.value)\" [placeholder]=\"state.filter.textPlaceholder\" />\r\n </ui-icon-field>\r\n }\r\n </div>\r\n @if (toolbarTemplate != null) {\r\n <div class=\"grid grid-nogutter items-center mt-2\"\r\n [ngClass]=\"'justify-' + state.header.toolbar.alignment\">\r\n <ng-container *ngTemplateOutlet=\"toolbarTemplate; context: { $implicit: dt }\"></ng-container>\r\n </div>\r\n }\r\n }\r\n </ng-template>\r\n }\r\n @if (state.footer.isVisible) {\r\n <ng-template smzTemplate=\"footer\">\r\n <div class=\"grid grid-nogutter justify-start items-center\">\r\n <span class=\"col mr-2\">FOOTER</span>\r\n </div>\r\n </ng-template>\r\n }\r\n @for (content of contentTemplates; track content) {\r\n <ng-template let-node [smzTemplate]=\"content.type\">\r\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\r\n @if (content.template != null) {\r\n <ng-container *ngTemplateOutlet=\"content.template; context: { $implicit: node }\"></ng-container>\r\n } @else {\r\n <div>{{ node.label }}</div>\r\n }\r\n @if (state.menu.behavior === 'row-menu') {\r\n <button smzButton clickStopPropagation (click)=\"onRowMenuOpen(node, rowMenu, $event)\" [icon]=\"state.menu.rowMenuIcon\" [rounded]=\"true\" [text]=\"true\" [severity]=\"state.menu.rowMenuIconSeverity\"></button>\r\n }\r\n </div>\r\n </ng-template>\r\n }\r\n <ng-template let-node smzTemplate=\"Check\">\r\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\r\n <div>{{ node.label }}</div>\r\n @if (state.menu.behavior === 'row-menu') {\r\n <button smzButton clickStopPropagation (click)=\"onRowMenuOpen(node, rowMenu, $event)\" [icon]=\"state.menu.rowMenuIcon\" [rounded]=\"true\" [text]=\"true\" [severity]=\"state.menu.rowMenuIconSeverity\"></button>\r\n }\r\n </div>\r\n </ng-template>\r\n <ng-template smzTemplate=\"empty\">\r\n @if (!state.emptyFeedback.isFeatured) {\r\n <div>{{ state.emptyFeedback.message }}</div>\r\n }\r\n </ng-template>\r\n </ui-tree>\r\n }\r\n }\r\n} @else {\r\n @if (emptyStateTemplate != null) {\r\n <ng-container *ngTemplateOutlet=\"emptyStateTemplate; context: { $implicit: {} }\"></ng-container>\r\n }\r\n}\r\n\r\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: i2.SmzButtonComponent, selector: "button[smzButton], a[smzButton]", inputs: ["label", "icon", "iconPosition", "severity", "variant", "size", "text", "outlined", "rounded", "loading", "styleClass"] }, { kind: "directive", type: ClickStopPropagationDirective, selector: "[clickStopPropagation]" }, { kind: "component", type: SmzDataInfoComponent, selector: "smz-data-info", inputs: ["image", "message", "actions", "callbackInfo", "callbackLabel"], outputs: ["clicked"] }, { kind: "directive", type: i2.SmzTooltipDirective, selector: "[smzTooltip]", inputs: ["smzTooltip", "tooltipPosition", "showDelay", "hideDelay", "tooltipEvent", "escape", "tooltipStyleClass", "tooltipZIndex", "tooltipDisabled", "tooltipOptions", "appendTo"] }, { kind: "component", type: i2.SmzMenuListComponent, selector: "ui-menu", inputs: ["model", "popup", "style", "styleClass", "autoZIndex", "appendTo", "baseZIndex"], outputs: ["shown", "hidden"] }, { kind: "component", type: i2.SmzUiTreeComponent, selector: "ui-tree", inputs: ["value", "selectionMode", "selection", "metaKeySelection", "propagateSelectionUp", "propagateSelectionDown", "loading", "loadingIcon", "filter", "filterMode", "filterPlaceholder", "filterBy", "emptyMessage", "draggableNodes", "droppableNodes", "validateDrop", "scrollHeight", "style", "styleClass", "contextMenu", "templateOverride", "layout", "virtualScroll"], outputs: ["selectionChange", "nodeSelect", "nodeUnselect", "nodeExpand", "nodeCollapse", "nodeContextMenuSelect", "nodeDblClick", "nodeDrop", "filtered"] }, { kind: "directive", type: i2.SmzInputTextDirective, selector: "input[smzInputText]", inputs: ["size", "invalid"] }, { kind: "component", type: i2.SmzIconFieldComponent, selector: "ui-icon-field" }, { kind: "component", type: i2.SmzInputIconComponent, selector: "ui-input-icon", inputs: ["styleClass"] }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
44686
44740
|
}
|
|
44687
44741
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzTreeComponent, decorators: [{
|
|
44688
44742
|
type: Component,
|
|
44689
|
-
args: [{ selector: 'smz-ui-tree', changeDetection: ChangeDetectionStrategy.Default, standalone: false, template: "@if (state) {\n @if ((state.emptyFeedback?.isFeatured) && (treeItems != null && treeItems.length === 0)) {\n <smz-data-info\n [image]=\"state.emptyFeedback.image\"\n [message]=\"state.emptyFeedback.message\"\n [callbackInfo]=\"state.emptyFeedback.extraInfo\"\n [callbackLabel]=\"state.emptyFeedback.actionButton?.label\"\n (clicked)=\"state.emptyFeedback.actionButton?.callback($event)\">\n <ng-template smzTemplate=\"actions\">\n <ng-container *ngTemplateOutlet=\"emptyActionsTemplate; context: { $implicit: {} }\"></ng-container>\n </ng-template>\n </smz-data-info>\n } @else {\n @if (treeItems != null) {\n <ui-menu #cm [model]=\"menuItems\" [popup]=\"true\" [styleClass]=\"menuItems == null || menuItems?.length === 0 ? 'invisible-important' : ''\"></ui-menu>\n <ui-menu #rowMenu [model]=\"menuItems\" [popup]=\"true\" appendTo=\"body\"></ui-menu>\n <ui-tree #dt [value]=\"treeItems\" scrollHeight=\"flex\" [contextMenu]=\"state.menu.behavior === 'context-menu' ? cm : null\" [selectionMode]=\"state.selection.mode\" [(selection)]=\"primeSelection\" layout=\"vertical\" [style]=\"inlineStyle\" [styleClass]=\"styleClass\" [propagateSelectionUp]=\"state.selection.propagateUp\" [propagateSelectionDown]=\"state.selection.propagateDown\" [loading]=\"state.loading.isLoading\" [loadingIcon]=\"state.loading.icon\" [filter]=\"false\" [filterMode]=\"state.filter.mode\" [filterPlaceholder]=\"state.filter.textPlaceholder\" [draggableNodes]=\"state.dragAndDrop.draggable\" [droppableNodes]=\"state.dragAndDrop.droppable\" [validateDrop]=\"state.dragAndDrop.validateDrop\" (nodeContextMenuSelect)=\"onContextMenuOpen($event)\" (nodeSelect)=\"onSelected($event)\" (nodeUnselect)=\"onUnselected($event)\" (nodeExpand)=\"onExpanded($event)\" (nodeCollapse)=\"onCollapsed($event)\" (nodeDrop)=\"onDropped($event)\" (filtered)=\"onFiltered($event)\">\n @if (state.header.isVisible) {\n <ng-template smzTemplate=\"header\">\n @if (state.header.toolbar; as toolbar) {\n @if (headerTemplate != null) {\n <div class=\"grid grid-nogutter items-center w-full justify-start\">\n <ng-container *ngTemplateOutlet=\"headerTemplate; context: { $implicit: dt }\"></ng-container>\n </div>\n }\n <div class=\"grid grid-nogutter justify-start items-center mb-2 gap-2\">\n @if (state.header.title != null) {\n <h3 class=\"m-2 col\">{{state.header.title}}</h3>\n }\n <div class=\"grid grid-nogutter justify-start items-center gap-2\">\n @for (button of state.header.toolbar.items; track button; let i = $index) {\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': button.color === 'secondary', 'p-button-success': button.color === 'success', 'p-button-info': button.color === 'info', 'p-button-warning': button.color === 'warning', 'p-button-help': button.color === 'help', 'p-button-danger': button.color === 'danger' }\" [label]=\"button.label\" [icon]=\"button.icon\" (click)=\"onToolbarButtonClick($event, button, treeItems)\" [smzTooltip]=\"button.tooltip\">\n </button>\n }\n @if (toolbar.nodeExpandButtons.isVisible === true) {\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.nodeExpandButtons.expandLabel\" icon=\"fa-solid fa-angle-down\" (click)=\"expandNode()\" [smzTooltip]=\"selection != null ? toolbar.nodeExpandButtons.expandTooltip : toolbar.nodeExpandButtons.disabledTooltip\" [disabled]=\"selection == null\">\n </button>\n }\n @if (toolbar.nodeExpandButtons.isVisible === true) {\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.nodeExpandButtons.collapseLabel\" icon=\"fa-solid fa-angle-up\" (click)=\"collapseNode()\" [smzTooltip]=\"selection != null ? toolbar.nodeExpandButtons.collapseTooltip : toolbar.nodeExpandButtons.disabledTooltip\" [disabled]=\"selection == null\">\n </button>\n }\n @if (toolbar.treeExpandButtons.isVisible === true) {\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeExpandButtons.expandLabel\" icon=\"fa-solid fa-angles-down\" (click)=\"expandAll()\" [smzTooltip]=\"toolbar.treeExpandButtons.expandLabel != null && toolbar.treeExpandButtons.expandLabel !== '' \n ? toolbar.treeExpandButtons.expandLabel \n : 'Expandir \u00E1rvore'\">\n </button>\n }\n @if (toolbar.treeExpandButtons.isVisible === true) {\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeExpandButtons.collapseLabel\" icon=\"fa-solid fa-angles-up\" (click)=\"collapseAll()\" [smzTooltip]=\"toolbar.treeExpandButtons.collapseLabel != null && toolbar.treeExpandButtons.collapseLabel !== '' \n ? toolbar.treeExpandButtons.collapseLabel \n : 'Colapsar \u00E1rvore'\">\n </button>\n }\n @if (toolbar.treeSelectionButtons?.isVisible === true) {\n\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeSelectionButtons.selectAllLabel\" icon=\"fa-solid fa-check-double\" (click)=\"selectAll()\" [disabled]=\"state.selection?.mode === 'single'\" [smzTooltip]=\"state.selection?.mode === 'single' \n ? 'Dispon\u00EDvel apenas em sele\u00E7\u00E3o m\u00FAltipla' \n : (toolbar.treeSelectionButtons.selectAllLabel != null && toolbar.treeSelectionButtons.selectAllLabel !== '' ? toolbar.treeSelectionButtons.selectAllLabel : 'Selecionar tudo')\">\n </button>\n\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeSelectionButtons.clearSelectionLabel\" icon=\"fa-solid fa-eraser\" (click)=\"clearSelection()\" [disabled]=\"!hasSelection\" [smzTooltip]=\"toolbar.treeSelectionButtons.clearSelectionLabel != null && toolbar.treeSelectionButtons.clearSelectionLabel !== '' \n ? toolbar.treeSelectionButtons.clearSelectionLabel \n : 'Limpar sele\u00E7\u00E3o'\">\n </button>\n }\n\n @if (actionsTemplate != null) {\n <div class=\"grid grid-nogutter items-center justify-start\">\n <ng-container *ngTemplateOutlet=\"actionsTemplate; context: { $implicit: dt }\"></ng-container>\n </div>\n }\n </div>\n @if (state.filter.show) {\n <ui-icon-field class=\"col-12\" [ngClass]=\"state.filter.styleClass\">\n <ui-input-icon styleClass=\"fa-solid fa-magnifying-glass\"></ui-input-icon>\n <input #inputGlobal smzInputText type=\"text\" (input)=\"dt._filter(inputGlobal.value)\" [placeholder]=\"state.filter.textPlaceholder\" />\n </ui-icon-field>\n }\n </div>\n @if (toolbarTemplate != null) {\n <div class=\"grid grid-nogutter items-center mt-2\"\n [ngClass]=\"'justify-' + state.header.toolbar.alignment\">\n <ng-container *ngTemplateOutlet=\"toolbarTemplate; context: { $implicit: dt }\"></ng-container>\n </div>\n }\n }\n </ng-template>\n }\n @if (state.footer.isVisible) {\n <ng-template smzTemplate=\"footer\">\n <div class=\"grid grid-nogutter justify-start items-center\">\n <span class=\"col mr-2\">FOOTER</span>\n </div>\n </ng-template>\n }\n @for (content of contentTemplates; track content) {\n <ng-template let-node [smzTemplate]=\"content.type\">\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\n @if (content.template != null) {\n <ng-container *ngTemplateOutlet=\"content.template; context: { $implicit: node }\"></ng-container>\n } @else {\n <div>{{ node.label }}</div>\n }\n @if (state.menu.behavior === 'row-menu') {\n <button smzButton clickStopPropagation (click)=\"onRowMenuOpen(node, rowMenu, $event)\" [icon]=\"state.menu.rowMenuIcon\" [rounded]=\"true\" [text]=\"true\" [severity]=\"state.menu.rowMenuIconSeverity\"></button>\n }\n </div>\n </ng-template>\n }\n <ng-template let-node smzTemplate=\"Check\">\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\n <div>{{ node.label }}</div>\n @if (state.menu.behavior === 'row-menu') {\n <button smzButton clickStopPropagation (click)=\"onRowMenuOpen(node, rowMenu, $event)\" [icon]=\"state.menu.rowMenuIcon\" [rounded]=\"true\" [text]=\"true\" [severity]=\"state.menu.rowMenuIconSeverity\"></button>\n }\n </div>\n </ng-template>\n <ng-template smzTemplate=\"empty\">\n @if (!state.emptyFeedback.isFeatured) {\n <div>{{ state.emptyFeedback.message }}</div>\n }\n </ng-template>\n </ui-tree>\n }\n }\n} @else {\n @if (emptyStateTemplate != null) {\n <ng-container *ngTemplateOutlet=\"emptyStateTemplate; context: { $implicit: {} }\"></ng-container>\n }\n}\n\n" }]
|
|
44743
|
+
args: [{ selector: 'smz-ui-tree', changeDetection: ChangeDetectionStrategy.Default, standalone: false, template: "@if (state) {\r\n @if ((state.emptyFeedback?.isFeatured) && (treeItems != null && treeItems.length === 0)) {\r\n <smz-data-info\r\n [image]=\"state.emptyFeedback.image\"\r\n [message]=\"state.emptyFeedback.message\"\r\n [callbackInfo]=\"state.emptyFeedback.extraInfo\"\r\n [callbackLabel]=\"state.emptyFeedback.actionButton?.label\"\r\n (clicked)=\"state.emptyFeedback.actionButton?.callback($event)\">\r\n <ng-template smzTemplate=\"actions\">\r\n <ng-container *ngTemplateOutlet=\"emptyActionsTemplate; context: { $implicit: {} }\"></ng-container>\r\n </ng-template>\r\n </smz-data-info>\r\n } @else {\r\n @if (treeItems != null) {\r\n <ui-menu #cm [model]=\"menuItems\" [popup]=\"true\" [styleClass]=\"menuItems == null || menuItems?.length === 0 ? 'invisible-important' : ''\"></ui-menu>\r\n <ui-menu #rowMenu [model]=\"menuItems\" [popup]=\"true\" appendTo=\"body\"></ui-menu>\r\n <ui-tree #dt [value]=\"treeItems\" scrollHeight=\"flex\" [contextMenu]=\"state.menu.behavior === 'context-menu' ? cm : null\" [selectionMode]=\"state.selection.mode\" [(selection)]=\"primeSelection\" layout=\"vertical\" [style]=\"inlineStyle\" [styleClass]=\"styleClass\" [propagateSelectionUp]=\"state.selection.propagateUp\" [propagateSelectionDown]=\"state.selection.propagateDown\" [loading]=\"state.loading.isLoading\" [loadingIcon]=\"state.loading.icon\" [filter]=\"false\" [filterMode]=\"state.filter.mode\" [filterPlaceholder]=\"state.filter.textPlaceholder\" [draggableNodes]=\"state.dragAndDrop.draggable\" [droppableNodes]=\"state.dragAndDrop.droppable\" [validateDrop]=\"state.dragAndDrop.validateDrop\" (nodeContextMenuSelect)=\"onContextMenuOpen($event)\" (nodeSelect)=\"onSelected($event)\" (nodeUnselect)=\"onUnselected($event)\" (nodeExpand)=\"onExpanded($event)\" (nodeCollapse)=\"onCollapsed($event)\" (nodeDrop)=\"onDropped($event)\" (filtered)=\"onFiltered($event)\">\r\n @if (state.header.isVisible) {\r\n <ng-template smzTemplate=\"header\">\r\n @if (state.header.toolbar; as toolbar) {\r\n @if (headerTemplate != null) {\r\n <div class=\"grid grid-nogutter items-center w-full justify-start\">\r\n <ng-container *ngTemplateOutlet=\"headerTemplate; context: { $implicit: dt }\"></ng-container>\r\n </div>\r\n }\r\n <div class=\"grid grid-nogutter justify-start items-center mb-2 gap-2\">\r\n @if (state.header.title != null) {\r\n <h3 class=\"m-2 col\">{{state.header.title}}</h3>\r\n }\r\n <div class=\"grid grid-nogutter justify-start items-center gap-2\">\r\n @for (button of state.header.toolbar.items; track button; let i = $index) {\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': button.color === 'secondary', 'p-button-success': button.color === 'success', 'p-button-info': button.color === 'info', 'p-button-warning': button.color === 'warning', 'p-button-help': button.color === 'help', 'p-button-danger': button.color === 'danger' }\" [label]=\"button.label\" [icon]=\"button.icon\" (click)=\"onToolbarButtonClick($event, button, treeItems)\" [smzTooltip]=\"button.tooltip\">\r\n </button>\r\n }\r\n @if (toolbar.nodeExpandButtons.isVisible === true) {\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.nodeExpandButtons.expandLabel\" icon=\"fa-solid fa-angle-down\" (click)=\"expandNode()\" [smzTooltip]=\"selection != null ? toolbar.nodeExpandButtons.expandTooltip : toolbar.nodeExpandButtons.disabledTooltip\" [disabled]=\"selection == null\">\r\n </button>\r\n }\r\n @if (toolbar.nodeExpandButtons.isVisible === true) {\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.nodeExpandButtons.collapseLabel\" icon=\"fa-solid fa-angle-up\" (click)=\"collapseNode()\" [smzTooltip]=\"selection != null ? toolbar.nodeExpandButtons.collapseTooltip : toolbar.nodeExpandButtons.disabledTooltip\" [disabled]=\"selection == null\">\r\n </button>\r\n }\r\n @if (toolbar.treeExpandButtons.isVisible === true) {\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeExpandButtons.expandLabel\" icon=\"fa-solid fa-angles-down\" (click)=\"expandAll()\" [smzTooltip]=\"toolbar.treeExpandButtons.expandLabel != null && toolbar.treeExpandButtons.expandLabel !== '' \r\n ? toolbar.treeExpandButtons.expandLabel \r\n : 'Expandir \u00E1rvore'\">\r\n </button>\r\n }\r\n @if (toolbar.treeExpandButtons.isVisible === true) {\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeExpandButtons.collapseLabel\" icon=\"fa-solid fa-angles-up\" (click)=\"collapseAll()\" [smzTooltip]=\"toolbar.treeExpandButtons.collapseLabel != null && toolbar.treeExpandButtons.collapseLabel !== '' \r\n ? toolbar.treeExpandButtons.collapseLabel \r\n : 'Colapsar \u00E1rvore'\">\r\n </button>\r\n }\r\n @if (toolbar.treeSelectionButtons?.isVisible === true) {\r\n\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeSelectionButtons.selectAllLabel\" icon=\"fa-solid fa-check-double\" (click)=\"selectAll()\" [disabled]=\"state.selection?.mode === 'single'\" [smzTooltip]=\"state.selection?.mode === 'single' \r\n ? 'Dispon\u00EDvel apenas em sele\u00E7\u00E3o m\u00FAltipla' \r\n : (toolbar.treeSelectionButtons.selectAllLabel != null && toolbar.treeSelectionButtons.selectAllLabel !== '' ? toolbar.treeSelectionButtons.selectAllLabel : 'Selecionar tudo')\">\r\n </button>\r\n\r\n <button smzButton smzRipple type=\"button\" [styleClass]=\"{ 'p-button-text': toolbar.buttonType.endsWith('borderless'), 'p-button-outlined': toolbar.buttonType.endsWith('outlined'), 'p-button-rounded': toolbar.buttonType.startsWith('rounded'), 'p-button-secondary': true }\" [label]=\"toolbar.treeSelectionButtons.clearSelectionLabel\" icon=\"fa-solid fa-eraser\" (click)=\"clearSelection()\" [disabled]=\"!hasSelection\" [smzTooltip]=\"toolbar.treeSelectionButtons.clearSelectionLabel != null && toolbar.treeSelectionButtons.clearSelectionLabel !== '' \r\n ? toolbar.treeSelectionButtons.clearSelectionLabel \r\n : 'Limpar sele\u00E7\u00E3o'\">\r\n </button>\r\n }\r\n\r\n @if (actionsTemplate != null) {\r\n <div class=\"grid grid-nogutter items-center justify-start\">\r\n <ng-container *ngTemplateOutlet=\"actionsTemplate; context: { $implicit: dt }\"></ng-container>\r\n </div>\r\n }\r\n </div>\r\n @if (state.filter.show) {\r\n <ui-icon-field class=\"col-12\" [ngClass]=\"state.filter.styleClass\">\r\n <ui-input-icon styleClass=\"fa-solid fa-magnifying-glass\"></ui-input-icon>\r\n <input #inputGlobal smzInputText type=\"text\" (input)=\"dt._filter(inputGlobal.value)\" [placeholder]=\"state.filter.textPlaceholder\" />\r\n </ui-icon-field>\r\n }\r\n </div>\r\n @if (toolbarTemplate != null) {\r\n <div class=\"grid grid-nogutter items-center mt-2\"\r\n [ngClass]=\"'justify-' + state.header.toolbar.alignment\">\r\n <ng-container *ngTemplateOutlet=\"toolbarTemplate; context: { $implicit: dt }\"></ng-container>\r\n </div>\r\n }\r\n }\r\n </ng-template>\r\n }\r\n @if (state.footer.isVisible) {\r\n <ng-template smzTemplate=\"footer\">\r\n <div class=\"grid grid-nogutter justify-start items-center\">\r\n <span class=\"col mr-2\">FOOTER</span>\r\n </div>\r\n </ng-template>\r\n }\r\n @for (content of contentTemplates; track content) {\r\n <ng-template let-node [smzTemplate]=\"content.type\">\r\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\r\n @if (content.template != null) {\r\n <ng-container *ngTemplateOutlet=\"content.template; context: { $implicit: node }\"></ng-container>\r\n } @else {\r\n <div>{{ node.label }}</div>\r\n }\r\n @if (state.menu.behavior === 'row-menu') {\r\n <button smzButton clickStopPropagation (click)=\"onRowMenuOpen(node, rowMenu, $event)\" [icon]=\"state.menu.rowMenuIcon\" [rounded]=\"true\" [text]=\"true\" [severity]=\"state.menu.rowMenuIconSeverity\"></button>\r\n }\r\n </div>\r\n </ng-template>\r\n }\r\n <ng-template let-node smzTemplate=\"Check\">\r\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\r\n <div>{{ node.label }}</div>\r\n @if (state.menu.behavior === 'row-menu') {\r\n <button smzButton clickStopPropagation (click)=\"onRowMenuOpen(node, rowMenu, $event)\" [icon]=\"state.menu.rowMenuIcon\" [rounded]=\"true\" [text]=\"true\" [severity]=\"state.menu.rowMenuIconSeverity\"></button>\r\n }\r\n </div>\r\n </ng-template>\r\n <ng-template smzTemplate=\"empty\">\r\n @if (!state.emptyFeedback.isFeatured) {\r\n <div>{{ state.emptyFeedback.message }}</div>\r\n }\r\n </ng-template>\r\n </ui-tree>\r\n }\r\n }\r\n} @else {\r\n @if (emptyStateTemplate != null) {\r\n <ng-container *ngTemplateOutlet=\"emptyStateTemplate; context: { $implicit: {} }\"></ng-container>\r\n }\r\n}\r\n\r\n" }]
|
|
44690
44744
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: TreeHelperService }], propDecorators: { dt: [{
|
|
44691
44745
|
type: ViewChild,
|
|
44692
44746
|
args: [SmzUiTreeComponent]
|
|
@@ -44978,11 +45032,11 @@ class SmzTreeWithDetailsComponent {
|
|
|
44978
45032
|
this.selectionChange.emit(node);
|
|
44979
45033
|
}
|
|
44980
45034
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzTreeWithDetailsComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
44981
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzTreeWithDetailsComponent, isStandalone: false, selector: "smz-ui-tree-with-details", inputs: { state: "state" }, outputs: { selectionChange: "selectionChange", detailsChange: "detailsChange" }, host: { classAttribute: "absolute inset-0" }, queries: [{ propertyName: "templates", predicate: SmzTemplateDirective }], viewQueries: [{ propertyName: "treeComponent", first: true, predicate: SmzTreeComponent, descendants: true }], usesOnChanges: true, ngImport: i0, template: "@if (state != null) {\n <div class=\"grid grid-nogutter items-start justify-start h-full\" [ngClass]=\"state?.styleClass?.content\">\n <ng-container *ngClone=\"state.items$ | async as items\">\n <!-- TREE -->\n <div class=\"h-full col p-0\">\n <div smzUiBlock #treeContainer [component]=\"treeContainer\" class=\"h-full w-full rounded p-2 bg-surface-a text-text-color border border-solid border-surface-d\">\n <div class=\"h-full\">\n <ng-container *ngVar=\"items | treeItems : state as treeItems\">\n <smz-ui-tree #treeComponent [items]=\"treeItems\" [state]=\"state.tree.state\" (selectionChange)=\"selectionChanged($event)\" [styleClass]=\"state.tree.styleClass\">\n @if (headerTemplate != null) {\n <ng-template smzTemplate=\"header\">\n <ng-container *ngTemplateOutlet=\"headerTemplate; context: { $implicit: state, component: treeContainer, items: treeItems }\"></ng-container>\n </ng-template>\n }\n @if (toolbarTemplate != null) {\n <ng-template smzTemplate=\"toolbar\">\n <ng-container *ngTemplateOutlet=\"toolbarTemplate; context: { $implicit: state, component: treeContainer, items: treeItems }\"></ng-container>\n </ng-template>\n }\n @for (content of contentTemplates; track content) {\n <ng-template let-node [smzTemplate]=\"'type:' + content.type\">\n <ng-container *ngTemplateOutlet=\"content.template; context: { $implicit: node }\"></ng-container>\n </ng-template>\n }\n </smz-ui-tree>\n </ng-container>\n </div>\n </div>\n </div>\n <!-- DETAILS -->\n <div class=\"h-full col-12\" [ngClass]=\"state.layout.detailsStyleClass\">\n <div class=\"h-full items-stretch flex-col grid justify-start grid-nogutter rounded w-full overflow-y-auto bg-surface-a text-text-color border border-solid border-surface-d\">\n <!-- CONTE\u00DADO -->\n @if (state.context.selectedNode != null) {\n @if (detailsTemplate != null) {\n <ng-container *ngTemplateOutlet=\"detailsTemplate; context: { $implicit: state.context.selectedNode, type: state.context.selectedNode?.type }\"></ng-container>\n }\n } @else {\n @if (items != null) {\n @if (emptySelectionTemplate != null) {\n <ng-container *ngTemplateOutlet=\"emptySelectionTemplate; context: { $implicit: state.context.selectedNode, type: state.context.selectedNode?.type }\"></ng-container>\n } @else {\n <div class=\"grid grid-nogutter items-center justify-center p-4 flex-col flex-grow mt-10\">\n <i class=\"fas fa-info-circle text-5xl text-yellow-500 mb-4\"></i>\n <div class=\"text-lg\">Nenhum item selecionado.</div>\n </div>\n }\n }\n }\n </div>\n </div>\n </ng-container>\n </div>\n}", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: SmzTreeComponent, selector: "smz-ui-tree", inputs: ["state", "items", "loading", "styleClass", "inlineStyle", "appendTo", "selection", "selectionKey"], outputs: ["selectedNodes", "selectionChange", "parentChange", "reorder", "blockedDrop", "nodeExpanded", "nodeCollapsed", "treeExpanded", "nodeDropped"] }, { kind: "directive", type: NgCloneDirective, selector: "[ngClone]", inputs: ["ngClone"] }, { kind: "directive", type: SmzUiBlockDirective, selector: "[smzUiBlock]", inputs: ["component"] }, { kind: "directive", type: NgVar, selector: "[ngVar]", inputs: ["ngVar"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: TreeItemsPipe, name: "treeItems" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
45035
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzTreeWithDetailsComponent, isStandalone: false, selector: "smz-ui-tree-with-details", inputs: { state: "state" }, outputs: { selectionChange: "selectionChange", detailsChange: "detailsChange" }, host: { classAttribute: "absolute inset-0" }, queries: [{ propertyName: "templates", predicate: SmzTemplateDirective }], viewQueries: [{ propertyName: "treeComponent", first: true, predicate: SmzTreeComponent, descendants: true }], usesOnChanges: true, ngImport: i0, template: "@if (state != null) {\r\n <div class=\"grid grid-nogutter items-start justify-start h-full\" [ngClass]=\"state?.styleClass?.content\">\r\n <ng-container *ngClone=\"state.items$ | async as items\">\r\n <!-- TREE -->\r\n <div class=\"h-full col p-0\">\r\n <div smzUiBlock #treeContainer [component]=\"treeContainer\" class=\"h-full w-full rounded p-2 bg-surface-a text-text-color border border-solid border-surface-d\">\r\n <div class=\"h-full\">\r\n <ng-container *ngVar=\"items | treeItems : state as treeItems\">\r\n <smz-ui-tree #treeComponent [items]=\"treeItems\" [state]=\"state.tree.state\" (selectionChange)=\"selectionChanged($event)\" [styleClass]=\"state.tree.styleClass\">\r\n @if (headerTemplate != null) {\r\n <ng-template smzTemplate=\"header\">\r\n <ng-container *ngTemplateOutlet=\"headerTemplate; context: { $implicit: state, component: treeContainer, items: treeItems }\"></ng-container>\r\n </ng-template>\r\n }\r\n @if (toolbarTemplate != null) {\r\n <ng-template smzTemplate=\"toolbar\">\r\n <ng-container *ngTemplateOutlet=\"toolbarTemplate; context: { $implicit: state, component: treeContainer, items: treeItems }\"></ng-container>\r\n </ng-template>\r\n }\r\n @for (content of contentTemplates; track content) {\r\n <ng-template let-node [smzTemplate]=\"'type:' + content.type\">\r\n <ng-container *ngTemplateOutlet=\"content.template; context: { $implicit: node }\"></ng-container>\r\n </ng-template>\r\n }\r\n </smz-ui-tree>\r\n </ng-container>\r\n </div>\r\n </div>\r\n </div>\r\n <!-- DETAILS -->\r\n <div class=\"h-full col-12\" [ngClass]=\"state.layout.detailsStyleClass\">\r\n <div class=\"h-full items-stretch flex-col grid justify-start grid-nogutter rounded w-full overflow-y-auto bg-surface-a text-text-color border border-solid border-surface-d\">\r\n <!-- CONTE\u00DADO -->\r\n @if (state.context.selectedNode != null) {\r\n @if (detailsTemplate != null) {\r\n <ng-container *ngTemplateOutlet=\"detailsTemplate; context: { $implicit: state.context.selectedNode, type: state.context.selectedNode?.type }\"></ng-container>\r\n }\r\n } @else {\r\n @if (items != null) {\r\n @if (emptySelectionTemplate != null) {\r\n <ng-container *ngTemplateOutlet=\"emptySelectionTemplate; context: { $implicit: state.context.selectedNode, type: state.context.selectedNode?.type }\"></ng-container>\r\n } @else {\r\n <div class=\"grid grid-nogutter items-center justify-center p-4 flex-col flex-grow mt-10\">\r\n <i class=\"fas fa-info-circle text-5xl text-yellow-500 mb-4\"></i>\r\n <div class=\"text-lg\">Nenhum item selecionado.</div>\r\n </div>\r\n }\r\n }\r\n }\r\n </div>\r\n </div>\r\n </ng-container>\r\n </div>\r\n}", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: SmzTreeComponent, selector: "smz-ui-tree", inputs: ["state", "items", "loading", "styleClass", "inlineStyle", "appendTo", "selection", "selectionKey"], outputs: ["selectedNodes", "selectionChange", "parentChange", "reorder", "blockedDrop", "nodeExpanded", "nodeCollapsed", "treeExpanded", "nodeDropped"] }, { kind: "directive", type: NgCloneDirective, selector: "[ngClone]", inputs: ["ngClone"] }, { kind: "directive", type: SmzUiBlockDirective, selector: "[smzUiBlock]", inputs: ["component"] }, { kind: "directive", type: NgVar, selector: "[ngVar]", inputs: ["ngVar"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: TreeItemsPipe, name: "treeItems" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
44982
45036
|
}
|
|
44983
45037
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzTreeWithDetailsComponent, decorators: [{
|
|
44984
45038
|
type: Component,
|
|
44985
|
-
args: [{ selector: 'smz-ui-tree-with-details', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'absolute inset-0' }, standalone: false, template: "@if (state != null) {\n <div class=\"grid grid-nogutter items-start justify-start h-full\" [ngClass]=\"state?.styleClass?.content\">\n <ng-container *ngClone=\"state.items$ | async as items\">\n <!-- TREE -->\n <div class=\"h-full col p-0\">\n <div smzUiBlock #treeContainer [component]=\"treeContainer\" class=\"h-full w-full rounded p-2 bg-surface-a text-text-color border border-solid border-surface-d\">\n <div class=\"h-full\">\n <ng-container *ngVar=\"items | treeItems : state as treeItems\">\n <smz-ui-tree #treeComponent [items]=\"treeItems\" [state]=\"state.tree.state\" (selectionChange)=\"selectionChanged($event)\" [styleClass]=\"state.tree.styleClass\">\n @if (headerTemplate != null) {\n <ng-template smzTemplate=\"header\">\n <ng-container *ngTemplateOutlet=\"headerTemplate; context: { $implicit: state, component: treeContainer, items: treeItems }\"></ng-container>\n </ng-template>\n }\n @if (toolbarTemplate != null) {\n <ng-template smzTemplate=\"toolbar\">\n <ng-container *ngTemplateOutlet=\"toolbarTemplate; context: { $implicit: state, component: treeContainer, items: treeItems }\"></ng-container>\n </ng-template>\n }\n @for (content of contentTemplates; track content) {\n <ng-template let-node [smzTemplate]=\"'type:' + content.type\">\n <ng-container *ngTemplateOutlet=\"content.template; context: { $implicit: node }\"></ng-container>\n </ng-template>\n }\n </smz-ui-tree>\n </ng-container>\n </div>\n </div>\n </div>\n <!-- DETAILS -->\n <div class=\"h-full col-12\" [ngClass]=\"state.layout.detailsStyleClass\">\n <div class=\"h-full items-stretch flex-col grid justify-start grid-nogutter rounded w-full overflow-y-auto bg-surface-a text-text-color border border-solid border-surface-d\">\n <!-- CONTE\u00DADO -->\n @if (state.context.selectedNode != null) {\n @if (detailsTemplate != null) {\n <ng-container *ngTemplateOutlet=\"detailsTemplate; context: { $implicit: state.context.selectedNode, type: state.context.selectedNode?.type }\"></ng-container>\n }\n } @else {\n @if (items != null) {\n @if (emptySelectionTemplate != null) {\n <ng-container *ngTemplateOutlet=\"emptySelectionTemplate; context: { $implicit: state.context.selectedNode, type: state.context.selectedNode?.type }\"></ng-container>\n } @else {\n <div class=\"grid grid-nogutter items-center justify-center p-4 flex-col flex-grow mt-10\">\n <i class=\"fas fa-info-circle text-5xl text-yellow-500 mb-4\"></i>\n <div class=\"text-lg\">Nenhum item selecionado.</div>\n </div>\n }\n }\n }\n </div>\n </div>\n </ng-container>\n </div>\n}" }]
|
|
45039
|
+
args: [{ selector: 'smz-ui-tree-with-details', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'absolute inset-0' }, standalone: false, template: "@if (state != null) {\r\n <div class=\"grid grid-nogutter items-start justify-start h-full\" [ngClass]=\"state?.styleClass?.content\">\r\n <ng-container *ngClone=\"state.items$ | async as items\">\r\n <!-- TREE -->\r\n <div class=\"h-full col p-0\">\r\n <div smzUiBlock #treeContainer [component]=\"treeContainer\" class=\"h-full w-full rounded p-2 bg-surface-a text-text-color border border-solid border-surface-d\">\r\n <div class=\"h-full\">\r\n <ng-container *ngVar=\"items | treeItems : state as treeItems\">\r\n <smz-ui-tree #treeComponent [items]=\"treeItems\" [state]=\"state.tree.state\" (selectionChange)=\"selectionChanged($event)\" [styleClass]=\"state.tree.styleClass\">\r\n @if (headerTemplate != null) {\r\n <ng-template smzTemplate=\"header\">\r\n <ng-container *ngTemplateOutlet=\"headerTemplate; context: { $implicit: state, component: treeContainer, items: treeItems }\"></ng-container>\r\n </ng-template>\r\n }\r\n @if (toolbarTemplate != null) {\r\n <ng-template smzTemplate=\"toolbar\">\r\n <ng-container *ngTemplateOutlet=\"toolbarTemplate; context: { $implicit: state, component: treeContainer, items: treeItems }\"></ng-container>\r\n </ng-template>\r\n }\r\n @for (content of contentTemplates; track content) {\r\n <ng-template let-node [smzTemplate]=\"'type:' + content.type\">\r\n <ng-container *ngTemplateOutlet=\"content.template; context: { $implicit: node }\"></ng-container>\r\n </ng-template>\r\n }\r\n </smz-ui-tree>\r\n </ng-container>\r\n </div>\r\n </div>\r\n </div>\r\n <!-- DETAILS -->\r\n <div class=\"h-full col-12\" [ngClass]=\"state.layout.detailsStyleClass\">\r\n <div class=\"h-full items-stretch flex-col grid justify-start grid-nogutter rounded w-full overflow-y-auto bg-surface-a text-text-color border border-solid border-surface-d\">\r\n <!-- CONTE\u00DADO -->\r\n @if (state.context.selectedNode != null) {\r\n @if (detailsTemplate != null) {\r\n <ng-container *ngTemplateOutlet=\"detailsTemplate; context: { $implicit: state.context.selectedNode, type: state.context.selectedNode?.type }\"></ng-container>\r\n }\r\n } @else {\r\n @if (items != null) {\r\n @if (emptySelectionTemplate != null) {\r\n <ng-container *ngTemplateOutlet=\"emptySelectionTemplate; context: { $implicit: state.context.selectedNode, type: state.context.selectedNode?.type }\"></ng-container>\r\n } @else {\r\n <div class=\"grid grid-nogutter items-center justify-center p-4 flex-col flex-grow mt-10\">\r\n <i class=\"fas fa-info-circle text-5xl text-yellow-500 mb-4\"></i>\r\n <div class=\"text-lg\">Nenhum item selecionado.</div>\r\n </div>\r\n }\r\n }\r\n }\r\n </div>\r\n </div>\r\n </ng-container>\r\n </div>\r\n}" }]
|
|
44986
45040
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { treeComponent: [{
|
|
44987
45041
|
type: ViewChild,
|
|
44988
45042
|
args: [SmzTreeComponent]
|
|
@@ -45997,7 +46051,7 @@ var CommentsForms;
|
|
|
45997
46051
|
const commentInput = {
|
|
45998
46052
|
propertyName: 'comment', name: 'Escreva seu comentário', type: SmzControlType.TEXT_AREA,
|
|
45999
46053
|
defaultValue: label,
|
|
46000
|
-
template: { large: { row:
|
|
46054
|
+
template: { large: { row: 12 } },
|
|
46001
46055
|
validatorsPreset: { isRequired: true, minLength: 2 },
|
|
46002
46056
|
isDisabled: false, textAreaRows: 7,
|
|
46003
46057
|
advancedSettings: {
|
|
@@ -46073,74 +46127,74 @@ class SmzCommentsComponent {
|
|
|
46073
46127
|
});
|
|
46074
46128
|
}
|
|
46075
46129
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzCommentsComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: SmzDialogsService }, { token: i1$3.Store }], target: i0.ɵɵFactoryTarget.Component });
|
|
46076
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzCommentsComponent, isStandalone: false, selector: "smz-comments", inputs: { state: "state", data: "data" }, ngImport: i0, template: `
|
|
46077
|
-
<!-- <mentionable-textarea [users]="users" class="w-full"></mentionable-textarea> -->
|
|
46078
|
-
@if (data.length > 0) {
|
|
46079
|
-
<ui-tree [value]="data">
|
|
46080
|
-
<ng-template let-node smzTemplate="default">
|
|
46081
|
-
<!-- CONTAINER -->
|
|
46082
|
-
<div class="grid grid-nogutter items-start justify-start flex-nowrap gap-3 mb-3 py-1">
|
|
46083
|
-
<!-- AVATAR -->
|
|
46084
|
-
<img class="w-20" [src]="node.data.avatar | safeUrl"/>
|
|
46085
|
-
<!-- CONTENT -->
|
|
46086
|
-
<div class="col grid grid-nogutter flex-col items-start justify-start gap-2">
|
|
46087
|
-
<!-- NAME AND DATE -->
|
|
46088
|
-
<div class="grid grid-nogutter items-center justify-start gap-2">
|
|
46089
|
-
<!-- DISPLAY NAME -->
|
|
46090
|
-
<div class="font-bold leading-4">{{ node.data.displayName }}</div>
|
|
46091
|
-
<!-- DATE: lastUpdated → timestamp → date -->
|
|
46092
|
-
<div class="text-xs pt-px">{{ resolveCommentDate(node.data) | simpleCalendar : 'fromNow' }}</div>
|
|
46093
|
-
</div>
|
|
46094
|
-
<!-- MESSAGE -->
|
|
46095
|
-
<div [innerHTML]="node.label | safeHtml"></div>
|
|
46096
|
-
<!-- ACTIONS -->
|
|
46097
|
-
@if (state.response.enabled) {
|
|
46098
|
-
<a class="cursor-pointer text-sm" (click)="showCreateDialog(node)">{{ state.locale.answser }}</a>
|
|
46099
|
-
}
|
|
46100
|
-
</div>
|
|
46101
|
-
</div>
|
|
46102
|
-
</ng-template>
|
|
46103
|
-
</ui-tree>
|
|
46104
|
-
} @else {
|
|
46105
|
-
<smz-icon-message [icon]="'far fa-comment'" [message]="state.locale.emptyMessage" [comment]="state.locale.firstMessage"></smz-icon-message>
|
|
46106
|
-
}
|
|
46107
|
-
|
|
46130
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzCommentsComponent, isStandalone: false, selector: "smz-comments", inputs: { state: "state", data: "data" }, ngImport: i0, template: `
|
|
46131
|
+
<!-- <mentionable-textarea [users]="users" class="w-full"></mentionable-textarea> -->
|
|
46132
|
+
@if (data.length > 0) {
|
|
46133
|
+
<ui-tree [value]="data">
|
|
46134
|
+
<ng-template let-node smzTemplate="default">
|
|
46135
|
+
<!-- CONTAINER -->
|
|
46136
|
+
<div class="grid grid-nogutter items-start justify-start flex-nowrap gap-3 mb-3 py-1">
|
|
46137
|
+
<!-- AVATAR -->
|
|
46138
|
+
<img class="w-20" [src]="node.data.avatar | safeUrl"/>
|
|
46139
|
+
<!-- CONTENT -->
|
|
46140
|
+
<div class="col grid grid-nogutter flex-col items-start justify-start gap-2">
|
|
46141
|
+
<!-- NAME AND DATE -->
|
|
46142
|
+
<div class="grid grid-nogutter items-center justify-start gap-2">
|
|
46143
|
+
<!-- DISPLAY NAME -->
|
|
46144
|
+
<div class="font-bold leading-4">{{ node.data.displayName }}</div>
|
|
46145
|
+
<!-- DATE: lastUpdated → timestamp → date -->
|
|
46146
|
+
<div class="text-xs pt-px">{{ resolveCommentDate(node.data) | simpleCalendar : 'fromNow' }}</div>
|
|
46147
|
+
</div>
|
|
46148
|
+
<!-- MESSAGE -->
|
|
46149
|
+
<div [innerHTML]="node.label | safeHtml"></div>
|
|
46150
|
+
<!-- ACTIONS -->
|
|
46151
|
+
@if (state.response.enabled) {
|
|
46152
|
+
<a class="cursor-pointer text-sm" (click)="showCreateDialog(node)">{{ state.locale.answser }}</a>
|
|
46153
|
+
}
|
|
46154
|
+
</div>
|
|
46155
|
+
</div>
|
|
46156
|
+
</ng-template>
|
|
46157
|
+
</ui-tree>
|
|
46158
|
+
} @else {
|
|
46159
|
+
<smz-icon-message [icon]="'far fa-comment'" [message]="state.locale.emptyMessage" [comment]="state.locale.firstMessage"></smz-icon-message>
|
|
46160
|
+
}
|
|
46161
|
+
|
|
46108
46162
|
`, isInline: true, styles: ["smz-comments .p-tree .p-tree-container .p-treenode .p-treenode-content:focus{box-shadow:unset!important}\n"], dependencies: [{ kind: "component", type: i2.SmzUiTreeComponent, selector: "ui-tree", inputs: ["value", "selectionMode", "selection", "metaKeySelection", "propagateSelectionUp", "propagateSelectionDown", "loading", "loadingIcon", "filter", "filterMode", "filterPlaceholder", "filterBy", "emptyMessage", "draggableNodes", "droppableNodes", "validateDrop", "scrollHeight", "style", "styleClass", "contextMenu", "templateOverride", "layout", "virtualScroll"], outputs: ["selectionChange", "nodeSelect", "nodeUnselect", "nodeExpand", "nodeCollapse", "nodeContextMenuSelect", "nodeDblClick", "nodeDrop", "filtered"] }, { kind: "component", type: SmzIconMessageComponent, selector: "smz-icon-message", inputs: ["icon", "message", "comment"] }, { kind: "pipe", type: SafeHtmlPipe$2, name: "safeHtml" }, { kind: "pipe", type: SafeUrlPipe$1, name: "safeUrl" }, { kind: "pipe", type: SimpleCalendarPipe, name: "simpleCalendar" }], changeDetection: i0.ChangeDetectionStrategy.Eager, encapsulation: i0.ViewEncapsulation.None });
|
|
46109
46163
|
}
|
|
46110
46164
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzCommentsComponent, decorators: [{
|
|
46111
46165
|
type: Component,
|
|
46112
|
-
args: [{ selector: 'smz-comments', template: `
|
|
46113
|
-
<!-- <mentionable-textarea [users]="users" class="w-full"></mentionable-textarea> -->
|
|
46114
|
-
@if (data.length > 0) {
|
|
46115
|
-
<ui-tree [value]="data">
|
|
46116
|
-
<ng-template let-node smzTemplate="default">
|
|
46117
|
-
<!-- CONTAINER -->
|
|
46118
|
-
<div class="grid grid-nogutter items-start justify-start flex-nowrap gap-3 mb-3 py-1">
|
|
46119
|
-
<!-- AVATAR -->
|
|
46120
|
-
<img class="w-20" [src]="node.data.avatar | safeUrl"/>
|
|
46121
|
-
<!-- CONTENT -->
|
|
46122
|
-
<div class="col grid grid-nogutter flex-col items-start justify-start gap-2">
|
|
46123
|
-
<!-- NAME AND DATE -->
|
|
46124
|
-
<div class="grid grid-nogutter items-center justify-start gap-2">
|
|
46125
|
-
<!-- DISPLAY NAME -->
|
|
46126
|
-
<div class="font-bold leading-4">{{ node.data.displayName }}</div>
|
|
46127
|
-
<!-- DATE: lastUpdated → timestamp → date -->
|
|
46128
|
-
<div class="text-xs pt-px">{{ resolveCommentDate(node.data) | simpleCalendar : 'fromNow' }}</div>
|
|
46129
|
-
</div>
|
|
46130
|
-
<!-- MESSAGE -->
|
|
46131
|
-
<div [innerHTML]="node.label | safeHtml"></div>
|
|
46132
|
-
<!-- ACTIONS -->
|
|
46133
|
-
@if (state.response.enabled) {
|
|
46134
|
-
<a class="cursor-pointer text-sm" (click)="showCreateDialog(node)">{{ state.locale.answser }}</a>
|
|
46135
|
-
}
|
|
46136
|
-
</div>
|
|
46137
|
-
</div>
|
|
46138
|
-
</ng-template>
|
|
46139
|
-
</ui-tree>
|
|
46140
|
-
} @else {
|
|
46141
|
-
<smz-icon-message [icon]="'far fa-comment'" [message]="state.locale.emptyMessage" [comment]="state.locale.firstMessage"></smz-icon-message>
|
|
46142
|
-
}
|
|
46143
|
-
|
|
46166
|
+
args: [{ selector: 'smz-comments', template: `
|
|
46167
|
+
<!-- <mentionable-textarea [users]="users" class="w-full"></mentionable-textarea> -->
|
|
46168
|
+
@if (data.length > 0) {
|
|
46169
|
+
<ui-tree [value]="data">
|
|
46170
|
+
<ng-template let-node smzTemplate="default">
|
|
46171
|
+
<!-- CONTAINER -->
|
|
46172
|
+
<div class="grid grid-nogutter items-start justify-start flex-nowrap gap-3 mb-3 py-1">
|
|
46173
|
+
<!-- AVATAR -->
|
|
46174
|
+
<img class="w-20" [src]="node.data.avatar | safeUrl"/>
|
|
46175
|
+
<!-- CONTENT -->
|
|
46176
|
+
<div class="col grid grid-nogutter flex-col items-start justify-start gap-2">
|
|
46177
|
+
<!-- NAME AND DATE -->
|
|
46178
|
+
<div class="grid grid-nogutter items-center justify-start gap-2">
|
|
46179
|
+
<!-- DISPLAY NAME -->
|
|
46180
|
+
<div class="font-bold leading-4">{{ node.data.displayName }}</div>
|
|
46181
|
+
<!-- DATE: lastUpdated → timestamp → date -->
|
|
46182
|
+
<div class="text-xs pt-px">{{ resolveCommentDate(node.data) | simpleCalendar : 'fromNow' }}</div>
|
|
46183
|
+
</div>
|
|
46184
|
+
<!-- MESSAGE -->
|
|
46185
|
+
<div [innerHTML]="node.label | safeHtml"></div>
|
|
46186
|
+
<!-- ACTIONS -->
|
|
46187
|
+
@if (state.response.enabled) {
|
|
46188
|
+
<a class="cursor-pointer text-sm" (click)="showCreateDialog(node)">{{ state.locale.answser }}</a>
|
|
46189
|
+
}
|
|
46190
|
+
</div>
|
|
46191
|
+
</div>
|
|
46192
|
+
</ng-template>
|
|
46193
|
+
</ui-tree>
|
|
46194
|
+
} @else {
|
|
46195
|
+
<smz-icon-message [icon]="'far fa-comment'" [message]="state.locale.emptyMessage" [comment]="state.locale.firstMessage"></smz-icon-message>
|
|
46196
|
+
}
|
|
46197
|
+
|
|
46144
46198
|
`, changeDetection: ChangeDetectionStrategy.Default, encapsulation: ViewEncapsulation.None, standalone: false, styles: ["smz-comments .p-tree .p-tree-container .p-treenode .p-treenode-content:focus{box-shadow:unset!important}\n"] }]
|
|
46145
46199
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: SmzDialogsService }, { type: i1$3.Store }], propDecorators: { state: [{
|
|
46146
46200
|
type: Input
|
|
@@ -46921,9 +46975,9 @@ class ServerImageDirective {
|
|
|
46921
46975
|
.if(this.openMaximized)
|
|
46922
46976
|
.openMaximized()
|
|
46923
46977
|
.endIf
|
|
46924
|
-
.setLayout('EXTRA_LARGE',
|
|
46925
|
-
.setLayout('LARGE',
|
|
46926
|
-
.setLayout('MEDIUM',
|
|
46978
|
+
.setLayout('EXTRA_LARGE', 8)
|
|
46979
|
+
.setLayout('LARGE', 10)
|
|
46980
|
+
.setLayout('MEDIUM', 12)
|
|
46927
46981
|
.html([`<img src="${this.currentSrc}" class="w-full">`])
|
|
46928
46982
|
.hideFooter()
|
|
46929
46983
|
.build());
|
|
@@ -47916,7 +47970,7 @@ class SmzTimelineComponent {
|
|
|
47916
47970
|
this.cdr.markForCheck();
|
|
47917
47971
|
}
|
|
47918
47972
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzTimelineComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
47919
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzTimelineComponent, isStandalone: true, selector: "smz-ui-timeline", inputs: { state: "state" }, queries: [{ propertyName: "templates", predicate: SmzTemplateDirective }], ngImport: i0, template: "@if (state != null) {\n @if (state.items$ | async; as items) {\n @if (state.title.isVisible || headerTemplate != null || state.sources.length > 0) {\n <div class=\"grid grid-nogutter lg:flex-row xl:flex-row md:flex-col sm:flex-col items-center justify-between gap-2 mb-3\">\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\n @if (state.title.isVisible) {\n <div class=\"text-lg\" [innerHtml]=\"state.title.getText() | safeHtml\"></div>\n }\n </div>\n <div class=\"grid grid-nogutter items-center justify-end gap-3\">\n @if (headerTemplate != null) {\n <ng-container *ngTemplateOutlet=\"headerTemplate; context: { $implicit: state }\"></ng-container>\n }\n @if (state.sources.length > 0) {\n <ui-select appendTo=\"body\" [options]=\"state.sources\" dataKey=\"key\" [(ngModel)]=\"state.selectedSource\" optionLabel=\"label\" (changed)=\"updateMainSource($event)\"></ui-select>\n }\n </div>\n </div>\n }\n @if (items?.length > 0) {\n <ui-timeline [value]=\"items\" [align]=\"state.view.align\" [styleClass]=\"state.view.styleClass.timeline\">\n <ng-template smzTemplate=\"marker\" let-event>\n <span [ngClass]=\"state.marker.styleClass\">\n <i [ngClass]=\"state.marker.icon\"></i>\n </span>\n </ng-template>\n <ng-template smzTemplate=\"content\" let-event>\n @if (state.template != null) {\n <smz-grid-item [isDebug]=\"state.isDebug\" [template]=\"state.template\" [data]=\"event\" [menu]=\"state.menu\" [buttons]=\"state.buttons\" [ngClass]=\"state.view.styleClass.event\"></smz-grid-item>\n }\n </ng-template>\n </ui-timeline>\n } @else {\n <div>{{ state.locale.emptyMessage }}</div>\n }\n }\n}", styles: ["@media screen and (max-width:960px){smz-ui-timeline .mobile-timeline .p-timeline-event:nth-child(2n){flex-direction:row!important}smz-ui-timeline .mobile-timeline .p-timeline-event:nth-child(2n) .p-timeline-event-content{text-align:left!important}smz-ui-timeline .mobile-timeline .p-timeline-event-opposite{flex:0}}smz-ui-timeline .p-timeline-left .p-timeline-event-opposite{display:none}smz-ui-timeline .p-timeline-right .p-timeline-event-opposite{display:none}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: SmzSelectComponent, selector: "ui-select", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "placeholder", "filter", "filterBy", "filterMatchMode", "filterPlaceholder", "showClear", "emptyMessage", "emptyFilterMessage", "styleClass", "inputId", "ariaLabel", "appendTo"], outputs: ["changed", "showed", "hidden"] }, { kind: "component", type: SmzUiTimelineComponent, selector: "ui-timeline", inputs: ["value", "align", "layout", "styleClass"] }, { kind: "ngmodule", type: SafeContentPipeModule }, { kind: "ngmodule", type: NgxSmzCardsModule }, { kind: "component", type: SmzGridItemComponent, selector: "smz-grid-item", inputs: ["isDebug", "template", "buttons", "menu", "data"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: SafeHtmlPipe$1, name: "safeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
47973
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.1", type: SmzTimelineComponent, isStandalone: true, selector: "smz-ui-timeline", inputs: { state: "state" }, queries: [{ propertyName: "templates", predicate: SmzTemplateDirective }], ngImport: i0, template: "@if (state != null) {\r\n @if (state.items$ | async; as items) {\r\n @if (state.title.isVisible || headerTemplate != null || state.sources.length > 0) {\r\n <div class=\"grid grid-nogutter lg:flex-row xl:flex-row md:flex-col sm:flex-col items-center justify-between gap-2 mb-3\">\r\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\r\n @if (state.title.isVisible) {\r\n <div class=\"text-lg\" [innerHtml]=\"state.title.getText() | safeHtml\"></div>\r\n }\r\n </div>\r\n <div class=\"grid grid-nogutter items-center justify-end gap-3\">\r\n @if (headerTemplate != null) {\r\n <ng-container *ngTemplateOutlet=\"headerTemplate; context: { $implicit: state }\"></ng-container>\r\n }\r\n @if (state.sources.length > 0) {\r\n <ui-select appendTo=\"body\" [options]=\"state.sources\" dataKey=\"key\" [(ngModel)]=\"state.selectedSource\" optionLabel=\"label\" (changed)=\"updateMainSource($event)\"></ui-select>\r\n }\r\n </div>\r\n </div>\r\n }\r\n @if (items?.length > 0) {\r\n <ui-timeline [value]=\"items\" [align]=\"state.view.align\" [styleClass]=\"state.view.styleClass.timeline\">\r\n <ng-template smzTemplate=\"marker\" let-event>\r\n <span [ngClass]=\"state.marker.styleClass\">\r\n <i [ngClass]=\"state.marker.icon\"></i>\r\n </span>\r\n </ng-template>\r\n <ng-template smzTemplate=\"content\" let-event>\r\n @if (state.template != null) {\r\n <smz-grid-item [isDebug]=\"state.isDebug\" [template]=\"state.template\" [data]=\"event\" [menu]=\"state.menu\" [buttons]=\"state.buttons\" [ngClass]=\"state.view.styleClass.event\"></smz-grid-item>\r\n }\r\n </ng-template>\r\n </ui-timeline>\r\n } @else {\r\n <div>{{ state.locale.emptyMessage }}</div>\r\n }\r\n }\r\n}", styles: ["@media screen and (max-width:960px){smz-ui-timeline .mobile-timeline .p-timeline-event:nth-child(2n){flex-direction:row!important}smz-ui-timeline .mobile-timeline .p-timeline-event:nth-child(2n) .p-timeline-event-content{text-align:left!important}smz-ui-timeline .mobile-timeline .p-timeline-event-opposite{flex:0}}smz-ui-timeline .p-timeline-left .p-timeline-event-opposite{display:none}smz-ui-timeline .p-timeline-right .p-timeline-event-opposite{display:none}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: SmzTemplateDirective, selector: "ng-template[smzTemplate]", inputs: ["smzTemplate"] }, { kind: "component", type: SmzSelectComponent, selector: "ui-select", inputs: ["options", "optionLabel", "optionValue", "optionDisabled", "dataKey", "placeholder", "filter", "filterBy", "filterMatchMode", "filterPlaceholder", "showClear", "emptyMessage", "emptyFilterMessage", "styleClass", "inputId", "ariaLabel", "appendTo"], outputs: ["changed", "showed", "hidden"] }, { kind: "component", type: SmzUiTimelineComponent, selector: "ui-timeline", inputs: ["value", "align", "layout", "styleClass"] }, { kind: "ngmodule", type: SafeContentPipeModule }, { kind: "ngmodule", type: NgxSmzCardsModule }, { kind: "component", type: SmzGridItemComponent, selector: "smz-grid-item", inputs: ["isDebug", "template", "buttons", "menu", "data"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: SafeHtmlPipe$1, name: "safeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
47920
47974
|
}
|
|
47921
47975
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzTimelineComponent, decorators: [{
|
|
47922
47976
|
type: Component,
|
|
@@ -47928,7 +47982,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImpor
|
|
|
47928
47982
|
SmzUiTimelineComponent,
|
|
47929
47983
|
SafeContentPipeModule,
|
|
47930
47984
|
NgxSmzCardsModule,
|
|
47931
|
-
], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "@if (state != null) {\n @if (state.items$ | async; as items) {\n @if (state.title.isVisible || headerTemplate != null || state.sources.length > 0) {\n <div class=\"grid grid-nogutter lg:flex-row xl:flex-row md:flex-col sm:flex-col items-center justify-between gap-2 mb-3\">\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\n @if (state.title.isVisible) {\n <div class=\"text-lg\" [innerHtml]=\"state.title.getText() | safeHtml\"></div>\n }\n </div>\n <div class=\"grid grid-nogutter items-center justify-end gap-3\">\n @if (headerTemplate != null) {\n <ng-container *ngTemplateOutlet=\"headerTemplate; context: { $implicit: state }\"></ng-container>\n }\n @if (state.sources.length > 0) {\n <ui-select appendTo=\"body\" [options]=\"state.sources\" dataKey=\"key\" [(ngModel)]=\"state.selectedSource\" optionLabel=\"label\" (changed)=\"updateMainSource($event)\"></ui-select>\n }\n </div>\n </div>\n }\n @if (items?.length > 0) {\n <ui-timeline [value]=\"items\" [align]=\"state.view.align\" [styleClass]=\"state.view.styleClass.timeline\">\n <ng-template smzTemplate=\"marker\" let-event>\n <span [ngClass]=\"state.marker.styleClass\">\n <i [ngClass]=\"state.marker.icon\"></i>\n </span>\n </ng-template>\n <ng-template smzTemplate=\"content\" let-event>\n @if (state.template != null) {\n <smz-grid-item [isDebug]=\"state.isDebug\" [template]=\"state.template\" [data]=\"event\" [menu]=\"state.menu\" [buttons]=\"state.buttons\" [ngClass]=\"state.view.styleClass.event\"></smz-grid-item>\n }\n </ng-template>\n </ui-timeline>\n } @else {\n <div>{{ state.locale.emptyMessage }}</div>\n }\n }\n}", styles: ["@media screen and (max-width:960px){smz-ui-timeline .mobile-timeline .p-timeline-event:nth-child(2n){flex-direction:row!important}smz-ui-timeline .mobile-timeline .p-timeline-event:nth-child(2n) .p-timeline-event-content{text-align:left!important}smz-ui-timeline .mobile-timeline .p-timeline-event-opposite{flex:0}}smz-ui-timeline .p-timeline-left .p-timeline-event-opposite{display:none}smz-ui-timeline .p-timeline-right .p-timeline-event-opposite{display:none}\n"] }]
|
|
47985
|
+
], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "@if (state != null) {\r\n @if (state.items$ | async; as items) {\r\n @if (state.title.isVisible || headerTemplate != null || state.sources.length > 0) {\r\n <div class=\"grid grid-nogutter lg:flex-row xl:flex-row md:flex-col sm:flex-col items-center justify-between gap-2 mb-3\">\r\n <div class=\"grid grid-nogutter items-center justify-start gap-2\">\r\n @if (state.title.isVisible) {\r\n <div class=\"text-lg\" [innerHtml]=\"state.title.getText() | safeHtml\"></div>\r\n }\r\n </div>\r\n <div class=\"grid grid-nogutter items-center justify-end gap-3\">\r\n @if (headerTemplate != null) {\r\n <ng-container *ngTemplateOutlet=\"headerTemplate; context: { $implicit: state }\"></ng-container>\r\n }\r\n @if (state.sources.length > 0) {\r\n <ui-select appendTo=\"body\" [options]=\"state.sources\" dataKey=\"key\" [(ngModel)]=\"state.selectedSource\" optionLabel=\"label\" (changed)=\"updateMainSource($event)\"></ui-select>\r\n }\r\n </div>\r\n </div>\r\n }\r\n @if (items?.length > 0) {\r\n <ui-timeline [value]=\"items\" [align]=\"state.view.align\" [styleClass]=\"state.view.styleClass.timeline\">\r\n <ng-template smzTemplate=\"marker\" let-event>\r\n <span [ngClass]=\"state.marker.styleClass\">\r\n <i [ngClass]=\"state.marker.icon\"></i>\r\n </span>\r\n </ng-template>\r\n <ng-template smzTemplate=\"content\" let-event>\r\n @if (state.template != null) {\r\n <smz-grid-item [isDebug]=\"state.isDebug\" [template]=\"state.template\" [data]=\"event\" [menu]=\"state.menu\" [buttons]=\"state.buttons\" [ngClass]=\"state.view.styleClass.event\"></smz-grid-item>\r\n }\r\n </ng-template>\r\n </ui-timeline>\r\n } @else {\r\n <div>{{ state.locale.emptyMessage }}</div>\r\n }\r\n }\r\n}", styles: ["@media screen and (max-width:960px){smz-ui-timeline .mobile-timeline .p-timeline-event:nth-child(2n){flex-direction:row!important}smz-ui-timeline .mobile-timeline .p-timeline-event:nth-child(2n) .p-timeline-event-content{text-align:left!important}smz-ui-timeline .mobile-timeline .p-timeline-event-opposite{flex:0}}smz-ui-timeline .p-timeline-left .p-timeline-event-opposite{display:none}smz-ui-timeline .p-timeline-right .p-timeline-event-opposite{display:none}\n"] }]
|
|
47932
47986
|
}], propDecorators: { templates: [{
|
|
47933
47987
|
type: ContentChildren,
|
|
47934
47988
|
args: [SmzTemplateDirective]
|
|
@@ -47982,7 +48036,7 @@ class SmzMultiTablesComponent {
|
|
|
47982
48036
|
</ui-tab-panels>
|
|
47983
48037
|
</ui-tabs>
|
|
47984
48038
|
}
|
|
47985
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: i2.SmzTabsComponent, selector: "ui-tabs", inputs: ["value", "lazy", "scrollable"], outputs: ["valueChange"] }, { kind: "component", type: i2.SmzTabListComponent, selector: "ui-tab-list" }, { kind: "component", type: i2.SmzTabComponent, selector: "ui-tab", inputs: ["value", "disabled"] }, { kind: "component", type: i2.SmzTabPanelsComponent, selector: "ui-tab-panels" }, { kind: "component", type: i2.SmzTabPanelComponent, selector: "ui-tab-panel", inputs: ["value"] }, { kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: SafeHtmlPipe$1, name: "safeHtml" }] });
|
|
48039
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: i2.SmzTabsComponent, selector: "ui-tabs", inputs: ["value", "lazy", "scrollable"], outputs: ["valueChange"] }, { kind: "component", type: i2.SmzTabListComponent, selector: "ui-tab-list" }, { kind: "component", type: i2.SmzTabComponent, selector: "ui-tab", inputs: ["value", "disabled"] }, { kind: "component", type: i2.SmzTabPanelsComponent, selector: "ui-tab-panels" }, { kind: "component", type: i2.SmzTabPanelComponent, selector: "ui-tab-panel", inputs: ["value"] }, { kind: "component", type: SmzTableComponent, selector: "smz-ui-table", inputs: ["state", "items", "loading"], outputs: ["selectionChange", "validChange", "filterChange", "columnVisibilityChange", "create", "update", "delete"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "pipe", type: SafeHtmlPipe$1, name: "safeHtml" }] });
|
|
47986
48040
|
}
|
|
47987
48041
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.1", ngImport: i0, type: SmzMultiTablesComponent, decorators: [{
|
|
47988
48042
|
type: Component,
|
|
@@ -48923,9 +48977,9 @@ class SmzClipboardService {
|
|
|
48923
48977
|
title: 'Area de transferência',
|
|
48924
48978
|
features: [{ type: 'message', data: 'Mensagem copiada com sucesso.' }],
|
|
48925
48979
|
dialogTemplate: {
|
|
48926
|
-
extraSmall: { row:
|
|
48927
|
-
large: { row:
|
|
48928
|
-
extraLarge: { row:
|
|
48980
|
+
extraSmall: { row: 10 },
|
|
48981
|
+
large: { row: 4 },
|
|
48982
|
+
extraLarge: { row: 3 },
|
|
48929
48983
|
}
|
|
48930
48984
|
});
|
|
48931
48985
|
}
|
|
@@ -49143,9 +49197,9 @@ class ServerImageToBase64Directive {
|
|
|
49143
49197
|
.if(this.openMaximized)
|
|
49144
49198
|
.openMaximized()
|
|
49145
49199
|
.endIf
|
|
49146
|
-
.setLayout('EXTRA_LARGE',
|
|
49147
|
-
.setLayout('LARGE',
|
|
49148
|
-
.setLayout('MEDIUM',
|
|
49200
|
+
.setLayout('EXTRA_LARGE', 8)
|
|
49201
|
+
.setLayout('LARGE', 10)
|
|
49202
|
+
.setLayout('MEDIUM', 12)
|
|
49149
49203
|
.html([`<img src="${this.currentSrc}" class="w-full">`])
|
|
49150
49204
|
.hideFooter()
|
|
49151
49205
|
.build());
|
|
@@ -51094,11 +51148,11 @@ const defaultDialogsModuleConfig = {
|
|
|
51094
51148
|
saveDependsOnValidation: true
|
|
51095
51149
|
},
|
|
51096
51150
|
featureTemplate: {
|
|
51097
|
-
extraSmall: { row:
|
|
51151
|
+
extraSmall: { row: 12 }
|
|
51098
51152
|
},
|
|
51099
51153
|
dialogTemplate: {
|
|
51100
|
-
extraSmall: { row:
|
|
51101
|
-
large: { row:
|
|
51154
|
+
extraSmall: { row: 12 },
|
|
51155
|
+
large: { row: 6 },
|
|
51102
51156
|
}
|
|
51103
51157
|
},
|
|
51104
51158
|
forms: defaultFormsModuleConfig,
|