@seniorsistemas/angular-components 17.2.9 → 17.2.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/bundles/seniorsistemas-angular-components.umd.js +1698 -1649
- package/bundles/seniorsistemas-angular-components.umd.js.map +1 -1
- package/bundles/seniorsistemas-angular-components.umd.min.js +2 -2
- package/bundles/seniorsistemas-angular-components.umd.min.js.map +1 -1
- package/components/country-phone-picker/country-phone-picker.component.d.ts +5 -0
- package/components/dynamic-form/components/fields/base-field-component.d.ts +2 -1
- package/components/dynamic-form/components/fields/country-phone-picker/country-phone-picker-field.component.d.ts +7 -0
- package/components/dynamic-form/configurations/field-type.d.ts +1 -0
- package/components/dynamic-form/configurations/fields/country-phone-picker-field.d.ts +15 -0
- package/components/dynamic-form/configurations/fields/index.d.ts +19 -0
- package/esm2015/components/country-phone-picker/country-phone-picker.component.js +13 -2
- package/esm2015/components/dynamic-form/components/fields/base-field-component.js +1 -1
- package/esm2015/components/dynamic-form/components/fields/country-phone-picker/country-phone-picker-field.component.js +17 -0
- package/esm2015/components/dynamic-form/configurations/field-type.js +2 -1
- package/esm2015/components/dynamic-form/configurations/fields/country-phone-picker-field.js +11 -0
- package/esm2015/components/dynamic-form/configurations/fields/index.js +20 -0
- package/esm2015/components/dynamic-form/configurations/form-field.js +4 -1
- package/esm2015/components/dynamic-form/dynamic-form.js +7 -4
- package/esm2015/components/dynamic-form/dynamic-form.module.js +56 -47
- package/esm2015/components/file-upload/file-upload.component.js +2 -7
- package/esm2015/components/file-upload/file-upload.module.js +3 -1
- package/esm2015/locale/fallback.js +5 -1
- package/esm2015/seniorsistemas-angular-components.js +55 -54
- package/esm5/components/country-phone-picker/country-phone-picker.component.js +13 -2
- package/esm5/components/dynamic-form/components/fields/base-field-component.js +1 -1
- package/esm5/components/dynamic-form/components/fields/country-phone-picker/country-phone-picker-field.component.js +20 -0
- package/esm5/components/dynamic-form/configurations/field-type.js +2 -1
- package/esm5/components/dynamic-form/configurations/fields/country-phone-picker-field.js +16 -0
- package/esm5/components/dynamic-form/configurations/fields/index.js +20 -0
- package/esm5/components/dynamic-form/configurations/form-field.js +4 -1
- package/esm5/components/dynamic-form/dynamic-form.js +7 -4
- package/esm5/components/dynamic-form/dynamic-form.module.js +56 -47
- package/esm5/components/file-upload/file-upload.component.js +2 -7
- package/esm5/components/file-upload/file-upload.module.js +3 -1
- package/esm5/locale/fallback.js +5 -1
- package/esm5/seniorsistemas-angular-components.js +55 -54
- package/fesm2015/seniorsistemas-angular-components.js +1508 -1466
- package/fesm2015/seniorsistemas-angular-components.js.map +1 -1
- package/fesm5/seniorsistemas-angular-components.js +1641 -1593
- package/fesm5/seniorsistemas-angular-components.js.map +1 -1
- package/package.json +1 -1
- package/seniorsistemas-angular-components.d.ts +54 -53
- package/seniorsistemas-angular-components.metadata.json +1 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
(function (global, factory) {
|
|
2
|
-
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/animations'), require('rxjs'), require('rxjs/operators'), require('@angular/common'), require('@angular/forms'), require('@angular/router'), require('primeng/breadcrumb'), require('primeng/tieredmenu'), require('primeng/tooltip'), require('primeng/dom'), require('primeng/calendar'), require('@ngx-translate/core'), require('ngx-mask'), require('@angular/common/http'), require('angular2-hotkeys'), require('bignumber.js'), require('primeng/autocomplete'), require('primeng/dialog'), require('primeng/table'), require('@seniorsistemas/ng2-currency-mask'), require('@seniorsistemas/senior-platform-data'), require('moment'), require('ngx-cookie-service'), require('ng2-currency-mask'), require('primeng/button'), require('primeng/checkbox'), require('primeng/chips'), require('primeng/dropdown'), require('primeng/fieldset'), require('primeng/inputmask'), require('primeng/inputtext'), require('primeng/inputtextarea'), require('primeng/keyfilter'), require('primeng/multiselect'), require('primeng/panel'), require('primeng/radiobutton'), require('primeng/slider'), require('primeng/progressbar'), require('@angular/platform-browser'), require('@angular/cdk/clipboard'), require('
|
|
3
|
-
typeof define === 'function' && define.amd ? define('@seniorsistemas/angular-components', ['exports', '@angular/core', '@angular/animations', 'rxjs', 'rxjs/operators', '@angular/common', '@angular/forms', '@angular/router', 'primeng/breadcrumb', 'primeng/tieredmenu', 'primeng/tooltip', 'primeng/dom', 'primeng/calendar', '@ngx-translate/core', 'ngx-mask', '@angular/common/http', 'angular2-hotkeys', 'bignumber.js', 'primeng/autocomplete', 'primeng/dialog', 'primeng/table', '@seniorsistemas/ng2-currency-mask', '@seniorsistemas/senior-platform-data', 'moment', 'ngx-cookie-service', 'ng2-currency-mask', 'primeng/button', 'primeng/checkbox', 'primeng/chips', 'primeng/dropdown', 'primeng/fieldset', 'primeng/inputmask', 'primeng/inputtext', 'primeng/inputtextarea', 'primeng/keyfilter', 'primeng/multiselect', 'primeng/panel', 'primeng/radiobutton', 'primeng/slider', 'primeng/progressbar', '@angular/platform-browser', '@angular/cdk/clipboard', '
|
|
4
|
-
(global = global || self, factory((global.seniorsistemas = global.seniorsistemas || {}, global.seniorsistemas['angular-components'] = {}), global.ng.core, global.ng.animations, global.rxjs, global.rxjs.operators, global.ng.common, global.ng.forms, global.ng.router, global.breadcrumb, global.tieredmenu, global.tooltip, global.dom, global.calendar, global.core$1, global.ngxMask, global.ng.common.http, global.angular2Hotkeys, global.BigNumber, global.autocomplete$1, global.dialog, global.table, global.ng2CurrencyMask, global.seniorPlatformData, global.moment_, global.ngxCookieService, global.ng2CurrencyMask$1, global.button, global.checkbox, global.chips, global.dropdown, global.fieldset, global.inputmask, global.inputtext, global.inputtextarea, global.keyfilter, global.multiselect, global.panel, global.radiobutton, global.slider, global.progressbar, global.ng.platformBrowser, global.ng.cdk.clipboard, global.
|
|
5
|
-
}(this, (function (exports, core, animations, rxjs, operators, common, forms, router, breadcrumb, tieredmenu, tooltip, dom, calendar, core$1, ngxMask, http, angular2Hotkeys, BigNumber, autocomplete$1, dialog, table, ng2CurrencyMask, seniorPlatformData, moment_, ngxCookieService, ng2CurrencyMask$1, button, checkbox, chips, dropdown, fieldset, inputmask, inputtext, inputtextarea, keyfilter, multiselect, panel, radiobutton, slider, progressbar, platformBrowser, clipboard,
|
|
2
|
+
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/animations'), require('rxjs'), require('rxjs/operators'), require('@angular/common'), require('@angular/forms'), require('@angular/router'), require('primeng/breadcrumb'), require('primeng/tieredmenu'), require('primeng/tooltip'), require('primeng/dom'), require('primeng/calendar'), require('@ngx-translate/core'), require('ngx-mask'), require('@angular/common/http'), require('angular2-hotkeys'), require('bignumber.js'), require('primeng/autocomplete'), require('primeng/dialog'), require('primeng/table'), require('@seniorsistemas/ng2-currency-mask'), require('@seniorsistemas/senior-platform-data'), require('moment'), require('ngx-cookie-service'), require('ng2-currency-mask'), require('primeng/button'), require('primeng/checkbox'), require('primeng/chips'), require('primeng/dropdown'), require('primeng/fieldset'), require('primeng/inputmask'), require('primeng/inputtext'), require('primeng/inputtextarea'), require('primeng/keyfilter'), require('primeng/multiselect'), require('primeng/panel'), require('primeng/radiobutton'), require('primeng/slider'), require('primeng/api'), require('primeng/progressbar'), require('@angular/platform-browser'), require('@angular/cdk/clipboard'), require('cropperjs'), require('element-resize-detector'), require('@angular/cdk/a11y'), require('primeng/scrollpanel'), require('primeng/sidebar'), require('primeng/confirmdialog'), require('@codemirror/view'), require('@codemirror/state'), require('@codemirror/lint'), require('@codemirror/language'), require('@lezer/generator'), require('@codemirror/highlight'), require('@codemirror/autocomplete'), require('@codemirror/tooltip'), require('@codemirror/gutter')) :
|
|
3
|
+
typeof define === 'function' && define.amd ? define('@seniorsistemas/angular-components', ['exports', '@angular/core', '@angular/animations', 'rxjs', 'rxjs/operators', '@angular/common', '@angular/forms', '@angular/router', 'primeng/breadcrumb', 'primeng/tieredmenu', 'primeng/tooltip', 'primeng/dom', 'primeng/calendar', '@ngx-translate/core', 'ngx-mask', '@angular/common/http', 'angular2-hotkeys', 'bignumber.js', 'primeng/autocomplete', 'primeng/dialog', 'primeng/table', '@seniorsistemas/ng2-currency-mask', '@seniorsistemas/senior-platform-data', 'moment', 'ngx-cookie-service', 'ng2-currency-mask', 'primeng/button', 'primeng/checkbox', 'primeng/chips', 'primeng/dropdown', 'primeng/fieldset', 'primeng/inputmask', 'primeng/inputtext', 'primeng/inputtextarea', 'primeng/keyfilter', 'primeng/multiselect', 'primeng/panel', 'primeng/radiobutton', 'primeng/slider', 'primeng/api', 'primeng/progressbar', '@angular/platform-browser', '@angular/cdk/clipboard', 'cropperjs', 'element-resize-detector', '@angular/cdk/a11y', 'primeng/scrollpanel', 'primeng/sidebar', 'primeng/confirmdialog', '@codemirror/view', '@codemirror/state', '@codemirror/lint', '@codemirror/language', '@lezer/generator', '@codemirror/highlight', '@codemirror/autocomplete', '@codemirror/tooltip', '@codemirror/gutter'], factory) :
|
|
4
|
+
(global = global || self, factory((global.seniorsistemas = global.seniorsistemas || {}, global.seniorsistemas['angular-components'] = {}), global.ng.core, global.ng.animations, global.rxjs, global.rxjs.operators, global.ng.common, global.ng.forms, global.ng.router, global.breadcrumb, global.tieredmenu, global.tooltip, global.dom, global.calendar, global.core$1, global.ngxMask, global.ng.common.http, global.angular2Hotkeys, global.BigNumber, global.autocomplete$1, global.dialog, global.table, global.ng2CurrencyMask, global.seniorPlatformData, global.moment_, global.ngxCookieService, global.ng2CurrencyMask$1, global.button, global.checkbox, global.chips, global.dropdown, global.fieldset, global.inputmask, global.inputtext, global.inputtextarea, global.keyfilter, global.multiselect, global.panel, global.radiobutton, global.slider, global.api, global.progressbar, global.ng.platformBrowser, global.ng.cdk.clipboard, global.Cropper, global.elementResizeDetectorMaker_, global.ng.cdk.a11y, global.scrollpanel, global.sidebar, global.confirmdialog, global.view, global.state, global.lint, global.language, global.generator, global.highlight, global.autocomplete$2, global.tooltip$1, global.gutter));
|
|
5
|
+
}(this, (function (exports, core, animations, rxjs, operators, common, forms, router, breadcrumb, tieredmenu, tooltip, dom, calendar, core$1, ngxMask, http, angular2Hotkeys, BigNumber, autocomplete$1, dialog, table, ng2CurrencyMask, seniorPlatformData, moment_, ngxCookieService, ng2CurrencyMask$1, button, checkbox, chips, dropdown, fieldset, inputmask, inputtext, inputtextarea, keyfilter, multiselect, panel, radiobutton, slider, api, progressbar, platformBrowser, clipboard, Cropper, elementResizeDetectorMaker_, a11y, scrollpanel, sidebar, confirmdialog, view, state, lint, language, generator, highlight, autocomplete$2, tooltip$1, gutter) { 'use strict';
|
|
6
6
|
|
|
7
7
|
var BigNumber__default = 'default' in BigNumber ? BigNumber['default'] : BigNumber;
|
|
8
8
|
Cropper = Cropper && Cropper.hasOwnProperty('default') ? Cropper['default'] : Cropper;
|
|
@@ -2265,7 +2265,11 @@
|
|
|
2265
2265
|
this.offsetTop = 0;
|
|
2266
2266
|
this.ordination = exports.Ordination.NO;
|
|
2267
2267
|
this.selected = new core.EventEmitter();
|
|
2268
|
+
/**
|
|
2269
|
+
* @deprecated Use focusLost event instead.
|
|
2270
|
+
*/
|
|
2268
2271
|
this.blur = new core.EventEmitter();
|
|
2272
|
+
this.focusLost = new core.EventEmitter();
|
|
2269
2273
|
this.tabindex = 0;
|
|
2270
2274
|
this._filterCountries = function (value) {
|
|
2271
2275
|
if (!value) {
|
|
@@ -2404,6 +2408,10 @@
|
|
|
2404
2408
|
CountryPhonePickerComponent.prototype.getPlaceholder = function () {
|
|
2405
2409
|
return this.mask.replace(/9/g, "");
|
|
2406
2410
|
};
|
|
2411
|
+
CountryPhonePickerComponent.prototype.onBlur = function (value) {
|
|
2412
|
+
this.blur.emit(value);
|
|
2413
|
+
this.focusLost.emit(value);
|
|
2414
|
+
};
|
|
2407
2415
|
CountryPhonePickerComponent.prototype._getSelectedCountryDefault = function () {
|
|
2408
2416
|
if (!this._countriesList.length) {
|
|
2409
2417
|
throw new Error("No country loaded");
|
|
@@ -2497,6 +2505,9 @@
|
|
|
2497
2505
|
__decorate([
|
|
2498
2506
|
core.Output()
|
|
2499
2507
|
], CountryPhonePickerComponent.prototype, "blur", void 0);
|
|
2508
|
+
__decorate([
|
|
2509
|
+
core.Output()
|
|
2510
|
+
], CountryPhonePickerComponent.prototype, "focusLost", void 0);
|
|
2500
2511
|
__decorate([
|
|
2501
2512
|
core.ViewChild("phoneInput", { static: true })
|
|
2502
2513
|
], CountryPhonePickerComponent.prototype, "phoneInput", void 0);
|
|
@@ -2512,7 +2523,7 @@
|
|
|
2512
2523
|
CountryPhonePickerComponent = CountryPhonePickerComponent_1 = __decorate([
|
|
2513
2524
|
core.Component({
|
|
2514
2525
|
selector: "s-country-phone-picker",
|
|
2515
|
-
template: "<div class=\"country-phone-picker\">\n <div class=\"phone-input\">\n <div class=\"drop\" (click)=\"open = !open\">\n <span class=\"drop-flag\" [ngClass]=\"'fi fi-' + selectedItem.id\">\n </span>\n <span class=\"drop-icon fas fa-caret-down\"></span>\n </div>\n <p class=\"phone-ddi\">{{ selectedItem.ddi }}</p>\n <input\n #phoneInput\n type=\"tel\"\n autofocus\n [mask]=\"mask\" \n [placeholder]=\"getPlaceholder()\"\n [formControl]=\"phone\"\n (focus)=\"onPhoneInputFocus()\" \n (blur)=\"
|
|
2526
|
+
template: "<div class=\"country-phone-picker\">\n <div class=\"phone-input\">\n <div class=\"drop\" (click)=\"open = !open\">\n <span class=\"drop-flag\" [ngClass]=\"'fi fi-' + selectedItem.id\">\n </span>\n <span class=\"drop-icon fas fa-caret-down\"></span>\n </div>\n <p class=\"phone-ddi\">{{ selectedItem.ddi }}</p>\n <input\n #phoneInput\n type=\"tel\"\n autofocus\n [mask]=\"mask\" \n [placeholder]=\"getPlaceholder()\"\n [formControl]=\"phone\"\n (focus)=\"onPhoneInputFocus()\" \n (blur)=\"onBlur(value)\"\n />\n </div>\n <div *ngIf=\"open\" class=\"dropdown\">\n <div class=\"search\">\n <input\n class=\"search-field\"\n type=\"text\"\n [formControl]=\"filter\">\n <span class=\"search-icon fas fa-search\"></span>\n <span\n class=\"search-clear fa fa-times\"\n (click)=\"onCleanFilter()\"></span>\n </div>\n <ul class=\"select-list\">\n <li\n *ngFor=\"let country of filteredCountriesList; let i = index;\"\n class=\"select-option\"\n [ngClass]=\"{ 'select-option--focused': i == currentItemIndex }\"\n (click)=\"onSelectItem(country)\">\n <span\n class=\"select-option__flag\"\n [ngClass]=\"'fi fi-' + country.id\">\n </span>\n <span class=\"select-option__name\">\n {{ \"platform.angular_components.country_name_\" + country.id | translate }}\n </span>\n <span class=\"select-option__ddi\">\n {{ country.ddi }}\n </span>\n </li>\n </ul>\n </div>\n</div>",
|
|
2516
2527
|
providers: [{
|
|
2517
2528
|
provide: forms.NG_VALUE_ACCESSOR,
|
|
2518
2529
|
useExisting: core.forwardRef(function () { return CountryPhonePickerComponent_1; }),
|
|
@@ -2550,6 +2561,7 @@
|
|
|
2550
2561
|
FieldType["Blob"] = "Blob";
|
|
2551
2562
|
FieldType["Boolean"] = "Boolean";
|
|
2552
2563
|
FieldType["Chips"] = "Chips";
|
|
2564
|
+
FieldType["CountryPhonePicker"] = "CountryPhonePicker";
|
|
2553
2565
|
FieldType["Custom"] = "Custom";
|
|
2554
2566
|
FieldType["Date"] = "Date";
|
|
2555
2567
|
FieldType["DateTime"] = "DateTime";
|
|
@@ -3519,6 +3531,19 @@
|
|
|
3519
3531
|
return SliderField;
|
|
3520
3532
|
}(Field));
|
|
3521
3533
|
|
|
3534
|
+
var CountryPhonePickerField = /** @class */ (function (_super) {
|
|
3535
|
+
__extends(CountryPhonePickerField, _super);
|
|
3536
|
+
function CountryPhonePickerField(config) {
|
|
3537
|
+
var _this = _super.call(this, config) || this;
|
|
3538
|
+
_this.countries = config.countries;
|
|
3539
|
+
_this.ordination = config.ordination;
|
|
3540
|
+
_this.onSelected = config.onSelected;
|
|
3541
|
+
_this.onFocusLost = config.onFocusLost;
|
|
3542
|
+
return _this;
|
|
3543
|
+
}
|
|
3544
|
+
return CountryPhonePickerField;
|
|
3545
|
+
}(Field));
|
|
3546
|
+
|
|
3522
3547
|
var FormField = /** @class */ (function () {
|
|
3523
3548
|
function FormField(config) {
|
|
3524
3549
|
switch (config.type) {
|
|
@@ -3556,6 +3581,8 @@
|
|
|
3556
3581
|
return new RadioButtonField(config);
|
|
3557
3582
|
case exports.FieldType.Chips:
|
|
3558
3583
|
return new ChipsField(config);
|
|
3584
|
+
case exports.FieldType.CountryPhonePicker:
|
|
3585
|
+
return new CountryPhonePickerField(config);
|
|
3559
3586
|
case exports.FieldType.Blob:
|
|
3560
3587
|
return new BlobField(config);
|
|
3561
3588
|
case exports.FieldType.Slider:
|
|
@@ -4266,157 +4293,422 @@
|
|
|
4266
4293
|
return DynamicFormComponent;
|
|
4267
4294
|
}());
|
|
4268
4295
|
|
|
4269
|
-
var
|
|
4270
|
-
function
|
|
4271
|
-
this.
|
|
4272
|
-
this.
|
|
4273
|
-
this.showPrimaryAction = true;
|
|
4274
|
-
this.showSecondaryAction = true;
|
|
4275
|
-
this.primaryModel = [];
|
|
4276
|
-
this.primaryAction = new core.EventEmitter();
|
|
4277
|
-
this.secondaryAction = new core.EventEmitter();
|
|
4296
|
+
var IAssistService = /** @class */ (function () {
|
|
4297
|
+
function IAssistService(http, _messageService) {
|
|
4298
|
+
this.http = http;
|
|
4299
|
+
this._messageService = _messageService;
|
|
4278
4300
|
}
|
|
4279
|
-
|
|
4280
|
-
|
|
4281
|
-
|
|
4282
|
-
|
|
4283
|
-
|
|
4284
|
-
|
|
4285
|
-
|
|
4286
|
-
|
|
4287
|
-
|
|
4288
|
-
|
|
4289
|
-
|
|
4290
|
-
|
|
4291
|
-
|
|
4292
|
-
|
|
4293
|
-
|
|
4294
|
-
|
|
4295
|
-
|
|
4296
|
-
|
|
4297
|
-
|
|
4298
|
-
|
|
4299
|
-
|
|
4300
|
-
|
|
4301
|
-
|
|
4302
|
-
|
|
4303
|
-
|
|
4304
|
-
|
|
4305
|
-
|
|
4301
|
+
IAssistService.prototype.askIA = function (context, data) {
|
|
4302
|
+
var _this = this;
|
|
4303
|
+
return this.http.post("platform/iassist/api/latest/completions", {
|
|
4304
|
+
"prompt": this._createPrompt(context, data),
|
|
4305
|
+
"provider": "OPEN_AI",
|
|
4306
|
+
"parameters": {
|
|
4307
|
+
"model": "gpt-3.5-turbo",
|
|
4308
|
+
"max_tokens": 700,
|
|
4309
|
+
"temperature": 1
|
|
4310
|
+
}
|
|
4311
|
+
}).pipe(operators.catchError(function (err) {
|
|
4312
|
+
_this._messageService.add({
|
|
4313
|
+
severity: "error",
|
|
4314
|
+
summary: err.status ? String(err.status) : "Error",
|
|
4315
|
+
detail: (err.error && err.error.message) || err.statusText || err.message || "Error",
|
|
4316
|
+
});
|
|
4317
|
+
return rxjs.throwError(err);
|
|
4318
|
+
}));
|
|
4319
|
+
};
|
|
4320
|
+
IAssistService.prototype._createPrompt = function (context, data) {
|
|
4321
|
+
return "Crie um texto gen\u00E9rico para preencher o campo de textarea.\n " + (data.label ? "O campo tem o label " + data.label + "." : "") + "\n " + (data.id ? "O campo tem o id " + data.id + "." : "") + "\n " + (data.placeholder ? "Considere as instru\u00E7\u00F5es/sugest\u00F5es do placeholder: " + data.placeholder + "." : "") + "\n Baseie-se no contexto informado pelo usu\u00E1rio: '" + context + "'.\n O texto deve ser formal e conter informa\u00E7\u00F5es pertinentes a um campo como este, como se um usu\u00E1rio real tivesse preenchido com as informa\u00E7\u00F5es necess\u00E1rias. \n O texto deve ser neutro com rela\u00E7\u00E3o a generos, ra\u00E7as, religi\u00F5es, etc.\n O texto deve ser impessoal e n\u00E3o deve conter informa\u00E7\u00F5es pessoais do usu\u00E1rio.\n N\u00E3o direcione o texto a ningu\u00E9m, n\u00E3o use express\u00F5es como: caro, atenciosamente. gostaria, agrade\u00E7o. O texto deve ser gen\u00E9rico.\n \n Exemplos de texto:\n Um campo de descri\u00E7\u00E3o de usu\u00E1rio: \"Usu\u00E1rio com 20 anos, estudante de engenharia, gosta de jogar futebol e assistir filmes.\"\n Outro exemplo de descri\u00E7\u00E3o de usu\u00E1rio: \"Usu\u00E1rio administrador, com acesso total ao sistema, respons\u00E1vel por gerenciar os usu\u00E1rios e os produtos.\"\n Um campo de descri\u00E7\u00E3o de um produto: \"O produto \u00E9 um celular, com tela de 6 polegadas, 128GB de armazenamento, 4GB de mem\u00F3ria RAM, c\u00E2mera de 12MP e bateria de 4000mAh.\"\n Outro exemplo de descri\u00E7\u00E3o de produto: \"O produto \u00E9 uma geladeira, com capacidade de 500 litros, 2 portas, cor branca, com freezer e gaveta de legumes.\"\n Outro exemplo de descri\u00E7\u00E3o de produto: \"O produto \u00E9 uma camiseta, tamanho M, cor azul, 100% algod\u00E3o, com estampa de um gato.\"\n \n Em caso de contexto incompleto crie um texto gen\u00E9rico, como se fosse um exemplo de preenchimento do campo.\n O texto \u00E9 para um campo de textarea, ent\u00E3o escreva um texto sucinto.\n Exiba apenas o texto do output";
|
|
4322
|
+
};
|
|
4323
|
+
IAssistService.ctorParameters = function () { return [
|
|
4324
|
+
{ type: http.HttpClient },
|
|
4325
|
+
{ type: api.MessageService }
|
|
4326
|
+
]; };
|
|
4327
|
+
IAssistService = __decorate([
|
|
4328
|
+
core.Injectable()
|
|
4329
|
+
], IAssistService);
|
|
4330
|
+
return IAssistService;
|
|
4331
|
+
}());
|
|
4332
|
+
|
|
4333
|
+
var LongPressDirective = /** @class */ (function () {
|
|
4334
|
+
function LongPressDirective() {
|
|
4335
|
+
this.sLongPressDelay = 500;
|
|
4336
|
+
this.sLongPress = new core.EventEmitter();
|
|
4337
|
+
this.mouseUp = new rxjs.Subject();
|
|
4338
|
+
this.mouseDown = new rxjs.Subject();
|
|
4339
|
+
this.ngUnsubscribe = new rxjs.Subject();
|
|
4340
|
+
}
|
|
4341
|
+
LongPressDirective.prototype.onMouseUp = function (event) {
|
|
4342
|
+
this.mouseUp.next(event);
|
|
4343
|
+
};
|
|
4344
|
+
LongPressDirective.prototype.onMouseDown = function (event) {
|
|
4345
|
+
this.mouseDown.next(event);
|
|
4346
|
+
};
|
|
4347
|
+
LongPressDirective.prototype.ngOnInit = function () {
|
|
4348
|
+
var _this = this;
|
|
4349
|
+
this.mouseDown
|
|
4350
|
+
.pipe(operators.debounceTime(this.sLongPressDelay), operators.takeUntil(this.mouseUp), operators.repeat(), operators.takeUntil(this.ngUnsubscribe))
|
|
4351
|
+
.subscribe(function (event) { return _this.sLongPress.emit(event); });
|
|
4352
|
+
};
|
|
4353
|
+
LongPressDirective.prototype.ngOnDestroy = function () {
|
|
4354
|
+
this.ngUnsubscribe.next();
|
|
4355
|
+
this.ngUnsubscribe.complete();
|
|
4356
|
+
};
|
|
4306
4357
|
__decorate([
|
|
4307
4358
|
core.Input()
|
|
4308
|
-
],
|
|
4359
|
+
], LongPressDirective.prototype, "sLongPressDelay", void 0);
|
|
4309
4360
|
__decorate([
|
|
4310
4361
|
core.Output()
|
|
4311
|
-
],
|
|
4362
|
+
], LongPressDirective.prototype, "sLongPress", void 0);
|
|
4312
4363
|
__decorate([
|
|
4313
|
-
core.
|
|
4314
|
-
|
|
4315
|
-
|
|
4316
|
-
|
|
4317
|
-
|
|
4318
|
-
|
|
4319
|
-
|
|
4364
|
+
core.HostListener("mouseup", ["$event"]),
|
|
4365
|
+
core.HostListener("touchend", ["$event"])
|
|
4366
|
+
], LongPressDirective.prototype, "onMouseUp", null);
|
|
4367
|
+
__decorate([
|
|
4368
|
+
core.HostListener("mousedown", ["$event"]),
|
|
4369
|
+
core.HostListener("touchstart", ["$event"])
|
|
4370
|
+
], LongPressDirective.prototype, "onMouseDown", null);
|
|
4371
|
+
LongPressDirective = __decorate([
|
|
4372
|
+
core.Directive({
|
|
4373
|
+
selector: "[sLongPress]",
|
|
4320
4374
|
})
|
|
4321
|
-
],
|
|
4322
|
-
return
|
|
4375
|
+
], LongPressDirective);
|
|
4376
|
+
return LongPressDirective;
|
|
4323
4377
|
}());
|
|
4324
4378
|
|
|
4325
|
-
var
|
|
4326
|
-
function
|
|
4327
|
-
this.
|
|
4328
|
-
this.
|
|
4379
|
+
var DoubleClickDirective = /** @class */ (function () {
|
|
4380
|
+
function DoubleClickDirective() {
|
|
4381
|
+
this.onDoubleClick = new core.EventEmitter();
|
|
4382
|
+
this._timeout = null;
|
|
4383
|
+
this._DOUBLE_CLICK_DELAY = 500;
|
|
4329
4384
|
}
|
|
4330
|
-
|
|
4331
|
-
|
|
4332
|
-
|
|
4385
|
+
DoubleClickDirective.prototype.onClick = function (event) {
|
|
4386
|
+
this.handleOnClickEvent(event);
|
|
4387
|
+
};
|
|
4388
|
+
DoubleClickDirective.prototype.handleOnClickEvent = function (event) {
|
|
4389
|
+
var _this = this;
|
|
4390
|
+
if (this._timeout) {
|
|
4391
|
+
this.clearTimeout();
|
|
4392
|
+
this.onDoubleClick.emit(event);
|
|
4393
|
+
}
|
|
4394
|
+
else {
|
|
4395
|
+
this._timeout = setTimeout(function () { return _this.clearTimeout(); }, this._DOUBLE_CLICK_DELAY);
|
|
4396
|
+
}
|
|
4397
|
+
};
|
|
4398
|
+
DoubleClickDirective.prototype.clearTimeout = function () {
|
|
4399
|
+
clearTimeout(this._timeout);
|
|
4400
|
+
this._timeout = null;
|
|
4333
4401
|
};
|
|
4334
|
-
EmptyStateGoBackComponent.nextId = 0;
|
|
4335
|
-
EmptyStateGoBackComponent.ctorParameters = function () { return [
|
|
4336
|
-
{ type: ngxCookieService.CookieService }
|
|
4337
|
-
]; };
|
|
4338
|
-
__decorate([
|
|
4339
|
-
core.Input()
|
|
4340
|
-
], EmptyStateGoBackComponent.prototype, "iconClass", void 0);
|
|
4341
|
-
__decorate([
|
|
4342
|
-
core.Input()
|
|
4343
|
-
], EmptyStateGoBackComponent.prototype, "title", void 0);
|
|
4344
4402
|
__decorate([
|
|
4345
|
-
core.
|
|
4346
|
-
],
|
|
4403
|
+
core.Output()
|
|
4404
|
+
], DoubleClickDirective.prototype, "onDoubleClick", void 0);
|
|
4347
4405
|
__decorate([
|
|
4348
|
-
core.
|
|
4349
|
-
],
|
|
4350
|
-
|
|
4351
|
-
core.
|
|
4352
|
-
selector:
|
|
4353
|
-
template: "<s-empty-state \n [iconClass]=\"iconClass\" \n [title]=\"title\" \n [description]=\"description\" \n (primaryAction)=\"goBack()\"\n [primaryActionLabel]=\"primaryActionLabel\">\n</s-empty-state>"
|
|
4406
|
+
core.HostListener("click", ["$event"])
|
|
4407
|
+
], DoubleClickDirective.prototype, "onClick", null);
|
|
4408
|
+
DoubleClickDirective = __decorate([
|
|
4409
|
+
core.Directive({
|
|
4410
|
+
selector: '[sDoubleClick]'
|
|
4354
4411
|
})
|
|
4355
|
-
],
|
|
4356
|
-
return
|
|
4412
|
+
], DoubleClickDirective);
|
|
4413
|
+
return DoubleClickDirective;
|
|
4357
4414
|
}());
|
|
4358
4415
|
|
|
4359
|
-
var
|
|
4360
|
-
function
|
|
4416
|
+
var MouseEventsModule = /** @class */ (function () {
|
|
4417
|
+
function MouseEventsModule() {
|
|
4361
4418
|
}
|
|
4362
|
-
|
|
4419
|
+
MouseEventsModule = __decorate([
|
|
4363
4420
|
core.NgModule({
|
|
4364
|
-
imports: [common.CommonModule
|
|
4365
|
-
|
|
4366
|
-
|
|
4367
|
-
|
|
4421
|
+
imports: [common.CommonModule],
|
|
4422
|
+
declarations: [
|
|
4423
|
+
LongPressDirective,
|
|
4424
|
+
DoubleClickDirective
|
|
4425
|
+
],
|
|
4426
|
+
exports: [
|
|
4427
|
+
LongPressDirective,
|
|
4428
|
+
DoubleClickDirective
|
|
4429
|
+
],
|
|
4368
4430
|
})
|
|
4369
|
-
],
|
|
4370
|
-
return
|
|
4431
|
+
], MouseEventsModule);
|
|
4432
|
+
return MouseEventsModule;
|
|
4371
4433
|
}());
|
|
4372
4434
|
|
|
4373
|
-
/**
|
|
4374
|
-
|
|
4375
|
-
|
|
4376
|
-
|
|
4377
|
-
|
|
4378
|
-
|
|
4379
|
-
|
|
4380
|
-
|
|
4381
|
-
|
|
4382
|
-
|
|
4383
|
-
}
|
|
4384
|
-
|
|
4385
|
-
|
|
4386
|
-
|
|
4387
|
-
|
|
4388
|
-
|
|
4389
|
-
|
|
4390
|
-
|
|
4391
|
-
|
|
4392
|
-
|
|
4393
|
-
|
|
4394
|
-
|
|
4395
|
-
|
|
4396
|
-
|
|
4397
|
-
|
|
4398
|
-
|
|
4399
|
-
|
|
4400
|
-
|
|
4401
|
-
|
|
4402
|
-
|
|
4403
|
-
|
|
4404
|
-
|
|
4405
|
-
|
|
4406
|
-
|
|
4407
|
-
|
|
4408
|
-
|
|
4409
|
-
|
|
4410
|
-
|
|
4411
|
-
|
|
4412
|
-
|
|
4413
|
-
|
|
4414
|
-
|
|
4415
|
-
*
|
|
4416
|
-
|
|
4417
|
-
|
|
4418
|
-
|
|
4419
|
-
|
|
4435
|
+
var BignumberInputDirective = /** @class */ (function (_super) {
|
|
4436
|
+
__extends(BignumberInputDirective, _super);
|
|
4437
|
+
function BignumberInputDirective() {
|
|
4438
|
+
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
4439
|
+
_this.precision = 15;
|
|
4440
|
+
_this.scale = 0;
|
|
4441
|
+
_this.decimalSeparator = ",";
|
|
4442
|
+
_this.alignTo = ng2CurrencyMask.AlignmentOptions.LEFT;
|
|
4443
|
+
_this.allowNegative = true;
|
|
4444
|
+
return _this;
|
|
4445
|
+
}
|
|
4446
|
+
BignumberInputDirective_1 = BignumberInputDirective;
|
|
4447
|
+
BignumberInputDirective.prototype.ngOnInit = function () {
|
|
4448
|
+
this.updateVariables();
|
|
4449
|
+
_super.prototype.ngOnInit.call(this);
|
|
4450
|
+
};
|
|
4451
|
+
BignumberInputDirective.prototype.ngOnChanges = function (changes) {
|
|
4452
|
+
var placeholderChange = changes.placeholder && changes.placeholder.currentValue;
|
|
4453
|
+
if (!placeholderChange && this.scale) {
|
|
4454
|
+
this.placeholder = "0" + this.decimalSeparator + "".padEnd(this.scale, "0");
|
|
4455
|
+
}
|
|
4456
|
+
if (changes.scale ||
|
|
4457
|
+
changes.decimalSeparator ||
|
|
4458
|
+
changes.thousandsSeparator ||
|
|
4459
|
+
changes.alignTo ||
|
|
4460
|
+
changes.precision ||
|
|
4461
|
+
changes.allowNegative) {
|
|
4462
|
+
this.updateVariables();
|
|
4463
|
+
}
|
|
4464
|
+
};
|
|
4465
|
+
BignumberInputDirective.prototype.onKeypress = function (event) {
|
|
4466
|
+
var code = event.code;
|
|
4467
|
+
if (code === "Minus" || code === "NumpadSubtract") {
|
|
4468
|
+
if (this.allowNegative) {
|
|
4469
|
+
this.maxLength = this._maxLength + 1;
|
|
4470
|
+
}
|
|
4471
|
+
}
|
|
4472
|
+
else if (code === "Equal" || code === "NumpadAdd") {
|
|
4473
|
+
this.maxLength = this._maxLength;
|
|
4474
|
+
}
|
|
4475
|
+
};
|
|
4476
|
+
/**
|
|
4477
|
+
* Update the options values according to the directive input values.
|
|
4478
|
+
*/
|
|
4479
|
+
BignumberInputDirective.prototype.updateVariables = function () {
|
|
4480
|
+
var _a;
|
|
4481
|
+
this.options = {
|
|
4482
|
+
align: this.alignTo,
|
|
4483
|
+
decimalSeparator: this.decimalSeparator,
|
|
4484
|
+
thousandsSeparator: (_a = this.thousandsSeparator) !== null && _a !== void 0 ? _a : ".",
|
|
4485
|
+
scale: this.scale || 0,
|
|
4486
|
+
prefix: "",
|
|
4487
|
+
suffix: "",
|
|
4488
|
+
allowNegative: this.allowNegative
|
|
4489
|
+
};
|
|
4490
|
+
this.calculateMaxLength();
|
|
4491
|
+
};
|
|
4492
|
+
/**
|
|
4493
|
+
* Responsible to calculate the field maximum length considering the separators.
|
|
4494
|
+
*/
|
|
4495
|
+
BignumberInputDirective.prototype.calculateMaxLength = function () {
|
|
4496
|
+
var _a, _b;
|
|
4497
|
+
var decSepLength = this.decimalSeparator.length;
|
|
4498
|
+
var thoSepLength = (_b = (_a = this.thousandsSeparator) === null || _a === void 0 ? void 0 : _a.length) !== null && _b !== void 0 ? _b : 1;
|
|
4499
|
+
var maxLength = this.precision + (this.scale ? decSepLength : 0);
|
|
4500
|
+
maxLength += Math.ceil((this.precision - (this.scale ? this.scale : 0)) / 3 - 1) * thoSepLength;
|
|
4501
|
+
this._maxLength = maxLength;
|
|
4502
|
+
this.maxLength = maxLength;
|
|
4503
|
+
};
|
|
4504
|
+
var BignumberInputDirective_1;
|
|
4505
|
+
__decorate([
|
|
4506
|
+
core.Input()
|
|
4507
|
+
], BignumberInputDirective.prototype, "precision", void 0);
|
|
4508
|
+
__decorate([
|
|
4509
|
+
core.Input()
|
|
4510
|
+
], BignumberInputDirective.prototype, "scale", void 0);
|
|
4511
|
+
__decorate([
|
|
4512
|
+
core.Input()
|
|
4513
|
+
], BignumberInputDirective.prototype, "decimalSeparator", void 0);
|
|
4514
|
+
__decorate([
|
|
4515
|
+
core.Input()
|
|
4516
|
+
], BignumberInputDirective.prototype, "thousandsSeparator", void 0);
|
|
4517
|
+
__decorate([
|
|
4518
|
+
core.Input()
|
|
4519
|
+
], BignumberInputDirective.prototype, "alignTo", void 0);
|
|
4520
|
+
__decorate([
|
|
4521
|
+
core.Input()
|
|
4522
|
+
], BignumberInputDirective.prototype, "allowNegative", void 0);
|
|
4523
|
+
__decorate([
|
|
4524
|
+
core.Input(),
|
|
4525
|
+
core.HostBinding("attr.placeholder")
|
|
4526
|
+
], BignumberInputDirective.prototype, "placeholder", void 0);
|
|
4527
|
+
__decorate([
|
|
4528
|
+
core.HostBinding("attr.maxLength")
|
|
4529
|
+
], BignumberInputDirective.prototype, "maxLength", void 0);
|
|
4530
|
+
__decorate([
|
|
4531
|
+
core.HostListener("keypress", ["$event"])
|
|
4532
|
+
], BignumberInputDirective.prototype, "onKeypress", null);
|
|
4533
|
+
BignumberInputDirective = BignumberInputDirective_1 = __decorate([
|
|
4534
|
+
core.Directive({
|
|
4535
|
+
selector: "input[sBignumberInput]",
|
|
4536
|
+
providers: [
|
|
4537
|
+
{
|
|
4538
|
+
provide: forms.NG_VALUE_ACCESSOR,
|
|
4539
|
+
useExisting: core.forwardRef(function () { return BignumberInputDirective_1; }),
|
|
4540
|
+
multi: true,
|
|
4541
|
+
},
|
|
4542
|
+
],
|
|
4543
|
+
})
|
|
4544
|
+
], BignumberInputDirective);
|
|
4545
|
+
return BignumberInputDirective;
|
|
4546
|
+
}(ng2CurrencyMask.CurrencyMaskDirective));
|
|
4547
|
+
|
|
4548
|
+
var BignumberInputModule = /** @class */ (function () {
|
|
4549
|
+
function BignumberInputModule() {
|
|
4550
|
+
}
|
|
4551
|
+
BignumberInputModule = __decorate([
|
|
4552
|
+
core.NgModule({
|
|
4553
|
+
imports: [common.CommonModule],
|
|
4554
|
+
declarations: [BignumberInputDirective],
|
|
4555
|
+
exports: [BignumberInputDirective],
|
|
4556
|
+
})
|
|
4557
|
+
], BignumberInputModule);
|
|
4558
|
+
return BignumberInputModule;
|
|
4559
|
+
}());
|
|
4560
|
+
|
|
4561
|
+
var EmptyStateComponent = /** @class */ (function () {
|
|
4562
|
+
function EmptyStateComponent() {
|
|
4563
|
+
this.id = "s-empty-state-" + EmptyStateComponent_1.nextId++;
|
|
4564
|
+
this.iconClass = "fa fa-inbox";
|
|
4565
|
+
this.showPrimaryAction = true;
|
|
4566
|
+
this.showSecondaryAction = true;
|
|
4567
|
+
this.primaryModel = [];
|
|
4568
|
+
this.primaryAction = new core.EventEmitter();
|
|
4569
|
+
this.secondaryAction = new core.EventEmitter();
|
|
4570
|
+
}
|
|
4571
|
+
EmptyStateComponent_1 = EmptyStateComponent;
|
|
4572
|
+
var EmptyStateComponent_1;
|
|
4573
|
+
EmptyStateComponent.nextId = 0;
|
|
4574
|
+
__decorate([
|
|
4575
|
+
core.Input()
|
|
4576
|
+
], EmptyStateComponent.prototype, "id", void 0);
|
|
4577
|
+
__decorate([
|
|
4578
|
+
core.Input()
|
|
4579
|
+
], EmptyStateComponent.prototype, "iconClass", void 0);
|
|
4580
|
+
__decorate([
|
|
4581
|
+
core.Input()
|
|
4582
|
+
], EmptyStateComponent.prototype, "title", void 0);
|
|
4583
|
+
__decorate([
|
|
4584
|
+
core.Input()
|
|
4585
|
+
], EmptyStateComponent.prototype, "description", void 0);
|
|
4586
|
+
__decorate([
|
|
4587
|
+
core.Input()
|
|
4588
|
+
], EmptyStateComponent.prototype, "showPrimaryAction", void 0);
|
|
4589
|
+
__decorate([
|
|
4590
|
+
core.Input()
|
|
4591
|
+
], EmptyStateComponent.prototype, "showSecondaryAction", void 0);
|
|
4592
|
+
__decorate([
|
|
4593
|
+
core.Input()
|
|
4594
|
+
], EmptyStateComponent.prototype, "primaryActionLabel", void 0);
|
|
4595
|
+
__decorate([
|
|
4596
|
+
core.Input()
|
|
4597
|
+
], EmptyStateComponent.prototype, "secondaryActionLabel", void 0);
|
|
4598
|
+
__decorate([
|
|
4599
|
+
core.Input()
|
|
4600
|
+
], EmptyStateComponent.prototype, "primaryModel", void 0);
|
|
4601
|
+
__decorate([
|
|
4602
|
+
core.Output()
|
|
4603
|
+
], EmptyStateComponent.prototype, "primaryAction", void 0);
|
|
4604
|
+
__decorate([
|
|
4605
|
+
core.Output()
|
|
4606
|
+
], EmptyStateComponent.prototype, "secondaryAction", void 0);
|
|
4607
|
+
EmptyStateComponent = EmptyStateComponent_1 = __decorate([
|
|
4608
|
+
core.Component({
|
|
4609
|
+
selector: "s-empty-state",
|
|
4610
|
+
template: "<div [id]=\"id\" class=\"container\">\n <div [id]=\"id + '-icon'\" class=\"icon\">\n <i [attr.class]=\"iconClass ? iconClass : 'fa fa-cogs'\" aria-hidden=\"true\"></i>\n </div>\n <div [id]=\"id + '-title'\" class=\"title\">{{title}}</div>\n <div [id]=\"id + '-description'\" class=\"description\" *ngIf=\"description\">\n <p>{{description}}</p>\n </div>\n <div [id]=\"id + '-actions'\" class=\"actions\" *ngIf=\"showPrimaryAction && primaryActionLabel\">\n <s-button [id]=\"id + '-primary-action'\" type=\"button\" [label]=\"primaryActionLabel\"\n [model]=\"primaryModel\" (click)=\"primaryAction.next()\"></s-button>\n <s-button [id]=\"id + '-secondary-action'\" *ngIf=\"showSecondaryAction && secondaryActionLabel\" id=\"secondaryAction\" type=\"button\"\n [label]=\"secondaryActionLabel\" priority=\"link\" (click)=\"secondaryAction.next()\"></s-button>\n </div>\n</div>",
|
|
4611
|
+
styles: [".container{width:100%;text-align:center}.title{font-weight:700;margin-bottom:10px}.description{margin-bottom:15px;color:#999;padding:0 20px;text-align:center}.description>p{margin:auto;max-width:400px;max-height:80px;overflow:hidden}.icon{color:#d8d8d8;font-size:6em}.actions{text-align:center;width:100%}"]
|
|
4612
|
+
})
|
|
4613
|
+
], EmptyStateComponent);
|
|
4614
|
+
return EmptyStateComponent;
|
|
4615
|
+
}());
|
|
4616
|
+
|
|
4617
|
+
var EmptyStateGoBackComponent = /** @class */ (function () {
|
|
4618
|
+
function EmptyStateGoBackComponent(cookieService) {
|
|
4619
|
+
this.cookieService = cookieService;
|
|
4620
|
+
this.iconClass = "fa fa-exclamation-triangle";
|
|
4621
|
+
}
|
|
4622
|
+
EmptyStateGoBackComponent.prototype.goBack = function () {
|
|
4623
|
+
var portalUrl = this.cookieService.get("com.senior.portal.url");
|
|
4624
|
+
window.open(portalUrl, "_top");
|
|
4625
|
+
};
|
|
4626
|
+
EmptyStateGoBackComponent.nextId = 0;
|
|
4627
|
+
EmptyStateGoBackComponent.ctorParameters = function () { return [
|
|
4628
|
+
{ type: ngxCookieService.CookieService }
|
|
4629
|
+
]; };
|
|
4630
|
+
__decorate([
|
|
4631
|
+
core.Input()
|
|
4632
|
+
], EmptyStateGoBackComponent.prototype, "iconClass", void 0);
|
|
4633
|
+
__decorate([
|
|
4634
|
+
core.Input()
|
|
4635
|
+
], EmptyStateGoBackComponent.prototype, "title", void 0);
|
|
4636
|
+
__decorate([
|
|
4637
|
+
core.Input()
|
|
4638
|
+
], EmptyStateGoBackComponent.prototype, "description", void 0);
|
|
4639
|
+
__decorate([
|
|
4640
|
+
core.Input()
|
|
4641
|
+
], EmptyStateGoBackComponent.prototype, "primaryActionLabel", void 0);
|
|
4642
|
+
EmptyStateGoBackComponent = __decorate([
|
|
4643
|
+
core.Component({
|
|
4644
|
+
selector: "s-empty-state-go-back",
|
|
4645
|
+
template: "<s-empty-state \n [iconClass]=\"iconClass\" \n [title]=\"title\" \n [description]=\"description\" \n (primaryAction)=\"goBack()\"\n [primaryActionLabel]=\"primaryActionLabel\">\n</s-empty-state>"
|
|
4646
|
+
})
|
|
4647
|
+
], EmptyStateGoBackComponent);
|
|
4648
|
+
return EmptyStateGoBackComponent;
|
|
4649
|
+
}());
|
|
4650
|
+
|
|
4651
|
+
var EmptyStateModule = /** @class */ (function () {
|
|
4652
|
+
function EmptyStateModule() {
|
|
4653
|
+
}
|
|
4654
|
+
EmptyStateModule = __decorate([
|
|
4655
|
+
core.NgModule({
|
|
4656
|
+
imports: [common.CommonModule, ButtonModule],
|
|
4657
|
+
providers: [ngxCookieService.CookieService],
|
|
4658
|
+
declarations: [EmptyStateComponent, EmptyStateGoBackComponent],
|
|
4659
|
+
exports: [EmptyStateComponent, EmptyStateGoBackComponent],
|
|
4660
|
+
})
|
|
4661
|
+
], EmptyStateModule);
|
|
4662
|
+
return EmptyStateModule;
|
|
4663
|
+
}());
|
|
4664
|
+
|
|
4665
|
+
/**
|
|
4666
|
+
* Formats a JSON response to a JS object
|
|
4667
|
+
* @param response The response to format
|
|
4668
|
+
* @returns A JS object based on the response's body
|
|
4669
|
+
*/
|
|
4670
|
+
function formatJsonResponse(response) {
|
|
4671
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
4672
|
+
return __generator(this, function (_a) {
|
|
4673
|
+
return [2 /*return*/, response.json()];
|
|
4674
|
+
});
|
|
4675
|
+
});
|
|
4676
|
+
}
|
|
4677
|
+
|
|
4678
|
+
/**
|
|
4679
|
+
* Formats a Blob response to a JS object
|
|
4680
|
+
* @param response The response to format
|
|
4681
|
+
* @returns A JS object based on the response's body
|
|
4682
|
+
*/
|
|
4683
|
+
function formatBlobResponse(response) {
|
|
4684
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
4685
|
+
var textResponse;
|
|
4686
|
+
return __generator(this, function (_a) {
|
|
4687
|
+
switch (_a.label) {
|
|
4688
|
+
case 0: return [4 /*yield*/, response.blob()];
|
|
4689
|
+
case 1: return [4 /*yield*/, (_a.sent()).text()];
|
|
4690
|
+
case 2:
|
|
4691
|
+
textResponse = _a.sent();
|
|
4692
|
+
return [2 /*return*/, JSON.parse(textResponse)];
|
|
4693
|
+
}
|
|
4694
|
+
});
|
|
4695
|
+
});
|
|
4696
|
+
}
|
|
4697
|
+
|
|
4698
|
+
/**
|
|
4699
|
+
* Custom HttpClient for cases when is not possible to use the Angular's HttpClient
|
|
4700
|
+
*/
|
|
4701
|
+
var CustomHttpClient = /** @class */ (function () {
|
|
4702
|
+
function CustomHttpClient() {
|
|
4703
|
+
}
|
|
4704
|
+
/**
|
|
4705
|
+
* Executes a Http Get
|
|
4706
|
+
* @param url Url to execute the Get on
|
|
4707
|
+
* @param init Optional additional configs
|
|
4708
|
+
* @returns Whether a Promise<T> on request success or an error in request fail
|
|
4709
|
+
*/
|
|
4710
|
+
CustomHttpClient.GET = function (url, init) {
|
|
4711
|
+
if (init === void 0) { init = {}; }
|
|
4420
4712
|
return __awaiter(this, void 0, void 0, function () {
|
|
4421
4713
|
var response;
|
|
4422
4714
|
return __generator(this, function (_a) {
|
|
@@ -4766,12 +5058,7 @@
|
|
|
4766
5058
|
this.READ_PERMISSION = FileUploadPermissions.Read;
|
|
4767
5059
|
this.REMOVE_PERMISSION = FileUploadPermissions.Remove;
|
|
4768
5060
|
this.id = "s-file-upload-" + FileUploadComponent_1.nextId++;
|
|
4769
|
-
this.chooseLabel = "Anexar arquivos";
|
|
4770
|
-
this.removeLabel = "Remover";
|
|
4771
|
-
this.cancelLabel = "Cancelar";
|
|
4772
|
-
this.successTooltip = "Arquivo anexado com sucesso";
|
|
4773
5061
|
this.supportedExtensions = [];
|
|
4774
|
-
this.ariaLabelProgress = "Carregando arquivo";
|
|
4775
5062
|
this.disabled = false;
|
|
4776
5063
|
this.showFileUploadDate = false;
|
|
4777
5064
|
this.permissions = ALL_PERMISSIONS;
|
|
@@ -5028,7 +5315,7 @@
|
|
|
5028
5315
|
FileUploadComponent = FileUploadComponent_1 = __decorate([
|
|
5029
5316
|
core.Component({
|
|
5030
5317
|
selector: "s-file-upload",
|
|
5031
|
-
template: "<div\n [id]=\"id\"\n class=\"s-fileupload\">\n <div class=\"s-fileupload-choose\">\n <input\n #inputUpload\n [id]=\"id+'input-upload'\"\n type=\"file\"\n name=\"file\"\n [accept]=\"accept\"\n [multiple]=\"multiple\"\n (change)=\"onFileSelect($event.dataTransfer\n ? $event.dataTransfer.files\n : $event.target.files)\"> \n <s-button\n *ngIf=\"permissions.includes(ADD_PERMISSION)\"\n [id]=\"id + 'upload-button'\"\n [label]=\"chooseLabel\"\n (onClick)=\"inputUpload.click()\"\n priority=\"primary\"\n [disabled]=\"disabled || !!formGroup?.disabled\"\n [auxiliary]=\"false\">\n </s-button>\n </div>\n\n <section\n *ngIf=\"files.length\" \n [id]=\"id + 'fileupload-list'\"\n class=\"s-fileupload-list\"\n role=\"grid\">\n <ng-container *ngFor=\"let file of files; let i = index\">\n <div\n class=\"s-fileupload-list-file\"\n role=\"row\">\n <div\n [id]=\"id + '-file-' + i + '-name'\"\n class=\"s-fileupload-list-file-name\"\n role=\"gridcell\">\n <ng-container *ngTemplateOutlet=\"permissions.includes(READ_PERMISSION) && file.savedFile || file.progress === 100\n ? descriptionUrl\n : description; context: {\n $implicit: file,\n index: i\n }\">\n </ng-container>\n <span *ngIf=\"modifiedDate\" class=\"s-fileupload-list-file-name-date\">{{ modifiedDate }}</span>\n </div>\n <div\n class=\"s-fileupload-list-file-status\"\n role=\"gridcell\">\n <p-progressBar\n *ngIf=\"file.isUploading && !isSmallDevice\"\n [style]=\"{ 'width': '250px', 'background-color': '#d8d8d8', 'border-radius': '0px', 'height': '14px'}\"\n [value]=\"file.progress\"\n [showValue]=\"false\"\n role=\"alert\"\n [attr.aria-label]=\"ariaLabelProgress\">\n </p-progressBar>\n <span\n *ngIf=\"file.isUploading && isSmallDevice\" \n [id]=\"id + '-file-' + i + '-spin'\"\n class=\"fas fa-circle-notch fa-spin\"\n [attr.aria-label]=\"ariaLabelProgress\">\n </span>\n <span\n *ngIf=\"!file.isUploading && !file.error && file.progress === 100\"\n [id]=\"id + '-file-' + i + '-check'\"\n class=\"fas fa-check\"\n role=\"alert\"\n [attr.aria-label]=\"ariaLabelSuccess || successTooltip\"\n [pTooltip]=\"successTooltip\"\n tooltipPosition=\"top\"\n showDelay=\"500\"\n [appendTo]=\"'body'\">\n </span>\n <span\n *ngIf=\"file.error?.message\" \n [id]=\"id + '-file-' + i + '-error'\"\n class=\"fas fa-times\"\n role=\"alert\"\n [pTooltip]=\"file.error?.message\"\n tooltipPosition=\"top\"\n showDelay=\"500\"\n [appendTo]=\"'body'\">\n </span>\n </div>\n <div\n class=\"s-fileupload-list-file-actions\"\n role=\"gridcell\">\n <a\n *ngIf=\"file.isUploading\"\n [id]=\"id + '-file-' + i + '-cancel'\"\n class=\"s-fileupload-list-file-actions-action\"\n (click)=\"onCancelUpload(i)\">\n {{cancelLabel}}\n </a>\n <a\n *ngIf=\"permissions.includes(REMOVE_PERMISSION) && !file.isUploading && !(disabled || !!formGroup?.disabled)\"\n role=\"button\"\n tabindex=\"0\"\n [id]=\"id + '-file-' + i + '-remove'\"\n class=\"s-fileupload-list-file-actions-action\"\n (click)=\"onRemoveFile(file)\"\n [attr.aria-label]=\"ariaLabelRemove || removeLabel\">\n {{removeLabel}}\n </a>\n </div>\n </div>\n </ng-container>\n </section>\n</div>\n\n<ng-template\n #descriptionUrl\n let-file\n let-i = index>\n <a\n [id]=\"id + '-file-' + i + '-name-link'\"\n tabindex=\"0\"\n (click)=\"onDowloadFile(i)\"\n [attr.aria-label]=\"ariaLabelFileName || file.name\">{{file.name}}\n </a>\n <a\n style=\"display: none;\"\n [href]=\"file.objectURL\"\n target=\"_blank\"\n download\n #anchor>\n </a>\n</ng-template>\n\n<ng-template\n #description\n let-file>\n <span\n tabindex=\"0\"\n [attr.aria-label]=\"ariaLabelFileName || file.name\">\n {{file.name}}\n </span>\n</ng-template>\n",
|
|
5318
|
+
template: "<div\n [id]=\"id\"\n class=\"s-fileupload\">\n <div class=\"s-fileupload-choose\">\n <input\n #inputUpload\n [id]=\"id+'input-upload'\"\n type=\"file\"\n name=\"file\"\n [accept]=\"accept\"\n [multiple]=\"multiple\"\n (change)=\"onFileSelect($event.dataTransfer\n ? $event.dataTransfer.files\n : $event.target.files)\"> \n <s-button\n *ngIf=\"permissions.includes(ADD_PERMISSION)\"\n [id]=\"id + 'upload-button'\"\n [label]=\"chooseLabel || 'platform.angular_components.attach_files' | translate\"\n (onClick)=\"inputUpload.click()\"\n priority=\"primary\"\n [disabled]=\"disabled || !!formGroup?.disabled\"\n [auxiliary]=\"false\">\n </s-button>\n </div>\n\n <section\n *ngIf=\"files.length\" \n [id]=\"id + 'fileupload-list'\"\n class=\"s-fileupload-list\"\n role=\"grid\">\n <ng-container *ngFor=\"let file of files; let i = index\">\n <div\n class=\"s-fileupload-list-file\"\n role=\"row\">\n <div\n [id]=\"id + '-file-' + i + '-name'\"\n class=\"s-fileupload-list-file-name\"\n role=\"gridcell\">\n <ng-container *ngTemplateOutlet=\"permissions.includes(READ_PERMISSION) && file.savedFile || file.progress === 100\n ? descriptionUrl\n : description; context: {\n $implicit: file,\n index: i\n }\">\n </ng-container>\n <span *ngIf=\"modifiedDate\" class=\"s-fileupload-list-file-name-date\">{{ modifiedDate }}</span>\n </div>\n <div\n class=\"s-fileupload-list-file-status\"\n role=\"gridcell\">\n <p-progressBar\n *ngIf=\"file.isUploading && !isSmallDevice\"\n [style]=\"{ 'width': '250px', 'background-color': '#d8d8d8', 'border-radius': '0px', 'height': '14px'}\"\n [value]=\"file.progress\"\n [showValue]=\"false\"\n role=\"alert\"\n [attr.aria-label]=\"ariaLabelProgress || 'platform.angular_components.loading_file' | translate\">\n </p-progressBar>\n <span\n *ngIf=\"file.isUploading && isSmallDevice\" \n [id]=\"id + '-file-' + i + '-spin'\"\n class=\"fas fa-circle-notch fa-spin\"\n [attr.aria-label]=\"ariaLabelProgress || 'platform.angular_components.loading_file' | translate\">\n </span>\n <span\n *ngIf=\"!file.isUploading && !file.error && file.progress === 100\"\n [id]=\"id + '-file-' + i + '-check'\"\n class=\"fas fa-check\"\n role=\"alert\"\n [attr.aria-label]=\"ariaLabelSuccess || successTooltip || 'platform.angular_components.file_attached_successfully' | translate\"\n [pTooltip]=\"successTooltip || 'platform.angular_components.file_attached_successfully' | translate\"\n tooltipPosition=\"top\"\n showDelay=\"500\"\n [appendTo]=\"'body'\">\n </span>\n <span\n *ngIf=\"file.error?.message\" \n [id]=\"id + '-file-' + i + '-error'\"\n class=\"fas fa-times\"\n role=\"alert\"\n [pTooltip]=\"file.error?.message\"\n tooltipPosition=\"top\"\n showDelay=\"500\"\n [appendTo]=\"'body'\">\n </span>\n </div>\n <div\n class=\"s-fileupload-list-file-actions\"\n role=\"gridcell\">\n <a\n *ngIf=\"file.isUploading\"\n [id]=\"id + '-file-' + i + '-cancel'\"\n class=\"s-fileupload-list-file-actions-action\"\n (click)=\"onCancelUpload(i)\">\n {{ cancelLabel || 'platform.angular_components.cancel' | translate }}\n </a>\n <a\n *ngIf=\"permissions.includes(REMOVE_PERMISSION) && !file.isUploading && !(disabled || !!formGroup?.disabled)\"\n role=\"button\"\n tabindex=\"0\"\n [id]=\"id + '-file-' + i + '-remove'\"\n class=\"s-fileupload-list-file-actions-action\"\n (click)=\"onRemoveFile(file)\"\n [attr.aria-label]=\"ariaLabelRemove || removeLabel || 'platform.angular_components.remove' | translate\">\n {{ removeLabel || 'platform.angular_components.remove' | translate }}\n </a>\n </div>\n </div>\n </ng-container>\n </section>\n</div>\n\n<ng-template\n #descriptionUrl\n let-file\n let-i = index>\n <a\n [id]=\"id + '-file-' + i + '-name-link'\"\n tabindex=\"0\"\n (click)=\"onDowloadFile(i)\"\n [attr.aria-label]=\"ariaLabelFileName || file.name\">{{file.name}}\n </a>\n <a\n style=\"display: none;\"\n [href]=\"file.objectURL\"\n target=\"_blank\"\n download\n #anchor>\n </a>\n</ng-template>\n\n<ng-template\n #description\n let-file>\n <span\n tabindex=\"0\"\n [attr.aria-label]=\"ariaLabelFileName || file.name\">\n {{file.name}}\n </span>\n</ng-template>\n",
|
|
5032
5319
|
styles: [".s-fileupload .s-fileupload-choose{position:relative;margin:15px 0;width:-webkit-max-content;width:max-content}.s-fileupload input[type=file]{display:none}.s-fileupload-list{border:1px solid #ccc}.s-fileupload-list-file:not(:first-child){border-top:1px solid #ccc}.s-fileupload-list .s-fileupload-list-file{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap;-ms-flex-pack:justify;justify-content:space-between;padding:15px}.s-fileupload-list .s-fileupload-list-file .s-fileupload-list-file-name{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-item-align:center;align-self:center;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.s-fileupload-list .s-fileupload-list-file .s-fileupload-list-file-name .s-fileupload-list-file-name-date{font-size:.75rem;color:#999}.s-fileupload-list .s-fileupload-list-file .s-fileupload-list-file-name>a{cursor:pointer;text-decoration:none}.s-fileupload-list .s-fileupload-list-file .s-fileupload-list-file-status{-ms-flex-item-align:center;-ms-grid-row-align:center;align-self:center}.s-fileupload-list .s-fileupload-list-file .fas.fa-circle-notch{color:#d8d8d8;font-size:12px}.s-fileupload-list .s-fileupload-list-file .fas.fa-check{color:#0c9348;font-size:12px}.s-fileupload-list .s-fileupload-list-file .fas.fa-times{color:#c13018;font-size:12px}.s-fileupload-list .s-fileupload-list-file .s-fileupload-list-file-actions{margin-top:15px;-ms-flex-item-align:center;-ms-grid-row-align:center;align-self:center;width:100%}.s-fileupload-list .s-fileupload-list-file .s-fileupload-list-file-actions a.s-fileupload-list-file-actions-action{text-decoration:none;color:#428bca}.s-fileupload-list .s-fileupload-list-file .s-fileupload-list-file-actions a.s-fileupload-list-file-actions-action :focus,.s-fileupload-list .s-fileupload-list-file .s-fileupload-list-file-actions a.s-fileupload-list-file-actions-action :visited,.s-fileupload-list .s-fileupload-list-file .s-fileupload-list-file-actions a.s-fileupload-list-file-actions-action:hover{text-decoration:none}@media (min-width:768px){.s-fileupload-list .s-fileupload-list-file{-ms-flex-wrap:nowrap;flex-wrap:nowrap}.s-fileupload-list .s-fileupload-list-file .s-fileupload-list-file-name{width:auto;-ms-flex-positive:2;flex-grow:2}.s-fileupload-list .s-fileupload-list-file .s-fileupload-list-file-status{margin:0 15px}.s-fileupload-list .s-fileupload-list-file .s-fileupload-list-file-actions{margin:0;width:auto}}"]
|
|
5033
5320
|
})
|
|
5034
5321
|
], FileUploadComponent);
|
|
@@ -5046,6 +5333,7 @@
|
|
|
5046
5333
|
ButtonModule,
|
|
5047
5334
|
tooltip.TooltipModule,
|
|
5048
5335
|
progressbar.ProgressBarModule,
|
|
5336
|
+
core$1.TranslateModule,
|
|
5049
5337
|
],
|
|
5050
5338
|
providers: [FileUploadService],
|
|
5051
5339
|
exports: [FileUploadComponent],
|
|
@@ -5410,294 +5698,319 @@
|
|
|
5410
5698
|
return MaskFormatterModule;
|
|
5411
5699
|
}());
|
|
5412
5700
|
|
|
5413
|
-
|
|
5414
|
-
|
|
5415
|
-
|
|
5416
|
-
|
|
5417
|
-
|
|
5418
|
-
|
|
5419
|
-
|
|
5420
|
-
|
|
5421
|
-
|
|
5422
|
-
|
|
5701
|
+
|
|
5702
|
+
(function (PasswordStrengths) {
|
|
5703
|
+
PasswordStrengths["VeryWeak"] = "Very_weak";
|
|
5704
|
+
PasswordStrengths["Weak"] = "weak";
|
|
5705
|
+
PasswordStrengths["Medium"] = "medium";
|
|
5706
|
+
PasswordStrengths["Strong"] = "strong";
|
|
5707
|
+
})(exports.PasswordStrengths || (exports.PasswordStrengths = {}));
|
|
5708
|
+
|
|
5709
|
+
|
|
5710
|
+
(function (PasswordStrengthPositions) {
|
|
5711
|
+
PasswordStrengthPositions["Top"] = "top";
|
|
5712
|
+
PasswordStrengthPositions["Right"] = "right";
|
|
5713
|
+
PasswordStrengthPositions["Left"] = "left";
|
|
5714
|
+
})(exports.PasswordStrengthPositions || (exports.PasswordStrengthPositions = {}));
|
|
5715
|
+
|
|
5716
|
+
var PasswordStrengthComponent = /** @class */ (function () {
|
|
5717
|
+
function PasswordStrengthComponent() {
|
|
5718
|
+
this.weakTitle = "Fraca";
|
|
5719
|
+
this.mediumTitle = "Médio";
|
|
5720
|
+
this.strongTitle = "Forte";
|
|
5721
|
+
this.position = exports.PasswordStrengthPositions.Right;
|
|
5722
|
+
this.left = 0;
|
|
5723
|
+
this.top = 0;
|
|
5724
|
+
this.visible = false;
|
|
5423
5725
|
}
|
|
5424
|
-
|
|
5425
|
-
|
|
5426
|
-
this.updateVariables();
|
|
5427
|
-
_super.prototype.ngOnInit.call(this);
|
|
5726
|
+
PasswordStrengthComponent.prototype.ngOnInit = function () {
|
|
5727
|
+
this.title = this.weakTitle;
|
|
5428
5728
|
};
|
|
5429
|
-
|
|
5430
|
-
var
|
|
5431
|
-
|
|
5432
|
-
|
|
5433
|
-
|
|
5434
|
-
|
|
5435
|
-
|
|
5436
|
-
|
|
5437
|
-
|
|
5438
|
-
|
|
5439
|
-
|
|
5440
|
-
|
|
5729
|
+
PasswordStrengthComponent.prototype.setPasswordStrengthPosition = function () {
|
|
5730
|
+
var passwordStrength = document.querySelector(".password-strength");
|
|
5731
|
+
switch (this.position) {
|
|
5732
|
+
case exports.PasswordStrengthPositions.Top:
|
|
5733
|
+
passwordStrength.classList.add("password-strength--top");
|
|
5734
|
+
break;
|
|
5735
|
+
case exports.PasswordStrengthPositions.Right:
|
|
5736
|
+
passwordStrength.classList.add("password-strength--right");
|
|
5737
|
+
break;
|
|
5738
|
+
case exports.PasswordStrengthPositions.Left:
|
|
5739
|
+
passwordStrength.classList.add("password-strength--left");
|
|
5740
|
+
break;
|
|
5441
5741
|
}
|
|
5442
5742
|
};
|
|
5443
|
-
|
|
5444
|
-
var
|
|
5445
|
-
|
|
5446
|
-
|
|
5447
|
-
|
|
5448
|
-
|
|
5449
|
-
|
|
5450
|
-
|
|
5451
|
-
|
|
5743
|
+
PasswordStrengthComponent.prototype.updateIndicators = function (passwordStrength) {
|
|
5744
|
+
var strengthIndicator1 = document.querySelector("#strength-indicator-1");
|
|
5745
|
+
var strengthIndicator2 = document.querySelector("#strength-indicator-2");
|
|
5746
|
+
var strengthIndicator3 = document.querySelector("#strength-indicator-3");
|
|
5747
|
+
var onIndicators = [];
|
|
5748
|
+
var indicators = [
|
|
5749
|
+
strengthIndicator1,
|
|
5750
|
+
strengthIndicator2,
|
|
5751
|
+
strengthIndicator3,
|
|
5752
|
+
];
|
|
5753
|
+
var strengthClass;
|
|
5754
|
+
switch (passwordStrength) {
|
|
5755
|
+
case exports.PasswordStrengths.VeryWeak:
|
|
5756
|
+
this.title = this.weakTitle;
|
|
5757
|
+
break;
|
|
5758
|
+
case exports.PasswordStrengths.Weak:
|
|
5759
|
+
this.title = this.weakTitle;
|
|
5760
|
+
strengthClass = "strength-indicator--weak";
|
|
5761
|
+
onIndicators.push(strengthIndicator1);
|
|
5762
|
+
break;
|
|
5763
|
+
case exports.PasswordStrengths.Medium:
|
|
5764
|
+
this.title = this.mediumTitle;
|
|
5765
|
+
strengthClass = "strength-indicator--medium";
|
|
5766
|
+
onIndicators.push(strengthIndicator1);
|
|
5767
|
+
onIndicators.push(strengthIndicator2);
|
|
5768
|
+
break;
|
|
5769
|
+
case exports.PasswordStrengths.Strong:
|
|
5770
|
+
this.title = this.strongTitle;
|
|
5771
|
+
strengthClass = "strength-indicator--strong";
|
|
5772
|
+
onIndicators.push(strengthIndicator1);
|
|
5773
|
+
onIndicators.push(strengthIndicator2);
|
|
5774
|
+
onIndicators.push(strengthIndicator3);
|
|
5775
|
+
break;
|
|
5452
5776
|
}
|
|
5777
|
+
indicators.forEach(function (indicator) {
|
|
5778
|
+
indicator.classList.remove("strength-indicator--weak", "strength-indicator--medium", "strength-indicator--strong");
|
|
5779
|
+
});
|
|
5780
|
+
onIndicators.forEach(function (indicator) {
|
|
5781
|
+
indicator.classList.add(strengthClass);
|
|
5782
|
+
});
|
|
5453
5783
|
};
|
|
5454
|
-
/**
|
|
5455
|
-
* Update the options values according to the directive input values.
|
|
5456
|
-
*/
|
|
5457
|
-
BignumberInputDirective.prototype.updateVariables = function () {
|
|
5458
|
-
var _a;
|
|
5459
|
-
this.options = {
|
|
5460
|
-
align: this.alignTo,
|
|
5461
|
-
decimalSeparator: this.decimalSeparator,
|
|
5462
|
-
thousandsSeparator: (_a = this.thousandsSeparator) !== null && _a !== void 0 ? _a : ".",
|
|
5463
|
-
scale: this.scale || 0,
|
|
5464
|
-
prefix: "",
|
|
5465
|
-
suffix: "",
|
|
5466
|
-
allowNegative: this.allowNegative
|
|
5467
|
-
};
|
|
5468
|
-
this.calculateMaxLength();
|
|
5469
|
-
};
|
|
5470
|
-
/**
|
|
5471
|
-
* Responsible to calculate the field maximum length considering the separators.
|
|
5472
|
-
*/
|
|
5473
|
-
BignumberInputDirective.prototype.calculateMaxLength = function () {
|
|
5474
|
-
var _a, _b;
|
|
5475
|
-
var decSepLength = this.decimalSeparator.length;
|
|
5476
|
-
var thoSepLength = (_b = (_a = this.thousandsSeparator) === null || _a === void 0 ? void 0 : _a.length) !== null && _b !== void 0 ? _b : 1;
|
|
5477
|
-
var maxLength = this.precision + (this.scale ? decSepLength : 0);
|
|
5478
|
-
maxLength += Math.ceil((this.precision - (this.scale ? this.scale : 0)) / 3 - 1) * thoSepLength;
|
|
5479
|
-
this._maxLength = maxLength;
|
|
5480
|
-
this.maxLength = maxLength;
|
|
5481
|
-
};
|
|
5482
|
-
var BignumberInputDirective_1;
|
|
5483
5784
|
__decorate([
|
|
5484
5785
|
core.Input()
|
|
5485
|
-
],
|
|
5486
|
-
__decorate([
|
|
5487
|
-
core.Input()
|
|
5488
|
-
], BignumberInputDirective.prototype, "scale", void 0);
|
|
5489
|
-
__decorate([
|
|
5490
|
-
core.Input()
|
|
5491
|
-
], BignumberInputDirective.prototype, "decimalSeparator", void 0);
|
|
5786
|
+
], PasswordStrengthComponent.prototype, "weakTitle", void 0);
|
|
5492
5787
|
__decorate([
|
|
5493
5788
|
core.Input()
|
|
5494
|
-
],
|
|
5789
|
+
], PasswordStrengthComponent.prototype, "mediumTitle", void 0);
|
|
5495
5790
|
__decorate([
|
|
5496
5791
|
core.Input()
|
|
5497
|
-
],
|
|
5792
|
+
], PasswordStrengthComponent.prototype, "strongTitle", void 0);
|
|
5498
5793
|
__decorate([
|
|
5499
5794
|
core.Input()
|
|
5500
|
-
],
|
|
5501
|
-
__decorate([
|
|
5502
|
-
core.
|
|
5503
|
-
|
|
5504
|
-
|
|
5505
|
-
__decorate([
|
|
5506
|
-
core.HostBinding("attr.maxLength")
|
|
5507
|
-
], BignumberInputDirective.prototype, "maxLength", void 0);
|
|
5508
|
-
__decorate([
|
|
5509
|
-
core.HostListener("keypress", ["$event"])
|
|
5510
|
-
], BignumberInputDirective.prototype, "onKeypress", null);
|
|
5511
|
-
BignumberInputDirective = BignumberInputDirective_1 = __decorate([
|
|
5512
|
-
core.Directive({
|
|
5513
|
-
selector: "input[sBignumberInput]",
|
|
5514
|
-
providers: [
|
|
5515
|
-
{
|
|
5516
|
-
provide: forms.NG_VALUE_ACCESSOR,
|
|
5517
|
-
useExisting: core.forwardRef(function () { return BignumberInputDirective_1; }),
|
|
5518
|
-
multi: true,
|
|
5519
|
-
},
|
|
5520
|
-
],
|
|
5521
|
-
})
|
|
5522
|
-
], BignumberInputDirective);
|
|
5523
|
-
return BignumberInputDirective;
|
|
5524
|
-
}(ng2CurrencyMask.CurrencyMaskDirective));
|
|
5525
|
-
|
|
5526
|
-
var BignumberInputModule = /** @class */ (function () {
|
|
5527
|
-
function BignumberInputModule() {
|
|
5528
|
-
}
|
|
5529
|
-
BignumberInputModule = __decorate([
|
|
5530
|
-
core.NgModule({
|
|
5531
|
-
imports: [common.CommonModule],
|
|
5532
|
-
declarations: [BignumberInputDirective],
|
|
5533
|
-
exports: [BignumberInputDirective],
|
|
5795
|
+
], PasswordStrengthComponent.prototype, "description", void 0);
|
|
5796
|
+
PasswordStrengthComponent = __decorate([
|
|
5797
|
+
core.Component({
|
|
5798
|
+
template: "<div\n class=\"password-strength\"\n [ngStyle]=\"{\n 'left': left + 'px',\n 'top': top + 'px'\n }\"\n [ngClass]=\"['password-strength--' + position]\">\n <span class=\"title\">{{ title }}</span>\n <div class=\"strength-indicators\">\n <span class=\"strength-indicator\" id=\"strength-indicator-1\"></span>\n <span class=\"strength-indicator\" id=\"strength-indicator-2\"></span>\n <span class=\"strength-indicator\" id=\"strength-indicator-3\"></span>\n </div>\n <span class=\"content\">{{ description }}</span>\n</div>",
|
|
5799
|
+
styles: [".password-strength{position:fixed;transform:translateX(-50%);background-color:#fff;border-radius:2px;box-shadow:0 0 5px 1px #ccc;padding:10px;width:232px;z-index:99999}.password-strength::after{content:\"\";position:absolute}.password-strength .title{font-family:\"Open Sans\",sans-serif;font-size:14px;font-weight:700;line-height:150%}.password-strength .strength-indicators{display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;padding:10px 0}.password-strength .strength-indicators .strength-indicator{background-color:#ccc;border-radius:2px;display:inline-block;height:3px;width:64px}.password-strength .strength-indicators .strength-indicator--weak{background-color:#c13018}.password-strength .strength-indicators .strength-indicator--medium{background-color:#fcbf10}.password-strength .strength-indicators .strength-indicator--strong{background-color:#0c9348}.password-strength .content{font-family:\"Open Sans\",sans-serif;font-size:12px;font-weight:400;line-height:150%}.password-strength--top{transform:translate(-50%,-100%)}.password-strength--top::after{top:100%;right:calc(50% - 4px);border-left:8px solid transparent;border-right:8px solid transparent;border-top:8px solid #fff}.password-strength--right{transform:translateY(-50%)}.password-strength--right::after{bottom:calc(50% - 8px);left:-8px;border-top:8px solid transparent;border-right:8px solid #fff;border-bottom:8px solid transparent}.password-strength--left{transform:translate(-100%,-50%)}.password-strength--left::after{bottom:calc(50% - 8px);right:-8px;border-top:8px solid transparent;border-left:8px solid #fff;border-bottom:8px solid transparent}"]
|
|
5534
5800
|
})
|
|
5535
|
-
],
|
|
5536
|
-
return
|
|
5801
|
+
], PasswordStrengthComponent);
|
|
5802
|
+
return PasswordStrengthComponent;
|
|
5537
5803
|
}());
|
|
5538
5804
|
|
|
5539
|
-
var
|
|
5540
|
-
function
|
|
5541
|
-
|
|
5542
|
-
this.
|
|
5543
|
-
this.
|
|
5544
|
-
this.
|
|
5545
|
-
this.
|
|
5546
|
-
this.
|
|
5547
|
-
|
|
5548
|
-
});
|
|
5549
|
-
this.table.tableService.selectionSource$.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function () {
|
|
5550
|
-
_this.checked = _this.updateCheckedState();
|
|
5551
|
-
});
|
|
5805
|
+
var PasswordStrengthDirective = /** @class */ (function () {
|
|
5806
|
+
function PasswordStrengthDirective(elementRef, appRef, componentFactoryResolver, injector) {
|
|
5807
|
+
this.elementRef = elementRef;
|
|
5808
|
+
this.appRef = appRef;
|
|
5809
|
+
this.componentFactoryResolver = componentFactoryResolver;
|
|
5810
|
+
this.injector = injector;
|
|
5811
|
+
this.enabled = true;
|
|
5812
|
+
this.position = exports.PasswordStrengthPositions.Right;
|
|
5813
|
+
this.componentRef = null;
|
|
5552
5814
|
}
|
|
5553
|
-
|
|
5554
|
-
|
|
5555
|
-
this.checked = this.updateCheckedState();
|
|
5556
|
-
};
|
|
5557
|
-
TableHeaderCheckboxComponent.prototype.ngOnDestroy = function () {
|
|
5558
|
-
this.ngUnsubscribe.next();
|
|
5559
|
-
};
|
|
5560
|
-
TableHeaderCheckboxComponent.prototype.onFocus = function () {
|
|
5561
|
-
this.hasFocus = true;
|
|
5815
|
+
PasswordStrengthDirective.prototype.ngOnInit = function () {
|
|
5816
|
+
this.validateProperties();
|
|
5562
5817
|
};
|
|
5563
|
-
|
|
5564
|
-
|
|
5818
|
+
PasswordStrengthDirective.prototype.onFocus = function () {
|
|
5819
|
+
var _a, _b, _c;
|
|
5820
|
+
var content = (_a = this.elementRef.nativeElement.value) !== null && _a !== void 0 ? _a : "";
|
|
5821
|
+
if (content) {
|
|
5822
|
+
this.createPasswordStrength();
|
|
5823
|
+
(_b = this.componentRef) === null || _b === void 0 ? void 0 : _b.instance.updateIndicators(this.validation(content));
|
|
5824
|
+
}
|
|
5825
|
+
else {
|
|
5826
|
+
(_c = this.componentRef) === null || _c === void 0 ? void 0 : _c.instance.updateIndicators(exports.PasswordStrengths.VeryWeak);
|
|
5827
|
+
}
|
|
5565
5828
|
};
|
|
5566
|
-
|
|
5567
|
-
|
|
5829
|
+
PasswordStrengthDirective.prototype.onBlur = function () {
|
|
5830
|
+
this.destroyPasswordStrength();
|
|
5568
5831
|
};
|
|
5569
|
-
|
|
5570
|
-
if (
|
|
5571
|
-
|
|
5572
|
-
|
|
5832
|
+
PasswordStrengthDirective.prototype.createPasswordStrength = function () {
|
|
5833
|
+
if (this.enabled && this.componentRef === null) {
|
|
5834
|
+
var componentFactory = this.componentFactoryResolver.resolveComponentFactory(PasswordStrengthComponent);
|
|
5835
|
+
this.componentRef = componentFactory.create(this.injector);
|
|
5836
|
+
this.appRef.attachView(this.componentRef.hostView);
|
|
5837
|
+
var domElem = this.componentRef.hostView.rootNodes[0];
|
|
5838
|
+
document.body.appendChild(domElem);
|
|
5839
|
+
this.setPasswordStrengthComponentProperties();
|
|
5840
|
+
this.showPasswordStrength();
|
|
5573
5841
|
}
|
|
5574
5842
|
};
|
|
5575
|
-
|
|
5576
|
-
if (this.
|
|
5577
|
-
|
|
5578
|
-
return val && val.length > 0 && this.table.selection && this.table.selection.length > 0 && this.isAllFilteredValuesChecked();
|
|
5579
|
-
}
|
|
5580
|
-
else {
|
|
5581
|
-
var val = this.table.value;
|
|
5582
|
-
return val && val.length > 0 && this.table.selection && this.table.selection.length > 0 && this.isAllValuesChecked();
|
|
5843
|
+
PasswordStrengthDirective.prototype.showPasswordStrength = function () {
|
|
5844
|
+
if (this.componentRef !== null) {
|
|
5845
|
+
this.componentRef.instance.visible = true;
|
|
5583
5846
|
}
|
|
5584
5847
|
};
|
|
5585
|
-
|
|
5586
|
-
|
|
5587
|
-
|
|
5588
|
-
|
|
5589
|
-
|
|
5590
|
-
|
|
5591
|
-
|
|
5592
|
-
|
|
5593
|
-
|
|
5594
|
-
|
|
5595
|
-
|
|
5596
|
-
|
|
5597
|
-
|
|
5598
|
-
|
|
5599
|
-
|
|
5600
|
-
|
|
5601
|
-
|
|
5602
|
-
|
|
5848
|
+
PasswordStrengthDirective.prototype.setPasswordStrengthComponentProperties = function () {
|
|
5849
|
+
if (this.componentRef != null) {
|
|
5850
|
+
this.componentRef.instance.position = this.position;
|
|
5851
|
+
this.componentRef.instance.weakTitle = this.weakTitle;
|
|
5852
|
+
this.componentRef.instance.mediumTitle = this.mediumTitle;
|
|
5853
|
+
this.componentRef.instance.strongTitle = this.strongTitle;
|
|
5854
|
+
this.componentRef.instance.description = this.description;
|
|
5855
|
+
var _a = this.elementRef.nativeElement.getBoundingClientRect(), top_1 = _a.top, right = _a.right, bottom = _a.bottom, left = _a.left;
|
|
5856
|
+
var margin = 20;
|
|
5857
|
+
var elementRefHeight = bottom - top_1;
|
|
5858
|
+
var elementRefWidth = right - left;
|
|
5859
|
+
var safeSpace = 150;
|
|
5860
|
+
var positioned = false;
|
|
5861
|
+
var invalidOptions = [];
|
|
5862
|
+
while (!positioned) {
|
|
5863
|
+
if (invalidOptions.includes(exports.PasswordStrengthPositions.Top)
|
|
5864
|
+
&& invalidOptions.includes(exports.PasswordStrengthPositions.Right)
|
|
5865
|
+
&& invalidOptions.includes(exports.PasswordStrengthPositions.Left)) {
|
|
5866
|
+
this.destroyPasswordStrength();
|
|
5867
|
+
throw new Error("No space to show password strength");
|
|
5868
|
+
}
|
|
5869
|
+
switch (this.position) {
|
|
5870
|
+
case exports.PasswordStrengthPositions.Top: {
|
|
5871
|
+
var topShift = top_1;
|
|
5872
|
+
var rightShift = document.body.clientWidth - right;
|
|
5873
|
+
var leftShift = left;
|
|
5874
|
+
if (topShift <= elementRefHeight + safeSpace || rightShift < 50 || leftShift < 50) {
|
|
5875
|
+
this.position = exports.PasswordStrengthPositions.Right;
|
|
5876
|
+
invalidOptions.push(exports.PasswordStrengthPositions.Top);
|
|
5877
|
+
break;
|
|
5878
|
+
}
|
|
5879
|
+
this.componentRef.instance.top = Math.round(top_1 - margin);
|
|
5880
|
+
this.componentRef.instance.left = Math.round(elementRefWidth / 2 + left);
|
|
5881
|
+
positioned = true;
|
|
5882
|
+
break;
|
|
5883
|
+
}
|
|
5884
|
+
case exports.PasswordStrengthPositions.Right: {
|
|
5885
|
+
var rightShift = document.body.clientWidth - right;
|
|
5886
|
+
if (rightShift <= elementRefWidth + safeSpace) {
|
|
5887
|
+
this.position = exports.PasswordStrengthPositions.Left;
|
|
5888
|
+
invalidOptions.push(exports.PasswordStrengthPositions.Right);
|
|
5889
|
+
break;
|
|
5890
|
+
}
|
|
5891
|
+
this.componentRef.instance.top = Math.round(top_1 + elementRefHeight / 2);
|
|
5892
|
+
this.componentRef.instance.left = Math.round(right + margin);
|
|
5893
|
+
positioned = true;
|
|
5894
|
+
break;
|
|
5895
|
+
}
|
|
5896
|
+
case exports.PasswordStrengthPositions.Left: {
|
|
5897
|
+
var leftShift = left;
|
|
5898
|
+
if (leftShift <= elementRefWidth + safeSpace) {
|
|
5899
|
+
this.position = exports.PasswordStrengthPositions.Top;
|
|
5900
|
+
invalidOptions.push(exports.PasswordStrengthPositions.Left);
|
|
5901
|
+
break;
|
|
5902
|
+
}
|
|
5903
|
+
this.componentRef.instance.top = Math.round(top_1 + elementRefHeight / 2);
|
|
5904
|
+
this.componentRef.instance.left = Math.round(left - margin);
|
|
5905
|
+
positioned = true;
|
|
5906
|
+
break;
|
|
5907
|
+
}
|
|
5908
|
+
default: {
|
|
5909
|
+
break;
|
|
5910
|
+
}
|
|
5911
|
+
}
|
|
5912
|
+
this.componentRef.instance.position = this.position;
|
|
5913
|
+
}
|
|
5603
5914
|
}
|
|
5604
|
-
|
|
5605
|
-
|
|
5606
|
-
|
|
5607
|
-
|
|
5915
|
+
};
|
|
5916
|
+
PasswordStrengthDirective.prototype.validateProperties = function () {
|
|
5917
|
+
this.validation = this.validation || this.defaultValidator;
|
|
5918
|
+
if (!this.description) {
|
|
5919
|
+
throw new Error("Description is required");
|
|
5608
5920
|
}
|
|
5609
|
-
this.table.updateSelectionKeys();
|
|
5610
|
-
this.table.selectionChange.emit(this.table._selection);
|
|
5611
|
-
this.tableService.onSelectionChange();
|
|
5612
|
-
if (this.table.isStateful())
|
|
5613
|
-
this.table.saveState();
|
|
5614
5921
|
};
|
|
5615
|
-
|
|
5616
|
-
|
|
5617
|
-
|
|
5618
|
-
|
|
5922
|
+
PasswordStrengthDirective.prototype.destroyPasswordStrength = function () {
|
|
5923
|
+
if (this.componentRef !== null) {
|
|
5924
|
+
this.appRef.detachView(this.componentRef.hostView);
|
|
5925
|
+
this.componentRef.destroy();
|
|
5926
|
+
this.componentRef = null;
|
|
5619
5927
|
}
|
|
5620
|
-
|
|
5621
|
-
|
|
5622
|
-
|
|
5623
|
-
|
|
5624
|
-
|
|
5625
|
-
|
|
5626
|
-
|
|
5627
|
-
|
|
5628
|
-
|
|
5629
|
-
|
|
5630
|
-
|
|
5631
|
-
|
|
5632
|
-
|
|
5633
|
-
|
|
5634
|
-
|
|
5928
|
+
};
|
|
5929
|
+
PasswordStrengthDirective.prototype.defaultValidator = function (content) {
|
|
5930
|
+
var points = 0;
|
|
5931
|
+
var regExpValidations = [
|
|
5932
|
+
new RegExp("(?=.*\\d)"),
|
|
5933
|
+
new RegExp("(?=.*[a-z])"),
|
|
5934
|
+
new RegExp("(?=.*[A-Z])"),
|
|
5935
|
+
new RegExp("(?=.*[!@#$%&*.\\-=+^~])"),
|
|
5936
|
+
];
|
|
5937
|
+
if (content.length >= 6) {
|
|
5938
|
+
points++;
|
|
5939
|
+
}
|
|
5940
|
+
regExpValidations.forEach(function (validation) {
|
|
5941
|
+
if (validation.test(content)) {
|
|
5942
|
+
points++;
|
|
5635
5943
|
}
|
|
5636
|
-
|
|
5944
|
+
});
|
|
5945
|
+
if (points < 1) {
|
|
5946
|
+
return exports.PasswordStrengths.VeryWeak;
|
|
5637
5947
|
}
|
|
5638
|
-
|
|
5639
|
-
|
|
5640
|
-
|
|
5641
|
-
if (
|
|
5642
|
-
return
|
|
5948
|
+
else if (points < 4) {
|
|
5949
|
+
return exports.PasswordStrengths.Weak;
|
|
5950
|
+
}
|
|
5951
|
+
else if (points < 5) {
|
|
5952
|
+
return exports.PasswordStrengths.Medium;
|
|
5643
5953
|
}
|
|
5644
5954
|
else {
|
|
5645
|
-
|
|
5646
|
-
for (var _b = __values(this.table.value), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
5647
|
-
var rowData = _c.value;
|
|
5648
|
-
if (!this.table.isSelected(rowData)) {
|
|
5649
|
-
return false;
|
|
5650
|
-
}
|
|
5651
|
-
}
|
|
5652
|
-
}
|
|
5653
|
-
catch (e_2_1) { e_2 = { error: e_2_1 }; }
|
|
5654
|
-
finally {
|
|
5655
|
-
try {
|
|
5656
|
-
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
|
5657
|
-
}
|
|
5658
|
-
finally { if (e_2) throw e_2.error; }
|
|
5659
|
-
}
|
|
5660
|
-
return true;
|
|
5955
|
+
return exports.PasswordStrengths.Strong;
|
|
5661
5956
|
}
|
|
5662
5957
|
};
|
|
5663
|
-
|
|
5664
|
-
|
|
5665
|
-
|
|
5666
|
-
{ type:
|
|
5667
|
-
{ type:
|
|
5958
|
+
PasswordStrengthDirective.ctorParameters = function () { return [
|
|
5959
|
+
{ type: core.ElementRef },
|
|
5960
|
+
{ type: core.ApplicationRef },
|
|
5961
|
+
{ type: core.ComponentFactoryResolver },
|
|
5962
|
+
{ type: core.Injector }
|
|
5668
5963
|
]; };
|
|
5669
5964
|
__decorate([
|
|
5670
|
-
core.Input()
|
|
5671
|
-
],
|
|
5965
|
+
core.Input("sPasswordStrength")
|
|
5966
|
+
], PasswordStrengthDirective.prototype, "enabled", void 0);
|
|
5672
5967
|
__decorate([
|
|
5673
|
-
core.Input()
|
|
5674
|
-
],
|
|
5968
|
+
core.Input("psValidation")
|
|
5969
|
+
], PasswordStrengthDirective.prototype, "validation", void 0);
|
|
5675
5970
|
__decorate([
|
|
5676
|
-
core.Input()
|
|
5677
|
-
],
|
|
5971
|
+
core.Input("psPosition")
|
|
5972
|
+
], PasswordStrengthDirective.prototype, "position", void 0);
|
|
5678
5973
|
__decorate([
|
|
5679
|
-
core.Input()
|
|
5680
|
-
],
|
|
5681
|
-
|
|
5682
|
-
core.
|
|
5683
|
-
|
|
5684
|
-
|
|
5974
|
+
core.Input("psWeakTitle")
|
|
5975
|
+
], PasswordStrengthDirective.prototype, "weakTitle", void 0);
|
|
5976
|
+
__decorate([
|
|
5977
|
+
core.Input("psMediumTitle")
|
|
5978
|
+
], PasswordStrengthDirective.prototype, "mediumTitle", void 0);
|
|
5979
|
+
__decorate([
|
|
5980
|
+
core.Input("psStrongTitle")
|
|
5981
|
+
], PasswordStrengthDirective.prototype, "strongTitle", void 0);
|
|
5982
|
+
__decorate([
|
|
5983
|
+
core.Input("psDescription")
|
|
5984
|
+
], PasswordStrengthDirective.prototype, "description", void 0);
|
|
5985
|
+
__decorate([
|
|
5986
|
+
core.HostListener("keyup"),
|
|
5987
|
+
core.HostListener("focus")
|
|
5988
|
+
], PasswordStrengthDirective.prototype, "onFocus", null);
|
|
5989
|
+
__decorate([
|
|
5990
|
+
core.HostListener("blur")
|
|
5991
|
+
], PasswordStrengthDirective.prototype, "onBlur", null);
|
|
5992
|
+
PasswordStrengthDirective = __decorate([
|
|
5993
|
+
core.Directive({
|
|
5994
|
+
selector: "[sPasswordStrength]",
|
|
5685
5995
|
})
|
|
5686
|
-
],
|
|
5687
|
-
return
|
|
5996
|
+
], PasswordStrengthDirective);
|
|
5997
|
+
return PasswordStrengthDirective;
|
|
5688
5998
|
}());
|
|
5689
5999
|
|
|
5690
|
-
var
|
|
5691
|
-
function
|
|
6000
|
+
var PasswordStrengthModule = /** @class */ (function () {
|
|
6001
|
+
function PasswordStrengthModule() {
|
|
5692
6002
|
}
|
|
5693
|
-
|
|
6003
|
+
PasswordStrengthModule = __decorate([
|
|
5694
6004
|
core.NgModule({
|
|
5695
6005
|
imports: [common.CommonModule],
|
|
5696
|
-
|
|
5697
|
-
|
|
6006
|
+
declarations: [
|
|
6007
|
+
PasswordStrengthComponent,
|
|
6008
|
+
PasswordStrengthDirective,
|
|
6009
|
+
],
|
|
6010
|
+
exports: [PasswordStrengthDirective],
|
|
5698
6011
|
})
|
|
5699
|
-
],
|
|
5700
|
-
return
|
|
6012
|
+
], PasswordStrengthModule);
|
|
6013
|
+
return PasswordStrengthModule;
|
|
5701
6014
|
}());
|
|
5702
6015
|
|
|
5703
6016
|
var NavigationDirective = /** @class */ (function () {
|
|
@@ -6660,223 +6973,246 @@
|
|
|
6660
6973
|
], TablePagingComponent.prototype, "enableExportSelectedRecords", void 0);
|
|
6661
6974
|
__decorate([
|
|
6662
6975
|
core.Input()
|
|
6663
|
-
], TablePagingComponent.prototype, "customActions", void 0);
|
|
6664
|
-
__decorate([
|
|
6665
|
-
core.Input()
|
|
6666
|
-
], TablePagingComponent.prototype, "loadAllRecords", void 0);
|
|
6667
|
-
__decorate([
|
|
6668
|
-
core.Input()
|
|
6669
|
-
], TablePagingComponent.prototype, "loadCurrentPageRecords", void 0);
|
|
6670
|
-
__decorate([
|
|
6671
|
-
core.Input()
|
|
6672
|
-
], TablePagingComponent.prototype, "loadSelectedRecords", void 0);
|
|
6673
|
-
__decorate([
|
|
6674
|
-
core.Output()
|
|
6675
|
-
], TablePagingComponent.prototype, "totalRecordsText", void 0);
|
|
6676
|
-
TablePagingComponent = __decorate([
|
|
6677
|
-
core.Component({
|
|
6678
|
-
template: "<div class=\"paging-container\">\n <span class=\"total-records\">\n {{totalRecordsText}}\n </span>\n <s-button\n *ngIf=\"exportable\"\n class=\"export-button\" \n priority=\"default\" \n iconClass=\"fa fa-fw fa-file-export\" \n [disabled]=\"false\" \n [auxiliary]=\"true\" \n [tooltip]=\"getTooltipText()\" \n [model]=\"getActions()\">\n </s-button>\n</div>\n",
|
|
6679
|
-
selector: "s-table-paging",
|
|
6680
|
-
styles: [".paging-container{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.export-button{margin-left:6px}"]
|
|
6681
|
-
}),
|
|
6682
|
-
__param(1, core.Inject(HostProjectConfigsInjectionToken))
|
|
6683
|
-
], TablePagingComponent);
|
|
6684
|
-
return TablePagingComponent;
|
|
6685
|
-
}());
|
|
6686
|
-
|
|
6687
|
-
var TableModule = /** @class */ (function () {
|
|
6688
|
-
function TableModule() {
|
|
6689
|
-
}
|
|
6690
|
-
TableModule = __decorate([
|
|
6691
|
-
core.NgModule({
|
|
6692
|
-
imports: [
|
|
6693
|
-
common.CommonModule,
|
|
6694
|
-
TooltipModule,
|
|
6695
|
-
TokenListModule,
|
|
6696
|
-
core$1.TranslateModule,
|
|
6697
|
-
ButtonModule,
|
|
6698
|
-
InfoSignModule
|
|
6699
|
-
],
|
|
6700
|
-
exports: [
|
|
6701
|
-
RowTogllerDirective,
|
|
6702
|
-
NavigationDirective,
|
|
6703
|
-
TableColumnsComponent,
|
|
6704
|
-
TableFrozenPositionDirective,
|
|
6705
|
-
TablePagingComponent
|
|
6706
|
-
],
|
|
6707
|
-
declarations: [
|
|
6708
|
-
RowTogllerDirective,
|
|
6709
|
-
NavigationDirective,
|
|
6710
|
-
TableColumnsComponent,
|
|
6711
|
-
TableFrozenPositionDirective,
|
|
6712
|
-
TablePagingComponent
|
|
6713
|
-
],
|
|
6714
|
-
})
|
|
6715
|
-
], TableModule);
|
|
6716
|
-
return TableModule;
|
|
6717
|
-
}());
|
|
6718
|
-
|
|
6719
|
-
var AutocompleteFieldComponent = /** @class */ (function () {
|
|
6720
|
-
function AutocompleteFieldComponent() {
|
|
6721
|
-
}
|
|
6722
|
-
__decorate([
|
|
6723
|
-
core.Input()
|
|
6724
|
-
], AutocompleteFieldComponent.prototype, "field", void 0);
|
|
6725
|
-
__decorate([
|
|
6726
|
-
core.Input()
|
|
6727
|
-
], AutocompleteFieldComponent.prototype, "formControl", void 0);
|
|
6728
|
-
AutocompleteFieldComponent = __decorate([
|
|
6729
|
-
core.Component({
|
|
6730
|
-
template: "<div\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\">\n <s-lookup\n [id]=\"(field.id || field.name)\"\n [multiple]=\"field.multiple\"\n [formControl]=\"formControl\"\n [placeholder]=\"field.placeholder\"\n [lookupSuggestions]=\"field.suggestions\"\n [dataKey]=\"field.dataKey\"\n (onLookupRequest)=\"field.onSearch($event)\"\n [lookupDisplayField]=\"field.displayField\"\n [showSearch]=\"false\"\n [lookupAppendTo]=\"field.appendTo\"\n (onSelect)=\"field.onSelect ? field.onSelect($event) : null\"\n (onUnselect)=\"field.onUnselect ? field.onUnselect($event) : null\"\n (onClear)=\"field.onClear ? field.onClear($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n [lookupEmptyMessage]=\"field.emptyMessage\">\n </s-lookup>\n</div>\n"
|
|
6731
|
-
})
|
|
6732
|
-
], AutocompleteFieldComponent);
|
|
6733
|
-
return AutocompleteFieldComponent;
|
|
6734
|
-
}());
|
|
6735
|
-
|
|
6736
|
-
var BooleanFieldComponent = /** @class */ (function () {
|
|
6737
|
-
function BooleanFieldComponent() {
|
|
6738
|
-
}
|
|
6739
|
-
BooleanFieldComponent.prototype.onClear = function () {
|
|
6740
|
-
this.formControl.reset();
|
|
6741
|
-
};
|
|
6742
|
-
__decorate([
|
|
6743
|
-
core.Input()
|
|
6744
|
-
], BooleanFieldComponent.prototype, "field", void 0);
|
|
6745
|
-
__decorate([
|
|
6746
|
-
core.Input()
|
|
6747
|
-
], BooleanFieldComponent.prototype, "formControl", void 0);
|
|
6748
|
-
BooleanFieldComponent = __decorate([
|
|
6749
|
-
core.Component({
|
|
6750
|
-
template: "<ng-container *ngIf=\"field.verticalAlignment;else horizontalAlignment\">\n <div class=\"ui-g\">\n <div class=\"ui-g-12\">\n <p-radioButton\n [name]=\"field.name\"\n [value]=\"true\"\n [label]=\"field.optionsLabel.true\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-1'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton>\n </div>\n <div class=\"ui-g-12\">\n <p-radioButton\n [name]=\"field.name\"\n [value]=\"false\"\n [label]=\"field.optionsLabel.false\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-2'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton>\n </div>\n <div\n *ngIf=\"!field.showClear && !field.required()\"\n class=\"ui-g-12\">\n <p-radioButton \n [name]=\"field.name\"\n [value]=\"null\"\n [label]=\"field.optionsLabel.empty\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-3'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton> \n </div>\n <div>\n <s-button\n *ngIf=\"field.showClear && !field.required() && !formControl.disabled\"\n [label]=\"field.optionsLabel.clear || 'Clear selection'\"\n (onClick)=\"onClear()\"\n priority=\"link\">\n </s-button>\n </div>\n\n </div>\n</ng-container>\n\n<ng-template #horizontalAlignment>\n <div class=\"ui-g\">\n <p-radioButton\n [name]=\"field.name\"\n [value]=\"true\"\n [label]=\"field.optionsLabel.true\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-1'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton>\n \n <p-radioButton\n [name]=\"field.name\"\n [value]=\"false\"\n [label]=\"field.optionsLabel.false\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-2'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton>\n\n <p-radioButton\n *ngIf=\"!field.showClear && !field.required()\"\n [name]=\"field.name\"\n [value]=\"null\"\n [label]=\"field.optionsLabel.empty\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-3'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton>\n\n <s-button\n *ngIf=\"field.showClear && !field.required() && !formControl.disabled\"\n style=\"margin-left: 40px;\"\n [label]=\"field.optionsLabel.clear || 'Clear selection'\"\n (onClick)=\"onClear()\"\n priority=\"link\">\n </s-button>\n </div>\n</ng-template>\n"
|
|
6751
|
-
})
|
|
6752
|
-
], BooleanFieldComponent);
|
|
6753
|
-
return BooleanFieldComponent;
|
|
6754
|
-
}());
|
|
6755
|
-
|
|
6756
|
-
var CalendarFieldComponent = /** @class */ (function () {
|
|
6757
|
-
function CalendarFieldComponent() {
|
|
6758
|
-
}
|
|
6759
|
-
__decorate([
|
|
6760
|
-
core.Input()
|
|
6761
|
-
], CalendarFieldComponent.prototype, "field", void 0);
|
|
6976
|
+
], TablePagingComponent.prototype, "customActions", void 0);
|
|
6762
6977
|
__decorate([
|
|
6763
6978
|
core.Input()
|
|
6764
|
-
],
|
|
6979
|
+
], TablePagingComponent.prototype, "loadAllRecords", void 0);
|
|
6765
6980
|
__decorate([
|
|
6766
6981
|
core.Input()
|
|
6767
|
-
],
|
|
6982
|
+
], TablePagingComponent.prototype, "loadCurrentPageRecords", void 0);
|
|
6768
6983
|
__decorate([
|
|
6769
6984
|
core.Input()
|
|
6770
|
-
],
|
|
6771
|
-
|
|
6985
|
+
], TablePagingComponent.prototype, "loadSelectedRecords", void 0);
|
|
6986
|
+
__decorate([
|
|
6987
|
+
core.Output()
|
|
6988
|
+
], TablePagingComponent.prototype, "totalRecordsText", void 0);
|
|
6989
|
+
TablePagingComponent = __decorate([
|
|
6772
6990
|
core.Component({
|
|
6773
|
-
template: "<div
|
|
6991
|
+
template: "<div class=\"paging-container\">\n <span class=\"total-records\">\n {{totalRecordsText}}\n </span>\n <s-button\n *ngIf=\"exportable\"\n class=\"export-button\" \n priority=\"default\" \n iconClass=\"fa fa-fw fa-file-export\" \n [disabled]=\"false\" \n [auxiliary]=\"true\" \n [tooltip]=\"getTooltipText()\" \n [model]=\"getActions()\">\n </s-button>\n</div>\n",
|
|
6992
|
+
selector: "s-table-paging",
|
|
6993
|
+
styles: [".paging-container{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.export-button{margin-left:6px}"]
|
|
6994
|
+
}),
|
|
6995
|
+
__param(1, core.Inject(HostProjectConfigsInjectionToken))
|
|
6996
|
+
], TablePagingComponent);
|
|
6997
|
+
return TablePagingComponent;
|
|
6998
|
+
}());
|
|
6999
|
+
|
|
7000
|
+
var TableModule = /** @class */ (function () {
|
|
7001
|
+
function TableModule() {
|
|
7002
|
+
}
|
|
7003
|
+
TableModule = __decorate([
|
|
7004
|
+
core.NgModule({
|
|
7005
|
+
imports: [
|
|
7006
|
+
common.CommonModule,
|
|
7007
|
+
TooltipModule,
|
|
7008
|
+
TokenListModule,
|
|
7009
|
+
core$1.TranslateModule,
|
|
7010
|
+
ButtonModule,
|
|
7011
|
+
InfoSignModule
|
|
7012
|
+
],
|
|
7013
|
+
exports: [
|
|
7014
|
+
RowTogllerDirective,
|
|
7015
|
+
NavigationDirective,
|
|
7016
|
+
TableColumnsComponent,
|
|
7017
|
+
TableFrozenPositionDirective,
|
|
7018
|
+
TablePagingComponent
|
|
7019
|
+
],
|
|
7020
|
+
declarations: [
|
|
7021
|
+
RowTogllerDirective,
|
|
7022
|
+
NavigationDirective,
|
|
7023
|
+
TableColumnsComponent,
|
|
7024
|
+
TableFrozenPositionDirective,
|
|
7025
|
+
TablePagingComponent
|
|
7026
|
+
],
|
|
6774
7027
|
})
|
|
6775
|
-
],
|
|
6776
|
-
return
|
|
7028
|
+
], TableModule);
|
|
7029
|
+
return TableModule;
|
|
6777
7030
|
}());
|
|
6778
7031
|
|
|
6779
|
-
var
|
|
6780
|
-
function
|
|
6781
|
-
|
|
6782
|
-
this.
|
|
6783
|
-
this.
|
|
7032
|
+
var TableHeaderCheckboxComponent = /** @class */ (function () {
|
|
7033
|
+
function TableHeaderCheckboxComponent(table, tableService) {
|
|
7034
|
+
var _this = this;
|
|
7035
|
+
this.table = table;
|
|
7036
|
+
this.tableService = tableService;
|
|
7037
|
+
this.id = "s-table-header-checkbox-" + TableHeaderCheckboxComponent_1.nextId++;
|
|
7038
|
+
this.ngUnsubscribe = new rxjs.Subject();
|
|
7039
|
+
this.table.tableService.valueSource$.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function () {
|
|
7040
|
+
_this.checked = _this.updateCheckedState();
|
|
7041
|
+
});
|
|
7042
|
+
this.table.tableService.selectionSource$.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function () {
|
|
7043
|
+
_this.checked = _this.updateCheckedState();
|
|
7044
|
+
});
|
|
6784
7045
|
}
|
|
6785
|
-
|
|
7046
|
+
TableHeaderCheckboxComponent_1 = TableHeaderCheckboxComponent;
|
|
7047
|
+
TableHeaderCheckboxComponent.prototype.ngOnInit = function () {
|
|
7048
|
+
this.checked = this.updateCheckedState();
|
|
7049
|
+
};
|
|
7050
|
+
TableHeaderCheckboxComponent.prototype.ngOnDestroy = function () {
|
|
7051
|
+
this.ngUnsubscribe.next();
|
|
7052
|
+
};
|
|
7053
|
+
TableHeaderCheckboxComponent.prototype.onFocus = function () {
|
|
7054
|
+
this.hasFocus = true;
|
|
7055
|
+
};
|
|
7056
|
+
TableHeaderCheckboxComponent.prototype.onBlur = function () {
|
|
7057
|
+
this.hasFocus = false;
|
|
7058
|
+
};
|
|
7059
|
+
TableHeaderCheckboxComponent.prototype.isDisabled = function () {
|
|
7060
|
+
return this.disabled || !this.table.value || !this.table.value.length;
|
|
7061
|
+
};
|
|
7062
|
+
TableHeaderCheckboxComponent.prototype.onClick = function () {
|
|
7063
|
+
if (!this.disabled) {
|
|
7064
|
+
if (this.table.value && this.table.value.length > 0)
|
|
7065
|
+
this.onToggleCheckbox(!this.checked);
|
|
7066
|
+
}
|
|
7067
|
+
};
|
|
7068
|
+
TableHeaderCheckboxComponent.prototype.updateCheckedState = function () {
|
|
7069
|
+
if (this.table.filteredValue) {
|
|
7070
|
+
var val = this.table.filteredValue;
|
|
7071
|
+
return val && val.length > 0 && this.table.selection && this.table.selection.length > 0 && this.isAllFilteredValuesChecked();
|
|
7072
|
+
}
|
|
7073
|
+
else {
|
|
7074
|
+
var val = this.table.value;
|
|
7075
|
+
return val && val.length > 0 && this.table.selection && this.table.selection.length > 0 && this.isAllValuesChecked();
|
|
7076
|
+
}
|
|
7077
|
+
};
|
|
7078
|
+
TableHeaderCheckboxComponent.prototype.onToggleCheckbox = function (checked) {
|
|
6786
7079
|
var _this = this;
|
|
6787
|
-
|
|
6788
|
-
|
|
6789
|
-
|
|
6790
|
-
|
|
6791
|
-
_this.
|
|
6792
|
-
|
|
6793
|
-
|
|
6794
|
-
|
|
6795
|
-
|
|
6796
|
-
|
|
6797
|
-
|
|
7080
|
+
var _a = this.table, filteredValue = _a.filteredValue, value = _a.value, dataKey = _a.dataKey;
|
|
7081
|
+
var gridData = checked ? (filteredValue ? filteredValue.slice() : value.slice()) : [];
|
|
7082
|
+
if (checked) {
|
|
7083
|
+
var unselecteds = gridData
|
|
7084
|
+
.filter(function (record) { return !_this.table._selection.find(function (selected) { return record[dataKey] === selected[dataKey]; }); })
|
|
7085
|
+
.map(function (record) {
|
|
7086
|
+
if (_this.useAllObject)
|
|
7087
|
+
return record;
|
|
7088
|
+
var newRecord = {};
|
|
7089
|
+
if (_this.rowProps)
|
|
7090
|
+
_this.rowProps.forEach(function (prop) { return (newRecord[prop] = record[prop]); });
|
|
7091
|
+
else
|
|
7092
|
+
newRecord[dataKey] = record[dataKey];
|
|
7093
|
+
return newRecord;
|
|
7094
|
+
});
|
|
7095
|
+
this.table._selection = __spread(this.table._selection, unselecteds);
|
|
7096
|
+
}
|
|
7097
|
+
else {
|
|
7098
|
+
value.forEach(function (data) {
|
|
7099
|
+
_this.table._selection = _this.table._selection.filter(function (record) { return record[dataKey] !== data[dataKey]; });
|
|
7100
|
+
});
|
|
7101
|
+
}
|
|
7102
|
+
this.table.updateSelectionKeys();
|
|
7103
|
+
this.table.selectionChange.emit(this.table._selection);
|
|
7104
|
+
this.tableService.onSelectionChange();
|
|
7105
|
+
if (this.table.isStateful())
|
|
7106
|
+
this.table.saveState();
|
|
7107
|
+
};
|
|
7108
|
+
TableHeaderCheckboxComponent.prototype.isAllFilteredValuesChecked = function () {
|
|
7109
|
+
var e_1, _a;
|
|
7110
|
+
if (!this.table.filteredValue) {
|
|
7111
|
+
return false;
|
|
7112
|
+
}
|
|
7113
|
+
else {
|
|
7114
|
+
try {
|
|
7115
|
+
for (var _b = __values(this.table.filteredValue), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
7116
|
+
var rowData = _c.value;
|
|
7117
|
+
if (!this.table.isSelected(rowData)) {
|
|
7118
|
+
return false;
|
|
7119
|
+
}
|
|
7120
|
+
}
|
|
7121
|
+
}
|
|
7122
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
7123
|
+
finally {
|
|
7124
|
+
try {
|
|
7125
|
+
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
|
7126
|
+
}
|
|
7127
|
+
finally { if (e_1) throw e_1.error; }
|
|
6798
7128
|
}
|
|
7129
|
+
return true;
|
|
6799
7130
|
}
|
|
6800
7131
|
};
|
|
6801
|
-
|
|
6802
|
-
|
|
7132
|
+
TableHeaderCheckboxComponent.prototype.isAllValuesChecked = function () {
|
|
7133
|
+
var e_2, _a;
|
|
7134
|
+
if (!this.table.value) {
|
|
7135
|
+
return false;
|
|
7136
|
+
}
|
|
7137
|
+
else {
|
|
7138
|
+
try {
|
|
7139
|
+
for (var _b = __values(this.table.value), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
7140
|
+
var rowData = _c.value;
|
|
7141
|
+
if (!this.table.isSelected(rowData)) {
|
|
7142
|
+
return false;
|
|
7143
|
+
}
|
|
7144
|
+
}
|
|
7145
|
+
}
|
|
7146
|
+
catch (e_2_1) { e_2 = { error: e_2_1 }; }
|
|
7147
|
+
finally {
|
|
7148
|
+
try {
|
|
7149
|
+
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
|
7150
|
+
}
|
|
7151
|
+
finally { if (e_2) throw e_2.error; }
|
|
7152
|
+
}
|
|
7153
|
+
return true;
|
|
7154
|
+
}
|
|
7155
|
+
};
|
|
7156
|
+
var TableHeaderCheckboxComponent_1;
|
|
7157
|
+
TableHeaderCheckboxComponent.nextId = 0;
|
|
7158
|
+
TableHeaderCheckboxComponent.ctorParameters = function () { return [
|
|
7159
|
+
{ type: table.Table },
|
|
7160
|
+
{ type: table.TableService }
|
|
6803
7161
|
]; };
|
|
6804
7162
|
__decorate([
|
|
6805
7163
|
core.Input()
|
|
6806
|
-
],
|
|
7164
|
+
], TableHeaderCheckboxComponent.prototype, "id", void 0);
|
|
6807
7165
|
__decorate([
|
|
6808
7166
|
core.Input()
|
|
6809
|
-
],
|
|
6810
|
-
ChipsFieldComponent = __decorate([
|
|
6811
|
-
core.Component({
|
|
6812
|
-
template: "<div class=\"chips-field-wrapper\">\n <div style=\"width: 100%;\">\n <p-chips\n *ngIf=\"field.keyFilter\"\n [inputId]=\"(field.id || field.name)\"\n [formControl]=\"formControl\"\n [placeholder]=\"field.placeholder\"\n [allowDuplicate]=\"false\"\n [addOnTab]=\"true\"\n [addOnBlur]=\"true\"\n (onAdd)=\"field.onAdd ? field.onAdd($event) : null\"\n (onRemove)=\"field.onRemove ? field.onRemove($event) : null\"\n (onChipClick)=\"field.onChipClick ? field.onChipClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n [pKeyFilter]=\"field.keyFilter\">\n <ng-template let-item pTemplate=\"item\">\n <span\n class=\"chip-content\"\n [sTooltip]=\"item\">\n {{ item }}\n </span>\n </ng-template>\n </p-chips>\n \n <p-chips\n *ngIf=\"!field.keyFilter\"\n [inputId]=\"(field.id || field.name)\"\n [formControl]=\"formControl\"\n [placeholder]=\"field.placeholder\"\n [allowDuplicate]=\"false\"\n [addOnTab]=\"true\"\n [addOnBlur]=\"true\"\n (onAdd)=\"field.onAdd ? field.onAdd($event) : null\"\n (onRemove)=\"field.onRemove ? field.onRemove($event) : null\"\n (onChipClick)=\"field.onChipClick ? field.onChipClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n <ng-template let-item pTemplate=\"item\">\n <span\n class=\"chip-content\"\n [sTooltip]=\"item\">\n {{ item }}\n </span>\n </ng-template>\n </p-chips>\n </div>\n \n <button\n *ngIf=\"field.showCopyButton && formControl.value?.length > 0 && copyButtonVisible\"\n class=\"copy-content-button\"\n (click)=\"onCopyFieldContent()\">\n {{ \"platform.angular_components.copy_field_content\" | translate }}\n </button>\n \n <span\n *ngIf=\"feedbackMessageVisible\"\n class=\"feedback-message\">\n {{ \"platform.angular_components.copied_to_clipboard\" | translate }}\n </span>\n</div>\n",
|
|
6813
|
-
styles: [".chips-field-wrapper{-ms-flex-align:start;align-items:flex-start;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.chips-field-wrapper .chip-content{display:block;overflow:hidden;padding-right:1rem;text-overflow:ellipsis}.chips-field-wrapper .copy-content-button{background-color:transparent;border:none;color:#2a6496;cursor:pointer;margin-top:8px}.chips-field-wrapper .feedback-message{color:#0c9348;display:block;margin-top:8px;-webkit-user-select:none;-ms-user-select:none;user-select:none}"]
|
|
6814
|
-
})
|
|
6815
|
-
], ChipsFieldComponent);
|
|
6816
|
-
return ChipsFieldComponent;
|
|
6817
|
-
}());
|
|
6818
|
-
|
|
6819
|
-
/**
|
|
6820
|
-
* @deprecated Should use bignumber instead
|
|
6821
|
-
*/
|
|
6822
|
-
var CurrencyFieldComponent = /** @class */ (function (_super) {
|
|
6823
|
-
__extends(CurrencyFieldComponent, _super);
|
|
6824
|
-
function CurrencyFieldComponent() {
|
|
6825
|
-
return _super !== null && _super.apply(this, arguments) || this;
|
|
6826
|
-
}
|
|
7167
|
+
], TableHeaderCheckboxComponent.prototype, "disabled", void 0);
|
|
6827
7168
|
__decorate([
|
|
6828
7169
|
core.Input()
|
|
6829
|
-
],
|
|
7170
|
+
], TableHeaderCheckboxComponent.prototype, "rowProps", void 0);
|
|
6830
7171
|
__decorate([
|
|
6831
7172
|
core.Input()
|
|
6832
|
-
],
|
|
6833
|
-
|
|
7173
|
+
], TableHeaderCheckboxComponent.prototype, "useAllObject", void 0);
|
|
7174
|
+
TableHeaderCheckboxComponent = TableHeaderCheckboxComponent_1 = __decorate([
|
|
6834
7175
|
core.Component({
|
|
6835
|
-
|
|
7176
|
+
selector: "s-table-header-checkbox",
|
|
7177
|
+
template: "\n <div class=\"ui-chkbox ui-widget\" (click)=\"onClick()\">\n <div class=\"ui-helper-hidden-accessible\">\n <input type=\"checkbox\" [checked]=\"checked\" (focus)=\"onFocus()\" (blur)=\"onBlur()\" [disabled]=\"isDisabled()\">\n </div>\n <div [ngClass]=\"{'ui-chkbox-box ui-widget ui-state-default':true,\n 'ui-state-active':checked, 'ui-state-disabled': isDisabled(), 'ui-state-focus': hasFocus}\">\n <span [id]=\"id\" class=\"ui-chkbox-icon ui-clickable\" [ngClass]=\"{'pi pi-check':checked}\"></span>\n </div>\n </div>\n "
|
|
6836
7178
|
})
|
|
6837
|
-
],
|
|
6838
|
-
return
|
|
6839
|
-
}(
|
|
7179
|
+
], TableHeaderCheckboxComponent);
|
|
7180
|
+
return TableHeaderCheckboxComponent;
|
|
7181
|
+
}());
|
|
6840
7182
|
|
|
6841
|
-
var
|
|
6842
|
-
|
|
6843
|
-
function FileUploadComponent() {
|
|
6844
|
-
return _super !== null && _super.apply(this, arguments) || this;
|
|
7183
|
+
var TableHeaderCheckboxModule = /** @class */ (function () {
|
|
7184
|
+
function TableHeaderCheckboxModule() {
|
|
6845
7185
|
}
|
|
6846
|
-
__decorate([
|
|
6847
|
-
core.
|
|
6848
|
-
|
|
6849
|
-
|
|
6850
|
-
|
|
6851
|
-
|
|
6852
|
-
|
|
6853
|
-
|
|
6854
|
-
|
|
6855
|
-
})
|
|
6856
|
-
], FileUploadComponent);
|
|
6857
|
-
return FileUploadComponent;
|
|
6858
|
-
}(BaseFieldComponent));
|
|
7186
|
+
TableHeaderCheckboxModule = __decorate([
|
|
7187
|
+
core.NgModule({
|
|
7188
|
+
imports: [common.CommonModule],
|
|
7189
|
+
exports: [TableHeaderCheckboxComponent],
|
|
7190
|
+
declarations: [TableHeaderCheckboxComponent],
|
|
7191
|
+
})
|
|
7192
|
+
], TableHeaderCheckboxModule);
|
|
7193
|
+
return TableHeaderCheckboxModule;
|
|
7194
|
+
}());
|
|
6859
7195
|
|
|
6860
|
-
var
|
|
6861
|
-
function
|
|
7196
|
+
var AutocompleteFieldComponent = /** @class */ (function () {
|
|
7197
|
+
function AutocompleteFieldComponent() {
|
|
6862
7198
|
}
|
|
6863
7199
|
__decorate([
|
|
6864
7200
|
core.Input()
|
|
6865
|
-
],
|
|
7201
|
+
], AutocompleteFieldComponent.prototype, "field", void 0);
|
|
6866
7202
|
__decorate([
|
|
6867
7203
|
core.Input()
|
|
6868
|
-
],
|
|
6869
|
-
|
|
7204
|
+
], AutocompleteFieldComponent.prototype, "formControl", void 0);
|
|
7205
|
+
AutocompleteFieldComponent = __decorate([
|
|
6870
7206
|
core.Component({
|
|
6871
|
-
template: "<div\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\">\n <s-lookup\n [id]=\"(field.id || field.name)\"\n [multiple]=\"field.multiple\"\n [formControl]=\"formControl\"\n [
|
|
7207
|
+
template: "<div\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\">\n <s-lookup\n [id]=\"(field.id || field.name)\"\n [multiple]=\"field.multiple\"\n [formControl]=\"formControl\"\n [placeholder]=\"field.placeholder\"\n [lookupSuggestions]=\"field.suggestions\"\n [dataKey]=\"field.dataKey\"\n (onLookupRequest)=\"field.onSearch($event)\"\n [lookupDisplayField]=\"field.displayField\"\n [showSearch]=\"false\"\n [lookupAppendTo]=\"field.appendTo\"\n (onSelect)=\"field.onSelect ? field.onSelect($event) : null\"\n (onUnselect)=\"field.onUnselect ? field.onUnselect($event) : null\"\n (onClear)=\"field.onClear ? field.onClear($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n [lookupEmptyMessage]=\"field.emptyMessage\">\n </s-lookup>\n</div>\n"
|
|
6872
7208
|
})
|
|
6873
|
-
],
|
|
6874
|
-
return
|
|
7209
|
+
], AutocompleteFieldComponent);
|
|
7210
|
+
return AutocompleteFieldComponent;
|
|
6875
7211
|
}());
|
|
6876
7212
|
|
|
6877
|
-
var
|
|
6878
|
-
__extends(
|
|
6879
|
-
function
|
|
7213
|
+
var BignumberFieldComponent = /** @class */ (function (_super) {
|
|
7214
|
+
__extends(BignumberFieldComponent, _super);
|
|
7215
|
+
function BignumberFieldComponent() {
|
|
6880
7216
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
6881
7217
|
_this.onInput = new core.EventEmitter();
|
|
6882
7218
|
_this.onFocus = new core.EventEmitter();
|
|
@@ -6884,33 +7220,35 @@
|
|
|
6884
7220
|
_this.ngUnsubscribe = new rxjs.Subject();
|
|
6885
7221
|
return _this;
|
|
6886
7222
|
}
|
|
6887
|
-
|
|
7223
|
+
BignumberFieldComponent.prototype.ngOnInit = function () {
|
|
6888
7224
|
var _this = this;
|
|
6889
|
-
this.onFocus
|
|
6890
|
-
|
|
7225
|
+
this.onFocus
|
|
7226
|
+
.pipe(operators.takeUntil(this.ngUnsubscribe))
|
|
7227
|
+
.subscribe(function (event) {
|
|
7228
|
+
if (_this.field.onFocus) {
|
|
6891
7229
|
_this.field.onFocus(event);
|
|
7230
|
+
}
|
|
6892
7231
|
});
|
|
6893
|
-
this.onInput
|
|
6894
|
-
|
|
7232
|
+
this.onInput
|
|
7233
|
+
.pipe(operators.takeUntil(this.ngUnsubscribe))
|
|
7234
|
+
.subscribe(function (event) {
|
|
7235
|
+
if (_this.field.onInput) {
|
|
6895
7236
|
_this.field.onInput(event);
|
|
7237
|
+
}
|
|
6896
7238
|
});
|
|
6897
|
-
this.onComplete
|
|
6898
|
-
|
|
7239
|
+
this.onComplete
|
|
7240
|
+
.pipe(operators.takeUntil(this.ngUnsubscribe))
|
|
7241
|
+
.subscribe(function (event) {
|
|
7242
|
+
if (_this.field.onComplete) {
|
|
6899
7243
|
_this.field.onComplete(event);
|
|
7244
|
+
}
|
|
6900
7245
|
});
|
|
6901
7246
|
};
|
|
6902
|
-
|
|
7247
|
+
BignumberFieldComponent.prototype.ngOnDestroy = function () {
|
|
6903
7248
|
this.ngUnsubscribe.next();
|
|
6904
7249
|
this.ngUnsubscribe.complete();
|
|
6905
7250
|
};
|
|
6906
|
-
Object.defineProperty(
|
|
6907
|
-
get: function () {
|
|
6908
|
-
return exports.NumberAlignmentOption;
|
|
6909
|
-
},
|
|
6910
|
-
enumerable: true,
|
|
6911
|
-
configurable: true
|
|
6912
|
-
});
|
|
6913
|
-
Object.defineProperty(NumberFieldComponent.prototype, "fieldType", {
|
|
7251
|
+
Object.defineProperty(BignumberFieldComponent.prototype, "fieldType", {
|
|
6914
7252
|
get: function () {
|
|
6915
7253
|
return exports.FieldType;
|
|
6916
7254
|
},
|
|
@@ -6919,308 +7257,167 @@
|
|
|
6919
7257
|
});
|
|
6920
7258
|
__decorate([
|
|
6921
7259
|
core.Input()
|
|
6922
|
-
],
|
|
7260
|
+
], BignumberFieldComponent.prototype, "field", void 0);
|
|
6923
7261
|
__decorate([
|
|
6924
7262
|
core.Input()
|
|
6925
|
-
],
|
|
7263
|
+
], BignumberFieldComponent.prototype, "formControl", void 0);
|
|
6926
7264
|
__decorate([
|
|
6927
7265
|
core.Output()
|
|
6928
|
-
],
|
|
7266
|
+
], BignumberFieldComponent.prototype, "onInput", void 0);
|
|
6929
7267
|
__decorate([
|
|
6930
7268
|
core.Output()
|
|
6931
|
-
],
|
|
7269
|
+
], BignumberFieldComponent.prototype, "onFocus", void 0);
|
|
6932
7270
|
__decorate([
|
|
6933
7271
|
core.Output()
|
|
6934
|
-
],
|
|
6935
|
-
|
|
7272
|
+
], BignumberFieldComponent.prototype, "onComplete", void 0);
|
|
7273
|
+
BignumberFieldComponent = __decorate([
|
|
6936
7274
|
core.Component({
|
|
6937
|
-
template: "<p-inputMask\n *ngIf=\"field.mask; else noMask\"\n type=\"text\"\n [inputId]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [mask]=\"isFunction(field.mask) ? field.mask() : field.mask\"\n [placeholder]=\"field.placeholder\"\n slotChar=\"_\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\"\n styleClass=\"mousetrap\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n (onFocus)=\"onFocus.next($event)\"\n (onComplete)=\"onComplete.next($event)\"\n (onInput)=\"onInput.next($event)\"\n [formControl]=\"formControl\"
|
|
7275
|
+
template: "<p-inputMask\n *ngIf=\"field.mask; else noMask\"\n type=\"text\"\n [inputId]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [mask]=\"isFunction(field.mask) ? field.mask() : field.mask\"\n [placeholder]=\"field.placeholder\"\n slotChar=\"_\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\"\n styleClass=\"mousetrap\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n (onFocus)=\"onFocus.next($event)\"\n (onComplete)=\"onComplete.next($event)\"\n (onInput)=\"onInput.next($event)\"\n [formControl]=\"formControl\"\n [autoClear]=\"field.autoClear\">\n</p-inputMask>\n\n<ng-template #noMask>\n <ng-container>\n <div class=\"ui-inputgroup\">\n <ng-container *ngIf=\"field.leftAddon\">\n <span class=\"ui-inputgroup-addon\">\n <span *ngIf=\"field.leftAddon.label\">{{field.leftAddon.label}}</span>\n <span *ngIf=\"!field.leftAddon.label\" [ngClass]=\"field.leftAddon.icon\"></span>\n </span>\n </ng-container>\n\n <input\n [id]=\"(field.id || field.name)\"\n type=\"text\"\n [name]=\"field.name\"\n sBignumberInput\n [allowNegative]=\"field.allowNegative\"\n [precision]=\"isFunction(field.precision) ? trigger(field.precision) : field.precision\"\n [scale]=\"isFunction(field.scale) ? trigger(field.scale) : field.scale\"\n [decimalSeparator]=\"field.numberLocaleOptions.decimalSeparator\"\n [thousandsSeparator]=\"field.numberLocaleOptions.thousandsSeparator\"\n [alignTo]=\"field.alignTo\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [placeholder]=\"field.placeholder\"\n [showDelay]=\"500\"\n pInputText\n [autocomplete]=\"field.browserAutocomplete ? 'on' : 'off'\"\n [ngClass]=\"'mousetrap'\"\n (blur)=\"field.onBlur ? field.onBlur($event) : null\"\n (focus)=\"onFocus.next($event)\"\n [formControl]=\"formControl\" />\n <ng-container *ngIf=\"field.rightAddon\">\n <span class=\"ui-inputgroup-addon\">\n <span *ngIf=\"field.rightAddon.label\">{{field.rightAddon.label}}</span>\n <span *ngIf=\"!field.rightAddon.label\" [ngClass]=\"field.rightAddon.icon\"></span>\n </span>\n </ng-container>\n </div>\n </ng-container>\n</ng-template>\n",
|
|
6938
7276
|
encapsulation: core.ViewEncapsulation.None,
|
|
6939
7277
|
styles: ["s-number-field.ng-dirty.ng-invalid .ui-inputtext{border-color:#c13018}s-number-field.ng-dirty.ng-invalid .ui-inputtext:hover{border-color:#e44328}"]
|
|
6940
7278
|
})
|
|
6941
|
-
],
|
|
6942
|
-
return
|
|
7279
|
+
], BignumberFieldComponent);
|
|
7280
|
+
return BignumberFieldComponent;
|
|
6943
7281
|
}(BaseFieldComponent));
|
|
6944
7282
|
|
|
6945
|
-
var
|
|
6946
|
-
function
|
|
6947
|
-
this.onClick = new core.EventEmitter();
|
|
6948
|
-
this.onFocus = new core.EventEmitter();
|
|
6949
|
-
this.ngUnsubscribe = new rxjs.Subject();
|
|
7283
|
+
var BooleanFieldComponent = /** @class */ (function () {
|
|
7284
|
+
function BooleanFieldComponent() {
|
|
6950
7285
|
}
|
|
6951
|
-
|
|
6952
|
-
var _this = this;
|
|
6953
|
-
this.onFocus.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function (event) {
|
|
6954
|
-
if (_this.field.onFocus)
|
|
6955
|
-
_this.field.onFocus(event);
|
|
6956
|
-
});
|
|
6957
|
-
this.onClick.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function (event) {
|
|
6958
|
-
if (_this.field.onClick)
|
|
6959
|
-
_this.field.onClick(event);
|
|
6960
|
-
});
|
|
6961
|
-
};
|
|
6962
|
-
RadioButtonComponent.prototype.ngOnDestroy = function () {
|
|
6963
|
-
this.ngUnsubscribe.next();
|
|
6964
|
-
this.ngUnsubscribe.complete();
|
|
6965
|
-
};
|
|
6966
|
-
RadioButtonComponent.prototype.onClear = function () {
|
|
7286
|
+
BooleanFieldComponent.prototype.onClear = function () {
|
|
6967
7287
|
this.formControl.reset();
|
|
6968
7288
|
};
|
|
6969
7289
|
__decorate([
|
|
6970
7290
|
core.Input()
|
|
6971
|
-
],
|
|
7291
|
+
], BooleanFieldComponent.prototype, "field", void 0);
|
|
6972
7292
|
__decorate([
|
|
6973
7293
|
core.Input()
|
|
6974
|
-
],
|
|
6975
|
-
__decorate([
|
|
6976
|
-
core.Output()
|
|
6977
|
-
], RadioButtonComponent.prototype, "onClick", void 0);
|
|
6978
|
-
__decorate([
|
|
6979
|
-
core.Output()
|
|
6980
|
-
], RadioButtonComponent.prototype, "onFocus", void 0);
|
|
6981
|
-
RadioButtonComponent = __decorate([
|
|
7294
|
+
], BooleanFieldComponent.prototype, "formControl", void 0);
|
|
7295
|
+
BooleanFieldComponent = __decorate([
|
|
6982
7296
|
core.Component({
|
|
6983
|
-
template: "<ng-container *ngIf=\"field.verticalAlignment;else horizontalAlignment\">\n <div class=\"ui-g\">\n <div\n
|
|
6984
|
-
encapsulation: core.ViewEncapsulation.None,
|
|
6985
|
-
styles: ["\n s-button.horizontal-clear-option button {\n width: min-content !important;\n }\n "]
|
|
7297
|
+
template: "<ng-container *ngIf=\"field.verticalAlignment;else horizontalAlignment\">\n <div class=\"ui-g\">\n <div class=\"ui-g-12\">\n <p-radioButton\n [name]=\"field.name\"\n [value]=\"true\"\n [label]=\"field.optionsLabel.true\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-1'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton>\n </div>\n <div class=\"ui-g-12\">\n <p-radioButton\n [name]=\"field.name\"\n [value]=\"false\"\n [label]=\"field.optionsLabel.false\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-2'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton>\n </div>\n <div\n *ngIf=\"!field.showClear && !field.required()\"\n class=\"ui-g-12\">\n <p-radioButton \n [name]=\"field.name\"\n [value]=\"null\"\n [label]=\"field.optionsLabel.empty\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-3'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton> \n </div>\n <div>\n <s-button\n *ngIf=\"field.showClear && !field.required() && !formControl.disabled\"\n [label]=\"field.optionsLabel.clear || 'Clear selection'\"\n (onClick)=\"onClear()\"\n priority=\"link\">\n </s-button>\n </div>\n\n </div>\n</ng-container>\n\n<ng-template #horizontalAlignment>\n <div class=\"ui-g\">\n <p-radioButton\n [name]=\"field.name\"\n [value]=\"true\"\n [label]=\"field.optionsLabel.true\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-1'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton>\n \n <p-radioButton\n [name]=\"field.name\"\n [value]=\"false\"\n [label]=\"field.optionsLabel.false\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-2'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton>\n\n <p-radioButton\n *ngIf=\"!field.showClear && !field.required()\"\n [name]=\"field.name\"\n [value]=\"null\"\n [label]=\"field.optionsLabel.empty\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-3'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton>\n\n <s-button\n *ngIf=\"field.showClear && !field.required() && !formControl.disabled\"\n style=\"margin-left: 40px;\"\n [label]=\"field.optionsLabel.clear || 'Clear selection'\"\n (onClick)=\"onClear()\"\n priority=\"link\">\n </s-button>\n </div>\n</ng-template>\n"
|
|
6986
7298
|
})
|
|
6987
|
-
],
|
|
6988
|
-
return
|
|
7299
|
+
], BooleanFieldComponent);
|
|
7300
|
+
return BooleanFieldComponent;
|
|
6989
7301
|
}());
|
|
6990
7302
|
|
|
6991
|
-
var
|
|
6992
|
-
|
|
6993
|
-
function SelectFieldComponent() {
|
|
6994
|
-
return _super !== null && _super.apply(this, arguments) || this;
|
|
6995
|
-
}
|
|
6996
|
-
__decorate([
|
|
6997
|
-
core.Input()
|
|
6998
|
-
], SelectFieldComponent.prototype, "field", void 0);
|
|
6999
|
-
__decorate([
|
|
7000
|
-
core.Input()
|
|
7001
|
-
], SelectFieldComponent.prototype, "formControl", void 0);
|
|
7002
|
-
SelectFieldComponent = __decorate([
|
|
7003
|
-
core.Component({
|
|
7004
|
-
template: "<p-dropdown\n *ngIf=\"!field.multiple\"\n [inputId]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [options]=\"isFunction(field.options) ? field.options() : field.options\"\n [placeholder]=\"field.placeholder || ' '\"\n [formControl]=\"formControl\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\"\n [showClear]=\"field.showClear\"\n dataKey=\"{{field.dataKey}}\"\n optionLabel=\"{{field.optionLabel}}\"\n [autoDisplayFirst]=\"field.autoDisplayFirst\"\n [appendTo]=\"field.appendTo || 'body'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onChange)=\"field.onChange ? field.onChange($event) : null\">\n</p-dropdown>\n<p-multiSelect\n *ngIf=\"field.multiple\"\n [formControl]=\"formControl\"\n [name]=\"field.name\"\n [inputId]=\"(field.id || field.name)\"\n [options]=\"isFunction(field.options) ? field.options() : field.options\"\n [defaultLabel]=\"field.placeholder\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [emptyFilterMessage]=\"field.emptyMessage || 'Nenhum registro encontrado'\"\n [showDelay]=\"500\"\n [selectedItemsLabel]=\"field.multipleSelectedLabel\"\n [appendTo]=\"field.appendTo || 'body'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onChange)=\"field.onChange ? field.onChange($event) : null\">\n</p-multiSelect>\n\n"
|
|
7005
|
-
})
|
|
7006
|
-
], SelectFieldComponent);
|
|
7007
|
-
return SelectFieldComponent;
|
|
7008
|
-
}(BaseFieldComponent));
|
|
7009
|
-
|
|
7010
|
-
var TextAreaFieldComponent = /** @class */ (function () {
|
|
7011
|
-
function TextAreaFieldComponent() {
|
|
7303
|
+
var BooleanSwitchFieldComponent = /** @class */ (function () {
|
|
7304
|
+
function BooleanSwitchFieldComponent() {
|
|
7012
7305
|
}
|
|
7013
7306
|
__decorate([
|
|
7014
7307
|
core.Input()
|
|
7015
|
-
],
|
|
7308
|
+
], BooleanSwitchFieldComponent.prototype, "field", void 0);
|
|
7016
7309
|
__decorate([
|
|
7017
7310
|
core.Input()
|
|
7018
|
-
],
|
|
7019
|
-
|
|
7311
|
+
], BooleanSwitchFieldComponent.prototype, "formControl", void 0);
|
|
7312
|
+
BooleanSwitchFieldComponent = __decorate([
|
|
7020
7313
|
core.Component({
|
|
7021
|
-
template: "<
|
|
7022
|
-
})
|
|
7023
|
-
],
|
|
7024
|
-
return
|
|
7025
|
-
}());
|
|
7026
|
-
|
|
7027
|
-
var
|
|
7028
|
-
function
|
|
7029
|
-
|
|
7030
|
-
this._messageService = _messageService;
|
|
7031
|
-
}
|
|
7032
|
-
IAssistService.prototype.askIA = function (context, data) {
|
|
7033
|
-
var _this = this;
|
|
7034
|
-
return this.http.post("platform/iassist/api/latest/completions", {
|
|
7035
|
-
"prompt": this._createPrompt(context, data),
|
|
7036
|
-
"provider": "OPEN_AI",
|
|
7037
|
-
"parameters": {
|
|
7038
|
-
"model": "gpt-3.5-turbo",
|
|
7039
|
-
"max_tokens": 700,
|
|
7040
|
-
"temperature": 1
|
|
7041
|
-
}
|
|
7042
|
-
}).pipe(operators.catchError(function (err) {
|
|
7043
|
-
_this._messageService.add({
|
|
7044
|
-
severity: "error",
|
|
7045
|
-
summary: err.status ? String(err.status) : "Error",
|
|
7046
|
-
detail: (err.error && err.error.message) || err.statusText || err.message || "Error",
|
|
7047
|
-
});
|
|
7048
|
-
return rxjs.throwError(err);
|
|
7049
|
-
}));
|
|
7050
|
-
};
|
|
7051
|
-
IAssistService.prototype._createPrompt = function (context, data) {
|
|
7052
|
-
return "Crie um texto gen\u00E9rico para preencher o campo de textarea.\n " + (data.label ? "O campo tem o label " + data.label + "." : "") + "\n " + (data.id ? "O campo tem o id " + data.id + "." : "") + "\n " + (data.placeholder ? "Considere as instru\u00E7\u00F5es/sugest\u00F5es do placeholder: " + data.placeholder + "." : "") + "\n Baseie-se no contexto informado pelo usu\u00E1rio: '" + context + "'.\n O texto deve ser formal e conter informa\u00E7\u00F5es pertinentes a um campo como este, como se um usu\u00E1rio real tivesse preenchido com as informa\u00E7\u00F5es necess\u00E1rias. \n O texto deve ser neutro com rela\u00E7\u00E3o a generos, ra\u00E7as, religi\u00F5es, etc.\n O texto deve ser impessoal e n\u00E3o deve conter informa\u00E7\u00F5es pessoais do usu\u00E1rio.\n N\u00E3o direcione o texto a ningu\u00E9m, n\u00E3o use express\u00F5es como: caro, atenciosamente. gostaria, agrade\u00E7o. O texto deve ser gen\u00E9rico.\n \n Exemplos de texto:\n Um campo de descri\u00E7\u00E3o de usu\u00E1rio: \"Usu\u00E1rio com 20 anos, estudante de engenharia, gosta de jogar futebol e assistir filmes.\"\n Outro exemplo de descri\u00E7\u00E3o de usu\u00E1rio: \"Usu\u00E1rio administrador, com acesso total ao sistema, respons\u00E1vel por gerenciar os usu\u00E1rios e os produtos.\"\n Um campo de descri\u00E7\u00E3o de um produto: \"O produto \u00E9 um celular, com tela de 6 polegadas, 128GB de armazenamento, 4GB de mem\u00F3ria RAM, c\u00E2mera de 12MP e bateria de 4000mAh.\"\n Outro exemplo de descri\u00E7\u00E3o de produto: \"O produto \u00E9 uma geladeira, com capacidade de 500 litros, 2 portas, cor branca, com freezer e gaveta de legumes.\"\n Outro exemplo de descri\u00E7\u00E3o de produto: \"O produto \u00E9 uma camiseta, tamanho M, cor azul, 100% algod\u00E3o, com estampa de um gato.\"\n \n Em caso de contexto incompleto crie um texto gen\u00E9rico, como se fosse um exemplo de preenchimento do campo.\n O texto \u00E9 para um campo de textarea, ent\u00E3o escreva um texto sucinto.\n Exiba apenas o texto do output";
|
|
7053
|
-
};
|
|
7054
|
-
IAssistService.ctorParameters = function () { return [
|
|
7055
|
-
{ type: http.HttpClient },
|
|
7056
|
-
{ type: api.MessageService }
|
|
7057
|
-
]; };
|
|
7058
|
-
IAssistService = __decorate([
|
|
7059
|
-
core.Injectable()
|
|
7060
|
-
], IAssistService);
|
|
7061
|
-
return IAssistService;
|
|
7062
|
-
}());
|
|
7063
|
-
|
|
7064
|
-
var TextAreaIAFieldComponent = /** @class */ (function () {
|
|
7065
|
-
function TextAreaIAFieldComponent(_iassistService, _formBuilder, _translateService) {
|
|
7066
|
-
this._iassistService = _iassistService;
|
|
7067
|
-
this._formBuilder = _formBuilder;
|
|
7068
|
-
this._translateService = _translateService;
|
|
7069
|
-
this.isVisible = false;
|
|
7070
|
-
this.isLoading = false;
|
|
7071
|
-
}
|
|
7072
|
-
TextAreaIAFieldComponent.prototype.ngOnInit = function () {
|
|
7073
|
-
this._createDialogFields();
|
|
7074
|
-
this._createDialogFormGroup();
|
|
7075
|
-
};
|
|
7076
|
-
TextAreaIAFieldComponent.prototype.showDialog = function () {
|
|
7077
|
-
this.isVisible = true;
|
|
7078
|
-
};
|
|
7079
|
-
TextAreaIAFieldComponent.prototype.onHideDialog = function () {
|
|
7080
|
-
this.formGroup.get("context").setValue("");
|
|
7081
|
-
};
|
|
7082
|
-
TextAreaIAFieldComponent.prototype.hideDialog = function () {
|
|
7083
|
-
this.isVisible = false;
|
|
7084
|
-
};
|
|
7085
|
-
TextAreaIAFieldComponent.prototype.submitContext = function () {
|
|
7086
|
-
var _this = this;
|
|
7087
|
-
var context = this.formGroup.get("context");
|
|
7088
|
-
this.isLoading = true;
|
|
7089
|
-
this._iassistService.askIA(context.value, {
|
|
7090
|
-
id: this.field.id,
|
|
7091
|
-
label: this.field.label,
|
|
7092
|
-
placeholder: this.field.placeholder,
|
|
7093
|
-
})
|
|
7094
|
-
.pipe(operators.catchError(function (err) {
|
|
7095
|
-
_this.isLoading = false;
|
|
7096
|
-
return rxjs.throwError(err);
|
|
7097
|
-
}))
|
|
7098
|
-
.subscribe(function (res) {
|
|
7099
|
-
_this.formControl.setValue(res.text);
|
|
7100
|
-
_this.isLoading = false;
|
|
7101
|
-
});
|
|
7102
|
-
this.hideDialog();
|
|
7103
|
-
};
|
|
7104
|
-
TextAreaIAFieldComponent.prototype._createDialogFields = function () {
|
|
7105
|
-
this.fields = [
|
|
7106
|
-
new FormField({
|
|
7107
|
-
name: "context",
|
|
7108
|
-
type: exports.FieldType.String,
|
|
7109
|
-
label: this._translateService.instant("platform.angular_components.context"),
|
|
7110
|
-
size: { sm: 12, md: 12, lg: 12, xl: 12 },
|
|
7111
|
-
}),
|
|
7112
|
-
];
|
|
7113
|
-
};
|
|
7114
|
-
TextAreaIAFieldComponent.prototype._createDialogFormGroup = function () {
|
|
7115
|
-
this.formGroup = this._formBuilder.group({
|
|
7116
|
-
context: [""],
|
|
7117
|
-
});
|
|
7118
|
-
};
|
|
7119
|
-
TextAreaIAFieldComponent.ctorParameters = function () { return [
|
|
7120
|
-
{ type: IAssistService },
|
|
7121
|
-
{ type: forms.FormBuilder },
|
|
7122
|
-
{ type: core$1.TranslateService }
|
|
7123
|
-
]; };
|
|
7314
|
+
template: "<div class=\"ui-grid ui-grid-responsive ui-grid-pad ui-fluid\">\n <div class=\"ui-grid-row\">\n <div class=\"i-grid-col-1\">\n <s-switch\n [id]=\"(field.id || field.name)\"\n [inputName]=\"field.name\"\n [formControl]=\"formControl\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n (valueChanged)=\"field.onChange ? field.onChange($event) : null\">\n </s-switch>\n </div>\n <div class=\"i-grid-col-1\" *ngIf=\"field.optionsLabel\">\n <ng-container *ngIf=\"formControl.value; else caseFalse\">\n <span>{{ field.optionsLabel.true }}</span>\n </ng-container>\n <ng-template #caseFalse>\n <span>{{ field.optionsLabel.false }}</span>\n </ng-template>\n </div>\n </div>\n</div>"
|
|
7315
|
+
})
|
|
7316
|
+
], BooleanSwitchFieldComponent);
|
|
7317
|
+
return BooleanSwitchFieldComponent;
|
|
7318
|
+
}());
|
|
7319
|
+
|
|
7320
|
+
var CalendarFieldComponent = /** @class */ (function () {
|
|
7321
|
+
function CalendarFieldComponent() {
|
|
7322
|
+
}
|
|
7124
7323
|
__decorate([
|
|
7125
7324
|
core.Input()
|
|
7126
|
-
],
|
|
7325
|
+
], CalendarFieldComponent.prototype, "field", void 0);
|
|
7127
7326
|
__decorate([
|
|
7128
7327
|
core.Input()
|
|
7129
|
-
],
|
|
7130
|
-
|
|
7328
|
+
], CalendarFieldComponent.prototype, "formControl", void 0);
|
|
7329
|
+
__decorate([
|
|
7330
|
+
core.Input()
|
|
7331
|
+
], CalendarFieldComponent.prototype, "showTime", void 0);
|
|
7332
|
+
__decorate([
|
|
7333
|
+
core.Input()
|
|
7334
|
+
], CalendarFieldComponent.prototype, "timeOnly", void 0);
|
|
7335
|
+
CalendarFieldComponent = __decorate([
|
|
7131
7336
|
core.Component({
|
|
7132
|
-
template: "<
|
|
7133
|
-
styles: [".footer-content{display:-ms-flexbox;display:flex;-ms-flex-positive:0;flex-grow:0}.textarea-ia{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;gap:8px}.iassist-button{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;border:none;border-radius:50%;box-shadow:none;cursor:pointer;height:32px;width:32px}.dialog-header{display:-ms-flexbox;display:flex;gap:12px}.dialog-header .iassist-icon{display:block;height:24px;width:24px}"]
|
|
7337
|
+
template: "<div\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\">\n <!-- Remover as propriedades [showTransitionOptions] e [hideTransitionOptions] quando atualizar para o PrimeNG v10, esses atributos foram\n usados para remover um bug ocasionado pela anima\u00E7\u00E3o do componente p-calendar, bug explicado nas issues: #ERPROM-5534, #ERPROM-8248 e #DSN-1045. -->\n <p-calendar\n #calendar\n sCalendarMask\n [inputId]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [showIcon]=\"true\"\n [timeOnly]=\"timeOnly\"\n [selectionMode]=\"field.selectionMode\"\n [rangeSeparator]=\"field.rangeSeparator\"\n [showTime]=\"showTime\"\n [showSeconds]=\"field.showSeconds\"\n [showOnFocus]=\"field.showOnFocus\"\n [formControl]=\"formControl\"\n [icon]=\"timeOnly ? 'fa fa-clock' : 'fa fa-calendar'\"\n [minDate]=\"field.minDate\"\n [maxDate]=\"field.maxDate\"\n [defaultDate]=\"field.defaultDate\"\n [locale]=\"field.calendarLocaleOptions\"\n [dateFormat]=\"field.calendarLocaleOptions.dateFormat\"\n [hourFormat]=\"field.calendarLocaleOptions.hourFormat\"\n [view]=\"field.view\"\n [placeholder]=\"field.placeholder\"\n inputStyleClass=\"mousetrap\"\n [appendTo]=\"field.appendTo\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event): null\"\n (onSelect)=\"field.onSelect ? field.onSelect($event) : null\"\n (onClose)=\"field.onClose ? field.onClose($event) : null\"\n (onTodayClick)=\"field.onTodayClick ? field.onTodayClick($event) : null\"\n (onClearClick)=\"field.onClearClick ? field.onClearClick($event) : null\"\n (onMonthChange)=\"field.onMonthChange ? field.onMonthChange($event) : null\"\n (onYearChange)=\"field.onYearChange ? field.onYearChange($event) : null\"\n [showTransitionOptions]=\"'0ms'\"\n [hideTransitionOptions]=\"'0ms'\">\n </p-calendar>\n</div>\n"
|
|
7134
7338
|
})
|
|
7135
|
-
],
|
|
7136
|
-
return
|
|
7339
|
+
], CalendarFieldComponent);
|
|
7340
|
+
return CalendarFieldComponent;
|
|
7137
7341
|
}());
|
|
7138
7342
|
|
|
7139
|
-
var
|
|
7140
|
-
|
|
7141
|
-
|
|
7142
|
-
|
|
7143
|
-
|
|
7144
|
-
_this.onFocus = new core.EventEmitter();
|
|
7145
|
-
_this.onComplete = new core.EventEmitter();
|
|
7146
|
-
_this.ngUnsubscribe = new rxjs.Subject();
|
|
7147
|
-
return _this;
|
|
7343
|
+
var ChipsFieldComponent = /** @class */ (function () {
|
|
7344
|
+
function ChipsFieldComponent(clipboard) {
|
|
7345
|
+
this.clipboard = clipboard;
|
|
7346
|
+
this.feedbackMessageVisible = false;
|
|
7347
|
+
this.copyButtonVisible = true;
|
|
7148
7348
|
}
|
|
7149
|
-
|
|
7349
|
+
ChipsFieldComponent.prototype.onCopyFieldContent = function () {
|
|
7150
7350
|
var _this = this;
|
|
7151
|
-
|
|
7152
|
-
|
|
7153
|
-
|
|
7154
|
-
|
|
7155
|
-
|
|
7156
|
-
|
|
7157
|
-
|
|
7158
|
-
|
|
7159
|
-
|
|
7160
|
-
if (
|
|
7161
|
-
|
|
7162
|
-
|
|
7163
|
-
|
|
7164
|
-
TextFieldComponent.prototype.ngOnDestroy = function () {
|
|
7165
|
-
this.ngUnsubscribe.next();
|
|
7166
|
-
this.ngUnsubscribe.complete();
|
|
7351
|
+
if (this.formControl.value) {
|
|
7352
|
+
this.copyButtonVisible = false;
|
|
7353
|
+
this.feedbackMessageVisible = true;
|
|
7354
|
+
setTimeout(function () {
|
|
7355
|
+
_this.feedbackMessageVisible = false;
|
|
7356
|
+
_this.copyButtonVisible = true;
|
|
7357
|
+
}, 3000);
|
|
7358
|
+
var content = this.formControl.value.join(this.field.separator || "\n");
|
|
7359
|
+
this.clipboard.copy(content);
|
|
7360
|
+
if (this.field.onCopy) {
|
|
7361
|
+
this.field.onCopy(content);
|
|
7362
|
+
}
|
|
7363
|
+
}
|
|
7167
7364
|
};
|
|
7365
|
+
ChipsFieldComponent.ctorParameters = function () { return [
|
|
7366
|
+
{ type: clipboard.Clipboard }
|
|
7367
|
+
]; };
|
|
7168
7368
|
__decorate([
|
|
7169
7369
|
core.Input()
|
|
7170
|
-
],
|
|
7370
|
+
], ChipsFieldComponent.prototype, "field", void 0);
|
|
7171
7371
|
__decorate([
|
|
7172
7372
|
core.Input()
|
|
7173
|
-
],
|
|
7174
|
-
__decorate([
|
|
7175
|
-
core.Output()
|
|
7176
|
-
], TextFieldComponent.prototype, "onInput", void 0);
|
|
7177
|
-
__decorate([
|
|
7178
|
-
core.Output()
|
|
7179
|
-
], TextFieldComponent.prototype, "onFocus", void 0);
|
|
7180
|
-
__decorate([
|
|
7181
|
-
core.Output()
|
|
7182
|
-
], TextFieldComponent.prototype, "onComplete", void 0);
|
|
7183
|
-
TextFieldComponent = __decorate([
|
|
7373
|
+
], ChipsFieldComponent.prototype, "formControl", void 0);
|
|
7374
|
+
ChipsFieldComponent = __decorate([
|
|
7184
7375
|
core.Component({
|
|
7185
|
-
template: "<
|
|
7186
|
-
|
|
7187
|
-
styles: ["s-text-field.ng-dirty.ng-invalid .ui-inputtext{border-color:#c13018}s-text-field.ng-dirty.ng-invalid .ui-inputtext:hover{border-color:#e44328}"]
|
|
7376
|
+
template: "<div class=\"chips-field-wrapper\">\n <div style=\"width: 100%;\">\n <p-chips\n *ngIf=\"field.keyFilter\"\n [inputId]=\"(field.id || field.name)\"\n [formControl]=\"formControl\"\n [placeholder]=\"field.placeholder\"\n [allowDuplicate]=\"false\"\n [addOnTab]=\"true\"\n [addOnBlur]=\"true\"\n (onAdd)=\"field.onAdd ? field.onAdd($event) : null\"\n (onRemove)=\"field.onRemove ? field.onRemove($event) : null\"\n (onChipClick)=\"field.onChipClick ? field.onChipClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n [pKeyFilter]=\"field.keyFilter\">\n <ng-template let-item pTemplate=\"item\">\n <span\n class=\"chip-content\"\n [sTooltip]=\"item\">\n {{ item }}\n </span>\n </ng-template>\n </p-chips>\n \n <p-chips\n *ngIf=\"!field.keyFilter\"\n [inputId]=\"(field.id || field.name)\"\n [formControl]=\"formControl\"\n [placeholder]=\"field.placeholder\"\n [allowDuplicate]=\"false\"\n [addOnTab]=\"true\"\n [addOnBlur]=\"true\"\n (onAdd)=\"field.onAdd ? field.onAdd($event) : null\"\n (onRemove)=\"field.onRemove ? field.onRemove($event) : null\"\n (onChipClick)=\"field.onChipClick ? field.onChipClick($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n <ng-template let-item pTemplate=\"item\">\n <span\n class=\"chip-content\"\n [sTooltip]=\"item\">\n {{ item }}\n </span>\n </ng-template>\n </p-chips>\n </div>\n \n <button\n *ngIf=\"field.showCopyButton && formControl.value?.length > 0 && copyButtonVisible\"\n class=\"copy-content-button\"\n (click)=\"onCopyFieldContent()\">\n {{ \"platform.angular_components.copy_field_content\" | translate }}\n </button>\n \n <span\n *ngIf=\"feedbackMessageVisible\"\n class=\"feedback-message\">\n {{ \"platform.angular_components.copied_to_clipboard\" | translate }}\n </span>\n</div>\n",
|
|
7377
|
+
styles: [".chips-field-wrapper{-ms-flex-align:start;align-items:flex-start;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.chips-field-wrapper .chip-content{display:block;overflow:hidden;padding-right:1rem;text-overflow:ellipsis}.chips-field-wrapper .copy-content-button{background-color:transparent;border:none;color:#2a6496;cursor:pointer;margin-top:8px}.chips-field-wrapper .feedback-message{color:#0c9348;display:block;margin-top:8px;-webkit-user-select:none;-ms-user-select:none;user-select:none}"]
|
|
7188
7378
|
})
|
|
7189
|
-
],
|
|
7190
|
-
return
|
|
7191
|
-
}(
|
|
7379
|
+
], ChipsFieldComponent);
|
|
7380
|
+
return ChipsFieldComponent;
|
|
7381
|
+
}());
|
|
7192
7382
|
|
|
7193
|
-
var
|
|
7194
|
-
function
|
|
7383
|
+
var CountryPhonePickerFieldComponent = /** @class */ (function () {
|
|
7384
|
+
function CountryPhonePickerFieldComponent() {
|
|
7195
7385
|
}
|
|
7196
|
-
RowComponent.prototype.ngOnInit = function () { };
|
|
7197
|
-
RowComponent.prototype.getErrorMessages = function (errorMessages) {
|
|
7198
|
-
if (errorMessages)
|
|
7199
|
-
return this.isFunction(errorMessages) ? errorMessages() : errorMessages;
|
|
7200
|
-
return this.errorMessages;
|
|
7201
|
-
};
|
|
7202
|
-
RowComponent.prototype.isFunction = function (value) {
|
|
7203
|
-
return value instanceof Function;
|
|
7204
|
-
};
|
|
7205
7386
|
__decorate([
|
|
7206
7387
|
core.Input()
|
|
7207
|
-
],
|
|
7388
|
+
], CountryPhonePickerFieldComponent.prototype, "field", void 0);
|
|
7208
7389
|
__decorate([
|
|
7209
7390
|
core.Input()
|
|
7210
|
-
],
|
|
7391
|
+
], CountryPhonePickerFieldComponent.prototype, "formControl", void 0);
|
|
7392
|
+
CountryPhonePickerFieldComponent = __decorate([
|
|
7393
|
+
core.Component({
|
|
7394
|
+
template: "<s-country-phone-picker\n [formControl]=\"formControl\"\n [ordination]=\"field.ordination\"\n [countries]=\"field.countries\"\n (selected)=\"field.onSelected\"\n (focusLost)=\"field.onFocusLost\">\n</s-country-phone-picker>"
|
|
7395
|
+
})
|
|
7396
|
+
], CountryPhonePickerFieldComponent);
|
|
7397
|
+
return CountryPhonePickerFieldComponent;
|
|
7398
|
+
}());
|
|
7399
|
+
|
|
7400
|
+
/**
|
|
7401
|
+
* @deprecated Should use bignumber instead
|
|
7402
|
+
*/
|
|
7403
|
+
var CurrencyFieldComponent = /** @class */ (function (_super) {
|
|
7404
|
+
__extends(CurrencyFieldComponent, _super);
|
|
7405
|
+
function CurrencyFieldComponent() {
|
|
7406
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
7407
|
+
}
|
|
7211
7408
|
__decorate([
|
|
7212
7409
|
core.Input()
|
|
7213
|
-
],
|
|
7410
|
+
], CurrencyFieldComponent.prototype, "field", void 0);
|
|
7214
7411
|
__decorate([
|
|
7215
7412
|
core.Input()
|
|
7216
|
-
],
|
|
7217
|
-
|
|
7413
|
+
], CurrencyFieldComponent.prototype, "formControl", void 0);
|
|
7414
|
+
CurrencyFieldComponent = __decorate([
|
|
7218
7415
|
core.Component({
|
|
7219
|
-
template: "
|
|
7416
|
+
template: "<div class=\"ui-inputgroup\">\n <span\n *ngIf=\"field.numberLocaleOptions.currencySymbol\"\n class=\"ui-inputgroup-addon\">\n {{ field.numberLocaleOptions.currencySymbol }}\n </span>\n <input\n *ngIf=\"!field.mask\"\n type=\"text\"\n [id]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [formControl]=\"formControl\"\n sNumberInput\n [precision]=\"isFunction(field.precision) ? trigger(field.precision) : field.precision\"\n [scale]=\"isFunction(field.scale) ? trigger(field.scale) : field.scale\"\n [decimalSeparator]=\"field.numberLocaleOptions.decimalSeparator\"\n [thousandsSeparator]=\"field.numberLocaleOptions.thousandsSeparator\"\n [alignTo]=\"field.alignTo\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [placeholder]=\"field.placeholder\"\n [showDelay]=\"500\"\n pInputText\n [autocomplete]=\"field.browserAutocomplete ? 'on' : 'off'\"\n [ngClass]=\"'mousetrap'\"\n (blur)=\"field.onBlur ? field.onBlur($event) : null\"\n (focus)=\"field.onFocus ? field.onFocus($event): null\" />\n <p-inputMask\n *ngIf=\"field.mask\"\n type=\"text\"\n [inputId]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [formControl]=\"formControl\"\n [mask]=\"field.mask\"\n [placeholder]=\"field.placeholder\"\n slotChar=\"_\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\"\n styleClass=\"mousetrap\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n (onFocus)=\"field.onFocus ? field.onFocus($event): null\"\n (onComplete)=\"field.onComplete ? field.onComplete($event) : null\"\n (onInput)=\"field.onInput ? field.onInput($event) : null\" >\n </p-inputMask>\n</div>\n"
|
|
7220
7417
|
})
|
|
7221
|
-
],
|
|
7222
|
-
return
|
|
7223
|
-
}());
|
|
7418
|
+
], CurrencyFieldComponent);
|
|
7419
|
+
return CurrencyFieldComponent;
|
|
7420
|
+
}(BaseFieldComponent));
|
|
7224
7421
|
|
|
7225
7422
|
var FieldsetComponent = /** @class */ (function () {
|
|
7226
7423
|
function FieldsetComponent() {
|
|
@@ -7246,79 +7443,45 @@
|
|
|
7246
7443
|
return FieldsetComponent;
|
|
7247
7444
|
}());
|
|
7248
7445
|
|
|
7249
|
-
var
|
|
7250
|
-
|
|
7446
|
+
var FileUploadComponent$1 = /** @class */ (function (_super) {
|
|
7447
|
+
__extends(FileUploadComponent, _super);
|
|
7448
|
+
function FileUploadComponent() {
|
|
7449
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
7251
7450
|
}
|
|
7252
7451
|
__decorate([
|
|
7253
7452
|
core.Input()
|
|
7254
|
-
],
|
|
7255
|
-
__decorate([
|
|
7256
|
-
core.Input()
|
|
7257
|
-
], SectionComponent.prototype, "config", void 0);
|
|
7258
|
-
__decorate([
|
|
7259
|
-
core.Input()
|
|
7260
|
-
], SectionComponent.prototype, "group", void 0);
|
|
7453
|
+
], FileUploadComponent.prototype, "field", void 0);
|
|
7261
7454
|
__decorate([
|
|
7262
7455
|
core.Input()
|
|
7263
|
-
],
|
|
7264
|
-
|
|
7456
|
+
], FileUploadComponent.prototype, "formControl", void 0);
|
|
7457
|
+
FileUploadComponent = __decorate([
|
|
7265
7458
|
core.Component({
|
|
7266
|
-
template: "
|
|
7459
|
+
template: "<s-file-upload [id]=\"(field.id || field.name)\" [accept]=\"field.accept\" [files]=\"field.files\" [multiple]=\"field.multiple\"\n [chooseLabel]=\"field.chooseLabel\" [removeLabel]=\"field.removeLabel\" [cancelLabel]=\"field.cancelLabel\"\n [successTooltip]=\"field.successTooltip\" (uploadHandler)=\"field.onUploadFile($event, field)\"\n (removeFile)=\"field.onRemoveFile($event, field)\" (cancelUpload)=\"field.onCancelUpload($event, field)\"\n (downloadFile)=\"field.onDownloadFile($event, field)\" [formGroup]=\"formControl\"\n [showFileUploadDate]=\"field.showFileUploadDate\"> \n</s-file-upload>\n"
|
|
7267
7460
|
})
|
|
7268
|
-
],
|
|
7269
|
-
return
|
|
7270
|
-
}());
|
|
7461
|
+
], FileUploadComponent);
|
|
7462
|
+
return FileUploadComponent;
|
|
7463
|
+
}(BaseFieldComponent));
|
|
7271
7464
|
|
|
7272
|
-
var
|
|
7273
|
-
function
|
|
7465
|
+
var LookupFieldComponent = /** @class */ (function () {
|
|
7466
|
+
function LookupFieldComponent() {
|
|
7274
7467
|
}
|
|
7275
|
-
DynamicFieldComponent.prototype.getErrorMessages = function (errorMessages) {
|
|
7276
|
-
if (errorMessages)
|
|
7277
|
-
return this.isFunction(errorMessages)
|
|
7278
|
-
? __assign(__assign({}, this.errorMessages), errorMessages()) : __assign(__assign({}, this.errorMessages), errorMessages);
|
|
7279
|
-
return this.errorMessages;
|
|
7280
|
-
};
|
|
7281
|
-
DynamicFieldComponent.prototype.isFunction = function (value) {
|
|
7282
|
-
return value instanceof Function;
|
|
7283
|
-
};
|
|
7284
|
-
__decorate([
|
|
7285
|
-
core.Input()
|
|
7286
|
-
], DynamicFieldComponent.prototype, "id", void 0);
|
|
7287
|
-
__decorate([
|
|
7288
|
-
core.Input()
|
|
7289
|
-
], DynamicFieldComponent.prototype, "fields", void 0);
|
|
7290
|
-
__decorate([
|
|
7291
|
-
core.Input()
|
|
7292
|
-
], DynamicFieldComponent.prototype, "form", void 0);
|
|
7293
7468
|
__decorate([
|
|
7294
7469
|
core.Input()
|
|
7295
|
-
],
|
|
7470
|
+
], LookupFieldComponent.prototype, "field", void 0);
|
|
7296
7471
|
__decorate([
|
|
7297
7472
|
core.Input()
|
|
7298
|
-
],
|
|
7299
|
-
|
|
7473
|
+
], LookupFieldComponent.prototype, "formControl", void 0);
|
|
7474
|
+
LookupFieldComponent = __decorate([
|
|
7300
7475
|
core.Component({
|
|
7301
|
-
|
|
7302
|
-
template: "<div class=\"ui-fluid\" [formGroup]=\"form\">\n <div class=\"ui-g\">\n <ng-container *ngFor=\"let field of fields\">\n <div\n *ngIf=\"!field.visible || field.visible()\"\n [ngClass]=\"field.gridClass\">\n <span *ngIf=\"field.label\">\n <label\n *sInfoSign=\"field.infoSign; displayTime: displayTimeInfoSign\"\n [for]=\"field.name\"\n [ngClass]=\"{ 'required': field.required() }\">\n {{ field.label }}\n </label>\n </span>\n <ng-container *sDynamicForm=\"{\n id: id,\n config: field,\n group: form\n }\">\n </ng-container>\n <s-control-errors\n [form]=\"form\"\n [control]=\"form.controls[field.name]\"\n [errorMessages]=\"getErrorMessages(field.errorMessages)\">\n </s-control-errors>\n <ng-template\n *ngIf=\"field?.bottomTemplate\"\n [ngTemplateOutlet]=\"field.bottomTemplate\">\n </ng-template>\n </div>\n </ng-container>\n </div>\n</div>"
|
|
7476
|
+
template: "<div\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\">\n <s-lookup\n [id]=\"(field.id || field.name)\"\n [multiple]=\"field.multiple\"\n [formControl]=\"formControl\"\n [lookupSuggestions]=\"field.lookupSuggestions\"\n [dataKey]=\"field.dataKey\"\n [placeholder]=\"field.placeholder\"\n [searchFields]=\"field.searchFields\"\n [searchGridFields]=\"field.searchGridFields\"\n [searchGridData]=\"field.gridData\"\n (onLookupRequest)=\"field.onLookupRequest($event)\"\n (onSearchRequest)=\"field.onSearchRequest($event)\"\n [lookupDisplayField]=\"field.lookupDisplayField\"\n [searchTotalRecords]=\"field.searchTotalRecords\"\n [searchTotalRecordsLabel]=\"field.searchTotalRecordsLabel\"\n [searchTitle]=\"field.searchTitle\"\n [selectLabel]=\"field.selectLabel\"\n [searchEmptyTitle]=\"field.searchEmptyTitle\"\n [filterLabel]=\"field.filterLabel\"\n [filterTitle]=\"field.filterTitle\"\n [clearLabel]=\"field.clearLabel\"\n [cancelLabel]=\"field.cancelLabel\"\n [emptyFieldLabel]=\"field.emptyFieldLabel \"\n (onSelect)=\"field.onSelect($event)\"\n (onUnselect)=\"field.onUnselect($event)\"\n (onClear)=\"field.onClear ? field.onClear($event) : null\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n [lookupAppendTo]=\"field.appendTo\"\n [lookupEmptyMessage]=\"field.emptyMessage\"\n [recordLabel]=\"field.recordLabel\"\n [recordsLabel]=\"field.recordsLabel\"\n [defaultFilter]=\"field.defaultFilter\"\n [autocompleteForceSelection]=\"field.autocompleteForceSelection\">\n </s-lookup>\n</div>\n"
|
|
7303
7477
|
})
|
|
7304
|
-
],
|
|
7305
|
-
return
|
|
7478
|
+
], LookupFieldComponent);
|
|
7479
|
+
return LookupFieldComponent;
|
|
7306
7480
|
}());
|
|
7307
7481
|
|
|
7308
|
-
var
|
|
7309
|
-
|
|
7310
|
-
|
|
7311
|
-
})(GridType || (GridType = {}));
|
|
7312
|
-
|
|
7313
|
-
var StructureType;
|
|
7314
|
-
(function (StructureType) {
|
|
7315
|
-
StructureType["Fieldset"] = "Fieldset";
|
|
7316
|
-
StructureType["Section"] = "Section";
|
|
7317
|
-
})(StructureType || (StructureType = {}));
|
|
7318
|
-
|
|
7319
|
-
var BignumberFieldComponent = /** @class */ (function (_super) {
|
|
7320
|
-
__extends(BignumberFieldComponent, _super);
|
|
7321
|
-
function BignumberFieldComponent() {
|
|
7482
|
+
var NumberFieldComponent = /** @class */ (function (_super) {
|
|
7483
|
+
__extends(NumberFieldComponent, _super);
|
|
7484
|
+
function NumberFieldComponent() {
|
|
7322
7485
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
7323
7486
|
_this.onInput = new core.EventEmitter();
|
|
7324
7487
|
_this.onFocus = new core.EventEmitter();
|
|
@@ -7326,35 +7489,33 @@
|
|
|
7326
7489
|
_this.ngUnsubscribe = new rxjs.Subject();
|
|
7327
7490
|
return _this;
|
|
7328
7491
|
}
|
|
7329
|
-
|
|
7492
|
+
NumberFieldComponent.prototype.ngOnInit = function () {
|
|
7330
7493
|
var _this = this;
|
|
7331
|
-
this.onFocus
|
|
7332
|
-
|
|
7333
|
-
.subscribe(function (event) {
|
|
7334
|
-
if (_this.field.onFocus) {
|
|
7494
|
+
this.onFocus.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function (event) {
|
|
7495
|
+
if (_this.field.onFocus)
|
|
7335
7496
|
_this.field.onFocus(event);
|
|
7336
|
-
}
|
|
7337
7497
|
});
|
|
7338
|
-
this.onInput
|
|
7339
|
-
|
|
7340
|
-
.subscribe(function (event) {
|
|
7341
|
-
if (_this.field.onInput) {
|
|
7498
|
+
this.onInput.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function (event) {
|
|
7499
|
+
if (_this.field.onInput)
|
|
7342
7500
|
_this.field.onInput(event);
|
|
7343
|
-
}
|
|
7344
7501
|
});
|
|
7345
|
-
this.onComplete
|
|
7346
|
-
|
|
7347
|
-
.subscribe(function (event) {
|
|
7348
|
-
if (_this.field.onComplete) {
|
|
7502
|
+
this.onComplete.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function (event) {
|
|
7503
|
+
if (_this.field.onComplete)
|
|
7349
7504
|
_this.field.onComplete(event);
|
|
7350
|
-
}
|
|
7351
7505
|
});
|
|
7352
7506
|
};
|
|
7353
|
-
|
|
7507
|
+
NumberFieldComponent.prototype.ngOnDestroy = function () {
|
|
7354
7508
|
this.ngUnsubscribe.next();
|
|
7355
7509
|
this.ngUnsubscribe.complete();
|
|
7356
7510
|
};
|
|
7357
|
-
Object.defineProperty(
|
|
7511
|
+
Object.defineProperty(NumberFieldComponent.prototype, "numberAlignmentOption", {
|
|
7512
|
+
get: function () {
|
|
7513
|
+
return exports.NumberAlignmentOption;
|
|
7514
|
+
},
|
|
7515
|
+
enumerable: true,
|
|
7516
|
+
configurable: true
|
|
7517
|
+
});
|
|
7518
|
+
Object.defineProperty(NumberFieldComponent.prototype, "fieldType", {
|
|
7358
7519
|
get: function () {
|
|
7359
7520
|
return exports.FieldType;
|
|
7360
7521
|
},
|
|
@@ -7363,46 +7524,29 @@
|
|
|
7363
7524
|
});
|
|
7364
7525
|
__decorate([
|
|
7365
7526
|
core.Input()
|
|
7366
|
-
],
|
|
7527
|
+
], NumberFieldComponent.prototype, "field", void 0);
|
|
7367
7528
|
__decorate([
|
|
7368
7529
|
core.Input()
|
|
7369
|
-
],
|
|
7530
|
+
], NumberFieldComponent.prototype, "formControl", void 0);
|
|
7370
7531
|
__decorate([
|
|
7371
7532
|
core.Output()
|
|
7372
|
-
],
|
|
7533
|
+
], NumberFieldComponent.prototype, "onInput", void 0);
|
|
7373
7534
|
__decorate([
|
|
7374
7535
|
core.Output()
|
|
7375
|
-
],
|
|
7536
|
+
], NumberFieldComponent.prototype, "onFocus", void 0);
|
|
7376
7537
|
__decorate([
|
|
7377
7538
|
core.Output()
|
|
7378
|
-
],
|
|
7379
|
-
|
|
7539
|
+
], NumberFieldComponent.prototype, "onComplete", void 0);
|
|
7540
|
+
NumberFieldComponent = __decorate([
|
|
7380
7541
|
core.Component({
|
|
7381
|
-
template: "<p-inputMask\n *ngIf=\"field.mask; else noMask\"\n type=\"text\"\n [inputId]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [mask]=\"isFunction(field.mask) ? field.mask() : field.mask\"\n [placeholder]=\"field.placeholder\"\n slotChar=\"_\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\"\n styleClass=\"mousetrap\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n (onFocus)=\"onFocus.next($event)\"\n (onComplete)=\"onComplete.next($event)\"\n (onInput)=\"onInput.next($event)\"\n [formControl]=\"formControl\"
|
|
7542
|
+
template: "<p-inputMask\n *ngIf=\"field.mask; else noMask\"\n type=\"text\"\n [inputId]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [mask]=\"isFunction(field.mask) ? field.mask() : field.mask\"\n [placeholder]=\"field.placeholder\"\n slotChar=\"_\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\"\n styleClass=\"mousetrap\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n (onFocus)=\"onFocus.next($event)\"\n (onComplete)=\"onComplete.next($event)\"\n (onInput)=\"onInput.next($event)\"\n [formControl]=\"formControl\" >\n</p-inputMask>\n<ng-template #noMask>\n <ng-container>\n <div class=\"ui-inputgroup\">\n <ng-container *ngIf=\"field.leftAddon\">\n <span class=\"ui-inputgroup-addon\">\n <span *ngIf=\"field.leftAddon.label\">{{field.leftAddon.label}}</span>\n <span *ngIf=\"!field.leftAddon.label\" [ngClass]=\"field.leftAddon.icon\"></span>\n </span>\n </ng-container>\n\n <ng-container *ngTemplateOutlet=\"field.type === fieldType.Double && field.alignTo === numberAlignmentOption.LEFT ? localizedNumber : input\"></ng-container>\n\n <ng-container *ngIf=\"field.rightAddon\">\n <span class=\"ui-inputgroup-addon\">\n <span *ngIf=\"field.rightAddon.label\">{{field.rightAddon.label}}</span>\n <span *ngIf=\"!field.rightAddon.label\" [ngClass]=\"field.rightAddon.icon\"></span>\n </span>\n </ng-container>\n </div>\n </ng-container>\n</ng-template>\n<ng-template #input>\n <input\n [id]=\"(field.id || field.name)\"\n type=\"text\"\n [name]=\"field.name\"\n sNumberInput\n [precision]=\"isFunction(field.precision) ? trigger(field.precision) : field.precision\"\n [scale]=\"isFunction(field.scale) ? trigger(field.scale) : field.scale\"\n [decimalSeparator]=\"field.numberLocaleOptions.decimalSeparator\"\n [thousandsSeparator]=\"field.numberLocaleOptions.thousandsSeparator\"\n [alignTo]=\"field.alignTo\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [placeholder]=\"field.placeholder\"\n [showDelay]=\"500\"\n pInputText\n [autocomplete]=\"field.browserAutocomplete ? 'on' : 'off'\"\n [ngClass]=\"'mousetrap'\"\n (blur)=\"field.onBlur ? field.onBlur($event) : null\"\n (focus)=\"onFocus.next($event)\"\n [formControl]=\"formControl\" />\n</ng-template>\n<ng-template #localizedNumber>\n <input\n [id]=\"(field.id || field.name)\"\n type=\"text\"\n [name]=\"field.name\"\n sLocalizedNumberInput\n [precision]=\"isFunction(field.precision) ? trigger(field.precision) : field.precision\"\n [decimalSeparator]=\"field.numberLocaleOptions.decimalSeparator\"\n [thousandsSeparator]=\"field.numberLocaleOptions.thousandsSeparator\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [placeholder]=\"field.placeholder\"\n [showDelay]=\"500\"\n pInputText\n [autocomplete]=\"field.browserAutocomplete ? 'on' : 'off'\"\n [ngClass]=\"'mousetrap'\"\n (blur)=\"field.onBlur ? field.onBlur($event) : null\"\n (focus)=\"onFocus.next($event)\"\n [formControl]=\"formControl\" />\n</ng-template>\n",
|
|
7382
7543
|
encapsulation: core.ViewEncapsulation.None,
|
|
7383
7544
|
styles: ["s-number-field.ng-dirty.ng-invalid .ui-inputtext{border-color:#c13018}s-number-field.ng-dirty.ng-invalid .ui-inputtext:hover{border-color:#e44328}"]
|
|
7384
7545
|
})
|
|
7385
|
-
],
|
|
7386
|
-
return
|
|
7546
|
+
], NumberFieldComponent);
|
|
7547
|
+
return NumberFieldComponent;
|
|
7387
7548
|
}(BaseFieldComponent));
|
|
7388
7549
|
|
|
7389
|
-
var BooleanSwitchFieldComponent = /** @class */ (function () {
|
|
7390
|
-
function BooleanSwitchFieldComponent() {
|
|
7391
|
-
}
|
|
7392
|
-
__decorate([
|
|
7393
|
-
core.Input()
|
|
7394
|
-
], BooleanSwitchFieldComponent.prototype, "field", void 0);
|
|
7395
|
-
__decorate([
|
|
7396
|
-
core.Input()
|
|
7397
|
-
], BooleanSwitchFieldComponent.prototype, "formControl", void 0);
|
|
7398
|
-
BooleanSwitchFieldComponent = __decorate([
|
|
7399
|
-
core.Component({
|
|
7400
|
-
template: "<div class=\"ui-grid ui-grid-responsive ui-grid-pad ui-fluid\">\n <div class=\"ui-grid-row\">\n <div class=\"i-grid-col-1\">\n <s-switch\n [id]=\"(field.id || field.name)\"\n [inputName]=\"field.name\"\n [formControl]=\"formControl\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n (valueChanged)=\"field.onChange ? field.onChange($event) : null\">\n </s-switch>\n </div>\n <div class=\"i-grid-col-1\" *ngIf=\"field.optionsLabel\">\n <ng-container *ngIf=\"formControl.value; else caseFalse\">\n <span>{{ field.optionsLabel.true }}</span>\n </ng-container>\n <ng-template #caseFalse>\n <span>{{ field.optionsLabel.false }}</span>\n </ng-template>\n </div>\n </div>\n</div>"
|
|
7401
|
-
})
|
|
7402
|
-
], BooleanSwitchFieldComponent);
|
|
7403
|
-
return BooleanSwitchFieldComponent;
|
|
7404
|
-
}());
|
|
7405
|
-
|
|
7406
7550
|
var PasswordFieldComponent = /** @class */ (function () {
|
|
7407
7551
|
function PasswordFieldComponent() {
|
|
7408
7552
|
this.onInput = new core.EventEmitter();
|
|
@@ -7463,751 +7607,649 @@
|
|
|
7463
7607
|
return PasswordFieldComponent;
|
|
7464
7608
|
}());
|
|
7465
7609
|
|
|
7466
|
-
var
|
|
7467
|
-
|
|
7468
|
-
|
|
7469
|
-
|
|
7470
|
-
|
|
7471
|
-
_this.onSlideEnd = new core.EventEmitter();
|
|
7472
|
-
_this.ngUnsubscribe = new rxjs.Subject();
|
|
7473
|
-
return _this;
|
|
7610
|
+
var RadioButtonComponent = /** @class */ (function () {
|
|
7611
|
+
function RadioButtonComponent() {
|
|
7612
|
+
this.onClick = new core.EventEmitter();
|
|
7613
|
+
this.onFocus = new core.EventEmitter();
|
|
7614
|
+
this.ngUnsubscribe = new rxjs.Subject();
|
|
7474
7615
|
}
|
|
7475
|
-
|
|
7616
|
+
RadioButtonComponent.prototype.ngOnInit = function () {
|
|
7476
7617
|
var _this = this;
|
|
7477
|
-
|
|
7478
|
-
|
|
7479
|
-
|
|
7480
|
-
if (_this.field.onChange) {
|
|
7481
|
-
_this.field.onChange(event);
|
|
7482
|
-
}
|
|
7618
|
+
this.onFocus.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function (event) {
|
|
7619
|
+
if (_this.field.onFocus)
|
|
7620
|
+
_this.field.onFocus(event);
|
|
7483
7621
|
});
|
|
7484
|
-
this.
|
|
7485
|
-
|
|
7486
|
-
|
|
7487
|
-
_this.field.onSlideEnd(event);
|
|
7488
|
-
}
|
|
7622
|
+
this.onClick.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function (event) {
|
|
7623
|
+
if (_this.field.onClick)
|
|
7624
|
+
_this.field.onClick(event);
|
|
7489
7625
|
});
|
|
7490
|
-
var values = ((_a = this.field) === null || _a === void 0 ? void 0 : _a.range) ? [this.field.min, this.field.max] : this.field.min;
|
|
7491
|
-
this.formControl.setValue((_b = this.field.defaultValue) !== null && _b !== void 0 ? _b : values);
|
|
7492
7626
|
};
|
|
7493
|
-
|
|
7627
|
+
RadioButtonComponent.prototype.ngOnDestroy = function () {
|
|
7494
7628
|
this.ngUnsubscribe.next();
|
|
7495
7629
|
this.ngUnsubscribe.complete();
|
|
7496
7630
|
};
|
|
7497
|
-
|
|
7498
|
-
|
|
7499
|
-
return exports.FieldType;
|
|
7500
|
-
},
|
|
7501
|
-
enumerable: true,
|
|
7502
|
-
configurable: true
|
|
7503
|
-
});
|
|
7504
|
-
SliderFieldComponent.prototype.getRangeLabel = function () {
|
|
7505
|
-
var _a, _b, _c, _d;
|
|
7506
|
-
var _e = __read((_a = this.formControl.value) !== null && _a !== void 0 ? _a : [0, 0], 2), value0 = _e[0], value1 = _e[1];
|
|
7507
|
-
var prefix = (_b = this.field.prefix) !== null && _b !== void 0 ? _b : '';
|
|
7508
|
-
var suffix = (_c = this.field.suffix) !== null && _c !== void 0 ? _c : '';
|
|
7509
|
-
var separator = (_d = this.field.rangeSeparator) !== null && _d !== void 0 ? _d : ' - ';
|
|
7510
|
-
if (!value0 || value0 < this.field.min) {
|
|
7511
|
-
value0 = this.field.min;
|
|
7512
|
-
}
|
|
7513
|
-
if (!value1 || value1 > this.field.max) {
|
|
7514
|
-
value1 = this.field.max;
|
|
7515
|
-
}
|
|
7516
|
-
return "" + prefix + value0 + suffix + separator + prefix + value1 + suffix;
|
|
7517
|
-
};
|
|
7518
|
-
SliderFieldComponent.prototype.getNonRangeLabel = function () {
|
|
7519
|
-
var _a, _b, _c;
|
|
7520
|
-
var value = (_a = this.formControl) === null || _a === void 0 ? void 0 : _a.value;
|
|
7521
|
-
var prefix = (_b = this.field.prefix) !== null && _b !== void 0 ? _b : '';
|
|
7522
|
-
var suffix = (_c = this.field.suffix) !== null && _c !== void 0 ? _c : '';
|
|
7523
|
-
if (!value || value < this.field.min) {
|
|
7524
|
-
value = this.field.min;
|
|
7525
|
-
}
|
|
7526
|
-
if (value > this.field.max) {
|
|
7527
|
-
value = this.field.max;
|
|
7528
|
-
}
|
|
7529
|
-
return "" + prefix + value + suffix;
|
|
7631
|
+
RadioButtonComponent.prototype.onClear = function () {
|
|
7632
|
+
this.formControl.reset();
|
|
7530
7633
|
};
|
|
7531
|
-
Object.defineProperty(SliderFieldComponent.prototype, "label", {
|
|
7532
|
-
get: function () {
|
|
7533
|
-
return this.field.range ? this.getRangeLabel() : this.getNonRangeLabel();
|
|
7534
|
-
},
|
|
7535
|
-
enumerable: true,
|
|
7536
|
-
configurable: true
|
|
7537
|
-
});
|
|
7538
7634
|
__decorate([
|
|
7539
7635
|
core.Input()
|
|
7540
|
-
],
|
|
7636
|
+
], RadioButtonComponent.prototype, "field", void 0);
|
|
7541
7637
|
__decorate([
|
|
7542
7638
|
core.Input()
|
|
7543
|
-
],
|
|
7639
|
+
], RadioButtonComponent.prototype, "formControl", void 0);
|
|
7544
7640
|
__decorate([
|
|
7545
7641
|
core.Output()
|
|
7546
|
-
],
|
|
7642
|
+
], RadioButtonComponent.prototype, "onClick", void 0);
|
|
7547
7643
|
__decorate([
|
|
7548
7644
|
core.Output()
|
|
7549
|
-
],
|
|
7550
|
-
|
|
7645
|
+
], RadioButtonComponent.prototype, "onFocus", void 0);
|
|
7646
|
+
RadioButtonComponent = __decorate([
|
|
7551
7647
|
core.Component({
|
|
7552
|
-
template: "<ng-container>\n <div class=\"
|
|
7553
|
-
|
|
7648
|
+
template: "<ng-container *ngIf=\"field.verticalAlignment;else horizontalAlignment\">\n <div class=\"ui-g\">\n <div\n *ngFor=\"let option of field.options; let i = index\"\n class=\"ui-g-12\">\n <ng-container\n [ngTemplateOutlet]=\"radioButton\"\n [ngTemplateOutletContext]=\"{option: option, index: i}\">\n </ng-container>\n </div>\n <s-button\n *ngIf=\"field.showClear && !field.required() && !formControl.disabled\"\n [label]=\"field.clearLabel || 'Clear selection'\"\n (onClick)=\"onClear()\"\n priority=\"link\">\n </s-button>\n </div>\n</ng-container>\n\n<ng-template #horizontalAlignment>\n <div class=\"ui-g\">\n <ng-container\n *ngFor=\"let option of field.options; let i = index\"\n [ngTemplateOutlet]=\"radioButton\"\n [ngTemplateOutletContext]=\"{option: option, index: i}\">\n </ng-container>\n </div>\n <s-button\n *ngIf=\"field.showClear && !field.required() && !formControl.disabled\"\n class=\"horizontal-clear-option\"\n [label]=\"field.clearLabel || 'Clear selection'\"\n (onClick)=\"onClear()\"\n priority=\"link\">\n </s-button>\n</ng-template>\n\n<ng-template #radioButton let-option=\"option\" let-i=\"index\">\n <p-radioButton\n [name]=\"field.name\"\n [value]=\"option.value\"\n [label]=\"option.label\"\n [formControl]=\"formControl\"\n [inputId]=\"(field.id || field.name) + '-' + i\"\n [sTooltip]=\"field.tooltip\"\n (onClick)=\"onClick.next($event)\"\n (onFocus)=\"onFocus.next($event)\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\">\n </p-radioButton>\n</ng-template>\n",
|
|
7649
|
+
encapsulation: core.ViewEncapsulation.None,
|
|
7650
|
+
styles: ["\n s-button.horizontal-clear-option button {\n width: min-content !important;\n }\n "]
|
|
7554
7651
|
})
|
|
7555
|
-
],
|
|
7556
|
-
return
|
|
7557
|
-
}(
|
|
7652
|
+
], RadioButtonComponent);
|
|
7653
|
+
return RadioButtonComponent;
|
|
7654
|
+
}());
|
|
7558
7655
|
|
|
7559
|
-
var
|
|
7560
|
-
function
|
|
7561
|
-
var group = _a.group, errorMessages = _a.errorMessages;
|
|
7562
|
-
this.group = group;
|
|
7563
|
-
this.errorMessages = errorMessages;
|
|
7656
|
+
var SectionComponent = /** @class */ (function () {
|
|
7657
|
+
function SectionComponent() {
|
|
7564
7658
|
}
|
|
7565
|
-
|
|
7659
|
+
__decorate([
|
|
7660
|
+
core.Input()
|
|
7661
|
+
], SectionComponent.prototype, "id", void 0);
|
|
7662
|
+
__decorate([
|
|
7663
|
+
core.Input()
|
|
7664
|
+
], SectionComponent.prototype, "config", void 0);
|
|
7665
|
+
__decorate([
|
|
7666
|
+
core.Input()
|
|
7667
|
+
], SectionComponent.prototype, "group", void 0);
|
|
7668
|
+
__decorate([
|
|
7669
|
+
core.Input()
|
|
7670
|
+
], SectionComponent.prototype, "errorMessages", void 0);
|
|
7671
|
+
SectionComponent = __decorate([
|
|
7672
|
+
core.Component({
|
|
7673
|
+
template: "\n <h3 *ngIf=\"config?.header\" class=\"sds-section-title\">{{config.header}}</h3>\n <ng-container *ngFor=\"let conf of config.configs\">\n <ng-container *sDynamicForm=\"{ id: id, config: conf, group: group, errorMessages: errorMessages }\"></ng-container>\n </ng-container>\n "
|
|
7674
|
+
})
|
|
7675
|
+
], SectionComponent);
|
|
7676
|
+
return SectionComponent;
|
|
7566
7677
|
}());
|
|
7567
|
-
|
|
7568
|
-
|
|
7569
|
-
|
|
7570
|
-
|
|
7571
|
-
|
|
7572
|
-
group: group,
|
|
7573
|
-
errorMessages: errorMessages,
|
|
7574
|
-
}) || this;
|
|
7575
|
-
_this.field = field;
|
|
7576
|
-
_this.setFieldPropertiesByType();
|
|
7577
|
-
return _this;
|
|
7578
|
-
}
|
|
7579
|
-
DynamicField.prototype.setFieldPropertiesByType = function () {
|
|
7580
|
-
if (this.field.type === exports.FieldType.Integer || this.field.type === exports.FieldType.Double) {
|
|
7581
|
-
this.field.numberLocaleOptions.currencySymbol = "";
|
|
7582
|
-
}
|
|
7583
|
-
};
|
|
7584
|
-
DynamicField.prototype.createComponent = function (resolver, container) {
|
|
7585
|
-
var componentFactory = resolver.resolveComponentFactory(this.getComponent());
|
|
7586
|
-
var component = container.createComponent(componentFactory);
|
|
7587
|
-
component.instance.field = this.field;
|
|
7588
|
-
// Must be this way because some teams use name like "e070emp.codemp"
|
|
7589
|
-
component.instance.formControl = this.group["controls"][this.field.name];
|
|
7590
|
-
component.instance.errorMessages = this.errorMessages;
|
|
7591
|
-
this.setVariablesByType(component);
|
|
7592
|
-
return component;
|
|
7593
|
-
};
|
|
7594
|
-
DynamicField.prototype.setVariablesByType = function (component) {
|
|
7595
|
-
if (this.field.type == exports.FieldType.Time) {
|
|
7596
|
-
component.instance.timeOnly = true;
|
|
7597
|
-
}
|
|
7598
|
-
if ([exports.FieldType.LocalDateTime, exports.FieldType.DateTime, exports.FieldType.Time].includes(this.field.type)) {
|
|
7599
|
-
component.instance.showTime = true;
|
|
7600
|
-
}
|
|
7601
|
-
};
|
|
7602
|
-
DynamicField.prototype.updateVariables = function (component) {
|
|
7603
|
-
component.instance.field = this.field;
|
|
7604
|
-
component.instance.formControl = this.group["controls"][this.field.name];
|
|
7605
|
-
this.setVariablesByType(component);
|
|
7606
|
-
};
|
|
7607
|
-
DynamicField.prototype.getComponent = function () {
|
|
7608
|
-
switch (this.field.type) {
|
|
7609
|
-
case exports.FieldType.Autocomplete:
|
|
7610
|
-
return AutocompleteFieldComponent;
|
|
7611
|
-
case exports.FieldType.Binary:
|
|
7612
|
-
case exports.FieldType.String:
|
|
7613
|
-
return TextFieldComponent;
|
|
7614
|
-
case exports.FieldType.Boolean:
|
|
7615
|
-
return this.field.representedBy === "switch" ? BooleanSwitchFieldComponent : BooleanFieldComponent;
|
|
7616
|
-
case exports.FieldType.Chips:
|
|
7617
|
-
return ChipsFieldComponent;
|
|
7618
|
-
case exports.FieldType.Date:
|
|
7619
|
-
case exports.FieldType.DateTime:
|
|
7620
|
-
case exports.FieldType.LocalDateTime:
|
|
7621
|
-
case exports.FieldType.Time:
|
|
7622
|
-
return CalendarFieldComponent;
|
|
7623
|
-
case exports.FieldType.Number:
|
|
7624
|
-
case exports.FieldType.Integer:
|
|
7625
|
-
case exports.FieldType.Double:
|
|
7626
|
-
return BignumberFieldComponent;
|
|
7627
|
-
case exports.FieldType.Enum:
|
|
7628
|
-
return SelectFieldComponent;
|
|
7629
|
-
case exports.FieldType.Lookup:
|
|
7630
|
-
return LookupFieldComponent;
|
|
7631
|
-
case exports.FieldType.Money:
|
|
7632
|
-
return CurrencyFieldComponent;
|
|
7633
|
-
case exports.FieldType.Radio:
|
|
7634
|
-
return RadioButtonComponent;
|
|
7635
|
-
case exports.FieldType.Text:
|
|
7636
|
-
return TextAreaFieldComponent;
|
|
7637
|
-
case exports.FieldType.TextIA:
|
|
7638
|
-
return TextAreaIAFieldComponent;
|
|
7639
|
-
case exports.FieldType.Password:
|
|
7640
|
-
return PasswordFieldComponent;
|
|
7641
|
-
case exports.FieldType.Blob:
|
|
7642
|
-
return FileUploadComponent$1;
|
|
7643
|
-
case exports.FieldType.Slider:
|
|
7644
|
-
return SliderFieldComponent;
|
|
7645
|
-
case exports.FieldType.Custom:
|
|
7646
|
-
return this.field.CustomFieldComponentClass;
|
|
7647
|
-
default:
|
|
7648
|
-
throw new Error("Trying to use an unsupported type (" + this.field.type + ").");
|
|
7649
|
-
}
|
|
7650
|
-
};
|
|
7651
|
-
return DynamicField;
|
|
7652
|
-
}(DynamicForm));
|
|
7653
|
-
var DynamicStructure = /** @class */ (function (_super) {
|
|
7654
|
-
__extends(DynamicStructure, _super);
|
|
7655
|
-
function DynamicStructure(_a) {
|
|
7656
|
-
var group = _a.group, config = _a.config, errorMessages = _a.errorMessages;
|
|
7657
|
-
var _this = _super.call(this, {
|
|
7658
|
-
group: group,
|
|
7659
|
-
errorMessages: errorMessages,
|
|
7660
|
-
}) || this;
|
|
7661
|
-
_this.config = config;
|
|
7662
|
-
return _this;
|
|
7678
|
+
|
|
7679
|
+
var SelectFieldComponent = /** @class */ (function (_super) {
|
|
7680
|
+
__extends(SelectFieldComponent, _super);
|
|
7681
|
+
function SelectFieldComponent() {
|
|
7682
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
7663
7683
|
}
|
|
7664
|
-
|
|
7665
|
-
|
|
7666
|
-
|
|
7667
|
-
|
|
7668
|
-
|
|
7669
|
-
|
|
7670
|
-
|
|
7671
|
-
|
|
7672
|
-
|
|
7673
|
-
|
|
7674
|
-
|
|
7675
|
-
|
|
7676
|
-
|
|
7677
|
-
|
|
7678
|
-
|
|
7679
|
-
|
|
7680
|
-
|
|
7681
|
-
|
|
7682
|
-
|
|
7683
|
-
|
|
7684
|
-
|
|
7685
|
-
return DynamicStructure;
|
|
7686
|
-
}(DynamicForm));
|
|
7687
|
-
var DynamicGrid = /** @class */ (function (_super) {
|
|
7688
|
-
__extends(DynamicGrid, _super);
|
|
7689
|
-
function DynamicGrid(_a) {
|
|
7690
|
-
var group = _a.group, config = _a.config, errorMessages = _a.errorMessages;
|
|
7691
|
-
var _this = _super.call(this, { group: group, errorMessages: errorMessages }) || this;
|
|
7692
|
-
_this.config = config;
|
|
7684
|
+
__decorate([
|
|
7685
|
+
core.Input()
|
|
7686
|
+
], SelectFieldComponent.prototype, "field", void 0);
|
|
7687
|
+
__decorate([
|
|
7688
|
+
core.Input()
|
|
7689
|
+
], SelectFieldComponent.prototype, "formControl", void 0);
|
|
7690
|
+
SelectFieldComponent = __decorate([
|
|
7691
|
+
core.Component({
|
|
7692
|
+
template: "<p-dropdown\n *ngIf=\"!field.multiple\"\n [inputId]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [options]=\"isFunction(field.options) ? field.options() : field.options\"\n [placeholder]=\"field.placeholder || ' '\"\n [formControl]=\"formControl\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\"\n [showClear]=\"field.showClear\"\n dataKey=\"{{field.dataKey}}\"\n optionLabel=\"{{field.optionLabel}}\"\n [autoDisplayFirst]=\"field.autoDisplayFirst\"\n [appendTo]=\"field.appendTo || 'body'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onChange)=\"field.onChange ? field.onChange($event) : null\">\n</p-dropdown>\n<p-multiSelect\n *ngIf=\"field.multiple\"\n [formControl]=\"formControl\"\n [name]=\"field.name\"\n [inputId]=\"(field.id || field.name)\"\n [options]=\"isFunction(field.options) ? field.options() : field.options\"\n [defaultLabel]=\"field.placeholder\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [emptyFilterMessage]=\"field.emptyMessage || 'Nenhum registro encontrado'\"\n [showDelay]=\"500\"\n [selectedItemsLabel]=\"field.multipleSelectedLabel\"\n [appendTo]=\"field.appendTo || 'body'\"\n (onClick)=\"field.onClick ? field.onClick($event) : null\"\n (onChange)=\"field.onChange ? field.onChange($event) : null\">\n</p-multiSelect>\n\n"
|
|
7693
|
+
})
|
|
7694
|
+
], SelectFieldComponent);
|
|
7695
|
+
return SelectFieldComponent;
|
|
7696
|
+
}(BaseFieldComponent));
|
|
7697
|
+
|
|
7698
|
+
var SliderFieldComponent = /** @class */ (function (_super) {
|
|
7699
|
+
__extends(SliderFieldComponent, _super);
|
|
7700
|
+
function SliderFieldComponent() {
|
|
7701
|
+
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
7702
|
+
_this.onChange = new core.EventEmitter();
|
|
7703
|
+
_this.onSlideEnd = new core.EventEmitter();
|
|
7704
|
+
_this.ngUnsubscribe = new rxjs.Subject();
|
|
7693
7705
|
return _this;
|
|
7694
7706
|
}
|
|
7695
|
-
|
|
7696
|
-
var
|
|
7697
|
-
var
|
|
7698
|
-
|
|
7699
|
-
|
|
7700
|
-
|
|
7701
|
-
|
|
7702
|
-
|
|
7703
|
-
|
|
7704
|
-
|
|
7705
|
-
|
|
7707
|
+
SliderFieldComponent.prototype.ngOnInit = function () {
|
|
7708
|
+
var _this = this;
|
|
7709
|
+
var _a, _b;
|
|
7710
|
+
this.onChange.pipe(operators.takeUntil(this.ngUnsubscribe))
|
|
7711
|
+
.subscribe(function (event) {
|
|
7712
|
+
if (_this.field.onChange) {
|
|
7713
|
+
_this.field.onChange(event);
|
|
7714
|
+
}
|
|
7715
|
+
});
|
|
7716
|
+
this.onSlideEnd.pipe(operators.takeUntil(this.ngUnsubscribe))
|
|
7717
|
+
.subscribe(function (event) {
|
|
7718
|
+
if (_this.field.onSlideEnd) {
|
|
7719
|
+
_this.field.onSlideEnd(event);
|
|
7720
|
+
}
|
|
7721
|
+
});
|
|
7722
|
+
var values = ((_a = this.field) === null || _a === void 0 ? void 0 : _a.range) ? [this.field.min, this.field.max] : this.field.min;
|
|
7723
|
+
this.formControl.setValue((_b = this.field.defaultValue) !== null && _b !== void 0 ? _b : values);
|
|
7706
7724
|
};
|
|
7707
|
-
|
|
7708
|
-
|
|
7709
|
-
|
|
7710
|
-
return RowComponent;
|
|
7711
|
-
default:
|
|
7712
|
-
throw new Error("Trying to use an unsupported type (" + this.config.type + ").");
|
|
7713
|
-
}
|
|
7725
|
+
SliderFieldComponent.prototype.ngOnDestroy = function () {
|
|
7726
|
+
this.ngUnsubscribe.next();
|
|
7727
|
+
this.ngUnsubscribe.complete();
|
|
7714
7728
|
};
|
|
7715
|
-
|
|
7716
|
-
|
|
7717
|
-
|
|
7718
|
-
var DynamicFormDirective = /** @class */ (function () {
|
|
7719
|
-
function DynamicFormDirective(resolver, container) {
|
|
7720
|
-
this.resolver = resolver;
|
|
7721
|
-
this.container = container;
|
|
7722
|
-
}
|
|
7723
|
-
Object.defineProperty(DynamicFormDirective.prototype, "sDynamicForm", {
|
|
7724
|
-
set: function (context) {
|
|
7725
|
-
var id = context.id, config = context.config, group = context.group, errorMessages = context.errorMessages;
|
|
7726
|
-
this.id = id;
|
|
7727
|
-
this.config = config;
|
|
7728
|
-
this.group = group;
|
|
7729
|
-
this.errorMessages = errorMessages;
|
|
7729
|
+
Object.defineProperty(SliderFieldComponent.prototype, "fieldType", {
|
|
7730
|
+
get: function () {
|
|
7731
|
+
return exports.FieldType;
|
|
7730
7732
|
},
|
|
7731
7733
|
enumerable: true,
|
|
7732
7734
|
configurable: true
|
|
7733
7735
|
});
|
|
7734
|
-
|
|
7735
|
-
|
|
7736
|
-
|
|
7737
|
-
|
|
7738
|
-
|
|
7739
|
-
|
|
7740
|
-
|
|
7741
|
-
|
|
7742
|
-
errorMessages: this.errorMessages,
|
|
7743
|
-
});
|
|
7744
|
-
}
|
|
7745
|
-
else if (this.isStructure()) {
|
|
7746
|
-
this.directiveConfig = new DynamicStructure({
|
|
7747
|
-
group: this.group,
|
|
7748
|
-
config: this.config,
|
|
7749
|
-
errorMessages: this.errorMessages,
|
|
7750
|
-
});
|
|
7736
|
+
SliderFieldComponent.prototype.getRangeLabel = function () {
|
|
7737
|
+
var _a, _b, _c, _d;
|
|
7738
|
+
var _e = __read((_a = this.formControl.value) !== null && _a !== void 0 ? _a : [0, 0], 2), value0 = _e[0], value1 = _e[1];
|
|
7739
|
+
var prefix = (_b = this.field.prefix) !== null && _b !== void 0 ? _b : '';
|
|
7740
|
+
var suffix = (_c = this.field.suffix) !== null && _c !== void 0 ? _c : '';
|
|
7741
|
+
var separator = (_d = this.field.rangeSeparator) !== null && _d !== void 0 ? _d : ' - ';
|
|
7742
|
+
if (!value0 || value0 < this.field.min) {
|
|
7743
|
+
value0 = this.field.min;
|
|
7751
7744
|
}
|
|
7752
|
-
|
|
7753
|
-
|
|
7754
|
-
group: this.group,
|
|
7755
|
-
config: this.config,
|
|
7756
|
-
errorMessages: this.errorMessages,
|
|
7757
|
-
});
|
|
7745
|
+
if (!value1 || value1 > this.field.max) {
|
|
7746
|
+
value1 = this.field.max;
|
|
7758
7747
|
}
|
|
7759
|
-
|
|
7760
|
-
throw new Error("Trying to use an unsupported type (" + this.config.type + ").");
|
|
7761
|
-
this.component = this.directiveConfig.createComponent(this.resolver, this.container);
|
|
7762
|
-
this.component.instance.id = this.id;
|
|
7763
|
-
this.component.instance.errorMessages = this.errorMessages;
|
|
7748
|
+
return "" + prefix + value0 + suffix + separator + prefix + value1 + suffix;
|
|
7764
7749
|
};
|
|
7765
|
-
|
|
7766
|
-
|
|
7767
|
-
|
|
7768
|
-
|
|
7750
|
+
SliderFieldComponent.prototype.getNonRangeLabel = function () {
|
|
7751
|
+
var _a, _b, _c;
|
|
7752
|
+
var value = (_a = this.formControl) === null || _a === void 0 ? void 0 : _a.value;
|
|
7753
|
+
var prefix = (_b = this.field.prefix) !== null && _b !== void 0 ? _b : '';
|
|
7754
|
+
var suffix = (_c = this.field.suffix) !== null && _c !== void 0 ? _c : '';
|
|
7755
|
+
if (!value || value < this.field.min) {
|
|
7756
|
+
value = this.field.min;
|
|
7757
|
+
}
|
|
7758
|
+
if (value > this.field.max) {
|
|
7759
|
+
value = this.field.max;
|
|
7769
7760
|
}
|
|
7761
|
+
return "" + prefix + value + suffix;
|
|
7770
7762
|
};
|
|
7771
|
-
|
|
7772
|
-
|
|
7763
|
+
Object.defineProperty(SliderFieldComponent.prototype, "label", {
|
|
7764
|
+
get: function () {
|
|
7765
|
+
return this.field.range ? this.getRangeLabel() : this.getNonRangeLabel();
|
|
7766
|
+
},
|
|
7767
|
+
enumerable: true,
|
|
7768
|
+
configurable: true
|
|
7769
|
+
});
|
|
7770
|
+
__decorate([
|
|
7771
|
+
core.Input()
|
|
7772
|
+
], SliderFieldComponent.prototype, "field", void 0);
|
|
7773
|
+
__decorate([
|
|
7774
|
+
core.Input()
|
|
7775
|
+
], SliderFieldComponent.prototype, "formControl", void 0);
|
|
7776
|
+
__decorate([
|
|
7777
|
+
core.Output()
|
|
7778
|
+
], SliderFieldComponent.prototype, "onChange", void 0);
|
|
7779
|
+
__decorate([
|
|
7780
|
+
core.Output()
|
|
7781
|
+
], SliderFieldComponent.prototype, "onSlideEnd", void 0);
|
|
7782
|
+
SliderFieldComponent = __decorate([
|
|
7783
|
+
core.Component({
|
|
7784
|
+
template: "<ng-container>\n <div class=\"slider-group\">\n <div class=\"slider-label\">\n <span>{{label}}</span>\n </div>\n <p-slider \n [id]=\"(field.id || field.name)\"\n [formControl]=\"formControl\"\n [range]=\"field.range\"\n [orientation]=\"field.orientation\"\n [min]=\"field.min\" \n [max]=\"field.max\"\n [step]=\"field.step\"\n [animate]=\"field.animate\" \n (onChange)=\"field.onChange ? field.onChange($event) : null\"\n (onSlideEnd)=\"field.onSlideEnd ? field.onSlideEnd($event) : null\">\n </p-slider>\n </div>\n</ng-container>",
|
|
7785
|
+
styles: [".slider-label{margin-bottom:5px;margin-left:-10px}.slider-group{margin-left:9px;margin-right:11px}"]
|
|
7786
|
+
})
|
|
7787
|
+
], SliderFieldComponent);
|
|
7788
|
+
return SliderFieldComponent;
|
|
7789
|
+
}(BaseFieldComponent));
|
|
7790
|
+
|
|
7791
|
+
var TextAreaFieldComponent = /** @class */ (function () {
|
|
7792
|
+
function TextAreaFieldComponent() {
|
|
7793
|
+
}
|
|
7794
|
+
__decorate([
|
|
7795
|
+
core.Input()
|
|
7796
|
+
], TextAreaFieldComponent.prototype, "field", void 0);
|
|
7797
|
+
__decorate([
|
|
7798
|
+
core.Input()
|
|
7799
|
+
], TextAreaFieldComponent.prototype, "formControl", void 0);
|
|
7800
|
+
TextAreaFieldComponent = __decorate([
|
|
7801
|
+
core.Component({
|
|
7802
|
+
template: "<textarea\n [id]=\"(field.id || field.name)\"\n *ngIf=\"!field.keyFilter\"\n pInputTextarea\n [rows]=\"field.rows\"\n [cols]=\"field.cols\"\n [formControl]=\"formControl\"\n style=\"resize: vertical;\"\n [ngStyle]=\"field.style\"\n></textarea>\n<textarea\n [id]=\"(field.id || field.name)\"\n *ngIf=\"field.keyFilter\"\n pInputTextarea\n [rows]=\"field.rows\"\n [cols]=\"field.cols\"\n [formControl]=\"formControl\"\n style=\"resize: vertical;\"\n [pKeyFilter]=\"field.keyFilter\"\n [ngStyle]=\"field.style\"\n></textarea>\n"
|
|
7803
|
+
})
|
|
7804
|
+
], TextAreaFieldComponent);
|
|
7805
|
+
return TextAreaFieldComponent;
|
|
7806
|
+
}());
|
|
7807
|
+
|
|
7808
|
+
var TextAreaIAFieldComponent = /** @class */ (function () {
|
|
7809
|
+
function TextAreaIAFieldComponent(_iassistService, _formBuilder, _translateService) {
|
|
7810
|
+
this._iassistService = _iassistService;
|
|
7811
|
+
this._formBuilder = _formBuilder;
|
|
7812
|
+
this._translateService = _translateService;
|
|
7813
|
+
this.isVisible = false;
|
|
7814
|
+
this.isLoading = false;
|
|
7815
|
+
}
|
|
7816
|
+
TextAreaIAFieldComponent.prototype.ngOnInit = function () {
|
|
7817
|
+
this._createDialogFields();
|
|
7818
|
+
this._createDialogFormGroup();
|
|
7773
7819
|
};
|
|
7774
|
-
|
|
7775
|
-
|
|
7820
|
+
TextAreaIAFieldComponent.prototype.showDialog = function () {
|
|
7821
|
+
this.isVisible = true;
|
|
7822
|
+
};
|
|
7823
|
+
TextAreaIAFieldComponent.prototype.onHideDialog = function () {
|
|
7824
|
+
this.formGroup.get("context").setValue("");
|
|
7825
|
+
};
|
|
7826
|
+
TextAreaIAFieldComponent.prototype.hideDialog = function () {
|
|
7827
|
+
this.isVisible = false;
|
|
7828
|
+
};
|
|
7829
|
+
TextAreaIAFieldComponent.prototype.submitContext = function () {
|
|
7830
|
+
var _this = this;
|
|
7831
|
+
var context = this.formGroup.get("context");
|
|
7832
|
+
this.isLoading = true;
|
|
7833
|
+
this._iassistService.askIA(context.value, {
|
|
7834
|
+
id: this.field.id,
|
|
7835
|
+
label: this.field.label,
|
|
7836
|
+
placeholder: this.field.placeholder,
|
|
7837
|
+
})
|
|
7838
|
+
.pipe(operators.catchError(function (err) {
|
|
7839
|
+
_this.isLoading = false;
|
|
7840
|
+
return rxjs.throwError(err);
|
|
7841
|
+
}))
|
|
7842
|
+
.subscribe(function (res) {
|
|
7843
|
+
_this.formControl.setValue(res.text);
|
|
7844
|
+
_this.isLoading = false;
|
|
7845
|
+
});
|
|
7846
|
+
this.hideDialog();
|
|
7847
|
+
};
|
|
7848
|
+
TextAreaIAFieldComponent.prototype._createDialogFields = function () {
|
|
7849
|
+
this.fields = [
|
|
7850
|
+
new FormField({
|
|
7851
|
+
name: "context",
|
|
7852
|
+
type: exports.FieldType.String,
|
|
7853
|
+
label: this._translateService.instant("platform.angular_components.context"),
|
|
7854
|
+
size: { sm: 12, md: 12, lg: 12, xl: 12 },
|
|
7855
|
+
}),
|
|
7856
|
+
];
|
|
7776
7857
|
};
|
|
7777
|
-
|
|
7778
|
-
|
|
7858
|
+
TextAreaIAFieldComponent.prototype._createDialogFormGroup = function () {
|
|
7859
|
+
this.formGroup = this._formBuilder.group({
|
|
7860
|
+
context: [""],
|
|
7861
|
+
});
|
|
7779
7862
|
};
|
|
7780
|
-
|
|
7781
|
-
{ type:
|
|
7782
|
-
{ type:
|
|
7863
|
+
TextAreaIAFieldComponent.ctorParameters = function () { return [
|
|
7864
|
+
{ type: IAssistService },
|
|
7865
|
+
{ type: forms.FormBuilder },
|
|
7866
|
+
{ type: core$1.TranslateService }
|
|
7783
7867
|
]; };
|
|
7784
7868
|
__decorate([
|
|
7785
7869
|
core.Input()
|
|
7786
|
-
],
|
|
7870
|
+
], TextAreaIAFieldComponent.prototype, "field", void 0);
|
|
7787
7871
|
__decorate([
|
|
7788
|
-
core.Input(
|
|
7789
|
-
],
|
|
7790
|
-
|
|
7791
|
-
core.
|
|
7792
|
-
]
|
|
7793
|
-
|
|
7872
|
+
core.Input()
|
|
7873
|
+
], TextAreaIAFieldComponent.prototype, "formControl", void 0);
|
|
7874
|
+
TextAreaIAFieldComponent = __decorate([
|
|
7875
|
+
core.Component({
|
|
7876
|
+
template: "<s-loading-state\n [loading]=\"isLoading\"\n [blockWindow]=\"true\"> \n</s-loading-state>\n\n<p-dialog\n [(visible)]=\"isVisible\"\n [modal]=\"true\"\n [style]=\"{ width: '50vw' }\"\n [draggable]=\"false\"\n [resizable]=\"false\"\n (onHide)=\"onHideDialog()\">\n <p-header>\n <div class=\"dialog-header\">\n <span class=\"iassist-icon\">\n <ng-container [ngTemplateOutlet]=\"iassistIcon\"></ng-container>\n </span>\n {{ 'platform.angular_components.iassist_text_generator' | translate }}\n </div>\n </p-header>\n <s-dynamic-form\n [fields]=\"fields\"\n [form]=\"formGroup\">\n </s-dynamic-form>\n <p-footer>\n <div class=\"footer-content\">\n <s-button\n id=\"-submit-button\"\n type=\"button\"\n [label]=\"'platform.angular_components.generate_text' | translate\"\n (onClick)=\"submitContext()\"\n sTooltip=\"(ALT + SHIFT + S)\"\n showDelay=\"500\">\n </s-button>\n <s-button\n id=\"-cancel-button\"\n type=\"button\"\n priority=\"link\"\n [label]=\"'platform.angular_components.cancel' | translate\"\n (onClick)=\"hideDialog()\"\n sTooltip=\"(ALT + SHIFT + C)\"\n showDelay=\"500\">\n </s-button>\n </div>\n </p-footer>\n</p-dialog>\n\n<div class=\"textarea-ia\">\n <textarea\n [id]=\"(field.id || field.name)\"\n pInputTextarea\n [rows]=\"field.rows\"\n [cols]=\"field.cols\"\n [formControl]=\"formControl\"\n style=\"resize: vertical;\"\n [ngStyle]=\"field.style\">\n </textarea>\n <button\n class=\"iassist-button\"\n (click)=\"showDialog()\"\n [sTooltip]=\"'platform.angular_components.iassist_text_generator' | translate\">\n <ng-container [ngTemplateOutlet]=\"iassistIcon\"></ng-container>\n </button>\n</div>\n\n<ng-template #iassistIcon>\n <svg style=\"width: 100%; height: 100%;\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M5.81451 18.1054L5.99593 17.6059L7.52166 13.4099L7.60877 13.1726L7.61277 13.1614L7.94285 12.2543L8.01159 12.0648L8.05394 11.949L5.2998 8.52426L5.02726 8.18379C5.00569 8.15821 4.9881 8.13104 4.97292 8.10226C4.90099 7.9632 4.85063 7.81294 4.82186 7.6531C4.73075 7.1344 4.90418 6.60771 5.28382 6.24326C5.29421 6.23447 5.3038 6.22567 5.31419 6.21688L5.47164 6.0914L9.3439 3.00238L9.5469 2.84094L9.57088 2.82096L10.4101 2.15041L11.8007 1.04188C11.2181 0.925188 10.6163 0.863647 10.0001 0.863647C4.95374 0.863647 0.863281 4.9541 0.863281 9.99963C0.863281 13.5346 2.87254 16.5989 5.80971 18.1182\" fill=\"#0FA389\"/>\n <path d=\"M14.099 1.83472L13.9495 2.24632L11.997 7.61074L11.9427 7.7594L11.9003 7.87369L14.7448 11.4103C14.7463 11.4127 14.7479 11.4143 14.7495 11.4167L14.9414 11.654C14.9541 11.67 14.9661 11.6868 14.9765 11.7044C15.0764 11.8698 15.1444 12.0505 15.1779 12.2431C15.273 12.7826 15.0812 13.3284 14.676 13.6897C14.656 13.7129 14.6345 13.7344 14.6105 13.7536L11.8563 15.9507L11.6789 16.0922L11.6022 16.1537L10.7406 16.8402V16.841L10.3937 17.1176L9.85747 17.5452L9.39951 17.9112L8.11035 18.9398C8.72016 19.0677 9.35155 19.1364 9.99973 19.1364C15.0461 19.1364 19.1365 15.046 19.1365 9.99964C19.1365 6.42789 17.0857 3.33727 14.099 1.83472Z\" fill=\"#0FA389\"/>\n <path d=\"M14.7287 12.3222C14.7047 12.1832 14.6551 12.0545 14.5864 11.941L14.3954 11.7036C14.3954 11.7036 14.3946 11.7028 14.3938 11.7028L11.3839 7.96005L10.5031 6.86511L10.4256 6.7676L9.03255 5.03487L8.83674 4.79191C8.79278 4.71678 8.75681 4.63446 8.73204 4.54814C8.72085 4.51058 8.71286 4.47222 8.70566 4.43465C8.68568 4.32196 8.68408 4.21007 8.69847 4.10217L8.62334 4.16291L8.44511 4.30438L5.75731 6.44871L5.60066 6.57339C5.34011 6.82275 5.20584 7.19279 5.27218 7.57482C5.29296 7.68751 5.32892 7.79541 5.37927 7.89292C5.37927 7.89292 5.37927 7.89292 5.38007 7.89371L5.6566 8.23818L8.57139 11.8627L8.63293 11.9394L9.53047 13.0559L9.59041 13.1303L9.98363 13.6186L11.0178 14.9046C11.0186 14.9054 11.0194 14.9069 11.0202 14.9077L11.1361 15.0516V15.0524C11.2184 15.1755 11.2768 15.317 11.3048 15.4728C11.3239 15.5807 11.3263 15.6878 11.3143 15.7925L11.3175 15.7965L11.3943 15.735L11.5717 15.5935L14.3266 13.3964L14.3218 13.3908C14.6335 13.1438 14.8022 12.7394 14.7287 12.3222Z\" fill=\"#F3F3F5\"/>\n <path d=\"M10.6822 15.0082C10.6814 15.0074 10.6806 15.0058 10.6806 15.005L10.5672 14.8643L10.3809 14.6325L10.3282 14.567L10.2211 14.4335L9.40028 13.4129L9.32835 13.3242L8.77289 12.6345L8.68098 12.5194L8.44121 12.2205L8.37168 12.4099L8.04159 13.317L8.0376 13.329L7.95128 13.5664L6.42475 17.7623L6.24333 18.2618L5.90605 19.1881L5.73262 19.6645C5.73182 19.6661 5.73102 19.6677 5.73102 19.6685C5.72863 19.6749 5.72703 19.6821 5.72543 19.6885C5.71584 19.7228 5.71424 19.758 5.72063 19.7948C5.74461 19.929 5.87329 20.0193 6.00836 19.9962C6.04112 19.9898 6.07229 19.9778 6.09867 19.9602C6.09867 19.9602 6.09947 19.9602 6.10027 19.9594L6.14103 19.9266L7.39422 18.9268L9.11496 17.5537L9.57292 17.1877L10.1092 16.7601L10.4561 16.4827L10.4537 16.4811C10.7582 16.2382 10.9236 15.8402 10.8509 15.4294C10.8237 15.2735 10.7654 15.1313 10.6822 15.0082Z\" fill=\"#0C847B\"/>\n <path d=\"M9.17644 4.56325C9.2124 4.68713 9.26915 4.80062 9.34268 4.90053C9.34348 4.90053 9.34428 4.90213 9.34428 4.90213L9.40342 4.97645C9.40502 4.97805 9.40582 4.97885 9.40662 4.98045L9.56806 5.17946L9.64878 5.28096L9.67915 5.31932L9.8414 5.51993L10.5559 6.40947L10.7054 6.59569L11.2169 7.23188L11.5142 7.60192L11.5693 7.45247L13.5202 2.08964L14.1596 0.332135C14.1596 0.330536 14.1604 0.328139 14.1612 0.32654C14.174 0.288177 14.1772 0.246617 14.17 0.205058C14.1468 0.0699879 14.0182 -0.0195258 13.8823 0.00365186C13.8407 0.0116442 13.8024 0.028428 13.7712 0.0540033L12.578 1.00589L12.498 1.06982L10.6958 2.50844L9.85658 3.17819L9.8326 3.19737L9.6296 3.35961L9.45297 3.50028C9.2116 3.73925 9.08692 4.08931 9.15006 4.44976C9.15726 4.48813 9.16525 4.52649 9.17644 4.56325Z\" fill=\"#0C847B\"/>\n </svg>\n</ng-template>",
|
|
7877
|
+
styles: [".footer-content{display:-ms-flexbox;display:flex;-ms-flex-positive:0;flex-grow:0}.textarea-ia{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;gap:8px}.iassist-button{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;border:none;border-radius:50%;box-shadow:none;cursor:pointer;height:32px;width:32px}.dialog-header{display:-ms-flexbox;display:flex;gap:12px}.dialog-header .iassist-icon{display:block;height:24px;width:24px}"]
|
|
7878
|
+
})
|
|
7879
|
+
], TextAreaIAFieldComponent);
|
|
7880
|
+
return TextAreaIAFieldComponent;
|
|
7794
7881
|
}());
|
|
7795
7882
|
|
|
7796
|
-
var
|
|
7797
|
-
|
|
7798
|
-
|
|
7799
|
-
|
|
7800
|
-
|
|
7801
|
-
|
|
7802
|
-
|
|
7883
|
+
var TextFieldComponent = /** @class */ (function (_super) {
|
|
7884
|
+
__extends(TextFieldComponent, _super);
|
|
7885
|
+
function TextFieldComponent() {
|
|
7886
|
+
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
7887
|
+
_this.onInput = new core.EventEmitter();
|
|
7888
|
+
_this.onFocus = new core.EventEmitter();
|
|
7889
|
+
_this.onComplete = new core.EventEmitter();
|
|
7890
|
+
_this.ngUnsubscribe = new rxjs.Subject();
|
|
7891
|
+
return _this;
|
|
7803
7892
|
}
|
|
7804
|
-
|
|
7805
|
-
this.mouseUp.next(event);
|
|
7806
|
-
};
|
|
7807
|
-
LongPressDirective.prototype.onMouseDown = function (event) {
|
|
7808
|
-
this.mouseDown.next(event);
|
|
7809
|
-
};
|
|
7810
|
-
LongPressDirective.prototype.ngOnInit = function () {
|
|
7893
|
+
TextFieldComponent.prototype.ngOnInit = function () {
|
|
7811
7894
|
var _this = this;
|
|
7812
|
-
this.
|
|
7813
|
-
|
|
7814
|
-
|
|
7895
|
+
this.onFocus.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function (event) {
|
|
7896
|
+
if (_this.field.onFocus)
|
|
7897
|
+
_this.field.onFocus(event);
|
|
7898
|
+
});
|
|
7899
|
+
this.onInput.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function (event) {
|
|
7900
|
+
if (_this.field.onInput)
|
|
7901
|
+
_this.field.onInput(event);
|
|
7902
|
+
});
|
|
7903
|
+
this.onComplete.pipe(operators.takeUntil(this.ngUnsubscribe)).subscribe(function (event) {
|
|
7904
|
+
if (_this.field.onComplete)
|
|
7905
|
+
_this.field.onComplete(event);
|
|
7906
|
+
});
|
|
7815
7907
|
};
|
|
7816
|
-
|
|
7908
|
+
TextFieldComponent.prototype.ngOnDestroy = function () {
|
|
7817
7909
|
this.ngUnsubscribe.next();
|
|
7818
7910
|
this.ngUnsubscribe.complete();
|
|
7819
7911
|
};
|
|
7820
7912
|
__decorate([
|
|
7821
7913
|
core.Input()
|
|
7822
|
-
],
|
|
7914
|
+
], TextFieldComponent.prototype, "field", void 0);
|
|
7915
|
+
__decorate([
|
|
7916
|
+
core.Input()
|
|
7917
|
+
], TextFieldComponent.prototype, "formControl", void 0);
|
|
7823
7918
|
__decorate([
|
|
7824
7919
|
core.Output()
|
|
7825
|
-
],
|
|
7920
|
+
], TextFieldComponent.prototype, "onInput", void 0);
|
|
7826
7921
|
__decorate([
|
|
7827
|
-
core.
|
|
7828
|
-
|
|
7829
|
-
], LongPressDirective.prototype, "onMouseUp", null);
|
|
7922
|
+
core.Output()
|
|
7923
|
+
], TextFieldComponent.prototype, "onFocus", void 0);
|
|
7830
7924
|
__decorate([
|
|
7831
|
-
core.
|
|
7832
|
-
|
|
7833
|
-
|
|
7834
|
-
|
|
7835
|
-
|
|
7836
|
-
|
|
7925
|
+
core.Output()
|
|
7926
|
+
], TextFieldComponent.prototype, "onComplete", void 0);
|
|
7927
|
+
TextFieldComponent = __decorate([
|
|
7928
|
+
core.Component({
|
|
7929
|
+
template: "<p-inputMask\n *ngIf=\"field.mask; else noMask\"\n [type]=\"field.inputType || 'text'\"\n [inputId]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [mask]=\"isFunction(field.mask) ? field.mask() : field.mask\"\n [placeholder]=\"field.placeholder\"\n slotChar=\"_\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\"\n styleClass=\"mousetrap\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n (onFocus)=\"onFocus.next($event)\"\n (onComplete)=\"onComplete.next($event)\"\n (onInput)=\"onInput.next($event)\"\n [formControl]=\"formControl\">\n</p-inputMask>\n<ng-template #noMask>\n <ng-container>\n <div class=\"ui-inputgroup\">\n <ng-container *ngIf=\"field.leftAddon\">\n <span class=\"ui-inputgroup-addon\">\n <span *ngIf=\"field.leftAddon.label\">{{field.leftAddon.label}}</span>\n <span *ngIf=\"!field.leftAddon.label\" [ngClass]=\"field.leftAddon.icon\"></span>\n </span>\n </ng-container>\n <ng-container *ngTemplateOutlet=\"field.keyFilter ? inputKeyFilter : input\"></ng-container>\n <ng-container *ngIf=\"field.rightAddon\">\n <span class=\"ui-inputgroup-addon\">\n <span *ngIf=\"field.rightAddon.label\">{{field.rightAddon.label}}</span>\n <span *ngIf=\"!field.rightAddon.label\" [ngClass]=\"field.rightAddon.icon\"></span>\n </span>\n </ng-container>\n </div>\n </ng-container>\n</ng-template>\n<ng-template #input>\n <input\n [type]=\"field.inputType || 'text'\"\n [id]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [placeholder]=\"field.placeholder\"\n [showDelay]=\"500\"\n [maxLength]=\"field.maxLength\"\n pInputText\n [autocomplete]=\"field.browserAutocomplete ? 'on' : 'off'\"\n [ngClass]=\"'mousetrap'\"\n (blur)=\"field.onBlur ? field.onBlur($event) : null\"\n (focus)=\"onFocus.next($event)\"\n (input)=\"onInput.next($event)\"\n [formControl]=\"formControl\"\n [ngStyle]=\"field.style\" />\n</ng-template>\n<ng-template #inputKeyFilter>\n <input\n #inputText\n [type]=\"field.inputType || 'text'\"\n [id]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [placeholder]=\"field.placeholder\"\n [showDelay]=\"500\"\n [maxLength]=\"field.maxLength\"\n pInputText\n [autocomplete]=\"field.browserAutocomplete ? 'on' : 'off'\"\n [ngClass]=\"'mousetrap'\"\n (blur)=\"field.onBlur ? field.onBlur($event) : null\"\n (focus)=\"onFocus.next($event)\"\n (input)=\"onInput.next($event)\"\n [pKeyFilter]=\"field.keyFilter\"\n [formControl]=\"formControl\"\n [ngStyle]=\"field.style\" />\n</ng-template>\n",
|
|
7930
|
+
encapsulation: core.ViewEncapsulation.None,
|
|
7931
|
+
styles: ["s-text-field.ng-dirty.ng-invalid .ui-inputtext{border-color:#c13018}s-text-field.ng-dirty.ng-invalid .ui-inputtext:hover{border-color:#e44328}"]
|
|
7837
7932
|
})
|
|
7838
|
-
],
|
|
7839
|
-
return
|
|
7840
|
-
}());
|
|
7933
|
+
], TextFieldComponent);
|
|
7934
|
+
return TextFieldComponent;
|
|
7935
|
+
}(BaseFieldComponent));
|
|
7841
7936
|
|
|
7842
|
-
var
|
|
7843
|
-
function
|
|
7844
|
-
this.onDoubleClick = new core.EventEmitter();
|
|
7845
|
-
this._timeout = null;
|
|
7846
|
-
this._DOUBLE_CLICK_DELAY = 500;
|
|
7937
|
+
var RowComponent = /** @class */ (function () {
|
|
7938
|
+
function RowComponent() {
|
|
7847
7939
|
}
|
|
7848
|
-
|
|
7849
|
-
|
|
7850
|
-
|
|
7851
|
-
|
|
7852
|
-
|
|
7853
|
-
if (this._timeout) {
|
|
7854
|
-
this.clearTimeout();
|
|
7855
|
-
this.onDoubleClick.emit(event);
|
|
7856
|
-
}
|
|
7857
|
-
else {
|
|
7858
|
-
this._timeout = setTimeout(function () { return _this.clearTimeout(); }, this._DOUBLE_CLICK_DELAY);
|
|
7859
|
-
}
|
|
7940
|
+
RowComponent.prototype.ngOnInit = function () { };
|
|
7941
|
+
RowComponent.prototype.getErrorMessages = function (errorMessages) {
|
|
7942
|
+
if (errorMessages)
|
|
7943
|
+
return this.isFunction(errorMessages) ? errorMessages() : errorMessages;
|
|
7944
|
+
return this.errorMessages;
|
|
7860
7945
|
};
|
|
7861
|
-
|
|
7862
|
-
|
|
7863
|
-
this._timeout = null;
|
|
7946
|
+
RowComponent.prototype.isFunction = function (value) {
|
|
7947
|
+
return value instanceof Function;
|
|
7864
7948
|
};
|
|
7865
7949
|
__decorate([
|
|
7866
|
-
core.
|
|
7867
|
-
],
|
|
7950
|
+
core.Input()
|
|
7951
|
+
], RowComponent.prototype, "id", void 0);
|
|
7868
7952
|
__decorate([
|
|
7869
|
-
core.
|
|
7870
|
-
],
|
|
7871
|
-
|
|
7872
|
-
core.
|
|
7873
|
-
|
|
7874
|
-
|
|
7875
|
-
|
|
7876
|
-
|
|
7877
|
-
|
|
7878
|
-
|
|
7879
|
-
|
|
7880
|
-
|
|
7881
|
-
|
|
7882
|
-
|
|
7883
|
-
|
|
7884
|
-
|
|
7885
|
-
|
|
7886
|
-
|
|
7887
|
-
|
|
7888
|
-
|
|
7889
|
-
|
|
7890
|
-
|
|
7891
|
-
|
|
7892
|
-
|
|
7893
|
-
|
|
7894
|
-
|
|
7895
|
-
|
|
7896
|
-
}());
|
|
7897
|
-
|
|
7898
|
-
|
|
7899
|
-
(function (PasswordStrengths) {
|
|
7900
|
-
PasswordStrengths["VeryWeak"] = "Very_weak";
|
|
7901
|
-
PasswordStrengths["Weak"] = "weak";
|
|
7902
|
-
PasswordStrengths["Medium"] = "medium";
|
|
7903
|
-
PasswordStrengths["Strong"] = "strong";
|
|
7904
|
-
})(exports.PasswordStrengths || (exports.PasswordStrengths = {}));
|
|
7905
|
-
|
|
7906
|
-
|
|
7907
|
-
(function (PasswordStrengthPositions) {
|
|
7908
|
-
PasswordStrengthPositions["Top"] = "top";
|
|
7909
|
-
PasswordStrengthPositions["Right"] = "right";
|
|
7910
|
-
PasswordStrengthPositions["Left"] = "left";
|
|
7911
|
-
})(exports.PasswordStrengthPositions || (exports.PasswordStrengthPositions = {}));
|
|
7912
|
-
|
|
7913
|
-
var PasswordStrengthComponent = /** @class */ (function () {
|
|
7914
|
-
function PasswordStrengthComponent() {
|
|
7915
|
-
this.weakTitle = "Fraca";
|
|
7916
|
-
this.mediumTitle = "Médio";
|
|
7917
|
-
this.strongTitle = "Forte";
|
|
7918
|
-
this.position = exports.PasswordStrengthPositions.Right;
|
|
7919
|
-
this.left = 0;
|
|
7920
|
-
this.top = 0;
|
|
7921
|
-
this.visible = false;
|
|
7922
|
-
}
|
|
7923
|
-
PasswordStrengthComponent.prototype.ngOnInit = function () {
|
|
7924
|
-
this.title = this.weakTitle;
|
|
7925
|
-
};
|
|
7926
|
-
PasswordStrengthComponent.prototype.setPasswordStrengthPosition = function () {
|
|
7927
|
-
var passwordStrength = document.querySelector(".password-strength");
|
|
7928
|
-
switch (this.position) {
|
|
7929
|
-
case exports.PasswordStrengthPositions.Top:
|
|
7930
|
-
passwordStrength.classList.add("password-strength--top");
|
|
7931
|
-
break;
|
|
7932
|
-
case exports.PasswordStrengthPositions.Right:
|
|
7933
|
-
passwordStrength.classList.add("password-strength--right");
|
|
7934
|
-
break;
|
|
7935
|
-
case exports.PasswordStrengthPositions.Left:
|
|
7936
|
-
passwordStrength.classList.add("password-strength--left");
|
|
7937
|
-
break;
|
|
7938
|
-
}
|
|
7939
|
-
};
|
|
7940
|
-
PasswordStrengthComponent.prototype.updateIndicators = function (passwordStrength) {
|
|
7941
|
-
var strengthIndicator1 = document.querySelector("#strength-indicator-1");
|
|
7942
|
-
var strengthIndicator2 = document.querySelector("#strength-indicator-2");
|
|
7943
|
-
var strengthIndicator3 = document.querySelector("#strength-indicator-3");
|
|
7944
|
-
var onIndicators = [];
|
|
7945
|
-
var indicators = [
|
|
7946
|
-
strengthIndicator1,
|
|
7947
|
-
strengthIndicator2,
|
|
7948
|
-
strengthIndicator3,
|
|
7949
|
-
];
|
|
7950
|
-
var strengthClass;
|
|
7951
|
-
switch (passwordStrength) {
|
|
7952
|
-
case exports.PasswordStrengths.VeryWeak:
|
|
7953
|
-
this.title = this.weakTitle;
|
|
7954
|
-
break;
|
|
7955
|
-
case exports.PasswordStrengths.Weak:
|
|
7956
|
-
this.title = this.weakTitle;
|
|
7957
|
-
strengthClass = "strength-indicator--weak";
|
|
7958
|
-
onIndicators.push(strengthIndicator1);
|
|
7959
|
-
break;
|
|
7960
|
-
case exports.PasswordStrengths.Medium:
|
|
7961
|
-
this.title = this.mediumTitle;
|
|
7962
|
-
strengthClass = "strength-indicator--medium";
|
|
7963
|
-
onIndicators.push(strengthIndicator1);
|
|
7964
|
-
onIndicators.push(strengthIndicator2);
|
|
7965
|
-
break;
|
|
7966
|
-
case exports.PasswordStrengths.Strong:
|
|
7967
|
-
this.title = this.strongTitle;
|
|
7968
|
-
strengthClass = "strength-indicator--strong";
|
|
7969
|
-
onIndicators.push(strengthIndicator1);
|
|
7970
|
-
onIndicators.push(strengthIndicator2);
|
|
7971
|
-
onIndicators.push(strengthIndicator3);
|
|
7972
|
-
break;
|
|
7973
|
-
}
|
|
7974
|
-
indicators.forEach(function (indicator) {
|
|
7975
|
-
indicator.classList.remove("strength-indicator--weak", "strength-indicator--medium", "strength-indicator--strong");
|
|
7976
|
-
});
|
|
7977
|
-
onIndicators.forEach(function (indicator) {
|
|
7978
|
-
indicator.classList.add(strengthClass);
|
|
7979
|
-
});
|
|
7953
|
+
core.Input()
|
|
7954
|
+
], RowComponent.prototype, "config", void 0);
|
|
7955
|
+
__decorate([
|
|
7956
|
+
core.Input()
|
|
7957
|
+
], RowComponent.prototype, "group", void 0);
|
|
7958
|
+
__decorate([
|
|
7959
|
+
core.Input()
|
|
7960
|
+
], RowComponent.prototype, "errorMessages", void 0);
|
|
7961
|
+
RowComponent = __decorate([
|
|
7962
|
+
core.Component({
|
|
7963
|
+
template: "\n <div class=\"ui-fluid\" [formGroup]=\"group\">\n <div class=\"ui-g\">\n <ng-container *ngFor=\"let field of config.fields\">\n <div [ngClass]=\"field.gridClass\" *ngIf=\"field.visible()\">\n <label\n [for]=\"field.name\"\n [ngClass]=\"{ 'required': field.required() }\"\n *sInfoSign=\"field.infoSign\"\n >\n {{ field.label }}\n </label>\n <ng-container *sDynamicForm=\"{ id: id, config: field, group: group}\"></ng-container>\n <s-control-errors [form]=\"group\" [control]=\"group.controls[field.name]\"\n [errorMessages]=\"getErrorMessages(field.errorMessages)\"></s-control-errors>\n <ng-template *ngIf=\"field?.bottomTemplate\" [ngTemplateOutlet]=\"field.bottomTemplate\"></ng-template>\n </div>\n </ng-container>\n </div>\n "
|
|
7964
|
+
})
|
|
7965
|
+
], RowComponent);
|
|
7966
|
+
return RowComponent;
|
|
7967
|
+
}());
|
|
7968
|
+
|
|
7969
|
+
var DynamicFieldComponent = /** @class */ (function () {
|
|
7970
|
+
function DynamicFieldComponent() {
|
|
7971
|
+
}
|
|
7972
|
+
DynamicFieldComponent.prototype.getErrorMessages = function (errorMessages) {
|
|
7973
|
+
if (errorMessages)
|
|
7974
|
+
return this.isFunction(errorMessages)
|
|
7975
|
+
? __assign(__assign({}, this.errorMessages), errorMessages()) : __assign(__assign({}, this.errorMessages), errorMessages);
|
|
7976
|
+
return this.errorMessages;
|
|
7977
|
+
};
|
|
7978
|
+
DynamicFieldComponent.prototype.isFunction = function (value) {
|
|
7979
|
+
return value instanceof Function;
|
|
7980
7980
|
};
|
|
7981
7981
|
__decorate([
|
|
7982
7982
|
core.Input()
|
|
7983
|
-
],
|
|
7983
|
+
], DynamicFieldComponent.prototype, "id", void 0);
|
|
7984
7984
|
__decorate([
|
|
7985
7985
|
core.Input()
|
|
7986
|
-
],
|
|
7986
|
+
], DynamicFieldComponent.prototype, "fields", void 0);
|
|
7987
7987
|
__decorate([
|
|
7988
7988
|
core.Input()
|
|
7989
|
-
],
|
|
7989
|
+
], DynamicFieldComponent.prototype, "form", void 0);
|
|
7990
7990
|
__decorate([
|
|
7991
7991
|
core.Input()
|
|
7992
|
-
],
|
|
7993
|
-
|
|
7992
|
+
], DynamicFieldComponent.prototype, "errorMessages", void 0);
|
|
7993
|
+
__decorate([
|
|
7994
|
+
core.Input()
|
|
7995
|
+
], DynamicFieldComponent.prototype, "displayTimeInfoSign", void 0);
|
|
7996
|
+
DynamicFieldComponent = __decorate([
|
|
7994
7997
|
core.Component({
|
|
7995
|
-
|
|
7996
|
-
|
|
7998
|
+
selector: "s-dynamic-field",
|
|
7999
|
+
template: "<div class=\"ui-fluid\" [formGroup]=\"form\">\n <div class=\"ui-g\">\n <ng-container *ngFor=\"let field of fields\">\n <div\n *ngIf=\"!field.visible || field.visible()\"\n [ngClass]=\"field.gridClass\">\n <span *ngIf=\"field.label\">\n <label\n *sInfoSign=\"field.infoSign; displayTime: displayTimeInfoSign\"\n [for]=\"field.name\"\n [ngClass]=\"{ 'required': field.required() }\">\n {{ field.label }}\n </label>\n </span>\n <ng-container *sDynamicForm=\"{\n id: id,\n config: field,\n group: form\n }\">\n </ng-container>\n <s-control-errors\n [form]=\"form\"\n [control]=\"form.controls[field.name]\"\n [errorMessages]=\"getErrorMessages(field.errorMessages)\">\n </s-control-errors>\n <ng-template\n *ngIf=\"field?.bottomTemplate\"\n [ngTemplateOutlet]=\"field.bottomTemplate\">\n </ng-template>\n </div>\n </ng-container>\n </div>\n</div>"
|
|
7997
8000
|
})
|
|
7998
|
-
],
|
|
7999
|
-
return
|
|
8001
|
+
], DynamicFieldComponent);
|
|
8002
|
+
return DynamicFieldComponent;
|
|
8000
8003
|
}());
|
|
8001
8004
|
|
|
8002
|
-
var
|
|
8003
|
-
|
|
8004
|
-
|
|
8005
|
-
|
|
8006
|
-
|
|
8007
|
-
|
|
8008
|
-
|
|
8009
|
-
|
|
8010
|
-
|
|
8005
|
+
var GridType;
|
|
8006
|
+
(function (GridType) {
|
|
8007
|
+
GridType["Row"] = "Row";
|
|
8008
|
+
})(GridType || (GridType = {}));
|
|
8009
|
+
|
|
8010
|
+
var StructureType;
|
|
8011
|
+
(function (StructureType) {
|
|
8012
|
+
StructureType["Fieldset"] = "Fieldset";
|
|
8013
|
+
StructureType["Section"] = "Section";
|
|
8014
|
+
})(StructureType || (StructureType = {}));
|
|
8015
|
+
|
|
8016
|
+
var DynamicForm = /** @class */ (function () {
|
|
8017
|
+
function DynamicForm(_a) {
|
|
8018
|
+
var group = _a.group, errorMessages = _a.errorMessages;
|
|
8019
|
+
this.group = group;
|
|
8020
|
+
this.errorMessages = errorMessages;
|
|
8011
8021
|
}
|
|
8012
|
-
|
|
8013
|
-
|
|
8014
|
-
|
|
8015
|
-
|
|
8016
|
-
|
|
8017
|
-
var
|
|
8018
|
-
|
|
8019
|
-
|
|
8020
|
-
|
|
8021
|
-
}
|
|
8022
|
-
|
|
8023
|
-
|
|
8022
|
+
return DynamicForm;
|
|
8023
|
+
}());
|
|
8024
|
+
var DynamicField = /** @class */ (function (_super) {
|
|
8025
|
+
__extends(DynamicField, _super);
|
|
8026
|
+
function DynamicField(_a) {
|
|
8027
|
+
var group = _a.group, field = _a.field, errorMessages = _a.errorMessages;
|
|
8028
|
+
var _this = _super.call(this, {
|
|
8029
|
+
group: group,
|
|
8030
|
+
errorMessages: errorMessages,
|
|
8031
|
+
}) || this;
|
|
8032
|
+
_this.field = field;
|
|
8033
|
+
_this.setFieldPropertiesByType();
|
|
8034
|
+
return _this;
|
|
8035
|
+
}
|
|
8036
|
+
DynamicField.prototype.setFieldPropertiesByType = function () {
|
|
8037
|
+
if (this.field.type === exports.FieldType.Integer || this.field.type === exports.FieldType.Double) {
|
|
8038
|
+
this.field.numberLocaleOptions.currencySymbol = "";
|
|
8024
8039
|
}
|
|
8025
8040
|
};
|
|
8026
|
-
|
|
8027
|
-
this.
|
|
8041
|
+
DynamicField.prototype.createComponent = function (resolver, container) {
|
|
8042
|
+
var componentFactory = resolver.resolveComponentFactory(this.getComponent());
|
|
8043
|
+
var component = container.createComponent(componentFactory);
|
|
8044
|
+
component.instance.field = this.field;
|
|
8045
|
+
// Must be this way because some teams use name like "e070emp.codemp"
|
|
8046
|
+
component.instance.formControl = this.group["controls"][this.field.name];
|
|
8047
|
+
component.instance.errorMessages = this.errorMessages;
|
|
8048
|
+
this.setVariablesByType(component);
|
|
8049
|
+
return component;
|
|
8028
8050
|
};
|
|
8029
|
-
|
|
8030
|
-
if (this.
|
|
8031
|
-
|
|
8032
|
-
this.componentRef = componentFactory.create(this.injector);
|
|
8033
|
-
this.appRef.attachView(this.componentRef.hostView);
|
|
8034
|
-
var domElem = this.componentRef.hostView.rootNodes[0];
|
|
8035
|
-
document.body.appendChild(domElem);
|
|
8036
|
-
this.setPasswordStrengthComponentProperties();
|
|
8037
|
-
this.showPasswordStrength();
|
|
8051
|
+
DynamicField.prototype.setVariablesByType = function (component) {
|
|
8052
|
+
if (this.field.type == exports.FieldType.Time) {
|
|
8053
|
+
component.instance.timeOnly = true;
|
|
8038
8054
|
}
|
|
8039
|
-
|
|
8040
|
-
|
|
8041
|
-
if (this.componentRef !== null) {
|
|
8042
|
-
this.componentRef.instance.visible = true;
|
|
8055
|
+
if ([exports.FieldType.LocalDateTime, exports.FieldType.DateTime, exports.FieldType.Time].includes(this.field.type)) {
|
|
8056
|
+
component.instance.showTime = true;
|
|
8043
8057
|
}
|
|
8044
8058
|
};
|
|
8045
|
-
|
|
8046
|
-
|
|
8047
|
-
|
|
8048
|
-
|
|
8049
|
-
|
|
8050
|
-
|
|
8051
|
-
|
|
8052
|
-
|
|
8053
|
-
|
|
8054
|
-
|
|
8055
|
-
|
|
8056
|
-
|
|
8057
|
-
|
|
8058
|
-
|
|
8059
|
-
|
|
8060
|
-
|
|
8061
|
-
|
|
8062
|
-
|
|
8063
|
-
|
|
8064
|
-
|
|
8065
|
-
|
|
8066
|
-
|
|
8067
|
-
|
|
8068
|
-
|
|
8069
|
-
|
|
8070
|
-
|
|
8071
|
-
|
|
8072
|
-
|
|
8073
|
-
|
|
8074
|
-
|
|
8075
|
-
|
|
8076
|
-
|
|
8077
|
-
|
|
8078
|
-
|
|
8079
|
-
|
|
8080
|
-
|
|
8081
|
-
|
|
8082
|
-
|
|
8083
|
-
|
|
8084
|
-
|
|
8085
|
-
|
|
8086
|
-
|
|
8087
|
-
|
|
8088
|
-
|
|
8089
|
-
|
|
8090
|
-
|
|
8091
|
-
|
|
8092
|
-
|
|
8093
|
-
|
|
8094
|
-
var leftShift = left;
|
|
8095
|
-
if (leftShift <= elementRefWidth + safeSpace) {
|
|
8096
|
-
this.position = exports.PasswordStrengthPositions.Top;
|
|
8097
|
-
invalidOptions.push(exports.PasswordStrengthPositions.Left);
|
|
8098
|
-
break;
|
|
8099
|
-
}
|
|
8100
|
-
this.componentRef.instance.top = Math.round(top_1 + elementRefHeight / 2);
|
|
8101
|
-
this.componentRef.instance.left = Math.round(left - margin);
|
|
8102
|
-
positioned = true;
|
|
8103
|
-
break;
|
|
8104
|
-
}
|
|
8105
|
-
default: {
|
|
8106
|
-
break;
|
|
8107
|
-
}
|
|
8108
|
-
}
|
|
8109
|
-
this.componentRef.instance.position = this.position;
|
|
8110
|
-
}
|
|
8059
|
+
DynamicField.prototype.updateVariables = function (component) {
|
|
8060
|
+
component.instance.field = this.field;
|
|
8061
|
+
component.instance.formControl = this.group["controls"][this.field.name];
|
|
8062
|
+
this.setVariablesByType(component);
|
|
8063
|
+
};
|
|
8064
|
+
DynamicField.prototype.getComponent = function () {
|
|
8065
|
+
switch (this.field.type) {
|
|
8066
|
+
case exports.FieldType.Autocomplete:
|
|
8067
|
+
return AutocompleteFieldComponent;
|
|
8068
|
+
case exports.FieldType.Binary:
|
|
8069
|
+
case exports.FieldType.String:
|
|
8070
|
+
return TextFieldComponent;
|
|
8071
|
+
case exports.FieldType.Boolean:
|
|
8072
|
+
return this.field.representedBy === "switch" ? BooleanSwitchFieldComponent : BooleanFieldComponent;
|
|
8073
|
+
case exports.FieldType.Chips:
|
|
8074
|
+
return ChipsFieldComponent;
|
|
8075
|
+
case exports.FieldType.CountryPhonePicker:
|
|
8076
|
+
return CountryPhonePickerFieldComponent;
|
|
8077
|
+
case exports.FieldType.Date:
|
|
8078
|
+
case exports.FieldType.DateTime:
|
|
8079
|
+
case exports.FieldType.LocalDateTime:
|
|
8080
|
+
case exports.FieldType.Time:
|
|
8081
|
+
return CalendarFieldComponent;
|
|
8082
|
+
case exports.FieldType.Number:
|
|
8083
|
+
case exports.FieldType.Integer:
|
|
8084
|
+
case exports.FieldType.Double:
|
|
8085
|
+
return BignumberFieldComponent;
|
|
8086
|
+
case exports.FieldType.Enum:
|
|
8087
|
+
return SelectFieldComponent;
|
|
8088
|
+
case exports.FieldType.Lookup:
|
|
8089
|
+
return LookupFieldComponent;
|
|
8090
|
+
case exports.FieldType.Money:
|
|
8091
|
+
return CurrencyFieldComponent;
|
|
8092
|
+
case exports.FieldType.Radio:
|
|
8093
|
+
return RadioButtonComponent;
|
|
8094
|
+
case exports.FieldType.Text:
|
|
8095
|
+
return TextAreaFieldComponent;
|
|
8096
|
+
case exports.FieldType.TextIA:
|
|
8097
|
+
return TextAreaIAFieldComponent;
|
|
8098
|
+
case exports.FieldType.Password:
|
|
8099
|
+
return PasswordFieldComponent;
|
|
8100
|
+
case exports.FieldType.Blob:
|
|
8101
|
+
return FileUploadComponent$1;
|
|
8102
|
+
case exports.FieldType.Slider:
|
|
8103
|
+
return SliderFieldComponent;
|
|
8104
|
+
case exports.FieldType.Custom:
|
|
8105
|
+
return this.field.CustomFieldComponentClass;
|
|
8106
|
+
default:
|
|
8107
|
+
throw new Error("Trying to use an unsupported type (" + this.field.type + ").");
|
|
8111
8108
|
}
|
|
8112
8109
|
};
|
|
8113
|
-
|
|
8114
|
-
|
|
8115
|
-
|
|
8116
|
-
|
|
8117
|
-
|
|
8110
|
+
return DynamicField;
|
|
8111
|
+
}(DynamicForm));
|
|
8112
|
+
var DynamicStructure = /** @class */ (function (_super) {
|
|
8113
|
+
__extends(DynamicStructure, _super);
|
|
8114
|
+
function DynamicStructure(_a) {
|
|
8115
|
+
var group = _a.group, config = _a.config, errorMessages = _a.errorMessages;
|
|
8116
|
+
var _this = _super.call(this, {
|
|
8117
|
+
group: group,
|
|
8118
|
+
errorMessages: errorMessages,
|
|
8119
|
+
}) || this;
|
|
8120
|
+
_this.config = config;
|
|
8121
|
+
return _this;
|
|
8122
|
+
}
|
|
8123
|
+
DynamicStructure.prototype.createComponent = function (resolver, container) {
|
|
8124
|
+
var componentFactory = resolver.resolveComponentFactory(this.getComponent());
|
|
8125
|
+
var component = container.createComponent(componentFactory);
|
|
8126
|
+
component.instance.config = this.config;
|
|
8127
|
+
component.instance.group = this.group;
|
|
8128
|
+
return component;
|
|
8129
|
+
};
|
|
8130
|
+
DynamicStructure.prototype.updateVariables = function (component) {
|
|
8131
|
+
component.instance.structure = this.config;
|
|
8132
|
+
component.instance.group = this.group;
|
|
8118
8133
|
};
|
|
8119
|
-
|
|
8120
|
-
|
|
8121
|
-
|
|
8122
|
-
|
|
8123
|
-
|
|
8134
|
+
DynamicStructure.prototype.getComponent = function () {
|
|
8135
|
+
switch (this.config.type) {
|
|
8136
|
+
case StructureType.Fieldset:
|
|
8137
|
+
return FieldsetComponent;
|
|
8138
|
+
case StructureType.Section:
|
|
8139
|
+
return SectionComponent;
|
|
8140
|
+
default:
|
|
8141
|
+
throw new Error("Trying to use an unsupported type (" + this.config.type + ").");
|
|
8124
8142
|
}
|
|
8125
8143
|
};
|
|
8126
|
-
|
|
8127
|
-
|
|
8128
|
-
|
|
8129
|
-
|
|
8130
|
-
|
|
8131
|
-
|
|
8132
|
-
|
|
8133
|
-
|
|
8134
|
-
|
|
8135
|
-
|
|
8144
|
+
return DynamicStructure;
|
|
8145
|
+
}(DynamicForm));
|
|
8146
|
+
var DynamicGrid = /** @class */ (function (_super) {
|
|
8147
|
+
__extends(DynamicGrid, _super);
|
|
8148
|
+
function DynamicGrid(_a) {
|
|
8149
|
+
var group = _a.group, config = _a.config, errorMessages = _a.errorMessages;
|
|
8150
|
+
var _this = _super.call(this, { group: group, errorMessages: errorMessages }) || this;
|
|
8151
|
+
_this.config = config;
|
|
8152
|
+
return _this;
|
|
8153
|
+
}
|
|
8154
|
+
DynamicGrid.prototype.createComponent = function (resolver, container) {
|
|
8155
|
+
var componentFactory = resolver.resolveComponentFactory(this.getComponent());
|
|
8156
|
+
var component = container.createComponent(componentFactory);
|
|
8157
|
+
component.instance.config = this.config;
|
|
8158
|
+
component.instance.group = this.group;
|
|
8159
|
+
component.instance.errorMessages = this.errorMessages;
|
|
8160
|
+
return component;
|
|
8161
|
+
};
|
|
8162
|
+
DynamicGrid.prototype.updateVariables = function (component) {
|
|
8163
|
+
component.instance.config = this.config;
|
|
8164
|
+
component.instance.group = this.group;
|
|
8165
|
+
};
|
|
8166
|
+
DynamicGrid.prototype.getComponent = function () {
|
|
8167
|
+
switch (this.config.type) {
|
|
8168
|
+
case GridType.Row:
|
|
8169
|
+
return RowComponent;
|
|
8170
|
+
default:
|
|
8171
|
+
throw new Error("Trying to use an unsupported type (" + this.config.type + ").");
|
|
8136
8172
|
}
|
|
8137
|
-
|
|
8138
|
-
|
|
8139
|
-
|
|
8173
|
+
};
|
|
8174
|
+
return DynamicGrid;
|
|
8175
|
+
}(DynamicForm));
|
|
8176
|
+
|
|
8177
|
+
var DynamicFormDirective = /** @class */ (function () {
|
|
8178
|
+
function DynamicFormDirective(resolver, container) {
|
|
8179
|
+
this.resolver = resolver;
|
|
8180
|
+
this.container = container;
|
|
8181
|
+
}
|
|
8182
|
+
Object.defineProperty(DynamicFormDirective.prototype, "sDynamicForm", {
|
|
8183
|
+
set: function (context) {
|
|
8184
|
+
var id = context.id, config = context.config, group = context.group, errorMessages = context.errorMessages;
|
|
8185
|
+
this.id = id;
|
|
8186
|
+
this.config = config;
|
|
8187
|
+
this.group = group;
|
|
8188
|
+
this.errorMessages = errorMessages;
|
|
8189
|
+
},
|
|
8190
|
+
enumerable: true,
|
|
8191
|
+
configurable: true
|
|
8192
|
+
});
|
|
8193
|
+
DynamicFormDirective.prototype.ngOnInit = function () {
|
|
8194
|
+
if (this.isField()) {
|
|
8195
|
+
if (!(this.config.id) && this.id) {
|
|
8196
|
+
this.config.id = this.id + "-" + this.config.name;
|
|
8140
8197
|
}
|
|
8141
|
-
|
|
8142
|
-
|
|
8143
|
-
|
|
8198
|
+
this.directiveConfig = new DynamicField({
|
|
8199
|
+
group: this.group,
|
|
8200
|
+
field: this.config,
|
|
8201
|
+
errorMessages: this.errorMessages,
|
|
8202
|
+
});
|
|
8144
8203
|
}
|
|
8145
|
-
else if (
|
|
8146
|
-
|
|
8204
|
+
else if (this.isStructure()) {
|
|
8205
|
+
this.directiveConfig = new DynamicStructure({
|
|
8206
|
+
group: this.group,
|
|
8207
|
+
config: this.config,
|
|
8208
|
+
errorMessages: this.errorMessages,
|
|
8209
|
+
});
|
|
8147
8210
|
}
|
|
8148
|
-
else if (
|
|
8149
|
-
|
|
8211
|
+
else if (this.isGrid()) {
|
|
8212
|
+
this.directiveConfig = new DynamicGrid({
|
|
8213
|
+
group: this.group,
|
|
8214
|
+
config: this.config,
|
|
8215
|
+
errorMessages: this.errorMessages,
|
|
8216
|
+
});
|
|
8150
8217
|
}
|
|
8151
|
-
else
|
|
8152
|
-
|
|
8218
|
+
else
|
|
8219
|
+
throw new Error("Trying to use an unsupported type (" + this.config.type + ").");
|
|
8220
|
+
this.component = this.directiveConfig.createComponent(this.resolver, this.container);
|
|
8221
|
+
this.component.instance.id = this.id;
|
|
8222
|
+
this.component.instance.errorMessages = this.errorMessages;
|
|
8223
|
+
};
|
|
8224
|
+
DynamicFormDirective.prototype.ngOnChanges = function () {
|
|
8225
|
+
if (this.component) {
|
|
8226
|
+
this.directiveConfig.updateVariables(this.component);
|
|
8227
|
+
this.component.instance.errorMessages = this.errorMessages;
|
|
8153
8228
|
}
|
|
8154
8229
|
};
|
|
8155
|
-
|
|
8156
|
-
|
|
8157
|
-
|
|
8230
|
+
DynamicFormDirective.prototype.isField = function () {
|
|
8231
|
+
return exports.FieldType[this.config.type];
|
|
8232
|
+
};
|
|
8233
|
+
DynamicFormDirective.prototype.isStructure = function () {
|
|
8234
|
+
return StructureType[this.config.type];
|
|
8235
|
+
};
|
|
8236
|
+
DynamicFormDirective.prototype.isGrid = function () {
|
|
8237
|
+
return GridType[this.config.type];
|
|
8238
|
+
};
|
|
8239
|
+
DynamicFormDirective.ctorParameters = function () { return [
|
|
8158
8240
|
{ type: core.ComponentFactoryResolver },
|
|
8159
|
-
{ type: core.
|
|
8241
|
+
{ type: core.ViewContainerRef }
|
|
8160
8242
|
]; };
|
|
8161
8243
|
__decorate([
|
|
8162
|
-
core.Input(
|
|
8163
|
-
],
|
|
8164
|
-
__decorate([
|
|
8165
|
-
core.Input("psValidation")
|
|
8166
|
-
], PasswordStrengthDirective.prototype, "validation", void 0);
|
|
8167
|
-
__decorate([
|
|
8168
|
-
core.Input("psPosition")
|
|
8169
|
-
], PasswordStrengthDirective.prototype, "position", void 0);
|
|
8170
|
-
__decorate([
|
|
8171
|
-
core.Input("psWeakTitle")
|
|
8172
|
-
], PasswordStrengthDirective.prototype, "weakTitle", void 0);
|
|
8173
|
-
__decorate([
|
|
8174
|
-
core.Input("psMediumTitle")
|
|
8175
|
-
], PasswordStrengthDirective.prototype, "mediumTitle", void 0);
|
|
8176
|
-
__decorate([
|
|
8177
|
-
core.Input("psStrongTitle")
|
|
8178
|
-
], PasswordStrengthDirective.prototype, "strongTitle", void 0);
|
|
8179
|
-
__decorate([
|
|
8180
|
-
core.Input("psDescription")
|
|
8181
|
-
], PasswordStrengthDirective.prototype, "description", void 0);
|
|
8182
|
-
__decorate([
|
|
8183
|
-
core.HostListener("keyup"),
|
|
8184
|
-
core.HostListener("focus")
|
|
8185
|
-
], PasswordStrengthDirective.prototype, "onFocus", null);
|
|
8244
|
+
core.Input()
|
|
8245
|
+
], DynamicFormDirective.prototype, "sDynamicForm", null);
|
|
8186
8246
|
__decorate([
|
|
8187
|
-
core.
|
|
8188
|
-
],
|
|
8189
|
-
|
|
8190
|
-
core.Directive({
|
|
8191
|
-
|
|
8192
|
-
|
|
8193
|
-
], PasswordStrengthDirective);
|
|
8194
|
-
return PasswordStrengthDirective;
|
|
8195
|
-
}());
|
|
8196
|
-
|
|
8197
|
-
var PasswordStrengthModule = /** @class */ (function () {
|
|
8198
|
-
function PasswordStrengthModule() {
|
|
8199
|
-
}
|
|
8200
|
-
PasswordStrengthModule = __decorate([
|
|
8201
|
-
core.NgModule({
|
|
8202
|
-
imports: [common.CommonModule],
|
|
8203
|
-
declarations: [
|
|
8204
|
-
PasswordStrengthComponent,
|
|
8205
|
-
PasswordStrengthDirective,
|
|
8206
|
-
],
|
|
8207
|
-
exports: [PasswordStrengthDirective],
|
|
8208
|
-
})
|
|
8209
|
-
], PasswordStrengthModule);
|
|
8210
|
-
return PasswordStrengthModule;
|
|
8247
|
+
core.Input("sDynamicFormDisplayTimeInfoSign")
|
|
8248
|
+
], DynamicFormDirective.prototype, "displayTimeInfoSign", void 0);
|
|
8249
|
+
DynamicFormDirective = __decorate([
|
|
8250
|
+
core.Directive({ selector: "[sDynamicForm]" })
|
|
8251
|
+
], DynamicFormDirective);
|
|
8252
|
+
return DynamicFormDirective;
|
|
8211
8253
|
}());
|
|
8212
8254
|
|
|
8213
8255
|
var DynamicFormModule = /** @class */ (function () {
|
|
@@ -8216,36 +8258,36 @@
|
|
|
8216
8258
|
DynamicFormModule = __decorate([
|
|
8217
8259
|
core.NgModule({
|
|
8218
8260
|
imports: [
|
|
8219
|
-
common.CommonModule,
|
|
8220
|
-
forms.FormsModule,
|
|
8221
|
-
forms.ReactiveFormsModule,
|
|
8222
|
-
TooltipModule,
|
|
8223
|
-
inputtext.InputTextModule,
|
|
8224
|
-
checkbox.CheckboxModule,
|
|
8225
|
-
calendar.CalendarModule,
|
|
8226
|
-
inputmask.InputMaskModule,
|
|
8227
|
-
dropdown.DropdownModule,
|
|
8228
|
-
NumberInputModule,
|
|
8229
|
-
BignumberInputModule,
|
|
8230
|
-
LocalizedNumberInputModule,
|
|
8231
|
-
ControlErrorsModule,
|
|
8232
|
-
LocaleModule,
|
|
8233
8261
|
autocomplete$1.AutoCompleteModule,
|
|
8234
|
-
|
|
8235
|
-
button.ButtonModule,
|
|
8262
|
+
BignumberInputModule,
|
|
8236
8263
|
ButtonModule,
|
|
8237
|
-
|
|
8264
|
+
CalendarMaskModule,
|
|
8265
|
+
calendar.CalendarModule,
|
|
8266
|
+
checkbox.CheckboxModule,
|
|
8267
|
+
chips.ChipsModule,
|
|
8268
|
+
common.CommonModule,
|
|
8269
|
+
ControlErrorsModule,
|
|
8270
|
+
CountryPhonePickerModule,
|
|
8238
8271
|
dialog.DialogModule,
|
|
8239
|
-
|
|
8240
|
-
table.TableModule,
|
|
8272
|
+
dropdown.DropdownModule,
|
|
8241
8273
|
EmptyStateModule,
|
|
8242
|
-
|
|
8274
|
+
forms.FormsModule,
|
|
8243
8275
|
angular2Hotkeys.HotkeyModule,
|
|
8244
|
-
|
|
8245
|
-
CalendarMaskModule,
|
|
8276
|
+
inputmask.InputMaskModule,
|
|
8246
8277
|
inputtextarea.InputTextareaModule,
|
|
8247
|
-
|
|
8278
|
+
inputtext.InputTextModule,
|
|
8248
8279
|
keyfilter.KeyFilterModule,
|
|
8280
|
+
LoadingStateModule,
|
|
8281
|
+
LocaleModule,
|
|
8282
|
+
LocalizedNumberInputModule,
|
|
8283
|
+
panel.PanelModule,
|
|
8284
|
+
button.ButtonModule,
|
|
8285
|
+
table.TableModule,
|
|
8286
|
+
multiselect.MultiSelectModule,
|
|
8287
|
+
NumberInputModule,
|
|
8288
|
+
radiobutton.RadioButtonModule,
|
|
8289
|
+
forms.ReactiveFormsModule,
|
|
8290
|
+
TooltipModule,
|
|
8249
8291
|
fieldset.FieldsetModule,
|
|
8250
8292
|
TableHeaderCheckboxModule,
|
|
8251
8293
|
FileUploadModule,
|
|
@@ -8261,52 +8303,54 @@
|
|
|
8261
8303
|
],
|
|
8262
8304
|
declarations: [
|
|
8263
8305
|
AutocompleteFieldComponent,
|
|
8306
|
+
BignumberFieldComponent,
|
|
8264
8307
|
BooleanFieldComponent,
|
|
8308
|
+
BooleanSwitchFieldComponent,
|
|
8265
8309
|
CalendarFieldComponent,
|
|
8266
8310
|
ChipsFieldComponent,
|
|
8311
|
+
CountryPhonePickerFieldComponent,
|
|
8267
8312
|
CurrencyFieldComponent,
|
|
8268
|
-
DynamicFormComponent,
|
|
8269
8313
|
DynamicFieldComponent,
|
|
8314
|
+
DynamicFormComponent,
|
|
8270
8315
|
DynamicFormDirective,
|
|
8271
8316
|
FieldsetComponent,
|
|
8272
8317
|
FileUploadComponent$1,
|
|
8273
8318
|
LookupComponent,
|
|
8274
8319
|
LookupFieldComponent,
|
|
8275
8320
|
NumberFieldComponent,
|
|
8276
|
-
|
|
8321
|
+
PasswordFieldComponent,
|
|
8277
8322
|
RadioButtonComponent,
|
|
8278
8323
|
RowComponent,
|
|
8279
8324
|
SectionComponent,
|
|
8280
8325
|
SelectFieldComponent,
|
|
8326
|
+
SliderFieldComponent,
|
|
8281
8327
|
TextAreaFieldComponent,
|
|
8282
8328
|
TextAreaIAFieldComponent,
|
|
8283
8329
|
TextFieldComponent,
|
|
8284
|
-
BooleanSwitchFieldComponent,
|
|
8285
|
-
PasswordFieldComponent,
|
|
8286
|
-
SliderFieldComponent,
|
|
8287
8330
|
],
|
|
8288
8331
|
exports: [DynamicFormComponent, LookupComponent],
|
|
8289
8332
|
entryComponents: [
|
|
8290
8333
|
AutocompleteFieldComponent,
|
|
8334
|
+
BignumberFieldComponent,
|
|
8291
8335
|
BooleanFieldComponent,
|
|
8336
|
+
BooleanSwitchFieldComponent,
|
|
8292
8337
|
CalendarFieldComponent,
|
|
8293
8338
|
ChipsFieldComponent,
|
|
8339
|
+
CountryPhonePickerFieldComponent,
|
|
8294
8340
|
CurrencyFieldComponent,
|
|
8295
8341
|
FieldsetComponent,
|
|
8296
8342
|
FileUploadComponent$1,
|
|
8297
8343
|
LookupFieldComponent,
|
|
8298
8344
|
NumberFieldComponent,
|
|
8299
|
-
|
|
8345
|
+
PasswordFieldComponent,
|
|
8300
8346
|
RadioButtonComponent,
|
|
8301
8347
|
RowComponent,
|
|
8302
8348
|
SectionComponent,
|
|
8303
8349
|
SelectFieldComponent,
|
|
8350
|
+
SliderFieldComponent,
|
|
8304
8351
|
TextAreaFieldComponent,
|
|
8305
8352
|
TextAreaIAFieldComponent,
|
|
8306
8353
|
TextFieldComponent,
|
|
8307
|
-
PasswordFieldComponent,
|
|
8308
|
-
BooleanSwitchFieldComponent,
|
|
8309
|
-
SliderFieldComponent,
|
|
8310
8354
|
],
|
|
8311
8355
|
providers: [
|
|
8312
8356
|
angular2Hotkeys.HotkeysService,
|
|
@@ -15639,6 +15683,10 @@
|
|
|
15639
15683
|
}());
|
|
15640
15684
|
|
|
15641
15685
|
var fallback = {
|
|
15686
|
+
"platform.angular_components.attach_files": "Anexar arquivos",
|
|
15687
|
+
"platform.angular_components.remove": "Remover",
|
|
15688
|
+
"platform.angular_components.file_attached_successfully": "Arquivo anexado com sucesso",
|
|
15689
|
+
"platform.angular_components.loading_file": "Carregando arquivo",
|
|
15642
15690
|
"platform.angular_components.iassist_text_generator": "IAssist Gerador de texto",
|
|
15643
15691
|
"platform.angular_components.copied_to_clipboard": "Copiado para área de transferência",
|
|
15644
15692
|
"platform.angular_components.copy_field_content": "Copiar conteúdo preenchido",
|
|
@@ -16033,46 +16081,47 @@
|
|
|
16033
16081
|
exports.fallback = fallback;
|
|
16034
16082
|
exports.ɵa = TooltipComponent;
|
|
16035
16083
|
exports.ɵb = TooltipDirective;
|
|
16036
|
-
exports.ɵba =
|
|
16037
|
-
exports.ɵbb =
|
|
16038
|
-
exports.ɵbc =
|
|
16039
|
-
exports.ɵbd =
|
|
16040
|
-
exports.ɵbe =
|
|
16041
|
-
exports.ɵbf =
|
|
16042
|
-
exports.ɵbg =
|
|
16043
|
-
exports.ɵbh =
|
|
16044
|
-
exports.ɵ
|
|
16045
|
-
exports.ɵbk =
|
|
16046
|
-
exports.ɵbl =
|
|
16047
|
-
exports.ɵbm =
|
|
16048
|
-
exports.ɵbn =
|
|
16049
|
-
exports.ɵbo =
|
|
16050
|
-
exports.ɵbp =
|
|
16051
|
-
exports.ɵbq =
|
|
16052
|
-
exports.ɵbr =
|
|
16053
|
-
exports.ɵbs =
|
|
16054
|
-
exports.ɵbt =
|
|
16055
|
-
exports.ɵbu =
|
|
16056
|
-
exports.ɵbv =
|
|
16057
|
-
exports.ɵbw =
|
|
16058
|
-
exports.ɵbx =
|
|
16059
|
-
exports.ɵby =
|
|
16060
|
-
exports.ɵbz =
|
|
16084
|
+
exports.ɵba = RadioButtonComponent;
|
|
16085
|
+
exports.ɵbb = RowComponent;
|
|
16086
|
+
exports.ɵbc = SectionComponent;
|
|
16087
|
+
exports.ɵbd = SelectFieldComponent;
|
|
16088
|
+
exports.ɵbe = SliderFieldComponent;
|
|
16089
|
+
exports.ɵbf = TextAreaFieldComponent;
|
|
16090
|
+
exports.ɵbg = TextAreaIAFieldComponent;
|
|
16091
|
+
exports.ɵbh = IAssistService;
|
|
16092
|
+
exports.ɵbi = TextFieldComponent;
|
|
16093
|
+
exports.ɵbk = DecimalField;
|
|
16094
|
+
exports.ɵbl = SideTableComponent;
|
|
16095
|
+
exports.ɵbm = StructureModule;
|
|
16096
|
+
exports.ɵbn = HeaderComponent;
|
|
16097
|
+
exports.ɵbo = FooterComponent;
|
|
16098
|
+
exports.ɵbp = NumberLocaleOptions;
|
|
16099
|
+
exports.ɵbq = ThumbnailService;
|
|
16100
|
+
exports.ɵbr = BorderButtonModule;
|
|
16101
|
+
exports.ɵbs = BorderButtonComponent;
|
|
16102
|
+
exports.ɵbt = TimelineItemModule;
|
|
16103
|
+
exports.ɵbu = TimelineIconItemComponent;
|
|
16104
|
+
exports.ɵbv = HorizontalTimelineModule;
|
|
16105
|
+
exports.ɵbw = HorizontalTimelineComponent;
|
|
16106
|
+
exports.ɵbx = VerticalTimelineModule;
|
|
16107
|
+
exports.ɵby = VerticalTimelineComponent;
|
|
16108
|
+
exports.ɵbz = RangeLineComponent;
|
|
16061
16109
|
exports.ɵc = CountryPhonePickerService;
|
|
16062
|
-
exports.ɵca =
|
|
16063
|
-
exports.ɵcb =
|
|
16064
|
-
exports.ɵcc =
|
|
16065
|
-
exports.ɵcd =
|
|
16066
|
-
exports.ɵce =
|
|
16067
|
-
exports.ɵcf =
|
|
16068
|
-
exports.ɵcg =
|
|
16069
|
-
exports.ɵch =
|
|
16070
|
-
exports.ɵci =
|
|
16071
|
-
exports.ɵcj =
|
|
16072
|
-
exports.ɵck =
|
|
16073
|
-
exports.ɵcl =
|
|
16074
|
-
exports.ɵcm =
|
|
16075
|
-
exports.ɵcn =
|
|
16110
|
+
exports.ɵca = CollapseOptionComponent;
|
|
16111
|
+
exports.ɵcb = CollapsedItemsComponent;
|
|
16112
|
+
exports.ɵcc = VerticalItemsComponent;
|
|
16113
|
+
exports.ɵcd = InfiniteScrollModule;
|
|
16114
|
+
exports.ɵce = InfiniteScrollDirective;
|
|
16115
|
+
exports.ɵcf = CustomTranslationsModule;
|
|
16116
|
+
exports.ɵcg = CodeEditorComponent;
|
|
16117
|
+
exports.ɵch = CoreFacade;
|
|
16118
|
+
exports.ɵci = CodeMirror6Core;
|
|
16119
|
+
exports.ɵcj = TieredMenuEventService;
|
|
16120
|
+
exports.ɵck = TieredMenuService;
|
|
16121
|
+
exports.ɵcl = TieredMenuComponent;
|
|
16122
|
+
exports.ɵcm = TieredMenuNestedComponent;
|
|
16123
|
+
exports.ɵcn = TieredMenuItemComponent;
|
|
16124
|
+
exports.ɵco = TieredMenuDividerComponent;
|
|
16076
16125
|
exports.ɵd = LocalizedCurrencyImpurePipe;
|
|
16077
16126
|
exports.ɵe = LocalizedBignumberPipe;
|
|
16078
16127
|
exports.ɵf = LocalizedBignumberImpurePipe;
|
|
@@ -16082,20 +16131,20 @@
|
|
|
16082
16131
|
exports.ɵj = TableColumnsComponent;
|
|
16083
16132
|
exports.ɵk = TablePagingComponent;
|
|
16084
16133
|
exports.ɵl = AutocompleteFieldComponent;
|
|
16085
|
-
exports.ɵm =
|
|
16086
|
-
exports.ɵn =
|
|
16087
|
-
exports.ɵo =
|
|
16088
|
-
exports.ɵp =
|
|
16089
|
-
exports.ɵq =
|
|
16090
|
-
exports.ɵr =
|
|
16091
|
-
exports.ɵs =
|
|
16092
|
-
exports.ɵt =
|
|
16093
|
-
exports.ɵu =
|
|
16094
|
-
exports.ɵv =
|
|
16095
|
-
exports.ɵw =
|
|
16096
|
-
exports.ɵx =
|
|
16097
|
-
exports.ɵy =
|
|
16098
|
-
exports.ɵz =
|
|
16134
|
+
exports.ɵm = BignumberFieldComponent;
|
|
16135
|
+
exports.ɵn = BooleanFieldComponent;
|
|
16136
|
+
exports.ɵo = BooleanSwitchFieldComponent;
|
|
16137
|
+
exports.ɵp = CalendarFieldComponent;
|
|
16138
|
+
exports.ɵq = ChipsFieldComponent;
|
|
16139
|
+
exports.ɵr = CountryPhonePickerFieldComponent;
|
|
16140
|
+
exports.ɵs = CurrencyFieldComponent;
|
|
16141
|
+
exports.ɵt = DynamicFieldComponent;
|
|
16142
|
+
exports.ɵu = DynamicFormDirective;
|
|
16143
|
+
exports.ɵv = FieldsetComponent;
|
|
16144
|
+
exports.ɵw = FileUploadComponent$1;
|
|
16145
|
+
exports.ɵx = LookupFieldComponent;
|
|
16146
|
+
exports.ɵy = NumberFieldComponent;
|
|
16147
|
+
exports.ɵz = PasswordFieldComponent;
|
|
16099
16148
|
|
|
16100
16149
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
16101
16150
|
|