@dev-tcloud/tcloud-ui 7.9.0 → 8.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/docs/tcloud-ui-el-copy.md +2 -2
- package/docs/tcloud-ui-tc-btn.md +12 -1
- package/fesm2022/dev-tcloud-tcloud-ui.mjs +36 -1949
- package/fesm2022/dev-tcloud-tcloud-ui.mjs.map +1 -1
- package/js/tcloud-ui-app.js +74 -71
- package/package.json +1 -1
- package/scss/tcloud-ui/styles/_claus-btn.scss +21 -0
- package/scss/tcloud-ui/styles/_colors.scss +11 -0
- package/types/dev-tcloud-tcloud-ui.d.ts +48 -703
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Injectable, Component, EventEmitter, Input, Output, InjectionToken, Optional, Inject, inject, signal, Pipe, forwardRef, ViewChild, input, effect, Directive, ViewEncapsulation, HostListener, HostBinding, SkipSelf, ChangeDetectionStrategy, ChangeDetectorRef, computed, ApplicationRef, output, model, numberAttribute, booleanAttribute, ContentChildren, viewChild, EnvironmentInjector, createComponent, ViewContainerRef, NgModule, makeEnvironmentProviders
|
|
2
|
+
import { Injectable, Component, EventEmitter, Input, Output, InjectionToken, Optional, Inject, inject, signal, Pipe, forwardRef, ViewChild, input, effect, Directive, ViewEncapsulation, HostListener, HostBinding, SkipSelf, ChangeDetectionStrategy, ChangeDetectorRef, computed, ApplicationRef, output, model, numberAttribute, booleanAttribute, ContentChildren, viewChild, EnvironmentInjector, createComponent, ViewContainerRef, NgModule, makeEnvironmentProviders } from '@angular/core';
|
|
3
3
|
import * as i1$1 from '@angular/common';
|
|
4
4
|
import { DatePipe, CommonModule } from '@angular/common';
|
|
5
5
|
import { Subject, Subscription, BehaviorSubject, firstValueFrom, debounceTime, distinctUntilChanged, map, catchError, switchMap, throwError } from 'rxjs';
|
|
6
6
|
import * as i1 from '@angular/forms';
|
|
7
|
-
import { NG_VALUE_ACCESSOR, FormsModule, FormControl, ReactiveFormsModule, NG_VALIDATORS, Validators
|
|
7
|
+
import { NG_VALUE_ACCESSOR, FormsModule, FormControl, ReactiveFormsModule, NG_VALIDATORS, Validators } from '@angular/forms';
|
|
8
8
|
import * as i1$2 from '@angular/router';
|
|
9
9
|
import { Router, RouterModule } from '@angular/router';
|
|
10
10
|
import * as i1$3 from '@angular/common/http';
|
|
@@ -6006,14 +6006,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
6006
6006
|
type: Input
|
|
6007
6007
|
}] } });
|
|
6008
6008
|
|
|
6009
|
-
var ProgressStatusBarGradientStatus
|
|
6009
|
+
var ProgressStatusBarGradientStatus;
|
|
6010
6010
|
(function (ProgressStatusBarGradientStatus) {
|
|
6011
6011
|
ProgressStatusBarGradientStatus["info"] = "info";
|
|
6012
6012
|
ProgressStatusBarGradientStatus["danger"] = "danger";
|
|
6013
6013
|
ProgressStatusBarGradientStatus["success"] = "success";
|
|
6014
6014
|
ProgressStatusBarGradientStatus["alert"] = "alert";
|
|
6015
|
-
})(ProgressStatusBarGradientStatus
|
|
6016
|
-
var ProgressStatusBarRangeColor
|
|
6015
|
+
})(ProgressStatusBarGradientStatus || (ProgressStatusBarGradientStatus = {}));
|
|
6016
|
+
var ProgressStatusBarRangeColor;
|
|
6017
6017
|
(function (ProgressStatusBarRangeColor) {
|
|
6018
6018
|
ProgressStatusBarRangeColor["dangerStart"] = "#F48E85";
|
|
6019
6019
|
ProgressStatusBarRangeColor["dangerEnd"] = "#DC3545";
|
|
@@ -6023,7 +6023,7 @@ var ProgressStatusBarRangeColor$1;
|
|
|
6023
6023
|
ProgressStatusBarRangeColor["infoEnd"] = "#0897E9";
|
|
6024
6024
|
ProgressStatusBarRangeColor["successStart"] = "#A3E78C";
|
|
6025
6025
|
ProgressStatusBarRangeColor["successEnd"] = "#47B13D";
|
|
6026
|
-
})(ProgressStatusBarRangeColor
|
|
6026
|
+
})(ProgressStatusBarRangeColor || (ProgressStatusBarRangeColor = {}));
|
|
6027
6027
|
class TCloudUiProgressStatusBarComponent {
|
|
6028
6028
|
constructor() {
|
|
6029
6029
|
this.currentValue = input.required(...(ngDevMode ? [{ debugName: "currentValue" }] : /* istanbul ignore next */ []));
|
|
@@ -6051,14 +6051,14 @@ class TCloudUiProgressStatusBarComponent {
|
|
|
6051
6051
|
}
|
|
6052
6052
|
getProgressStatusBarRangeColor(_gradientStatus, position) {
|
|
6053
6053
|
switch (_gradientStatus) {
|
|
6054
|
-
case ProgressStatusBarGradientStatus
|
|
6055
|
-
return position === 'start' ? ProgressStatusBarRangeColor
|
|
6056
|
-
case ProgressStatusBarGradientStatus
|
|
6057
|
-
return position === 'start' ? ProgressStatusBarRangeColor
|
|
6058
|
-
case ProgressStatusBarGradientStatus
|
|
6059
|
-
return position === 'start' ? ProgressStatusBarRangeColor
|
|
6054
|
+
case ProgressStatusBarGradientStatus.alert:
|
|
6055
|
+
return position === 'start' ? ProgressStatusBarRangeColor.alertStart : ProgressStatusBarRangeColor.alertEnd;
|
|
6056
|
+
case ProgressStatusBarGradientStatus.danger:
|
|
6057
|
+
return position === 'start' ? ProgressStatusBarRangeColor.dangerStart : ProgressStatusBarRangeColor.dangerEnd;
|
|
6058
|
+
case ProgressStatusBarGradientStatus.success:
|
|
6059
|
+
return position === 'start' ? ProgressStatusBarRangeColor.successStart : ProgressStatusBarRangeColor.successEnd;
|
|
6060
6060
|
default:
|
|
6061
|
-
return position === 'start' ? ProgressStatusBarRangeColor
|
|
6061
|
+
return position === 'start' ? ProgressStatusBarRangeColor.infoStart : ProgressStatusBarRangeColor.infoEnd;
|
|
6062
6062
|
}
|
|
6063
6063
|
}
|
|
6064
6064
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TCloudUiProgressStatusBarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
@@ -8810,53 +8810,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
8810
8810
|
args: [{ selector: 'tcloud-ui-card-title', imports: [], template: "<div class=\"tcloud-ui-card-title c-neutral-700\">\n <span class=\"tcloud-ui-card-title__icon w-40 h-40 f-size-18 bg-c-neutral-200 bor-rad-rounded\">\n <ng-content select=\"[icon]\"></ng-content>\n </span>\n\n <h2 class=\"tcloud-ui-card-title__text f-h2 f-weight-700 mar-none\">{{title()}}</h2>\n\n <ng-content></ng-content>\n</div>\n", styles: [":host{display:block}.tcloud-ui-card-title{align-items:center;display:flex;gap:var(--size-8);height:var(--size-40);max-height:var(--size-40);min-height:var(--size-40)}.tcloud-ui-card-title__icon{align-content:center;text-align:center;max-width:var(--size-40);min-width:var(--size-40);max-height:var(--size-40);min-height:var(--size-40)}.tcloud-ui-card-title__text{cursor:default}@media(max-width:480px){.tcloud-ui-card-title{max-height:var(--size-32);min-height:var(--size-32)}.tcloud-ui-card-title__icon{max-width:var(--size-32);min-width:var(--size-32);max-height:var(--size-32);min-height:var(--size-32);font-size:var(--f-size-16)}.tcloud-ui-card-title__text{font-size:var(--f-size-16);line-height:var(--l-height-16);font-weight:var(--f-weight-600);text-transform:inherit;display:-webkit-box;-webkit-box-orient:vertical;overflow:hidden;line-clamp:2;-webkit-line-clamp:2}}\n"] }]
|
|
8811
8811
|
}], propDecorators: { title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: true }] }] } });
|
|
8812
8812
|
|
|
8813
|
-
class TcRevButtonDirective {
|
|
8814
|
-
constructor(_el) {
|
|
8815
|
-
this._el = _el;
|
|
8816
|
-
this.color = input('primary', ...(ngDevMode ? [{ debugName: "color" }] : /* istanbul ignore next */ []));
|
|
8817
|
-
this.size = input('sm', ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
8818
|
-
this.fullWidth = input(false, ...(ngDevMode ? [{ debugName: "fullWidth" }] : /* istanbul ignore next */ []));
|
|
8819
|
-
this.tcRevButton = input('filled', ...(ngDevMode ? [{ debugName: "tcRevButton" }] : /* istanbul ignore next */ []));
|
|
8820
|
-
effect(() => {
|
|
8821
|
-
this.setClasses();
|
|
8822
|
-
});
|
|
8823
|
-
}
|
|
8824
|
-
setClasses() {
|
|
8825
|
-
const tokenList = this._el.nativeElement.classList;
|
|
8826
|
-
tokenList.remove(...Array.from(tokenList).filter((c) => c.startsWith('tc-rev-btn--')));
|
|
8827
|
-
let tcRevButton = this.tcRevButton();
|
|
8828
|
-
if (!tcRevButton) {
|
|
8829
|
-
tcRevButton = 'filled';
|
|
8830
|
-
}
|
|
8831
|
-
this.fullWidth() ? this._el.nativeElement.classList.add('tc-rev-btn--full-width') : null;
|
|
8832
|
-
this._el.nativeElement.classList.add(`tc-rev-btn--${this.size()}`);
|
|
8833
|
-
this._el.nativeElement.classList.add(`tc-rev-btn--${this.color()}-${tcRevButton}`);
|
|
8834
|
-
}
|
|
8835
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevButtonDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
8836
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.17", type: TcRevButtonDirective, isStandalone: true, selector: "button[tcRevButton]", inputs: { color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, fullWidth: { classPropertyName: "fullWidth", publicName: "fullWidth", isSignal: true, isRequired: false, transformFunction: null }, tcRevButton: { classPropertyName: "tcRevButton", publicName: "tcRevButton", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "tc-rev-btn" }, ngImport: i0 }); }
|
|
8837
|
-
}
|
|
8838
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevButtonDirective, decorators: [{
|
|
8839
|
-
type: Directive,
|
|
8840
|
-
args: [{
|
|
8841
|
-
selector: 'button[tcRevButton]',
|
|
8842
|
-
host: {
|
|
8843
|
-
class: 'tc-rev-btn'
|
|
8844
|
-
}
|
|
8845
|
-
}]
|
|
8846
|
-
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], fullWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "fullWidth", required: false }] }], tcRevButton: [{ type: i0.Input, args: [{ isSignal: true, alias: "tcRevButton", required: false }] }] } });
|
|
8847
|
-
|
|
8848
|
-
class TcRevCardTitleComponent {
|
|
8849
|
-
constructor() {
|
|
8850
|
-
this.title = input.required(...(ngDevMode ? [{ debugName: "title" }] : /* istanbul ignore next */ []));
|
|
8851
|
-
}
|
|
8852
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevCardTitleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
8853
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.17", type: TcRevCardTitleComponent, isStandalone: true, selector: "tc-rev-card-title", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: true, transformFunction: null } }, ngImport: i0, template: "<div class=\"tc-rev-card-title c-neutral-700\">\n <span class=\"tc-rev-card-title__icon w-40 h-40 f-size-18 bg-c-neutral-200 bor-rad-rounded\">\n <ng-content select=\"[icon]\"></ng-content>\n </span>\n\n <h2 class=\"tc-rev-card-title__text f-h2 f-weight-700 mar-none\">{{title()}}</h2>\n\n <ng-content></ng-content>\n</div>\n", styles: [":host{display:block}.tc-rev-card-title{align-items:center;display:flex;gap:var(--size-8);height:var(--size-40);max-height:var(--size-40);min-height:var(--size-40)}.tc-rev-card-title__icon{align-content:center;text-align:center;max-width:var(--size-40);min-width:var(--size-40);max-height:var(--size-40);min-height:var(--size-40)}.tc-rev-card-title__text{cursor:default}@media(max-width:480px){.tc-rev-card-title{max-height:var(--size-32);min-height:var(--size-32)}.tc-rev-card-title__icon{max-width:var(--size-32);min-width:var(--size-32);max-height:var(--size-32);min-height:var(--size-32);font-size:var(--f-size-16)}.tc-rev-card-title__text{font-size:var(--f-size-16);line-height:var(--l-height-16);font-weight:var(--f-weight-600);text-transform:inherit;display:-webkit-box;-webkit-box-orient:vertical;overflow:hidden;-webkit-line-clamp:2}}\n"] }); }
|
|
8854
|
-
}
|
|
8855
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevCardTitleComponent, decorators: [{
|
|
8856
|
-
type: Component,
|
|
8857
|
-
args: [{ selector: 'tc-rev-card-title', imports: [], template: "<div class=\"tc-rev-card-title c-neutral-700\">\n <span class=\"tc-rev-card-title__icon w-40 h-40 f-size-18 bg-c-neutral-200 bor-rad-rounded\">\n <ng-content select=\"[icon]\"></ng-content>\n </span>\n\n <h2 class=\"tc-rev-card-title__text f-h2 f-weight-700 mar-none\">{{title()}}</h2>\n\n <ng-content></ng-content>\n</div>\n", styles: [":host{display:block}.tc-rev-card-title{align-items:center;display:flex;gap:var(--size-8);height:var(--size-40);max-height:var(--size-40);min-height:var(--size-40)}.tc-rev-card-title__icon{align-content:center;text-align:center;max-width:var(--size-40);min-width:var(--size-40);max-height:var(--size-40);min-height:var(--size-40)}.tc-rev-card-title__text{cursor:default}@media(max-width:480px){.tc-rev-card-title{max-height:var(--size-32);min-height:var(--size-32)}.tc-rev-card-title__icon{max-width:var(--size-32);min-width:var(--size-32);max-height:var(--size-32);min-height:var(--size-32);font-size:var(--f-size-16)}.tc-rev-card-title__text{font-size:var(--f-size-16);line-height:var(--l-height-16);font-weight:var(--f-weight-600);text-transform:inherit;display:-webkit-box;-webkit-box-orient:vertical;overflow:hidden;-webkit-line-clamp:2}}\n"] }]
|
|
8858
|
-
}], propDecorators: { title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: true }] }] } });
|
|
8859
|
-
|
|
8860
8813
|
class TCloudUiCardAccordionComponent {
|
|
8861
8814
|
constructor() {
|
|
8862
8815
|
this._viewPort = inject(TCloudUiDeviceUtilsService);
|
|
@@ -8884,11 +8837,11 @@ class TCloudUiCardAccordionComponent {
|
|
|
8884
8837
|
return ['pad-14'];
|
|
8885
8838
|
}
|
|
8886
8839
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TCloudUiCardAccordionComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
8887
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TCloudUiCardAccordionComponent, isStandalone: true, selector: "tcloud-ui-card-accordion", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, iconClass: { classPropertyName: "iconClass", publicName: "iconClass", isSignal: true, isRequired: false, transformFunction: null }, showMoreText: { classPropertyName: "showMoreText", publicName: "showMoreText", isSignal: true, isRequired: false, transformFunction: null }, showLessText: { classPropertyName: "showLessText", publicName: "showLessText", isSignal: true, isRequired: false, transformFunction: null }, badge: { classPropertyName: "badge", publicName: "badge", isSignal: true, isRequired: false, transformFunction: null }, isOpen: { classPropertyName: "isOpen", publicName: "isOpen", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { toggle: "toggle", isOpen: "isOpenChange" }, ngImport: i0, template: "<div class=\"tcloud-ui-card-accordion tcloud-ui-card bg-c-neutral-50 bor-xs bor-rad-16\"\n [ngClass]=\"accordionExtraClasses\"\n >\n <
|
|
8840
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TCloudUiCardAccordionComponent, isStandalone: true, selector: "tcloud-ui-card-accordion", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, iconClass: { classPropertyName: "iconClass", publicName: "iconClass", isSignal: true, isRequired: false, transformFunction: null }, showMoreText: { classPropertyName: "showMoreText", publicName: "showMoreText", isSignal: true, isRequired: false, transformFunction: null }, showLessText: { classPropertyName: "showLessText", publicName: "showLessText", isSignal: true, isRequired: false, transformFunction: null }, badge: { classPropertyName: "badge", publicName: "badge", isSignal: true, isRequired: false, transformFunction: null }, isOpen: { classPropertyName: "isOpen", publicName: "isOpen", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { toggle: "toggle", isOpen: "isOpenChange" }, ngImport: i0, template: "<div class=\"tcloud-ui-card-accordion tcloud-ui-card bg-c-neutral-50 bor-xs bor-rad-16\"\n [ngClass]=\"accordionExtraClasses\"\n >\n <tcloud-ui-card-title [title]=\"title()\" [class]=\"isOpen() ? 'pad-b-16' : '' \">\n <i [class]=\"iconClass()\" icon></i>\n\n @if (badge()) {\n <div\n class=\"f-size-12 f-weight-600 pad-x-4 pad-y-2 bor-xs bor-rad-xs\"\n [ngClass]=\"badge()?.class\"\n [class.mar-l-8]=\"isDesktop()\"\n >\n {{ badge()?.text }}\n </div>\n }\n\n @if(isDesktop()){\n <button tcloudButton=\"outline\" color=\"dark\" size=\"sm\" class=\"mar-l-a\" (click)=\"toggleAccordion()\">\n {{ isOpen() ? showLessText() : showMoreText() }}\n <i class=\"fa-light\" [ngClass]=\"isOpen() ? 'fa-chevron-up' : 'fa-chevron-down'\"></i>\n </button>\n }\n\n @if(!isDesktop()){\n <button tcloudButton=\"link\" color=\"dark\" size=\"md\" (click)=\"toggleAccordion()\" class=\"tcloud-ui-card-accordion__arrow-mobile mar-l-a\">\n <i class=\"fa-light\" [ngClass]=\"isOpen() ? 'fa-chevron-up' : 'fa-chevron-down'\"></i>\n </button>\n }\n\n </tcloud-ui-card-title>\n @if (isOpen()) {\n <ng-content></ng-content>\n }\n</div>\n", styles: [":host{display:block}.tcloud-ui-card-accordion{border-color:var(--c-neutral-400)}@media(max-width:480px){.tcloud-ui-card-accordion__arrow-mobile{font-size:var(--f-size-16);padding:0 var(--size-6)}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: TCloudUiCardTitleComponent, selector: "tcloud-ui-card-title", inputs: ["title"] }, { kind: "directive", type: TCloudUiButtonDirective, selector: "[tcloudButton]", inputs: ["color", "size", "fullWidth", "tcloudButton"] }] }); }
|
|
8888
8841
|
}
|
|
8889
8842
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TCloudUiCardAccordionComponent, decorators: [{
|
|
8890
8843
|
type: Component,
|
|
8891
|
-
args: [{ selector: 'tcloud-ui-card-accordion', imports: [CommonModule,
|
|
8844
|
+
args: [{ selector: 'tcloud-ui-card-accordion', imports: [CommonModule, TCloudUiCardTitleComponent, TCloudUiButtonDirective], template: "<div class=\"tcloud-ui-card-accordion tcloud-ui-card bg-c-neutral-50 bor-xs bor-rad-16\"\n [ngClass]=\"accordionExtraClasses\"\n >\n <tcloud-ui-card-title [title]=\"title()\" [class]=\"isOpen() ? 'pad-b-16' : '' \">\n <i [class]=\"iconClass()\" icon></i>\n\n @if (badge()) {\n <div\n class=\"f-size-12 f-weight-600 pad-x-4 pad-y-2 bor-xs bor-rad-xs\"\n [ngClass]=\"badge()?.class\"\n [class.mar-l-8]=\"isDesktop()\"\n >\n {{ badge()?.text }}\n </div>\n }\n\n @if(isDesktop()){\n <button tcloudButton=\"outline\" color=\"dark\" size=\"sm\" class=\"mar-l-a\" (click)=\"toggleAccordion()\">\n {{ isOpen() ? showLessText() : showMoreText() }}\n <i class=\"fa-light\" [ngClass]=\"isOpen() ? 'fa-chevron-up' : 'fa-chevron-down'\"></i>\n </button>\n }\n\n @if(!isDesktop()){\n <button tcloudButton=\"link\" color=\"dark\" size=\"md\" (click)=\"toggleAccordion()\" class=\"tcloud-ui-card-accordion__arrow-mobile mar-l-a\">\n <i class=\"fa-light\" [ngClass]=\"isOpen() ? 'fa-chevron-up' : 'fa-chevron-down'\"></i>\n </button>\n }\n\n </tcloud-ui-card-title>\n @if (isOpen()) {\n <ng-content></ng-content>\n }\n</div>\n", styles: [":host{display:block}.tcloud-ui-card-accordion{border-color:var(--c-neutral-400)}@media(max-width:480px){.tcloud-ui-card-accordion__arrow-mobile{font-size:var(--f-size-16);padding:0 var(--size-6)}}\n"] }]
|
|
8892
8845
|
}], propDecorators: { toggle: [{ type: i0.Output, args: ["toggle"] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], iconClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconClass", required: false }] }], showMoreText: [{ type: i0.Input, args: [{ isSignal: true, alias: "showMoreText", required: false }] }], showLessText: [{ type: i0.Input, args: [{ isSignal: true, alias: "showLessText", required: false }] }], badge: [{ type: i0.Input, args: [{ isSignal: true, alias: "badge", required: false }] }], isOpen: [{ type: i0.Input, args: [{ isSignal: true, alias: "isOpen", required: false }] }, { type: i0.Output, args: ["isOpenChange"] }] } });
|
|
8893
8846
|
|
|
8894
8847
|
class TCloudUiCalendarComponent {
|
|
@@ -9490,144 +9443,12 @@ function isTextEllipsed(text, containerWidth) {
|
|
|
9490
9443
|
// }
|
|
9491
9444
|
// }
|
|
9492
9445
|
|
|
9493
|
-
|
|
9494
|
-
constructor(_el, _renderer, _vcr) {
|
|
9495
|
-
this._el = _el;
|
|
9496
|
-
this._renderer = _renderer;
|
|
9497
|
-
this._vcr = _vcr;
|
|
9498
|
-
this.tcRevTooltip = input('', ...(ngDevMode ? [{ debugName: "tcRevTooltip" }] : /* istanbul ignore next */ []));
|
|
9499
|
-
this.position = input('top', ...(ngDevMode ? [{ debugName: "position" }] : /* istanbul ignore next */ []));
|
|
9500
|
-
this.tooltipElement = null;
|
|
9501
|
-
}
|
|
9502
|
-
onMouseEnter() {
|
|
9503
|
-
const tooltipText = this.tcRevTooltip();
|
|
9504
|
-
if (this.isValidTooltipText(tooltipText)) {
|
|
9505
|
-
this.showTooltip(tooltipText);
|
|
9506
|
-
}
|
|
9507
|
-
}
|
|
9508
|
-
onMouseLeave() {
|
|
9509
|
-
this.hideTooltip();
|
|
9510
|
-
}
|
|
9511
|
-
isValidTooltipText(text) {
|
|
9512
|
-
return text && text.trim().length > 0;
|
|
9513
|
-
}
|
|
9514
|
-
showTooltip(text) {
|
|
9515
|
-
if (this.tooltipElement) {
|
|
9516
|
-
this.hideTooltip();
|
|
9517
|
-
}
|
|
9518
|
-
// Create tooltip element
|
|
9519
|
-
this.tooltipElement = this._renderer.createElement('div');
|
|
9520
|
-
// Add text content
|
|
9521
|
-
const textNode = this._renderer.createText(text);
|
|
9522
|
-
this._renderer.appendChild(this.tooltipElement, textNode);
|
|
9523
|
-
// Add CSS classes
|
|
9524
|
-
this._renderer.addClass(this.tooltipElement, 'tc-rev-tooltip');
|
|
9525
|
-
this._renderer.addClass(this.tooltipElement, `tc-rev-tooltip--${this.position()}`);
|
|
9526
|
-
// Set initial styles
|
|
9527
|
-
this._renderer.setStyle(this.tooltipElement, 'position', 'absolute');
|
|
9528
|
-
this._renderer.setStyle(this.tooltipElement, 'z-index', '9999');
|
|
9529
|
-
this._renderer.setStyle(this.tooltipElement, 'visibility', 'hidden');
|
|
9530
|
-
// this._renderer.setStyle(this.tooltipElement, 'opacity', '0');
|
|
9531
|
-
// Append to body
|
|
9532
|
-
this._renderer.appendChild(document.body, this.tooltipElement);
|
|
9533
|
-
// Position tooltip
|
|
9534
|
-
this.positionTooltip();
|
|
9535
|
-
// Show tooltip with animation
|
|
9536
|
-
this._renderer.setStyle(this.tooltipElement, 'visibility', 'visible');
|
|
9537
|
-
this._renderer.addClass(this.tooltipElement, 'tc-rev-tooltip--visible');
|
|
9538
|
-
}
|
|
9539
|
-
hideTooltip() {
|
|
9540
|
-
if (this.tooltipElement) {
|
|
9541
|
-
this._renderer.removeChild(document.body, this.tooltipElement);
|
|
9542
|
-
this.tooltipElement = null;
|
|
9543
|
-
}
|
|
9544
|
-
}
|
|
9545
|
-
positionTooltip() {
|
|
9546
|
-
if (!this.tooltipElement)
|
|
9547
|
-
return;
|
|
9548
|
-
const hostRect = this._el.nativeElement.getBoundingClientRect();
|
|
9549
|
-
const tooltipRect = this.tooltipElement.getBoundingClientRect();
|
|
9550
|
-
const position = this.position();
|
|
9551
|
-
let top = 0;
|
|
9552
|
-
let left = 0;
|
|
9553
|
-
switch (position) {
|
|
9554
|
-
case 'top':
|
|
9555
|
-
top = hostRect.top + window.scrollY - tooltipRect.height - 8;
|
|
9556
|
-
left = hostRect.left + window.scrollX + (hostRect.width - tooltipRect.width) / 2;
|
|
9557
|
-
break;
|
|
9558
|
-
case 'bottom':
|
|
9559
|
-
top = hostRect.bottom + window.scrollY + 8;
|
|
9560
|
-
left = hostRect.left + window.scrollX + (hostRect.width - tooltipRect.width) / 2;
|
|
9561
|
-
break;
|
|
9562
|
-
case 'left':
|
|
9563
|
-
top = hostRect.top + window.scrollY + (hostRect.height - tooltipRect.height) / 2;
|
|
9564
|
-
left = hostRect.left + window.scrollX - tooltipRect.width - 8;
|
|
9565
|
-
break;
|
|
9566
|
-
case 'right':
|
|
9567
|
-
top = hostRect.top + window.scrollY + (hostRect.height - tooltipRect.height) / 2;
|
|
9568
|
-
left = hostRect.right + window.scrollX + 8;
|
|
9569
|
-
break;
|
|
9570
|
-
}
|
|
9571
|
-
this._renderer.setStyle(this.tooltipElement, 'top', `${top}px`);
|
|
9572
|
-
this._renderer.setStyle(this.tooltipElement, 'left', `${left}px`);
|
|
9573
|
-
}
|
|
9574
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevTooltipDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
9575
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.17", type: TcRevTooltipDirective, isStandalone: true, selector: "[tcRevTooltip]", inputs: { tcRevTooltip: { classPropertyName: "tcRevTooltip", publicName: "tcRevTooltip", isSignal: true, isRequired: false, transformFunction: null }, position: { classPropertyName: "position", publicName: "position", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "mouseenter": "onMouseEnter()", "mouseleave": "onMouseLeave()" } }, ngImport: i0 }); }
|
|
9576
|
-
}
|
|
9577
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevTooltipDirective, decorators: [{
|
|
9578
|
-
type: Directive,
|
|
9579
|
-
args: [{
|
|
9580
|
-
selector: '[tcRevTooltip]',
|
|
9581
|
-
standalone: true
|
|
9582
|
-
}]
|
|
9583
|
-
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.Renderer2 }, { type: i0.ViewContainerRef }], propDecorators: { tcRevTooltip: [{ type: i0.Input, args: [{ isSignal: true, alias: "tcRevTooltip", required: false }] }], position: [{ type: i0.Input, args: [{ isSignal: true, alias: "position", required: false }] }], onMouseEnter: [{
|
|
9584
|
-
type: HostListener,
|
|
9585
|
-
args: ['mouseenter']
|
|
9586
|
-
}], onMouseLeave: [{
|
|
9587
|
-
type: HostListener,
|
|
9588
|
-
args: ['mouseleave']
|
|
9589
|
-
}] } });
|
|
9590
|
-
|
|
9591
|
-
class TcRevIconButtonDirective {
|
|
9592
|
-
constructor(_el) {
|
|
9593
|
-
this._el = _el;
|
|
9594
|
-
this.color = input('primary', ...(ngDevMode ? [{ debugName: "color" }] : /* istanbul ignore next */ []));
|
|
9595
|
-
this.size = input('sm', ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
9596
|
-
this.tcRevIconButton = input('filled', ...(ngDevMode ? [{ debugName: "tcRevIconButton" }] : /* istanbul ignore next */ []));
|
|
9597
|
-
effect(() => {
|
|
9598
|
-
this.setClasses();
|
|
9599
|
-
});
|
|
9600
|
-
}
|
|
9601
|
-
setClasses() {
|
|
9602
|
-
const tokenList = this._el.nativeElement.classList;
|
|
9603
|
-
tokenList.remove(...Array.from(tokenList).filter((c) => c.startsWith('tc-rev-btn--')));
|
|
9604
|
-
let tcRevIconButton = this.tcRevIconButton();
|
|
9605
|
-
if (!tcRevIconButton) {
|
|
9606
|
-
tcRevIconButton = 'filled';
|
|
9607
|
-
}
|
|
9608
|
-
this._el.nativeElement.classList.add(`tc-rev-btn--${this.size()}`);
|
|
9609
|
-
this._el.nativeElement.classList.add(`tc-rev-btn--${this.size()}-icon`);
|
|
9610
|
-
this._el.nativeElement.classList.add(`tc-rev-btn--${this.color()}-${tcRevIconButton}`);
|
|
9611
|
-
}
|
|
9612
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevIconButtonDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
9613
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.17", type: TcRevIconButtonDirective, isStandalone: true, selector: "button[tcRevIconButton]", inputs: { color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, tcRevIconButton: { classPropertyName: "tcRevIconButton", publicName: "tcRevIconButton", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "tc-rev-btn tc-rev-btn-icon" }, ngImport: i0 }); }
|
|
9614
|
-
}
|
|
9615
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevIconButtonDirective, decorators: [{
|
|
9616
|
-
type: Directive,
|
|
9617
|
-
args: [{
|
|
9618
|
-
selector: 'button[tcRevIconButton]',
|
|
9619
|
-
host: {
|
|
9620
|
-
class: 'tc-rev-btn tc-rev-btn-icon'
|
|
9621
|
-
}
|
|
9622
|
-
}]
|
|
9623
|
-
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], tcRevIconButton: [{ type: i0.Input, args: [{ isSignal: true, alias: "tcRevIconButton", required: false }] }] } });
|
|
9624
|
-
|
|
9625
|
-
var DropdownSize$1;
|
|
9446
|
+
var DropdownSize;
|
|
9626
9447
|
(function (DropdownSize) {
|
|
9627
9448
|
DropdownSize["sm"] = "sm";
|
|
9628
9449
|
DropdownSize["md"] = "md";
|
|
9629
9450
|
DropdownSize["lg"] = "lg";
|
|
9630
|
-
})(DropdownSize
|
|
9451
|
+
})(DropdownSize || (DropdownSize = {}));
|
|
9631
9452
|
const noop = () => { };
|
|
9632
9453
|
const CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR = {
|
|
9633
9454
|
provide: NG_VALUE_ACCESSOR,
|
|
@@ -9649,14 +9470,14 @@ class TCloudUiDropdownComponent {
|
|
|
9649
9470
|
this.options = input.required(...(ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ [])); // Lista de opções no novo formato
|
|
9650
9471
|
this.initialValue = input(null, ...(ngDevMode ? [{ debugName: "initialValue" }] : /* istanbul ignore next */ [])); // Valor pré-selecionado (deprecated - use value instead)
|
|
9651
9472
|
this.value = model(null, ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ [])); // Two-way binding para o valor selecionado
|
|
9652
|
-
this.size = input(DropdownSize
|
|
9473
|
+
this.size = input(DropdownSize.sm, ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
9653
9474
|
this.width = input('', ...(ngDevMode ? [{ debugName: "width" }] : /* istanbul ignore next */ [])); // Largura específica do dropdown (ex: '300px', '50%'). Se não informado, ocupa 100% do pai
|
|
9654
9475
|
this.searchable = input(false, ...(ngDevMode ? [{ debugName: "searchable" }] : /* istanbul ignore next */ [])); // Habilita campo de busca
|
|
9655
9476
|
this.searchPlaceholder = input('Buscar...', ...(ngDevMode ? [{ debugName: "searchPlaceholder" }] : /* istanbul ignore next */ [])); // Placeholder do campo de busca
|
|
9656
9477
|
this.optionSelected = output(); // Emissor para o valor selecionado
|
|
9657
9478
|
this.selectedOption = signal(null, ...(ngDevMode ? [{ debugName: "selectedOption" }] : /* istanbul ignore next */ [])); // Opção selecionada
|
|
9658
9479
|
this.isOpen = false; // Controla se o dropdown está aberto
|
|
9659
|
-
this.dropdownSize = DropdownSize
|
|
9480
|
+
this.dropdownSize = DropdownSize;
|
|
9660
9481
|
this.isDesktop = this._deviceService.isDesktop;
|
|
9661
9482
|
this.isMobile = this._deviceService.isMobile;
|
|
9662
9483
|
this.searchText = signal('', ...(ngDevMode ? [{ debugName: "searchText" }] : /* istanbul ignore next */ [])); // Texto de busca
|
|
@@ -9791,16 +9612,15 @@ class TCloudUiDropdownComponent {
|
|
|
9791
9612
|
this._disabledByForm.set(isDisabled);
|
|
9792
9613
|
}
|
|
9793
9614
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TCloudUiDropdownComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
9794
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TCloudUiDropdownComponent, isStandalone: true, selector: "tcloud-ui-dropdown", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: true, transformFunction: null }, initialValue: { classPropertyName: "initialValue", publicName: "initialValue", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null }, searchable: { classPropertyName: "searchable", publicName: "searchable", isSignal: true, isRequired: false, transformFunction: null }, searchPlaceholder: { classPropertyName: "searchPlaceholder", publicName: "searchPlaceholder", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange", optionSelected: "optionSelected" }, host: { listeners: { "document:click": "onDocumentClick($event)" } }, providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR], viewQueries: [{ propertyName: "menuTemplate", first: true, predicate: ["menuTemplate"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div\n class=\"tcloud-ui-dropdown\"\n [class.disabled]=\"isDisabled()\"\n [style.width]=\"this.width()\"\n >\n <button\n class=\"tcloud-ui-dropdown-toggle\"\n [class.tcloud-ui-dropdown-toggle--sm]=\"this.size() === dropdownSize.sm\"\n [class.tcloud-ui-dropdown-toggle--md]=\"this.size() === dropdownSize.md\"\n [class.tcloud-ui-dropdown-toggle--lg]=\"this.size() === dropdownSize.lg\"\n (click)=\"toggleDropdown()\"\n [class.disabled]=\"isDisabled()\"\n [disabled]=\"isDisabled()\"\n >\n @if (label()) {\n <b [innerHTML]=\"label()\"></b>\n }\n <span class=\"tcloud-ui-dropdown-selected-text\">\n {{ selectedOption() ? selectedOption()?.displayValue : \"Selecione\" }}\n </span>\n <i class=\"fa-light fa-chevron-down mar-l-a\"></i>\n </button>\n @if (isOpen && isDesktop()) {\n <ul class=\"tcloud-ui-dropdown-menu\">\n <!-- Campo de busca -->\n @if (searchable()) {\n <li class=\"tcloud-ui-dropdown-search\">\n <div class=\"tcloud-ui-dropdown-search-container\">\n <input\n type=\"text\"\n class=\"tcloud-ui-dropdown-search-input\"\n [placeholder]=\"searchPlaceholder()\"\n [value]=\"searchText()\"\n (input)=\"onSearchChange($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n <i class=\"fa-light fa-magnifying-glass tcloud-ui-dropdown-search-icon\"></i>\n @if (searchText()) {\n <button\n type=\"button\"\n class=\"tcloud-ui-dropdown-search-clear\"\n (click)=\"clearSearch(); $event.stopPropagation()\"\n >\n <i class=\"fa-light fa-times\"></i>\n </button>\n }\n </div>\n </li>\n }\n @for (option of filteredOptions(); track option?.value) {\n <li class=\"tcloud-ui-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tcloud-ui-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n <span\n class=\"tcloud-ui-dropdown-option-text\"\n position=\"top\"\n >\n {{ option?.displayValue }}\n </span>\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check\"></i>\n }\n </button>\n </li>\n }\n <!-- Mensagem quando nenhum item for encontrado na busca -->\n @if (searchable() && searchText() && filteredOptions().length === 0) {\n <li class=\"tcloud-ui-dropdown-no-results\">\n <span>Nenhuma op\u00E7\u00E3o encontrada</span>\n </li>\n }\n </ul>\n }\n\n <!-- Dropdown full screen -->\n <ng-template #menuTemplate>\n <div class=\"tcloud-ui-dropdown-menu tcloud-ui-dropdown-menu--device\">\n <div class=\"tcloud-ui-dropdown-menu-section\">\n <div class=\"tcloud-ui-dropdown-menu-header pad-b-24\">\n <h3 class=\"mar-none f-h2 f-weight-600 c-neutral-600\">\n {{ label() }}\n </h3>\n <button\n tcRevIconButton=\"outline\"\n color=\"dark\"\n size=\"sm\"\n (click)=\"_deviceService.closeDropdownDevice()\"\n >\n <i class=\"fa-light fa-times f-size-16\"></i>\n </button>\n </div>\n <ul class=\"tcloud-ui-dropdown-menu-container mar-t-8\">\n <!-- Campo de busca mobile -->\n @if (searchable()) {\n <li class=\"tcloud-ui-dropdown-search tcloud-ui-dropdown-search--mobile\">\n <div class=\"tcloud-ui-dropdown-search-container\">\n <input\n type=\"text\"\n class=\"tcloud-ui-dropdown-search-input\"\n [placeholder]=\"searchPlaceholder()\"\n [value]=\"searchText()\"\n (input)=\"onSearchChange($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n <i class=\"fa-light fa-magnifying-glass tcloud-ui-dropdown-search-icon\"></i>\n @if (searchText()) {\n <button\n type=\"button\"\n class=\"tcloud-ui-dropdown-search-clear\"\n (click)=\"clearSearch(); $event.stopPropagation()\"\n >\n <i class=\"fa-light fa-times\"></i>\n </button>\n }\n </div>\n </li>\n }\n @for (option of filteredOptions(); track option?.value) {\n <li class=\"tcloud-ui-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tcloud-ui-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n {{ option?.displayValue }}\n\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check f-size-16\"></i>\n }\n </button>\n </li>\n }\n <!-- Mensagem quando nenhum item for encontrado na busca mobile -->\n @if (searchable() && searchText() && filteredOptions().length === 0) {\n <li class=\"tcloud-ui-dropdown-no-results tcloud-ui-dropdown-no-results--mobile\">\n <span>Nenhuma op\u00E7\u00E3o encontrada</span>\n </li>\n }\n </ul>\n </div>\n </div>\n </ng-template>\n </div>\n", styles: [".tcloud-ui-dropdown{position:relative;display:block;width:100%}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle{align-items:center;background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-400);border-radius:var(--bor-radius-pill);color:var(--c-neutral-700);cursor:pointer;display:inline-flex;font-family:var(--f-family);font-size:var(--f-size-12);gap:var(--size-8);line-height:var(--l-height-16);outline:none;transition:.2s ease;padding:0 var(--size-12) 0 var(--size-16);width:100%}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle .tcloud-ui-dropdown-selected-text{flex:1;overflow:hidden;text-align:left;text-overflow:ellipsis;white-space:nowrap}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle i{align-items:center;display:inline-flex;flex-shrink:0;height:var(--size-24);justify-content:center;line-height:1;width:var(--size-24)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle--sm{height:var(--size-40)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle--md{height:var(--size-44)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle--lg{height:var(--size-48)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle:hover,.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle:focus{border-color:var(--c-primary-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle:disabled{border-color:var(--c-neutral-300);color:var(--c-neutral-300);cursor:not-allowed}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu{box-shadow:var(--shadow-md);border:1px solid var(--c-neutral-300);position:absolute;top:110%;left:0;background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);list-style:none;margin:0;max-height:15.625rem;overflow-y:auto;padding:0;width:100%;z-index:1000}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-700);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-12);line-height:var(--l-height-16);height:var(--size-32);padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn .tcloud-ui-dropdown-option-text{flex:1;overflow:hidden;text-align:left;white-space:nowrap}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn .tcloud-ui-dropdown-option-text.ellipsed{text-overflow:ellipsis}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:hover{border-color:var(--c-primary-500);color:var(--c-primary-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search{position:sticky;top:0;background-color:var(--c-neutral-50);padding:var(--size-8);border-bottom:1px solid var(--c-neutral-200);z-index:1}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container{position:relative;display:flex;align-items:center}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input{width:100%;height:var(--size-32);padding:0 var(--size-36) 0 var(--size-32);border:1px solid var(--c-neutral-300);border-radius:var(--bor-radius-pill);font-size:var(--f-size-12);line-height:var(--l-height-16);color:var(--c-neutral-700);background-color:var(--c-neutral-50);outline:none;transition:border-color .2s ease}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input:focus{border-color:var(--c-primary-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input::placeholder{color:var(--c-neutral-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-icon{position:absolute;left:var(--size-8);color:var(--c-neutral-500);font-size:var(--f-size-12);line-height:1;pointer-events:none;top:50%;transform:translateY(-50%)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-clear{position:absolute;right:var(--size-8);background:none;border:none;color:var(--c-neutral-500);cursor:pointer;padding:var(--size-2);display:flex;align-items:center;height:var(--size-24);justify-content:center;line-height:1;transition:color .2s ease;top:50%;transform:translateY(-50%);width:var(--size-24)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-clear:hover{color:var(--c-neutral-700)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-no-results{padding:var(--size-12) var(--size-8);text-align:center;color:var(--c-neutral-500);font-size:var(--f-size-12);font-style:italic}.tcloud-ui-dropdown-menu--device{height:100%;overflow-y:auto;background-color:var(--c-neutral-50);padding:var(--size-16)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-section{display:contents}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-header{align-items:center;display:flex;gap:var(--size-16);justify-content:space-between}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-container{list-style:none;margin:0;padding:0;gap:.5rem;display:flex;flex-direction:column}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-14);line-height:var(--l-height-16);height:var(--size-40);padding:var(--size-12);text-align:left;text-wrap:nowrap;transition:all .2s ease;width:100%}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:active:not(:disabled):not(.selected){background-color:var(--c-primary-200);border-color:var(--c-primary-200);color:var(--c-primary-500);transform:scale(.98)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile{position:sticky;top:0;background-color:var(--c-neutral-50);padding:var(--size-12) 0;margin-bottom:var(--size-8);border-bottom:1px solid var(--c-neutral-200);z-index:1}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input{height:var(--size-40);font-size:var(--f-size-14);padding:var(--size-12) var(--size-40) var(--size-12) var(--size-16)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-icon{left:var(--size-12);font-size:var(--f-size-14)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-clear{right:var(--size-12);padding:var(--size-4)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-no-results--mobile{padding:var(--size-16) var(--size-12);font-size:var(--f-size-14);color:var(--c-neutral-600)}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: TcRevIconButtonDirective, selector: "button[tcRevIconButton]", inputs: ["color", "size", "tcRevIconButton"] }] }); }
|
|
9615
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TCloudUiDropdownComponent, isStandalone: true, selector: "tcloud-ui-dropdown", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: true, transformFunction: null }, initialValue: { classPropertyName: "initialValue", publicName: "initialValue", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null }, searchable: { classPropertyName: "searchable", publicName: "searchable", isSignal: true, isRequired: false, transformFunction: null }, searchPlaceholder: { classPropertyName: "searchPlaceholder", publicName: "searchPlaceholder", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange", optionSelected: "optionSelected" }, host: { listeners: { "document:click": "onDocumentClick($event)" } }, providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR], viewQueries: [{ propertyName: "menuTemplate", first: true, predicate: ["menuTemplate"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div\n class=\"tcloud-ui-dropdown\"\n [class.disabled]=\"isDisabled()\"\n [style.width]=\"this.width()\"\n >\n <button\n class=\"tcloud-ui-dropdown-toggle\"\n [class.tcloud-ui-dropdown-toggle--sm]=\"this.size() === dropdownSize.sm\"\n [class.tcloud-ui-dropdown-toggle--md]=\"this.size() === dropdownSize.md\"\n [class.tcloud-ui-dropdown-toggle--lg]=\"this.size() === dropdownSize.lg\"\n (click)=\"toggleDropdown()\"\n [class.disabled]=\"isDisabled()\"\n [disabled]=\"isDisabled()\"\n >\n @if (label()) {\n <b [innerHTML]=\"label()\"></b>\n }\n <span class=\"tcloud-ui-dropdown-selected-text\">\n {{ selectedOption() ? selectedOption()?.displayValue : \"Selecione\" }}\n </span>\n <i class=\"fa-light fa-chevron-down mar-l-a\"></i>\n </button>\n @if (isOpen && isDesktop()) {\n <ul class=\"tcloud-ui-dropdown-menu\">\n <!-- Campo de busca -->\n @if (searchable()) {\n <li class=\"tcloud-ui-dropdown-search\">\n <div class=\"tcloud-ui-dropdown-search-container\">\n <input\n type=\"text\"\n class=\"tcloud-ui-dropdown-search-input\"\n [placeholder]=\"searchPlaceholder()\"\n [value]=\"searchText()\"\n (input)=\"onSearchChange($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n <i class=\"fa-light fa-magnifying-glass tcloud-ui-dropdown-search-icon\"></i>\n @if (searchText()) {\n <button\n type=\"button\"\n class=\"tcloud-ui-dropdown-search-clear\"\n (click)=\"clearSearch(); $event.stopPropagation()\"\n >\n <i class=\"fa-light fa-times\"></i>\n </button>\n }\n </div>\n </li>\n }\n @for (option of filteredOptions(); track option?.value) {\n <li class=\"tcloud-ui-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tcloud-ui-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n <span\n class=\"tcloud-ui-dropdown-option-text\"\n position=\"top\"\n >\n {{ option?.displayValue }}\n </span>\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check\"></i>\n }\n </button>\n </li>\n }\n <!-- Mensagem quando nenhum item for encontrado na busca -->\n @if (searchable() && searchText() && filteredOptions().length === 0) {\n <li class=\"tcloud-ui-dropdown-no-results\">\n <span>Nenhuma op\u00E7\u00E3o encontrada</span>\n </li>\n }\n </ul>\n }\n\n <!-- Dropdown full screen -->\n <ng-template #menuTemplate>\n <div class=\"tcloud-ui-dropdown-menu tcloud-ui-dropdown-menu--device\">\n <div class=\"tcloud-ui-dropdown-menu-section\">\n <div class=\"tcloud-ui-dropdown-menu-header pad-b-24\">\n <h3 class=\"mar-none f-h2 f-weight-600 c-neutral-600\">\n {{ label() }}\n </h3>\n <button\n tcloudUiIconButton=\"outline\"\n color=\"dark\"\n size=\"sm\"\n (click)=\"_deviceService.closeDropdownDevice()\"\n >\n <i class=\"fa-light fa-times f-size-16\"></i>\n </button>\n </div>\n <ul class=\"tcloud-ui-dropdown-menu-container mar-t-8\">\n <!-- Campo de busca mobile -->\n @if (searchable()) {\n <li class=\"tcloud-ui-dropdown-search tcloud-ui-dropdown-search--mobile\">\n <div class=\"tcloud-ui-dropdown-search-container\">\n <input\n type=\"text\"\n class=\"tcloud-ui-dropdown-search-input\"\n [placeholder]=\"searchPlaceholder()\"\n [value]=\"searchText()\"\n (input)=\"onSearchChange($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n <i class=\"fa-light fa-magnifying-glass tcloud-ui-dropdown-search-icon\"></i>\n @if (searchText()) {\n <button\n type=\"button\"\n class=\"tcloud-ui-dropdown-search-clear\"\n (click)=\"clearSearch(); $event.stopPropagation()\"\n >\n <i class=\"fa-light fa-times\"></i>\n </button>\n }\n </div>\n </li>\n }\n @for (option of filteredOptions(); track option?.value) {\n <li class=\"tcloud-ui-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tcloud-ui-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n {{ option?.displayValue }}\n\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check f-size-16\"></i>\n }\n </button>\n </li>\n }\n <!-- Mensagem quando nenhum item for encontrado na busca mobile -->\n @if (searchable() && searchText() && filteredOptions().length === 0) {\n <li class=\"tcloud-ui-dropdown-no-results tcloud-ui-dropdown-no-results--mobile\">\n <span>Nenhuma op\u00E7\u00E3o encontrada</span>\n </li>\n }\n </ul>\n </div>\n </div>\n </ng-template>\n </div>\n", styles: [".tcloud-ui-dropdown{position:relative;display:block;width:100%}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle{align-items:center;background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-400);border-radius:var(--bor-radius-pill);color:var(--c-neutral-700);cursor:pointer;display:inline-flex;font-family:var(--f-family);font-size:var(--f-size-12);gap:var(--size-8);line-height:var(--l-height-16);outline:none;transition:.2s ease;padding:0 var(--size-12) 0 var(--size-16);width:100%}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle .tcloud-ui-dropdown-selected-text{flex:1;overflow:hidden;text-align:left;text-overflow:ellipsis;white-space:nowrap}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle i{align-items:center;display:inline-flex;flex-shrink:0;height:var(--size-24);justify-content:center;line-height:1;width:var(--size-24)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle--sm{height:var(--size-40)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle--md{height:var(--size-44)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle--lg{height:var(--size-48)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle:hover,.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle:focus{border-color:var(--c-primary-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle:disabled{border-color:var(--c-neutral-300);color:var(--c-neutral-300);cursor:not-allowed}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu{box-shadow:var(--shadow-md);border:1px solid var(--c-neutral-300);position:absolute;top:110%;left:0;background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);list-style:none;margin:0;max-height:15.625rem;overflow-y:auto;padding:0;width:100%;z-index:1000}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-700);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-12);line-height:var(--l-height-16);height:var(--size-32);padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn .tcloud-ui-dropdown-option-text{flex:1;overflow:hidden;text-align:left;white-space:nowrap}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn .tcloud-ui-dropdown-option-text.ellipsed{text-overflow:ellipsis}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:hover{border-color:var(--c-primary-500);color:var(--c-primary-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search{position:sticky;top:0;background-color:var(--c-neutral-50);padding:var(--size-8);border-bottom:1px solid var(--c-neutral-200);z-index:1}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container{position:relative;display:flex;align-items:center}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input{width:100%;height:var(--size-32);padding:0 var(--size-36) 0 var(--size-32);border:1px solid var(--c-neutral-300);border-radius:var(--bor-radius-pill);font-size:var(--f-size-12);line-height:var(--l-height-16);color:var(--c-neutral-700);background-color:var(--c-neutral-50);outline:none;transition:border-color .2s ease}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input:focus{border-color:var(--c-primary-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input::placeholder{color:var(--c-neutral-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-icon{position:absolute;left:var(--size-8);color:var(--c-neutral-500);font-size:var(--f-size-12);line-height:1;pointer-events:none;top:50%;transform:translateY(-50%)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-clear{position:absolute;right:var(--size-8);background:none;border:none;color:var(--c-neutral-500);cursor:pointer;padding:var(--size-2);display:flex;align-items:center;height:var(--size-24);justify-content:center;line-height:1;transition:color .2s ease;top:50%;transform:translateY(-50%);width:var(--size-24)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-clear:hover{color:var(--c-neutral-700)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-no-results{padding:var(--size-12) var(--size-8);text-align:center;color:var(--c-neutral-500);font-size:var(--f-size-12);font-style:italic}.tcloud-ui-dropdown-menu--device{height:100%;overflow-y:auto;background-color:var(--c-neutral-50);padding:var(--size-16)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-section{display:contents}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-header{align-items:center;display:flex;gap:var(--size-16);justify-content:space-between}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-container{list-style:none;margin:0;padding:0;gap:.5rem;display:flex;flex-direction:column}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-14);line-height:var(--l-height-16);height:var(--size-40);padding:var(--size-12);text-align:left;text-wrap:nowrap;transition:all .2s ease;width:100%}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:active:not(:disabled):not(.selected){background-color:var(--c-primary-200);border-color:var(--c-primary-200);color:var(--c-primary-500);transform:scale(.98)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile{position:sticky;top:0;background-color:var(--c-neutral-50);padding:var(--size-12) 0;margin-bottom:var(--size-8);border-bottom:1px solid var(--c-neutral-200);z-index:1}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input{height:var(--size-40);font-size:var(--f-size-14);padding:var(--size-12) var(--size-40) var(--size-12) var(--size-16)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-icon{left:var(--size-12);font-size:var(--f-size-14)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-clear{right:var(--size-12);padding:var(--size-4)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-no-results--mobile{padding:var(--size-16) var(--size-12);font-size:var(--f-size-14);color:var(--c-neutral-600)}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: TCloudUiIconButtonDirective, selector: "button[tcloudUiIconButton]", inputs: ["color", "size", "tcloudUiIconButton"] }] }); }
|
|
9795
9616
|
}
|
|
9796
9617
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TCloudUiDropdownComponent, decorators: [{
|
|
9797
9618
|
type: Component,
|
|
9798
9619
|
args: [{ selector: 'tcloud-ui-dropdown', imports: [
|
|
9799
9620
|
FormsModule,
|
|
9800
9621
|
ReactiveFormsModule,
|
|
9801
|
-
|
|
9802
|
-
TcRevIconButtonDirective
|
|
9803
|
-
], providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR], template: "<div\n class=\"tcloud-ui-dropdown\"\n [class.disabled]=\"isDisabled()\"\n [style.width]=\"this.width()\"\n >\n <button\n class=\"tcloud-ui-dropdown-toggle\"\n [class.tcloud-ui-dropdown-toggle--sm]=\"this.size() === dropdownSize.sm\"\n [class.tcloud-ui-dropdown-toggle--md]=\"this.size() === dropdownSize.md\"\n [class.tcloud-ui-dropdown-toggle--lg]=\"this.size() === dropdownSize.lg\"\n (click)=\"toggleDropdown()\"\n [class.disabled]=\"isDisabled()\"\n [disabled]=\"isDisabled()\"\n >\n @if (label()) {\n <b [innerHTML]=\"label()\"></b>\n }\n <span class=\"tcloud-ui-dropdown-selected-text\">\n {{ selectedOption() ? selectedOption()?.displayValue : \"Selecione\" }}\n </span>\n <i class=\"fa-light fa-chevron-down mar-l-a\"></i>\n </button>\n @if (isOpen && isDesktop()) {\n <ul class=\"tcloud-ui-dropdown-menu\">\n <!-- Campo de busca -->\n @if (searchable()) {\n <li class=\"tcloud-ui-dropdown-search\">\n <div class=\"tcloud-ui-dropdown-search-container\">\n <input\n type=\"text\"\n class=\"tcloud-ui-dropdown-search-input\"\n [placeholder]=\"searchPlaceholder()\"\n [value]=\"searchText()\"\n (input)=\"onSearchChange($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n <i class=\"fa-light fa-magnifying-glass tcloud-ui-dropdown-search-icon\"></i>\n @if (searchText()) {\n <button\n type=\"button\"\n class=\"tcloud-ui-dropdown-search-clear\"\n (click)=\"clearSearch(); $event.stopPropagation()\"\n >\n <i class=\"fa-light fa-times\"></i>\n </button>\n }\n </div>\n </li>\n }\n @for (option of filteredOptions(); track option?.value) {\n <li class=\"tcloud-ui-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tcloud-ui-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n <span\n class=\"tcloud-ui-dropdown-option-text\"\n position=\"top\"\n >\n {{ option?.displayValue }}\n </span>\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check\"></i>\n }\n </button>\n </li>\n }\n <!-- Mensagem quando nenhum item for encontrado na busca -->\n @if (searchable() && searchText() && filteredOptions().length === 0) {\n <li class=\"tcloud-ui-dropdown-no-results\">\n <span>Nenhuma op\u00E7\u00E3o encontrada</span>\n </li>\n }\n </ul>\n }\n\n <!-- Dropdown full screen -->\n <ng-template #menuTemplate>\n <div class=\"tcloud-ui-dropdown-menu tcloud-ui-dropdown-menu--device\">\n <div class=\"tcloud-ui-dropdown-menu-section\">\n <div class=\"tcloud-ui-dropdown-menu-header pad-b-24\">\n <h3 class=\"mar-none f-h2 f-weight-600 c-neutral-600\">\n {{ label() }}\n </h3>\n <button\n tcRevIconButton=\"outline\"\n color=\"dark\"\n size=\"sm\"\n (click)=\"_deviceService.closeDropdownDevice()\"\n >\n <i class=\"fa-light fa-times f-size-16\"></i>\n </button>\n </div>\n <ul class=\"tcloud-ui-dropdown-menu-container mar-t-8\">\n <!-- Campo de busca mobile -->\n @if (searchable()) {\n <li class=\"tcloud-ui-dropdown-search tcloud-ui-dropdown-search--mobile\">\n <div class=\"tcloud-ui-dropdown-search-container\">\n <input\n type=\"text\"\n class=\"tcloud-ui-dropdown-search-input\"\n [placeholder]=\"searchPlaceholder()\"\n [value]=\"searchText()\"\n (input)=\"onSearchChange($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n <i class=\"fa-light fa-magnifying-glass tcloud-ui-dropdown-search-icon\"></i>\n @if (searchText()) {\n <button\n type=\"button\"\n class=\"tcloud-ui-dropdown-search-clear\"\n (click)=\"clearSearch(); $event.stopPropagation()\"\n >\n <i class=\"fa-light fa-times\"></i>\n </button>\n }\n </div>\n </li>\n }\n @for (option of filteredOptions(); track option?.value) {\n <li class=\"tcloud-ui-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tcloud-ui-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n {{ option?.displayValue }}\n\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check f-size-16\"></i>\n }\n </button>\n </li>\n }\n <!-- Mensagem quando nenhum item for encontrado na busca mobile -->\n @if (searchable() && searchText() && filteredOptions().length === 0) {\n <li class=\"tcloud-ui-dropdown-no-results tcloud-ui-dropdown-no-results--mobile\">\n <span>Nenhuma op\u00E7\u00E3o encontrada</span>\n </li>\n }\n </ul>\n </div>\n </div>\n </ng-template>\n </div>\n", styles: [".tcloud-ui-dropdown{position:relative;display:block;width:100%}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle{align-items:center;background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-400);border-radius:var(--bor-radius-pill);color:var(--c-neutral-700);cursor:pointer;display:inline-flex;font-family:var(--f-family);font-size:var(--f-size-12);gap:var(--size-8);line-height:var(--l-height-16);outline:none;transition:.2s ease;padding:0 var(--size-12) 0 var(--size-16);width:100%}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle .tcloud-ui-dropdown-selected-text{flex:1;overflow:hidden;text-align:left;text-overflow:ellipsis;white-space:nowrap}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle i{align-items:center;display:inline-flex;flex-shrink:0;height:var(--size-24);justify-content:center;line-height:1;width:var(--size-24)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle--sm{height:var(--size-40)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle--md{height:var(--size-44)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle--lg{height:var(--size-48)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle:hover,.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle:focus{border-color:var(--c-primary-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle:disabled{border-color:var(--c-neutral-300);color:var(--c-neutral-300);cursor:not-allowed}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu{box-shadow:var(--shadow-md);border:1px solid var(--c-neutral-300);position:absolute;top:110%;left:0;background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);list-style:none;margin:0;max-height:15.625rem;overflow-y:auto;padding:0;width:100%;z-index:1000}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-700);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-12);line-height:var(--l-height-16);height:var(--size-32);padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn .tcloud-ui-dropdown-option-text{flex:1;overflow:hidden;text-align:left;white-space:nowrap}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn .tcloud-ui-dropdown-option-text.ellipsed{text-overflow:ellipsis}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:hover{border-color:var(--c-primary-500);color:var(--c-primary-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search{position:sticky;top:0;background-color:var(--c-neutral-50);padding:var(--size-8);border-bottom:1px solid var(--c-neutral-200);z-index:1}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container{position:relative;display:flex;align-items:center}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input{width:100%;height:var(--size-32);padding:0 var(--size-36) 0 var(--size-32);border:1px solid var(--c-neutral-300);border-radius:var(--bor-radius-pill);font-size:var(--f-size-12);line-height:var(--l-height-16);color:var(--c-neutral-700);background-color:var(--c-neutral-50);outline:none;transition:border-color .2s ease}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input:focus{border-color:var(--c-primary-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input::placeholder{color:var(--c-neutral-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-icon{position:absolute;left:var(--size-8);color:var(--c-neutral-500);font-size:var(--f-size-12);line-height:1;pointer-events:none;top:50%;transform:translateY(-50%)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-clear{position:absolute;right:var(--size-8);background:none;border:none;color:var(--c-neutral-500);cursor:pointer;padding:var(--size-2);display:flex;align-items:center;height:var(--size-24);justify-content:center;line-height:1;transition:color .2s ease;top:50%;transform:translateY(-50%);width:var(--size-24)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-clear:hover{color:var(--c-neutral-700)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-no-results{padding:var(--size-12) var(--size-8);text-align:center;color:var(--c-neutral-500);font-size:var(--f-size-12);font-style:italic}.tcloud-ui-dropdown-menu--device{height:100%;overflow-y:auto;background-color:var(--c-neutral-50);padding:var(--size-16)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-section{display:contents}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-header{align-items:center;display:flex;gap:var(--size-16);justify-content:space-between}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-container{list-style:none;margin:0;padding:0;gap:.5rem;display:flex;flex-direction:column}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-14);line-height:var(--l-height-16);height:var(--size-40);padding:var(--size-12);text-align:left;text-wrap:nowrap;transition:all .2s ease;width:100%}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:active:not(:disabled):not(.selected){background-color:var(--c-primary-200);border-color:var(--c-primary-200);color:var(--c-primary-500);transform:scale(.98)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile{position:sticky;top:0;background-color:var(--c-neutral-50);padding:var(--size-12) 0;margin-bottom:var(--size-8);border-bottom:1px solid var(--c-neutral-200);z-index:1}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input{height:var(--size-40);font-size:var(--f-size-14);padding:var(--size-12) var(--size-40) var(--size-12) var(--size-16)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-icon{left:var(--size-12);font-size:var(--f-size-14)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-clear{right:var(--size-12);padding:var(--size-4)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-no-results--mobile{padding:var(--size-16) var(--size-12);font-size:var(--f-size-14);color:var(--c-neutral-600)}\n"] }]
|
|
9622
|
+
TCloudUiIconButtonDirective
|
|
9623
|
+
], providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR], template: "<div\n class=\"tcloud-ui-dropdown\"\n [class.disabled]=\"isDisabled()\"\n [style.width]=\"this.width()\"\n >\n <button\n class=\"tcloud-ui-dropdown-toggle\"\n [class.tcloud-ui-dropdown-toggle--sm]=\"this.size() === dropdownSize.sm\"\n [class.tcloud-ui-dropdown-toggle--md]=\"this.size() === dropdownSize.md\"\n [class.tcloud-ui-dropdown-toggle--lg]=\"this.size() === dropdownSize.lg\"\n (click)=\"toggleDropdown()\"\n [class.disabled]=\"isDisabled()\"\n [disabled]=\"isDisabled()\"\n >\n @if (label()) {\n <b [innerHTML]=\"label()\"></b>\n }\n <span class=\"tcloud-ui-dropdown-selected-text\">\n {{ selectedOption() ? selectedOption()?.displayValue : \"Selecione\" }}\n </span>\n <i class=\"fa-light fa-chevron-down mar-l-a\"></i>\n </button>\n @if (isOpen && isDesktop()) {\n <ul class=\"tcloud-ui-dropdown-menu\">\n <!-- Campo de busca -->\n @if (searchable()) {\n <li class=\"tcloud-ui-dropdown-search\">\n <div class=\"tcloud-ui-dropdown-search-container\">\n <input\n type=\"text\"\n class=\"tcloud-ui-dropdown-search-input\"\n [placeholder]=\"searchPlaceholder()\"\n [value]=\"searchText()\"\n (input)=\"onSearchChange($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n <i class=\"fa-light fa-magnifying-glass tcloud-ui-dropdown-search-icon\"></i>\n @if (searchText()) {\n <button\n type=\"button\"\n class=\"tcloud-ui-dropdown-search-clear\"\n (click)=\"clearSearch(); $event.stopPropagation()\"\n >\n <i class=\"fa-light fa-times\"></i>\n </button>\n }\n </div>\n </li>\n }\n @for (option of filteredOptions(); track option?.value) {\n <li class=\"tcloud-ui-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tcloud-ui-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n <span\n class=\"tcloud-ui-dropdown-option-text\"\n position=\"top\"\n >\n {{ option?.displayValue }}\n </span>\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check\"></i>\n }\n </button>\n </li>\n }\n <!-- Mensagem quando nenhum item for encontrado na busca -->\n @if (searchable() && searchText() && filteredOptions().length === 0) {\n <li class=\"tcloud-ui-dropdown-no-results\">\n <span>Nenhuma op\u00E7\u00E3o encontrada</span>\n </li>\n }\n </ul>\n }\n\n <!-- Dropdown full screen -->\n <ng-template #menuTemplate>\n <div class=\"tcloud-ui-dropdown-menu tcloud-ui-dropdown-menu--device\">\n <div class=\"tcloud-ui-dropdown-menu-section\">\n <div class=\"tcloud-ui-dropdown-menu-header pad-b-24\">\n <h3 class=\"mar-none f-h2 f-weight-600 c-neutral-600\">\n {{ label() }}\n </h3>\n <button\n tcloudUiIconButton=\"outline\"\n color=\"dark\"\n size=\"sm\"\n (click)=\"_deviceService.closeDropdownDevice()\"\n >\n <i class=\"fa-light fa-times f-size-16\"></i>\n </button>\n </div>\n <ul class=\"tcloud-ui-dropdown-menu-container mar-t-8\">\n <!-- Campo de busca mobile -->\n @if (searchable()) {\n <li class=\"tcloud-ui-dropdown-search tcloud-ui-dropdown-search--mobile\">\n <div class=\"tcloud-ui-dropdown-search-container\">\n <input\n type=\"text\"\n class=\"tcloud-ui-dropdown-search-input\"\n [placeholder]=\"searchPlaceholder()\"\n [value]=\"searchText()\"\n (input)=\"onSearchChange($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n <i class=\"fa-light fa-magnifying-glass tcloud-ui-dropdown-search-icon\"></i>\n @if (searchText()) {\n <button\n type=\"button\"\n class=\"tcloud-ui-dropdown-search-clear\"\n (click)=\"clearSearch(); $event.stopPropagation()\"\n >\n <i class=\"fa-light fa-times\"></i>\n </button>\n }\n </div>\n </li>\n }\n @for (option of filteredOptions(); track option?.value) {\n <li class=\"tcloud-ui-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tcloud-ui-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n {{ option?.displayValue }}\n\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check f-size-16\"></i>\n }\n </button>\n </li>\n }\n <!-- Mensagem quando nenhum item for encontrado na busca mobile -->\n @if (searchable() && searchText() && filteredOptions().length === 0) {\n <li class=\"tcloud-ui-dropdown-no-results tcloud-ui-dropdown-no-results--mobile\">\n <span>Nenhuma op\u00E7\u00E3o encontrada</span>\n </li>\n }\n </ul>\n </div>\n </div>\n </ng-template>\n </div>\n", styles: [".tcloud-ui-dropdown{position:relative;display:block;width:100%}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle{align-items:center;background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-400);border-radius:var(--bor-radius-pill);color:var(--c-neutral-700);cursor:pointer;display:inline-flex;font-family:var(--f-family);font-size:var(--f-size-12);gap:var(--size-8);line-height:var(--l-height-16);outline:none;transition:.2s ease;padding:0 var(--size-12) 0 var(--size-16);width:100%}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle .tcloud-ui-dropdown-selected-text{flex:1;overflow:hidden;text-align:left;text-overflow:ellipsis;white-space:nowrap}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle i{align-items:center;display:inline-flex;flex-shrink:0;height:var(--size-24);justify-content:center;line-height:1;width:var(--size-24)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle--sm{height:var(--size-40)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle--md{height:var(--size-44)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle--lg{height:var(--size-48)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle:hover,.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle:focus{border-color:var(--c-primary-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-toggle:disabled{border-color:var(--c-neutral-300);color:var(--c-neutral-300);cursor:not-allowed}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu{box-shadow:var(--shadow-md);border:1px solid var(--c-neutral-300);position:absolute;top:110%;left:0;background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);list-style:none;margin:0;max-height:15.625rem;overflow-y:auto;padding:0;width:100%;z-index:1000}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-700);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-12);line-height:var(--l-height-16);height:var(--size-32);padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn .tcloud-ui-dropdown-option-text{flex:1;overflow:hidden;text-align:left;white-space:nowrap}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn .tcloud-ui-dropdown-option-text.ellipsed{text-overflow:ellipsis}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:hover{border-color:var(--c-primary-500);color:var(--c-primary-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search{position:sticky;top:0;background-color:var(--c-neutral-50);padding:var(--size-8);border-bottom:1px solid var(--c-neutral-200);z-index:1}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container{position:relative;display:flex;align-items:center}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input{width:100%;height:var(--size-32);padding:0 var(--size-36) 0 var(--size-32);border:1px solid var(--c-neutral-300);border-radius:var(--bor-radius-pill);font-size:var(--f-size-12);line-height:var(--l-height-16);color:var(--c-neutral-700);background-color:var(--c-neutral-50);outline:none;transition:border-color .2s ease}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input:focus{border-color:var(--c-primary-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input::placeholder{color:var(--c-neutral-500)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-icon{position:absolute;left:var(--size-8);color:var(--c-neutral-500);font-size:var(--f-size-12);line-height:1;pointer-events:none;top:50%;transform:translateY(-50%)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-clear{position:absolute;right:var(--size-8);background:none;border:none;color:var(--c-neutral-500);cursor:pointer;padding:var(--size-2);display:flex;align-items:center;height:var(--size-24);justify-content:center;line-height:1;transition:color .2s ease;top:50%;transform:translateY(-50%);width:var(--size-24)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-search .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-clear:hover{color:var(--c-neutral-700)}.tcloud-ui-dropdown .tcloud-ui-dropdown-menu .tcloud-ui-dropdown-no-results{padding:var(--size-12) var(--size-8);text-align:center;color:var(--c-neutral-500);font-size:var(--f-size-12);font-style:italic}.tcloud-ui-dropdown-menu--device{height:100%;overflow-y:auto;background-color:var(--c-neutral-50);padding:var(--size-16)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-section{display:contents}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-header{align-items:center;display:flex;gap:var(--size-16);justify-content:space-between}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-container{list-style:none;margin:0;padding:0;gap:.5rem;display:flex;flex-direction:column}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-14);line-height:var(--l-height-16);height:var(--size-40);padding:var(--size-12);text-align:left;text-wrap:nowrap;transition:all .2s ease;width:100%}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:active:not(:disabled):not(.selected){background-color:var(--c-primary-200);border-color:var(--c-primary-200);color:var(--c-primary-500);transform:scale(.98)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-menu-item .tcloud-ui-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile{position:sticky;top:0;background-color:var(--c-neutral-50);padding:var(--size-12) 0;margin-bottom:var(--size-8);border-bottom:1px solid var(--c-neutral-200);z-index:1}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-input{height:var(--size-40);font-size:var(--f-size-14);padding:var(--size-12) var(--size-40) var(--size-12) var(--size-16)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-icon{left:var(--size-12);font-size:var(--f-size-14)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-search--mobile .tcloud-ui-dropdown-search-container .tcloud-ui-dropdown-search-clear{right:var(--size-12);padding:var(--size-4)}.tcloud-ui-dropdown-menu--device .tcloud-ui-dropdown-no-results--mobile{padding:var(--size-16) var(--size-12);font-size:var(--f-size-14);color:var(--c-neutral-600)}\n"] }]
|
|
9804
9624
|
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { menuTemplate: [{
|
|
9805
9625
|
type: ViewChild,
|
|
9806
9626
|
args: ['menuTemplate']
|
|
@@ -9809,12 +9629,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
9809
9629
|
args: ['document:click', ['$event']]
|
|
9810
9630
|
}], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], options: [{ type: i0.Input, args: [{ isSignal: true, alias: "options", required: true }] }], initialValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialValue", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], width: [{ type: i0.Input, args: [{ isSignal: true, alias: "width", required: false }] }], searchable: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchable", required: false }] }], searchPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchPlaceholder", required: false }] }], optionSelected: [{ type: i0.Output, args: ["optionSelected"] }] } });
|
|
9811
9631
|
|
|
9812
|
-
var DropdownMultiSize
|
|
9632
|
+
var DropdownMultiSize;
|
|
9813
9633
|
(function (DropdownMultiSize) {
|
|
9814
9634
|
DropdownMultiSize["sm"] = "sm";
|
|
9815
9635
|
DropdownMultiSize["md"] = "md";
|
|
9816
9636
|
DropdownMultiSize["lg"] = "lg";
|
|
9817
|
-
})(DropdownMultiSize
|
|
9637
|
+
})(DropdownMultiSize || (DropdownMultiSize = {}));
|
|
9818
9638
|
class TCloudUiDropdownMultiComponent {
|
|
9819
9639
|
onDocumentClick(event) {
|
|
9820
9640
|
if (this.isOpen && !this.elementRef.nativeElement.contains(event.target)) {
|
|
@@ -9828,7 +9648,7 @@ class TCloudUiDropdownMultiComponent {
|
|
|
9828
9648
|
this.options = input.required(...(ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ [])); // Lista de opções no novo formato
|
|
9829
9649
|
this.initialValues = input([], ...(ngDevMode ? [{ debugName: "initialValues" }] : /* istanbul ignore next */ [])); // Valores pré-selecionados (deprecated - use values instead)
|
|
9830
9650
|
this.values = model([], ...(ngDevMode ? [{ debugName: "values" }] : /* istanbul ignore next */ [])); // Two-way binding para os valores selecionados
|
|
9831
|
-
this.size = input(DropdownMultiSize
|
|
9651
|
+
this.size = input(DropdownMultiSize.sm, ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
9832
9652
|
this.width = input('', ...(ngDevMode ? [{ debugName: "width" }] : /* istanbul ignore next */ [])); // Largura do dropdown
|
|
9833
9653
|
this.placeholder = input('Selecione', ...(ngDevMode ? [{ debugName: "placeholder" }] : /* istanbul ignore next */ [])); // Placeholder quando nenhum item estiver selecionado
|
|
9834
9654
|
this.maxDisplayItems = input(2, ...(ngDevMode ? [{ debugName: "maxDisplayItems" }] : /* istanbul ignore next */ [])); // Máximo de itens a serem exibidos no botão
|
|
@@ -9837,7 +9657,7 @@ class TCloudUiDropdownMultiComponent {
|
|
|
9837
9657
|
this.optionsSelected = output(); // Emissor para os valores selecionados
|
|
9838
9658
|
this.selectedOptions = signal([], ...(ngDevMode ? [{ debugName: "selectedOptions" }] : /* istanbul ignore next */ [])); // Opções selecionadas
|
|
9839
9659
|
this.isOpen = false; // Controla se o dropdown está aberto
|
|
9840
|
-
this.dropdownSize = DropdownMultiSize
|
|
9660
|
+
this.dropdownSize = DropdownMultiSize;
|
|
9841
9661
|
this.searchText = signal('', ...(ngDevMode ? [{ debugName: "searchText" }] : /* istanbul ignore next */ [])); // Texto de busca
|
|
9842
9662
|
// Opções filtradas baseadas na busca
|
|
9843
9663
|
this.filteredOptions = computed(() => {
|
|
@@ -10063,7 +9883,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
10063
9883
|
class TCloudUiSkeletonLoadingComponentStyle {
|
|
10064
9884
|
}
|
|
10065
9885
|
|
|
10066
|
-
var TagColorsEnum
|
|
9886
|
+
var TagColorsEnum;
|
|
10067
9887
|
(function (TagColorsEnum) {
|
|
10068
9888
|
TagColorsEnum["neutral-50"] = "neutral-50";
|
|
10069
9889
|
TagColorsEnum["neutral-100"] = "neutral-100";
|
|
@@ -10097,12 +9917,12 @@ var TagColorsEnum$1;
|
|
|
10097
9917
|
TagColorsEnum["success-300"] = "success-300";
|
|
10098
9918
|
TagColorsEnum["success-400"] = "success-400";
|
|
10099
9919
|
TagColorsEnum["success-500"] = "success-500";
|
|
10100
|
-
})(TagColorsEnum
|
|
9920
|
+
})(TagColorsEnum || (TagColorsEnum = {}));
|
|
10101
9921
|
|
|
10102
9922
|
class TCloudUiTagComponent {
|
|
10103
9923
|
constructor() {
|
|
10104
9924
|
this.size = input('md', ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
10105
|
-
this.color = input(TagColorsEnum
|
|
9925
|
+
this.color = input(TagColorsEnum['primary-500'], ...(ngDevMode ? [{ debugName: "color" }] : /* istanbul ignore next */ []));
|
|
10106
9926
|
this.variant = input('filled', ...(ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []));
|
|
10107
9927
|
this.shape = input('rectangle', ...(ngDevMode ? [{ debugName: "shape" }] : /* istanbul ignore next */ []));
|
|
10108
9928
|
this.fullWidth = input(false, ...(ngDevMode ? [{ debugName: "fullWidth" }] : /* istanbul ignore next */ []));
|
|
@@ -10535,38 +10355,6 @@ var TCloudUiDialogEventsEnum;
|
|
|
10535
10355
|
TCloudUiDialogEventsEnum[TCloudUiDialogEventsEnum["close"] = 1] = "close";
|
|
10536
10356
|
})(TCloudUiDialogEventsEnum || (TCloudUiDialogEventsEnum = {}));
|
|
10537
10357
|
|
|
10538
|
-
class TcRevSmallLoadingComponent {
|
|
10539
|
-
constructor() {
|
|
10540
|
-
/** Width of the loading spinner accepts string with CSS units (px, rem, em) */
|
|
10541
|
-
this.width = input('1.25rem', ...(ngDevMode ? [{ debugName: "width" }] : /* istanbul ignore next */ []));
|
|
10542
|
-
/** Margin top in pixels */
|
|
10543
|
-
this.marginTop = input(0, ...(ngDevMode ? [{ debugName: "marginTop" }] : /* istanbul ignore next */ []));
|
|
10544
|
-
/** Margin bottom in pixels */
|
|
10545
|
-
this.marginBottom = input(0, ...(ngDevMode ? [{ debugName: "marginBottom" }] : /* istanbul ignore next */ []));
|
|
10546
|
-
/** Margin right in pixels */
|
|
10547
|
-
this.marginRight = input(0, ...(ngDevMode ? [{ debugName: "marginRight" }] : /* istanbul ignore next */ []));
|
|
10548
|
-
/** Margin left in pixels */
|
|
10549
|
-
this.marginLeft = input(0, ...(ngDevMode ? [{ debugName: "marginLeft" }] : /* istanbul ignore next */ []));
|
|
10550
|
-
this.style = new TcRevSmallLoadingComponentStyle();
|
|
10551
|
-
}
|
|
10552
|
-
ngOnInit() {
|
|
10553
|
-
this.style.marginTop = `${this.marginTop()}px`;
|
|
10554
|
-
this.style.marginRight = `${this.marginRight()}px`;
|
|
10555
|
-
this.style.marginLeft = `${this.marginLeft()}px`;
|
|
10556
|
-
this.style.marginBottom = `${this.marginBottom()}px`;
|
|
10557
|
-
this.style.width = this.width();
|
|
10558
|
-
this.style.height = this.width();
|
|
10559
|
-
}
|
|
10560
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSmallLoadingComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
10561
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.17", type: TcRevSmallLoadingComponent, isStandalone: true, selector: "tc-rev-small-loading", inputs: { width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null }, marginTop: { classPropertyName: "marginTop", publicName: "marginTop", isSignal: true, isRequired: false, transformFunction: null }, marginBottom: { classPropertyName: "marginBottom", publicName: "marginBottom", isSignal: true, isRequired: false, transformFunction: null }, marginRight: { classPropertyName: "marginRight", publicName: "marginRight", isSignal: true, isRequired: false, transformFunction: null }, marginLeft: { classPropertyName: "marginLeft", publicName: "marginLeft", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"tc-rev-small-loading\">\n <span\n class=\"tc-rev-small-loading__spinner\"\n [ngStyle]=\"this.style\">\n </span>\n</div>\n", styles: ["@keyframes rotation{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.tc-rev-small-loading{display:flex;align-items:center;justify-content:center}.tc-rev-small-loading__spinner{animation:rotation 1s linear infinite;border:3px solid var(--c-neutral-200);border-bottom-color:var(--c-neutral-500);border-radius:50%;box-sizing:border-box;display:inline-block;height:var(--size-20);width:var(--size-20)}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }] }); }
|
|
10562
|
-
}
|
|
10563
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSmallLoadingComponent, decorators: [{
|
|
10564
|
-
type: Component,
|
|
10565
|
-
args: [{ selector: 'tc-rev-small-loading', imports: [CommonModule], template: "<div class=\"tc-rev-small-loading\">\n <span\n class=\"tc-rev-small-loading__spinner\"\n [ngStyle]=\"this.style\">\n </span>\n</div>\n", styles: ["@keyframes rotation{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.tc-rev-small-loading{display:flex;align-items:center;justify-content:center}.tc-rev-small-loading__spinner{animation:rotation 1s linear infinite;border:3px solid var(--c-neutral-200);border-bottom-color:var(--c-neutral-500);border-radius:50%;box-sizing:border-box;display:inline-block;height:var(--size-20);width:var(--size-20)}\n"] }]
|
|
10566
|
-
}], propDecorators: { width: [{ type: i0.Input, args: [{ isSignal: true, alias: "width", required: false }] }], marginTop: [{ type: i0.Input, args: [{ isSignal: true, alias: "marginTop", required: false }] }], marginBottom: [{ type: i0.Input, args: [{ isSignal: true, alias: "marginBottom", required: false }] }], marginRight: [{ type: i0.Input, args: [{ isSignal: true, alias: "marginRight", required: false }] }], marginLeft: [{ type: i0.Input, args: [{ isSignal: true, alias: "marginLeft", required: false }] }] } });
|
|
10567
|
-
class TcRevSmallLoadingComponentStyle {
|
|
10568
|
-
}
|
|
10569
|
-
|
|
10570
10358
|
class TCloudUiDialogComponent {
|
|
10571
10359
|
constructor() {
|
|
10572
10360
|
this.animation = 'visible';
|
|
@@ -10684,11 +10472,11 @@ class TCloudUiDialogComponent {
|
|
|
10684
10472
|
return this;
|
|
10685
10473
|
}
|
|
10686
10474
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TCloudUiDialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
10687
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TCloudUiDialogComponent, isStandalone: true, selector: "tcloud-ui-dialog", host: { listeners: { "document:keydown.escape": "onKeydownHandler($event)" } }, ngImport: i0, template: "<div class=\"background-modal\" (click)=\"onBackdropClick()\"></div>\n\n@let disabled = data.disable || data.loading;\n<div class=\"container-dialog\" [class.dialog-hide]=\"animation === 'hide'\">\n\n <!-- Header -->\n <div class=\"container-header\">\n\n <!-- Title -->\n <h4 class=\"tc-title tcloud-ui-modal-header tc-modal-header\">{{ data.title }}</h4>\n\n <!-- Close button -->\n <div class=\"container-close-button\" (click)=\" disabled ? null : close()\">\n <i class=\"fas fa-times\"></i>\n </div>\n </div>\n\n <!-- Message -->\n <div [innerHTML]=\"data.message\"></div>\n\n <!-- Input confirmation -->\n @if (hasInputConfirmation)\n {\n <div class=\"container-input-confirmation\">\n <input\n tcloudForm\n class=\"tc-form-confirm tc-form-control\"\n [formControl]=\"inputConfirmationControl\"\n [placeholder]=\"inputConfirmationErrorMessage()\"\n (keyup.enter)=\"confirm()\"\n />\n\n @if (inputConfirmationControl.touched && inputConfirmationControl.invalid)\n {\n <p class=\"text-danger\">{{ inputConfirmationErrorMessage() }}</p>\n }\n </div>\n }\n\n <!-- Loading -->\n @if (data.loading)\n {\n <
|
|
10475
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TCloudUiDialogComponent, isStandalone: true, selector: "tcloud-ui-dialog", host: { listeners: { "document:keydown.escape": "onKeydownHandler($event)" } }, ngImport: i0, template: "<div class=\"background-modal\" (click)=\"onBackdropClick()\"></div>\n\n@let disabled = data.disable || data.loading;\n<div class=\"container-dialog\" [class.dialog-hide]=\"animation === 'hide'\">\n\n <!-- Header -->\n <div class=\"container-header\">\n\n <!-- Title -->\n <h4 class=\"tc-title tcloud-ui-modal-header tc-modal-header\">{{ data.title }}</h4>\n\n <!-- Close button -->\n <div class=\"container-close-button\" (click)=\" disabled ? null : close()\">\n <i class=\"fas fa-times\"></i>\n </div>\n </div>\n\n <!-- Message -->\n <div [innerHTML]=\"data.message\"></div>\n\n <!-- Input confirmation -->\n @if (hasInputConfirmation)\n {\n <div class=\"container-input-confirmation\">\n <input\n tcloudForm\n class=\"tc-form-confirm tc-form-control\"\n [formControl]=\"inputConfirmationControl\"\n [placeholder]=\"inputConfirmationErrorMessage()\"\n (keyup.enter)=\"confirm()\"\n />\n\n @if (inputConfirmationControl.touched && inputConfirmationControl.invalid)\n {\n <p class=\"text-danger\">{{ inputConfirmationErrorMessage() }}</p>\n }\n </div>\n }\n\n <!-- Loading -->\n @if (data.loading)\n {\n <tcloud-ui-loading [loading]=\"true\" mode=\"inline\" />\n }\n\n <!-- Footer -->\n <div class=\"container-footer\">\n\n <!-- Cancelar -->\n <button\n class=\"tc-btn tc-btn-outline-primary\"\n [disabled]=\"disabled\"\n (click)=\"close()\">{{ data.buttonCancelText || ('dialogConfirmation.cancel' | i18nTranslate: 'Cancelar') }}\n </button>\n\n <!-- Confirmar -->\n <button\n class=\"tc-btn tc-btn-primary\"\n [disabled]=\"disabled\"\n (click)=\"confirm()\">{{ textConfirmation | titlecase }}\n </button>\n </div>\n</div>\n", styles: [".background-modal{position:fixed;z-index:3000;width:100%;height:100%;background-color:#00000080;top:0;left:0}.container-dialog{position:fixed;top:15%;left:calc(50% - 300px);width:500px;z-index:30001;border-radius:8px;padding:24px;box-sizing:border-box;display:grid;gap:24px;background-color:var(--c-neutral-50);color:var(--c-neutral-700);opacity:1;transition:opacity .3s ease-out,top .3s ease-out}.container-dialog .container-header{display:flex;justify-content:space-between;align-items:center}.container-dialog .container-header .tc-title{font-size:18px;font-weight:700}.container-dialog .container-header .container-close-button{width:40px;height:40px;border-radius:100%;cursor:pointer;display:flex;align-items:center;justify-content:center;font-size:18px;color:var(--c-neutral-600);border:1px solid var(--c-neutral-300)}.container-dialog .container-input-confirmation{display:grid;gap:8px}.container-dialog .container-footer{display:flex;justify-content:space-between;align-items:center;gap:16px}.container-dialog .container-footer button{width:100%}.container-dialog.dialog-hide{opacity:0;top:-38%}@starting-style{.container-dialog{opacity:0;top:-38%}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.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.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: TCloudUiLoadingComponent, selector: "tcloud-ui-loading", inputs: ["gif", "mode", "onlyInline", "onlyIcon", "full", "loading"] }, { kind: "pipe", type: i1$1.TitleCasePipe, name: "titlecase" }, { kind: "pipe", type: I18nTranslatePipe, name: "i18nTranslate" }] }); }
|
|
10688
10476
|
}
|
|
10689
10477
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TCloudUiDialogComponent, decorators: [{
|
|
10690
10478
|
type: Component,
|
|
10691
|
-
args: [{ selector: 'tcloud-ui-dialog', standalone: true, imports: [CommonModule, ReactiveFormsModule, I18nTranslatePipe, TCloudUiLoadingComponent
|
|
10479
|
+
args: [{ selector: 'tcloud-ui-dialog', standalone: true, imports: [CommonModule, ReactiveFormsModule, I18nTranslatePipe, TCloudUiLoadingComponent], template: "<div class=\"background-modal\" (click)=\"onBackdropClick()\"></div>\n\n@let disabled = data.disable || data.loading;\n<div class=\"container-dialog\" [class.dialog-hide]=\"animation === 'hide'\">\n\n <!-- Header -->\n <div class=\"container-header\">\n\n <!-- Title -->\n <h4 class=\"tc-title tcloud-ui-modal-header tc-modal-header\">{{ data.title }}</h4>\n\n <!-- Close button -->\n <div class=\"container-close-button\" (click)=\" disabled ? null : close()\">\n <i class=\"fas fa-times\"></i>\n </div>\n </div>\n\n <!-- Message -->\n <div [innerHTML]=\"data.message\"></div>\n\n <!-- Input confirmation -->\n @if (hasInputConfirmation)\n {\n <div class=\"container-input-confirmation\">\n <input\n tcloudForm\n class=\"tc-form-confirm tc-form-control\"\n [formControl]=\"inputConfirmationControl\"\n [placeholder]=\"inputConfirmationErrorMessage()\"\n (keyup.enter)=\"confirm()\"\n />\n\n @if (inputConfirmationControl.touched && inputConfirmationControl.invalid)\n {\n <p class=\"text-danger\">{{ inputConfirmationErrorMessage() }}</p>\n }\n </div>\n }\n\n <!-- Loading -->\n @if (data.loading)\n {\n <tcloud-ui-loading [loading]=\"true\" mode=\"inline\" />\n }\n\n <!-- Footer -->\n <div class=\"container-footer\">\n\n <!-- Cancelar -->\n <button\n class=\"tc-btn tc-btn-outline-primary\"\n [disabled]=\"disabled\"\n (click)=\"close()\">{{ data.buttonCancelText || ('dialogConfirmation.cancel' | i18nTranslate: 'Cancelar') }}\n </button>\n\n <!-- Confirmar -->\n <button\n class=\"tc-btn tc-btn-primary\"\n [disabled]=\"disabled\"\n (click)=\"confirm()\">{{ textConfirmation | titlecase }}\n </button>\n </div>\n</div>\n", styles: [".background-modal{position:fixed;z-index:3000;width:100%;height:100%;background-color:#00000080;top:0;left:0}.container-dialog{position:fixed;top:15%;left:calc(50% - 300px);width:500px;z-index:30001;border-radius:8px;padding:24px;box-sizing:border-box;display:grid;gap:24px;background-color:var(--c-neutral-50);color:var(--c-neutral-700);opacity:1;transition:opacity .3s ease-out,top .3s ease-out}.container-dialog .container-header{display:flex;justify-content:space-between;align-items:center}.container-dialog .container-header .tc-title{font-size:18px;font-weight:700}.container-dialog .container-header .container-close-button{width:40px;height:40px;border-radius:100%;cursor:pointer;display:flex;align-items:center;justify-content:center;font-size:18px;color:var(--c-neutral-600);border:1px solid var(--c-neutral-300)}.container-dialog .container-input-confirmation{display:grid;gap:8px}.container-dialog .container-footer{display:flex;justify-content:space-between;align-items:center;gap:16px}.container-dialog .container-footer button{width:100%}.container-dialog.dialog-hide{opacity:0;top:-38%}@starting-style{.container-dialog{opacity:0;top:-38%}}\n"] }]
|
|
10692
10480
|
}], propDecorators: { onKeydownHandler: [{
|
|
10693
10481
|
type: HostListener,
|
|
10694
10482
|
args: ['document:keydown.escape', ['$event']]
|
|
@@ -11643,12 +11431,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
11643
11431
|
args: ['subMenuEl', { static: true }]
|
|
11644
11432
|
}] } });
|
|
11645
11433
|
|
|
11646
|
-
var MultiLevelDropdownSize
|
|
11434
|
+
var MultiLevelDropdownSize;
|
|
11647
11435
|
(function (MultiLevelDropdownSize) {
|
|
11648
11436
|
MultiLevelDropdownSize["sm"] = "sm";
|
|
11649
11437
|
MultiLevelDropdownSize["md"] = "md";
|
|
11650
11438
|
MultiLevelDropdownSize["lg"] = "lg";
|
|
11651
|
-
})(MultiLevelDropdownSize
|
|
11439
|
+
})(MultiLevelDropdownSize || (MultiLevelDropdownSize = {}));
|
|
11652
11440
|
class TCloudUiDropdownMultiLevelComponent {
|
|
11653
11441
|
onDocumentClick(event) {
|
|
11654
11442
|
if (this.isOpen && !this.elementRef.nativeElement.contains(event.target)) {
|
|
@@ -11657,11 +11445,11 @@ class TCloudUiDropdownMultiLevelComponent {
|
|
|
11657
11445
|
}
|
|
11658
11446
|
constructor(elementRef) {
|
|
11659
11447
|
this.elementRef = elementRef;
|
|
11660
|
-
this.dropdownSize = MultiLevelDropdownSize
|
|
11448
|
+
this.dropdownSize = MultiLevelDropdownSize;
|
|
11661
11449
|
this.menu = input.required(...(ngDevMode ? [{ debugName: "menu" }] : /* istanbul ignore next */ []));
|
|
11662
11450
|
this.subMenuPosition = input('right', ...(ngDevMode ? [{ debugName: "subMenuPosition" }] : /* istanbul ignore next */ []));
|
|
11663
11451
|
this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
|
|
11664
|
-
this.size = input(MultiLevelDropdownSize
|
|
11452
|
+
this.size = input(MultiLevelDropdownSize.sm, ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
11665
11453
|
this.maxHeight = input(320, ...(ngDevMode ? [{ debugName: "maxHeight" }] : /* istanbul ignore next */ [])); // Altura máxima (px) do menu/submenus; ativa scroll ao exceder
|
|
11666
11454
|
this.initialValue = input(null, ...(ngDevMode ? [{ debugName: "initialValue" }] : /* istanbul ignore next */ [])); // Valor pré-selecionado
|
|
11667
11455
|
this.optionSelected = output();
|
|
@@ -11786,1707 +11574,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
11786
11574
|
}]
|
|
11787
11575
|
}], ctorParameters: () => [] });
|
|
11788
11576
|
|
|
11789
|
-
class TcRevCalendarComponent {
|
|
11790
|
-
constructor() {
|
|
11791
|
-
this.appointments = []; // Updated to use the new type
|
|
11792
|
-
/** Active date format
|
|
11793
|
-
* @format YYYY-MM-DD
|
|
11794
|
-
* @example 2023-10-01
|
|
11795
|
-
*/
|
|
11796
|
-
this.activeDate = input(...(ngDevMode ? [undefined, { debugName: "activeDate" }] : /* istanbul ignore next */ []));
|
|
11797
|
-
this.innerActiveDate = computed(() => {
|
|
11798
|
-
if (!this.activeDate())
|
|
11799
|
-
return '';
|
|
11800
|
-
const date = new Date(`${this.activeDate()} 00:00:00`);
|
|
11801
|
-
return date;
|
|
11802
|
-
}, ...(ngDevMode ? [{ debugName: "innerActiveDate" }] : /* istanbul ignore next */ []));
|
|
11803
|
-
this.onSelectDate = output();
|
|
11804
|
-
this.currentDate = new Date();
|
|
11805
|
-
this.viewMode = 'days';
|
|
11806
|
-
this.yearOffset = 0; // Offset for year navigation
|
|
11807
|
-
}
|
|
11808
|
-
ngOnInit() {
|
|
11809
|
-
this.updateMonth();
|
|
11810
|
-
this.updateYear();
|
|
11811
|
-
this.updateDaysOfWeek();
|
|
11812
|
-
this.updateCalendarDays();
|
|
11813
|
-
this.updateCalendarMonths();
|
|
11814
|
-
this.updateCalendarYears();
|
|
11815
|
-
}
|
|
11816
|
-
// Methods to update fixed properties
|
|
11817
|
-
updateMonth() {
|
|
11818
|
-
this.month = this.currentDate.toLocaleString('default', { month: 'long' });
|
|
11819
|
-
}
|
|
11820
|
-
updateYear() {
|
|
11821
|
-
this.year = this.currentDate.getFullYear();
|
|
11822
|
-
}
|
|
11823
|
-
updateDaysOfWeek() {
|
|
11824
|
-
this.daysOfWeek = ['D', 'S', 'T', 'Q', 'Q', 'S', 'S'];
|
|
11825
|
-
}
|
|
11826
|
-
updateCalendarDays() {
|
|
11827
|
-
const year = this.currentDate.getFullYear();
|
|
11828
|
-
const month = this.currentDate.getMonth();
|
|
11829
|
-
const firstDayOfMonth = new Date(year, month, 1);
|
|
11830
|
-
const lastDayOfMonth = new Date(year, month + 1, 0);
|
|
11831
|
-
const daysInLastMonth = firstDayOfMonth.getDay();
|
|
11832
|
-
const daysInCurrentMonth = lastDayOfMonth.getDate();
|
|
11833
|
-
const calendarDays = [];
|
|
11834
|
-
// Add last days of the previous month
|
|
11835
|
-
for (let i = daysInLastMonth - 1; i >= 0; i--) {
|
|
11836
|
-
const date = new Date(year, month, -i);
|
|
11837
|
-
calendarDays.push({ date, isCurrentMonth: false });
|
|
11838
|
-
}
|
|
11839
|
-
// Add all days of the current month
|
|
11840
|
-
for (let i = 1; i <= daysInCurrentMonth; i++) {
|
|
11841
|
-
const date = new Date(year, month, i);
|
|
11842
|
-
calendarDays.push({ date, isCurrentMonth: true });
|
|
11843
|
-
}
|
|
11844
|
-
// Add first days of the next month
|
|
11845
|
-
const remainingDays = 35 - calendarDays.length;
|
|
11846
|
-
for (let i = 1; i <= remainingDays; i++) {
|
|
11847
|
-
const date = new Date(year, month + 1, i);
|
|
11848
|
-
calendarDays.push({ date, isCurrentMonth: false });
|
|
11849
|
-
}
|
|
11850
|
-
this.calendarDays = calendarDays;
|
|
11851
|
-
console.log('calendarDays', this.calendarDays[16].date);
|
|
11852
|
-
}
|
|
11853
|
-
updateCalendarMonths() {
|
|
11854
|
-
this.calendarMonths = Array.from({ length: 12 }, (_, i) => new Date(this.year, i).toLocaleString('default', { month: 'long' }));
|
|
11855
|
-
}
|
|
11856
|
-
updateCalendarYears() {
|
|
11857
|
-
const startYear = this.year - 5 + this.yearOffset * 12;
|
|
11858
|
-
this.calendarYears = Array.from({ length: 12 }, (_, i) => startYear + i);
|
|
11859
|
-
}
|
|
11860
|
-
// Existing methods updated to call the update methods
|
|
11861
|
-
changeMonth(offset) {
|
|
11862
|
-
this.currentDate = new Date(this.currentDate.getFullYear(), this.currentDate.getMonth() + offset, 1);
|
|
11863
|
-
this.updateMonth();
|
|
11864
|
-
this.updateYear();
|
|
11865
|
-
this.updateCalendarDays();
|
|
11866
|
-
}
|
|
11867
|
-
selectMonth(monthIndex) {
|
|
11868
|
-
this.currentDate = new Date(this.year, monthIndex, 1);
|
|
11869
|
-
this.viewMode = 'days';
|
|
11870
|
-
this.updateMonth();
|
|
11871
|
-
this.updateCalendarDays();
|
|
11872
|
-
}
|
|
11873
|
-
changeYearOffset(offset) {
|
|
11874
|
-
if (this.viewMode === 'months') {
|
|
11875
|
-
// Adjust the current date by adding or subtracting a year
|
|
11876
|
-
this.currentDate = new Date(this.currentDate.getFullYear() + offset, this.currentDate.getMonth(), 1);
|
|
11877
|
-
this.updateYear();
|
|
11878
|
-
this.updateCalendarMonths();
|
|
11879
|
-
}
|
|
11880
|
-
else if (this.viewMode === 'years') {
|
|
11881
|
-
// Adjust the year offset for the year view
|
|
11882
|
-
this.yearOffset += offset;
|
|
11883
|
-
this.updateCalendarYears();
|
|
11884
|
-
}
|
|
11885
|
-
}
|
|
11886
|
-
selectYear(year) {
|
|
11887
|
-
this.currentDate = new Date(year, this.currentDate.getMonth(), 1);
|
|
11888
|
-
this.viewMode = 'months';
|
|
11889
|
-
this.updateYear();
|
|
11890
|
-
this.updateCalendarMonths();
|
|
11891
|
-
}
|
|
11892
|
-
toggleViewMode(mode) {
|
|
11893
|
-
this.viewMode = mode;
|
|
11894
|
-
if (mode === 'years') {
|
|
11895
|
-
this.yearOffset = 0; // Reset year offset when entering year view
|
|
11896
|
-
this.updateCalendarYears();
|
|
11897
|
-
}
|
|
11898
|
-
}
|
|
11899
|
-
isAppointment(date) {
|
|
11900
|
-
const dateString = date.toISOString().split('T')[0];
|
|
11901
|
-
return this.appointments.find(appointment => appointment.appointmentDate === dateString);
|
|
11902
|
-
}
|
|
11903
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevCalendarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
11904
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevCalendarComponent, isStandalone: true, selector: "tc-rev-calendar", inputs: { appointments: { classPropertyName: "appointments", publicName: "appointments", isSignal: false, isRequired: false, transformFunction: null }, activeDate: { classPropertyName: "activeDate", publicName: "activeDate", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onSelectDate: "onSelectDate" }, ngImport: i0, template: "<div class=\"tc-rev-calendar\">\n <div class=\"calendar-header\">\n @if (viewMode === 'days') {\n <button class=\"prev-btn mar-r-a\" (click)=\"changeMonth(-1)\"><i class=\"fa-light fa-chevron-left\"></i></button>\n }\n @if (viewMode === 'months' || viewMode === 'years') {\n <button class=\"prev-btn mar-r-a\" (click)=\"changeYearOffset(-1)\"><i class=\"fa-light fa-chevron-left\"></i></button>\n }\n @if (viewMode === 'days')\n {\n <span class=\"calendar-title date\" (click)=\"toggleViewMode('months')\">{{ month }} - </span>\n <span class=\"calendar-title date\" (click)=\"toggleViewMode('years')\">{{ year }}</span>\n }\n @else if (viewMode === 'months')\n {\n <span class=\"calendar-title\">Selecione o m\u00EAs</span>\n }\n @else if (viewMode === 'years')\n {\n <span class=\"calendar-title\">Selecione o ano</span>\n}\n@if (viewMode === 'months' || viewMode === 'years') {\n <button class=\"next-btn mar-l-a\" (click)=\"changeYearOffset(1)\"><i class=\"fa-light fa-chevron-right\"></i></button>\n}\n@if (viewMode === 'days') {\n <button class=\"next-btn mar-l-a\" (click)=\"changeMonth(1)\"><i class=\"fa-light fa-chevron-right\"></i></button>\n}\n</div>\n\n@if (viewMode === 'days') {\n <div class=\"calendar-grid\">\n @for (day of daysOfWeek; track $index) {\n <div class=\"day-header\">{{ day }}</div>\n }\n @for (day of calendarDays; track day) {\n <button\n class=\"day\"\n [class.selected]=\"day.date.valueOf() === innerActiveDate().valueOf()\"\n [class.current-month]=\"day.isCurrentMonth\"\n [title]=\"isAppointment(day.date)?.description ? isAppointment(day.date)?.description : ''\"\n (click)=\"onSelectDate.emit(day.date)\"\n >\n @if (isAppointment(day.date)) {\n <span\n class=\"appointment-dot\"\n [ngClass]=\"'appointment-'+ isAppointment(day.date)?.type\"\n ></span>\n }\n {{ day.date.getDate() }}\n </button>\n }\n </div>\n}\n\n@if (viewMode === 'months') {\n <div class=\"calendar-grid months\">\n @for (month of calendarMonths; track month; let i = $index) {\n <div\n class=\"month\"\n (click)=\"selectMonth(i)\"\n >\n {{ month }}\n </div>\n }\n </div>\n}\n\n@if (viewMode === 'years') {\n <div class=\"calendar-grid years\">\n @for (year of calendarYears; track year) {\n <div\n class=\"year\"\n (click)=\"selectYear(year)\"\n >\n {{ year }}\n </div>\n }\n </div>\n}\n</div>", styles: [":host{display:block}.tc-rev-calendar{background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-300);border-radius:var(--bor-radius-16);color:var(--c-neutral-700);font-family:var(--f-family);min-height:274px;min-width:16.125rem;padding:var(--size-16)}.tc-rev-calendar .calendar-header{align-items:center;display:flex;justify-content:space-between;margin-bottom:var(--size-16)}.tc-rev-calendar .calendar-header .prev-btn,.tc-rev-calendar .calendar-header .next-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-500);border-radius:var(--bor-radius-rounded);color:inherit;cursor:pointer;display:flex;justify-content:center;font-size:var(--f-size-14);height:var(--size-32);width:var(--size-32)}.tc-rev-calendar .calendar-header .calendar-title{cursor:default;font-size:var(--f-size-14);line-height:var(--l-height-20)}.tc-rev-calendar .calendar-header .calendar-title.date{cursor:pointer;text-transform:capitalize}.tc-rev-calendar .calendar-grid{display:grid;grid-template-columns:repeat(7,1fr);justify-items:center}.tc-rev-calendar .calendar-grid.months{grid-template-columns:repeat(3,1fr);row-gap:10px}.tc-rev-calendar .calendar-grid.years{grid-template-columns:repeat(4,1fr);row-gap:10px}.tc-rev-calendar .day-header{cursor:default;font-size:var(--f-size-12);font-weight:var(--f-weight-700);line-height:var(--l-height-16);text-align:center;align-content:center;height:var(--size-32);width:var(--size-32)}.tc-rev-calendar .day{align-content:center;border-radius:var(--bor-radius-rounded);background:transparent;border:none;color:inherit;padding:0;cursor:default;font-size:var(--f-size-12);line-height:var(--l-height-16);position:relative;height:var(--size-32);text-align:center;transition:.1s ease;width:var(--size-32)}.tc-rev-calendar .day:hover,.tc-rev-calendar .day:focus{background-color:var(--c-neutral-100);color:var(--c-primary-500)}.tc-rev-calendar .day:active,.tc-rev-calendar .day.selected{background-color:var(--c-primary-300);color:var(--c-primary-500)}.tc-rev-calendar .day .appointment-dot{width:6px;height:6px;border-radius:50%;position:absolute;top:5px;right:5px}.tc-rev-calendar .day .appointment-dot.appointment-info{background-color:var(--c-info-500)}.tc-rev-calendar .day .appointment-dot.appointment-alert{background-color:var(--c-alert-500)}.tc-rev-calendar .day .appointment-dot.appointment-danger{background-color:var(--c-danger-500)}.tc-rev-calendar .day .appointment-dot.appointment-success{background-color:var(--c-success-500)}.tc-rev-calendar .month,.tc-rev-calendar .year{align-content:center;border:none;border-radius:var(--bor-radius-4);cursor:pointer;height:var(--size-32);text-align:center;text-transform:capitalize;transition:.1s ease;width:100%}.tc-rev-calendar .month:hover,.tc-rev-calendar .month:focus,.tc-rev-calendar .year:hover,.tc-rev-calendar .year:focus{background-color:var(--c-neutral-100);color:var(--c-primary-500)}.tc-rev-calendar .month:active,.tc-rev-calendar .year:active{background-color:var(--c-primary-300);color:var(--c-primary-500)}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] }); }
|
|
11905
|
-
}
|
|
11906
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevCalendarComponent, decorators: [{
|
|
11907
|
-
type: Component,
|
|
11908
|
-
args: [{ selector: 'tc-rev-calendar', imports: [
|
|
11909
|
-
CommonModule,
|
|
11910
|
-
], template: "<div class=\"tc-rev-calendar\">\n <div class=\"calendar-header\">\n @if (viewMode === 'days') {\n <button class=\"prev-btn mar-r-a\" (click)=\"changeMonth(-1)\"><i class=\"fa-light fa-chevron-left\"></i></button>\n }\n @if (viewMode === 'months' || viewMode === 'years') {\n <button class=\"prev-btn mar-r-a\" (click)=\"changeYearOffset(-1)\"><i class=\"fa-light fa-chevron-left\"></i></button>\n }\n @if (viewMode === 'days')\n {\n <span class=\"calendar-title date\" (click)=\"toggleViewMode('months')\">{{ month }} - </span>\n <span class=\"calendar-title date\" (click)=\"toggleViewMode('years')\">{{ year }}</span>\n }\n @else if (viewMode === 'months')\n {\n <span class=\"calendar-title\">Selecione o m\u00EAs</span>\n }\n @else if (viewMode === 'years')\n {\n <span class=\"calendar-title\">Selecione o ano</span>\n}\n@if (viewMode === 'months' || viewMode === 'years') {\n <button class=\"next-btn mar-l-a\" (click)=\"changeYearOffset(1)\"><i class=\"fa-light fa-chevron-right\"></i></button>\n}\n@if (viewMode === 'days') {\n <button class=\"next-btn mar-l-a\" (click)=\"changeMonth(1)\"><i class=\"fa-light fa-chevron-right\"></i></button>\n}\n</div>\n\n@if (viewMode === 'days') {\n <div class=\"calendar-grid\">\n @for (day of daysOfWeek; track $index) {\n <div class=\"day-header\">{{ day }}</div>\n }\n @for (day of calendarDays; track day) {\n <button\n class=\"day\"\n [class.selected]=\"day.date.valueOf() === innerActiveDate().valueOf()\"\n [class.current-month]=\"day.isCurrentMonth\"\n [title]=\"isAppointment(day.date)?.description ? isAppointment(day.date)?.description : ''\"\n (click)=\"onSelectDate.emit(day.date)\"\n >\n @if (isAppointment(day.date)) {\n <span\n class=\"appointment-dot\"\n [ngClass]=\"'appointment-'+ isAppointment(day.date)?.type\"\n ></span>\n }\n {{ day.date.getDate() }}\n </button>\n }\n </div>\n}\n\n@if (viewMode === 'months') {\n <div class=\"calendar-grid months\">\n @for (month of calendarMonths; track month; let i = $index) {\n <div\n class=\"month\"\n (click)=\"selectMonth(i)\"\n >\n {{ month }}\n </div>\n }\n </div>\n}\n\n@if (viewMode === 'years') {\n <div class=\"calendar-grid years\">\n @for (year of calendarYears; track year) {\n <div\n class=\"year\"\n (click)=\"selectYear(year)\"\n >\n {{ year }}\n </div>\n }\n </div>\n}\n</div>", styles: [":host{display:block}.tc-rev-calendar{background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-300);border-radius:var(--bor-radius-16);color:var(--c-neutral-700);font-family:var(--f-family);min-height:274px;min-width:16.125rem;padding:var(--size-16)}.tc-rev-calendar .calendar-header{align-items:center;display:flex;justify-content:space-between;margin-bottom:var(--size-16)}.tc-rev-calendar .calendar-header .prev-btn,.tc-rev-calendar .calendar-header .next-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-500);border-radius:var(--bor-radius-rounded);color:inherit;cursor:pointer;display:flex;justify-content:center;font-size:var(--f-size-14);height:var(--size-32);width:var(--size-32)}.tc-rev-calendar .calendar-header .calendar-title{cursor:default;font-size:var(--f-size-14);line-height:var(--l-height-20)}.tc-rev-calendar .calendar-header .calendar-title.date{cursor:pointer;text-transform:capitalize}.tc-rev-calendar .calendar-grid{display:grid;grid-template-columns:repeat(7,1fr);justify-items:center}.tc-rev-calendar .calendar-grid.months{grid-template-columns:repeat(3,1fr);row-gap:10px}.tc-rev-calendar .calendar-grid.years{grid-template-columns:repeat(4,1fr);row-gap:10px}.tc-rev-calendar .day-header{cursor:default;font-size:var(--f-size-12);font-weight:var(--f-weight-700);line-height:var(--l-height-16);text-align:center;align-content:center;height:var(--size-32);width:var(--size-32)}.tc-rev-calendar .day{align-content:center;border-radius:var(--bor-radius-rounded);background:transparent;border:none;color:inherit;padding:0;cursor:default;font-size:var(--f-size-12);line-height:var(--l-height-16);position:relative;height:var(--size-32);text-align:center;transition:.1s ease;width:var(--size-32)}.tc-rev-calendar .day:hover,.tc-rev-calendar .day:focus{background-color:var(--c-neutral-100);color:var(--c-primary-500)}.tc-rev-calendar .day:active,.tc-rev-calendar .day.selected{background-color:var(--c-primary-300);color:var(--c-primary-500)}.tc-rev-calendar .day .appointment-dot{width:6px;height:6px;border-radius:50%;position:absolute;top:5px;right:5px}.tc-rev-calendar .day .appointment-dot.appointment-info{background-color:var(--c-info-500)}.tc-rev-calendar .day .appointment-dot.appointment-alert{background-color:var(--c-alert-500)}.tc-rev-calendar .day .appointment-dot.appointment-danger{background-color:var(--c-danger-500)}.tc-rev-calendar .day .appointment-dot.appointment-success{background-color:var(--c-success-500)}.tc-rev-calendar .month,.tc-rev-calendar .year{align-content:center;border:none;border-radius:var(--bor-radius-4);cursor:pointer;height:var(--size-32);text-align:center;text-transform:capitalize;transition:.1s ease;width:100%}.tc-rev-calendar .month:hover,.tc-rev-calendar .month:focus,.tc-rev-calendar .year:hover,.tc-rev-calendar .year:focus{background-color:var(--c-neutral-100);color:var(--c-primary-500)}.tc-rev-calendar .month:active,.tc-rev-calendar .year:active{background-color:var(--c-primary-300);color:var(--c-primary-500)}\n"] }]
|
|
11911
|
-
}], propDecorators: { appointments: [{
|
|
11912
|
-
type: Input
|
|
11913
|
-
}], activeDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "activeDate", required: false }] }], onSelectDate: [{ type: i0.Output, args: ["onSelectDate"] }] } });
|
|
11914
|
-
|
|
11915
|
-
class TcRevCardAccordionComponent {
|
|
11916
|
-
constructor() {
|
|
11917
|
-
this._viewPort = inject(TCloudUiDeviceUtilsService);
|
|
11918
|
-
this.toggle = output();
|
|
11919
|
-
this.title = input('', ...(ngDevMode ? [{ debugName: "title" }] : /* istanbul ignore next */ []));
|
|
11920
|
-
this.iconClass = input('fa-light fa-hard-drive', ...(ngDevMode ? [{ debugName: "iconClass" }] : /* istanbul ignore next */ []));
|
|
11921
|
-
this.showMoreText = input('Exibir mais', ...(ngDevMode ? [{ debugName: "showMoreText" }] : /* istanbul ignore next */ []));
|
|
11922
|
-
this.showLessText = input('Exibir menos', ...(ngDevMode ? [{ debugName: "showLessText" }] : /* istanbul ignore next */ []));
|
|
11923
|
-
this.badge = input(null, ...(ngDevMode ? [{ debugName: "badge" }] : /* istanbul ignore next */ []));
|
|
11924
|
-
this.isOpen = model(...(ngDevMode ? [undefined, { debugName: "isOpen" }] : /* istanbul ignore next */ []));
|
|
11925
|
-
this.isDesktop = this._viewPort.isDesktop;
|
|
11926
|
-
}
|
|
11927
|
-
toggleAccordion() {
|
|
11928
|
-
this.isOpen.update((current) => !current);
|
|
11929
|
-
this.toggle.emit(this.isOpen());
|
|
11930
|
-
}
|
|
11931
|
-
/**
|
|
11932
|
-
* APPLY FUNCTIONS RESPONSIVE < 500PX
|
|
11933
|
-
*/
|
|
11934
|
-
get accordionExtraClasses() {
|
|
11935
|
-
if (this.isDesktop()) {
|
|
11936
|
-
return ['pad-16'];
|
|
11937
|
-
}
|
|
11938
|
-
//Responsive Classes
|
|
11939
|
-
return ['pad-14'];
|
|
11940
|
-
}
|
|
11941
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevCardAccordionComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
11942
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevCardAccordionComponent, isStandalone: true, selector: "tc-rev-card-accordion", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, iconClass: { classPropertyName: "iconClass", publicName: "iconClass", isSignal: true, isRequired: false, transformFunction: null }, showMoreText: { classPropertyName: "showMoreText", publicName: "showMoreText", isSignal: true, isRequired: false, transformFunction: null }, showLessText: { classPropertyName: "showLessText", publicName: "showLessText", isSignal: true, isRequired: false, transformFunction: null }, badge: { classPropertyName: "badge", publicName: "badge", isSignal: true, isRequired: false, transformFunction: null }, isOpen: { classPropertyName: "isOpen", publicName: "isOpen", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { toggle: "toggle", isOpen: "isOpenChange" }, ngImport: i0, template: "<div class=\"tc-rev-card-accordion tc-rev-card bg-c-neutral-50 bor-xs bor-rad-16\"\n [ngClass]=\"accordionExtraClasses\"\n >\n <tc-rev-card-title [title]=\"title()\" [class]=\"isOpen() ? 'pad-b-16' : '' \">\n <i [class]=\"iconClass()\" icon></i>\n\n @if (badge()) {\n <div\n class=\"f-size-12 f-weight-600 pad-x-4 pad-y-2 bor-xs bor-rad-xs\"\n [ngClass]=\"badge()?.class\"\n [class.mar-l-8]=\"isDesktop()\"\n >\n {{ badge()?.text }}\n </div>\n }\n\n @if(isDesktop()){\n <button tcRevButton=\"outline\" color=\"dark\" size=\"sm\" class=\"mar-l-a\" (click)=\"toggleAccordion()\">\n {{ isOpen() ? showLessText() : showMoreText() }}\n <i class=\"fa-light\" [ngClass]=\"isOpen() ? 'fa-chevron-up' : 'fa-chevron-down'\"></i>\n </button>\n }\n\n @if(!isDesktop()){\n <button tcRevButton=\"link\" color=\"dark\" size=\"md\" (click)=\"toggleAccordion()\" class=\"tc-rev-card-accordion__arrow-mobile mar-l-a\">\n <i class=\"fa-light\" [ngClass]=\"isOpen() ? 'fa-chevron-up' : 'fa-chevron-down'\"></i>\n </button>\n }\n\n </tc-rev-card-title>\n @if (isOpen()) {\n <ng-content></ng-content>\n }\n</div>\n", styles: [":host{display:block}.tc-rev-card-accordion{border-color:var(--c-neutral-400)}@media(max-width:480px){.tc-rev-card-accordion__arrow-mobile{font-size:var(--f-size-16);padding:0 var(--size-6)}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: TcRevCardTitleComponent, selector: "tc-rev-card-title", inputs: ["title"] }, { kind: "directive", type: TcRevButtonDirective, selector: "button[tcRevButton]", inputs: ["color", "size", "fullWidth", "tcRevButton"] }] }); }
|
|
11943
|
-
}
|
|
11944
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevCardAccordionComponent, decorators: [{
|
|
11945
|
-
type: Component,
|
|
11946
|
-
args: [{ selector: 'tc-rev-card-accordion', imports: [CommonModule, TcRevCardTitleComponent, TcRevButtonDirective], template: "<div class=\"tc-rev-card-accordion tc-rev-card bg-c-neutral-50 bor-xs bor-rad-16\"\n [ngClass]=\"accordionExtraClasses\"\n >\n <tc-rev-card-title [title]=\"title()\" [class]=\"isOpen() ? 'pad-b-16' : '' \">\n <i [class]=\"iconClass()\" icon></i>\n\n @if (badge()) {\n <div\n class=\"f-size-12 f-weight-600 pad-x-4 pad-y-2 bor-xs bor-rad-xs\"\n [ngClass]=\"badge()?.class\"\n [class.mar-l-8]=\"isDesktop()\"\n >\n {{ badge()?.text }}\n </div>\n }\n\n @if(isDesktop()){\n <button tcRevButton=\"outline\" color=\"dark\" size=\"sm\" class=\"mar-l-a\" (click)=\"toggleAccordion()\">\n {{ isOpen() ? showLessText() : showMoreText() }}\n <i class=\"fa-light\" [ngClass]=\"isOpen() ? 'fa-chevron-up' : 'fa-chevron-down'\"></i>\n </button>\n }\n\n @if(!isDesktop()){\n <button tcRevButton=\"link\" color=\"dark\" size=\"md\" (click)=\"toggleAccordion()\" class=\"tc-rev-card-accordion__arrow-mobile mar-l-a\">\n <i class=\"fa-light\" [ngClass]=\"isOpen() ? 'fa-chevron-up' : 'fa-chevron-down'\"></i>\n </button>\n }\n\n </tc-rev-card-title>\n @if (isOpen()) {\n <ng-content></ng-content>\n }\n</div>\n", styles: [":host{display:block}.tc-rev-card-accordion{border-color:var(--c-neutral-400)}@media(max-width:480px){.tc-rev-card-accordion__arrow-mobile{font-size:var(--f-size-16);padding:0 var(--size-6)}}\n"] }]
|
|
11947
|
-
}], propDecorators: { toggle: [{ type: i0.Output, args: ["toggle"] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], iconClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconClass", required: false }] }], showMoreText: [{ type: i0.Input, args: [{ isSignal: true, alias: "showMoreText", required: false }] }], showLessText: [{ type: i0.Input, args: [{ isSignal: true, alias: "showLessText", required: false }] }], badge: [{ type: i0.Input, args: [{ isSignal: true, alias: "badge", required: false }] }], isOpen: [{ type: i0.Input, args: [{ isSignal: true, alias: "isOpen", required: false }] }, { type: i0.Output, args: ["isOpenChange"] }] } });
|
|
11948
|
-
|
|
11949
|
-
class TcRevCardComponent {
|
|
11950
|
-
constructor() {
|
|
11951
|
-
this._viewPort = inject(TCloudUiDeviceUtilsService);
|
|
11952
|
-
this.isDesktop = this._viewPort.isDesktop;
|
|
11953
|
-
}
|
|
11954
|
-
/**
|
|
11955
|
-
* APPLY FUNCTIONS RESPONSIVE < 480PX
|
|
11956
|
-
*/
|
|
11957
|
-
get extraClasses() {
|
|
11958
|
-
if (this.isDesktop()) {
|
|
11959
|
-
return ['shadow-md', 'pad-16'];
|
|
11960
|
-
}
|
|
11961
|
-
//Responsive Classes
|
|
11962
|
-
return ['shadow-sm', 'pad-14'];
|
|
11963
|
-
}
|
|
11964
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevCardComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
11965
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.17", type: TcRevCardComponent, isStandalone: true, selector: "tc-rev-card", ngImport: i0, template: "<div class=\"tc-rev-card bg-c-neutral-50 bor-rad-16\"\n[ngClass]=\"extraClasses\"\n>\n <ng-content></ng-content>\n</div>", styles: [":host{display:block}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] }); }
|
|
11966
|
-
}
|
|
11967
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevCardComponent, decorators: [{
|
|
11968
|
-
type: Component,
|
|
11969
|
-
args: [{ selector: 'tc-rev-card', imports: [CommonModule], template: "<div class=\"tc-rev-card bg-c-neutral-50 bor-rad-16\"\n[ngClass]=\"extraClasses\"\n>\n <ng-content></ng-content>\n</div>", styles: [":host{display:block}\n"] }]
|
|
11970
|
-
}] });
|
|
11971
|
-
|
|
11972
|
-
class TcRevCheckboxDirective {
|
|
11973
|
-
constructor() { }
|
|
11974
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevCheckboxDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
11975
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.17", type: TcRevCheckboxDirective, isStandalone: true, selector: "input[type=\"checkbox\"][tcRevCheckbox]", host: { classAttribute: "tc-rev-checkbox" }, ngImport: i0 }); }
|
|
11976
|
-
}
|
|
11977
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevCheckboxDirective, decorators: [{
|
|
11978
|
-
type: Directive,
|
|
11979
|
-
args: [{
|
|
11980
|
-
selector: 'input[type="checkbox"][tcRevCheckbox]',
|
|
11981
|
-
host: {
|
|
11982
|
-
class: 'tc-rev-checkbox'
|
|
11983
|
-
}
|
|
11984
|
-
}]
|
|
11985
|
-
}], ctorParameters: () => [] });
|
|
11986
|
-
|
|
11987
|
-
var DropdownSize;
|
|
11988
|
-
(function (DropdownSize) {
|
|
11989
|
-
DropdownSize["sm"] = "sm";
|
|
11990
|
-
DropdownSize["md"] = "md";
|
|
11991
|
-
DropdownSize["lg"] = "lg";
|
|
11992
|
-
})(DropdownSize || (DropdownSize = {}));
|
|
11993
|
-
class TcRevDropdownComponent {
|
|
11994
|
-
onDocumentClick(event) {
|
|
11995
|
-
if (this.isOpen && !this.elementRef.nativeElement.contains(event.target)) {
|
|
11996
|
-
this.isOpen = false;
|
|
11997
|
-
}
|
|
11998
|
-
}
|
|
11999
|
-
constructor(elementRef) {
|
|
12000
|
-
this.elementRef = elementRef;
|
|
12001
|
-
this._deviceService = inject(TCloudUiDeviceUtilsService);
|
|
12002
|
-
this.label = input('', ...(ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ [])); // Label que será exibida
|
|
12003
|
-
this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ [])); // Desabilita o dropdown
|
|
12004
|
-
this.options = input.required(...(ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ [])); // Lista de opções no novo formato
|
|
12005
|
-
this.initialValue = input(null, ...(ngDevMode ? [{ debugName: "initialValue" }] : /* istanbul ignore next */ [])); // Valor pré-selecionado (deprecated - use value instead)
|
|
12006
|
-
this.value = model(null, ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ [])); // Two-way binding para o valor selecionado
|
|
12007
|
-
this.size = input(DropdownSize.sm, ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
12008
|
-
this.width = input('', ...(ngDevMode ? [{ debugName: "width" }] : /* istanbul ignore next */ [])); // Largura específica do dropdown (ex: '300px', '50%'). Se não informado, ocupa 100% do pai
|
|
12009
|
-
this.optionSelected = output(); // Emissor para o valor selecionado
|
|
12010
|
-
this.selectedOption = signal(null, ...(ngDevMode ? [{ debugName: "selectedOption" }] : /* istanbul ignore next */ [])); // Opção selecionada
|
|
12011
|
-
this.isOpen = false; // Controla se o dropdown está aberto
|
|
12012
|
-
this.dropdownSize = DropdownSize;
|
|
12013
|
-
this.isDesktop = this._deviceService.isDesktop;
|
|
12014
|
-
this.isMobile = this._deviceService.isMobile;
|
|
12015
|
-
}
|
|
12016
|
-
ngOnChanges(_simpleChanges) {
|
|
12017
|
-
// Atualiza a opção selecionada quando o valor pré-selecionado muda
|
|
12018
|
-
if (_simpleChanges['initialValue'] ||
|
|
12019
|
-
_simpleChanges['options'] ||
|
|
12020
|
-
_simpleChanges['value']) {
|
|
12021
|
-
const valueToUse = this.value() || this.initialValue();
|
|
12022
|
-
this.selectedOption.set(this.options().find((option) => option.value === valueToUse) || null);
|
|
12023
|
-
}
|
|
12024
|
-
}
|
|
12025
|
-
ngOnInit() {
|
|
12026
|
-
// Prioriza o valor do model, mas mantém compatibilidade com initialValue
|
|
12027
|
-
const valueToUse = this.value() || this.initialValue();
|
|
12028
|
-
const foundOption = this.options().find((option) => option.value === valueToUse) || null;
|
|
12029
|
-
this.selectedOption.set(foundOption);
|
|
12030
|
-
// Se não havia valor no model mas havia initialValue, sincroniza o model
|
|
12031
|
-
if (!this.value() && this.initialValue() && foundOption) {
|
|
12032
|
-
this.value.set(foundOption.value);
|
|
12033
|
-
}
|
|
12034
|
-
// Escuta mudanças no model e atualiza a opção selecionada
|
|
12035
|
-
this.value.subscribe((newValue) => {
|
|
12036
|
-
const option = this.options().find((opt) => opt.value === newValue) || null;
|
|
12037
|
-
if (this.selectedOption() !== option) {
|
|
12038
|
-
this.selectedOption.set(option);
|
|
12039
|
-
}
|
|
12040
|
-
});
|
|
12041
|
-
}
|
|
12042
|
-
toggleDropdown() {
|
|
12043
|
-
// Abertura do dropdown para mobile
|
|
12044
|
-
if (this.isMobile()) {
|
|
12045
|
-
this._deviceService.openDropdownDevice(this.menuTemplate);
|
|
12046
|
-
return;
|
|
12047
|
-
}
|
|
12048
|
-
this.isOpen = !this.isOpen;
|
|
12049
|
-
}
|
|
12050
|
-
selectOption(option) {
|
|
12051
|
-
this.selectedOption.set(option);
|
|
12052
|
-
this.value.set(option.value); // Atualiza o model com two-way binding
|
|
12053
|
-
this.optionSelected.emit(option); // Emite a opção selecionada para compatibilidade
|
|
12054
|
-
// Fechamento dd dropdown para mobile
|
|
12055
|
-
if (this.isMobile()) {
|
|
12056
|
-
this._deviceService.closeDropdownDevice();
|
|
12057
|
-
return;
|
|
12058
|
-
}
|
|
12059
|
-
this.isOpen = false; // Fecha o dropdown
|
|
12060
|
-
}
|
|
12061
|
-
/**
|
|
12062
|
-
* Verifica se o texto de uma opção na lista está elipsado
|
|
12063
|
-
* @param text - Texto a ser verificado
|
|
12064
|
-
* @returns true se o texto estiver elipsado
|
|
12065
|
-
*/
|
|
12066
|
-
isOptionEllipsed(text) {
|
|
12067
|
-
if (!text)
|
|
12068
|
-
return false;
|
|
12069
|
-
// Calcula a largura disponível para o texto nas opções da lista
|
|
12070
|
-
const menuElement = this.elementRef.nativeElement.querySelector('.tc-rev-dropdown-menu');
|
|
12071
|
-
if (!menuElement) {
|
|
12072
|
-
// Se o menu não está aberto, usa a largura do dropdown
|
|
12073
|
-
const dropdownElement = this.elementRef.nativeElement.querySelector('.tc-rev-dropdown');
|
|
12074
|
-
if (!dropdownElement)
|
|
12075
|
-
return false;
|
|
12076
|
-
const dropdownWidth = dropdownElement.clientWidth;
|
|
12077
|
-
const padding = 16; // 8px de cada lado do botão
|
|
12078
|
-
const iconSpace = 24; // Espaço do ícone de check quando selecionado
|
|
12079
|
-
const availableWidth = Math.max(50, dropdownWidth - padding - iconSpace);
|
|
12080
|
-
return isTextEllipsed(text, availableWidth);
|
|
12081
|
-
}
|
|
12082
|
-
// Largura do menu menos padding do item (16px total) e espaço do ícone de check (24px)
|
|
12083
|
-
const menuWidth = menuElement.clientWidth;
|
|
12084
|
-
const padding = 16; // 8px de cada lado do botão do item
|
|
12085
|
-
const iconSpace = 24; // Espaço do ícone de check quando selecionado
|
|
12086
|
-
const availableWidth = Math.max(50, menuWidth - padding - iconSpace);
|
|
12087
|
-
return isTextEllipsed(text, availableWidth);
|
|
12088
|
-
}
|
|
12089
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevDropdownComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12090
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevDropdownComponent, isStandalone: true, selector: "tc-rev-dropdown", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: true, transformFunction: null }, initialValue: { classPropertyName: "initialValue", publicName: "initialValue", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange", optionSelected: "optionSelected" }, host: { listeners: { "document:click": "onDocumentClick($event)" } }, viewQueries: [{ propertyName: "menuTemplate", first: true, predicate: ["menuTemplate"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div\n class=\"tc-rev-dropdown\"\n [class.disabled]=\"disabled()\"\n [style.width]=\"this.width()\"\n >\n <button\n class=\"tc-rev-dropdown-toggle\"\n [class.tc-rev-dropdown-toggle--sm]=\"this.size() === dropdownSize.sm\"\n [class.tc-rev-dropdown-toggle--md]=\"this.size() === dropdownSize.md\"\n [class.tc-rev-dropdown-toggle--lg]=\"this.size() === dropdownSize.lg\"\n (click)=\"toggleDropdown()\"\n [class.disabled]=\"disabled()\"\n [disabled]=\"disabled()\"\n >\n @if (label()) {\n <b>{{ label() }}</b>\n }\n <span class=\"tc-rev-dropdown-selected-text\">\n {{ selectedOption() ? selectedOption()?.displayValue : \"Selecione\" }}\n </span>\n <i class=\"fa-light fa-chevron-down mar-l-a\"></i>\n </button>\n @if (isOpen && isDesktop()) {\n <ul class=\"tc-rev-dropdown-menu\">\n @for (option of options(); track option?.value) {\n <li class=\"tc-rev-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tc-rev-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n <span\n class=\"tc-rev-dropdown-option-text\"\n [class.ellipsed]=\"isOptionEllipsed(option.displayValue)\"\n [tcRevTooltip]=\"\n isOptionEllipsed(option.displayValue) ? option.displayValue : ''\n \"\n position=\"top\"\n >\n {{ option?.displayValue }}\n </span>\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check\"></i>\n }\n </button>\n </li>\n }\n </ul>\n }\n\n <!-- Dropdown full screen -->\n <ng-template #menuTemplate>\n <div class=\"tc-rev-dropdown-menu tc-rev-dropdown-menu--device\">\n <div class=\"tc-rev-dropdown-menu-section\">\n <div class=\"tc-rev-dropdown-menu-header pad-b-24\">\n <h3 class=\"mar-none f-h2 f-weight-600 c-neutral-600\">\n {{ label() }}\n </h3>\n <button\n tcRevIconButton=\"outline\"\n color=\"dark\"\n size=\"sm\"\n (click)=\"_deviceService.closeDropdownDevice()\"\n >\n <i class=\"fa-light fa-times f-size-16\"></i>\n </button>\n </div>\n <ul class=\"tc-rev-dropdown-menu-container mar-t-8\">\n @for (option of options(); track option?.value) {\n <li class=\"tc-rev-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tc-rev-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n {{ option?.displayValue }}\n\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check f-size-16\"></i>\n }\n </button>\n </li>\n }\n </ul>\n </div>\n </div>\n </ng-template>\n</div>\n", styles: [".tc-rev-dropdown{position:relative;display:block;width:100%}.tc-rev-dropdown .tc-rev-dropdown-toggle{align-items:center;background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-400);border-radius:var(--bor-radius-pill);color:var(--c-neutral-700);cursor:pointer;display:inline-flex;font-family:var(--f-family);font-size:var(--f-size-12);gap:var(--size-8);line-height:var(--l-height-16);outline:none;transition:.2s ease;padding:0 var(--size-12) 0 var(--size-16);width:100%}.tc-rev-dropdown .tc-rev-dropdown-toggle .tc-rev-dropdown-selected-text{flex:1;overflow:hidden;text-align:left;text-overflow:ellipsis;white-space:nowrap}.tc-rev-dropdown .tc-rev-dropdown-toggle i{align-items:center;display:inline-flex;flex-shrink:0;height:var(--size-24);justify-content:center;line-height:1;width:var(--size-24)}.tc-rev-dropdown .tc-rev-dropdown-toggle--sm{height:var(--size-40)}.tc-rev-dropdown .tc-rev-dropdown-toggle--md{height:var(--size-44)}.tc-rev-dropdown .tc-rev-dropdown-toggle--lg{height:var(--size-48)}.tc-rev-dropdown .tc-rev-dropdown-toggle:hover,.tc-rev-dropdown .tc-rev-dropdown-toggle:focus{border-color:var(--c-primary-500)}.tc-rev-dropdown .tc-rev-dropdown-toggle:disabled{border-color:var(--c-neutral-300);color:var(--c-neutral-300);cursor:not-allowed}.tc-rev-dropdown .tc-rev-dropdown-menu{box-shadow:var(--shadow-md);position:absolute;top:110%;left:0;background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);list-style:none;margin:0;max-height:15.625rem;overflow-y:auto;padding:0;width:100%;z-index:1000}.tc-rev-dropdown .tc-rev-dropdown-menu .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-700);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-12);line-height:var(--l-height-16);height:var(--size-32);padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.tc-rev-dropdown .tc-rev-dropdown-menu .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn .tc-rev-dropdown-option-text{flex:1;overflow:hidden;text-align:left;white-space:nowrap}.tc-rev-dropdown .tc-rev-dropdown-menu .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn .tc-rev-dropdown-option-text.ellipsed{text-overflow:ellipsis}.tc-rev-dropdown .tc-rev-dropdown-menu .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:hover{border-color:var(--c-primary-500);color:var(--c-primary-500)}.tc-rev-dropdown .tc-rev-dropdown-menu .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown .tc-rev-dropdown-menu .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}.tc-rev-dropdown-menu--device{height:100%;overflow-y:auto;background-color:var(--c-neutral-50);padding:var(--size-16)}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-section{display:contents}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-header{align-items:center;display:flex;gap:var(--size-16);justify-content:space-between}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container{list-style:none;margin:0;padding:0;gap:.5rem;display:flex;flex-direction:column}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-14);line-height:var(--l-height-16);height:var(--size-40);padding:var(--size-12);text-align:left;text-wrap:nowrap;transition:all .2s ease;width:100%}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:active:not(:disabled):not(.selected){background-color:var(--c-primary-200);border-color:var(--c-primary-200);color:var(--c-primary-500);transform:scale(.98)}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: TcRevTooltipDirective, selector: "[tcRevTooltip]", inputs: ["tcRevTooltip", "position"] }, { kind: "directive", type: TcRevIconButtonDirective, selector: "button[tcRevIconButton]", inputs: ["color", "size", "tcRevIconButton"] }] }); }
|
|
12091
|
-
}
|
|
12092
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevDropdownComponent, decorators: [{
|
|
12093
|
-
type: Component,
|
|
12094
|
-
args: [{ selector: 'tc-rev-dropdown', imports: [
|
|
12095
|
-
FormsModule,
|
|
12096
|
-
ReactiveFormsModule,
|
|
12097
|
-
TcRevTooltipDirective,
|
|
12098
|
-
TcRevIconButtonDirective
|
|
12099
|
-
], template: "<div\n class=\"tc-rev-dropdown\"\n [class.disabled]=\"disabled()\"\n [style.width]=\"this.width()\"\n >\n <button\n class=\"tc-rev-dropdown-toggle\"\n [class.tc-rev-dropdown-toggle--sm]=\"this.size() === dropdownSize.sm\"\n [class.tc-rev-dropdown-toggle--md]=\"this.size() === dropdownSize.md\"\n [class.tc-rev-dropdown-toggle--lg]=\"this.size() === dropdownSize.lg\"\n (click)=\"toggleDropdown()\"\n [class.disabled]=\"disabled()\"\n [disabled]=\"disabled()\"\n >\n @if (label()) {\n <b>{{ label() }}</b>\n }\n <span class=\"tc-rev-dropdown-selected-text\">\n {{ selectedOption() ? selectedOption()?.displayValue : \"Selecione\" }}\n </span>\n <i class=\"fa-light fa-chevron-down mar-l-a\"></i>\n </button>\n @if (isOpen && isDesktop()) {\n <ul class=\"tc-rev-dropdown-menu\">\n @for (option of options(); track option?.value) {\n <li class=\"tc-rev-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tc-rev-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n <span\n class=\"tc-rev-dropdown-option-text\"\n [class.ellipsed]=\"isOptionEllipsed(option.displayValue)\"\n [tcRevTooltip]=\"\n isOptionEllipsed(option.displayValue) ? option.displayValue : ''\n \"\n position=\"top\"\n >\n {{ option?.displayValue }}\n </span>\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check\"></i>\n }\n </button>\n </li>\n }\n </ul>\n }\n\n <!-- Dropdown full screen -->\n <ng-template #menuTemplate>\n <div class=\"tc-rev-dropdown-menu tc-rev-dropdown-menu--device\">\n <div class=\"tc-rev-dropdown-menu-section\">\n <div class=\"tc-rev-dropdown-menu-header pad-b-24\">\n <h3 class=\"mar-none f-h2 f-weight-600 c-neutral-600\">\n {{ label() }}\n </h3>\n <button\n tcRevIconButton=\"outline\"\n color=\"dark\"\n size=\"sm\"\n (click)=\"_deviceService.closeDropdownDevice()\"\n >\n <i class=\"fa-light fa-times f-size-16\"></i>\n </button>\n </div>\n <ul class=\"tc-rev-dropdown-menu-container mar-t-8\">\n @for (option of options(); track option?.value) {\n <li class=\"tc-rev-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tc-rev-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n {{ option?.displayValue }}\n\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check f-size-16\"></i>\n }\n </button>\n </li>\n }\n </ul>\n </div>\n </div>\n </ng-template>\n</div>\n", styles: [".tc-rev-dropdown{position:relative;display:block;width:100%}.tc-rev-dropdown .tc-rev-dropdown-toggle{align-items:center;background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-400);border-radius:var(--bor-radius-pill);color:var(--c-neutral-700);cursor:pointer;display:inline-flex;font-family:var(--f-family);font-size:var(--f-size-12);gap:var(--size-8);line-height:var(--l-height-16);outline:none;transition:.2s ease;padding:0 var(--size-12) 0 var(--size-16);width:100%}.tc-rev-dropdown .tc-rev-dropdown-toggle .tc-rev-dropdown-selected-text{flex:1;overflow:hidden;text-align:left;text-overflow:ellipsis;white-space:nowrap}.tc-rev-dropdown .tc-rev-dropdown-toggle i{align-items:center;display:inline-flex;flex-shrink:0;height:var(--size-24);justify-content:center;line-height:1;width:var(--size-24)}.tc-rev-dropdown .tc-rev-dropdown-toggle--sm{height:var(--size-40)}.tc-rev-dropdown .tc-rev-dropdown-toggle--md{height:var(--size-44)}.tc-rev-dropdown .tc-rev-dropdown-toggle--lg{height:var(--size-48)}.tc-rev-dropdown .tc-rev-dropdown-toggle:hover,.tc-rev-dropdown .tc-rev-dropdown-toggle:focus{border-color:var(--c-primary-500)}.tc-rev-dropdown .tc-rev-dropdown-toggle:disabled{border-color:var(--c-neutral-300);color:var(--c-neutral-300);cursor:not-allowed}.tc-rev-dropdown .tc-rev-dropdown-menu{box-shadow:var(--shadow-md);position:absolute;top:110%;left:0;background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);list-style:none;margin:0;max-height:15.625rem;overflow-y:auto;padding:0;width:100%;z-index:1000}.tc-rev-dropdown .tc-rev-dropdown-menu .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-700);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-12);line-height:var(--l-height-16);height:var(--size-32);padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.tc-rev-dropdown .tc-rev-dropdown-menu .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn .tc-rev-dropdown-option-text{flex:1;overflow:hidden;text-align:left;white-space:nowrap}.tc-rev-dropdown .tc-rev-dropdown-menu .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn .tc-rev-dropdown-option-text.ellipsed{text-overflow:ellipsis}.tc-rev-dropdown .tc-rev-dropdown-menu .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:hover{border-color:var(--c-primary-500);color:var(--c-primary-500)}.tc-rev-dropdown .tc-rev-dropdown-menu .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown .tc-rev-dropdown-menu .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}.tc-rev-dropdown-menu--device{height:100%;overflow-y:auto;background-color:var(--c-neutral-50);padding:var(--size-16)}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-section{display:contents}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-header{align-items:center;display:flex;gap:var(--size-16);justify-content:space-between}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container{list-style:none;margin:0;padding:0;gap:.5rem;display:flex;flex-direction:column}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-14);line-height:var(--l-height-16);height:var(--size-40);padding:var(--size-12);text-align:left;text-wrap:nowrap;transition:all .2s ease;width:100%}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:active:not(:disabled):not(.selected){background-color:var(--c-primary-200);border-color:var(--c-primary-200);color:var(--c-primary-500);transform:scale(.98)}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}\n"] }]
|
|
12100
|
-
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { menuTemplate: [{
|
|
12101
|
-
type: ViewChild,
|
|
12102
|
-
args: ['menuTemplate']
|
|
12103
|
-
}], onDocumentClick: [{
|
|
12104
|
-
type: HostListener,
|
|
12105
|
-
args: ['document:click', ['$event']]
|
|
12106
|
-
}], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], options: [{ type: i0.Input, args: [{ isSignal: true, alias: "options", required: true }] }], initialValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialValue", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], width: [{ type: i0.Input, args: [{ isSignal: true, alias: "width", required: false }] }], optionSelected: [{ type: i0.Output, args: ["optionSelected"] }] } });
|
|
12107
|
-
|
|
12108
|
-
class TcRevSearchInputComponent {
|
|
12109
|
-
constructor() {
|
|
12110
|
-
this.searchTextChange = new EventEmitter();
|
|
12111
|
-
this.searchInput = viewChild('searchInput', ...(ngDevMode ? [{ debugName: "searchInput" }] : /* istanbul ignore next */ []));
|
|
12112
|
-
this.searchTextForm = new FormControl('');
|
|
12113
|
-
this.placeholder = input('', ...(ngDevMode ? [{ debugName: "placeholder" }] : /* istanbul ignore next */ []));
|
|
12114
|
-
this.onSearch = output();
|
|
12115
|
-
this.autoFocus = input(false, ...(ngDevMode ? [{ debugName: "autoFocus" }] : /* istanbul ignore next */ []));
|
|
12116
|
-
}
|
|
12117
|
-
ngOnChanges(_simpleChanges) {
|
|
12118
|
-
if (_simpleChanges['searchText']) {
|
|
12119
|
-
this.searchTextForm.setValue(this.searchText);
|
|
12120
|
-
}
|
|
12121
|
-
}
|
|
12122
|
-
ngOnInit() {
|
|
12123
|
-
// Inicializa o FormControl com o valor do model
|
|
12124
|
-
this.searchTextForm.setValue(this.searchText);
|
|
12125
|
-
this.searchTextForm.valueChanges
|
|
12126
|
-
.pipe(debounceTime(500), distinctUntilChanged(), map((text) => text?.toLowerCase() || ''))
|
|
12127
|
-
.subscribe((text) => {
|
|
12128
|
-
this.searchTextChange.emit(text);
|
|
12129
|
-
this.onSearch.emit(text);
|
|
12130
|
-
});
|
|
12131
|
-
}
|
|
12132
|
-
ngAfterViewInit() {
|
|
12133
|
-
if (this.autoFocus() && this.searchInput) {
|
|
12134
|
-
this.searchInput().nativeElement.focus();
|
|
12135
|
-
}
|
|
12136
|
-
}
|
|
12137
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSearchInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12138
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "21.2.17", type: TcRevSearchInputComponent, isStandalone: true, selector: "tc-rev-search-input", inputs: { searchText: { classPropertyName: "searchText", publicName: "searchText", isSignal: false, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, autoFocus: { classPropertyName: "autoFocus", publicName: "autoFocus", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { searchTextChange: "searchTextChange", onSearch: "onSearch" }, viewQueries: [{ propertyName: "searchInput", first: true, predicate: ["searchInput"], descendants: true, isSignal: true }], usesOnChanges: true, ngImport: i0, template: "<form class=\"tc-rev-search-input-container\">\n <input\n type=\"text\"\n class=\"tc-rev-search-input-control\"\n [formControl]=\"this.searchTextForm\"\n [placeholder]=\"this.placeholder()\"\n #searchInput\n />\n\n <button class=\"tc-rev-search-input-btn\">\n <i class=\"fa-light fa-magnifying-glass\"></i>\n </button>\n</form>\n\n\n", styles: [":host{display:block}.tc-rev-search-input-container{position:relative;max-height:var(--size-40);min-height:var(--size-40);height:var(--size-40);min-width:7.5rem}.tc-rev-search-input-container .tc-rev-search-input-control{border:1px solid var(--c-neutral-400);border-radius:var(--bor-radius-pill);color:var(--c-neutral-700);display:inline-block;font-family:var(--f-family);font-size:var(--f-size-14);line-height:var(--l-height-20);outline:none;height:var(--size-40);transition:.2s ease;padding:0 var(--size-16);position:absolute;top:0;left:0;padding-right:var(--size-44);width:100%;z-index:1}.tc-rev-search-input-container .tc-rev-search-input-control:hover,.tc-rev-search-input-container .tc-rev-search-input-control:focus{border-color:var(--c-primary-500)}.tc-rev-search-input-container .tc-rev-search-input-btn{cursor:pointer;display:block;position:absolute;right:4px;top:4px;z-index:2;background-color:var(--c-primary-500);border-radius:var(--bor-radius-rounded);border:none;width:var(--size-32);height:var(--size-32);color:var(--c-neutral-50);font-size:var(--f-size-16)}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.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.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }] }); }
|
|
12139
|
-
}
|
|
12140
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSearchInputComponent, decorators: [{
|
|
12141
|
-
type: Component,
|
|
12142
|
-
args: [{ selector: 'tc-rev-search-input', imports: [FormsModule, ReactiveFormsModule], template: "<form class=\"tc-rev-search-input-container\">\n <input\n type=\"text\"\n class=\"tc-rev-search-input-control\"\n [formControl]=\"this.searchTextForm\"\n [placeholder]=\"this.placeholder()\"\n #searchInput\n />\n\n <button class=\"tc-rev-search-input-btn\">\n <i class=\"fa-light fa-magnifying-glass\"></i>\n </button>\n</form>\n\n\n", styles: [":host{display:block}.tc-rev-search-input-container{position:relative;max-height:var(--size-40);min-height:var(--size-40);height:var(--size-40);min-width:7.5rem}.tc-rev-search-input-container .tc-rev-search-input-control{border:1px solid var(--c-neutral-400);border-radius:var(--bor-radius-pill);color:var(--c-neutral-700);display:inline-block;font-family:var(--f-family);font-size:var(--f-size-14);line-height:var(--l-height-20);outline:none;height:var(--size-40);transition:.2s ease;padding:0 var(--size-16);position:absolute;top:0;left:0;padding-right:var(--size-44);width:100%;z-index:1}.tc-rev-search-input-container .tc-rev-search-input-control:hover,.tc-rev-search-input-container .tc-rev-search-input-control:focus{border-color:var(--c-primary-500)}.tc-rev-search-input-container .tc-rev-search-input-btn{cursor:pointer;display:block;position:absolute;right:4px;top:4px;z-index:2;background-color:var(--c-primary-500);border-radius:var(--bor-radius-rounded);border:none;width:var(--size-32);height:var(--size-32);color:var(--c-neutral-50);font-size:var(--f-size-16)}\n"] }]
|
|
12143
|
-
}], propDecorators: { searchText: [{
|
|
12144
|
-
type: Input
|
|
12145
|
-
}], searchTextChange: [{
|
|
12146
|
-
type: Output
|
|
12147
|
-
}], searchInput: [{ type: i0.ViewChild, args: ['searchInput', { isSignal: true }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], onSearch: [{ type: i0.Output, args: ["onSearch"] }], autoFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoFocus", required: false }] }] } });
|
|
12148
|
-
|
|
12149
|
-
var DropdownGroupedSize;
|
|
12150
|
-
(function (DropdownGroupedSize) {
|
|
12151
|
-
DropdownGroupedSize["sm"] = "sm";
|
|
12152
|
-
DropdownGroupedSize["md"] = "md";
|
|
12153
|
-
DropdownGroupedSize["lg"] = "lg";
|
|
12154
|
-
})(DropdownGroupedSize || (DropdownGroupedSize = {}));
|
|
12155
|
-
class TcRevDropdownGroupedComponent {
|
|
12156
|
-
onDocumentClick(event) {
|
|
12157
|
-
if (this.isOpen && !this.elementRef.nativeElement.contains(event.target)) {
|
|
12158
|
-
this.isOpen = false;
|
|
12159
|
-
}
|
|
12160
|
-
}
|
|
12161
|
-
constructor(elementRef) {
|
|
12162
|
-
this.elementRef = elementRef;
|
|
12163
|
-
this._deviceService = inject(TCloudUiDeviceUtilsService);
|
|
12164
|
-
this.label = input('', ...(ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ [])); // Label que será exibida
|
|
12165
|
-
this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ [])); // Desabilita o dropdown
|
|
12166
|
-
this.options = input.required(...(ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ [])); // Lista de opções agrupadas
|
|
12167
|
-
this.initialValue = input(null, ...(ngDevMode ? [{ debugName: "initialValue" }] : /* istanbul ignore next */ [])); // Valor pré-selecionado (deprecated - use value instead)
|
|
12168
|
-
this.value = model(null, ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ [])); // Two-way binding para o valor selecionado
|
|
12169
|
-
this.size = input(DropdownGroupedSize.sm, ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
12170
|
-
this.placeholder = input('Selecione', ...(ngDevMode ? [{ debugName: "placeholder" }] : /* istanbul ignore next */ []));
|
|
12171
|
-
this.searchPlaceholder = input('Buscar...', ...(ngDevMode ? [{ debugName: "searchPlaceholder" }] : /* istanbul ignore next */ []));
|
|
12172
|
-
this.showSearch = input(true, ...(ngDevMode ? [{ debugName: "showSearch" }] : /* istanbul ignore next */ [])); // Controla se mostra o input de busca
|
|
12173
|
-
this.width = input('', ...(ngDevMode ? [{ debugName: "width" }] : /* istanbul ignore next */ [])); // Largura do dropdown
|
|
12174
|
-
this.optionSelected = output(); // Emissor para o valor selecionado
|
|
12175
|
-
this.selectedOption = signal(null, ...(ngDevMode ? [{ debugName: "selectedOption" }] : /* istanbul ignore next */ [])); // Opção selecionada
|
|
12176
|
-
this.isOpen = false; // Controla se o dropdown está aberto
|
|
12177
|
-
this.searchTerm = signal('', ...(ngDevMode ? [{ debugName: "searchTerm" }] : /* istanbul ignore next */ [])); // Termo de busca
|
|
12178
|
-
this.dropdownSize = DropdownGroupedSize;
|
|
12179
|
-
this.isDesktop = this._deviceService.isDesktop;
|
|
12180
|
-
this.isMobile = this._deviceService.isMobile;
|
|
12181
|
-
}
|
|
12182
|
-
ngOnChanges(_simpleChanges) {
|
|
12183
|
-
// Atualiza a opção selecionada quando o valor pré-selecionado muda
|
|
12184
|
-
if (_simpleChanges['initialValue'] ||
|
|
12185
|
-
_simpleChanges['options'] ||
|
|
12186
|
-
_simpleChanges['value']) {
|
|
12187
|
-
const valueToUse = this.value() || this.initialValue();
|
|
12188
|
-
this.selectedOption.set(this.options().find((option) => option.value === valueToUse) || null);
|
|
12189
|
-
}
|
|
12190
|
-
}
|
|
12191
|
-
ngOnInit() {
|
|
12192
|
-
// Prioriza o valor do model, mas mantém compatibilidade com initialValue
|
|
12193
|
-
const valueToUse = this.value() || this.initialValue();
|
|
12194
|
-
const foundOption = this.options().find((option) => option.value === valueToUse) || null;
|
|
12195
|
-
this.selectedOption.set(foundOption);
|
|
12196
|
-
// Se não havia valor no model mas havia initialValue, sincroniza o model
|
|
12197
|
-
if (!this.value() && this.initialValue() && foundOption) {
|
|
12198
|
-
this.value.set(foundOption.value);
|
|
12199
|
-
}
|
|
12200
|
-
// Escuta mudanças no model e atualiza a opção selecionada
|
|
12201
|
-
this.value.subscribe((newValue) => {
|
|
12202
|
-
const option = this.options().find((opt) => opt.value === newValue) || null;
|
|
12203
|
-
if (this.selectedOption() !== option) {
|
|
12204
|
-
this.selectedOption.set(option);
|
|
12205
|
-
}
|
|
12206
|
-
});
|
|
12207
|
-
}
|
|
12208
|
-
toggleDropdown() {
|
|
12209
|
-
if (!this.disabled()) {
|
|
12210
|
-
// Abertura do dropdown para mobile
|
|
12211
|
-
if (this.isMobile()) {
|
|
12212
|
-
this._deviceService.openDropdownDevice(this.menuTemplate);
|
|
12213
|
-
return;
|
|
12214
|
-
}
|
|
12215
|
-
this.isOpen = !this.isOpen;
|
|
12216
|
-
if (this.isOpen) {
|
|
12217
|
-
this.searchTerm.set('');
|
|
12218
|
-
// Foca no input de busca quando abre o dropdown
|
|
12219
|
-
setTimeout(() => {
|
|
12220
|
-
const searchInput = this.elementRef.nativeElement.querySelector('.tc-rev-dropdown-search input');
|
|
12221
|
-
if (searchInput) {
|
|
12222
|
-
searchInput.focus();
|
|
12223
|
-
}
|
|
12224
|
-
}, 100);
|
|
12225
|
-
}
|
|
12226
|
-
}
|
|
12227
|
-
}
|
|
12228
|
-
selectOption(option) {
|
|
12229
|
-
if (!option.disabled) {
|
|
12230
|
-
this.selectedOption.set(option);
|
|
12231
|
-
this.value.set(option.value); // Atualiza o model com two-way binding
|
|
12232
|
-
this.optionSelected.emit(option); // Emite a opção selecionada para compatibilidade
|
|
12233
|
-
if (this.isMobile()) {
|
|
12234
|
-
this._deviceService.closeDropdownDevice();
|
|
12235
|
-
return;
|
|
12236
|
-
}
|
|
12237
|
-
this.isOpen = false;
|
|
12238
|
-
this.searchTerm.set('');
|
|
12239
|
-
}
|
|
12240
|
-
}
|
|
12241
|
-
onSearchChange(searchText) {
|
|
12242
|
-
this.searchTerm.set(searchText);
|
|
12243
|
-
}
|
|
12244
|
-
getGroupedOptions() {
|
|
12245
|
-
const filtered = this.getFilteredOptions();
|
|
12246
|
-
const groups = {};
|
|
12247
|
-
// Agrupa as opções filtradas
|
|
12248
|
-
filtered.forEach((option) => {
|
|
12249
|
-
const groupName = option.group || 'Sem grupo';
|
|
12250
|
-
if (!groups[groupName]) {
|
|
12251
|
-
groups[groupName] = [];
|
|
12252
|
-
}
|
|
12253
|
-
groups[groupName].push(option);
|
|
12254
|
-
});
|
|
12255
|
-
// Converte para array de grupos
|
|
12256
|
-
return Object.keys(groups).map((groupName) => ({
|
|
12257
|
-
groupName,
|
|
12258
|
-
options: groups[groupName],
|
|
12259
|
-
}));
|
|
12260
|
-
}
|
|
12261
|
-
getFilteredOptions() {
|
|
12262
|
-
const search = this.searchTerm().toLowerCase().trim();
|
|
12263
|
-
if (!search) {
|
|
12264
|
-
return this.options();
|
|
12265
|
-
}
|
|
12266
|
-
return this.options().filter((option) => option.displayValue.toLowerCase().includes(search) ||
|
|
12267
|
-
(option.group && option.group.toLowerCase().includes(search)));
|
|
12268
|
-
}
|
|
12269
|
-
clearSearch() {
|
|
12270
|
-
this.searchTerm.set('');
|
|
12271
|
-
}
|
|
12272
|
-
hasResults() {
|
|
12273
|
-
return this.getFilteredOptions().length > 0;
|
|
12274
|
-
}
|
|
12275
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevDropdownGroupedComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12276
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevDropdownGroupedComponent, isStandalone: true, selector: "tc-rev-dropdown-grouped", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: true, transformFunction: null }, initialValue: { classPropertyName: "initialValue", publicName: "initialValue", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, searchPlaceholder: { classPropertyName: "searchPlaceholder", publicName: "searchPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, showSearch: { classPropertyName: "showSearch", publicName: "showSearch", isSignal: true, isRequired: false, transformFunction: null }, width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange", optionSelected: "optionSelected" }, host: { listeners: { "document:click": "onDocumentClick($event)" } }, viewQueries: [{ propertyName: "menuTemplate", first: true, predicate: ["menuTemplate"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div class=\"tc-rev-dropdown-grouped\" [class.disabled]=\"disabled()\">\n <button\n class=\"tc-rev-dropdown-toggle\"\n [class.tc-rev-dropdown-toggle--sm]=\"this.size() === dropdownSize.sm\"\n [class.tc-rev-dropdown-toggle--md]=\"this.size() === dropdownSize.md\"\n [class.tc-rev-dropdown-toggle--lg]=\"this.size() === dropdownSize.lg\"\n (click)=\"toggleDropdown()\"\n [class.disabled]=\"disabled()\"\n [disabled]=\"disabled()\"\n [style.width]=\"this.width()\"\n >\n @if (label()) {\n <b>{{ label() }}</b>\n }\n {{ selectedOption() ? selectedOption()?.displayValue : placeholder() }}\n <i class=\"fa-light fa-chevron-down mar-l-a\" [class.rotate]=\"isOpen\"></i>\n </button>\n\n @if (isOpen && isDesktop()) {\n <div\n class=\"tc-rev-dropdown-menu\"\n [style.width]=\"this.width()\"\n >\n <!-- Input de busca -->\n @if (showSearch()) {\n <div class=\"tc-rev-dropdown-search\">\n <tc-rev-search-input\n (onSearch)=\"onSearchChange($event)\"\n [placeholder]=\"this.searchPlaceholder()\"\n />\n </div>\n <!-- <div class=\"tc-rev-dropdown-search\">\n <i class=\"fa-light fa-magnifying-glass search-icon\"></i>\n <input\n type=\"text\"\n [placeholder]=\"searchPlaceholder()\"\n [value]=\"searchTerm()\"\n (input)=\"onSearchChange($event)\"\n class=\"search-input\">\n @if (searchTerm()) {\n <button\n type=\"button\"\n class=\"clear-search\"\n (click)=\"clearSearch()\"\n title=\"Limpar busca\">\n <i class=\"fa-light fa-xmark\"></i>\n </button>\n }\n </div> -->\n }\n <!-- Lista de op\u00E7\u00F5es agrupadas -->\n @if (hasResults()) {\n <ul class=\"tc-rev-dropdown-options\">\n @for (group of getGroupedOptions(); track group.groupName) {\n <li class=\"tc-rev-dropdown-group\">\n <div class=\"tc-rev-dropdown-group-header\">\n {{ group.groupName }}\n </div>\n <ul class=\"tc-rev-dropdown-group-options\">\n @for (option of group.options; track option?.value) {\n <li class=\"tc-rev-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tc-rev-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n {{ option?.displayValue }}\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check\"></i>\n }\n </button>\n </li>\n }\n </ul>\n </li>\n }\n </ul>\n } @else {\n <div class=\"tc-rev-dropdown-no-results f-family\">\n <i class=\"fa-light fa-magnifying-glass\"></i>\n <span>Nenhum resultado encontrado</span>\n </div>\n }\n </div>\n }\n\n <!-- Dropdown full screen -->\n <ng-template #menuTemplate>\n <div class=\"tc-rev-dropdown-menu tc-rev-dropdown-menu--device\">\n <div class=\"tc-rev-dropdown-menu-section\">\n <div class=\"tc-rev-dropdown-menu-header pad-b-24\">\n <h3 class=\"mar-none f-h2 f-weight-600 c-neutral-600\">\n {{ label() }}\n </h3>\n <button\n tcRevIconButton=\"outline\"\n color=\"dark\"\n size=\"sm\"\n (click)=\"_deviceService.closeDropdownDevice()\"\n >\n <i class=\"fa-light fa-times f-size-16\"></i>\n </button>\n </div>\n\n @if (showSearch()) {\n <div class=\"tc-rev-dropdown-search mar-b-12\">\n <tc-rev-search-input\n (onSearch)=\"onSearchChange($event)\"\n [placeholder]=\"searchPlaceholder()\"\n />\n </div>\n } @if (hasResults()) {\n <ul class=\"tc-rev-dropdown-menu-container mar-t-8\">\n @for (group of getGroupedOptions(); track group.groupName) {\n <li class=\"tc-rev-dropdown-group\">\n <div class=\"tc-rev-dropdown-group-header\">\n {{ group.groupName }}\n </div>\n <ul class=\"tc-rev-dropdown-group-options\">\n @for (option of group.options; track option?.value) {\n <li\n class=\"tc-rev-dropdown-menu-item\"\n (click)=\"selectOption(option)\"\n >\n <button\n class=\"tc-rev-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n {{ option?.displayValue }}\n\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check f-size-16\"></i>\n }\n </button>\n </li>\n }\n </ul>\n </li>\n }\n </ul>\n }\n </div>\n </div>\n </ng-template>\n </div>\n", styles: [":host{display:inline-block}.tc-rev-dropdown-grouped{position:relative;display:inline-block}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle{background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-400);border-radius:var(--bor-radius-pill);color:var(--c-neutral-700);cursor:pointer;display:inline-flex;align-items:center;justify-content:flex-start;gap:var(--size-4);font-family:var(--f-family);font-size:var(--f-size-12);line-height:var(--l-height-16);outline:none;transition:.2s ease;padding:0 var(--size-16);min-width:5rem}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle--sm{height:var(--size-40)}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle--md{height:var(--size-44)}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle--lg{height:var(--size-48)}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle:hover,.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle:focus{border-color:var(--c-primary-500)}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle:disabled{border-color:var(--c-neutral-300);color:var(--c-neutral-300);cursor:not-allowed}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle i.rotate{transform:rotate(-180deg)}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle i{transition:transform .2s ease}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu{box-shadow:var(--shadow-md);position:absolute;top:110%;left:0;background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);max-height:20rem;overflow:hidden;width:100%;min-width:10rem;z-index:1000;display:flex;flex-direction:column}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search{position:relative;padding:var(--size-8);border-bottom:1px solid var(--c-neutral-200);background-color:var(--c-neutral-50)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search .search-icon{position:absolute;left:var(--size-20);top:50%;transform:translateY(-50%);color:var(--c-neutral-500);font-size:var(--f-size-14)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search .search-input{width:100%;height:var(--size-40);padding:var(--size-8) var(--size-12) var(--size-8) var(--size-36);border:1px solid var(--c-neutral-300);border-radius:var(--bor-radius-4);font-size:var(--f-size-12);line-height:var(--l-height-16);outline:none;transition:border-color .2s ease;font-family:var(--f-family)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search .search-input:focus{border-color:var(--c-primary-500)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search .search-input::placeholder{color:var(--c-neutral-500)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search .clear-search{position:absolute;right:var(--size-20);top:50%;transform:translateY(-50%);background:none;border:none;color:var(--c-neutral-500);cursor:pointer;padding:var(--size-4);border-radius:var(--bor-radius-4);transition:color .2s ease;font-family:var(--f-family)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search .clear-search:hover{color:var(--c-neutral-700)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options{list-style:none;margin:0;padding:0;overflow-y:auto;flex:1;font-family:var(--f-family)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-header{background-color:var(--c-neutral-100);color:var(--c-neutral-600);font-size:var(--f-size-14);font-weight:var(--f-weight-500);line-height:var(--l-height-16);padding:var(--size-10);text-transform:uppercase;letter-spacing:.5px;border-bottom:1px solid var(--c-neutral-200);position:sticky;top:0;z-index:1}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-options{list-style:none;margin:0;padding:0}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-12);line-height:var(--l-height-16);height:var(--size-32);padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:hover{background-color:var(--c-neutral-50);border-color:var(--c-primary-500);color:var(--c-primary-500)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-400);cursor:not-allowed}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:disabled:hover{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-400)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-no-results{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:var(--size-24);color:var(--c-neutral-500);text-align:center}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-no-results i{font-size:var(--f-size-24);margin-bottom:var(--size-8);opacity:.5}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-no-results span{font-size:var(--f-size-12);line-height:var(--l-height-16)}.tc-rev-dropdown-grouped.disabled .tc-rev-dropdown-toggle{border-color:var(--c-neutral-300);color:var(--c-neutral-300);cursor:not-allowed}.tc-rev-dropdown-grouped.disabled .tc-rev-dropdown-toggle:hover{border-color:var(--c-neutral-300)}.tc-rev-dropdown-menu--device{height:100%;overflow-y:auto;background-color:var(--c-neutral-50);padding:var(--size-16)}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-section{display:contents}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-header{align-items:center;display:flex;gap:var(--size-16);justify-content:space-between}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container{list-style:none;margin:0;padding:0;overflow-y:auto;flex:1}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container .tc-rev-dropdown-group .tc-rev-dropdown-group-header{background-color:var(--c-neutral-100);color:var(--c-neutral-600);font-size:var(--f-size-14);font-weight:var(--f-weight-500);line-height:var(--l-height-16);padding:var(--size-10);text-transform:uppercase;letter-spacing:.5px;border-bottom:1px solid var(--c-neutral-200);position:sticky;top:0;z-index:1}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container .tc-rev-dropdown-group .tc-rev-dropdown-group-options{list-style:none;margin:0;padding:0}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-14);line-height:var(--l-height-16);height:var(--size-40);padding:var(--size-12);text-align:left;text-wrap:nowrap;transition:all .2s ease;width:100%}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:active:not(:disabled):not(.selected){background-color:var(--c-primary-200);border-color:var(--c-primary-200);color:var(--c-primary-500);transform:scale(.98)}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "component", type: TcRevSearchInputComponent, selector: "tc-rev-search-input", inputs: ["searchText", "placeholder", "autoFocus"], outputs: ["searchTextChange", "onSearch"] }, { kind: "directive", type: TcRevIconButtonDirective, selector: "button[tcRevIconButton]", inputs: ["color", "size", "tcRevIconButton"] }] }); }
|
|
12277
|
-
}
|
|
12278
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevDropdownGroupedComponent, decorators: [{
|
|
12279
|
-
type: Component,
|
|
12280
|
-
args: [{ selector: 'tc-rev-dropdown-grouped', imports: [
|
|
12281
|
-
FormsModule,
|
|
12282
|
-
ReactiveFormsModule,
|
|
12283
|
-
TcRevSearchInputComponent,
|
|
12284
|
-
TcRevIconButtonDirective
|
|
12285
|
-
], template: "<div class=\"tc-rev-dropdown-grouped\" [class.disabled]=\"disabled()\">\n <button\n class=\"tc-rev-dropdown-toggle\"\n [class.tc-rev-dropdown-toggle--sm]=\"this.size() === dropdownSize.sm\"\n [class.tc-rev-dropdown-toggle--md]=\"this.size() === dropdownSize.md\"\n [class.tc-rev-dropdown-toggle--lg]=\"this.size() === dropdownSize.lg\"\n (click)=\"toggleDropdown()\"\n [class.disabled]=\"disabled()\"\n [disabled]=\"disabled()\"\n [style.width]=\"this.width()\"\n >\n @if (label()) {\n <b>{{ label() }}</b>\n }\n {{ selectedOption() ? selectedOption()?.displayValue : placeholder() }}\n <i class=\"fa-light fa-chevron-down mar-l-a\" [class.rotate]=\"isOpen\"></i>\n </button>\n\n @if (isOpen && isDesktop()) {\n <div\n class=\"tc-rev-dropdown-menu\"\n [style.width]=\"this.width()\"\n >\n <!-- Input de busca -->\n @if (showSearch()) {\n <div class=\"tc-rev-dropdown-search\">\n <tc-rev-search-input\n (onSearch)=\"onSearchChange($event)\"\n [placeholder]=\"this.searchPlaceholder()\"\n />\n </div>\n <!-- <div class=\"tc-rev-dropdown-search\">\n <i class=\"fa-light fa-magnifying-glass search-icon\"></i>\n <input\n type=\"text\"\n [placeholder]=\"searchPlaceholder()\"\n [value]=\"searchTerm()\"\n (input)=\"onSearchChange($event)\"\n class=\"search-input\">\n @if (searchTerm()) {\n <button\n type=\"button\"\n class=\"clear-search\"\n (click)=\"clearSearch()\"\n title=\"Limpar busca\">\n <i class=\"fa-light fa-xmark\"></i>\n </button>\n }\n </div> -->\n }\n <!-- Lista de op\u00E7\u00F5es agrupadas -->\n @if (hasResults()) {\n <ul class=\"tc-rev-dropdown-options\">\n @for (group of getGroupedOptions(); track group.groupName) {\n <li class=\"tc-rev-dropdown-group\">\n <div class=\"tc-rev-dropdown-group-header\">\n {{ group.groupName }}\n </div>\n <ul class=\"tc-rev-dropdown-group-options\">\n @for (option of group.options; track option?.value) {\n <li class=\"tc-rev-dropdown-menu-item\" (click)=\"selectOption(option)\">\n <button\n class=\"tc-rev-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n {{ option?.displayValue }}\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check\"></i>\n }\n </button>\n </li>\n }\n </ul>\n </li>\n }\n </ul>\n } @else {\n <div class=\"tc-rev-dropdown-no-results f-family\">\n <i class=\"fa-light fa-magnifying-glass\"></i>\n <span>Nenhum resultado encontrado</span>\n </div>\n }\n </div>\n }\n\n <!-- Dropdown full screen -->\n <ng-template #menuTemplate>\n <div class=\"tc-rev-dropdown-menu tc-rev-dropdown-menu--device\">\n <div class=\"tc-rev-dropdown-menu-section\">\n <div class=\"tc-rev-dropdown-menu-header pad-b-24\">\n <h3 class=\"mar-none f-h2 f-weight-600 c-neutral-600\">\n {{ label() }}\n </h3>\n <button\n tcRevIconButton=\"outline\"\n color=\"dark\"\n size=\"sm\"\n (click)=\"_deviceService.closeDropdownDevice()\"\n >\n <i class=\"fa-light fa-times f-size-16\"></i>\n </button>\n </div>\n\n @if (showSearch()) {\n <div class=\"tc-rev-dropdown-search mar-b-12\">\n <tc-rev-search-input\n (onSearch)=\"onSearchChange($event)\"\n [placeholder]=\"searchPlaceholder()\"\n />\n </div>\n } @if (hasResults()) {\n <ul class=\"tc-rev-dropdown-menu-container mar-t-8\">\n @for (group of getGroupedOptions(); track group.groupName) {\n <li class=\"tc-rev-dropdown-group\">\n <div class=\"tc-rev-dropdown-group-header\">\n {{ group.groupName }}\n </div>\n <ul class=\"tc-rev-dropdown-group-options\">\n @for (option of group.options; track option?.value) {\n <li\n class=\"tc-rev-dropdown-menu-item\"\n (click)=\"selectOption(option)\"\n >\n <button\n class=\"tc-rev-dropdown-menu-item-btn\"\n [class.selected]=\"selectedOption()?.value === option.value\"\n [disabled]=\"option?.disabled\"\n >\n {{ option?.displayValue }}\n\n @if (selectedOption()?.value === option?.value) {\n <i class=\"fa-light fa-circle-check f-size-16\"></i>\n }\n </button>\n </li>\n }\n </ul>\n </li>\n }\n </ul>\n }\n </div>\n </div>\n </ng-template>\n </div>\n", styles: [":host{display:inline-block}.tc-rev-dropdown-grouped{position:relative;display:inline-block}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle{background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-400);border-radius:var(--bor-radius-pill);color:var(--c-neutral-700);cursor:pointer;display:inline-flex;align-items:center;justify-content:flex-start;gap:var(--size-4);font-family:var(--f-family);font-size:var(--f-size-12);line-height:var(--l-height-16);outline:none;transition:.2s ease;padding:0 var(--size-16);min-width:5rem}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle--sm{height:var(--size-40)}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle--md{height:var(--size-44)}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle--lg{height:var(--size-48)}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle:hover,.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle:focus{border-color:var(--c-primary-500)}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle:disabled{border-color:var(--c-neutral-300);color:var(--c-neutral-300);cursor:not-allowed}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle i.rotate{transform:rotate(-180deg)}.tc-rev-dropdown-grouped .tc-rev-dropdown-toggle i{transition:transform .2s ease}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu{box-shadow:var(--shadow-md);position:absolute;top:110%;left:0;background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);max-height:20rem;overflow:hidden;width:100%;min-width:10rem;z-index:1000;display:flex;flex-direction:column}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search{position:relative;padding:var(--size-8);border-bottom:1px solid var(--c-neutral-200);background-color:var(--c-neutral-50)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search .search-icon{position:absolute;left:var(--size-20);top:50%;transform:translateY(-50%);color:var(--c-neutral-500);font-size:var(--f-size-14)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search .search-input{width:100%;height:var(--size-40);padding:var(--size-8) var(--size-12) var(--size-8) var(--size-36);border:1px solid var(--c-neutral-300);border-radius:var(--bor-radius-4);font-size:var(--f-size-12);line-height:var(--l-height-16);outline:none;transition:border-color .2s ease;font-family:var(--f-family)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search .search-input:focus{border-color:var(--c-primary-500)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search .search-input::placeholder{color:var(--c-neutral-500)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search .clear-search{position:absolute;right:var(--size-20);top:50%;transform:translateY(-50%);background:none;border:none;color:var(--c-neutral-500);cursor:pointer;padding:var(--size-4);border-radius:var(--bor-radius-4);transition:color .2s ease;font-family:var(--f-family)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-search .clear-search:hover{color:var(--c-neutral-700)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options{list-style:none;margin:0;padding:0;overflow-y:auto;flex:1;font-family:var(--f-family)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-header{background-color:var(--c-neutral-100);color:var(--c-neutral-600);font-size:var(--f-size-14);font-weight:var(--f-weight-500);line-height:var(--l-height-16);padding:var(--size-10);text-transform:uppercase;letter-spacing:.5px;border-bottom:1px solid var(--c-neutral-200);position:sticky;top:0;z-index:1}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-options{list-style:none;margin:0;padding:0}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-12);line-height:var(--l-height-16);height:var(--size-32);padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:hover{background-color:var(--c-neutral-50);border-color:var(--c-primary-500);color:var(--c-primary-500)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-400);cursor:not-allowed}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-options .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:disabled:hover{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-400)}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-no-results{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:var(--size-24);color:var(--c-neutral-500);text-align:center}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-no-results i{font-size:var(--f-size-24);margin-bottom:var(--size-8);opacity:.5}.tc-rev-dropdown-grouped .tc-rev-dropdown-menu .tc-rev-dropdown-no-results span{font-size:var(--f-size-12);line-height:var(--l-height-16)}.tc-rev-dropdown-grouped.disabled .tc-rev-dropdown-toggle{border-color:var(--c-neutral-300);color:var(--c-neutral-300);cursor:not-allowed}.tc-rev-dropdown-grouped.disabled .tc-rev-dropdown-toggle:hover{border-color:var(--c-neutral-300)}.tc-rev-dropdown-menu--device{height:100%;overflow-y:auto;background-color:var(--c-neutral-50);padding:var(--size-16)}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-section{display:contents}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-header{align-items:center;display:flex;gap:var(--size-16);justify-content:space-between}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container{list-style:none;margin:0;padding:0;overflow-y:auto;flex:1}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container .tc-rev-dropdown-group .tc-rev-dropdown-group-header{background-color:var(--c-neutral-100);color:var(--c-neutral-600);font-size:var(--f-size-14);font-weight:var(--f-weight-500);line-height:var(--l-height-16);padding:var(--size-10);text-transform:uppercase;letter-spacing:.5px;border-bottom:1px solid var(--c-neutral-200);position:sticky;top:0;z-index:1}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container .tc-rev-dropdown-group .tc-rev-dropdown-group-options{list-style:none;margin:0;padding:0}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-14);line-height:var(--l-height-16);height:var(--size-40);padding:var(--size-12);text-align:left;text-wrap:nowrap;transition:all .2s ease;width:100%}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:active:not(:disabled):not(.selected){background-color:var(--c-primary-200);border-color:var(--c-primary-200);color:var(--c-primary-500);transform:scale(.98)}.tc-rev-dropdown-menu--device .tc-rev-dropdown-menu-container .tc-rev-dropdown-group .tc-rev-dropdown-group-options .tc-rev-dropdown-menu-item .tc-rev-dropdown-menu-item-btn:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}\n"] }]
|
|
12286
|
-
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { menuTemplate: [{
|
|
12287
|
-
type: ViewChild,
|
|
12288
|
-
args: ['menuTemplate']
|
|
12289
|
-
}], onDocumentClick: [{
|
|
12290
|
-
type: HostListener,
|
|
12291
|
-
args: ['document:click', ['$event']]
|
|
12292
|
-
}], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], options: [{ type: i0.Input, args: [{ isSignal: true, alias: "options", required: true }] }], initialValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialValue", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], searchPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchPlaceholder", required: false }] }], showSearch: [{ type: i0.Input, args: [{ isSignal: true, alias: "showSearch", required: false }] }], width: [{ type: i0.Input, args: [{ isSignal: true, alias: "width", required: false }] }], optionSelected: [{ type: i0.Output, args: ["optionSelected"] }] } });
|
|
12293
|
-
|
|
12294
|
-
var DropdownMultiSize;
|
|
12295
|
-
(function (DropdownMultiSize) {
|
|
12296
|
-
DropdownMultiSize["sm"] = "sm";
|
|
12297
|
-
DropdownMultiSize["md"] = "md";
|
|
12298
|
-
DropdownMultiSize["lg"] = "lg";
|
|
12299
|
-
})(DropdownMultiSize || (DropdownMultiSize = {}));
|
|
12300
|
-
class TcRevDropdownMultiComponent {
|
|
12301
|
-
onDocumentClick(event) {
|
|
12302
|
-
if (this.isOpen && !this.elementRef.nativeElement.contains(event.target)) {
|
|
12303
|
-
this.isOpen = false;
|
|
12304
|
-
}
|
|
12305
|
-
}
|
|
12306
|
-
constructor(elementRef) {
|
|
12307
|
-
this.elementRef = elementRef;
|
|
12308
|
-
this.label = input('', ...(ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ [])); // Label que será exibida
|
|
12309
|
-
this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ [])); // Desabilita o dropdown
|
|
12310
|
-
this.options = input.required(...(ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ [])); // Lista de opções no novo formato
|
|
12311
|
-
this.initialValues = input([], ...(ngDevMode ? [{ debugName: "initialValues" }] : /* istanbul ignore next */ [])); // Valores pré-selecionados (deprecated - use values instead)
|
|
12312
|
-
this.values = model([], ...(ngDevMode ? [{ debugName: "values" }] : /* istanbul ignore next */ [])); // Two-way binding para os valores selecionados
|
|
12313
|
-
this.size = input(DropdownMultiSize.sm, ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
12314
|
-
this.width = input('', ...(ngDevMode ? [{ debugName: "width" }] : /* istanbul ignore next */ [])); // Largura do dropdown
|
|
12315
|
-
this.placeholder = input('Selecione', ...(ngDevMode ? [{ debugName: "placeholder" }] : /* istanbul ignore next */ [])); // Placeholder quando nenhum item estiver selecionado
|
|
12316
|
-
this.maxDisplayItems = input(2, ...(ngDevMode ? [{ debugName: "maxDisplayItems" }] : /* istanbul ignore next */ [])); // Máximo de itens a serem exibidos no botão
|
|
12317
|
-
this.optionsSelected = output(); // Emissor para os valores selecionados
|
|
12318
|
-
this.selectedOptions = signal([], ...(ngDevMode ? [{ debugName: "selectedOptions" }] : /* istanbul ignore next */ [])); // Opções selecionadas
|
|
12319
|
-
this.isOpen = false; // Controla se o dropdown está aberto
|
|
12320
|
-
this.dropdownSize = DropdownMultiSize;
|
|
12321
|
-
}
|
|
12322
|
-
ngOnChanges(_simpleChanges) {
|
|
12323
|
-
// Atualiza as opções selecionadas quando os valores pré-selecionados mudam
|
|
12324
|
-
if (_simpleChanges['initialValues'] || _simpleChanges['options'] || _simpleChanges['values']) {
|
|
12325
|
-
const valuesToUse = this.values().length > 0 ? this.values() : this.initialValues();
|
|
12326
|
-
const selected = this.options().filter(option => valuesToUse.includes(option.value));
|
|
12327
|
-
this.selectedOptions.set(selected);
|
|
12328
|
-
}
|
|
12329
|
-
}
|
|
12330
|
-
ngOnInit() {
|
|
12331
|
-
// Prioriza os valores do model, mas mantém compatibilidade com initialValues
|
|
12332
|
-
const valuesToUse = this.values().length > 0 ? this.values() : this.initialValues();
|
|
12333
|
-
const selected = this.options().filter(option => valuesToUse.includes(option.value));
|
|
12334
|
-
this.selectedOptions.set(selected);
|
|
12335
|
-
// Se não havia valores no model mas havia initialValues, sincroniza o model
|
|
12336
|
-
if (this.values().length === 0 && this.initialValues().length > 0) {
|
|
12337
|
-
this.values.set([...this.initialValues()]);
|
|
12338
|
-
}
|
|
12339
|
-
// Escuta mudanças no model e atualiza as opções selecionadas
|
|
12340
|
-
this.values.subscribe((newValues) => {
|
|
12341
|
-
const newSelected = this.options().filter(option => newValues.includes(option.value));
|
|
12342
|
-
// Só atualiza se realmente mudou para evitar loops
|
|
12343
|
-
const currentSelectedValues = this.selectedOptions().map(opt => opt.value);
|
|
12344
|
-
const newSelectedValues = newSelected.map(opt => opt.value);
|
|
12345
|
-
if (JSON.stringify(currentSelectedValues.sort()) !== JSON.stringify(newSelectedValues.sort())) {
|
|
12346
|
-
this.selectedOptions.set(newSelected);
|
|
12347
|
-
}
|
|
12348
|
-
});
|
|
12349
|
-
}
|
|
12350
|
-
toggleDropdown() {
|
|
12351
|
-
if (!this.disabled()) {
|
|
12352
|
-
this.isOpen = !this.isOpen;
|
|
12353
|
-
}
|
|
12354
|
-
}
|
|
12355
|
-
toggleOption(option, event) {
|
|
12356
|
-
event.stopPropagation();
|
|
12357
|
-
if (option.disabled)
|
|
12358
|
-
return;
|
|
12359
|
-
const currentSelected = this.selectedOptions();
|
|
12360
|
-
const isSelected = currentSelected.some(selected => selected.value === option.value);
|
|
12361
|
-
let newSelected;
|
|
12362
|
-
if (isSelected) {
|
|
12363
|
-
// Remove a opção se já estiver selecionada
|
|
12364
|
-
newSelected = currentSelected.filter(selected => selected.value !== option.value);
|
|
12365
|
-
}
|
|
12366
|
-
else {
|
|
12367
|
-
// Adiciona a opção se não estiver selecionada
|
|
12368
|
-
newSelected = [...currentSelected, option];
|
|
12369
|
-
}
|
|
12370
|
-
const newValues = newSelected.map(opt => opt.value);
|
|
12371
|
-
this.selectedOptions.set(newSelected);
|
|
12372
|
-
this.values.set(newValues); // Atualiza o model com two-way binding
|
|
12373
|
-
this.optionsSelected.emit(newValues); // Emite os valores para compatibilidade
|
|
12374
|
-
}
|
|
12375
|
-
isOptionSelected(option) {
|
|
12376
|
-
return this.selectedOptions().some(selected => selected.value === option.value);
|
|
12377
|
-
}
|
|
12378
|
-
getDisplayText() {
|
|
12379
|
-
const selected = this.selectedOptions();
|
|
12380
|
-
if (selected.length === 0) {
|
|
12381
|
-
return this.placeholder();
|
|
12382
|
-
}
|
|
12383
|
-
// Se todos os itens (não desabilitados) estão selecionados, mostra "Todos"
|
|
12384
|
-
if (this.isAllSelected()) {
|
|
12385
|
-
return 'Todos';
|
|
12386
|
-
}
|
|
12387
|
-
const maxDisplay = this.maxDisplayItems();
|
|
12388
|
-
if (selected.length <= maxDisplay) {
|
|
12389
|
-
return selected.map(opt => opt.displayValue).join(', ');
|
|
12390
|
-
}
|
|
12391
|
-
const firstItems = selected.slice(0, maxDisplay).map(opt => opt.displayValue).join(', ');
|
|
12392
|
-
const remaining = selected.length - maxDisplay;
|
|
12393
|
-
return `${firstItems} (+${remaining})`;
|
|
12394
|
-
}
|
|
12395
|
-
clearAll() {
|
|
12396
|
-
this.selectedOptions.set([]);
|
|
12397
|
-
this.values.set([]); // Atualiza o model com two-way binding
|
|
12398
|
-
this.optionsSelected.emit([]);
|
|
12399
|
-
}
|
|
12400
|
-
selectAll() {
|
|
12401
|
-
const enabledOptions = this.options().filter(option => !option.disabled);
|
|
12402
|
-
const allValues = enabledOptions.map(opt => opt.value);
|
|
12403
|
-
this.selectedOptions.set(enabledOptions);
|
|
12404
|
-
this.values.set(allValues); // Atualiza o model com two-way binding
|
|
12405
|
-
this.optionsSelected.emit(allValues);
|
|
12406
|
-
}
|
|
12407
|
-
isAllSelected() {
|
|
12408
|
-
const enabledOptions = this.options().filter(option => !option.disabled);
|
|
12409
|
-
const selectedOptions = this.selectedOptions();
|
|
12410
|
-
if (enabledOptions.length === 0)
|
|
12411
|
-
return false;
|
|
12412
|
-
return enabledOptions.every(option => selectedOptions.some(selected => selected.value === option.value));
|
|
12413
|
-
}
|
|
12414
|
-
isSomeSelected() {
|
|
12415
|
-
const enabledOptions = this.options().filter(option => !option.disabled);
|
|
12416
|
-
const selectedOptions = this.selectedOptions();
|
|
12417
|
-
if (enabledOptions.length === 0 || selectedOptions.length === 0)
|
|
12418
|
-
return false;
|
|
12419
|
-
const selectedCount = enabledOptions.filter(option => selectedOptions.some(selected => selected.value === option.value)).length;
|
|
12420
|
-
return selectedCount > 0 && selectedCount < enabledOptions.length;
|
|
12421
|
-
}
|
|
12422
|
-
toggleSelectAll(event) {
|
|
12423
|
-
event.stopPropagation();
|
|
12424
|
-
if (this.isAllSelected()) {
|
|
12425
|
-
this.clearAll();
|
|
12426
|
-
}
|
|
12427
|
-
else {
|
|
12428
|
-
this.selectAll();
|
|
12429
|
-
}
|
|
12430
|
-
}
|
|
12431
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevDropdownMultiComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12432
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevDropdownMultiComponent, isStandalone: true, selector: "tc-rev-dropdown-multi", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: true, transformFunction: null }, initialValues: { classPropertyName: "initialValues", publicName: "initialValues", isSignal: true, isRequired: false, transformFunction: null }, values: { classPropertyName: "values", publicName: "values", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, maxDisplayItems: { classPropertyName: "maxDisplayItems", publicName: "maxDisplayItems", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { values: "valuesChange", optionsSelected: "optionsSelected" }, host: { listeners: { "document:click": "onDocumentClick($event)" } }, usesOnChanges: true, ngImport: i0, template: "<div\n class=\"tc-rev-dropdown-multi\"\n [class.disabled]=\"disabled()\">\n <button\n class=\"tc-rev-dropdown-multi-toggle\"\n [class.tc-rev-dropdown-multi-toggle--sm]=\"this.size() === dropdownSize.sm\"\n [class.tc-rev-dropdown-multi-toggle--md]=\"this.size() === dropdownSize.md\"\n [class.tc-rev-dropdown-multi-toggle--lg]=\"this.size() === dropdownSize.lg\"\n (click)=\"toggleDropdown()\"\n [class.disabled]=\"disabled()\"\n [disabled]=\"disabled()\"\n [attr.aria-expanded]=\"isOpen\"\n [style.width]=\"this.width()\">\n @if (label())\n {\n <b>{{label()}}</b>\n }\n <span class=\"selected-text\">{{ getDisplayText() }}</span>\n <i class=\"fa-light fa-chevron-down\"></i>\n </button>\n\n @if (isOpen) {\n <div\n class=\"tc-rev-dropdown-multi-menu\"\n [style.width]=\"this.width()\">\n <!-- Checkbox Selecionar/Limpar Todos -->\n <div class=\"tc-rev-dropdown-multi-actions\">\n <label\n class=\"tc-rev-dropdown-multi-select-all-label\"\n [class.selected]=\"isAllSelected()\">\n <input\n type=\"checkbox\"\n tcRevCheckbox\n [disabled]=\"disabled()\"\n [checked]=\"isAllSelected()\"\n [indeterminate]=\"isSomeSelected()\"\n (change)=\"toggleSelectAll($event)\">\n <span class=\"tc-rev-dropdown-multi-select-all-text\">Todos</span>\n </label>\n </div>\n <ul class=\"tc-rev-dropdown-multi-options\">\n @for (option of options(); track option?.value)\n {\n <li class=\"tc-rev-dropdown-multi-menu-item\">\n <label\n class=\"tc-rev-dropdown-multi-menu-item-label\"\n [class.disabled]=\"option?.disabled\"\n [class.selected]=\"isOptionSelected(option)\">\n <input\n type=\"checkbox\"\n tcRevCheckbox\n [checked]=\"isOptionSelected(option)\"\n [disabled]=\"option?.disabled\"\n (change)=\"toggleOption(option, $event)\">\n <span class=\"tc-rev-dropdown-multi-text\">\n {{ option?.displayValue }}\n </span>\n </label>\n </li>\n }\n </ul>\n </div>\n }\n </div>\n", styles: ["input[type=checkbox].tc-rev-input-checkbox,input[type=checkbox].tc-rev-checkbox{position:initial;margin:initial}input[type=checkbox].tc-rev-input-checkbox:after,input[type=checkbox].tc-rev-input-checkbox:before,input[type=checkbox].tc-rev-checkbox:after,input[type=checkbox].tc-rev-checkbox:before{content:\"\";position:initial;border-radius:initial;background:initial;z-index:initial}input[type=checkbox].tc-rev-input-checkbox:after,input[type=checkbox].tc-rev-checkbox:after{height:initial;width:initial;left:initial;top:initial;margin:initial;border:initial}input[type=checkbox].tc-rev-input-checkbox:checked:before,input[type=checkbox].tc-rev-checkbox:checked:before{background:initial;height:initial;width:initial;margin:initial;z-index:initial;left:initial;top:initial;border:initial;border-width:initial;transform:initial}input[type=checkbox].tc-rev-input-checkbox:checked:after,input[type=checkbox].tc-rev-checkbox:checked:after{border-color:initial}input[type=checkbox].tc-rev-input-checkbox,input[type=checkbox].tc-rev-checkbox{appearance:none;-webkit-appearance:none;width:20px;height:20px;border:1.5px solid var(--c-neutral-700);border-radius:2px;background:#fff;cursor:pointer;position:relative;outline:none;transition:border-color .2s,background .2s;display:inline-block;vertical-align:middle}input[type=checkbox].tc-rev-input-checkbox:before,input[type=checkbox].tc-rev-checkbox:before{content:\"\";display:block;width:100%;height:100%;border-radius:2px;background:var(--c-neutral-50);transition:background .2s,border-color .2s;position:absolute;top:0;left:0;z-index:1}input[type=checkbox].tc-rev-input-checkbox:after,input[type=checkbox].tc-rev-checkbox:after{content:\"\";display:block;position:absolute;top:4px;left:2px;width:14px;height:10px;background:none;mask:none;-webkit-mask:none;pointer-events:none;z-index:2;transition:background .2s}input[type=checkbox].tc-rev-input-checkbox:checked,input[type=checkbox].tc-rev-checkbox:checked{border-color:var(--c-primary-500);background:var(--c-primary-500)}input[type=checkbox].tc-rev-input-checkbox:checked:before,input[type=checkbox].tc-rev-checkbox:checked:before{background:var(--c-primary-500)}input[type=checkbox].tc-rev-input-checkbox:checked:after,input[type=checkbox].tc-rev-checkbox:checked:after{background:#fff;mask:url('data:image/svg+xml;utf8,<svg width=\"14\" height=\"10\" viewBox=\"0 0 14 10\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M1 5.5L5 9L13 1\" stroke=\"white\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>') no-repeat center/contain;-webkit-mask:url('data:image/svg+xml;utf8,<svg width=\"14\" height=\"10\" viewBox=\"0 0 14 10\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M1 5.5L5 9L13 1\" stroke=\"white\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>') no-repeat center/contain}input[type=checkbox].tc-rev-input-checkbox:disabled,input[type=checkbox].tc-rev-checkbox:disabled{border-color:var(--c-neutral-300);cursor:not-allowed}input[type=checkbox].tc-rev-input-checkbox:disabled:checked,input[type=checkbox].tc-rev-checkbox:disabled:checked{background:var(--c-neutral-300)}input[type=checkbox].tc-rev-input-checkbox:disabled:checked:before,input[type=checkbox].tc-rev-checkbox:disabled:checked:before{background:var(--c-neutral-300)}:host{display:inline-block}.tc-rev-dropdown-multi{position:relative;display:inline-block}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle{background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-400);border-radius:var(--bor-radius-pill);color:var(--c-neutral-700);cursor:pointer;display:flex;align-items:center;justify-content:space-between;font-family:var(--f-family);font-size:var(--f-size-12);min-width:6.25rem;line-height:var(--l-height-16);outline:none;transition:.2s ease;padding:0 var(--size-12) 0 var(--size-16);text-align:left;gap:var(--size-8)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle--sm{height:var(--size-40)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle--md{height:var(--size-44)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle--lg{height:var(--size-48)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle:hover,.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle:focus{border-color:var(--c-primary-500)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle:disabled,.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle.disabled{border-color:var(--c-neutral-300);color:var(--c-neutral-300);cursor:not-allowed}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle .selected-text{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle i{align-items:center;display:inline-flex;flex-shrink:0;height:var(--size-24);justify-content:center;line-height:1;transition:transform .2s ease;width:var(--size-24)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle[aria-expanded=true] i{transform:rotate(-180deg)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu{box-shadow:var(--shadow-md);position:absolute;top:110%;left:0;background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);display:flex;flex-direction:column;max-height:18.75rem;min-width:6.25rem;overflow:hidden;width:100%;z-index:1000;border:1px solid var(--c-neutral-200)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions{flex:none}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;font-family:var(--f-family);font-size:var(--f-size-12);gap:var(--size-8);line-height:var(--l-height-16);height:var(--size-32);margin:0;padding:var(--size-8);text-align:left;transition:.2s ease;width:100%}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label:hover{background-color:var(--c-primary-50);border-color:var(--c-primary-500)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label.selected:hover{border-color:transparent}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label.disabled,.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label:disabled{color:var(--c-neutral-400);cursor:not-allowed}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label.disabled:hover,.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label:disabled:hover{background-color:transparent;border-color:var(--c-neutral-50)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label .tc-rev-dropdown-multi-select-all-text{flex:1;-webkit-user-select:none;user-select:none}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options{list-style:none;flex:1 1 auto;margin:0;padding:0 0 var(--size-8);max-height:none;min-height:0;overflow-y:auto;overscroll-behavior:contain}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;font-family:var(--f-family);font-size:var(--f-size-12);gap:var(--size-8);justify-content:space-between;line-height:var(--l-height-16);height:var(--size-32);margin:0;padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label:hover{background-color:var(--c-primary-50);border-color:var(--c-primary-500)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label.selected:hover{border-color:transparent}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label.disabled,.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label:disabled{color:var(--c-neutral-400);cursor:not-allowed}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label.disabled:hover,.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label:disabled:hover{background-color:transparent;border-color:var(--c-neutral-50)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label .tc-rev-dropdown-multi-text{flex:1;text-wrap:nowrap;overflow:hidden;text-overflow:ellipsis}.tc-rev-dropdown-multi-menu{animation:dropdownSlideIn .2s ease-out}@keyframes dropdownSlideIn{0%{opacity:0;transform:translateY(-10px)}to{opacity:1;transform:translateY(0)}}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: TcRevCheckboxDirective, selector: "input[type=\"checkbox\"][tcRevCheckbox]" }] }); }
|
|
12433
|
-
}
|
|
12434
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevDropdownMultiComponent, decorators: [{
|
|
12435
|
-
type: Component,
|
|
12436
|
-
args: [{ selector: 'tc-rev-dropdown-multi', imports: [
|
|
12437
|
-
FormsModule,
|
|
12438
|
-
ReactiveFormsModule,
|
|
12439
|
-
TcRevCheckboxDirective
|
|
12440
|
-
], template: "<div\n class=\"tc-rev-dropdown-multi\"\n [class.disabled]=\"disabled()\">\n <button\n class=\"tc-rev-dropdown-multi-toggle\"\n [class.tc-rev-dropdown-multi-toggle--sm]=\"this.size() === dropdownSize.sm\"\n [class.tc-rev-dropdown-multi-toggle--md]=\"this.size() === dropdownSize.md\"\n [class.tc-rev-dropdown-multi-toggle--lg]=\"this.size() === dropdownSize.lg\"\n (click)=\"toggleDropdown()\"\n [class.disabled]=\"disabled()\"\n [disabled]=\"disabled()\"\n [attr.aria-expanded]=\"isOpen\"\n [style.width]=\"this.width()\">\n @if (label())\n {\n <b>{{label()}}</b>\n }\n <span class=\"selected-text\">{{ getDisplayText() }}</span>\n <i class=\"fa-light fa-chevron-down\"></i>\n </button>\n\n @if (isOpen) {\n <div\n class=\"tc-rev-dropdown-multi-menu\"\n [style.width]=\"this.width()\">\n <!-- Checkbox Selecionar/Limpar Todos -->\n <div class=\"tc-rev-dropdown-multi-actions\">\n <label\n class=\"tc-rev-dropdown-multi-select-all-label\"\n [class.selected]=\"isAllSelected()\">\n <input\n type=\"checkbox\"\n tcRevCheckbox\n [disabled]=\"disabled()\"\n [checked]=\"isAllSelected()\"\n [indeterminate]=\"isSomeSelected()\"\n (change)=\"toggleSelectAll($event)\">\n <span class=\"tc-rev-dropdown-multi-select-all-text\">Todos</span>\n </label>\n </div>\n <ul class=\"tc-rev-dropdown-multi-options\">\n @for (option of options(); track option?.value)\n {\n <li class=\"tc-rev-dropdown-multi-menu-item\">\n <label\n class=\"tc-rev-dropdown-multi-menu-item-label\"\n [class.disabled]=\"option?.disabled\"\n [class.selected]=\"isOptionSelected(option)\">\n <input\n type=\"checkbox\"\n tcRevCheckbox\n [checked]=\"isOptionSelected(option)\"\n [disabled]=\"option?.disabled\"\n (change)=\"toggleOption(option, $event)\">\n <span class=\"tc-rev-dropdown-multi-text\">\n {{ option?.displayValue }}\n </span>\n </label>\n </li>\n }\n </ul>\n </div>\n }\n </div>\n", styles: ["input[type=checkbox].tc-rev-input-checkbox,input[type=checkbox].tc-rev-checkbox{position:initial;margin:initial}input[type=checkbox].tc-rev-input-checkbox:after,input[type=checkbox].tc-rev-input-checkbox:before,input[type=checkbox].tc-rev-checkbox:after,input[type=checkbox].tc-rev-checkbox:before{content:\"\";position:initial;border-radius:initial;background:initial;z-index:initial}input[type=checkbox].tc-rev-input-checkbox:after,input[type=checkbox].tc-rev-checkbox:after{height:initial;width:initial;left:initial;top:initial;margin:initial;border:initial}input[type=checkbox].tc-rev-input-checkbox:checked:before,input[type=checkbox].tc-rev-checkbox:checked:before{background:initial;height:initial;width:initial;margin:initial;z-index:initial;left:initial;top:initial;border:initial;border-width:initial;transform:initial}input[type=checkbox].tc-rev-input-checkbox:checked:after,input[type=checkbox].tc-rev-checkbox:checked:after{border-color:initial}input[type=checkbox].tc-rev-input-checkbox,input[type=checkbox].tc-rev-checkbox{appearance:none;-webkit-appearance:none;width:20px;height:20px;border:1.5px solid var(--c-neutral-700);border-radius:2px;background:#fff;cursor:pointer;position:relative;outline:none;transition:border-color .2s,background .2s;display:inline-block;vertical-align:middle}input[type=checkbox].tc-rev-input-checkbox:before,input[type=checkbox].tc-rev-checkbox:before{content:\"\";display:block;width:100%;height:100%;border-radius:2px;background:var(--c-neutral-50);transition:background .2s,border-color .2s;position:absolute;top:0;left:0;z-index:1}input[type=checkbox].tc-rev-input-checkbox:after,input[type=checkbox].tc-rev-checkbox:after{content:\"\";display:block;position:absolute;top:4px;left:2px;width:14px;height:10px;background:none;mask:none;-webkit-mask:none;pointer-events:none;z-index:2;transition:background .2s}input[type=checkbox].tc-rev-input-checkbox:checked,input[type=checkbox].tc-rev-checkbox:checked{border-color:var(--c-primary-500);background:var(--c-primary-500)}input[type=checkbox].tc-rev-input-checkbox:checked:before,input[type=checkbox].tc-rev-checkbox:checked:before{background:var(--c-primary-500)}input[type=checkbox].tc-rev-input-checkbox:checked:after,input[type=checkbox].tc-rev-checkbox:checked:after{background:#fff;mask:url('data:image/svg+xml;utf8,<svg width=\"14\" height=\"10\" viewBox=\"0 0 14 10\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M1 5.5L5 9L13 1\" stroke=\"white\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>') no-repeat center/contain;-webkit-mask:url('data:image/svg+xml;utf8,<svg width=\"14\" height=\"10\" viewBox=\"0 0 14 10\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M1 5.5L5 9L13 1\" stroke=\"white\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>') no-repeat center/contain}input[type=checkbox].tc-rev-input-checkbox:disabled,input[type=checkbox].tc-rev-checkbox:disabled{border-color:var(--c-neutral-300);cursor:not-allowed}input[type=checkbox].tc-rev-input-checkbox:disabled:checked,input[type=checkbox].tc-rev-checkbox:disabled:checked{background:var(--c-neutral-300)}input[type=checkbox].tc-rev-input-checkbox:disabled:checked:before,input[type=checkbox].tc-rev-checkbox:disabled:checked:before{background:var(--c-neutral-300)}:host{display:inline-block}.tc-rev-dropdown-multi{position:relative;display:inline-block}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle{background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-400);border-radius:var(--bor-radius-pill);color:var(--c-neutral-700);cursor:pointer;display:flex;align-items:center;justify-content:space-between;font-family:var(--f-family);font-size:var(--f-size-12);min-width:6.25rem;line-height:var(--l-height-16);outline:none;transition:.2s ease;padding:0 var(--size-12) 0 var(--size-16);text-align:left;gap:var(--size-8)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle--sm{height:var(--size-40)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle--md{height:var(--size-44)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle--lg{height:var(--size-48)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle:hover,.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle:focus{border-color:var(--c-primary-500)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle:disabled,.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle.disabled{border-color:var(--c-neutral-300);color:var(--c-neutral-300);cursor:not-allowed}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle .selected-text{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle i{align-items:center;display:inline-flex;flex-shrink:0;height:var(--size-24);justify-content:center;line-height:1;transition:transform .2s ease;width:var(--size-24)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-toggle[aria-expanded=true] i{transform:rotate(-180deg)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu{box-shadow:var(--shadow-md);position:absolute;top:110%;left:0;background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);display:flex;flex-direction:column;max-height:18.75rem;min-width:6.25rem;overflow:hidden;width:100%;z-index:1000;border:1px solid var(--c-neutral-200)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions{flex:none}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;font-family:var(--f-family);font-size:var(--f-size-12);gap:var(--size-8);line-height:var(--l-height-16);height:var(--size-32);margin:0;padding:var(--size-8);text-align:left;transition:.2s ease;width:100%}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label:hover{background-color:var(--c-primary-50);border-color:var(--c-primary-500)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label.selected:hover{border-color:transparent}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label.disabled,.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label:disabled{color:var(--c-neutral-400);cursor:not-allowed}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label.disabled:hover,.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label:disabled:hover{background-color:transparent;border-color:var(--c-neutral-50)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-actions .tc-rev-dropdown-multi-select-all-label .tc-rev-dropdown-multi-select-all-text{flex:1;-webkit-user-select:none;user-select:none}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options{list-style:none;flex:1 1 auto;margin:0;padding:0 0 var(--size-8);max-height:none;min-height:0;overflow-y:auto;overscroll-behavior:contain}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-900);cursor:pointer;display:flex;font-family:var(--f-family);font-size:var(--f-size-12);gap:var(--size-8);justify-content:space-between;line-height:var(--l-height-16);height:var(--size-32);margin:0;padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label:hover{background-color:var(--c-primary-50);border-color:var(--c-primary-500)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label.selected:hover{border-color:transparent}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label.disabled,.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label:disabled{color:var(--c-neutral-400);cursor:not-allowed}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label.disabled:hover,.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label:disabled:hover{background-color:transparent;border-color:var(--c-neutral-50)}.tc-rev-dropdown-multi .tc-rev-dropdown-multi-menu .tc-rev-dropdown-multi-options .tc-rev-dropdown-multi-menu-item .tc-rev-dropdown-multi-menu-item-label .tc-rev-dropdown-multi-text{flex:1;text-wrap:nowrap;overflow:hidden;text-overflow:ellipsis}.tc-rev-dropdown-multi-menu{animation:dropdownSlideIn .2s ease-out}@keyframes dropdownSlideIn{0%{opacity:0;transform:translateY(-10px)}to{opacity:1;transform:translateY(0)}}\n"] }]
|
|
12441
|
-
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { onDocumentClick: [{
|
|
12442
|
-
type: HostListener,
|
|
12443
|
-
args: ['document:click', ['$event']]
|
|
12444
|
-
}], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], options: [{ type: i0.Input, args: [{ isSignal: true, alias: "options", required: true }] }], initialValues: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialValues", required: false }] }], values: [{ type: i0.Input, args: [{ isSignal: true, alias: "values", required: false }] }, { type: i0.Output, args: ["valuesChange"] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], width: [{ type: i0.Input, args: [{ isSignal: true, alias: "width", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], maxDisplayItems: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxDisplayItems", required: false }] }], optionsSelected: [{ type: i0.Output, args: ["optionsSelected"] }] } });
|
|
12445
|
-
|
|
12446
|
-
class TcRevDropdownSubMenuComponent {
|
|
12447
|
-
constructor() {
|
|
12448
|
-
this.items = input.required(...(ngDevMode ? [{ debugName: "items" }] : /* istanbul ignore next */ []));
|
|
12449
|
-
this.position = input('right', ...(ngDevMode ? [{ debugName: "position" }] : /* istanbul ignore next */ []));
|
|
12450
|
-
this.parentOffsetTop = input.required(...(ngDevMode ? [{ debugName: "parentOffsetTop" }] : /* istanbul ignore next */ []));
|
|
12451
|
-
this.selectedOption = input(...(ngDevMode ? [undefined, { debugName: "selectedOption" }] : /* istanbul ignore next */ []));
|
|
12452
|
-
this.onOptionSelected = output();
|
|
12453
|
-
}
|
|
12454
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevDropdownSubMenuComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12455
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevDropdownSubMenuComponent, isStandalone: true, selector: "tc-rev-dropdown-sub-menu", inputs: { items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: true, transformFunction: null }, position: { classPropertyName: "position", publicName: "position", isSignal: true, isRequired: false, transformFunction: null }, parentOffsetTop: { classPropertyName: "parentOffsetTop", publicName: "parentOffsetTop", isSignal: true, isRequired: true, transformFunction: null }, selectedOption: { classPropertyName: "selectedOption", publicName: "selectedOption", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onOptionSelected: "onOptionSelected" }, ngImport: i0, template: "<ul\n class=\"sub-menu\"\n [ngClass]=\"this.position()\"\n [style.top.px]=\"this.parentOffsetTop()\">\n @for (item of this.items(); track item.value)\n {\n <li\n class=\"sub-menu-item\"\n [class.selected]=\"this.selectedOption()?.value === item.value\"\n (click)=\"this.onOptionSelected.emit(item)\">\n {{ item.displayValue }}\n @if (this.selectedOption()?.value === item?.value)\n {\n <i class=\"fa-light fa-circle-check\"></i>\n }\n @if (item.children?.length)\n {\n <tc-rev-dropdown-sub-menu\n [items]=\"item.children\"\n [position]=\"this.position()\"\n [parentOffsetTop]=\"0\"\n [selectedOption]=\"this.selectedOption()\">\n </tc-rev-dropdown-sub-menu>\n }\n </li>\n }\n</ul>\n", styles: [".sub-menu{background-color:var(--c-neutral-50);box-shadow:var(--shadow-md);list-style:none;max-height:15.625rem;min-width:160px;overflow-y:auto;padding:0;position:absolute;margin:0;z-index:1001}.sub-menu.right{left:100%}.sub-menu.left{right:100%}.sub-menu-item{padding:8px 16px;white-space:nowrap;position:relative;align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-700);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-12);line-height:var(--l-height-16);height:var(--size-32);padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.sub-menu-item:hover{border-color:var(--c-primary-500);color:var(--c-primary-500)}.sub-menu-item.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.sub-menu-item:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}\n"], dependencies: [{ kind: "component", type: TcRevDropdownSubMenuComponent, selector: "tc-rev-dropdown-sub-menu", inputs: ["items", "position", "parentOffsetTop", "selectedOption"], outputs: ["onOptionSelected"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] }); }
|
|
12456
|
-
}
|
|
12457
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevDropdownSubMenuComponent, decorators: [{
|
|
12458
|
-
type: Component,
|
|
12459
|
-
args: [{ selector: 'tc-rev-dropdown-sub-menu', imports: [CommonModule], template: "<ul\n class=\"sub-menu\"\n [ngClass]=\"this.position()\"\n [style.top.px]=\"this.parentOffsetTop()\">\n @for (item of this.items(); track item.value)\n {\n <li\n class=\"sub-menu-item\"\n [class.selected]=\"this.selectedOption()?.value === item.value\"\n (click)=\"this.onOptionSelected.emit(item)\">\n {{ item.displayValue }}\n @if (this.selectedOption()?.value === item?.value)\n {\n <i class=\"fa-light fa-circle-check\"></i>\n }\n @if (item.children?.length)\n {\n <tc-rev-dropdown-sub-menu\n [items]=\"item.children\"\n [position]=\"this.position()\"\n [parentOffsetTop]=\"0\"\n [selectedOption]=\"this.selectedOption()\">\n </tc-rev-dropdown-sub-menu>\n }\n </li>\n }\n</ul>\n", styles: [".sub-menu{background-color:var(--c-neutral-50);box-shadow:var(--shadow-md);list-style:none;max-height:15.625rem;min-width:160px;overflow-y:auto;padding:0;position:absolute;margin:0;z-index:1001}.sub-menu.right{left:100%}.sub-menu.left{right:100%}.sub-menu-item{padding:8px 16px;white-space:nowrap;position:relative;align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-700);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-12);line-height:var(--l-height-16);height:var(--size-32);padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.sub-menu-item:hover{border-color:var(--c-primary-500);color:var(--c-primary-500)}.sub-menu-item.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.sub-menu-item:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}\n"] }]
|
|
12460
|
-
}], propDecorators: { items: [{ type: i0.Input, args: [{ isSignal: true, alias: "items", required: true }] }], position: [{ type: i0.Input, args: [{ isSignal: true, alias: "position", required: false }] }], parentOffsetTop: [{ type: i0.Input, args: [{ isSignal: true, alias: "parentOffsetTop", required: true }] }], selectedOption: [{ type: i0.Input, args: [{ isSignal: true, alias: "selectedOption", required: false }] }], onOptionSelected: [{ type: i0.Output, args: ["onOptionSelected"] }] } });
|
|
12461
|
-
|
|
12462
|
-
var MultiLevelDropdownSize;
|
|
12463
|
-
(function (MultiLevelDropdownSize) {
|
|
12464
|
-
MultiLevelDropdownSize["sm"] = "sm";
|
|
12465
|
-
MultiLevelDropdownSize["md"] = "md";
|
|
12466
|
-
MultiLevelDropdownSize["lg"] = "lg";
|
|
12467
|
-
})(MultiLevelDropdownSize || (MultiLevelDropdownSize = {}));
|
|
12468
|
-
class TcRevDropdownMultiLevelComponent {
|
|
12469
|
-
onDocumentClick(event) {
|
|
12470
|
-
if (this.isOpen && !this.elementRef.nativeElement.contains(event.target)) {
|
|
12471
|
-
this.isOpen = false;
|
|
12472
|
-
}
|
|
12473
|
-
}
|
|
12474
|
-
constructor(elementRef) {
|
|
12475
|
-
this.elementRef = elementRef;
|
|
12476
|
-
this.dropdownSize = MultiLevelDropdownSize;
|
|
12477
|
-
this.menu = input.required(...(ngDevMode ? [{ debugName: "menu" }] : /* istanbul ignore next */ []));
|
|
12478
|
-
this.subMenuPosition = input('right', ...(ngDevMode ? [{ debugName: "subMenuPosition" }] : /* istanbul ignore next */ []));
|
|
12479
|
-
this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
|
|
12480
|
-
this.size = input(MultiLevelDropdownSize.sm, ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
12481
|
-
this.initialValue = input(null, ...(ngDevMode ? [{ debugName: "initialValue" }] : /* istanbul ignore next */ [])); // Valor pré-selecionado
|
|
12482
|
-
this.optionSelected = output();
|
|
12483
|
-
this.selectedOption = signal(null, ...(ngDevMode ? [{ debugName: "selectedOption" }] : /* istanbul ignore next */ []));
|
|
12484
|
-
this.selectedParentOption = signal(null, ...(ngDevMode ? [{ debugName: "selectedParentOption" }] : /* istanbul ignore next */ []));
|
|
12485
|
-
this.hoveredIndex = null;
|
|
12486
|
-
this.isOpen = false;
|
|
12487
|
-
}
|
|
12488
|
-
ngOnChanges(_simpleChanges) {
|
|
12489
|
-
// Atualiza a opção selecionada quando o valor pré-selecionado muda
|
|
12490
|
-
if (_simpleChanges['initialValue'] || _simpleChanges['menu']) {
|
|
12491
|
-
this.selectedOption.set(null);
|
|
12492
|
-
this.selectedParentOption.set(null);
|
|
12493
|
-
}
|
|
12494
|
-
}
|
|
12495
|
-
getItemOffsetTop(index) {
|
|
12496
|
-
if (!this.menuRoot)
|
|
12497
|
-
return 0;
|
|
12498
|
-
const items = this.menuRoot.nativeElement.querySelectorAll('.menu-item');
|
|
12499
|
-
if (items && items[index]) {
|
|
12500
|
-
return items[index].offsetTop;
|
|
12501
|
-
}
|
|
12502
|
-
return 0;
|
|
12503
|
-
}
|
|
12504
|
-
toggleDropdown() {
|
|
12505
|
-
this.isOpen = !this.isOpen;
|
|
12506
|
-
}
|
|
12507
|
-
selectOption(option, parentOption) {
|
|
12508
|
-
this.selectedOption.set(option);
|
|
12509
|
-
this.selectedParentOption.set(parentOption);
|
|
12510
|
-
this.optionSelected.emit({ option, parentOption }); // Emite apenas o valor da opção selecionada
|
|
12511
|
-
// this.isOpen = false; // Fecha o dropdown
|
|
12512
|
-
// this.hoveredIndex = null;
|
|
12513
|
-
}
|
|
12514
|
-
selectParentItem($event, option, parentOption) {
|
|
12515
|
-
$event.stopPropagation();
|
|
12516
|
-
if (parentOption?.children?.length)
|
|
12517
|
-
return;
|
|
12518
|
-
this.selectOption(option, parentOption);
|
|
12519
|
-
}
|
|
12520
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevDropdownMultiLevelComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12521
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevDropdownMultiLevelComponent, isStandalone: true, selector: "tc-rev-dropdown-multi-level", inputs: { menu: { classPropertyName: "menu", publicName: "menu", isSignal: true, isRequired: true, transformFunction: null }, subMenuPosition: { classPropertyName: "subMenuPosition", publicName: "subMenuPosition", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, initialValue: { classPropertyName: "initialValue", publicName: "initialValue", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { optionSelected: "optionSelected" }, host: { listeners: { "document:click": "onDocumentClick($event)" } }, viewQueries: [{ propertyName: "menuRoot", first: true, predicate: ["menuRoot"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div class=\"tc-rev-dropdown-multi-level\">\n <button\n class=\"tc-rev-btn tc-rev-btn--sm tc-rev-btn--dark-outline tc-rev-dropdown-toggle\"\n [class.tc-rev-btn--sm]=\"this.size() === dropdownSize.sm\"\n [class.tc-rev-btn--md]=\"this.size() === dropdownSize.md\"\n [class.tc-rev-btn--lg]=\"this.size() === dropdownSize.lg\"\n [class.active]=\"isOpen\"\n (click)=\"toggleDropdown()\"\n [class.disabled]=\"disabled()\">\n <ng-content></ng-content>\n </button>\n\n\t<ul class=\"tc-rev-dropdown-multi-level__menu-list\" #menuRoot>\n\t\t@if (isOpen)\n {\n @for (item of menu(); track $index; let i = $index)\n {\n <li \n class=\"menu-item\"\n [class.c-primary-500]=\"this.selectedParentOption()?.value === item?.value\"\n (mouseenter)=\"hoveredIndex = i\"\n (mouseleave)=\"hoveredIndex = null\"\n (click)=\"this.selectParentItem($event, item, item)\">\n {{ item.displayValue }}\n @if (this.selectedParentOption()?.value === item?.value)\n {\n <i class=\"fa-light fa-circle-check c-primary-500 mar-l-a\"></i>\n }\n @if (item?.children?.length && hoveredIndex === i)\n {\n <tc-rev-dropdown-sub-menu\n [items]=\"item.children\"\n [position]=\"subMenuPosition()\"\n [parentOffsetTop]=\"getItemOffsetTop(i)\"\n [selectedOption]=\"this.selectedOption()\"\n (onOptionSelected)=\"this.selectOption($event, item)\">\n </tc-rev-dropdown-sub-menu>\n }\n </li>\n }\n }\n\t</ul>\n</div>\n", styles: [":host{display:inline-block}.tc-rev-dropdown-multi-level{position:relative;display:inline-block}.tc-rev-dropdown-multi-level .tc-rev-dropdown-toggle{align-items:center;background-color:var(--c-neutral-50);display:inline-flex;font-family:var(--f-family);font-size:var(--f-size-14);font-weight:var(--f-weight-600);gap:var(--size-8);line-height:var(--l-height-20);outline:none;transition:.2s ease;padding:0 var(--size-16)}.tc-rev-dropdown-multi-level .tc-rev-dropdown-toggle.active{background-color:var(--c-neutral-500);color:var(--c-neutral-50);border-color:var(--c-neutral-700)}.tc-rev-dropdown-multi-level__menu-list{background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);box-shadow:var(--shadow-md);color:var(--c-neutral-700);left:0;list-style:none;margin:0;max-height:15.625rem;overflow-y:auto;padding:0;position:absolute;top:110%;width:100%;z-index:1000}.tc-rev-dropdown-multi-level__menu-list .menu-item{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-12);line-height:var(--l-height-16);height:var(--size-32);padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.tc-rev-dropdown-multi-level__menu-list .menu-item:hover{border-color:var(--c-primary-500);color:var(--c-primary-500)}.tc-rev-dropdown-multi-level__menu-list .menu-item.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown-multi-level__menu-list .menu-item:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}\n"], dependencies: [{ kind: "component", type: TcRevDropdownSubMenuComponent, selector: "tc-rev-dropdown-sub-menu", inputs: ["items", "position", "parentOffsetTop", "selectedOption"], outputs: ["onOptionSelected"] }] }); }
|
|
12522
|
-
}
|
|
12523
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevDropdownMultiLevelComponent, decorators: [{
|
|
12524
|
-
type: Component,
|
|
12525
|
-
args: [{ selector: 'tc-rev-dropdown-multi-level', imports: [
|
|
12526
|
-
TcRevDropdownSubMenuComponent
|
|
12527
|
-
], template: "<div class=\"tc-rev-dropdown-multi-level\">\n <button\n class=\"tc-rev-btn tc-rev-btn--sm tc-rev-btn--dark-outline tc-rev-dropdown-toggle\"\n [class.tc-rev-btn--sm]=\"this.size() === dropdownSize.sm\"\n [class.tc-rev-btn--md]=\"this.size() === dropdownSize.md\"\n [class.tc-rev-btn--lg]=\"this.size() === dropdownSize.lg\"\n [class.active]=\"isOpen\"\n (click)=\"toggleDropdown()\"\n [class.disabled]=\"disabled()\">\n <ng-content></ng-content>\n </button>\n\n\t<ul class=\"tc-rev-dropdown-multi-level__menu-list\" #menuRoot>\n\t\t@if (isOpen)\n {\n @for (item of menu(); track $index; let i = $index)\n {\n <li \n class=\"menu-item\"\n [class.c-primary-500]=\"this.selectedParentOption()?.value === item?.value\"\n (mouseenter)=\"hoveredIndex = i\"\n (mouseleave)=\"hoveredIndex = null\"\n (click)=\"this.selectParentItem($event, item, item)\">\n {{ item.displayValue }}\n @if (this.selectedParentOption()?.value === item?.value)\n {\n <i class=\"fa-light fa-circle-check c-primary-500 mar-l-a\"></i>\n }\n @if (item?.children?.length && hoveredIndex === i)\n {\n <tc-rev-dropdown-sub-menu\n [items]=\"item.children\"\n [position]=\"subMenuPosition()\"\n [parentOffsetTop]=\"getItemOffsetTop(i)\"\n [selectedOption]=\"this.selectedOption()\"\n (onOptionSelected)=\"this.selectOption($event, item)\">\n </tc-rev-dropdown-sub-menu>\n }\n </li>\n }\n }\n\t</ul>\n</div>\n", styles: [":host{display:inline-block}.tc-rev-dropdown-multi-level{position:relative;display:inline-block}.tc-rev-dropdown-multi-level .tc-rev-dropdown-toggle{align-items:center;background-color:var(--c-neutral-50);display:inline-flex;font-family:var(--f-family);font-size:var(--f-size-14);font-weight:var(--f-weight-600);gap:var(--size-8);line-height:var(--l-height-20);outline:none;transition:.2s ease;padding:0 var(--size-16)}.tc-rev-dropdown-multi-level .tc-rev-dropdown-toggle.active{background-color:var(--c-neutral-500);color:var(--c-neutral-50);border-color:var(--c-neutral-700)}.tc-rev-dropdown-multi-level__menu-list{background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);box-shadow:var(--shadow-md);color:var(--c-neutral-700);left:0;list-style:none;margin:0;max-height:15.625rem;overflow-y:auto;padding:0;position:absolute;top:110%;width:100%;z-index:1000}.tc-rev-dropdown-multi-level__menu-list .menu-item{align-items:center;background-color:transparent;border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);cursor:pointer;display:flex;justify-content:space-between;font-size:var(--f-size-12);line-height:var(--l-height-16);height:var(--size-32);padding:var(--size-8);text-align:left;text-wrap:nowrap;transition:.2s ease;width:100%}.tc-rev-dropdown-multi-level__menu-list .menu-item:hover{border-color:var(--c-primary-500);color:var(--c-primary-500)}.tc-rev-dropdown-multi-level__menu-list .menu-item.selected{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-primary-500);font-weight:var(--f-weight-700)}.tc-rev-dropdown-multi-level__menu-list .menu-item:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-500);cursor:not-allowed}\n"] }]
|
|
12528
|
-
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { onDocumentClick: [{
|
|
12529
|
-
type: HostListener,
|
|
12530
|
-
args: ['document:click', ['$event']]
|
|
12531
|
-
}], menuRoot: [{
|
|
12532
|
-
type: ViewChild,
|
|
12533
|
-
args: ['menuRoot', { static: false }]
|
|
12534
|
-
}], menu: [{ type: i0.Input, args: [{ isSignal: true, alias: "menu", required: true }] }], subMenuPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "subMenuPosition", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], initialValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialValue", required: false }] }], optionSelected: [{ type: i0.Output, args: ["optionSelected"] }] } });
|
|
12535
|
-
|
|
12536
|
-
/**
|
|
12537
|
-
*
|
|
12538
|
-
* @param echarts echars instance
|
|
12539
|
-
* @param chartData chart info to build the config
|
|
12540
|
-
* @returns a bar chart config for echarts with the given data
|
|
12541
|
-
*/
|
|
12542
|
-
function echartBarConfig(echarts, chartData) {
|
|
12543
|
-
const { xAxisName, xAxisLabels, seriesData, tooltipFormatter, yAxisLabelFormatter, xAxisLabelFormatter } = chartData;
|
|
12544
|
-
return {
|
|
12545
|
-
grid: {
|
|
12546
|
-
left: '6.5%',
|
|
12547
|
-
top: 48,
|
|
12548
|
-
right: '2%',
|
|
12549
|
-
bottom: 56
|
|
12550
|
-
},
|
|
12551
|
-
tooltip: {
|
|
12552
|
-
trigger: 'axis',
|
|
12553
|
-
backgroundColor: '#131313',
|
|
12554
|
-
formatter: tooltipFormatter,
|
|
12555
|
-
textStyle: {
|
|
12556
|
-
color: '#f3f3f3',
|
|
12557
|
-
fontSize: 12,
|
|
12558
|
-
fontFamily: 'Nunito Sans'
|
|
12559
|
-
}
|
|
12560
|
-
},
|
|
12561
|
-
xAxis: {
|
|
12562
|
-
type: 'category',
|
|
12563
|
-
axisLabel: {
|
|
12564
|
-
color: '#131313',
|
|
12565
|
-
fontSize: 14,
|
|
12566
|
-
fontFamily: 'Nunito Sans',
|
|
12567
|
-
margin: 16,
|
|
12568
|
-
formatter: xAxisLabelFormatter,
|
|
12569
|
-
},
|
|
12570
|
-
axisLine: {
|
|
12571
|
-
show: true,
|
|
12572
|
-
lineStyle: {
|
|
12573
|
-
color: '#BAC0C6'
|
|
12574
|
-
}
|
|
12575
|
-
},
|
|
12576
|
-
axisTick: {
|
|
12577
|
-
show: false
|
|
12578
|
-
},
|
|
12579
|
-
data: xAxisLabels,
|
|
12580
|
-
name: xAxisName,
|
|
12581
|
-
nameLocation: 'start',
|
|
12582
|
-
nameTextStyle: {
|
|
12583
|
-
align: 'left',
|
|
12584
|
-
color: '#131313',
|
|
12585
|
-
fontFamily: 'Nunito Sans',
|
|
12586
|
-
fontSize: 14,
|
|
12587
|
-
fontWeight: 700,
|
|
12588
|
-
padding: [0, 0, -46, -36]
|
|
12589
|
-
}
|
|
12590
|
-
},
|
|
12591
|
-
yAxis: {
|
|
12592
|
-
type: 'value',
|
|
12593
|
-
axisLine: {
|
|
12594
|
-
show: false
|
|
12595
|
-
},
|
|
12596
|
-
axisTick: {
|
|
12597
|
-
show: false
|
|
12598
|
-
},
|
|
12599
|
-
axisLabel: {
|
|
12600
|
-
formatter: yAxisLabelFormatter,
|
|
12601
|
-
align: 'left',
|
|
12602
|
-
color: '#131313',
|
|
12603
|
-
fontSize: 14,
|
|
12604
|
-
fontFamily: 'Nunito Sans',
|
|
12605
|
-
inside: false,
|
|
12606
|
-
padding: [-40, 0, 0, -40]
|
|
12607
|
-
}
|
|
12608
|
-
},
|
|
12609
|
-
series: seriesData.map((serie) => ({
|
|
12610
|
-
name: serie.serieName,
|
|
12611
|
-
type: 'bar',
|
|
12612
|
-
data: serie.values,
|
|
12613
|
-
itemStyle: {
|
|
12614
|
-
barBorderRadius: [8, 8, 8, 8],
|
|
12615
|
-
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
|
|
12616
|
-
{ offset: 0, color: '#0897E9' },
|
|
12617
|
-
{ offset: 1, color: '#75D8FF' }
|
|
12618
|
-
])
|
|
12619
|
-
}
|
|
12620
|
-
}))
|
|
12621
|
-
};
|
|
12622
|
-
}
|
|
12623
|
-
|
|
12624
|
-
class TcRevEmptyContentComponent {
|
|
12625
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevEmptyContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12626
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.17", type: TcRevEmptyContentComponent, isStandalone: true, selector: "tc-rev-empty-content", ngImport: i0, template: "<div class=\"tc-rev-empty-content f-family f-sm c-neutral-700 pad-x-16 pad-y-16 bg-c-neutral-200 bor-rad-8\">\n <ng-content></ng-content>\n</div>\n", styles: [""] }); }
|
|
12627
|
-
}
|
|
12628
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevEmptyContentComponent, decorators: [{
|
|
12629
|
-
type: Component,
|
|
12630
|
-
args: [{ selector: 'tc-rev-empty-content', imports: [], template: "<div class=\"tc-rev-empty-content f-family f-sm c-neutral-700 pad-x-16 pad-y-16 bg-c-neutral-200 bor-rad-8\">\n <ng-content></ng-content>\n</div>\n" }]
|
|
12631
|
-
}] });
|
|
12632
|
-
|
|
12633
|
-
class TcRevFaqComponent {
|
|
12634
|
-
constructor() {
|
|
12635
|
-
this.title = 'Dúvidas frequentes';
|
|
12636
|
-
this.questions = [];
|
|
12637
|
-
this.openIndex = signal(null, ...(ngDevMode ? [{ debugName: "openIndex" }] : /* istanbul ignore next */ []));
|
|
12638
|
-
}
|
|
12639
|
-
toggle(index) {
|
|
12640
|
-
if (this.openIndex() === index) {
|
|
12641
|
-
this.openIndex.set(null);
|
|
12642
|
-
}
|
|
12643
|
-
else {
|
|
12644
|
-
this.openIndex.set(index);
|
|
12645
|
-
}
|
|
12646
|
-
}
|
|
12647
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevFaqComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12648
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevFaqComponent, isStandalone: true, selector: "tc-rev-faq", inputs: { title: "title", questions: "questions" }, ngImport: i0, template: "<div class=\"tc-rev-faq\">\n <div class=\"tc-rev-faq-list\">\n @for (q of questions; track q; let i = $index) {\n <div\n class=\"tc-rev-faq-item f-family c-neutral-700 f-size-16\"\n [class.open]=\"openIndex() === i\"\n (click)=\"toggle(i)\"\n >\n <div class=\"tc-rev-faq-question\">\n <p>{{ q.question }}</p>\n <i class=\"fa-light fa-angle-down arrow\" [class.open]=\"openIndex() === i\"></i>\n </div>\n <div\n class=\"tc-rev-faq-answer\"\n >\n <p>{{ q.answer }}</p>\n </div>\n </div>\n }\n </div>\n</div>\n", styles: [":host{display:block}.tc-rev-faq{background-color:var(--c-neutral-50)}.tc-rev-faq .faq-header{display:flex;align-items:center;gap:.5rem;margin-bottom:1rem}.tc-rev-faq .faq-header .icon{width:48px;height:48px;background:var(--c-neutral-200);border-radius:var(--bor-radius-rounded);display:flex;align-items:center;justify-content:center;color:var(--c-neutral-700)}.tc-rev-faq .faq-header .icon i{font-size:1.5rem;color:var(--c-neutral-700)}.tc-rev-faq .faq-header h2{font-size:var(--f-size-20);font-weight:var(--f-weight-700);font-family:var(--f-family)}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item{border-top:1px solid var(--c-neutral-300);cursor:pointer;height:var(--size-56);overflow:hidden;padding:var(--size-16);transition:all .2s ease}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item.open{height:auto;overflow:visible}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item:first-child{border-top:none}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item .tc-rev-faq-question{display:flex;justify-content:space-between;align-items:center}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item .tc-rev-faq-question p{margin:0}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item .tc-rev-faq-question .arrow{transition:all .3s ease}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item .tc-rev-faq-question .arrow.open{transform:rotate(180deg)}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item .tc-rev-faq-answer{border:0;margin-top:1rem;padding:0}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item .tc-rev-faq-answer p{margin:0;line-height:1.6}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
12649
|
-
}
|
|
12650
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevFaqComponent, decorators: [{
|
|
12651
|
-
type: Component,
|
|
12652
|
-
args: [{ selector: 'tc-rev-faq', imports: [], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"tc-rev-faq\">\n <div class=\"tc-rev-faq-list\">\n @for (q of questions; track q; let i = $index) {\n <div\n class=\"tc-rev-faq-item f-family c-neutral-700 f-size-16\"\n [class.open]=\"openIndex() === i\"\n (click)=\"toggle(i)\"\n >\n <div class=\"tc-rev-faq-question\">\n <p>{{ q.question }}</p>\n <i class=\"fa-light fa-angle-down arrow\" [class.open]=\"openIndex() === i\"></i>\n </div>\n <div\n class=\"tc-rev-faq-answer\"\n >\n <p>{{ q.answer }}</p>\n </div>\n </div>\n }\n </div>\n</div>\n", styles: [":host{display:block}.tc-rev-faq{background-color:var(--c-neutral-50)}.tc-rev-faq .faq-header{display:flex;align-items:center;gap:.5rem;margin-bottom:1rem}.tc-rev-faq .faq-header .icon{width:48px;height:48px;background:var(--c-neutral-200);border-radius:var(--bor-radius-rounded);display:flex;align-items:center;justify-content:center;color:var(--c-neutral-700)}.tc-rev-faq .faq-header .icon i{font-size:1.5rem;color:var(--c-neutral-700)}.tc-rev-faq .faq-header h2{font-size:var(--f-size-20);font-weight:var(--f-weight-700);font-family:var(--f-family)}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item{border-top:1px solid var(--c-neutral-300);cursor:pointer;height:var(--size-56);overflow:hidden;padding:var(--size-16);transition:all .2s ease}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item.open{height:auto;overflow:visible}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item:first-child{border-top:none}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item .tc-rev-faq-question{display:flex;justify-content:space-between;align-items:center}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item .tc-rev-faq-question p{margin:0}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item .tc-rev-faq-question .arrow{transition:all .3s ease}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item .tc-rev-faq-question .arrow.open{transform:rotate(180deg)}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item .tc-rev-faq-answer{border:0;margin-top:1rem;padding:0}.tc-rev-faq .tc-rev-faq-list .tc-rev-faq-item .tc-rev-faq-answer p{margin:0;line-height:1.6}\n"] }]
|
|
12653
|
-
}], propDecorators: { title: [{
|
|
12654
|
-
type: Input
|
|
12655
|
-
}], questions: [{
|
|
12656
|
-
type: Input
|
|
12657
|
-
}] } });
|
|
12658
|
-
|
|
12659
|
-
class TcRevInputContainerComponent {
|
|
12660
|
-
constructor() {
|
|
12661
|
-
this.fullWidth = input(false, ...(ngDevMode ? [{ debugName: "fullWidth" }] : /* istanbul ignore next */ []));
|
|
12662
|
-
this.inputId = input('', ...(ngDevMode ? [{ debugName: "inputId" }] : /* istanbul ignore next */ []));
|
|
12663
|
-
this.label = input('', ...(ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ []));
|
|
12664
|
-
this.labelPosition = input('top', ...(ngDevMode ? [{ debugName: "labelPosition" }] : /* istanbul ignore next */ []));
|
|
12665
|
-
this.required = input(false, ...(ngDevMode ? [{ debugName: "required" }] : /* istanbul ignore next */ []));
|
|
12666
|
-
}
|
|
12667
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevInputContainerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12668
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevInputContainerComponent, isStandalone: true, selector: "tc-rev-input-container", inputs: { fullWidth: { classPropertyName: "fullWidth", publicName: "fullWidth", isSignal: true, isRequired: false, transformFunction: null }, inputId: { classPropertyName: "inputId", publicName: "inputId", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, labelPosition: { classPropertyName: "labelPosition", publicName: "labelPosition", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div\n class=\"{{ 'tc-rev-input-container ' + 'label-' + this.labelPosition() }}\"\n [class.full-width]=\"this.fullWidth()\">\n @if (this.label()) {\n @if (this.inputId()) {\n <label\n class=\"tc-rev-input-label cursor-pointer\" [for]=\"this.inputId()\">\n {{this.label()}}\n @if (this.required()) {\n <ng-container *ngTemplateOutlet=\"required\" />\n }\n </label>\n }\n @else {\n <label\n class=\"tc-rev-input-label\">\n {{this.label()}}\n @if (this.required()) {\n <ng-container *ngTemplateOutlet=\"required\" />\n }\n </label>\n }\n }\n <ng-content />\n</div>\n\n\n<ng-template #required>\n <span class=\"c-danger-500\">*</span>\n</ng-template>\n", styles: [":host{display:block}.tc-rev-input-container{display:inline-flex;gap:var(--size-4)}.tc-rev-input-container.full-width{width:100%}.tc-rev-input-container .tc-rev-input-label{font-family:var(--f-family);font-size:var(--f-size-14);font-weight:var(--f-weight-600);color:var(--c-neutral-700);line-height:var(--l-height-20);margin:0}.tc-rev-input-container.label-top{flex-direction:column}.tc-rev-input-container.label-right{align-items:center;flex-direction:row-reverse}.tc-rev-input-container.label-bottom{flex-direction:column-reverse}.tc-rev-input-container.label-left{align-items:center;flex-direction:row}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] }); }
|
|
12669
|
-
}
|
|
12670
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevInputContainerComponent, decorators: [{
|
|
12671
|
-
type: Component,
|
|
12672
|
-
args: [{ selector: 'tc-rev-input-container', imports: [CommonModule], template: "<div\n class=\"{{ 'tc-rev-input-container ' + 'label-' + this.labelPosition() }}\"\n [class.full-width]=\"this.fullWidth()\">\n @if (this.label()) {\n @if (this.inputId()) {\n <label\n class=\"tc-rev-input-label cursor-pointer\" [for]=\"this.inputId()\">\n {{this.label()}}\n @if (this.required()) {\n <ng-container *ngTemplateOutlet=\"required\" />\n }\n </label>\n }\n @else {\n <label\n class=\"tc-rev-input-label\">\n {{this.label()}}\n @if (this.required()) {\n <ng-container *ngTemplateOutlet=\"required\" />\n }\n </label>\n }\n }\n <ng-content />\n</div>\n\n\n<ng-template #required>\n <span class=\"c-danger-500\">*</span>\n</ng-template>\n", styles: [":host{display:block}.tc-rev-input-container{display:inline-flex;gap:var(--size-4)}.tc-rev-input-container.full-width{width:100%}.tc-rev-input-container .tc-rev-input-label{font-family:var(--f-family);font-size:var(--f-size-14);font-weight:var(--f-weight-600);color:var(--c-neutral-700);line-height:var(--l-height-20);margin:0}.tc-rev-input-container.label-top{flex-direction:column}.tc-rev-input-container.label-right{align-items:center;flex-direction:row-reverse}.tc-rev-input-container.label-bottom{flex-direction:column-reverse}.tc-rev-input-container.label-left{align-items:center;flex-direction:row}\n"] }]
|
|
12673
|
-
}], propDecorators: { fullWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "fullWidth", required: false }] }], inputId: [{ type: i0.Input, args: [{ isSignal: true, alias: "inputId", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], labelPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "labelPosition", required: false }] }], required: [{ type: i0.Input, args: [{ isSignal: true, alias: "required", required: false }] }] } });
|
|
12674
|
-
|
|
12675
|
-
class TcRevInputDirective {
|
|
12676
|
-
constructor(_el) {
|
|
12677
|
-
this._el = _el;
|
|
12678
|
-
this.fullWidth = input(false, ...(ngDevMode ? [{ debugName: "fullWidth" }] : /* istanbul ignore next */ []));
|
|
12679
|
-
effect(() => {
|
|
12680
|
-
this.setClasses();
|
|
12681
|
-
});
|
|
12682
|
-
}
|
|
12683
|
-
setClasses() {
|
|
12684
|
-
this.fullWidth() ? this._el.nativeElement.classList.add('tc-rev-input-control--full-width') : null;
|
|
12685
|
-
}
|
|
12686
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevInputDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
12687
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.17", type: TcRevInputDirective, isStandalone: true, selector: "input[tcRevInput], select[tcRevInput]", inputs: { fullWidth: { classPropertyName: "fullWidth", publicName: "fullWidth", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "tc-rev-input-control" }, ngImport: i0 }); }
|
|
12688
|
-
}
|
|
12689
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevInputDirective, decorators: [{
|
|
12690
|
-
type: Directive,
|
|
12691
|
-
args: [{
|
|
12692
|
-
selector: 'input[tcRevInput], select[tcRevInput]',
|
|
12693
|
-
host: {
|
|
12694
|
-
class: 'tc-rev-input-control'
|
|
12695
|
-
}
|
|
12696
|
-
}]
|
|
12697
|
-
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { fullWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "fullWidth", required: false }] }] } });
|
|
12698
|
-
|
|
12699
|
-
class TcRevLoadingComponent {
|
|
12700
|
-
constructor() {
|
|
12701
|
-
this.message = input('Carregando', ...(ngDevMode ? [{ debugName: "message" }] : /* istanbul ignore next */ []));
|
|
12702
|
-
}
|
|
12703
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevLoadingComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12704
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.17", type: TcRevLoadingComponent, isStandalone: true, selector: "tc-rev-loading", inputs: { message: { classPropertyName: "message", publicName: "message", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"tc-rev-loading-overlay\">\n <div class=\"tc-rev-loading-container\">\n <span\n class=\"tc-rev-loading-spinner\">\n </span>\n <p class=\"tc-rev-loading-message\">{{message()}}...</p>\n </div>\n</div>\n", styles: ["@keyframes rotation{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.tc-rev-loading-overlay{background:#00000080;display:grid;inset:0;place-items:center;position:fixed;z-index:1000}.tc-rev-loading-overlay .tc-rev-loading-container{align-items:center;display:flex;flex-direction:column;gap:.5rem}.tc-rev-loading-overlay .tc-rev-loading-container .tc-rev-loading-spinner{animation:rotation 1s linear infinite;border:8px solid var(--c-neutral-200);border-bottom-color:var(--c-neutral-500);border-radius:50%;box-sizing:border-box;display:block;height:8rem;width:8rem}.tc-rev-loading-overlay .tc-rev-loading-container .tc-rev-loading-message{background-color:var(--c-neutral-600);border-radius:var(--bor-radius-8);color:var(--c-neutral-50);font-family:var(--f-family);font-size:var(--f-size-16);margin:var(--size-12) 0 0 0;padding:var(--size-4) var(--size-12)}\n"] }); }
|
|
12705
|
-
}
|
|
12706
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevLoadingComponent, decorators: [{
|
|
12707
|
-
type: Component,
|
|
12708
|
-
args: [{ selector: 'tc-rev-loading', imports: [], template: "<div class=\"tc-rev-loading-overlay\">\n <div class=\"tc-rev-loading-container\">\n <span\n class=\"tc-rev-loading-spinner\">\n </span>\n <p class=\"tc-rev-loading-message\">{{message()}}...</p>\n </div>\n</div>\n", styles: ["@keyframes rotation{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.tc-rev-loading-overlay{background:#00000080;display:grid;inset:0;place-items:center;position:fixed;z-index:1000}.tc-rev-loading-overlay .tc-rev-loading-container{align-items:center;display:flex;flex-direction:column;gap:.5rem}.tc-rev-loading-overlay .tc-rev-loading-container .tc-rev-loading-spinner{animation:rotation 1s linear infinite;border:8px solid var(--c-neutral-200);border-bottom-color:var(--c-neutral-500);border-radius:50%;box-sizing:border-box;display:block;height:8rem;width:8rem}.tc-rev-loading-overlay .tc-rev-loading-container .tc-rev-loading-message{background-color:var(--c-neutral-600);border-radius:var(--bor-radius-8);color:var(--c-neutral-50);font-family:var(--f-family);font-size:var(--f-size-16);margin:var(--size-12) 0 0 0;padding:var(--size-4) var(--size-12)}\n"] }]
|
|
12709
|
-
}], propDecorators: { message: [{ type: i0.Input, args: [{ isSignal: true, alias: "message", required: false }] }] } });
|
|
12710
|
-
|
|
12711
|
-
class TcRevMessageComponent {
|
|
12712
|
-
constructor() {
|
|
12713
|
-
this.message = '';
|
|
12714
|
-
this.type = 'info';
|
|
12715
|
-
}
|
|
12716
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevMessageComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12717
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevMessageComponent, isStandalone: true, selector: "tc-rev-message", inputs: { message: "message", type: "type" }, ngImport: i0, template: "@if (message) {\n <div class=\"message\" [ngClass]=\"type\">\n <i class=\"icon fas\" [ngClass]=\"{\n 'fa-check': type === 'success',\n 'fa-times': type === 'error',\n 'fa-info-circle': type === 'info',\n 'fa-exclamation-triangle': type === 'warning'\n }\"></i>\n <i class=\"text\">{{ message }}</i>\n </div>\n}\n", styles: [":host{display:block}.message{padding:.75rem 1rem;border-radius:6px;font-size:14px;display:flex;align-items:center;gap:.5rem;margin:8px 0}.message.success{background-color:var(--c-success-300);color:var(--c-success-500);border:1px solid var(--c-success-300)}.message.error{background-color:var(--c-danger-300);color:var(--c-danger-500);border:1px solid var(--c-danger-300)}.message.info{background-color:var(--c-info-300);color:var(--c-info-500);border:1px solid var(--c-info-300)}.message.warning{background-color:var(--c-alert-300);color:var(--c-alert-500);border:1px solid var(--c-alert-300)}.message .icon{font-size:16px}.message .text{flex:1;font-style:normal}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
12718
|
-
}
|
|
12719
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevMessageComponent, decorators: [{
|
|
12720
|
-
type: Component,
|
|
12721
|
-
args: [{ selector: 'tc-rev-message', standalone: true, imports: [CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (message) {\n <div class=\"message\" [ngClass]=\"type\">\n <i class=\"icon fas\" [ngClass]=\"{\n 'fa-check': type === 'success',\n 'fa-times': type === 'error',\n 'fa-info-circle': type === 'info',\n 'fa-exclamation-triangle': type === 'warning'\n }\"></i>\n <i class=\"text\">{{ message }}</i>\n </div>\n}\n", styles: [":host{display:block}.message{padding:.75rem 1rem;border-radius:6px;font-size:14px;display:flex;align-items:center;gap:.5rem;margin:8px 0}.message.success{background-color:var(--c-success-300);color:var(--c-success-500);border:1px solid var(--c-success-300)}.message.error{background-color:var(--c-danger-300);color:var(--c-danger-500);border:1px solid var(--c-danger-300)}.message.info{background-color:var(--c-info-300);color:var(--c-info-500);border:1px solid var(--c-info-300)}.message.warning{background-color:var(--c-alert-300);color:var(--c-alert-500);border:1px solid var(--c-alert-300)}.message .icon{font-size:16px}.message .text{flex:1;font-style:normal}\n"] }]
|
|
12722
|
-
}], propDecorators: { message: [{
|
|
12723
|
-
type: Input
|
|
12724
|
-
}], type: [{
|
|
12725
|
-
type: Input
|
|
12726
|
-
}] } });
|
|
12727
|
-
|
|
12728
|
-
class TcRevMultiInputComponent {
|
|
12729
|
-
constructor() {
|
|
12730
|
-
this.autoFocus = false;
|
|
12731
|
-
this.initialValue = input('', ...(ngDevMode ? [{ debugName: "initialValue" }] : /* istanbul ignore next */ []));
|
|
12732
|
-
this.description = input('', ...(ngDevMode ? [{ debugName: "description" }] : /* istanbul ignore next */ []));
|
|
12733
|
-
this.initialList = input([], ...(ngDevMode ? [{ debugName: "initialList" }] : /* istanbul ignore next */ [])); // Deprecated - use items instead
|
|
12734
|
-
this.items = model([], ...(ngDevMode ? [{ debugName: "items" }] : /* istanbul ignore next */ [])); // Two-way binding para a lista de itens
|
|
12735
|
-
this.validators = input([], ...(ngDevMode ? [{ debugName: "validators" }] : /* istanbul ignore next */ []));
|
|
12736
|
-
this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
|
|
12737
|
-
this.itemsList = signal([], ...(ngDevMode ? [{ debugName: "itemsList" }] : /* istanbul ignore next */ []));
|
|
12738
|
-
this.onChangeList = output();
|
|
12739
|
-
effect(() => {
|
|
12740
|
-
this.disabled() ? this.multiInputForm?.get('multiInput')?.disable() : this.multiInputForm?.get('multiInput')?.enable();
|
|
12741
|
-
});
|
|
12742
|
-
}
|
|
12743
|
-
ngOnInit() {
|
|
12744
|
-
this.multiInputForm = new FormGroup({
|
|
12745
|
-
multiInput: new FormControl('', [Validators.required, ...this.validators()])
|
|
12746
|
-
});
|
|
12747
|
-
// Prioriza os itens do model, mas mantém compatibilidade com initialList
|
|
12748
|
-
const itemsToUse = this.items().length > 0 ? this.items() : this.initialList();
|
|
12749
|
-
if (itemsToUse?.length) {
|
|
12750
|
-
this.itemsList.set([...itemsToUse]);
|
|
12751
|
-
}
|
|
12752
|
-
// Se não havia itens no model mas havia initialList, sincroniza o model
|
|
12753
|
-
if (this.items().length === 0 && this.initialList().length > 0) {
|
|
12754
|
-
this.items.set([...this.initialList()]);
|
|
12755
|
-
}
|
|
12756
|
-
// Escuta mudanças no model e atualiza a lista interna
|
|
12757
|
-
this.items.subscribe((newItems) => {
|
|
12758
|
-
// Só atualiza se realmente mudou para evitar loops
|
|
12759
|
-
const currentItems = this.itemsList();
|
|
12760
|
-
if (JSON.stringify(currentItems) !== JSON.stringify(newItems)) {
|
|
12761
|
-
this.itemsList.set([...newItems]);
|
|
12762
|
-
}
|
|
12763
|
-
});
|
|
12764
|
-
setTimeout(() => {
|
|
12765
|
-
if (this.initialValue() !== '') {
|
|
12766
|
-
this.autoFocus = true;
|
|
12767
|
-
this.multiInputForm?.get('multiInput')?.setValue(this.initialValue());
|
|
12768
|
-
}
|
|
12769
|
-
});
|
|
12770
|
-
}
|
|
12771
|
-
ngAfterViewInit() {
|
|
12772
|
-
setTimeout(() => {
|
|
12773
|
-
if (this.autoFocus) {
|
|
12774
|
-
this.multiInputRef?.nativeElement?.focus();
|
|
12775
|
-
}
|
|
12776
|
-
}, 0);
|
|
12777
|
-
}
|
|
12778
|
-
isEllipsed(text) {
|
|
12779
|
-
return isTextEllipsed(text);
|
|
12780
|
-
}
|
|
12781
|
-
addItem() {
|
|
12782
|
-
const newItem = this.multiInputForm?.get('multiInput').value;
|
|
12783
|
-
this.itemsList.update((currentItems) => {
|
|
12784
|
-
const updatedItems = currentItems.includes(newItem)
|
|
12785
|
-
? currentItems
|
|
12786
|
-
: [...currentItems, newItem];
|
|
12787
|
-
// Atualiza o model com two-way binding
|
|
12788
|
-
this.items.set([...updatedItems]);
|
|
12789
|
-
this.onChangeList.emit(updatedItems);
|
|
12790
|
-
return updatedItems;
|
|
12791
|
-
});
|
|
12792
|
-
this.multiInputForm?.reset();
|
|
12793
|
-
}
|
|
12794
|
-
removeItem(index) {
|
|
12795
|
-
this.itemsList.update((currentItems) => {
|
|
12796
|
-
const newItems = [...currentItems];
|
|
12797
|
-
newItems.splice(index, 1);
|
|
12798
|
-
// Atualiza o model com two-way binding
|
|
12799
|
-
this.items.set([...newItems]);
|
|
12800
|
-
this.onChangeList.emit(newItems);
|
|
12801
|
-
return newItems;
|
|
12802
|
-
});
|
|
12803
|
-
}
|
|
12804
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevMultiInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12805
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevMultiInputComponent, isStandalone: true, selector: "tc-rev-multi-input", inputs: { autoFocus: { classPropertyName: "autoFocus", publicName: "autoFocus", isSignal: false, isRequired: false, transformFunction: null }, initialValue: { classPropertyName: "initialValue", publicName: "initialValue", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null }, initialList: { classPropertyName: "initialList", publicName: "initialList", isSignal: true, isRequired: false, transformFunction: null }, items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: false, transformFunction: null }, validators: { classPropertyName: "validators", publicName: "validators", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { items: "itemsChange", onChangeList: "onChangeList" }, viewQueries: [{ propertyName: "multiInputRef", first: true, predicate: ["multiInputRef "], descendants: true }], ngImport: i0, template: "<div class=\"tc-rev-multi-input\">\n\t<div class=\"tc-rev-multi-input__input-container\">\n\t\t<form\n [formGroup]=\"multiInputForm\"\n (ngSubmit)=\"addItem()\">\n\n <input\n #multiInputRef\n type=\"text\"\n class=\"tc-rev-input-control\"\n formControlName=\"multiInput\"\n />\n\n <button\n class=\"tc-rev-btn tc-rev-btn--sm tc-rev-btn--primary-filled add-button\"\n type=\"submit\"\n [disabled]=\"multiInputForm.invalid || disabled()\">\n\t\t\t\tAdicionar\n\t\t\t</button>\n\t\t</form>\n\t</div>\n\n\t@if (description()) {\n <span class=\"description f-sm c-neutral-700 mar-t-4 mar-b-16 d-block\">\n {{ description() }}\n </span>\n\t}\n\n @if (itemsList().length > 0) {\n <div class=\"tc-rev-multi-input__added-list\">\n @for (item of itemsList(); track item; let i = $index) {\n <div class=\"list-item h-28 pad-x-8 f-md f-weight-500 bor-rad-4 bg-c-neutral-100\">\n <span\n class=\"c-primary-500 mar-r-4 list-item__text\"\n [tcRevTooltip]=\"isEllipsed(item) ? item : ''\"\n position=\"top\">{{ item }}</span>\n\n <button class=\"h-24 w-24 d-inline-block cursor-pointer bg-c-transparent c-neutral-700 bor-none\" (click)=\"removeItem(i)\">\n <i class=\"fa-solid fa-times\"></i>\n </button>\n </div>\n }\n </div>\n }\n</div>\n", styles: [":host{display:block}.tc-rev-multi-input__input-container{height:var(--size-40);position:relative}.tc-rev-multi-input__input-container .tc-rev-input-control{height:var(--size-40);position:absolute;top:0;left:0;width:100%;z-index:1}.tc-rev-multi-input__input-container .add-button{display:block;height:var(--size-34);min-height:var(--size-34);max-height:var(--size-34);position:absolute;right:3px;top:3px;width:6.125rem;z-index:2}.tc-rev-multi-input__added-list{display:flex;flex-wrap:wrap;gap:8px;margin-top:8px}.tc-rev-multi-input__added-list .list-item{align-content:center;max-width:12.5rem;display:flex;align-items:center}.tc-rev-multi-input__added-list .list-item__text{flex:1;max-width:calc(100% - 1.75rem);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}\n"], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.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.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: TcRevTooltipDirective, selector: "[tcRevTooltip]", inputs: ["tcRevTooltip", "position"] }] }); }
|
|
12806
|
-
}
|
|
12807
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevMultiInputComponent, decorators: [{
|
|
12808
|
-
type: Component,
|
|
12809
|
-
args: [{ selector: 'tc-rev-multi-input', imports: [
|
|
12810
|
-
ReactiveFormsModule,
|
|
12811
|
-
TcRevTooltipDirective
|
|
12812
|
-
], template: "<div class=\"tc-rev-multi-input\">\n\t<div class=\"tc-rev-multi-input__input-container\">\n\t\t<form\n [formGroup]=\"multiInputForm\"\n (ngSubmit)=\"addItem()\">\n\n <input\n #multiInputRef\n type=\"text\"\n class=\"tc-rev-input-control\"\n formControlName=\"multiInput\"\n />\n\n <button\n class=\"tc-rev-btn tc-rev-btn--sm tc-rev-btn--primary-filled add-button\"\n type=\"submit\"\n [disabled]=\"multiInputForm.invalid || disabled()\">\n\t\t\t\tAdicionar\n\t\t\t</button>\n\t\t</form>\n\t</div>\n\n\t@if (description()) {\n <span class=\"description f-sm c-neutral-700 mar-t-4 mar-b-16 d-block\">\n {{ description() }}\n </span>\n\t}\n\n @if (itemsList().length > 0) {\n <div class=\"tc-rev-multi-input__added-list\">\n @for (item of itemsList(); track item; let i = $index) {\n <div class=\"list-item h-28 pad-x-8 f-md f-weight-500 bor-rad-4 bg-c-neutral-100\">\n <span\n class=\"c-primary-500 mar-r-4 list-item__text\"\n [tcRevTooltip]=\"isEllipsed(item) ? item : ''\"\n position=\"top\">{{ item }}</span>\n\n <button class=\"h-24 w-24 d-inline-block cursor-pointer bg-c-transparent c-neutral-700 bor-none\" (click)=\"removeItem(i)\">\n <i class=\"fa-solid fa-times\"></i>\n </button>\n </div>\n }\n </div>\n }\n</div>\n", styles: [":host{display:block}.tc-rev-multi-input__input-container{height:var(--size-40);position:relative}.tc-rev-multi-input__input-container .tc-rev-input-control{height:var(--size-40);position:absolute;top:0;left:0;width:100%;z-index:1}.tc-rev-multi-input__input-container .add-button{display:block;height:var(--size-34);min-height:var(--size-34);max-height:var(--size-34);position:absolute;right:3px;top:3px;width:6.125rem;z-index:2}.tc-rev-multi-input__added-list{display:flex;flex-wrap:wrap;gap:8px;margin-top:8px}.tc-rev-multi-input__added-list .list-item{align-content:center;max-width:12.5rem;display:flex;align-items:center}.tc-rev-multi-input__added-list .list-item__text{flex:1;max-width:calc(100% - 1.75rem);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}\n"] }]
|
|
12813
|
-
}], ctorParameters: () => [], propDecorators: { autoFocus: [{
|
|
12814
|
-
type: Input
|
|
12815
|
-
}], initialValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialValue", required: false }] }], description: [{ type: i0.Input, args: [{ isSignal: true, alias: "description", required: false }] }], initialList: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialList", required: false }] }], items: [{ type: i0.Input, args: [{ isSignal: true, alias: "items", required: false }] }, { type: i0.Output, args: ["itemsChange"] }], validators: [{ type: i0.Input, args: [{ isSignal: true, alias: "validators", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], onChangeList: [{ type: i0.Output, args: ["onChangeList"] }], multiInputRef: [{
|
|
12816
|
-
type: ViewChild,
|
|
12817
|
-
args: ['multiInputRef ']
|
|
12818
|
-
}] } });
|
|
12819
|
-
|
|
12820
|
-
class TcRevPaginationComponent {
|
|
12821
|
-
constructor() {
|
|
12822
|
-
this.currentPage = 1;
|
|
12823
|
-
this.totalPages = 1;
|
|
12824
|
-
this.pageChange = new EventEmitter();
|
|
12825
|
-
this.pageInputError = false;
|
|
12826
|
-
}
|
|
12827
|
-
previous() {
|
|
12828
|
-
if (this.currentPage > 1) {
|
|
12829
|
-
this.currentPage--;
|
|
12830
|
-
this.pageChange.emit(this.currentPage);
|
|
12831
|
-
}
|
|
12832
|
-
}
|
|
12833
|
-
next() {
|
|
12834
|
-
if (this.currentPage < this.totalPages) {
|
|
12835
|
-
this.currentPage++;
|
|
12836
|
-
this.pageChange.emit(this.currentPage);
|
|
12837
|
-
}
|
|
12838
|
-
}
|
|
12839
|
-
goToPage(event) {
|
|
12840
|
-
const input = event.target;
|
|
12841
|
-
const value = input.value;
|
|
12842
|
-
let pageNumber = parseInt(value.replace(/^0+/, ''), 10);
|
|
12843
|
-
if (isNaN(pageNumber) || pageNumber < 1 || pageNumber > this.totalPages) {
|
|
12844
|
-
this.pageInputError = true;
|
|
12845
|
-
if (isNaN(pageNumber) || pageNumber < 1) {
|
|
12846
|
-
pageNumber = 1;
|
|
12847
|
-
}
|
|
12848
|
-
else if (pageNumber > this.totalPages) {
|
|
12849
|
-
pageNumber = this.totalPages;
|
|
12850
|
-
}
|
|
12851
|
-
}
|
|
12852
|
-
else {
|
|
12853
|
-
this.pageInputError = false;
|
|
12854
|
-
}
|
|
12855
|
-
input.value = this.formatPage(pageNumber);
|
|
12856
|
-
if (pageNumber !== this.currentPage) {
|
|
12857
|
-
this.currentPage = pageNumber;
|
|
12858
|
-
this.pageChange.emit(this.currentPage);
|
|
12859
|
-
}
|
|
12860
|
-
}
|
|
12861
|
-
formatPage(page) {
|
|
12862
|
-
return page < 10 ? `0${page}` : `${page}`;
|
|
12863
|
-
}
|
|
12864
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevPaginationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12865
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.17", type: TcRevPaginationComponent, isStandalone: true, selector: "tc-rev-pagination", inputs: { currentPage: "currentPage", totalPages: "totalPages" }, outputs: { pageChange: "pageChange" }, ngImport: i0, template: "<div class=\"pagination-container\">\n\t<button class=\"arrow\" [disabled]=\"currentPage === 1\" (click)=\"previous()\"><i class=\"fas fa-angle-left\"></i></button>\n\n\t<span class=\"label f-family f-weight-600 f-size-14 c-neutral-700\">P\u00E1gina</span>\n\n\t<div class=\"page-input-container\">\n\t\t<input\n\t\t\ttype=\"text\"\n\t\t\tclass=\"page-input\"\n\t\t\t[ngClass]=\"{'error': pageInputError}\"\n\t\t\t[value]=\"formatPage(currentPage)\"\n\t\t\t(keyup.enter)=\"goToPage($event)\"\n\t\t\t(blur)=\"goToPage($event)\"\n\t\t/>\n\t</div>\n\n\t<span class=\"label f-family f-weight-600 f-size-14 c-neutral-700\">de {{ totalPages }}</span>\n\n\t<button class=\"arrow\" [disabled]=\"currentPage === totalPages\" (click)=\"next()\"><i class=\"fas fa-angle-right\"></i></button>\n</div>\n", styles: [":host{display:block}.pagination-container{display:flex;align-items:center;gap:8px;font-family:var(--f-family);justify-content:center}.pagination-container .label{color:var(--c-neutral-700)}.pagination-container .page-input-container{position:relative;width:48px;height:32px}.pagination-container .page-input{width:100%;height:100%;padding:var(--size-4) var(--size-8);border:1px solid var(--c-neutral-300);border-radius:var(--bor-radius-8);font-size:var(--f-size-14);font-family:var(--f-family);font-weight:var(--f-weight-600);color:var(--c-neutral-700);text-align:center;background-color:var(--c-neutral-50);outline:none;transition:border-color .2s ease}.pagination-container .page-input:focus:not(.error){border-color:var(--c-primary-500)}.pagination-container .page-input.error{border-color:var(--c-danger-500)}.pagination-container .page-input.error:focus{border-color:var(--c-danger-500)}.pagination-container .arrow{background-color:var(--c-neutral-100);border:1px solid var(--c-neutral-300);border-radius:var(--bor-radius-8);width:32px;height:32px;font-size:var(--f-size-16);color:var(--c-neutral-300);cursor:pointer;transition:all .2s ease;display:flex;align-items:center;justify-content:center}.pagination-container .arrow:disabled{cursor:not-allowed;opacity:.5}.pagination-container .arrow:hover:not(:disabled){background-color:var(--c-primary-100);border-color:var(--c-primary-300);color:var(--c-primary-500)}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
12866
|
-
}
|
|
12867
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevPaginationComponent, decorators: [{
|
|
12868
|
-
type: Component,
|
|
12869
|
-
args: [{ selector: 'tc-rev-pagination', imports: [CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, template: "<div class=\"pagination-container\">\n\t<button class=\"arrow\" [disabled]=\"currentPage === 1\" (click)=\"previous()\"><i class=\"fas fa-angle-left\"></i></button>\n\n\t<span class=\"label f-family f-weight-600 f-size-14 c-neutral-700\">P\u00E1gina</span>\n\n\t<div class=\"page-input-container\">\n\t\t<input\n\t\t\ttype=\"text\"\n\t\t\tclass=\"page-input\"\n\t\t\t[ngClass]=\"{'error': pageInputError}\"\n\t\t\t[value]=\"formatPage(currentPage)\"\n\t\t\t(keyup.enter)=\"goToPage($event)\"\n\t\t\t(blur)=\"goToPage($event)\"\n\t\t/>\n\t</div>\n\n\t<span class=\"label f-family f-weight-600 f-size-14 c-neutral-700\">de {{ totalPages }}</span>\n\n\t<button class=\"arrow\" [disabled]=\"currentPage === totalPages\" (click)=\"next()\"><i class=\"fas fa-angle-right\"></i></button>\n</div>\n", styles: [":host{display:block}.pagination-container{display:flex;align-items:center;gap:8px;font-family:var(--f-family);justify-content:center}.pagination-container .label{color:var(--c-neutral-700)}.pagination-container .page-input-container{position:relative;width:48px;height:32px}.pagination-container .page-input{width:100%;height:100%;padding:var(--size-4) var(--size-8);border:1px solid var(--c-neutral-300);border-radius:var(--bor-radius-8);font-size:var(--f-size-14);font-family:var(--f-family);font-weight:var(--f-weight-600);color:var(--c-neutral-700);text-align:center;background-color:var(--c-neutral-50);outline:none;transition:border-color .2s ease}.pagination-container .page-input:focus:not(.error){border-color:var(--c-primary-500)}.pagination-container .page-input.error{border-color:var(--c-danger-500)}.pagination-container .page-input.error:focus{border-color:var(--c-danger-500)}.pagination-container .arrow{background-color:var(--c-neutral-100);border:1px solid var(--c-neutral-300);border-radius:var(--bor-radius-8);width:32px;height:32px;font-size:var(--f-size-16);color:var(--c-neutral-300);cursor:pointer;transition:all .2s ease;display:flex;align-items:center;justify-content:center}.pagination-container .arrow:disabled{cursor:not-allowed;opacity:.5}.pagination-container .arrow:hover:not(:disabled){background-color:var(--c-primary-100);border-color:var(--c-primary-300);color:var(--c-primary-500)}\n"] }]
|
|
12870
|
-
}], propDecorators: { currentPage: [{
|
|
12871
|
-
type: Input
|
|
12872
|
-
}], totalPages: [{
|
|
12873
|
-
type: Input
|
|
12874
|
-
}], pageChange: [{
|
|
12875
|
-
type: Output
|
|
12876
|
-
}] } });
|
|
12877
|
-
|
|
12878
|
-
var ProgressStatusBarGradientStatus;
|
|
12879
|
-
(function (ProgressStatusBarGradientStatus) {
|
|
12880
|
-
ProgressStatusBarGradientStatus["info"] = "info";
|
|
12881
|
-
ProgressStatusBarGradientStatus["danger"] = "danger";
|
|
12882
|
-
ProgressStatusBarGradientStatus["success"] = "success";
|
|
12883
|
-
ProgressStatusBarGradientStatus["alert"] = "alert";
|
|
12884
|
-
})(ProgressStatusBarGradientStatus || (ProgressStatusBarGradientStatus = {}));
|
|
12885
|
-
var ProgressStatusBarRangeColor;
|
|
12886
|
-
(function (ProgressStatusBarRangeColor) {
|
|
12887
|
-
ProgressStatusBarRangeColor["dangerStart"] = "#F48E85";
|
|
12888
|
-
ProgressStatusBarRangeColor["dangerEnd"] = "#DC3545";
|
|
12889
|
-
ProgressStatusBarRangeColor["alertStart"] = "#FECD6E";
|
|
12890
|
-
ProgressStatusBarRangeColor["alertEnd"] = "#FEAC0E";
|
|
12891
|
-
ProgressStatusBarRangeColor["infoStart"] = "#6BC1F2";
|
|
12892
|
-
ProgressStatusBarRangeColor["infoEnd"] = "#0897E9";
|
|
12893
|
-
ProgressStatusBarRangeColor["successStart"] = "#A3E78C";
|
|
12894
|
-
ProgressStatusBarRangeColor["successEnd"] = "#47B13D";
|
|
12895
|
-
})(ProgressStatusBarRangeColor || (ProgressStatusBarRangeColor = {}));
|
|
12896
|
-
class TcRevProgressStatusBarComponent {
|
|
12897
|
-
constructor() {
|
|
12898
|
-
this.currentValue = input.required(...(ngDevMode ? [{ debugName: "currentValue" }] : /* istanbul ignore next */ []));
|
|
12899
|
-
this.progressStatusConfig = input.required(...(ngDevMode ? [{ debugName: "progressStatusConfig" }] : /* istanbul ignore next */ []));
|
|
12900
|
-
this.backgroundStyle = '';
|
|
12901
|
-
effect(() => {
|
|
12902
|
-
this.backgroundStyle = this.getBackgroundStyle();
|
|
12903
|
-
});
|
|
12904
|
-
}
|
|
12905
|
-
getBackgroundStyle() {
|
|
12906
|
-
if (!this.currentValue())
|
|
12907
|
-
return '';
|
|
12908
|
-
let currentStatusConfig = this.progressStatusConfig().find((x) => (this.currentValue() >= x.start && this.currentValue() <= x.end));
|
|
12909
|
-
const lastStatusConfig = this.progressStatusConfig()[this.progressStatusConfig()?.length - 1];
|
|
12910
|
-
if (!currentStatusConfig && this.currentValue() < lastStatusConfig.end)
|
|
12911
|
-
return '';
|
|
12912
|
-
if (!currentStatusConfig && this.currentValue() > lastStatusConfig.end) {
|
|
12913
|
-
currentStatusConfig = { start: 0, end: 100, gradientStatus: lastStatusConfig.gradientStatus };
|
|
12914
|
-
}
|
|
12915
|
-
const startStatus = this.getProgressStatusBarRangeColor(currentStatusConfig.gradientStatus, 'start');
|
|
12916
|
-
const endStatus = this.getProgressStatusBarRangeColor(currentStatusConfig.gradientStatus, 'end');
|
|
12917
|
-
let style = `width:${this.currentValue()}%;backgroundImage:linear-gradient(90deg`;
|
|
12918
|
-
style += `,${startStatus} 0%,${endStatus} 100%);`;
|
|
12919
|
-
return style;
|
|
12920
|
-
}
|
|
12921
|
-
getProgressStatusBarRangeColor(_gradientStatus, position) {
|
|
12922
|
-
switch (_gradientStatus) {
|
|
12923
|
-
case ProgressStatusBarGradientStatus.alert:
|
|
12924
|
-
return position === 'start' ? ProgressStatusBarRangeColor.alertStart : ProgressStatusBarRangeColor.alertEnd;
|
|
12925
|
-
case ProgressStatusBarGradientStatus.danger:
|
|
12926
|
-
return position === 'start' ? ProgressStatusBarRangeColor.dangerStart : ProgressStatusBarRangeColor.dangerEnd;
|
|
12927
|
-
case ProgressStatusBarGradientStatus.success:
|
|
12928
|
-
return position === 'start' ? ProgressStatusBarRangeColor.successStart : ProgressStatusBarRangeColor.successEnd;
|
|
12929
|
-
default:
|
|
12930
|
-
return position === 'start' ? ProgressStatusBarRangeColor.infoStart : ProgressStatusBarRangeColor.infoEnd;
|
|
12931
|
-
}
|
|
12932
|
-
}
|
|
12933
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevProgressStatusBarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12934
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.17", type: TcRevProgressStatusBarComponent, isStandalone: true, selector: "tc-rev-progress-status-bar", inputs: { currentValue: { classPropertyName: "currentValue", publicName: "currentValue", isSignal: true, isRequired: true, transformFunction: null }, progressStatusConfig: { classPropertyName: "progressStatusConfig", publicName: "progressStatusConfig", isSignal: true, isRequired: true, transformFunction: null } }, ngImport: i0, template: "<div class=\"progress-status-bar-container\">\n <div\n class=\"progress-status-bar\"\n [style]=\"this.backgroundStyle\">\n </div>\n</div>\n", styles: [":host{display:block}.progress-status-bar-container{background-color:var(--c-neutral-200);border-radius:var(--bor-radius-pill);display:block;height:var(--size-12);position:relative}.progress-status-bar-container .progress-status-bar{border-radius:var(--bor-radius-pill);display:block;height:var(--size-12);left:0;max-width:100%;position:absolute;top:0;transition:width .2s linear;width:0}\n"] }); }
|
|
12935
|
-
}
|
|
12936
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevProgressStatusBarComponent, decorators: [{
|
|
12937
|
-
type: Component,
|
|
12938
|
-
args: [{ selector: 'tc-rev-progress-status-bar', imports: [], template: "<div class=\"progress-status-bar-container\">\n <div\n class=\"progress-status-bar\"\n [style]=\"this.backgroundStyle\">\n </div>\n</div>\n", styles: [":host{display:block}.progress-status-bar-container{background-color:var(--c-neutral-200);border-radius:var(--bor-radius-pill);display:block;height:var(--size-12);position:relative}.progress-status-bar-container .progress-status-bar{border-radius:var(--bor-radius-pill);display:block;height:var(--size-12);left:0;max-width:100%;position:absolute;top:0;transition:width .2s linear;width:0}\n"] }]
|
|
12939
|
-
}], ctorParameters: () => [], propDecorators: { currentValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "currentValue", required: true }] }], progressStatusConfig: [{ type: i0.Input, args: [{ isSignal: true, alias: "progressStatusConfig", required: true }] }] } });
|
|
12940
|
-
|
|
12941
|
-
class TcRevRadioDirective {
|
|
12942
|
-
constructor() { }
|
|
12943
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevRadioDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
12944
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.17", type: TcRevRadioDirective, isStandalone: true, selector: "input[type=\"radio\"][tcRevRadio]", host: { classAttribute: "tc-rev-radio" }, ngImport: i0 }); }
|
|
12945
|
-
}
|
|
12946
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevRadioDirective, decorators: [{
|
|
12947
|
-
type: Directive,
|
|
12948
|
-
args: [{
|
|
12949
|
-
selector: 'input[type="radio"][tcRevRadio]',
|
|
12950
|
-
host: {
|
|
12951
|
-
class: 'tc-rev-radio'
|
|
12952
|
-
}
|
|
12953
|
-
}]
|
|
12954
|
-
}], ctorParameters: () => [] });
|
|
12955
|
-
|
|
12956
|
-
class TcRevSideDrawerComponent {
|
|
12957
|
-
constructor(document, el, renderer) {
|
|
12958
|
-
this.document = document;
|
|
12959
|
-
this.el = el;
|
|
12960
|
-
this.renderer = renderer;
|
|
12961
|
-
this.loading = input(false, ...(ngDevMode ? [{ debugName: "loading" }] : /* istanbul ignore next */ []));
|
|
12962
|
-
this.position = input('right', ...(ngDevMode ? [{ debugName: "position" }] : /* istanbul ignore next */ []));
|
|
12963
|
-
this.title = input.required(...(ngDevMode ? [{ debugName: "title" }] : /* istanbul ignore next */ []));
|
|
12964
|
-
this.xAxis = computed(() => this.position() === 'left' ? `left: 0` : `right: 0`, ...(ngDevMode ? [{ debugName: "xAxis" }] : /* istanbul ignore next */ []));
|
|
12965
|
-
this.onCloseDrawer = output();
|
|
12966
|
-
this.isOpen = false;
|
|
12967
|
-
this._deviceService = inject(TCloudUiDeviceUtilsService);
|
|
12968
|
-
this.isDesktop = this._deviceService.isDesktop;
|
|
12969
|
-
this.isMobile = this._deviceService.isMobile;
|
|
12970
|
-
}
|
|
12971
|
-
ngOnInit() {
|
|
12972
|
-
this.document.body.style.overflowY = 'hidden';
|
|
12973
|
-
this.isOpen = true;
|
|
12974
|
-
// --- mover o host do componente para o <body> apenas em mobile ---
|
|
12975
|
-
if (this.el &&
|
|
12976
|
-
this.el.nativeElement &&
|
|
12977
|
-
this.el.nativeElement.parentNode !== this.document.body &&
|
|
12978
|
-
this.isMobile()) {
|
|
12979
|
-
this.renderer.appendChild(this.document.body, this.el.nativeElement);
|
|
12980
|
-
}
|
|
12981
|
-
}
|
|
12982
|
-
ngOnDestroy() {
|
|
12983
|
-
this.document.body.style.overflowY = '';
|
|
12984
|
-
// remover o host do body ao destruir apenas em mobile
|
|
12985
|
-
if (this.el &&
|
|
12986
|
-
this.el.nativeElement &&
|
|
12987
|
-
this.el.nativeElement.parentNode === this.document.body &&
|
|
12988
|
-
this.isMobile()) {
|
|
12989
|
-
this.renderer.removeChild(this.document.body, this.el.nativeElement);
|
|
12990
|
-
}
|
|
12991
|
-
}
|
|
12992
|
-
handleClickOverlay() {
|
|
12993
|
-
if (this.loading()) {
|
|
12994
|
-
return;
|
|
12995
|
-
}
|
|
12996
|
-
this.isOpen = false;
|
|
12997
|
-
setTimeout(() => this.onCloseDrawer.emit(), 250);
|
|
12998
|
-
}
|
|
12999
|
-
handleClickContent(_ev) {
|
|
13000
|
-
_ev.stopPropagation();
|
|
13001
|
-
}
|
|
13002
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSideDrawerComponent, deps: [{ token: DOCUMENT }, { token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
13003
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevSideDrawerComponent, isStandalone: true, selector: "tc-rev-side-drawer", inputs: { loading: { classPropertyName: "loading", publicName: "loading", isSignal: true, isRequired: false, transformFunction: null }, position: { classPropertyName: "position", publicName: "position", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { onCloseDrawer: "onCloseDrawer" }, ngImport: i0, template: "@if(isDesktop() && isOpen){\n <div\n animate.enter=\"drawer-backdrop-enter\"\n animate.leave=\"drawer-backdrop-leave\"\n class=\"tc-rev-side-drawer-overlay\"\n (click)=\"handleClickOverlay()\">\n </div>\n}\n\n@if (isOpen) {\n <div\n [animate.enter]=\"isDesktop() ? 'drawer-enter-desktop' : 'drawer-enter-mobile'\"\n [animate.leave]=\"isDesktop() ? 'drawer-leave-desktop' : 'drawer-leave-mobile'\"\n class=\"tc-rev-side-drawer-content\"\n [style.width]=\"isMobile() ? '100%' : null\"\n (click)=\"handleClickContent($event)\"\n [style]=\"xAxis()\">\n <div class=\"tc-rev-side-drawer-content__header\">\n <h2 class=\"mar-none f-h2 f-weight-600\">{{title()}}</h2>\n <button\n tcRevIconButton=\"outline\" color=\"dark\"\n [disabled]=\"loading()\"\n (click)=\"handleClickOverlay()\">\n <i class=\"fa-light fa-times\"></i>\n </button>\n </div>\n <ng-content></ng-content>\n </div>\n}", styles: [":host{display:block}.tc-rev-side-drawer-overlay{background-color:#00000080;inset:0;position:fixed;height:100vh;z-index:3000}.tc-rev-side-drawer-overlay.drawer-backdrop-enter{animation:tcDrawerBackdropIn .1s ease}.tc-rev-side-drawer-overlay.drawer-backdrop-leave{animation:tcDrawerBackdropOut .25s ease}.tc-rev-side-drawer-content.drawer-enter-desktop{animation:tcDrawerSlideIn .25s ease}.tc-rev-side-drawer-content.drawer-leave-desktop{animation:tcDrawerSlideOut .25s ease}.tc-rev-side-drawer-content.drawer-enter-mobile{animation:tcDrawerFadeIn .2s ease}.tc-rev-side-drawer-content.drawer-leave-mobile{animation:tcDrawerFadeOut .2s ease}@keyframes tcDrawerBackdropIn{0%{opacity:0}to{opacity:1}}@keyframes tcDrawerBackdropOut{0%{opacity:1}to{opacity:0}}@keyframes tcDrawerSlideIn{0%{opacity:0;transform:translate(100%)}to{opacity:1;transform:translate(0)}}@keyframes tcDrawerSlideOut{0%{opacity:1;transform:translate(0)}to{opacity:0;transform:translate(100%)}}@keyframes tcDrawerFadeIn{0%{opacity:0}to{opacity:1}}@keyframes tcDrawerFadeOut{0%{opacity:1}to{opacity:0}}.tc-rev-side-drawer-content{background-color:var(--c-neutral-50);height:100vh;position:fixed;z-index:3001;top:0}.tc-rev-side-drawer-content__header{align-items:center;color:var(--c-neutral-700);display:flex;font-family:var(--f-family);gap:var(--size-16);justify-content:space-between;padding:var(--size-16);padding-bottom:0}\n"], dependencies: [{ kind: "directive", type: TcRevIconButtonDirective, selector: "button[tcRevIconButton]", inputs: ["color", "size", "tcRevIconButton"] }] }); }
|
|
13004
|
-
}
|
|
13005
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSideDrawerComponent, decorators: [{
|
|
13006
|
-
type: Component,
|
|
13007
|
-
args: [{ selector: 'tc-rev-side-drawer', imports: [TcRevIconButtonDirective], template: "@if(isDesktop() && isOpen){\n <div\n animate.enter=\"drawer-backdrop-enter\"\n animate.leave=\"drawer-backdrop-leave\"\n class=\"tc-rev-side-drawer-overlay\"\n (click)=\"handleClickOverlay()\">\n </div>\n}\n\n@if (isOpen) {\n <div\n [animate.enter]=\"isDesktop() ? 'drawer-enter-desktop' : 'drawer-enter-mobile'\"\n [animate.leave]=\"isDesktop() ? 'drawer-leave-desktop' : 'drawer-leave-mobile'\"\n class=\"tc-rev-side-drawer-content\"\n [style.width]=\"isMobile() ? '100%' : null\"\n (click)=\"handleClickContent($event)\"\n [style]=\"xAxis()\">\n <div class=\"tc-rev-side-drawer-content__header\">\n <h2 class=\"mar-none f-h2 f-weight-600\">{{title()}}</h2>\n <button\n tcRevIconButton=\"outline\" color=\"dark\"\n [disabled]=\"loading()\"\n (click)=\"handleClickOverlay()\">\n <i class=\"fa-light fa-times\"></i>\n </button>\n </div>\n <ng-content></ng-content>\n </div>\n}", styles: [":host{display:block}.tc-rev-side-drawer-overlay{background-color:#00000080;inset:0;position:fixed;height:100vh;z-index:3000}.tc-rev-side-drawer-overlay.drawer-backdrop-enter{animation:tcDrawerBackdropIn .1s ease}.tc-rev-side-drawer-overlay.drawer-backdrop-leave{animation:tcDrawerBackdropOut .25s ease}.tc-rev-side-drawer-content.drawer-enter-desktop{animation:tcDrawerSlideIn .25s ease}.tc-rev-side-drawer-content.drawer-leave-desktop{animation:tcDrawerSlideOut .25s ease}.tc-rev-side-drawer-content.drawer-enter-mobile{animation:tcDrawerFadeIn .2s ease}.tc-rev-side-drawer-content.drawer-leave-mobile{animation:tcDrawerFadeOut .2s ease}@keyframes tcDrawerBackdropIn{0%{opacity:0}to{opacity:1}}@keyframes tcDrawerBackdropOut{0%{opacity:1}to{opacity:0}}@keyframes tcDrawerSlideIn{0%{opacity:0;transform:translate(100%)}to{opacity:1;transform:translate(0)}}@keyframes tcDrawerSlideOut{0%{opacity:1;transform:translate(0)}to{opacity:0;transform:translate(100%)}}@keyframes tcDrawerFadeIn{0%{opacity:0}to{opacity:1}}@keyframes tcDrawerFadeOut{0%{opacity:1}to{opacity:0}}.tc-rev-side-drawer-content{background-color:var(--c-neutral-50);height:100vh;position:fixed;z-index:3001;top:0}.tc-rev-side-drawer-content__header{align-items:center;color:var(--c-neutral-700);display:flex;font-family:var(--f-family);gap:var(--size-16);justify-content:space-between;padding:var(--size-16);padding-bottom:0}\n"] }]
|
|
13008
|
-
}], ctorParameters: () => [{ type: Document, decorators: [{
|
|
13009
|
-
type: Inject,
|
|
13010
|
-
args: [DOCUMENT]
|
|
13011
|
-
}] }, { type: i0.ElementRef }, { type: i0.Renderer2 }], propDecorators: { loading: [{ type: i0.Input, args: [{ isSignal: true, alias: "loading", required: false }] }], position: [{ type: i0.Input, args: [{ isSignal: true, alias: "position", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: true }] }], onCloseDrawer: [{ type: i0.Output, args: ["onCloseDrawer"] }] } });
|
|
13012
|
-
|
|
13013
|
-
class TcRevSkeletonLoadingComponent {
|
|
13014
|
-
constructor() {
|
|
13015
|
-
/** Params of the loading skeleton accepts string with CSS units (px, rem, em) */
|
|
13016
|
-
this.width = input('10rem', ...(ngDevMode ? [{ debugName: "width" }] : /* istanbul ignore next */ []));
|
|
13017
|
-
this.height = input('1.25rem', ...(ngDevMode ? [{ debugName: "height" }] : /* istanbul ignore next */ []));
|
|
13018
|
-
this.borderRadius = input('0.3rem', ...(ngDevMode ? [{ debugName: "borderRadius" }] : /* istanbul ignore next */ []));
|
|
13019
|
-
this.style = new TcRevSkeletonLoadingComponentStyle();
|
|
13020
|
-
}
|
|
13021
|
-
ngOnInit() {
|
|
13022
|
-
this.style.width = this.width();
|
|
13023
|
-
this.style.height = this.height();
|
|
13024
|
-
this.style.borderRadius = this.borderRadius();
|
|
13025
|
-
}
|
|
13026
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSkeletonLoadingComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
13027
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.17", type: TcRevSkeletonLoadingComponent, isStandalone: true, selector: "tc-rev-skeleton-loading", inputs: { width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null }, height: { classPropertyName: "height", publicName: "height", isSignal: true, isRequired: false, transformFunction: null }, borderRadius: { classPropertyName: "borderRadius", publicName: "borderRadius", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"tc-rev-skeleton-loading\" [ngStyle]=\"this.style\"></div>\n", styles: [":host{display:block}.tc-rev-skeleton-loading{background:linear-gradient(90deg,#eee 25%,#fff,#eee 75%);background-size:400% 100%;animation:shimmer 2s infinite linear}@keyframes shimmer{0%{background-position:200% 0}to{background-position:-200% 0}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }] }); }
|
|
13028
|
-
}
|
|
13029
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSkeletonLoadingComponent, decorators: [{
|
|
13030
|
-
type: Component,
|
|
13031
|
-
args: [{ selector: 'tc-rev-skeleton-loading', imports: [CommonModule], template: "<div class=\"tc-rev-skeleton-loading\" [ngStyle]=\"this.style\"></div>\n", styles: [":host{display:block}.tc-rev-skeleton-loading{background:linear-gradient(90deg,#eee 25%,#fff,#eee 75%);background-size:400% 100%;animation:shimmer 2s infinite linear}@keyframes shimmer{0%{background-position:200% 0}to{background-position:-200% 0}}\n"] }]
|
|
13032
|
-
}], propDecorators: { width: [{ type: i0.Input, args: [{ isSignal: true, alias: "width", required: false }] }], height: [{ type: i0.Input, args: [{ isSignal: true, alias: "height", required: false }] }], borderRadius: [{ type: i0.Input, args: [{ isSignal: true, alias: "borderRadius", required: false }] }] } });
|
|
13033
|
-
class TcRevSkeletonLoadingComponentStyle {
|
|
13034
|
-
}
|
|
13035
|
-
|
|
13036
|
-
class TcRevSlideToggleDirective {
|
|
13037
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSlideToggleDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
13038
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.17", type: TcRevSlideToggleDirective, isStandalone: true, selector: "input[type=\"checkbox\"][tcRevSlideToggle]", host: { classAttribute: "tc-rev-slide-toggle" }, ngImport: i0 }); }
|
|
13039
|
-
}
|
|
13040
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSlideToggleDirective, decorators: [{
|
|
13041
|
-
type: Directive,
|
|
13042
|
-
args: [{
|
|
13043
|
-
selector: 'input[type="checkbox"][tcRevSlideToggle]',
|
|
13044
|
-
host: {
|
|
13045
|
-
class: 'tc-rev-slide-toggle'
|
|
13046
|
-
}
|
|
13047
|
-
}]
|
|
13048
|
-
}] });
|
|
13049
|
-
|
|
13050
|
-
class TcRevTabGroupComponent {
|
|
13051
|
-
constructor() {
|
|
13052
|
-
this.isCarouselOverflowed = false;
|
|
13053
|
-
}
|
|
13054
|
-
onResize() {
|
|
13055
|
-
this.checkCarouselOverflow();
|
|
13056
|
-
}
|
|
13057
|
-
ngOnInit() {
|
|
13058
|
-
this.checkCarouselOverflow();
|
|
13059
|
-
}
|
|
13060
|
-
checkCarouselOverflow() {
|
|
13061
|
-
setTimeout(() => {
|
|
13062
|
-
const el = this.tabGroupCarousel?.nativeElement;
|
|
13063
|
-
this.isCarouselOverflowed = !!el && el.scrollWidth > el.clientWidth;
|
|
13064
|
-
});
|
|
13065
|
-
}
|
|
13066
|
-
scrollTabsCarousel(direction) {
|
|
13067
|
-
const el = this.tabGroupCarousel?.nativeElement;
|
|
13068
|
-
if (!el)
|
|
13069
|
-
return;
|
|
13070
|
-
const scrollAmount = 200;
|
|
13071
|
-
if (direction === 'left') {
|
|
13072
|
-
el.scrollBy({ left: -scrollAmount, behavior: 'smooth' });
|
|
13073
|
-
}
|
|
13074
|
-
else {
|
|
13075
|
-
el.scrollBy({ left: scrollAmount, behavior: 'smooth' });
|
|
13076
|
-
}
|
|
13077
|
-
}
|
|
13078
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevTabGroupComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
13079
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevTabGroupComponent, isStandalone: true, selector: "tc-rev-tab-group", host: { listeners: { "window:resize": "onResize()" } }, viewQueries: [{ propertyName: "tabGroupCarousel", first: true, predicate: ["tabGroupCarousel"], descendants: true }], ngImport: i0, template: "<div class=\"tc-rev-tab-group\">\n @if (isCarouselOverflowed) {\n <button\n class=\"tc-rev-tab-item carousel-arrow left\"\n (click)=\"this.scrollTabsCarousel('left')\"\n aria-label=\"Scroll left\">\n <i class=\"fa-light fa-chevron-left\"></i>\n </button>\n }\n\n <div\n class=\"tc-rev-tab-group-carousel\"\n [class.overflowed]=\"isCarouselOverflowed\"\n #tabGroupCarousel>\n <ng-content></ng-content>\n </div>\n\n @if (isCarouselOverflowed) {\n <button\n class=\"tc-rev-tab-item carousel-arrow right\"\n (click)=\"this.scrollTabsCarousel('right')\"\n aria-label=\"Scroll right\">\n <i class=\"fa-light fa-chevron-right\"></i>\n </button>\n }\n</div>\n\n<!-- <div class=\"products-carousel-container f-family\">\n<button\n *ngIf=\"isCarouselOverflowed\"\n class=\"tc-rev-tab-item carousel-arrow left\"\n (click)=\"scrollProductsCarousel('left')\"\n aria-label=\"Scroll left\">\n <i class=\"fa-light fa-chevron-left\"></i>\n</button>\n\n<div\n #productsCarousel\n class=\"products-carousel\"\n [class.overflowed]=\"isCarouselOverflowed\">\n @for (productName of topologiesData.availableProductsNames(); track productName)\n {\n <button\n class=\"tc-rev-tab-item\"\n [class.active]=\"filter().product === productName\"\n (click)=\"handleChangeTopologiesByProduct(productName)\">\n {{ productName | topologyProduct }}\n </button>\n }\n</div>\n\n<button\n *ngIf=\"isCarouselOverflowed\"\n class=\"tc-rev-tab-item carousel-arrow right\"\n (click)=\"scrollProductsCarousel('right')\"\n aria-label=\"Scroll right\">\n <i class=\"fa-light fa-chevron-right\"></i>\n</button>\n</div> -->", styles: [":host{display:block}.tc-rev-tab-group{position:relative;height:var(--size-40);width:100%}.tc-rev-tab-group .tc-rev-tab-group-carousel{display:flex;gap:var(--size-8);height:var(--size-40);left:0;margin:0;overflow:hidden;position:absolute;scroll-behavior:smooth;top:0;width:calc(100% - 6.25rem);z-index:1}.tc-rev-tab-group .tc-rev-tab-group-carousel.overflowed{left:var(--size-20);margin:0 var(--size-32)}.tc-rev-tab-group .tc-rev-tab-group-carousel.full-width{width:100%}.tc-rev-tab-group .carousel-arrow{background-color:var(--c-neutral-50);border:var(--bor-size-1) solid var(--c-neutral-400);border-radius:var(--bor-radius-8);color:var(--c-neutral-700);cursor:pointer;font-size:var(--f-size-14);font-weight:600;height:var(--size-40);line-height:var(--l-height-20);padding:0;text-wrap:nowrap;transition:all .2s ease;width:var(--size-40)}.tc-rev-tab-group .carousel-arrow:hover,.tc-rev-tab-group .carousel-arrow:focus{background-color:var(--c-neutral-200);border-color:var(--c-neutral-200);color:var(--c-primary-500);font-weight:600}.tc-rev-tab-group .carousel-arrow:active,.tc-rev-tab-group .carousel-arrow.selected,.tc-rev-tab-group .carousel-arrow.active{background-color:var(--c-primary-300);border-color:var(--c-primary-500);color:var(--c-primary-500);font-weight:700}.tc-rev-tab-group .carousel-arrow:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-50);color:var(--c-neutral-400);cursor:not-allowed;font-weight:var(--f-weight-400)}.tc-rev-tab-group .carousel-arrow.left{left:0;position:absolute;z-index:1}.tc-rev-tab-group .carousel-arrow.right{position:absolute;right:0;z-index:1}@media(max-width:480px){:host{display:block;position:relative;height:var(--size-40)}:host .carousel-arrow{display:none}:host .tc-rev-tab-group-carousel{width:100%!important;overflow-x:auto!important;scrollbar-width:none;-ms-overflow-style:none;white-space:nowrap;padding-left:var(--size-40);padding-right:var(--size-40)}:host .tc-rev-tab-group-carousel.overflowed{left:auto!important;margin:0!important}:host .tc-rev-tab-group-carousel::-webkit-scrollbar{display:none}:host .tc-rev-tab-group{left:calc(-1 * var(--size-40));width:calc(100% + var(--size-80))}}\n"] }); }
|
|
13080
|
-
}
|
|
13081
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevTabGroupComponent, decorators: [{
|
|
13082
|
-
type: Component,
|
|
13083
|
-
args: [{ selector: 'tc-rev-tab-group', imports: [], template: "<div class=\"tc-rev-tab-group\">\n @if (isCarouselOverflowed) {\n <button\n class=\"tc-rev-tab-item carousel-arrow left\"\n (click)=\"this.scrollTabsCarousel('left')\"\n aria-label=\"Scroll left\">\n <i class=\"fa-light fa-chevron-left\"></i>\n </button>\n }\n\n <div\n class=\"tc-rev-tab-group-carousel\"\n [class.overflowed]=\"isCarouselOverflowed\"\n #tabGroupCarousel>\n <ng-content></ng-content>\n </div>\n\n @if (isCarouselOverflowed) {\n <button\n class=\"tc-rev-tab-item carousel-arrow right\"\n (click)=\"this.scrollTabsCarousel('right')\"\n aria-label=\"Scroll right\">\n <i class=\"fa-light fa-chevron-right\"></i>\n </button>\n }\n</div>\n\n<!-- <div class=\"products-carousel-container f-family\">\n<button\n *ngIf=\"isCarouselOverflowed\"\n class=\"tc-rev-tab-item carousel-arrow left\"\n (click)=\"scrollProductsCarousel('left')\"\n aria-label=\"Scroll left\">\n <i class=\"fa-light fa-chevron-left\"></i>\n</button>\n\n<div\n #productsCarousel\n class=\"products-carousel\"\n [class.overflowed]=\"isCarouselOverflowed\">\n @for (productName of topologiesData.availableProductsNames(); track productName)\n {\n <button\n class=\"tc-rev-tab-item\"\n [class.active]=\"filter().product === productName\"\n (click)=\"handleChangeTopologiesByProduct(productName)\">\n {{ productName | topologyProduct }}\n </button>\n }\n</div>\n\n<button\n *ngIf=\"isCarouselOverflowed\"\n class=\"tc-rev-tab-item carousel-arrow right\"\n (click)=\"scrollProductsCarousel('right')\"\n aria-label=\"Scroll right\">\n <i class=\"fa-light fa-chevron-right\"></i>\n</button>\n</div> -->", styles: [":host{display:block}.tc-rev-tab-group{position:relative;height:var(--size-40);width:100%}.tc-rev-tab-group .tc-rev-tab-group-carousel{display:flex;gap:var(--size-8);height:var(--size-40);left:0;margin:0;overflow:hidden;position:absolute;scroll-behavior:smooth;top:0;width:calc(100% - 6.25rem);z-index:1}.tc-rev-tab-group .tc-rev-tab-group-carousel.overflowed{left:var(--size-20);margin:0 var(--size-32)}.tc-rev-tab-group .tc-rev-tab-group-carousel.full-width{width:100%}.tc-rev-tab-group .carousel-arrow{background-color:var(--c-neutral-50);border:var(--bor-size-1) solid var(--c-neutral-400);border-radius:var(--bor-radius-8);color:var(--c-neutral-700);cursor:pointer;font-size:var(--f-size-14);font-weight:600;height:var(--size-40);line-height:var(--l-height-20);padding:0;text-wrap:nowrap;transition:all .2s ease;width:var(--size-40)}.tc-rev-tab-group .carousel-arrow:hover,.tc-rev-tab-group .carousel-arrow:focus{background-color:var(--c-neutral-200);border-color:var(--c-neutral-200);color:var(--c-primary-500);font-weight:600}.tc-rev-tab-group .carousel-arrow:active,.tc-rev-tab-group .carousel-arrow.selected,.tc-rev-tab-group .carousel-arrow.active{background-color:var(--c-primary-300);border-color:var(--c-primary-500);color:var(--c-primary-500);font-weight:700}.tc-rev-tab-group .carousel-arrow:disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-50);color:var(--c-neutral-400);cursor:not-allowed;font-weight:var(--f-weight-400)}.tc-rev-tab-group .carousel-arrow.left{left:0;position:absolute;z-index:1}.tc-rev-tab-group .carousel-arrow.right{position:absolute;right:0;z-index:1}@media(max-width:480px){:host{display:block;position:relative;height:var(--size-40)}:host .carousel-arrow{display:none}:host .tc-rev-tab-group-carousel{width:100%!important;overflow-x:auto!important;scrollbar-width:none;-ms-overflow-style:none;white-space:nowrap;padding-left:var(--size-40);padding-right:var(--size-40)}:host .tc-rev-tab-group-carousel.overflowed{left:auto!important;margin:0!important}:host .tc-rev-tab-group-carousel::-webkit-scrollbar{display:none}:host .tc-rev-tab-group{left:calc(-1 * var(--size-40));width:calc(100% + var(--size-80))}}\n"] }]
|
|
13084
|
-
}], propDecorators: { onResize: [{
|
|
13085
|
-
type: HostListener,
|
|
13086
|
-
args: ['window:resize']
|
|
13087
|
-
}], tabGroupCarousel: [{
|
|
13088
|
-
type: ViewChild,
|
|
13089
|
-
args: ['tabGroupCarousel']
|
|
13090
|
-
}] } });
|
|
13091
|
-
|
|
13092
|
-
class TcRevTabItemComponent {
|
|
13093
|
-
constructor() {
|
|
13094
|
-
this.onClick = output();
|
|
13095
|
-
this.active = input(false, ...(ngDevMode ? [{ debugName: "active" }] : /* istanbul ignore next */ []));
|
|
13096
|
-
this.url = input('', ...(ngDevMode ? [{ debugName: "url" }] : /* istanbul ignore next */ []));
|
|
13097
|
-
this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
|
|
13098
|
-
this.fullWidth = input(false, ...(ngDevMode ? [{ debugName: "fullWidth" }] : /* istanbul ignore next */ []));
|
|
13099
|
-
}
|
|
13100
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevTabItemComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
13101
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevTabItemComponent, isStandalone: true, selector: "tc-rev-tab-item", inputs: { active: { classPropertyName: "active", publicName: "active", isSignal: true, isRequired: false, transformFunction: null }, url: { classPropertyName: "url", publicName: "url", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, fullWidth: { classPropertyName: "fullWidth", publicName: "fullWidth", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onClick: "onClick" }, ngImport: i0, template: "@if (this.url()) {\n <a\n class=\"tc-rev-tab-item\"\n [class.disabled]=\"this.disabled()\"\n [class.full-width]=\"this.fullWidth()\"\n [routerLinkActive]=\"'active'\"\n [routerLink]=\"[this.url()]\"\n (click)=\"this.onClick.emit($event)\">\n <ng-container *ngTemplateOutlet=\"content\" />\n </a>\n}\n\n\n@if (!this.url()) {\n <button\n class=\"tc-rev-tab-item\"\n [class.active]=\"this.active()\"\n [class.full-width]=\"this.fullWidth()\"\n [disabled]=\"this.disabled()\"\n (click)=\"this.onClick.emit($event)\">\n <ng-container *ngTemplateOutlet=\"content\" />\n </button>\n}\n\n<ng-template #content>\n <ng-content></ng-content>\n</ng-template>\n", styles: [":host{display:block}.tc-rev-tab-item,.tc-rev-tab-item:link{align-items:center;background-color:var(--c-neutral-50);border:var(--bor-size-1) solid var(--c-neutral-400);border-radius:var(--bor-radius-8);color:var(--c-neutral-700);cursor:pointer;display:inline-flex;font-family:var(--f-family);font-size:var(--f-size-14);font-weight:600;gap:var(--size-8);height:var(--size-40);line-height:var(--l-height-20);justify-content:center;padding:0 var(--size-16);text-decoration:none;text-wrap:nowrap;transition:all .2s ease}.tc-rev-tab-item.full-width,.tc-rev-tab-item:link.full-width{width:100%}.tc-rev-tab-item:hover,.tc-rev-tab-item:focus,.tc-rev-tab-item:link:hover,.tc-rev-tab-item:link:focus{background-color:var(--c-neutral-200);border-color:var(--c-neutral-200);color:var(--c-primary-500);font-weight:600}.tc-rev-tab-item:active,.tc-rev-tab-item.selected,.tc-rev-tab-item.active,.tc-rev-tab-item:link:active,.tc-rev-tab-item:link.selected,.tc-rev-tab-item:link.active{background-color:var(--c-primary-300);border-color:var(--c-primary-500);color:var(--c-primary-500);font-weight:600}.tc-rev-tab-item:disabled,.tc-rev-tab-item.disabled,.tc-rev-tab-item:link:disabled,.tc-rev-tab-item:link.disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-50);color:var(--c-neutral-400);cursor:not-allowed;font-weight:var(--f-weight-400);pointer-events:none}@media(max-width:480px){:host{display:contents}:host .tc-rev-tab-item{width:100%}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: RouterModule }, { kind: "directive", type: i1$2.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: i1$2.RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }] }); }
|
|
13102
|
-
}
|
|
13103
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevTabItemComponent, decorators: [{
|
|
13104
|
-
type: Component,
|
|
13105
|
-
args: [{ selector: 'tc-rev-tab-item', imports: [
|
|
13106
|
-
CommonModule,
|
|
13107
|
-
RouterModule
|
|
13108
|
-
], template: "@if (this.url()) {\n <a\n class=\"tc-rev-tab-item\"\n [class.disabled]=\"this.disabled()\"\n [class.full-width]=\"this.fullWidth()\"\n [routerLinkActive]=\"'active'\"\n [routerLink]=\"[this.url()]\"\n (click)=\"this.onClick.emit($event)\">\n <ng-container *ngTemplateOutlet=\"content\" />\n </a>\n}\n\n\n@if (!this.url()) {\n <button\n class=\"tc-rev-tab-item\"\n [class.active]=\"this.active()\"\n [class.full-width]=\"this.fullWidth()\"\n [disabled]=\"this.disabled()\"\n (click)=\"this.onClick.emit($event)\">\n <ng-container *ngTemplateOutlet=\"content\" />\n </button>\n}\n\n<ng-template #content>\n <ng-content></ng-content>\n</ng-template>\n", styles: [":host{display:block}.tc-rev-tab-item,.tc-rev-tab-item:link{align-items:center;background-color:var(--c-neutral-50);border:var(--bor-size-1) solid var(--c-neutral-400);border-radius:var(--bor-radius-8);color:var(--c-neutral-700);cursor:pointer;display:inline-flex;font-family:var(--f-family);font-size:var(--f-size-14);font-weight:600;gap:var(--size-8);height:var(--size-40);line-height:var(--l-height-20);justify-content:center;padding:0 var(--size-16);text-decoration:none;text-wrap:nowrap;transition:all .2s ease}.tc-rev-tab-item.full-width,.tc-rev-tab-item:link.full-width{width:100%}.tc-rev-tab-item:hover,.tc-rev-tab-item:focus,.tc-rev-tab-item:link:hover,.tc-rev-tab-item:link:focus{background-color:var(--c-neutral-200);border-color:var(--c-neutral-200);color:var(--c-primary-500);font-weight:600}.tc-rev-tab-item:active,.tc-rev-tab-item.selected,.tc-rev-tab-item.active,.tc-rev-tab-item:link:active,.tc-rev-tab-item:link.selected,.tc-rev-tab-item:link.active{background-color:var(--c-primary-300);border-color:var(--c-primary-500);color:var(--c-primary-500);font-weight:600}.tc-rev-tab-item:disabled,.tc-rev-tab-item.disabled,.tc-rev-tab-item:link:disabled,.tc-rev-tab-item:link.disabled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-50);color:var(--c-neutral-400);cursor:not-allowed;font-weight:var(--f-weight-400);pointer-events:none}@media(max-width:480px){:host{display:contents}:host .tc-rev-tab-item{width:100%}}\n"] }]
|
|
13109
|
-
}], propDecorators: { onClick: [{ type: i0.Output, args: ["onClick"] }], active: [{ type: i0.Input, args: [{ isSignal: true, alias: "active", required: false }] }], url: [{ type: i0.Input, args: [{ isSignal: true, alias: "url", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], fullWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "fullWidth", required: false }] }] } });
|
|
13110
|
-
|
|
13111
|
-
var TagColorsEnum;
|
|
13112
|
-
(function (TagColorsEnum) {
|
|
13113
|
-
TagColorsEnum["neutral-50"] = "neutral-50";
|
|
13114
|
-
TagColorsEnum["neutral-100"] = "neutral-100";
|
|
13115
|
-
TagColorsEnum["neutral-200"] = "neutral-200";
|
|
13116
|
-
TagColorsEnum["neutral-300"] = "neutral-300";
|
|
13117
|
-
TagColorsEnum["neutral-400"] = "neutral-400";
|
|
13118
|
-
TagColorsEnum["neutral-500"] = "neutral-500";
|
|
13119
|
-
TagColorsEnum["neutral-600"] = "neutral-600";
|
|
13120
|
-
TagColorsEnum["neutral-700"] = "neutral-700";
|
|
13121
|
-
TagColorsEnum["neutral-800"] = "neutral-800";
|
|
13122
|
-
TagColorsEnum["neutral-900"] = "neutral-900";
|
|
13123
|
-
// Primary
|
|
13124
|
-
TagColorsEnum["primary-300"] = "primary-300";
|
|
13125
|
-
TagColorsEnum["primary-400"] = "primary-400";
|
|
13126
|
-
TagColorsEnum["primary-500"] = "primary-500";
|
|
13127
|
-
TagColorsEnum["primary-600"] = "primary-600";
|
|
13128
|
-
TagColorsEnum["primary-700"] = "primary-700";
|
|
13129
|
-
// Danger
|
|
13130
|
-
TagColorsEnum["danger-300"] = "danger-300";
|
|
13131
|
-
TagColorsEnum["danger-400"] = "danger-400";
|
|
13132
|
-
TagColorsEnum["danger-500"] = "danger-500";
|
|
13133
|
-
// Alert
|
|
13134
|
-
TagColorsEnum["alert-300"] = "alert-300";
|
|
13135
|
-
TagColorsEnum["alert-400"] = "alert-400";
|
|
13136
|
-
TagColorsEnum["alert-500"] = "alert-500";
|
|
13137
|
-
// Info
|
|
13138
|
-
TagColorsEnum["info-300"] = "info-300";
|
|
13139
|
-
TagColorsEnum["info-400"] = "info-400";
|
|
13140
|
-
TagColorsEnum["info-500"] = "info-500";
|
|
13141
|
-
// Success
|
|
13142
|
-
TagColorsEnum["success-300"] = "success-300";
|
|
13143
|
-
TagColorsEnum["success-400"] = "success-400";
|
|
13144
|
-
TagColorsEnum["success-500"] = "success-500";
|
|
13145
|
-
})(TagColorsEnum || (TagColorsEnum = {}));
|
|
13146
|
-
|
|
13147
|
-
class TcRevTagComponent {
|
|
13148
|
-
constructor() {
|
|
13149
|
-
this.size = input('md', ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
13150
|
-
this.color = input(TagColorsEnum['primary-500'], ...(ngDevMode ? [{ debugName: "color" }] : /* istanbul ignore next */ []));
|
|
13151
|
-
this.variant = input('filled', ...(ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []));
|
|
13152
|
-
this.shape = input('rectangle', ...(ngDevMode ? [{ debugName: "shape" }] : /* istanbul ignore next */ []));
|
|
13153
|
-
this.fullWidth = input(false, ...(ngDevMode ? [{ debugName: "fullWidth" }] : /* istanbul ignore next */ []));
|
|
13154
|
-
}
|
|
13155
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevTagComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
13156
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.17", type: TcRevTagComponent, isStandalone: true, selector: "tc-rev-tag", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, shape: { classPropertyName: "shape", publicName: "shape", isSignal: true, isRequired: false, transformFunction: null }, fullWidth: { classPropertyName: "fullWidth", publicName: "fullWidth", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<span\n [class.tc-rev-tag--sm]=\"size() === 'sm'\"\n [class.tc-rev-tag--md]=\"size() === 'md' || size() === 'regular'\"\n [class.tc-rev-tag--lg]=\"size() === 'lg'\"\n [class.tc-rev-tag--pill]=\"shape() === 'pill'\"\n [class.tc-rev-tag--full-width]=\"fullWidth()\"\n class=\"{{!color() && !variant() ? '' : 'tc-rev-tag tc-rev-tag--c-' + color() + '-' + variant()}}\">\n <ng-content></ng-content>\n</span>\n", styles: [":host{display:block}.tc-rev-tag,.tc-rev-tag--lg,.tc-rev-tag--md,.tc-rev-tag--sm{background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-700);cursor:default;display:inline-flex;align-items:center;justify-content:center;gap:var(--size-8);font-family:var(--f-family);font-size:var(--f-size-12);font-weight:var(--f-weight-500);padding:var(--size-2) var(--size-4);height:var(--size-22);max-height:var(--size-22);min-height:var(--size-22)}.tc-rev-tag--full-width{width:100%}.tc-rev-tag--sm{padding:var(--size-2) var(--size-4);height:var(--size-22);max-height:var(--size-22);min-height:var(--size-22)}.tc-rev-tag--md{padding:var(--size-4);height:var(--size-26);max-height:var(--size-26);min-height:var(--size-26)}.tc-rev-tag--lg{padding:var(--size-8);height:var(--size-34);max-height:var(--size-34);min-height:var(--size-34)}.tc-rev-tag--pill{border-radius:var(--bor-radius-pill)}.tc-rev-tag--c-neutral-50-filled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-50);color:var(--c-neutral-700)}.tc-rev-tag--c-neutral-100-filled{background-color:var(--c-neutral-100);border-color:var(--c-neutral-100);color:var(--c-neutral-700)}.tc-rev-tag--c-neutral-200-filled{background-color:var(--c-neutral-200);border-color:var(--c-neutral-200);color:var(--c-neutral-700)}.tc-rev-tag--c-neutral-300-filled{background-color:var(--c-neutral-300);border-color:var(--c-neutral-300);color:var(--c-neutral-700)}.tc-rev-tag--c-neutral-400-filled{background-color:var(--c-neutral-400);border-color:var(--c-neutral-400);color:var(--c-neutral-700)}.tc-rev-tag--c-neutral-500-filled{background-color:var(--c-neutral-500);border-color:var(--c-neutral-500);color:var(--c-neutral-50)}.tc-rev-tag--c-neutral-600-filled{background-color:var(--c-neutral-600);border-color:var(--c-neutral-600);color:var(--c-neutral-50)}.tc-rev-tag--c-neutral-700-filled,.tc-rev-tag--c-neutral-800-filled{background-color:var(--c-neutral-700);border-color:var(--c-neutral-700);color:var(--c-neutral-50)}.tc-rev-tag--c-primary-300-filled{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-neutral-700)}.tc-rev-tag--c-primary-400-filled{background-color:var(--c-primary-400);border-color:var(--c-primary-400);color:var(--c-neutral-700)}.tc-rev-tag--c-primary-500-filled{background-color:var(--c-primary-500);border-color:var(--c-primary-500);color:var(--c-neutral-50)}.tc-rev-tag--c-primary-600-filled{background-color:var(--c-primary-600);border-color:var(--c-primary-600);color:var(--c-neutral-50)}.tc-rev-tag--c-primary-700-filled{background-color:var(--c-primary-700);border-color:var(--c-primary-700);color:var(--c-neutral-50)}.tc-rev-tag--c-danger-300-filled{background-color:var(--c-danger-300);border-color:var(--c-danger-300);color:var(--c-neutral-700)}.tc-rev-tag--c-danger-400-filled{background-color:var(--c-danger-400);border-color:var(--c-danger-400);color:var(--c-neutral-700)}.tc-rev-tag--c-danger-500-filled{background-color:var(--c-danger-500);border-color:var(--c-danger-500);color:var(--c-neutral-50)}.tc-rev-tag--c-alert-300-filled{background-color:var(--c-alert-300);border-color:var(--c-alert-300);color:var(--c-neutral-700)}.tc-rev-tag--c-alert-400-filled{background-color:var(--c-alert-400);border-color:var(--c-alert-400);color:var(--c-neutral-700)}.tc-rev-tag--c-alert-500-filled{background-color:var(--c-alert-500);border-color:var(--c-alert-500);color:var(--c-neutral-700)}.tc-rev-tag--c-info-300-filled{background-color:var(--c-info-300);border-color:var(--c-info-300);color:var(--c-neutral-700)}.tc-rev-tag--c-info-400-filled{background-color:var(--c-info-400);border-color:var(--c-info-400);color:var(--c-neutral-700)}.tc-rev-tag--c-info-500-filled{background-color:var(--c-info-500);border-color:var(--c-info-500);color:var(--c-neutral-50)}.tc-rev-tag--c-success-300-filled{background-color:var(--c-success-300);border-color:var(--c-success-300);color:var(--c-neutral-700)}.tc-rev-tag--c-success-400-filled{background-color:var(--c-success-400);border-color:var(--c-success-400);color:var(--c-neutral-700)}.tc-rev-tag--c-success-500-filled{background-color:var(--c-success-500);border-color:var(--c-success-500);color:var(--c-neutral-700)}.tc-rev-tag--c-neutral-50-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-50);color:var(--c-neutral-50)}.tc-rev-tag--c-neutral-100-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-100);color:var(--c-neutral-100)}.tc-rev-tag--c-neutral-200-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-200);color:var(--c-neutral-200)}.tc-rev-tag--c-neutral-300-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-300)}.tc-rev-tag--c-neutral-400-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-400);color:var(--c-neutral-400)}.tc-rev-tag--c-neutral-500-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-500);color:var(--c-neutral-500)}.tc-rev-tag--c-neutral-600-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-600);color:var(--c-neutral-600)}.tc-rev-tag--c-neutral-700-outline,.tc-rev-tag--c-neutral-800-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-700);color:var(--c-neutral-700)}.tc-rev-tag--c-primary-300-outline{background-color:var(--c-neutral-50);border-color:var(--c-primary-300);color:var(--c-primary-300)}.tc-rev-tag--c-primary-400-outline{background-color:var(--c-neutral-50);border-color:var(--c-primary-400);color:var(--c-primary-400)}.tc-rev-tag--c-primary-500-outline{background-color:var(--c-neutral-50);border-color:var(--c-primary-500);color:var(--c-primary-500)}.tc-rev-tag--c-primary-600-outline{background-color:var(--c-neutral-50);border-color:var(--c-primary-600);color:var(--c-primary-600)}.tc-rev-tag--c-primary-700-outline{background-color:var(--c-neutral-50);border-color:var(--c-primary-700);color:var(--c-primary-700)}.tc-rev-tag--c-danger-300-outline{background-color:var(--c-neutral-50);border-color:var(--c-danger-300);color:var(--c-danger-300)}.tc-rev-tag--c-danger-400-outline{background-color:var(--c-neutral-50);border-color:var(--c-danger-400);color:var(--c-danger-400)}.tc-rev-tag--c-danger-500-outline{background-color:var(--c-neutral-50);border-color:var(--c-danger-500);color:var(--c-danger-500)}.tc-rev-tag--c-alert-300-outline{background-color:var(--c-neutral-50);border-color:var(--c-alert-300);color:var(--c-alert-300)}.tc-rev-tag--c-alert-400-outline{background-color:var(--c-neutral-50);border-color:var(--c-alert-400);color:var(--c-alert-400)}.tc-rev-tag--c-alert-500-outline{background-color:var(--c-neutral-50);border-color:var(--c-alert-500);color:var(--c-alert-500)}.tc-rev-tag--c-info-300-outline{background-color:var(--c-neutral-50);border-color:var(--c-info-300);color:var(--c-info-300)}.tc-rev-tag--c-info-400-outline{background-color:var(--c-neutral-50);border-color:var(--c-info-400);color:var(--c-info-400)}.tc-rev-tag--c-info-500-outline{background-color:var(--c-neutral-50);border-color:var(--c-info-500);color:var(--c-info-500)}.tc-rev-tag--c-success-300-outline{background-color:var(--c-neutral-50);border-color:var(--c-success-300);color:var(--c-success-300)}.tc-rev-tag--c-success-400-outline{background-color:var(--c-neutral-50);border-color:var(--c-success-400);color:var(--c-success-400)}.tc-rev-tag--c-success-500-outline{background-color:var(--c-neutral-50);border-color:var(--c-success-500);color:var(--c-success-500)}\n"] }); }
|
|
13157
|
-
}
|
|
13158
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevTagComponent, decorators: [{
|
|
13159
|
-
type: Component,
|
|
13160
|
-
args: [{ selector: 'tc-rev-tag', imports: [], template: "<span\n [class.tc-rev-tag--sm]=\"size() === 'sm'\"\n [class.tc-rev-tag--md]=\"size() === 'md' || size() === 'regular'\"\n [class.tc-rev-tag--lg]=\"size() === 'lg'\"\n [class.tc-rev-tag--pill]=\"shape() === 'pill'\"\n [class.tc-rev-tag--full-width]=\"fullWidth()\"\n class=\"{{!color() && !variant() ? '' : 'tc-rev-tag tc-rev-tag--c-' + color() + '-' + variant()}}\">\n <ng-content></ng-content>\n</span>\n", styles: [":host{display:block}.tc-rev-tag,.tc-rev-tag--lg,.tc-rev-tag--md,.tc-rev-tag--sm{background-color:var(--c-neutral-50);border:1px solid var(--c-neutral-50);border-radius:var(--bor-radius-4);color:var(--c-neutral-700);cursor:default;display:inline-flex;align-items:center;justify-content:center;gap:var(--size-8);font-family:var(--f-family);font-size:var(--f-size-12);font-weight:var(--f-weight-500);padding:var(--size-2) var(--size-4);height:var(--size-22);max-height:var(--size-22);min-height:var(--size-22)}.tc-rev-tag--full-width{width:100%}.tc-rev-tag--sm{padding:var(--size-2) var(--size-4);height:var(--size-22);max-height:var(--size-22);min-height:var(--size-22)}.tc-rev-tag--md{padding:var(--size-4);height:var(--size-26);max-height:var(--size-26);min-height:var(--size-26)}.tc-rev-tag--lg{padding:var(--size-8);height:var(--size-34);max-height:var(--size-34);min-height:var(--size-34)}.tc-rev-tag--pill{border-radius:var(--bor-radius-pill)}.tc-rev-tag--c-neutral-50-filled{background-color:var(--c-neutral-50);border-color:var(--c-neutral-50);color:var(--c-neutral-700)}.tc-rev-tag--c-neutral-100-filled{background-color:var(--c-neutral-100);border-color:var(--c-neutral-100);color:var(--c-neutral-700)}.tc-rev-tag--c-neutral-200-filled{background-color:var(--c-neutral-200);border-color:var(--c-neutral-200);color:var(--c-neutral-700)}.tc-rev-tag--c-neutral-300-filled{background-color:var(--c-neutral-300);border-color:var(--c-neutral-300);color:var(--c-neutral-700)}.tc-rev-tag--c-neutral-400-filled{background-color:var(--c-neutral-400);border-color:var(--c-neutral-400);color:var(--c-neutral-700)}.tc-rev-tag--c-neutral-500-filled{background-color:var(--c-neutral-500);border-color:var(--c-neutral-500);color:var(--c-neutral-50)}.tc-rev-tag--c-neutral-600-filled{background-color:var(--c-neutral-600);border-color:var(--c-neutral-600);color:var(--c-neutral-50)}.tc-rev-tag--c-neutral-700-filled,.tc-rev-tag--c-neutral-800-filled{background-color:var(--c-neutral-700);border-color:var(--c-neutral-700);color:var(--c-neutral-50)}.tc-rev-tag--c-primary-300-filled{background-color:var(--c-primary-300);border-color:var(--c-primary-300);color:var(--c-neutral-700)}.tc-rev-tag--c-primary-400-filled{background-color:var(--c-primary-400);border-color:var(--c-primary-400);color:var(--c-neutral-700)}.tc-rev-tag--c-primary-500-filled{background-color:var(--c-primary-500);border-color:var(--c-primary-500);color:var(--c-neutral-50)}.tc-rev-tag--c-primary-600-filled{background-color:var(--c-primary-600);border-color:var(--c-primary-600);color:var(--c-neutral-50)}.tc-rev-tag--c-primary-700-filled{background-color:var(--c-primary-700);border-color:var(--c-primary-700);color:var(--c-neutral-50)}.tc-rev-tag--c-danger-300-filled{background-color:var(--c-danger-300);border-color:var(--c-danger-300);color:var(--c-neutral-700)}.tc-rev-tag--c-danger-400-filled{background-color:var(--c-danger-400);border-color:var(--c-danger-400);color:var(--c-neutral-700)}.tc-rev-tag--c-danger-500-filled{background-color:var(--c-danger-500);border-color:var(--c-danger-500);color:var(--c-neutral-50)}.tc-rev-tag--c-alert-300-filled{background-color:var(--c-alert-300);border-color:var(--c-alert-300);color:var(--c-neutral-700)}.tc-rev-tag--c-alert-400-filled{background-color:var(--c-alert-400);border-color:var(--c-alert-400);color:var(--c-neutral-700)}.tc-rev-tag--c-alert-500-filled{background-color:var(--c-alert-500);border-color:var(--c-alert-500);color:var(--c-neutral-700)}.tc-rev-tag--c-info-300-filled{background-color:var(--c-info-300);border-color:var(--c-info-300);color:var(--c-neutral-700)}.tc-rev-tag--c-info-400-filled{background-color:var(--c-info-400);border-color:var(--c-info-400);color:var(--c-neutral-700)}.tc-rev-tag--c-info-500-filled{background-color:var(--c-info-500);border-color:var(--c-info-500);color:var(--c-neutral-50)}.tc-rev-tag--c-success-300-filled{background-color:var(--c-success-300);border-color:var(--c-success-300);color:var(--c-neutral-700)}.tc-rev-tag--c-success-400-filled{background-color:var(--c-success-400);border-color:var(--c-success-400);color:var(--c-neutral-700)}.tc-rev-tag--c-success-500-filled{background-color:var(--c-success-500);border-color:var(--c-success-500);color:var(--c-neutral-700)}.tc-rev-tag--c-neutral-50-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-50);color:var(--c-neutral-50)}.tc-rev-tag--c-neutral-100-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-100);color:var(--c-neutral-100)}.tc-rev-tag--c-neutral-200-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-200);color:var(--c-neutral-200)}.tc-rev-tag--c-neutral-300-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-300);color:var(--c-neutral-300)}.tc-rev-tag--c-neutral-400-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-400);color:var(--c-neutral-400)}.tc-rev-tag--c-neutral-500-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-500);color:var(--c-neutral-500)}.tc-rev-tag--c-neutral-600-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-600);color:var(--c-neutral-600)}.tc-rev-tag--c-neutral-700-outline,.tc-rev-tag--c-neutral-800-outline{background-color:var(--c-neutral-50);border-color:var(--c-neutral-700);color:var(--c-neutral-700)}.tc-rev-tag--c-primary-300-outline{background-color:var(--c-neutral-50);border-color:var(--c-primary-300);color:var(--c-primary-300)}.tc-rev-tag--c-primary-400-outline{background-color:var(--c-neutral-50);border-color:var(--c-primary-400);color:var(--c-primary-400)}.tc-rev-tag--c-primary-500-outline{background-color:var(--c-neutral-50);border-color:var(--c-primary-500);color:var(--c-primary-500)}.tc-rev-tag--c-primary-600-outline{background-color:var(--c-neutral-50);border-color:var(--c-primary-600);color:var(--c-primary-600)}.tc-rev-tag--c-primary-700-outline{background-color:var(--c-neutral-50);border-color:var(--c-primary-700);color:var(--c-primary-700)}.tc-rev-tag--c-danger-300-outline{background-color:var(--c-neutral-50);border-color:var(--c-danger-300);color:var(--c-danger-300)}.tc-rev-tag--c-danger-400-outline{background-color:var(--c-neutral-50);border-color:var(--c-danger-400);color:var(--c-danger-400)}.tc-rev-tag--c-danger-500-outline{background-color:var(--c-neutral-50);border-color:var(--c-danger-500);color:var(--c-danger-500)}.tc-rev-tag--c-alert-300-outline{background-color:var(--c-neutral-50);border-color:var(--c-alert-300);color:var(--c-alert-300)}.tc-rev-tag--c-alert-400-outline{background-color:var(--c-neutral-50);border-color:var(--c-alert-400);color:var(--c-alert-400)}.tc-rev-tag--c-alert-500-outline{background-color:var(--c-neutral-50);border-color:var(--c-alert-500);color:var(--c-alert-500)}.tc-rev-tag--c-info-300-outline{background-color:var(--c-neutral-50);border-color:var(--c-info-300);color:var(--c-info-300)}.tc-rev-tag--c-info-400-outline{background-color:var(--c-neutral-50);border-color:var(--c-info-400);color:var(--c-info-400)}.tc-rev-tag--c-info-500-outline{background-color:var(--c-neutral-50);border-color:var(--c-info-500);color:var(--c-info-500)}.tc-rev-tag--c-success-300-outline{background-color:var(--c-neutral-50);border-color:var(--c-success-300);color:var(--c-success-300)}.tc-rev-tag--c-success-400-outline{background-color:var(--c-neutral-50);border-color:var(--c-success-400);color:var(--c-success-400)}.tc-rev-tag--c-success-500-outline{background-color:var(--c-neutral-50);border-color:var(--c-success-500);color:var(--c-success-500)}\n"] }]
|
|
13161
|
-
}], propDecorators: { size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], shape: [{ type: i0.Input, args: [{ isSignal: true, alias: "shape", required: false }] }], fullWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "fullWidth", required: false }] }] } });
|
|
13162
|
-
|
|
13163
|
-
class TcRevToastComponent {
|
|
13164
|
-
constructor() {
|
|
13165
|
-
this.type = input('info', ...(ngDevMode ? [{ debugName: "type" }] : /* istanbul ignore next */ []));
|
|
13166
|
-
this.fullWidth = input(false, ...(ngDevMode ? [{ debugName: "fullWidth" }] : /* istanbul ignore next */ []));
|
|
13167
|
-
this.size = input('md', ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
13168
|
-
}
|
|
13169
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevToastComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
13170
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.17", type: TcRevToastComponent, isStandalone: true, selector: "tc-rev-toast", inputs: { type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: false, transformFunction: null }, fullWidth: { classPropertyName: "fullWidth", publicName: "fullWidth", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"tc-rev-toast c-neutral-700\">\n <div\n class=\"tc-rev-toast__icon\"\n [ngClass]=\"[\n 'tc-rev-toast__icon--' + type(),\n 'tc-rev-toast__icon--' + size()\n ]\"\n >\n <ng-content select=\"[icon]\" />\n </div>\n\n <div\n class=\"tc-rev-toast__content\"\n [ngClass]=\"[\n 'tc-rev-toast__content--' + type(),\n 'tc-rev-toast__content--' + size()\n ]\"\n [class.full-width]=\"fullWidth()\"\n >\n <ng-content />\n </div>\n</div>\n", styles: [":host{display:block}.tc-rev-toast{display:flex}.tc-rev-toast__icon{align-items:center;border-radius:var(--bor-radius-8) 0 0 var(--bor-radius-8);display:flex;justify-content:center}.tc-rev-toast__icon--info{background-color:var(--c-primary-500)}.tc-rev-toast__icon--success{background-color:var(--c-success-500)}.tc-rev-toast__icon--alert{background-color:var(--c-alert-500)}.tc-rev-toast__icon--danger{background-color:var(--c-danger-500)}.tc-rev-toast__icon--sm{font-size:var(--f-size-20);padding:var(--size-14)}.tc-rev-toast__icon--md{font-size:var(--f-size-24);padding:var(--size-16)}.tc-rev-toast__icon--lg{font-size:var(--f-size-24);padding:var(--size-18)}.tc-rev-toast__content{align-items:center;border-radius:0 var(--bor-radius-8) var(--bor-radius-8) 0;display:flex;font-family:var(--f-family)}.tc-rev-toast__content--info{background-color:var(--c-primary-300)}.tc-rev-toast__content--success{background-color:var(--c-success-300)}.tc-rev-toast__content--alert{background-color:var(--c-alert-300)}.tc-rev-toast__content--danger{background-color:var(--c-danger-300)}.tc-rev-toast__content--sm{padding:var(--size-12);font-size:var(--f-size-12);line-height:var(--l-height-16)}.tc-rev-toast__content--md{padding:var(--size-16);font-size:var(--f-size-14);line-height:var(--l-height-20)}.tc-rev-toast__content--lg{padding:var(--size-18);font-size:var(--f-size-16);line-height:var(--l-height-24)}.tc-rev-toast__content.full-width{flex-grow:1}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] }); }
|
|
13171
|
-
}
|
|
13172
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevToastComponent, decorators: [{
|
|
13173
|
-
type: Component,
|
|
13174
|
-
args: [{ selector: 'tc-rev-toast', imports: [CommonModule], template: "<div class=\"tc-rev-toast c-neutral-700\">\n <div\n class=\"tc-rev-toast__icon\"\n [ngClass]=\"[\n 'tc-rev-toast__icon--' + type(),\n 'tc-rev-toast__icon--' + size()\n ]\"\n >\n <ng-content select=\"[icon]\" />\n </div>\n\n <div\n class=\"tc-rev-toast__content\"\n [ngClass]=\"[\n 'tc-rev-toast__content--' + type(),\n 'tc-rev-toast__content--' + size()\n ]\"\n [class.full-width]=\"fullWidth()\"\n >\n <ng-content />\n </div>\n</div>\n", styles: [":host{display:block}.tc-rev-toast{display:flex}.tc-rev-toast__icon{align-items:center;border-radius:var(--bor-radius-8) 0 0 var(--bor-radius-8);display:flex;justify-content:center}.tc-rev-toast__icon--info{background-color:var(--c-primary-500)}.tc-rev-toast__icon--success{background-color:var(--c-success-500)}.tc-rev-toast__icon--alert{background-color:var(--c-alert-500)}.tc-rev-toast__icon--danger{background-color:var(--c-danger-500)}.tc-rev-toast__icon--sm{font-size:var(--f-size-20);padding:var(--size-14)}.tc-rev-toast__icon--md{font-size:var(--f-size-24);padding:var(--size-16)}.tc-rev-toast__icon--lg{font-size:var(--f-size-24);padding:var(--size-18)}.tc-rev-toast__content{align-items:center;border-radius:0 var(--bor-radius-8) var(--bor-radius-8) 0;display:flex;font-family:var(--f-family)}.tc-rev-toast__content--info{background-color:var(--c-primary-300)}.tc-rev-toast__content--success{background-color:var(--c-success-300)}.tc-rev-toast__content--alert{background-color:var(--c-alert-300)}.tc-rev-toast__content--danger{background-color:var(--c-danger-300)}.tc-rev-toast__content--sm{padding:var(--size-12);font-size:var(--f-size-12);line-height:var(--l-height-16)}.tc-rev-toast__content--md{padding:var(--size-16);font-size:var(--f-size-14);line-height:var(--l-height-20)}.tc-rev-toast__content--lg{padding:var(--size-18);font-size:var(--f-size-16);line-height:var(--l-height-24)}.tc-rev-toast__content.full-width{flex-grow:1}\n"] }]
|
|
13175
|
-
}], propDecorators: { type: [{ type: i0.Input, args: [{ isSignal: true, alias: "type", required: false }] }], fullWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "fullWidth", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }] } });
|
|
13176
|
-
|
|
13177
|
-
class TcRevSubNavbarItemComponent {
|
|
13178
|
-
constructor() {
|
|
13179
|
-
this.label = input.required(...(ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ []));
|
|
13180
|
-
this.onClick = output();
|
|
13181
|
-
this.active = input(false, ...(ngDevMode ? [{ debugName: "active" }] : /* istanbul ignore next */ []));
|
|
13182
|
-
this.routerLink = input(null, ...(ngDevMode ? [{ debugName: "routerLink" }] : /* istanbul ignore next */ []));
|
|
13183
|
-
this.queryParams = input(null, ...(ngDevMode ? [{ debugName: "queryParams" }] : /* istanbul ignore next */ []));
|
|
13184
|
-
}
|
|
13185
|
-
handleClick(_ev) {
|
|
13186
|
-
this.onClick.emit(_ev);
|
|
13187
|
-
}
|
|
13188
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSubNavbarItemComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
13189
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevSubNavbarItemComponent, isStandalone: true, selector: "tc-rev-sub-navbar-item", inputs: { isMenuExpanded: { classPropertyName: "isMenuExpanded", publicName: "isMenuExpanded", isSignal: false, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: true, transformFunction: null }, active: { classPropertyName: "active", publicName: "active", isSignal: true, isRequired: false, transformFunction: null }, routerLink: { classPropertyName: "routerLink", publicName: "routerLink", isSignal: true, isRequired: false, transformFunction: null }, queryParams: { classPropertyName: "queryParams", publicName: "queryParams", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onClick: "onClick" }, ngImport: i0, template: "<li\n class=\"tc-sub-navbar-item\"\n [class.tc-rev-submenu-expanded]=\"isMenuExpanded\">\n <a\n class=\"tc-sub-navbar-item-link\"\n [class.selected]=\"active()\"\n [routerLink]=\"routerLink()\"\n routerLinkActive=\"active\"\n [queryParams]=\"queryParams()\"\n [routerLinkActiveOptions]=\"{ exact: true }\"\n [title]=\"label()\"\n (click)=\"handleClick($event)\">\n\n <div class=\"navbar-item-icon-container\">\n <ng-content select=\"[icon]\"></ng-content>\n </div>\n\n @if (isMenuExpanded)\n {\n <div class=\"navbar-item-label\">\n {{label()}}\n </div>\n }\n </a>\n</li>\n", styles: [":host{display:block}.tc-sub-navbar-item{list-style:none;margin:0;padding:0}.tc-sub-navbar-item .tc-sub-navbar-item-link{align-items:center;border-radius:var(--bor-radius-4);color:var(--c-neutral-700);cursor:pointer;font-family:var(--f-family);display:flex;transition:all .2s ease;text-decoration:none}.tc-sub-navbar-item .tc-sub-navbar-item-link .navbar-item-icon-container{text-align:center;align-content:center;background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);font-size:var(--f-size-20);height:var(--size-36);width:var(--size-36);transition:all .2s ease;min-height:var(--size-36);min-width:var(--size-36);max-height:var(--size-36);max-width:var(--size-36)}.tc-sub-navbar-item .tc-sub-navbar-item-link .navbar-item-icon-container:hover,.tc-sub-navbar-item .tc-sub-navbar-item-link .navbar-item-icon-container:focus{background-color:var(--c-neutral-200);color:var(--c-primary-500)}.tc-sub-navbar-item .tc-sub-navbar-item-link .navbar-item-label{align-content:center;color:var(--c-neutral-700);font-size:var(--f-size-14);height:var(--size-36);padding-left:var(--size-8);transition:all .2s ease;min-height:var(--size-36);max-height:var(--size-36)}.tc-sub-navbar-item .tc-sub-navbar-item-link:hover,.tc-sub-navbar-item .tc-sub-navbar-item-link:focus{color:var(--c-primary-500)}.tc-sub-navbar-item .tc-sub-navbar-item-link.active .navbar-item-icon-container,.tc-sub-navbar-item .tc-sub-navbar-item-link.selected .navbar-item-icon-container,.tc-sub-navbar-item .tc-sub-navbar-item-link:active .navbar-item-icon-container{background-color:var(--c-primary-300);color:var(--c-primary-500)}.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link .navbar-item-icon-container{background-color:var(--c-neutral-200)}.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link:hover .navbar-item-label,.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link:focus .navbar-item-label{color:var(--c-primary-500)}.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link.active,.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link.selected,.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link.active .navbar-item-icon-container,.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link.selected .navbar-item-icon-container{background-color:var(--c-primary-300)}.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link.active .navbar-item-label,.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link.selected .navbar-item-label{color:var(--c-primary-500);font-weight:var(--f-weight-700)}\n"], dependencies: [{ kind: "ngmodule", type: RouterModule }, { kind: "directive", type: i1$2.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: i1$2.RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }] }); }
|
|
13190
|
-
}
|
|
13191
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSubNavbarItemComponent, decorators: [{
|
|
13192
|
-
type: Component,
|
|
13193
|
-
args: [{ selector: 'tc-rev-sub-navbar-item', imports: [
|
|
13194
|
-
RouterModule
|
|
13195
|
-
], template: "<li\n class=\"tc-sub-navbar-item\"\n [class.tc-rev-submenu-expanded]=\"isMenuExpanded\">\n <a\n class=\"tc-sub-navbar-item-link\"\n [class.selected]=\"active()\"\n [routerLink]=\"routerLink()\"\n routerLinkActive=\"active\"\n [queryParams]=\"queryParams()\"\n [routerLinkActiveOptions]=\"{ exact: true }\"\n [title]=\"label()\"\n (click)=\"handleClick($event)\">\n\n <div class=\"navbar-item-icon-container\">\n <ng-content select=\"[icon]\"></ng-content>\n </div>\n\n @if (isMenuExpanded)\n {\n <div class=\"navbar-item-label\">\n {{label()}}\n </div>\n }\n </a>\n</li>\n", styles: [":host{display:block}.tc-sub-navbar-item{list-style:none;margin:0;padding:0}.tc-sub-navbar-item .tc-sub-navbar-item-link{align-items:center;border-radius:var(--bor-radius-4);color:var(--c-neutral-700);cursor:pointer;font-family:var(--f-family);display:flex;transition:all .2s ease;text-decoration:none}.tc-sub-navbar-item .tc-sub-navbar-item-link .navbar-item-icon-container{text-align:center;align-content:center;background-color:var(--c-neutral-50);border-radius:var(--bor-radius-4);font-size:var(--f-size-20);height:var(--size-36);width:var(--size-36);transition:all .2s ease;min-height:var(--size-36);min-width:var(--size-36);max-height:var(--size-36);max-width:var(--size-36)}.tc-sub-navbar-item .tc-sub-navbar-item-link .navbar-item-icon-container:hover,.tc-sub-navbar-item .tc-sub-navbar-item-link .navbar-item-icon-container:focus{background-color:var(--c-neutral-200);color:var(--c-primary-500)}.tc-sub-navbar-item .tc-sub-navbar-item-link .navbar-item-label{align-content:center;color:var(--c-neutral-700);font-size:var(--f-size-14);height:var(--size-36);padding-left:var(--size-8);transition:all .2s ease;min-height:var(--size-36);max-height:var(--size-36)}.tc-sub-navbar-item .tc-sub-navbar-item-link:hover,.tc-sub-navbar-item .tc-sub-navbar-item-link:focus{color:var(--c-primary-500)}.tc-sub-navbar-item .tc-sub-navbar-item-link.active .navbar-item-icon-container,.tc-sub-navbar-item .tc-sub-navbar-item-link.selected .navbar-item-icon-container,.tc-sub-navbar-item .tc-sub-navbar-item-link:active .navbar-item-icon-container{background-color:var(--c-primary-300);color:var(--c-primary-500)}.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link .navbar-item-icon-container{background-color:var(--c-neutral-200)}.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link:hover .navbar-item-label,.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link:focus .navbar-item-label{color:var(--c-primary-500)}.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link.active,.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link.selected,.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link.active .navbar-item-icon-container,.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link.selected .navbar-item-icon-container{background-color:var(--c-primary-300)}.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link.active .navbar-item-label,.tc-sub-navbar-item.tc-rev-submenu-expanded .tc-sub-navbar-item-link.selected .navbar-item-label{color:var(--c-primary-500);font-weight:var(--f-weight-700)}\n"] }]
|
|
13196
|
-
}], propDecorators: { isMenuExpanded: [{
|
|
13197
|
-
type: Input
|
|
13198
|
-
}], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: true }] }], onClick: [{ type: i0.Output, args: ["onClick"] }], active: [{ type: i0.Input, args: [{ isSignal: true, alias: "active", required: false }] }], routerLink: [{ type: i0.Input, args: [{ isSignal: true, alias: "routerLink", required: false }] }], queryParams: [{ type: i0.Input, args: [{ isSignal: true, alias: "queryParams", required: false }] }] } });
|
|
13199
|
-
|
|
13200
|
-
class TcRevSubNavbarComponent {
|
|
13201
|
-
constructor() {
|
|
13202
|
-
this.isMenuExpanded = signal(true, ...(ngDevMode ? [{ debugName: "isMenuExpanded" }] : /* istanbul ignore next */ []));
|
|
13203
|
-
this.onSubMenuExpandChange = output();
|
|
13204
|
-
}
|
|
13205
|
-
ngAfterContentInit() {
|
|
13206
|
-
setTimeout(() => this.setExpandedMenuValueToChildrend(), 0);
|
|
13207
|
-
}
|
|
13208
|
-
handleExpandMenu() {
|
|
13209
|
-
this.isMenuExpanded.update((value) => !value);
|
|
13210
|
-
this.setExpandedMenuValueToChildrend();
|
|
13211
|
-
}
|
|
13212
|
-
setExpandedMenuValueToChildrend() {
|
|
13213
|
-
if (!this.subNavbarItems?.length)
|
|
13214
|
-
return;
|
|
13215
|
-
this.subNavbarItems.forEach((x) => {
|
|
13216
|
-
x.isMenuExpanded = this.isMenuExpanded();
|
|
13217
|
-
});
|
|
13218
|
-
this.onSubMenuExpandChange.emit(this.isMenuExpanded());
|
|
13219
|
-
}
|
|
13220
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSubNavbarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
13221
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.17", type: TcRevSubNavbarComponent, isStandalone: true, selector: "tc-rev-sub-navbar", outputs: { onSubMenuExpandChange: "onSubMenuExpandChange" }, queries: [{ propertyName: "subNavbarItems", predicate: TcRevSubNavbarItemComponent }], ngImport: i0, template: "<nav class=\"tc-sub-navbar\">\n <ul\n class=\"tc-sub-navbar-list\"\n [class.tc-rev-submenu-expanded]=\"isMenuExpanded()\"\n >\n <tc-rev-sub-navbar-item\n [isMenuExpanded]=\"isMenuExpanded()\"\n (click)=\"handleExpandMenu()\"\n label=\"Minimizar\"\n >\n <i\n class=\"fa-light\"\n [class.fa-arrow-left-to-line]=\"isMenuExpanded()\"\n [class.fa-arrow-right-to-line]=\"!isMenuExpanded()\"\n icon\n ></i>\n </tc-rev-sub-navbar-item>\n <ng-content></ng-content>\n </ul>\n</nav>\n", styles: [":host{display:block;height:100%}.tc-sub-navbar{height:100%;margin:var(--size-0);padding:var(--size-0)}.tc-sub-navbar .tc-sub-navbar-list{background-color:var(--c-neutral-50);color:var(--c-neutral-700);box-shadow:var(--shadow-xs);border-radius:var(--bor-radius-8);display:flex;flex-direction:column;gap:var(--size-8);height:100%;list-style:none;margin:var(--size-0);overflow:hidden auto;padding:var(--size-8);width:var(--size-52)}.tc-sub-navbar .tc-sub-navbar-list::-webkit-scrollbar{display:none}.tc-sub-navbar .tc-sub-navbar-list.tc-rev-submenu-expanded{width:14.5rem}\n"], dependencies: [{ kind: "component", type: TcRevSubNavbarItemComponent, selector: "tc-rev-sub-navbar-item", inputs: ["isMenuExpanded", "label", "active", "routerLink", "queryParams"], outputs: ["onClick"] }] }); }
|
|
13222
|
-
}
|
|
13223
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevSubNavbarComponent, decorators: [{
|
|
13224
|
-
type: Component,
|
|
13225
|
-
args: [{ selector: 'tc-rev-sub-navbar', imports: [
|
|
13226
|
-
TcRevSubNavbarItemComponent
|
|
13227
|
-
], template: "<nav class=\"tc-sub-navbar\">\n <ul\n class=\"tc-sub-navbar-list\"\n [class.tc-rev-submenu-expanded]=\"isMenuExpanded()\"\n >\n <tc-rev-sub-navbar-item\n [isMenuExpanded]=\"isMenuExpanded()\"\n (click)=\"handleExpandMenu()\"\n label=\"Minimizar\"\n >\n <i\n class=\"fa-light\"\n [class.fa-arrow-left-to-line]=\"isMenuExpanded()\"\n [class.fa-arrow-right-to-line]=\"!isMenuExpanded()\"\n icon\n ></i>\n </tc-rev-sub-navbar-item>\n <ng-content></ng-content>\n </ul>\n</nav>\n", styles: [":host{display:block;height:100%}.tc-sub-navbar{height:100%;margin:var(--size-0);padding:var(--size-0)}.tc-sub-navbar .tc-sub-navbar-list{background-color:var(--c-neutral-50);color:var(--c-neutral-700);box-shadow:var(--shadow-xs);border-radius:var(--bor-radius-8);display:flex;flex-direction:column;gap:var(--size-8);height:100%;list-style:none;margin:var(--size-0);overflow:hidden auto;padding:var(--size-8);width:var(--size-52)}.tc-sub-navbar .tc-sub-navbar-list::-webkit-scrollbar{display:none}.tc-sub-navbar .tc-sub-navbar-list.tc-rev-submenu-expanded{width:14.5rem}\n"] }]
|
|
13228
|
-
}], propDecorators: { subNavbarItems: [{
|
|
13229
|
-
type: ContentChildren,
|
|
13230
|
-
args: [TcRevSubNavbarItemComponent]
|
|
13231
|
-
}], onSubMenuExpandChange: [{ type: i0.Output, args: ["onSubMenuExpandChange"] }] } });
|
|
13232
|
-
|
|
13233
|
-
class TcRevWizardStepsComponent {
|
|
13234
|
-
constructor() {
|
|
13235
|
-
this.onStepClick = output();
|
|
13236
|
-
this.direction = input('horizontal', ...(ngDevMode ? [{ debugName: "direction" }] : /* istanbul ignore next */ []));
|
|
13237
|
-
this.currentStep = input(0, ...(ngDevMode ? [{ debugName: "currentStep" }] : /* istanbul ignore next */ []));
|
|
13238
|
-
this.stepClickable = input(false, ...(ngDevMode ? [{ debugName: "stepClickable" }] : /* istanbul ignore next */ []));
|
|
13239
|
-
this.steps = input.required(...(ngDevMode ? [{ debugName: "steps" }] : /* istanbul ignore next */ []));
|
|
13240
|
-
}
|
|
13241
|
-
handleStepClick(step, isNext, index) {
|
|
13242
|
-
if (this.stepClickable() && !isNext) {
|
|
13243
|
-
this.onStepClick.emit({ step, index });
|
|
13244
|
-
}
|
|
13245
|
-
}
|
|
13246
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevWizardStepsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
13247
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevWizardStepsComponent, isStandalone: true, selector: "tc-rev-wizard-steps", inputs: { direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null }, currentStep: { classPropertyName: "currentStep", publicName: "currentStep", isSignal: true, isRequired: false, transformFunction: null }, stepClickable: { classPropertyName: "stepClickable", publicName: "stepClickable", isSignal: true, isRequired: false, transformFunction: null }, steps: { classPropertyName: "steps", publicName: "steps", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { onStepClick: "onStepClick" }, ngImport: i0, template: "<div [class]=\"'tc-rev-wizard-steps' + ` tc-rev-wizard-steps--${this.direction()}`\">\n @for (step of this.steps(); let i = $index; track step.title + i) {\n @let isCompleted = step.completed || i + 1 < this.currentStep();\n @let isNext = i + 1 > this.currentStep();\n <div\n class=\"tc-rev-wizard-step\"\n [class.tc-rev-wizard-step--current]=\"i + 1 === this.currentStep()\"\n [class.tc-rev-wizard-step--completed]=\"isCompleted\"\n [class.tc-rev-wizard-step--next]=\"isNext\">\n\n <span\n class=\"tc-rev-wizard-step__counter f-h3\"\n [class.cursor-default]=\"!this.stepClickable()\"\n [class.cursor-pointer]=\"this.stepClickable() && !isNext\"\n (click)=\"this.handleStepClick(step, isNext, i)\">\n @if (isCompleted) {\n <i class=\"fas fa-check\"></i>\n }\n @else {\n {{ i + 1 }}\n }\n </span>\n\n <div class=\"tc-rev-wizard-step__info\">\n <p class=\"tc-rev-wizard-step__title f-lg mar-none cursor-default\">\n {{ step.title }}\n </p>\n\n @if (step.description) {\n <p class=\"tc-rev-wizard-step__description f-sm mar-none cursor-default\">\n {{ step.description }}\n </p>\n }\n </div>\n </div>\n }\n</div>\n\n<!-- VERS\u00C3O COM DIVISOR -->\n<!-- <div [class]=\"'tc-rev-wizard-steps' + ` tc-rev-wizard-steps--${this.direction()}`\">\n @for (step of this.steps(); let i = $index; let last = $last; track step.title + i) {\n @let isCompleted = step.completed || i + 1 < this.currentStep();\n\n <div\n class=\"tc-rev-wizard-step\"\n [class.tc-rev-wizard-step--current]=\"i + 1 === this.currentStep()\"\n [class.tc-rev-wizard-step--completed]=\"isCompleted\"\n [class.tc-rev-wizard-step--next]=\"i + 1 > this.currentStep()\"\n [ngClass]=\"this.direction()\">\n\n <span class=\"tc-rev-wizard-step__counter f-h3 cursor-default\">\n {{ i + 1 }}\n </span>\n\n <div class=\"tc-rev-wizard-step__info\">\n <p class=\"tc-rev-wizard-step__title f-lg mar-none cursor-default\">\n {{ step.title }}\n </p>\n\n @if (step.description) {\n <p class=\"tc-rev-wizard-step__description f-sm mar-none cursor-default\">\n {{ step.description }}\n </p>\n }\n </div>\n </div>\n\n @if (this.steps().length > i && !last) {\n <div\n class=\"tc-rev-wizard-step-divider\"\n [class.completed]=\"isCompleted\"\n [ngClass]=\"this.direction()\">\n </div>\n }\n }\n</div> -->\n", styles: [":host{display:block}.tc-rev-wizard-steps{display:inline-flex;font-family:var(--f-family);gap:var(--size-32)}.tc-rev-wizard-steps--horizontal{flex-direction:row}.tc-rev-wizard-steps--vertical{flex-direction:column}.tc-rev-wizard-steps .tc-rev-wizard-step{display:flex;gap:var(--size-8)}.tc-rev-wizard-steps .tc-rev-wizard-step__info{max-width:13.25rem}.tc-rev-wizard-steps .tc-rev-wizard-step__counter{align-items:center;border:1px solid;border-radius:var(--bor-radius-rounded);display:flex;height:var(--size-40);justify-content:center;width:var(--size-40);transition:all .3s ease;min-height:var(--size-40);min-width:var(--size-40)}.tc-rev-wizard-steps .tc-rev-wizard-step--completed .tc-rev-wizard-step__counter{border-color:1px solid var(--c-primary-600);color:var(--c-neutral-600)}.tc-rev-wizard-steps .tc-rev-wizard-step--completed .tc-rev-wizard-step__title{color:var(--c-neutral-600);font-weight:var(--f-weight-400)}.tc-rev-wizard-steps .tc-rev-wizard-step--completed .tc-rev-wizard-step__description{color:var(--c-neutral-600)}.tc-rev-wizard-steps .tc-rev-wizard-step--current .tc-rev-wizard-step__counter{background-color:var(--c-primary-500);border-color:var(--c-primary-500);color:var(--c-neutral-50)}.tc-rev-wizard-steps .tc-rev-wizard-step--current .tc-rev-wizard-step__title{color:var(--c-neutral-700);font-weight:var(--f-weight-600)}.tc-rev-wizard-steps .tc-rev-wizard-step--current .tc-rev-wizard-step__description{color:var(--c-neutral-700);font-weight:var(--f-weight-400)}.tc-rev-wizard-steps .tc-rev-wizard-step--next .tc-rev-wizard-step__counter{border-color:var(--c-neutral-400);color:var(--c-neutral-400)}.tc-rev-wizard-steps .tc-rev-wizard-step--next .tc-rev-wizard-step__title{color:var(--c-neutral-400);font-weight:var(--f-weight-400)}.tc-rev-wizard-steps .tc-rev-wizard-step--next .tc-rev-wizard-step__description{color:var(--c-neutral-400)}\n"] }); }
|
|
13248
|
-
}
|
|
13249
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevWizardStepsComponent, decorators: [{
|
|
13250
|
-
type: Component,
|
|
13251
|
-
args: [{ selector: 'tc-rev-wizard-steps', imports: [], template: "<div [class]=\"'tc-rev-wizard-steps' + ` tc-rev-wizard-steps--${this.direction()}`\">\n @for (step of this.steps(); let i = $index; track step.title + i) {\n @let isCompleted = step.completed || i + 1 < this.currentStep();\n @let isNext = i + 1 > this.currentStep();\n <div\n class=\"tc-rev-wizard-step\"\n [class.tc-rev-wizard-step--current]=\"i + 1 === this.currentStep()\"\n [class.tc-rev-wizard-step--completed]=\"isCompleted\"\n [class.tc-rev-wizard-step--next]=\"isNext\">\n\n <span\n class=\"tc-rev-wizard-step__counter f-h3\"\n [class.cursor-default]=\"!this.stepClickable()\"\n [class.cursor-pointer]=\"this.stepClickable() && !isNext\"\n (click)=\"this.handleStepClick(step, isNext, i)\">\n @if (isCompleted) {\n <i class=\"fas fa-check\"></i>\n }\n @else {\n {{ i + 1 }}\n }\n </span>\n\n <div class=\"tc-rev-wizard-step__info\">\n <p class=\"tc-rev-wizard-step__title f-lg mar-none cursor-default\">\n {{ step.title }}\n </p>\n\n @if (step.description) {\n <p class=\"tc-rev-wizard-step__description f-sm mar-none cursor-default\">\n {{ step.description }}\n </p>\n }\n </div>\n </div>\n }\n</div>\n\n<!-- VERS\u00C3O COM DIVISOR -->\n<!-- <div [class]=\"'tc-rev-wizard-steps' + ` tc-rev-wizard-steps--${this.direction()}`\">\n @for (step of this.steps(); let i = $index; let last = $last; track step.title + i) {\n @let isCompleted = step.completed || i + 1 < this.currentStep();\n\n <div\n class=\"tc-rev-wizard-step\"\n [class.tc-rev-wizard-step--current]=\"i + 1 === this.currentStep()\"\n [class.tc-rev-wizard-step--completed]=\"isCompleted\"\n [class.tc-rev-wizard-step--next]=\"i + 1 > this.currentStep()\"\n [ngClass]=\"this.direction()\">\n\n <span class=\"tc-rev-wizard-step__counter f-h3 cursor-default\">\n {{ i + 1 }}\n </span>\n\n <div class=\"tc-rev-wizard-step__info\">\n <p class=\"tc-rev-wizard-step__title f-lg mar-none cursor-default\">\n {{ step.title }}\n </p>\n\n @if (step.description) {\n <p class=\"tc-rev-wizard-step__description f-sm mar-none cursor-default\">\n {{ step.description }}\n </p>\n }\n </div>\n </div>\n\n @if (this.steps().length > i && !last) {\n <div\n class=\"tc-rev-wizard-step-divider\"\n [class.completed]=\"isCompleted\"\n [ngClass]=\"this.direction()\">\n </div>\n }\n }\n</div> -->\n", styles: [":host{display:block}.tc-rev-wizard-steps{display:inline-flex;font-family:var(--f-family);gap:var(--size-32)}.tc-rev-wizard-steps--horizontal{flex-direction:row}.tc-rev-wizard-steps--vertical{flex-direction:column}.tc-rev-wizard-steps .tc-rev-wizard-step{display:flex;gap:var(--size-8)}.tc-rev-wizard-steps .tc-rev-wizard-step__info{max-width:13.25rem}.tc-rev-wizard-steps .tc-rev-wizard-step__counter{align-items:center;border:1px solid;border-radius:var(--bor-radius-rounded);display:flex;height:var(--size-40);justify-content:center;width:var(--size-40);transition:all .3s ease;min-height:var(--size-40);min-width:var(--size-40)}.tc-rev-wizard-steps .tc-rev-wizard-step--completed .tc-rev-wizard-step__counter{border-color:1px solid var(--c-primary-600);color:var(--c-neutral-600)}.tc-rev-wizard-steps .tc-rev-wizard-step--completed .tc-rev-wizard-step__title{color:var(--c-neutral-600);font-weight:var(--f-weight-400)}.tc-rev-wizard-steps .tc-rev-wizard-step--completed .tc-rev-wizard-step__description{color:var(--c-neutral-600)}.tc-rev-wizard-steps .tc-rev-wizard-step--current .tc-rev-wizard-step__counter{background-color:var(--c-primary-500);border-color:var(--c-primary-500);color:var(--c-neutral-50)}.tc-rev-wizard-steps .tc-rev-wizard-step--current .tc-rev-wizard-step__title{color:var(--c-neutral-700);font-weight:var(--f-weight-600)}.tc-rev-wizard-steps .tc-rev-wizard-step--current .tc-rev-wizard-step__description{color:var(--c-neutral-700);font-weight:var(--f-weight-400)}.tc-rev-wizard-steps .tc-rev-wizard-step--next .tc-rev-wizard-step__counter{border-color:var(--c-neutral-400);color:var(--c-neutral-400)}.tc-rev-wizard-steps .tc-rev-wizard-step--next .tc-rev-wizard-step__title{color:var(--c-neutral-400);font-weight:var(--f-weight-400)}.tc-rev-wizard-steps .tc-rev-wizard-step--next .tc-rev-wizard-step__description{color:var(--c-neutral-400)}\n"] }]
|
|
13252
|
-
}], propDecorators: { onStepClick: [{ type: i0.Output, args: ["onStepClick"] }], direction: [{ type: i0.Input, args: [{ isSignal: true, alias: "direction", required: false }] }], currentStep: [{ type: i0.Input, args: [{ isSignal: true, alias: "currentStep", required: false }] }], stepClickable: [{ type: i0.Input, args: [{ isSignal: true, alias: "stepClickable", required: false }] }], steps: [{ type: i0.Input, args: [{ isSignal: true, alias: "steps", required: true }] }] } });
|
|
13253
|
-
|
|
13254
|
-
class TcRevBreadcrumbService {
|
|
13255
|
-
constructor() {
|
|
13256
|
-
this.breadcrumbsSubject = new BehaviorSubject([]);
|
|
13257
|
-
this.breadcrumbs$ = this.breadcrumbsSubject.asObservable();
|
|
13258
|
-
}
|
|
13259
|
-
setBreadcrumb(items) {
|
|
13260
|
-
this.breadcrumbsSubject.next(items);
|
|
13261
|
-
}
|
|
13262
|
-
addLevel(item) {
|
|
13263
|
-
const currentItems = this.breadcrumbsSubject.getValue();
|
|
13264
|
-
this.breadcrumbsSubject.next([...currentItems, item]);
|
|
13265
|
-
}
|
|
13266
|
-
removeLastLevel() {
|
|
13267
|
-
const currentItems = this.breadcrumbsSubject.getValue();
|
|
13268
|
-
if (currentItems.length > 0) {
|
|
13269
|
-
const newItems = [...currentItems];
|
|
13270
|
-
newItems.pop();
|
|
13271
|
-
this.breadcrumbsSubject.next(newItems);
|
|
13272
|
-
}
|
|
13273
|
-
}
|
|
13274
|
-
clear() {
|
|
13275
|
-
this.breadcrumbsSubject.next([]);
|
|
13276
|
-
}
|
|
13277
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevBreadcrumbService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
13278
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevBreadcrumbService, providedIn: 'root' }); }
|
|
13279
|
-
}
|
|
13280
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevBreadcrumbService, decorators: [{
|
|
13281
|
-
type: Injectable,
|
|
13282
|
-
args: [{
|
|
13283
|
-
providedIn: 'root',
|
|
13284
|
-
}]
|
|
13285
|
-
}], ctorParameters: () => [] });
|
|
13286
|
-
|
|
13287
|
-
class TcRevBreadcrumbComponent {
|
|
13288
|
-
constructor() {
|
|
13289
|
-
this.breadcrumbs = [];
|
|
13290
|
-
this.router = inject(Router);
|
|
13291
|
-
this.breadcrumbService = inject(TcRevBreadcrumbService);
|
|
13292
|
-
}
|
|
13293
|
-
ngOnInit() {
|
|
13294
|
-
this.breadcrumbService.breadcrumbs$.subscribe(items => this.breadcrumbs = items);
|
|
13295
|
-
}
|
|
13296
|
-
navigate(url, index) {
|
|
13297
|
-
if (url) {
|
|
13298
|
-
this.router.navigateByUrl(url);
|
|
13299
|
-
// Opcional: remover níveis do breadcrumb após o clicado
|
|
13300
|
-
if (index !== undefined && index < this.breadcrumbs.length - 1) {
|
|
13301
|
-
this.breadcrumbService.setBreadcrumb(this.breadcrumbs.slice(0, index + 1));
|
|
13302
|
-
}
|
|
13303
|
-
}
|
|
13304
|
-
}
|
|
13305
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevBreadcrumbComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
13306
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: TcRevBreadcrumbComponent, isStandalone: true, selector: "tc-rev-breadcrumb", ngImport: i0, template: "<nav aria-label=\"breadcrumb\" class=\"tc-rev-breadcrumb\">\n <ol class=\"tc-rev-breadcrumb-list\">\n <!-- Link para o Dashboard -->\n <li class=\"tc-rev-breadcrumb-item\">\n <a [routerLink]=\"['/dashboard']\"><i class=\"fa-light fa-house-blank\"></i>\n @if (breadcrumbs.length > 0)\n {\n <i class=\"fa-light fa-chevron-right\"></i>\n }\n @else\n {\n P\u00E1gina inicial\n }\n </a>\n</li>\n\n<!-- Itera\u00E7\u00E3o sobre os itens do breadcrumb -->\n@for (breadcrumb of breadcrumbs; track breadcrumb; let i = $index; let last = $last) {\n <li\n class=\"tc-rev-breadcrumb-item\"\n [ngClass]=\"{ 'active': last }\"\n [attr.aria-current]=\"last ? 'page' : null\">\n @if (!last) {\n <a (click)=\"navigate(breadcrumb.url, i)\">{{ breadcrumb.label }}</a>\n <i class=\"fa-light fa-chevron-right\"></i>\n }\n @if (last) {\n {{ breadcrumb.label }}\n }\n </li>\n}\n</ol>\n</nav>", styles: [":host{display:block}.tc-rev-breadcrumb-list{display:flex;list-style:none;padding:0;margin:0;margin-bottom:var(--size-24)}.tc-rev-breadcrumb-item{display:flex;align-items:center;color:var(--c-neutral-700);font-size:var(--f-size-14);font-family:var(--f-family)}.tc-rev-breadcrumb-item a{text-decoration:none;color:inherit;cursor:pointer}.tc-rev-breadcrumb-item a:hover{text-decoration:underline}.tc-rev-breadcrumb-item i{margin:0}.tc-rev-breadcrumb-item i.fa-chevron-right{margin:0 var(--size-12)}.tc-rev-breadcrumb-item.active{pointer-events:none}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: RouterModule }, { kind: "directive", type: i1$2.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }] }); }
|
|
13307
|
-
}
|
|
13308
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevBreadcrumbComponent, decorators: [{
|
|
13309
|
-
type: Component,
|
|
13310
|
-
args: [{ selector: 'tc-rev-breadcrumb', imports: [
|
|
13311
|
-
CommonModule,
|
|
13312
|
-
RouterModule
|
|
13313
|
-
], template: "<nav aria-label=\"breadcrumb\" class=\"tc-rev-breadcrumb\">\n <ol class=\"tc-rev-breadcrumb-list\">\n <!-- Link para o Dashboard -->\n <li class=\"tc-rev-breadcrumb-item\">\n <a [routerLink]=\"['/dashboard']\"><i class=\"fa-light fa-house-blank\"></i>\n @if (breadcrumbs.length > 0)\n {\n <i class=\"fa-light fa-chevron-right\"></i>\n }\n @else\n {\n P\u00E1gina inicial\n }\n </a>\n</li>\n\n<!-- Itera\u00E7\u00E3o sobre os itens do breadcrumb -->\n@for (breadcrumb of breadcrumbs; track breadcrumb; let i = $index; let last = $last) {\n <li\n class=\"tc-rev-breadcrumb-item\"\n [ngClass]=\"{ 'active': last }\"\n [attr.aria-current]=\"last ? 'page' : null\">\n @if (!last) {\n <a (click)=\"navigate(breadcrumb.url, i)\">{{ breadcrumb.label }}</a>\n <i class=\"fa-light fa-chevron-right\"></i>\n }\n @if (last) {\n {{ breadcrumb.label }}\n }\n </li>\n}\n</ol>\n</nav>", styles: [":host{display:block}.tc-rev-breadcrumb-list{display:flex;list-style:none;padding:0;margin:0;margin-bottom:var(--size-24)}.tc-rev-breadcrumb-item{display:flex;align-items:center;color:var(--c-neutral-700);font-size:var(--f-size-14);font-family:var(--f-family)}.tc-rev-breadcrumb-item a{text-decoration:none;color:inherit;cursor:pointer}.tc-rev-breadcrumb-item a:hover{text-decoration:underline}.tc-rev-breadcrumb-item i{margin:0}.tc-rev-breadcrumb-item i.fa-chevron-right{margin:0 var(--size-12)}.tc-rev-breadcrumb-item.active{pointer-events:none}\n"] }]
|
|
13314
|
-
}], ctorParameters: () => [] });
|
|
13315
|
-
|
|
13316
|
-
class TcRevComponentsLibModule {
|
|
13317
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevComponentsLibModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
13318
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "21.2.17", ngImport: i0, type: TcRevComponentsLibModule, imports: [TcRevBreadcrumbComponent,
|
|
13319
|
-
TcRevButtonDirective,
|
|
13320
|
-
TcRevCalendarComponent,
|
|
13321
|
-
TcRevCardComponent,
|
|
13322
|
-
TcRevCardAccordionComponent,
|
|
13323
|
-
TcRevCardTitleComponent,
|
|
13324
|
-
TcRevCheckboxDirective,
|
|
13325
|
-
TcRevDropdownComponent,
|
|
13326
|
-
TcRevDropdownGroupedComponent,
|
|
13327
|
-
TcRevDropdownMultiComponent,
|
|
13328
|
-
TcRevDropdownMultiLevelComponent,
|
|
13329
|
-
TcRevEmptyContentComponent,
|
|
13330
|
-
TcRevFaqComponent,
|
|
13331
|
-
TcRevIconButtonDirective,
|
|
13332
|
-
TcRevInputContainerComponent,
|
|
13333
|
-
TcRevInputDirective,
|
|
13334
|
-
TcRevLoadingComponent,
|
|
13335
|
-
TcRevMessageComponent,
|
|
13336
|
-
TcRevMultiInputComponent,
|
|
13337
|
-
TcRevPaginationComponent,
|
|
13338
|
-
TcRevProgressStatusBarComponent,
|
|
13339
|
-
TcRevRadioDirective,
|
|
13340
|
-
TcRevSearchInputComponent,
|
|
13341
|
-
TcRevSideDrawerComponent,
|
|
13342
|
-
TcRevSkeletonLoadingComponent,
|
|
13343
|
-
TcRevSlideToggleDirective,
|
|
13344
|
-
TcRevSmallLoadingComponent,
|
|
13345
|
-
TcRevTabGroupComponent,
|
|
13346
|
-
TcRevTabItemComponent,
|
|
13347
|
-
TcRevTagComponent,
|
|
13348
|
-
TcRevToastComponent,
|
|
13349
|
-
TcRevTooltipDirective,
|
|
13350
|
-
TcRevSubNavbarComponent,
|
|
13351
|
-
TcRevSubNavbarItemComponent,
|
|
13352
|
-
TcRevWizardStepsComponent], exports: [
|
|
13353
|
-
// TcRevBreadcrumbComponent,
|
|
13354
|
-
TcRevButtonDirective,
|
|
13355
|
-
TcRevCalendarComponent,
|
|
13356
|
-
TcRevCardComponent,
|
|
13357
|
-
TcRevCardAccordionComponent,
|
|
13358
|
-
TcRevCardTitleComponent,
|
|
13359
|
-
TcRevCheckboxDirective,
|
|
13360
|
-
TcRevDropdownComponent,
|
|
13361
|
-
TcRevDropdownGroupedComponent,
|
|
13362
|
-
TcRevDropdownMultiComponent,
|
|
13363
|
-
TcRevDropdownMultiLevelComponent,
|
|
13364
|
-
TcRevEmptyContentComponent,
|
|
13365
|
-
TcRevFaqComponent,
|
|
13366
|
-
TcRevIconButtonDirective,
|
|
13367
|
-
TcRevInputContainerComponent,
|
|
13368
|
-
TcRevInputDirective,
|
|
13369
|
-
TcRevLoadingComponent,
|
|
13370
|
-
TcRevMessageComponent,
|
|
13371
|
-
TcRevMultiInputComponent,
|
|
13372
|
-
TcRevPaginationComponent,
|
|
13373
|
-
TcRevProgressStatusBarComponent,
|
|
13374
|
-
TcRevSmallLoadingComponent,
|
|
13375
|
-
TcRevRadioDirective,
|
|
13376
|
-
TcRevSearchInputComponent,
|
|
13377
|
-
TcRevSideDrawerComponent,
|
|
13378
|
-
TcRevSkeletonLoadingComponent,
|
|
13379
|
-
TcRevSlideToggleDirective,
|
|
13380
|
-
TcRevTabGroupComponent,
|
|
13381
|
-
TcRevTabItemComponent,
|
|
13382
|
-
TcRevTagComponent,
|
|
13383
|
-
TcRevToastComponent,
|
|
13384
|
-
TcRevTooltipDirective,
|
|
13385
|
-
TcRevSubNavbarComponent,
|
|
13386
|
-
TcRevSubNavbarItemComponent,
|
|
13387
|
-
TcRevWizardStepsComponent] }); }
|
|
13388
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevComponentsLibModule, imports: [TcRevBreadcrumbComponent,
|
|
13389
|
-
TcRevCalendarComponent,
|
|
13390
|
-
TcRevCardComponent,
|
|
13391
|
-
TcRevCardAccordionComponent,
|
|
13392
|
-
TcRevDropdownComponent,
|
|
13393
|
-
TcRevDropdownGroupedComponent,
|
|
13394
|
-
TcRevDropdownMultiComponent,
|
|
13395
|
-
TcRevDropdownMultiLevelComponent,
|
|
13396
|
-
TcRevInputContainerComponent,
|
|
13397
|
-
TcRevMessageComponent,
|
|
13398
|
-
TcRevMultiInputComponent,
|
|
13399
|
-
TcRevPaginationComponent,
|
|
13400
|
-
TcRevSearchInputComponent,
|
|
13401
|
-
TcRevSkeletonLoadingComponent,
|
|
13402
|
-
TcRevSmallLoadingComponent,
|
|
13403
|
-
TcRevTabItemComponent,
|
|
13404
|
-
TcRevToastComponent,
|
|
13405
|
-
TcRevSubNavbarComponent,
|
|
13406
|
-
TcRevSubNavbarItemComponent] }); }
|
|
13407
|
-
}
|
|
13408
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: TcRevComponentsLibModule, decorators: [{
|
|
13409
|
-
type: NgModule,
|
|
13410
|
-
args: [{
|
|
13411
|
-
imports: [
|
|
13412
|
-
TcRevBreadcrumbComponent,
|
|
13413
|
-
TcRevButtonDirective,
|
|
13414
|
-
TcRevCalendarComponent,
|
|
13415
|
-
TcRevCardComponent,
|
|
13416
|
-
TcRevCardAccordionComponent,
|
|
13417
|
-
TcRevCardTitleComponent,
|
|
13418
|
-
TcRevCheckboxDirective,
|
|
13419
|
-
TcRevDropdownComponent,
|
|
13420
|
-
TcRevDropdownGroupedComponent,
|
|
13421
|
-
TcRevDropdownMultiComponent,
|
|
13422
|
-
TcRevDropdownMultiLevelComponent,
|
|
13423
|
-
TcRevEmptyContentComponent,
|
|
13424
|
-
TcRevFaqComponent,
|
|
13425
|
-
TcRevIconButtonDirective,
|
|
13426
|
-
TcRevInputContainerComponent,
|
|
13427
|
-
TcRevInputDirective,
|
|
13428
|
-
TcRevLoadingComponent,
|
|
13429
|
-
TcRevMessageComponent,
|
|
13430
|
-
TcRevMultiInputComponent,
|
|
13431
|
-
TcRevPaginationComponent,
|
|
13432
|
-
TcRevProgressStatusBarComponent,
|
|
13433
|
-
TcRevRadioDirective,
|
|
13434
|
-
TcRevSearchInputComponent,
|
|
13435
|
-
TcRevSideDrawerComponent,
|
|
13436
|
-
TcRevSkeletonLoadingComponent,
|
|
13437
|
-
TcRevSlideToggleDirective,
|
|
13438
|
-
TcRevSmallLoadingComponent,
|
|
13439
|
-
TcRevTabGroupComponent,
|
|
13440
|
-
TcRevTabItemComponent,
|
|
13441
|
-
TcRevTagComponent,
|
|
13442
|
-
TcRevToastComponent,
|
|
13443
|
-
TcRevTooltipDirective,
|
|
13444
|
-
TcRevSubNavbarComponent,
|
|
13445
|
-
TcRevSubNavbarItemComponent,
|
|
13446
|
-
TcRevWizardStepsComponent,
|
|
13447
|
-
],
|
|
13448
|
-
exports: [
|
|
13449
|
-
// TcRevBreadcrumbComponent,
|
|
13450
|
-
TcRevButtonDirective,
|
|
13451
|
-
TcRevCalendarComponent,
|
|
13452
|
-
TcRevCardComponent,
|
|
13453
|
-
TcRevCardAccordionComponent,
|
|
13454
|
-
TcRevCardTitleComponent,
|
|
13455
|
-
TcRevCheckboxDirective,
|
|
13456
|
-
TcRevDropdownComponent,
|
|
13457
|
-
TcRevDropdownGroupedComponent,
|
|
13458
|
-
TcRevDropdownMultiComponent,
|
|
13459
|
-
TcRevDropdownMultiLevelComponent,
|
|
13460
|
-
TcRevEmptyContentComponent,
|
|
13461
|
-
TcRevFaqComponent,
|
|
13462
|
-
TcRevIconButtonDirective,
|
|
13463
|
-
TcRevInputContainerComponent,
|
|
13464
|
-
TcRevInputDirective,
|
|
13465
|
-
TcRevLoadingComponent,
|
|
13466
|
-
TcRevMessageComponent,
|
|
13467
|
-
TcRevMultiInputComponent,
|
|
13468
|
-
TcRevPaginationComponent,
|
|
13469
|
-
TcRevProgressStatusBarComponent,
|
|
13470
|
-
TcRevSmallLoadingComponent,
|
|
13471
|
-
TcRevRadioDirective,
|
|
13472
|
-
TcRevSearchInputComponent,
|
|
13473
|
-
TcRevSideDrawerComponent,
|
|
13474
|
-
TcRevSkeletonLoadingComponent,
|
|
13475
|
-
TcRevSlideToggleDirective,
|
|
13476
|
-
TcRevTabGroupComponent,
|
|
13477
|
-
TcRevTabItemComponent,
|
|
13478
|
-
TcRevTagComponent,
|
|
13479
|
-
TcRevToastComponent,
|
|
13480
|
-
TcRevTooltipDirective,
|
|
13481
|
-
TcRevSubNavbarComponent,
|
|
13482
|
-
TcRevSubNavbarItemComponent,
|
|
13483
|
-
TcRevWizardStepsComponent,
|
|
13484
|
-
],
|
|
13485
|
-
declarations: [],
|
|
13486
|
-
providers: [],
|
|
13487
|
-
}]
|
|
13488
|
-
}] });
|
|
13489
|
-
|
|
13490
11577
|
/*
|
|
13491
11578
|
* Public API Surface of tcloud-ui
|
|
13492
11579
|
*/
|
|
@@ -13495,5 +11582,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
13495
11582
|
* Generated bundle index. Do not edit.
|
|
13496
11583
|
*/
|
|
13497
11584
|
|
|
13498
|
-
export { AcceptedFileType, BytesPipe, CNPJPipe, CPFPipe, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$2 as CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR, DateBRPipe,
|
|
11585
|
+
export { AcceptedFileType, BytesPipe, CNPJPipe, CPFPipe, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$2 as CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR, DateBRPipe, DropdownMultiSize, DropdownSize, MonthNamePipe, MultiLevelDropdownSize, ProductActionPipe, ProgressStatusBarGradientStatus, RespectivePipe, StatusInfoPipe, TCCondition, TCFiltersType, TCLOUD_UI_AUTH_CONFIG, TCLOUD_UI_CONFIG, TCLOUD_UI_LAYOUT_SERVICE, TCLOUD_UI_LOCALE_SERVICE, TCLOUD_UI_USER_SERVICE, TCLOUD_UI_VIEWPORT_SERVICE, TCloudUiAccordionBodyComponent, TCloudUiAccordionComponent, TCloudUiAccordionTitleComponent, TCloudUiAlertBannerComponent, TCloudUiAlignDirective, TCloudUiAuthenticationService, TCloudUiBreadcrumbComponent, TCloudUiBreadcrumbService, TCloudUiButtonDirective, TCloudUiCalendarComponent, TCloudUiCardAccordionComponent, TCloudUiCardComponent, TCloudUiCardTitleComponent, TCloudUiCarouselComponent, TCloudUiCheckAccessDirective, TCloudUiCheckAccessService, TCloudUiCheckboxDirective, TCloudUiChoiceIssuesComponent, TCloudUiContainerColComponent, TCloudUiContainerComponent, TCloudUiContainerContentComponent, TCloudUiCubesComponent, TCloudUiCurrencyDirective, TCloudUiDataListComponent, TCloudUiDataListOptionComponent, TCloudUiDatepickerComponent, TCloudUiDatepickerTimeComponent, TCloudUiDialogComponent, TCloudUiDialogEventsEnum, TCloudUiDialogHostComponent, TCloudUiDialogModel, TCloudUiDialogService, TCloudUiDialogStatusEnum, TCloudUiDialogTextConfirmationEnum, TCloudUiDigitOnlyDirective, TCloudUiDropdownComponent, TCloudUiDropdownMultiComponent, TCloudUiDropdownMultiLevelComponent, TCloudUiEditorComponent, TCloudUiEditorDiffComponent, TCloudUiElCopyDirective, TCloudUiEmptyContentComponent, TCloudUiFaqComponent, TCloudUiFilterBarComponent, TCloudUiFiltersComponent, TCloudUiFooterComponent, TCloudUiFormDirective, TCloudUiHighLightDirective, TCloudUiHoverParentDirective, TCloudUiIconButtonDirective, TCloudUiInputContainerComponent, TCloudUiInputDirective, TCloudUiInputPasswordComponent, TCloudUiInputSearchComponent, TCloudUiIpMaskDirective, TCloudUiLabelTokenComponent, TCloudUiLegendComponent, TCloudUiLineStepCircleComponent, TCloudUiLineStepTitleComponent, TCloudUiLinhaLogoComponent, TCloudUiLoadingComponent, TCloudUiLoadingTransitionsService, TCloudUiMarkReadmeComponent, TCloudUiMessageComponent, TCloudUiModalBodyComponent, TCloudUiModalComponent, TCloudUiModalFooterComponent, TCloudUiModalHeaderComponent, TCloudUiModule, TCloudUiMultiInputComponent, TCloudUiMultiSelectComponent, TCloudUiMultiplesValuesComponent, TCloudUiNavbarComponent, TCloudUiNavbarFooterComponent, TCloudUiNavbarItemComponent, TCloudUiNgCheckAccessDirective, TCloudUiNgFeatureFlagsDirective, TCloudUiNotFoundComponent, TCloudUiNumberStepComponent, TCloudUiPaginationComponent, TCloudUiPaginationPipe, TCloudUiPopoverComponent, TCloudUiProgressBarComponent, TCloudUiProgressStatusBarComponent, TCloudUiRadioDirective, TCloudUiRangeDateComponent, TCloudUiReorderItemsComponent, TCloudUiScrollBoxComponent, TCloudUiSearchBarComponent, TCloudUiSearchInObjectService, TCloudUiSearchInputComponent, TCloudUiSkeletonLoadingComponent, TCloudUiSkeletonLoadingComponentStyle, TCloudUiSlideToggleDirective, TCloudUiStorageService, TCloudUiSubNavbarComponent, TCloudUiSubNavbarGroupComponent, TCloudUiSubNavbarItemComponent, TCloudUiTabContentComponent, TCloudUiTabGroupComponent, TCloudUiTabHeadComponent, TCloudUiTabItemComponent, TCloudUiTabMenuComponent, TCloudUiTabOptionComponent, TCloudUiTabSubtitleComponent, TCloudUiTabTitleComponent, TCloudUiTableComponent, TCloudUiTagComponent, TCloudUiToastComponent, TCloudUiTooltipDirective, TCloudUiTopNavigationComponent, TCloudUiUploadAreaComponent, TCloudUiUserService, TCloudUiWelcomeComponent, TCloudUiWizardStepsComponent, ToTextPipe, TopologyEnvironmentPipe, TopologyProductPipe, TopologyRegionPipe, TopologyStatusPipe, isTextEllipsed, provideTCloudUi, tcloudUiAuthGuard, tcloudUiJwtInterceptor, withAuthDefaults };
|
|
13499
11586
|
//# sourceMappingURL=dev-tcloud-tcloud-ui.mjs.map
|