@gipisistemas/ng-core 1.1.3 → 1.1.5
Sign up to get free protection for your applications and to get access to all the features.
- package/assets/styles/colors.scss +5 -1
- package/bundles/gipisistemas-ng-core.umd.js +2098 -1285
- package/bundles/gipisistemas-ng-core.umd.js.map +1 -1
- package/bundles/gipisistemas-ng-core.umd.min.js +10 -9
- package/bundles/gipisistemas-ng-core.umd.min.js.map +1 -1
- package/core/gipi-components/models/sort.model.d.ts +3 -3
- package/core/utils/array.util.d.ts +2 -2
- package/core/utils/object.util.d.ts +3 -5
- package/core/utils/string.util.d.ts +4 -0
- package/esm2015/core/gipi-components/models/sort.model.js +1 -1
- package/esm2015/core/gipi-components/services/abstract-crud.service.js +18 -24
- package/esm2015/core/utils/array.util.js +4 -2
- package/esm2015/core/utils/object.util.js +5 -9
- package/esm2015/core/utils/string.util.js +27 -1
- package/esm2015/gipi-components.js +11 -1
- package/esm2015/shared/components/input/input.component.js +46 -23
- package/esm2015/shared/components/select-entity-paged/shared/select-search/select-search.component.js +2 -2
- package/esm2015/shared/components/table/table.component.js +1 -1
- package/esm2015/shared/gipi-components/abstract-form/abstract-form.component.js +1 -1
- package/esm2015/shared/gipi-components/button/button.component.js +18 -2
- package/esm2015/shared/gipi-components/card/card.component.js +113 -0
- package/esm2015/shared/gipi-components/datepicker/datepicker/datepicker.component.js +8 -3
- package/esm2015/shared/gipi-components/empty-state/empty-state.component.js +30 -0
- package/esm2015/shared/gipi-components/input-select-paged/input-search/input-search.component.js +2 -2
- package/esm2015/shared/gipi-components/layout-grid/col.directive.js +4 -4
- package/esm2015/shared/gipi-components/month-year-picker/month-year-picker.component.js +2 -2
- package/esm2015/shared/gipi-components/notification/notification.component.js +8 -3
- package/esm2015/shared/gipi-components/popover/shared/popover-trigger.js +4 -4
- package/esm2015/shared/gipi-components/sidebar/sidenav/sidenav.component.js +35 -3
- package/esm2015/shared/gipi-components/slide-toggle/slide-toggle.component.js +113 -0
- package/esm2015/shared/gipi-components/split-button/split-button.component.js +243 -0
- package/esm2015/shared/gipi-components/tabs/shared/dynamic-tab.directive.js +18 -0
- package/esm2015/shared/gipi-components/tabs/shared/tab.model.js +8 -0
- package/esm2015/shared/gipi-components/tabs/tab/tab.component.js +66 -0
- package/esm2015/shared/gipi-components/tabs/tab-group/tab-group.component.js +123 -0
- package/esm2015/shared/gipi-components/textarea/textarea.component.js +298 -0
- package/esm2015/shared/shared.module.js +22 -16
- package/esm2015/shared.js +1 -5
- package/esm5/core/gipi-components/models/sort.model.js +1 -1
- package/esm5/core/gipi-components/services/abstract-crud.service.js +18 -24
- package/esm5/core/utils/array.util.js +4 -3
- package/esm5/core/utils/object.util.js +5 -9
- package/esm5/core/utils/string.util.js +27 -1
- package/esm5/gipi-components.js +11 -1
- package/esm5/shared/components/input/input.component.js +46 -23
- package/esm5/shared/components/select-entity-paged/shared/select-search/select-search.component.js +2 -2
- package/esm5/shared/components/table/table.component.js +1 -1
- package/esm5/shared/gipi-components/abstract-form/abstract-form.component.js +1 -1
- package/esm5/shared/gipi-components/button/button.component.js +22 -2
- package/esm5/shared/gipi-components/card/card.component.js +135 -0
- package/esm5/shared/gipi-components/datepicker/datepicker/datepicker.component.js +8 -3
- package/esm5/shared/gipi-components/empty-state/empty-state.component.js +33 -0
- package/esm5/shared/gipi-components/input-select-paged/input-search/input-search.component.js +2 -2
- package/esm5/shared/gipi-components/layout-grid/col.directive.js +4 -4
- package/esm5/shared/gipi-components/month-year-picker/month-year-picker.component.js +2 -2
- package/esm5/shared/gipi-components/notification/notification.component.js +8 -3
- package/esm5/shared/gipi-components/popover/shared/popover-trigger.js +4 -4
- package/esm5/shared/gipi-components/sidebar/sidenav/sidenav.component.js +35 -3
- package/esm5/shared/gipi-components/slide-toggle/slide-toggle.component.js +127 -0
- package/esm5/shared/gipi-components/split-button/split-button.component.js +249 -0
- package/esm5/shared/gipi-components/tabs/shared/dynamic-tab.directive.js +19 -0
- package/esm5/shared/gipi-components/tabs/shared/tab.model.js +10 -0
- package/esm5/shared/gipi-components/tabs/tab/tab.component.js +67 -0
- package/esm5/shared/gipi-components/tabs/tab-group/tab-group.component.js +131 -0
- package/esm5/shared/gipi-components/textarea/textarea.component.js +352 -0
- package/esm5/shared/shared.module.js +22 -16
- package/esm5/shared.js +1 -5
- package/fesm2015/gipisistemas-ng-core.js +1991 -1274
- package/fesm2015/gipisistemas-ng-core.js.map +1 -1
- package/fesm5/gipisistemas-ng-core.js +2088 -1281
- package/fesm5/gipisistemas-ng-core.js.map +1 -1
- package/gipi-components.d.ts +9 -0
- package/gipisistemas-ng-core.metadata.json +1 -1
- package/package.json +1 -2
- package/shared/components/input/input.component.d.ts +13 -11
- package/shared/components/table/table.component.d.ts +3 -3
- package/shared/gipi-components/button/button.component.d.ts +14 -0
- package/shared/gipi-components/card/card.component.d.ts +23 -0
- package/shared/gipi-components/empty-state/empty-state.component.d.ts +5 -0
- package/shared/gipi-components/notification/notification.component.d.ts +1 -0
- package/shared/gipi-components/sidebar/sidenav/sidenav.component.d.ts +7 -0
- package/shared/gipi-components/slide-toggle/slide-toggle.component.d.ts +27 -0
- package/shared/gipi-components/split-button/split-button.component.d.ts +60 -0
- package/shared/{directives → gipi-components/tabs/shared}/dynamic-tab.directive.d.ts +1 -1
- package/shared/gipi-components/tabs/shared/tab.model.d.ts +12 -0
- package/shared/{components → gipi-components/tabs}/tab/tab.component.d.ts +4 -2
- package/shared/gipi-components/tabs/tab-group/tab-group.component.d.ts +22 -0
- package/shared/gipi-components/textarea/textarea.component.d.ts +68 -0
- package/shared.d.ts +0 -4
- package/esm2015/shared/components/select-button/select-button.component.js +0 -181
- package/esm2015/shared/components/tab/tab.component.js +0 -57
- package/esm2015/shared/components/tab-group/tab-group.component.js +0 -117
- package/esm2015/shared/directives/dynamic-tab.directive.js +0 -18
- package/esm5/shared/components/select-button/select-button.component.js +0 -195
- package/esm5/shared/components/tab/tab.component.js +0 -58
- package/esm5/shared/components/tab-group/tab-group.component.js +0 -125
- package/esm5/shared/directives/dynamic-tab.directive.js +0 -19
- package/shared/components/select-button/select-button.component.d.ts +0 -35
- package/shared/components/tab-group/tab-group.component.d.ts +0 -22
@@ -1,8 +1,10 @@
|
|
1
1
|
(function (global, factory) {
|
2
|
-
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/cdk/stepper'), require('@angular/common'), require('@angular/flex-layout'), require('@angular/forms'), require('@angular/material'), require('@angular/router'), require('@material-extended/mde'), require('angular-mentions'), require('ngx-currency'), require('ngx-infinite-scroll'), require('ngx-mask'), require('ngx-material-timepicker'), require('@angular/cdk-experimental/popover-edit'), require('@angular/cdk/a11y'), require('@angular/cdk/drag-drop'), require('@angular/cdk/portal'), require('@angular/cdk/scrolling'), require('@angular/cdk/table'), require('@angular/cdk/tree'), require('@angular/material/autocomplete'), require('@angular/material/badge'), require('@angular/material/bottom-sheet'), require('@angular/material/button'), require('@angular/material/button-toggle'), require('@angular/material/card'), require('@angular/material/checkbox'), require('@angular/material/chips'), require('@angular/material/core'), require('@angular/material/dialog'), require('@angular/material/divider'), require('@angular/material/expansion'), require('@angular/material/form-field'), require('@angular/material/grid-list'), require('@angular/material/icon'), require('@angular/material/input'), require('@angular/material/list'), require('@angular/material/menu'), require('@angular/material/paginator'), require('@angular/material/progress-bar'), require('@angular/material/progress-spinner'), require('@angular/material/radio'), require('@angular/material/select'), require('@angular/material/sidenav'), require('@angular/material/slide-toggle'), require('@angular/material/slider'), require('@angular/material/snack-bar'), require('@angular/material/sort'), require('@angular/material/stepper'), require('@angular/material/table'), require('@angular/material/tabs'), require('@angular/material/toolbar'), require('@angular/material/tooltip'), require('@angular/material/tree'), require('@angular/common/http'), require('rxjs'), require('rxjs/operators'), require('@angular/animations'), require('@angular/cdk/keycodes'), require('@angular/cdk/coercion'), require('@angular/cdk/layout'), require('@angular/cdk/platform'), require('@angular/cdk/bidi'), require('@angular/cdk/overlay'), require('moment'), require('@angular/material/datepicker'), require('@angular/platform-browser/animations'), require('@angular/platform-browser'), require('@brazilian-utils/brazilian-utils')
|
3
|
-
typeof define === 'function' && define.amd ? define('@gipisistemas/ng-core', ['exports', '@angular/core', '@angular/cdk/stepper', '@angular/common', '@angular/flex-layout', '@angular/forms', '@angular/material', '@angular/router', '@material-extended/mde', 'angular-mentions', 'ngx-currency', 'ngx-infinite-scroll', 'ngx-mask', 'ngx-material-timepicker', '@angular/cdk-experimental/popover-edit', '@angular/cdk/a11y', '@angular/cdk/drag-drop', '@angular/cdk/portal', '@angular/cdk/scrolling', '@angular/cdk/table', '@angular/cdk/tree', '@angular/material/autocomplete', '@angular/material/badge', '@angular/material/bottom-sheet', '@angular/material/button', '@angular/material/button-toggle', '@angular/material/card', '@angular/material/checkbox', '@angular/material/chips', '@angular/material/core', '@angular/material/dialog', '@angular/material/divider', '@angular/material/expansion', '@angular/material/form-field', '@angular/material/grid-list', '@angular/material/icon', '@angular/material/input', '@angular/material/list', '@angular/material/menu', '@angular/material/paginator', '@angular/material/progress-bar', '@angular/material/progress-spinner', '@angular/material/radio', '@angular/material/select', '@angular/material/sidenav', '@angular/material/slide-toggle', '@angular/material/slider', '@angular/material/snack-bar', '@angular/material/sort', '@angular/material/stepper', '@angular/material/table', '@angular/material/tabs', '@angular/material/toolbar', '@angular/material/tooltip', '@angular/material/tree', '@angular/common/http', 'rxjs', 'rxjs/operators', '@angular/animations', '@angular/cdk/keycodes', '@angular/cdk/coercion', '@angular/cdk/layout', '@angular/cdk/platform', '@angular/cdk/bidi', '@angular/cdk/overlay', 'moment', '@angular/material/datepicker', '@angular/platform-browser/animations', '@angular/platform-browser', '@brazilian-utils/brazilian-utils'
|
4
|
-
(global = global || self, factory((global.gipisistemas = global.gipisistemas || {}, global.gipisistemas['ng-core'] = {}), global.ng.core, global.ng.cdk.stepper, global.ng.common, global.ng['flex-layout'], global.ng.forms, global.ng.material, global.ng.router, global.mde, global.angularMentions, global.ngxCurrency, global.ngxInfiniteScroll, global.ngxMask, global.ngxMaterialTimepicker, global.ng['cdk-experimental']['popover-edit'], global.ng.cdk.a11y, global.ng.cdk['drag-drop'], global.ng.cdk.portal, global.ng.cdk.scrolling, global.ng.cdk.table, global.ng.cdk.tree, global.ng.material.autocomplete, global.ng.material.badge, global.ng.material['bottom-sheet'], global.ng.material.button, global.ng.material['button-toggle'], global.ng.material.card, global.ng.material.checkbox, global.ng.material.chips, global.ng.material.core, global.ng.material.dialog, global.ng.material.divider, global.ng.material.expansion, global.ng.material['form-field'], global.ng.material['grid-list'], global.ng.material.icon, global.ng.material.input, global.ng.material.list, global.ng.material.menu, global.ng.material.paginator, global.ng.material['progress-bar'], global.ng.material['progress-spinner'], global.ng.material.radio, global.ng.material.select, global.ng.material.sidenav, global.ng.material['slide-toggle'], global.ng.material.slider, global.ng.material['snack-bar'], global.ng.material.sort, global.ng.material.stepper, global.ng.material.table, global.ng.material.tabs, global.ng.material.toolbar, global.ng.material.tooltip, global.ng.material.tree, global.ng.common.http, global.rxjs, global.rxjs.operators, global.ng.animations, global.ng.cdk.keycodes, global.ng.cdk.coercion, global.ng.cdk.layout, global.ng.cdk.platform, global.ng.cdk.bidi, global.ng.cdk.overlay, global.moment_, global.ng.material.datepicker, global.ng.platformBrowser.animations, global.ng.platformBrowser, global.brazilianUtils
|
5
|
-
}(this, (function (exports, core, stepper, common, flexLayout, forms, material, router, mde, angularMentions, ngxCurrency, ngxInfiniteScroll, ngxMask, ngxMaterialTimepicker, popoverEdit, a11y, dragDrop, portal, scrolling, table, tree, autocomplete, badge, bottomSheet, button, buttonToggle, card, checkbox, chips, core$1, dialog, divider, expansion, formField, gridList, icon, input, list, menu, paginator, progressBar, progressSpinner, radio, select, sidenav, slideToggle, slider, snackBar, sort, stepper$1, table$1, tabs, toolbar, tooltip, tree$1, http, rxjs, operators, animations, keycodes, coercion, layout, platform, bidi, overlay, moment_, datepicker, animations$1, platformBrowser, brazilianUtils
|
2
|
+
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/cdk/stepper'), require('@angular/common'), require('@angular/flex-layout'), require('@angular/forms'), require('@angular/material'), require('@angular/router'), require('@material-extended/mde'), require('angular-mentions'), require('ngx-currency'), require('ngx-infinite-scroll'), require('ngx-mask'), require('ngx-material-timepicker'), require('@angular/cdk-experimental/popover-edit'), require('@angular/cdk/a11y'), require('@angular/cdk/drag-drop'), require('@angular/cdk/portal'), require('@angular/cdk/scrolling'), require('@angular/cdk/table'), require('@angular/cdk/tree'), require('@angular/material/autocomplete'), require('@angular/material/badge'), require('@angular/material/bottom-sheet'), require('@angular/material/button'), require('@angular/material/button-toggle'), require('@angular/material/card'), require('@angular/material/checkbox'), require('@angular/material/chips'), require('@angular/material/core'), require('@angular/material/dialog'), require('@angular/material/divider'), require('@angular/material/expansion'), require('@angular/material/form-field'), require('@angular/material/grid-list'), require('@angular/material/icon'), require('@angular/material/input'), require('@angular/material/list'), require('@angular/material/menu'), require('@angular/material/paginator'), require('@angular/material/progress-bar'), require('@angular/material/progress-spinner'), require('@angular/material/radio'), require('@angular/material/select'), require('@angular/material/sidenav'), require('@angular/material/slide-toggle'), require('@angular/material/slider'), require('@angular/material/snack-bar'), require('@angular/material/sort'), require('@angular/material/stepper'), require('@angular/material/table'), require('@angular/material/tabs'), require('@angular/material/toolbar'), require('@angular/material/tooltip'), require('@angular/material/tree'), require('rfdc'), require('@angular/common/http'), require('rxjs'), require('rxjs/operators'), require('libphonenumber-js'), require('@angular/animations'), require('@angular/cdk/keycodes'), require('@angular/cdk/coercion'), require('@angular/cdk/layout'), require('@angular/cdk/platform'), require('@angular/cdk/bidi'), require('@angular/cdk/overlay'), require('moment'), require('@angular/material/datepicker'), require('@angular/platform-browser/animations'), require('@angular/platform-browser'), require('@brazilian-utils/brazilian-utils')) :
|
3
|
+
typeof define === 'function' && define.amd ? define('@gipisistemas/ng-core', ['exports', '@angular/core', '@angular/cdk/stepper', '@angular/common', '@angular/flex-layout', '@angular/forms', '@angular/material', '@angular/router', '@material-extended/mde', 'angular-mentions', 'ngx-currency', 'ngx-infinite-scroll', 'ngx-mask', 'ngx-material-timepicker', '@angular/cdk-experimental/popover-edit', '@angular/cdk/a11y', '@angular/cdk/drag-drop', '@angular/cdk/portal', '@angular/cdk/scrolling', '@angular/cdk/table', '@angular/cdk/tree', '@angular/material/autocomplete', '@angular/material/badge', '@angular/material/bottom-sheet', '@angular/material/button', '@angular/material/button-toggle', '@angular/material/card', '@angular/material/checkbox', '@angular/material/chips', '@angular/material/core', '@angular/material/dialog', '@angular/material/divider', '@angular/material/expansion', '@angular/material/form-field', '@angular/material/grid-list', '@angular/material/icon', '@angular/material/input', '@angular/material/list', '@angular/material/menu', '@angular/material/paginator', '@angular/material/progress-bar', '@angular/material/progress-spinner', '@angular/material/radio', '@angular/material/select', '@angular/material/sidenav', '@angular/material/slide-toggle', '@angular/material/slider', '@angular/material/snack-bar', '@angular/material/sort', '@angular/material/stepper', '@angular/material/table', '@angular/material/tabs', '@angular/material/toolbar', '@angular/material/tooltip', '@angular/material/tree', 'rfdc', '@angular/common/http', 'rxjs', 'rxjs/operators', 'libphonenumber-js', '@angular/animations', '@angular/cdk/keycodes', '@angular/cdk/coercion', '@angular/cdk/layout', '@angular/cdk/platform', '@angular/cdk/bidi', '@angular/cdk/overlay', 'moment', '@angular/material/datepicker', '@angular/platform-browser/animations', '@angular/platform-browser', '@brazilian-utils/brazilian-utils'], factory) :
|
4
|
+
(global = global || self, factory((global.gipisistemas = global.gipisistemas || {}, global.gipisistemas['ng-core'] = {}), global.ng.core, global.ng.cdk.stepper, global.ng.common, global.ng['flex-layout'], global.ng.forms, global.ng.material, global.ng.router, global.mde, global.angularMentions, global.ngxCurrency, global.ngxInfiniteScroll, global.ngxMask, global.ngxMaterialTimepicker, global.ng['cdk-experimental']['popover-edit'], global.ng.cdk.a11y, global.ng.cdk['drag-drop'], global.ng.cdk.portal, global.ng.cdk.scrolling, global.ng.cdk.table, global.ng.cdk.tree, global.ng.material.autocomplete, global.ng.material.badge, global.ng.material['bottom-sheet'], global.ng.material.button, global.ng.material['button-toggle'], global.ng.material.card, global.ng.material.checkbox, global.ng.material.chips, global.ng.material.core, global.ng.material.dialog, global.ng.material.divider, global.ng.material.expansion, global.ng.material['form-field'], global.ng.material['grid-list'], global.ng.material.icon, global.ng.material.input, global.ng.material.list, global.ng.material.menu, global.ng.material.paginator, global.ng.material['progress-bar'], global.ng.material['progress-spinner'], global.ng.material.radio, global.ng.material.select, global.ng.material.sidenav, global.ng.material['slide-toggle'], global.ng.material.slider, global.ng.material['snack-bar'], global.ng.material.sort, global.ng.material.stepper, global.ng.material.table, global.ng.material.tabs, global.ng.material.toolbar, global.ng.material.tooltip, global.ng.material.tree, global.rfdc_, global.ng.common.http, global.rxjs, global.rxjs.operators, global.libphonenumberJs, global.ng.animations, global.ng.cdk.keycodes, global.ng.cdk.coercion, global.ng.cdk.layout, global.ng.cdk.platform, global.ng.cdk.bidi, global.ng.cdk.overlay, global.moment_, global.ng.material.datepicker, global.ng.platformBrowser.animations, global.ng.platformBrowser, global.brazilianUtils));
|
5
|
+
}(this, (function (exports, core, stepper, common, flexLayout, forms, material, router, mde, angularMentions, ngxCurrency, ngxInfiniteScroll, ngxMask, ngxMaterialTimepicker, popoverEdit, a11y, dragDrop, portal, scrolling, table, tree, autocomplete, badge, bottomSheet, button, buttonToggle, card, checkbox, chips, core$1, dialog, divider, expansion, formField, gridList, icon, input, list, menu, paginator, progressBar, progressSpinner, radio, select, sidenav, slideToggle, slider, snackBar, sort, stepper$1, table$1, tabs, toolbar, tooltip, tree$1, rfdc_, http, rxjs, operators, libphonenumberJs, animations, keycodes, coercion, layout, platform, bidi, overlay, moment_, datepicker, animations$1, platformBrowser, brazilianUtils) { 'use strict';
|
6
|
+
|
7
|
+
rfdc_ = rfdc_ && rfdc_.hasOwnProperty('default') ? rfdc_['default'] : rfdc_;
|
6
8
|
|
7
9
|
/*! *****************************************************************************
|
8
10
|
Copyright (c) Microsoft Corporation.
|
@@ -718,10 +720,37 @@
|
|
718
720
|
StringUtil.truncateWithEllipses = function (text, max) {
|
719
721
|
return text.trim().substring(0, max - 1) + (text.trim().length > max) ? '...' : '';
|
720
722
|
};
|
723
|
+
/** Codifica a string em Base64 */
|
724
|
+
StringUtil.encodeBase64 = function (input) {
|
725
|
+
if (this.isEmpty(input)) {
|
726
|
+
return '';
|
727
|
+
}
|
728
|
+
var utf8Encoder = new TextEncoder();
|
729
|
+
var utf8Bytes = utf8Encoder.encode(input);
|
730
|
+
var binary = '';
|
731
|
+
utf8Bytes.forEach(function (byte) {
|
732
|
+
binary += String.fromCharCode(byte);
|
733
|
+
});
|
734
|
+
return btoa(binary);
|
735
|
+
};
|
736
|
+
/** Decodifica a string Base64 */
|
737
|
+
StringUtil.decodeBase64 = function (input) {
|
738
|
+
if (this.isEmpty(input)) {
|
739
|
+
return '';
|
740
|
+
}
|
741
|
+
var binary = atob(input);
|
742
|
+
var utf8Decoder = new TextDecoder();
|
743
|
+
var utf8Bytes = new Uint8Array(binary.length);
|
744
|
+
for (var i = 0; i < binary.length; i++) {
|
745
|
+
utf8Bytes[i] = binary.charCodeAt(i);
|
746
|
+
}
|
747
|
+
return utf8Decoder.decode(utf8Bytes);
|
748
|
+
};
|
721
749
|
StringUtil.EMPTY = '';
|
722
750
|
return StringUtil;
|
723
751
|
}());
|
724
752
|
|
753
|
+
var cloneDeep = rfdc_();
|
725
754
|
/** @dynamic */
|
726
755
|
var ObjectUtil = /** @class */ (function () {
|
727
756
|
function ObjectUtil() {
|
@@ -735,21 +764,15 @@
|
|
735
764
|
}
|
736
765
|
var id = null;
|
737
766
|
if (typeof value === 'object') {
|
738
|
-
id =
|
767
|
+
id = value['id'];
|
739
768
|
}
|
740
769
|
return !UUIDUtil.isValid(id);
|
741
770
|
};
|
742
|
-
ObjectUtil.isNotNil = function (value) {
|
743
|
-
return typeof value !== 'undefined' && value !== null;
|
744
|
-
};
|
745
|
-
ObjectUtil.isNil = function (value) {
|
746
|
-
return typeof value === 'undefined' || value === null;
|
747
|
-
};
|
748
771
|
ObjectUtil.clone = function (value) {
|
749
772
|
if (ObjectUtil.isNull(value)) {
|
750
773
|
return new Object();
|
751
774
|
}
|
752
|
-
return
|
775
|
+
return cloneDeep(value);
|
753
776
|
};
|
754
777
|
ObjectUtil.resolveFieldData = function (data, field) {
|
755
778
|
if (data && field) {
|
@@ -1301,10 +1324,171 @@
|
|
1301
1324
|
return InputFileComponent;
|
1302
1325
|
}(AbstractComponent));
|
1303
1326
|
|
1327
|
+
/** @dynamic */
|
1328
|
+
var NumberUtil = /** @class */ (function () {
|
1329
|
+
function NumberUtil() {
|
1330
|
+
}
|
1331
|
+
NumberUtil.isPositive = function (value) {
|
1332
|
+
return !ObjectUtil.isNull(value) && value > 0;
|
1333
|
+
};
|
1334
|
+
NumberUtil.isNegative = function (value) {
|
1335
|
+
return !ObjectUtil.isNull(value) && value < 0;
|
1336
|
+
};
|
1337
|
+
NumberUtil.format = function (value, digitsInfo, type) {
|
1338
|
+
if (!ObjectUtil.isNull(value) && (!type || type === 'NUMBER')) {
|
1339
|
+
return common.formatNumber(value, 'pt', digitsInfo);
|
1340
|
+
}
|
1341
|
+
else if (!ObjectUtil.isNull(value) && type === 'PERCENT') {
|
1342
|
+
return common.formatPercent(value / 100, 'pt', digitsInfo);
|
1343
|
+
}
|
1344
|
+
return StringUtil.EMPTY;
|
1345
|
+
};
|
1346
|
+
NumberUtil.onlyNumbers = function (value) {
|
1347
|
+
return String(value).replace(/[^\d]/g, '');
|
1348
|
+
};
|
1349
|
+
NumberUtil.isNumber = function (value) {
|
1350
|
+
return value !== null && value !== undefined && !isNaN(value) && typeof value === 'number';
|
1351
|
+
};
|
1352
|
+
return NumberUtil;
|
1353
|
+
}());
|
1354
|
+
|
1355
|
+
/** @dynamic */
|
1356
|
+
var PhoneUtil = /** @class */ (function () {
|
1357
|
+
function PhoneUtil() {
|
1358
|
+
}
|
1359
|
+
PhoneUtil.removeCharacters = function (value) {
|
1360
|
+
if (StringUtil.isEmpty(value)) {
|
1361
|
+
return '';
|
1362
|
+
}
|
1363
|
+
return value.replace(/\D/g, '');
|
1364
|
+
};
|
1365
|
+
PhoneUtil.maskLib = function (phoneNumber, state, country) {
|
1366
|
+
if (country === void 0) { country = 'BR'; }
|
1367
|
+
var exampleNumber;
|
1368
|
+
if (!StringUtil.isEmpty(phoneNumber)) {
|
1369
|
+
var parsedNumber = libphonenumberJs.parsePhoneNumberFromString(phoneNumber, country);
|
1370
|
+
if (parsedNumber) {
|
1371
|
+
exampleNumber = parsedNumber;
|
1372
|
+
}
|
1373
|
+
}
|
1374
|
+
else {
|
1375
|
+
exampleNumber = libphonenumberJs.getExampleNumber(country, state);
|
1376
|
+
}
|
1377
|
+
if (exampleNumber) {
|
1378
|
+
var formattedNumber = exampleNumber.formatNational();
|
1379
|
+
return formattedNumber.replace(/\d/g, '0');
|
1380
|
+
}
|
1381
|
+
else {
|
1382
|
+
throw new Error('Estado não suportado ou código de estado inválido.');
|
1383
|
+
}
|
1384
|
+
};
|
1385
|
+
PhoneUtil.formatLib = function (phoneNumber, country) {
|
1386
|
+
if (country === void 0) { country = 'BR'; }
|
1387
|
+
try {
|
1388
|
+
var parsedNumber = libphonenumberJs.parsePhoneNumberFromString(phoneNumber, country);
|
1389
|
+
if (parsedNumber) {
|
1390
|
+
return parsedNumber.formatNational();
|
1391
|
+
}
|
1392
|
+
else {
|
1393
|
+
throw new Error('Número de telefone inválido.');
|
1394
|
+
}
|
1395
|
+
}
|
1396
|
+
catch (error) {
|
1397
|
+
throw new Error('Erro ao formatar o número de telefone: ' + error.message);
|
1398
|
+
}
|
1399
|
+
};
|
1400
|
+
PhoneUtil.format = function (number, mask) {
|
1401
|
+
var numberNotFormatted = NumberUtil.onlyNumbers(number);
|
1402
|
+
var phoneFormatted = '';
|
1403
|
+
if ((numberNotFormatted.length < 8) ||
|
1404
|
+
(numberNotFormatted.length > 12) ||
|
1405
|
+
(!this.isPossible(numberNotFormatted) && !this.isValid(numberNotFormatted))) {
|
1406
|
+
return numberNotFormatted;
|
1407
|
+
}
|
1408
|
+
if (StringUtil.isEmpty(mask)) {
|
1409
|
+
mask = this.mask(numberNotFormatted);
|
1410
|
+
}
|
1411
|
+
for (var i = 0, j = 0; i < mask.length && j < numberNotFormatted.length; i++) {
|
1412
|
+
phoneFormatted += mask.charAt(i) === '0' ? numberNotFormatted.charAt(j++) : mask.charAt(i);
|
1413
|
+
}
|
1414
|
+
return phoneFormatted;
|
1415
|
+
};
|
1416
|
+
PhoneUtil.mask = function (phone) {
|
1417
|
+
var specialPrefixes = ['0900', '0800', '0700', '0600', '0500', '0400', '0300', '0200', '0100'];
|
1418
|
+
var phoneAux = this.removeCharacters(phone.replace(/\D/g, ''));
|
1419
|
+
if ((phoneAux.length < 8) ||
|
1420
|
+
(phoneAux.length > 12) ||
|
1421
|
+
(!this.isPossible(phoneAux) && !this.isValid(phoneAux))) {
|
1422
|
+
return '0*';
|
1423
|
+
}
|
1424
|
+
var existInArray = specialPrefixes.some(function (prefix) { return phoneAux.startsWith(prefix); });
|
1425
|
+
if (existInArray) {
|
1426
|
+
return '0000 000 0000'; // Para números especiais como 0800
|
1427
|
+
}
|
1428
|
+
switch (phoneAux.length) {
|
1429
|
+
case 8: return '0000-0000';
|
1430
|
+
case 9: return '0 0000-0000';
|
1431
|
+
case 10: return '(00) 0000-0000';
|
1432
|
+
case 11: return '(00) 0 0000-0000';
|
1433
|
+
case 12: return '(000) 0 0000-0000';
|
1434
|
+
default: return '0*';
|
1435
|
+
}
|
1436
|
+
};
|
1437
|
+
PhoneUtil.isPossible = function (phoneNumber, country) {
|
1438
|
+
if (country === void 0) { country = 'BR'; }
|
1439
|
+
try {
|
1440
|
+
var parsedNumber = libphonenumberJs.parsePhoneNumberFromString(phoneNumber, country);
|
1441
|
+
return parsedNumber ? parsedNumber.isPossible() : false;
|
1442
|
+
}
|
1443
|
+
catch (error) {
|
1444
|
+
return false;
|
1445
|
+
}
|
1446
|
+
};
|
1447
|
+
PhoneUtil.isValid = function (phoneNumber, country) {
|
1448
|
+
if (country === void 0) { country = 'BR'; }
|
1449
|
+
try {
|
1450
|
+
var parsedNumber = libphonenumberJs.parsePhoneNumberFromString(phoneNumber, country);
|
1451
|
+
return parsedNumber ? parsedNumber.isValid() : false;
|
1452
|
+
}
|
1453
|
+
catch (error) {
|
1454
|
+
return false;
|
1455
|
+
}
|
1456
|
+
};
|
1457
|
+
PhoneUtil.getType = function (phoneNumber, country) {
|
1458
|
+
if (country === void 0) { country = 'BR'; }
|
1459
|
+
try {
|
1460
|
+
var parsedNumber = libphonenumberJs.parsePhoneNumberFromString(phoneNumber, country);
|
1461
|
+
return parsedNumber ? parsedNumber.getType() : null;
|
1462
|
+
}
|
1463
|
+
catch (error) {
|
1464
|
+
return null;
|
1465
|
+
}
|
1466
|
+
};
|
1467
|
+
PhoneUtil.isEqual = function (phoneNumber1, phoneNumber2, country) {
|
1468
|
+
if (country === void 0) { country = 'BR'; }
|
1469
|
+
try {
|
1470
|
+
var parsedNumber1 = libphonenumberJs.parsePhoneNumberFromString(phoneNumber1, country);
|
1471
|
+
var parsedNumber2 = libphonenumberJs.parsePhoneNumberFromString(phoneNumber2, country);
|
1472
|
+
if (parsedNumber1 && parsedNumber2) {
|
1473
|
+
return parsedNumber1.isEqual(parsedNumber2);
|
1474
|
+
}
|
1475
|
+
else {
|
1476
|
+
return false;
|
1477
|
+
}
|
1478
|
+
}
|
1479
|
+
catch (error) {
|
1480
|
+
return false;
|
1481
|
+
}
|
1482
|
+
};
|
1483
|
+
return PhoneUtil;
|
1484
|
+
}());
|
1485
|
+
|
1304
1486
|
var InputComponent = /** @class */ (function () {
|
1305
|
-
function InputComponent() {
|
1306
|
-
this.
|
1307
|
-
this.
|
1487
|
+
function InputComponent(elementRef, _changeDetectorRef) {
|
1488
|
+
this.elementRef = elementRef;
|
1489
|
+
this._changeDetectorRef = _changeDetectorRef;
|
1490
|
+
this._inputSubject$ = new rxjs.BehaviorSubject('');
|
1491
|
+
this._maskPhone$ = new rxjs.BehaviorSubject('');
|
1308
1492
|
this.tooltip = '';
|
1309
1493
|
this.styleClassFormField = '';
|
1310
1494
|
this.styleClassSuffix = '';
|
@@ -1327,16 +1511,21 @@
|
|
1327
1511
|
InputComponent_1 = InputComponent;
|
1328
1512
|
Object.defineProperty(InputComponent.prototype, "value", {
|
1329
1513
|
get: function () {
|
1330
|
-
return this.
|
1514
|
+
return this._value;
|
1331
1515
|
},
|
1332
|
-
set: function (
|
1516
|
+
set: function (value) {
|
1517
|
+
var valueAux = null;
|
1333
1518
|
if (this.lowerCase) {
|
1334
|
-
|
1519
|
+
valueAux = this.checkLowercase(this.checkSpaceDrop(value));
|
1335
1520
|
}
|
1336
1521
|
else {
|
1337
|
-
|
1522
|
+
valueAux = this.checkUppercase(this.checkSpaceDrop(value));
|
1338
1523
|
}
|
1339
|
-
this.
|
1524
|
+
this._value = valueAux;
|
1525
|
+
if (this.value !== value) {
|
1526
|
+
this._changeDetectorRef.detectChanges();
|
1527
|
+
}
|
1528
|
+
this.onChange(this._value);
|
1340
1529
|
this.onTouch();
|
1341
1530
|
},
|
1342
1531
|
enumerable: false,
|
@@ -1345,12 +1534,13 @@
|
|
1345
1534
|
InputComponent.prototype.ngOnInit = function () {
|
1346
1535
|
var _this = this;
|
1347
1536
|
if (this.phone) {
|
1348
|
-
this._inputSubject
|
1349
|
-
|
1537
|
+
this._inputSubject$.pipe(operators.debounceTime(300)).subscribe(function (value) {
|
1538
|
+
if (!StringUtil.isEmpty(value)) {
|
1539
|
+
_this._maskPhone$.next(PhoneUtil.mask(value));
|
1540
|
+
}
|
1350
1541
|
});
|
1351
1542
|
}
|
1352
1543
|
};
|
1353
|
-
InputComponent.prototype.ngAfterViewInit = function () { };
|
1354
1544
|
InputComponent.prototype.registerOnChange = function (fn) {
|
1355
1545
|
this.onChange = fn;
|
1356
1546
|
};
|
@@ -1358,8 +1548,16 @@
|
|
1358
1548
|
this.onTouch = fn;
|
1359
1549
|
};
|
1360
1550
|
InputComponent.prototype.writeValue = function (value) {
|
1551
|
+
if (this.phone && !StringUtil.isEmpty(value)) {
|
1552
|
+
this._inputSubject$.next(value);
|
1553
|
+
this._changeDetectorRef.detectChanges();
|
1554
|
+
}
|
1361
1555
|
this.value = value;
|
1362
1556
|
};
|
1557
|
+
InputComponent.prototype.setDisabledState = function (isDisabled) {
|
1558
|
+
this.disabled = isDisabled;
|
1559
|
+
this._changeDetectorRef.detectChanges();
|
1560
|
+
};
|
1363
1561
|
InputComponent.prototype.checkSpaceDrop = function (value) {
|
1364
1562
|
if (this.spaceDrop && value) {
|
1365
1563
|
return value.replace(/\s/g, '');
|
@@ -1389,23 +1587,27 @@
|
|
1389
1587
|
this.onTouch();
|
1390
1588
|
}
|
1391
1589
|
};
|
1392
|
-
InputComponent.prototype.
|
1590
|
+
InputComponent.prototype.onInputPhoneKeydown = function (event) {
|
1393
1591
|
if (!this.phone) {
|
1394
1592
|
return;
|
1395
1593
|
}
|
1396
1594
|
var value = PhoneUtil.removeCharacters(event.target.value);
|
1397
1595
|
var key = event.key;
|
1398
|
-
if (/\d/.test(key) && value.length < 12) {
|
1399
|
-
this._maskPhone
|
1596
|
+
if (/\d/.test(key) && ((value.trim().length < 8) || (value.trim().length > 12))) {
|
1597
|
+
this._maskPhone$.next('0*');
|
1400
1598
|
}
|
1401
1599
|
};
|
1402
1600
|
InputComponent.prototype.onInputPhoneChange = function (value) {
|
1403
1601
|
if (!this.phone) {
|
1404
1602
|
return;
|
1405
1603
|
}
|
1406
|
-
this._inputSubject
|
1604
|
+
this._inputSubject$.next(value);
|
1407
1605
|
};
|
1408
1606
|
var InputComponent_1;
|
1607
|
+
InputComponent.ctorParameters = function () { return [
|
1608
|
+
{ type: core.ElementRef },
|
1609
|
+
{ type: core.ChangeDetectorRef }
|
1610
|
+
]; };
|
1409
1611
|
__decorate([
|
1410
1612
|
core.ViewChild('input', { static: false, read: core.ElementRef }),
|
1411
1613
|
__metadata("design:type", core.ElementRef)
|
@@ -1475,9 +1677,10 @@
|
|
1475
1677
|
__metadata("design:type", String)
|
1476
1678
|
], InputComponent.prototype, "appearance", void 0);
|
1477
1679
|
__decorate([
|
1478
|
-
core.Input(
|
1479
|
-
__metadata("design:type", Object)
|
1480
|
-
|
1680
|
+
core.Input(),
|
1681
|
+
__metadata("design:type", Object),
|
1682
|
+
__metadata("design:paramtypes", [Object])
|
1683
|
+
], InputComponent.prototype, "value", null);
|
1481
1684
|
__decorate([
|
1482
1685
|
core.Input(),
|
1483
1686
|
__metadata("design:type", String)
|
@@ -1521,7 +1724,7 @@
|
|
1521
1724
|
InputComponent = InputComponent_1 = __decorate([
|
1522
1725
|
core.Component({
|
1523
1726
|
selector: 'itss-input',
|
1524
|
-
template: "<div fxLayout=\"column\">\n <mat-label *ngIf=\"label\">\n {{ label }}\n <span *ngIf=\"required && label\"> * </span>\n <gipi-helpful-tip *ngIf=\"tooltip && label\"\n [tooltip]=\"tooltip\">\n </gipi-helpful-tip>\n </mat-label>\n\n <ng-container *ngIf=\"hidePasswordManager && (type === 'password')\">\n <input style=\"opacity: 0;position: absolute;\">\n <input type=\"password\"\n style=\"opacity: 0;position: absolute;\">\n </ng-container>\n\n <mat-form-field [appearance]=\"appearance\"\n [class]=\"styleClassFormField\">\n <input matInput\n #input\n *ngIf=\"mask\"\n autocomplete=\"off\"\n upperCase\n lowerCase\n spaceDrop\n [enabledUpperCase]=\"upperCase\"\n [enabledLowerCase]=\"lowerCase\"\n [spaceDrop]=\"spaceDrop\"\n [name]=\"name\"\n [readonly]=\"readonly\"\n [placeholder]=\"placeholder\"\n [required]=\"required\"\n [disabled]=\"disabled\"\n [(ngModel)]=\"value\"\n [type]=\"type\"\n [min]=\"min\"\n [max]=\"max\"\n [maxlength]=\"maxlength\"\n [mask]=\"phone ? (_maskPhone | async) : mask\"\n [dropSpecialCharacters]=\"dropSpecialCharacters\"\n [patterns]=\"patterns\"\n (focus)=\"onFocus($event)\"\n (blur)=\"onBlur($event)\"\n (
|
1727
|
+
template: "<div fxLayout=\"column\">\n <mat-label *ngIf=\"label\">\n {{ label }}\n <span *ngIf=\"required && label\"> * </span>\n <gipi-helpful-tip *ngIf=\"tooltip && label\"\n [tooltip]=\"tooltip\">\n </gipi-helpful-tip>\n </mat-label>\n\n <ng-container *ngIf=\"hidePasswordManager && (type === 'password')\">\n <input style=\"opacity: 0;position: absolute;\">\n <input type=\"password\"\n style=\"opacity: 0;position: absolute;\">\n </ng-container>\n\n <mat-form-field [appearance]=\"appearance\"\n [class]=\"styleClassFormField\">\n <input matInput\n #input\n *ngIf=\"mask || phone\"\n autocomplete=\"off\"\n upperCase\n lowerCase\n spaceDrop\n [enabledUpperCase]=\"upperCase\"\n [enabledLowerCase]=\"lowerCase\"\n [spaceDrop]=\"spaceDrop\"\n [name]=\"name\"\n [readonly]=\"readonly\"\n [placeholder]=\"placeholder\"\n [required]=\"required\"\n [disabled]=\"disabled\"\n [(ngModel)]=\"value\"\n [type]=\"type\"\n [min]=\"min\"\n [max]=\"max\"\n [maxlength]=\"maxlength\"\n [mask]=\"phone ? (_maskPhone$ | async) : mask\"\n [dropSpecialCharacters]=\"dropSpecialCharacters\"\n [patterns]=\"patterns\"\n (focus)=\"onFocus($event)\"\n (blur)=\"onBlur($event)\"\n (keydown)=\"onInputPhoneKeydown($event)\"\n (ngModelChange)=\"onInputPhoneChange($event)\">\n\n <input matInput\n #input\n *ngIf=\"!mask && !phone\"\n [name]=\"name\"\n [readonly]=\"readonly\"\n [placeholder]=\"placeholder\"\n [required]=\"required\"\n [disabled]=\"disabled\"\n [(ngModel)]=\"value\"\n autocomplete=\"off\"\n upperCase\n [enabledUpperCase]=\"upperCase\"\n [type]=\"type\"\n [min]=\"min\"\n [max]=\"max\"\n [maxlength]=\"maxlength\"\n [mask]=\"''\"\n spaceDrop\n [spaceDrop]=\"spaceDrop\"\n (focus)=\"onFocus($event)\"\n (blur)=\"onBlur($event)\">\n\n <mat-spinner matPrefix\n *ngIf=\"loading\"\n mode=\"indeterminate\"\n diameter=\"17\">\n </mat-spinner>\n\n <div *ngIf=\"suffixRef\"\n matSuffix\n [class]=\"styleClassSuffix\">\n <ng-template [ngTemplateOutlet]=\"suffixRef\"> </ng-template>\n </div>\n </mat-form-field>\n</div>",
|
1525
1728
|
providers: [
|
1526
1729
|
{
|
1527
1730
|
provide: forms.NG_VALUE_ACCESSOR,
|
@@ -1531,7 +1734,8 @@
|
|
1531
1734
|
],
|
1532
1735
|
styles: ["mat-label span{color:#d14014!important}"]
|
1533
1736
|
}),
|
1534
|
-
__metadata("design:paramtypes", [
|
1737
|
+
__metadata("design:paramtypes", [core.ElementRef,
|
1738
|
+
core.ChangeDetectorRef])
|
1535
1739
|
], InputComponent);
|
1536
1740
|
return InputComponent;
|
1537
1741
|
}());
|
@@ -2931,198 +3135,8 @@
|
|
2931
3135
|
return RadioGroupEnumComponent;
|
2932
3136
|
}());
|
2933
3137
|
|
2934
|
-
var
|
2935
|
-
function
|
2936
|
-
this.cd = cd;
|
2937
|
-
this.tabindex = 0;
|
2938
|
-
this.onOptionClick = new core.EventEmitter();
|
2939
|
-
this.onChange = new core.EventEmitter();
|
2940
|
-
this.onModelChange = function () { };
|
2941
|
-
this.onModelTouched = function () { };
|
2942
|
-
}
|
2943
|
-
SelectButtonComponent_1 = SelectButtonComponent;
|
2944
|
-
SelectButtonComponent.prototype.ngOnInit = function () { };
|
2945
|
-
SelectButtonComponent.prototype.getPropertyLabel = function (option) {
|
2946
|
-
return this.property ? ObjectUtil.resolveFieldData(option, this.property) : (option.label !== undefined ? option.label : option);
|
2947
|
-
};
|
2948
|
-
SelectButtonComponent.prototype.getOptionValue = function (option) {
|
2949
|
-
return this.optionValue ? ObjectUtil.resolveFieldData(option, this.optionValue) : (this.property || option.value === undefined ? option : option.value);
|
2950
|
-
};
|
2951
|
-
SelectButtonComponent.prototype.isOptionDisabled = function (option) {
|
2952
|
-
return this.optionDisabled ? ObjectUtil.resolveFieldData(option, this.optionDisabled) : (option.disabled !== undefined ? option.disabled : false);
|
2953
|
-
};
|
2954
|
-
SelectButtonComponent.prototype.writeValue = function (value) {
|
2955
|
-
this.value = value;
|
2956
|
-
this.cd.markForCheck();
|
2957
|
-
};
|
2958
|
-
SelectButtonComponent.prototype.registerOnChange = function (fn) {
|
2959
|
-
this.onModelChange = fn;
|
2960
|
-
};
|
2961
|
-
SelectButtonComponent.prototype.registerOnTouched = function (fn) {
|
2962
|
-
this.onModelTouched = fn;
|
2963
|
-
};
|
2964
|
-
SelectButtonComponent.prototype.setDisabledState = function (val) {
|
2965
|
-
this.disabled = val;
|
2966
|
-
this.cd.markForCheck();
|
2967
|
-
};
|
2968
|
-
SelectButtonComponent.prototype.onItemClick = function (event, option, index) {
|
2969
|
-
if (this.disabled || this.isOptionDisabled(option)) {
|
2970
|
-
return;
|
2971
|
-
}
|
2972
|
-
if (this.multiple) {
|
2973
|
-
if (this.isSelected(option)) {
|
2974
|
-
this.removeOption(option);
|
2975
|
-
}
|
2976
|
-
else {
|
2977
|
-
this.value = __spread((this.value || []), [this.getOptionValue(option)]);
|
2978
|
-
}
|
2979
|
-
this.onModelChange(this.value);
|
2980
|
-
this.onChange.emit({
|
2981
|
-
originalEvent: event,
|
2982
|
-
value: this.value
|
2983
|
-
});
|
2984
|
-
}
|
2985
|
-
else {
|
2986
|
-
var value = this.getOptionValue(option);
|
2987
|
-
if (this.value !== value) {
|
2988
|
-
this.value = this.getOptionValue(option);
|
2989
|
-
this.onModelChange(this.value);
|
2990
|
-
this.onChange.emit({
|
2991
|
-
originalEvent: event,
|
2992
|
-
value: this.value
|
2993
|
-
});
|
2994
|
-
}
|
2995
|
-
}
|
2996
|
-
this.onOptionClick.emit({
|
2997
|
-
originalEvent: event,
|
2998
|
-
option: option,
|
2999
|
-
index: index
|
3000
|
-
});
|
3001
|
-
};
|
3002
|
-
SelectButtonComponent.prototype.onBlur = function () {
|
3003
|
-
this.onModelTouched();
|
3004
|
-
};
|
3005
|
-
SelectButtonComponent.prototype.removeOption = function (option) {
|
3006
|
-
var _this = this;
|
3007
|
-
this.value = this.value.filter(function (val) { return !ObjectUtil.equals(val, _this.getOptionValue(option), _this.dataKey); });
|
3008
|
-
};
|
3009
|
-
SelectButtonComponent.prototype.isSelected = function (option) {
|
3010
|
-
var e_1, _a;
|
3011
|
-
var selected = false;
|
3012
|
-
var optionValue = this.getOptionValue(option);
|
3013
|
-
if (this.multiple) {
|
3014
|
-
if (this.value) {
|
3015
|
-
try {
|
3016
|
-
for (var _b = __values(this.value), _c = _b.next(); !_c.done; _c = _b.next()) {
|
3017
|
-
var val = _c.value;
|
3018
|
-
if (ObjectUtil.equals(val, optionValue, this.dataKey)) {
|
3019
|
-
selected = true;
|
3020
|
-
break;
|
3021
|
-
}
|
3022
|
-
}
|
3023
|
-
}
|
3024
|
-
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
3025
|
-
finally {
|
3026
|
-
try {
|
3027
|
-
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
3028
|
-
}
|
3029
|
-
finally { if (e_1) throw e_1.error; }
|
3030
|
-
}
|
3031
|
-
}
|
3032
|
-
}
|
3033
|
-
else {
|
3034
|
-
selected = ObjectUtil.equals(this.getOptionValue(option), this.value, this.dataKey);
|
3035
|
-
}
|
3036
|
-
return selected;
|
3037
|
-
};
|
3038
|
-
var SelectButtonComponent_1;
|
3039
|
-
SelectButtonComponent.ctorParameters = function () { return [
|
3040
|
-
{ type: core.ChangeDetectorRef }
|
3041
|
-
]; };
|
3042
|
-
__decorate([
|
3043
|
-
core.Input(),
|
3044
|
-
__metadata("design:type", Array)
|
3045
|
-
], SelectButtonComponent.prototype, "options", void 0);
|
3046
|
-
__decorate([
|
3047
|
-
core.Input(),
|
3048
|
-
__metadata("design:type", String)
|
3049
|
-
], SelectButtonComponent.prototype, "property", void 0);
|
3050
|
-
__decorate([
|
3051
|
-
core.Input(),
|
3052
|
-
__metadata("design:type", String)
|
3053
|
-
], SelectButtonComponent.prototype, "optionValue", void 0);
|
3054
|
-
__decorate([
|
3055
|
-
core.Input(),
|
3056
|
-
__metadata("design:type", String)
|
3057
|
-
], SelectButtonComponent.prototype, "optionDisabled", void 0);
|
3058
|
-
__decorate([
|
3059
|
-
core.Input(),
|
3060
|
-
__metadata("design:type", Number)
|
3061
|
-
], SelectButtonComponent.prototype, "tabindex", void 0);
|
3062
|
-
__decorate([
|
3063
|
-
core.Input(),
|
3064
|
-
__metadata("design:type", Boolean)
|
3065
|
-
], SelectButtonComponent.prototype, "multiple", void 0);
|
3066
|
-
__decorate([
|
3067
|
-
core.Input(),
|
3068
|
-
__metadata("design:type", String)
|
3069
|
-
], SelectButtonComponent.prototype, "label", void 0);
|
3070
|
-
__decorate([
|
3071
|
-
core.Input(),
|
3072
|
-
__metadata("design:type", Boolean)
|
3073
|
-
], SelectButtonComponent.prototype, "required", void 0);
|
3074
|
-
__decorate([
|
3075
|
-
core.Input(),
|
3076
|
-
__metadata("design:type", String)
|
3077
|
-
], SelectButtonComponent.prototype, "styleClass", void 0);
|
3078
|
-
__decorate([
|
3079
|
-
core.Input(),
|
3080
|
-
__metadata("design:type", String)
|
3081
|
-
], SelectButtonComponent.prototype, "ariaLabelledBy", void 0);
|
3082
|
-
__decorate([
|
3083
|
-
core.Input(),
|
3084
|
-
__metadata("design:type", Boolean)
|
3085
|
-
], SelectButtonComponent.prototype, "disabled", void 0);
|
3086
|
-
__decorate([
|
3087
|
-
core.Input(),
|
3088
|
-
__metadata("design:type", String)
|
3089
|
-
], SelectButtonComponent.prototype, "dataKey", void 0);
|
3090
|
-
__decorate([
|
3091
|
-
core.Output(),
|
3092
|
-
__metadata("design:type", core.EventEmitter)
|
3093
|
-
], SelectButtonComponent.prototype, "onOptionClick", void 0);
|
3094
|
-
__decorate([
|
3095
|
-
core.Output(),
|
3096
|
-
__metadata("design:type", core.EventEmitter)
|
3097
|
-
], SelectButtonComponent.prototype, "onChange", void 0);
|
3098
|
-
__decorate([
|
3099
|
-
core.ContentChild(core.TemplateRef, { static: false }),
|
3100
|
-
__metadata("design:type", Object)
|
3101
|
-
], SelectButtonComponent.prototype, "itemTemplate", void 0);
|
3102
|
-
SelectButtonComponent = SelectButtonComponent_1 = __decorate([
|
3103
|
-
core.Component({
|
3104
|
-
selector: 'itss-select-button',
|
3105
|
-
template: "<div fxLayout=\"column\">\n <mat-label *ngIf=\"label\"\n class=\"label\">\n {{ label }}\n <span *ngIf=\"required && label\">*</span>\n </mat-label>\n\n <div [ngClass]=\"'selectbutton component'\"\n [class]=\"styleClass\"\n role=\"group\">\n <div *ngFor=\"let option of options; let i = index\"\n #btn\n class=\"button component\"\n [class]=\"option.styleClass\"\n role=\"button\"\n [attr.aria-pressed]=\"isSelected(option)\"\n [ngClass]=\"{'highlight': isSelected(option),\n 'disabled': disabled || isOptionDisabled(option),\n 'button-icon-only': (option.icon && !getPropertyLabel(option))}\"\n (click)=\"onItemClick($event,option,i)\"\n (keydown.enter)=\"onItemClick($event,option,i)\"\n [attr.title]=\"option.title\"\n [attr.aria-label]=\"option.label\"\n (blur)=\"onBlur()\"\n [attr.tabindex]=\"disabled ? null : tabindex\"\n [attr.aria-labelledby]=\"this.getPropertyLabel(option)\"\n [attr.id]=\"i\">\n\n <ng-container *ngIf=\"!itemTemplate else customcontent\">\n <span [ngClass]=\"'button-icon button-icon-left'\"\n [class]=\"option.icon\"\n *ngIf=\"option.icon\">\n </span>\n <span class=\"button-label\">\n {{ getPropertyLabel(option) }}\n </span>\n </ng-container>\n\n <ng-template #customcontent>\n <ng-container *ngTemplateOutlet=\"itemTemplate; context: {$implicit: option, index: i}\"></ng-container>\n </ng-template>\n\n </div>\n </div>\n</div>",
|
3106
|
-
providers: [
|
3107
|
-
{
|
3108
|
-
provide: forms.NG_VALUE_ACCESSOR,
|
3109
|
-
useExisting: core.forwardRef(function () { return SelectButtonComponent_1; }),
|
3110
|
-
multi: true
|
3111
|
-
}
|
3112
|
-
],
|
3113
|
-
changeDetection: core.ChangeDetectionStrategy.OnPush,
|
3114
|
-
host: {
|
3115
|
-
'class': 'itss-element'
|
3116
|
-
},
|
3117
|
-
styles: [".label{color:#696969;font-size:1rem;margin-bottom:7px!important}.label>span{color:#f44336}.component{font-weight:400;display:flex;width:100%}.component:disabled,.disabled{cursor:not-allowed!important;background:#e0e0e0!important;border-color:#e0e0e0!important;color:#00000042!important}.selectbutton .button{background:#fff;border:1px solid #e1e5e4;color:#696969;transition:background-color .2s,color .2s,border-color .2s,box-shadow .2s;padding:1rem;align-items:center;display:flex;justify-content:center;min-width:5rem;cursor:pointer}.selectbutton .button:first-of-type{border-top-left-radius:5px;border-bottom-left-radius:5px}.selectbutton .button:last-of-type{border-top-right-radius:5px;border-bottom-right-radius:5px}.selectbutton .button .button-icon-left,.selectbutton .button .button-icon-right{color:#696969}.selectbutton .button:not(.disabled):not(.highlight):hover{background:#f7f7f7;border-color:#e1e5e4;color:#696969}.selectbutton .button:not(.disabled):not(.highlight):hover .button-icon-left,.selectbutton .button:not(.disabled):not(.highlight):hover .button-icon-right{color:#696969}.selectbutton .button.highlight{background:#f3465c;border-color:#f3465c;color:#fff;cursor:default}.selectbutton .button.highlight .button-icon-left,.selectbutton .button.highlight .button-icon-right{color:#fff}.selectbutton .button.highlight:hover{background:#e6364e;border-color:#e6364e;color:#fff}.selectbutton .button.highlight:hover .button-icon-left,.selectbutton .button.highlight:hover .button-icon-right{color:#fff}itss-select-button.ng-dirty.ng-invalid>.selectbutton>.button{border-color:#f44336}.button.button-icon-only{width:3rem;padding:.75rem 0}.button.button-icon-only .button-icon-left,.button.button-icon-only .button-icon-right{margin:0}.button.button-icon-only.button-rounded{border-radius:50%;height:3rem}.button-label{font-weight:700}"]
|
3118
|
-
}),
|
3119
|
-
__metadata("design:paramtypes", [core.ChangeDetectorRef])
|
3120
|
-
], SelectButtonComponent);
|
3121
|
-
return SelectButtonComponent;
|
3122
|
-
}());
|
3123
|
-
|
3124
|
-
var SelectEntityPagedComponent = /** @class */ (function () {
|
3125
|
-
function SelectEntityPagedComponent(_changeDetectorRef) {
|
3138
|
+
var SelectEntityPagedComponent = /** @class */ (function () {
|
3139
|
+
function SelectEntityPagedComponent(_changeDetectorRef) {
|
3126
3140
|
var _this = this;
|
3127
3141
|
this._changeDetectorRef = _changeDetectorRef;
|
3128
3142
|
this.valueSearchCtrl = new forms.FormControl('');
|
@@ -4315,7 +4329,7 @@
|
|
4315
4329
|
SelectSearchComponent = SelectSearchComponent_1 = __decorate([
|
4316
4330
|
core.Component({
|
4317
4331
|
selector: 'itss-input-search',
|
4318
|
-
template: "<!-- Espa\u00E7o reservado para ajustar o deslocamento vertical dos elementos mat-option -->\n<input matInput\n class=\"mat-select-search-input mat-select-search-hidden\" />\n\n<!-- Note: o mat-datepicker-content mat-tab-header \u00E9 necess\u00E1rio para herdar as cores do tema do material, consulte PR n\u00BA 22 -->\n<div #innerSelectSearch\n class=\"mat-select-search-inner mat-typography mat-datepicker-content mat-tab-header\"\n [ngClass]=\"{'mat-select-search-inner-multiple': matSelect.multiple, 'mat-select-search-inner-toggle-all': _isToggleAllCheckboxVisible() }\">\n\n <mat-checkbox *ngIf=\"_isToggleAllCheckboxVisible()\"\n class=\"mat-select-search-toggle-all-checkbox\"\n color=\"primary\"\n [color]=\"matFormField?.color\"\n [disabled]=\"searching\"\n [matTooltip]=\"toggleAllCheckboxTooltipMessage\"\n matTooltipClass=\"ngx-mat-select-search-toggle-all-tooltip\"\n [matTooltipPosition]=\"toggleAllCheckboxTooltipPosition\"\n [(ngModel)]=\"toggleAllCheckboxChecked\"\n [(indeterminate)]=\"toggleAllCheckboxIndeterminate\">\n </mat-checkbox>\n\n <input class=\"mat-select-search-input mat-input-element\"\n autocomplete=\"off\"\n [type]=\"type\"\n [formControl]=\"_formControl\"\n #searchSelectInput\n (keydown)=\"_handleKeydown($event)\"\n (keyup)=\"_handleKeyup($event)\"\n (blur)=\"onBlur()\"\n [placeholder]=\"placeholderLabel\"\n [attr.aria-label]=\"ariaLabel\">\n\n <mat-spinner *ngIf=\"searching\"\n class=\"mat-select-search-spinner\"\n diameter=\"16\">\n </mat-spinner>\n\n <button *ngIf=\"!hideClearSearchButton && value && !searching\"\n mat-icon-button\n aria-label=\"Clear\"\n (click)=\"_reset(true)\"\n class=\"mat-select-search-clear\">\n <ng-content *ngIf=\"clearIcon; else defaultIcon\"\n select=\"[itssSelectSearchClear]\">\n </ng-content>\n\n <ng-template #defaultIcon>\n <mat-icon [svgIcon]=\"closeSvgIcon\">\n {{ !closeSvgIcon ? closeIcon : null }}\n </mat-icon>\n </ng-template>\n </button>\n\n <ng-content select=\".mat-select-search-custom-header-content\"> </ng-content>\n\n <mat-divider> </mat-divider>\n</div>\n\n<div *ngIf=\"(_showNoEntriesFound$ | async) && !searching\"\n class=\"mat-select-search-no-entries-found\">\n <ng-content *ngIf=\"noEntriesFound; else defaultNoEntriesFound\"\n select=\"[itssSelectNoEntriesFound]\">\n </ng-content>\n\n <ng-template #defaultNoEntriesFound>\n {{ noEntriesFoundLabel }}\n </ng-template>\n</div
|
4332
|
+
template: "<!-- Espa\u00E7o reservado para ajustar o deslocamento vertical dos elementos mat-option -->\n<input matInput\n class=\"mat-select-search-input mat-select-search-hidden\" />\n\n<!-- Note: o mat-datepicker-content mat-tab-header \u00E9 necess\u00E1rio para herdar as cores do tema do material, consulte PR n\u00BA 22 -->\n<div #innerSelectSearch\n class=\"mat-select-search-inner mat-typography mat-datepicker-content mat-tab-header\"\n [ngClass]=\"{'mat-select-search-inner-multiple': matSelect.multiple, 'mat-select-search-inner-toggle-all': _isToggleAllCheckboxVisible() }\">\n\n <mat-checkbox *ngIf=\"_isToggleAllCheckboxVisible()\"\n class=\"mat-select-search-toggle-all-checkbox\"\n color=\"primary\"\n [color]=\"matFormField?.color\"\n [disabled]=\"searching\"\n [matTooltip]=\"toggleAllCheckboxTooltipMessage\"\n matTooltipClass=\"ngx-mat-select-search-toggle-all-tooltip\"\n [matTooltipPosition]=\"toggleAllCheckboxTooltipPosition\"\n [(ngModel)]=\"toggleAllCheckboxChecked\"\n [(indeterminate)]=\"toggleAllCheckboxIndeterminate\">\n </mat-checkbox>\n\n <input class=\"mat-select-search-input mat-input-element\"\n autocomplete=\"off\"\n [type]=\"type\"\n [formControl]=\"_formControl\"\n #searchSelectInput\n (keydown)=\"_handleKeydown($event)\"\n (keyup)=\"_handleKeyup($event)\"\n (blur)=\"onBlur()\"\n [placeholder]=\"placeholderLabel\"\n [attr.aria-label]=\"ariaLabel\"\n aria-hidden=\"false\">\n\n <mat-spinner *ngIf=\"searching\"\n class=\"mat-select-search-spinner\"\n diameter=\"16\">\n </mat-spinner>\n\n <button *ngIf=\"!hideClearSearchButton && value && !searching\"\n mat-icon-button\n aria-label=\"Clear\"\n (click)=\"_reset(true)\"\n class=\"mat-select-search-clear\">\n <ng-content *ngIf=\"clearIcon; else defaultIcon\"\n select=\"[itssSelectSearchClear]\">\n </ng-content>\n\n <ng-template #defaultIcon>\n <mat-icon [svgIcon]=\"closeSvgIcon\">\n {{ !closeSvgIcon ? closeIcon : null }}\n </mat-icon>\n </ng-template>\n </button>\n\n <ng-content select=\".mat-select-search-custom-header-content\"> </ng-content>\n\n <mat-divider> </mat-divider>\n</div>\n\n<div *ngIf=\"(_showNoEntriesFound$ | async) && !searching\"\n class=\"mat-select-search-no-entries-found\">\n <ng-content *ngIf=\"noEntriesFound; else defaultNoEntriesFound\"\n select=\"[itssSelectNoEntriesFound]\">\n </ng-content>\n\n <ng-template #defaultNoEntriesFound>\n {{ noEntriesFoundLabel }}\n </ng-template>\n</div>",
|
4319
4333
|
providers: [
|
4320
4334
|
{
|
4321
4335
|
provide: forms.NG_VALUE_ACCESSOR,
|
@@ -4339,6 +4353,7 @@
|
|
4339
4353
|
return SelectSearchComponent;
|
4340
4354
|
}());
|
4341
4355
|
|
4356
|
+
var cloneDeep$1 = rfdc_();
|
4342
4357
|
/** @dynamic */
|
4343
4358
|
var ArrayUtil = /** @class */ (function () {
|
4344
4359
|
function ArrayUtil() {
|
@@ -4350,7 +4365,7 @@
|
|
4350
4365
|
if (ObjectUtil.isNull(value)) {
|
4351
4366
|
return new Array();
|
4352
4367
|
}
|
4353
|
-
return
|
4368
|
+
return cloneDeep$1(value);
|
4354
4369
|
};
|
4355
4370
|
/**
|
4356
4371
|
* Função para realizar ordenação de Array de objetos
|
@@ -5032,208 +5047,6 @@
|
|
5032
5047
|
return StepperComponent;
|
5033
5048
|
}(stepper.CdkStepper));
|
5034
5049
|
|
5035
|
-
var TabComponent = /** @class */ (function () {
|
5036
|
-
function TabComponent() {
|
5037
|
-
this.active = false;
|
5038
|
-
this.closeable = false;
|
5039
|
-
this.disabled = false;
|
5040
|
-
this.selectionChange = new core.EventEmitter();
|
5041
|
-
}
|
5042
|
-
TabComponent.prototype.ngOnInit = function () {
|
5043
|
-
};
|
5044
|
-
__decorate([
|
5045
|
-
core.Input(),
|
5046
|
-
__metadata("design:type", Number)
|
5047
|
-
], TabComponent.prototype, "index", void 0);
|
5048
|
-
__decorate([
|
5049
|
-
core.Input(),
|
5050
|
-
__metadata("design:type", String)
|
5051
|
-
], TabComponent.prototype, "label", void 0);
|
5052
|
-
__decorate([
|
5053
|
-
core.Input(),
|
5054
|
-
__metadata("design:type", Object)
|
5055
|
-
], TabComponent.prototype, "active", void 0);
|
5056
|
-
__decorate([
|
5057
|
-
core.Input(),
|
5058
|
-
__metadata("design:type", core.TemplateRef)
|
5059
|
-
], TabComponent.prototype, "template", void 0);
|
5060
|
-
__decorate([
|
5061
|
-
core.Input(),
|
5062
|
-
__metadata("design:type", Object)
|
5063
|
-
], TabComponent.prototype, "closeable", void 0);
|
5064
|
-
__decorate([
|
5065
|
-
core.Input(),
|
5066
|
-
__metadata("design:type", Object)
|
5067
|
-
], TabComponent.prototype, "disabled", void 0);
|
5068
|
-
__decorate([
|
5069
|
-
core.Input(),
|
5070
|
-
__metadata("design:type", Object)
|
5071
|
-
], TabComponent.prototype, "data", void 0);
|
5072
|
-
__decorate([
|
5073
|
-
core.Input(),
|
5074
|
-
__metadata("design:type", String)
|
5075
|
-
], TabComponent.prototype, "icon", void 0);
|
5076
|
-
__decorate([
|
5077
|
-
core.Output(),
|
5078
|
-
__metadata("design:type", Object)
|
5079
|
-
], TabComponent.prototype, "selectionChange", void 0);
|
5080
|
-
TabComponent = __decorate([
|
5081
|
-
core.Component({
|
5082
|
-
selector: 'itss-tab',
|
5083
|
-
template: "<div *ngIf=\"active\">\n <ng-content></ng-content>\n <ng-container *ngIf=\"template\"\n [ngTemplateOutlet]=\"template\"\n [ngTemplateOutletContext]=\"{$implicit: data}\">\n </ng-container>\n</div>\n",
|
5084
|
-
styles: [""]
|
5085
|
-
})
|
5086
|
-
], TabComponent);
|
5087
|
-
return TabComponent;
|
5088
|
-
}());
|
5089
|
-
|
5090
|
-
var DynamicTabDirective = /** @class */ (function () {
|
5091
|
-
function DynamicTabDirective(viewContainer) {
|
5092
|
-
this.viewContainer = viewContainer;
|
5093
|
-
}
|
5094
|
-
DynamicTabDirective.ctorParameters = function () { return [
|
5095
|
-
{ type: core.ViewContainerRef }
|
5096
|
-
]; };
|
5097
|
-
DynamicTabDirective = __decorate([
|
5098
|
-
core.Directive({
|
5099
|
-
selector: '[dynamicTab]'
|
5100
|
-
}),
|
5101
|
-
__metadata("design:paramtypes", [core.ViewContainerRef])
|
5102
|
-
], DynamicTabDirective);
|
5103
|
-
return DynamicTabDirective;
|
5104
|
-
}());
|
5105
|
-
|
5106
|
-
var TabDTO = /** @class */ (function (_super) {
|
5107
|
-
__extends(TabDTO, _super);
|
5108
|
-
function TabDTO() {
|
5109
|
-
var _this = _super !== null && _super.apply(this, arguments) || this;
|
5110
|
-
_this.active = false;
|
5111
|
-
_this.closeable = false;
|
5112
|
-
_this.disabled = false;
|
5113
|
-
return _this;
|
5114
|
-
}
|
5115
|
-
return TabDTO;
|
5116
|
-
}(AbstractDTO));
|
5117
|
-
|
5118
|
-
var TabGroupComponent = /** @class */ (function () {
|
5119
|
-
function TabGroupComponent(_componentFactoryResolver) {
|
5120
|
-
this._componentFactoryResolver = _componentFactoryResolver;
|
5121
|
-
this.dynamicTabs = [];
|
5122
|
-
}
|
5123
|
-
TabGroupComponent.prototype.ngOnInit = function () {
|
5124
|
-
};
|
5125
|
-
TabGroupComponent.prototype.ngAfterContentInit = function () {
|
5126
|
-
var activeTabs = this.tabs.filter(function (tab) { return tab.active; });
|
5127
|
-
if (activeTabs.length === 0 && this.tabs.length > 0) {
|
5128
|
-
this.selectTab(this.tabs.first);
|
5129
|
-
}
|
5130
|
-
};
|
5131
|
-
TabGroupComponent.prototype.openTab = function (label, template, data, closeable, disabled, action) {
|
5132
|
-
if (closeable === void 0) { closeable = false; }
|
5133
|
-
if (disabled === void 0) { disabled = false; }
|
5134
|
-
var tab = new TabDTO();
|
5135
|
-
tab.label = label;
|
5136
|
-
tab.template = template;
|
5137
|
-
tab.data = data;
|
5138
|
-
tab.closeable = closeable;
|
5139
|
-
tab.disabled = disabled;
|
5140
|
-
tab.action = action;
|
5141
|
-
this.openTabs(Array(tab));
|
5142
|
-
};
|
5143
|
-
TabGroupComponent.prototype.openTabs = function (tabs) {
|
5144
|
-
var _a;
|
5145
|
-
var _this = this;
|
5146
|
-
var tabsComponent = tabs.map(function (tab) { return _this.getTabComponent(tab.label, tab.template, tab.data, tab.closeable, tab.disabled, tab.action); });
|
5147
|
-
(_a = this.dynamicTabs).push.apply(_a, __spread(tabsComponent));
|
5148
|
-
this.selectTab(this.dynamicTabs[0]);
|
5149
|
-
};
|
5150
|
-
TabGroupComponent.prototype.getTabComponent = function (label, template, data, closeable, disabled, action) {
|
5151
|
-
if (closeable === void 0) { closeable = false; }
|
5152
|
-
if (disabled === void 0) { disabled = false; }
|
5153
|
-
var componentFactory = this._componentFactoryResolver.resolveComponentFactory(TabComponent);
|
5154
|
-
var componentRef = this.dynamicTabPlaceholder.viewContainer.createComponent(componentFactory);
|
5155
|
-
var instance = componentRef.instance;
|
5156
|
-
instance.label = label;
|
5157
|
-
instance.template = template;
|
5158
|
-
instance.data = data;
|
5159
|
-
instance.closeable = closeable;
|
5160
|
-
instance.disabled = disabled;
|
5161
|
-
instance.action = action;
|
5162
|
-
return componentRef.instance;
|
5163
|
-
};
|
5164
|
-
TabGroupComponent.prototype.selectTab = function (tab) {
|
5165
|
-
this.tabs.toArray().forEach(function (t) { return (t.active = false); });
|
5166
|
-
this.dynamicTabs.forEach(function (t) { return (t.active = false); });
|
5167
|
-
tab.active = true;
|
5168
|
-
tab.selectionChange.emit();
|
5169
|
-
if (tab.action) {
|
5170
|
-
tab.action(tab.data);
|
5171
|
-
}
|
5172
|
-
};
|
5173
|
-
TabGroupComponent.prototype.closeTab = function (tab) {
|
5174
|
-
var index = this.dynamicTabs.indexOf(tab);
|
5175
|
-
this.dynamicTabs.splice(index, 1);
|
5176
|
-
var viewContainerRef = this.dynamicTabPlaceholder.viewContainer;
|
5177
|
-
viewContainerRef.remove(index);
|
5178
|
-
if (this.tabs.length > 0) {
|
5179
|
-
this.selectTab(this.tabs.first);
|
5180
|
-
}
|
5181
|
-
};
|
5182
|
-
TabGroupComponent.prototype.closeActiveTab = function () {
|
5183
|
-
var activeTabs = this.dynamicTabs.filter(function (tab) { return tab.active; });
|
5184
|
-
if (activeTabs.length > 0) {
|
5185
|
-
this.closeTab(activeTabs[0]);
|
5186
|
-
}
|
5187
|
-
};
|
5188
|
-
TabGroupComponent.prototype.closeAllTabs = function () {
|
5189
|
-
var _this = this;
|
5190
|
-
var tabs = Object.assign([], this.dynamicTabs);
|
5191
|
-
if (tabs.length > 0) {
|
5192
|
-
tabs.forEach(function (tab) { return _this.closeTab(tab); });
|
5193
|
-
}
|
5194
|
-
};
|
5195
|
-
TabGroupComponent.prototype.nextTab = function () {
|
5196
|
-
var currentTab = this.tabs.toArray().find(function (tab) { return tab.active; });
|
5197
|
-
var nextTab = this.tabs.toArray()[this.tabs.toArray().indexOf(currentTab) + 1];
|
5198
|
-
if (nextTab != null) {
|
5199
|
-
this.tabs.toArray().forEach(function (t) { return (t.active = false); });
|
5200
|
-
this.dynamicTabs.forEach(function (t) { return (t.active = false); });
|
5201
|
-
nextTab.active = true;
|
5202
|
-
nextTab.selectionChange.emit();
|
5203
|
-
}
|
5204
|
-
};
|
5205
|
-
TabGroupComponent.prototype.previousTab = function () {
|
5206
|
-
var currentTab = this.tabs.toArray().find(function (tab) { return tab.active; });
|
5207
|
-
var previousTab = this.tabs.toArray()[this.tabs.toArray().indexOf(currentTab) - 1];
|
5208
|
-
if (previousTab != null) {
|
5209
|
-
this.tabs.toArray().forEach(function (t) { return (t.active = false); });
|
5210
|
-
this.dynamicTabs.forEach(function (t) { return (t.active = false); });
|
5211
|
-
previousTab.active = true;
|
5212
|
-
previousTab.selectionChange.emit();
|
5213
|
-
}
|
5214
|
-
};
|
5215
|
-
TabGroupComponent.ctorParameters = function () { return [
|
5216
|
-
{ type: core.ComponentFactoryResolver }
|
5217
|
-
]; };
|
5218
|
-
__decorate([
|
5219
|
-
core.ContentChildren(TabComponent),
|
5220
|
-
__metadata("design:type", core.QueryList)
|
5221
|
-
], TabGroupComponent.prototype, "tabs", void 0);
|
5222
|
-
__decorate([
|
5223
|
-
core.ViewChild(DynamicTabDirective, { static: false }),
|
5224
|
-
__metadata("design:type", DynamicTabDirective)
|
5225
|
-
], TabGroupComponent.prototype, "dynamicTabPlaceholder", void 0);
|
5226
|
-
TabGroupComponent = __decorate([
|
5227
|
-
core.Component({
|
5228
|
-
selector: 'itss-tab-group',
|
5229
|
-
template: "<nav mat-tab-nav-bar>\n <a mat-tab-link\n *ngFor=\"let tab of tabs\"\n (click)=\"selectTab(tab)\"\n [class.active]=\"tab.active\"\n [disabled]=\"tab.disabled\">\n <div mat-card-avatar\n *ngIf=\"tab.icon\">\n <mat-icon>{{ tab.icon }}</mat-icon>\n </div>\n\n {{ tab.label }}\n </a>\n\n <a mat-tab-link\n *ngFor=\"let tab of dynamicTabs\"\n (click)=\"selectTab(tab)\"\n [class.active]=\"tab.active\"\n [disabled]=\"tab.disabled\">\n <div mat-card-avatar\n *ngIf=\"tab.icon\">\n <mat-icon>{{ tab.icon }}</mat-icon>\n </div>\n\n {{ tab.label }}\n </a>\n</nav>\n\n<ng-content></ng-content>\n<ng-template dynamicTab\n #container></ng-template>\n",
|
5230
|
-
styles: [""]
|
5231
|
-
}),
|
5232
|
-
__metadata("design:paramtypes", [core.ComponentFactoryResolver])
|
5233
|
-
], TabGroupComponent);
|
5234
|
-
return TabGroupComponent;
|
5235
|
-
}());
|
5236
|
-
|
5237
5050
|
/**
|
5238
5051
|
* Throttle a function
|
5239
5052
|
*/
|
@@ -7067,7 +6880,7 @@
|
|
7067
6880
|
};
|
7068
6881
|
GIPIColDirective.prototype._setHostClassMap = function () {
|
7069
6882
|
var _a;
|
7070
|
-
var hostClassMap = __assign((_a = {}, _a['grid-col'] = true, _a["grid-col-" + this.GIPISpan] = ObjectUtil.
|
6883
|
+
var hostClassMap = __assign((_a = {}, _a['grid-col'] = true, _a["grid-col-" + this.GIPISpan] = !ObjectUtil.isNull(this.GIPISpan), _a["grid-col-order-" + this.GIPIOrder] = !ObjectUtil.isNull(this.GIPIOrder), _a["grid-col-offset-" + this.GIPIOffset] = !ObjectUtil.isNull(this.GIPIOffset), _a["grid-col-pull-" + this.GIPIPull] = !ObjectUtil.isNull(this.GIPIPull), _a["grid-col-push-" + this.GIPIPush] = !ObjectUtil.isNull(this.GIPIPush), _a), this._generateClass());
|
7071
6884
|
for (var i in this._classMap) {
|
7072
6885
|
if (this._classMap.hasOwnProperty(i)) {
|
7073
6886
|
this.renderer.removeClass(this.elementRef.nativeElement, i);
|
@@ -7100,7 +6913,7 @@
|
|
7100
6913
|
var listClassMap = {};
|
7101
6914
|
listOfSizeInputName.forEach(function (name) {
|
7102
6915
|
var sizeName = name.replace('GIPI', '').toLowerCase();
|
7103
|
-
if (ObjectUtil.
|
6916
|
+
if (!ObjectUtil.isNull(_this[name])) {
|
7104
6917
|
if (typeof _this[name] === 'number' || typeof _this[name] === 'string') {
|
7105
6918
|
listClassMap["grid-col-" + sizeName + "-" + _this[name]] = true;
|
7106
6919
|
}
|
@@ -7109,7 +6922,7 @@
|
|
7109
6922
|
var prefixArray = ['span', 'pull', 'push', 'offset', 'order'];
|
7110
6923
|
prefixArray.forEach(function (prefix) {
|
7111
6924
|
var prefixClass = prefix === 'span' ? '-' : "-" + prefix + "-";
|
7112
|
-
listClassMap["grid-col-" + sizeName + prefixClass + embedded_1[prefix]] = embedded_1 && ObjectUtil.
|
6925
|
+
listClassMap["grid-col-" + sizeName + prefixClass + embedded_1[prefix]] = embedded_1 && !ObjectUtil.isNull(embedded_1[prefix]);
|
7113
6926
|
});
|
7114
6927
|
}
|
7115
6928
|
}
|
@@ -7516,6 +7329,22 @@
|
|
7516
7329
|
return GIPIPaginationControlsDirective;
|
7517
7330
|
}());
|
7518
7331
|
|
7332
|
+
var GIPIDynamicTabDirective = /** @class */ (function () {
|
7333
|
+
function GIPIDynamicTabDirective(viewContainer) {
|
7334
|
+
this.viewContainer = viewContainer;
|
7335
|
+
}
|
7336
|
+
GIPIDynamicTabDirective.ctorParameters = function () { return [
|
7337
|
+
{ type: core.ViewContainerRef }
|
7338
|
+
]; };
|
7339
|
+
GIPIDynamicTabDirective = __decorate([
|
7340
|
+
core.Directive({
|
7341
|
+
selector: '[GIPIDynamicTab]'
|
7342
|
+
}),
|
7343
|
+
__metadata("design:paramtypes", [core.ViewContainerRef])
|
7344
|
+
], GIPIDynamicTabDirective);
|
7345
|
+
return GIPIDynamicTabDirective;
|
7346
|
+
}());
|
7347
|
+
|
7519
7348
|
var GIPITemplateDirective = /** @class */ (function () {
|
7520
7349
|
function GIPITemplateDirective(template) {
|
7521
7350
|
this.template = template;
|
@@ -7812,7 +7641,7 @@
|
|
7812
7641
|
core.Component({
|
7813
7642
|
selector: "gipi-abstract-form",
|
7814
7643
|
exportAs: 'gipiAbstractForm',
|
7815
|
-
template: "<div
|
7644
|
+
template: "<div class=\"form-content\"\n [class.form-dialog]=\"dialog\"\n [class.space-bottom]=\"!dialog\"\n [style.flex-direction]=\"flexDirection\"\n [style.align-items]=\"alignItems\"\n [style.justify-content]=\"justifyContent\"\n [style.gap]=\"getGap\"\n [style.padding]=\"getPadding\">\n <ng-content> </ng-content>\n</div>\n<div class=\"form-footer\"\n [style.margin-inline]=\"getPadding\"\n *ngIf=\"GIPIActionRowComponent\">\n <ng-content select=\"gipi-action-row\"> </ng-content>\n</div>",
|
7816
7645
|
providers: [
|
7817
7646
|
{
|
7818
7647
|
provide: forms.NG_VALUE_ACCESSOR,
|
@@ -8750,7 +8579,7 @@
|
|
8750
8579
|
var _this = this;
|
8751
8580
|
if (this._overlayRef) {
|
8752
8581
|
/** Only subscribe to backdrop if trigger event is click */
|
8753
|
-
if (this.triggerEvent
|
8582
|
+
if (this.triggerEvent !== 'hover' && this.backdropCloseOnClick) {
|
8754
8583
|
this._overlayRef.backdropClick()
|
8755
8584
|
.pipe(operators.takeUntil(this.popoverClosed), operators.takeUntil(this._onDestroy))
|
8756
8585
|
.subscribe(function () {
|
@@ -8834,8 +8663,8 @@
|
|
8834
8663
|
GIPIPopoverTrigger.prototype._getOverlayConfig = function () {
|
8835
8664
|
var overlayState = new overlay.OverlayConfig();
|
8836
8665
|
overlayState.positionStrategy = this._getPosition();
|
8837
|
-
/** Display overlay backdrop if trigger event is
|
8838
|
-
if (this.triggerEvent
|
8666
|
+
/** Display overlay backdrop if trigger event is different of hover */
|
8667
|
+
if (this.triggerEvent !== 'hover') {
|
8839
8668
|
overlayState.hasBackdrop = true;
|
8840
8669
|
overlayState.backdropClass = 'cdk-overlay-transparent-backdrop';
|
8841
8670
|
}
|
@@ -9124,6 +8953,26 @@
|
|
9124
8953
|
this.onBlur = new core.EventEmitter(true);
|
9125
8954
|
}
|
9126
8955
|
GIPIButtonComponent_1 = GIPIButtonComponent;
|
8956
|
+
Object.defineProperty(GIPIButtonComponent.prototype, "internalButtonClass", {
|
8957
|
+
get: function () {
|
8958
|
+
return {
|
8959
|
+
'button-base': true,
|
8960
|
+
'button-primary': (this.isButtonPrimary || this.isButtonPrimaryIcon),
|
8961
|
+
'button-primary-icon': this.isButtonPrimaryIcon,
|
8962
|
+
'button-secondary': (this.isButtonSecondary || this.isButtonSecondaryIcon),
|
8963
|
+
'button-secondary-icon': this.isButtonSecondaryIcon,
|
8964
|
+
'button-tertiary': (this.isButtonTertiary || this.isButtonTertiaryIcon),
|
8965
|
+
'button-tertiary-icon': this.isButtonTertiaryIcon,
|
8966
|
+
'button-link': this.isButtonLink,
|
8967
|
+
'button-only-icon': this.isButtonIcon,
|
8968
|
+
'button-for-input': this.isForInput,
|
8969
|
+
'button-notification': this.notification,
|
8970
|
+
'button-action': this.isButtonAction
|
8971
|
+
};
|
8972
|
+
},
|
8973
|
+
enumerable: false,
|
8974
|
+
configurable: true
|
8975
|
+
});
|
9127
8976
|
GIPIButtonComponent.prototype.ngOnInit = function () { };
|
9128
8977
|
GIPIButtonComponent.prototype.ngOnDestroy = function () {
|
9129
8978
|
if (this.popoverTrigger) {
|
@@ -9323,7 +9172,7 @@
|
|
9323
9172
|
core.Component({
|
9324
9173
|
selector: "gipi-button[gipi-primary], gipi-button[gipi-primary-icon], gipi-button[gipi-secondary], gipi-button[gipi-secondary-icon],\n gipi-button[gipi-tertiary], gipi-button[gipi-link], gipi-button[gipi-icon], gipi-button[gipi-action]",
|
9325
9174
|
exportAs: 'gipiButton',
|
9326
|
-
template: "<button [attr.id]=\"id\"\n [attr.name]=\"name\"\n [attr.type]=\"type\"\n [attr.aria-label]=\"ariaLabel ? ariaLabel : label\"\n [attr.title]=\"title ? title : label\"\n [disabled]=\"disabled || loading\"\n [matTooltip]=\"tooltip\"\n role=\"button\"\n [class]=\"buttonClass\"\n [ngClass]=\"
|
9175
|
+
template: "<button [attr.id]=\"id\"\n [attr.name]=\"name\"\n [attr.type]=\"type\"\n [attr.aria-label]=\"ariaLabel ? ariaLabel : label\"\n [attr.title]=\"title ? title : label\"\n [disabled]=\"disabled || loading\"\n [matTooltip]=\"tooltip\"\n role=\"button\"\n [class]=\"buttonClass\"\n [ngClass]=\"internalButtonClass\"\n [style.padding.px]=\"buttonPadding\"\n #popoverTrigger=\"popoverTrigger\"\n [popoverTriggerFor]=\"btnPopover\"\n [popoverTriggerOn]=\"popover ? 'click' : 'none'\"\n [popoverBackdropCloseOnClick]=\"true\"\n (opened)=\"onOpenPopover.emit()\"\n (closed)=\"onClosePopover.emit()\"\n (click)=\"handleClick($event)\"\n (focus)=\"handleFocus($event)\"\n (blur)=\"handleBlur($event)\">\n <span [ngClass]=\"{'button-content': true,\n 'button-disabled': disabled,\n 'button-icon-left': ((iconPos === 'left') && label),\n 'button-icon-right': ((iconPos === 'right') && label),\n 'button-icon-top': ((iconPos === 'top') && label),\n 'button-icon-bottom': ((iconPos === 'bottom') && label),\n 'button-icon-center': (iconPos === 'center')}\">\n <mat-icon *ngIf=\"svgIcon || icon\"\n [svgIcon]=\"svgIcon\"\n [style.width.px]=\"iconWidth\"\n [style.height.px]=\"iconHeight\"\n [style.font-size.px]=\"iconWidth || iconHeight\">\n {{ (!svgIcon && icon) ? icon : '' }}\n </mat-icon>\n\n <span class=\"button-label\"\n [attr.aria-hidden]=\"(icon || svgIcon) && !label\"\n *ngIf=\"!isButtonIcon && label\">\n {{ label }}\n </span>\n </span>\n</button>\n\n<gipi-overlay *ngIf=\"overlay && !popover\"\n [(visible)]=\"_overlayVisible\"\n [appendTo]=\"'body'\"\n (onShow)=\"onShowOverlay.emit()\">\n <ng-content> </ng-content>\n</gipi-overlay>\n\n<gipi-popover #btnPopover=\"gipiPopover\"\n [popoverOverlapTrigger]=\"false\"\n [popoverCloseOnClick]=\"false\"\n [popoverArrowWidth]=\"0\"\n [popoverOffsetY]=\"3\"\n [fxHide]=\"!popover\">\n <div class=\"btn-popover-content\">\n <ng-content> </ng-content>\n </div>\n</gipi-popover>",
|
9327
9176
|
providers: [
|
9328
9177
|
{
|
9329
9178
|
provide: forms.NG_VALUE_ACCESSOR,
|
@@ -9341,21 +9190,152 @@
|
|
9341
9190
|
return GIPIButtonComponent;
|
9342
9191
|
}());
|
9343
9192
|
|
9344
|
-
var RemoveChange = /** @class */ (function () {
|
9345
|
-
function RemoveChange() {
|
9346
|
-
}
|
9347
|
-
return RemoveChange;
|
9348
|
-
}());
|
9349
9193
|
var nextUniqueId = 0;
|
9350
|
-
var
|
9351
|
-
function
|
9352
|
-
this._changeDetectorRef = _changeDetectorRef;
|
9194
|
+
var GIPICardComponent = /** @class */ (function () {
|
9195
|
+
function GIPICardComponent(elementRef, _changeDetectorRef) {
|
9353
9196
|
this.elementRef = elementRef;
|
9354
|
-
this.
|
9355
|
-
this.
|
9356
|
-
this.
|
9357
|
-
this.
|
9358
|
-
this.
|
9197
|
+
this._changeDetectorRef = _changeDetectorRef;
|
9198
|
+
this._uniqueId = "gipi-card-" + ++nextUniqueId;
|
9199
|
+
this._id = '';
|
9200
|
+
this._name = '';
|
9201
|
+
this._loading = false;
|
9202
|
+
this._shadow = true;
|
9203
|
+
this._padding = true;
|
9204
|
+
}
|
9205
|
+
GIPICardComponent_1 = GIPICardComponent;
|
9206
|
+
Object.defineProperty(GIPICardComponent.prototype, "id", {
|
9207
|
+
get: function () {
|
9208
|
+
return this._id;
|
9209
|
+
},
|
9210
|
+
set: function (value) {
|
9211
|
+
this._id = value || this._uniqueId;
|
9212
|
+
},
|
9213
|
+
enumerable: false,
|
9214
|
+
configurable: true
|
9215
|
+
});
|
9216
|
+
Object.defineProperty(GIPICardComponent.prototype, "name", {
|
9217
|
+
get: function () {
|
9218
|
+
return this._name;
|
9219
|
+
},
|
9220
|
+
set: function (value) {
|
9221
|
+
this._name = value || this._uniqueId;
|
9222
|
+
},
|
9223
|
+
enumerable: false,
|
9224
|
+
configurable: true
|
9225
|
+
});
|
9226
|
+
Object.defineProperty(GIPICardComponent.prototype, "loading", {
|
9227
|
+
get: function () {
|
9228
|
+
return this._loading;
|
9229
|
+
},
|
9230
|
+
set: function (value) {
|
9231
|
+
if (value !== this.loading) {
|
9232
|
+
this._loading = value;
|
9233
|
+
this._changeDetectorRef.markForCheck();
|
9234
|
+
}
|
9235
|
+
},
|
9236
|
+
enumerable: false,
|
9237
|
+
configurable: true
|
9238
|
+
});
|
9239
|
+
Object.defineProperty(GIPICardComponent.prototype, "shadow", {
|
9240
|
+
get: function () {
|
9241
|
+
return this._shadow;
|
9242
|
+
},
|
9243
|
+
set: function (value) {
|
9244
|
+
if (value !== this.shadow) {
|
9245
|
+
this._shadow = value;
|
9246
|
+
this._changeDetectorRef.markForCheck();
|
9247
|
+
}
|
9248
|
+
},
|
9249
|
+
enumerable: false,
|
9250
|
+
configurable: true
|
9251
|
+
});
|
9252
|
+
Object.defineProperty(GIPICardComponent.prototype, "padding", {
|
9253
|
+
get: function () {
|
9254
|
+
return this._padding;
|
9255
|
+
},
|
9256
|
+
set: function (value) {
|
9257
|
+
if (value !== this.padding) {
|
9258
|
+
this._padding = value;
|
9259
|
+
this._changeDetectorRef.markForCheck();
|
9260
|
+
}
|
9261
|
+
},
|
9262
|
+
enumerable: false,
|
9263
|
+
configurable: true
|
9264
|
+
});
|
9265
|
+
GIPICardComponent.prototype.ngOnInit = function () { };
|
9266
|
+
var GIPICardComponent_1;
|
9267
|
+
GIPICardComponent.ctorParameters = function () { return [
|
9268
|
+
{ type: core.ElementRef },
|
9269
|
+
{ type: core.ChangeDetectorRef }
|
9270
|
+
]; };
|
9271
|
+
__decorate([
|
9272
|
+
core.Input(),
|
9273
|
+
__metadata("design:type", String),
|
9274
|
+
__metadata("design:paramtypes", [String])
|
9275
|
+
], GIPICardComponent.prototype, "id", null);
|
9276
|
+
__decorate([
|
9277
|
+
core.Input(),
|
9278
|
+
__metadata("design:type", String),
|
9279
|
+
__metadata("design:paramtypes", [String])
|
9280
|
+
], GIPICardComponent.prototype, "name", null);
|
9281
|
+
__decorate([
|
9282
|
+
core.Input(),
|
9283
|
+
__metadata("design:type", Boolean),
|
9284
|
+
__metadata("design:paramtypes", [Boolean])
|
9285
|
+
], GIPICardComponent.prototype, "loading", null);
|
9286
|
+
__decorate([
|
9287
|
+
core.Input(),
|
9288
|
+
__metadata("design:type", Boolean),
|
9289
|
+
__metadata("design:paramtypes", [Boolean])
|
9290
|
+
], GIPICardComponent.prototype, "shadow", null);
|
9291
|
+
__decorate([
|
9292
|
+
core.Input(),
|
9293
|
+
__metadata("design:type", Boolean),
|
9294
|
+
__metadata("design:paramtypes", [Boolean])
|
9295
|
+
], GIPICardComponent.prototype, "padding", null);
|
9296
|
+
GIPICardComponent = GIPICardComponent_1 = __decorate([
|
9297
|
+
core.Component({
|
9298
|
+
selector: 'gipi-card',
|
9299
|
+
exportAs: 'gipiCard',
|
9300
|
+
template: "<ng-content></ng-content>",
|
9301
|
+
providers: [
|
9302
|
+
{
|
9303
|
+
provide: forms.NG_VALUE_ACCESSOR,
|
9304
|
+
useExisting: core.forwardRef(function () { return GIPICardComponent_1; }),
|
9305
|
+
multi: true
|
9306
|
+
}
|
9307
|
+
],
|
9308
|
+
host: {
|
9309
|
+
'class': 'gipi-card',
|
9310
|
+
'[attr.id]': 'id',
|
9311
|
+
'[attr.name]': 'name',
|
9312
|
+
'[class.shadow-none]': '!shadow',
|
9313
|
+
'[class.padding-none]': '!padding',
|
9314
|
+
'[class.loading]': 'loading',
|
9315
|
+
},
|
9316
|
+
styles: [":host{display:block;flex:1;border-radius:.2rem;box-shadow:0 3px 1px -2px rgba(0,0,0,.14),0 2px 2px 0 rgba(0,0,0,.098),0 1px 5px 0 rgba(0,0,0,.084);padding:1.6rem}.padding-none{padding:0!important}.shadow-none{box-shadow:none!important}"]
|
9317
|
+
}),
|
9318
|
+
__metadata("design:paramtypes", [core.ElementRef,
|
9319
|
+
core.ChangeDetectorRef])
|
9320
|
+
], GIPICardComponent);
|
9321
|
+
return GIPICardComponent;
|
9322
|
+
}());
|
9323
|
+
|
9324
|
+
var RemoveChange = /** @class */ (function () {
|
9325
|
+
function RemoveChange() {
|
9326
|
+
}
|
9327
|
+
return RemoveChange;
|
9328
|
+
}());
|
9329
|
+
var nextUniqueId$1 = 0;
|
9330
|
+
var GIPIChipsComponent = /** @class */ (function () {
|
9331
|
+
function GIPIChipsComponent(_changeDetectorRef, elementRef) {
|
9332
|
+
this._changeDetectorRef = _changeDetectorRef;
|
9333
|
+
this.elementRef = elementRef;
|
9334
|
+
this._name = "gipi-chips-" + nextUniqueId$1++;
|
9335
|
+
this.id = this._name;
|
9336
|
+
this.name = this._name;
|
9337
|
+
this.label = 'Selecionados';
|
9338
|
+
this.labelRemoveAll = 'Limpar';
|
9359
9339
|
this.disabled = false;
|
9360
9340
|
this.showRemovableAll = false;
|
9361
9341
|
this.showRemovable = false;
|
@@ -9544,12 +9524,12 @@
|
|
9544
9524
|
return GIPIConfirmationDialogComponent;
|
9545
9525
|
}());
|
9546
9526
|
|
9547
|
-
var nextUniqueId$
|
9527
|
+
var nextUniqueId$2 = 0;
|
9548
9528
|
var GIPIDropdownMenuComponent = /** @class */ (function () {
|
9549
9529
|
function GIPIDropdownMenuComponent(_changeDetectorRef, elementRef) {
|
9550
9530
|
this._changeDetectorRef = _changeDetectorRef;
|
9551
9531
|
this.elementRef = elementRef;
|
9552
|
-
this._name = "gipi-dropdown-menu-" + nextUniqueId$
|
9532
|
+
this._name = "gipi-dropdown-menu-" + nextUniqueId$2++;
|
9553
9533
|
this.id = this._name;
|
9554
9534
|
this.name = this._name;
|
9555
9535
|
this.label = '';
|
@@ -9730,6 +9710,35 @@
|
|
9730
9710
|
return GIPIDropdownMenuComponent;
|
9731
9711
|
}());
|
9732
9712
|
|
9713
|
+
var GIPIEmptyStateComponent = /** @class */ (function () {
|
9714
|
+
function GIPIEmptyStateComponent() {
|
9715
|
+
}
|
9716
|
+
GIPIEmptyStateComponent_1 = GIPIEmptyStateComponent;
|
9717
|
+
GIPIEmptyStateComponent.prototype.ngOnInit = function () { };
|
9718
|
+
var GIPIEmptyStateComponent_1;
|
9719
|
+
GIPIEmptyStateComponent = GIPIEmptyStateComponent_1 = __decorate([
|
9720
|
+
core.Component({
|
9721
|
+
selector: 'gipi-empty-state',
|
9722
|
+
exportAs: 'gipiEmptyState',
|
9723
|
+
template: "<mat-icon>sentiment_very_dissatisfied</mat-icon>\nNenhum registro foi encontrado",
|
9724
|
+
providers: [
|
9725
|
+
{
|
9726
|
+
provide: forms.NG_VALUE_ACCESSOR,
|
9727
|
+
useExisting: core.forwardRef(function () { return GIPIEmptyStateComponent_1; }),
|
9728
|
+
multi: true
|
9729
|
+
}
|
9730
|
+
],
|
9731
|
+
host: {
|
9732
|
+
'class': 'gipi-empty-state',
|
9733
|
+
},
|
9734
|
+
changeDetection: core.ChangeDetectionStrategy.OnPush,
|
9735
|
+
styles: [":host{display:flex;align-items:center;justify-content:center;flex-direction:column;font-size:1.4rem;font-weight:600;color:#131313;padding:2.4rem 0}:host>mat-icon{font-size:3.2rem;height:3.2rem;width:3.2rem;margin-bottom:5px}"]
|
9736
|
+
}),
|
9737
|
+
__metadata("design:paramtypes", [])
|
9738
|
+
], GIPIEmptyStateComponent);
|
9739
|
+
return GIPIEmptyStateComponent;
|
9740
|
+
}());
|
9741
|
+
|
9733
9742
|
var GIPIExpansionPanelComponent = /** @class */ (function () {
|
9734
9743
|
function GIPIExpansionPanelComponent(elementRef, _changeDetectorRef) {
|
9735
9744
|
this.elementRef = elementRef;
|
@@ -10141,12 +10150,12 @@
|
|
10141
10150
|
return GIPIFooterComponent;
|
10142
10151
|
}());
|
10143
10152
|
|
10144
|
-
var nextUniqueId$
|
10153
|
+
var nextUniqueId$3 = 0;
|
10145
10154
|
var GIPIFormFieldComponent = /** @class */ (function () {
|
10146
10155
|
function GIPIFormFieldComponent(_changeDetectorRef, elementRef) {
|
10147
10156
|
this._changeDetectorRef = _changeDetectorRef;
|
10148
10157
|
this.elementRef = elementRef;
|
10149
|
-
this._name = "gipi-form-field-" + nextUniqueId$
|
10158
|
+
this._name = "gipi-form-field-" + nextUniqueId$3++;
|
10150
10159
|
this.id = this._name;
|
10151
10160
|
this.name = this._name;
|
10152
10161
|
this.label = '';
|
@@ -10412,12 +10421,12 @@
|
|
10412
10421
|
return GIPIFormFieldComponent;
|
10413
10422
|
}());
|
10414
10423
|
|
10415
|
-
var nextUniqueId$
|
10424
|
+
var nextUniqueId$4 = 0;
|
10416
10425
|
var GIPIHelpfulTipComponent = /** @class */ (function () {
|
10417
10426
|
function GIPIHelpfulTipComponent(_changeDetectorRef, elementRef) {
|
10418
10427
|
this._changeDetectorRef = _changeDetectorRef;
|
10419
10428
|
this.elementRef = elementRef;
|
10420
|
-
this._name = "gipi-form-field-" + nextUniqueId$
|
10429
|
+
this._name = "gipi-form-field-" + nextUniqueId$4++;
|
10421
10430
|
this.id = this._name;
|
10422
10431
|
this.name = this._name;
|
10423
10432
|
this._tooltip = '';
|
@@ -10476,11 +10485,11 @@
|
|
10476
10485
|
return GIPIHelpfulTipComponent;
|
10477
10486
|
}());
|
10478
10487
|
|
10479
|
-
var nextUniqueId$
|
10488
|
+
var nextUniqueId$5 = 0;
|
10480
10489
|
var GIPIInputCheckboxComponent = /** @class */ (function () {
|
10481
10490
|
function GIPIInputCheckboxComponent(_changeDetectorRef) {
|
10482
10491
|
this._changeDetectorRef = _changeDetectorRef;
|
10483
|
-
this._name = "gipi-input-checkbox-" + nextUniqueId$
|
10492
|
+
this._name = "gipi-input-checkbox-" + nextUniqueId$5++;
|
10484
10493
|
this.id = this._name;
|
10485
10494
|
this.name = this._name;
|
10486
10495
|
this.disabled = false;
|
@@ -10590,12 +10599,12 @@
|
|
10590
10599
|
return GIPIInputCheckboxComponent;
|
10591
10600
|
}());
|
10592
10601
|
|
10593
|
-
var nextUniqueId$
|
10602
|
+
var nextUniqueId$6 = 0;
|
10594
10603
|
var GIPIInputCurrencyComponent = /** @class */ (function () {
|
10595
10604
|
function GIPIInputCurrencyComponent(_changeDetectorRef, elementRef) {
|
10596
10605
|
this._changeDetectorRef = _changeDetectorRef;
|
10597
10606
|
this.elementRef = elementRef;
|
10598
|
-
this._name = "gipi-input-currency-" + nextUniqueId$
|
10607
|
+
this._name = "gipi-input-currency-" + nextUniqueId$6++;
|
10599
10608
|
this.id = this._name;
|
10600
10609
|
this.name = this._name;
|
10601
10610
|
this.placeholder = '';
|
@@ -10793,12 +10802,12 @@
|
|
10793
10802
|
}());
|
10794
10803
|
|
10795
10804
|
var yearsPerPage = 24;
|
10796
|
-
var nextUniqueId$
|
10805
|
+
var nextUniqueId$7 = 0;
|
10797
10806
|
var GIPIInputMonthPickerComponent = /** @class */ (function () {
|
10798
10807
|
function GIPIInputMonthPickerComponent(_changeDetectorRef, _config) {
|
10799
10808
|
this._changeDetectorRef = _changeDetectorRef;
|
10800
10809
|
this._config = _config;
|
10801
|
-
this._name = "gipi-input-monthpicker-" + nextUniqueId$
|
10810
|
+
this._name = "gipi-input-monthpicker-" + nextUniqueId$7++;
|
10802
10811
|
this._yearArrays = [];
|
10803
10812
|
this._now = new Date();
|
10804
10813
|
this._currentMonth = this._now.getMonth();
|
@@ -11212,14 +11221,14 @@
|
|
11212
11221
|
return GIPIInputMonthPickerComponent;
|
11213
11222
|
}());
|
11214
11223
|
|
11215
|
-
var nextUniqueId$
|
11224
|
+
var nextUniqueId$8 = 0;
|
11216
11225
|
/** A altura dos itens selecionados em unidades `px`. */
|
11217
11226
|
var OPTION_HEIGHT_PX = 40;
|
11218
11227
|
var GIPIInputSelectEnumComponent = /** @class */ (function () {
|
11219
11228
|
function GIPIInputSelectEnumComponent(elementRef, _changeDetectorRef) {
|
11220
11229
|
this.elementRef = elementRef;
|
11221
11230
|
this._changeDetectorRef = _changeDetectorRef;
|
11222
|
-
this._name = "gipi-input-select-enum-" + nextUniqueId$
|
11231
|
+
this._name = "gipi-input-select-enum-" + nextUniqueId$8++;
|
11223
11232
|
this._enumList = [];
|
11224
11233
|
this._itemSizeScrollViewport = 5;
|
11225
11234
|
this._lastOptionSelected = null;
|
@@ -12241,12 +12250,12 @@
|
|
12241
12250
|
|
12242
12251
|
/** A altura dos itens selecionados em unidades `px`. */
|
12243
12252
|
var OPTION_HEIGHT_PX$1 = 44;
|
12244
|
-
var nextUniqueId$
|
12253
|
+
var nextUniqueId$9 = 0;
|
12245
12254
|
var GIPIInputSelectComponent = /** @class */ (function () {
|
12246
12255
|
function GIPIInputSelectComponent(_changeDetectorRef) {
|
12247
12256
|
var _this = this;
|
12248
12257
|
this._changeDetectorRef = _changeDetectorRef;
|
12249
|
-
this._name = "gipi-input-select-" + nextUniqueId$
|
12258
|
+
this._name = "gipi-input-select-" + nextUniqueId$9++;
|
12250
12259
|
this._onDestroy = new rxjs.Subject();
|
12251
12260
|
this._itemSizeScrollViewport = 5;
|
12252
12261
|
this._overlayVisible = false;
|
@@ -12933,14 +12942,14 @@
|
|
12933
12942
|
return GIPIInputSelectComponent;
|
12934
12943
|
}());
|
12935
12944
|
|
12936
|
-
var nextUniqueId$
|
12945
|
+
var nextUniqueId$a = 0;
|
12937
12946
|
var GIPIInputSelectListboxComponent = /** @class */ (function () {
|
12938
12947
|
function GIPIInputSelectListboxComponent(_changeDetectorRef, _elementRef, _renderer) {
|
12939
12948
|
var _this = this;
|
12940
12949
|
this._changeDetectorRef = _changeDetectorRef;
|
12941
12950
|
this._elementRef = _elementRef;
|
12942
12951
|
this._renderer = _renderer;
|
12943
|
-
this._name = "gipi-input-select-listbox-" + nextUniqueId$
|
12952
|
+
this._name = "gipi-input-select-listbox-" + nextUniqueId$a++;
|
12944
12953
|
this._isOverlayChildrenClicked = false;
|
12945
12954
|
this._overlayVisible = false;
|
12946
12955
|
this._selectEntityOpened = false;
|
@@ -13722,7 +13731,7 @@
|
|
13722
13731
|
core.Component({
|
13723
13732
|
selector: "gipi-input-search",
|
13724
13733
|
exportAs: 'gipiInputSearch',
|
13725
|
-
template: "<!-- Espa\u00E7o reservado para ajustar o deslocamento vertical dos elementos mat-option -->\n<input matInput\n class=\"mat-select-search-input mat-select-search-hidden\" />\n\n<!-- Note: o mat-datepicker-content mat-tab-header \u00E9 necess\u00E1rio para herdar as cores do tema do material, consulte PR n\u00BA 22 -->\n<div #innerSelectSearch\n class=\"mat-select-search-inner mat-typography mat-datepicker-content mat-tab-header\">\n\n <input class=\"mat-select-search-input mat-input-element\"\n aria-label=\"Pesquisa suspensa\"\n autocomplete=\"off\"\n type=\"text\"\n #searchSelectInput\n [placeholder]=\"placeholderLabel\"\n [formControl]=\"_formControl\"\n (keydown)=\"_handleKeydown($event)\"\n (keyup)=\"_handleKeyup($event)\"\n (blur)=\"onBlur()\">\n\n <mat-spinner *ngIf=\"searching\"\n class=\"mat-select-search-spinner\"\n diameter=\"16\">\n </mat-spinner>\n\n <button *ngIf=\"!hideClearSearchButton && value && !searching\"\n class=\"mat-select-search-clear\"\n aria-label=\"Limpar\"\n mat-icon-button\n (click)=\"_reset(true)\">\n <mat-icon> close </mat-icon>\n </button>\n\n <mat-divider> </mat-divider>\n</div>\n\n<div *ngIf=\"(_showNoEntriesFound$ | async) && !searching\"\n class=\"mat-select-search-no-entries-found\">\n <mat-icon>sentiment_very_dissatisfied</mat-icon>\n Nenhum registro foi encontrado\n</div>",
|
13734
|
+
template: "<!-- Espa\u00E7o reservado para ajustar o deslocamento vertical dos elementos mat-option -->\n<input matInput\n class=\"mat-select-search-input mat-select-search-hidden\" />\n\n<!-- Note: o mat-datepicker-content mat-tab-header \u00E9 necess\u00E1rio para herdar as cores do tema do material, consulte PR n\u00BA 22 -->\n<div #innerSelectSearch\n class=\"mat-select-search-inner mat-typography mat-datepicker-content mat-tab-header\">\n\n <input class=\"mat-select-search-input mat-input-element\"\n aria-label=\"Pesquisa suspensa\"\n aria-hidden=\"false\"\n autocomplete=\"off\"\n type=\"text\"\n #searchSelectInput\n [placeholder]=\"placeholderLabel\"\n [formControl]=\"_formControl\"\n (keydown)=\"_handleKeydown($event)\"\n (keyup)=\"_handleKeyup($event)\"\n (blur)=\"onBlur()\">\n\n <mat-spinner *ngIf=\"searching\"\n class=\"mat-select-search-spinner\"\n diameter=\"16\">\n </mat-spinner>\n\n <button *ngIf=\"!hideClearSearchButton && value && !searching\"\n class=\"mat-select-search-clear\"\n aria-label=\"Limpar\"\n mat-icon-button\n (click)=\"_reset(true)\">\n <mat-icon> close </mat-icon>\n </button>\n\n <mat-divider> </mat-divider>\n</div>\n\n<div *ngIf=\"(_showNoEntriesFound$ | async) && !searching\"\n class=\"mat-select-search-no-entries-found\">\n <mat-icon>sentiment_very_dissatisfied</mat-icon>\n Nenhum registro foi encontrado\n</div>",
|
13726
13735
|
providers: [
|
13727
13736
|
{
|
13728
13737
|
provide: forms.NG_VALUE_ACCESSOR,
|
@@ -13748,12 +13757,12 @@
|
|
13748
13757
|
return GIPIInputSearchComponent;
|
13749
13758
|
}());
|
13750
13759
|
|
13751
|
-
var nextUniqueId$
|
13760
|
+
var nextUniqueId$b = 0;
|
13752
13761
|
var GIPIInputSelectPagedComponent = /** @class */ (function () {
|
13753
13762
|
function GIPIInputSelectPagedComponent(_changeDetectorRef) {
|
13754
13763
|
var _this = this;
|
13755
13764
|
this._changeDetectorRef = _changeDetectorRef;
|
13756
|
-
this._name = "gipi-input-select-paged-" + nextUniqueId$
|
13765
|
+
this._name = "gipi-input-select-paged-" + nextUniqueId$b++;
|
13757
13766
|
this.valueSearchCtrl = new forms.FormControl('');
|
13758
13767
|
this.totalOptions = 0;
|
13759
13768
|
this.subscriptions = [];
|
@@ -14124,12 +14133,12 @@
|
|
14124
14133
|
return GIPIInputSelectPagedComponent;
|
14125
14134
|
}());
|
14126
14135
|
|
14127
|
-
var nextUniqueId$
|
14136
|
+
var nextUniqueId$c = 0;
|
14128
14137
|
var GIPIInputSelectRadioComponent = /** @class */ (function () {
|
14129
14138
|
function GIPIInputSelectRadioComponent(elementRef, _changeDetectorRef) {
|
14130
14139
|
this.elementRef = elementRef;
|
14131
14140
|
this._changeDetectorRef = _changeDetectorRef;
|
14132
|
-
this._name = "gipi-input-select-radio-" + nextUniqueId$
|
14141
|
+
this._name = "gipi-input-select-radio-" + nextUniqueId$c++;
|
14133
14142
|
this._enumList = [];
|
14134
14143
|
this.id = this._name;
|
14135
14144
|
this.name = this._name;
|
@@ -14409,6 +14418,7 @@
|
|
14409
14418
|
this.iconHeight = 24;
|
14410
14419
|
this.icon = null;
|
14411
14420
|
this.svgIcon = null;
|
14421
|
+
this.notification = false;
|
14412
14422
|
this.onShowOverlay = new core.EventEmitter();
|
14413
14423
|
this.onClick = new core.EventEmitter();
|
14414
14424
|
this.onFocus = new core.EventEmitter();
|
@@ -14465,6 +14475,10 @@
|
|
14465
14475
|
core.Input(),
|
14466
14476
|
__metadata("design:type", String)
|
14467
14477
|
], GIPINotificationComponent.prototype, "tooltip", void 0);
|
14478
|
+
__decorate([
|
14479
|
+
core.Input(),
|
14480
|
+
__metadata("design:type", Boolean)
|
14481
|
+
], GIPINotificationComponent.prototype, "notification", void 0);
|
14468
14482
|
__decorate([
|
14469
14483
|
core.Output(),
|
14470
14484
|
__metadata("design:type", core.EventEmitter)
|
@@ -14485,7 +14499,7 @@
|
|
14485
14499
|
core.Component({
|
14486
14500
|
selector: "gipi-notification",
|
14487
14501
|
exportAs: 'gipiNotification',
|
14488
|
-
template: "<gipi-button gipi-icon\n [id]=\"id\"\n [name]=\"name\"\n [ariaLabel]=\"ariaLabel\"\n [buttonPadding]=\"buttonPadding\"\n [iconWidth]=\"iconWidth\"\n [iconHeight]=\"iconHeight\"\n [icon]=\"icon\"\n [svgIcon]=\"svgIcon\"\n [disabled]=\"disabled\"\n [loading]=\"loading\"\n [tooltip]=\"tooltip\"\n [popover]=\"true\"\n [overlay]=\"false\"\n (onShowOverlay)=\"onShowOverlay.emit()\"\n (click)=\"onClick.emit($event)\"\n (focus)=\"onFocus.emit($event)\"\n (blur)=\"onBlur.emit($event)\">\n <
|
14502
|
+
template: "<gipi-button gipi-icon\n [id]=\"id\"\n [name]=\"name\"\n [ariaLabel]=\"ariaLabel\"\n [buttonPadding]=\"buttonPadding\"\n [iconWidth]=\"iconWidth\"\n [iconHeight]=\"iconHeight\"\n [icon]=\"icon\"\n [svgIcon]=\"svgIcon\"\n [disabled]=\"disabled\"\n [loading]=\"loading\"\n [tooltip]=\"tooltip\"\n [popover]=\"true\"\n [overlay]=\"false\"\n [notification]=\"notification\"\n (onShowOverlay)=\"onShowOverlay.emit()\"\n (click)=\"onClick.emit($event)\"\n (focus)=\"onFocus.emit($event)\"\n (blur)=\"onBlur.emit($event)\">\n <ng-content> </ng-content>\n</gipi-button>\n",
|
14489
14503
|
providers: [
|
14490
14504
|
{
|
14491
14505
|
provide: forms.NG_VALUE_ACCESSOR,
|
@@ -14497,7 +14511,7 @@
|
|
14497
14511
|
'class': 'gipi-notification',
|
14498
14512
|
},
|
14499
14513
|
changeDetection: core.ChangeDetectionStrategy.OnPush,
|
14500
|
-
styles: [".button-only-icon{padding:4px!important}.button-only-icon .button-content>mat-icon{width:24px!important;height:24px!important}
|
14514
|
+
styles: [".button-only-icon{padding:4px!important}.button-only-icon .button-content>mat-icon{width:24px!important;height:24px!important}"]
|
14501
14515
|
}),
|
14502
14516
|
__metadata("design:paramtypes", [])
|
14503
14517
|
], GIPINotificationComponent);
|
@@ -14651,11 +14665,11 @@
|
|
14651
14665
|
return PasswordUtil;
|
14652
14666
|
}());
|
14653
14667
|
|
14654
|
-
var nextUniqueId$
|
14668
|
+
var nextUniqueId$d = 0;
|
14655
14669
|
var GIPIPasswordRequerimentsComponent = /** @class */ (function () {
|
14656
14670
|
function GIPIPasswordRequerimentsComponent(_changeDetectorRef) {
|
14657
14671
|
this._changeDetectorRef = _changeDetectorRef;
|
14658
|
-
this._name = "gipi-password-requeriments-" + nextUniqueId$
|
14672
|
+
this._name = "gipi-password-requeriments-" + nextUniqueId$d++;
|
14659
14673
|
this.id = this._name;
|
14660
14674
|
this.name = this._name;
|
14661
14675
|
this.disabled = false;
|
@@ -15311,11 +15325,11 @@
|
|
15311
15325
|
return GIPIPopoverTarget;
|
15312
15326
|
}());
|
15313
15327
|
|
15314
|
-
var nextUniqueId$
|
15328
|
+
var nextUniqueId$e = 0;
|
15315
15329
|
var GIPIRadioGroupComponent = /** @class */ (function () {
|
15316
15330
|
function GIPIRadioGroupComponent(_changeDetectorRef) {
|
15317
15331
|
this._changeDetectorRef = _changeDetectorRef;
|
15318
|
-
this._name = "gipi-radio-group-" + nextUniqueId$
|
15332
|
+
this._name = "gipi-radio-group-" + nextUniqueId$e++;
|
15319
15333
|
this._enumList = [];
|
15320
15334
|
this.id = this._name;
|
15321
15335
|
this.name = this._name;
|
@@ -15461,114 +15475,748 @@
|
|
15461
15475
|
return GIPIRadioGroupComponent;
|
15462
15476
|
}());
|
15463
15477
|
|
15464
|
-
var
|
15465
|
-
|
15466
|
-
|
15467
|
-
this.
|
15468
|
-
this.
|
15469
|
-
this.isButtonSecondary = this._hasHostAttributes('gipi-secondary');
|
15470
|
-
this.required = false;
|
15471
|
-
this.multiple = false;
|
15472
|
-
this.disabled = false;
|
15473
|
-
this.onOptionClick = new core.EventEmitter();
|
15474
|
-
this.onChange = new core.EventEmitter();
|
15475
|
-
this.onModelChange = function () { };
|
15476
|
-
this.onModelTouched = function () { };
|
15478
|
+
var nextUniqueId$f = 0;
|
15479
|
+
var RangePage = /** @class */ (function () {
|
15480
|
+
function RangePage(start, end) {
|
15481
|
+
this.start = start;
|
15482
|
+
this.end = end;
|
15477
15483
|
}
|
15478
|
-
|
15479
|
-
|
15480
|
-
GIPISelectButtonComponent.prototype.writeValue = function (obj) {
|
15481
|
-
this.value = obj;
|
15482
|
-
this._changeDetectorRef.markForCheck();
|
15483
|
-
};
|
15484
|
-
GIPISelectButtonComponent.prototype.registerOnChange = function (fn) {
|
15485
|
-
this.onModelChange = fn;
|
15486
|
-
};
|
15487
|
-
GIPISelectButtonComponent.prototype.registerOnTouched = function (fn) {
|
15488
|
-
this.onModelTouched = fn;
|
15489
|
-
};
|
15490
|
-
GIPISelectButtonComponent.prototype.setDisabledState = function (isDisabled) {
|
15491
|
-
this.disabled = isDisabled;
|
15492
|
-
this._changeDetectorRef.markForCheck();
|
15493
|
-
};
|
15494
|
-
GIPISelectButtonComponent.prototype.getOptionLabel = function (option) {
|
15495
|
-
return this.optionLabel ? ObjectUtil.resolveFieldData(option, this.optionLabel) : option.label != undefined ? option.label : option;
|
15496
|
-
};
|
15497
|
-
GIPISelectButtonComponent.prototype.getOptionValue = function (option) {
|
15498
|
-
return this.optionValue ? ObjectUtil.resolveFieldData(option, this.optionValue) : this.optionLabel || option.value === undefined ? option : option.value;
|
15499
|
-
};
|
15500
|
-
GIPISelectButtonComponent.prototype.isOptionDisabled = function (option) {
|
15501
|
-
return this.optionDisabled ? ObjectUtil.resolveFieldData(option, this.optionDisabled) : option.disabled !== undefined ? option.disabled : false;
|
15502
|
-
};
|
15503
|
-
GIPISelectButtonComponent.prototype.onItemClick = function (event, option, index) {
|
15504
|
-
if (this.disabled || this.isOptionDisabled(option)) {
|
15505
|
-
return;
|
15506
|
-
}
|
15507
|
-
if (this.multiple) {
|
15508
|
-
if (this.isSelected(option)) {
|
15509
|
-
this.removeOption(option);
|
15510
|
-
}
|
15511
|
-
else {
|
15512
|
-
this.value = __spread((this.value || []), [this.getOptionValue(option)]);
|
15513
|
-
}
|
15514
|
-
this.onModelChange(this.value);
|
15515
|
-
this.onChange.emit({
|
15516
|
-
originalEvent: event,
|
15517
|
-
value: this.value
|
15518
|
-
});
|
15519
|
-
}
|
15520
|
-
else {
|
15521
|
-
var value = this.getOptionValue(option);
|
15522
|
-
if (this.value !== value) {
|
15523
|
-
this.value = this.getOptionValue(option);
|
15524
|
-
this.onModelChange(this.value);
|
15525
|
-
this.onChange.emit({
|
15526
|
-
originalEvent: event,
|
15527
|
-
value: this.value
|
15528
|
-
});
|
15529
|
-
}
|
15530
|
-
}
|
15531
|
-
this.onOptionClick.emit({
|
15532
|
-
originalEvent: event,
|
15533
|
-
option: option,
|
15534
|
-
index: index
|
15535
|
-
});
|
15536
|
-
};
|
15537
|
-
GIPISelectButtonComponent.prototype.isSelected = function (option) {
|
15538
|
-
var e_1, _a;
|
15539
|
-
var selected = false;
|
15540
|
-
var optionValue = this.getOptionValue(option);
|
15541
|
-
if (this.multiple) {
|
15542
|
-
if (this.value && Array.isArray(this.value)) {
|
15543
|
-
try {
|
15544
|
-
for (var _b = __values(this.value), _c = _b.next(); !_c.done; _c = _b.next()) {
|
15545
|
-
var val = _c.value;
|
15546
|
-
if (ObjectUtil.equals(val, optionValue, this.dataKey)) {
|
15547
|
-
selected = true;
|
15548
|
-
break;
|
15549
|
-
}
|
15550
|
-
}
|
15551
|
-
}
|
15552
|
-
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
15553
|
-
finally {
|
15554
|
-
try {
|
15555
|
-
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
15556
|
-
}
|
15557
|
-
finally { if (e_1) throw e_1.error; }
|
15558
|
-
}
|
15559
|
-
}
|
15560
|
-
}
|
15561
|
-
else {
|
15562
|
-
selected = ObjectUtil.equals(this.getOptionValue(option), this.value, this.dataKey);
|
15563
|
-
}
|
15564
|
-
return selected;
|
15484
|
+
RangePage.prototype.getTotalCount = function () {
|
15485
|
+
return (this.end - this.start) + 1;
|
15565
15486
|
};
|
15566
|
-
|
15487
|
+
RangePage.prototype.getRange = function () {
|
15567
15488
|
var _this = this;
|
15568
|
-
|
15489
|
+
return Array.from({ length: this.getTotalCount() }, function (_, i) { return _this.start - 1 + i; });
|
15569
15490
|
};
|
15570
|
-
|
15571
|
-
|
15491
|
+
return RangePage;
|
15492
|
+
}());
|
15493
|
+
var GIPIRangePageComponent = /** @class */ (function () {
|
15494
|
+
function GIPIRangePageComponent(elementRef, _changeDetectorRef) {
|
15495
|
+
this.elementRef = elementRef;
|
15496
|
+
this._changeDetectorRef = _changeDetectorRef;
|
15497
|
+
this._name = "gipi-range-page-" + nextUniqueId$f++;
|
15498
|
+
this._startPage = 1;
|
15499
|
+
this._endPage = 1;
|
15500
|
+
this.id = this._name;
|
15501
|
+
this.name = this._name;
|
15502
|
+
this.label = '';
|
15503
|
+
this.tooltip = '';
|
15504
|
+
this.placeholderStart = '';
|
15505
|
+
this.placeholderEnd = '';
|
15506
|
+
this.help = '';
|
15507
|
+
this._min = 1;
|
15508
|
+
this._max = 100;
|
15509
|
+
this._step = 1;
|
15510
|
+
this._required = false;
|
15511
|
+
this._disabled = false;
|
15512
|
+
this.onChange = function (value) { };
|
15513
|
+
this.onTouched = function () { };
|
15514
|
+
}
|
15515
|
+
GIPIRangePageComponent_1 = GIPIRangePageComponent;
|
15516
|
+
Object.defineProperty(GIPIRangePageComponent.prototype, "min", {
|
15517
|
+
get: function () {
|
15518
|
+
return NumberUtil.isNumber(this._min) ? this._min : 1;
|
15519
|
+
},
|
15520
|
+
set: function (value) {
|
15521
|
+
this._min = value;
|
15522
|
+
this._initPage();
|
15523
|
+
},
|
15524
|
+
enumerable: false,
|
15525
|
+
configurable: true
|
15526
|
+
});
|
15527
|
+
Object.defineProperty(GIPIRangePageComponent.prototype, "max", {
|
15528
|
+
get: function () {
|
15529
|
+
return NumberUtil.isNumber(this._max) ? this._max : 100;
|
15530
|
+
},
|
15531
|
+
set: function (value) {
|
15532
|
+
this._max = value;
|
15533
|
+
this._initPage();
|
15534
|
+
},
|
15535
|
+
enumerable: false,
|
15536
|
+
configurable: true
|
15537
|
+
});
|
15538
|
+
Object.defineProperty(GIPIRangePageComponent.prototype, "step", {
|
15539
|
+
get: function () {
|
15540
|
+
return NumberUtil.isNumber(this._step) ? this._step : 1;
|
15541
|
+
},
|
15542
|
+
set: function (value) {
|
15543
|
+
this._step = value;
|
15544
|
+
this._initPage();
|
15545
|
+
},
|
15546
|
+
enumerable: false,
|
15547
|
+
configurable: true
|
15548
|
+
});
|
15549
|
+
Object.defineProperty(GIPIRangePageComponent.prototype, "required", {
|
15550
|
+
get: function () {
|
15551
|
+
return this._required;
|
15552
|
+
},
|
15553
|
+
set: function (value) {
|
15554
|
+
this._required = coercion.coerceBooleanProperty(value);
|
15555
|
+
},
|
15556
|
+
enumerable: false,
|
15557
|
+
configurable: true
|
15558
|
+
});
|
15559
|
+
Object.defineProperty(GIPIRangePageComponent.prototype, "disabled", {
|
15560
|
+
get: function () {
|
15561
|
+
return this._disabled;
|
15562
|
+
},
|
15563
|
+
set: function (value) {
|
15564
|
+
this._disabled = coercion.coerceBooleanProperty(value);
|
15565
|
+
},
|
15566
|
+
enumerable: false,
|
15567
|
+
configurable: true
|
15568
|
+
});
|
15569
|
+
Object.defineProperty(GIPIRangePageComponent.prototype, "formattedValue", {
|
15570
|
+
get: function () {
|
15571
|
+
return '';
|
15572
|
+
},
|
15573
|
+
enumerable: false,
|
15574
|
+
configurable: true
|
15575
|
+
});
|
15576
|
+
GIPIRangePageComponent.prototype.ngOnInit = function () {
|
15577
|
+
this._initPage();
|
15578
|
+
};
|
15579
|
+
GIPIRangePageComponent.prototype.ngOnDestroy = function () { };
|
15580
|
+
GIPIRangePageComponent.prototype.writeValue = function (value) {
|
15581
|
+
if (!ObjectUtil.isNull(value)) {
|
15582
|
+
this._startPage = value.start || this._startPage;
|
15583
|
+
this._endPage = value.end || this._endPage;
|
15584
|
+
}
|
15585
|
+
this._changeDetectorRef.detectChanges();
|
15586
|
+
};
|
15587
|
+
GIPIRangePageComponent.prototype.registerOnChange = function (fn) {
|
15588
|
+
this.onChange = fn;
|
15589
|
+
};
|
15590
|
+
GIPIRangePageComponent.prototype.registerOnTouched = function (fn) {
|
15591
|
+
this.onTouched = fn;
|
15592
|
+
};
|
15593
|
+
GIPIRangePageComponent.prototype.setDisabledState = function (isDisabled) {
|
15594
|
+
this.disabled = isDisabled;
|
15595
|
+
this._changeDetectorRef.markForCheck();
|
15596
|
+
};
|
15597
|
+
GIPIRangePageComponent.prototype._initPage = function () {
|
15598
|
+
this._startPage = this.min;
|
15599
|
+
this._endPage = Math.min(this._startPage + this.step - 1, this.max);
|
15600
|
+
};
|
15601
|
+
GIPIRangePageComponent.prototype.updateEndPage = function () {
|
15602
|
+
if (this.disabled) {
|
15603
|
+
return;
|
15604
|
+
}
|
15605
|
+
if (this._startPage < this.min) {
|
15606
|
+
this._startPage = this.min;
|
15607
|
+
}
|
15608
|
+
else if (this._startPage > this.max) {
|
15609
|
+
this._startPage = this.max;
|
15610
|
+
}
|
15611
|
+
if (this._endPage < this._startPage) {
|
15612
|
+
this._endPage = this._startPage;
|
15613
|
+
}
|
15614
|
+
else if (this._endPage > (this._startPage + (this.step - 1))) {
|
15615
|
+
this._endPage = Math.min(this._startPage + this.step - 1, this.max);
|
15616
|
+
}
|
15617
|
+
this._propagateChange();
|
15618
|
+
};
|
15619
|
+
GIPIRangePageComponent.prototype.updateStartPage = function () {
|
15620
|
+
if (this.disabled) {
|
15621
|
+
return;
|
15622
|
+
}
|
15623
|
+
if (this._endPage > this.max) {
|
15624
|
+
this._endPage = this.max;
|
15625
|
+
}
|
15626
|
+
else if (this._endPage > this.max) {
|
15627
|
+
this._endPage = this.max;
|
15628
|
+
}
|
15629
|
+
if (this._startPage > this._endPage) {
|
15630
|
+
this._startPage = this._endPage;
|
15631
|
+
}
|
15632
|
+
else if (this._startPage < (this._endPage - (this.step + 1))) {
|
15633
|
+
this._startPage = Math.max(this._endPage - this.step + 1, this.min);
|
15634
|
+
}
|
15635
|
+
this._propagateChange();
|
15636
|
+
};
|
15637
|
+
GIPIRangePageComponent.prototype.previous = function () {
|
15638
|
+
if (this.disabled) {
|
15639
|
+
return;
|
15640
|
+
}
|
15641
|
+
var newStartPage = Math.max(this._startPage - this.step + 1, this.min);
|
15642
|
+
var newEndPage = Math.min(newStartPage + this.step - 1, this.max);
|
15643
|
+
if (newEndPage >= this.min) {
|
15644
|
+
this._startPage = newStartPage;
|
15645
|
+
this._endPage = newEndPage;
|
15646
|
+
this._propagateChange();
|
15647
|
+
}
|
15648
|
+
};
|
15649
|
+
GIPIRangePageComponent.prototype.next = function () {
|
15650
|
+
if (this.disabled) {
|
15651
|
+
return;
|
15652
|
+
}
|
15653
|
+
// const newStartPage = Math.min(this._startPage + this.step, this.max - this.step + 1);
|
15654
|
+
// let newEndPage = newStartPage + this.step - 1;
|
15655
|
+
var newStartPage = Math.min(this._startPage + this.step, this.max);
|
15656
|
+
var newEndPage = Math.min(newStartPage + this.step - 1, this.max);
|
15657
|
+
if ((newStartPage === this.max) || (newEndPage > this.max)) {
|
15658
|
+
newEndPage = newStartPage;
|
15659
|
+
}
|
15660
|
+
if (newEndPage <= this.max) {
|
15661
|
+
this._startPage = newStartPage;
|
15662
|
+
this._endPage = newEndPage;
|
15663
|
+
this._propagateChange();
|
15664
|
+
}
|
15665
|
+
};
|
15666
|
+
GIPIRangePageComponent.prototype.selectText = function (input) {
|
15667
|
+
if (this.disabled || !input) {
|
15668
|
+
return;
|
15669
|
+
}
|
15670
|
+
setTimeout(function () { return input.select(); }, 0);
|
15671
|
+
};
|
15672
|
+
GIPIRangePageComponent.prototype._propagateChange = function () {
|
15673
|
+
this.onChange(new RangePage(this._startPage, this._endPage));
|
15674
|
+
this.onTouched();
|
15675
|
+
};
|
15676
|
+
var GIPIRangePageComponent_1;
|
15677
|
+
GIPIRangePageComponent.ctorParameters = function () { return [
|
15678
|
+
{ type: core.ElementRef },
|
15679
|
+
{ type: core.ChangeDetectorRef }
|
15680
|
+
]; };
|
15681
|
+
__decorate([
|
15682
|
+
core.Input(),
|
15683
|
+
__metadata("design:type", String)
|
15684
|
+
], GIPIRangePageComponent.prototype, "id", void 0);
|
15685
|
+
__decorate([
|
15686
|
+
core.Input(),
|
15687
|
+
__metadata("design:type", String)
|
15688
|
+
], GIPIRangePageComponent.prototype, "name", void 0);
|
15689
|
+
__decorate([
|
15690
|
+
core.Input(),
|
15691
|
+
__metadata("design:type", String)
|
15692
|
+
], GIPIRangePageComponent.prototype, "label", void 0);
|
15693
|
+
__decorate([
|
15694
|
+
core.Input(),
|
15695
|
+
__metadata("design:type", String)
|
15696
|
+
], GIPIRangePageComponent.prototype, "tooltip", void 0);
|
15697
|
+
__decorate([
|
15698
|
+
core.Input(),
|
15699
|
+
__metadata("design:type", String)
|
15700
|
+
], GIPIRangePageComponent.prototype, "placeholderStart", void 0);
|
15701
|
+
__decorate([
|
15702
|
+
core.Input(),
|
15703
|
+
__metadata("design:type", String)
|
15704
|
+
], GIPIRangePageComponent.prototype, "placeholderEnd", void 0);
|
15705
|
+
__decorate([
|
15706
|
+
core.Input(),
|
15707
|
+
__metadata("design:type", String)
|
15708
|
+
], GIPIRangePageComponent.prototype, "help", void 0);
|
15709
|
+
__decorate([
|
15710
|
+
core.Input(),
|
15711
|
+
__metadata("design:type", Number),
|
15712
|
+
__metadata("design:paramtypes", [Number])
|
15713
|
+
], GIPIRangePageComponent.prototype, "min", null);
|
15714
|
+
__decorate([
|
15715
|
+
core.Input(),
|
15716
|
+
__metadata("design:type", Number),
|
15717
|
+
__metadata("design:paramtypes", [Number])
|
15718
|
+
], GIPIRangePageComponent.prototype, "max", null);
|
15719
|
+
__decorate([
|
15720
|
+
core.Input(),
|
15721
|
+
__metadata("design:type", Number),
|
15722
|
+
__metadata("design:paramtypes", [Number])
|
15723
|
+
], GIPIRangePageComponent.prototype, "step", null);
|
15724
|
+
__decorate([
|
15725
|
+
core.Input(),
|
15726
|
+
__metadata("design:type", Boolean),
|
15727
|
+
__metadata("design:paramtypes", [Boolean])
|
15728
|
+
], GIPIRangePageComponent.prototype, "required", null);
|
15729
|
+
__decorate([
|
15730
|
+
core.Input(),
|
15731
|
+
__metadata("design:type", Boolean),
|
15732
|
+
__metadata("design:paramtypes", [Boolean])
|
15733
|
+
], GIPIRangePageComponent.prototype, "disabled", null);
|
15734
|
+
GIPIRangePageComponent = GIPIRangePageComponent_1 = __decorate([
|
15735
|
+
core.Component({
|
15736
|
+
selector: 'gipi-range-page',
|
15737
|
+
template: "<label *ngIf=\"label\"\n class=\"input-label\"\n [attr.for]=\"id\">\n {{ label }}\n <span *ngIf=\"required\"> * </span>\n <gipi-helpful-tip *ngIf=\"tooltip && label\"\n [tooltip]=\"tooltip\">\n </gipi-helpful-tip>\n</label>\n\n<div class=\"input-content\">\n <div class=\"prefix\"\n [class.disabled]=\"disabled\"\n (click)=\"previous()\">\n <mat-icon>chevron_left</mat-icon>\n </div>\n <input #startInput\n matInput\n class=\"input-element\"\n type=\"number\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [min]=\"min\"\n [max]=\"max\"\n [maxlength]=\"10\"\n [placeholder]=\"placeholderStart\"\n [disabled]=\"disabled\"\n [required]=\"required\"\n [readOnly]=\"false\"\n [autocomplete]=\"'off'\"\n [autofocus]=\"false\"\n [(ngModel)]=\"_startPage\"\n (keyup)=\"updateEndPage()\"\n (focus)=\"selectText(startInput)\"\n (click)=\"selectText(startInput)\" />\n <div class=\"infix\">\n a\n </div>\n <input #endInput\n matInput\n class=\"input-element\"\n type=\"number\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [min]=\"_startPage\"\n [max]=\"max\"\n [maxlength]=\"10\"\n [placeholder]=\"placeholderEnd\"\n [disabled]=\"disabled\"\n [required]=\"required\"\n [readOnly]=\"false\"\n [autocomplete]=\"'off'\"\n [autofocus]=\"false\"\n [(ngModel)]=\"_endPage\"\n (keyup)=\"updateStartPage()\"\n (focus)=\"selectText(endInput)\"\n (click)=\"selectText(endInput)\" />\n <div class=\"suffix\"\n [class.disabled]=\"disabled\"\n (click)=\"next()\">\n <mat-icon>chevron_right</mat-icon>\n </div>\n</div>\n\n<small *ngIf=\"help\"\n class=\"input-help\">\n {{ help }}\n</small>",
|
15738
|
+
providers: [
|
15739
|
+
{
|
15740
|
+
provide: forms.NG_VALUE_ACCESSOR,
|
15741
|
+
useExisting: core.forwardRef(function () { return GIPIRangePageComponent_1; }),
|
15742
|
+
multi: true
|
15743
|
+
},
|
15744
|
+
],
|
15745
|
+
styles: [":host{display:flex;flex-direction:column;gap:.8rem;font-size:1.4rem;color:#696969}:host .input-label{display:flex;align-items:center;gap:.4rem;color:#131313;line-height:1.6rem}:host .input-label>span{font-size:1.6rem;line-height:1.6rem;color:#d14014}:host .input-content{display:flex;font-family:inherit;font-size:inherit;color:inherit;height:4rem;background:#fff;border:1px solid rgba(0,0,0,.12);transition:background-color .2s,color .2s,border-color .2s,box-shadow .2s;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:.6rem}:host .input-content .input-element{padding:.75rem .8rem;border:none;outline:0;background-color:transparent;flex:1;color:inherit;caret-color:#696969;min-width:0;text-align:center;margin:0!important}:host .input-content .input-element::-webkit-inner-spin-button,:host .input-content .input-element::-webkit-outer-spin-button{-webkit-appearance:none;appearance:none;opacity:0}:host .input-content:has(.input-element:disabled){color:#bbbdc1!important;border-color:#e0e1e2!important;background-color:#f5f5f6!important;cursor:not-allowed}:host .input-content:has(.input-element:disabled) .suffix>mat-icon{color:#bbbdc1!important}:host .input-content .input-element:disabled{cursor:not-allowed}:host .input-content .infix,:host .input-content .prefix,:host .input-content .suffix{display:flex;align-items:center;justify-content:center;padding-block:.75rem;padding-inline:.8rem;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;transition:.2s;background-color:#e0313e}:host .input-content .infix>mat-icon,:host .input-content .prefix>mat-icon,:host .input-content .suffix>mat-icon{width:2rem;height:2rem;font-size:2rem;color:#fff}:host .input-content .infix:not(.infix):not(.disabled):hover,:host .input-content .prefix:not(.infix):not(.disabled):hover,:host .input-content .suffix:not(.infix):not(.disabled):hover{background-color:#cc2d38}:host .input-content .infix:not(.infix):not(.disabled):active,:host .input-content .prefix:not(.infix):not(.disabled):active,:host .input-content .suffix:not(.infix):not(.disabled):active{background-color:#9f232c}:host .input-content .prefix.disabled,:host .input-content .suffix.disabled{background-color:#d1d2d4}:host .input-content .prefix.disabled>mat-icon,:host .input-content .suffix.disabled>mat-icon{color:#9a9da2}:host .input-content .prefix{border-right:1px solid rgba(0,0,0,.12);border-radius:.6rem 0 0 .6rem;cursor:pointer}:host .input-content .infix{width:1rem;padding:0;background-color:transparent}:host .input-content .suffix{border-left:1px solid rgba(0,0,0,.12);border-radius:0 .6rem .6rem 0;cursor:pointer}:host .input-help{flex:1;font-size:1rem;font-weight:500;margin-top:-.4rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}::-webkit-input-placeholder{color:#bbbdc1}:-moz-placeholder{color:#bbbdc1}::-moz-placeholder{color:#bbbdc1}:-ms-input-placeholder{color:#bbbdc1}"]
|
15746
|
+
}),
|
15747
|
+
__metadata("design:paramtypes", [core.ElementRef,
|
15748
|
+
core.ChangeDetectorRef])
|
15749
|
+
], GIPIRangePageComponent);
|
15750
|
+
return GIPIRangePageComponent;
|
15751
|
+
}());
|
15752
|
+
|
15753
|
+
var nextUniqueId$g = 0;
|
15754
|
+
var GIPIRangeSliderComponent = /** @class */ (function () {
|
15755
|
+
function GIPIRangeSliderComponent(elementRef, _changeDetectorRef) {
|
15756
|
+
this.elementRef = elementRef;
|
15757
|
+
this._changeDetectorRef = _changeDetectorRef;
|
15758
|
+
this._name = "gipi-range-slider-" + nextUniqueId$g++;
|
15759
|
+
this.id = this._name;
|
15760
|
+
this.name = this._name;
|
15761
|
+
this.label = '';
|
15762
|
+
this.help = '';
|
15763
|
+
this.min = 1;
|
15764
|
+
this.max = 100;
|
15765
|
+
this._maxRange = 5;
|
15766
|
+
this._fromValue = 1;
|
15767
|
+
this._toValue = 1;
|
15768
|
+
this._step = 1;
|
15769
|
+
this._disabled = false;
|
15770
|
+
this._required = false;
|
15771
|
+
this.onChange = function () { };
|
15772
|
+
this.onTouched = function () { };
|
15773
|
+
}
|
15774
|
+
GIPIRangeSliderComponent_1 = GIPIRangeSliderComponent;
|
15775
|
+
Object.defineProperty(GIPIRangeSliderComponent.prototype, "maxRange", {
|
15776
|
+
get: function () {
|
15777
|
+
return this._maxRange || 5;
|
15778
|
+
},
|
15779
|
+
set: function (value) {
|
15780
|
+
if (!value || (value <= 0)) {
|
15781
|
+
throw new Error('Minimum value for "maxRange" must be 1');
|
15782
|
+
}
|
15783
|
+
this._maxRange = value || 5;
|
15784
|
+
},
|
15785
|
+
enumerable: false,
|
15786
|
+
configurable: true
|
15787
|
+
});
|
15788
|
+
Object.defineProperty(GIPIRangeSliderComponent.prototype, "fromValue", {
|
15789
|
+
get: function () {
|
15790
|
+
return this._fromValue || 1;
|
15791
|
+
},
|
15792
|
+
set: function (value) {
|
15793
|
+
if (!value || (value <= 0)) {
|
15794
|
+
throw new Error('Minimum value for "from" must be 1');
|
15795
|
+
}
|
15796
|
+
this._fromValue = value || 1;
|
15797
|
+
},
|
15798
|
+
enumerable: false,
|
15799
|
+
configurable: true
|
15800
|
+
});
|
15801
|
+
Object.defineProperty(GIPIRangeSliderComponent.prototype, "toValue", {
|
15802
|
+
get: function () {
|
15803
|
+
return this._toValue || 1;
|
15804
|
+
},
|
15805
|
+
set: function (value) {
|
15806
|
+
if (!value || (value <= 0)) {
|
15807
|
+
throw new Error('Minimum value for "to" must be 1');
|
15808
|
+
}
|
15809
|
+
this._toValue = value || 1;
|
15810
|
+
},
|
15811
|
+
enumerable: false,
|
15812
|
+
configurable: true
|
15813
|
+
});
|
15814
|
+
Object.defineProperty(GIPIRangeSliderComponent.prototype, "step", {
|
15815
|
+
get: function () {
|
15816
|
+
return this._step || 1;
|
15817
|
+
},
|
15818
|
+
set: function (value) {
|
15819
|
+
if (!value || (value <= 0)) {
|
15820
|
+
throw new Error('Minimum value for "step" must be 1');
|
15821
|
+
}
|
15822
|
+
this._step = value || 1;
|
15823
|
+
},
|
15824
|
+
enumerable: false,
|
15825
|
+
configurable: true
|
15826
|
+
});
|
15827
|
+
Object.defineProperty(GIPIRangeSliderComponent.prototype, "disabled", {
|
15828
|
+
get: function () {
|
15829
|
+
return this._disabled;
|
15830
|
+
},
|
15831
|
+
set: function (value) {
|
15832
|
+
this._disabled = coercion.coerceBooleanProperty(value);
|
15833
|
+
},
|
15834
|
+
enumerable: false,
|
15835
|
+
configurable: true
|
15836
|
+
});
|
15837
|
+
Object.defineProperty(GIPIRangeSliderComponent.prototype, "required", {
|
15838
|
+
get: function () {
|
15839
|
+
return this._required;
|
15840
|
+
},
|
15841
|
+
set: function (value) {
|
15842
|
+
this._required = coercion.coerceBooleanProperty(value);
|
15843
|
+
},
|
15844
|
+
enumerable: false,
|
15845
|
+
configurable: true
|
15846
|
+
});
|
15847
|
+
GIPIRangeSliderComponent.prototype.ngOnInit = function () { };
|
15848
|
+
GIPIRangeSliderComponent.prototype.ngAfterViewInit = function () {
|
15849
|
+
this._fillSlider();
|
15850
|
+
this._setToggleAccessible();
|
15851
|
+
};
|
15852
|
+
GIPIRangeSliderComponent.prototype.ngOnDestroy = function () { };
|
15853
|
+
GIPIRangeSliderComponent.prototype.writeValue = function (value) {
|
15854
|
+
if (value) {
|
15855
|
+
this.fromValue = value.from;
|
15856
|
+
this.toValue = value.to;
|
15857
|
+
if (this.fromSlider && this.toSlider) {
|
15858
|
+
this.fromSlider.nativeElement.value = this.fromValue.toString();
|
15859
|
+
this.toSlider.nativeElement.value = this.toValue.toString();
|
15860
|
+
this._fillSlider();
|
15861
|
+
this._setToggleAccessible();
|
15862
|
+
}
|
15863
|
+
}
|
15864
|
+
};
|
15865
|
+
GIPIRangeSliderComponent.prototype.registerOnChange = function (fn) {
|
15866
|
+
this.onChange = fn;
|
15867
|
+
};
|
15868
|
+
GIPIRangeSliderComponent.prototype.registerOnTouched = function (fn) {
|
15869
|
+
this.onTouched = fn;
|
15870
|
+
};
|
15871
|
+
GIPIRangeSliderComponent.prototype.setDisabledState = function (isDisabled) {
|
15872
|
+
this.disabled = isDisabled;
|
15873
|
+
this._changeDetectorRef.markForCheck();
|
15874
|
+
};
|
15875
|
+
GIPIRangeSliderComponent.prototype.controlFromInput = function (isByNgModel) {
|
15876
|
+
var _a = __read(isByNgModel ? [this.fromValue, this.toValue] : this._getParsed(this.fromSlider.nativeElement, this.toSlider.nativeElement), 2), from = _a[0], to = _a[1];
|
15877
|
+
from = this._roundToStep(from);
|
15878
|
+
to = this._roundToStep(to);
|
15879
|
+
// if ((to - from) > this.maxRange) {
|
15880
|
+
// from = to - this.maxRange;
|
15881
|
+
// }
|
15882
|
+
this._fillSlider();
|
15883
|
+
this._setToggleAccessible();
|
15884
|
+
if (from > to) {
|
15885
|
+
this.fromValue = to;
|
15886
|
+
}
|
15887
|
+
this.fromSlider.nativeElement.value = this.fromValue.toString();
|
15888
|
+
this._notifyValueChange();
|
15889
|
+
};
|
15890
|
+
GIPIRangeSliderComponent.prototype.controlToInput = function (isByNgModel) {
|
15891
|
+
var _a = __read(isByNgModel ? [this.fromValue, this.toValue] : this._getParsed(this.fromSlider.nativeElement, this.toSlider.nativeElement), 2), from = _a[0], to = _a[1];
|
15892
|
+
from = this._roundToStep(from);
|
15893
|
+
to = this._roundToStep(to);
|
15894
|
+
// if ((to - from) > this.maxRange) {
|
15895
|
+
// to = from + this.maxRange;
|
15896
|
+
// }
|
15897
|
+
this._fillSlider();
|
15898
|
+
this._setToggleAccessible();
|
15899
|
+
if (from <= to) {
|
15900
|
+
this.toValue = to;
|
15901
|
+
}
|
15902
|
+
else {
|
15903
|
+
this.toValue = from;
|
15904
|
+
}
|
15905
|
+
this.toSlider.nativeElement.value = this.toValue.toString();
|
15906
|
+
this._notifyValueChange();
|
15907
|
+
};
|
15908
|
+
GIPIRangeSliderComponent.prototype.controlFromSlider = function () {
|
15909
|
+
var _a = __read(this._getParsed(this.fromSlider.nativeElement, this.toSlider.nativeElement), 2), from = _a[0], to = _a[1];
|
15910
|
+
from = this._roundToStep(from);
|
15911
|
+
to = this._roundToStep(to);
|
15912
|
+
if ((to - from) > this.maxRange) {
|
15913
|
+
from = to - this.maxRange;
|
15914
|
+
}
|
15915
|
+
this._fillSlider();
|
15916
|
+
this._setToggleAccessible();
|
15917
|
+
if ((to - from) === this.maxRange) {
|
15918
|
+
var _b = __read(this._getParsed(this.fromSlider.nativeElement, this.toSlider.nativeElement), 2), from_1 = _b[0], to_1 = _b[1];
|
15919
|
+
from_1 = this._roundToStep(from_1);
|
15920
|
+
to_1 = this._roundToStep(to_1);
|
15921
|
+
if ((to_1 - from_1) > this.maxRange) {
|
15922
|
+
to_1 = from_1 + this.maxRange;
|
15923
|
+
}
|
15924
|
+
this._fillSlider();
|
15925
|
+
if (from_1 <= to_1) {
|
15926
|
+
this.toValue = to_1;
|
15927
|
+
}
|
15928
|
+
else {
|
15929
|
+
this.toValue = from_1;
|
15930
|
+
}
|
15931
|
+
this.toSlider.nativeElement.value = this.toValue.toString();
|
15932
|
+
}
|
15933
|
+
if (from >= to) {
|
15934
|
+
this.fromValue = to;
|
15935
|
+
}
|
15936
|
+
else {
|
15937
|
+
this.fromValue = from;
|
15938
|
+
}
|
15939
|
+
this.fromSlider.nativeElement.value = this.fromValue.toString();
|
15940
|
+
this._notifyValueChange();
|
15941
|
+
};
|
15942
|
+
GIPIRangeSliderComponent.prototype.controlToSlider = function () {
|
15943
|
+
var _a = __read(this._getParsed(this.fromSlider.nativeElement, this.toSlider.nativeElement), 2), from = _a[0], to = _a[1];
|
15944
|
+
from = this._roundToStep(from);
|
15945
|
+
to = this._roundToStep(to);
|
15946
|
+
if ((to - from) > this.maxRange) {
|
15947
|
+
to = from + this.maxRange;
|
15948
|
+
}
|
15949
|
+
this._fillSlider();
|
15950
|
+
this._setToggleAccessible();
|
15951
|
+
if ((to - from) === this.maxRange) {
|
15952
|
+
var _b = __read(this._getParsed(this.fromSlider.nativeElement, this.toSlider.nativeElement), 2), from_2 = _b[0], to_2 = _b[1];
|
15953
|
+
from_2 = this._roundToStep(from_2);
|
15954
|
+
to_2 = this._roundToStep(to_2);
|
15955
|
+
if ((to_2 - from_2) > this.maxRange) {
|
15956
|
+
from_2 = to_2 - this.maxRange;
|
15957
|
+
}
|
15958
|
+
this._fillSlider();
|
15959
|
+
if (from_2 >= to_2) {
|
15960
|
+
this.fromValue = to_2;
|
15961
|
+
}
|
15962
|
+
else {
|
15963
|
+
this.fromValue = from_2;
|
15964
|
+
}
|
15965
|
+
this.fromSlider.nativeElement.value = this.fromValue.toString();
|
15966
|
+
}
|
15967
|
+
if (from <= to) {
|
15968
|
+
this.toValue = to;
|
15969
|
+
}
|
15970
|
+
else {
|
15971
|
+
this.toValue = from;
|
15972
|
+
}
|
15973
|
+
this.toSlider.nativeElement.value = this.toValue.toString();
|
15974
|
+
this._notifyValueChange();
|
15975
|
+
};
|
15976
|
+
GIPIRangeSliderComponent.prototype._getParsed = function (currentFrom, currentTo) {
|
15977
|
+
var from = parseInt(currentFrom.value, 10);
|
15978
|
+
var to = parseInt(currentTo.value, 10);
|
15979
|
+
return [from, to];
|
15980
|
+
};
|
15981
|
+
GIPIRangeSliderComponent.prototype._fillSlider = function () {
|
15982
|
+
var fromSliderEl = this.fromSlider.nativeElement;
|
15983
|
+
var toSliderEl = this.toSlider.nativeElement;
|
15984
|
+
var rangeDistance = Number(toSliderEl.max) - Number(toSliderEl.min);
|
15985
|
+
var fromPosition = (this.fromValue - Number(fromSliderEl.min));
|
15986
|
+
var toPosition = (this.toValue - Number(toSliderEl.min));
|
15987
|
+
var sliderColor = '#e0e1e2';
|
15988
|
+
var rangeColor = '#f1a0a6';
|
15989
|
+
toSliderEl.style.background = "linear-gradient(\n to right,\n " + sliderColor + " 0%,\n " + sliderColor + " " + (fromPosition) / (rangeDistance) * 100 + "%,\n " + rangeColor + " " + ((fromPosition) / (rangeDistance)) * 100 + "%,\n " + rangeColor + " " + (toPosition) / (rangeDistance) * 100 + "%,\n " + sliderColor + " " + (toPosition) / (rangeDistance) * 100 + "%,\n " + sliderColor + " 100%)";
|
15990
|
+
};
|
15991
|
+
GIPIRangeSliderComponent.prototype._setToggleAccessible = function () {
|
15992
|
+
var fromInput = this.fromSlider.nativeElement;
|
15993
|
+
var toInput = this.toSlider.nativeElement;
|
15994
|
+
var fromValue = parseInt(fromInput.value, 10);
|
15995
|
+
var toValue = parseInt(toInput.value, 10);
|
15996
|
+
if (fromValue <= parseInt(fromInput.min, 10) && toValue <= parseInt(toInput.min, 10)) {
|
15997
|
+
// Ambos estão no mínimo
|
15998
|
+
fromInput.style.zIndex = '1';
|
15999
|
+
toInput.style.zIndex = '2';
|
16000
|
+
}
|
16001
|
+
else if (fromValue >= parseInt(fromInput.max, 10) && toValue >= parseInt(toInput.max, 10)) {
|
16002
|
+
// Ambos estão no máximo
|
16003
|
+
fromInput.style.zIndex = '2';
|
16004
|
+
toInput.style.zIndex = '1';
|
16005
|
+
}
|
16006
|
+
else {
|
16007
|
+
// Caso geral
|
16008
|
+
fromInput.style.zIndex = '2';
|
16009
|
+
toInput.style.zIndex = '1';
|
16010
|
+
}
|
16011
|
+
};
|
16012
|
+
GIPIRangeSliderComponent.prototype._roundToStep = function (value) {
|
16013
|
+
return Math.round(value / this.step) * this.step;
|
16014
|
+
};
|
16015
|
+
GIPIRangeSliderComponent.prototype._notifyValueChange = function () {
|
16016
|
+
this.onChange({ from: this.fromValue, to: this.toValue });
|
16017
|
+
};
|
16018
|
+
GIPIRangeSliderComponent.prototype.onBlur = function () {
|
16019
|
+
this.onTouched();
|
16020
|
+
};
|
16021
|
+
var GIPIRangeSliderComponent_1;
|
16022
|
+
GIPIRangeSliderComponent.ctorParameters = function () { return [
|
16023
|
+
{ type: core.ElementRef },
|
16024
|
+
{ type: core.ChangeDetectorRef }
|
16025
|
+
]; };
|
16026
|
+
__decorate([
|
16027
|
+
core.ViewChild('fromSlider', { static: false }),
|
16028
|
+
__metadata("design:type", core.ElementRef)
|
16029
|
+
], GIPIRangeSliderComponent.prototype, "fromSlider", void 0);
|
16030
|
+
__decorate([
|
16031
|
+
core.ViewChild('toSlider', { static: false }),
|
16032
|
+
__metadata("design:type", core.ElementRef)
|
16033
|
+
], GIPIRangeSliderComponent.prototype, "toSlider", void 0);
|
16034
|
+
__decorate([
|
16035
|
+
core.Input(),
|
16036
|
+
__metadata("design:type", String)
|
16037
|
+
], GIPIRangeSliderComponent.prototype, "id", void 0);
|
16038
|
+
__decorate([
|
16039
|
+
core.Input(),
|
16040
|
+
__metadata("design:type", String)
|
16041
|
+
], GIPIRangeSliderComponent.prototype, "name", void 0);
|
16042
|
+
__decorate([
|
16043
|
+
core.Input(),
|
16044
|
+
__metadata("design:type", String)
|
16045
|
+
], GIPIRangeSliderComponent.prototype, "label", void 0);
|
16046
|
+
__decorate([
|
16047
|
+
core.Input(),
|
16048
|
+
__metadata("design:type", String)
|
16049
|
+
], GIPIRangeSliderComponent.prototype, "help", void 0);
|
16050
|
+
__decorate([
|
16051
|
+
core.Input(),
|
16052
|
+
__metadata("design:type", Number)
|
16053
|
+
], GIPIRangeSliderComponent.prototype, "min", void 0);
|
16054
|
+
__decorate([
|
16055
|
+
core.Input(),
|
16056
|
+
__metadata("design:type", Number)
|
16057
|
+
], GIPIRangeSliderComponent.prototype, "max", void 0);
|
16058
|
+
__decorate([
|
16059
|
+
core.Input(),
|
16060
|
+
__metadata("design:type", Number),
|
16061
|
+
__metadata("design:paramtypes", [Number])
|
16062
|
+
], GIPIRangeSliderComponent.prototype, "maxRange", null);
|
16063
|
+
__decorate([
|
16064
|
+
core.Input('from'),
|
16065
|
+
__metadata("design:type", Number),
|
16066
|
+
__metadata("design:paramtypes", [Number])
|
16067
|
+
], GIPIRangeSliderComponent.prototype, "fromValue", null);
|
16068
|
+
__decorate([
|
16069
|
+
core.Input('to'),
|
16070
|
+
__metadata("design:type", Number),
|
16071
|
+
__metadata("design:paramtypes", [Number])
|
16072
|
+
], GIPIRangeSliderComponent.prototype, "toValue", null);
|
16073
|
+
__decorate([
|
16074
|
+
core.Input(),
|
16075
|
+
__metadata("design:type", Number),
|
16076
|
+
__metadata("design:paramtypes", [Number])
|
16077
|
+
], GIPIRangeSliderComponent.prototype, "step", null);
|
16078
|
+
__decorate([
|
16079
|
+
core.Input(),
|
16080
|
+
__metadata("design:type", Boolean),
|
16081
|
+
__metadata("design:paramtypes", [Boolean])
|
16082
|
+
], GIPIRangeSliderComponent.prototype, "disabled", null);
|
16083
|
+
__decorate([
|
16084
|
+
core.Input(),
|
16085
|
+
__metadata("design:type", Boolean),
|
16086
|
+
__metadata("design:paramtypes", [Boolean])
|
16087
|
+
], GIPIRangeSliderComponent.prototype, "required", null);
|
16088
|
+
GIPIRangeSliderComponent = GIPIRangeSliderComponent_1 = __decorate([
|
16089
|
+
core.Component({
|
16090
|
+
selector: 'gipi-range-slider',
|
16091
|
+
exportAs: 'gipiRangeSlider',
|
16092
|
+
template: "<label *ngIf=\"label\"\n class=\"input-label\"\n [attr.for]=\"id\">\n {{ label }}\n <span *ngIf=\"required\"> * </span>\n</label>\n\n<div class=\"slider-wrapper\">\n <!-- <input type=\"number\"\n [min]=\"min\"\n [max]=\"max\"\n [step]=\"step\"\n [(ngModel)]=\"fromValue\"\n (ngModelChange)=\"controlFromInput(true)\"\n (input)=\"controlFromInput(false)\"\n (blur)=\"onBlur()\" /> -->\n <span class=\"value min\">\n {{ min }}\n </span>\n <div class=\"sliders-control\">\n <input #fromSlider\n id=\"fromSlider\"\n type=\"range\"\n class=\"from-value\"\n [min]=\"min\"\n [max]=\"max\"\n [value]=\"fromValue\"\n (input)=\"controlFromSlider()\"\n (mouseup)=\"controlFromSlider()\"\n (blur)=\"onBlur()\" />\n <input #toSlider\n id=\"toSlider\"\n type=\"range\"\n class=\"to-value\"\n [min]=\"min\"\n [max]=\"max\"\n [value]=\"toValue\"\n (input)=\"controlToSlider()\"\n (mouseup)=\"controlToSlider()\"\n (blur)=\"onBlur()\" />\n </div>\n <span class=\"value max\">\n {{ max }}\n </span>\n <!-- <input type=\"number\"\n [min]=\"min\"\n [max]=\"max\"\n [step]=\"step\"\n [(ngModel)]=\"toValue\"\n (ngModelChange)=\"controlToInput(true)\"\n (input)=\"controlToInput(false)\"\n (blur)=\"onBlur()\" /> -->\n</div>\n<span class=\"value min\">\n {{ fromValue }} - {{ toValue }}\n</span>\n<small *ngIf=\"help\"\n class=\"input-help\">\n {{ help }}\n</small>",
|
16093
|
+
providers: [
|
16094
|
+
{
|
16095
|
+
provide: forms.NG_VALUE_ACCESSOR,
|
16096
|
+
useExisting: core.forwardRef(function () { return GIPIRangeSliderComponent_1; }),
|
16097
|
+
multi: true
|
16098
|
+
},
|
16099
|
+
],
|
16100
|
+
host: {
|
16101
|
+
'class': 'gipi-range-slider',
|
16102
|
+
},
|
16103
|
+
changeDetection: core.ChangeDetectionStrategy.OnPush,
|
16104
|
+
styles: [":host{display:flex;flex-direction:column;gap:.8rem;font-size:1.4rem;color:#696969}:host .input-label{display:flex;align-items:center;gap:.4rem;color:#131313;line-height:1.6rem}:host .input-label>span{font-size:1.6rem;line-height:1.6rem;color:#d14014}:host .slider-wrapper{display:flex;align-items:center;justify-content:space-between;gap:1.6rem}:host .slider-wrapper>input{display:flex;font-family:inherit;font-size:inherit;color:inherit;text-align:center;padding:.75rem .8rem;background:#fff;border:1px solid rgba(0,0,0,.12);transition:background-color .2s,color .2s,border-color .2s,box-shadow .2s;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:.6rem;outline:0}:host .sliders-control{display:flex;align-items:center;justify-content:center;padding:2rem;position:relative;flex:1}:host .from-value,:host .to-value{-webkit-appearance:none;-moz-appearance:none;appearance:none;height:.6rem;border-radius:.4rem;width:100%;position:absolute;background-color:#e0e1e2;pointer-events:none;outline:0}:host .from-value::-webkit-slider-thumb,:host .to-value::-webkit-slider-thumb{-webkit-appearance:none;display:block;width:1.4rem;height:1.4rem;border-radius:50%;background-color:#e0313e;pointer-events:all;box-shadow:0 .5px 0 0 rgba(0,0,0,.08),0 1px 1px 0 rgba(0,0,0,.14);cursor:-webkit-grab;cursor:grab;outline:0}:host .from-value::-webkit-slider-thumb:hover,:host .to-value::-webkit-slider-thumb:hover{background-color:#cc2d38}:host .from-value::-webkit-slider-thumb:active,:host .to-value::-webkit-slider-thumb:active{box-shadow:inset 0 0 3px #e0313e,0 0 9px #e0313e;-webkit-box-shadow:inset 0 0 3px #e0313e,0 0 9px #e0313e;cursor:-webkit-grabbing;cursor:grabbing}:host input[type=number]{border:1px solid rgba(0,0,0,.12);color:#131313;width:50px;height:30px;font-size:20px;outline:0}:host input[type=number]::-webkit-inner-spin-button,:host input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;appearance:none;opacity:0}:host #fromSlider{height:0;z-index:1}"]
|
16105
|
+
}),
|
16106
|
+
__metadata("design:paramtypes", [core.ElementRef,
|
16107
|
+
core.ChangeDetectorRef])
|
16108
|
+
], GIPIRangeSliderComponent);
|
16109
|
+
return GIPIRangeSliderComponent;
|
16110
|
+
}());
|
16111
|
+
|
16112
|
+
var GIPISelectButtonComponent = /** @class */ (function () {
|
16113
|
+
function GIPISelectButtonComponent(_elementRef, _changeDetectorRef) {
|
16114
|
+
this._elementRef = _elementRef;
|
16115
|
+
this._changeDetectorRef = _changeDetectorRef;
|
16116
|
+
this.isButtonPrimary = this._hasHostAttributes('gipi-primary');
|
16117
|
+
this.isButtonSecondary = this._hasHostAttributes('gipi-secondary');
|
16118
|
+
this.required = false;
|
16119
|
+
this.multiple = false;
|
16120
|
+
this.disabled = false;
|
16121
|
+
this.onOptionClick = new core.EventEmitter();
|
16122
|
+
this.onChange = new core.EventEmitter();
|
16123
|
+
this.onModelChange = function () { };
|
16124
|
+
this.onModelTouched = function () { };
|
16125
|
+
}
|
16126
|
+
GIPISelectButtonComponent_1 = GIPISelectButtonComponent;
|
16127
|
+
GIPISelectButtonComponent.prototype.ngOnInit = function () { };
|
16128
|
+
GIPISelectButtonComponent.prototype.writeValue = function (obj) {
|
16129
|
+
this.value = obj;
|
16130
|
+
this._changeDetectorRef.markForCheck();
|
16131
|
+
};
|
16132
|
+
GIPISelectButtonComponent.prototype.registerOnChange = function (fn) {
|
16133
|
+
this.onModelChange = fn;
|
16134
|
+
};
|
16135
|
+
GIPISelectButtonComponent.prototype.registerOnTouched = function (fn) {
|
16136
|
+
this.onModelTouched = fn;
|
16137
|
+
};
|
16138
|
+
GIPISelectButtonComponent.prototype.setDisabledState = function (isDisabled) {
|
16139
|
+
this.disabled = isDisabled;
|
16140
|
+
this._changeDetectorRef.markForCheck();
|
16141
|
+
};
|
16142
|
+
GIPISelectButtonComponent.prototype.getOptionLabel = function (option) {
|
16143
|
+
return this.optionLabel ? ObjectUtil.resolveFieldData(option, this.optionLabel) : option.label != undefined ? option.label : option;
|
16144
|
+
};
|
16145
|
+
GIPISelectButtonComponent.prototype.getOptionValue = function (option) {
|
16146
|
+
return this.optionValue ? ObjectUtil.resolveFieldData(option, this.optionValue) : this.optionLabel || option.value === undefined ? option : option.value;
|
16147
|
+
};
|
16148
|
+
GIPISelectButtonComponent.prototype.isOptionDisabled = function (option) {
|
16149
|
+
return this.optionDisabled ? ObjectUtil.resolveFieldData(option, this.optionDisabled) : option.disabled !== undefined ? option.disabled : false;
|
16150
|
+
};
|
16151
|
+
GIPISelectButtonComponent.prototype.onItemClick = function (event, option, index) {
|
16152
|
+
if (this.disabled || this.isOptionDisabled(option)) {
|
16153
|
+
return;
|
16154
|
+
}
|
16155
|
+
if (this.multiple) {
|
16156
|
+
if (this.isSelected(option)) {
|
16157
|
+
this.removeOption(option);
|
16158
|
+
}
|
16159
|
+
else {
|
16160
|
+
this.value = __spread((this.value || []), [this.getOptionValue(option)]);
|
16161
|
+
}
|
16162
|
+
this.onModelChange(this.value);
|
16163
|
+
this.onChange.emit({
|
16164
|
+
originalEvent: event,
|
16165
|
+
value: this.value
|
16166
|
+
});
|
16167
|
+
}
|
16168
|
+
else {
|
16169
|
+
var value = this.getOptionValue(option);
|
16170
|
+
if (this.value !== value) {
|
16171
|
+
this.value = this.getOptionValue(option);
|
16172
|
+
this.onModelChange(this.value);
|
16173
|
+
this.onChange.emit({
|
16174
|
+
originalEvent: event,
|
16175
|
+
value: this.value
|
16176
|
+
});
|
16177
|
+
}
|
16178
|
+
}
|
16179
|
+
this.onOptionClick.emit({
|
16180
|
+
originalEvent: event,
|
16181
|
+
option: option,
|
16182
|
+
index: index
|
16183
|
+
});
|
16184
|
+
};
|
16185
|
+
GIPISelectButtonComponent.prototype.isSelected = function (option) {
|
16186
|
+
var e_1, _a;
|
16187
|
+
var selected = false;
|
16188
|
+
var optionValue = this.getOptionValue(option);
|
16189
|
+
if (this.multiple) {
|
16190
|
+
if (this.value && Array.isArray(this.value)) {
|
16191
|
+
try {
|
16192
|
+
for (var _b = __values(this.value), _c = _b.next(); !_c.done; _c = _b.next()) {
|
16193
|
+
var val = _c.value;
|
16194
|
+
if (ObjectUtil.equals(val, optionValue, this.dataKey)) {
|
16195
|
+
selected = true;
|
16196
|
+
break;
|
16197
|
+
}
|
16198
|
+
}
|
16199
|
+
}
|
16200
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
16201
|
+
finally {
|
16202
|
+
try {
|
16203
|
+
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
16204
|
+
}
|
16205
|
+
finally { if (e_1) throw e_1.error; }
|
16206
|
+
}
|
16207
|
+
}
|
16208
|
+
}
|
16209
|
+
else {
|
16210
|
+
selected = ObjectUtil.equals(this.getOptionValue(option), this.value, this.dataKey);
|
16211
|
+
}
|
16212
|
+
return selected;
|
16213
|
+
};
|
16214
|
+
GIPISelectButtonComponent.prototype.removeOption = function (option) {
|
16215
|
+
var _this = this;
|
16216
|
+
this.value = this.value.filter(function (val) { return !ObjectUtil.equals(val, _this.getOptionValue(option), _this.dataKey); });
|
16217
|
+
};
|
16218
|
+
GIPISelectButtonComponent.prototype.onBlur = function () {
|
16219
|
+
this.onModelTouched();
|
15572
16220
|
};
|
15573
16221
|
GIPISelectButtonComponent.prototype._getHostElement = function () {
|
15574
16222
|
return this._elementRef.nativeElement;
|
@@ -16064,8 +16712,12 @@
|
|
16064
16712
|
this._mouseEnter = false;
|
16065
16713
|
this.menuItems = [];
|
16066
16714
|
this.labelToggle = 'Retrair menu';
|
16715
|
+
this.showTagNewIntegration = false;
|
16716
|
+
this.showIntegration = false;
|
16067
16717
|
this.showConfiguration = false;
|
16068
16718
|
this.onClickMenuItem = new core.EventEmitter();
|
16719
|
+
this.onClickMenuIntegration = new core.EventEmitter();
|
16720
|
+
this.onClickMenuConfiguration = new core.EventEmitter();
|
16069
16721
|
}
|
16070
16722
|
GIPISidenavComponent_1 = GIPISidenavComponent;
|
16071
16723
|
GIPISidenavComponent.prototype.ngOnInit = function () { };
|
@@ -16255,6 +16907,26 @@
|
|
16255
16907
|
core.Input(),
|
16256
16908
|
__metadata("design:type", String)
|
16257
16909
|
], GIPISidenavComponent.prototype, "labelToggle", void 0);
|
16910
|
+
__decorate([
|
16911
|
+
core.Input(),
|
16912
|
+
__metadata("design:type", Boolean)
|
16913
|
+
], GIPISidenavComponent.prototype, "showTagNewIntegration", void 0);
|
16914
|
+
__decorate([
|
16915
|
+
core.Input(),
|
16916
|
+
__metadata("design:type", String)
|
16917
|
+
], GIPISidenavComponent.prototype, "iconIntegration", void 0);
|
16918
|
+
__decorate([
|
16919
|
+
core.Input(),
|
16920
|
+
__metadata("design:type", String)
|
16921
|
+
], GIPISidenavComponent.prototype, "svgIconIntegration", void 0);
|
16922
|
+
__decorate([
|
16923
|
+
core.Input(),
|
16924
|
+
__metadata("design:type", String)
|
16925
|
+
], GIPISidenavComponent.prototype, "labelIntegration", void 0);
|
16926
|
+
__decorate([
|
16927
|
+
core.Input(),
|
16928
|
+
__metadata("design:type", Boolean)
|
16929
|
+
], GIPISidenavComponent.prototype, "showIntegration", void 0);
|
16258
16930
|
__decorate([
|
16259
16931
|
core.Input(),
|
16260
16932
|
__metadata("design:type", String)
|
@@ -16275,11 +16947,19 @@
|
|
16275
16947
|
core.Output(),
|
16276
16948
|
__metadata("design:type", core.EventEmitter)
|
16277
16949
|
], GIPISidenavComponent.prototype, "onClickMenuItem", void 0);
|
16950
|
+
__decorate([
|
16951
|
+
core.Output(),
|
16952
|
+
__metadata("design:type", core.EventEmitter)
|
16953
|
+
], GIPISidenavComponent.prototype, "onClickMenuIntegration", void 0);
|
16954
|
+
__decorate([
|
16955
|
+
core.Output(),
|
16956
|
+
__metadata("design:type", core.EventEmitter)
|
16957
|
+
], GIPISidenavComponent.prototype, "onClickMenuConfiguration", void 0);
|
16278
16958
|
GIPISidenavComponent = GIPISidenavComponent_1 = __decorate([
|
16279
16959
|
core.Component({
|
16280
16960
|
selector: "gipi-sidenav",
|
16281
16961
|
exportAs: 'gipiSidenav',
|
16282
|
-
template: "<mat-sidenav #sidenav\n [mode]=\"(isScreenLarge | async) ? 'side' : 'over'\"\n class=\"sidenav\"\n [class.large-sidenav]=\"(isOpened | async)\"\n [class.small-sidenav]=\"!(isOpened | async)\"\n [disableClose]=\"(isScreenLarge | async)\"\n opened=\"true\">\n\n <div [ngClass]=\"{'sidenav-content-menu': true,\n 'show-
|
16962
|
+
template: "<mat-sidenav #sidenav\n [mode]=\"(isScreenLarge | async) ? 'side' : 'over'\"\n class=\"sidenav\"\n [class.large-sidenav]=\"(isOpened | async)\"\n [class.small-sidenav]=\"!(isOpened | async)\"\n [disableClose]=\"(isScreenLarge | async)\"\n opened=\"true\">\n\n <div [ngClass]=\"{'sidenav-content-menu': true,\n 'show-bottom': (showConfiguration || showIntegration)}\">\n\n <!-- Bot\u00E3o expandir e retrair o menu -->\n <button id=\"buttonToogleSidenav\"\n name=\"toggleSidenav\"\n class=\"toggle-sidenav\"\n (click)=\"toggleSidenav(); _mouseEnter = false;\">\n <mat-icon [@indicatorRotate]=\"(isOpened | async) ? 'opened': 'closed'\">\n chevron_right\n </mat-icon>\n\n {{ ((labelToggle) && (isOpened | async)) ? labelToggle : '' }}\n </button>\n\n <!-- Bot\u00E3o voltar do submenu -->\n <div class=\"sidenav-action-menu sidenav-menu-collapsable\">\n <a *ngIf=\"(isOpened | async) && (_levelOneMenuCollapsableSelected || _levelTwoMenuCollapsableSelected)\"\n (click)=\"onMenuCollapsableGoBack()\"\n (mouseenter)=\"!_mouseEnter && onMouseEnter()\"\n (mouseleave)=\"_mouseEnter && onMouseLeave()\">\n <mat-icon>\n arrow_back\n </mat-icon>\n <span>\n {{ (submenuBackButtonName | async) }}\n </span>\n </a>\n </div>\n\n <!-- Se o menu item for do tipo submenu -->\n <mat-nav-list class=\"sidenav-menu-list\"\n (mouseenter)=\"onMouseEnter()\"\n (mouseleave)=\"onMouseLeave()\">\n <div *ngFor=\"let menu of (levelMenuCollapsableSelected | async)\"\n class=\"sidenav-action-menu\">\n\n <a *ngIf=\"menu.type === 'ITEM'\"\n [routerLink]=\"menu.route\"\n [class.menu-active]=\"isMenuActive(menu)\"\n (click)=\"onMenuItemSelected(menu)\">\n <mat-icon *ngIf=\"menu.icon\">\n {{ menu.icon }}\n </mat-icon>\n <mat-icon *ngIf=\"menu.svgIcon\"\n [svgIcon]=\"menu.svgIcon\">\n </mat-icon>\n <span *ngIf=\"(isOpened | async)\">\n {{ getMenuName(menu.name) }}\n </span>\n </a>\n\n <a *ngIf=\"menu.type === 'COLLAPSABLE'\"\n [class.menu-active]=\"isMenuCollapsableActive(menu)\"\n (click)=\"onMenuCollapsableSelected(menu); onMenuItemSelected(menu, false)\">\n <mat-icon *ngIf=\"menu.icon\">\n {{ menu.icon }}\n </mat-icon>\n <mat-icon *ngIf=\"menu.svgIcon\"\n [svgIcon]=\"menu.svgIcon\">\n </mat-icon>\n <span *ngIf=\"(isOpened | async)\">\n {{ getMenuName(menu.name) }}\n </span>\n <mat-icon *ngIf=\"(isOpened | async)\">\n chevron_right\n </mat-icon>\n </a>\n\n </div>\n </mat-nav-list>\n </div>\n\n <div class=\"sidenav-action-menu sidenav-bottom-menu\">\n <a *ngIf=\"showIntegration\"\n (click)=\"onMenuItemSelected(null); onClickMenuIntegration.emit()\">\n <mat-icon *ngIf=\"iconIntegration\">\n {{ iconIntegration }}\n </mat-icon>\n <mat-icon *ngIf=\"svgIconIntegration\"\n [svgIcon]=\"svgIconIntegration\">\n </mat-icon>\n <span *ngIf=\"(labelIntegration) && (isOpened | async)\">\n {{ labelIntegration }}\n </span>\n <div class=\"tag-new\"\n *ngIf=\"showTagNewIntegration\">\n Novo\n </div>\n </a>\n\n <a *ngIf=\"showConfiguration\"\n (click)=\"onMenuItemSelected(null); onClickMenuConfiguration.emit()\">\n <mat-icon *ngIf=\"iconConfiguration\">\n {{ iconConfiguration }}\n </mat-icon>\n <mat-icon *ngIf=\"svgIconConfiguration\"\n [svgIcon]=\"svgIconConfiguration\">\n </mat-icon>\n <span *ngIf=\"(labelConfiguration) && (isOpened | async)\">\n {{ labelConfiguration }}\n </span>\n </a>\n </div>\n</mat-sidenav>\n",
|
16283
16963
|
encapsulation: core.ViewEncapsulation.None,
|
16284
16964
|
providers: [
|
16285
16965
|
{
|
@@ -16298,7 +16978,7 @@
|
|
16298
16978
|
animations.transition('expanded <=> collapsed', animations.animate('225ms cubic-bezier(0.4,0.0,0.2,1)')),
|
16299
16979
|
])
|
16300
16980
|
],
|
16301
|
-
styles: [".sidenav{padding:.8rem 1.2rem;border-radius:5px;background-color:#fff;position:fixed!important;top:66px!important;bottom:8px!important;border:0!important}.sidenav.small-sidenav{overflow-y:auto;width:76px}.sidenav.small-sidenav .sidenav-
|
16981
|
+
styles: [".sidenav{padding:.8rem 1.2rem;border-radius:5px;background-color:#fff;position:fixed!important;top:66px!important;bottom:8px!important;border:0!important}.sidenav.small-sidenav{overflow-y:auto;width:76px}.sidenav.small-sidenav .sidenav-bottom-menu,.sidenav.small-sidenav .sidenav-content-menu .sidenav-menu-list .action-sidenav,.sidenav.small-sidenav .sidenav-content-menu .toggle-sidenav{text-align:center!important}.sidenav.large-sidenav{overflow-y:auto;width:248px}.sidenav .sidenav-content-menu{width:100%;background-color:#f5f5f6;border-radius:4px;display:flex;flex-direction:column;align-items:stretch;height:100%}.sidenav .sidenav-content-menu.show-bottom{height:calc(100% - 18px - 52px)!important}.sidenav .sidenav-content-menu .toggle-sidenav{all:unset;border-radius:4px;border:none;text-align:left;cursor:pointer;background-color:#e0313e;color:#fff;display:flex;align-items:center;gap:8px;padding:10px 16px}.sidenav .sidenav-content-menu .toggle-sidenav>mat-icon{width:2rem;height:2rem;font-size:2rem}.sidenav .sidenav-content-menu .toggle-sidenav:hover{background-color:#cc2d38}.sidenav .sidenav-content-menu .sidenav-menu-list{overflow-y:scroll;-ms-overflow-style:none;scrollbar-width:none;border-bottom-left-radius:4px;border-bottom-right-radius:4px}.sidenav .sidenav-content-menu .sidenav-menu-list::-webkit-scrollbar{display:none}.menu-active{color:#e0313e!important;background-color:#e0e1e2!important}.menu-active>mat-icon,.menu-active>mat-icon svg,.menu-active>mat-icon svg path{color:#e0313e!important;fill:#e0313e!important}.sidenav-action-menu{cursor:pointer;display:flex}.sidenav-action-menu.sidenav-bottom-menu{flex-direction:column;gap:1rem;margin-top:1rem}.sidenav-action-menu a{flex:1;padding:16px;background-color:#f5f5f6;display:flex;align-items:center;gap:8px;cursor:pointer;font-size:1.4rem;font-weight:600}.sidenav-action-menu a:hover{background-color:#e0e1e2}.sidenav-action-menu a>span{flex:1;line-height:2rem}.sidenav-action-menu a>mat-icon{width:2rem;height:2rem;font-size:2rem;line-height:2rem;color:#595959;fill:#595959}.sidenav-action-menu a>mat-icon svg,.sidenav-action-menu a>mat-icon svg path{color:#595959;fill:#595959}.sidenav-bottom-menu a{border-radius:4px}.sidenav-menu-collapsable a{background-color:#e0e1e2}.sidenav-menu-collapsable a:hover{background-color:#d1d2d4}.mat-list-base{padding-top:0!important}.mat-drawer-inner-container{display:flex;flex-direction:column;align-items:stretch;justify-content:space-between;overflow:hidden!important}.mat-drawer:not(.mat-drawer-side){box-shadow:none!important}.tag-new{display:flex;align-items:center;justify-content:center;background-color:#e0313e;color:#fff;padding:.2rem .6rem;font-size:1rem;line-height:1.2rem;border-radius:.4rem}"]
|
16302
16982
|
}),
|
16303
16983
|
__metadata("design:paramtypes", [NavService,
|
16304
16984
|
BreakpointObserverService,
|
@@ -16307,6 +16987,128 @@
|
|
16307
16987
|
return GIPISidenavComponent;
|
16308
16988
|
}());
|
16309
16989
|
|
16990
|
+
var nextUniqueId$h = 0;
|
16991
|
+
var GIPISlideToggleComponent = /** @class */ (function () {
|
16992
|
+
function GIPISlideToggleComponent(_changeDetectorRef) {
|
16993
|
+
this._changeDetectorRef = _changeDetectorRef;
|
16994
|
+
this._name = "gipi-slide-toggle-" + nextUniqueId$h++;
|
16995
|
+
this._slideToggleValue = false;
|
16996
|
+
this.id = this._name;
|
16997
|
+
this.name = this._name;
|
16998
|
+
this.label = '';
|
16999
|
+
this.help = '';
|
17000
|
+
this._required = false;
|
17001
|
+
this._disabled = false;
|
17002
|
+
this.onChange = function () { };
|
17003
|
+
this.onTouched = function () { };
|
17004
|
+
}
|
17005
|
+
GIPISlideToggleComponent_1 = GIPISlideToggleComponent;
|
17006
|
+
Object.defineProperty(GIPISlideToggleComponent.prototype, "slideToggleValue", {
|
17007
|
+
get: function () {
|
17008
|
+
return this._slideToggleValue;
|
17009
|
+
},
|
17010
|
+
set: function (value) {
|
17011
|
+
this._slideToggleValue = value;
|
17012
|
+
this.onChange(value);
|
17013
|
+
this.onTouched();
|
17014
|
+
},
|
17015
|
+
enumerable: false,
|
17016
|
+
configurable: true
|
17017
|
+
});
|
17018
|
+
Object.defineProperty(GIPISlideToggleComponent.prototype, "required", {
|
17019
|
+
get: function () {
|
17020
|
+
return this._required;
|
17021
|
+
},
|
17022
|
+
set: function (value) {
|
17023
|
+
if (this.required !== value) {
|
17024
|
+
this._required = coercion.coerceBooleanProperty(value);
|
17025
|
+
this._changeDetectorRef.markForCheck();
|
17026
|
+
}
|
17027
|
+
},
|
17028
|
+
enumerable: false,
|
17029
|
+
configurable: true
|
17030
|
+
});
|
17031
|
+
Object.defineProperty(GIPISlideToggleComponent.prototype, "disabled", {
|
17032
|
+
get: function () {
|
17033
|
+
return this._disabled;
|
17034
|
+
},
|
17035
|
+
set: function (value) {
|
17036
|
+
if (this.disabled !== value) {
|
17037
|
+
this._disabled = coercion.coerceBooleanProperty(value);
|
17038
|
+
this._changeDetectorRef.markForCheck();
|
17039
|
+
}
|
17040
|
+
},
|
17041
|
+
enumerable: false,
|
17042
|
+
configurable: true
|
17043
|
+
});
|
17044
|
+
GIPISlideToggleComponent.prototype.ngOnInit = function () { };
|
17045
|
+
GIPISlideToggleComponent.prototype.writeValue = function (value) {
|
17046
|
+
this.slideToggleValue = value;
|
17047
|
+
this._changeDetectorRef.markForCheck();
|
17048
|
+
};
|
17049
|
+
GIPISlideToggleComponent.prototype.registerOnChange = function (fn) {
|
17050
|
+
this.onChange = fn;
|
17051
|
+
};
|
17052
|
+
GIPISlideToggleComponent.prototype.registerOnTouched = function (fn) {
|
17053
|
+
this.onTouched = fn;
|
17054
|
+
};
|
17055
|
+
GIPISlideToggleComponent.prototype.setDisabledState = function (isDisabled) {
|
17056
|
+
this.disabled = isDisabled;
|
17057
|
+
this._changeDetectorRef.markForCheck();
|
17058
|
+
};
|
17059
|
+
var GIPISlideToggleComponent_1;
|
17060
|
+
GIPISlideToggleComponent.ctorParameters = function () { return [
|
17061
|
+
{ type: core.ChangeDetectorRef }
|
17062
|
+
]; };
|
17063
|
+
__decorate([
|
17064
|
+
core.Input(),
|
17065
|
+
__metadata("design:type", String)
|
17066
|
+
], GIPISlideToggleComponent.prototype, "id", void 0);
|
17067
|
+
__decorate([
|
17068
|
+
core.Input(),
|
17069
|
+
__metadata("design:type", String)
|
17070
|
+
], GIPISlideToggleComponent.prototype, "name", void 0);
|
17071
|
+
__decorate([
|
17072
|
+
core.Input(),
|
17073
|
+
__metadata("design:type", String)
|
17074
|
+
], GIPISlideToggleComponent.prototype, "label", void 0);
|
17075
|
+
__decorate([
|
17076
|
+
core.Input(),
|
17077
|
+
__metadata("design:type", String)
|
17078
|
+
], GIPISlideToggleComponent.prototype, "help", void 0);
|
17079
|
+
__decorate([
|
17080
|
+
core.Input(),
|
17081
|
+
__metadata("design:type", Boolean),
|
17082
|
+
__metadata("design:paramtypes", [Boolean])
|
17083
|
+
], GIPISlideToggleComponent.prototype, "required", null);
|
17084
|
+
__decorate([
|
17085
|
+
core.Input(),
|
17086
|
+
__metadata("design:type", Boolean),
|
17087
|
+
__metadata("design:paramtypes", [Boolean])
|
17088
|
+
], GIPISlideToggleComponent.prototype, "disabled", null);
|
17089
|
+
GIPISlideToggleComponent = GIPISlideToggleComponent_1 = __decorate([
|
17090
|
+
core.Component({
|
17091
|
+
selector: 'gipi-slide-toggle',
|
17092
|
+
exportAs: 'gipiSlideToggle',
|
17093
|
+
template: "<input class=\"toggle toggle-light\"\n type=\"checkbox\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [(ngModel)]=\"slideToggleValue\" />\n<label class=\"toggle-btn\"\n [attr.for]=\"id\">\n</label>\n<label class=\"toggle-label\"\n *ngIf=\"label\"\n [attr.for]=\"id\">\n {{ label }}\n</label>",
|
17094
|
+
providers: [
|
17095
|
+
{
|
17096
|
+
provide: forms.NG_VALUE_ACCESSOR,
|
17097
|
+
useExisting: core.forwardRef(function () { return GIPISlideToggleComponent_1; }),
|
17098
|
+
multi: true,
|
17099
|
+
},
|
17100
|
+
],
|
17101
|
+
changeDetection: core.ChangeDetectionStrategy.OnPush,
|
17102
|
+
host: {
|
17103
|
+
'class': 'gipi-slide-toggle',
|
17104
|
+
},
|
17105
|
+
styles: [":host{display:flex;align-items:center;cursor:pointer}.toggle-label{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;margin-left:1rem;cursor:pointer}.toggle{display:none}.toggle ::-moz-selection,.toggle :after::-moz-selection,.toggle :before::-moz-selection,.toggle+.toggle-btn::-moz-selection,.toggle::-moz-selection,.toggle:after::-moz-selection,.toggle:before::-moz-selection{background:0 0}.toggle ::selection,.toggle :after::selection,.toggle :before::selection,.toggle+.toggle-btn::selection,.toggle::selection,.toggle:after::selection,.toggle:before::selection{background:0 0}.toggle+.toggle-btn{display:block;width:40px;height:24px;outline:0;background:#e0e1e2;border-radius:22px;padding:4px;transition:.4s;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer}.toggle+.toggle-btn:after,.toggle+.toggle-btn:before{content:\"\";display:block;width:16px;height:16px;position:relative}.toggle+.toggle-btn:after{left:0;background:#8c8f93;border-radius:50%;transition:.2s}.toggle+.toggle-btn:before{display:none}.toggle:checked+.toggle-btn:after{left:50%;background:#414244}"]
|
17106
|
+
}),
|
17107
|
+
__metadata("design:paramtypes", [core.ChangeDetectorRef])
|
17108
|
+
], GIPISlideToggleComponent);
|
17109
|
+
return GIPISlideToggleComponent;
|
17110
|
+
}());
|
17111
|
+
|
16310
17112
|
var GIPIStepperComponent = /** @class */ (function (_super) {
|
16311
17113
|
__extends(GIPIStepperComponent, _super);
|
16312
17114
|
function GIPIStepperComponent() {
|
@@ -17022,34 +17824,232 @@
|
|
17022
17824
|
__metadata("design:type", Boolean)
|
17023
17825
|
], GIPITableComponent.prototype, "tableShowBorder", void 0);
|
17024
17826
|
__decorate([
|
17025
|
-
core.Input(),
|
17026
|
-
__metadata("design:type", Boolean)
|
17027
|
-
], GIPITableComponent.prototype, "hideHeader", void 0);
|
17827
|
+
core.Input(),
|
17828
|
+
__metadata("design:type", Boolean)
|
17829
|
+
], GIPITableComponent.prototype, "hideHeader", void 0);
|
17830
|
+
__decorate([
|
17831
|
+
core.Input(),
|
17832
|
+
__metadata("design:type", Boolean)
|
17833
|
+
], GIPITableComponent.prototype, "hideFooter", void 0);
|
17834
|
+
GIPITableComponent = GIPITableComponent_1 = __decorate([
|
17835
|
+
core.Component({
|
17836
|
+
selector: "gipi-table",
|
17837
|
+
exportAs: 'gipiTable',
|
17838
|
+
template: "<div role=\"table\"\n class=\"table\">\n <gipi-table-header [columns]=\"columns\"\n [loading]=\"loading\"\n [disabled]=\"disabled\"\n [sortActive]=\"sortActive\"\n [sortStart]=\"sortStart\"\n [sortLocked]=\"sortLocked\"\n [sortDisableClear]=\"sortDisableClear\"\n [sortAscendingIcon]=\"sortAscendingIcon\"\n [sortDescendingIcon]=\"sortDescendingIcon\"\n [sortUnsetIcon]=\"sortUnsetIcon\"\n (sortChange)=\"sortChange.emit($event)\">\n </gipi-table-header>\n <gipi-table-body [columns]=\"columns\"\n [loading]=\"loading\"\n [loadingDetail]=\"loadingDetail\"\n [disabled]=\"disabled\"\n [clickOnRow]=\"clickOnRow\"\n [expandable]=\"expandable\"\n [expandOnlyOneRow]=\"expandOnlyOneRow\"\n [rowExpandableFn]=\"rowExpandableFn\"\n [highlightRowFn]=\"highlightRowFn\"\n [trackBy]=\"trackBy\"\n [rowDetailRef]=\"rowDetailRef\"\n [rows]=\"rows\"\n (rowsExpandedChange)=\"rowsExpandedChange.emit($event)\"\n (rowDetailToggleChange)=\"rowDetailToggleChange.emit($event)\">\n </gipi-table-body>\n</div>",
|
17839
|
+
providers: [
|
17840
|
+
{
|
17841
|
+
provide: forms.NG_VALUE_ACCESSOR,
|
17842
|
+
useExisting: core.forwardRef(function () { return GIPITableComponent_1; }),
|
17843
|
+
multi: true
|
17844
|
+
}
|
17845
|
+
],
|
17846
|
+
host: {
|
17847
|
+
'class': 'gipi-table',
|
17848
|
+
},
|
17849
|
+
changeDetection: core.ChangeDetectionStrategy.OnPush,
|
17850
|
+
styles: [".table{border:1px solid #e0e1e2;border-radius:4px}"]
|
17851
|
+
}),
|
17852
|
+
__metadata("design:paramtypes", [])
|
17853
|
+
], GIPITableComponent);
|
17854
|
+
return GIPITableComponent;
|
17855
|
+
}());
|
17856
|
+
|
17857
|
+
var TabModel = /** @class */ (function () {
|
17858
|
+
function TabModel() {
|
17859
|
+
this.active = false;
|
17860
|
+
this.closeable = false;
|
17861
|
+
this.disabled = false;
|
17862
|
+
}
|
17863
|
+
return TabModel;
|
17864
|
+
}());
|
17865
|
+
|
17866
|
+
var GIPITabComponent = /** @class */ (function () {
|
17867
|
+
function GIPITabComponent() {
|
17868
|
+
this.active = false;
|
17869
|
+
this.closeable = false;
|
17870
|
+
this.disabled = false;
|
17871
|
+
this.selectionChange = new core.EventEmitter();
|
17872
|
+
}
|
17873
|
+
GIPITabComponent.prototype.ngOnInit = function () { };
|
17874
|
+
__decorate([
|
17875
|
+
core.Input(),
|
17876
|
+
__metadata("design:type", Number)
|
17877
|
+
], GIPITabComponent.prototype, "index", void 0);
|
17878
|
+
__decorate([
|
17879
|
+
core.Input(),
|
17880
|
+
__metadata("design:type", String)
|
17881
|
+
], GIPITabComponent.prototype, "label", void 0);
|
17882
|
+
__decorate([
|
17883
|
+
core.Input(),
|
17884
|
+
__metadata("design:type", Boolean)
|
17885
|
+
], GIPITabComponent.prototype, "active", void 0);
|
17886
|
+
__decorate([
|
17887
|
+
core.Input(),
|
17888
|
+
__metadata("design:type", core.TemplateRef)
|
17889
|
+
], GIPITabComponent.prototype, "template", void 0);
|
17890
|
+
__decorate([
|
17891
|
+
core.Input(),
|
17892
|
+
__metadata("design:type", Boolean)
|
17893
|
+
], GIPITabComponent.prototype, "closeable", void 0);
|
17894
|
+
__decorate([
|
17895
|
+
core.Input(),
|
17896
|
+
__metadata("design:type", Boolean)
|
17897
|
+
], GIPITabComponent.prototype, "disabled", void 0);
|
17898
|
+
__decorate([
|
17899
|
+
core.Input(),
|
17900
|
+
__metadata("design:type", Object)
|
17901
|
+
], GIPITabComponent.prototype, "data", void 0);
|
17902
|
+
__decorate([
|
17903
|
+
core.Input(),
|
17904
|
+
__metadata("design:type", String)
|
17905
|
+
], GIPITabComponent.prototype, "icon", void 0);
|
17906
|
+
__decorate([
|
17907
|
+
core.Input(),
|
17908
|
+
__metadata("design:type", String)
|
17909
|
+
], GIPITabComponent.prototype, "svgIcon", void 0);
|
17910
|
+
__decorate([
|
17911
|
+
core.Output(),
|
17912
|
+
__metadata("design:type", core.EventEmitter)
|
17913
|
+
], GIPITabComponent.prototype, "selectionChange", void 0);
|
17914
|
+
GIPITabComponent = __decorate([
|
17915
|
+
core.Component({
|
17916
|
+
selector: 'gipi-tab',
|
17917
|
+
exportAs: 'gipiTab',
|
17918
|
+
template: "<ng-container *ngIf=\"active\">\n <ng-content> </ng-content>\n <ng-container *ngIf=\"template\"\n [ngTemplateOutlet]=\"template\"\n [ngTemplateOutletContext]=\"{$implicit: data}\">\n </ng-container>\n</ng-container>",
|
17919
|
+
host: {
|
17920
|
+
'class': 'gipi-tab',
|
17921
|
+
'[style.display]': '!active ? "none" : "block"',
|
17922
|
+
},
|
17923
|
+
styles: [":host{padding:1.6rem}"]
|
17924
|
+
}),
|
17925
|
+
__metadata("design:paramtypes", [])
|
17926
|
+
], GIPITabComponent);
|
17927
|
+
return GIPITabComponent;
|
17928
|
+
}());
|
17929
|
+
|
17930
|
+
var GIPITabGroupComponent = /** @class */ (function () {
|
17931
|
+
function GIPITabGroupComponent(elementRef, _componentFactoryResolver) {
|
17932
|
+
this.elementRef = elementRef;
|
17933
|
+
this._componentFactoryResolver = _componentFactoryResolver;
|
17934
|
+
this.dynamicTabs = [];
|
17935
|
+
}
|
17936
|
+
GIPITabGroupComponent.prototype.ngOnInit = function () { };
|
17937
|
+
GIPITabGroupComponent.prototype.ngAfterContentInit = function () {
|
17938
|
+
var activeTabs = this.tabQueryList.filter(function (tab) { return tab.active; });
|
17939
|
+
if (activeTabs.length === 0 && this.tabQueryList.length > 0) {
|
17940
|
+
this.selectTab(this.tabQueryList.first);
|
17941
|
+
}
|
17942
|
+
};
|
17943
|
+
GIPITabGroupComponent.prototype.openTab = function (label, template, data, closeable, disabled, action) {
|
17944
|
+
if (closeable === void 0) { closeable = false; }
|
17945
|
+
if (disabled === void 0) { disabled = false; }
|
17946
|
+
var tab = new TabModel();
|
17947
|
+
tab.label = label;
|
17948
|
+
tab.template = template;
|
17949
|
+
tab.data = data;
|
17950
|
+
tab.closeable = closeable;
|
17951
|
+
tab.disabled = disabled;
|
17952
|
+
tab.action = action;
|
17953
|
+
this._openTabs(Array(tab));
|
17954
|
+
};
|
17955
|
+
GIPITabGroupComponent.prototype._openTabs = function (tabList) {
|
17956
|
+
var _a;
|
17957
|
+
var _this = this;
|
17958
|
+
var tabsComponent = tabList.map(function (tab) { return _this._getTabComponent(tab.label, tab.template, tab.data, tab.closeable, tab.disabled, tab.action); });
|
17959
|
+
(_a = this.dynamicTabs).push.apply(_a, __spread(tabsComponent));
|
17960
|
+
this.selectTab(this.dynamicTabs[0]);
|
17961
|
+
};
|
17962
|
+
GIPITabGroupComponent.prototype._getTabComponent = function (label, template, data, closeable, disabled, action) {
|
17963
|
+
if (closeable === void 0) { closeable = false; }
|
17964
|
+
if (disabled === void 0) { disabled = false; }
|
17965
|
+
var componentFactory = this._componentFactoryResolver.resolveComponentFactory(GIPITabComponent);
|
17966
|
+
var componentRef = this.dynamicTabPlaceholder.viewContainer.createComponent(componentFactory);
|
17967
|
+
var instance = componentRef.instance;
|
17968
|
+
instance.label = label;
|
17969
|
+
instance.template = template;
|
17970
|
+
instance.data = data;
|
17971
|
+
instance.closeable = closeable;
|
17972
|
+
instance.disabled = disabled;
|
17973
|
+
instance.action = action;
|
17974
|
+
return componentRef.instance;
|
17975
|
+
};
|
17976
|
+
GIPITabGroupComponent.prototype.selectTab = function (tab) {
|
17977
|
+
this.tabQueryList.toArray().forEach(function (t) { return (t.active = false); });
|
17978
|
+
this.dynamicTabs.forEach(function (t) { return (t.active = false); });
|
17979
|
+
tab.active = true;
|
17980
|
+
tab.selectionChange.emit();
|
17981
|
+
if (tab.action) {
|
17982
|
+
tab.action(tab.data);
|
17983
|
+
}
|
17984
|
+
};
|
17985
|
+
GIPITabGroupComponent.prototype.closeTab = function (tab) {
|
17986
|
+
var index = this.dynamicTabs.indexOf(tab);
|
17987
|
+
this.dynamicTabs.splice(index, 1);
|
17988
|
+
var viewContainerRef = this.dynamicTabPlaceholder.viewContainer;
|
17989
|
+
viewContainerRef.remove(index);
|
17990
|
+
if (this.tabQueryList.length > 0) {
|
17991
|
+
this.selectTab(this.tabQueryList.first);
|
17992
|
+
}
|
17993
|
+
};
|
17994
|
+
GIPITabGroupComponent.prototype.closeActiveTab = function () {
|
17995
|
+
var activeTabs = this.dynamicTabs.filter(function (tab) { return tab.active; });
|
17996
|
+
if (activeTabs.length > 0) {
|
17997
|
+
this.closeTab(activeTabs[0]);
|
17998
|
+
}
|
17999
|
+
};
|
18000
|
+
GIPITabGroupComponent.prototype.closeAllTabs = function () {
|
18001
|
+
var _this = this;
|
18002
|
+
var tabs = Object.assign([], this.dynamicTabs);
|
18003
|
+
if (tabs.length > 0) {
|
18004
|
+
tabs.forEach(function (tab) { return _this.closeTab(tab); });
|
18005
|
+
}
|
18006
|
+
};
|
18007
|
+
GIPITabGroupComponent.prototype.nextTab = function () {
|
18008
|
+
var currentTab = this.tabQueryList.toArray().find(function (tab) { return tab.active; });
|
18009
|
+
var nextTab = this.tabQueryList.toArray()[this.tabQueryList.toArray().indexOf(currentTab) + 1];
|
18010
|
+
if (nextTab != null) {
|
18011
|
+
this.tabQueryList.toArray().forEach(function (t) { return (t.active = false); });
|
18012
|
+
this.dynamicTabs.forEach(function (t) { return (t.active = false); });
|
18013
|
+
nextTab.active = true;
|
18014
|
+
nextTab.selectionChange.emit();
|
18015
|
+
}
|
18016
|
+
};
|
18017
|
+
GIPITabGroupComponent.prototype.previousTab = function () {
|
18018
|
+
var currentTab = this.tabQueryList.toArray().find(function (tab) { return tab.active; });
|
18019
|
+
var previousTab = this.tabQueryList.toArray()[this.tabQueryList.toArray().indexOf(currentTab) - 1];
|
18020
|
+
if (previousTab != null) {
|
18021
|
+
this.tabQueryList.toArray().forEach(function (t) { return (t.active = false); });
|
18022
|
+
this.dynamicTabs.forEach(function (t) { return (t.active = false); });
|
18023
|
+
previousTab.active = true;
|
18024
|
+
previousTab.selectionChange.emit();
|
18025
|
+
}
|
18026
|
+
};
|
18027
|
+
GIPITabGroupComponent.ctorParameters = function () { return [
|
18028
|
+
{ type: core.ElementRef },
|
18029
|
+
{ type: core.ComponentFactoryResolver }
|
18030
|
+
]; };
|
18031
|
+
__decorate([
|
18032
|
+
core.ContentChildren(GIPITabComponent),
|
18033
|
+
__metadata("design:type", core.QueryList)
|
18034
|
+
], GIPITabGroupComponent.prototype, "tabQueryList", void 0);
|
17028
18035
|
__decorate([
|
17029
|
-
core.
|
17030
|
-
__metadata("design:type",
|
17031
|
-
],
|
17032
|
-
|
18036
|
+
core.ViewChild(GIPIDynamicTabDirective, { static: false }),
|
18037
|
+
__metadata("design:type", GIPIDynamicTabDirective)
|
18038
|
+
], GIPITabGroupComponent.prototype, "dynamicTabPlaceholder", void 0);
|
18039
|
+
GIPITabGroupComponent = __decorate([
|
17033
18040
|
core.Component({
|
17034
|
-
selector:
|
17035
|
-
exportAs: '
|
17036
|
-
template: "<
|
17037
|
-
providers: [
|
17038
|
-
{
|
17039
|
-
provide: forms.NG_VALUE_ACCESSOR,
|
17040
|
-
useExisting: core.forwardRef(function () { return GIPITableComponent_1; }),
|
17041
|
-
multi: true
|
17042
|
-
}
|
17043
|
-
],
|
18041
|
+
selector: 'gipi-tab-group',
|
18042
|
+
exportAs: 'gipiTabGroup',
|
18043
|
+
template: "<nav mat-tab-nav-bar>\n <a mat-tab-link\n *ngFor=\"let tab of tabQueryList\"\n (click)=\"selectTab(tab)\"\n [class.active]=\"tab.active\"\n [disabled]=\"tab.disabled\">\n <mat-icon *ngIf=\"tab.icon || tab.svgIcon\"\n [svgIcon]=\"tab.svgIcon ? tab.svgIcon : ''\">\n {{ !tab.svgIcon && tab.icon ? tab.icon : '' }}\n </mat-icon>\n\n {{ tab.label }}\n </a>\n\n <a mat-tab-link\n *ngFor=\"let tab of dynamicTabs\"\n (click)=\"selectTab(tab)\"\n [class.active]=\"tab.active\"\n [disabled]=\"tab.disabled\">\n <mat-icon *ngIf=\"tab.icon || tab.svgIcon\"\n [svgIcon]=\"tab.svgIcon ? tab.svgIcon : ''\">\n {{ !tab.svgIcon && tab.icon ? tab.icon : '' }}\n </mat-icon>\n\n {{ tab.label }}\n </a>\n</nav>\n\n<ng-content> </ng-content>\n<ng-template dynamicTab\n #container>\n</ng-template>",
|
17044
18044
|
host: {
|
17045
|
-
'class': 'gipi-
|
18045
|
+
'class': 'gipi-tab-group',
|
17046
18046
|
},
|
17047
|
-
|
17048
|
-
styles: [".table{border:1px solid #e0e1e2;border-radius:4px}"]
|
18047
|
+
styles: [":host{display:block;flex:1;width:100%;box-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1)}:host ::ng-deep .mat-tab-nav-bar{background:#f5f5f6;border:none;border-radius:.4rem;padding:.4rem;box-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1)}:host ::ng-deep .mat-tab-links{display:flex;gap:1rem}:host ::ng-deep .mat-tab-link{height:auto!important;padding:1rem!important;opacity:1!important;border:none!important;border-radius:4px!important;transition:.2s!important;color:#595959!important;gap:1rem}:host ::ng-deep .mat-tab-link>mat-icon{width:2rem!important;height:2rem!important;font-size:2rem!important;color:#595959!important}:host ::ng-deep .mat-tab-link>mat-icon svg,:host ::ng-deep .mat-tab-link>mat-icon svg g path,:host ::ng-deep .mat-tab-link>mat-icon svg path{color:#595959!important;fill:#595959!important}:host ::ng-deep .mat-tab-link:not(.active):hover{background:#e0e1e2!important}:host ::ng-deep .mat-tab-link.active{background:#e0313e!important;color:#fff!important}:host ::ng-deep .mat-tab-link.active>mat-icon{color:#fff!important}:host ::ng-deep .mat-tab-link.active>mat-icon svg,:host ::ng-deep .mat-tab-link.active>mat-icon svg g path,:host ::ng-deep .mat-tab-link.active>mat-icon svg path{color:#fff!important;fill:#fff!important}:host ::ng-deep .mat-tab-link:disabled,:host ::ng-deep .mat-tab-link:disabled>mat-icon{color:#9a9da2!important;fill:#9a9da2!important}:host ::ng-deep .mat-tab-link:disabled svg,:host ::ng-deep .mat-tab-link:disabled svg g path,:host ::ng-deep .mat-tab-link:disabled svg path,:host ::ng-deep .mat-tab-link:disabled>mat-icon svg,:host ::ng-deep .mat-tab-link:disabled>mat-icon svg g path,:host ::ng-deep .mat-tab-link:disabled>mat-icon svg path{color:#9a9da2!important;fill:#9a9da2!important}:host ::ng-deep .mat-ink-bar{display:none!important}"]
|
17049
18048
|
}),
|
17050
|
-
__metadata("design:paramtypes", [
|
17051
|
-
|
17052
|
-
|
18049
|
+
__metadata("design:paramtypes", [core.ElementRef,
|
18050
|
+
core.ComponentFactoryResolver])
|
18051
|
+
], GIPITabGroupComponent);
|
18052
|
+
return GIPITabGroupComponent;
|
17053
18053
|
}());
|
17054
18054
|
|
17055
18055
|
var GIPIToolbarComponent = /** @class */ (function () {
|
@@ -17139,34 +18139,6 @@
|
|
17139
18139
|
return GIPITopNavComponent;
|
17140
18140
|
}());
|
17141
18141
|
|
17142
|
-
/** @dynamic */
|
17143
|
-
var NumberUtil = /** @class */ (function () {
|
17144
|
-
function NumberUtil() {
|
17145
|
-
}
|
17146
|
-
NumberUtil.isPositive = function (value) {
|
17147
|
-
return !ObjectUtil.isNull(value) && value > 0;
|
17148
|
-
};
|
17149
|
-
NumberUtil.isNegative = function (value) {
|
17150
|
-
return !ObjectUtil.isNull(value) && value < 0;
|
17151
|
-
};
|
17152
|
-
NumberUtil.format = function (value, digitsInfo, type) {
|
17153
|
-
if (!ObjectUtil.isNull(value) && (!type || type === 'NUMBER')) {
|
17154
|
-
return common.formatNumber(value, 'pt', digitsInfo);
|
17155
|
-
}
|
17156
|
-
else if (!ObjectUtil.isNull(value) && type === 'PERCENT') {
|
17157
|
-
return common.formatPercent(value / 100, 'pt', digitsInfo);
|
17158
|
-
}
|
17159
|
-
return StringUtil.EMPTY;
|
17160
|
-
};
|
17161
|
-
NumberUtil.onlyNumbers = function (value) {
|
17162
|
-
return String(value).replace(/[^\d]/g, '');
|
17163
|
-
};
|
17164
|
-
NumberUtil.isNumber = function (value) {
|
17165
|
-
return value !== null && value !== undefined && !isNaN(value) && typeof value === 'number';
|
17166
|
-
};
|
17167
|
-
return NumberUtil;
|
17168
|
-
}());
|
17169
|
-
|
17170
18142
|
var moment = moment_;
|
17171
18143
|
/** @dynamic */
|
17172
18144
|
var DateUtil = /** @class */ (function () {
|
@@ -21192,7 +22164,7 @@
|
|
21192
22164
|
* Use of this source code is governed by an MIT-style license that can be
|
21193
22165
|
* found in the LICENSE file at https://angular.io/license
|
21194
22166
|
*/
|
21195
|
-
var nextUniqueId$
|
22167
|
+
var nextUniqueId$i = 0;
|
21196
22168
|
var MatDateRangeInput = /** @class */ (function () {
|
21197
22169
|
function MatDateRangeInput(_changeDetectorRef, _elementRef, control, _dateAdapter, _formField) {
|
21198
22170
|
this._changeDetectorRef = _changeDetectorRef;
|
@@ -21200,7 +22172,7 @@
|
|
21200
22172
|
this._dateAdapter = _dateAdapter;
|
21201
22173
|
this._formField = _formField;
|
21202
22174
|
/** Unique ID for the input. */
|
21203
|
-
this.id = "mat-date-range-input-" + nextUniqueId$
|
22175
|
+
this.id = "mat-date-range-input-" + nextUniqueId$i++;
|
21204
22176
|
/** Whether the control is focused. */
|
21205
22177
|
this.focused = false;
|
21206
22178
|
/** Name of the form control. */
|
@@ -22775,12 +23747,12 @@
|
|
22775
23747
|
}());
|
22776
23748
|
|
22777
23749
|
var moment$3 = moment_;
|
22778
|
-
var nextUniqueId$
|
23750
|
+
var nextUniqueId$k = 0;
|
22779
23751
|
var DatepickerComponent = /** @class */ (function () {
|
22780
23752
|
function DatepickerComponent(elementRef, _changeDetectorRef) {
|
22781
23753
|
this.elementRef = elementRef;
|
22782
23754
|
this._changeDetectorRef = _changeDetectorRef;
|
22783
|
-
this._name = "gipi-date-range-" + nextUniqueId$
|
23755
|
+
this._name = "gipi-date-range-" + nextUniqueId$k++;
|
22784
23756
|
this.id = this._name + "-date";
|
22785
23757
|
this.name = this._name + "-date";
|
22786
23758
|
this.label = '';
|
@@ -22801,7 +23773,9 @@
|
|
22801
23773
|
},
|
22802
23774
|
set: function (value) {
|
22803
23775
|
this._minDate = value;
|
22804
|
-
|
23776
|
+
if (!ObjectUtil.isNull(value)) {
|
23777
|
+
this._minDate.setHours(0, 0, 0, 0);
|
23778
|
+
}
|
22805
23779
|
},
|
22806
23780
|
enumerable: false,
|
22807
23781
|
configurable: true
|
@@ -22812,7 +23786,9 @@
|
|
22812
23786
|
},
|
22813
23787
|
set: function (value) {
|
22814
23788
|
this._maxDate = value;
|
22815
|
-
|
23789
|
+
if (!ObjectUtil.isNull(value)) {
|
23790
|
+
this._maxDate.setHours(0, 0, 0, 0);
|
23791
|
+
}
|
22816
23792
|
},
|
22817
23793
|
enumerable: false,
|
22818
23794
|
configurable: true
|
@@ -23355,7 +24331,7 @@
|
|
23355
24331
|
this.selectedYearMoment = moment$5();
|
23356
24332
|
this.updateYearText();
|
23357
24333
|
this.selectedMonthMoment = moment$5();
|
23358
|
-
this.months =
|
24334
|
+
this.months = ['Jan.', 'Fev.', 'Mar.', 'Abr.', 'Mai.', 'Jun.', 'Jul.', 'Ago.', 'Set.', 'Out.', 'Nov.', 'Dez.'];
|
23359
24335
|
this.selectedMonthIndex = this.selectedMonthMoment.month();
|
23360
24336
|
this.selectedMonthYear = this.selectedYearMoment.year();
|
23361
24337
|
}
|
@@ -23377,7 +24353,7 @@
|
|
23377
24353
|
};
|
23378
24354
|
return MonthPickerModel;
|
23379
24355
|
}());
|
23380
|
-
var nextUniqueId$
|
24356
|
+
var nextUniqueId$l = 0;
|
23381
24357
|
var MonthYearPickerComponent = /** @class */ (function () {
|
23382
24358
|
function MonthYearPickerComponent(elementRef, _changeDetectorRef, _overlay, _ngZone, _viewContainerRef, scrollStrategy, _dir, _document) {
|
23383
24359
|
this.elementRef = elementRef;
|
@@ -23387,7 +24363,7 @@
|
|
23387
24363
|
this._viewContainerRef = _viewContainerRef;
|
23388
24364
|
this._dir = _dir;
|
23389
24365
|
this._document = _document;
|
23390
|
-
this._name = "gipi-date-range-" + nextUniqueId$
|
24366
|
+
this._name = "gipi-date-range-" + nextUniqueId$l++;
|
23391
24367
|
this._focusedElementBeforeOpen = null;
|
23392
24368
|
this._backdropHarnessClass = this._name + "-backdrop";
|
23393
24369
|
this._stateChanges = new rxjs.Subject();
|
@@ -23805,393 +24781,395 @@
|
|
23805
24781
|
common.CommonModule,
|
23806
24782
|
button.MatButtonModule,
|
23807
24783
|
dialog.MatDialogModule,
|
23808
|
-
overlay.OverlayModule,
|
23809
|
-
a11y.A11yModule,
|
23810
|
-
portal.PortalModule,
|
23811
|
-
icon.MatIconModule,
|
23812
|
-
forms.FormsModule,
|
23813
|
-
forms.ReactiveFormsModule,
|
23814
|
-
],
|
23815
|
-
exports: [
|
23816
|
-
scrolling.ScrollingModule,
|
23817
|
-
CalendarMonthYearComponent,
|
23818
|
-
MonthYearPickerComponent,
|
23819
|
-
],
|
23820
|
-
declarations: [
|
23821
|
-
CalendarMonthYearComponent,
|
23822
|
-
MonthYearPickerComponent,
|
23823
|
-
],
|
23824
|
-
providers: [
|
23825
|
-
GIPI_MONTH_YEAR_SCROLL_STRATEGY_FACTORY_PROVIDER,
|
23826
|
-
],
|
23827
|
-
entryComponents: [
|
23828
|
-
CalendarMonthYearComponent,
|
23829
|
-
],
|
23830
|
-
})
|
23831
|
-
], MonthYearPickerModule);
|
23832
|
-
return MonthYearPickerModule;
|
23833
|
-
}());
|
23834
|
-
|
23835
|
-
var nextUniqueId$
|
23836
|
-
var
|
23837
|
-
function
|
23838
|
-
this.
|
23839
|
-
this.
|
23840
|
-
|
23841
|
-
|
23842
|
-
|
23843
|
-
|
23844
|
-
|
23845
|
-
|
23846
|
-
|
23847
|
-
|
23848
|
-
|
23849
|
-
|
23850
|
-
|
23851
|
-
|
23852
|
-
this.
|
23853
|
-
this.
|
23854
|
-
this.
|
23855
|
-
this.
|
23856
|
-
this.
|
23857
|
-
this.
|
23858
|
-
this.
|
23859
|
-
this.
|
23860
|
-
this.
|
23861
|
-
this.
|
23862
|
-
|
23863
|
-
|
23864
|
-
|
23865
|
-
|
23866
|
-
this.
|
23867
|
-
|
23868
|
-
this._disabled = false;
|
23869
|
-
this.onChange = function (value) { };
|
23870
|
-
this.onTouched = function () { };
|
23871
|
-
}
|
23872
|
-
GIPIRangePageComponent_1 = GIPIRangePageComponent;
|
23873
|
-
Object.defineProperty(GIPIRangePageComponent.prototype, "min", {
|
23874
|
-
get: function () {
|
23875
|
-
return NumberUtil.isNumber(this._min) ? this._min : 1;
|
23876
|
-
},
|
23877
|
-
set: function (value) {
|
23878
|
-
this._min = value;
|
23879
|
-
this._initPage();
|
23880
|
-
},
|
23881
|
-
enumerable: false,
|
23882
|
-
configurable: true
|
23883
|
-
});
|
23884
|
-
Object.defineProperty(GIPIRangePageComponent.prototype, "max", {
|
23885
|
-
get: function () {
|
23886
|
-
return NumberUtil.isNumber(this._max) ? this._max : 100;
|
23887
|
-
},
|
23888
|
-
set: function (value) {
|
23889
|
-
this._max = value;
|
23890
|
-
this._initPage();
|
23891
|
-
},
|
23892
|
-
enumerable: false,
|
23893
|
-
configurable: true
|
23894
|
-
});
|
23895
|
-
Object.defineProperty(GIPIRangePageComponent.prototype, "step", {
|
23896
|
-
get: function () {
|
23897
|
-
return NumberUtil.isNumber(this._step) ? this._step : 1;
|
23898
|
-
},
|
23899
|
-
set: function (value) {
|
23900
|
-
this._step = value;
|
23901
|
-
this._initPage();
|
23902
|
-
},
|
23903
|
-
enumerable: false,
|
23904
|
-
configurable: true
|
23905
|
-
});
|
23906
|
-
Object.defineProperty(GIPIRangePageComponent.prototype, "required", {
|
23907
|
-
get: function () {
|
23908
|
-
return this._required;
|
23909
|
-
},
|
23910
|
-
set: function (value) {
|
23911
|
-
this._required = coercion.coerceBooleanProperty(value);
|
23912
|
-
},
|
23913
|
-
enumerable: false,
|
23914
|
-
configurable: true
|
23915
|
-
});
|
23916
|
-
Object.defineProperty(GIPIRangePageComponent.prototype, "disabled", {
|
23917
|
-
get: function () {
|
23918
|
-
return this._disabled;
|
23919
|
-
},
|
23920
|
-
set: function (value) {
|
23921
|
-
this._disabled = coercion.coerceBooleanProperty(value);
|
23922
|
-
},
|
23923
|
-
enumerable: false,
|
23924
|
-
configurable: true
|
23925
|
-
});
|
23926
|
-
Object.defineProperty(GIPIRangePageComponent.prototype, "formattedValue", {
|
23927
|
-
get: function () {
|
23928
|
-
return '';
|
23929
|
-
},
|
23930
|
-
enumerable: false,
|
23931
|
-
configurable: true
|
23932
|
-
});
|
23933
|
-
GIPIRangePageComponent.prototype.ngOnInit = function () {
|
23934
|
-
this._initPage();
|
23935
|
-
};
|
23936
|
-
GIPIRangePageComponent.prototype.ngOnDestroy = function () { };
|
23937
|
-
GIPIRangePageComponent.prototype.writeValue = function (value) {
|
23938
|
-
if (!ObjectUtil.isNull(value)) {
|
23939
|
-
this._startPage = value.start || this._startPage;
|
23940
|
-
this._endPage = value.end || this._endPage;
|
24784
|
+
overlay.OverlayModule,
|
24785
|
+
a11y.A11yModule,
|
24786
|
+
portal.PortalModule,
|
24787
|
+
icon.MatIconModule,
|
24788
|
+
forms.FormsModule,
|
24789
|
+
forms.ReactiveFormsModule,
|
24790
|
+
],
|
24791
|
+
exports: [
|
24792
|
+
scrolling.ScrollingModule,
|
24793
|
+
CalendarMonthYearComponent,
|
24794
|
+
MonthYearPickerComponent,
|
24795
|
+
],
|
24796
|
+
declarations: [
|
24797
|
+
CalendarMonthYearComponent,
|
24798
|
+
MonthYearPickerComponent,
|
24799
|
+
],
|
24800
|
+
providers: [
|
24801
|
+
GIPI_MONTH_YEAR_SCROLL_STRATEGY_FACTORY_PROVIDER,
|
24802
|
+
],
|
24803
|
+
entryComponents: [
|
24804
|
+
CalendarMonthYearComponent,
|
24805
|
+
],
|
24806
|
+
})
|
24807
|
+
], MonthYearPickerModule);
|
24808
|
+
return MonthYearPickerModule;
|
24809
|
+
}());
|
24810
|
+
|
24811
|
+
var nextUniqueId$m = 0;
|
24812
|
+
var GIPISplitButtonComponent = /** @class */ (function () {
|
24813
|
+
function GIPISplitButtonComponent(elementRef) {
|
24814
|
+
this.elementRef = elementRef;
|
24815
|
+
this._uniqueId = nextUniqueId$m++;
|
24816
|
+
this._name = "gipi-split-button-" + this._uniqueId;
|
24817
|
+
this.idBtnDefault = "gipi-split-button-default-" + this._uniqueId;
|
24818
|
+
this.idBtnMenu = "gipi-split-button-menu-" + this._uniqueId;
|
24819
|
+
this.isSplitButtonPrimary = this._hasHostAttributes('gipi-primary');
|
24820
|
+
this.isSplitButtonSecondary = this._hasHostAttributes('gipi-secondary');
|
24821
|
+
this.isSplitButtonTertiary = this._hasHostAttributes('gipi-tertiary');
|
24822
|
+
this.isSplitButtonAction = this._hasHostAttributes('gipi-action');
|
24823
|
+
this.id = this._name;
|
24824
|
+
this.name = this._name;
|
24825
|
+
this.type = 'button';
|
24826
|
+
this.ariaLabel = '';
|
24827
|
+
this.title = '';
|
24828
|
+
this.label = '';
|
24829
|
+
this.disabled = false;
|
24830
|
+
this.loading = false;
|
24831
|
+
this.tooltip = '';
|
24832
|
+
this.splitOptions = [];
|
24833
|
+
this.onOpenPopover = new core.EventEmitter();
|
24834
|
+
this.onClosePopover = new core.EventEmitter();
|
24835
|
+
this.onClick = new core.EventEmitter(true);
|
24836
|
+
this.onFocus = new core.EventEmitter(true);
|
24837
|
+
this.onBlur = new core.EventEmitter(true);
|
24838
|
+
}
|
24839
|
+
GIPISplitButtonComponent_1 = GIPISplitButtonComponent;
|
24840
|
+
GIPISplitButtonComponent.prototype.ngOnInit = function () { };
|
24841
|
+
GIPISplitButtonComponent.prototype.ngOnDestroy = function () {
|
24842
|
+
if (this.popoverTrigger) {
|
24843
|
+
this.popoverTrigger.destroyPopover();
|
23941
24844
|
}
|
23942
|
-
this._changeDetectorRef.detectChanges();
|
23943
24845
|
};
|
23944
|
-
|
23945
|
-
this.
|
24846
|
+
GIPISplitButtonComponent.prototype.getHostElement = function () {
|
24847
|
+
return this.elementRef.nativeElement;
|
23946
24848
|
};
|
23947
|
-
|
23948
|
-
|
24849
|
+
GIPISplitButtonComponent.prototype._hasHostAttributes = function () {
|
24850
|
+
var _this = this;
|
24851
|
+
var attributes = [];
|
24852
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
24853
|
+
attributes[_i] = arguments[_i];
|
24854
|
+
}
|
24855
|
+
return attributes.some(function (attribute) { return _this.getHostElement().hasAttribute(attribute); });
|
23949
24856
|
};
|
23950
|
-
|
23951
|
-
|
23952
|
-
|
24857
|
+
GIPISplitButtonComponent.prototype.btnIdAndName = function () {
|
24858
|
+
var uniqueId = nextUniqueId$m++;
|
24859
|
+
return {
|
24860
|
+
btnDefault: "gipi-split-button-default-" + uniqueId,
|
24861
|
+
btnMenu: "gipi-split-button-menu-" + uniqueId,
|
24862
|
+
};
|
23953
24863
|
};
|
23954
|
-
|
23955
|
-
|
23956
|
-
|
24864
|
+
GIPISplitButtonComponent.prototype.getInternalButtonClass = function (isBtnDefault) {
|
24865
|
+
return {
|
24866
|
+
'button-default': isBtnDefault,
|
24867
|
+
'button-menu': !isBtnDefault,
|
24868
|
+
'button-primary': this.isSplitButtonPrimary,
|
24869
|
+
'button-secondary': this.isSplitButtonSecondary,
|
24870
|
+
'button-tertiary': this.isSplitButtonTertiary,
|
24871
|
+
'button-action': this.isSplitButtonAction,
|
24872
|
+
};
|
23957
24873
|
};
|
23958
|
-
|
23959
|
-
if (this.disabled) {
|
24874
|
+
GIPISplitButtonComponent.prototype.showPopover = function () {
|
24875
|
+
if (this.disabled || this.loading) {
|
23960
24876
|
return;
|
23961
24877
|
}
|
23962
|
-
|
23963
|
-
this.
|
23964
|
-
}
|
23965
|
-
else if (this._startPage > this.max) {
|
23966
|
-
this._startPage = this.max;
|
24878
|
+
else {
|
24879
|
+
this.popoverTrigger.openPopover();
|
23967
24880
|
}
|
23968
|
-
|
23969
|
-
|
24881
|
+
};
|
24882
|
+
GIPISplitButtonComponent.prototype.closePopover = function () {
|
24883
|
+
if (this.disabled || this.loading) {
|
24884
|
+
return;
|
23970
24885
|
}
|
23971
|
-
else
|
23972
|
-
this.
|
24886
|
+
else {
|
24887
|
+
this.popoverTrigger.closePopover();
|
23973
24888
|
}
|
23974
|
-
this._propagateChange();
|
23975
24889
|
};
|
23976
|
-
|
23977
|
-
if (this.disabled) {
|
24890
|
+
GIPISplitButtonComponent.prototype.handleClick = function (event) {
|
24891
|
+
if (this.disabled || this.loading) {
|
23978
24892
|
return;
|
23979
24893
|
}
|
23980
|
-
|
23981
|
-
this.
|
23982
|
-
|
23983
|
-
|
23984
|
-
this._endPage = this.max;
|
24894
|
+
else {
|
24895
|
+
this.onClick.emit(event);
|
24896
|
+
this.closePopover();
|
24897
|
+
event.stopPropagation();
|
23985
24898
|
}
|
23986
|
-
|
23987
|
-
|
24899
|
+
};
|
24900
|
+
GIPISplitButtonComponent.prototype.handleFocus = function (event) {
|
24901
|
+
if (this.disabled || this.loading) {
|
24902
|
+
return;
|
23988
24903
|
}
|
23989
|
-
else
|
23990
|
-
this.
|
24904
|
+
else {
|
24905
|
+
this.onFocus.emit(event);
|
24906
|
+
event.stopPropagation();
|
23991
24907
|
}
|
23992
|
-
this._propagateChange();
|
23993
24908
|
};
|
23994
|
-
|
23995
|
-
if (this.disabled) {
|
24909
|
+
GIPISplitButtonComponent.prototype.handleBlur = function (event) {
|
24910
|
+
if (this.disabled || this.loading) {
|
23996
24911
|
return;
|
23997
24912
|
}
|
23998
|
-
|
23999
|
-
|
24000
|
-
|
24001
|
-
this._startPage = newStartPage;
|
24002
|
-
this._endPage = newEndPage;
|
24003
|
-
this._propagateChange();
|
24913
|
+
else {
|
24914
|
+
this.onBlur.emit(event);
|
24915
|
+
event.stopPropagation();
|
24004
24916
|
}
|
24005
24917
|
};
|
24006
|
-
|
24007
|
-
if (this.disabled) {
|
24918
|
+
GIPISplitButtonComponent.prototype.handleClickBtnMenu = function (event) {
|
24919
|
+
if (this.disabled || this.loading) {
|
24008
24920
|
return;
|
24009
24921
|
}
|
24010
|
-
|
24011
|
-
|
24012
|
-
|
24013
|
-
|
24014
|
-
|
24015
|
-
newEndPage = newStartPage;
|
24016
|
-
}
|
24017
|
-
if (newEndPage <= this.max) {
|
24018
|
-
this._startPage = newStartPage;
|
24019
|
-
this._endPage = newEndPage;
|
24020
|
-
this._propagateChange();
|
24922
|
+
else {
|
24923
|
+
if (!ObjectUtil.isNull(this.popoverTrigger)) {
|
24924
|
+
this.popoverTrigger.togglePopover();
|
24925
|
+
}
|
24926
|
+
event.stopPropagation();
|
24021
24927
|
}
|
24022
24928
|
};
|
24023
|
-
|
24024
|
-
if (this.disabled || !
|
24929
|
+
GIPISplitButtonComponent.prototype.handleClickBtnSplitOption = function (option) {
|
24930
|
+
if (this.disabled || this.loading || !option || option.disabled || !option.clickFn) {
|
24025
24931
|
return;
|
24026
24932
|
}
|
24027
|
-
|
24933
|
+
else {
|
24934
|
+
option.clickFn();
|
24935
|
+
this.closePopover();
|
24936
|
+
}
|
24028
24937
|
};
|
24029
|
-
|
24030
|
-
|
24031
|
-
|
24938
|
+
GIPISplitButtonComponent.prototype.onResize = function (event) {
|
24939
|
+
if (this.popoverTrigger) {
|
24940
|
+
this.popoverTrigger.closePopover();
|
24941
|
+
event.stopPropagation();
|
24942
|
+
}
|
24032
24943
|
};
|
24033
|
-
var
|
24034
|
-
|
24035
|
-
{ type: core.ElementRef }
|
24036
|
-
{ type: core.ChangeDetectorRef }
|
24944
|
+
var GIPISplitButtonComponent_1;
|
24945
|
+
GIPISplitButtonComponent.ctorParameters = function () { return [
|
24946
|
+
{ type: core.ElementRef }
|
24037
24947
|
]; };
|
24948
|
+
__decorate([
|
24949
|
+
core.ViewChild(GIPIPopoverTrigger, { static: false }),
|
24950
|
+
__metadata("design:type", GIPIPopoverTrigger)
|
24951
|
+
], GIPISplitButtonComponent.prototype, "popoverTrigger", void 0);
|
24038
24952
|
__decorate([
|
24039
24953
|
core.Input(),
|
24040
24954
|
__metadata("design:type", String)
|
24041
|
-
],
|
24955
|
+
], GIPISplitButtonComponent.prototype, "id", void 0);
|
24042
24956
|
__decorate([
|
24043
24957
|
core.Input(),
|
24044
24958
|
__metadata("design:type", String)
|
24045
|
-
],
|
24959
|
+
], GIPISplitButtonComponent.prototype, "name", void 0);
|
24046
24960
|
__decorate([
|
24047
24961
|
core.Input(),
|
24048
24962
|
__metadata("design:type", String)
|
24049
|
-
],
|
24963
|
+
], GIPISplitButtonComponent.prototype, "type", void 0);
|
24050
24964
|
__decorate([
|
24051
24965
|
core.Input(),
|
24052
24966
|
__metadata("design:type", String)
|
24053
|
-
],
|
24967
|
+
], GIPISplitButtonComponent.prototype, "ariaLabel", void 0);
|
24054
24968
|
__decorate([
|
24055
24969
|
core.Input(),
|
24056
24970
|
__metadata("design:type", String)
|
24057
|
-
],
|
24971
|
+
], GIPISplitButtonComponent.prototype, "title", void 0);
|
24058
24972
|
__decorate([
|
24059
24973
|
core.Input(),
|
24060
24974
|
__metadata("design:type", String)
|
24061
|
-
],
|
24975
|
+
], GIPISplitButtonComponent.prototype, "label", void 0);
|
24062
24976
|
__decorate([
|
24063
24977
|
core.Input(),
|
24064
24978
|
__metadata("design:type", String)
|
24065
|
-
],
|
24979
|
+
], GIPISplitButtonComponent.prototype, "buttonClass", void 0);
|
24066
24980
|
__decorate([
|
24067
24981
|
core.Input(),
|
24068
|
-
__metadata("design:type",
|
24069
|
-
|
24070
|
-
], GIPIRangePageComponent.prototype, "min", null);
|
24982
|
+
__metadata("design:type", Boolean)
|
24983
|
+
], GIPISplitButtonComponent.prototype, "disabled", void 0);
|
24071
24984
|
__decorate([
|
24072
24985
|
core.Input(),
|
24073
|
-
__metadata("design:type",
|
24074
|
-
|
24075
|
-
], GIPIRangePageComponent.prototype, "max", null);
|
24986
|
+
__metadata("design:type", Boolean)
|
24987
|
+
], GIPISplitButtonComponent.prototype, "loading", void 0);
|
24076
24988
|
__decorate([
|
24077
24989
|
core.Input(),
|
24078
|
-
__metadata("design:type",
|
24079
|
-
|
24080
|
-
], GIPIRangePageComponent.prototype, "step", null);
|
24990
|
+
__metadata("design:type", String)
|
24991
|
+
], GIPISplitButtonComponent.prototype, "tooltip", void 0);
|
24081
24992
|
__decorate([
|
24082
|
-
core.Input(),
|
24083
|
-
__metadata("design:type",
|
24084
|
-
|
24085
|
-
], GIPIRangePageComponent.prototype, "required", null);
|
24993
|
+
core.Input('options'),
|
24994
|
+
__metadata("design:type", Array)
|
24995
|
+
], GIPISplitButtonComponent.prototype, "splitOptions", void 0);
|
24086
24996
|
__decorate([
|
24087
|
-
core.
|
24088
|
-
__metadata("design:type",
|
24089
|
-
|
24090
|
-
|
24091
|
-
|
24997
|
+
core.Output(),
|
24998
|
+
__metadata("design:type", core.EventEmitter)
|
24999
|
+
], GIPISplitButtonComponent.prototype, "onOpenPopover", void 0);
|
25000
|
+
__decorate([
|
25001
|
+
core.Output(),
|
25002
|
+
__metadata("design:type", core.EventEmitter)
|
25003
|
+
], GIPISplitButtonComponent.prototype, "onClosePopover", void 0);
|
25004
|
+
__decorate([
|
25005
|
+
core.Output('click'),
|
25006
|
+
__metadata("design:type", core.EventEmitter)
|
25007
|
+
], GIPISplitButtonComponent.prototype, "onClick", void 0);
|
25008
|
+
__decorate([
|
25009
|
+
core.Output('focus'),
|
25010
|
+
__metadata("design:type", core.EventEmitter)
|
25011
|
+
], GIPISplitButtonComponent.prototype, "onFocus", void 0);
|
25012
|
+
__decorate([
|
25013
|
+
core.Output('blur'),
|
25014
|
+
__metadata("design:type", core.EventEmitter)
|
25015
|
+
], GIPISplitButtonComponent.prototype, "onBlur", void 0);
|
25016
|
+
__decorate([
|
25017
|
+
core.HostListener('window:resize', ['$event']),
|
25018
|
+
__metadata("design:type", Function),
|
25019
|
+
__metadata("design:paramtypes", [UIEvent]),
|
25020
|
+
__metadata("design:returntype", void 0)
|
25021
|
+
], GIPISplitButtonComponent.prototype, "onResize", null);
|
25022
|
+
GIPISplitButtonComponent = GIPISplitButtonComponent_1 = __decorate([
|
24092
25023
|
core.Component({
|
24093
|
-
selector:
|
24094
|
-
|
25024
|
+
selector: "gipi-split-button[gipi-primary], gipi-split-button[gipi-secondary],\n gipi-split-button[gipi-tertiary], gipi-split-button[gipi-action]",
|
25025
|
+
exportAs: 'gipiSplitButton',
|
25026
|
+
template: "<div [matTooltip]=\"tooltip\"\n [class]=\"buttonClass || ''\"\n [class.button-base]=\"true\"\n [class.disabled]=\"disabled || loading\"\n #popoverTrigger=\"popoverTrigger\"\n [popoverTriggerFor]=\"btnPopover\"\n [popoverTriggerOn]=\"'none'\"\n [popoverBackdropCloseOnClick]=\"true\"\n (opened)=\"onOpenPopover.emit()\"\n (closed)=\"onClosePopover.emit()\">\n <button [attr.id]=\"idBtnDefault\"\n [attr.name]=\"idBtnDefault\"\n [attr.type]=\"type\"\n [attr.aria-label]=\"ariaLabel ? ariaLabel : label\"\n [attr.title]=\"title ? title : label\"\n [disabled]=\"disabled || loading\"\n [ngClass]=\"getInternalButtonClass(true)\"\n role=\"button\"\n (click)=\"handleClick($event)\"\n (focus)=\"handleFocus($event)\"\n (blur)=\"handleBlur($event)\">\n {{ label ? label : '' }}\n </button>\n <button [attr.id]=\"idBtnMenu\"\n [attr.name]=\"idBtnMenu\"\n [attr.type]=\"type\"\n [attr.aria-label]=\"ariaLabel ? ariaLabel : label\"\n [attr.title]=\"title ? title : label\"\n [disabled]=\"disabled || loading\"\n [ngClass]=\"getInternalButtonClass(false)\"\n role=\"button\"\n (click)=\"handleClickBtnMenu($event)\">\n <mat-icon [@indicatorRotate]=\"popoverTrigger?.popoverOpen ? 'opened': 'closed'\"> expand_more </mat-icon>\n </button>\n</div>\n\n<gipi-popover #btnPopover=\"gipiPopover\"\n [popoverOverlapTrigger]=\"false\"\n [popoverCloseOnClick]=\"false\"\n [popoverArrowWidth]=\"0\"\n [popoverOffsetY]=\"3\">\n <div class=\"btn-popover-content\">\n <button class=\"btn-split-option\"\n *ngFor=\"let option of splitOptions\"\n [disabled]=\"option?.disabled\"\n (click)=\"handleClickBtnSplitOption(option)\">\n {{ option.label }}\n </button>\n </div>\n</gipi-popover>",
|
24095
25027
|
providers: [
|
24096
25028
|
{
|
24097
25029
|
provide: forms.NG_VALUE_ACCESSOR,
|
24098
|
-
useExisting: core.forwardRef(function () { return
|
25030
|
+
useExisting: core.forwardRef(function () { return GIPISplitButtonComponent_1; }),
|
24099
25031
|
multi: true
|
24100
|
-
}
|
25032
|
+
}
|
24101
25033
|
],
|
24102
|
-
|
25034
|
+
host: {
|
25035
|
+
'class': 'gipi-split-button',
|
25036
|
+
'[attr.id]': 'id',
|
25037
|
+
'[attr.name]': 'name',
|
25038
|
+
},
|
25039
|
+
animations: [
|
25040
|
+
animations.trigger('indicatorRotate', [
|
25041
|
+
animations.state('closed', animations.style({ transform: 'rotate(0deg)' })),
|
25042
|
+
animations.state('opened', animations.style({ transform: 'rotate(-180deg)' })),
|
25043
|
+
animations.transition('opened <=> closed', animations.animate('225ms cubic-bezier(0.4,0.0,0.2,1)')),
|
25044
|
+
])
|
25045
|
+
],
|
25046
|
+
styles: [".button-base{display:flex;flex-direction:row;justify-content:center;border-radius:4px;font-weight:600;font-size:1.4rem;line-height:1.6rem;cursor:pointer;outline:0;white-space:nowrap;text-decoration:none;vertical-align:middle;text-align:center;box-shadow:1px 1px 5px 0 rgba(0,0,0,.1);transition:.2s;width:100%;max-height:4rem;border:1px solid transparent;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.button-base.disabled{cursor:not-allowed!important;box-shadow:none}.button-base>button{display:flex;align-items:center;justify-content:center;border:none;outline:0;box-shadow:none;width:100%;height:40px;padding:12px 16px;overflow:hidden;border-radius:inherit;cursor:inherit;font-size:inherit;font-weight:inherit;white-space:nowrap;text-decoration:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;position:relative}.button-base>button:not(.disabled):active{opacity:.8}.button-base .button-default{border-top-right-radius:0!important;border-bottom-right-radius:0!important}.button-base .button-menu{max-width:-webkit-fit-content;max-width:-moz-fit-content;max-width:fit-content;border-top-left-radius:0!important;border-bottom-left-radius:0!important}.button-primary:not(:disabled),.button-primary:not(:disabled)>mat-icon{background-color:#e0313e;color:#fff;fill:#fff}.button-primary:not(:disabled).button-default,.button-primary:not(:disabled)>mat-icon.button-default{border-right:1px solid #9f232c}.button-primary:not(:disabled) svg,.button-primary:not(:disabled) svg g path,.button-primary:not(:disabled) svg path,.button-primary:not(:disabled)>mat-icon svg,.button-primary:not(:disabled)>mat-icon svg g path,.button-primary:not(:disabled)>mat-icon svg path{color:#fff;fill:#fff}.button-primary:disabled,.button-primary:disabled>mat-icon{background-color:#d1d2d4;color:#9a9da2;fill:#9a9da2}.button-primary:disabled.button-default,.button-primary:disabled>mat-icon.button-default{border-right:1px solid #9a9da2}.button-primary:disabled svg,.button-primary:disabled svg g path,.button-primary:disabled svg path,.button-primary:disabled>mat-icon svg,.button-primary:disabled>mat-icon svg g path,.button-primary:disabled>mat-icon svg path{color:#9a9da2;fill:#9a9da2}.button-primary:not(:disabled):hover,.button-primary:not(:disabled):hover>mat-icon{background-color:#cc2d38;color:#fff;fill:#fff}.button-primary:not(:disabled):hover svg,.button-primary:not(:disabled):hover svg g path,.button-primary:not(:disabled):hover svg path,.button-primary:not(:disabled):hover>mat-icon svg,.button-primary:not(:disabled):hover>mat-icon svg g path,.button-primary:not(:disabled):hover>mat-icon svg path{color:#fff;fill:#fff}.button-secondary{background-color:transparent}.button-secondary:not(:disabled),.button-secondary:not(:disabled)>mat-icon{border-color:#595959;color:#595959;fill:#595959}.button-secondary:not(:disabled).button-default,.button-secondary:not(:disabled)>mat-icon.button-default{border-right:1px solid #595959}.button-secondary:not(:disabled) svg,.button-secondary:not(:disabled) svg g path,.button-secondary:not(:disabled) svg path,.button-secondary:not(:disabled)>mat-icon svg,.button-secondary:not(:disabled)>mat-icon svg g path,.button-secondary:not(:disabled)>mat-icon svg path{color:#595959;fill:#595959}.button-secondary:disabled,.button-secondary:disabled>mat-icon{border-color:#d1d2d4;background-color:#d1d2d4;color:#9a9da2;fill:#9a9da2}.button-secondary:disabled.button-default,.button-secondary:disabled>mat-icon.button-default{border-right:1px solid #9a9da2}.button-secondary:disabled svg,.button-secondary:disabled svg g path,.button-secondary:disabled svg path,.button-secondary:disabled>mat-icon svg,.button-secondary:disabled>mat-icon svg g path,.button-secondary:disabled>mat-icon svg path{color:#9a9da2;fill:#9a9da2}.button-secondary:not(:disabled):hover,.button-secondary:not(:disabled):hover>mat-icon{border-color:#595959;background-color:#e0e1e2;color:#595959;fill:#595959}.button-secondary:not(:disabled):hover svg,.button-secondary:not(:disabled):hover svg g path,.button-secondary:not(:disabled):hover svg path,.button-secondary:not(:disabled):hover>mat-icon svg,.button-secondary:not(:disabled):hover>mat-icon svg g path,.button-secondary:not(:disabled):hover>mat-icon svg path{color:#595959;fill:#595959}.button-tertiary{background-color:#e7ebee;box-shadow:none}.button-tertiary:not(:disabled),.button-tertiary:not(:disabled)>mat-icon{color:#595959;fill:#595959}.button-tertiary:not(:disabled).button-default,.button-tertiary:not(:disabled)>mat-icon.button-default{border-right:1px solid #595959}.button-tertiary:not(:disabled) svg,.button-tertiary:not(:disabled) svg g path,.button-tertiary:not(:disabled) svg path,.button-tertiary:not(:disabled)>mat-icon svg,.button-tertiary:not(:disabled)>mat-icon svg g path,.button-tertiary:not(:disabled)>mat-icon svg path{color:#595959;fill:#595959}.button-tertiary:disabled,.button-tertiary:disabled>mat-icon{background-color:#d1d2d4;color:#9a9da2;fill:#9a9da2}.button-tertiary:disabled.button-default,.button-tertiary:disabled>mat-icon.button-default{border-right:1px solid #9a9da2}.button-tertiary:disabled svg,.button-tertiary:disabled svg g path,.button-tertiary:disabled svg path,.button-tertiary:disabled>mat-icon svg,.button-tertiary:disabled>mat-icon svg g path,.button-tertiary:disabled>mat-icon svg path{color:#9a9da2;fill:#9a9da2}.button-tertiary:not(:disabled):hover,.button-tertiary:not(:disabled):hover>mat-icon{background-color:#e0e1e2;color:#595959;fill:#595959}.button-tertiary:not(:disabled):hover svg,.button-tertiary:not(:disabled):hover svg g path,.button-tertiary:not(:disabled):hover svg path,.button-tertiary:not(:disabled):hover>mat-icon svg,.button-tertiary:not(:disabled):hover>mat-icon svg g path,.button-tertiary:not(:disabled):hover>mat-icon svg path{color:#595959;fill:#595959}.button-action{background-color:transparent;box-shadow:none;display:flex;justify-content:flex-start!important}.button-action:not(:disabled),.button-action:not(:disabled)>mat-icon{color:#262626;fill:#262626}.button-action:not(:disabled).button-default,.button-action:not(:disabled)>mat-icon.button-default{border-right:1px solid #262626}.button-action:not(:disabled) svg,.button-action:not(:disabled) svg g path,.button-action:not(:disabled) svg path,.button-action:not(:disabled)>mat-icon svg,.button-action:not(:disabled)>mat-icon svg g path,.button-action:not(:disabled)>mat-icon svg path{color:#262626;fill:#262626}.button-action:disabled,.button-action:disabled>mat-icon{color:#9a9da2;fill:#9a9da2}.button-action:disabled.button-default,.button-action:disabled>mat-icon.button-default{border-right:1px solid #9a9da2}.button-action:disabled svg,.button-action:disabled svg g path,.button-action:disabled svg path,.button-action:disabled>mat-icon svg,.button-action:disabled>mat-icon svg g path,.button-action:disabled>mat-icon svg path{color:#9a9da2;fill:#9a9da2}.button-action:not(:disabled):hover,.button-action:not(:disabled):hover>mat-icon{background-color:#f5f5f6;color:#262626;fill:#262626}.button-action:not(:disabled):hover svg,.button-action:not(:disabled):hover svg g path,.button-action:not(:disabled):hover svg path,.button-action:not(:disabled):hover>mat-icon svg,.button-action:not(:disabled):hover>mat-icon svg g path,.button-action:not(:disabled):hover>mat-icon svg path{color:#262626;fill:#262626}.disabled,:disabled{pointer-events:none!important}.btn-popover-content{display:flex;flex-direction:column;gap:.8rem;background-color:#fff;border-radius:4px;box-shadow:0 2px 4px -1px rgba(0,0,0,.2),0 4px 5px 0 rgba(0,0,0,.14),0 1px 10px 0 rgba(0,0,0,.12);padding:8px}.btn-split-option{width:100%;padding:.8rem;border-radius:.4rem;border:1px solid transparent;text-align:left;outline:0;background-color:transparent;cursor:pointer}.btn-split-option:not(:disabled){color:#595959}.btn-split-option:disabled{border-color:#d1d2d4;background-color:#d1d2d4;color:#9a9da2;cursor:not-allowed}.btn-split-option:not(:disabled):hover{border-color:#595959;background-color:#e0e1e2;color:#595959}"]
|
24103
25047
|
}),
|
24104
|
-
__metadata("design:paramtypes", [core.ElementRef
|
24105
|
-
|
24106
|
-
|
24107
|
-
return GIPIRangePageComponent;
|
25048
|
+
__metadata("design:paramtypes", [core.ElementRef])
|
25049
|
+
], GIPISplitButtonComponent);
|
25050
|
+
return GIPISplitButtonComponent;
|
24108
25051
|
}());
|
24109
25052
|
|
24110
|
-
var nextUniqueId$
|
24111
|
-
var
|
24112
|
-
function
|
25053
|
+
var nextUniqueId$n = 0;
|
25054
|
+
var GIPITextareaComponent = /** @class */ (function () {
|
25055
|
+
function GIPITextareaComponent(elementRef, _changeDetectorRef) {
|
24113
25056
|
this.elementRef = elementRef;
|
24114
25057
|
this._changeDetectorRef = _changeDetectorRef;
|
24115
|
-
this._name = "gipi-
|
25058
|
+
this._name = "gipi-textarea-" + nextUniqueId$n++;
|
24116
25059
|
this.id = this._name;
|
24117
25060
|
this.name = this._name;
|
24118
25061
|
this.label = '';
|
25062
|
+
this.placeholder = '';
|
25063
|
+
this.cols = 20;
|
25064
|
+
this.rows = 4;
|
24119
25065
|
this.help = '';
|
24120
|
-
this.
|
24121
|
-
this.
|
24122
|
-
this.
|
24123
|
-
this.
|
24124
|
-
this.
|
24125
|
-
this.
|
24126
|
-
this.
|
25066
|
+
this.maxlength = 254;
|
25067
|
+
this.minlength = 0;
|
25068
|
+
this._resize = 'horizontal';
|
25069
|
+
this._minHeight = '60px';
|
25070
|
+
this._height = '60px';
|
25071
|
+
this._maxHeight = 'auto';
|
25072
|
+
this._autocomplete = 'off';
|
25073
|
+
this._autofocus = false;
|
25074
|
+
this._readOnly = false;
|
24127
25075
|
this._required = false;
|
25076
|
+
this._disabled = false;
|
25077
|
+
this._lowerCase = false;
|
25078
|
+
this._upperCase = false;
|
25079
|
+
this._spaceDrop = false;
|
24128
25080
|
this.onChange = function () { };
|
24129
25081
|
this.onTouched = function () { };
|
24130
25082
|
}
|
24131
|
-
|
24132
|
-
Object.defineProperty(
|
25083
|
+
GIPITextareaComponent_1 = GIPITextareaComponent;
|
25084
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "resize", {
|
25085
|
+
get: function () {
|
25086
|
+
return this._resize;
|
25087
|
+
},
|
25088
|
+
set: function (value) {
|
25089
|
+
if (value !== this.resize) {
|
25090
|
+
this._resize = value.toLowerCase();
|
25091
|
+
this._changeDetectorRef.detectChanges();
|
25092
|
+
}
|
25093
|
+
},
|
25094
|
+
enumerable: false,
|
25095
|
+
configurable: true
|
25096
|
+
});
|
25097
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "minHeight", {
|
25098
|
+
get: function () {
|
25099
|
+
return this._minHeight;
|
25100
|
+
},
|
25101
|
+
set: function (value) {
|
25102
|
+
if (value.trim().toUpperCase() === 'AUTO') {
|
25103
|
+
this._minHeight = 'auto';
|
25104
|
+
}
|
25105
|
+
else {
|
25106
|
+
this._minHeight = coercion.coerceCssPixelValue(value);
|
25107
|
+
}
|
25108
|
+
},
|
25109
|
+
enumerable: false,
|
25110
|
+
configurable: true
|
25111
|
+
});
|
25112
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "height", {
|
24133
25113
|
get: function () {
|
24134
|
-
return this.
|
25114
|
+
return this._height;
|
24135
25115
|
},
|
24136
25116
|
set: function (value) {
|
24137
|
-
if (
|
24138
|
-
|
25117
|
+
if (value.trim().toUpperCase() === 'AUTO') {
|
25118
|
+
this._height = 'auto';
|
25119
|
+
}
|
25120
|
+
else {
|
25121
|
+
this._height = coercion.coerceCssPixelValue(value);
|
24139
25122
|
}
|
24140
|
-
this._maxRange = value || 5;
|
24141
25123
|
},
|
24142
25124
|
enumerable: false,
|
24143
25125
|
configurable: true
|
24144
25126
|
});
|
24145
|
-
Object.defineProperty(
|
25127
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "maxHeight", {
|
24146
25128
|
get: function () {
|
24147
|
-
return this.
|
25129
|
+
return this._maxHeight;
|
24148
25130
|
},
|
24149
25131
|
set: function (value) {
|
24150
|
-
if (
|
24151
|
-
|
25132
|
+
if (value.trim().toUpperCase() === 'AUTO') {
|
25133
|
+
this._maxHeight = 'auto';
|
25134
|
+
}
|
25135
|
+
else {
|
25136
|
+
this._maxHeight = coercion.coerceCssPixelValue(value);
|
24152
25137
|
}
|
24153
|
-
this._fromValue = value || 1;
|
24154
25138
|
},
|
24155
25139
|
enumerable: false,
|
24156
25140
|
configurable: true
|
24157
25141
|
});
|
24158
|
-
Object.defineProperty(
|
25142
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "autocomplete", {
|
24159
25143
|
get: function () {
|
24160
|
-
return this.
|
25144
|
+
return this._autocomplete;
|
24161
25145
|
},
|
24162
25146
|
set: function (value) {
|
24163
|
-
|
24164
|
-
throw new Error('Minimum value for "to" must be 1');
|
24165
|
-
}
|
24166
|
-
this._toValue = value || 1;
|
25147
|
+
this._autocomplete = value;
|
24167
25148
|
},
|
24168
25149
|
enumerable: false,
|
24169
25150
|
configurable: true
|
24170
25151
|
});
|
24171
|
-
Object.defineProperty(
|
25152
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "autofocus", {
|
24172
25153
|
get: function () {
|
24173
|
-
return this.
|
25154
|
+
return this._autofocus;
|
24174
25155
|
},
|
24175
25156
|
set: function (value) {
|
24176
|
-
|
24177
|
-
throw new Error('Minimum value for "step" must be 1');
|
24178
|
-
}
|
24179
|
-
this._step = value || 1;
|
25157
|
+
this._autofocus = coercion.coerceBooleanProperty(value);
|
24180
25158
|
},
|
24181
25159
|
enumerable: false,
|
24182
25160
|
configurable: true
|
24183
25161
|
});
|
24184
|
-
Object.defineProperty(
|
25162
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "readOnly", {
|
24185
25163
|
get: function () {
|
24186
|
-
return this.
|
25164
|
+
return this._readOnly;
|
24187
25165
|
},
|
24188
25166
|
set: function (value) {
|
24189
|
-
this.
|
25167
|
+
this._readOnly = coercion.coerceBooleanProperty(value);
|
24190
25168
|
},
|
24191
25169
|
enumerable: false,
|
24192
25170
|
configurable: true
|
24193
25171
|
});
|
24194
|
-
Object.defineProperty(
|
25172
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "required", {
|
24195
25173
|
get: function () {
|
24196
25174
|
return this._required;
|
24197
25175
|
},
|
@@ -24201,269 +25179,222 @@
|
|
24201
25179
|
enumerable: false,
|
24202
25180
|
configurable: true
|
24203
25181
|
});
|
24204
|
-
|
24205
|
-
|
24206
|
-
|
24207
|
-
|
24208
|
-
|
24209
|
-
|
24210
|
-
|
24211
|
-
|
24212
|
-
|
24213
|
-
|
24214
|
-
|
24215
|
-
|
24216
|
-
|
24217
|
-
|
24218
|
-
|
24219
|
-
|
24220
|
-
}
|
25182
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "disabled", {
|
25183
|
+
get: function () {
|
25184
|
+
return this._disabled;
|
25185
|
+
},
|
25186
|
+
set: function (value) {
|
25187
|
+
this._disabled = coercion.coerceBooleanProperty(value);
|
25188
|
+
},
|
25189
|
+
enumerable: false,
|
25190
|
+
configurable: true
|
25191
|
+
});
|
25192
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "lowerCase", {
|
25193
|
+
get: function () {
|
25194
|
+
return this._lowerCase;
|
25195
|
+
},
|
25196
|
+
set: function (value) {
|
25197
|
+
this._lowerCase = coercion.coerceBooleanProperty(value);
|
25198
|
+
},
|
25199
|
+
enumerable: false,
|
25200
|
+
configurable: true
|
25201
|
+
});
|
25202
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "upperCase", {
|
25203
|
+
get: function () {
|
25204
|
+
return this._upperCase;
|
25205
|
+
},
|
25206
|
+
set: function (value) {
|
25207
|
+
this._upperCase = coercion.coerceBooleanProperty(value);
|
25208
|
+
},
|
25209
|
+
enumerable: false,
|
25210
|
+
configurable: true
|
25211
|
+
});
|
25212
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "spaceDrop", {
|
25213
|
+
get: function () {
|
25214
|
+
return this._spaceDrop;
|
25215
|
+
},
|
25216
|
+
set: function (value) {
|
25217
|
+
this._spaceDrop = coercion.coerceBooleanProperty(value);
|
25218
|
+
},
|
25219
|
+
enumerable: false,
|
25220
|
+
configurable: true
|
25221
|
+
});
|
25222
|
+
Object.defineProperty(GIPITextareaComponent.prototype, "value", {
|
25223
|
+
get: function () {
|
25224
|
+
return this._value;
|
25225
|
+
},
|
25226
|
+
set: function (value) {
|
25227
|
+
var valueAux = value;
|
25228
|
+
valueAux = this._checkSpaceDrop(valueAux);
|
25229
|
+
valueAux = this._checkLowercase(valueAux);
|
25230
|
+
valueAux = this._checkUppercase(valueAux);
|
25231
|
+
this._value = valueAux;
|
25232
|
+
this.onChange(this._value);
|
25233
|
+
this.onTouched(this._value);
|
25234
|
+
},
|
25235
|
+
enumerable: false,
|
25236
|
+
configurable: true
|
25237
|
+
});
|
25238
|
+
GIPITextareaComponent.prototype.ngOnInit = function () { };
|
25239
|
+
GIPITextareaComponent.prototype.writeValue = function (value) {
|
25240
|
+
this._value = value;
|
24221
25241
|
};
|
24222
|
-
|
25242
|
+
GIPITextareaComponent.prototype.registerOnChange = function (fn) {
|
24223
25243
|
this.onChange = fn;
|
24224
25244
|
};
|
24225
|
-
|
25245
|
+
GIPITextareaComponent.prototype.registerOnTouched = function (fn) {
|
24226
25246
|
this.onTouched = fn;
|
24227
25247
|
};
|
24228
|
-
|
25248
|
+
GIPITextareaComponent.prototype.setDisabledState = function (isDisabled) {
|
24229
25249
|
this.disabled = isDisabled;
|
24230
25250
|
this._changeDetectorRef.markForCheck();
|
24231
25251
|
};
|
24232
|
-
|
24233
|
-
|
24234
|
-
|
24235
|
-
to = this._roundToStep(to);
|
24236
|
-
// if ((to - from) > this.maxRange) {
|
24237
|
-
// from = to - this.maxRange;
|
24238
|
-
// }
|
24239
|
-
this._fillSlider();
|
24240
|
-
this._setToggleAccessible();
|
24241
|
-
if (from > to) {
|
24242
|
-
this.fromValue = to;
|
24243
|
-
}
|
24244
|
-
this.fromSlider.nativeElement.value = this.fromValue.toString();
|
24245
|
-
this._notifyValueChange();
|
24246
|
-
};
|
24247
|
-
GIPIRangeSliderComponent.prototype.controlToInput = function (isByNgModel) {
|
24248
|
-
var _a = __read(isByNgModel ? [this.fromValue, this.toValue] : this._getParsed(this.fromSlider.nativeElement, this.toSlider.nativeElement), 2), from = _a[0], to = _a[1];
|
24249
|
-
from = this._roundToStep(from);
|
24250
|
-
to = this._roundToStep(to);
|
24251
|
-
// if ((to - from) > this.maxRange) {
|
24252
|
-
// to = from + this.maxRange;
|
24253
|
-
// }
|
24254
|
-
this._fillSlider();
|
24255
|
-
this._setToggleAccessible();
|
24256
|
-
if (from <= to) {
|
24257
|
-
this.toValue = to;
|
24258
|
-
}
|
24259
|
-
else {
|
24260
|
-
this.toValue = from;
|
24261
|
-
}
|
24262
|
-
this.toSlider.nativeElement.value = this.toValue.toString();
|
24263
|
-
this._notifyValueChange();
|
24264
|
-
};
|
24265
|
-
GIPIRangeSliderComponent.prototype.controlFromSlider = function () {
|
24266
|
-
var _a = __read(this._getParsed(this.fromSlider.nativeElement, this.toSlider.nativeElement), 2), from = _a[0], to = _a[1];
|
24267
|
-
from = this._roundToStep(from);
|
24268
|
-
to = this._roundToStep(to);
|
24269
|
-
if ((to - from) > this.maxRange) {
|
24270
|
-
from = to - this.maxRange;
|
24271
|
-
}
|
24272
|
-
this._fillSlider();
|
24273
|
-
this._setToggleAccessible();
|
24274
|
-
if ((to - from) === this.maxRange) {
|
24275
|
-
var _b = __read(this._getParsed(this.fromSlider.nativeElement, this.toSlider.nativeElement), 2), from_1 = _b[0], to_1 = _b[1];
|
24276
|
-
from_1 = this._roundToStep(from_1);
|
24277
|
-
to_1 = this._roundToStep(to_1);
|
24278
|
-
if ((to_1 - from_1) > this.maxRange) {
|
24279
|
-
to_1 = from_1 + this.maxRange;
|
24280
|
-
}
|
24281
|
-
this._fillSlider();
|
24282
|
-
if (from_1 <= to_1) {
|
24283
|
-
this.toValue = to_1;
|
24284
|
-
}
|
24285
|
-
else {
|
24286
|
-
this.toValue = from_1;
|
24287
|
-
}
|
24288
|
-
this.toSlider.nativeElement.value = this.toValue.toString();
|
24289
|
-
}
|
24290
|
-
if (from >= to) {
|
24291
|
-
this.fromValue = to;
|
24292
|
-
}
|
24293
|
-
else {
|
24294
|
-
this.fromValue = from;
|
24295
|
-
}
|
24296
|
-
this.fromSlider.nativeElement.value = this.fromValue.toString();
|
24297
|
-
this._notifyValueChange();
|
24298
|
-
};
|
24299
|
-
GIPIRangeSliderComponent.prototype.controlToSlider = function () {
|
24300
|
-
var _a = __read(this._getParsed(this.fromSlider.nativeElement, this.toSlider.nativeElement), 2), from = _a[0], to = _a[1];
|
24301
|
-
from = this._roundToStep(from);
|
24302
|
-
to = this._roundToStep(to);
|
24303
|
-
if ((to - from) > this.maxRange) {
|
24304
|
-
to = from + this.maxRange;
|
24305
|
-
}
|
24306
|
-
this._fillSlider();
|
24307
|
-
this._setToggleAccessible();
|
24308
|
-
if ((to - from) === this.maxRange) {
|
24309
|
-
var _b = __read(this._getParsed(this.fromSlider.nativeElement, this.toSlider.nativeElement), 2), from_2 = _b[0], to_2 = _b[1];
|
24310
|
-
from_2 = this._roundToStep(from_2);
|
24311
|
-
to_2 = this._roundToStep(to_2);
|
24312
|
-
if ((to_2 - from_2) > this.maxRange) {
|
24313
|
-
from_2 = to_2 - this.maxRange;
|
24314
|
-
}
|
24315
|
-
this._fillSlider();
|
24316
|
-
if (from_2 >= to_2) {
|
24317
|
-
this.fromValue = to_2;
|
24318
|
-
}
|
24319
|
-
else {
|
24320
|
-
this.fromValue = from_2;
|
24321
|
-
}
|
24322
|
-
this.fromSlider.nativeElement.value = this.fromValue.toString();
|
24323
|
-
}
|
24324
|
-
if (from <= to) {
|
24325
|
-
this.toValue = to;
|
24326
|
-
}
|
24327
|
-
else {
|
24328
|
-
this.toValue = from;
|
25252
|
+
GIPITextareaComponent.prototype._checkSpaceDrop = function (value) {
|
25253
|
+
if (this.spaceDrop && value) {
|
25254
|
+
return value.replace(/\s/g, '');
|
24329
25255
|
}
|
24330
|
-
|
24331
|
-
this._notifyValueChange();
|
24332
|
-
};
|
24333
|
-
GIPIRangeSliderComponent.prototype._getParsed = function (currentFrom, currentTo) {
|
24334
|
-
var from = parseInt(currentFrom.value, 10);
|
24335
|
-
var to = parseInt(currentTo.value, 10);
|
24336
|
-
return [from, to];
|
24337
|
-
};
|
24338
|
-
GIPIRangeSliderComponent.prototype._fillSlider = function () {
|
24339
|
-
var fromSliderEl = this.fromSlider.nativeElement;
|
24340
|
-
var toSliderEl = this.toSlider.nativeElement;
|
24341
|
-
var rangeDistance = Number(toSliderEl.max) - Number(toSliderEl.min);
|
24342
|
-
var fromPosition = (this.fromValue - Number(fromSliderEl.min));
|
24343
|
-
var toPosition = (this.toValue - Number(toSliderEl.min));
|
24344
|
-
var sliderColor = '#e0e1e2';
|
24345
|
-
var rangeColor = '#f1a0a6';
|
24346
|
-
toSliderEl.style.background = "linear-gradient(\n to right,\n " + sliderColor + " 0%,\n " + sliderColor + " " + (fromPosition) / (rangeDistance) * 100 + "%,\n " + rangeColor + " " + ((fromPosition) / (rangeDistance)) * 100 + "%,\n " + rangeColor + " " + (toPosition) / (rangeDistance) * 100 + "%,\n " + sliderColor + " " + (toPosition) / (rangeDistance) * 100 + "%,\n " + sliderColor + " 100%)";
|
25256
|
+
return value;
|
24347
25257
|
};
|
24348
|
-
|
24349
|
-
|
24350
|
-
|
24351
|
-
var fromValue = parseInt(fromInput.value, 10);
|
24352
|
-
var toValue = parseInt(toInput.value, 10);
|
24353
|
-
if (fromValue <= parseInt(fromInput.min, 10) && toValue <= parseInt(toInput.min, 10)) {
|
24354
|
-
// Ambos estão no mínimo
|
24355
|
-
fromInput.style.zIndex = '1';
|
24356
|
-
toInput.style.zIndex = '2';
|
24357
|
-
}
|
24358
|
-
else if (fromValue >= parseInt(fromInput.max, 10) && toValue >= parseInt(toInput.max, 10)) {
|
24359
|
-
// Ambos estão no máximo
|
24360
|
-
fromInput.style.zIndex = '2';
|
24361
|
-
toInput.style.zIndex = '1';
|
24362
|
-
}
|
24363
|
-
else {
|
24364
|
-
// Caso geral
|
24365
|
-
fromInput.style.zIndex = '2';
|
24366
|
-
toInput.style.zIndex = '1';
|
25258
|
+
GIPITextareaComponent.prototype._checkUppercase = function (value) {
|
25259
|
+
if (this.upperCase && value) {
|
25260
|
+
return value.toUpperCase();
|
24367
25261
|
}
|
25262
|
+
return value;
|
24368
25263
|
};
|
24369
|
-
|
24370
|
-
|
24371
|
-
|
24372
|
-
|
24373
|
-
|
24374
|
-
};
|
24375
|
-
|
24376
|
-
|
24377
|
-
};
|
24378
|
-
var GIPIRangeSliderComponent_1;
|
24379
|
-
GIPIRangeSliderComponent.ctorParameters = function () { return [
|
25264
|
+
GIPITextareaComponent.prototype._checkLowercase = function (value) {
|
25265
|
+
if (this.lowerCase && value) {
|
25266
|
+
return value.toLowerCase();
|
25267
|
+
}
|
25268
|
+
return value;
|
25269
|
+
};
|
25270
|
+
var GIPITextareaComponent_1;
|
25271
|
+
GIPITextareaComponent.ctorParameters = function () { return [
|
24380
25272
|
{ type: core.ElementRef },
|
24381
25273
|
{ type: core.ChangeDetectorRef }
|
24382
25274
|
]; };
|
24383
25275
|
__decorate([
|
24384
|
-
core.
|
24385
|
-
__metadata("design:type",
|
24386
|
-
],
|
24387
|
-
__decorate([
|
24388
|
-
core.ViewChild('toSlider', { static: false }),
|
24389
|
-
__metadata("design:type", core.ElementRef)
|
24390
|
-
], GIPIRangeSliderComponent.prototype, "toSlider", void 0);
|
25276
|
+
core.Input(),
|
25277
|
+
__metadata("design:type", String)
|
25278
|
+
], GIPITextareaComponent.prototype, "id", void 0);
|
24391
25279
|
__decorate([
|
24392
25280
|
core.Input(),
|
24393
25281
|
__metadata("design:type", String)
|
24394
|
-
],
|
25282
|
+
], GIPITextareaComponent.prototype, "name", void 0);
|
24395
25283
|
__decorate([
|
24396
25284
|
core.Input(),
|
24397
25285
|
__metadata("design:type", String)
|
24398
|
-
],
|
25286
|
+
], GIPITextareaComponent.prototype, "label", void 0);
|
24399
25287
|
__decorate([
|
24400
25288
|
core.Input(),
|
24401
25289
|
__metadata("design:type", String)
|
24402
|
-
],
|
25290
|
+
], GIPITextareaComponent.prototype, "placeholder", void 0);
|
25291
|
+
__decorate([
|
25292
|
+
core.Input(),
|
25293
|
+
__metadata("design:type", Number)
|
25294
|
+
], GIPITextareaComponent.prototype, "cols", void 0);
|
25295
|
+
__decorate([
|
25296
|
+
core.Input(),
|
25297
|
+
__metadata("design:type", Number)
|
25298
|
+
], GIPITextareaComponent.prototype, "rows", void 0);
|
24403
25299
|
__decorate([
|
24404
25300
|
core.Input(),
|
24405
25301
|
__metadata("design:type", String)
|
24406
|
-
],
|
25302
|
+
], GIPITextareaComponent.prototype, "help", void 0);
|
24407
25303
|
__decorate([
|
24408
25304
|
core.Input(),
|
24409
25305
|
__metadata("design:type", Number)
|
24410
|
-
],
|
25306
|
+
], GIPITextareaComponent.prototype, "maxlength", void 0);
|
24411
25307
|
__decorate([
|
24412
25308
|
core.Input(),
|
24413
25309
|
__metadata("design:type", Number)
|
24414
|
-
],
|
25310
|
+
], GIPITextareaComponent.prototype, "minlength", void 0);
|
24415
25311
|
__decorate([
|
24416
25312
|
core.Input(),
|
24417
|
-
__metadata("design:type",
|
24418
|
-
__metadata("design:paramtypes", [
|
24419
|
-
],
|
25313
|
+
__metadata("design:type", String),
|
25314
|
+
__metadata("design:paramtypes", [String])
|
25315
|
+
], GIPITextareaComponent.prototype, "resize", null);
|
24420
25316
|
__decorate([
|
24421
|
-
core.Input(
|
24422
|
-
__metadata("design:type",
|
24423
|
-
__metadata("design:paramtypes", [
|
24424
|
-
],
|
25317
|
+
core.Input(),
|
25318
|
+
__metadata("design:type", String),
|
25319
|
+
__metadata("design:paramtypes", [String])
|
25320
|
+
], GIPITextareaComponent.prototype, "minHeight", null);
|
24425
25321
|
__decorate([
|
24426
|
-
core.Input(
|
24427
|
-
__metadata("design:type",
|
24428
|
-
__metadata("design:paramtypes", [
|
24429
|
-
],
|
25322
|
+
core.Input(),
|
25323
|
+
__metadata("design:type", String),
|
25324
|
+
__metadata("design:paramtypes", [String])
|
25325
|
+
], GIPITextareaComponent.prototype, "height", null);
|
24430
25326
|
__decorate([
|
24431
25327
|
core.Input(),
|
24432
|
-
__metadata("design:type",
|
24433
|
-
__metadata("design:paramtypes", [
|
24434
|
-
],
|
25328
|
+
__metadata("design:type", String),
|
25329
|
+
__metadata("design:paramtypes", [String])
|
25330
|
+
], GIPITextareaComponent.prototype, "maxHeight", null);
|
25331
|
+
__decorate([
|
25332
|
+
core.Input(),
|
25333
|
+
__metadata("design:type", String),
|
25334
|
+
__metadata("design:paramtypes", [String])
|
25335
|
+
], GIPITextareaComponent.prototype, "autocomplete", null);
|
24435
25336
|
__decorate([
|
24436
25337
|
core.Input(),
|
24437
25338
|
__metadata("design:type", Boolean),
|
24438
25339
|
__metadata("design:paramtypes", [Boolean])
|
24439
|
-
],
|
25340
|
+
], GIPITextareaComponent.prototype, "autofocus", null);
|
24440
25341
|
__decorate([
|
24441
25342
|
core.Input(),
|
24442
25343
|
__metadata("design:type", Boolean),
|
24443
25344
|
__metadata("design:paramtypes", [Boolean])
|
24444
|
-
],
|
24445
|
-
|
25345
|
+
], GIPITextareaComponent.prototype, "readOnly", null);
|
25346
|
+
__decorate([
|
25347
|
+
core.Input(),
|
25348
|
+
__metadata("design:type", Boolean),
|
25349
|
+
__metadata("design:paramtypes", [Boolean])
|
25350
|
+
], GIPITextareaComponent.prototype, "required", null);
|
25351
|
+
__decorate([
|
25352
|
+
core.Input(),
|
25353
|
+
__metadata("design:type", Boolean),
|
25354
|
+
__metadata("design:paramtypes", [Boolean])
|
25355
|
+
], GIPITextareaComponent.prototype, "disabled", null);
|
25356
|
+
__decorate([
|
25357
|
+
core.Input(),
|
25358
|
+
__metadata("design:type", Boolean),
|
25359
|
+
__metadata("design:paramtypes", [Boolean])
|
25360
|
+
], GIPITextareaComponent.prototype, "lowerCase", null);
|
25361
|
+
__decorate([
|
25362
|
+
core.Input(),
|
25363
|
+
__metadata("design:type", Boolean),
|
25364
|
+
__metadata("design:paramtypes", [Boolean])
|
25365
|
+
], GIPITextareaComponent.prototype, "upperCase", null);
|
25366
|
+
__decorate([
|
25367
|
+
core.Input(),
|
25368
|
+
__metadata("design:type", Boolean),
|
25369
|
+
__metadata("design:paramtypes", [Boolean])
|
25370
|
+
], GIPITextareaComponent.prototype, "spaceDrop", null);
|
25371
|
+
__decorate([
|
25372
|
+
core.Input(),
|
25373
|
+
__metadata("design:type", Object),
|
25374
|
+
__metadata("design:paramtypes", [Object])
|
25375
|
+
], GIPITextareaComponent.prototype, "value", null);
|
25376
|
+
GIPITextareaComponent = GIPITextareaComponent_1 = __decorate([
|
24446
25377
|
core.Component({
|
24447
|
-
selector: 'gipi-
|
24448
|
-
exportAs: '
|
24449
|
-
template: "<label
|
25378
|
+
selector: 'gipi-textarea',
|
25379
|
+
exportAs: 'gipiTextarea',
|
25380
|
+
template: "<label class=\"textarea-label\"\n *ngIf=\"label\"\n [attr.for]=\"id\">\n {{ label }}\n <span *ngIf=\"required\"> * </span>\n</label>\n\n<textarea class=\"textarea-element\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [placeholder]=\"placeholder\"\n [cols]=\"cols\"\n [rows]=\"rows\"\n [class.resize-none]=\"resize === 'none'\"\n [class.resize-both]=\"resize === 'both'\"\n [class.resize-horizontal]=\"resize === 'horizontal'\"\n [class.resize-vertical]=\"resize === 'vertical'\"\n [style.min-height.px]=\"minHeight\"\n [style.height.px]=\"height\"\n [style.max-height.px]=\"maxHeight\"\n [minlength]=\"minlength\"\n [maxlength]=\"maxlength\"\n [disabled]=\"disabled\"\n [required]=\"required\"\n [readOnly]=\"readOnly\"\n [attr.autocomplete]=\"autocomplete\"\n [autofocus]=\"autofocus\"\n [(ngModel)]=\"value\"\n [value]=\"value\">\n </textarea>\n\n<small *ngIf=\"help\"\n class=\"textarea-help\">\n {{ help }}\n</small>",
|
24450
25381
|
providers: [
|
24451
25382
|
{
|
24452
25383
|
provide: forms.NG_VALUE_ACCESSOR,
|
24453
|
-
useExisting: core.forwardRef(function () { return
|
25384
|
+
useExisting: core.forwardRef(function () { return GIPITextareaComponent_1; }),
|
24454
25385
|
multi: true
|
24455
|
-
}
|
25386
|
+
}
|
24456
25387
|
],
|
24457
25388
|
host: {
|
24458
|
-
'class': 'gipi-
|
25389
|
+
'class': 'gipi-textarea',
|
24459
25390
|
},
|
24460
25391
|
changeDetection: core.ChangeDetectionStrategy.OnPush,
|
24461
|
-
styles: [":host{display:flex;flex-direction:column;gap:.8rem;font-size:1.4rem;color:#696969}:host .
|
25392
|
+
styles: [":host{display:flex;flex-direction:column;gap:.8rem;font-size:1.4rem;color:#696969}:host .textarea-label{display:flex;align-items:center;gap:.4rem;color:#131313;line-height:1.6rem}:host .textarea-label>span{font-size:1.6rem;line-height:1.6rem;color:#d14014}:host .textarea-element{display:flex;font-family:inherit;font-size:inherit;color:inherit;padding:.75rem .8rem;background:#fff;border:1px solid rgba(0,0,0,.12);transition:background-color .2s,color .2s,border-color .2s,box-shadow .2s;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:6px;caret-color:#696969;max-height:12rem;min-height:6rem;resize:vertical;outline:0;overflow:auto}:host .textarea-element:not(:disabled):hover{border-color:#6d6f73}:host .textarea-element:not(:disabled).ng-dirty.ng-invalid:enabled:hover,:host .textarea-element:not(:disabled):invalid:enabled:hover{border-color:#e07f62}:host .textarea-element:not(:disabled):enabled:focus{outline:0;outline-offset:0;box-shadow:0 0 0 .2rem #e0e1e2;border-color:#6d6f73}:host .textarea-element:not(:disabled).ng-dirty.ng-invalid:enabled,:host .textarea-element:not(:disabled):invalid:enabled{border-color:#d14014}:host .textarea-element:not(:disabled).ng-dirty.ng-invalid:enabled:focus,:host .textarea-element:not(:disabled):invalid:enabled:focus{outline:0;outline-offset:0;box-shadow:0 0 0 .2rem #f1c4b6;border-color:#d14014}:host .textarea-element:disabled{color:#bbbdc1!important;border-color:#e0e1e2!important;background-color:#f5f5f6!important;cursor:not-allowed}:host .textarea-element.resize-none{resize:none}:host .textarea-element.resize-both{resize:both}:host .textarea-element.resize-horizontal{resize:horizontal}:host .textarea-element.resize-vertical{resize:vertical}:host .textarea-help{flex:1;font-size:1rem;font-weight:500;margin-top:-.4rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}::-webkit-input-placeholder{color:#bbbdc1}:-moz-placeholder{color:#bbbdc1}::-moz-placeholder{color:#bbbdc1}:-ms-input-placeholder{color:#bbbdc1}"]
|
24462
25393
|
}),
|
24463
25394
|
__metadata("design:paramtypes", [core.ElementRef,
|
24464
25395
|
core.ChangeDetectorRef])
|
24465
|
-
],
|
24466
|
-
return
|
25396
|
+
], GIPITextareaComponent);
|
25397
|
+
return GIPITextareaComponent;
|
24467
25398
|
}());
|
24468
25399
|
|
24469
25400
|
|
@@ -24507,6 +25438,14 @@
|
|
24507
25438
|
GIPIBadgeComponent,
|
24508
25439
|
GIPIRangeSliderComponent,
|
24509
25440
|
GIPIRangePageComponent,
|
25441
|
+
GIPISlideToggleComponent,
|
25442
|
+
GIPIEmptyStateComponent,
|
25443
|
+
GIPICardComponent,
|
25444
|
+
GIPITextareaComponent,
|
25445
|
+
GIPISplitButtonComponent,
|
25446
|
+
// Tabs
|
25447
|
+
GIPITabGroupComponent,
|
25448
|
+
GIPITabComponent,
|
24510
25449
|
// Table
|
24511
25450
|
GIPITableHeaderComponent,
|
24512
25451
|
GIPITableBodyComponent,
|
@@ -24522,6 +25461,7 @@
|
|
24522
25461
|
GIPIFileDragAndDropDirective,
|
24523
25462
|
GIPIInfiniteScrollDirective,
|
24524
25463
|
GIPIPaginationControlsDirective,
|
25464
|
+
GIPIDynamicTabDirective,
|
24525
25465
|
];
|
24526
25466
|
var GIPIPipes = [
|
24527
25467
|
GIPIPaginatePipe,
|
@@ -24569,9 +25509,6 @@
|
|
24569
25509
|
RadioGroupEntityComponent,
|
24570
25510
|
RadioGroupEnumComponent,
|
24571
25511
|
SlideToggleComponent,
|
24572
|
-
TabGroupComponent,
|
24573
|
-
TabComponent,
|
24574
|
-
DynamicTabDirective,
|
24575
25512
|
IconComponent,
|
24576
25513
|
StepperComponent,
|
24577
25514
|
TextareaComponent,
|
@@ -24584,7 +25521,6 @@
|
|
24584
25521
|
SpaceDropDirective,
|
24585
25522
|
OverlayPanelComponent,
|
24586
25523
|
ItssTemplate,
|
24587
|
-
SelectButtonComponent,
|
24588
25524
|
SelectMonthPeriodComponent,
|
24589
25525
|
InputSelectInfiniteScrollDirective,
|
24590
25526
|
TableScrolledComponent,
|
@@ -24636,8 +25572,6 @@
|
|
24636
25572
|
RadioGroupEntityComponent,
|
24637
25573
|
RadioGroupEnumComponent,
|
24638
25574
|
SlideToggleComponent,
|
24639
|
-
TabGroupComponent,
|
24640
|
-
TabComponent,
|
24641
25575
|
IconComponent,
|
24642
25576
|
StepperComponent,
|
24643
25577
|
TextareaComponent,
|
@@ -24647,7 +25581,6 @@
|
|
24647
25581
|
angularMentions.MentionModule,
|
24648
25582
|
OverlayPanelComponent,
|
24649
25583
|
ItssTemplate,
|
24650
|
-
SelectButtonComponent,
|
24651
25584
|
SelectMonthPeriodComponent,
|
24652
25585
|
InputSelectInfiniteScrollDirective,
|
24653
25586
|
TableScrolledComponent,
|
@@ -24662,8 +25595,8 @@
|
|
24662
25595
|
],
|
24663
25596
|
entryComponents: [
|
24664
25597
|
GIPIConfirmationDialogComponent,
|
24665
|
-
|
24666
|
-
|
25598
|
+
GIPITabGroupComponent,
|
25599
|
+
GIPITabComponent,
|
24667
25600
|
PopoverComponent,
|
24668
25601
|
],
|
24669
25602
|
providers: [
|
@@ -25534,33 +26467,27 @@
|
|
25534
26467
|
return this.baseService.httpClient.post(this.url('find-all', version), filter, this.options()).pipe(operators.map(this.handleMapper), operators.takeUntil(this.handleDestroy), operators.catchError(this.handleError));
|
25535
26468
|
};
|
25536
26469
|
GIPIAbstractCrudService.prototype.findAllEnabled = function (page, size, version) {
|
25537
|
-
|
25538
|
-
|
25539
|
-
|
25540
|
-
|
25541
|
-
|
25542
|
-
|
25543
|
-
return this.baseService.httpClient.get(this.url("find-all-enabled
|
26470
|
+
var validatedPage = Math.max(page, 0);
|
26471
|
+
var validatedSize = Math.max(size, 10);
|
26472
|
+
var params = new URLSearchParams();
|
26473
|
+
params.set('page', validatedPage.toString());
|
26474
|
+
params.set('size', validatedSize.toString());
|
26475
|
+
var queryString = !StringUtil.isEmpty(params.toString()) ? "?" + params.toString() : '';
|
26476
|
+
return this.baseService.httpClient.get(this.url("find-all-enabled" + queryString, version), this.options()).pipe(operators.map(this.handleMapper), operators.takeUntil(this.handleDestroy), operators.catchError(this.handleError));
|
25544
26477
|
};
|
25545
26478
|
GIPIAbstractCrudService.prototype.findByValue = function (value, page, size, sort, version) {
|
25546
|
-
var
|
25547
|
-
|
25548
|
-
|
25549
|
-
|
25550
|
-
|
25551
|
-
|
25552
|
-
|
25553
|
-
if ((!page) || (page && (page < 0))) {
|
25554
|
-
page = 0;
|
25555
|
-
}
|
25556
|
-
if ((!size) || (size && (size <= 0))) {
|
25557
|
-
size = 10;
|
25558
|
-
}
|
25559
|
-
var lSort = '';
|
26479
|
+
var formattedValue = !StringUtil.isEmpty(value) ? value.trim() : '';
|
26480
|
+
var validatedPage = Math.max(page, 0);
|
26481
|
+
var validatedSize = Math.max(size, 10);
|
26482
|
+
var params = new URLSearchParams();
|
26483
|
+
params.set('value', formattedValue);
|
26484
|
+
params.set('page', validatedPage.toString());
|
26485
|
+
params.set('size', validatedSize.toString());
|
25560
26486
|
if (!ObjectUtil.isNull(sort) && !StringUtil.isEmpty(sort.field)) {
|
25561
|
-
|
26487
|
+
params.set('sort', sort.field + "," + sort.direction);
|
25562
26488
|
}
|
25563
|
-
|
26489
|
+
var queryString = !StringUtil.isEmpty(params.toString()) ? "?" + params.toString() : '';
|
26490
|
+
return this.baseService.httpClient.get(this.url("find-by-value" + queryString, version), this.options()).pipe(operators.map(this.handleMapper), operators.takeUntil(this.handleDestroy), operators.catchError(this.handleError));
|
25564
26491
|
};
|
25565
26492
|
/**
|
25566
26493
|
* Refers to the enable-or-disable endpoint
|
@@ -26853,6 +27780,18 @@
|
|
26853
27780
|
return MenuDTO;
|
26854
27781
|
}(AbstractDTO));
|
26855
27782
|
|
27783
|
+
var TabDTO = /** @class */ (function (_super) {
|
27784
|
+
__extends(TabDTO, _super);
|
27785
|
+
function TabDTO() {
|
27786
|
+
var _this = _super !== null && _super.apply(this, arguments) || this;
|
27787
|
+
_this.active = false;
|
27788
|
+
_this.closeable = false;
|
27789
|
+
_this.disabled = false;
|
27790
|
+
return _this;
|
27791
|
+
}
|
27792
|
+
return TabDTO;
|
27793
|
+
}(AbstractDTO));
|
27794
|
+
|
26856
27795
|
var TableColumnDTO = /** @class */ (function (_super) {
|
26857
27796
|
__extends(TableColumnDTO, _super);
|
26858
27797
|
function TableColumnDTO(name, property, value, sortable, hiddenSm, visible, width, marginLeft, marginRight, align, template, templateHeader, sliceLength, action) {
|
@@ -27285,137 +28224,6 @@
|
|
27285
28224
|
return EmailUtil;
|
27286
28225
|
}());
|
27287
28226
|
|
27288
|
-
/** @dynamic */
|
27289
|
-
var PhoneUtil = /** @class */ (function () {
|
27290
|
-
function PhoneUtil() {
|
27291
|
-
}
|
27292
|
-
PhoneUtil.removeCharacters = function (value) {
|
27293
|
-
if (StringUtil.isEmpty(value)) {
|
27294
|
-
return '';
|
27295
|
-
}
|
27296
|
-
return value.replace(/\D/g, '');
|
27297
|
-
};
|
27298
|
-
PhoneUtil.maskLib = function (phoneNumber, state, country) {
|
27299
|
-
if (country === void 0) { country = 'BR'; }
|
27300
|
-
var exampleNumber;
|
27301
|
-
if (!StringUtil.isEmpty(phoneNumber)) {
|
27302
|
-
var parsedNumber = libphonenumberJs.parsePhoneNumberFromString(phoneNumber, country);
|
27303
|
-
if (parsedNumber) {
|
27304
|
-
exampleNumber = parsedNumber;
|
27305
|
-
}
|
27306
|
-
}
|
27307
|
-
else {
|
27308
|
-
exampleNumber = libphonenumberJs.getExampleNumber(country, state);
|
27309
|
-
}
|
27310
|
-
if (exampleNumber) {
|
27311
|
-
var formattedNumber = exampleNumber.formatNational();
|
27312
|
-
return formattedNumber.replace(/\d/g, '0');
|
27313
|
-
}
|
27314
|
-
else {
|
27315
|
-
throw new Error('Estado não suportado ou código de estado inválido.');
|
27316
|
-
}
|
27317
|
-
};
|
27318
|
-
PhoneUtil.formatLib = function (phoneNumber, country) {
|
27319
|
-
if (country === void 0) { country = 'BR'; }
|
27320
|
-
try {
|
27321
|
-
var parsedNumber = libphonenumberJs.parsePhoneNumberFromString(phoneNumber, country);
|
27322
|
-
if (parsedNumber) {
|
27323
|
-
return parsedNumber.formatNational();
|
27324
|
-
}
|
27325
|
-
else {
|
27326
|
-
throw new Error('Número de telefone inválido.');
|
27327
|
-
}
|
27328
|
-
}
|
27329
|
-
catch (error) {
|
27330
|
-
throw new Error('Erro ao formatar o número de telefone: ' + error.message);
|
27331
|
-
}
|
27332
|
-
};
|
27333
|
-
PhoneUtil.format = function (number, mask) {
|
27334
|
-
var numberNotFormatted = NumberUtil.onlyNumbers(number);
|
27335
|
-
var phoneFormatted = '';
|
27336
|
-
if ((numberNotFormatted.length < 8) ||
|
27337
|
-
(numberNotFormatted.length > 12) ||
|
27338
|
-
(!this.isPossible(numberNotFormatted) && !this.isValid(numberNotFormatted))) {
|
27339
|
-
return numberNotFormatted;
|
27340
|
-
}
|
27341
|
-
if (StringUtil.isEmpty(mask)) {
|
27342
|
-
mask = this.mask(numberNotFormatted);
|
27343
|
-
}
|
27344
|
-
for (var i = 0, j = 0; i < mask.length && j < numberNotFormatted.length; i++) {
|
27345
|
-
phoneFormatted += mask.charAt(i) === '0' ? numberNotFormatted.charAt(j++) : mask.charAt(i);
|
27346
|
-
}
|
27347
|
-
return phoneFormatted;
|
27348
|
-
};
|
27349
|
-
PhoneUtil.mask = function (phone) {
|
27350
|
-
var specialPrefixes = ['0900', '0800', '0700', '0600', '0500', '0400', '0300', '0200', '0100'];
|
27351
|
-
var phoneAux = this.removeCharacters(phone.replace(/\D/g, ''));
|
27352
|
-
if ((phoneAux.length < 8) ||
|
27353
|
-
(phoneAux.length > 12) ||
|
27354
|
-
(!this.isPossible(phoneAux) && !this.isValid(phoneAux))) {
|
27355
|
-
return '0*';
|
27356
|
-
}
|
27357
|
-
var existInArray = specialPrefixes.some(function (prefix) { return phoneAux.startsWith(prefix); });
|
27358
|
-
if (existInArray) {
|
27359
|
-
return '0000 000 0000'; // Para números especiais como 0800
|
27360
|
-
}
|
27361
|
-
switch (phoneAux.length) {
|
27362
|
-
case 8: return '0000-0000';
|
27363
|
-
case 9: return '0 0000-0000';
|
27364
|
-
case 10: return '(00) 0000-0000';
|
27365
|
-
case 11: return '(00) 0 0000-0000';
|
27366
|
-
case 12: return '(000) 0 0000-0000';
|
27367
|
-
default: return '0*';
|
27368
|
-
}
|
27369
|
-
};
|
27370
|
-
PhoneUtil.isPossible = function (phoneNumber, country) {
|
27371
|
-
if (country === void 0) { country = 'BR'; }
|
27372
|
-
try {
|
27373
|
-
var parsedNumber = libphonenumberJs.parsePhoneNumberFromString(phoneNumber, country);
|
27374
|
-
return parsedNumber ? parsedNumber.isPossible() : false;
|
27375
|
-
}
|
27376
|
-
catch (error) {
|
27377
|
-
return false;
|
27378
|
-
}
|
27379
|
-
};
|
27380
|
-
PhoneUtil.isValid = function (phoneNumber, country) {
|
27381
|
-
if (country === void 0) { country = 'BR'; }
|
27382
|
-
try {
|
27383
|
-
var parsedNumber = libphonenumberJs.parsePhoneNumberFromString(phoneNumber, country);
|
27384
|
-
return parsedNumber ? parsedNumber.isValid() : false;
|
27385
|
-
}
|
27386
|
-
catch (error) {
|
27387
|
-
return false;
|
27388
|
-
}
|
27389
|
-
};
|
27390
|
-
PhoneUtil.getType = function (phoneNumber, country) {
|
27391
|
-
if (country === void 0) { country = 'BR'; }
|
27392
|
-
try {
|
27393
|
-
var parsedNumber = libphonenumberJs.parsePhoneNumberFromString(phoneNumber, country);
|
27394
|
-
return parsedNumber ? parsedNumber.getType() : null;
|
27395
|
-
}
|
27396
|
-
catch (error) {
|
27397
|
-
return null;
|
27398
|
-
}
|
27399
|
-
};
|
27400
|
-
PhoneUtil.isEqual = function (phoneNumber1, phoneNumber2, country) {
|
27401
|
-
if (country === void 0) { country = 'BR'; }
|
27402
|
-
try {
|
27403
|
-
var parsedNumber1 = libphonenumberJs.parsePhoneNumberFromString(phoneNumber1, country);
|
27404
|
-
var parsedNumber2 = libphonenumberJs.parsePhoneNumberFromString(phoneNumber2, country);
|
27405
|
-
if (parsedNumber1 && parsedNumber2) {
|
27406
|
-
return parsedNumber1.isEqual(parsedNumber2);
|
27407
|
-
}
|
27408
|
-
else {
|
27409
|
-
return false;
|
27410
|
-
}
|
27411
|
-
}
|
27412
|
-
catch (error) {
|
27413
|
-
return false;
|
27414
|
-
}
|
27415
|
-
};
|
27416
|
-
return PhoneUtil;
|
27417
|
-
}());
|
27418
|
-
|
27419
28227
|
/** @dynamic */
|
27420
28228
|
var TableColumnBuilder = /** @class */ (function () {
|
27421
28229
|
function TableColumnBuilder(breakpointObserverService) {
|
@@ -28155,7 +28963,6 @@
|
|
28155
28963
|
exports.DialogDTO = DialogDTO;
|
28156
28964
|
exports.DialogService = DialogService;
|
28157
28965
|
exports.DocumentUtil = DocumentUtil;
|
28158
|
-
exports.DynamicTabDirective = DynamicTabDirective;
|
28159
28966
|
exports.EmailUtil = EmailUtil;
|
28160
28967
|
exports.ErrorInterceptor = ErrorInterceptor;
|
28161
28968
|
exports.FilterDTO = FilterDTO;
|
@@ -28175,11 +28982,14 @@
|
|
28175
28982
|
exports.GIPIBaseService = GIPIBaseService;
|
28176
28983
|
exports.GIPIBreakpointService = GIPIBreakpointService;
|
28177
28984
|
exports.GIPIButtonComponent = GIPIButtonComponent;
|
28985
|
+
exports.GIPICardComponent = GIPICardComponent;
|
28178
28986
|
exports.GIPIColDirective = GIPIColDirective;
|
28179
28987
|
exports.GIPIConfirmationDialogComponent = GIPIConfirmationDialogComponent;
|
28180
28988
|
exports.GIPIConnectedOverlayScrollHandler = GIPIConnectedOverlayScrollHandler;
|
28181
28989
|
exports.GIPIDomHandler = GIPIDomHandler;
|
28182
28990
|
exports.GIPIDropdownMenuComponent = GIPIDropdownMenuComponent;
|
28991
|
+
exports.GIPIDynamicTabDirective = GIPIDynamicTabDirective;
|
28992
|
+
exports.GIPIEmptyStateComponent = GIPIEmptyStateComponent;
|
28183
28993
|
exports.GIPIExpansionPanelComponent = GIPIExpansionPanelComponent;
|
28184
28994
|
exports.GIPIFileDragAndDropComponent = GIPIFileDragAndDropComponent;
|
28185
28995
|
exports.GIPIFileService = GIPIFileService;
|
@@ -28219,8 +29029,12 @@
|
|
28219
29029
|
exports.GIPISessionStorageService = GIPISessionStorageService;
|
28220
29030
|
exports.GIPISidenavComponent = GIPISidenavComponent;
|
28221
29031
|
exports.GIPISidenavContainerComponent = GIPISidenavContainerComponent;
|
29032
|
+
exports.GIPISlideToggleComponent = GIPISlideToggleComponent;
|
28222
29033
|
exports.GIPISortModel = GIPISortModel;
|
29034
|
+
exports.GIPISplitButtonComponent = GIPISplitButtonComponent;
|
28223
29035
|
exports.GIPIStepperComponent = GIPIStepperComponent;
|
29036
|
+
exports.GIPITabComponent = GIPITabComponent;
|
29037
|
+
exports.GIPITabGroupComponent = GIPITabGroupComponent;
|
28224
29038
|
exports.GIPITableBodyComponent = GIPITableBodyComponent;
|
28225
29039
|
exports.GIPITableComponent = GIPITableComponent;
|
28226
29040
|
exports.GIPITableFooterComponent = GIPITableFooterComponent;
|
@@ -28228,6 +29042,7 @@
|
|
28228
29042
|
exports.GIPITablePaginationComponent = GIPITablePaginationComponent;
|
28229
29043
|
exports.GIPITableProgressBarComponent = GIPITableProgressBarComponent;
|
28230
29044
|
exports.GIPITemplateDirective = GIPITemplateDirective;
|
29045
|
+
exports.GIPITextareaComponent = GIPITextareaComponent;
|
28231
29046
|
exports.GIPIToolbarComponent = GIPIToolbarComponent;
|
28232
29047
|
exports.GIPITopNavComponent = GIPITopNavComponent;
|
28233
29048
|
exports.GIPIUserProfileComponent = GIPIUserProfileComponent;
|
@@ -28314,7 +29129,6 @@
|
|
28314
29129
|
exports.RangePage = RangePage;
|
28315
29130
|
exports.Role = Role;
|
28316
29131
|
exports.SelectButtonAddComponent = SelectButtonAddComponent;
|
28317
|
-
exports.SelectButtonComponent = SelectButtonComponent;
|
28318
29132
|
exports.SelectButtonNextBatchComponent = SelectButtonNextBatchComponent;
|
28319
29133
|
exports.SelectEntityComponent = SelectEntityComponent;
|
28320
29134
|
exports.SelectEntityPagedComponent = SelectEntityPagedComponent;
|
@@ -28330,9 +29144,8 @@
|
|
28330
29144
|
exports.StepperComponent = StepperComponent;
|
28331
29145
|
exports.StringUtil = StringUtil;
|
28332
29146
|
exports.SvgRegisterService = SvgRegisterService;
|
28333
|
-
exports.TabComponent = TabComponent;
|
28334
29147
|
exports.TabDTO = TabDTO;
|
28335
|
-
exports.
|
29148
|
+
exports.TabModel = TabModel;
|
28336
29149
|
exports.TableColumnBuilder = TableColumnBuilder;
|
28337
29150
|
exports.TableColumnBuilderModel = TableColumnBuilderModel;
|
28338
29151
|
exports.TableColumnDTO = TableColumnDTO;
|