@sankhyalabs/ezui 0.0.0-bugfix-dev-KB-08202.0 → 0.0.0-bugfix-dev-KB-6165.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.
Files changed (59) hide show
  1. package/README.md +10 -8
  2. package/dist/cjs/ez-combo-box.cjs.entry.js +3 -11
  3. package/dist/cjs/ez-form-view.cjs.entry.js +1 -37
  4. package/dist/cjs/ez-form.cjs.entry.js +1 -2
  5. package/dist/cjs/ez-grid.cjs.entry.js +38 -87
  6. package/dist/cjs/ez-multi-selection-list.cjs.entry.js +1 -3
  7. package/dist/cjs/ez-search.cjs.entry.js +1 -3
  8. package/dist/cjs/ezui.cjs.js +1 -1
  9. package/dist/cjs/filter-column.cjs.entry.js +7 -30
  10. package/dist/cjs/loader.cjs.js +1 -1
  11. package/dist/collection/components/ez-combo-box/ez-combo-box.js +3 -47
  12. package/dist/collection/components/ez-form/ez-form.js +0 -20
  13. package/dist/collection/components/ez-form-view/ez-form-view.js +0 -23
  14. package/dist/collection/components/ez-form-view/fieldbuilder/FieldBuilder.js +1 -4
  15. package/dist/collection/components/ez-grid/controller/ag-grid/AgGridController.js +1 -1
  16. package/dist/collection/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.js +1 -1
  17. package/dist/collection/components/ez-grid/ez-grid.js +39 -11
  18. package/dist/collection/components/ez-grid/subcomponents/filter-column.js +8 -50
  19. package/dist/collection/components/ez-multi-selection-list/ez-multi-selection-list.js +1 -21
  20. package/dist/collection/components/ez-search/ez-search.js +1 -39
  21. package/dist/collection/utils/form/DataBinder.js +1 -1
  22. package/dist/custom-elements/index.js +57 -178
  23. package/dist/esm/ez-combo-box.entry.js +3 -11
  24. package/dist/esm/ez-form-view.entry.js +1 -37
  25. package/dist/esm/ez-form.entry.js +1 -2
  26. package/dist/esm/ez-grid.entry.js +39 -88
  27. package/dist/esm/ez-multi-selection-list.entry.js +1 -3
  28. package/dist/esm/ez-search.entry.js +1 -3
  29. package/dist/esm/ezui.js +1 -1
  30. package/dist/esm/filter-column.entry.js +7 -30
  31. package/dist/esm/loader.js +1 -1
  32. package/dist/ezui/ezui.esm.js +1 -1
  33. package/dist/ezui/p-2a0e1679.entry.js +1 -0
  34. package/dist/ezui/p-4535da17.entry.js +1 -0
  35. package/dist/ezui/p-4c8b029b.entry.js +1 -0
  36. package/dist/ezui/p-4e31b69b.entry.js +1 -0
  37. package/dist/ezui/p-5495fa45.entry.js +1 -0
  38. package/dist/ezui/p-90fa4cb3.entry.js +1 -0
  39. package/dist/ezui/{p-964e5571.entry.js → p-fd54b5b4.entry.js} +2 -2
  40. package/dist/types/components/ez-combo-box/ez-combo-box.d.ts +0 -9
  41. package/dist/types/components/ez-form/ez-form.d.ts +0 -5
  42. package/dist/types/components/ez-form-view/ez-form-view.d.ts +0 -5
  43. package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.d.ts +1 -1
  44. package/dist/types/components/ez-grid/ez-grid.d.ts +5 -3
  45. package/dist/types/components/ez-grid/subcomponents/filter-column.d.ts +0 -8
  46. package/dist/types/components/ez-multi-selection-list/ez-multi-selection-list.d.ts +0 -4
  47. package/dist/types/components/ez-search/ez-search.d.ts +0 -8
  48. package/dist/types/components.d.ts +0 -51
  49. package/package.json +2 -2
  50. package/dist/collection/components/ez-form-view/structure/index.js +0 -29
  51. package/dist/collection/components/ez-grid/utils/InMemoryFilterColumnDataSource.js +0 -78
  52. package/dist/ezui/p-061f4d73.entry.js +0 -1
  53. package/dist/ezui/p-25562cf8.entry.js +0 -1
  54. package/dist/ezui/p-5e55a42b.entry.js +0 -1
  55. package/dist/ezui/p-6ab2f7c2.entry.js +0 -1
  56. package/dist/ezui/p-7526f2b6.entry.js +0 -1
  57. package/dist/ezui/p-8fdff9cd.entry.js +0 -1
  58. package/dist/types/components/ez-form-view/structure/index.d.ts +0 -14
  59. package/dist/types/components/ez-grid/utils/InMemoryFilterColumnDataSource.d.ts +0 -16
@@ -681,7 +681,7 @@ class DataBinder {
681
681
  this._dataUnit.addRecord();
682
682
  }
683
683
  this._dataUnit.clearInvalid(this.getCurrentRecordId(), fieldName);
684
- this._dataUnit.setFieldValue(fieldName, newValue);
684
+ this._dataUnit.setFieldValue(fieldName, newValue, [this.getCurrentRecordId()]);
685
685
  if (this._dataUnit.waitingForChange(fieldName)) {
686
686
  const bind = this._fields.get(fieldName);
687
687
  if (bind) {
@@ -2155,9 +2155,7 @@ const EzComboBox$1 = class extends HTMLElement$1 {
2155
2155
  this.suppressEmptyOption = false;
2156
2156
  this.canShowError = true;
2157
2157
  this.mode = "regular";
2158
- this.hideErrorOnFocusOut = true;
2159
2158
  this.listOptionsPosition = undefined;
2160
- this.isTextSearch = false;
2161
2159
  }
2162
2160
  observeErrorMessage() {
2163
2161
  var _a;
@@ -2480,6 +2478,7 @@ const EzComboBox$1 = class extends HTMLElement$1 {
2480
2478
  this._visibleOptions = [];
2481
2479
  this.clearSource();
2482
2480
  }
2481
+ this.setFocus();
2483
2482
  }
2484
2483
  loadOptions(mode, argument = "") {
2485
2484
  this._criteria = argument;
@@ -2664,12 +2663,6 @@ const EzComboBox$1 = class extends HTMLElement$1 {
2664
2663
  handlerIconClick() {
2665
2664
  this.searchMode ? this.loadOptions(SearchMode.ADVANCED) : this.showOptions();
2666
2665
  }
2667
- buildNumberArgument(argument) {
2668
- if (this.isTextSearch) {
2669
- return NaN;
2670
- }
2671
- return Number(argument || undefined);
2672
- }
2673
2666
  onTextInputChangeHandler(event) {
2674
2667
  var _a;
2675
2668
  this.clearDeboucingTimeout();
@@ -2680,7 +2673,7 @@ const EzComboBox$1 = class extends HTMLElement$1 {
2680
2673
  return;
2681
2674
  }
2682
2675
  const argument = (_a = event.target.value) === null || _a === void 0 ? void 0 : _a.trim();
2683
- const argumentNumber = this.buildNumberArgument(argument);
2676
+ const argumentNumber = Number(argument || undefined);
2684
2677
  if (!this._criteria) {
2685
2678
  this._textInput.value = event.data || argument;
2686
2679
  }
@@ -2767,8 +2760,7 @@ const EzComboBox$1 = class extends HTMLElement$1 {
2767
2760
  //event.stopPropagation();
2768
2761
  }
2769
2762
  onTextInputFocusOutHandler() {
2770
- if (this.hideErrorOnFocusOut)
2771
- this.cancelPreselection();
2763
+ this.cancelPreselection();
2772
2764
  }
2773
2765
  canShowListOptions() {
2774
2766
  return !this._showLoading && this._visibleOptions.length > 0;
@@ -4455,7 +4447,6 @@ const EzForm$1 = class extends HTMLElement$1 {
4455
4447
  super();
4456
4448
  this.__registerHost();
4457
4449
  this.ezReady = createEvent(this, "ezReady", 7);
4458
- this.formItemsReady = createEvent(this, "formItemsReady", 7);
4459
4450
  this.onDataUnitAction = (action) => {
4460
4451
  if (action.type === Action.METADATA_LOADED) {
4461
4452
  this.processMetadata();
@@ -4642,42 +4633,9 @@ uiBuilders$1.set(UserInterface.LONGTEXT, buildTextArea);
4642
4633
  const fieldBuilder = (field) => {
4643
4634
  const builder = uiBuilders$1.get(field.userInterface) || buildTextInput$1;
4644
4635
  const label = field.required ? `${field.label}${REQUIRED_INFO}` : field.label;
4645
- const builtElement = builder(Object.assign(Object.assign({}, field), { label }));
4646
- //@ts-ignore
4647
- builtElement.$attrs$['data-form-item'] = field.name;
4648
- return builtElement;
4636
+ return builder(Object.assign(Object.assign({}, field), { label }));
4649
4637
  };
4650
4638
 
4651
- class FormItem {
4652
- constructor(elem) {
4653
- this.elem = elem;
4654
- }
4655
- addRightElement(el) {
4656
- el.classList.add('ez-padding-left--small');
4657
- this.elem.classList.add('ez-col--nowrap');
4658
- this.elem.appendChild(el);
4659
- }
4660
- get fieldName() {
4661
- return this.elem.getAttribute('data-form-item');
4662
- }
4663
- }
4664
- class FormItems {
4665
- constructor(items, formId) {
4666
- this.items = new Map();
4667
- this.formId = formId;
4668
- items.forEach(item => {
4669
- const formItem = new FormItem(item);
4670
- this.items.set(formItem.fieldName, formItem);
4671
- });
4672
- }
4673
- getItem(name) {
4674
- return this.items.get(name);
4675
- }
4676
- get formName() {
4677
- return this.formId;
4678
- }
4679
- }
4680
-
4681
4639
  const ezFormViewCss = ".sc-ez-form-view-h{display:flex;flex-direction:row;flex-wrap:wrap;width:100%}";
4682
4640
 
4683
4641
  const EzFormView$1 = class extends HTMLElement$1 {
@@ -4685,7 +4643,6 @@ const EzFormView$1 = class extends HTMLElement$1 {
4685
4643
  super();
4686
4644
  this.__registerHost();
4687
4645
  this.ezContentReady = createEvent(this, "ezContentReady", 7);
4688
- this.formItemsReady = createEvent(this, "formItemsReady", 7);
4689
4646
  this.fields = undefined;
4690
4647
  }
4691
4648
  async showUp() {
@@ -4711,8 +4668,6 @@ const EzFormView$1 = class extends HTMLElement$1 {
4711
4668
  }
4712
4669
  componentDidRender() {
4713
4670
  this.ezContentReady.emit(Array.from(this._element.querySelectorAll("[data-field-name]")));
4714
- const formItems = new FormItems(Array.from(this._element.querySelectorAll("[data-form-item]")));
4715
- this.formItemsReady.emit(formItems);
4716
4671
  }
4717
4672
  render() {
4718
4673
  ElementIDUtils.addIDInfoIfNotExists(this._element, 'ezFormView');
@@ -123699,7 +123654,7 @@ class EzGridCustomHeader {
123699
123654
  onClickFilter() {
123700
123655
  var _a;
123701
123656
  const iconLeft = (_a = this.filterButton) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect().left;
123702
- this.params.showColumnFilter(`${calcFilterColumnLeftPosition(iconLeft)}px`, true);
123657
+ this.params.showColumnFilter(`${calcFilterColumnLeftPosition(iconLeft)}px`);
123703
123658
  }
123704
123659
  configSortIcon() {
123705
123660
  this.sortDownIcon.style.display = this.params.column.isSortDescending() ? 'flex' : 'none';
@@ -124941,7 +124896,7 @@ class AgGridController {
124941
124896
  tooltip: tooltip,
124942
124897
  isSortable: propSortable,
124943
124898
  hasFilter: () => this.hasFilterColumn(source.name),
124944
- showColumnFilter: (leftPosition, fromIcon) => this.showFilterColumn({ columnName: source.name, columnLabel: source.label, leftPosition, filteredOptions: this._filteredColumns.get(source.name), fromIcon }),
124899
+ showColumnFilter: (leftPosition) => this.showFilterColumn({ columnName: source.name, columnLabel: source.label, leftPosition, filteredOptions: this._filteredColumns.get(source.name) }),
124945
124900
  },
124946
124901
  valueFormatter: params => {
124947
124902
  if (params.value == undefined) {
@@ -125164,84 +125119,6 @@ function getElementID(sufix) {
125164
125119
  };
125165
125120
  }
125166
125121
 
125167
- class InMemoryFilterColumnDataSource {
125168
- constructor(dataUnit) {
125169
- var _a;
125170
- this.onDataUnitAction = (action) => {
125171
- if (action.type === Action.DATA_SAVED || action.type === Action.RECORDS_REMOVED) {
125172
- this.originalRecords = this.dataUnit.records;
125173
- }
125174
- };
125175
- this.dataUnit = dataUnit;
125176
- this.originalRecords = (_a = this.dataUnit.records) !== null && _a !== void 0 ? _a : [];
125177
- this.dataUnit.subscribe(this.onDataUnitAction);
125178
- }
125179
- fetchData(filterTerm, fieldName) {
125180
- return new Promise(resolve => {
125181
- const filteredRecords = this.originalRecords.filter(record => this.includesSearchTerm(record, fieldName, filterTerm));
125182
- const options = filteredRecords.map(item => this.buildFieldOption(item, fieldName));
125183
- resolve(this.removeDuplicatedOptions(options));
125184
- });
125185
- }
125186
- buildFieldOption(item, fieldName) {
125187
- return {
125188
- value: this.buildValue(item, fieldName),
125189
- label: this.formatLabel(fieldName, item[fieldName]),
125190
- check: true,
125191
- };
125192
- }
125193
- buildValue(item, fieldName) {
125194
- var _a;
125195
- let value = item[fieldName];
125196
- if (((_a = this.dataUnit.getField(fieldName)) === null || _a === void 0 ? void 0 : _a.dataType) === DataType.OBJECT) {
125197
- value = value.value;
125198
- }
125199
- return value === null || value === void 0 ? void 0 : value.toString();
125200
- }
125201
- removeDuplicatedOptions(options) {
125202
- const noDuplicatedOptions = [];
125203
- options.forEach(option => {
125204
- if (!noDuplicatedOptions.find(({ label }) => label === option.label)) {
125205
- noDuplicatedOptions.push(option);
125206
- }
125207
- });
125208
- return noDuplicatedOptions;
125209
- }
125210
- includesSearchTerm(record, fieldName, filterTerm) {
125211
- let label = this.buildLabel(fieldName, record[fieldName]);
125212
- return label.toLowerCase().includes(filterTerm.toLowerCase());
125213
- }
125214
- buildLabel(fieldName, value) {
125215
- var _a;
125216
- const { dataType } = this.dataUnit.getField(fieldName);
125217
- if (dataType === DataType.NUMBER) {
125218
- return value === null || value === void 0 ? void 0 : value.toString().replace('.', ',');
125219
- }
125220
- if (dataType === DataType.DATE) {
125221
- return (typeof value === 'object')
125222
- ? (_a = DateUtils$1.formatDate(this.dataUnit.valueFromString(fieldName, value))) === null || _a === void 0 ? void 0 : _a.toString()
125223
- : value === null || value === void 0 ? void 0 : value.toString();
125224
- }
125225
- if (dataType === DataType.OBJECT) {
125226
- return `${value === null || value === void 0 ? void 0 : value.value} - ${value === null || value === void 0 ? void 0 : value.label}`;
125227
- }
125228
- return value === null || value === void 0 ? void 0 : value.toString();
125229
- }
125230
- formatLabel(fieldName, value) {
125231
- var _a, _b;
125232
- const { userInterface, dataType } = this.dataUnit.getField(fieldName);
125233
- if (dataType === DataType.DATE) {
125234
- return (typeof value === 'object')
125235
- ? DateUtils$1.formatDate(this.dataUnit.valueFromString(fieldName, value))
125236
- : value === null || value === void 0 ? void 0 : value.toString();
125237
- }
125238
- if (dataType === DataType.NUMBER && userInterface !== UserInterface.DECIMALNUMBER) {
125239
- return (_a = parseInt(this.dataUnit.getFormattedValue(fieldName, value))) === null || _a === void 0 ? void 0 : _a.toString();
125240
- }
125241
- return (_b = this.dataUnit.getFormattedValue(fieldName, value)) === null || _b === void 0 ? void 0 : _b.toString();
125242
- }
125243
- }
125244
-
125245
125122
  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(--visible, 1);--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(--more-visible, 2)}.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}";
125246
125123
 
125247
125124
  const windowInstace$1 = window;
@@ -125256,13 +125133,18 @@ const EzGrid$1 = class extends HTMLElement$1 {
125256
125133
  this.componentReady = createEvent(this, "componentReady", 7);
125257
125134
  this._gridController = new AgGridController(false);
125258
125135
  this._messageFilterAppliedSuccess = 'Filtro de coluna aplicado com sucesso!';
125136
+ this.onDataUnitAction = (action) => {
125137
+ if (action.type === Action.DATA_SAVED || action.type === Action.RECORDS_REMOVED) {
125138
+ this._originalRecords = this.dataUnit.records;
125139
+ }
125140
+ };
125259
125141
  this._paginationInfo = undefined;
125260
125142
  this._paginationChangedByKeyboard = true;
125261
125143
  this._showSelectionCounter = false;
125262
125144
  this._isAllSelection = false;
125263
125145
  this._currentPageSelected = undefined;
125264
125146
  this._selectionCount = undefined;
125265
- this._hasLeftButtons = false;
125147
+ this._originalRecords = [];
125266
125148
  this.multipleSelection = undefined;
125267
125149
  this.config = undefined;
125268
125150
  this.selectionToastConfig = undefined;
@@ -125532,20 +125414,44 @@ const EzGrid$1 = class extends HTMLElement$1 {
125532
125414
  });
125533
125415
  }
125534
125416
  componentWillLoad() {
125535
- this._hasLeftButtons = !!this._element.querySelector('[slot="leftButtons"]');
125536
125417
  if (!this.dataUnit.name.includes("InMemoryDataUnit"))
125537
125418
  return;
125419
+ this.dataUnit.subscribe(this.onDataUnitAction);
125538
125420
  }
125539
125421
  getDataSource() {
125540
- var _a;
125541
- return (_a = this.columnfilterDataSource) !== null && _a !== void 0 ? _a : new InMemoryFilterColumnDataSource(this.dataUnit);
125422
+ return this.columnfilterDataSource ? this.columnfilterDataSource : this.buildDefaultDataSource();
125542
125423
  }
125543
- hideHeader() {
125544
- return (!!this._element.getAttribute("no-header") && !this._paginationInfo);
125424
+ buildDefaultDataSource() {
125425
+ var _a, _b;
125426
+ if (this._originalRecords.length === 0) {
125427
+ this._originalRecords = (_b = (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.records) !== null && _b !== void 0 ? _b : [];
125428
+ }
125429
+ return {
125430
+ fetchData: (filterTerm, fieldName) => {
125431
+ return new Promise(resolve => {
125432
+ const filteredRecords = this._originalRecords.filter(record => {
125433
+ var _a, _b;
125434
+ const label = typeof record[fieldName] === "object" ? `${(_a = record[fieldName]) === null || _a === void 0 ? void 0 : _a.value} - ${(_b = record[fieldName]) === null || _b === void 0 ? void 0 : _b.label}` : record[fieldName];
125435
+ return label === null || label === void 0 ? void 0 : label.toString().toLowerCase().includes(filterTerm.toLowerCase());
125436
+ });
125437
+ const options = filteredRecords.map(item => {
125438
+ return { value: item[fieldName].toString(), label: this.formatLabel(fieldName, item[fieldName]), check: true };
125439
+ });
125440
+ resolve(options);
125441
+ });
125442
+ }
125443
+ };
125444
+ }
125445
+ formatLabel(fieldName, value) {
125446
+ const { userInterface } = this.dataUnit.getField(fieldName);
125447
+ if (userInterface === UserInterface.DATETIME) {
125448
+ return DateUtils$1.formatDate(this.dataUnit.valueFromString(fieldName, value));
125449
+ }
125450
+ return String(this.dataUnit.getFormattedValue(fieldName, value));
125545
125451
  }
125546
125452
  render() {
125547
125453
  var _a;
125548
- return (h(Host, { "no-header": this.hideHeader() }, h("div", { class: "ez-box ez-box--shadow ez-padding--medium grid-header" }, h("filter-column", { class: "grid-header__popover", noHeaderTaskBar: !this._hasLeftButtons, dataSource: this.getDataSource(), dataUnit: this.dataUnit, gridHeaderHidden: this.hideHeader(), 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
125454
+ 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
125549
125455
  ${this._showSelectionCounter ? 'grid__selection-counter--opened' : ''}
125550
125456
  ` }, 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" }))));
125551
125457
  }
@@ -126413,7 +126319,6 @@ const EzMuiltiSelectionList = class extends HTMLElement$1 {
126413
126319
  this.dataSource = undefined;
126414
126320
  this.useOptions = false;
126415
126321
  this.options = undefined;
126416
- this.isTextSearch = false;
126417
126322
  this.filteredOptions = undefined;
126418
126323
  this.displayOptions = undefined;
126419
126324
  this.viewScenario = undefined;
@@ -126496,7 +126401,6 @@ const EzMuiltiSelectionList = class extends HTMLElement$1 {
126496
126401
  this.filteredOptions = this.ordenationByCheckStateAndAlphabetically([...optionsToSort, event.detail]);
126497
126402
  }
126498
126403
  this.viewScenario = ViewScenarios.DATASOURCE_RESULTS;
126499
- this.searchInput.value = "";
126500
126404
  }
126501
126405
  handleRemoveItemFromOptions(item) {
126502
126406
  this.filteredOptions = this.ordenationByCheckStateAndAlphabetically(this.filteredOptions.filter(i => i.value !== item.value));
@@ -126560,7 +126464,7 @@ const EzMuiltiSelectionList = class extends HTMLElement$1 {
126560
126464
  return scenarios[view];
126561
126465
  }
126562
126466
  render() {
126563
- return (h(Host, null, h("div", { class: "multi-selection" }, this.useOptions ? (h("ez-filter-input", { ref: (element) => (this.filterInput = element), label: `Buscar..`, onEzChange: this.handleSearchOnOption.bind(this) })) : (h("ez-search", { class: "multi-selection__input", label: `Buscar...`, ref: (element) => (this.searchInput = element), suppressEmptyOption: true, showOptionValue: false, showSelectedValue: false, optionLoader: (search) => this.searchWithDataSource(search, this.columnName), onEzChange: this.handleSearchOnDataSource.bind(this), isTextSearch: this.isTextSearch })), h("ez-scroll", { class: "multi-selection__content-options" }, this.scenarioToDisplay(this.viewScenario)))));
126467
+ return (h(Host, null, h("div", { class: "multi-selection" }, this.useOptions ? (h("ez-filter-input", { ref: (element) => (this.filterInput = element), label: `Buscar..`, onEzChange: this.handleSearchOnOption.bind(this) })) : (h("ez-search", { class: "multi-selection__input", label: `Buscar...`, ref: (element) => (this.searchInput = element), suppressEmptyOption: true, showOptionValue: false, showSelectedValue: false, optionLoader: (search) => this.searchWithDataSource(search, this.columnName), onEzChange: this.handleSearchOnDataSource.bind(this) })), h("ez-scroll", { class: "multi-selection__content-options" }, this.scenarioToDisplay(this.viewScenario)))));
126564
126468
  }
126565
126469
  static get watchers() { return {
126566
126470
  "useOptions": ["onChangeUseOptions"],
@@ -127205,9 +127109,7 @@ const EzSearch$1 = class extends HTMLElement$1 {
127205
127109
  this.suppressEmptyOption = false;
127206
127110
  this.mode = "regular";
127207
127111
  this.canShowError = true;
127208
- this.hideErrorOnFocusOut = true;
127209
127112
  this.listOptionsPosition = undefined;
127210
- this.isTextSearch = false;
127211
127113
  }
127212
127114
  observeErrorMessage() {
127213
127115
  if (this._comboElement) {
@@ -127265,7 +127167,7 @@ const EzSearch$1 = class extends HTMLElement$1 {
127265
127167
  }
127266
127168
  render() {
127267
127169
  ElementIDUtils.addIDInfoIfNotExists(this._elem, 'input');
127268
- return (h("ez-combo-box", { "data-element-id": ElementIDUtils.getInternalIDInfo("combo"), ref: elem => this._comboElement = elem, value: this.value, label: this.label, enabled: this.enabled, errorMessage: this.errorMessage, hideErrorOnFocusOut: this.hideErrorOnFocusOut, optionLoader: this.optionLoader, searchMode: true, onEzChange: event => this.onComboChange(event), showSelectedValue: this.showSelectedValue, showOptionValue: this.showOptionValue, suppressEmptyOption: this.suppressEmptyOption, mode: this.mode, canShowError: this.canShowError, listOptionsPosition: this.listOptionsPosition, isTextSearch: this.isTextSearch }));
127170
+ return (h("ez-combo-box", { "data-element-id": ElementIDUtils.getInternalIDInfo("combo"), ref: elem => this._comboElement = elem, value: this.value, label: this.label, enabled: this.enabled, errorMessage: this.errorMessage, optionLoader: this.optionLoader, searchMode: true, onEzChange: event => this.onComboChange(event), showSelectedValue: this.showSelectedValue, showOptionValue: this.showOptionValue, suppressEmptyOption: this.suppressEmptyOption, mode: this.mode, canShowError: this.canShowError, listOptionsPosition: this.listOptionsPosition }));
127269
127171
  }
127270
127172
  ;
127271
127173
  get _elem() { return this; }
@@ -129402,23 +129304,19 @@ const FilterColumn$1 = class extends HTMLElement$1 {
129402
129304
  super();
129403
129305
  this.__registerHost();
129404
129306
  this.applyFilterColumnOptions = createEvent(this, "applyFilterColumnOptions", 7);
129405
- this.TOP_POSITION = '65';
129307
+ this.TOP_POSITION = '65px';
129406
129308
  this.TOP_POSITION_HEADER_HIDDEN = '18';
129407
- this.TOP_POSITION_NO_TASKBAR = '32';
129408
- this.TOP_POSITION_NO_TASKBAR_HEADER_HIDDEN = '20';
129409
129309
  this.DEFAULT_HEIGHT = 430;
129410
129310
  this.opened = true;
129411
129311
  this.columnName = undefined;
129412
129312
  this.columnLabel = undefined;
129413
129313
  this.gridHeaderHidden = false;
129414
- this.noHeaderTaskBar = false;
129415
129314
  this.dataSource = undefined;
129416
129315
  this.dataUnit = undefined;
129417
129316
  this.options = undefined;
129418
129317
  this.selectedItems = undefined;
129419
129318
  this.fieldDescriptor = undefined;
129420
129319
  this.useOptions = false;
129421
- this.isTextSearch = false;
129422
129320
  }
129423
129321
  async hide() {
129424
129322
  await this.ezPopoverElement.hide();
@@ -129432,45 +129330,26 @@ const FilterColumn$1 = class extends HTMLElement$1 {
129432
129330
  if (this.canShow(configs)) {
129433
129331
  await this.hide();
129434
129332
  this.fieldDescriptor = this.dataUnit.getField(configs.columnName);
129435
- this.buildIsTextSearch();
129436
129333
  this.setOptions(configs.filteredOptions);
129437
129334
  this.columnName = configs.columnName;
129438
129335
  this.columnLabel = configs.columnLabel;
129439
- await this.ezPopoverElement.show(this.calcTopPosition(), this.calculateLeftPosition(configs));
129440
- }
129441
- }
129442
- calculateLeftPosition(configs) {
129443
- if (!configs.fromIcon) {
129444
- return configs.leftPosition;
129336
+ await this.ezPopoverElement.show(this.calcTopPosition(), configs.leftPosition);
129445
129337
  }
129446
- const difference = this.ezPopoverElement.getBoundingClientRect().left;
129447
- const leftReference = parseInt(configs.leftPosition.replace('px', ''));
129448
- const leftResolved = (leftReference + 16) - difference;
129449
- return `${(leftResolved > 0 ? leftResolved : 0)}px`;
129450
- }
129451
- buildIsTextSearch() {
129452
- var _a, _b;
129453
- const userInterface = (_b = (_a = this.fieldDescriptor) === null || _a === void 0 ? void 0 : _a.userInterface) !== null && _b !== void 0 ? _b : UserInterface.SHORTTEXT;
129454
- this.isTextSearch = !(userInterface === UserInterface.DECIMALNUMBER || userInterface === UserInterface.INTEGERNUMBER);
129455
129338
  }
129456
129339
  calcTopPosition() {
129457
- const referencePosition = this.buildReferenceTopPosition();
129340
+ const referencePosition = this.gridHeaderHidden
129341
+ ? this.TOP_POSITION_HEADER_HIDDEN
129342
+ : this.TOP_POSITION.replace('px', '');
129458
129343
  const totalPopoverHeight = parseInt(referencePosition) + this.DEFAULT_HEIGHT;
129459
129344
  const popoverPosition = Math.round(this.ezPopoverElement.getBoundingClientRect().top);
129460
129345
  const popoverBottomPosition = popoverPosition + totalPopoverHeight;
129461
129346
  const windowHeight = window.innerHeight;
129462
129347
  if (windowHeight > popoverBottomPosition) {
129463
- return `${referencePosition}px`;
129348
+ return referencePosition;
129464
129349
  }
129465
129350
  const differenceBetween = windowHeight - popoverBottomPosition;
129466
129351
  return `${differenceBetween}px`;
129467
129352
  }
129468
- buildReferenceTopPosition() {
129469
- if (this.noHeaderTaskBar) {
129470
- return this.gridHeaderHidden ? this.TOP_POSITION_NO_TASKBAR_HEADER_HIDDEN : this.TOP_POSITION_NO_TASKBAR;
129471
- }
129472
- return this.gridHeaderHidden ? this.TOP_POSITION_HEADER_HIDDEN : this.TOP_POSITION;
129473
- }
129474
129353
  async clearConfigs() {
129475
129354
  var _a;
129476
129355
  await ((_a = this.ezMultiSelectionList) === null || _a === void 0 ? void 0 : _a.clearFilteredOptions());
@@ -129528,7 +129407,7 @@ const FilterColumn$1 = class extends HTMLElement$1 {
129528
129407
  }
129529
129408
  }
129530
129409
  render() {
129531
- 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), isTextSearch: this.isTextSearch }), h("footer", { class: 'filter-column__footer' }, h("ez-button", { label: 'Aplicar', class: 'ez-button--primary', onClick: this.submit.bind(this) })))));
129410
+ 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) })))));
129532
129411
  }
129533
129412
  static get style() { return filterColumnCss; }
129534
129413
  };
@@ -129558,7 +129437,7 @@ const EzCardItem = /*@__PURE__*/proxyCustomElement(EzCardItem$1, [1,"ez-card-ite
129558
129437
  const EzCheck = /*@__PURE__*/proxyCustomElement(EzCheck$1, [1,"ez-check",{"label":[513],"value":[1540],"enabled":[1540],"indeterminate":[1540],"mode":[513],"compact":[4]}]);
129559
129438
  const EzChip = /*@__PURE__*/proxyCustomElement(EzChip$1, [1,"ez-chip",{"label":[513],"enabled":[516],"removePosition":[513,"remove-position"],"mode":[513],"value":[1540],"showNativeTooltip":[4,"show-native-tooltip"]}]);
129560
129439
  const EzCollapsibleBox = /*@__PURE__*/proxyCustomElement(EzCollapsibleBox$1, [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]}]);
129561
- const EzComboBox = /*@__PURE__*/proxyCustomElement(EzComboBox$1, [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],"hideErrorOnFocusOut":[4,"hide-error-on-focus-out"],"listOptionsPosition":[16],"isTextSearch":[4,"is-text-search"],"_preSelection":[32],"_visibleOptions":[32],"_startLoading":[32],"_showLoading":[32],"_criteria":[32]},[[11,"scroll","scrollListener"]]]);
129440
+ const EzComboBox = /*@__PURE__*/proxyCustomElement(EzComboBox$1, [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],"listOptionsPosition":[16],"_preSelection":[32],"_visibleOptions":[32],"_startLoading":[32],"_showLoading":[32],"_criteria":[32]},[[11,"scroll","scrollListener"]]]);
129562
129441
  const EzDateInput = /*@__PURE__*/proxyCustomElement(EzDateInput$1, [1,"ez-date-input",{"label":[513],"value":[1040],"enabled":[516],"errorMessage":[1537,"error-message"],"mode":[513],"canShowError":[516,"can-show-error"]}]);
129563
129442
  const EzDateTimeInput = /*@__PURE__*/proxyCustomElement(EzDateTimeInput$1, [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"]}]);
129564
129443
  const EzDialog = /*@__PURE__*/proxyCustomElement(EzDialog$1, [1,"ez-dialog",{"confirm":[1028],"dialogType":[1025,"dialog-type"],"message":[1025],"opened":[1540],"personalizedIconPath":[1025,"personalized-icon-path"],"ezTitle":[1025,"ez-title"],"beforeClose":[1040]}]);
@@ -129567,20 +129446,20 @@ const EzFileItem = /*@__PURE__*/proxyCustomElement(EzFileItem$1, [1,"ez-file-ite
129567
129446
  const EzFilterInput = /*@__PURE__*/proxyCustomElement(EzFilterInput$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"]}]);
129568
129447
  const EzForm = /*@__PURE__*/proxyCustomElement(EzForm$1, [2,"ez-form",{"dataUnit":[1040],"config":[16],"recordsValidator":[16]}]);
129569
129448
  const EzFormView = /*@__PURE__*/proxyCustomElement(EzFormView$1, [2,"ez-form-view",{"fields":[16]}]);
129570
- const EzGrid = /*@__PURE__*/proxyCustomElement(EzGrid$1, [6,"ez-grid",{"multipleSelection":[4,"multiple-selection"],"config":[1040],"selectionToastConfig":[16],"serverUrl":[1,"server-url"],"dataUnit":[16],"statusResolver":[16],"columnfilterDataSource":[16],"useEnterLikeTab":[4,"use-enter-like-tab"],"recordsValidator":[16],"canEdit":[4,"can-edit"],"_paginationInfo":[32],"_paginationChangedByKeyboard":[32],"_showSelectionCounter":[32],"_isAllSelection":[32],"_currentPageSelected":[32],"_selectionCount":[32],"_hasLeftButtons":[32]},[[0,"ezSelectionChange","onSelectionChange"]]]);
129449
+ const EzGrid = /*@__PURE__*/proxyCustomElement(EzGrid$1, [6,"ez-grid",{"multipleSelection":[4,"multiple-selection"],"config":[1040],"selectionToastConfig":[16],"serverUrl":[1,"server-url"],"dataUnit":[16],"statusResolver":[16],"columnfilterDataSource":[16],"useEnterLikeTab":[4,"use-enter-like-tab"],"recordsValidator":[16],"canEdit":[4,"can-edit"],"_paginationInfo":[32],"_paginationChangedByKeyboard":[32],"_showSelectionCounter":[32],"_isAllSelection":[32],"_currentPageSelected":[32],"_selectionCount":[32],"_originalRecords":[32]},[[0,"ezSelectionChange","onSelectionChange"]]]);
129571
129450
  const EzGuideNavigator = /*@__PURE__*/proxyCustomElement(EzGuideNavigator$1, [1,"ez-guide-navigator",{"open":[1540],"selectedId":[1537,"selected-id"],"items":[16],"tooltipResolver":[16],"filterText":[32]}]);
129572
129451
  const EzIcon = /*@__PURE__*/proxyCustomElement(EzIcon$1, [1,"ez-icon",{"size":[513],"href":[513],"iconName":[513,"icon-name"]}]);
129573
129452
  const EzList = /*@__PURE__*/proxyCustomElement(EzList$1, [1,"ez-list",{"dataSource":[1040],"listMode":[1,"list-mode"],"useGroups":[1540,"use-groups"],"ezDraggable":[1028,"ez-draggable"],"ezSelectable":[1028,"ez-selectable"],"itemSlotBuilder":[1040],"itemLeftSlotBuilder":[1040],"hoverFeedback":[1028,"hover-feedback"],"_listItems":[32],"_listGroupItems":[32]}]);
129574
129453
  const EzLoadingBar = /*@__PURE__*/proxyCustomElement(EzLoadingBar$1, [1,"ez-loading-bar",{"_showLoading":[32]}]);
129575
129454
  const EzModal = /*@__PURE__*/proxyCustomElement(EzModal$1, [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]}]);
129576
129455
  const EzModalContainer = /*@__PURE__*/proxyCustomElement(EzModalContainer$1, [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"]}]);
129577
- const EzMultiSelectionList = /*@__PURE__*/proxyCustomElement(EzMuiltiSelectionList, [2,"ez-multi-selection-list",{"columnName":[1,"column-name"],"dataSource":[16],"useOptions":[1028,"use-options"],"options":[16],"isTextSearch":[4,"is-text-search"],"filteredOptions":[32],"displayOptions":[32],"viewScenario":[32],"displayOptionToCheckAllItems":[32]}]);
129456
+ const EzMultiSelectionList = /*@__PURE__*/proxyCustomElement(EzMuiltiSelectionList, [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]}]);
129578
129457
  const EzNumberInput = /*@__PURE__*/proxyCustomElement(EzNumberInput$1, [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]}]);
129579
129458
  const EzPopover = /*@__PURE__*/proxyCustomElement(EzPopover$1, [1,"ez-popover",{"autoClose":[516,"auto-close"],"boxWidth":[513,"box-width"],"opened":[1540],"innerElement":[1537,"inner-element"],"overlayType":[513,"overlay-type"]}]);
129580
129459
  const EzPopup = /*@__PURE__*/proxyCustomElement(EzPopup$1, [1,"ez-popup",{"size":[1],"opened":[1540],"useHeader":[516,"use-header"],"heightMode":[513,"height-mode"],"ezTitle":[1,"ez-title"]}]);
129581
129460
  const EzRadioButton = /*@__PURE__*/proxyCustomElement(EzRadioButton$1, [1,"ez-radio-button",{"value":[1544],"options":[1040],"enabled":[516],"label":[513],"direction":[1537]}]);
129582
129461
  const EzScroller = /*@__PURE__*/proxyCustomElement(EzScroller$1, [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"]]]);
129583
- const EzSearch = /*@__PURE__*/proxyCustomElement(EzSearch$1, [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"],"hideErrorOnFocusOut":[4,"hide-error-on-focus-out"],"listOptionsPosition":[16],"isTextSearch":[4,"is-text-search"]}]);
129462
+ const EzSearch = /*@__PURE__*/proxyCustomElement(EzSearch$1, [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"],"listOptionsPosition":[16]}]);
129584
129463
  const EzSidebarButton = /*@__PURE__*/proxyCustomElement(EzSidebarButton$1, [1,"ez-sidebar-button"]);
129585
129464
  const EzSkeleton = /*@__PURE__*/proxyCustomElement(EzSkeleton$1, [0,"ez-skeleton",{"count":[2],"variant":[1],"width":[1],"height":[1],"marginBottom":[1,"margin-bottom"],"animation":[1]}]);
129586
129465
  const EzTabselector = /*@__PURE__*/proxyCustomElement(EzTabselector$1, [1,"ez-tabselector",{"selectedIndex":[1538,"selected-index"],"selectedTab":[1537,"selected-tab"],"tabs":[1],"_processedTabs":[32]}]);
@@ -129592,7 +129471,7 @@ const EzToast = /*@__PURE__*/proxyCustomElement(EzToast$1, [1,"ez-toast",{"messa
129592
129471
  const EzTree = /*@__PURE__*/proxyCustomElement(EzTree$1, [1,"ez-tree",{"items":[1040],"value":[1040],"selectedId":[1537,"selected-id"],"iconResolver":[16],"tooltipResolver":[16],"_tree":[32],"_waintingForLoad":[32]},[[2,"keydown","onKeyDownListener"]]]);
129593
129472
  const EzUpload = /*@__PURE__*/proxyCustomElement(EzUpload$1, [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]}]);
129594
129473
  const EzViewStack = /*@__PURE__*/proxyCustomElement(EzViewStack$1, [0,"ez-view-stack"]);
129595
- const FilterColumn = /*@__PURE__*/proxyCustomElement(FilterColumn$1, [0,"filter-column",{"opened":[4],"columnName":[1,"column-name"],"columnLabel":[1,"column-label"],"gridHeaderHidden":[4,"grid-header-hidden"],"noHeaderTaskBar":[1028,"no-header-task-bar"],"dataSource":[16],"dataUnit":[16],"options":[1040],"selectedItems":[32],"fieldDescriptor":[32],"useOptions":[32],"isTextSearch":[32]}]);
129474
+ const FilterColumn = /*@__PURE__*/proxyCustomElement(FilterColumn$1, [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]}]);
129596
129475
  const MultiSelectionBoxMessage = /*@__PURE__*/proxyCustomElement(MultiSelectionBoxMessage$1, [0,"multi-selection-box-message",{"message":[1]}]);
129597
129476
  const defineCustomElements = (opts) => {
129598
129477
  if (typeof customElements !== 'undefined') {
@@ -38,9 +38,7 @@ const EzComboBox = class {
38
38
  this.suppressEmptyOption = false;
39
39
  this.canShowError = true;
40
40
  this.mode = "regular";
41
- this.hideErrorOnFocusOut = true;
42
41
  this.listOptionsPosition = undefined;
43
- this.isTextSearch = false;
44
42
  }
45
43
  observeErrorMessage() {
46
44
  var _a;
@@ -363,6 +361,7 @@ const EzComboBox = class {
363
361
  this._visibleOptions = [];
364
362
  this.clearSource();
365
363
  }
364
+ this.setFocus();
366
365
  }
367
366
  loadOptions(mode, argument = "") {
368
367
  this._criteria = argument;
@@ -547,12 +546,6 @@ const EzComboBox = class {
547
546
  handlerIconClick() {
548
547
  this.searchMode ? this.loadOptions(SearchMode.ADVANCED) : this.showOptions();
549
548
  }
550
- buildNumberArgument(argument) {
551
- if (this.isTextSearch) {
552
- return NaN;
553
- }
554
- return Number(argument || undefined);
555
- }
556
549
  onTextInputChangeHandler(event) {
557
550
  var _a;
558
551
  this.clearDeboucingTimeout();
@@ -563,7 +556,7 @@ const EzComboBox = class {
563
556
  return;
564
557
  }
565
558
  const argument = (_a = event.target.value) === null || _a === void 0 ? void 0 : _a.trim();
566
- const argumentNumber = this.buildNumberArgument(argument);
559
+ const argumentNumber = Number(argument || undefined);
567
560
  if (!this._criteria) {
568
561
  this._textInput.value = event.data || argument;
569
562
  }
@@ -650,8 +643,7 @@ const EzComboBox = class {
650
643
  //event.stopPropagation();
651
644
  }
652
645
  onTextInputFocusOutHandler() {
653
- if (this.hideErrorOnFocusOut)
654
- this.cancelPreselection();
646
+ this.cancelPreselection();
655
647
  }
656
648
  canShowListOptions() {
657
649
  return !this._showLoading && this._visibleOptions.length > 0;
@@ -95,49 +95,15 @@ uiBuilders.set(UserInterface.LONGTEXT, buildTextArea);
95
95
  const fieldBuilder = (field) => {
96
96
  const builder = uiBuilders.get(field.userInterface) || buildTextInput;
97
97
  const label = field.required ? `${field.label}${REQUIRED_INFO}` : field.label;
98
- const builtElement = builder(Object.assign(Object.assign({}, field), { label }));
99
- //@ts-ignore
100
- builtElement.$attrs$['data-form-item'] = field.name;
101
- return builtElement;
98
+ return builder(Object.assign(Object.assign({}, field), { label }));
102
99
  };
103
100
 
104
- class FormItem {
105
- constructor(elem) {
106
- this.elem = elem;
107
- }
108
- addRightElement(el) {
109
- el.classList.add('ez-padding-left--small');
110
- this.elem.classList.add('ez-col--nowrap');
111
- this.elem.appendChild(el);
112
- }
113
- get fieldName() {
114
- return this.elem.getAttribute('data-form-item');
115
- }
116
- }
117
- class FormItems {
118
- constructor(items, formId) {
119
- this.items = new Map();
120
- this.formId = formId;
121
- items.forEach(item => {
122
- const formItem = new FormItem(item);
123
- this.items.set(formItem.fieldName, formItem);
124
- });
125
- }
126
- getItem(name) {
127
- return this.items.get(name);
128
- }
129
- get formName() {
130
- return this.formId;
131
- }
132
- }
133
-
134
101
  const ezFormViewCss = ".sc-ez-form-view-h{display:flex;flex-direction:row;flex-wrap:wrap;width:100%}";
135
102
 
136
103
  const EzFormView = class {
137
104
  constructor(hostRef) {
138
105
  registerInstance(this, hostRef);
139
106
  this.ezContentReady = createEvent(this, "ezContentReady", 7);
140
- this.formItemsReady = createEvent(this, "formItemsReady", 7);
141
107
  this.fields = undefined;
142
108
  }
143
109
  async showUp() {
@@ -163,8 +129,6 @@ const EzFormView = class {
163
129
  }
164
130
  componentDidRender() {
165
131
  this.ezContentReady.emit(Array.from(this._element.querySelectorAll("[data-field-name]")));
166
- const formItems = new FormItems(Array.from(this._element.querySelectorAll("[data-form-item]")));
167
- this.formItemsReady.emit(formItems);
168
132
  }
169
133
  render() {
170
134
  ElementIDUtils.addIDInfoIfNotExists(this._element, 'ezFormView');
@@ -342,7 +342,7 @@ class DataBinder {
342
342
  this._dataUnit.addRecord();
343
343
  }
344
344
  this._dataUnit.clearInvalid(this.getCurrentRecordId(), fieldName);
345
- this._dataUnit.setFieldValue(fieldName, newValue);
345
+ this._dataUnit.setFieldValue(fieldName, newValue, [this.getCurrentRecordId()]);
346
346
  if (this._dataUnit.waitingForChange(fieldName)) {
347
347
  const bind = this._fields.get(fieldName);
348
348
  if (bind) {
@@ -831,7 +831,6 @@ const EzForm = class {
831
831
  constructor(hostRef) {
832
832
  registerInstance(this, hostRef);
833
833
  this.ezReady = createEvent(this, "ezReady", 7);
834
- this.formItemsReady = createEvent(this, "formItemsReady", 7);
835
834
  this.onDataUnitAction = (action) => {
836
835
  if (action.type === Action.METADATA_LOADED) {
837
836
  this.processMetadata();