@sankhyalabs/ezui 5.4.2 → 5.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/ez-grid.cjs.entry.js +43 -5
- package/dist/cjs/ezui.cjs.js +1 -1
- package/dist/cjs/filter-column.cjs.entry.js +25 -5
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/ez-grid/ez-grid.css +2 -5
- package/dist/collection/components/ez-grid/ez-grid.js +55 -4
- package/dist/collection/components/ez-grid/interfaces/ISelectionToastConfig.js +1 -0
- package/dist/collection/components/ez-grid/interfaces/index.js +2 -0
- package/dist/collection/components/ez-grid/subcomponents/filter-column.js +43 -5
- package/dist/collection/components/ez-grid/subcomponents/selection-counter.js +10 -2
- package/dist/custom-elements/index.js +70 -12
- package/dist/esm/ez-grid.entry.js +43 -5
- package/dist/esm/ezui.js +1 -1
- package/dist/esm/filter-column.entry.js +25 -5
- package/dist/esm/loader.js +1 -1
- package/dist/ezui/ezui.esm.js +1 -1
- package/dist/ezui/p-4c8b029b.entry.js +1 -0
- package/dist/ezui/{p-3aa4621d.entry.js → p-7c83718e.entry.js} +1 -1
- package/dist/types/components/ez-grid/ez-grid.d.ts +9 -1
- package/dist/types/components/ez-grid/interfaces/ISelectionToastConfig.d.ts +3 -0
- package/dist/types/components/ez-grid/interfaces/index.d.ts +2 -0
- package/dist/types/components/ez-grid/subcomponents/filter-column.d.ts +4 -0
- package/dist/types/components/ez-grid/subcomponents/selection-counter.d.ts +3 -2
- package/dist/types/components.d.ts +11 -1
- package/package.json +1 -1
- package/dist/ezui/p-c0acdb46.entry.js +0 -1
|
@@ -119936,13 +119936,21 @@ class AgGridController {
|
|
|
119936
119936
|
}
|
|
119937
119937
|
|
|
119938
119938
|
const SelectionCounter = (props) => {
|
|
119939
|
-
const { selectionCount, currentPageSelected,
|
|
119939
|
+
const { selectionCount, currentPageSelected, allRecordSelected, paginationInfo, canSelectAll, onSelectAll, onSelectPage, onClearAll, onClose } = props;
|
|
119940
|
+
const { total, hasMore } = paginationInfo || {};
|
|
119941
|
+
const shouldRenderSelectionButton = () => {
|
|
119942
|
+
if ((!allRecordSelected && selectionCount === total) || (allRecordSelected && !hasMore))
|
|
119943
|
+
return false;
|
|
119944
|
+
if (canSelectAll !== undefined)
|
|
119945
|
+
return canSelectAll;
|
|
119946
|
+
return !!paginationInfo && (currentPageSelected || allRecordSelected);
|
|
119947
|
+
};
|
|
119940
119948
|
return (index.h("div", Object.assign({ class: "ez-box ez-box--shadow-small" }, getElementID("ezGridSelectionCounter")),
|
|
119941
119949
|
index.h("div", { class: "ez-flex ez-flex--align-items-center ez-size-width--full ez-padding-horizontal--medium" },
|
|
119942
119950
|
index.h("div", { class: "ez-flex ez-flex--wrap ez-flex--align-items-baseline ez-flex--justify-center" },
|
|
119943
119951
|
index.h("label", Object.assign({ innerHTML: getText(selectionCount, allRecordSelected), class: "ez-text ez-text--primary ez-text--medium ez-margin-right--medium ez-margin-top--medium" }, getElementID("ezGridSelectionCounter_label"))),
|
|
119944
119952
|
index.h("div", { class: "ez-flex ez-margin-right--medium" },
|
|
119945
|
-
|
|
119953
|
+
shouldRenderSelectionButton() &&
|
|
119946
119954
|
index.h("ez-button", Object.assign({ class: "ez-margin-right--medium", label: `Selecionar ${allRecordSelected ? "apenas a página atual" : `todos os ${total} registros`}`, mode: "link", onClick: allRecordSelected ? onSelectPage : onSelectAll }, getElementID(`ezGridSelectionCounter_select${allRecordSelected ? "Page" : "All"}`))),
|
|
119947
119955
|
index.h("ez-button", Object.assign({ class: "grid__btn-clear", label: "Limpar", mode: "link", onClick: onClearAll }, getElementID("ezGridSelectionCounter_clearAll"))))),
|
|
119948
119956
|
index.h("button", Object.assign({ class: "grid__btn-close", title: "Fechar", onClick: onClose }, getElementID("ezGridSelectionCounter_close")),
|
|
@@ -119963,7 +119971,7 @@ function getElementID(sufix) {
|
|
|
119963
119971
|
};
|
|
119964
119972
|
}
|
|
119965
119973
|
|
|
119966
|
-
const ezGridCss = ".sc-ez-grid-h{display:grid;grid-template-rows:auto 1fr auto;height:100%;width:100%;--ez-grid__header--background-color:var(--background--xlight, #FFF);--ez-grid__selection-counter--z-index:var(--more-visible, 2);--ez-grid__container--shadow:0 0 16px 0 rgb(0 38 111 / 12%)}
|
|
119974
|
+
const ezGridCss = ".sc-ez-grid-h{display:grid;grid-template-rows:auto 1fr auto;height:100%;width:100%;--ez-grid__header--background-color:var(--background--xlight, #FFF);--ez-grid__selection-counter--z-index:var(--more-visible, 2);--ez-grid__container--shadow:0 0 16px 0 rgb(0 38 111 / 12%)}.grid-header.sc-ez-grid{display:grid;justify-content:space-between;align-items:center;grid-template-columns:1fr;background-color:var(--ez-grid__header--background-color, #FFF);z-index:var(--visible)}.grid__container.sc-ez-grid{padding-top:15px;margin-top:-12px;box-shadow:var(--ez-grid__container--shadow);background-color:var(--ez-grid__header--background-color)}.grid-header__popover.sc-ez-grid{position:relative;top:var(--space--sm, 16px)}.grid-header__container.sc-ez-grid{display:flex;align-items:center}.grid-header__position.sc-ez-grid{display:flex;align-items:center;justify-content:space-between}.grid__selection-counter.sc-ez-grid{position:fixed;white-space:nowrap;transform:translate(-50%, 0px);left:50%;opacity:0;bottom:-100%;transition:opacity 0.1s, bottom 0.5s;z-index:var(--ez-grid__selection-counter--z-index)}.grid__selection-counter--opened.sc-ez-grid{opacity:1;bottom:0px}.grid__btn-close.sc-ez-grid{display:flex;align-items:center;justify-content:center;padding:0;outline:none;width:20px;height:20px;border:none;background-color:unset;cursor:pointer}.grid__btn-clear.sc-ez-grid{--ez-button--link-color:var(--color--alert-warning-900, #8C6B00);--ez-button--link--hover-color:var(--color--alert-warning-900, #8C6B00)}[no-header].sc-ez-grid-h .grid-header.sc-ez-grid{height:0;padding:0}";
|
|
119967
119975
|
|
|
119968
119976
|
const windowInstace = window;
|
|
119969
119977
|
const EzGrid = class {
|
|
@@ -119982,8 +119990,10 @@ const EzGrid = class {
|
|
|
119982
119990
|
this._isAllSelection = false;
|
|
119983
119991
|
this._currentPageSelected = undefined;
|
|
119984
119992
|
this._selectionCount = undefined;
|
|
119993
|
+
this._originalRecords = [];
|
|
119985
119994
|
this.multipleSelection = undefined;
|
|
119986
119995
|
this.config = undefined;
|
|
119996
|
+
this.selectionToastConfig = undefined;
|
|
119987
119997
|
this.serverUrl = undefined;
|
|
119988
119998
|
this.dataUnit = undefined;
|
|
119989
119999
|
this.statusResolver = undefined;
|
|
@@ -120238,11 +120248,39 @@ const EzGrid = class {
|
|
|
120238
120248
|
ApplicationUtils.ApplicationUtils.info(this._messageFilterAppliedSuccess);
|
|
120239
120249
|
});
|
|
120240
120250
|
}
|
|
120251
|
+
getDataSource() {
|
|
120252
|
+
return this.columnfilterDataSource ? this.columnfilterDataSource : this.buildDefaultDataSource();
|
|
120253
|
+
}
|
|
120254
|
+
buildDefaultDataSource() {
|
|
120255
|
+
if (this._originalRecords.length === 0) {
|
|
120256
|
+
this._originalRecords = this.dataUnit.records;
|
|
120257
|
+
}
|
|
120258
|
+
return {
|
|
120259
|
+
fetchData: (filterTerm, fieldName) => {
|
|
120260
|
+
return new Promise(resolve => {
|
|
120261
|
+
const filteredRecords = this._originalRecords.filter(record => {
|
|
120262
|
+
var _a;
|
|
120263
|
+
const label = record[fieldName] === "object" ? (_a = record[fieldName]) === null || _a === void 0 ? void 0 : _a.label : record[fieldName];
|
|
120264
|
+
return label === null || label === void 0 ? void 0 : label.toString().toLowerCase().includes(filterTerm.toLowerCase());
|
|
120265
|
+
});
|
|
120266
|
+
const options = filteredRecords.map(record => this.buildIMultiSelectionOption(record[fieldName]));
|
|
120267
|
+
resolve(options);
|
|
120268
|
+
});
|
|
120269
|
+
}
|
|
120270
|
+
};
|
|
120271
|
+
}
|
|
120272
|
+
buildIMultiSelectionOption(data) {
|
|
120273
|
+
return {
|
|
120274
|
+
check: true,
|
|
120275
|
+
value: String(data),
|
|
120276
|
+
label: String(data)
|
|
120277
|
+
};
|
|
120278
|
+
}
|
|
120241
120279
|
render() {
|
|
120242
120280
|
var _a;
|
|
120243
|
-
return (index.h(index.Host, null, index.h("div", { class: "ez-box ez-box--shadow ez-padding--medium grid-header" }, index.h("filter-column", { class: "grid-header__popover", dataSource: this.
|
|
120281
|
+
return (index.h(index.Host, null, index.h("div", { class: "ez-box ez-box--shadow ez-padding--medium grid-header" }, index.h("filter-column", { class: "grid-header__popover", dataSource: this.getDataSource(), dataUnit: this.dataUnit, gridHeaderHidden: !!this._element.getAttribute("no-header"), ref: (element) => (this._filterColumn = element) }), index.h("div", { class: "grid-header__position" }, index.h("div", { class: "grid-header__container" }, index.h("slot", { name: "leftButtons" })), index.h("div", { class: "grid-header__container", ref: ref => (this._refPaginationControl = ref) }, this.getPaginationControl()))), index.h("div", { ref: (ref) => (this._gridSelectionCounter = ref), class: `grid__selection-counter
|
|
120244
120282
|
${this._showSelectionCounter ? 'grid__selection-counter--opened' : ''}
|
|
120245
|
-
` }, index.h(SelectionCounter, { selectionCount: this._selectionCount, currentPageSelected: this._currentPageSelected,
|
|
120283
|
+
` }, index.h(SelectionCounter, { selectionCount: this._selectionCount, currentPageSelected: this._currentPageSelected, paginationInfo: this._paginationInfo, canSelectAll: (_a = this.selectionToastConfig) === null || _a === void 0 ? void 0 : _a.canSelectAll, allRecordSelected: this._isAllSelection, onSelectAll: () => this.onSelectAllRecords(), onSelectPage: () => this.onSelectPageRecords(), onClearAll: () => this.onClearSelectedRecords(), onClose: () => (this._showSelectionCounter = false) })), index.h("div", { class: "grid__container ez-grid", ref: elem => (this._container = elem) }), index.h("div", { class: "grid__footer" }, index.h("slot", { name: "footer" }))));
|
|
120246
120284
|
}
|
|
120247
120285
|
static get assetsDirs() { return ["../assets"]; }
|
|
120248
120286
|
get _element() { return index.getElement(this); }
|
package/dist/cjs/ezui.cjs.js
CHANGED
|
@@ -17,7 +17,7 @@ const patchBrowser = () => {
|
|
|
17
17
|
};
|
|
18
18
|
|
|
19
19
|
patchBrowser().then(options => {
|
|
20
|
-
return index.bootstrapLazy(JSON.parse("[[\"ez-grid.cjs\",[[6,\"ez-grid\",{\"multipleSelection\":[4,\"multiple-selection\"],\"config\":[1040],\"serverUrl\":[1,\"server-url\"],\"dataUnit\":[16],\"statusResolver\":[16],\"columnfilterDataSource\":[16],\"_paginationInfo\":[32],\"_paginationChangedByKeyboard\":[32],\"_showSelectionCounter\":[32],\"_isAllSelection\":[32],\"_currentPageSelected\":[32],\"_selectionCount\":[32],\"setColumnsDef\":[64],\"addColumnMenuItem\":[64],\"setColumnsState\":[64],\"setData\":[64],\"getSelection\":[64],\"getColumnsState\":[64],\"getColumns\":[64],\"quickFilter\":[64]},[[0,\"ezSelectionChange\",\"onSelectionChange\"]]]]],[\"ez-guide-navigator.cjs\",[[1,\"ez-guide-navigator\",{\"open\":[1540],\"selectedId\":[1537,\"selected-id\"],\"items\":[16],\"tooltipResolver\":[16],\"filterText\":[32],\"disableItem\":[64],\"enableItem\":[64],\"updateItem\":[64],\"getItem\":[64],\"getCurrentPath\":[64],\"selectGuide\":[64],\"getParent\":[64]}]]],[\"ez-actions-button.cjs\",[[1,\"ez-actions-button\",{\"enabled\":[516],\"actions\":[1040],\"size\":[513],\"showLabel\":[516,\"show-label\"],\"displayIcon\":[513,\"display-icon\"],\"checkOption\":[516,\"check-option\"],\"value\":[513],\"isTransparent\":[516,\"is-transparent\"],\"arrowActive\":[516,\"arrow-active\"],\"_selectedAction\":[32],\"hideActions\":[64],\"isOpened\":[64]}]]],[\"ez-breadcrumb.cjs\",[[1,\"ez-breadcrumb\",{\"items\":[1040],\"fillMode\":[1025,\"fill-mode\"],\"maxItems\":[1026,\"max-items\"],\"positionEllipsis\":[1026,\"position-ellipsis\"],\"visibleItems\":[32],\"hiddenItems\":[32],\"showDropdown\":[32],\"collapseConfigPosition\":[32]}]]],[\"ez-dialog.cjs\",[[1,\"ez-dialog\",{\"confirm\":[1028],\"dialogType\":[1025,\"dialog-type\"],\"message\":[1025],\"opened\":[1540],\"personalizedIconPath\":[1025,\"personalized-icon-path\"],\"ezTitle\":[1025,\"ez-title\"],\"beforeClose\":[1040],\"show\":[64]}]]],[\"ez-modal-container.cjs\",[[6,\"ez-modal-container\",{\"modalTitle\":[1,\"modal-title\"],\"modalSubTitle\":[1,\"modal-sub-title\"],\"showTitleBar\":[4,\"show-title-bar\"],\"cancelButtonLabel\":[1,\"cancel-button-label\"],\"okButtonLabel\":[1,\"ok-button-label\"],\"cancelButtonStatus\":[1,\"cancel-button-status\"],\"okButtonStatus\":[1,\"ok-button-status\"]}]]],[\"ez-alert.cjs\",[[1,\"ez-alert\",{\"alertType\":[513,\"alert-type\"]}]]],[\"ez-badge.cjs\",[[1,\"ez-badge\",{\"size\":[513],\"label\":[513],\"iconLeft\":[513,\"icon-left\"],\"iconRight\":[513,\"icon-right\"],\"position\":[1040],\"hasSlot\":[32]}]]],[\"ez-chip.cjs\",[[1,\"ez-chip\",{\"label\":[513],\"enabled\":[516],\"removePosition\":[513,\"remove-position\"],\"mode\":[513],\"value\":[1540],\"showNativeTooltip\":[4,\"show-native-tooltip\"],\"setFocus\":[64],\"setBlur\":[64]}]]],[\"ez-file-item.cjs\",[[1,\"ez-file-item\",{\"canRemove\":[4,\"can-remove\"],\"fileName\":[1,\"file-name\"],\"iconName\":[1,\"icon-name\"],\"fileSize\":[2,\"file-size\"],\"progress\":[2]}]]],[\"ez-application.cjs\",[[0,\"ez-application\"]]],[\"ez-card-item.cjs\",[[1,\"ez-card-item\",{\"item\":[16]}]]],[\"ez-loading-bar.cjs\",[[1,\"ez-loading-bar\",{\"_showLoading\":[32],\"hide\":[64],\"show\":[64]}]]],[\"ez-modal.cjs\",[[1,\"ez-modal\",{\"modalSize\":[1,\"modal-size\"],\"align\":[1],\"heightMode\":[1,\"height-mode\"],\"opened\":[1028],\"closeEsc\":[4,\"close-esc\"],\"closeOutsideClick\":[4,\"close-outside-click\"],\"scrim\":[1]}]]],[\"ez-popup.cjs\",[[1,\"ez-popup\",{\"size\":[1],\"opened\":[1540],\"useHeader\":[516,\"use-header\"],\"heightMode\":[513,\"height-mode\"],\"ezTitle\":[1,\"ez-title\"]}]]],[\"ez-radio-button.cjs\",[[1,\"ez-radio-button\",{\"value\":[1544],\"options\":[1040],\"enabled\":[516],\"label\":[513],\"direction\":[1537]}]]],[\"ez-skeleton.cjs\",[[0,\"ez-skeleton\",{\"count\":[2],\"variant\":[1],\"width\":[1],\"height\":[1],\"marginBottom\":[1,\"margin-bottom\"],\"animation\":[1]}]]],[\"ez-toast.cjs\",[[1,\"ez-toast\",{\"message\":[1025],\"fadeTime\":[1026,\"fade-time\"],\"useIcon\":[1028,\"use-icon\"],\"canClose\":[1028,\"can-close\"],\"show\":[64]}]]],[\"ez-view-stack.cjs\",[[0,\"ez-view-stack\",{\"show\":[64],\"getSelectedIndex\":[64]}]]],[\"ez-form-view.cjs\",[[2,\"ez-form-view\",{\"fields\":[16],\"showUp\":[64]}]]],[\"ez-filter-input_2.cjs\",[[0,\"multi-selection-box-message\",{\"message\":[1]}],[1,\"ez-filter-input\",{\"label\":[1],\"value\":[1537],\"enabled\":[4],\"errorMessage\":[1537,\"error-message\"],\"restrict\":[1],\"mode\":[513],\"asyncSearch\":[516,\"async-search\"],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64],\"setValue\":[64],\"endSearch\":[64]}]]],[\"ez-multi-selection-list.cjs\",[[2,\"ez-multi-selection-list\",{\"columnName\":[1,\"column-name\"],\"dataSource\":[16],\"useOptions\":[1028,\"use-options\"],\"options\":[16],\"filteredOptions\":[32],\"displayOptions\":[32],\"viewScenario\":[32],\"displayOptionToCheckAllItems\":[32],\"clearFilteredOptions\":[64]}]]],[\"filter-column.cjs\",[[0,\"filter-column\",{\"opened\":[4],\"columnName\":[1,\"column-name\"],\"columnLabel\":[1,\"column-label\"],\"dataSource\":[16],\"dataUnit\":[16],\"options\":[1040],\"selectedItems\":[32],\"fieldDescriptor\":[32],\"useOptions\":[32],\"hide\":[64],\"show\":[64]}]]],[\"ez-dropdown.cjs\",[[1,\"ez-dropdown\",{\"items\":[1040],\"value\":[1040],\"itemBuilder\":[16]}]]],[\"ez-tabselector.cjs\",[[1,\"ez-tabselector\",{\"selectedIndex\":[1538,\"selected-index\"],\"selectedTab\":[1537,\"selected-tab\"],\"tabs\":[1],\"_processedTabs\":[32]}]]],[\"ez-collapsible-box.cjs\",[[1,\"ez-collapsible-box\",{\"value\":[1540],\"boxBordered\":[4,\"box-bordered\"],\"label\":[513],\"subtitle\":[513],\"headerSize\":[513,\"header-size\"],\"iconPlacement\":[513,\"icon-placement\"],\"headerAlign\":[513,\"header-align\"],\"removable\":[516],\"editable\":[516],\"conditionalSave\":[16],\"_activeEditText\":[32],\"showHide\":[64],\"applyFocusTextEdit\":[64],\"cancelEdition\":[64]}]]],[\"ez-calendar.cjs\",[[1,\"ez-calendar\",{\"value\":[1040],\"floating\":[516],\"time\":[516],\"showSeconds\":[516,\"show-seconds\"],\"show\":[64],\"fitVertical\":[64],\"hide\":[64]}]]],[\"ez-text-input.cjs\",[[1,\"ez-text-input\",{\"label\":[513],\"value\":[1537],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"mask\":[1],\"canShowError\":[516,\"can-show-error\"],\"restrict\":[1],\"mode\":[513],\"noBorder\":[516,\"no-border\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-date-input.cjs\",[[1,\"ez-date-input\",{\"label\":[513],\"value\":[1040],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-date-time-input.cjs\",[[1,\"ez-date-time-input\",{\"label\":[513],\"value\":[1040],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"showSeconds\":[516,\"show-seconds\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-time-input.cjs\",[[1,\"ez-time-input\",{\"label\":[513],\"value\":[1026],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"showSeconds\":[516,\"show-seconds\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-number-input.cjs\",[[1,\"ez-number-input\",{\"label\":[1],\"value\":[1538],\"enabled\":[4],\"canShowError\":[516,\"can-show-error\"],\"errorMessage\":[1537,\"error-message\"],\"precision\":[2],\"prettyPrecision\":[2,\"pretty-precision\"],\"mode\":[513],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-popover.cjs\",[[1,\"ez-popover\",{\"autoClose\":[516,\"auto-close\"],\"boxWidth\":[513,\"box-width\"],\"opened\":[1540],\"innerElement\":[1537,\"inner-element\"],\"overlayType\":[513,\"overlay-type\"],\"updatePosition\":[64],\"show\":[64],\"showUnder\":[64],\"hide\":[64]}]]],[\"ez-text-area.cjs\",[[1,\"ez-text-area\",{\"label\":[513],\"value\":[1537],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"rows\":[1538],\"canShowError\":[516,\"can-show-error\"],\"mode\":[513],\"appendTextToSelection\":[64],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-upload.cjs\",[[1,\"ez-upload\",{\"label\":[1],\"subtitle\":[1],\"enabled\":[4],\"maxFileSize\":[2,\"max-file-size\"],\"maxFiles\":[2,\"max-files\"],\"requestHeaders\":[8,\"request-headers\"],\"urlUpload\":[1,\"url-upload\"],\"urlDelete\":[1,\"url-delete\"],\"value\":[1040],\"addFiles\":[64],\"setFocus\":[64],\"setBlur\":[64]}]]],[\"ez-text-edit.cjs\",[[1,\"ez-text-edit\",{\"value\":[1],\"styled\":[16],\"_newValue\":[32],\"applyFocusSelect\":[64]}]]],[\"ez-scroller_3.cjs\",[[1,\"ez-tree\",{\"items\":[1040],\"value\":[1040],\"selectedId\":[1537,\"selected-id\"],\"iconResolver\":[16],\"tooltipResolver\":[16],\"_tree\":[32],\"_waintingForLoad\":[32],\"selectItem\":[64],\"openItem\":[64],\"disableItem\":[64],\"enableItem\":[64],\"addChild\":[64],\"applyFilter\":[64],\"updateItem\":[64],\"getItem\":[64],\"getCurrentPath\":[64],\"getParent\":[64]},[[2,\"keydown\",\"onKeyDownListener\"]]],[1,\"ez-scroller\",{\"direction\":[1],\"locked\":[4],\"activeShadow\":[4,\"active-shadow\"],\"isActive\":[32]},[[2,\"click\",\"clickListener\"],[1,\"mousedown\",\"mouseDownHandler\"],[1,\"mouseup\",\"mouseUpHandler\"],[1,\"mousemove\",\"mouseMoveHandler\"]]],[1,\"ez-sidebar-button\"]]],[\"ez-list.cjs\",[[1,\"ez-list\",{\"dataSource\":[1040],\"listMode\":[1,\"list-mode\"],\"useGroups\":[1540,\"use-groups\"],\"ezDraggable\":[1028,\"ez-draggable\"],\"ezSelectable\":[1028,\"ez-selectable\"],\"itemSlotBuilder\":[1040],\"hoverFeedback\":[1028,\"hover-feedback\"],\"_listItems\":[32],\"_listGroupItems\":[32],\"clearHistory\":[64],\"scrollToTop\":[64],\"setSelection\":[64],\"getSelection\":[64],\"getList\":[64]}]]],[\"ez-combo-box.cjs\",[[1,\"ez-combo-box\",{\"value\":[1537],\"label\":[513],\"enabled\":[516],\"options\":[1040],\"errorMessage\":[1537,\"error-message\"],\"searchMode\":[4,\"search-mode\"],\"showSelectedValue\":[4,\"show-selected-value\"],\"showOptionValue\":[4,\"show-option-value\"],\"suppressSearch\":[4,\"suppress-search\"],\"optionLoader\":[16],\"suppressEmptyOption\":[4,\"suppress-empty-option\"],\"canShowError\":[516,\"can-show-error\"],\"mode\":[513],\"_preSelection\":[32],\"_visibleOptions\":[32],\"_startLoading\":[32],\"_showLoading\":[32],\"_criteria\":[32],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64],\"clearValue\":[64]},[[11,\"scroll\",\"scrollListener\"]]]]],[\"ez-search.cjs\",[[1,\"ez-search\",{\"value\":[1537],\"label\":[1537],\"enabled\":[1540],\"errorMessage\":[1537,\"error-message\"],\"optionLoader\":[16],\"showSelectedValue\":[4,\"show-selected-value\"],\"showOptionValue\":[4,\"show-option-value\"],\"suppressEmptyOption\":[4,\"suppress-empty-option\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64],\"clearValue\":[64]}]]],[\"ez-check.cjs\",[[1,\"ez-check\",{\"label\":[513],\"value\":[1540],\"enabled\":[1540],\"indeterminate\":[1540],\"mode\":[513],\"compact\":[4],\"getMode\":[64],\"setFocus\":[64]}]]],[\"ez-icon.cjs\",[[1,\"ez-icon\",{\"size\":[513],\"href\":[513],\"iconName\":[513,\"icon-name\"]}]]],[\"ez-button.cjs\",[[1,\"ez-button\",{\"label\":[513],\"enabled\":[516],\"mode\":[513],\"image\":[513],\"iconName\":[513,\"icon-name\"],\"size\":[513],\"setFocus\":[64],\"setBlur\":[64]},[[2,\"click\",\"clickListener\"]]]]],[\"ez-form.cjs\",[[2,\"ez-form\",{\"dataUnit\":[1040],\"config\":[16],\"recordsValidator\":[16],\"validate\":[64]}]]]]"), options);
|
|
20
|
+
return index.bootstrapLazy(JSON.parse("[[\"ez-grid.cjs\",[[6,\"ez-grid\",{\"multipleSelection\":[4,\"multiple-selection\"],\"config\":[1040],\"selectionToastConfig\":[16],\"serverUrl\":[1,\"server-url\"],\"dataUnit\":[16],\"statusResolver\":[16],\"columnfilterDataSource\":[16],\"_paginationInfo\":[32],\"_paginationChangedByKeyboard\":[32],\"_showSelectionCounter\":[32],\"_isAllSelection\":[32],\"_currentPageSelected\":[32],\"_selectionCount\":[32],\"_originalRecords\":[32],\"setColumnsDef\":[64],\"addColumnMenuItem\":[64],\"setColumnsState\":[64],\"setData\":[64],\"getSelection\":[64],\"getColumnsState\":[64],\"getColumns\":[64],\"quickFilter\":[64]},[[0,\"ezSelectionChange\",\"onSelectionChange\"]]]]],[\"ez-guide-navigator.cjs\",[[1,\"ez-guide-navigator\",{\"open\":[1540],\"selectedId\":[1537,\"selected-id\"],\"items\":[16],\"tooltipResolver\":[16],\"filterText\":[32],\"disableItem\":[64],\"enableItem\":[64],\"updateItem\":[64],\"getItem\":[64],\"getCurrentPath\":[64],\"selectGuide\":[64],\"getParent\":[64]}]]],[\"ez-actions-button.cjs\",[[1,\"ez-actions-button\",{\"enabled\":[516],\"actions\":[1040],\"size\":[513],\"showLabel\":[516,\"show-label\"],\"displayIcon\":[513,\"display-icon\"],\"checkOption\":[516,\"check-option\"],\"value\":[513],\"isTransparent\":[516,\"is-transparent\"],\"arrowActive\":[516,\"arrow-active\"],\"_selectedAction\":[32],\"hideActions\":[64],\"isOpened\":[64]}]]],[\"ez-breadcrumb.cjs\",[[1,\"ez-breadcrumb\",{\"items\":[1040],\"fillMode\":[1025,\"fill-mode\"],\"maxItems\":[1026,\"max-items\"],\"positionEllipsis\":[1026,\"position-ellipsis\"],\"visibleItems\":[32],\"hiddenItems\":[32],\"showDropdown\":[32],\"collapseConfigPosition\":[32]}]]],[\"ez-dialog.cjs\",[[1,\"ez-dialog\",{\"confirm\":[1028],\"dialogType\":[1025,\"dialog-type\"],\"message\":[1025],\"opened\":[1540],\"personalizedIconPath\":[1025,\"personalized-icon-path\"],\"ezTitle\":[1025,\"ez-title\"],\"beforeClose\":[1040],\"show\":[64]}]]],[\"ez-modal-container.cjs\",[[6,\"ez-modal-container\",{\"modalTitle\":[1,\"modal-title\"],\"modalSubTitle\":[1,\"modal-sub-title\"],\"showTitleBar\":[4,\"show-title-bar\"],\"cancelButtonLabel\":[1,\"cancel-button-label\"],\"okButtonLabel\":[1,\"ok-button-label\"],\"cancelButtonStatus\":[1,\"cancel-button-status\"],\"okButtonStatus\":[1,\"ok-button-status\"]}]]],[\"ez-alert.cjs\",[[1,\"ez-alert\",{\"alertType\":[513,\"alert-type\"]}]]],[\"ez-badge.cjs\",[[1,\"ez-badge\",{\"size\":[513],\"label\":[513],\"iconLeft\":[513,\"icon-left\"],\"iconRight\":[513,\"icon-right\"],\"position\":[1040],\"hasSlot\":[32]}]]],[\"ez-chip.cjs\",[[1,\"ez-chip\",{\"label\":[513],\"enabled\":[516],\"removePosition\":[513,\"remove-position\"],\"mode\":[513],\"value\":[1540],\"showNativeTooltip\":[4,\"show-native-tooltip\"],\"setFocus\":[64],\"setBlur\":[64]}]]],[\"ez-file-item.cjs\",[[1,\"ez-file-item\",{\"canRemove\":[4,\"can-remove\"],\"fileName\":[1,\"file-name\"],\"iconName\":[1,\"icon-name\"],\"fileSize\":[2,\"file-size\"],\"progress\":[2]}]]],[\"ez-application.cjs\",[[0,\"ez-application\"]]],[\"ez-card-item.cjs\",[[1,\"ez-card-item\",{\"item\":[16]}]]],[\"ez-loading-bar.cjs\",[[1,\"ez-loading-bar\",{\"_showLoading\":[32],\"hide\":[64],\"show\":[64]}]]],[\"ez-modal.cjs\",[[1,\"ez-modal\",{\"modalSize\":[1,\"modal-size\"],\"align\":[1],\"heightMode\":[1,\"height-mode\"],\"opened\":[1028],\"closeEsc\":[4,\"close-esc\"],\"closeOutsideClick\":[4,\"close-outside-click\"],\"scrim\":[1]}]]],[\"ez-popup.cjs\",[[1,\"ez-popup\",{\"size\":[1],\"opened\":[1540],\"useHeader\":[516,\"use-header\"],\"heightMode\":[513,\"height-mode\"],\"ezTitle\":[1,\"ez-title\"]}]]],[\"ez-radio-button.cjs\",[[1,\"ez-radio-button\",{\"value\":[1544],\"options\":[1040],\"enabled\":[516],\"label\":[513],\"direction\":[1537]}]]],[\"ez-skeleton.cjs\",[[0,\"ez-skeleton\",{\"count\":[2],\"variant\":[1],\"width\":[1],\"height\":[1],\"marginBottom\":[1,\"margin-bottom\"],\"animation\":[1]}]]],[\"ez-toast.cjs\",[[1,\"ez-toast\",{\"message\":[1025],\"fadeTime\":[1026,\"fade-time\"],\"useIcon\":[1028,\"use-icon\"],\"canClose\":[1028,\"can-close\"],\"show\":[64]}]]],[\"ez-view-stack.cjs\",[[0,\"ez-view-stack\",{\"show\":[64],\"getSelectedIndex\":[64]}]]],[\"ez-form-view.cjs\",[[2,\"ez-form-view\",{\"fields\":[16],\"showUp\":[64]}]]],[\"ez-filter-input_2.cjs\",[[0,\"multi-selection-box-message\",{\"message\":[1]}],[1,\"ez-filter-input\",{\"label\":[1],\"value\":[1537],\"enabled\":[4],\"errorMessage\":[1537,\"error-message\"],\"restrict\":[1],\"mode\":[513],\"asyncSearch\":[516,\"async-search\"],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64],\"setValue\":[64],\"endSearch\":[64]}]]],[\"ez-multi-selection-list.cjs\",[[2,\"ez-multi-selection-list\",{\"columnName\":[1,\"column-name\"],\"dataSource\":[16],\"useOptions\":[1028,\"use-options\"],\"options\":[16],\"filteredOptions\":[32],\"displayOptions\":[32],\"viewScenario\":[32],\"displayOptionToCheckAllItems\":[32],\"clearFilteredOptions\":[64]}]]],[\"filter-column.cjs\",[[0,\"filter-column\",{\"opened\":[4],\"columnName\":[1,\"column-name\"],\"columnLabel\":[1,\"column-label\"],\"gridHeaderHidden\":[4,\"grid-header-hidden\"],\"dataSource\":[16],\"dataUnit\":[16],\"options\":[1040],\"selectedItems\":[32],\"fieldDescriptor\":[32],\"useOptions\":[32],\"hide\":[64],\"show\":[64]}]]],[\"ez-dropdown.cjs\",[[1,\"ez-dropdown\",{\"items\":[1040],\"value\":[1040],\"itemBuilder\":[16]}]]],[\"ez-tabselector.cjs\",[[1,\"ez-tabselector\",{\"selectedIndex\":[1538,\"selected-index\"],\"selectedTab\":[1537,\"selected-tab\"],\"tabs\":[1],\"_processedTabs\":[32]}]]],[\"ez-collapsible-box.cjs\",[[1,\"ez-collapsible-box\",{\"value\":[1540],\"boxBordered\":[4,\"box-bordered\"],\"label\":[513],\"subtitle\":[513],\"headerSize\":[513,\"header-size\"],\"iconPlacement\":[513,\"icon-placement\"],\"headerAlign\":[513,\"header-align\"],\"removable\":[516],\"editable\":[516],\"conditionalSave\":[16],\"_activeEditText\":[32],\"showHide\":[64],\"applyFocusTextEdit\":[64],\"cancelEdition\":[64]}]]],[\"ez-calendar.cjs\",[[1,\"ez-calendar\",{\"value\":[1040],\"floating\":[516],\"time\":[516],\"showSeconds\":[516,\"show-seconds\"],\"show\":[64],\"fitVertical\":[64],\"hide\":[64]}]]],[\"ez-text-input.cjs\",[[1,\"ez-text-input\",{\"label\":[513],\"value\":[1537],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"mask\":[1],\"canShowError\":[516,\"can-show-error\"],\"restrict\":[1],\"mode\":[513],\"noBorder\":[516,\"no-border\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-date-input.cjs\",[[1,\"ez-date-input\",{\"label\":[513],\"value\":[1040],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-date-time-input.cjs\",[[1,\"ez-date-time-input\",{\"label\":[513],\"value\":[1040],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"showSeconds\":[516,\"show-seconds\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-time-input.cjs\",[[1,\"ez-time-input\",{\"label\":[513],\"value\":[1026],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"showSeconds\":[516,\"show-seconds\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-number-input.cjs\",[[1,\"ez-number-input\",{\"label\":[1],\"value\":[1538],\"enabled\":[4],\"canShowError\":[516,\"can-show-error\"],\"errorMessage\":[1537,\"error-message\"],\"precision\":[2],\"prettyPrecision\":[2,\"pretty-precision\"],\"mode\":[513],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-popover.cjs\",[[1,\"ez-popover\",{\"autoClose\":[516,\"auto-close\"],\"boxWidth\":[513,\"box-width\"],\"opened\":[1540],\"innerElement\":[1537,\"inner-element\"],\"overlayType\":[513,\"overlay-type\"],\"updatePosition\":[64],\"show\":[64],\"showUnder\":[64],\"hide\":[64]}]]],[\"ez-text-area.cjs\",[[1,\"ez-text-area\",{\"label\":[513],\"value\":[1537],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"rows\":[1538],\"canShowError\":[516,\"can-show-error\"],\"mode\":[513],\"appendTextToSelection\":[64],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-upload.cjs\",[[1,\"ez-upload\",{\"label\":[1],\"subtitle\":[1],\"enabled\":[4],\"maxFileSize\":[2,\"max-file-size\"],\"maxFiles\":[2,\"max-files\"],\"requestHeaders\":[8,\"request-headers\"],\"urlUpload\":[1,\"url-upload\"],\"urlDelete\":[1,\"url-delete\"],\"value\":[1040],\"addFiles\":[64],\"setFocus\":[64],\"setBlur\":[64]}]]],[\"ez-text-edit.cjs\",[[1,\"ez-text-edit\",{\"value\":[1],\"styled\":[16],\"_newValue\":[32],\"applyFocusSelect\":[64]}]]],[\"ez-scroller_3.cjs\",[[1,\"ez-tree\",{\"items\":[1040],\"value\":[1040],\"selectedId\":[1537,\"selected-id\"],\"iconResolver\":[16],\"tooltipResolver\":[16],\"_tree\":[32],\"_waintingForLoad\":[32],\"selectItem\":[64],\"openItem\":[64],\"disableItem\":[64],\"enableItem\":[64],\"addChild\":[64],\"applyFilter\":[64],\"updateItem\":[64],\"getItem\":[64],\"getCurrentPath\":[64],\"getParent\":[64]},[[2,\"keydown\",\"onKeyDownListener\"]]],[1,\"ez-scroller\",{\"direction\":[1],\"locked\":[4],\"activeShadow\":[4,\"active-shadow\"],\"isActive\":[32]},[[2,\"click\",\"clickListener\"],[1,\"mousedown\",\"mouseDownHandler\"],[1,\"mouseup\",\"mouseUpHandler\"],[1,\"mousemove\",\"mouseMoveHandler\"]]],[1,\"ez-sidebar-button\"]]],[\"ez-list.cjs\",[[1,\"ez-list\",{\"dataSource\":[1040],\"listMode\":[1,\"list-mode\"],\"useGroups\":[1540,\"use-groups\"],\"ezDraggable\":[1028,\"ez-draggable\"],\"ezSelectable\":[1028,\"ez-selectable\"],\"itemSlotBuilder\":[1040],\"hoverFeedback\":[1028,\"hover-feedback\"],\"_listItems\":[32],\"_listGroupItems\":[32],\"clearHistory\":[64],\"scrollToTop\":[64],\"setSelection\":[64],\"getSelection\":[64],\"getList\":[64]}]]],[\"ez-combo-box.cjs\",[[1,\"ez-combo-box\",{\"value\":[1537],\"label\":[513],\"enabled\":[516],\"options\":[1040],\"errorMessage\":[1537,\"error-message\"],\"searchMode\":[4,\"search-mode\"],\"showSelectedValue\":[4,\"show-selected-value\"],\"showOptionValue\":[4,\"show-option-value\"],\"suppressSearch\":[4,\"suppress-search\"],\"optionLoader\":[16],\"suppressEmptyOption\":[4,\"suppress-empty-option\"],\"canShowError\":[516,\"can-show-error\"],\"mode\":[513],\"_preSelection\":[32],\"_visibleOptions\":[32],\"_startLoading\":[32],\"_showLoading\":[32],\"_criteria\":[32],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64],\"clearValue\":[64]},[[11,\"scroll\",\"scrollListener\"]]]]],[\"ez-search.cjs\",[[1,\"ez-search\",{\"value\":[1537],\"label\":[1537],\"enabled\":[1540],\"errorMessage\":[1537,\"error-message\"],\"optionLoader\":[16],\"showSelectedValue\":[4,\"show-selected-value\"],\"showOptionValue\":[4,\"show-option-value\"],\"suppressEmptyOption\":[4,\"suppress-empty-option\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64],\"clearValue\":[64]}]]],[\"ez-check.cjs\",[[1,\"ez-check\",{\"label\":[513],\"value\":[1540],\"enabled\":[1540],\"indeterminate\":[1540],\"mode\":[513],\"compact\":[4],\"getMode\":[64],\"setFocus\":[64]}]]],[\"ez-icon.cjs\",[[1,\"ez-icon\",{\"size\":[513],\"href\":[513],\"iconName\":[513,\"icon-name\"]}]]],[\"ez-button.cjs\",[[1,\"ez-button\",{\"label\":[513],\"enabled\":[516],\"mode\":[513],\"image\":[513],\"iconName\":[513,\"icon-name\"],\"size\":[513],\"setFocus\":[64],\"setBlur\":[64]},[[2,\"click\",\"clickListener\"]]]]],[\"ez-form.cjs\",[[2,\"ez-form\",{\"dataUnit\":[1040],\"config\":[16],\"recordsValidator\":[16],\"validate\":[64]}]]]]"), options);
|
|
21
21
|
});
|
|
22
22
|
|
|
23
23
|
exports.setNonce = index.setNonce;
|
|
@@ -18,9 +18,12 @@ const FilterColumn = class {
|
|
|
18
18
|
index.registerInstance(this, hostRef);
|
|
19
19
|
this.applyFilterColumnOptions = index.createEvent(this, "applyFilterColumnOptions", 7);
|
|
20
20
|
this.TOP_POSITION = '65px';
|
|
21
|
+
this.TOP_POSITION_HEADER_HIDDEN = '18';
|
|
22
|
+
this.DEFAULT_HEIGHT = 430;
|
|
21
23
|
this.opened = true;
|
|
22
24
|
this.columnName = undefined;
|
|
23
25
|
this.columnLabel = undefined;
|
|
26
|
+
this.gridHeaderHidden = false;
|
|
24
27
|
this.dataSource = undefined;
|
|
25
28
|
this.dataUnit = undefined;
|
|
26
29
|
this.options = undefined;
|
|
@@ -43,9 +46,23 @@ const FilterColumn = class {
|
|
|
43
46
|
this.setOptions(configs.filteredOptions);
|
|
44
47
|
this.columnName = configs.columnName;
|
|
45
48
|
this.columnLabel = configs.columnLabel;
|
|
46
|
-
await this.ezPopoverElement.show(this.
|
|
49
|
+
await this.ezPopoverElement.show(this.calcTopPosition(), configs.leftPosition);
|
|
47
50
|
}
|
|
48
51
|
}
|
|
52
|
+
calcTopPosition() {
|
|
53
|
+
const referencePosition = this.gridHeaderHidden
|
|
54
|
+
? this.TOP_POSITION_HEADER_HIDDEN
|
|
55
|
+
: this.TOP_POSITION.replace('px', '');
|
|
56
|
+
const totalPopoverHeight = parseInt(referencePosition) + this.DEFAULT_HEIGHT;
|
|
57
|
+
const popoverPosition = Math.round(this.ezPopoverElement.getBoundingClientRect().top);
|
|
58
|
+
const popoverBottomPosition = popoverPosition + totalPopoverHeight;
|
|
59
|
+
const windowHeight = window.innerHeight;
|
|
60
|
+
if (windowHeight > popoverBottomPosition) {
|
|
61
|
+
return referencePosition;
|
|
62
|
+
}
|
|
63
|
+
const differenceBetween = windowHeight - popoverBottomPosition;
|
|
64
|
+
return `${differenceBetween}px`;
|
|
65
|
+
}
|
|
49
66
|
async clearConfigs() {
|
|
50
67
|
var _a;
|
|
51
68
|
await ((_a = this.ezMultiSelectionList) === null || _a === void 0 ? void 0 : _a.clearFilteredOptions());
|
|
@@ -56,7 +73,10 @@ const FilterColumn = class {
|
|
|
56
73
|
return !this.ezPopoverElement.opened || configs.columnName !== this.columnName;
|
|
57
74
|
}
|
|
58
75
|
submit() {
|
|
59
|
-
this.applyFilterColumnOptions.emit({
|
|
76
|
+
this.applyFilterColumnOptions.emit({
|
|
77
|
+
field: this.columnName,
|
|
78
|
+
values: this.selectedItems,
|
|
79
|
+
});
|
|
60
80
|
windowInstace.dispatchEvent(onSubmitFilter);
|
|
61
81
|
this.hide();
|
|
62
82
|
}
|
|
@@ -84,8 +104,8 @@ const FilterColumn = class {
|
|
|
84
104
|
}
|
|
85
105
|
if (this.isCheckBoxOrSwitch()) {
|
|
86
106
|
return [
|
|
87
|
-
{ label:
|
|
88
|
-
{ label:
|
|
107
|
+
{ label: 'Sim', value: 'true', check: true },
|
|
108
|
+
{ label: 'Não', value: 'false', check: true },
|
|
89
109
|
];
|
|
90
110
|
}
|
|
91
111
|
const optionsObject = JSON.parse((_b = (_a = this.fieldDescriptor) === null || _a === void 0 ? void 0 : _a.properties) === null || _b === void 0 ? void 0 : _b.options);
|
|
@@ -100,7 +120,7 @@ const FilterColumn = class {
|
|
|
100
120
|
}
|
|
101
121
|
}
|
|
102
122
|
render() {
|
|
103
|
-
return (index.h("ez-popover", { class:
|
|
123
|
+
return (index.h("ez-popover", { class: 'filter-column__popover', "overlay-type": 'none', ref: (element) => (this.ezPopoverElement = element), autoClose: true, onEzVisibilityChange: this.handleEzVisibilityChange.bind(this) }, index.h("section", { class: 'filter-column' }, index.h("header", { class: 'filter-column__header' }, index.h("span", { class: 'ez-text ez-text--medium filter-column__header-title' }, "Filtro da coluna ", this.columnLabel), index.h("ez-button", { mode: 'icon', "icon-name": 'close', class: 'ez-button--tertiary', onClick: () => this.hide() })), index.h("ez-multi-selection-list", { columnName: this.columnName, dataSource: this.dataSource, options: this.options, useOptions: this.useOptions, ref: (element) => (this.ezMultiSelectionList = element), onChangeFilteredOptions: (event) => this.changeSelectedItems(event.detail) }), index.h("footer", { class: 'filter-column__footer' }, index.h("ez-button", { label: 'Aplicar', class: 'ez-button--primary', onClick: this.submit.bind(this) })))));
|
|
104
124
|
}
|
|
105
125
|
};
|
|
106
126
|
FilterColumn.style = filterColumnCss;
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -14,7 +14,7 @@ const patchEsm = () => {
|
|
|
14
14
|
const defineCustomElements = (win, options) => {
|
|
15
15
|
if (typeof window === 'undefined') return Promise.resolve();
|
|
16
16
|
return patchEsm().then(() => {
|
|
17
|
-
return index.bootstrapLazy(JSON.parse("[[\"ez-grid.cjs\",[[6,\"ez-grid\",{\"multipleSelection\":[4,\"multiple-selection\"],\"config\":[1040],\"serverUrl\":[1,\"server-url\"],\"dataUnit\":[16],\"statusResolver\":[16],\"columnfilterDataSource\":[16],\"_paginationInfo\":[32],\"_paginationChangedByKeyboard\":[32],\"_showSelectionCounter\":[32],\"_isAllSelection\":[32],\"_currentPageSelected\":[32],\"_selectionCount\":[32],\"setColumnsDef\":[64],\"addColumnMenuItem\":[64],\"setColumnsState\":[64],\"setData\":[64],\"getSelection\":[64],\"getColumnsState\":[64],\"getColumns\":[64],\"quickFilter\":[64]},[[0,\"ezSelectionChange\",\"onSelectionChange\"]]]]],[\"ez-guide-navigator.cjs\",[[1,\"ez-guide-navigator\",{\"open\":[1540],\"selectedId\":[1537,\"selected-id\"],\"items\":[16],\"tooltipResolver\":[16],\"filterText\":[32],\"disableItem\":[64],\"enableItem\":[64],\"updateItem\":[64],\"getItem\":[64],\"getCurrentPath\":[64],\"selectGuide\":[64],\"getParent\":[64]}]]],[\"ez-actions-button.cjs\",[[1,\"ez-actions-button\",{\"enabled\":[516],\"actions\":[1040],\"size\":[513],\"showLabel\":[516,\"show-label\"],\"displayIcon\":[513,\"display-icon\"],\"checkOption\":[516,\"check-option\"],\"value\":[513],\"isTransparent\":[516,\"is-transparent\"],\"arrowActive\":[516,\"arrow-active\"],\"_selectedAction\":[32],\"hideActions\":[64],\"isOpened\":[64]}]]],[\"ez-breadcrumb.cjs\",[[1,\"ez-breadcrumb\",{\"items\":[1040],\"fillMode\":[1025,\"fill-mode\"],\"maxItems\":[1026,\"max-items\"],\"positionEllipsis\":[1026,\"position-ellipsis\"],\"visibleItems\":[32],\"hiddenItems\":[32],\"showDropdown\":[32],\"collapseConfigPosition\":[32]}]]],[\"ez-dialog.cjs\",[[1,\"ez-dialog\",{\"confirm\":[1028],\"dialogType\":[1025,\"dialog-type\"],\"message\":[1025],\"opened\":[1540],\"personalizedIconPath\":[1025,\"personalized-icon-path\"],\"ezTitle\":[1025,\"ez-title\"],\"beforeClose\":[1040],\"show\":[64]}]]],[\"ez-modal-container.cjs\",[[6,\"ez-modal-container\",{\"modalTitle\":[1,\"modal-title\"],\"modalSubTitle\":[1,\"modal-sub-title\"],\"showTitleBar\":[4,\"show-title-bar\"],\"cancelButtonLabel\":[1,\"cancel-button-label\"],\"okButtonLabel\":[1,\"ok-button-label\"],\"cancelButtonStatus\":[1,\"cancel-button-status\"],\"okButtonStatus\":[1,\"ok-button-status\"]}]]],[\"ez-alert.cjs\",[[1,\"ez-alert\",{\"alertType\":[513,\"alert-type\"]}]]],[\"ez-badge.cjs\",[[1,\"ez-badge\",{\"size\":[513],\"label\":[513],\"iconLeft\":[513,\"icon-left\"],\"iconRight\":[513,\"icon-right\"],\"position\":[1040],\"hasSlot\":[32]}]]],[\"ez-chip.cjs\",[[1,\"ez-chip\",{\"label\":[513],\"enabled\":[516],\"removePosition\":[513,\"remove-position\"],\"mode\":[513],\"value\":[1540],\"showNativeTooltip\":[4,\"show-native-tooltip\"],\"setFocus\":[64],\"setBlur\":[64]}]]],[\"ez-file-item.cjs\",[[1,\"ez-file-item\",{\"canRemove\":[4,\"can-remove\"],\"fileName\":[1,\"file-name\"],\"iconName\":[1,\"icon-name\"],\"fileSize\":[2,\"file-size\"],\"progress\":[2]}]]],[\"ez-application.cjs\",[[0,\"ez-application\"]]],[\"ez-card-item.cjs\",[[1,\"ez-card-item\",{\"item\":[16]}]]],[\"ez-loading-bar.cjs\",[[1,\"ez-loading-bar\",{\"_showLoading\":[32],\"hide\":[64],\"show\":[64]}]]],[\"ez-modal.cjs\",[[1,\"ez-modal\",{\"modalSize\":[1,\"modal-size\"],\"align\":[1],\"heightMode\":[1,\"height-mode\"],\"opened\":[1028],\"closeEsc\":[4,\"close-esc\"],\"closeOutsideClick\":[4,\"close-outside-click\"],\"scrim\":[1]}]]],[\"ez-popup.cjs\",[[1,\"ez-popup\",{\"size\":[1],\"opened\":[1540],\"useHeader\":[516,\"use-header\"],\"heightMode\":[513,\"height-mode\"],\"ezTitle\":[1,\"ez-title\"]}]]],[\"ez-radio-button.cjs\",[[1,\"ez-radio-button\",{\"value\":[1544],\"options\":[1040],\"enabled\":[516],\"label\":[513],\"direction\":[1537]}]]],[\"ez-skeleton.cjs\",[[0,\"ez-skeleton\",{\"count\":[2],\"variant\":[1],\"width\":[1],\"height\":[1],\"marginBottom\":[1,\"margin-bottom\"],\"animation\":[1]}]]],[\"ez-toast.cjs\",[[1,\"ez-toast\",{\"message\":[1025],\"fadeTime\":[1026,\"fade-time\"],\"useIcon\":[1028,\"use-icon\"],\"canClose\":[1028,\"can-close\"],\"show\":[64]}]]],[\"ez-view-stack.cjs\",[[0,\"ez-view-stack\",{\"show\":[64],\"getSelectedIndex\":[64]}]]],[\"ez-form-view.cjs\",[[2,\"ez-form-view\",{\"fields\":[16],\"showUp\":[64]}]]],[\"ez-filter-input_2.cjs\",[[0,\"multi-selection-box-message\",{\"message\":[1]}],[1,\"ez-filter-input\",{\"label\":[1],\"value\":[1537],\"enabled\":[4],\"errorMessage\":[1537,\"error-message\"],\"restrict\":[1],\"mode\":[513],\"asyncSearch\":[516,\"async-search\"],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64],\"setValue\":[64],\"endSearch\":[64]}]]],[\"ez-multi-selection-list.cjs\",[[2,\"ez-multi-selection-list\",{\"columnName\":[1,\"column-name\"],\"dataSource\":[16],\"useOptions\":[1028,\"use-options\"],\"options\":[16],\"filteredOptions\":[32],\"displayOptions\":[32],\"viewScenario\":[32],\"displayOptionToCheckAllItems\":[32],\"clearFilteredOptions\":[64]}]]],[\"filter-column.cjs\",[[0,\"filter-column\",{\"opened\":[4],\"columnName\":[1,\"column-name\"],\"columnLabel\":[1,\"column-label\"],\"dataSource\":[16],\"dataUnit\":[16],\"options\":[1040],\"selectedItems\":[32],\"fieldDescriptor\":[32],\"useOptions\":[32],\"hide\":[64],\"show\":[64]}]]],[\"ez-dropdown.cjs\",[[1,\"ez-dropdown\",{\"items\":[1040],\"value\":[1040],\"itemBuilder\":[16]}]]],[\"ez-tabselector.cjs\",[[1,\"ez-tabselector\",{\"selectedIndex\":[1538,\"selected-index\"],\"selectedTab\":[1537,\"selected-tab\"],\"tabs\":[1],\"_processedTabs\":[32]}]]],[\"ez-collapsible-box.cjs\",[[1,\"ez-collapsible-box\",{\"value\":[1540],\"boxBordered\":[4,\"box-bordered\"],\"label\":[513],\"subtitle\":[513],\"headerSize\":[513,\"header-size\"],\"iconPlacement\":[513,\"icon-placement\"],\"headerAlign\":[513,\"header-align\"],\"removable\":[516],\"editable\":[516],\"conditionalSave\":[16],\"_activeEditText\":[32],\"showHide\":[64],\"applyFocusTextEdit\":[64],\"cancelEdition\":[64]}]]],[\"ez-calendar.cjs\",[[1,\"ez-calendar\",{\"value\":[1040],\"floating\":[516],\"time\":[516],\"showSeconds\":[516,\"show-seconds\"],\"show\":[64],\"fitVertical\":[64],\"hide\":[64]}]]],[\"ez-text-input.cjs\",[[1,\"ez-text-input\",{\"label\":[513],\"value\":[1537],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"mask\":[1],\"canShowError\":[516,\"can-show-error\"],\"restrict\":[1],\"mode\":[513],\"noBorder\":[516,\"no-border\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-date-input.cjs\",[[1,\"ez-date-input\",{\"label\":[513],\"value\":[1040],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-date-time-input.cjs\",[[1,\"ez-date-time-input\",{\"label\":[513],\"value\":[1040],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"showSeconds\":[516,\"show-seconds\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-time-input.cjs\",[[1,\"ez-time-input\",{\"label\":[513],\"value\":[1026],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"showSeconds\":[516,\"show-seconds\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-number-input.cjs\",[[1,\"ez-number-input\",{\"label\":[1],\"value\":[1538],\"enabled\":[4],\"canShowError\":[516,\"can-show-error\"],\"errorMessage\":[1537,\"error-message\"],\"precision\":[2],\"prettyPrecision\":[2,\"pretty-precision\"],\"mode\":[513],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-popover.cjs\",[[1,\"ez-popover\",{\"autoClose\":[516,\"auto-close\"],\"boxWidth\":[513,\"box-width\"],\"opened\":[1540],\"innerElement\":[1537,\"inner-element\"],\"overlayType\":[513,\"overlay-type\"],\"updatePosition\":[64],\"show\":[64],\"showUnder\":[64],\"hide\":[64]}]]],[\"ez-text-area.cjs\",[[1,\"ez-text-area\",{\"label\":[513],\"value\":[1537],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"rows\":[1538],\"canShowError\":[516,\"can-show-error\"],\"mode\":[513],\"appendTextToSelection\":[64],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-upload.cjs\",[[1,\"ez-upload\",{\"label\":[1],\"subtitle\":[1],\"enabled\":[4],\"maxFileSize\":[2,\"max-file-size\"],\"maxFiles\":[2,\"max-files\"],\"requestHeaders\":[8,\"request-headers\"],\"urlUpload\":[1,\"url-upload\"],\"urlDelete\":[1,\"url-delete\"],\"value\":[1040],\"addFiles\":[64],\"setFocus\":[64],\"setBlur\":[64]}]]],[\"ez-text-edit.cjs\",[[1,\"ez-text-edit\",{\"value\":[1],\"styled\":[16],\"_newValue\":[32],\"applyFocusSelect\":[64]}]]],[\"ez-scroller_3.cjs\",[[1,\"ez-tree\",{\"items\":[1040],\"value\":[1040],\"selectedId\":[1537,\"selected-id\"],\"iconResolver\":[16],\"tooltipResolver\":[16],\"_tree\":[32],\"_waintingForLoad\":[32],\"selectItem\":[64],\"openItem\":[64],\"disableItem\":[64],\"enableItem\":[64],\"addChild\":[64],\"applyFilter\":[64],\"updateItem\":[64],\"getItem\":[64],\"getCurrentPath\":[64],\"getParent\":[64]},[[2,\"keydown\",\"onKeyDownListener\"]]],[1,\"ez-scroller\",{\"direction\":[1],\"locked\":[4],\"activeShadow\":[4,\"active-shadow\"],\"isActive\":[32]},[[2,\"click\",\"clickListener\"],[1,\"mousedown\",\"mouseDownHandler\"],[1,\"mouseup\",\"mouseUpHandler\"],[1,\"mousemove\",\"mouseMoveHandler\"]]],[1,\"ez-sidebar-button\"]]],[\"ez-list.cjs\",[[1,\"ez-list\",{\"dataSource\":[1040],\"listMode\":[1,\"list-mode\"],\"useGroups\":[1540,\"use-groups\"],\"ezDraggable\":[1028,\"ez-draggable\"],\"ezSelectable\":[1028,\"ez-selectable\"],\"itemSlotBuilder\":[1040],\"hoverFeedback\":[1028,\"hover-feedback\"],\"_listItems\":[32],\"_listGroupItems\":[32],\"clearHistory\":[64],\"scrollToTop\":[64],\"setSelection\":[64],\"getSelection\":[64],\"getList\":[64]}]]],[\"ez-combo-box.cjs\",[[1,\"ez-combo-box\",{\"value\":[1537],\"label\":[513],\"enabled\":[516],\"options\":[1040],\"errorMessage\":[1537,\"error-message\"],\"searchMode\":[4,\"search-mode\"],\"showSelectedValue\":[4,\"show-selected-value\"],\"showOptionValue\":[4,\"show-option-value\"],\"suppressSearch\":[4,\"suppress-search\"],\"optionLoader\":[16],\"suppressEmptyOption\":[4,\"suppress-empty-option\"],\"canShowError\":[516,\"can-show-error\"],\"mode\":[513],\"_preSelection\":[32],\"_visibleOptions\":[32],\"_startLoading\":[32],\"_showLoading\":[32],\"_criteria\":[32],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64],\"clearValue\":[64]},[[11,\"scroll\",\"scrollListener\"]]]]],[\"ez-search.cjs\",[[1,\"ez-search\",{\"value\":[1537],\"label\":[1537],\"enabled\":[1540],\"errorMessage\":[1537,\"error-message\"],\"optionLoader\":[16],\"showSelectedValue\":[4,\"show-selected-value\"],\"showOptionValue\":[4,\"show-option-value\"],\"suppressEmptyOption\":[4,\"suppress-empty-option\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64],\"clearValue\":[64]}]]],[\"ez-check.cjs\",[[1,\"ez-check\",{\"label\":[513],\"value\":[1540],\"enabled\":[1540],\"indeterminate\":[1540],\"mode\":[513],\"compact\":[4],\"getMode\":[64],\"setFocus\":[64]}]]],[\"ez-icon.cjs\",[[1,\"ez-icon\",{\"size\":[513],\"href\":[513],\"iconName\":[513,\"icon-name\"]}]]],[\"ez-button.cjs\",[[1,\"ez-button\",{\"label\":[513],\"enabled\":[516],\"mode\":[513],\"image\":[513],\"iconName\":[513,\"icon-name\"],\"size\":[513],\"setFocus\":[64],\"setBlur\":[64]},[[2,\"click\",\"clickListener\"]]]]],[\"ez-form.cjs\",[[2,\"ez-form\",{\"dataUnit\":[1040],\"config\":[16],\"recordsValidator\":[16],\"validate\":[64]}]]]]"), options);
|
|
17
|
+
return index.bootstrapLazy(JSON.parse("[[\"ez-grid.cjs\",[[6,\"ez-grid\",{\"multipleSelection\":[4,\"multiple-selection\"],\"config\":[1040],\"selectionToastConfig\":[16],\"serverUrl\":[1,\"server-url\"],\"dataUnit\":[16],\"statusResolver\":[16],\"columnfilterDataSource\":[16],\"_paginationInfo\":[32],\"_paginationChangedByKeyboard\":[32],\"_showSelectionCounter\":[32],\"_isAllSelection\":[32],\"_currentPageSelected\":[32],\"_selectionCount\":[32],\"_originalRecords\":[32],\"setColumnsDef\":[64],\"addColumnMenuItem\":[64],\"setColumnsState\":[64],\"setData\":[64],\"getSelection\":[64],\"getColumnsState\":[64],\"getColumns\":[64],\"quickFilter\":[64]},[[0,\"ezSelectionChange\",\"onSelectionChange\"]]]]],[\"ez-guide-navigator.cjs\",[[1,\"ez-guide-navigator\",{\"open\":[1540],\"selectedId\":[1537,\"selected-id\"],\"items\":[16],\"tooltipResolver\":[16],\"filterText\":[32],\"disableItem\":[64],\"enableItem\":[64],\"updateItem\":[64],\"getItem\":[64],\"getCurrentPath\":[64],\"selectGuide\":[64],\"getParent\":[64]}]]],[\"ez-actions-button.cjs\",[[1,\"ez-actions-button\",{\"enabled\":[516],\"actions\":[1040],\"size\":[513],\"showLabel\":[516,\"show-label\"],\"displayIcon\":[513,\"display-icon\"],\"checkOption\":[516,\"check-option\"],\"value\":[513],\"isTransparent\":[516,\"is-transparent\"],\"arrowActive\":[516,\"arrow-active\"],\"_selectedAction\":[32],\"hideActions\":[64],\"isOpened\":[64]}]]],[\"ez-breadcrumb.cjs\",[[1,\"ez-breadcrumb\",{\"items\":[1040],\"fillMode\":[1025,\"fill-mode\"],\"maxItems\":[1026,\"max-items\"],\"positionEllipsis\":[1026,\"position-ellipsis\"],\"visibleItems\":[32],\"hiddenItems\":[32],\"showDropdown\":[32],\"collapseConfigPosition\":[32]}]]],[\"ez-dialog.cjs\",[[1,\"ez-dialog\",{\"confirm\":[1028],\"dialogType\":[1025,\"dialog-type\"],\"message\":[1025],\"opened\":[1540],\"personalizedIconPath\":[1025,\"personalized-icon-path\"],\"ezTitle\":[1025,\"ez-title\"],\"beforeClose\":[1040],\"show\":[64]}]]],[\"ez-modal-container.cjs\",[[6,\"ez-modal-container\",{\"modalTitle\":[1,\"modal-title\"],\"modalSubTitle\":[1,\"modal-sub-title\"],\"showTitleBar\":[4,\"show-title-bar\"],\"cancelButtonLabel\":[1,\"cancel-button-label\"],\"okButtonLabel\":[1,\"ok-button-label\"],\"cancelButtonStatus\":[1,\"cancel-button-status\"],\"okButtonStatus\":[1,\"ok-button-status\"]}]]],[\"ez-alert.cjs\",[[1,\"ez-alert\",{\"alertType\":[513,\"alert-type\"]}]]],[\"ez-badge.cjs\",[[1,\"ez-badge\",{\"size\":[513],\"label\":[513],\"iconLeft\":[513,\"icon-left\"],\"iconRight\":[513,\"icon-right\"],\"position\":[1040],\"hasSlot\":[32]}]]],[\"ez-chip.cjs\",[[1,\"ez-chip\",{\"label\":[513],\"enabled\":[516],\"removePosition\":[513,\"remove-position\"],\"mode\":[513],\"value\":[1540],\"showNativeTooltip\":[4,\"show-native-tooltip\"],\"setFocus\":[64],\"setBlur\":[64]}]]],[\"ez-file-item.cjs\",[[1,\"ez-file-item\",{\"canRemove\":[4,\"can-remove\"],\"fileName\":[1,\"file-name\"],\"iconName\":[1,\"icon-name\"],\"fileSize\":[2,\"file-size\"],\"progress\":[2]}]]],[\"ez-application.cjs\",[[0,\"ez-application\"]]],[\"ez-card-item.cjs\",[[1,\"ez-card-item\",{\"item\":[16]}]]],[\"ez-loading-bar.cjs\",[[1,\"ez-loading-bar\",{\"_showLoading\":[32],\"hide\":[64],\"show\":[64]}]]],[\"ez-modal.cjs\",[[1,\"ez-modal\",{\"modalSize\":[1,\"modal-size\"],\"align\":[1],\"heightMode\":[1,\"height-mode\"],\"opened\":[1028],\"closeEsc\":[4,\"close-esc\"],\"closeOutsideClick\":[4,\"close-outside-click\"],\"scrim\":[1]}]]],[\"ez-popup.cjs\",[[1,\"ez-popup\",{\"size\":[1],\"opened\":[1540],\"useHeader\":[516,\"use-header\"],\"heightMode\":[513,\"height-mode\"],\"ezTitle\":[1,\"ez-title\"]}]]],[\"ez-radio-button.cjs\",[[1,\"ez-radio-button\",{\"value\":[1544],\"options\":[1040],\"enabled\":[516],\"label\":[513],\"direction\":[1537]}]]],[\"ez-skeleton.cjs\",[[0,\"ez-skeleton\",{\"count\":[2],\"variant\":[1],\"width\":[1],\"height\":[1],\"marginBottom\":[1,\"margin-bottom\"],\"animation\":[1]}]]],[\"ez-toast.cjs\",[[1,\"ez-toast\",{\"message\":[1025],\"fadeTime\":[1026,\"fade-time\"],\"useIcon\":[1028,\"use-icon\"],\"canClose\":[1028,\"can-close\"],\"show\":[64]}]]],[\"ez-view-stack.cjs\",[[0,\"ez-view-stack\",{\"show\":[64],\"getSelectedIndex\":[64]}]]],[\"ez-form-view.cjs\",[[2,\"ez-form-view\",{\"fields\":[16],\"showUp\":[64]}]]],[\"ez-filter-input_2.cjs\",[[0,\"multi-selection-box-message\",{\"message\":[1]}],[1,\"ez-filter-input\",{\"label\":[1],\"value\":[1537],\"enabled\":[4],\"errorMessage\":[1537,\"error-message\"],\"restrict\":[1],\"mode\":[513],\"asyncSearch\":[516,\"async-search\"],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64],\"setValue\":[64],\"endSearch\":[64]}]]],[\"ez-multi-selection-list.cjs\",[[2,\"ez-multi-selection-list\",{\"columnName\":[1,\"column-name\"],\"dataSource\":[16],\"useOptions\":[1028,\"use-options\"],\"options\":[16],\"filteredOptions\":[32],\"displayOptions\":[32],\"viewScenario\":[32],\"displayOptionToCheckAllItems\":[32],\"clearFilteredOptions\":[64]}]]],[\"filter-column.cjs\",[[0,\"filter-column\",{\"opened\":[4],\"columnName\":[1,\"column-name\"],\"columnLabel\":[1,\"column-label\"],\"gridHeaderHidden\":[4,\"grid-header-hidden\"],\"dataSource\":[16],\"dataUnit\":[16],\"options\":[1040],\"selectedItems\":[32],\"fieldDescriptor\":[32],\"useOptions\":[32],\"hide\":[64],\"show\":[64]}]]],[\"ez-dropdown.cjs\",[[1,\"ez-dropdown\",{\"items\":[1040],\"value\":[1040],\"itemBuilder\":[16]}]]],[\"ez-tabselector.cjs\",[[1,\"ez-tabselector\",{\"selectedIndex\":[1538,\"selected-index\"],\"selectedTab\":[1537,\"selected-tab\"],\"tabs\":[1],\"_processedTabs\":[32]}]]],[\"ez-collapsible-box.cjs\",[[1,\"ez-collapsible-box\",{\"value\":[1540],\"boxBordered\":[4,\"box-bordered\"],\"label\":[513],\"subtitle\":[513],\"headerSize\":[513,\"header-size\"],\"iconPlacement\":[513,\"icon-placement\"],\"headerAlign\":[513,\"header-align\"],\"removable\":[516],\"editable\":[516],\"conditionalSave\":[16],\"_activeEditText\":[32],\"showHide\":[64],\"applyFocusTextEdit\":[64],\"cancelEdition\":[64]}]]],[\"ez-calendar.cjs\",[[1,\"ez-calendar\",{\"value\":[1040],\"floating\":[516],\"time\":[516],\"showSeconds\":[516,\"show-seconds\"],\"show\":[64],\"fitVertical\":[64],\"hide\":[64]}]]],[\"ez-text-input.cjs\",[[1,\"ez-text-input\",{\"label\":[513],\"value\":[1537],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"mask\":[1],\"canShowError\":[516,\"can-show-error\"],\"restrict\":[1],\"mode\":[513],\"noBorder\":[516,\"no-border\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-date-input.cjs\",[[1,\"ez-date-input\",{\"label\":[513],\"value\":[1040],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-date-time-input.cjs\",[[1,\"ez-date-time-input\",{\"label\":[513],\"value\":[1040],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"showSeconds\":[516,\"show-seconds\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-time-input.cjs\",[[1,\"ez-time-input\",{\"label\":[513],\"value\":[1026],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"showSeconds\":[516,\"show-seconds\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-number-input.cjs\",[[1,\"ez-number-input\",{\"label\":[1],\"value\":[1538],\"enabled\":[4],\"canShowError\":[516,\"can-show-error\"],\"errorMessage\":[1537,\"error-message\"],\"precision\":[2],\"prettyPrecision\":[2,\"pretty-precision\"],\"mode\":[513],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-popover.cjs\",[[1,\"ez-popover\",{\"autoClose\":[516,\"auto-close\"],\"boxWidth\":[513,\"box-width\"],\"opened\":[1540],\"innerElement\":[1537,\"inner-element\"],\"overlayType\":[513,\"overlay-type\"],\"updatePosition\":[64],\"show\":[64],\"showUnder\":[64],\"hide\":[64]}]]],[\"ez-text-area.cjs\",[[1,\"ez-text-area\",{\"label\":[513],\"value\":[1537],\"enabled\":[516],\"errorMessage\":[1537,\"error-message\"],\"rows\":[1538],\"canShowError\":[516,\"can-show-error\"],\"mode\":[513],\"appendTextToSelection\":[64],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64]}]]],[\"ez-upload.cjs\",[[1,\"ez-upload\",{\"label\":[1],\"subtitle\":[1],\"enabled\":[4],\"maxFileSize\":[2,\"max-file-size\"],\"maxFiles\":[2,\"max-files\"],\"requestHeaders\":[8,\"request-headers\"],\"urlUpload\":[1,\"url-upload\"],\"urlDelete\":[1,\"url-delete\"],\"value\":[1040],\"addFiles\":[64],\"setFocus\":[64],\"setBlur\":[64]}]]],[\"ez-text-edit.cjs\",[[1,\"ez-text-edit\",{\"value\":[1],\"styled\":[16],\"_newValue\":[32],\"applyFocusSelect\":[64]}]]],[\"ez-scroller_3.cjs\",[[1,\"ez-tree\",{\"items\":[1040],\"value\":[1040],\"selectedId\":[1537,\"selected-id\"],\"iconResolver\":[16],\"tooltipResolver\":[16],\"_tree\":[32],\"_waintingForLoad\":[32],\"selectItem\":[64],\"openItem\":[64],\"disableItem\":[64],\"enableItem\":[64],\"addChild\":[64],\"applyFilter\":[64],\"updateItem\":[64],\"getItem\":[64],\"getCurrentPath\":[64],\"getParent\":[64]},[[2,\"keydown\",\"onKeyDownListener\"]]],[1,\"ez-scroller\",{\"direction\":[1],\"locked\":[4],\"activeShadow\":[4,\"active-shadow\"],\"isActive\":[32]},[[2,\"click\",\"clickListener\"],[1,\"mousedown\",\"mouseDownHandler\"],[1,\"mouseup\",\"mouseUpHandler\"],[1,\"mousemove\",\"mouseMoveHandler\"]]],[1,\"ez-sidebar-button\"]]],[\"ez-list.cjs\",[[1,\"ez-list\",{\"dataSource\":[1040],\"listMode\":[1,\"list-mode\"],\"useGroups\":[1540,\"use-groups\"],\"ezDraggable\":[1028,\"ez-draggable\"],\"ezSelectable\":[1028,\"ez-selectable\"],\"itemSlotBuilder\":[1040],\"hoverFeedback\":[1028,\"hover-feedback\"],\"_listItems\":[32],\"_listGroupItems\":[32],\"clearHistory\":[64],\"scrollToTop\":[64],\"setSelection\":[64],\"getSelection\":[64],\"getList\":[64]}]]],[\"ez-combo-box.cjs\",[[1,\"ez-combo-box\",{\"value\":[1537],\"label\":[513],\"enabled\":[516],\"options\":[1040],\"errorMessage\":[1537,\"error-message\"],\"searchMode\":[4,\"search-mode\"],\"showSelectedValue\":[4,\"show-selected-value\"],\"showOptionValue\":[4,\"show-option-value\"],\"suppressSearch\":[4,\"suppress-search\"],\"optionLoader\":[16],\"suppressEmptyOption\":[4,\"suppress-empty-option\"],\"canShowError\":[516,\"can-show-error\"],\"mode\":[513],\"_preSelection\":[32],\"_visibleOptions\":[32],\"_startLoading\":[32],\"_showLoading\":[32],\"_criteria\":[32],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64],\"clearValue\":[64]},[[11,\"scroll\",\"scrollListener\"]]]]],[\"ez-search.cjs\",[[1,\"ez-search\",{\"value\":[1537],\"label\":[1537],\"enabled\":[1540],\"errorMessage\":[1537,\"error-message\"],\"optionLoader\":[16],\"showSelectedValue\":[4,\"show-selected-value\"],\"showOptionValue\":[4,\"show-option-value\"],\"suppressEmptyOption\":[4,\"suppress-empty-option\"],\"mode\":[513],\"canShowError\":[516,\"can-show-error\"],\"setFocus\":[64],\"setBlur\":[64],\"isInvalid\":[64],\"clearValue\":[64]}]]],[\"ez-check.cjs\",[[1,\"ez-check\",{\"label\":[513],\"value\":[1540],\"enabled\":[1540],\"indeterminate\":[1540],\"mode\":[513],\"compact\":[4],\"getMode\":[64],\"setFocus\":[64]}]]],[\"ez-icon.cjs\",[[1,\"ez-icon\",{\"size\":[513],\"href\":[513],\"iconName\":[513,\"icon-name\"]}]]],[\"ez-button.cjs\",[[1,\"ez-button\",{\"label\":[513],\"enabled\":[516],\"mode\":[513],\"image\":[513],\"iconName\":[513,\"icon-name\"],\"size\":[513],\"setFocus\":[64],\"setBlur\":[64]},[[2,\"click\",\"clickListener\"]]]]],[\"ez-form.cjs\",[[2,\"ez-form\",{\"dataUnit\":[1040],\"config\":[16],\"recordsValidator\":[16],\"validate\":[64]}]]]]"), options);
|
|
18
18
|
});
|
|
19
19
|
};
|
|
20
20
|
|
|
@@ -14,10 +14,6 @@
|
|
|
14
14
|
--ez-grid__container--shadow: 0 0 16px 0 rgb(0 38 111 / 12%);
|
|
15
15
|
}
|
|
16
16
|
|
|
17
|
-
:host[no-header]{
|
|
18
|
-
grid-template-rows: 1fr auto;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
17
|
.grid-header {
|
|
22
18
|
display: grid;
|
|
23
19
|
justify-content: space-between;
|
|
@@ -96,5 +92,6 @@
|
|
|
96
92
|
}
|
|
97
93
|
|
|
98
94
|
:host[no-header] .grid-header {
|
|
99
|
-
|
|
95
|
+
height: 0;
|
|
96
|
+
padding: 0;
|
|
100
97
|
}
|
|
@@ -15,8 +15,10 @@ export class EzGrid {
|
|
|
15
15
|
this._isAllSelection = false;
|
|
16
16
|
this._currentPageSelected = undefined;
|
|
17
17
|
this._selectionCount = undefined;
|
|
18
|
+
this._originalRecords = [];
|
|
18
19
|
this.multipleSelection = undefined;
|
|
19
20
|
this.config = undefined;
|
|
21
|
+
this.selectionToastConfig = undefined;
|
|
20
22
|
this.serverUrl = undefined;
|
|
21
23
|
this.dataUnit = undefined;
|
|
22
24
|
this.statusResolver = undefined;
|
|
@@ -271,11 +273,39 @@ export class EzGrid {
|
|
|
271
273
|
ApplicationUtils.info(this._messageFilterAppliedSuccess);
|
|
272
274
|
});
|
|
273
275
|
}
|
|
276
|
+
getDataSource() {
|
|
277
|
+
return this.columnfilterDataSource ? this.columnfilterDataSource : this.buildDefaultDataSource();
|
|
278
|
+
}
|
|
279
|
+
buildDefaultDataSource() {
|
|
280
|
+
if (this._originalRecords.length === 0) {
|
|
281
|
+
this._originalRecords = this.dataUnit.records;
|
|
282
|
+
}
|
|
283
|
+
return {
|
|
284
|
+
fetchData: (filterTerm, fieldName) => {
|
|
285
|
+
return new Promise(resolve => {
|
|
286
|
+
const filteredRecords = this._originalRecords.filter(record => {
|
|
287
|
+
var _a;
|
|
288
|
+
const label = record[fieldName] === "object" ? (_a = record[fieldName]) === null || _a === void 0 ? void 0 : _a.label : record[fieldName];
|
|
289
|
+
return label === null || label === void 0 ? void 0 : label.toString().toLowerCase().includes(filterTerm.toLowerCase());
|
|
290
|
+
});
|
|
291
|
+
const options = filteredRecords.map(record => this.buildIMultiSelectionOption(record[fieldName]));
|
|
292
|
+
resolve(options);
|
|
293
|
+
});
|
|
294
|
+
}
|
|
295
|
+
};
|
|
296
|
+
}
|
|
297
|
+
buildIMultiSelectionOption(data) {
|
|
298
|
+
return {
|
|
299
|
+
check: true,
|
|
300
|
+
value: String(data),
|
|
301
|
+
label: String(data)
|
|
302
|
+
};
|
|
303
|
+
}
|
|
274
304
|
render() {
|
|
275
305
|
var _a;
|
|
276
|
-
return (h(Host, null, h("div", { class: "ez-box ez-box--shadow ez-padding--medium grid-header" }, h("filter-column", { class: "grid-header__popover", dataSource: this.
|
|
306
|
+
return (h(Host, null, h("div", { class: "ez-box ez-box--shadow ez-padding--medium grid-header" }, h("filter-column", { class: "grid-header__popover", dataSource: this.getDataSource(), dataUnit: this.dataUnit, gridHeaderHidden: !!this._element.getAttribute("no-header"), ref: (element) => (this._filterColumn = element) }), h("div", { class: "grid-header__position" }, h("div", { class: "grid-header__container" }, h("slot", { name: "leftButtons" })), h("div", { class: "grid-header__container", ref: ref => (this._refPaginationControl = ref) }, this.getPaginationControl()))), h("div", { ref: (ref) => (this._gridSelectionCounter = ref), class: `grid__selection-counter
|
|
277
307
|
${this._showSelectionCounter ? 'grid__selection-counter--opened' : ''}
|
|
278
|
-
` }, h(SelectionCounter, { selectionCount: this._selectionCount, currentPageSelected: this._currentPageSelected,
|
|
308
|
+
` }, h(SelectionCounter, { selectionCount: this._selectionCount, currentPageSelected: this._currentPageSelected, paginationInfo: this._paginationInfo, canSelectAll: (_a = this.selectionToastConfig) === null || _a === void 0 ? void 0 : _a.canSelectAll, allRecordSelected: this._isAllSelection, onSelectAll: () => this.onSelectAllRecords(), onSelectPage: () => this.onSelectPageRecords(), onClearAll: () => this.onClearSelectedRecords(), onClose: () => (this._showSelectionCounter = false) })), h("div", { class: "grid__container ez-grid", ref: elem => (this._container = elem) }), h("div", { class: "grid__footer" }, h("slot", { name: "footer" }))));
|
|
279
309
|
}
|
|
280
310
|
static get is() { return "ez-grid"; }
|
|
281
311
|
static get encapsulation() { return "scoped"; }
|
|
@@ -329,6 +359,26 @@ export class EzGrid {
|
|
|
329
359
|
"text": "Configura\u00E7\u00E3o de exibi\u00E7\u00E3o da grade."
|
|
330
360
|
}
|
|
331
361
|
},
|
|
362
|
+
"selectionToastConfig": {
|
|
363
|
+
"type": "unknown",
|
|
364
|
+
"mutable": false,
|
|
365
|
+
"complexType": {
|
|
366
|
+
"original": "ISelectionToastConfig",
|
|
367
|
+
"resolved": "ISelectionToastConfig",
|
|
368
|
+
"references": {
|
|
369
|
+
"ISelectionToastConfig": {
|
|
370
|
+
"location": "import",
|
|
371
|
+
"path": "./interfaces"
|
|
372
|
+
}
|
|
373
|
+
}
|
|
374
|
+
},
|
|
375
|
+
"required": false,
|
|
376
|
+
"optional": false,
|
|
377
|
+
"docs": {
|
|
378
|
+
"tags": [],
|
|
379
|
+
"text": "Configura\u00E7\u00E3o da sele\u00E7\u00E3o de grade no toast."
|
|
380
|
+
}
|
|
381
|
+
},
|
|
332
382
|
"serverUrl": {
|
|
333
383
|
"type": "string",
|
|
334
384
|
"mutable": false,
|
|
@@ -419,7 +469,8 @@ export class EzGrid {
|
|
|
419
469
|
"_showSelectionCounter": {},
|
|
420
470
|
"_isAllSelection": {},
|
|
421
471
|
"_currentPageSelected": {},
|
|
422
|
-
"_selectionCount": {}
|
|
472
|
+
"_selectionCount": {},
|
|
473
|
+
"_originalRecords": {}
|
|
423
474
|
};
|
|
424
475
|
}
|
|
425
476
|
static get events() {
|
|
@@ -459,7 +510,7 @@ export class EzGrid {
|
|
|
459
510
|
"references": {
|
|
460
511
|
"ISelection": {
|
|
461
512
|
"location": "import",
|
|
462
|
-
"path": "./interfaces
|
|
513
|
+
"path": "./interfaces"
|
|
463
514
|
}
|
|
464
515
|
}
|
|
465
516
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -9,9 +9,12 @@ const onSubmitFilter = new CustomEvent('onSubmitFilter', {
|
|
|
9
9
|
export class FilterColumn {
|
|
10
10
|
constructor() {
|
|
11
11
|
this.TOP_POSITION = '65px';
|
|
12
|
+
this.TOP_POSITION_HEADER_HIDDEN = '18';
|
|
13
|
+
this.DEFAULT_HEIGHT = 430;
|
|
12
14
|
this.opened = true;
|
|
13
15
|
this.columnName = undefined;
|
|
14
16
|
this.columnLabel = undefined;
|
|
17
|
+
this.gridHeaderHidden = false;
|
|
15
18
|
this.dataSource = undefined;
|
|
16
19
|
this.dataUnit = undefined;
|
|
17
20
|
this.options = undefined;
|
|
@@ -34,9 +37,23 @@ export class FilterColumn {
|
|
|
34
37
|
this.setOptions(configs.filteredOptions);
|
|
35
38
|
this.columnName = configs.columnName;
|
|
36
39
|
this.columnLabel = configs.columnLabel;
|
|
37
|
-
await this.ezPopoverElement.show(this.
|
|
40
|
+
await this.ezPopoverElement.show(this.calcTopPosition(), configs.leftPosition);
|
|
38
41
|
}
|
|
39
42
|
}
|
|
43
|
+
calcTopPosition() {
|
|
44
|
+
const referencePosition = this.gridHeaderHidden
|
|
45
|
+
? this.TOP_POSITION_HEADER_HIDDEN
|
|
46
|
+
: this.TOP_POSITION.replace('px', '');
|
|
47
|
+
const totalPopoverHeight = parseInt(referencePosition) + this.DEFAULT_HEIGHT;
|
|
48
|
+
const popoverPosition = Math.round(this.ezPopoverElement.getBoundingClientRect().top);
|
|
49
|
+
const popoverBottomPosition = popoverPosition + totalPopoverHeight;
|
|
50
|
+
const windowHeight = window.innerHeight;
|
|
51
|
+
if (windowHeight > popoverBottomPosition) {
|
|
52
|
+
return referencePosition;
|
|
53
|
+
}
|
|
54
|
+
const differenceBetween = windowHeight - popoverBottomPosition;
|
|
55
|
+
return `${differenceBetween}px`;
|
|
56
|
+
}
|
|
40
57
|
async clearConfigs() {
|
|
41
58
|
var _a;
|
|
42
59
|
await ((_a = this.ezMultiSelectionList) === null || _a === void 0 ? void 0 : _a.clearFilteredOptions());
|
|
@@ -47,7 +64,10 @@ export class FilterColumn {
|
|
|
47
64
|
return !this.ezPopoverElement.opened || configs.columnName !== this.columnName;
|
|
48
65
|
}
|
|
49
66
|
submit() {
|
|
50
|
-
this.applyFilterColumnOptions.emit({
|
|
67
|
+
this.applyFilterColumnOptions.emit({
|
|
68
|
+
field: this.columnName,
|
|
69
|
+
values: this.selectedItems,
|
|
70
|
+
});
|
|
51
71
|
windowInstace.dispatchEvent(onSubmitFilter);
|
|
52
72
|
this.hide();
|
|
53
73
|
}
|
|
@@ -75,8 +95,8 @@ export class FilterColumn {
|
|
|
75
95
|
}
|
|
76
96
|
if (this.isCheckBoxOrSwitch()) {
|
|
77
97
|
return [
|
|
78
|
-
{ label:
|
|
79
|
-
{ label:
|
|
98
|
+
{ label: 'Sim', value: 'true', check: true },
|
|
99
|
+
{ label: 'Não', value: 'false', check: true },
|
|
80
100
|
];
|
|
81
101
|
}
|
|
82
102
|
const optionsObject = JSON.parse((_b = (_a = this.fieldDescriptor) === null || _a === void 0 ? void 0 : _a.properties) === null || _b === void 0 ? void 0 : _b.options);
|
|
@@ -91,7 +111,7 @@ export class FilterColumn {
|
|
|
91
111
|
}
|
|
92
112
|
}
|
|
93
113
|
render() {
|
|
94
|
-
return (h("ez-popover", { class:
|
|
114
|
+
return (h("ez-popover", { class: 'filter-column__popover', "overlay-type": 'none', ref: (element) => (this.ezPopoverElement = element), autoClose: true, onEzVisibilityChange: this.handleEzVisibilityChange.bind(this) }, h("section", { class: 'filter-column' }, h("header", { class: 'filter-column__header' }, h("span", { class: 'ez-text ez-text--medium filter-column__header-title' }, "Filtro da coluna ", this.columnLabel), h("ez-button", { mode: 'icon', "icon-name": 'close', class: 'ez-button--tertiary', onClick: () => this.hide() })), h("ez-multi-selection-list", { columnName: this.columnName, dataSource: this.dataSource, options: this.options, useOptions: this.useOptions, ref: (element) => (this.ezMultiSelectionList = element), onChangeFilteredOptions: (event) => this.changeSelectedItems(event.detail) }), h("footer", { class: 'filter-column__footer' }, h("ez-button", { label: 'Aplicar', class: 'ez-button--primary', onClick: this.submit.bind(this) })))));
|
|
95
115
|
}
|
|
96
116
|
static get is() { return "filter-column"; }
|
|
97
117
|
static get originalStyleUrls() {
|
|
@@ -158,6 +178,24 @@ export class FilterColumn {
|
|
|
158
178
|
"attribute": "column-label",
|
|
159
179
|
"reflect": false
|
|
160
180
|
},
|
|
181
|
+
"gridHeaderHidden": {
|
|
182
|
+
"type": "boolean",
|
|
183
|
+
"mutable": false,
|
|
184
|
+
"complexType": {
|
|
185
|
+
"original": "boolean",
|
|
186
|
+
"resolved": "boolean",
|
|
187
|
+
"references": {}
|
|
188
|
+
},
|
|
189
|
+
"required": false,
|
|
190
|
+
"optional": false,
|
|
191
|
+
"docs": {
|
|
192
|
+
"tags": [],
|
|
193
|
+
"text": ""
|
|
194
|
+
},
|
|
195
|
+
"attribute": "grid-header-hidden",
|
|
196
|
+
"reflect": false,
|
|
197
|
+
"defaultValue": "false"
|
|
198
|
+
},
|
|
161
199
|
"dataSource": {
|
|
162
200
|
"type": "unknown",
|
|
163
201
|
"mutable": false,
|
|
@@ -1,8 +1,16 @@
|
|
|
1
1
|
import { ElementIDUtils } from "@sankhyalabs/core";
|
|
2
2
|
import { h } from "@stencil/core";
|
|
3
3
|
export const SelectionCounter = (props) => {
|
|
4
|
-
const { selectionCount, currentPageSelected,
|
|
5
|
-
|
|
4
|
+
const { selectionCount, currentPageSelected, allRecordSelected, paginationInfo, canSelectAll, onSelectAll, onSelectPage, onClearAll, onClose } = props;
|
|
5
|
+
const { total, hasMore } = paginationInfo || {};
|
|
6
|
+
const shouldRenderSelectionButton = () => {
|
|
7
|
+
if ((!allRecordSelected && selectionCount === total) || (allRecordSelected && !hasMore))
|
|
8
|
+
return false;
|
|
9
|
+
if (canSelectAll !== undefined)
|
|
10
|
+
return canSelectAll;
|
|
11
|
+
return !!paginationInfo && (currentPageSelected || allRecordSelected);
|
|
12
|
+
};
|
|
13
|
+
return (h("div", Object.assign({ class: "ez-box ez-box--shadow-small" }, getElementID("ezGridSelectionCounter")), h("div", { class: "ez-flex ez-flex--align-items-center ez-size-width--full ez-padding-horizontal--medium" }, h("div", { class: "ez-flex ez-flex--wrap ez-flex--align-items-baseline ez-flex--justify-center" }, h("label", Object.assign({ innerHTML: getText(selectionCount, allRecordSelected), class: "ez-text ez-text--primary ez-text--medium ez-margin-right--medium ez-margin-top--medium" }, getElementID("ezGridSelectionCounter_label"))), h("div", { class: "ez-flex ez-margin-right--medium" }, shouldRenderSelectionButton() &&
|
|
6
14
|
h("ez-button", Object.assign({ class: "ez-margin-right--medium", label: `Selecionar ${allRecordSelected ? "apenas a página atual" : `todos os ${total} registros`}`, mode: "link", onClick: allRecordSelected ? onSelectPage : onSelectAll }, getElementID(`ezGridSelectionCounter_select${allRecordSelected ? "Page" : "All"}`))), h("ez-button", Object.assign({ class: "grid__btn-clear", label: "Limpar", mode: "link", onClick: onClearAll }, getElementID("ezGridSelectionCounter_clearAll"))))), h("button", Object.assign({ class: "grid__btn-close", title: "Fechar", onClick: onClose }, getElementID("ezGridSelectionCounter_close")), h("ez-icon", { iconName: "close" })))));
|
|
7
15
|
};
|
|
8
16
|
function getText(selectionCount, allSelectedRecords) {
|