@sankhyalabs/ezui 5.20.0-dev.2 → 5.20.0-dev.21

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 (139) hide show
  1. package/README.md +4 -5
  2. package/dist/cjs/{CSSVarsUtils-b136a156.js → CSSVarsUtils-10c9d5b4.js} +13 -0
  3. package/dist/cjs/ez-actions-button.cjs.entry.js +1 -1
  4. package/dist/cjs/ez-alert-list.cjs.entry.js +33 -28
  5. package/dist/cjs/ez-card-item_3.cjs.entry.js +6 -5
  6. package/dist/cjs/ez-combo-box.cjs.entry.js +8 -7
  7. package/dist/cjs/ez-date-input.cjs.entry.js +4 -1
  8. package/dist/cjs/ez-date-time-input.cjs.entry.js +4 -1
  9. package/dist/cjs/ez-form-view.cjs.entry.js +34 -15
  10. package/dist/cjs/ez-grid.cjs.entry.js +91 -30
  11. package/dist/cjs/ez-icon.cjs.entry.js +1 -1
  12. package/dist/cjs/ez-multi-selection-list.cjs.entry.js +2 -10
  13. package/dist/cjs/ez-number-input.cjs.entry.js +4 -1
  14. package/dist/cjs/ez-popup.cjs.entry.js +1 -1
  15. package/dist/cjs/ez-search.cjs.entry.js +7 -8
  16. package/dist/cjs/ez-split-button.cjs.entry.js +147 -0
  17. package/dist/cjs/ez-split-item.cjs.entry.js +20 -2
  18. package/dist/cjs/ez-split-panel.cjs.entry.js +15 -12
  19. package/dist/cjs/ez-time-input.cjs.entry.js +1 -1
  20. package/dist/cjs/ezui.cjs.js +1 -1
  21. package/dist/cjs/filter-column.cjs.entry.js +16 -5
  22. package/dist/cjs/index-a7b0c73d.js +8 -4
  23. package/dist/cjs/loader.cjs.js +1 -1
  24. package/dist/collection/collection-manifest.json +2 -1
  25. package/dist/collection/components/ez-alert-list/ez-alert-list.js +33 -28
  26. package/dist/collection/components/ez-card-item/ez-card-item.css +39 -6
  27. package/dist/collection/components/ez-card-item/ez-card-item.js +22 -3
  28. package/dist/collection/components/ez-collapsible-box/ez-collapsible-box.css +1 -0
  29. package/dist/collection/components/ez-combo-box/ez-combo-box.js +7 -6
  30. package/dist/collection/components/ez-date-input/ez-date-input.js +3 -0
  31. package/dist/collection/components/ez-date-time-input/ez-date-time-input.js +3 -0
  32. package/dist/collection/components/ez-form-view/ez-form-view.css +17 -1
  33. package/dist/collection/components/ez-form-view/ez-form-view.js +22 -5
  34. package/dist/collection/components/ez-form-view/fieldbuilder/templates/CheckBox.tpl.js +1 -1
  35. package/dist/collection/components/ez-form-view/fieldbuilder/templates/ComboBox.tpl.js +1 -1
  36. package/dist/collection/components/ez-form-view/fieldbuilder/templates/DateInput.tpl.js +3 -3
  37. package/dist/collection/components/ez-form-view/fieldbuilder/templates/FileInput.tpl.js +4 -2
  38. package/dist/collection/components/ez-form-view/fieldbuilder/templates/NumberInput.tpl.js +1 -1
  39. package/dist/collection/components/ez-form-view/fieldbuilder/templates/SearchInput.tpl.js +1 -1
  40. package/dist/collection/components/ez-form-view/fieldbuilder/templates/TextInput.tpl.js +1 -1
  41. package/dist/collection/components/ez-grid/controller/ag-grid/AgGridController.js +12 -11
  42. package/dist/collection/components/ez-grid/controller/ag-grid/DataSource.js +15 -1
  43. package/dist/collection/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.js +1 -3
  44. package/dist/collection/components/ez-grid/ez-grid.css +25 -1
  45. package/dist/collection/components/ez-grid/ez-grid.js +67 -10
  46. package/dist/collection/components/ez-grid/subcomponents/filter-column.js +16 -5
  47. package/dist/collection/components/ez-icon/ez-icon.css +1 -1
  48. package/dist/collection/components/ez-multi-selection-list/ez-multi-selection-list.js +2 -10
  49. package/dist/collection/components/ez-number-input/ez-number-input.js +3 -0
  50. package/dist/collection/components/ez-popup/ez-popup.css +2 -5
  51. package/dist/collection/components/ez-search/ez-search.css +2 -1
  52. package/dist/collection/components/ez-search/ez-search.js +5 -6
  53. package/dist/collection/components/ez-split-button/ez-split-button.css +229 -0
  54. package/dist/collection/components/ez-split-button/ez-split-button.js +436 -0
  55. package/dist/collection/components/ez-split-button/test/dropdownItems.js +42 -0
  56. package/dist/collection/components/ez-split-panel/ez-split-panel.css +6 -7
  57. package/dist/collection/components/ez-split-panel/ez-split-panel.js +35 -14
  58. package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.css +47 -12
  59. package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.js +82 -2
  60. package/dist/collection/utils/CSSVarsUtils.js +13 -0
  61. package/dist/collection/utils/form/test/DataBinder.test.js +9 -0
  62. package/dist/custom-elements/index.d.ts +6 -0
  63. package/dist/custom-elements/index.js +394 -124
  64. package/dist/esm/{CSSVarsUtils-a97cfa29.js → CSSVarsUtils-71ce76be.js} +13 -0
  65. package/dist/esm/ez-actions-button.entry.js +1 -1
  66. package/dist/esm/ez-alert-list.entry.js +33 -28
  67. package/dist/esm/ez-card-item_3.entry.js +6 -5
  68. package/dist/esm/ez-combo-box.entry.js +8 -7
  69. package/dist/esm/ez-date-input.entry.js +4 -1
  70. package/dist/esm/ez-date-time-input.entry.js +4 -1
  71. package/dist/esm/ez-form-view.entry.js +35 -16
  72. package/dist/esm/ez-grid.entry.js +92 -31
  73. package/dist/esm/ez-icon.entry.js +1 -1
  74. package/dist/esm/ez-multi-selection-list.entry.js +2 -10
  75. package/dist/esm/ez-number-input.entry.js +4 -1
  76. package/dist/esm/ez-popup.entry.js +1 -1
  77. package/dist/esm/ez-search.entry.js +7 -8
  78. package/dist/esm/ez-split-button.entry.js +143 -0
  79. package/dist/esm/ez-split-item.entry.js +20 -2
  80. package/dist/esm/ez-split-panel.entry.js +15 -12
  81. package/dist/esm/ez-time-input.entry.js +1 -1
  82. package/dist/esm/ezui.js +1 -1
  83. package/dist/esm/filter-column.entry.js +16 -5
  84. package/dist/esm/index-baa5e267.js +8 -4
  85. package/dist/esm/loader.js +1 -1
  86. package/dist/ezui/ezui.esm.js +1 -1
  87. package/dist/ezui/{p-f56dd1da.entry.js → p-07cbffce.entry.js} +1 -1
  88. package/dist/ezui/p-13dbad96.entry.js +1 -0
  89. package/dist/ezui/p-2eb8f73b.entry.js +1 -0
  90. package/dist/ezui/{p-40f72de4.entry.js → p-784fe207.entry.js} +1 -1
  91. package/dist/ezui/p-7af81663.entry.js +1 -0
  92. package/dist/ezui/p-801fd0f8.entry.js +1 -0
  93. package/dist/ezui/p-807560f0.entry.js +1 -0
  94. package/dist/ezui/p-940ed30b.entry.js +1 -0
  95. package/dist/ezui/{p-eb36f072.entry.js → p-99ead599.entry.js} +1 -1
  96. package/dist/ezui/{p-7eb3e1a5.js → p-9e11fc7b.js} +1 -1
  97. package/dist/ezui/p-9f1e89c9.entry.js +1 -0
  98. package/dist/ezui/{p-6e2f8e6b.entry.js → p-a2704c1a.entry.js} +2 -2
  99. package/dist/ezui/{p-51c5e071.entry.js → p-abc23d6f.entry.js} +1 -1
  100. package/dist/ezui/p-af95cd16.entry.js +1 -0
  101. package/dist/ezui/{p-c0f1715f.entry.js → p-b567fa8c.entry.js} +1 -1
  102. package/dist/ezui/p-b9fbf4e7.entry.js +1 -0
  103. package/dist/ezui/p-baf80b13.entry.js +1 -0
  104. package/dist/ezui/p-db77a984.entry.js +1 -0
  105. package/dist/ezui/{p-9cad9b6e.entry.js → p-e85c48d7.entry.js} +1 -1
  106. package/dist/types/components/ez-alert-list/ez-alert-list.d.ts +1 -1
  107. package/dist/types/components/ez-card-item/ez-card-item.d.ts +4 -0
  108. package/dist/types/components/ez-combo-box/ez-combo-box.d.ts +1 -0
  109. package/dist/types/components/ez-form-view/ez-form-view.d.ts +3 -0
  110. package/dist/types/components/ez-grid/controller/EzGridController.d.ts +1 -0
  111. package/dist/types/components/ez-grid/controller/ag-grid/AgGridController.d.ts +1 -0
  112. package/dist/types/components/ez-grid/controller/ag-grid/DataSource.d.ts +2 -1
  113. package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.d.ts +1 -1
  114. package/dist/types/components/ez-grid/ez-grid.d.ts +15 -2
  115. package/dist/types/components/ez-grid/subcomponents/filter-column.d.ts +4 -1
  116. package/dist/types/components/ez-multi-selection-list/ez-multi-selection-list.d.ts +0 -1
  117. package/dist/types/components/ez-split-button/ez-split-button.d.ts +89 -0
  118. package/dist/types/components/ez-split-button/test/dropdownItems.d.ts +2 -0
  119. package/dist/types/components/ez-split-panel/ez-split-panel.d.ts +23 -0
  120. package/dist/types/components/ez-split-panel/structure/item/ez-split-item.d.ts +27 -0
  121. package/dist/types/components.d.ts +155 -0
  122. package/dist/types/utils/CSSVarsUtils.d.ts +1 -0
  123. package/dist/types/utils/form/test/DataBinder.test.d.ts +1 -0
  124. package/package.json +13 -5
  125. package/react/components.d.ts +1 -0
  126. package/react/components.js +1 -0
  127. package/react/components.js.map +1 -1
  128. package/dist/collection/components/ez-grid/controller/ag-grid/AgGridUtils.js +0 -8
  129. package/dist/ezui/p-133fae4a.entry.js +0 -1
  130. package/dist/ezui/p-24d3fede.entry.js +0 -1
  131. package/dist/ezui/p-43b03119.entry.js +0 -1
  132. package/dist/ezui/p-4a7f113d.entry.js +0 -1
  133. package/dist/ezui/p-596634e9.entry.js +0 -1
  134. package/dist/ezui/p-76ba9d67.entry.js +0 -1
  135. package/dist/ezui/p-796c1a88.entry.js +0 -1
  136. package/dist/ezui/p-af15c277.entry.js +0 -1
  137. package/dist/ezui/p-ba875f37.entry.js +0 -1
  138. package/dist/ezui/p-d6ffe679.entry.js +0 -1
  139. package/dist/types/components/ez-grid/controller/ag-grid/AgGridUtils.d.ts +0 -1
@@ -1,11 +1,11 @@
1
1
  import { h, r as registerInstance, c as createEvent, H as Host, g as getElement } from './index-baa5e267.js';
2
- import { Action, ObjectUtils as ObjectUtils$1, HTMLBuilder, ApplicationContext, UserInterface, StringUtils as StringUtils$1, NumberUtils as NumberUtils$1, MaskFormatter, DataType, SortMode, ElementIDUtils, FieldComparator, DateUtils as DateUtils$1, ArrayUtils as ArrayUtils$1, JSUtils } from '@sankhyalabs/core';
2
+ import { Action, ObjectUtils as ObjectUtils$1, HTMLBuilder, ApplicationContext, UserInterface, StringUtils as StringUtils$1, NumberUtils as NumberUtils$1, MaskFormatter, DataType, SortMode, ElementIDUtils, FieldComparator, DateUtils as DateUtils$1, ArrayUtils as ArrayUtils$1, JSUtils, OverflowWatcher, OVERFLOWED_CLASS_NAME } from '@sankhyalabs/core';
3
3
  import { SelectionMode } from '@sankhyalabs/core/dist/dataunit/DataUnit';
4
- import { E as EZ_GRID_LOADING_SOURCE, D as DISTINCT_FILTER_NAME_PREFIX } from './constants-4e0d35b7.js';
5
- import { b as buildFieldMetadata, R as RecordValidationProcessor } from './RecordValidationProcessor-b00b8b77.js';
6
4
  import { A as ApplicationUtils } from './ApplicationUtils-eaf91331.js';
7
5
  import './DialogType-54a62731.js';
8
6
  import './CheckMode-bdb2ec19.js';
7
+ import { E as EZ_GRID_LOADING_SOURCE, D as DISTINCT_FILTER_NAME_PREFIX } from './constants-4e0d35b7.js';
8
+ import { b as buildFieldMetadata, R as RecordValidationProcessor } from './RecordValidationProcessor-b00b8b77.js';
9
9
 
10
10
  /**
11
11
  * @ag-grid-community/all-modules - Advanced Data Grid / Data Table supporting Javascript / Typescript / React / Angular / Vue * @version v28.2.1
@@ -118828,6 +118828,14 @@ var AllEnterpriseModules = [
118828
118828
  ModuleRegistry.registerModules(AllEnterpriseModules);
118829
118829
 
118830
118830
  class DataSource {
118831
+ updateLoadedRecords(action) {
118832
+ const records = action.payload;
118833
+ if ((records === null || records === void 0 ? void 0 : records.length) > 0) {
118834
+ records.forEach(record => {
118835
+ this._controller.changeValues(record, [record.__record__id__]);
118836
+ });
118837
+ }
118838
+ }
118831
118839
  isSilentChange(action) {
118832
118840
  //TODO: Provisorio p/ não atualizar a grade quando a alteração for apenas de campos transisntes
118833
118841
  var _a, _b;
@@ -118850,6 +118858,9 @@ class DataSource {
118850
118858
  break;
118851
118859
  case Action.LOADING_DATA:
118852
118860
  this._waitingForLoad = true;
118861
+ if (EZ_GRID_LOADING_SOURCE !== action.payload.source) {
118862
+ this._controller.clearFilter();
118863
+ }
118853
118864
  this._controller.refresh();
118854
118865
  break;
118855
118866
  case Action.DATA_LOADED:
@@ -118880,6 +118891,9 @@ class DataSource {
118880
118891
  case Action.PREVIOUS_SELECTED:
118881
118892
  this.updateSelection();
118882
118893
  break;
118894
+ case Action.RECORD_LOADED:
118895
+ this.updateLoadedRecords(action);
118896
+ break;
118883
118897
  }
118884
118898
  };
118885
118899
  this._dataUnit = dataUnit;
@@ -118949,15 +118963,6 @@ class DataSource {
118949
118963
  }
118950
118964
  }
118951
118965
 
118952
- function calcFilterColumnLeftPosition(leftReference) {
118953
- const FIX_MARGIN = 60;
118954
- const FILTER_COLUMN_WIDTH = 330;
118955
- const screenWidth = window.innerWidth;
118956
- const maxLeft = screenWidth - (FILTER_COLUMN_WIDTH + FIX_MARGIN);
118957
- const leftInt = leftReference - FIX_MARGIN;
118958
- return leftInt > maxLeft ? maxLeft : leftInt;
118959
- }
118960
-
118961
118966
  class EzGridCustomHeader {
118962
118967
  init(agParams) {
118963
118968
  var _a;
@@ -118994,8 +118999,7 @@ class EzGridCustomHeader {
118994
118999
  }
118995
119000
  onClickFilter() {
118996
119001
  var _a;
118997
- const iconLeft = (_a = this.filterButton) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect().left;
118998
- this.params.showColumnFilter(`${calcFilterColumnLeftPosition(iconLeft)}px`, true);
119002
+ this.params.showColumnFilter((_a = this.filterButton) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect().left);
118999
119003
  }
119000
119004
  configSortIcon() {
119001
119005
  this.sortDownIcon.style.display = this.params.column.isSortDescending() ? 'flex' : 'none';
@@ -119654,6 +119658,10 @@ class AgGridController {
119654
119658
  this._gridOptions.api.refreshHeader();
119655
119659
  this._dataUnit.loadData(undefined, undefined, undefined, EZ_GRID_LOADING_SOURCE);
119656
119660
  }
119661
+ clearFilter() {
119662
+ this._filteredColumns.clear();
119663
+ this._gridOptions.api.refreshHeader();
119664
+ }
119657
119665
  showFilterColumn(configs) {
119658
119666
  var _a;
119659
119667
  (_a = this._filterColumn) === null || _a === void 0 ? void 0 : _a.show(configs);
@@ -119672,7 +119680,7 @@ class AgGridController {
119672
119680
  this._idAttribName = '__record__id__';
119673
119681
  this._gridConfig = [];
119674
119682
  this._filteredColumns = new Map();
119675
- this._filterColumnleftPosition = '0px';
119683
+ this._filterColumnleftPosition = 0;
119676
119684
  this._enterprise = enterprise;
119677
119685
  }
119678
119686
  getGridConfig() {
@@ -119798,11 +119806,9 @@ class AgGridController {
119798
119806
  this._gridOptions.api.setHeaderHeight(this.getHeaderRowHeight());
119799
119807
  }
119800
119808
  }
119801
- setFilterColumnLeftPosition(params) {
119802
- if (params.type === 'columnMenu') {
119803
- const ePopup = params.ePopup;
119804
- const leftString = ePopup.style.left.replace('px', '');
119805
- this._filterColumnleftPosition = `${calcFilterColumnLeftPosition(parseInt(leftString))}px`;
119809
+ setFilterColumnLeftPosition({ type, ePopup }) {
119810
+ if (type === 'columnMenu') {
119811
+ this._filterColumnleftPosition = ePopup.getBoundingClientRect().left;
119806
119812
  return;
119807
119813
  }
119808
119814
  }
@@ -120242,10 +120248,10 @@ class AgGridController {
120242
120248
  tooltip: tooltip,
120243
120249
  isSortable: propSortable,
120244
120250
  hasFilter: () => this.hasFilterColumn(source.name),
120245
- showColumnFilter: (leftPosition, fromIcon) => this.showFilterColumn({ columnName: source.name, columnLabel: source.label, leftPosition, filteredOptions: this._filteredColumns.get(source.name), fromIcon }),
120251
+ showColumnFilter: (leftPosition) => this.showFilterColumn({ columnName: source.name, columnLabel: source.label, leftPosition, filteredOptions: this._filteredColumns.get(source.name), fromIcon: true }),
120246
120252
  },
120247
120253
  valueFormatter: params => {
120248
- if (params.value == undefined) {
120254
+ if (params.value === undefined) {
120249
120255
  return "";
120250
120256
  }
120251
120257
  if (params.value instanceof Promise) {
@@ -120627,13 +120633,13 @@ class InMemoryFilterColumnDataSource {
120627
120633
  }
120628
120634
  }
120629
120635
 
120630
- 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-row-start:1;grid-template-columns:1fr;background-color:var(--ez-grid__header--background-color, #FFF)}.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}.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}";
120636
+ 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%);--ez-grid--min-height:300px;min-height:var(--ez-grid--min-height)}.grid-header.sc-ez-grid{display:grid;justify-content:space-between;align-items:center;grid-row-start:1;grid-template-columns:1fr;background-color:var(--ez-grid__header--background-color, #FFF)}.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}.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}.grid-header__pagination.sc-ez-grid{width:30%;min-width:100px;justify-content:end;flex-wrap:wrap}.grid-header__left-container.sc-ez-grid{width:70%}.grid-header__pagination-label.sc-ez-grid{width:100%;white-space:nowrap}.overflowed.sc-ez-grid{display:none}";
120631
120637
 
120632
120638
  const windowInstace = window;
120633
120639
  const matches = (text, filter) => {
120634
- const normalizedText = StringUtils$1.replaceAccentuatedCharsLower(text.toLocaleLowerCase());
120640
+ const normalizedText = StringUtils$1.replaceAccentuatedCharsLower(text === null || text === void 0 ? void 0 : text.toLocaleLowerCase());
120635
120641
  const normalizedFilter = StringUtils$1.replaceAccentuatedCharsLower(filter.toLocaleLowerCase());
120636
- return normalizedText.includes(normalizedFilter);
120642
+ return normalizedText === null || normalizedText === void 0 ? void 0 : normalizedText.includes(normalizedFilter);
120637
120643
  };
120638
120644
  const EzGrid = class {
120639
120645
  constructor(hostRef) {
@@ -120726,6 +120732,14 @@ const EzGrid = class {
120726
120732
  observeConfig(config) {
120727
120733
  this._gridController.setColumnsState(config.columns);
120728
120734
  }
120735
+ updatePaginationTooltip() {
120736
+ if (this._refPaginationLabelTooltip) {
120737
+ const tooltip = this._getPaginationTooltip();
120738
+ if (tooltip) {
120739
+ this._refPaginationLabelTooltip.setAttribute('data-tooltip', tooltip);
120740
+ }
120741
+ }
120742
+ }
120729
120743
  onSelectionChange(evt) {
120730
120744
  this._currentPageSelected = evt.detail.selectionHeaderStatus === true;
120731
120745
  if (this.dataUnit) {
@@ -120881,11 +120895,10 @@ const EzGrid = class {
120881
120895
  }
120882
120896
  getPaginationControl() {
120883
120897
  if (this._paginationInfo) {
120884
- const { firstRecord, lastRecord, total, count, currentPage, hasMore } = this._paginationInfo;
120898
+ const { currentPage, hasMore } = this._paginationInfo;
120885
120899
  return [
120886
- h("div", { class: "ez-text ez-text--primary ez-text--medium ez-margin-right--medium" }, h("strong", { class: "ez-text ez-text--primary ez-text--medium" }, `${firstRecord}-${lastRecord}`), total == undefined ? ` de ${count + 1} ou mais` : ` de ${total}`),
120887
- h("ez-button", { size: "small", iconName: "chevron-left", class: "ez-margin-right--medium", mode: "icon", enabled: currentPage > 0, onClick: () => this.previousPage(), label: "P\u00E1gina anterior" }),
120888
- h("ez-button", { size: "small", iconName: "chevron-right", class: "ez-margin-right--medium", mode: "icon", enabled: hasMore, onClick: () => this.nextPage(), label: "Pr\u00F3xima P\u00E1gina" }),
120900
+ h("div", { class: "ez-text ez-text--primary ez-text--medium ez-margin-right--medium", ref: (element) => (this._refPaginationLabel = element) }, h("span", { class: "grid-header__pagination-label" }, h("strong", { class: "ez-text ez-text--primary ez-text--medium" }, this._getActualPageLabel()), this._getRemainingPageLabel())),
120901
+ h("div", { id: "grid-pagination-tooltip", ref: (element) => (this._refPaginationLabelTooltip = element), class: "ez-flex ez-margin-right--medium" }, h("ez-button", { size: "small", class: "ez-margin-right--medium", iconName: "chevron-left", mode: "icon", enabled: currentPage > 0, onClick: () => this.previousPage(), label: "P\u00E1gina anterior" }), h("ez-button", { size: "small", iconName: "chevron-right", mode: "icon", enabled: hasMore, onClick: () => this.nextPage(), label: "Pr\u00F3xima P\u00E1gina" })),
120889
120902
  ];
120890
120903
  }
120891
120904
  return null;
@@ -120929,6 +120942,53 @@ const EzGrid = class {
120929
120942
  this.setEvents();
120930
120943
  this.componentReady.emit();
120931
120944
  this._gridController.configFilterColumn(this._filterColumn);
120945
+ this._initHeaderOverflowWatcher();
120946
+ }
120947
+ _getActualPageLabel() {
120948
+ const { firstRecord, lastRecord } = this._paginationInfo;
120949
+ return `${firstRecord}-${lastRecord}`;
120950
+ }
120951
+ _getRemainingPageLabel() {
120952
+ const { total, count } = this._paginationInfo;
120953
+ return `${total == undefined ? ` de ${count + 1} ou mais` : ` de ${total}`}`;
120954
+ }
120955
+ _getPaginationTooltip() {
120956
+ return this._getActualPageLabel() + this._getRemainingPageLabel();
120957
+ }
120958
+ _initHeaderOverflowWatcher() {
120959
+ this._headerOverflowWatcher = new OverflowWatcher(this.buildOverFlowWatcherParams());
120960
+ }
120961
+ buildOverFlowWatcherParams() {
120962
+ return {
120963
+ element: this._refPaginationControl,
120964
+ callback: this.handleOverFlow.bind(this),
120965
+ notOverFlow: ["grid-pagination-tooltip"]
120966
+ };
120967
+ }
120968
+ handleOverFlow(elementsOverflow) {
120969
+ if (!this._refPaginationLabel)
120970
+ return;
120971
+ if (elementsOverflow.length > 0) {
120972
+ this._hidePaginationDescription();
120973
+ }
120974
+ else {
120975
+ this._showPaginationDescription();
120976
+ }
120977
+ }
120978
+ _hidePaginationDescription() {
120979
+ this._refPaginationLabel.classList.add(OVERFLOWED_CLASS_NAME);
120980
+ this._refPaginationLabelTooltip.setAttribute('data-flow', 'bottom');
120981
+ this._refPaginationLabelTooltip.setAttribute('data-tooltip', this._getPaginationTooltip());
120982
+ }
120983
+ ;
120984
+ _showPaginationDescription() {
120985
+ this._refPaginationLabel.classList.remove(OVERFLOWED_CLASS_NAME);
120986
+ this._refPaginationLabelTooltip.removeAttribute('data-flow');
120987
+ this._refPaginationLabelTooltip.removeAttribute('data-tooltip');
120988
+ }
120989
+ disconnectedCallback() {
120990
+ var _a;
120991
+ (_a = this._headerOverflowWatcher) === null || _a === void 0 ? void 0 : _a.destroy();
120932
120992
  }
120933
120993
  componentWillRender() {
120934
120994
  this.configSelectionCounter();
@@ -120952,14 +121012,15 @@ const EzGrid = class {
120952
121012
  }
120953
121013
  render() {
120954
121014
  var _a;
120955
- return (h(Host, { "no-header": this.hideHeader() }, h("div", { class: "grid__container ez-grid", ref: elem => (this._container = elem) }), 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 ez-elevation--4
121015
+ return (h(Host, { "no-header": this.hideHeader() }, h("div", { class: "grid__container ez-grid", ref: elem => (this._container = elem) }), 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 grid-header__left-container" }, h("slot", { name: "leftButtons" })), h("div", { class: "grid-header__container grid-header__pagination", ref: ref => (this._refPaginationControl = ref) }, this.getPaginationControl()))), h("div", { ref: (ref) => (this._gridSelectionCounter = ref), class: `grid__selection-counter ez-elevation--4
120956
121016
  ${this._showSelectionCounter ? 'grid__selection-counter--opened' : ''}
120957
121017
  ` }, 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__footer" }, h("slot", { name: "footer" }))));
120958
121018
  }
120959
121019
  static get assetsDirs() { return ["../assets"]; }
120960
121020
  get _element() { return getElement(this); }
120961
121021
  static get watchers() { return {
120962
- "config": ["observeConfig"]
121022
+ "config": ["observeConfig"],
121023
+ "_paginationInfo": ["updatePaginationTooltip"]
120963
121024
  }; }
120964
121025
  };
120965
121026
  EzGrid.style = ezGridCss;
@@ -1,7 +1,7 @@
1
1
  import { r as registerInstance, h, H as Host, g as getElement } from './index-baa5e267.js';
2
2
  import { StringUtils, ElementIDUtils } from '@sankhyalabs/core';
3
3
 
4
- const ezIconCss = ":host{display:flex;overflow:hidden;position:relative;--ez-icon--color:var(--icon--color, #ffffff)}svg{display:flex;justify-content:center;align-items:center;fill:var(--ez-icon--color)}.x-small{width:12px;height:12px}.small{width:16px;height:16px}.medium{width:20px;height:20px}.large{width:24px;height:24px}.x-large{width:30px;height:30px}[class^=\"ez-icon-\"],[class*=\" ez-icon-\"]{color:var(--ez-icon--color)}[class^=\"ez-icon-\"],[class*=\" ez-icon-\"]{font-family:'ez-icons' !important;font-size:16px;font-style:normal;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.ez-icon-2chevron-down:before{content:\"\\ea01\"}.ez-icon-2chevron-up:before{content:\"\\ea02\"}.ez-icon-acao:before{content:\"\\ea03\"}.ez-icon-account-outline:before{content:\"\\ea04\"}.ez-icon-account:before{content:\"\\ea05\"}.ez-icon-alert-circle-inverted:before{content:\"\\ea06\"}.ez-icon-alert-circle:before{content:\"\\ea07\"}.ez-icon-alert-mail:before{content:\"\\ea08\"}.ez-icon-alert-popup:before{content:\"\\ea09\"}.ez-icon-anexo:before{content:\"\\ea0a\"}.ez-icon-antecipação:before{content:\"\\ea0b\"}.ez-icon-apps:before{content:\"\\ea0c\"}.ez-icon-arrow-forward:before{content:\"\\ea0d\"}.ez-icon-arrow-upward:before{content:\"\\ea0e\"}.ez-icon-arrow_back:before{content:\"\\ea0f\"}.ez-icon-arrow_downward:before{content:\"\\ea10\"}.ez-icon-baixa:before{content:\"\\ea11\"}.ez-icon-balance:before{content:\"\\ea12\"}.ez-icon-bell-inverted:before{content:\"\\ea13\"}.ez-icon-bell:before{content:\"\\ea14\"}.ez-icon-boleto:before{content:\"\\ea15\"}.ez-icon-boolean:before{content:\"\\ea16\"}.ez-icon-business-center:before{content:\"\\ea17\"}.ez-icon-calendar-clock:before{content:\"\\ea18\"}.ez-icon-calendar:before{content:\"\\ea19\"}.ez-icon-cash-remove:before{content:\"\\ea1a\"}.ez-icon-check-circle-inverted:before{content:\"\\ea1b\"}.ez-icon-check-circle:before{content:\"\\ea1c\"}.ez-icon-check:before{content:\"\\ea1d\"}.ez-icon-chevron-down:before{content:\"\\ea1e\"}.ez-icon-chevron-left:before{content:\"\\ea1f\"}.ez-icon-chevron-right:before{content:\"\\ea20\"}.ez-icon-chevron-up:before{content:\"\\ea21\"}.ez-icon-circle--medium:before{content:\"\\ea22\"}.ez-icon-circle:before{content:\"\\ea23\"}.ez-icon-cleaning:before{content:\"\\ea24\"}.ez-icon-clipboard:before{content:\"\\ea25\"}.ez-icon-close:before{content:\"\\ea26\"}.ez-icon-cobrar:before{content:\"\\ea27\"}.ez-icon-code:before{content:\"\\ea28\"}.ez-icon-configuration:before{content:\"\\ea29\"}.ez-icon-content-cut:before{content:\"\\ea2a\"}.ez-icon-copy:before{content:\"\\ea2b\"}.ez-icon-credit_card:before{content:\"\\ea2c\"}.ez-icon-crop:before{content:\"\\ea2d\"}.ez-icon-custom:before{content:\"\\ea2e\"}.ez-icon-delete-file:before{content:\"\\ea2f\"}.ez-icon-delete:before{content:\"\\ea30\"}.ez-icon-description:before{content:\"\\ea31\"}.ez-icon-dividir:before{content:\"\\ea32\"}.ez-icon-docx:before{content:\"\\ea33\"}.ez-icon-dot-notification:before{content:\"\\ea34\"}.ez-icon-dots-horizontal:before{content:\"\\ea35\"}.ez-icon-dots-vertical:before{content:\"\\ea36\"}.ez-icon-drag-indicator:before{content:\"\\ea37\"}.ez-icon-dual-chevron-down:before{content:\"\\ea38\"}.ez-icon-dual-chevron-left:before{content:\"\\ea39\"}.ez-icon-dual-chevron-right:before{content:\"\\ea3a\"}.ez-icon-dual-chevron-up:before{content:\"\\ea3b\"}.ez-icon-edit-file:before{content:\"\\ea3c\"}.ez-icon-edit-table:before{content:\"\\ea3d\"}.ez-icon-edit-time:before{content:\"\\ea3e\"}.ez-icon-edit-value:before{content:\"\\ea3f\"}.ez-icon-edit:before{content:\"\\ea40\"}.ez-icon-email:before{content:\"\\ea41\"}.ez-icon-estorno:before{content:\"\\ea42\"}.ez-icon-exe:before{content:\"\\ea43\"}.ez-icon-expand:before{content:\"\\ea44\"}.ez-icon-expandir_card:before{content:\"\\ea45\"}.ez-icon-extrato:before{content:\"\\ea46\"}.ez-icon-eye-off:before{content:\"\\ea47\"}.ez-icon-eye:before{content:\"\\ea48\"}.ez-icon-favorite:before{content:\"\\ea49\"}.ez-icon-figma:before{content:\"\\ea4a\"}.ez-icon-file-download:before{content:\"\\ea4b\"}.ez-icon-file-upload:before{content:\"\\ea4c\"}.ez-icon-filter:before{content:\"\\ea4d\"}.ez-icon-find-file:before{content:\"\\ea4e\"}.ez-icon-find-page:before{content:\"\\ea4f\"}.ez-icon-format-color-fill:before{content:\"\\ea50\"}.ez-icon-generic:before{content:\"\\ea51\"}.ez-icon-gif:before{content:\"\\ea52\"}.ez-icon-graph_bar:before{content:\"\\ea53\"}.ez-icon-handshake:before{content:\"\\ea54\"}.ez-icon-help-inverted:before{content:\"\\ea55\"}.ez-icon-help:before{content:\"\\ea56\"}.ez-icon-hide_menu:before{content:\"\\ea57\"}.ez-icon-home:before{content:\"\\ea58\"}.ez-icon-icons104:before{content:\"\\ea59\"}.ez-icon-language:before{content:\"\\ea5a\"}.ez-icon-launch:before{content:\"\\ea5b\"}.ez-icon-lightbulb:before{content:\"\\ea5c\"}.ez-icon-list:before{content:\"\\ea5d\"}.ez-icon-location:before{content:\"\\ea5e\"}.ez-icon-lock-outline:before{content:\"\\ea5f\"}.ez-icon-lock:before{content:\"\\ea60\"}.ez-icon-menu:before{content:\"\\ea61\"}.ez-icon-mid:before{content:\"\\ea62\"}.ez-icon-minus:before{content:\"\\ea63\"}.ez-icon-money-off:before{content:\"\\ea64\"}.ez-icon-money:before{content:\"\\ea65\"}.ez-icon-more:before{content:\"\\ea66\"}.ez-icon-mp3:before{content:\"\\ea67\"}.ez-icon-mp4:before{content:\"\\ea68\"}.ez-icon-multiple-files:before{content:\"\\ea69\"}.ez-icon-north-west:before{content:\"\\ea6a\"}.ez-icon-number:before{content:\"\\ea6b\"}.ez-icon-ordem-ascendente:before{content:\"\\ea6c\"}.ez-icon-ordem-descendente:before{content:\"\\ea6d\"}.ez-icon-parcelar:before{content:\"\\ea6e\"}.ez-icon-pause:before{content:\"\\ea6f\"}.ez-icon-payments:before{content:\"\\ea70\"}.ez-icon-pdf:before{content:\"\\ea71\"}.ez-icon-play:before{content:\"\\ea72\"}.ez-icon-plus:before{content:\"\\ea73\"}.ez-icon-png:before{content:\"\\ea74\"}.ez-icon-power:before{content:\"\\ea75\"}.ez-icon-pptx:before{content:\"\\ea76\"}.ez-icon-preview:before{content:\"\\ea77\"}.ez-icon-print:before{content:\"\\ea78\"}.ez-icon-push-pin:before{content:\"\\ea79\"}.ez-icon-rateio:before{content:\"\\ea7a\"}.ez-icon-receipt:before{content:\"\\ea7b\"}.ez-icon-recolher_card:before{content:\"\\ea7c\"}.ez-icon-restore:before{content:\"\\ea7d\"}.ez-icon-return:before{content:\"\\ea7e\"}.ez-icon-sankhya-place:before{content:\"\\ea7f\"}.ez-icon-save:before{content:\"\\ea80\"}.ez-icon-search:before{content:\"\\ea81\"}.ez-icon-settings-inverted:before{content:\"\\ea82\"}.ez-icon-settings:before{content:\"\\ea83\"}.ez-icon-share:before{content:\"\\ea84\"}.ez-icon-shield:before{content:\"\\ea85\"}.ez-icon-show_menu:before{content:\"\\ea86\"}.ez-icon-south-east:before{content:\"\\ea87\"}.ez-icon-sync:before{content:\"\\ea88\"}.ez-icon-table:before{content:\"\\ea89\"}.ez-icon-tag_code:before{content:\"\\ea8a\"}.ez-icon-text:before{content:\"\\ea8b\"}.ez-icon-timeline:before{content:\"\\ea8c\"}.ez-icon-timer-outline:before{content:\"\\ea8d\"}.ez-icon-trending-up:before{content:\"\\ea8e\"}.ez-icon-tune:before{content:\"\\ea8f\"}.ez-icon-txt:before{content:\"\\ea90\"}.ez-icon-un-pin:before{content:\"\\ea91\"}.ez-icon-unfold_less:before{content:\"\\ea92\"}.ez-icon-unfold_more:before{content:\"\\ea93\"}.ez-icon-user-circle:before{content:\"\\ea94\"}.ez-icon-warning-outline:before{content:\"\\ea95\"}.ez-icon-warning_triangle:before{content:\"\\ea96\"}.ez-icon-whatshot:before{content:\"\\ea97\"}.ez-icon-xlsx:before{content:\"\\ea98\"}.ez-icon-zip:before{content:\"\\ea99\"}.x-small--font{font-size:12px}.small--font{font-size:16px}.medium--font{font-size:20px}.large--font{font-size:24px}.x-large--font{font-size:30px}";
4
+ const ezIconCss = ":host{display:flex;overflow:hidden;position:relative;--ez-icon--color:var(--icon--color, #ffffff)}svg{display:flex;justify-content:center;align-items:center;fill:var(--ez-icon--color)}.x-small{width:12px;height:12px}.small{width:16px;height:16px}.medium{width:20px;height:20px}.large{width:24px;height:24px}.x-large{width:30px;height:30px}[class^=\"ez-icon-\"],[class*=\" ez-icon-\"]{color:var(--ez-icon--color)}[class^=\"ez-icon-\"],[class*=\" ez-icon-\"]{font-family:'ez-icons' !important;font-size:16px;font-style:normal;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.ez-icon-2chevron-down:before{content:\"\\ea01\"}.ez-icon-2chevron-up:before{content:\"\\ea02\"}.ez-icon-acao:before{content:\"\\ea03\"}.ez-icon-account-outline:before{content:\"\\ea04\"}.ez-icon-account:before{content:\"\\ea05\"}.ez-icon-alert-circle-inverted:before{content:\"\\ea06\"}.ez-icon-alert-circle:before{content:\"\\ea07\"}.ez-icon-alert-mail:before{content:\"\\ea08\"}.ez-icon-alert-popup:before{content:\"\\ea09\"}.ez-icon-anexo:before{content:\"\\ea0a\"}.ez-icon-antecipacao:before{content:\"\\ea0b\"}.ez-icon-apps:before{content:\"\\ea0c\"}.ez-icon-arrow-forward:before{content:\"\\ea0d\"}.ez-icon-arrow-upward:before{content:\"\\ea0e\"}.ez-icon-arrow_back:before{content:\"\\ea0f\"}.ez-icon-arrow_downward:before{content:\"\\ea10\"}.ez-icon-baixa:before{content:\"\\ea11\"}.ez-icon-balance:before{content:\"\\ea12\"}.ez-icon-bell-inverted:before{content:\"\\ea13\"}.ez-icon-bell:before{content:\"\\ea14\"}.ez-icon-boleto:before{content:\"\\ea15\"}.ez-icon-boolean:before{content:\"\\ea16\"}.ez-icon-business-center:before{content:\"\\ea17\"}.ez-icon-calendar-clock:before{content:\"\\ea18\"}.ez-icon-calendar:before{content:\"\\ea19\"}.ez-icon-cash-remove:before{content:\"\\ea1a\"}.ez-icon-check-circle-inverted:before{content:\"\\ea1b\"}.ez-icon-check-circle:before{content:\"\\ea1c\"}.ez-icon-check:before{content:\"\\ea1d\"}.ez-icon-chevron-down:before{content:\"\\ea1e\"}.ez-icon-chevron-left:before{content:\"\\ea1f\"}.ez-icon-chevron-right:before{content:\"\\ea20\"}.ez-icon-chevron-up:before{content:\"\\ea21\"}.ez-icon-circle--medium:before{content:\"\\ea22\"}.ez-icon-circle:before{content:\"\\ea23\"}.ez-icon-cleaning:before{content:\"\\ea24\"}.ez-icon-clipboard:before{content:\"\\ea25\"}.ez-icon-close:before{content:\"\\ea26\"}.ez-icon-cobrar:before{content:\"\\ea27\"}.ez-icon-code:before{content:\"\\ea28\"}.ez-icon-configuration:before{content:\"\\ea29\"}.ez-icon-content-cut:before{content:\"\\ea2a\"}.ez-icon-copy:before{content:\"\\ea2b\"}.ez-icon-credit_card:before{content:\"\\ea2c\"}.ez-icon-crop:before{content:\"\\ea2d\"}.ez-icon-custom:before{content:\"\\ea2e\"}.ez-icon-delete-file:before{content:\"\\ea2f\"}.ez-icon-delete:before{content:\"\\ea30\"}.ez-icon-description:before{content:\"\\ea31\"}.ez-icon-dividir:before{content:\"\\ea32\"}.ez-icon-docx:before{content:\"\\ea33\"}.ez-icon-dot-notification:before{content:\"\\ea34\"}.ez-icon-dots-horizontal:before{content:\"\\ea35\"}.ez-icon-dots-vertical:before{content:\"\\ea36\"}.ez-icon-drag-indicator:before{content:\"\\ea37\"}.ez-icon-dual-chevron-down:before{content:\"\\ea38\"}.ez-icon-dual-chevron-left:before{content:\"\\ea39\"}.ez-icon-dual-chevron-right:before{content:\"\\ea3a\"}.ez-icon-dual-chevron-up:before{content:\"\\ea3b\"}.ez-icon-edit-file:before{content:\"\\ea3c\"}.ez-icon-edit-table:before{content:\"\\ea3d\"}.ez-icon-edit-time:before{content:\"\\ea3e\"}.ez-icon-edit-value:before{content:\"\\ea3f\"}.ez-icon-edit:before{content:\"\\ea40\"}.ez-icon-email:before{content:\"\\ea41\"}.ez-icon-estorno:before{content:\"\\ea42\"}.ez-icon-exe:before{content:\"\\ea43\"}.ez-icon-expand:before{content:\"\\ea44\"}.ez-icon-expandir_card:before{content:\"\\ea45\"}.ez-icon-extrato:before{content:\"\\ea46\"}.ez-icon-eye-off:before{content:\"\\ea47\"}.ez-icon-eye:before{content:\"\\ea48\"}.ez-icon-favorite:before{content:\"\\ea49\"}.ez-icon-figma:before{content:\"\\ea4a\"}.ez-icon-file-download:before{content:\"\\ea4b\"}.ez-icon-file-upload:before{content:\"\\ea4c\"}.ez-icon-filter:before{content:\"\\ea4d\"}.ez-icon-find-file:before{content:\"\\ea4e\"}.ez-icon-find-page:before{content:\"\\ea4f\"}.ez-icon-format-color-fill:before{content:\"\\ea50\"}.ez-icon-generic:before{content:\"\\ea51\"}.ez-icon-gif:before{content:\"\\ea52\"}.ez-icon-graph_bar:before{content:\"\\ea53\"}.ez-icon-handshake:before{content:\"\\ea54\"}.ez-icon-help-inverted:before{content:\"\\ea55\"}.ez-icon-help:before{content:\"\\ea56\"}.ez-icon-hide_menu:before{content:\"\\ea57\"}.ez-icon-home:before{content:\"\\ea58\"}.ez-icon-icons104:before{content:\"\\ea59\"}.ez-icon-language:before{content:\"\\ea5a\"}.ez-icon-launch:before{content:\"\\ea5b\"}.ez-icon-lightbulb:before{content:\"\\ea5c\"}.ez-icon-list:before{content:\"\\ea5d\"}.ez-icon-location:before{content:\"\\ea5e\"}.ez-icon-lock-outline:before{content:\"\\ea5f\"}.ez-icon-lock:before{content:\"\\ea60\"}.ez-icon-menu:before{content:\"\\ea61\"}.ez-icon-mid:before{content:\"\\ea62\"}.ez-icon-minus:before{content:\"\\ea63\"}.ez-icon-money-off:before{content:\"\\ea64\"}.ez-icon-money:before{content:\"\\ea65\"}.ez-icon-more:before{content:\"\\ea66\"}.ez-icon-mp3:before{content:\"\\ea67\"}.ez-icon-mp4:before{content:\"\\ea68\"}.ez-icon-multiple-files:before{content:\"\\ea69\"}.ez-icon-north-west:before{content:\"\\ea6a\"}.ez-icon-number:before{content:\"\\ea6b\"}.ez-icon-ordem-ascendente:before{content:\"\\ea6c\"}.ez-icon-ordem-descendente:before{content:\"\\ea6d\"}.ez-icon-parcelar:before{content:\"\\ea6e\"}.ez-icon-pause:before{content:\"\\ea6f\"}.ez-icon-payments:before{content:\"\\ea70\"}.ez-icon-pdf:before{content:\"\\ea71\"}.ez-icon-play:before{content:\"\\ea72\"}.ez-icon-plus:before{content:\"\\ea73\"}.ez-icon-png:before{content:\"\\ea74\"}.ez-icon-power:before{content:\"\\ea75\"}.ez-icon-pptx:before{content:\"\\ea76\"}.ez-icon-preview:before{content:\"\\ea77\"}.ez-icon-print:before{content:\"\\ea78\"}.ez-icon-push-pin:before{content:\"\\ea79\"}.ez-icon-rateio:before{content:\"\\ea7a\"}.ez-icon-receipt:before{content:\"\\ea7b\"}.ez-icon-recolher_card:before{content:\"\\ea7c\"}.ez-icon-restore:before{content:\"\\ea7d\"}.ez-icon-return:before{content:\"\\ea7e\"}.ez-icon-sankhya-place:before{content:\"\\ea7f\"}.ez-icon-save:before{content:\"\\ea80\"}.ez-icon-search:before{content:\"\\ea81\"}.ez-icon-settings-inverted:before{content:\"\\ea82\"}.ez-icon-settings:before{content:\"\\ea83\"}.ez-icon-share:before{content:\"\\ea84\"}.ez-icon-shield:before{content:\"\\ea85\"}.ez-icon-show_menu:before{content:\"\\ea86\"}.ez-icon-south-east:before{content:\"\\ea87\"}.ez-icon-sync:before{content:\"\\ea88\"}.ez-icon-table:before{content:\"\\ea89\"}.ez-icon-tag_code:before{content:\"\\ea8a\"}.ez-icon-text:before{content:\"\\ea8b\"}.ez-icon-timeline:before{content:\"\\ea8c\"}.ez-icon-timer-outline:before{content:\"\\ea8d\"}.ez-icon-trending-up:before{content:\"\\ea8e\"}.ez-icon-tune:before{content:\"\\ea8f\"}.ez-icon-txt:before{content:\"\\ea90\"}.ez-icon-un-pin:before{content:\"\\ea91\"}.ez-icon-unfold_less:before{content:\"\\ea92\"}.ez-icon-unfold_more:before{content:\"\\ea93\"}.ez-icon-user-circle:before{content:\"\\ea94\"}.ez-icon-warning-outline:before{content:\"\\ea95\"}.ez-icon-warning_triangle:before{content:\"\\ea96\"}.ez-icon-whatshot:before{content:\"\\ea97\"}.ez-icon-xlsx:before{content:\"\\ea98\"}.ez-icon-zip:before{content:\"\\ea99\"}.x-small--font{font-size:12px}.small--font{font-size:16px}.medium--font{font-size:20px}.large--font{font-size:24px}.x-large--font{font-size:30px}";
5
5
 
6
6
  const EzIcon = class {
7
7
  constructor(hostRef) {
@@ -142,16 +142,8 @@ const EzMuiltiSelectionList = class {
142
142
  }
143
143
  handleChangeSelectedItem(event) {
144
144
  const { detail: itemCheckSelected } = event;
145
- this.filteredOptions = this.filteredOptions.map(item => {
146
- if (item.label === itemCheckSelected.label) {
147
- return Object.assign(Object.assign({}, item), { check: itemCheckSelected.check });
148
- }
149
- return item;
150
- });
151
- this.clearInputs();
152
- }
153
- clearInputs() {
154
- this.filterInput ? (this.filterInput.value = '') : (this.searchInput.value = '');
145
+ const itemSelected = this.filteredOptions.find(item => item.label === itemCheckSelected.label);
146
+ itemSelected.check = itemCheckSelected.check;
155
147
  }
156
148
  buildViewList(hasDelete) {
157
149
  return (h(Fragment, null, this.displayOptionToCheckAllItems && (h("ez-check", { ref: (element) => (this.checkInput = element), label: "Selecionar todos", class: "multi-selection__select-all", onEzChange: this.handleChangeSelectAllItems.bind(this) })), h("ez-list", { class: "multi-selection__list", dataSource: this.displayOptions, listMode: "check", hoverFeedback: true, onEzCheckChange: this.handleChangeSelectedItem.bind(this), itemSlotBuilder: hasDelete ? this.buildDeleteIconSlot.bind(this) : null })));
@@ -1,6 +1,6 @@
1
1
  import { r as registerInstance, c as createEvent, h, g as getElement } from './index-baa5e267.js';
2
2
  import { NumberUtils, ElementIDUtils } from '@sankhyalabs/core';
3
- import { C as CSSVarsUtils } from './CSSVarsUtils-a97cfa29.js';
3
+ import { C as CSSVarsUtils } from './CSSVarsUtils-71ce76be.js';
4
4
 
5
5
  const ezNumberInputCss = ":host{display:block;width:100%}.number__input{height:100%}";
6
6
 
@@ -114,6 +114,9 @@ const EzNumberInput = class {
114
114
  this.ezCancelWaitingChange.emit();
115
115
  }
116
116
  handleBlur() {
117
+ if (!this._changePending) {
118
+ return;
119
+ }
117
120
  try {
118
121
  const parsedNumber = this.getParsedNumber();
119
122
  if (parsedNumber !== undefined && isNaN(parsedNumber)) {
@@ -1,7 +1,7 @@
1
1
  import { r as registerInstance, c as createEvent, h, F as Fragment, H as Host } from './index-baa5e267.js';
2
2
  import { FloatingManager } from '@sankhyalabs/core';
3
3
 
4
- const ezPopupCss = ":host{display:flex;--ez-popup-z-index:var(--elevation--24, 24);--ez-popup__container--color:var(--title--primary, #2b3a54);--ez-popup__container--padding:var(--space--large, 24px);--ez-popup__header--padding-bottom:var(--space--medium, 12px);--ez-popup__title--font-family:var(--font-pattern, \"Roboto\");--ez-popup__title--font-size:var(--title--extra-large, 24px);--ez-popup__title--color:var(--title--primary, #2b3a54);--ez-popup__title--font-weight:var(--text-weight--large, 600);--ez-popup__btn__close--icon-color:var(--title--primary, #2b3a54);--ez-popup__btn__close--icon:url('data:image/svg+xml;utf8,<svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M 8.2421753,6.9944578 13.743748,1.4930784 C 13.907781,1.3290628 14,1.1065946 14,0.87462511 14,0.64266712 13.907782,0.42019873 13.743748,0.25617155 13.579712,0.09215597 13.35727,6.48e-8 13.125266,6.48e-8 12.89338,6.48e-8 12.670821,0.09215634 12.506787,0.25617155 L 7.005215,5.7575508 1.5035972,0.25617155 C 1.3395631,0.09215597 1.1170968,6.48e-8 0.88511716,6.48e-8 0.65314917,6.48e-8 0.4306712,0.09215597 0.26663695,0.25617155 0.10260271,0.42019873 0.01045441,0.64266712 0.01045441,0.87462511 c 0,0.23196949 0.0921483,0.45443769 0.25618254,0.61845329 L 5.7682546,6.9944578 0.26663695,12.497027 c -0.0834745,0.08067 -0.15003245,0.1772 -0.19581514,0.283871 C 0.02505077,12.887561 9.831648e-4,13.002399 2.950369e-5,13.118395 -9.2415746e-4,13.234504 0.02125019,13.349689 0.06527245,13.457057 c 0.04401053,0.107479 0.10898307,0.205064 0.1911168,0.287137 0.0821454,0.08208 0.17979645,0.146888 0.28727561,0.190839 0.10747906,0.04395 0.22262954,0.06598 0.33872417,0.06493 0.116095,-10e-4 0.23082547,-0.0253 0.33747687,-0.07112 0.1066637,-0.04593 0.2031133,-0.112615 0.2837313,-0.196086 L 7.005215,8.2313646 12.506787,13.732768 c 0.164034,0.164027 0.386593,0.256125 0.618479,0.256125 0.232004,0 0.454446,-0.09209 0.618482,-0.256125 C 13.907781,13.568741 14,13.346308 14,13.114315 14,12.882323 13.90779,12.659888 13.743748,12.495861 Z\"/></svg>')}.overlay{position:fixed;display:flex;top:0px;z-index:var(--ez-popup-z-index, 24);left:0px;width:100%;align-items:center;justify-content:center;box-sizing:border-box;height:100vh;backdrop-filter:blur(4px);background:rgba(0, 4, 12, 0.4)}.popup{display:flex;height:100%;align-items:center;justify-content:center;box-sizing:border-box}.popup__container{width:100%;max-height:90%;height:100%;display:flex;flex-wrap:wrap;overflow:hidden;outline:none;background:#FFFF;color:var(--ez-popup__container--color);border-radius:12px;box-shadow:0px 0px 16px rgba(0, 38, 111, 0.122);box-sizing:border-box;padding:var(--ez-popup__container--padding)}.popup__container--auto{height:auto}.popup__content{box-sizing:border-box;max-height:100%;width:100%;display:grid;grid-template-rows:auto 1fr}.popup__expandable-content{box-sizing:border-box;width:100%;min-height:100%;height:100%}.popup__header{width:100%;display:flex}.popup__header--padding{padding-bottom:var(--ez-popup__header--padding-bottom)}.popup__title{display:flex;margin:0;width:100%;font-family:var(--ez-popup__title--font-family);font-size:var(--ez-popup__title--font-size);font-weight:var(--ez-popup__title--font-weight);color:var(--ez-popup__title--color);line-height:1.3}.btn-close{justify-content:flex-end;align-self:flex-start;align-items:flex-start;display:flex;outline:none;border:none;background-color:unset;cursor:pointer}.btn-close::after{content:'';display:flex;background-color:var(--ez-popup__btn__close--icon-color);width:14px;height:14px;-webkit-mask-image:var(--ez-popup__btn__close--icon);mask-image:var(--ez-popup__btn__close--icon)}.btn-close--solo{width:100%}.row{width:100%;display:flex;flex-wrap:wrap}.col{display:flex;flex-wrap:wrap;align-self:flex-start;box-sizing:border-box}.col--stretch{align-self:stretch}.col--undefined{width:unset}.col--nowrap{flex-wrap:nowrap}.ez-popup__size-limit--x-small{min-width:350px;max-width:560px}@media screen and (min-width: 320px){.col--sd-1{width:8.33333%}.col--sd-2{width:16.66667%}.col--sd-3{width:25%}.col--sd-4{width:33.33333%}.col--sd-5{width:41.66667%}.col--sd-6{width:50%}.col--sd-7{width:58.33333%}.col--sd-8{width:66.66667%}.col--sd-9{width:75%}.col--sd-10{width:83.33333%}.col--sd-11{width:91.66667%}.col--sd-12{width:100%}}@media screen and (min-width: 480px){.col--pn-1{width:8.33333%}.col--pn-2{width:16.66667%}.col--pn-3{width:25%}.col--pn-4{width:33.33333%}.col--pn-5{width:41.66667%}.col--pn-6{width:50%}.col--pn-7{width:58.33333%}.col--pn-8{width:66.66667%}.col--pn-9{width:75%}.col--pn-10{width:83.33333%}.col--pn-11{width:91.66667%}.col--pn-12{width:100%}}@media screen and (min-width: 768px){.col--tb-1{width:8.33333%}.col--tb-2{width:16.66667%}.col--tb-3{width:25%}.col--tb-4{width:33.33333%}.col--tb-5{width:41.66667%}.col--tb-6{width:50%}.col--tb-7{width:58.33333%}.col--tb-8{width:66.66667%}.col--tb-9{width:75%}.col--tb-10{width:83.33333%}.col--tb-11{width:91.66667%}.col--tb-12{width:100%}}@media screen and (min-width: 992px){.col--md-1{width:8.33333%}.col--md-2{width:16.66667%}.col--md-3{width:25%}.col--md-4{width:33.33333%}.col--md-5{width:41.66667%}.col--md-6{width:50%}.col--md-7{width:58.33333%}.col--md-8{width:66.66667%}.col--md-9{width:75%}.col--md-10{width:83.33333%}.col--md-11{width:91.66667%}.col--md-12{width:100%}}@media screen and (min-width: 1200px){.col--ld-1{width:8.33333%}.col--ld-2{width:16.66667%}.col--ld-3{width:25%}.col--ld-4{width:33.33333%}.col--ld-5{width:41.66667%}.col--ld-6{width:50%}.col--ld-7{width:58.33333%}.col--ld-8{width:66.66667%}.col--ld-9{width:75%}.col--ld-10{width:83.33333%}.col--ld-11{width:91.66667%}.col--ld-12{width:100%}}";
4
+ const ezPopupCss = ":host{display:flex;--ez-popup-z-index:var(--elevation--24, 24);--ez-popup__container--color:var(--title--primary, #2b3a54);--ez-popup__container--padding:var(--space--large, 24px);--ez-popup__header--padding-bottom:var(--space--medium, 12px);--ez-popup__title--font-family:var(--font-pattern, \"Roboto\");--ez-popup__title--font-size:var(--title--extra-large, 24px);--ez-popup__title--color:var(--title--primary, #2b3a54);--ez-popup__title--font-weight:var(--text-weight--large, 600);--ez-popup__btn__close--icon-color:var(--title--primary, #2b3a54);--ez-popup__btn__close--icon:url('data:image/svg+xml;utf8,<svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M 8.2421753,6.9944578 13.743748,1.4930784 C 13.907781,1.3290628 14,1.1065946 14,0.87462511 14,0.64266712 13.907782,0.42019873 13.743748,0.25617155 13.579712,0.09215597 13.35727,6.48e-8 13.125266,6.48e-8 12.89338,6.48e-8 12.670821,0.09215634 12.506787,0.25617155 L 7.005215,5.7575508 1.5035972,0.25617155 C 1.3395631,0.09215597 1.1170968,6.48e-8 0.88511716,6.48e-8 0.65314917,6.48e-8 0.4306712,0.09215597 0.26663695,0.25617155 0.10260271,0.42019873 0.01045441,0.64266712 0.01045441,0.87462511 c 0,0.23196949 0.0921483,0.45443769 0.25618254,0.61845329 L 5.7682546,6.9944578 0.26663695,12.497027 c -0.0834745,0.08067 -0.15003245,0.1772 -0.19581514,0.283871 C 0.02505077,12.887561 9.831648e-4,13.002399 2.950369e-5,13.118395 -9.2415746e-4,13.234504 0.02125019,13.349689 0.06527245,13.457057 c 0.04401053,0.107479 0.10898307,0.205064 0.1911168,0.287137 0.0821454,0.08208 0.17979645,0.146888 0.28727561,0.190839 0.10747906,0.04395 0.22262954,0.06598 0.33872417,0.06493 0.116095,-10e-4 0.23082547,-0.0253 0.33747687,-0.07112 0.1066637,-0.04593 0.2031133,-0.112615 0.2837313,-0.196086 L 7.005215,8.2313646 12.506787,13.732768 c 0.164034,0.164027 0.386593,0.256125 0.618479,0.256125 0.232004,0 0.454446,-0.09209 0.618482,-0.256125 C 13.907781,13.568741 14,13.346308 14,13.114315 14,12.882323 13.90779,12.659888 13.743748,12.495861 Z\"/></svg>')}.overlay{position:fixed;display:flex;top:0px;z-index:var(--ez-popup-z-index, 24);left:0px;width:100%;align-items:center;justify-content:center;box-sizing:border-box;height:100vh;backdrop-filter:blur(4px);background:rgba(0, 4, 12, 0.4)}.popup{display:flex;height:100%;align-items:center;justify-content:center;box-sizing:border-box}.popup__container{width:100%;max-height:90%;height:100%;display:flex;flex-wrap:wrap;overflow:hidden;outline:none;background:#FFFF;color:var(--ez-popup__container--color);border-radius:12px;box-shadow:0px 0px 16px rgba(0, 38, 111, 0.122);box-sizing:border-box;padding:var(--ez-popup__container--padding)}.popup__container--auto{height:auto}.popup__content{box-sizing:border-box;height:100%;width:100%}.popup__expandable-content{box-sizing:border-box;width:100%;height:calc(100% - 44px)}.popup__header{width:100%;display:flex}.popup__header--padding{padding-bottom:var(--ez-popup__header--padding-bottom)}.popup__title{display:flex;margin:0;width:100%;font-family:var(--ez-popup__title--font-family);font-size:var(--ez-popup__title--font-size);font-weight:var(--ez-popup__title--font-weight);color:var(--ez-popup__title--color);line-height:1.3}.btn-close{justify-content:flex-end;align-self:flex-start;align-items:flex-start;display:flex;outline:none;border:none;background-color:unset;cursor:pointer}.btn-close::after{content:'';display:flex;background-color:var(--ez-popup__btn__close--icon-color);width:14px;height:14px;-webkit-mask-image:var(--ez-popup__btn__close--icon);mask-image:var(--ez-popup__btn__close--icon)}.btn-close--solo{width:100%}.row{width:100%;display:flex;flex-wrap:wrap}.col{display:flex;flex-wrap:wrap;align-self:flex-start;box-sizing:border-box}.col--stretch{align-self:stretch}.col--undefined{width:unset}.col--nowrap{flex-wrap:nowrap}.ez-popup__size-limit--x-small{min-width:350px;max-width:560px}@media screen and (min-width: 320px){.col--sd-1{width:8.33333%}.col--sd-2{width:16.66667%}.col--sd-3{width:25%}.col--sd-4{width:33.33333%}.col--sd-5{width:41.66667%}.col--sd-6{width:50%}.col--sd-7{width:58.33333%}.col--sd-8{width:66.66667%}.col--sd-9{width:75%}.col--sd-10{width:83.33333%}.col--sd-11{width:91.66667%}.col--sd-12{width:100%}}@media screen and (min-width: 480px){.col--pn-1{width:8.33333%}.col--pn-2{width:16.66667%}.col--pn-3{width:25%}.col--pn-4{width:33.33333%}.col--pn-5{width:41.66667%}.col--pn-6{width:50%}.col--pn-7{width:58.33333%}.col--pn-8{width:66.66667%}.col--pn-9{width:75%}.col--pn-10{width:83.33333%}.col--pn-11{width:91.66667%}.col--pn-12{width:100%}}@media screen and (min-width: 768px){.col--tb-1{width:8.33333%}.col--tb-2{width:16.66667%}.col--tb-3{width:25%}.col--tb-4{width:33.33333%}.col--tb-5{width:41.66667%}.col--tb-6{width:50%}.col--tb-7{width:58.33333%}.col--tb-8{width:66.66667%}.col--tb-9{width:75%}.col--tb-10{width:83.33333%}.col--tb-11{width:91.66667%}.col--tb-12{width:100%}}@media screen and (min-width: 992px){.col--md-1{width:8.33333%}.col--md-2{width:16.66667%}.col--md-3{width:25%}.col--md-4{width:33.33333%}.col--md-5{width:41.66667%}.col--md-6{width:50%}.col--md-7{width:58.33333%}.col--md-8{width:66.66667%}.col--md-9{width:75%}.col--md-10{width:83.33333%}.col--md-11{width:91.66667%}.col--md-12{width:100%}}@media screen and (min-width: 1200px){.col--ld-1{width:8.33333%}.col--ld-2{width:16.66667%}.col--ld-3{width:25%}.col--ld-4{width:33.33333%}.col--ld-5{width:41.66667%}.col--ld-6{width:50%}.col--ld-7{width:58.33333%}.col--ld-8{width:66.66667%}.col--ld-9{width:75%}.col--ld-10{width:83.33333%}.col--ld-11{width:91.66667%}.col--ld-12{width:100%}}";
5
5
 
6
6
  const EzPopup = class {
7
7
  constructor(hostRef) {
@@ -1,12 +1,12 @@
1
1
  import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-baa5e267.js';
2
- import { C as CSSVarsUtils } from './CSSVarsUtils-a97cfa29.js';
2
+ import { C as CSSVarsUtils } from './CSSVarsUtils-71ce76be.js';
3
3
  import { ObjectUtils, StringUtils, FloatingManager, ElementIDUtils } from '@sankhyalabs/core';
4
4
  import { A as ApplicationUtils } from './ApplicationUtils-eaf91331.js';
5
5
  import './DialogType-54a62731.js';
6
6
  import './CheckMode-bdb2ec19.js';
7
7
  import { R as REQUIRED_INFO } from './constants-4e0d35b7.js';
8
8
 
9
- const ezSearchCss = ":host{--ez-search--height:42px;--ez-search--width:100%;--ez-search__icon--width:48px;--ez-search--border-radius:var(--border--radius-medium, 12px);--ez-search--border-radius-small:var(--border--radius-small, 6px);--ez-search--font-size:var(--text--medium, 14px);--ez-search--font-family:var(--font-pattern, Arial);--ez-search--font-weight--large:var(--text-weight--large, 500);--ez-search--font-weight--medium:var(--text-weight--medium, 400);--ez-search--background-color--xlight:var(--background--xlight, #fff);--ez-search--background-medium:var(--background--medium, #f0f3f7);--ez-search--line-height:calc(var(--text--medium, 14px) + 4px);--ez-search__input--background-color:var(--background--medium, #e0e0e0);--ez-search__input--border:var(--border--medium, 2px solid);--ez-search__input--border-color:var(--ez-search__input--background-color);--ez-search__input--focus--border-color:var(--color--primary, #008561);--ez-search__input--disabled--background-color:var(--color--disable-secondary, #F2F5F8);--ez-search__input--disabled--color:var(--text--disable, #AFB6C0);--ez-search__input--error--border-color:#CC2936;--ez-search__btn--color:var(--title--primary, #2B3A54);--ez-search__btn-disabled--color:var(--text--disable, #AFB6C0);--ez-search__btn-hover--color:var(--color--primary, #4e4e4e);--ez-search__label--color:var(--title--primary, #2B3A54);--ez-search__list-title--primary:var(--title--primary, #2B3A54);--ez-search__list-text--primary:var(--text--primary, #626e82);--ez-search__list-height:calc(var(--ez-search--font-size) + var(--ez-search--space--medium) + 4px);--ez-search__list-min-width:64px;--ez-search--space--medium:var(--space--medium, 12px);--ez-search--space--small:var(--space--small, 6px);--ez-search__scrollbar--color-default:var(--scrollbar--default, #626e82);--ez-search__scrollbar--color-background:var(--scrollbar--background, #E5EAF0);--ez-search__scrollbar--color-hover:var(--scrollbar--hover, #2B3A54);--ez-search__scrollbar--color-clicked:var(--scrollbar--clicked, #a2abb9);--ez-search__scrollbar--border-radius:var(--border--radius-small, 6px);--ez-search__scrollbar--width:var(--space--medium, 12px);display:flex;flex-wrap:wrap;position:relative;width:var(--ez-search--width)}ez-icon{--ez-icon--color:inherit;font-weight:var(--text-weight--large, 600)}.suppressed-search-input{--ez-text-input__input--border-color:var(--color--strokes, #dce0e8);--ez-text-input__input--disabled--background-color:var(--background--xlight, #fff);--ez-text-input__input--disabled--color:var(--title--primary, #2B3A54)}.list-container{min-width:var(--ez-search__list-min-width);position:relative;width:100%}.list-wrapper{display:flex;flex-direction:column;box-sizing:border-box;width:0;z-index:var(--more-visible, 2);max-height:350px;background-color:var(--ez-search--background-color--xlight);border-radius:var(--ez-search--border-radius);box-shadow:var(--shadow, 0px 0px 16px 0px #000);padding:var(--ez-search--space--small)}.list-options{box-sizing:border-box;width:100%;height:100%;padding:0;display:flex;flex-direction:column;scroll-behavior:smooth;overflow:auto;scrollbar-width:thin;gap:3px;scrollbar-color:var(--ez-search__scrollbar--color-clicked) var(--ez-search__scrollbar--color-background)}.list-options::-webkit-scrollbar{background-color:var(--ez-search__scrollbar--color-background);width:var(--ez-search__scrollbar--width);max-width:var(--ez-search__scrollbar--width);min-width:var(--ez-search__scrollbar--width)}.list-options::-webkit-scrollbar-track{background-color:var(--ez-search__scrollbar--color-background);border-radius:var(--ez-search__scrollbar--border-radius)}.list-options::-webkit-scrollbar-thumb{background-color:var(--ez-search__scrollbar--color-default);border-radius:var(--ez-search__scrollbar--border-radius)}.list-options::-webkit-scrollbar-thumb:vertical:hover,.list-options::-webkit-scrollbar-thumb:horizontal:hover{background-color:var(--ez-search__scrollbar--color-hover)}.list-options::-webkit-scrollbar-thumb:vertical:active,.list-options::-webkit-scrollbar-thumb:horizontal:active{background-color:var(--ez-search__scrollbar--color-clicked)}.item{display:flex;align-items:center;width:100%;box-sizing:border-box;list-style-type:none;cursor:pointer;border-radius:var(--ez-search--border-radius-small);padding:var(--ez-search--space--small);min-height:var(--ez-search__list-height);gap:var(--space--small, 6px)}.item__value,.item__label{flex-basis:auto;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:var(--ez-search__list-title--primary);font-family:var(--ez-search--font-family);font-size:var(--ez-search--font-size);line-height:var(--ez-search--line-height)}.item__label{font-weight:var(--ez-search--font-weight--medium)}.item__label--bold{font-weight:var(--ez-search--font-weight--large)}.item__value{text-align:center;color:var(--ez-search__list-text--primary);font-weight:var(--ez-search--font-weight--large)}.item__value--hidden{visibility:hidden;position:absolute;white-space:nowrap;z-index:-1;top:0;left:0}.item__label{text-align:left}.message{text-align:center;display:flex;justify-content:center;align-items:center;list-style-type:none;min-height:var(--ez-search__list-height)}.message__no-result{color:var(--ez-search__list-title--primary);font-family:var(--ez-search--font-family);font-size:var(--ez-search--font-size)}.message__loading{border-radius:50%;width:14px;height:14px;-webkit-animation:spin 1s linear infinite;animation:spin 1s linear infinite;border:3px solid var(--ez-search__list-title--primary);border-top:3px solid transparent}.item__list>li:hover{background-color:var(--ez-search--background-medium)}.preselected{background-color:var(--background--medium)}.btn{outline:none;border:none;background:none;cursor:pointer;color:var(--ez-search__btn--color)}.btn:disabled{cursor:unset;color:var(--ez-search__btn-disabled--color)}.btn:disabled:hover{cursor:unset;color:var(--ez-search__btn-disabled--color)}.btn:hover{color:var(--ez-search__btn-hover--color)}.btn__close{visibility:hidden}ez-text-input:hover .btn__close,ez-text-input:focus .btn__close{visibility:visible}@-webkit-keyframes spin{0%{-webkit-transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg)}}@keyframes spin{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}";
9
+ const ezSearchCss = ":host{--ez-search--height:42px;--ez-search--width:100%;--ez-search__icon--width:48px;--ez-search--border-radius:var(--border--radius-medium, 12px);--ez-search--border-radius-small:var(--border--radius-small, 6px);--ez-search--font-size:var(--text--medium, 14px);--ez-search--font-family:var(--font-pattern, Arial);--ez-search--font-weight--large:var(--text-weight--large, 500);--ez-search--font-weight--medium:var(--text-weight--medium, 400);--ez-search--background-color--xlight:var(--background--xlight, #fff);--ez-search--background-medium:var(--background--medium, #f0f3f7);--ez-search--line-height:calc(var(--text--medium, 14px) + 4px);--ez-search__input--background-color:var(--background--medium, #e0e0e0);--ez-search__input--border:var(--border--medium, 2px solid);--ez-search__input--border-color:var(--ez-search__input--background-color);--ez-search__input--focus--border-color:var(--color--primary, #008561);--ez-search__input--disabled--background-color:var(--color--disable-secondary, #F2F5F8);--ez-search__input--disabled--color:var(--text--disable, #AFB6C0);--ez-search__input--error--border-color:#CC2936;--ez-search__btn--color:var(--title--primary, #2B3A54);--ez-search__btn-disabled--color:var(--text--disable, #AFB6C0);--ez-search__btn-hover--color:var(--color--primary, #4e4e4e);--ez-search__label--color:var(--title--primary, #2B3A54);--ez-search__list-title--primary:var(--title--primary, #2B3A54);--ez-search__list-text--primary:var(--text--primary, #626e82);--ez-search__list-height:calc(var(--ez-search--font-size) + var(--ez-search--space--medium) + 4px);--ez-search__list-min-width:64px;--ez-search--space--medium:var(--space--medium, 12px);--ez-search--space--small:var(--space--small, 6px);--ez-search__scrollbar--color-default:var(--scrollbar--default, #626e82);--ez-search__scrollbar--color-background:var(--scrollbar--background, #E5EAF0);--ez-search__scrollbar--color-hover:var(--scrollbar--hover, #2B3A54);--ez-search__scrollbar--color-clicked:var(--scrollbar--clicked, #a2abb9);--ez-search__scrollbar--border-radius:var(--border--radius-small, 6px);--ez-search__scrollbar--width:var(--space--medium, 12px);display:flex;flex-wrap:wrap;position:relative;width:var(--ez-search--width)}ez-icon{--ez-icon--color:inherit;font-weight:var(--text-weight--large, 600)}.suppressed-search-input{--ez-text-input__input--border-color:var(--color--strokes, #dce0e8);--ez-text-input__input--disabled--background-color:var(--background--xlight, #fff);--ez-text-input__input--disabled--color:var(--title--primary, #2B3A54)}.list-container{min-width:var(--ez-search__list-min-width);overflow:auto;position:relative;width:100%}.list-wrapper{display:flex;flex-direction:column;box-sizing:border-box;width:0;z-index:var(--more-visible, 2);max-height:350px;min-width:150px;background-color:var(--ez-search--background-color--xlight);border-radius:var(--ez-search--border-radius);box-shadow:var(--shadow, 0px 0px 16px 0px #000);padding:var(--ez-search--space--small)}.list-options{box-sizing:border-box;width:100%;height:100%;padding:0;display:flex;flex-direction:column;scroll-behavior:smooth;overflow:auto;scrollbar-width:thin;gap:3px;scrollbar-color:var(--ez-search__scrollbar--color-clicked) var(--ez-search__scrollbar--color-background)}.list-options::-webkit-scrollbar{background-color:var(--ez-search__scrollbar--color-background);width:var(--ez-search__scrollbar--width);max-width:var(--ez-search__scrollbar--width);min-width:var(--ez-search__scrollbar--width)}.list-options::-webkit-scrollbar-track{background-color:var(--ez-search__scrollbar--color-background);border-radius:var(--ez-search__scrollbar--border-radius)}.list-options::-webkit-scrollbar-thumb{background-color:var(--ez-search__scrollbar--color-default);border-radius:var(--ez-search__scrollbar--border-radius)}.list-options::-webkit-scrollbar-thumb:vertical:hover,.list-options::-webkit-scrollbar-thumb:horizontal:hover{background-color:var(--ez-search__scrollbar--color-hover)}.list-options::-webkit-scrollbar-thumb:vertical:active,.list-options::-webkit-scrollbar-thumb:horizontal:active{background-color:var(--ez-search__scrollbar--color-clicked)}.item{display:flex;align-items:center;width:100%;box-sizing:border-box;list-style-type:none;cursor:pointer;border-radius:var(--ez-search--border-radius-small);padding:var(--ez-search--space--small);gap:var(--space--small, 6px)}.item__value,.item__label{flex-basis:auto;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:var(--ez-search__list-title--primary);font-family:var(--ez-search--font-family);font-size:var(--ez-search--font-size);line-height:var(--ez-search--line-height)}.item__label{font-weight:var(--ez-search--font-weight--medium)}.item__label--bold{font-weight:var(--ez-search--font-weight--large)}.item__value{text-align:center;color:var(--ez-search__list-text--primary);font-weight:var(--ez-search--font-weight--large)}.item__value--hidden{visibility:hidden;position:absolute;white-space:nowrap;z-index:-1;top:0;left:0}.item__label{text-align:left}.message{text-align:center;display:flex;justify-content:center;align-items:center;list-style-type:none;min-height:var(--ez-search__list-height)}.message__no-result{color:var(--ez-search__list-title--primary);font-family:var(--ez-search--font-family);font-size:var(--ez-search--font-size)}.message__loading{border-radius:50%;width:14px;height:14px;-webkit-animation:spin 1s linear infinite;animation:spin 1s linear infinite;border:3px solid var(--ez-search__list-title--primary);border-top:3px solid transparent}.item__list>li:hover{background-color:var(--ez-search--background-medium)}.preselected{background-color:var(--background--medium)}.btn{outline:none;border:none;background:none;cursor:pointer;color:var(--ez-search__btn--color)}.btn:disabled{cursor:unset;color:var(--ez-search__btn-disabled--color)}.btn:disabled:hover{cursor:unset;color:var(--ez-search__btn-disabled--color)}.btn:hover{color:var(--ez-search__btn-hover--color)}.btn__close{visibility:hidden}ez-text-input:hover .btn__close,ez-text-input:focus .btn__close{visibility:visible}@-webkit-keyframes spin{0%{-webkit-transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg)}}@keyframes spin{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}";
10
10
 
11
11
  const EzSearch = class {
12
12
  constructor(hostRef) {
@@ -194,10 +194,9 @@ const EzSearch = class {
194
194
  if (currentValue == undefined) {
195
195
  return;
196
196
  }
197
- if (!this.showSelectedValue || currentValue.value == undefined) {
198
- return currentValue.label;
199
- }
200
- return currentValue.label ? `${currentValue.value} - ${currentValue.label}` : currentValue.value;
197
+ let text = (!this.showSelectedValue || currentValue.value == undefined) ? currentValue.label : `${currentValue.value} - ${currentValue.label}`;
198
+ text = text.replace(new RegExp(this._startHighlightTag, 'g'), '').replace(new RegExp(this._endHighlightTag, 'g'), '');
199
+ return text;
201
200
  }
202
201
  getText() {
203
202
  const currentValue = this.getSelectedOption(this.value);
@@ -269,7 +268,7 @@ const EzSearch = class {
269
268
  title: opt.label,
270
269
  details: opt.details
271
270
  };
272
- return h("div", { style: { "height": "100%" }, onMouseDown: () => this.createOption(card), onMouseOver: () => this._preSelection = index }, h("ez-card-item", { item: card }));
271
+ return h("div", { style: { "height": "100%" }, class: index === this._preSelection ? "item preselected" : "item", id: `item_${opt.value}`, onMouseDown: () => this.createOption(card), onMouseOver: () => this._preSelection = index }, h("ez-card-item", { item: card }));
273
272
  }
274
273
  showOptions() {
275
274
  if (!this.enabled)
@@ -313,7 +312,7 @@ const EzSearch = class {
313
312
  }
314
313
  scrollToOption(opt) {
315
314
  window.requestAnimationFrame(() => {
316
- const liElem = (opt === null || opt === void 0 ? void 0 : opt.value) ? this._optionsList.querySelector(`li#item_${opt.value.replace(/[<>\[\]#=]/g, '\\$&').replace(/:/g, '\\:')}`) : undefined;
315
+ const liElem = (opt === null || opt === void 0 ? void 0 : opt.value) ? this._optionsList.querySelector(`div#item_${opt.value.replace(/[<>\[\]#=]/g, '\\$&').replace(/:/g, '\\:')}`) : undefined;
317
316
  if (liElem)
318
317
  liElem.scrollIntoView({ behavior: "smooth", block: "nearest" });
319
318
  });
@@ -0,0 +1,143 @@
1
+ import { r as registerInstance, c as createEvent, h, g as getElement } from './index-baa5e267.js';
2
+ import { ElementIDUtils } from '@sankhyalabs/core';
3
+
4
+ const ezSplitButtonCss = ":host{--ez-split-button--min-width:24;--ez-split-button--width:'auto';--ez-split-button__medium--height:32px;--ez-split-button__large--height:42px;--ez-split-button__medium-icon--width:40px;--ez-split-button__large-icon--width:44px;--ez-split-button__inline__icon--gap:6px;--ez-split-button__label--padding-top:0px;--ez-split-button__label--padding-bottom:0px;--ez-split-button__right-button--padding-left:8px;--ez-split-button--color:var(--title--primary, #FFF);--ez-split-button--font-size:var(--text--medium, 14px);--ez-split-button--font-family:var(--font-pattern, Arial);--ez-split-button--font-weight:var(--text-weight--large);--ez-split-button--background-color:var(--background--medium, #008561);--ez-split-button--border-radius:var(--border--radius-large, 12px);--ez-split-button--border:none;--ez-split-button--justify-content:center;--ez-split-button--hover-color:var(--color--primary-600);--ez-split-button--hover--background-color:var(--background--medium, var(--ez-split-button--background-color));--ez-split-button--disabled-color:var(--text--disable);--ez-split-button--disabled--background-color:var(--color--disable-secondary);--ez-split-button--focus--border:var(--border--medium, 2px) var(--color--primary-300);--ez-split-button--focus--box-shadow:none;--ez-split-button--active-color:var(--color--primary-700);--ez-split-button--active--background-color:var(--background--strong)}ez-icon{--ez-icon--color:inherit}button{position:relative;display:flex;align-items:center;margin:0;cursor:pointer;transition:background-color 0.2s linear;white-space:nowrap;min-width:var(--ez-split-button--min-width);width:var(--ez-split-button--width);height:var(--ez-split-button__medium--height);font-family:var(--ez-split-button--font-family);font-size:var(--ez-split-button--font-size);font-weight:var(--ez-split-button--font-weight);padding:var(--ez-split-button__label--padding-top) 0 var(--ez-split-button__label--padding-bottom) 0;border-top-left-radius:var(--ez-split-button--border-radius);border-bottom-left-radius:var(--ez-split-button--border-radius);background-color:var(--ez-split-button--background-color);color:var(--ez-split-button--color);fill:var(--ez-split-button--color);border:var(--ez-split-button--border);justify-content:var(--ez-split-button--justify-content)}label{cursor:pointer}button:active{outline:none;box-shadow:none;background-color:var(--ez-split-button--active--background-color);color:var(--ez-split-button--active-color);fill:var(--ez-split-button--active-color);--ez-icon--color:var(--ez-split-button--active-color)}.ez-split-button__left-button:focus,.ez-split-button__right-button:focus{outline:var(--ez-split-button--focus--border);box-shadow:var(--ez-split-button--focus--box-shadow)}.ez-split-button__left-button:hover,.ez-split-button__right-button:hover{outline:none;background-color:var(--ez-split-button--hover--background-color);color:var(--ez-split-button--hover-color);fill:var(--ez-split-button--hover-color);--ez-icon--color:var(--ez-split-button--hover-color)}.ez-split-button__left-button:disabled,.ez-split-button__left-button:disabled label,.ez-split-button__right-button:disabled{background-color:var(--ez-split-button--disabled--background-color);color:var(--ez-split-button--disabled-color);fill:var(--ez-split-button--disabled-color);border:none;--ez-icon--color:var(--ez-split-button--disabled-color);cursor:not-allowed}button.large{height:var(--ez-split-button__large--height)}button.medium{height:var(--ez-split-button__medium--height)}.default label{padding:var(--ez-split-button__label--padding-top) 12px var(--ez-split-button__label--padding-bottom) 20px}.icon-left{gap:var(--ez-split-button__inline__icon--gap)}.icon-left label{padding-right:12px}.icon-left ez-icon{padding-left:20px}.icon-only{padding-left:12px;padding-right:12px}.ez-split-button__right-button{border-top-right-radius:var(--ez-split-button--border-radius);border-bottom-right-radius:var(--ez-split-button--border-radius);border-top-left-radius:0;border-bottom-left-radius:0}.ez-split-button__right-button--medium{min-width:var(--ez-split-button__medium-icon--width)}.ez-split-button__right-button--large{min-width:var(--ez-split-button__large-icon--width)}.ez-split-button__right-button--divider{top:10%;bottom:10%}.ez-split-button__right-button--divider:before{content:\"\";position:absolute;left:0;border-left:1px solid rgba(0, 0, 0, 20%);border-radius:2px;height:75%}.btn-icon--medium{min-width:--ez-split-button__medium-icon--width}.btn-icon--large{min-width:--ez-split-button__large-icon--width}.ez-split-button__right-button-container{position:absolute;left:0;padding-left:var(--ez-split-button__right-button--padding-left)}.label-icon{display:flex;flex-direction:row;align-items:center;color:var(--ez-split-button--color)}.label-icon:active{color:var(--ez-split-button--active-color);fill:var(--ez-split-button--active-color);--ez-icon--color:var(--ez-split-button--active-color)}.dropdown{display:flex}.dropdown-content{display:block;position:absolute;background-color:#f1f1f1;min-width:160px;z-index:--ez-elevation--8;border-radius:var(--ez-split-button--border-radius)}.dropdown-content>ez-dropdown{position:relative}";
5
+
6
+ const EzSplitButton = class {
7
+ constructor(hostRef) {
8
+ registerInstance(this, hostRef);
9
+ this.buttonClick = createEvent(this, "buttonClick", 7);
10
+ this.dropdownItemClick = createEvent(this, "dropdownItemClick", 7);
11
+ this.dropdownSubActionClick = createEvent(this, "dropdownSubActionClick", 7);
12
+ this.rightDefaultTitle = 'Mais opções';
13
+ this.show = false;
14
+ this.enabled = true;
15
+ this.iconName = undefined;
16
+ this.image = undefined;
17
+ this.items = undefined;
18
+ this.label = undefined;
19
+ this.leftTitle = undefined;
20
+ this.rightTitle = 'Mais opções';
21
+ this.mode = 'default';
22
+ this.size = 'medium';
23
+ }
24
+ /**
25
+ * Remove o foco de ambos os botões.
26
+ */
27
+ async setBlur() {
28
+ this.leftButton.blur();
29
+ this.rightButton.blur();
30
+ }
31
+ /**
32
+ * Aplica o foco no botão principal.
33
+ */
34
+ async setLeftButtonFocus() {
35
+ this.leftButton.focus();
36
+ }
37
+ /**
38
+ * Aplica o foco no botão do dropdown.
39
+ */
40
+ async setRightButtonFocus() {
41
+ this.rightButton.focus();
42
+ }
43
+ clickListener(evt) {
44
+ if (!this.enabled) {
45
+ evt.preventDefault();
46
+ evt.stopPropagation();
47
+ evt.stopImmediatePropagation();
48
+ }
49
+ }
50
+ getIconSize(sizeParam = 'medium') {
51
+ var _a;
52
+ const sizeList = ['medium', 'large'];
53
+ const sizeLowerCase = (_a = this.size) === null || _a === void 0 ? void 0 : _a.toLowerCase();
54
+ return sizeList.includes(sizeLowerCase) ? sizeLowerCase : sizeParam;
55
+ }
56
+ closeDropdown() {
57
+ this.show = false;
58
+ }
59
+ toggleDropdown() {
60
+ this.show = !this.show;
61
+ }
62
+ handleButtonClick() {
63
+ this.buttonClick.emit();
64
+ }
65
+ handleDropdownItemClick(evt) {
66
+ this.dropdownItemClick.emit(evt.detail);
67
+ evt.stopPropagation();
68
+ this.closeDropdown();
69
+ }
70
+ handleDropdownSubActionClick(evt) {
71
+ this.dropdownSubActionClick.emit(evt.detail);
72
+ evt.stopPropagation();
73
+ this.closeDropdown();
74
+ }
75
+ /**
76
+ * Método responsável em posicionar o dropdown na tela.
77
+ * Faz com que o dropdown se ajuste automaticamente ao espaco na tela
78
+ */
79
+ positionDropdown() {
80
+ const { rightButton: _rightButton, dropdownParent: _dropdownParent } = this;
81
+ const rightButtonRect = _rightButton.getBoundingClientRect();
82
+ const dropdownParentRect = _dropdownParent.getBoundingClientRect();
83
+ const spaceBelow = window.innerHeight - rightButtonRect.bottom;
84
+ const spaceAbove = rightButtonRect.top;
85
+ const spaceRight = window.innerWidth - rightButtonRect.right;
86
+ const spaceLeft = rightButtonRect.left;
87
+ const hasSpaceBelow = spaceBelow < dropdownParentRect.height && spaceAbove > dropdownParentRect.height;
88
+ const hasSpaceRight = spaceRight < dropdownParentRect.width && spaceLeft > dropdownParentRect.width;
89
+ let top = `${rightButtonRect.bottom + window.scrollY}px`;
90
+ let left = `${rightButtonRect.left + window.scrollX}px`;
91
+ let bottom = 'auto';
92
+ if (hasSpaceBelow) {
93
+ bottom = `${window.innerHeight - rightButtonRect.top - window.scrollY}px`;
94
+ top = 'auto';
95
+ _dropdownParent.style.maxHeight = `${spaceAbove}px`;
96
+ }
97
+ if (hasSpaceRight) {
98
+ left = `${rightButtonRect.right - dropdownParentRect.width + window.scrollX}px`;
99
+ }
100
+ _dropdownParent.style.top = top;
101
+ _dropdownParent.style.bottom = bottom;
102
+ _dropdownParent.style.left = left;
103
+ }
104
+ setEvents() {
105
+ window.removeEventListener('scroll', this.positionDropdown.bind(this));
106
+ window.addEventListener('scroll', this.positionDropdown.bind(this));
107
+ }
108
+ componentWillLoad() {
109
+ this.setEvents();
110
+ }
111
+ componentDidLoad() {
112
+ if (this._element)
113
+ ElementIDUtils.addIDInfo(this._element);
114
+ if (this.leftButton) {
115
+ const dataInfo = { id: 'embedded' };
116
+ ElementIDUtils.addIDInfo(this.leftButton, 'left-button', dataInfo);
117
+ }
118
+ if (this.rightButton) {
119
+ const dataInfo = { id: 'embedded' };
120
+ ElementIDUtils.addIDInfo(this.rightButton, 'right-button', dataInfo);
121
+ }
122
+ this.positionDropdown();
123
+ }
124
+ componentDidUpdate() {
125
+ this.positionDropdown();
126
+ }
127
+ render() {
128
+ const hasIconButton = this.shouldShowIconOnLeftButton();
129
+ const hasLabelButton = this.shouldShowLabelOnLeftButton();
130
+ const iconSize = this.getIconSize();
131
+ return (h("div", { class: "label-icon" }, h("button", { class: `ez-split-button__left-button ${iconSize} ${this.mode}`, title: this.leftTitle || this.label, type: "button", disabled: !this.enabled, onClick: () => { this.handleButtonClick(); }, ref: el => (this.leftButton = el) }, hasIconButton && h("ez-icon", { href: this.image, iconName: this.iconName, size: iconSize }), hasLabelButton && h("label", { title: this.leftTitle || this.label }, this.label)), h("div", { class: "dropdown" }, h("button", { class: `ez-split-button__right-button ${iconSize} ez-split-button__right-button--${iconSize} ez-split-button__right-button--divider`, title: this.rightTitle || this.rightDefaultTitle, type: "button", disabled: !this.enabled, onClick: () => { this.toggleDropdown(); }, ref: el => (this.rightButton = el) }, h("ez-icon", { class: `ez-split-button__right-button-container ` + (iconSize ? `btn-icon--${iconSize}` : ''), iconName: 'chevron-down', size: iconSize })), h("div", { class: `dropdown-content dropdown-content--${this.size}`, ref: (ref) => (this.dropdownParent = ref) }, this.show && (h("ez-dropdown", { items: this.items, onClick: evt => { evt.stopPropagation(); }, onEzOutsideClick: () => { this.closeDropdown(); }, onEzClick: evt => { this.handleDropdownItemClick(evt); }, onEzSubActionClick: evt => { this.handleDropdownSubActionClick(evt); } }))))));
132
+ }
133
+ shouldShowLabelOnLeftButton() {
134
+ return ['icon-left', 'default'].includes(this.mode);
135
+ }
136
+ shouldShowIconOnLeftButton() {
137
+ return ['icon-left', 'icon-only'].includes(this.mode);
138
+ }
139
+ get _element() { return getElement(this); }
140
+ };
141
+ EzSplitButton.style = ezSplitButtonCss;
142
+
143
+ export { EzSplitButton as ez_split_button };
@@ -1,13 +1,31 @@
1
1
  import { r as registerInstance, h, H as Host } from './index-baa5e267.js';
2
+ import './ApplicationUtils-eaf91331.js';
3
+ import { C as CSSVarsUtils } from './CSSVarsUtils-71ce76be.js';
4
+ import './DialogType-54a62731.js';
5
+ import './CheckMode-bdb2ec19.js';
6
+ import '@sankhyalabs/core';
2
7
 
3
- const ezSplitItemCss = ".box_split-item{background-color:var(--background--xlight);padding:var(--space--nano);width:100%;height:100%;border-radius:var(--border--radius-medium);box-shadow:var(--shadow)}";
8
+ const ezSplitItemCss = "ez-split-item{--snk-grid-min-height:0;--ez-grid--min-height:0}.box_split-item{background-color:var(--background--xlight);width:100%;height:100%;border-radius:var(--border--radius-medium);box-shadow:var(--shadow);flex-direction:column;overflow:hidden;display:flex;padding:var(--space--nano)}.box_split-item>.ez-split-item--content{overflow:auto}.expanded__item{position:absolute;z-index:var(--more-visible);top:0;left:0;width:100%;height:100%}.ez-split-item--header{display:flex;align-items:center;justify-content:space-between}.ez-split-item--header-buttons{display:flex;align-items:center}.ez-split-item--content{display:block;height:100%}";
4
9
 
5
10
  const SplitItem = class {
6
11
  constructor(hostRef) {
7
12
  registerInstance(this, hostRef);
13
+ this.label = undefined;
14
+ this.enableExpand = true;
15
+ this._expanded = false;
16
+ this.size = undefined;
17
+ }
18
+ /**
19
+ * Alterna a visibilidade do painel.
20
+ */
21
+ toggleExpandItem() {
22
+ this._expanded = !this._expanded;
23
+ }
24
+ componentDidLoad() {
25
+ CSSVarsUtils.applyVarsGrid(this._element, this._slot.children[0]);
8
26
  }
9
27
  render() {
10
- return (h(Host, { class: 'box_split-item' }));
28
+ return (h(Host, { class: `box_split-item ${this._expanded ? 'expanded__item' : ''}`, ref: el => (this._element = el) }, h("div", { class: "ez-split-item--header" }, h("div", null, this.label && (h("div", { class: "ez-margin--small" }, h("h3", { class: " ez-title ez-title--small" }, this.label)))), h("div", { class: "ez-split-item--header-buttons" }, this.enableExpand && (h("ez-button", { size: "medium", mode: "icon", iconName: "expand", class: 'ez-button--tertiary', onClick: () => this.toggleExpandItem(), title: this._expanded ? 'Resumir' : 'Expandir' })), h("slot", { name: "rightButtons" }))), h("div", { class: "ez-split-item--content", ref: el => (this._slot = el) }, h("slot", null))));
11
29
  }
12
30
  };
13
31
  SplitItem.style = ezSplitItemCss;