@dev-tcloud/tcloud-ui 0.0.6 → 0.0.7

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.
@@ -933,10 +933,10 @@ class TCloudUiMultiSelectComponent {
933
933
  }
934
934
  }
935
935
  TCloudUiMultiSelectComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiSelectComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
936
- TCloudUiMultiSelectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiMultiSelectComponent, selector: "tcloud-ui-multi-select", inputs: { tcList: "tcList", placeholder: "placeholder", disabled: "disabled", loading: "loading" }, outputs: { tcChange: "tcChange" }, ngImport: i0, template: "<div>\r\n <table>\r\n <tr *ngIf=\"tcList\">\r\n <td>\r\n <select\r\n #_select\r\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n [title]=\"tcList.length === 0 ? 'Nenhum item dispon\u00EDvel' : placeholder\">\r\n <option></option>\r\n <ng-container *ngFor=\"let item of tcList; let i = index\">\r\n <option [title]=\"item.description\" *ngIf=\"!item.active\" [value]=\"item.value\">{{ item.description }}</option>\r\n </ng-container>\r\n </select>\r\n </td>\r\n <td>\r\n <button\r\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n title=\"Adicionar\"\r\n class=\"btn-plus-select\"\r\n (click)=\"addItem(_select.value)\"\r\n type=\"button\">\r\n <i class=\"fas fa-plus\"></i>\r\n </button>\r\n </td>\r\n </tr>\r\n </table>\r\n\r\n <div class=\"box-itens-selected\" *ngIf=\"count_actives > 0\">\r\n <ng-container *ngFor=\"let item of tcList\">\r\n <div class=\"itens-selected\" *ngIf=\"item.active\" [title]=\"item.description\">\r\n {{ item.description }}\r\n <button\r\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n title=\"Remover\"\r\n type=\"button\"\r\n (click)=\"removeItem(item.value)\">\r\n <i class=\"fas fa-times\"></i>\r\n </button>\r\n </div>\r\n </ng-container>\r\n </div>\r\n</div>\r\n", styles: ["table{width:100%;border-collapse:collapse;border:none}table td:first-child{width:100%}select{font-size:.8rem;height:40px;border:1px solid #999;border-radius:4px 0 0 4px;padding:6px 10px;white-space:nowrap;text-overflow:ellipsis;width:100%;background-color:#fff;color:#888}.btn-plus-select{width:30px;height:40px;border:none;color:#fff;background-color:var(--verde);border-radius:0 4px 4px 0}.box-itens-selected{display:flex;padding:9px;background-color:#ededed;border-radius:4px}.itens-selected{display:inline;width:100%;max-width:200px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;border:1px solid #ccc;height:35px;min-width:100px;background-color:var(--verde);color:#fff;padding:8px 15px 10px;border:none;border-radius:5px;margin:2px}.itens-selected button{position:relative;right:0;z-index:1;float:right;line-height:1;top:2px;left:10px;color:#d72020;background-color:var(--verde);border:none;font-weight:700;cursor:pointer}select:disabled{opacity:.8!important;cursor:not-allowed!important;background-color:#ededed}button:disabled{opacity:.5!important;cursor:not-allowed!important}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
936
+ TCloudUiMultiSelectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiMultiSelectComponent, selector: "tcloud-ui-multi-select", inputs: { tcList: "tcList", placeholder: "placeholder", disabled: "disabled", loading: "loading" }, outputs: { tcChange: "tcChange" }, ngImport: i0, template: "<div>\r\n <table>\r\n <tr *ngIf=\"tcList\">\r\n <td>\r\n <select\r\n #_select\r\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n [title]=\"tcList.length === 0 ? 'Nenhum item dispon\u00EDvel' : placeholder\">\r\n <option></option>\r\n <ng-container *ngFor=\"let item of tcList; let i = index\">\r\n <option [title]=\"item.description\" *ngIf=\"!item.active\" [value]=\"item.value\">{{ item.description }}</option>\r\n </ng-container>\r\n </select>\r\n </td>\r\n <td>\r\n <button\r\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n title=\"Adicionar\"\r\n class=\"btn-plus-select\"\r\n (click)=\"addItem(_select.value)\"\r\n type=\"button\">\r\n <i class=\"fas fa-plus\"></i>\r\n </button>\r\n </td>\r\n </tr>\r\n </table>\r\n\r\n <div class=\"box-itens-selected\" *ngIf=\"count_actives > 0\">\r\n <ng-container *ngFor=\"let item of tcList\">\r\n\r\n <ng-container *ngIf=\"item.active\">\r\n <div class=\"box-label\">\r\n <div class=\"box-value\" [title]=\"item.value\">\r\n {{ item.value }} \r\n </div>\r\n <div class=\"box-action\">\r\n <button\r\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n title=\"Remover\"\r\n type=\"button\"\r\n (click)=\"removeItem(item.value)\">\r\n <i class=\"fas fa-times\"></i>\r\n </button>\r\n </div>\r\n </div>\r\n </ng-container>\r\n\r\n </ng-container>\r\n </div>\r\n</div>\r\n", styles: ["table{width:100%;border-collapse:collapse;border:none}table td:first-child{width:100%}select{font-size:.8rem;height:40px;border:1px solid #999;border-radius:4px 0 0 4px;padding:6px 10px;white-space:nowrap;text-overflow:ellipsis;width:100%;background-color:#fff;color:#888}.btn-plus-select{width:30px;height:40px;border:none;color:#fff;background-color:var(--verde);border-radius:0 4px 4px 0}.box-itens-selected{display:flex;padding:9px;background-color:#ededed;border-radius:4px}select:disabled{opacity:.8!important;cursor:not-allowed!important;background-color:#ededed}button:disabled{opacity:.5!important;cursor:not-allowed!important}.box-label{display:flex;max-width:220px;height:35px;min-width:100px;background-color:var(--verde);color:#fff;padding:8px 15px 10px;border:none;border-radius:5px;margin:2px}.box-label .box-value{width:100%;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.box-label .box-action{width:8px}.box-label .box-action button{color:#d72020;background-color:var(--verde);border:none;font-weight:700;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
937
937
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiSelectComponent, decorators: [{
938
938
  type: Component,
939
- args: [{ selector: 'tcloud-ui-multi-select', template: "<div>\r\n <table>\r\n <tr *ngIf=\"tcList\">\r\n <td>\r\n <select\r\n #_select\r\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n [title]=\"tcList.length === 0 ? 'Nenhum item dispon\u00EDvel' : placeholder\">\r\n <option></option>\r\n <ng-container *ngFor=\"let item of tcList; let i = index\">\r\n <option [title]=\"item.description\" *ngIf=\"!item.active\" [value]=\"item.value\">{{ item.description }}</option>\r\n </ng-container>\r\n </select>\r\n </td>\r\n <td>\r\n <button\r\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n title=\"Adicionar\"\r\n class=\"btn-plus-select\"\r\n (click)=\"addItem(_select.value)\"\r\n type=\"button\">\r\n <i class=\"fas fa-plus\"></i>\r\n </button>\r\n </td>\r\n </tr>\r\n </table>\r\n\r\n <div class=\"box-itens-selected\" *ngIf=\"count_actives > 0\">\r\n <ng-container *ngFor=\"let item of tcList\">\r\n <div class=\"itens-selected\" *ngIf=\"item.active\" [title]=\"item.description\">\r\n {{ item.description }}\r\n <button\r\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n title=\"Remover\"\r\n type=\"button\"\r\n (click)=\"removeItem(item.value)\">\r\n <i class=\"fas fa-times\"></i>\r\n </button>\r\n </div>\r\n </ng-container>\r\n </div>\r\n</div>\r\n", styles: ["table{width:100%;border-collapse:collapse;border:none}table td:first-child{width:100%}select{font-size:.8rem;height:40px;border:1px solid #999;border-radius:4px 0 0 4px;padding:6px 10px;white-space:nowrap;text-overflow:ellipsis;width:100%;background-color:#fff;color:#888}.btn-plus-select{width:30px;height:40px;border:none;color:#fff;background-color:var(--verde);border-radius:0 4px 4px 0}.box-itens-selected{display:flex;padding:9px;background-color:#ededed;border-radius:4px}.itens-selected{display:inline;width:100%;max-width:200px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;border:1px solid #ccc;height:35px;min-width:100px;background-color:var(--verde);color:#fff;padding:8px 15px 10px;border:none;border-radius:5px;margin:2px}.itens-selected button{position:relative;right:0;z-index:1;float:right;line-height:1;top:2px;left:10px;color:#d72020;background-color:var(--verde);border:none;font-weight:700;cursor:pointer}select:disabled{opacity:.8!important;cursor:not-allowed!important;background-color:#ededed}button:disabled{opacity:.5!important;cursor:not-allowed!important}\n"] }]
939
+ args: [{ selector: 'tcloud-ui-multi-select', template: "<div>\r\n <table>\r\n <tr *ngIf=\"tcList\">\r\n <td>\r\n <select\r\n #_select\r\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n [title]=\"tcList.length === 0 ? 'Nenhum item dispon\u00EDvel' : placeholder\">\r\n <option></option>\r\n <ng-container *ngFor=\"let item of tcList; let i = index\">\r\n <option [title]=\"item.description\" *ngIf=\"!item.active\" [value]=\"item.value\">{{ item.description }}</option>\r\n </ng-container>\r\n </select>\r\n </td>\r\n <td>\r\n <button\r\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n title=\"Adicionar\"\r\n class=\"btn-plus-select\"\r\n (click)=\"addItem(_select.value)\"\r\n type=\"button\">\r\n <i class=\"fas fa-plus\"></i>\r\n </button>\r\n </td>\r\n </tr>\r\n </table>\r\n\r\n <div class=\"box-itens-selected\" *ngIf=\"count_actives > 0\">\r\n <ng-container *ngFor=\"let item of tcList\">\r\n\r\n <ng-container *ngIf=\"item.active\">\r\n <div class=\"box-label\">\r\n <div class=\"box-value\" [title]=\"item.value\">\r\n {{ item.value }} \r\n </div>\r\n <div class=\"box-action\">\r\n <button\r\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n title=\"Remover\"\r\n type=\"button\"\r\n (click)=\"removeItem(item.value)\">\r\n <i class=\"fas fa-times\"></i>\r\n </button>\r\n </div>\r\n </div>\r\n </ng-container>\r\n\r\n </ng-container>\r\n </div>\r\n</div>\r\n", styles: ["table{width:100%;border-collapse:collapse;border:none}table td:first-child{width:100%}select{font-size:.8rem;height:40px;border:1px solid #999;border-radius:4px 0 0 4px;padding:6px 10px;white-space:nowrap;text-overflow:ellipsis;width:100%;background-color:#fff;color:#888}.btn-plus-select{width:30px;height:40px;border:none;color:#fff;background-color:var(--verde);border-radius:0 4px 4px 0}.box-itens-selected{display:flex;padding:9px;background-color:#ededed;border-radius:4px}select:disabled{opacity:.8!important;cursor:not-allowed!important;background-color:#ededed}button:disabled{opacity:.5!important;cursor:not-allowed!important}.box-label{display:flex;max-width:220px;height:35px;min-width:100px;background-color:var(--verde);color:#fff;padding:8px 15px 10px;border:none;border-radius:5px;margin:2px}.box-label .box-value{width:100%;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.box-label .box-action{width:8px}.box-label .box-action button{color:#d72020;background-color:var(--verde);border:none;font-weight:700;cursor:pointer}\n"] }]
940
940
  }], ctorParameters: function () { return []; }, propDecorators: { tcList: [{
941
941
  type: Input
942
942
  }], placeholder: [{
@@ -1329,7 +1329,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
1329
1329
  }]
1330
1330
  }] });
1331
1331
 
1332
- class TooltipDirective {
1332
+ class TCloudUiTooltipDirective {
1333
1333
  constructor(el, renderer) {
1334
1334
  this.el = el;
1335
1335
  this.renderer = renderer;
@@ -1348,6 +1348,7 @@ class TooltipDirective {
1348
1348
  }
1349
1349
  onMouseOver() {
1350
1350
  if (this.getElement()) {
1351
+ this.renderer.addClass(this.el.nativeElement, 'main-tooltip');
1351
1352
  const el = this.getElement();
1352
1353
  el.style.display = 'inline';
1353
1354
  setTimeout(() => {
@@ -1387,6 +1388,7 @@ class TooltipDirective {
1387
1388
  if (this.getElement()) {
1388
1389
  const el = this.getElement();
1389
1390
  el.style.display = 'none';
1391
+ this.renderer.removeClass(this.el.nativeElement, 'main-tooltip');
1390
1392
  }
1391
1393
  }
1392
1394
  set tooltip(tooltip) {
@@ -1422,9 +1424,8 @@ class TooltipDirective {
1422
1424
  }
1423
1425
  }
1424
1426
  setStyle(el) {
1425
- this.renderer.setStyle(el, 'position', 'relative');
1426
- this.renderer.setStyle(el, 'border', '1px');
1427
- this.renderer.setStyle(el, 'display', 'inline');
1427
+ // this.renderer.setStyle(el, 'position', 'relative');
1428
+ // this.renderer.setStyle(el, 'display', 'inline');
1428
1429
  }
1429
1430
  create_tooltip(tip, el) {
1430
1431
  this.setStyle(el);
@@ -1433,7 +1434,7 @@ class TooltipDirective {
1433
1434
  tooltip.setAttribute('style', `
1434
1435
  position: absolute;
1435
1436
  display: none;
1436
- padding: .5rem;
1437
+ padding: 10px;
1437
1438
  border-radius: 10px;
1438
1439
  text-align: center;
1439
1440
  width: max-content;
@@ -1450,7 +1451,7 @@ class TooltipDirective {
1450
1451
  to_top(el) {
1451
1452
  const pos = this.el_center - (this.target_center);
1452
1453
  this.renderer.setStyle(el, 'left', `${(pos)}px`);
1453
- this.renderer.setStyle(el, 'bottom', `24px`);
1454
+ this.renderer.setStyle(el, 'bottom', `${(this.el_height + 7)}px`);
1454
1455
  el.setAttribute('class', 'tc-directive-tooltip tc-directive-tooltip-top');
1455
1456
  }
1456
1457
  to_bottom(el) {
@@ -1472,9 +1473,9 @@ class TooltipDirective {
1472
1473
  el.setAttribute('class', 'tc-directive-tooltip tc-directive-tooltip-left');
1473
1474
  }
1474
1475
  }
1475
- TooltipDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TooltipDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive });
1476
- TooltipDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.12", type: TooltipDirective, selector: "[tooltip]", inputs: { tooltip: "tooltip", direction: "direction" }, host: { listeners: { "mouseover": "onMouseOver()", "mouseout": "onMouseOut()" } }, ngImport: i0 });
1477
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TooltipDirective, decorators: [{
1476
+ TCloudUiTooltipDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiTooltipDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive });
1477
+ TCloudUiTooltipDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiTooltipDirective, selector: "[tooltip]", inputs: { tooltip: "tooltip", direction: "direction" }, host: { listeners: { "mouseover": "onMouseOver()", "mouseout": "onMouseOut()" } }, ngImport: i0 });
1478
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiTooltipDirective, decorators: [{
1478
1479
  type: Directive,
1479
1480
  args: [{
1480
1481
  selector: '[tooltip]'
@@ -1491,16 +1492,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
1491
1492
  type: Input
1492
1493
  }] } });
1493
1494
 
1494
- class TCloudAccessModule {
1495
+ class TCloudUiDirectiveModule {
1495
1496
  }
1496
- TCloudAccessModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudAccessModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1497
- TCloudAccessModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: TCloudAccessModule, declarations: [TooltipDirective], exports: [TooltipDirective] });
1498
- TCloudAccessModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudAccessModule });
1499
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudAccessModule, decorators: [{
1497
+ TCloudUiDirectiveModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiDirectiveModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1498
+ TCloudUiDirectiveModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiDirectiveModule, declarations: [TCloudUiTooltipDirective], exports: [TCloudUiTooltipDirective] });
1499
+ TCloudUiDirectiveModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiDirectiveModule });
1500
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiDirectiveModule, decorators: [{
1500
1501
  type: NgModule,
1501
1502
  args: [{
1502
- declarations: [TooltipDirective],
1503
- exports: [TooltipDirective],
1503
+ declarations: [TCloudUiTooltipDirective],
1504
+ exports: [TCloudUiTooltipDirective],
1504
1505
  }]
1505
1506
  }] });
1506
1507
 
@@ -1739,23 +1740,23 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
1739
1740
  args: [{ name: 'cpf' }]
1740
1741
  }] });
1741
1742
 
1742
- class TCloudPipesModule {
1743
+ class TCloudUiPipesModule {
1743
1744
  }
1744
- TCloudPipesModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudPipesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1745
- TCloudPipesModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: TCloudPipesModule, declarations: [MonthNamePipe,
1745
+ TCloudUiPipesModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiPipesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1746
+ TCloudUiPipesModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiPipesModule, declarations: [MonthNamePipe,
1746
1747
  StatusInfoPipe,
1747
1748
  RespectivePipe,
1748
1749
  CNPJPipe], imports: [CommonModule], exports: [MonthNamePipe,
1749
1750
  StatusInfoPipe,
1750
1751
  RespectivePipe,
1751
1752
  CNPJPipe] });
1752
- TCloudPipesModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudPipesModule, providers: [
1753
+ TCloudUiPipesModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiPipesModule, providers: [
1753
1754
  MonthNamePipe,
1754
1755
  StatusInfoPipe,
1755
1756
  RespectivePipe,
1756
1757
  CNPJPipe
1757
1758
  ], imports: [CommonModule] });
1758
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudPipesModule, decorators: [{
1759
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiPipesModule, decorators: [{
1759
1760
  type: NgModule,
1760
1761
  args: [{
1761
1762
  imports: [
@@ -1782,6 +1783,97 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
1782
1783
  }]
1783
1784
  }] });
1784
1785
 
1786
+ class TCloudUiMultiInputComponent {
1787
+ constructor() {
1788
+ this.placeholder = '';
1789
+ this.disabled = false;
1790
+ this.loading = false;
1791
+ this.count_actives = 0;
1792
+ this.tcChange = new EventEmitter();
1793
+ }
1794
+ ngOnInit() {
1795
+ setTimeout(() => {
1796
+ this.toChange();
1797
+ });
1798
+ }
1799
+ addItem(item) {
1800
+ if (this.disabled) {
1801
+ return;
1802
+ }
1803
+ if (!this.tcList) {
1804
+ this.tcList = [];
1805
+ }
1806
+ (this.tcList).push({ value: item });
1807
+ this.toChange();
1808
+ this.input_value = '';
1809
+ }
1810
+ removeItem(item, index) {
1811
+ if (this.disabled) {
1812
+ return;
1813
+ }
1814
+ if (this.tcList) {
1815
+ for (let i = 0; i < (this.tcList).length; i++) {
1816
+ const row = this.tcList[i];
1817
+ if (item === row.value && i === index) {
1818
+ (this.tcList).splice(index, 1);
1819
+ break;
1820
+ }
1821
+ }
1822
+ this.toChange();
1823
+ }
1824
+ }
1825
+ toChange() {
1826
+ let count_actives = 0;
1827
+ let itens = [];
1828
+ if (this.tcList) {
1829
+ for (let i = 0; i < (this.tcList).length; i++) {
1830
+ const row = this.tcList[i];
1831
+ (itens).push(row);
1832
+ }
1833
+ }
1834
+ this.count_actives = count_actives;
1835
+ this.tcChange.emit(itens);
1836
+ }
1837
+ }
1838
+ TCloudUiMultiInputComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
1839
+ TCloudUiMultiInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiMultiInputComponent, selector: "tcloud-ui-multi-input", inputs: { tcList: "tcList", placeholder: "placeholder", disabled: "disabled", loading: "loading" }, outputs: { tcChange: "tcChange" }, ngImport: i0, template: "<div>\n <form #_formulario=\"ngForm\">\n <table>\n <tr *ngIf=\"tcList\">\n <td>\n <input type=\"text\" [(ngModel)]=\"input_value\" [disabled]=\"disabled || loading\" name=\"input_value\" required>\n </td>\n <td>\n <button\n [disabled]=\"disabled || loading || !_formulario.valid\"\n title=\"Adicionar\"\n class=\"btn-plus-select\"\n (click)=\"addItem(input_value)\"\n type=\"button\">\n <i class=\"fas fa-plus\"></i>\n </button>\n </td>\n </tr>\n </table>\n \n <div class=\"box-itens-selected\">\n <ng-container *ngFor=\"let item of tcList; let i = index\">\n \n <div class=\"box-label\">\n <div class=\"box-value\" [title]=\"item.value\">\n {{ item.value }} \n </div>\n <div class=\"box-action\">\n <button\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\n title=\"Remover\"\n type=\"button\"\n (click)=\"removeItem(item.value, i)\">\n <i class=\"fas fa-times\"></i>\n </button>\n </div>\n </div>\n\n </ng-container>\n </div>\n </form>\n</div>\n ", styles: ["table{width:100%;border-collapse:collapse;border:none}table td:first-child{width:100%}input{font-size:.8rem;height:40px;border:1px solid #999;border-radius:4px 0 0 4px;padding:6px 10px;white-space:nowrap;text-overflow:ellipsis;width:100%;background-color:#fff;color:#888}.btn-plus-select{width:30px;height:40px;border:none;color:#fff;background-color:var(--verde);border-radius:0 4px 4px 0}.box-itens-selected{display:flex;padding:9px;background-color:#ededed;border-radius:4px}select:disabled{opacity:.8!important;cursor:not-allowed!important;background-color:#ededed}button:disabled{opacity:.5!important;cursor:not-allowed!important}.box-label{display:flex;max-width:220px;height:35px;min-width:100px;background-color:var(--verde);color:#fff;padding:8px 15px 10px;border:none;border-radius:5px;margin:2px}.box-label .box-value{width:100%;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.box-label .box-action{width:8px}.box-label .box-action button{color:#d72020;background-color:var(--verde);border:none;font-weight:700;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2.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: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
1840
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiInputComponent, decorators: [{
1841
+ type: Component,
1842
+ args: [{ selector: 'tcloud-ui-multi-input', template: "<div>\n <form #_formulario=\"ngForm\">\n <table>\n <tr *ngIf=\"tcList\">\n <td>\n <input type=\"text\" [(ngModel)]=\"input_value\" [disabled]=\"disabled || loading\" name=\"input_value\" required>\n </td>\n <td>\n <button\n [disabled]=\"disabled || loading || !_formulario.valid\"\n title=\"Adicionar\"\n class=\"btn-plus-select\"\n (click)=\"addItem(input_value)\"\n type=\"button\">\n <i class=\"fas fa-plus\"></i>\n </button>\n </td>\n </tr>\n </table>\n \n <div class=\"box-itens-selected\">\n <ng-container *ngFor=\"let item of tcList; let i = index\">\n \n <div class=\"box-label\">\n <div class=\"box-value\" [title]=\"item.value\">\n {{ item.value }} \n </div>\n <div class=\"box-action\">\n <button\n [disabled]=\"tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\n title=\"Remover\"\n type=\"button\"\n (click)=\"removeItem(item.value, i)\">\n <i class=\"fas fa-times\"></i>\n </button>\n </div>\n </div>\n\n </ng-container>\n </div>\n </form>\n</div>\n ", styles: ["table{width:100%;border-collapse:collapse;border:none}table td:first-child{width:100%}input{font-size:.8rem;height:40px;border:1px solid #999;border-radius:4px 0 0 4px;padding:6px 10px;white-space:nowrap;text-overflow:ellipsis;width:100%;background-color:#fff;color:#888}.btn-plus-select{width:30px;height:40px;border:none;color:#fff;background-color:var(--verde);border-radius:0 4px 4px 0}.box-itens-selected{display:flex;padding:9px;background-color:#ededed;border-radius:4px}select:disabled{opacity:.8!important;cursor:not-allowed!important;background-color:#ededed}button:disabled{opacity:.5!important;cursor:not-allowed!important}.box-label{display:flex;max-width:220px;height:35px;min-width:100px;background-color:var(--verde);color:#fff;padding:8px 15px 10px;border:none;border-radius:5px;margin:2px}.box-label .box-value{width:100%;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.box-label .box-action{width:8px}.box-label .box-action button{color:#d72020;background-color:var(--verde);border:none;font-weight:700;cursor:pointer}\n"] }]
1843
+ }], ctorParameters: function () { return []; }, propDecorators: { tcList: [{
1844
+ type: Input
1845
+ }], placeholder: [{
1846
+ type: Input
1847
+ }], disabled: [{
1848
+ type: Input
1849
+ }], loading: [{
1850
+ type: Input
1851
+ }], tcChange: [{
1852
+ type: Output
1853
+ }] } });
1854
+
1855
+ class TCloudUiMultiInputModule {
1856
+ }
1857
+ TCloudUiMultiInputModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiInputModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1858
+ TCloudUiMultiInputModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiInputModule, declarations: [TCloudUiMultiInputComponent], imports: [FormsModule,
1859
+ ReactiveFormsModule,
1860
+ CommonModule], exports: [TCloudUiMultiInputComponent] });
1861
+ TCloudUiMultiInputModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiInputModule, imports: [FormsModule,
1862
+ ReactiveFormsModule,
1863
+ CommonModule] });
1864
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiInputModule, decorators: [{
1865
+ type: NgModule,
1866
+ args: [{
1867
+ declarations: [TCloudUiMultiInputComponent],
1868
+ exports: [TCloudUiMultiInputComponent],
1869
+ imports: [
1870
+ FormsModule,
1871
+ ReactiveFormsModule,
1872
+ CommonModule
1873
+ ]
1874
+ }]
1875
+ }] });
1876
+
1785
1877
  class TCloudUiModule {
1786
1878
  }
1787
1879
  TCloudUiModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
@@ -1791,38 +1883,42 @@ TCloudUiModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version:
1791
1883
  TCloudUiLineStepCircleModule,
1792
1884
  TCloudUiMultiSelectModule,
1793
1885
  TCloudUiDataListModule,
1886
+ TCloudUiMultiInputModule,
1794
1887
  // Directives
1795
- TCloudAccessModule,
1888
+ TCloudUiDirectiveModule,
1796
1889
  // Pipes
1797
- TCloudPipesModule], exports: [TCloudUiModalModule,
1890
+ TCloudUiPipesModule], exports: [TCloudUiModalModule,
1798
1891
  TCloudUiTabMenuModule,
1799
1892
  TCloudUiLinhaLogoModule,
1800
1893
  TCloudUiLineStepCircleModule,
1801
1894
  TCloudUiMultiSelectModule,
1802
1895
  TCloudUiDataListModule,
1896
+ TCloudUiMultiInputModule,
1803
1897
  // Directives
1804
- TCloudAccessModule,
1898
+ TCloudUiDirectiveModule,
1805
1899
  // Pipes
1806
- TCloudPipesModule] });
1900
+ TCloudUiPipesModule] });
1807
1901
  TCloudUiModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiModule, imports: [TCloudUiModalModule,
1808
1902
  TCloudUiTabMenuModule,
1809
1903
  TCloudUiLinhaLogoModule,
1810
1904
  TCloudUiLineStepCircleModule,
1811
1905
  TCloudUiMultiSelectModule,
1812
1906
  TCloudUiDataListModule,
1907
+ TCloudUiMultiInputModule,
1813
1908
  // Directives
1814
- TCloudAccessModule,
1909
+ TCloudUiDirectiveModule,
1815
1910
  // Pipes
1816
- TCloudPipesModule, TCloudUiModalModule,
1911
+ TCloudUiPipesModule, TCloudUiModalModule,
1817
1912
  TCloudUiTabMenuModule,
1818
1913
  TCloudUiLinhaLogoModule,
1819
1914
  TCloudUiLineStepCircleModule,
1820
1915
  TCloudUiMultiSelectModule,
1821
1916
  TCloudUiDataListModule,
1917
+ TCloudUiMultiInputModule,
1822
1918
  // Directives
1823
- TCloudAccessModule,
1919
+ TCloudUiDirectiveModule,
1824
1920
  // Pipes
1825
- TCloudPipesModule] });
1921
+ TCloudUiPipesModule] });
1826
1922
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiModule, decorators: [{
1827
1923
  type: NgModule,
1828
1924
  args: [{
@@ -1833,10 +1929,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
1833
1929
  TCloudUiLineStepCircleModule,
1834
1930
  TCloudUiMultiSelectModule,
1835
1931
  TCloudUiDataListModule,
1932
+ TCloudUiMultiInputModule,
1836
1933
  // Directives
1837
- TCloudAccessModule,
1934
+ TCloudUiDirectiveModule,
1838
1935
  // Pipes
1839
- TCloudPipesModule
1936
+ TCloudUiPipesModule
1840
1937
  ],
1841
1938
  exports: [
1842
1939
  TCloudUiModalModule,
@@ -1845,10 +1942,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
1845
1942
  TCloudUiLineStepCircleModule,
1846
1943
  TCloudUiMultiSelectModule,
1847
1944
  TCloudUiDataListModule,
1945
+ TCloudUiMultiInputModule,
1848
1946
  // Directives
1849
- TCloudAccessModule,
1947
+ TCloudUiDirectiveModule,
1850
1948
  // Pipes
1851
- TCloudPipesModule
1949
+ TCloudUiPipesModule
1852
1950
  ]
1853
1951
  }]
1854
1952
  }] });
@@ -1861,5 +1959,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
1861
1959
  * Generated bundle index. Do not edit.
1862
1960
  */
1863
1961
 
1864
- export { CNPJPipe, CPFPipe, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR, MonthNamePipe, RespectivePipe, StatusInfoPipe, TCloudAccessModule, TCloudPipesModule, TCloudUiDataListComponent, TCloudUiDataListModule, TCloudUiDataListOptionComponent, TCloudUiLineStepCircleComponent, TCloudUiLineStepCircleModule, TCloudUiLinhaLogoComponent, TCloudUiLinhaLogoModule, TCloudUiModalBodyComponent, TCloudUiModalComponent, TCloudUiModalFooterComponent, TCloudUiModalHeaderComponent, TCloudUiModalModule, TCloudUiModule, TCloudUiMultiSelectComponent, TCloudUiMultiSelectModule, TCloudUiTabContentComponent, TCloudUiTabHeadComponent, TCloudUiTabMenuComponent, TCloudUiTabMenuModule, TCloudUiTabSubtitleComponent, TCloudUiTabTitleComponent, TooltipDirective };
1962
+ export { CNPJPipe, CPFPipe, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR, MonthNamePipe, RespectivePipe, StatusInfoPipe, TCloudUiDataListComponent, TCloudUiDataListModule, TCloudUiDataListOptionComponent, TCloudUiDirectiveModule, TCloudUiLineStepCircleComponent, TCloudUiLineStepCircleModule, TCloudUiLinhaLogoComponent, TCloudUiLinhaLogoModule, TCloudUiModalBodyComponent, TCloudUiModalComponent, TCloudUiModalFooterComponent, TCloudUiModalHeaderComponent, TCloudUiModalModule, TCloudUiModule, TCloudUiMultiInputComponent, TCloudUiMultiInputModule, TCloudUiMultiSelectComponent, TCloudUiMultiSelectModule, TCloudUiPipesModule, TCloudUiTabContentComponent, TCloudUiTabHeadComponent, TCloudUiTabMenuComponent, TCloudUiTabMenuModule, TCloudUiTabSubtitleComponent, TCloudUiTabTitleComponent, TCloudUiTooltipDirective };
1865
1963
  //# sourceMappingURL=dev-tcloud-tcloud-ui.mjs.map