@dev-tcloud/tcloud-ui 0.0.9 → 0.0.11
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/README.md +2 -1
- package/esm2020/lib/_modules/tcloud-ui-linha-logo/tcloud-ui-linha-logo.component.mjs +2 -4
- package/esm2020/lib/_modules/tcloud-ui-multi-input/tcloud-ui-multi-input.component.mjs +81 -4
- package/esm2020/lib/_modules/tcloud-ui-multi-select/tcloud-ui-multi-select.component.mjs +91 -8
- package/esm2020/lib/_modules/tcloud-ui-multi-select/tcloud-ui-multi-select.module.mjs +11 -4
- package/esm2020/lib/_modules/tcloud-ui-not-found/tcloud-ui-not-found.component.mjs +20 -0
- package/esm2020/lib/_modules/tcloud-ui-not-found/tcloud-ui-not-found.module.mjs +24 -0
- package/esm2020/lib/_modules/tcloud-ui-tab-menu/components/tcloud-ui-tab-head/tcloud-ui-tab-head.component.mjs +2 -2
- package/esm2020/lib/_modules/tcloud-ui-tab-menu/components/tcloud-ui-tab-title/tcloud-ui-tab-title.component.mjs +2 -2
- package/esm2020/lib/_modules/tcloud-ui-tab-menu/tcloud-ui-tab-menu.component.mjs +2 -2
- package/esm2020/lib/tcloud-ui.module.mjs +8 -1
- package/esm2020/public-api.mjs +4 -1
- package/fesm2015/dev-tcloud-tcloud-ui.mjs +238 -34
- package/fesm2015/dev-tcloud-tcloud-ui.mjs.map +1 -1
- package/fesm2020/dev-tcloud-tcloud-ui.mjs +238 -34
- package/fesm2020/dev-tcloud-tcloud-ui.mjs.map +1 -1
- package/lib/_modules/tcloud-ui-multi-input/tcloud-ui-multi-input.component.d.ts +22 -3
- package/lib/_modules/tcloud-ui-multi-select/tcloud-ui-multi-select.component.d.ts +23 -4
- package/lib/_modules/tcloud-ui-multi-select/tcloud-ui-multi-select.module.d.ts +2 -1
- package/lib/_modules/tcloud-ui-not-found/tcloud-ui-not-found.component.d.ts +8 -0
- package/lib/_modules/tcloud-ui-not-found/tcloud-ui-not-found.module.d.ts +8 -0
- package/lib/tcloud-ui.module.d.ts +4 -3
- package/package.json +1 -1
- package/public-api.d.ts +2 -0
|
@@ -2,16 +2,15 @@ import * as i0 from '@angular/core';
|
|
|
2
2
|
import { Component, Input, NgModule, Injectable, EventEmitter, Output, ViewChild, forwardRef, Pipe, Directive, HostListener } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/common';
|
|
4
4
|
import { CommonModule, DatePipe } from '@angular/common';
|
|
5
|
-
import { Buffer } from 'buffer';
|
|
6
5
|
import { Subject } from 'rxjs';
|
|
7
6
|
import * as i1$1 from '@angular/router';
|
|
8
7
|
import * as i2 from '@angular/forms';
|
|
9
|
-
import { FormsModule, ReactiveFormsModule, NG_VALUE_ACCESSOR, FormControl } from '@angular/forms';
|
|
8
|
+
import { FormsModule, ReactiveFormsModule, NG_VALIDATORS, NG_VALUE_ACCESSOR, FormControl } from '@angular/forms';
|
|
10
9
|
import { trigger, state, style, transition, animate } from '@angular/animations';
|
|
11
10
|
|
|
12
11
|
class TCloudUiLinhaLogoComponent {
|
|
13
12
|
constructor() {
|
|
14
|
-
this.server = '
|
|
13
|
+
this.server = 'https://ateleia-email.s3-sa-east-1.amazonaws.com/';
|
|
15
14
|
this.product = '';
|
|
16
15
|
this.logo_name = '';
|
|
17
16
|
this.product_name = '';
|
|
@@ -19,7 +18,6 @@ class TCloudUiLinhaLogoComponent {
|
|
|
19
18
|
this.font_size = '';
|
|
20
19
|
}
|
|
21
20
|
ngOnInit() {
|
|
22
|
-
this.server = Buffer.from(this.server, 'base64').toString('utf8');
|
|
23
21
|
this.logo_name = this.getLogoName();
|
|
24
22
|
this.product_name = this.getProductName();
|
|
25
23
|
this.alt_product_name = (this.product_name).toUpperCase();
|
|
@@ -201,10 +199,10 @@ class TCloudUiTabMenuComponent {
|
|
|
201
199
|
}
|
|
202
200
|
}
|
|
203
201
|
TCloudUiTabMenuComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiTabMenuComponent, deps: [{ token: TabMenuService }], target: i0.ɵɵFactoryTarget.Component });
|
|
204
|
-
TCloudUiTabMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiTabMenuComponent, selector: "tcloud-ui-tab-menu", inputs: { registerInUrl: "registerInUrl", loading: "loading", active: "active" }, outputs: { onChange: "onChange" }, providers: [TabMenuService], ngImport: i0, template: "<div class=\"tc-tab-menu\" [class.loading]=\"loading\" >\r\n <ng-content></ng-content>\r\n</div>", styles: [".tc-tab-menu{width:100%;overflow-x:hidden}.loading{opacity:.7;cursor:progress!important}\n"] });
|
|
202
|
+
TCloudUiTabMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiTabMenuComponent, selector: "tcloud-ui-tab-menu", inputs: { registerInUrl: "registerInUrl", loading: "loading", active: "active" }, outputs: { onChange: "onChange" }, providers: [TabMenuService], ngImport: i0, template: "<div class=\"tc-tab-menu\" [class.loading]=\"loading\" >\r\n <ng-content></ng-content>\r\n</div>", styles: [".tc-tab-menu{width:100%;overflow-x:hidden}.tc-tab-menu .fas{color:var(--primary);margin:0}.loading{opacity:.7;cursor:progress!important}\n"] });
|
|
205
203
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiTabMenuComponent, decorators: [{
|
|
206
204
|
type: Component,
|
|
207
|
-
args: [{ selector: 'tcloud-ui-tab-menu', providers: [TabMenuService], template: "<div class=\"tc-tab-menu\" [class.loading]=\"loading\" >\r\n <ng-content></ng-content>\r\n</div>", styles: [".tc-tab-menu{width:100%;overflow-x:hidden}.loading{opacity:.7;cursor:progress!important}\n"] }]
|
|
205
|
+
args: [{ selector: 'tcloud-ui-tab-menu', providers: [TabMenuService], template: "<div class=\"tc-tab-menu\" [class.loading]=\"loading\" >\r\n <ng-content></ng-content>\r\n</div>", styles: [".tc-tab-menu{width:100%;overflow-x:hidden}.tc-tab-menu .fas{color:var(--primary);margin:0}.loading{opacity:.7;cursor:progress!important}\n"] }]
|
|
208
206
|
}], ctorParameters: function () { return [{ type: TabMenuService }]; }, propDecorators: { registerInUrl: [{
|
|
209
207
|
type: Input
|
|
210
208
|
}], loading: [{
|
|
@@ -291,10 +289,10 @@ class TCloudUiTabTitleComponent {
|
|
|
291
289
|
}
|
|
292
290
|
}
|
|
293
291
|
TCloudUiTabTitleComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiTabTitleComponent, deps: [{ token: TabMenuService }], target: i0.ɵɵFactoryTarget.Component });
|
|
294
|
-
TCloudUiTabTitleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiTabTitleComponent, selector: "tcloud-ui-tab-title", inputs: { tab: "tab", title: "title", active: "active", disabled: "disabled" }, ngImport: i0, template: "<button [class.loading]=\"loading\" [attr.data-id]=\"tab\" [class.tab-title-active]=\"active\" [disabled]=\"disabled || loading\" type=\"button\" (click)=\"toTab()\" class=\"tab-title\" >\r\n <ng-content></ng-content>\r\n</button>\r\n", styles: [".tab-title{color:var(--cinza);border:none;background:none;text-transform:uppercase;font-size:11px;padding:20px;cursor:pointer;min-width:60px;max-width:200px;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;transition:all .25s}.tab-title:hover,.tab-title-active{background:var(--verde);color:#fff}@media (max-width: 1580px){.tab-title{font-size:11px;padding:20px 14px}}@media (max-width: 1440px){.tab-title{font-size:10px;padding:20px 13px}}
|
|
292
|
+
TCloudUiTabTitleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiTabTitleComponent, selector: "tcloud-ui-tab-title", inputs: { tab: "tab", title: "title", active: "active", disabled: "disabled" }, ngImport: i0, template: "<button [class.loading]=\"loading\" [attr.data-id]=\"tab\" [class.tab-title-active]=\"active\" [disabled]=\"disabled || loading\" type=\"button\" (click)=\"toTab()\" class=\"tab-title\" >\r\n <ng-content></ng-content>\r\n</button>\r\n", styles: [".tab-title{border-radius:0!important;height:initial;display:inline-block;margin:0!important;color:var(--cinza);border:none;background:none;text-transform:uppercase;font-size:11px;padding:20px;cursor:pointer;min-width:60px;max-width:200px;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;transition:all .25s}.tab-title:hover,.tab-title-active{background:var(--verde);color:#fff}.loading{cursor:progress!important}button:disabled{opacity:.7;cursor:not-allowed!important}.tab-title:hover,.tab-title-active{background:var(--primary);background:var(--verde)}@media (max-width: 1580px){.tab-title{font-size:11px;padding:20px 14px}}@media (max-width: 1440px){.tab-title{font-size:10px;padding:20px 13px}}\n"] });
|
|
295
293
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiTabTitleComponent, decorators: [{
|
|
296
294
|
type: Component,
|
|
297
|
-
args: [{ selector: 'tcloud-ui-tab-title', template: "<button [class.loading]=\"loading\" [attr.data-id]=\"tab\" [class.tab-title-active]=\"active\" [disabled]=\"disabled || loading\" type=\"button\" (click)=\"toTab()\" class=\"tab-title\" >\r\n <ng-content></ng-content>\r\n</button>\r\n", styles: [".tab-title{color:var(--cinza);border:none;background:none;text-transform:uppercase;font-size:11px;padding:20px;cursor:pointer;min-width:60px;max-width:200px;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;transition:all .25s}.tab-title:hover,.tab-title-active{background:var(--verde);color:#fff}@media (max-width: 1580px){.tab-title{font-size:11px;padding:20px 14px}}@media (max-width: 1440px){.tab-title{font-size:10px;padding:20px 13px}}
|
|
295
|
+
args: [{ selector: 'tcloud-ui-tab-title', template: "<button [class.loading]=\"loading\" [attr.data-id]=\"tab\" [class.tab-title-active]=\"active\" [disabled]=\"disabled || loading\" type=\"button\" (click)=\"toTab()\" class=\"tab-title\" >\r\n <ng-content></ng-content>\r\n</button>\r\n", styles: [".tab-title{border-radius:0!important;height:initial;display:inline-block;margin:0!important;color:var(--cinza);border:none;background:none;text-transform:uppercase;font-size:11px;padding:20px;cursor:pointer;min-width:60px;max-width:200px;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;transition:all .25s}.tab-title:hover,.tab-title-active{background:var(--verde);color:#fff}.loading{cursor:progress!important}button:disabled{opacity:.7;cursor:not-allowed!important}.tab-title:hover,.tab-title-active{background:var(--primary);background:var(--verde)}@media (max-width: 1580px){.tab-title{font-size:11px;padding:20px 14px}}@media (max-width: 1440px){.tab-title{font-size:10px;padding:20px 13px}}\n"] }]
|
|
298
296
|
}], ctorParameters: function () { return [{ type: TabMenuService }]; }, propDecorators: { tab: [{
|
|
299
297
|
type: Input
|
|
300
298
|
}], title: [{
|
|
@@ -409,10 +407,10 @@ class TCloudUiTabHeadComponent {
|
|
|
409
407
|
}
|
|
410
408
|
}
|
|
411
409
|
TCloudUiTabHeadComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiTabHeadComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
412
|
-
TCloudUiTabHeadComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiTabHeadComponent, selector: "tcloud-ui-tab-head", inputs: { background: "background" }, ngImport: i0, template: "\r\n\r\n<table class=\"area-navigation\">\r\n <tr>\r\n <td>\r\n <button (click)=\"to_scroll('prev')\"> <i class=\"fas fa-chevron-left\"></i> </button>\r\n </td>\r\n\r\n <td>\r\n \r\n </td>\r\n\r\n <td>\r\n <button (click)=\"to_scroll('next')\"> <i class=\"fas fa-chevron-right\"></i> </button>\r\n </td>\r\n </tr>\r\n</table>\r\n\r\n<div class=\"tc-menu {{ ID }}\" [attr.style]=\"'background: ' + background_color + ';'\" >\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n\r\n\r\n", styles: [".area-navigation{display:none;width:100%;line-height:0}.area-navigation td{width:100%;height:0;line-height:0}.area-navigation td:first-child{width:10px!important;text-align:left}.area-navigation td:first-child button{color:var(--verde);cursor:pointer;position:relative;top:15px;right:6px;border:none;background-color:transparent;font-size:15px;height:30px}.area-navigation td:last-child{width:10px!important;text-align:right}.area-navigation td:last-child button{color:var(--verde);cursor:pointer;position:relative;top:15px;left:6px;border:none;background-color:transparent;font-size:15px;height:30px}.tc-menu{display:flex;align-items:center;border-radius:10px;overflow:hidden;margin-bottom:5px;z-index:1;position:relative}@media (max-width: 1440px){.area-navigation{display:block!important;position:relative;top:0;height:2px}.tc-menu{margin-left:15px;margin-right:15px}}\n"] });
|
|
410
|
+
TCloudUiTabHeadComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiTabHeadComponent, selector: "tcloud-ui-tab-head", inputs: { background: "background" }, ngImport: i0, template: "\r\n\r\n<table class=\"area-navigation\">\r\n <tr>\r\n <td>\r\n <button (click)=\"to_scroll('prev')\"> <i class=\"fas fa-chevron-left\"></i> </button>\r\n </td>\r\n\r\n <td>\r\n \r\n </td>\r\n\r\n <td>\r\n <button (click)=\"to_scroll('next')\"> <i class=\"fas fa-chevron-right\"></i> </button>\r\n </td>\r\n </tr>\r\n</table>\r\n\r\n<div class=\"tc-menu {{ ID }}\" [attr.style]=\"'background: ' + background_color + ';'\" >\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n\r\n\r\n", styles: [".area-navigation{display:none;width:100%;line-height:0}.area-navigation button{padding:0!important}.area-navigation td{width:100%;height:0;line-height:0}.area-navigation td:first-child{width:10px!important;text-align:left}.area-navigation td:first-child button{color:var(--verde);cursor:pointer;position:relative;top:15px;right:6px;border:none;background-color:transparent;font-size:15px;height:30px}.area-navigation td:last-child{width:10px!important;text-align:right}.area-navigation td:last-child button{color:var(--verde);cursor:pointer;position:relative;top:15px;left:6px;border:none;background-color:transparent;font-size:15px;height:30px}.tc-menu{display:flex;align-items:center;border-radius:10px;overflow:hidden;margin-bottom:5px;z-index:1;position:relative}@media (max-width: 1440px){.area-navigation{display:block!important;position:relative;top:0;height:2px}.tc-menu{margin-left:15px;margin-right:15px}}\n"] });
|
|
413
411
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiTabHeadComponent, decorators: [{
|
|
414
412
|
type: Component,
|
|
415
|
-
args: [{ selector: 'tcloud-ui-tab-head', template: "\r\n\r\n<table class=\"area-navigation\">\r\n <tr>\r\n <td>\r\n <button (click)=\"to_scroll('prev')\"> <i class=\"fas fa-chevron-left\"></i> </button>\r\n </td>\r\n\r\n <td>\r\n \r\n </td>\r\n\r\n <td>\r\n <button (click)=\"to_scroll('next')\"> <i class=\"fas fa-chevron-right\"></i> </button>\r\n </td>\r\n </tr>\r\n</table>\r\n\r\n<div class=\"tc-menu {{ ID }}\" [attr.style]=\"'background: ' + background_color + ';'\" >\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n\r\n\r\n", styles: [".area-navigation{display:none;width:100%;line-height:0}.area-navigation td{width:100%;height:0;line-height:0}.area-navigation td:first-child{width:10px!important;text-align:left}.area-navigation td:first-child button{color:var(--verde);cursor:pointer;position:relative;top:15px;right:6px;border:none;background-color:transparent;font-size:15px;height:30px}.area-navigation td:last-child{width:10px!important;text-align:right}.area-navigation td:last-child button{color:var(--verde);cursor:pointer;position:relative;top:15px;left:6px;border:none;background-color:transparent;font-size:15px;height:30px}.tc-menu{display:flex;align-items:center;border-radius:10px;overflow:hidden;margin-bottom:5px;z-index:1;position:relative}@media (max-width: 1440px){.area-navigation{display:block!important;position:relative;top:0;height:2px}.tc-menu{margin-left:15px;margin-right:15px}}\n"] }]
|
|
413
|
+
args: [{ selector: 'tcloud-ui-tab-head', template: "\r\n\r\n<table class=\"area-navigation\">\r\n <tr>\r\n <td>\r\n <button (click)=\"to_scroll('prev')\"> <i class=\"fas fa-chevron-left\"></i> </button>\r\n </td>\r\n\r\n <td>\r\n \r\n </td>\r\n\r\n <td>\r\n <button (click)=\"to_scroll('next')\"> <i class=\"fas fa-chevron-right\"></i> </button>\r\n </td>\r\n </tr>\r\n</table>\r\n\r\n<div class=\"tc-menu {{ ID }}\" [attr.style]=\"'background: ' + background_color + ';'\" >\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n\r\n\r\n", styles: [".area-navigation{display:none;width:100%;line-height:0}.area-navigation button{padding:0!important}.area-navigation td{width:100%;height:0;line-height:0}.area-navigation td:first-child{width:10px!important;text-align:left}.area-navigation td:first-child button{color:var(--verde);cursor:pointer;position:relative;top:15px;right:6px;border:none;background-color:transparent;font-size:15px;height:30px}.area-navigation td:last-child{width:10px!important;text-align:right}.area-navigation td:last-child button{color:var(--verde);cursor:pointer;position:relative;top:15px;left:6px;border:none;background-color:transparent;font-size:15px;height:30px}.tc-menu{display:flex;align-items:center;border-radius:10px;overflow:hidden;margin-bottom:5px;z-index:1;position:relative}@media (max-width: 1440px){.area-navigation{display:block!important;position:relative;top:0;height:2px}.tc-menu{margin-left:15px;margin-right:15px}}\n"] }]
|
|
416
414
|
}], ctorParameters: function () { return []; }, propDecorators: { background: [{
|
|
417
415
|
type: Input
|
|
418
416
|
}] } });
|
|
@@ -900,18 +898,34 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
|
|
|
900
898
|
}]
|
|
901
899
|
}] });
|
|
902
900
|
|
|
901
|
+
const CUSTOM_INPUT_VALIDATORS$1 = {
|
|
902
|
+
provide: NG_VALIDATORS,
|
|
903
|
+
useExisting: forwardRef(() => TCloudUiMultiSelectComponent),
|
|
904
|
+
multi: true
|
|
905
|
+
};
|
|
906
|
+
const CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$3 = {
|
|
907
|
+
provide: NG_VALUE_ACCESSOR,
|
|
908
|
+
useExisting: forwardRef(() => TCloudUiMultiSelectComponent),
|
|
909
|
+
multi: true
|
|
910
|
+
};
|
|
911
|
+
const noop$3 = () => {
|
|
912
|
+
};
|
|
903
913
|
class TCloudUiMultiSelectComponent {
|
|
904
914
|
constructor() {
|
|
905
915
|
this.placeholder = 'Selecione um item';
|
|
906
916
|
this.disabled = false;
|
|
907
917
|
this.loading = false;
|
|
908
|
-
this.count_actives = 0;
|
|
909
918
|
this.tcChange = new EventEmitter();
|
|
919
|
+
this.use_validation_required = false;
|
|
920
|
+
this.count_actives = 0;
|
|
921
|
+
this.onChange = new EventEmitter();
|
|
922
|
+
//Placeholders for the callbacks which are later providesd
|
|
923
|
+
//by the Control Value Accessor
|
|
924
|
+
this.onTouchedCallback = noop$3;
|
|
925
|
+
this.onChangeCallback = noop$3;
|
|
910
926
|
}
|
|
911
927
|
ngOnInit() {
|
|
912
|
-
setTimeout(() => {
|
|
913
|
-
this.toChange();
|
|
914
|
-
});
|
|
928
|
+
setTimeout(() => { this.toChange(); });
|
|
915
929
|
}
|
|
916
930
|
addItem(item) {
|
|
917
931
|
if (this.disabled) {
|
|
@@ -955,15 +969,76 @@ class TCloudUiMultiSelectComponent {
|
|
|
955
969
|
}
|
|
956
970
|
}
|
|
957
971
|
}
|
|
972
|
+
this.item_value = null;
|
|
958
973
|
this.count_actives = count_actives;
|
|
959
974
|
this.tcChange.emit(itens);
|
|
975
|
+
this.onChangeCallback(this.tcList);
|
|
976
|
+
}
|
|
977
|
+
check_is_valid() {
|
|
978
|
+
let active = 0;
|
|
979
|
+
if (this.tcList) {
|
|
980
|
+
for (let i = 0; i < (this.tcList).length; i++) {
|
|
981
|
+
const item = this.tcList[i];
|
|
982
|
+
if (item && item.active && item.active === true) {
|
|
983
|
+
active++;
|
|
984
|
+
break;
|
|
985
|
+
}
|
|
986
|
+
}
|
|
987
|
+
}
|
|
988
|
+
return (active > 0) ? true : false;
|
|
989
|
+
}
|
|
990
|
+
onChangeTouched() {
|
|
991
|
+
this.onTouchedCallback();
|
|
992
|
+
}
|
|
993
|
+
//get accessor
|
|
994
|
+
get value() {
|
|
995
|
+
return this.innerValue;
|
|
996
|
+
}
|
|
997
|
+
;
|
|
998
|
+
//set accessor including call the onchange callback
|
|
999
|
+
set value(v) {
|
|
1000
|
+
if (v !== this.innerValue) {
|
|
1001
|
+
this.innerValue = v;
|
|
1002
|
+
this.onChangeCallback(v);
|
|
1003
|
+
}
|
|
1004
|
+
}
|
|
1005
|
+
//Set touched on blur
|
|
1006
|
+
onBlur() {
|
|
1007
|
+
this.onTouchedCallback();
|
|
1008
|
+
}
|
|
1009
|
+
//From ControlValueAccessor interface
|
|
1010
|
+
writeValue(value) {
|
|
1011
|
+
if (value !== this.innerValue) {
|
|
1012
|
+
this.innerValue = value;
|
|
1013
|
+
this.toSetDefault(value);
|
|
1014
|
+
}
|
|
1015
|
+
}
|
|
1016
|
+
//From ControlValueAccessor interface
|
|
1017
|
+
registerOnChange(fn) {
|
|
1018
|
+
this.onChangeCallback = fn;
|
|
1019
|
+
}
|
|
1020
|
+
//From ControlValueAccessor interface
|
|
1021
|
+
registerOnTouched(fn) {
|
|
1022
|
+
this.onTouchedCallback = fn;
|
|
1023
|
+
}
|
|
1024
|
+
toSetDefault(value) {
|
|
1025
|
+
this.tcList = value;
|
|
1026
|
+
}
|
|
1027
|
+
validate(c) {
|
|
1028
|
+
if (c && (typeof this.required !== 'undefined')) {
|
|
1029
|
+
this.use_validation_required = true;
|
|
1030
|
+
return (this.check_is_valid()) ? null : 'required';
|
|
1031
|
+
}
|
|
1032
|
+
return null;
|
|
1033
|
+
}
|
|
1034
|
+
ngOnDestroy() {
|
|
960
1035
|
}
|
|
961
1036
|
}
|
|
962
1037
|
TCloudUiMultiSelectComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiSelectComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
963
|
-
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
|
|
1038
|
+
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", required: "required" }, outputs: { tcChange: "tcChange", onChange: "onChange" }, providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$3, CUSTOM_INPUT_VALIDATORS$1], ngImport: i0, template: "\r\n <div>\r\n <table>\r\n <tr *ngIf=\"tcList\">\r\n <td>\r\n <select \r\n [(ngModel)]=\"item_value\"\r\n [class.tc-parent-validation]=\"use_validation_required\" \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]=\"!item_value || tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n title=\"Adicionar\"\r\n class=\"btn-plus-select\"\r\n (click)=\"addItem(_select.value);onChangeTouched()\"\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 && (tcList && tcList.length > 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);onChangeTouched()\">\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"] }, { kind: "directive", type: i2.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] });
|
|
964
1039
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiSelectComponent, decorators: [{
|
|
965
1040
|
type: Component,
|
|
966
|
-
args: [{ selector: 'tcloud-ui-multi-select', template: "<div>\r\n
|
|
1041
|
+
args: [{ selector: 'tcloud-ui-multi-select', providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$3, CUSTOM_INPUT_VALIDATORS$1], template: "\r\n <div>\r\n <table>\r\n <tr *ngIf=\"tcList\">\r\n <td>\r\n <select \r\n [(ngModel)]=\"item_value\"\r\n [class.tc-parent-validation]=\"use_validation_required\" \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]=\"!item_value || tcList === undefined || (tcList && tcList.length === 0) || disabled || loading\"\r\n title=\"Adicionar\"\r\n class=\"btn-plus-select\"\r\n (click)=\"addItem(_select.value);onChangeTouched()\"\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 && (tcList && tcList.length > 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);onChangeTouched()\">\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"] }]
|
|
967
1042
|
}], ctorParameters: function () { return []; }, propDecorators: { tcList: [{
|
|
968
1043
|
type: Input
|
|
969
1044
|
}], placeholder: [{
|
|
@@ -972,22 +1047,32 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
|
|
|
972
1047
|
type: Input
|
|
973
1048
|
}], loading: [{
|
|
974
1049
|
type: Input
|
|
1050
|
+
}], required: [{
|
|
1051
|
+
type: Input
|
|
975
1052
|
}], tcChange: [{
|
|
976
1053
|
type: Output
|
|
1054
|
+
}], onChange: [{
|
|
1055
|
+
type: Output
|
|
977
1056
|
}] } });
|
|
978
1057
|
|
|
979
1058
|
class TCloudUiMultiSelectModule {
|
|
980
1059
|
}
|
|
981
1060
|
TCloudUiMultiSelectModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiSelectModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
982
|
-
TCloudUiMultiSelectModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiSelectModule, declarations: [TCloudUiMultiSelectComponent], imports: [CommonModule
|
|
983
|
-
|
|
1061
|
+
TCloudUiMultiSelectModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiSelectModule, declarations: [TCloudUiMultiSelectComponent], imports: [CommonModule,
|
|
1062
|
+
FormsModule,
|
|
1063
|
+
ReactiveFormsModule], exports: [TCloudUiMultiSelectComponent] });
|
|
1064
|
+
TCloudUiMultiSelectModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiSelectModule, imports: [CommonModule,
|
|
1065
|
+
FormsModule,
|
|
1066
|
+
ReactiveFormsModule] });
|
|
984
1067
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiSelectModule, decorators: [{
|
|
985
1068
|
type: NgModule,
|
|
986
1069
|
args: [{
|
|
987
1070
|
declarations: [TCloudUiMultiSelectComponent],
|
|
988
1071
|
exports: [TCloudUiMultiSelectComponent],
|
|
989
1072
|
imports: [
|
|
990
|
-
CommonModule
|
|
1073
|
+
CommonModule,
|
|
1074
|
+
FormsModule,
|
|
1075
|
+
ReactiveFormsModule
|
|
991
1076
|
]
|
|
992
1077
|
}]
|
|
993
1078
|
}] });
|
|
@@ -1028,12 +1113,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
|
|
|
1028
1113
|
type: Injectable
|
|
1029
1114
|
}] });
|
|
1030
1115
|
|
|
1031
|
-
const CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$
|
|
1116
|
+
const CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$2 = {
|
|
1032
1117
|
provide: NG_VALUE_ACCESSOR,
|
|
1033
1118
|
useExisting: forwardRef(() => TCloudUiDataListComponent),
|
|
1034
1119
|
multi: true
|
|
1035
1120
|
};
|
|
1036
|
-
const noop$
|
|
1121
|
+
const noop$2 = () => {
|
|
1037
1122
|
};
|
|
1038
1123
|
class TCloudUiDataListComponent {
|
|
1039
1124
|
constructor(dataListService, formBuilder) {
|
|
@@ -1056,8 +1141,8 @@ class TCloudUiDataListComponent {
|
|
|
1056
1141
|
this.id = '';
|
|
1057
1142
|
//Placeholders for the callbacks which are later providesd
|
|
1058
1143
|
//by the Control Value Accessor
|
|
1059
|
-
this.onTouchedCallback = noop$
|
|
1060
|
-
this.onChangeCallback = noop$
|
|
1144
|
+
this.onTouchedCallback = noop$2;
|
|
1145
|
+
this.onChangeCallback = noop$2;
|
|
1061
1146
|
}
|
|
1062
1147
|
set disabled(v) {
|
|
1063
1148
|
this._disabled = v;
|
|
@@ -1247,13 +1332,13 @@ class TCloudUiDataListComponent {
|
|
|
1247
1332
|
TCloudUiDataListComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiDataListComponent, deps: [{ token: DataListService }, { token: i2.FormBuilder }], target: i0.ɵɵFactoryTarget.Component });
|
|
1248
1333
|
TCloudUiDataListComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiDataListComponent, selector: "tcloud-ui-data-list", inputs: { placeholder: "placeholder", disabled: "disabled", loading: "loading", search: "search", ngModel: "ngModel" }, outputs: { onInputChange: "onInputChange", onChange: "onChange" }, providers: [
|
|
1249
1334
|
DataListService,
|
|
1250
|
-
CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$
|
|
1335
|
+
CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$2
|
|
1251
1336
|
], ngImport: i0, template: "<div *ngIf=\"formulario\" id=\"area-{{ id }}\" class=\"tc-dropdown\" [class.disabled]=\"disabled || loading\">\r\n <div *ngIf=\"loading\" class=\"loading-area\">\r\n <i class=\"fas fa-spinner fa-spin\"></i>\r\n </div>\r\n <!-- [attr.data-bs-toggle]=\"'dropdown'\" -->\r\n <button \r\n [class.loading-box]=\"loading\"\r\n [disabled]=\"disabled || loading\"\r\n class=\"dropdown-toggle button-select\" \r\n type=\"button\" \r\n id=\"{{ id }}\" \r\n \r\n [attr.aria-haspopup]=\"'true'\" \r\n [attr.aria-expanded]=\"'false'\" \r\n (click)=\"toOpen()\" >\r\n\r\n <i *ngIf=\"(selected_description === undefined || selected_description === null || selected_description === '' ) && !loading \">{{ placeholder }}</i>\r\n {{ selected_description }}\r\n <span><i class=\"fas fa-angle-down\"></i></span>\r\n </button>\r\n <div class=\"tc-dropdown-menu {{ menu_on_top }}\" id=\"box-{{ id }}\" [attr.aria-labelledby]=\"id\" [class.to-hide]=\"!menu_show\" [style]=\"box_style\">\r\n\r\n <div class=\"line-search\" *ngIf=\"search\">\r\n <table class=\"box-search\">\r\n <tr>\r\n\r\n <td class=\"area-input\">\r\n <input type=\"text\" [(ngModel)]=\"search_text\" (input)=\"toSearch($event)\" placeholder=\"Buscar...\" > \r\n </td>\r\n\r\n <td class=\"area-icon\">\r\n <i *ngIf=\"search_text === ''\" class=\"fas fa-search icon-search\"></i>\r\n <button type=\"button\" *ngIf=\"search_text !== ''\" (click)=\"clearTextSearch()\"><i class=\"fas fa-times\"></i></button>\r\n </td>\r\n \r\n </tr>\r\n </table>\r\n </div>\r\n \r\n <div class=\"area-options\" id=\"{{ id }}-options\" (click)=\"toClose()\">\r\n <ng-content></ng-content> \r\n </div>\r\n </div>\r\n</div>\r\n\r\n<div *ngIf=\"formulario\">\r\n <form [formGroup]=\"formulario\" style=\"display: none;\" >\r\n <input id=\"{{ id }}-hidden\" formControlName=\"selected_item\" type=\"hidden\">\r\n </form>\r\n</div>", styles: [".dropdown-toggle:after{display:none!important}.tc-dropdown{position:relative}.tc-dropdown .button-select{width:100%;background-color:#fff;border:1px solid #ccc;height:35px;text-align:left;padding-left:15px;font-size:14px;color:#666}.tc-dropdown .button-select span{position:absolute;right:6px;top:7px}.tc-dropdown .tc-dropdown-menu{width:100%;border:1px solid #ccc;background-color:#fff}.tc-dropdown .area-options{max-height:200px;overflow-y:scroll;overflow-x:hidden}.tc-dropdown .menu-on-top{position:absolute}.line-search{padding:3px}.line-search .box-search{width:100%;border-collapse:collapse}.line-search .box-search td.area-icon{padding:4px 0 2px 8px;width:35px}.line-search .box-search td.area-icon .icon-search{color:#666}.line-search .box-search td.area-icon button{border:none;background-color:transparent;color:#999;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.line-search .box-search td.area-input{border:none}.line-search .box-search td.area-input input{width:100%}.line-search .box-search input{width:100%;font-size:13px;height:33px;border:1px solid #ccc;padding:10px}.loading-area{line-height:0;position:relative;height:0;bottom:-10px;left:10px}button:disabled{background-color:#eee!important;border:1px solid #ececec!important;cursor:not-allowed}.loading-box{cursor:progress!important}.disabled i{color:#999!important}.to-hide{display:none}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { 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.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }] });
|
|
1252
1337
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiDataListComponent, decorators: [{
|
|
1253
1338
|
type: Component,
|
|
1254
1339
|
args: [{ selector: 'tcloud-ui-data-list', providers: [
|
|
1255
1340
|
DataListService,
|
|
1256
|
-
CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$
|
|
1341
|
+
CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$2
|
|
1257
1342
|
], template: "<div *ngIf=\"formulario\" id=\"area-{{ id }}\" class=\"tc-dropdown\" [class.disabled]=\"disabled || loading\">\r\n <div *ngIf=\"loading\" class=\"loading-area\">\r\n <i class=\"fas fa-spinner fa-spin\"></i>\r\n </div>\r\n <!-- [attr.data-bs-toggle]=\"'dropdown'\" -->\r\n <button \r\n [class.loading-box]=\"loading\"\r\n [disabled]=\"disabled || loading\"\r\n class=\"dropdown-toggle button-select\" \r\n type=\"button\" \r\n id=\"{{ id }}\" \r\n \r\n [attr.aria-haspopup]=\"'true'\" \r\n [attr.aria-expanded]=\"'false'\" \r\n (click)=\"toOpen()\" >\r\n\r\n <i *ngIf=\"(selected_description === undefined || selected_description === null || selected_description === '' ) && !loading \">{{ placeholder }}</i>\r\n {{ selected_description }}\r\n <span><i class=\"fas fa-angle-down\"></i></span>\r\n </button>\r\n <div class=\"tc-dropdown-menu {{ menu_on_top }}\" id=\"box-{{ id }}\" [attr.aria-labelledby]=\"id\" [class.to-hide]=\"!menu_show\" [style]=\"box_style\">\r\n\r\n <div class=\"line-search\" *ngIf=\"search\">\r\n <table class=\"box-search\">\r\n <tr>\r\n\r\n <td class=\"area-input\">\r\n <input type=\"text\" [(ngModel)]=\"search_text\" (input)=\"toSearch($event)\" placeholder=\"Buscar...\" > \r\n </td>\r\n\r\n <td class=\"area-icon\">\r\n <i *ngIf=\"search_text === ''\" class=\"fas fa-search icon-search\"></i>\r\n <button type=\"button\" *ngIf=\"search_text !== ''\" (click)=\"clearTextSearch()\"><i class=\"fas fa-times\"></i></button>\r\n </td>\r\n \r\n </tr>\r\n </table>\r\n </div>\r\n \r\n <div class=\"area-options\" id=\"{{ id }}-options\" (click)=\"toClose()\">\r\n <ng-content></ng-content> \r\n </div>\r\n </div>\r\n</div>\r\n\r\n<div *ngIf=\"formulario\">\r\n <form [formGroup]=\"formulario\" style=\"display: none;\" >\r\n <input id=\"{{ id }}-hidden\" formControlName=\"selected_item\" type=\"hidden\">\r\n </form>\r\n</div>", styles: [".dropdown-toggle:after{display:none!important}.tc-dropdown{position:relative}.tc-dropdown .button-select{width:100%;background-color:#fff;border:1px solid #ccc;height:35px;text-align:left;padding-left:15px;font-size:14px;color:#666}.tc-dropdown .button-select span{position:absolute;right:6px;top:7px}.tc-dropdown .tc-dropdown-menu{width:100%;border:1px solid #ccc;background-color:#fff}.tc-dropdown .area-options{max-height:200px;overflow-y:scroll;overflow-x:hidden}.tc-dropdown .menu-on-top{position:absolute}.line-search{padding:3px}.line-search .box-search{width:100%;border-collapse:collapse}.line-search .box-search td.area-icon{padding:4px 0 2px 8px;width:35px}.line-search .box-search td.area-icon .icon-search{color:#666}.line-search .box-search td.area-icon button{border:none;background-color:transparent;color:#999;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.line-search .box-search td.area-input{border:none}.line-search .box-search td.area-input input{width:100%}.line-search .box-search input{width:100%;font-size:13px;height:33px;border:1px solid #ccc;padding:10px}.loading-area{line-height:0;position:relative;height:0;bottom:-10px;left:10px}button:disabled{background-color:#eee!important;border:1px solid #ececec!important;cursor:not-allowed}.loading-box{cursor:progress!important}.disabled i{color:#999!important}.to-hide{display:none}\n"] }]
|
|
1258
1343
|
}], ctorParameters: function () { return [{ type: DataListService }, { type: i2.FormBuilder }]; }, propDecorators: { placeholder: [{
|
|
1259
1344
|
type: Input
|
|
@@ -1356,12 +1441,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
|
|
|
1356
1441
|
}]
|
|
1357
1442
|
}] });
|
|
1358
1443
|
|
|
1359
|
-
const CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR = {
|
|
1444
|
+
const CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$1 = {
|
|
1360
1445
|
provide: NG_VALUE_ACCESSOR,
|
|
1361
1446
|
useExisting: forwardRef(() => TCloudUiChoiceIssuesComponent),
|
|
1362
1447
|
multi: true
|
|
1363
1448
|
};
|
|
1364
|
-
const noop = () => {
|
|
1449
|
+
const noop$1 = () => {
|
|
1365
1450
|
};
|
|
1366
1451
|
class TCloudUiChoiceIssuesComponent {
|
|
1367
1452
|
constructor() {
|
|
@@ -1373,8 +1458,8 @@ class TCloudUiChoiceIssuesComponent {
|
|
|
1373
1458
|
this.innerValue = false;
|
|
1374
1459
|
//Placeholders for the callbacks which are later providesd
|
|
1375
1460
|
//by the Control Value Accessor
|
|
1376
|
-
this.onTouchedCallback = noop;
|
|
1377
|
-
this.onChangeCallback = noop;
|
|
1461
|
+
this.onTouchedCallback = noop$1;
|
|
1462
|
+
this.onChangeCallback = noop$1;
|
|
1378
1463
|
this.ID = 'tc-issue-' + Math.random().toString(36).substr(2, 9);
|
|
1379
1464
|
}
|
|
1380
1465
|
//get accessor
|
|
@@ -1420,10 +1505,10 @@ class TCloudUiChoiceIssuesComponent {
|
|
|
1420
1505
|
}
|
|
1421
1506
|
}
|
|
1422
1507
|
TCloudUiChoiceIssuesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiChoiceIssuesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1423
|
-
TCloudUiChoiceIssuesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiChoiceIssuesComponent, selector: "tcloud-ui-choice-issues", inputs: { view: "view", titulo: "titulo", subTitulo: "subTitulo", disabled: "disabled" }, outputs: { onChange: "onChange" }, providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR], viewQueries: [{ propertyName: "inputRef", first: true, predicate: ["campo"], descendants: true, read: true }], ngImport: i0, template: "\r\n\r\n<input #campo [(ngModel)]=\"value\" type=\"hidden\" [value]=\"false\" >\r\n<div class=\"box p-2 mt-3 mb-2\">\r\n <div class=\"row\">\r\n <div class=\"col-md-8\">\r\n <p class=\"titulo\">{{ titulo }}</p> \r\n </div>\r\n <div class=\"col-md-4 text-right\"> \r\n\r\n <table class=\"mt-2 mr-2\" *ngIf=\"!view\" >\r\n <tr>\r\n <td>\r\n <div class=\"form-fieldset\">\r\n <label [class.v-true]=\"value\" class=\"mr-1\"><input #campo name=\"{{ ID }}\" [value]=\"true\" type=\"radio\" [(ngModel)]=\"value\" (click)=\"setV(true)\" >Sim</label>\r\n </div>\r\n </td>\r\n <td>\r\n <div class=\"form-fieldset\">\r\n <label [class.v-true]=\"!value\" class=\"ml-2\"><input #campo name=\"{{ ID }}\" [value]=\"false\" type=\"radio\" [(ngModel)]=\"value\" (click)=\"setV(false)\" >N\u00E3o</label>\r\n </div>\r\n </td>\r\n </tr>\r\n </table> \r\n\r\n <table class=\"mt-2 mr-2\" *ngIf=\"view\" >\r\n <tr>\r\n <td>\r\n <div class=\"form-fieldset view\" >\r\n <label *ngIf=\"value\" class=\"v-true disabled\" >Sim</label>\r\n <label *ngIf=\"!value\">N\u00E3o</label>\r\n </div>\r\n </td>\r\n </tr>\r\n </table>\r\n </div>\r\n <div class=\"col-md-12 mt-1\">\r\n <p class=\"sub-titulo\">{{ subTitulo }}</p>\r\n </div>\r\n <div class=\"col-md-12 mt-2 mb-1\">\r\n <ng-content></ng-content>\r\n </div>\r\n </div>\r\n</div>\r\n\r\n", styles: [".titulo{font-size:1rem;color:var(--cinza)}.sub-titulo{color:#b0adaa}.box{border:1px solid var(--cinza3);border-radius:10px}.box.box-icon{display:flex;justify-content:center;padding:35px 20px}.form-fieldset input{display:none}.form-fieldset .v-true{background:var(--verde);color:#fff}.form-fieldset label{font-size:11px;background:var(--cinza4);cursor:pointer;position:relative;display:inline-flex;align-items:center;justify-content:space-around;text-transform:uppercase;border-radius:30px;padding:7px;margin:0;width:66px}.form-fieldset label:before{content:\"\";background:#fff;border-radius:50%;height:15px;width:15px}.form-fieldset label:nth-child(2){margin-right:20px}table{width:100%;max-width:200px}.view,.view label{cursor:inherit!important}.disabled{background-color:#8fdfe8!important}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { 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.RadioControlValueAccessor, selector: "input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]", inputs: ["name", "formControlName", "value"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] });
|
|
1508
|
+
TCloudUiChoiceIssuesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiChoiceIssuesComponent, selector: "tcloud-ui-choice-issues", inputs: { view: "view", titulo: "titulo", subTitulo: "subTitulo", disabled: "disabled" }, outputs: { onChange: "onChange" }, providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$1], viewQueries: [{ propertyName: "inputRef", first: true, predicate: ["campo"], descendants: true, read: true }], ngImport: i0, template: "\r\n\r\n<input #campo [(ngModel)]=\"value\" type=\"hidden\" [value]=\"false\" >\r\n<div class=\"box p-2 mt-3 mb-2\">\r\n <div class=\"row\">\r\n <div class=\"col-md-8\">\r\n <p class=\"titulo\">{{ titulo }}</p> \r\n </div>\r\n <div class=\"col-md-4 text-right\"> \r\n\r\n <table class=\"mt-2 mr-2\" *ngIf=\"!view\" >\r\n <tr>\r\n <td>\r\n <div class=\"form-fieldset\">\r\n <label [class.v-true]=\"value\" class=\"mr-1\"><input #campo name=\"{{ ID }}\" [value]=\"true\" type=\"radio\" [(ngModel)]=\"value\" (click)=\"setV(true)\" >Sim</label>\r\n </div>\r\n </td>\r\n <td>\r\n <div class=\"form-fieldset\">\r\n <label [class.v-true]=\"!value\" class=\"ml-2\"><input #campo name=\"{{ ID }}\" [value]=\"false\" type=\"radio\" [(ngModel)]=\"value\" (click)=\"setV(false)\" >N\u00E3o</label>\r\n </div>\r\n </td>\r\n </tr>\r\n </table> \r\n\r\n <table class=\"mt-2 mr-2\" *ngIf=\"view\" >\r\n <tr>\r\n <td>\r\n <div class=\"form-fieldset view\" >\r\n <label *ngIf=\"value\" class=\"v-true disabled\" >Sim</label>\r\n <label *ngIf=\"!value\">N\u00E3o</label>\r\n </div>\r\n </td>\r\n </tr>\r\n </table>\r\n </div>\r\n <div class=\"col-md-12 mt-1\">\r\n <p class=\"sub-titulo\">{{ subTitulo }}</p>\r\n </div>\r\n <div class=\"col-md-12 mt-2 mb-1\">\r\n <ng-content></ng-content>\r\n </div>\r\n </div>\r\n</div>\r\n\r\n", styles: [".titulo{font-size:1rem;color:var(--cinza)}.sub-titulo{color:#b0adaa}.box{border:1px solid var(--cinza3);border-radius:10px}.box.box-icon{display:flex;justify-content:center;padding:35px 20px}.form-fieldset input{display:none}.form-fieldset .v-true{background:var(--verde);color:#fff}.form-fieldset label{font-size:11px;background:var(--cinza4);cursor:pointer;position:relative;display:inline-flex;align-items:center;justify-content:space-around;text-transform:uppercase;border-radius:30px;padding:7px;margin:0;width:66px}.form-fieldset label:before{content:\"\";background:#fff;border-radius:50%;height:15px;width:15px}.form-fieldset label:nth-child(2){margin-right:20px}table{width:100%;max-width:200px}.view,.view label{cursor:inherit!important}.disabled{background-color:#8fdfe8!important}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { 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.RadioControlValueAccessor, selector: "input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]", inputs: ["name", "formControlName", "value"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] });
|
|
1424
1509
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiChoiceIssuesComponent, decorators: [{
|
|
1425
1510
|
type: Component,
|
|
1426
|
-
args: [{ selector: 'tcloud-ui-choice-issues', providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR], template: "\r\n\r\n<input #campo [(ngModel)]=\"value\" type=\"hidden\" [value]=\"false\" >\r\n<div class=\"box p-2 mt-3 mb-2\">\r\n <div class=\"row\">\r\n <div class=\"col-md-8\">\r\n <p class=\"titulo\">{{ titulo }}</p> \r\n </div>\r\n <div class=\"col-md-4 text-right\"> \r\n\r\n <table class=\"mt-2 mr-2\" *ngIf=\"!view\" >\r\n <tr>\r\n <td>\r\n <div class=\"form-fieldset\">\r\n <label [class.v-true]=\"value\" class=\"mr-1\"><input #campo name=\"{{ ID }}\" [value]=\"true\" type=\"radio\" [(ngModel)]=\"value\" (click)=\"setV(true)\" >Sim</label>\r\n </div>\r\n </td>\r\n <td>\r\n <div class=\"form-fieldset\">\r\n <label [class.v-true]=\"!value\" class=\"ml-2\"><input #campo name=\"{{ ID }}\" [value]=\"false\" type=\"radio\" [(ngModel)]=\"value\" (click)=\"setV(false)\" >N\u00E3o</label>\r\n </div>\r\n </td>\r\n </tr>\r\n </table> \r\n\r\n <table class=\"mt-2 mr-2\" *ngIf=\"view\" >\r\n <tr>\r\n <td>\r\n <div class=\"form-fieldset view\" >\r\n <label *ngIf=\"value\" class=\"v-true disabled\" >Sim</label>\r\n <label *ngIf=\"!value\">N\u00E3o</label>\r\n </div>\r\n </td>\r\n </tr>\r\n </table>\r\n </div>\r\n <div class=\"col-md-12 mt-1\">\r\n <p class=\"sub-titulo\">{{ subTitulo }}</p>\r\n </div>\r\n <div class=\"col-md-12 mt-2 mb-1\">\r\n <ng-content></ng-content>\r\n </div>\r\n </div>\r\n</div>\r\n\r\n", styles: [".titulo{font-size:1rem;color:var(--cinza)}.sub-titulo{color:#b0adaa}.box{border:1px solid var(--cinza3);border-radius:10px}.box.box-icon{display:flex;justify-content:center;padding:35px 20px}.form-fieldset input{display:none}.form-fieldset .v-true{background:var(--verde);color:#fff}.form-fieldset label{font-size:11px;background:var(--cinza4);cursor:pointer;position:relative;display:inline-flex;align-items:center;justify-content:space-around;text-transform:uppercase;border-radius:30px;padding:7px;margin:0;width:66px}.form-fieldset label:before{content:\"\";background:#fff;border-radius:50%;height:15px;width:15px}.form-fieldset label:nth-child(2){margin-right:20px}table{width:100%;max-width:200px}.view,.view label{cursor:inherit!important}.disabled{background-color:#8fdfe8!important}\n"] }]
|
|
1511
|
+
args: [{ selector: 'tcloud-ui-choice-issues', providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$1], template: "\r\n\r\n<input #campo [(ngModel)]=\"value\" type=\"hidden\" [value]=\"false\" >\r\n<div class=\"box p-2 mt-3 mb-2\">\r\n <div class=\"row\">\r\n <div class=\"col-md-8\">\r\n <p class=\"titulo\">{{ titulo }}</p> \r\n </div>\r\n <div class=\"col-md-4 text-right\"> \r\n\r\n <table class=\"mt-2 mr-2\" *ngIf=\"!view\" >\r\n <tr>\r\n <td>\r\n <div class=\"form-fieldset\">\r\n <label [class.v-true]=\"value\" class=\"mr-1\"><input #campo name=\"{{ ID }}\" [value]=\"true\" type=\"radio\" [(ngModel)]=\"value\" (click)=\"setV(true)\" >Sim</label>\r\n </div>\r\n </td>\r\n <td>\r\n <div class=\"form-fieldset\">\r\n <label [class.v-true]=\"!value\" class=\"ml-2\"><input #campo name=\"{{ ID }}\" [value]=\"false\" type=\"radio\" [(ngModel)]=\"value\" (click)=\"setV(false)\" >N\u00E3o</label>\r\n </div>\r\n </td>\r\n </tr>\r\n </table> \r\n\r\n <table class=\"mt-2 mr-2\" *ngIf=\"view\" >\r\n <tr>\r\n <td>\r\n <div class=\"form-fieldset view\" >\r\n <label *ngIf=\"value\" class=\"v-true disabled\" >Sim</label>\r\n <label *ngIf=\"!value\">N\u00E3o</label>\r\n </div>\r\n </td>\r\n </tr>\r\n </table>\r\n </div>\r\n <div class=\"col-md-12 mt-1\">\r\n <p class=\"sub-titulo\">{{ subTitulo }}</p>\r\n </div>\r\n <div class=\"col-md-12 mt-2 mb-1\">\r\n <ng-content></ng-content>\r\n </div>\r\n </div>\r\n</div>\r\n\r\n", styles: [".titulo{font-size:1rem;color:var(--cinza)}.sub-titulo{color:#b0adaa}.box{border:1px solid var(--cinza3);border-radius:10px}.box.box-icon{display:flex;justify-content:center;padding:35px 20px}.form-fieldset input{display:none}.form-fieldset .v-true{background:var(--verde);color:#fff}.form-fieldset label{font-size:11px;background:var(--cinza4);cursor:pointer;position:relative;display:inline-flex;align-items:center;justify-content:space-around;text-transform:uppercase;border-radius:30px;padding:7px;margin:0;width:66px}.form-fieldset label:before{content:\"\";background:#fff;border-radius:50%;height:15px;width:15px}.form-fieldset label:nth-child(2){margin-right:20px}table{width:100%;max-width:200px}.view,.view label{cursor:inherit!important}.disabled{background-color:#8fdfe8!important}\n"] }]
|
|
1427
1512
|
}], ctorParameters: function () { return []; }, propDecorators: { view: [{
|
|
1428
1513
|
type: Input
|
|
1429
1514
|
}], titulo: [{
|
|
@@ -1465,13 +1550,31 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
|
|
|
1465
1550
|
}]
|
|
1466
1551
|
}] });
|
|
1467
1552
|
|
|
1553
|
+
const CUSTOM_INPUT_VALIDATORS = {
|
|
1554
|
+
provide: NG_VALIDATORS,
|
|
1555
|
+
useExisting: forwardRef(() => TCloudUiMultiInputComponent),
|
|
1556
|
+
multi: true
|
|
1557
|
+
};
|
|
1558
|
+
const CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR = {
|
|
1559
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1560
|
+
useExisting: forwardRef(() => TCloudUiMultiInputComponent),
|
|
1561
|
+
multi: true
|
|
1562
|
+
};
|
|
1563
|
+
const noop = () => {
|
|
1564
|
+
};
|
|
1468
1565
|
class TCloudUiMultiInputComponent {
|
|
1469
1566
|
constructor() {
|
|
1470
1567
|
this.placeholder = '';
|
|
1471
1568
|
this.disabled = false;
|
|
1472
1569
|
this.loading = false;
|
|
1473
1570
|
this.count_actives = 0;
|
|
1571
|
+
this.use_validation_required = false;
|
|
1474
1572
|
this.tcChange = new EventEmitter();
|
|
1573
|
+
this.onChange = new EventEmitter();
|
|
1574
|
+
//Placeholders for the callbacks which are later providesd
|
|
1575
|
+
//by the Control Value Accessor
|
|
1576
|
+
this.onTouchedCallback = noop;
|
|
1577
|
+
this.onChangeCallback = noop;
|
|
1475
1578
|
}
|
|
1476
1579
|
ngOnInit() {
|
|
1477
1580
|
setTimeout(() => {
|
|
@@ -1513,15 +1616,69 @@ class TCloudUiMultiInputComponent {
|
|
|
1513
1616
|
(itens).push(row);
|
|
1514
1617
|
}
|
|
1515
1618
|
}
|
|
1619
|
+
this.item_value = null;
|
|
1516
1620
|
this.count_actives = count_actives;
|
|
1517
1621
|
this.tcChange.emit(itens);
|
|
1622
|
+
this.onChangeCallback(this.tcList);
|
|
1623
|
+
}
|
|
1624
|
+
check_is_valid() {
|
|
1625
|
+
if (this.tcList) {
|
|
1626
|
+
return ((this.tcList).length > 0) ? true : false;
|
|
1627
|
+
}
|
|
1628
|
+
return false;
|
|
1629
|
+
}
|
|
1630
|
+
onChangeTouched() {
|
|
1631
|
+
this.onTouchedCallback();
|
|
1632
|
+
}
|
|
1633
|
+
//get accessor
|
|
1634
|
+
get value() {
|
|
1635
|
+
return this.innerValue;
|
|
1636
|
+
}
|
|
1637
|
+
;
|
|
1638
|
+
//set accessor including call the onchange callback
|
|
1639
|
+
set value(v) {
|
|
1640
|
+
if (v !== this.innerValue) {
|
|
1641
|
+
this.innerValue = v;
|
|
1642
|
+
this.onChangeCallback(v);
|
|
1643
|
+
}
|
|
1644
|
+
}
|
|
1645
|
+
//Set touched on blur
|
|
1646
|
+
onBlur() {
|
|
1647
|
+
this.onTouchedCallback();
|
|
1648
|
+
}
|
|
1649
|
+
//From ControlValueAccessor interface
|
|
1650
|
+
writeValue(value) {
|
|
1651
|
+
if (value !== this.innerValue) {
|
|
1652
|
+
this.innerValue = value;
|
|
1653
|
+
this.toSetDefault(value);
|
|
1654
|
+
}
|
|
1655
|
+
}
|
|
1656
|
+
//From ControlValueAccessor interface
|
|
1657
|
+
registerOnChange(fn) {
|
|
1658
|
+
this.onChangeCallback = fn;
|
|
1659
|
+
}
|
|
1660
|
+
//From ControlValueAccessor interface
|
|
1661
|
+
registerOnTouched(fn) {
|
|
1662
|
+
this.onTouchedCallback = fn;
|
|
1663
|
+
}
|
|
1664
|
+
toSetDefault(value) {
|
|
1665
|
+
this.tcList = value;
|
|
1666
|
+
}
|
|
1667
|
+
validate(c) {
|
|
1668
|
+
if (c && (typeof this.required !== 'undefined')) {
|
|
1669
|
+
this.use_validation_required = true;
|
|
1670
|
+
return (this.check_is_valid()) ? null : 'required';
|
|
1671
|
+
}
|
|
1672
|
+
return null;
|
|
1673
|
+
}
|
|
1674
|
+
ngOnDestroy() {
|
|
1518
1675
|
}
|
|
1519
1676
|
}
|
|
1520
1677
|
TCloudUiMultiInputComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1521
|
-
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
|
|
1678
|
+
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", required: "required" }, outputs: { tcChange: "tcChange", onChange: "onChange" }, providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR, CUSTOM_INPUT_VALIDATORS], ngImport: i0, template: "<div>\n\n <table>\n <tr>\n <td>\n <input (blur)=\"onChangeTouched()\" [(ngModel)]=\"item_value\" [class.tc-parent-validation]=\"use_validation_required\" type=\"text\" [(ngModel)]=\"input_value\" [disabled]=\"disabled || loading\" name=\"input_value\">\n </td>\n <td>\n <button\n [disabled]=\"!item_value || disabled || loading\"\n title=\"Adicionar\"\n class=\"btn-plus-select\"\n (click)=\"addItem(input_value);onChangeTouched()\"\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\" *ngIf=\"(tcList && tcList.length > 0)\">\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);onChangeTouched()\">\n <i class=\"fas fa-times\"></i>\n </button>\n </div>\n </div>\n\n </ng-container>\n </div>\n \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.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.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
1522
1679
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiMultiInputComponent, decorators: [{
|
|
1523
1680
|
type: Component,
|
|
1524
|
-
args: [{ selector: 'tcloud-ui-multi-input', template: "<div>\n
|
|
1681
|
+
args: [{ selector: 'tcloud-ui-multi-input', providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR, CUSTOM_INPUT_VALIDATORS], template: "<div>\n\n <table>\n <tr>\n <td>\n <input (blur)=\"onChangeTouched()\" [(ngModel)]=\"item_value\" [class.tc-parent-validation]=\"use_validation_required\" type=\"text\" [(ngModel)]=\"input_value\" [disabled]=\"disabled || loading\" name=\"input_value\">\n </td>\n <td>\n <button\n [disabled]=\"!item_value || disabled || loading\"\n title=\"Adicionar\"\n class=\"btn-plus-select\"\n (click)=\"addItem(input_value);onChangeTouched()\"\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\" *ngIf=\"(tcList && tcList.length > 0)\">\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);onChangeTouched()\">\n <i class=\"fas fa-times\"></i>\n </button>\n </div>\n </div>\n\n </ng-container>\n </div>\n \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"] }]
|
|
1525
1682
|
}], ctorParameters: function () { return []; }, propDecorators: { tcList: [{
|
|
1526
1683
|
type: Input
|
|
1527
1684
|
}], placeholder: [{
|
|
@@ -1530,8 +1687,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
|
|
|
1530
1687
|
type: Input
|
|
1531
1688
|
}], loading: [{
|
|
1532
1689
|
type: Input
|
|
1690
|
+
}], required: [{
|
|
1691
|
+
type: Input
|
|
1533
1692
|
}], tcChange: [{
|
|
1534
1693
|
type: Output
|
|
1694
|
+
}], onChange: [{
|
|
1695
|
+
type: Output
|
|
1535
1696
|
}] } });
|
|
1536
1697
|
|
|
1537
1698
|
class TCloudUiMultiInputModule {
|
|
@@ -1964,6 +2125,43 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
|
|
|
1964
2125
|
}]
|
|
1965
2126
|
}] });
|
|
1966
2127
|
|
|
2128
|
+
class TCloudUiNotFoundComponent {
|
|
2129
|
+
constructor() {
|
|
2130
|
+
this.message = 'Nenhum registro encontrado.';
|
|
2131
|
+
this.styleIcon = {};
|
|
2132
|
+
}
|
|
2133
|
+
ngOnInit() {
|
|
2134
|
+
}
|
|
2135
|
+
}
|
|
2136
|
+
TCloudUiNotFoundComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiNotFoundComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2137
|
+
TCloudUiNotFoundComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: TCloudUiNotFoundComponent, selector: "tcloud-ui-not-found", inputs: { message: "message" }, ngImport: i0, template: "<div class=\"tc-container-empty\">\r\n <div class=\"tc-message-empty-icon\">\r\n <i class=\"fas fa-exclamation-triangle\"></i>\r\n </div>\r\n <div *ngIf=\"message !== ''\" class=\"tc-message-empty\" [innerHTML]=\"message\" ></div>\r\n</div>", styles: [".tc-container-empty{margin:15px;text-align:center;border:1px solid rgba(204,204,204,.4392156863);padding:10px;border-radius:5px;background-color:#fff}.tc-container-empty .tc-message-empty-icon i{font-size:25px;color:#c1c1c1}.tc-container-empty .tc-message-empty{margin:15px;font-size:15px;color:#a49d9d}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
2138
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiNotFoundComponent, decorators: [{
|
|
2139
|
+
type: Component,
|
|
2140
|
+
args: [{ selector: 'tcloud-ui-not-found', template: "<div class=\"tc-container-empty\">\r\n <div class=\"tc-message-empty-icon\">\r\n <i class=\"fas fa-exclamation-triangle\"></i>\r\n </div>\r\n <div *ngIf=\"message !== ''\" class=\"tc-message-empty\" [innerHTML]=\"message\" ></div>\r\n</div>", styles: [".tc-container-empty{margin:15px;text-align:center;border:1px solid rgba(204,204,204,.4392156863);padding:10px;border-radius:5px;background-color:#fff}.tc-container-empty .tc-message-empty-icon i{font-size:25px;color:#c1c1c1}.tc-container-empty .tc-message-empty{margin:15px;font-size:15px;color:#a49d9d}\n"] }]
|
|
2141
|
+
}], propDecorators: { message: [{
|
|
2142
|
+
type: Input
|
|
2143
|
+
}] } });
|
|
2144
|
+
|
|
2145
|
+
class TCloudUiNotFoundModule {
|
|
2146
|
+
}
|
|
2147
|
+
TCloudUiNotFoundModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiNotFoundModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
2148
|
+
TCloudUiNotFoundModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiNotFoundModule, declarations: [TCloudUiNotFoundComponent], imports: [CommonModule], exports: [TCloudUiNotFoundComponent] });
|
|
2149
|
+
TCloudUiNotFoundModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiNotFoundModule, imports: [CommonModule] });
|
|
2150
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: TCloudUiNotFoundModule, decorators: [{
|
|
2151
|
+
type: NgModule,
|
|
2152
|
+
args: [{
|
|
2153
|
+
declarations: [
|
|
2154
|
+
TCloudUiNotFoundComponent
|
|
2155
|
+
],
|
|
2156
|
+
imports: [
|
|
2157
|
+
CommonModule,
|
|
2158
|
+
],
|
|
2159
|
+
exports: [
|
|
2160
|
+
TCloudUiNotFoundComponent
|
|
2161
|
+
],
|
|
2162
|
+
}]
|
|
2163
|
+
}] });
|
|
2164
|
+
|
|
1967
2165
|
class TCloudUiTooltipDirective {
|
|
1968
2166
|
constructor(el, renderer) {
|
|
1969
2167
|
this.el = el;
|
|
@@ -2246,6 +2444,7 @@ TCloudUiModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version:
|
|
|
2246
2444
|
TCloudUiMultiInputModule,
|
|
2247
2445
|
TCloudUiChoiceIssuesModule,
|
|
2248
2446
|
TCloudUiInputSearchModule,
|
|
2447
|
+
TCloudUiNotFoundModule,
|
|
2249
2448
|
// Directives
|
|
2250
2449
|
TCloudUiDirectiveModule,
|
|
2251
2450
|
// Pipes
|
|
@@ -2258,6 +2457,7 @@ TCloudUiModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version:
|
|
|
2258
2457
|
TCloudUiMultiInputModule,
|
|
2259
2458
|
TCloudUiChoiceIssuesModule,
|
|
2260
2459
|
TCloudUiInputSearchModule,
|
|
2460
|
+
TCloudUiNotFoundModule,
|
|
2261
2461
|
// Directives
|
|
2262
2462
|
TCloudUiDirectiveModule,
|
|
2263
2463
|
// Pipes
|
|
@@ -2274,6 +2474,7 @@ TCloudUiModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version:
|
|
|
2274
2474
|
TCloudUiMultiInputModule,
|
|
2275
2475
|
TCloudUiChoiceIssuesModule,
|
|
2276
2476
|
TCloudUiInputSearchModule,
|
|
2477
|
+
TCloudUiNotFoundModule,
|
|
2277
2478
|
// Directives
|
|
2278
2479
|
TCloudUiDirectiveModule,
|
|
2279
2480
|
// Pipes
|
|
@@ -2286,6 +2487,7 @@ TCloudUiModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version:
|
|
|
2286
2487
|
TCloudUiMultiInputModule,
|
|
2287
2488
|
TCloudUiChoiceIssuesModule,
|
|
2288
2489
|
TCloudUiInputSearchModule,
|
|
2490
|
+
TCloudUiNotFoundModule,
|
|
2289
2491
|
// Directives
|
|
2290
2492
|
TCloudUiDirectiveModule,
|
|
2291
2493
|
// Pipes
|
|
@@ -2303,6 +2505,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
|
|
|
2303
2505
|
TCloudUiMultiInputModule,
|
|
2304
2506
|
TCloudUiChoiceIssuesModule,
|
|
2305
2507
|
TCloudUiInputSearchModule,
|
|
2508
|
+
TCloudUiNotFoundModule,
|
|
2306
2509
|
// Directives
|
|
2307
2510
|
TCloudUiDirectiveModule,
|
|
2308
2511
|
// Pipes
|
|
@@ -2318,6 +2521,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
|
|
|
2318
2521
|
TCloudUiMultiInputModule,
|
|
2319
2522
|
TCloudUiChoiceIssuesModule,
|
|
2320
2523
|
TCloudUiInputSearchModule,
|
|
2524
|
+
TCloudUiNotFoundModule,
|
|
2321
2525
|
// Directives
|
|
2322
2526
|
TCloudUiDirectiveModule,
|
|
2323
2527
|
// Pipes
|
|
@@ -2338,5 +2542,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
|
|
|
2338
2542
|
* Generated bundle index. Do not edit.
|
|
2339
2543
|
*/
|
|
2340
2544
|
|
|
2341
|
-
export { CNPJPipe, CPFPipe, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$
|
|
2545
|
+
export { CNPJPipe, CPFPipe, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$2 as CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR, MonthNamePipe, RespectivePipe, StatusInfoPipe, TCloudUiChoiceIssuesComponent, TCloudUiChoiceIssuesModule, TCloudUiDataListComponent, TCloudUiDataListModule, TCloudUiDataListOptionComponent, TCloudUiDirectiveModule, TCloudUiInputSearchComponent, TCloudUiInputSearchModule, TCloudUiLineStepCircleComponent, TCloudUiLineStepCircleModule, TCloudUiLinhaLogoComponent, TCloudUiLinhaLogoModule, TCloudUiLoadingTransitionsService, TCloudUiModalBodyComponent, TCloudUiModalComponent, TCloudUiModalFooterComponent, TCloudUiModalHeaderComponent, TCloudUiModalModule, TCloudUiModule, TCloudUiMultiInputComponent, TCloudUiMultiInputModule, TCloudUiMultiSelectComponent, TCloudUiMultiSelectModule, TCloudUiNotFoundComponent, TCloudUiNotFoundModule, TCloudUiPipesModule, TCloudUiSearchInObjectService, TCloudUiTabContentComponent, TCloudUiTabHeadComponent, TCloudUiTabMenuComponent, TCloudUiTabMenuModule, TCloudUiTabSubtitleComponent, TCloudUiTabTitleComponent, TCloudUiTooltipDirective };
|
|
2342
2546
|
//# sourceMappingURL=dev-tcloud-tcloud-ui.mjs.map
|