@sankhyalabs/ezui 5.22.0-dev.10 → 5.22.0-dev.100

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 (357) hide show
  1. package/dist/cjs/{CSSVarsUtils-10c9d5b4.js → CSSVarsUtils-f20973d1.js} +1 -0
  2. package/dist/cjs/DataBinder-e92314c2.js +445 -0
  3. package/dist/cjs/FocusResolver-885f2173.js +35 -0
  4. package/dist/cjs/ez-actions-button.cjs.entry.js +4 -3
  5. package/dist/cjs/ez-badge.cjs.entry.js +14 -2
  6. package/dist/cjs/ez-button.cjs.entry.js +11 -5
  7. package/dist/cjs/ez-card-item_2.cjs.entry.js +1485 -0
  8. package/dist/cjs/ez-check.cjs.entry.js +1 -1
  9. package/dist/cjs/ez-chip.cjs.entry.js +1 -1
  10. package/dist/cjs/ez-collapsible-box.cjs.entry.js +1 -1
  11. package/dist/cjs/ez-combo-box-list_3.cjs.entry.js +387 -0
  12. package/dist/cjs/ez-combo-box.cjs.entry.js +82 -155
  13. package/dist/cjs/ez-date-input.cjs.entry.js +15 -19
  14. package/dist/cjs/ez-date-time-input.cjs.entry.js +14 -20
  15. package/dist/cjs/ez-dialog.cjs.entry.js +14 -7
  16. package/dist/cjs/ez-double-list.cjs.entry.js +287 -0
  17. package/dist/cjs/{ez-dropdown.cjs.entry.js → ez-dropdown_2.cjs.entry.js} +75 -8
  18. package/dist/cjs/ez-filter-input.cjs.entry.js +129 -0
  19. package/dist/cjs/ez-form-view.cjs.entry.js +26 -20
  20. package/dist/cjs/ez-form.cjs.entry.js +6 -325
  21. package/dist/cjs/ez-grid.cjs.entry.js +15067 -69836
  22. package/dist/cjs/ez-icon.cjs.entry.js +1 -1
  23. package/dist/cjs/ez-list.cjs.entry.js +258 -211
  24. package/dist/cjs/ez-modal-container.cjs.entry.js +2 -2
  25. package/dist/cjs/ez-modal.cjs.entry.js +12 -3
  26. package/dist/cjs/ez-multi-selection-list.cjs.entry.js +2 -2
  27. package/dist/cjs/ez-number-input.cjs.entry.js +15 -3
  28. package/dist/cjs/ez-popover-plus_3.cjs.entry.js +198 -0
  29. package/dist/cjs/ez-popup.cjs.entry.js +24 -2
  30. package/dist/cjs/ez-scroller_2.cjs.entry.js +3 -3
  31. package/dist/cjs/ez-search.cjs.entry.js +119 -188
  32. package/dist/cjs/ez-sidebar-navigator.cjs.entry.js +1 -1
  33. package/dist/cjs/ez-split-button.cjs.entry.js +2 -2
  34. package/dist/cjs/ez-split-item.cjs.entry.js +6 -3
  35. package/dist/cjs/ez-split-panel.cjs.entry.js +68 -6
  36. package/dist/cjs/ez-text-area.cjs.entry.js +68 -6
  37. package/dist/cjs/ez-text-input.cjs.entry.js +152 -16
  38. package/dist/cjs/ez-time-input.cjs.entry.js +7 -1
  39. package/dist/cjs/ez-tooltip.cjs.entry.js +55 -0
  40. package/dist/cjs/ez-tree.cjs.entry.js +5 -4
  41. package/dist/cjs/ezListHelper-0d3970b4.js +90 -0
  42. package/dist/cjs/ezui.cjs.js +1 -1
  43. package/dist/cjs/filter-column.cjs.entry.js +10 -47
  44. package/dist/cjs/index-a7b0c73d.js +22 -10
  45. package/dist/cjs/loader.cjs.js +1 -1
  46. package/dist/cjs/searchFormatters-b7e1ed1e.js +23 -0
  47. package/dist/collection/collection-manifest.json +8 -2
  48. package/dist/collection/components/ez-actions-button/ez-actions-button.js +3 -2
  49. package/dist/collection/components/ez-badge/ez-badge.css +12 -1
  50. package/dist/collection/components/ez-badge/ez-badge.js +31 -1
  51. package/dist/collection/components/ez-button/ez-button.css +24 -14
  52. package/dist/collection/components/ez-button/ez-button.js +12 -6
  53. package/dist/collection/components/ez-card-item/ez-card-item.css +58 -10
  54. package/dist/collection/components/ez-card-item/ez-card-item.js +30 -3
  55. package/dist/collection/components/ez-check/ez-check.css +1 -6
  56. package/dist/collection/components/ez-chip/ez-chip.css +5 -1
  57. package/dist/collection/components/ez-collapsible-box/ez-collapsible-box.css +2 -2
  58. package/dist/collection/components/ez-combo-box/ez-combo-box-list/ez-combo-box-list.css +205 -0
  59. package/dist/collection/components/ez-combo-box/ez-combo-box-list/ez-combo-box-list.js +426 -0
  60. package/dist/collection/components/ez-combo-box/ez-combo-box.css +8 -246
  61. package/dist/collection/components/ez-combo-box/ez-combo-box.js +129 -166
  62. package/dist/collection/components/ez-date-input/ez-date-input.css +1 -1
  63. package/dist/collection/components/ez-date-input/ez-date-input.js +40 -19
  64. package/dist/collection/components/ez-date-time-input/ez-date-time-input.css +1 -1
  65. package/dist/collection/components/ez-date-time-input/ez-date-time-input.js +39 -20
  66. package/dist/collection/components/ez-dialog/ez-dialog.css +3 -3
  67. package/dist/collection/components/ez-dialog/ez-dialog.js +14 -16
  68. package/dist/collection/components/ez-double-list/doubleListHelper.js +82 -0
  69. package/dist/collection/components/ez-double-list/ez-double-list.css +62 -0
  70. package/dist/collection/components/ez-double-list/ez-double-list.js +440 -0
  71. package/dist/collection/components/ez-dropdown/ez-dropdown.js +33 -8
  72. package/dist/collection/components/ez-filter-input/ez-filter-input.css +1 -1
  73. package/dist/collection/components/ez-filter-input/ez-filter-input.js +35 -4
  74. package/dist/collection/components/ez-form/ez-form.js +1 -0
  75. package/dist/collection/components/ez-form-view/custom-input/ez-custom-form-input.js +49 -6
  76. package/dist/collection/components/ez-form-view/ez-form-view.css +5 -2
  77. package/dist/collection/components/ez-form-view/fieldbuilder/FieldBuilder.js +2 -1
  78. package/dist/collection/components/ez-form-view/fieldbuilder/templates/CheckBox.tpl.js +1 -1
  79. package/dist/collection/components/ez-form-view/fieldbuilder/templates/ComboBox.tpl.js +1 -1
  80. package/dist/collection/components/ez-form-view/fieldbuilder/templates/DateInput.tpl.js +8 -4
  81. package/dist/collection/components/ez-form-view/fieldbuilder/templates/FileInput.tpl.js +1 -1
  82. package/dist/collection/components/ez-form-view/fieldbuilder/templates/NumberInput.tpl.js +1 -1
  83. package/dist/collection/components/ez-form-view/fieldbuilder/templates/SearchInput.tpl.js +1 -1
  84. package/dist/collection/components/ez-form-view/fieldbuilder/templates/TextArea.tpl.js +1 -1
  85. package/dist/collection/components/ez-form-view/fieldbuilder/templates/TextInput.tpl.js +2 -2
  86. package/dist/collection/components/ez-grid/controller/ag-grid/AgGridController.js +297 -63
  87. package/dist/collection/components/ez-grid/controller/ag-grid/DataSource.js +151 -31
  88. package/dist/collection/components/ez-grid/controller/ag-grid/DataSourceInterceptor.js +2 -1
  89. package/dist/collection/components/ez-grid/controller/ag-grid/GridEditionManager.js +219 -42
  90. package/dist/collection/components/ez-grid/controller/ag-grid/components/EzGridCustomCellEditor.js +16 -0
  91. package/dist/collection/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.js +1 -1
  92. package/dist/collection/components/ez-grid/controller/ag-grid/editor/EzCellEditor.js +8 -0
  93. package/dist/collection/components/ez-grid/controller/ag-grid/editor/templates/ComboBox.tpl.js +2 -0
  94. package/dist/collection/components/ez-grid/controller/ag-grid/editor/templates/DateInput.tpl.js +1 -0
  95. package/dist/collection/components/ez-grid/controller/ag-grid/editor/templates/NumberInput.tpl.js +1 -0
  96. package/dist/collection/components/ez-grid/controller/ag-grid/editor/templates/Search.tpl.js +8 -1
  97. package/dist/collection/components/ez-grid/controller/ag-grid/editor/templates/TextInput.tpl.js +4 -1
  98. package/dist/collection/components/ez-grid/controller/ag-grid/test/constants/GridEditionMock.js +2 -0
  99. package/dist/collection/components/ez-grid/ez-grid.css +95 -10
  100. package/dist/collection/components/ez-grid/ez-grid.js +375 -12
  101. package/dist/collection/components/ez-grid/subcomponents/filter-column.css +4 -0
  102. package/dist/collection/components/ez-grid/subcomponents/filter-column.js +9 -46
  103. package/dist/collection/components/ez-grid/utils/ColumnFilterManager.js +7 -54
  104. package/dist/collection/components/ez-grid/utils/InMemoryFilterColumnDataSource.js +20 -4
  105. package/dist/collection/components/ez-icon/ez-icon.css +156 -149
  106. package/dist/collection/components/ez-list/ez-list.css +5 -4
  107. package/dist/collection/components/ez-list/ez-list.js +301 -212
  108. package/dist/collection/components/ez-list/ezListHelper.js +85 -0
  109. package/dist/collection/components/ez-modal/ez-modal.css +7 -2
  110. package/dist/collection/components/ez-modal/ez-modal.js +13 -4
  111. package/dist/collection/components/ez-modal-container/ez-modal-container.css +1 -0
  112. package/dist/collection/components/ez-modal-container/ez-modal-container.js +1 -1
  113. package/dist/collection/components/ez-multi-selection-list/ez-multi-selection-list.css +3 -3
  114. package/dist/collection/components/ez-multi-selection-list/ez-multi-selection-list.js +1 -1
  115. package/dist/collection/components/ez-number-input/ez-number-input.css +8 -0
  116. package/dist/collection/components/ez-number-input/ez-number-input.js +49 -1
  117. package/dist/collection/components/ez-popover-plus/ez-popover-plus.css +3 -0
  118. package/dist/collection/components/ez-popover-plus/ez-popover-plus.js +432 -0
  119. package/dist/collection/components/ez-popover-plus/subcomponent/ez-popover-core.css +67 -0
  120. package/dist/collection/components/ez-popover-plus/subcomponent/ez-popover-core.js +528 -0
  121. package/dist/collection/components/ez-popup/ez-popup.css +8 -3
  122. package/dist/collection/components/ez-popup/ez-popup.js +43 -3
  123. package/dist/collection/components/ez-scroller/ez-scroller.css +4 -0
  124. package/dist/collection/components/ez-search/ez-search.css +2 -210
  125. package/dist/collection/components/ez-search/ez-search.js +204 -203
  126. package/dist/collection/components/ez-search/subcomponent/search-list/search-list.css +227 -0
  127. package/dist/collection/components/ez-search/subcomponent/search-list/search-list.js +289 -0
  128. package/dist/collection/components/ez-search/utils/searchFormatters.js +18 -0
  129. package/dist/collection/components/ez-sidebar-button/ez-sidebar-button.css +3 -0
  130. package/dist/collection/components/ez-sidebar-button/ez-sidebar-button.js +1 -1
  131. package/dist/collection/components/ez-sidebar-navigator/ez-sidebar-navigator.css +4 -1
  132. package/dist/collection/components/ez-skeleton/ez-skeleton.css +54 -34
  133. package/dist/collection/components/ez-split-button/ez-split-button.css +52 -14
  134. package/dist/collection/components/ez-split-button/ez-split-button.js +3 -3
  135. package/dist/collection/components/ez-split-panel/ez-split-panel.css +15 -0
  136. package/dist/collection/components/ez-split-panel/ez-split-panel.js +106 -5
  137. package/dist/collection/components/ez-split-panel/interfaces/IPanelSizeInfo.js +1 -0
  138. package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.css +14 -2
  139. package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.js +22 -1
  140. package/dist/collection/components/ez-text-area/ez-text-area.css +78 -29
  141. package/dist/collection/components/ez-text-area/ez-text-area.js +104 -4
  142. package/dist/collection/components/ez-text-input/ez-text-input.css +106 -91
  143. package/dist/collection/components/ez-text-input/ez-text-input.js +166 -15
  144. package/dist/collection/components/ez-time-input/ez-time-input.js +24 -0
  145. package/dist/collection/components/ez-tooltip/ez-tooltip.css +20 -0
  146. package/dist/collection/components/ez-tooltip/ez-tooltip.js +116 -0
  147. package/dist/collection/components/ez-tree/ez-tree.js +21 -1
  148. package/dist/collection/components/ez-tree/subcomponents/TreeItem.js +3 -3
  149. package/dist/collection/sw.js +46 -0
  150. package/dist/collection/utils/CSSVarsUtils.js +1 -0
  151. package/dist/collection/utils/FocusResolver.js +31 -0
  152. package/dist/collection/utils/ResponsiveInputUtils.js +26 -0
  153. package/dist/collection/utils/form/DataBinder.js +22 -7
  154. package/dist/collection/utils/form/FormMetadata.js +2 -1
  155. package/dist/collection/utils/interfaces/AbstractFieldMetadata.js +1 -1
  156. package/dist/collection/utils/validators/recordvalidator/IInvalidCells.js +1 -0
  157. package/dist/collection/utils/validators/recordvalidator/RecordValidationProcessor.js +7 -1
  158. package/dist/custom-elements/index.d.ts +36 -0
  159. package/dist/custom-elements/index.js +18612 -70878
  160. package/dist/esm/{CSSVarsUtils-71ce76be.js → CSSVarsUtils-acba92d7.js} +1 -0
  161. package/dist/esm/DataBinder-9c877244.js +441 -0
  162. package/dist/esm/FocusResolver-1ccbf850.js +33 -0
  163. package/dist/esm/ez-actions-button.entry.js +4 -3
  164. package/dist/esm/ez-badge.entry.js +14 -2
  165. package/dist/esm/ez-button.entry.js +11 -5
  166. package/dist/esm/ez-card-item_2.entry.js +1480 -0
  167. package/dist/esm/ez-check.entry.js +1 -1
  168. package/dist/esm/ez-chip.entry.js +1 -1
  169. package/dist/esm/ez-collapsible-box.entry.js +1 -1
  170. package/dist/esm/ez-combo-box-list_3.entry.js +381 -0
  171. package/dist/esm/ez-combo-box.entry.js +83 -156
  172. package/dist/esm/ez-date-input.entry.js +15 -19
  173. package/dist/esm/ez-date-time-input.entry.js +14 -20
  174. package/dist/esm/ez-dialog.entry.js +15 -8
  175. package/dist/esm/ez-double-list.entry.js +283 -0
  176. package/dist/esm/{ez-dropdown.entry.js → ez-dropdown_2.entry.js} +75 -9
  177. package/dist/esm/ez-filter-input.entry.js +125 -0
  178. package/dist/esm/ez-form-view.entry.js +26 -20
  179. package/dist/esm/ez-form.entry.js +5 -324
  180. package/dist/esm/ez-grid.entry.js +14989 -69758
  181. package/dist/esm/ez-icon.entry.js +1 -1
  182. package/dist/esm/ez-list.entry.js +258 -211
  183. package/dist/esm/ez-modal-container.entry.js +2 -2
  184. package/dist/esm/ez-modal.entry.js +12 -3
  185. package/dist/esm/ez-multi-selection-list.entry.js +2 -2
  186. package/dist/esm/ez-number-input.entry.js +15 -3
  187. package/dist/esm/ez-popover-plus_3.entry.js +192 -0
  188. package/dist/esm/ez-popup.entry.js +24 -2
  189. package/dist/esm/ez-scroller_2.entry.js +3 -3
  190. package/dist/esm/ez-search.entry.js +120 -189
  191. package/dist/esm/ez-sidebar-navigator.entry.js +1 -1
  192. package/dist/esm/ez-split-button.entry.js +2 -2
  193. package/dist/esm/ez-split-item.entry.js +6 -3
  194. package/dist/esm/ez-split-panel.entry.js +69 -7
  195. package/dist/esm/ez-text-area.entry.js +68 -6
  196. package/dist/esm/ez-text-input.entry.js +152 -16
  197. package/dist/esm/ez-time-input.entry.js +7 -1
  198. package/dist/esm/ez-tooltip.entry.js +51 -0
  199. package/dist/esm/ez-tree.entry.js +5 -4
  200. package/dist/esm/ezListHelper-00fb9b8d.js +87 -0
  201. package/dist/esm/ezui.js +1 -1
  202. package/dist/esm/filter-column.entry.js +10 -47
  203. package/dist/esm/index-baa5e267.js +22 -10
  204. package/dist/esm/loader.js +1 -1
  205. package/dist/esm/searchFormatters-8229207e.js +20 -0
  206. package/dist/ezui/ezui.esm.js +1 -1
  207. package/dist/ezui/p-0fa52b0f.entry.js +1 -0
  208. package/dist/ezui/p-17de16e5.entry.js +1 -0
  209. package/dist/ezui/p-17eabf46.entry.js +1 -0
  210. package/dist/ezui/p-1ad6c61b.entry.js +1 -0
  211. package/dist/ezui/p-20c024f7.entry.js +1 -0
  212. package/dist/ezui/p-20cb13fa.entry.js +1 -0
  213. package/dist/ezui/p-23b6128c.entry.js +1 -0
  214. package/dist/ezui/p-2872fd16.entry.js +1 -0
  215. package/dist/ezui/p-288631d1.entry.js +1 -0
  216. package/dist/ezui/p-2f45506d.entry.js +1 -0
  217. package/dist/ezui/p-3195a7a7.entry.js +1 -0
  218. package/dist/ezui/p-31b71e50.entry.js +1 -0
  219. package/dist/ezui/p-31da1b57.entry.js +1 -0
  220. package/dist/ezui/p-40a60148.js +1 -0
  221. package/dist/ezui/p-556468d9.entry.js +1 -0
  222. package/dist/ezui/p-56fe5341.entry.js +1 -0
  223. package/dist/ezui/p-5aca7386.entry.js +1 -0
  224. package/dist/ezui/p-6cdd3e0a.entry.js +1 -0
  225. package/dist/ezui/p-788467fe.entry.js +1 -0
  226. package/dist/ezui/p-7e677b7b.entry.js +1 -0
  227. package/dist/ezui/{p-bf79aaa1.entry.js → p-7fdd479f.entry.js} +1 -1
  228. package/dist/ezui/p-80dfc50b.js +1 -0
  229. package/dist/ezui/p-a4cee65d.entry.js +1 -0
  230. package/dist/ezui/p-acddfb2e.js +1 -0
  231. package/dist/ezui/p-b7706b43.entry.js +1 -0
  232. package/dist/ezui/p-c1527804.entry.js +1 -0
  233. package/dist/ezui/p-c297aa52.entry.js +1 -0
  234. package/dist/ezui/p-cb1535f7.entry.js +1 -0
  235. package/dist/ezui/p-cb5cd243.entry.js +309 -0
  236. package/dist/ezui/p-cf87aacb.entry.js +1 -0
  237. package/dist/ezui/p-da1b4a38.entry.js +1 -0
  238. package/dist/ezui/p-dc628ed3.js +1 -0
  239. package/dist/ezui/p-dc73e1fe.entry.js +1 -0
  240. package/dist/ezui/p-dcf3c8e5.entry.js +1 -0
  241. package/dist/ezui/{p-17be134a.entry.js → p-e06a9886.entry.js} +1 -1
  242. package/dist/ezui/{p-84e439b9.entry.js → p-e347df9c.entry.js} +1 -1
  243. package/dist/ezui/p-e6a9041d.entry.js +1 -0
  244. package/dist/ezui/p-e75c7a23.entry.js +1 -0
  245. package/dist/ezui/p-ea54d056.entry.js +1 -0
  246. package/dist/ezui/p-ec7db713.js +1 -0
  247. package/dist/ezui/p-f5931caa.entry.js +1 -0
  248. package/dist/ezui/p-fa6732f2.entry.js +1 -0
  249. package/dist/ezui/p-fd0a19d6.entry.js +1 -0
  250. package/dist/types/components/ez-badge/ez-badge.d.ts +5 -0
  251. package/dist/types/components/ez-button/ez-button.d.ts +2 -1
  252. package/dist/types/components/ez-calendar/ez-calendar.d.ts +3 -3
  253. package/dist/types/components/ez-card-item/ez-card-item.d.ts +5 -0
  254. package/dist/types/components/ez-combo-box/ez-combo-box-list/ez-combo-box-list.d.ts +104 -0
  255. package/dist/types/components/ez-combo-box/ez-combo-box.d.ts +17 -15
  256. package/dist/types/components/ez-date-input/ez-date-input.d.ts +8 -3
  257. package/dist/types/components/ez-date-time-input/ez-date-time-input.d.ts +8 -3
  258. package/dist/types/components/ez-dialog/ez-dialog.d.ts +2 -1
  259. package/dist/types/components/ez-double-list/doubleListHelper.d.ts +10 -0
  260. package/dist/types/components/ez-double-list/ez-double-list.d.ts +87 -0
  261. package/dist/types/components/ez-dropdown/ez-dropdown.d.ts +4 -0
  262. package/dist/types/components/ez-dropdown/structure/DropdownItem.d.ts +1 -1
  263. package/dist/types/components/ez-filter-input/ez-filter-input.d.ts +6 -1
  264. package/dist/types/components/ez-form-view/custom-input/ez-custom-form-input.d.ts +7 -1
  265. package/dist/types/components/ez-form-view/fieldbuilder/templates/DateInput.tpl.d.ts +2 -1
  266. package/dist/types/components/ez-form-view/fieldbuilder/templates/TextInput.tpl.d.ts +1 -1
  267. package/dist/types/components/ez-grid/controller/EzGridController.d.ts +71 -4
  268. package/dist/types/components/ez-grid/controller/ag-grid/AgGridController.d.ts +37 -4
  269. package/dist/types/components/ez-grid/controller/ag-grid/DataSource.d.ts +25 -2
  270. package/dist/types/components/ez-grid/controller/ag-grid/GridEditionManager.d.ts +33 -7
  271. package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomCellEditor.d.ts +4 -1
  272. package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomCellRender.d.ts +1 -1
  273. package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.d.ts +1 -1
  274. package/dist/types/components/ez-grid/controller/ag-grid/components/cellRendererStatus.d.ts +1 -1
  275. package/dist/types/components/ez-grid/controller/ag-grid/components/selectionHeader.d.ts +1 -1
  276. package/dist/types/components/ez-grid/controller/ag-grid/editor/EzCellEditor.d.ts +2 -1
  277. package/dist/types/components/ez-grid/controller/ag-grid/editor/EzCellRender.d.ts +1 -1
  278. package/dist/types/components/ez-grid/controller/ag-grid/editor/IUICellEditor.d.ts +1 -0
  279. package/dist/types/components/ez-grid/controller/ag-grid/mock/Server.d.ts +1 -1
  280. package/dist/types/components/ez-grid/ez-grid.d.ts +59 -1
  281. package/dist/types/components/ez-grid/subcomponents/filter-column.d.ts +0 -11
  282. package/dist/types/components/ez-grid/utils/ColumnFilterManager.d.ts +1 -1
  283. package/dist/types/components/ez-grid/utils/InMemoryFilterColumnDataSource.d.ts +3 -0
  284. package/dist/types/components/ez-list/ez-list.d.ts +23 -2
  285. package/dist/types/components/ez-list/ezListHelper.d.ts +20 -0
  286. package/dist/types/components/ez-modal/ez-modal.d.ts +2 -1
  287. package/dist/types/components/ez-number-input/ez-number-input.d.ts +8 -0
  288. package/dist/types/components/ez-popover-plus/ez-popover-plus.d.ts +76 -0
  289. package/dist/types/components/ez-popover-plus/subcomponent/ez-popover-core.d.ts +91 -0
  290. package/dist/types/components/ez-popup/ez-popup.d.ts +8 -1
  291. package/dist/types/components/ez-search/ez-search.d.ts +32 -18
  292. package/dist/types/components/ez-search/subcomponent/search-list/search-list.d.ts +23 -0
  293. package/dist/types/components/ez-search/utils/searchFormatters.d.ts +2 -0
  294. package/dist/types/components/ez-split-button/ez-split-button.d.ts +1 -1
  295. package/dist/types/components/ez-split-panel/ez-split-panel.d.ts +11 -0
  296. package/dist/types/components/ez-split-panel/interfaces/IPanelSizeInfo.d.ts +9 -0
  297. package/dist/types/components/ez-split-panel/structure/item/ez-split-item.d.ts +5 -0
  298. package/dist/types/components/ez-text-area/ez-text-area.d.ts +17 -0
  299. package/dist/types/components/ez-text-input/ez-text-input.d.ts +24 -2
  300. package/dist/types/components/ez-time-input/ez-time-input.d.ts +4 -0
  301. package/dist/types/components/ez-tooltip/ez-tooltip.d.ts +21 -0
  302. package/dist/types/components/ez-tree/ez-tree.d.ts +4 -0
  303. package/dist/types/components/ez-tree/interfaces/ITreeItem.d.ts +1 -0
  304. package/dist/types/components/ez-tree/subcomponents/TreeItem.d.ts +1 -0
  305. package/dist/types/components.d.ts +793 -29
  306. package/dist/types/utils/FocusResolver.d.ts +5 -0
  307. package/dist/types/utils/ResponsiveInputUtils.d.ts +6 -0
  308. package/dist/types/utils/customEditor/interfaces/ICustomEditor.d.ts +2 -0
  309. package/dist/types/utils/form/DataBinder.d.ts +3 -0
  310. package/dist/types/utils/validators/recordvalidator/IInvalidCells.d.ts +5 -0
  311. package/dist/types/utils/validators/recordvalidator/RecordValidationProcessor.d.ts +1 -1
  312. package/package.json +11 -3
  313. package/react/components.d.ts +6 -0
  314. package/react/components.js +6 -0
  315. package/react/components.js.map +1 -1
  316. package/dist/cjs/RecordValidationProcessor-4c893e04.js +0 -102
  317. package/dist/cjs/ez-card-item_3.cjs.entry.js +0 -183
  318. package/dist/cjs/ez-custom-form-input_2.cjs.entry.js +0 -206
  319. package/dist/cjs/ez-skeleton.cjs.entry.js +0 -67
  320. package/dist/esm/RecordValidationProcessor-b00b8b77.js +0 -99
  321. package/dist/esm/ez-card-item_3.entry.js +0 -177
  322. package/dist/esm/ez-custom-form-input_2.entry.js +0 -201
  323. package/dist/esm/ez-skeleton.entry.js +0 -63
  324. package/dist/ezui/p-04f24913.js +0 -1
  325. package/dist/ezui/p-072e6347.entry.js +0 -1
  326. package/dist/ezui/p-1285c902.entry.js +0 -1
  327. package/dist/ezui/p-13d2fe2d.entry.js +0 -1
  328. package/dist/ezui/p-2097d0cf.entry.js +0 -1
  329. package/dist/ezui/p-32e553e5.entry.js +0 -304
  330. package/dist/ezui/p-34b6916c.entry.js +0 -1
  331. package/dist/ezui/p-3b4eeeb6.entry.js +0 -1
  332. package/dist/ezui/p-3faa2b46.entry.js +0 -1
  333. package/dist/ezui/p-42533ea4.entry.js +0 -1
  334. package/dist/ezui/p-49456b34.entry.js +0 -1
  335. package/dist/ezui/p-4d5235f1.entry.js +0 -1
  336. package/dist/ezui/p-5bd5e68f.entry.js +0 -1
  337. package/dist/ezui/p-650e4b6d.entry.js +0 -1
  338. package/dist/ezui/p-784fe207.entry.js +0 -1
  339. package/dist/ezui/p-7922142b.entry.js +0 -1
  340. package/dist/ezui/p-7af81663.entry.js +0 -1
  341. package/dist/ezui/p-7bc07c31.entry.js +0 -1
  342. package/dist/ezui/p-85c8baae.entry.js +0 -1
  343. package/dist/ezui/p-8888d9ed.entry.js +0 -1
  344. package/dist/ezui/p-9050d2cd.entry.js +0 -1
  345. package/dist/ezui/p-922ac38b.entry.js +0 -1
  346. package/dist/ezui/p-9e11fc7b.js +0 -1
  347. package/dist/ezui/p-a31b9c90.entry.js +0 -1
  348. package/dist/ezui/p-aba3da00.entry.js +0 -1
  349. package/dist/ezui/p-af95cd16.entry.js +0 -1
  350. package/dist/ezui/p-bae4e180.entry.js +0 -1
  351. package/dist/ezui/p-baf80b13.entry.js +0 -1
  352. package/dist/ezui/p-bcb53f27.entry.js +0 -1
  353. package/dist/ezui/p-cdc472cc.entry.js +0 -1
  354. package/dist/ezui/p-d9401ea0.entry.js +0 -1
  355. package/dist/ezui/p-e85c48d7.entry.js +0 -1
  356. package/dist/ezui/p-ecc2c1ec.entry.js +0 -1
  357. package/dist/ezui/p-fcf0acce.entry.js +0 -1
@@ -1,102 +0,0 @@
1
- 'use strict';
2
-
3
- const core = require('@sankhyalabs/core');
4
- const ApplicationUtils = require('./ApplicationUtils-c9d1205c.js');
5
-
6
- const buildFieldMetadata = (descriptor, config) => {
7
- let { name, label, group } = Object.assign({}, config);
8
- let { readOnly, required } = Object.assign({}, config);
9
- let props;
10
- let userInterface;
11
- if (descriptor) {
12
- label = label || descriptor.label;
13
- name = name || descriptor.name;
14
- required = descriptor.required || (config === null || config === void 0 ? void 0 : config.required);
15
- readOnly = descriptor.readOnly || (config === null || config === void 0 ? void 0 : config.readOnly);
16
- props = descriptor.properties;
17
- userInterface = descriptor.userInterface;
18
- }
19
- return {
20
- name, label, group,
21
- readOnly, required,
22
- props,
23
- userInterface: userInterface || core.UserInterface.SHORTTEXT
24
- };
25
- };
26
-
27
- class RecordValidationProcessor {
28
- constructor(dataUnit, validationSource, validator) {
29
- this._dataUnit = dataUnit;
30
- this._validationSource = validationSource;
31
- this._validator = validator;
32
- }
33
- validate() {
34
- return new Promise((accept, reject) => {
35
- const records = this._dataUnit.getModifiedRecords();
36
- for (let i = 0; i < records.length; i++) {
37
- const record = records[i];
38
- const invalidResults = [];
39
- let validationResult = this.validateRequired(record);
40
- if (validationResult && !validationResult.isValid) {
41
- invalidResults.push(validationResult);
42
- }
43
- if (this._validator) {
44
- validationResult = this._validator.validateRecord(record);
45
- if (validationResult && !validationResult.isValid) {
46
- invalidResults.push(validationResult);
47
- }
48
- }
49
- if (invalidResults.length > 0) {
50
- this.processValidationResult(invalidResults, record.__record__id__);
51
- reject();
52
- break;
53
- }
54
- }
55
- return accept();
56
- });
57
- }
58
- validateRequired(record) {
59
- const requiredFields = this._validationSource.getRequiredFields();
60
- const invalidFields = [];
61
- new Set(requiredFields).forEach(field => {
62
- const value = record[field];
63
- if (value == undefined || value === "") {
64
- const errorMessage = this._validationSource.getMessageForField(field, record.__record__id__);
65
- if (errorMessage) {
66
- invalidFields.push({ name: field, message: errorMessage });
67
- }
68
- else {
69
- invalidFields.push({ name: field, message: "Essa informação é obrigatória" });
70
- }
71
- }
72
- });
73
- if (invalidFields.length > 0) {
74
- return { isValid: false, invalidFields, infoMessage: "Há pelo menos um campo obrigatório não preenchido." };
75
- }
76
- return undefined;
77
- }
78
- processValidationResult(validationResult, recordId) {
79
- validationResult.forEach(invalidResult => {
80
- const invalidFields = invalidResult.invalidFields;
81
- if (invalidFields) {
82
- invalidFields.forEach(field => {
83
- this.markAsInvalid(field, recordId);
84
- });
85
- }
86
- if (invalidResult.infoMessage) {
87
- ApplicationUtils.ApplicationUtils.info(invalidResult.infoMessage);
88
- }
89
- if (invalidResult.errorMessage) {
90
- const { errorTitle, errorMessage } = invalidResult;
91
- ApplicationUtils.ApplicationUtils.error(errorTitle, errorMessage);
92
- }
93
- });
94
- }
95
- markAsInvalid(field, recordId) {
96
- this._dataUnit.setInvalidField(field.name, field.message, recordId);
97
- this._validationSource.markAsInvalid(field, recordId);
98
- }
99
- }
100
-
101
- exports.RecordValidationProcessor = RecordValidationProcessor;
102
- exports.buildFieldMetadata = buildFieldMetadata;
@@ -1,183 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- const index = require('./index-a7b0c73d.js');
6
- const core = require('@sankhyalabs/core');
7
- const CSSVarsUtils = require('./CSSVarsUtils-10c9d5b4.js');
8
-
9
- const ezCardItemCss = ":host {\n /*@doc Define o tamanho da fonte do componente.*/\n --ez-card-item--font-size: var(--text--medium, 14px);\n\n /*@doc Define a família da fonte do componente.*/\n --ez-card-item--font-family: var(--font-pattern, Arial);\n\n /*@doc Define o peso da fonte do componente.*/\n --ez-card-item--font-weight: var(--text-weight--medium, 400);\n\n /*@doc Define o peso da fonte do title do componente.*/\n --ez-card-item--font-weight-large: var(--text-weight--large, 600);\n\n /*@doc Define a cor da fonte do componente.*/\n --ez-card-item--color: var(--title--primary, #2B3A54);\n\n /*@doc Define a cor da fonte da key do componente.*/\n --ez-card-item__key--color: var(--text--primary, #626e82);\n\n /*@doc Define a cor da fonte do label do detalhe do componente.*/\n --ez-card-item__detail-label--color: var(--text--secondary, #A2ABB9);\n\n /*@doc Define o espaçamento inferior dos detalhes do componente.*/\n --ez-card-item__detail--padding-bottom: var(--space--extra-small, 3px);\n\n /*@doc Define o espaçamento inferior do title do componente.*/\n --ez-card-item__title--padding-bottom: var(--space--extra-small, 3px);\n\n /*@doc Define a cor do highlight / marcação nos textos do componente.*/\n --ez-card-item__highlight--color: var(--color--primary-300, #E2F4EF);\n\n width: 100%;\n display: flex;\n cursor: pointer;\n}\n\n.card-item {\n display: flex;\n flex-direction: column;\n width: 100%;\n cursor: pointer;\n padding: 12px;\n z-index: 0;\n position: relative;\n container-type: inline-size;\n container-name: box;\n white-space: pre-line;\n}\n\n.card-item:hover {\n background: #F0F3F7;\n border-radius: 12px;\n}\n\n.card-item__title {\n display: flex;\n align-items: center;\n line-height: 18px;\n cursor: pointer;\n\n /*public*/\n font-size: var(--ez-card-item--font-size);\n font-family: var(--ez-card-item--font-family);\n font-weight: var(--ez-card-item--font-weight-large);\n color: var(--ez-card-item--color);\n padding-bottom: var(--ez-card-item__title--padding-bottom);\n gap: var(--space--small, 6px);\n}\n\n.card-item__key {\n /*public*/\n color: var(--ez-card-item__key--color);\n}\n\n.card-item__details {\n display: flex;\n flex-direction: column;\n cursor: pointer;\n justify-content: space-between;\n width: 100%;\n}\n\n.card-item__details-container__left {\n white-space: pre-line;\n cursor: pointer;\n width: 50%;\n}\n\n.card-item__details-container__right {\n white-space: pre-line;\n width: 50%;\n cursor: pointer;\n}\n\n.card-item__detail:not(:last-child) {\n cursor: pointer;\n white-space: pre-line;\n\n /*public*/\n padding-bottom: var(--ez-card-item__detail--padding-bottom);\n}\n\n.card-item__detail-label {\n cursor: pointer;\n\n /*public*/\n font-size: var(--ez-card-item--font-size);\n font-family: var(--ez-card-item--font-family);\n font-weight: var(--ez-card-item--font-weight);\n color: var(--ez-card-item__detail-label--color);\n}\n\n.card-item__detail-value {\n cursor: pointer;\n line-break: anywhere;\n\n /*public*/\n font-size: var(--ez-card-item--font-size);\n font-family: var(--ez-card-item--font-family);\n font-weight: var(--ez-card-item--font-weight);\n color: var(--ez-card-item--color);\n}\n\n.card-item__highlight {\n position: relative;\n border-radius: 8px;\n z-index: -1;\n\n /*public*/\n background-color: var(--ez-card-item__highlight--color);\n outline: 2px solid var(--ez-card-item__highlight--color);\n box-shadow: -4px 0px 0px 0px var(--ez-card-item__highlight--color), \n 4px 0px 0px 0px var(--ez-card-item__highlight--color);\n}\n\n.card-item__content{\n display: flex;\n align-items: center;\n}\n\n.card-item__details-container{\n display: flex;\n}\n\n.card-item__details-slot{\n margin-left: auto;\n}\n\n@container box (max-width: 550px) {\n .card-item__details {\n flex-direction: column;\n }\n\n .card-item__details-container__left {\n width: 100%;\n }\n \n .card-item__details-container__right {\n width: 100%;\n }\n}\n\n@container box (max-width: 200px) {\n .card-item__title {\n font-size: 10px;\n }\n\n .card-item__detail-label {\n font-size: 10px;\n }\n\n .card-item__detail-value {\n font-size: 10px;\n }\n\n}";
10
-
11
- const EzCardItem = class {
12
- constructor(hostRef) {
13
- index.registerInstance(this, hostRef);
14
- this.ezClick = index.createEvent(this, "ezClick", 7);
15
- this.item = undefined;
16
- this.enableKey = true;
17
- }
18
- componentWillRender() {
19
- this.createDetailList();
20
- }
21
- componentDidLoad() {
22
- var _a, _b;
23
- const dataInfo = { id: core.StringUtils.toCamelCase(((_a = this.item) === null || _a === void 0 ? void 0 : _a.key) || ((_b = this.item) === null || _b === void 0 ? void 0 : _b.title) || "") };
24
- core.ElementIDUtils.addIDInfo(this._element, null, dataInfo);
25
- }
26
- createDetailList() {
27
- var _a, _b, _c;
28
- this._details = { detailsLeft: [], detailsRight: [] };
29
- let cont = 0;
30
- if ((_a = this.item) === null || _a === void 0 ? void 0 : _a.details) {
31
- for (const attribute in this.item.details) {
32
- cont < 3 ?
33
- this._details.detailsLeft.push({ label: attribute, value: (_b = this.item.details[attribute]) === null || _b === void 0 ? void 0 : _b.toString() }) :
34
- this._details.detailsRight.push({ label: attribute, value: (_c = this.item.details[attribute]) === null || _c === void 0 ? void 0 : _c.toString() });
35
- cont++;
36
- }
37
- }
38
- }
39
- buildDetailContent(detail) {
40
- return index.h("div", { class: "card-item__detail" }, index.h("label", { class: "card-item__detail-label" }, detail.label), ": ", index.h("label", { class: "card-item__detail-value", innerHTML: detail.value }));
41
- }
42
- render() {
43
- return (index.h(index.Host, null, this.item &&
44
- index.h("div", { class: "card-item", onClick: () => { this.ezClick.emit(this.item); } }, index.h("div", { class: "ez-row card-item__content" }, index.h("div", { class: "ez-col ez-col--sd-11 card-item__details" }, index.h("label", { class: "card-item__title" }, this.enableKey && (index.h("span", { class: "card-item__key", innerHTML: this.item.key })), index.h("span", { innerHTML: this.item.title })), index.h("div", { class: "card-item__details-container" }, index.h("div", { class: "card-item__details-container__left" }, this._details.detailsLeft.map(detail => {
45
- return this.buildDetailContent(detail);
46
- })), index.h("div", { class: "card-item__details-container__right" }, this._details.detailsRight.map(detail => {
47
- return this.buildDetailContent(detail);
48
- })))), index.h("div", { class: "ez-col ez-col--sd-1 card-item__details-slot" }, index.h("slot", { name: "rightSlot" }))))));
49
- }
50
- get _element() { return index.getElement(this); }
51
- };
52
- EzCardItem.style = ezCardItemCss;
53
-
54
- const ezFilterInputCss = ":host{display:block;width:100%}";
55
-
56
- const EzFilterInput = class {
57
- constructor(hostRef) {
58
- index.registerInstance(this, hostRef);
59
- this.ezChange = index.createEvent(this, "ezChange", 7);
60
- this.ezSearching = index.createEvent(this, "ezSearching", 7);
61
- this.ezFocusIn = index.createEvent(this, "ezFocusIn", 7);
62
- this._searchingText = "";
63
- this.handleFocus = () => {
64
- if (this._searchingText === "") {
65
- this._textInput.value = "";
66
- }
67
- else {
68
- this._textInput.value = this._searchingText;
69
- }
70
- this.ezFocusIn.emit();
71
- };
72
- this.label = undefined;
73
- this.value = undefined;
74
- this.enabled = true;
75
- this.errorMessage = undefined;
76
- this.restrict = undefined;
77
- this.mode = "regular";
78
- this.asyncSearch = false;
79
- this.canShowError = true;
80
- }
81
- observeLabel() {
82
- if (this._textInput) {
83
- this._textInput.label = this.label;
84
- }
85
- }
86
- observeErrorMessage() {
87
- if (this._textInput) {
88
- this._textInput.errorMessage = this.errorMessage;
89
- }
90
- }
91
- observeValue(newValue, oldValue) {
92
- if (this._textInput && newValue != oldValue) {
93
- this._textInput.value = newValue;
94
- this.ezChange.emit(newValue);
95
- }
96
- }
97
- /**
98
- * Aplica o foco no campo.
99
- */
100
- async setFocus() {
101
- this._textInput.setFocus();
102
- }
103
- /**
104
- * Remove o foco do campo.
105
- */
106
- async setBlur() {
107
- this._textInput.setBlur();
108
- }
109
- /**
110
- * Retorna se o conteúdo é inválido.
111
- */
112
- async isInvalid() {
113
- return typeof this.errorMessage === "string" && this.errorMessage.trim() !== "";
114
- }
115
- /**
116
- * Método responsável por setar um novo valor ao campo.
117
- */
118
- async setValue(newValue) {
119
- if (!this.asyncSearch || this._textInput == undefined) {
120
- return;
121
- }
122
- if (newValue !== this.value) {
123
- this.value = newValue;
124
- this._searchingText = "";
125
- }
126
- else {
127
- this._textInput.value = newValue;
128
- }
129
- }
130
- /**
131
- * Método responsável por resetar o valor do campo para o ultimo valor inputado.
132
- */
133
- async endSearch() {
134
- if (!this.asyncSearch || this._textInput == undefined) {
135
- return;
136
- }
137
- if (this._textInput.value !== this.value) {
138
- this._textInput.value = this.value;
139
- }
140
- }
141
- handleChange(evt) {
142
- const newValue = evt.detail;
143
- this.errorMessage = "";
144
- if (this.asyncSearch) {
145
- this._searchingText = newValue;
146
- this.ezSearching.emit(newValue);
147
- }
148
- else if (newValue !== this.value) {
149
- this.value = newValue;
150
- }
151
- }
152
- componentDidLoad() {
153
- CSSVarsUtils.CSSVarsUtils.applyVarsTextInput(this._elem, this._textInput);
154
- }
155
- render() {
156
- core.ElementIDUtils.addIDInfoIfNotExists(this._elem, 'input');
157
- return (index.h("ez-text-input", { "data-element-id": core.ElementIDUtils.getInternalIDInfo("textInput"), ref: elem => this._textInput = elem, label: this.label, onEzChange: evt => this.handleChange(evt), value: this.value, enabled: this.enabled, errorMessage: this.errorMessage, restrict: this.restrict, mode: this.mode, onFocusin: this.handleFocus, canShowError: this.canShowError }, index.h("ez-icon", { slot: "leftIcon", iconName: "search" })));
158
- }
159
- get _elem() { return index.getElement(this); }
160
- static get watchers() { return {
161
- "label": ["observeLabel"],
162
- "errorMessage": ["observeErrorMessage"],
163
- "value": ["observeValue"]
164
- }; }
165
- };
166
- EzFilterInput.style = ezFilterInputCss;
167
-
168
- const multiSelectionBoxMessageCss = ".multi-selection__message{display:flex;flex-direction:row;align-items:center;justify-content:center;width:100%;min-height:320px;text-align:center}.multi-selection__text-message{margin-top:-30px;font-family:var(--font-pattern);font-size:var(--text--meduim);padding:var(--space-xs);color:var(--text--primary)}";
169
-
170
- const MultiSelectionBoxMessage = class {
171
- constructor(hostRef) {
172
- index.registerInstance(this, hostRef);
173
- this.message = undefined;
174
- }
175
- render() {
176
- return (index.h("div", { class: "multi-selection__message" }, index.h("span", { class: "multi-selection__text-message" }, this.message)));
177
- }
178
- };
179
- MultiSelectionBoxMessage.style = multiSelectionBoxMessageCss;
180
-
181
- exports.ez_card_item = EzCardItem;
182
- exports.ez_filter_input = EzFilterInput;
183
- exports.multi_selection_box_message = MultiSelectionBoxMessage;
@@ -1,206 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- const index = require('./index-a7b0c73d.js');
6
- const ICustomRender = require('./ICustomRender-6fafffce.js');
7
- const core = require('@sankhyalabs/core');
8
- const ApplicationUtils = require('./ApplicationUtils-c9d1205c.js');
9
- require('./DialogType-2114c337.js');
10
- require('./CheckMode-ecb90b87.js');
11
-
12
- const EzCustomFormInput = class {
13
- constructor(hostRef) {
14
- index.registerInstance(this, hostRef);
15
- this.gui = undefined;
16
- this.customEditor = undefined;
17
- this.formViewField = undefined;
18
- this.value = undefined;
19
- this.detailContext = undefined;
20
- this.builderFallback = undefined;
21
- this.selectedRecord = undefined;
22
- }
23
- /**
24
- * Aplica foco no campo.
25
- */
26
- async setFocus() {
27
- var _a, _b;
28
- (_b = (_a = this.gui) === null || _a === void 0 ? void 0 : _a["setFocus"]) === null || _b === void 0 ? void 0 : _b.call(_a);
29
- }
30
- /**
31
- * Remove o foco do campo.
32
- */
33
- async setBlur() {
34
- var _a, _b;
35
- (_b = (_a = this.gui) === null || _a === void 0 ? void 0 : _a["setBlur"]) === null || _b === void 0 ? void 0 : _b.call(_a);
36
- }
37
- /**
38
- * Retorna se o conteúdo é inválido.
39
- */
40
- async isInvalid() {
41
- var _a, _b;
42
- return ((_b = (_a = this.gui) === null || _a === void 0 ? void 0 : _a["isInvalid"]) === null || _b === void 0 ? void 0 : _b.call(_a)) || false;
43
- }
44
- getContent() {
45
- var _a, _b;
46
- const fieldProps = new Map();
47
- for (const prop in this.formViewField.props) {
48
- fieldProps.set(prop, this.formViewField.props[prop]);
49
- }
50
- const params = {
51
- value: this.value,
52
- name: this.formViewField.name,
53
- currentEditor: this.builderFallback(this.formViewField),
54
- setValue: (value) => this.setValue(value),
55
- getValue: this.getValue,
56
- record: this.selectedRecord,
57
- editorMetadata: {
58
- label: this.formViewField.label,
59
- hidden: ((_a = this.formViewField.props) === null || _a === void 0 ? void 0 : _a.visible) === false,
60
- userInterface: this.formViewField.userInterface,
61
- options: (_b = this.formViewField.props) === null || _b === void 0 ? void 0 : _b.options,
62
- props: this.formViewField.props ? fieldProps : undefined,
63
- optionLoader: this.formViewField.optionLoader
64
- },
65
- source: ICustomRender.CustomEditorSource.FORM,
66
- detailContext: this.detailContext
67
- };
68
- let gui = this.customEditor.getEditorElement(params);
69
- if (!gui) {
70
- gui = this.builderFallback(this.formViewField);
71
- this.handleValue(gui);
72
- this.gui = gui;
73
- return;
74
- }
75
- if (!(gui instanceof HTMLElement) && typeof gui !== 'string') {
76
- this.handleValue(gui);
77
- this.gui = gui;
78
- return;
79
- }
80
- if (typeof gui === 'string') {
81
- gui = core.HTMLBuilder.parseElement(gui);
82
- }
83
- if (this.value) {
84
- gui.setAttribute('value', typeof this.value === 'object' ? this.value.value : this.value);
85
- }
86
- this.gui = index.h("div", { key: core.StringUtils.generateUUID(), ref: el => el && el.appendChild(gui) });
87
- }
88
- setValue(value) {
89
- this.value = value;
90
- }
91
- getValue() {
92
- return this.value;
93
- }
94
- handleValue(gui) {
95
- var _a;
96
- //@ts-ignore
97
- (_a = gui.$children$) === null || _a === void 0 ? void 0 : _a.forEach((child) => {
98
- child.$attrs$.value = this.value;
99
- });
100
- }
101
- componentWillRender() {
102
- this.getContent();
103
- }
104
- render() {
105
- return (index.h(index.Host, null, this.gui));
106
- }
107
- };
108
-
109
- const ezTextEditCss = ":host{display:flex;align-items:center;gap:5px}.text-edit__form-input{width:auto;--ez-text-input__input--padding:0px}.text-edit__hidden-value{visibility:hidden;position:absolute;white-space:nowrap;z-index:-1;top:0;left:0}";
110
-
111
- const EzTextEdit = class {
112
- constructor(hostRef) {
113
- index.registerInstance(this, hostRef);
114
- this.saveEdition = index.createEvent(this, "saveEdition", 7);
115
- this.cancelEdition = index.createEvent(this, "cancelEdition", 7);
116
- this._newValue = undefined;
117
- this.value = undefined;
118
- this.styled = undefined;
119
- }
120
- /**
121
- * Aplica foco no campo.
122
- */
123
- async applyFocusSelect() {
124
- this.calcSizeInput(this.value, true);
125
- }
126
- calcSizeInput(value, setSelect = false) {
127
- var _a, _b;
128
- const textInput = (_b = (_a = this._inputElement) === null || _a === void 0 ? void 0 : _a.shadowRoot) === null || _b === void 0 ? void 0 : _b.querySelector('input');
129
- if (textInput != undefined) {
130
- const sizeText = this.getWidthValue(value);
131
- textInput.style.width = sizeText + 'px';
132
- if (setSelect) {
133
- setTimeout(() => textInput.select(), 100);
134
- }
135
- }
136
- }
137
- getWidthValue(value) {
138
- if (this._valueBasis != undefined) {
139
- const span = this._valueBasis;
140
- if (value != undefined) {
141
- const cursorSpace = 2;
142
- span.innerHTML = value;
143
- return span.clientWidth > 0 ? (span.clientWidth + cursorSpace) : cursorSpace;
144
- }
145
- else {
146
- span.innerHTML = "";
147
- }
148
- }
149
- return 0;
150
- }
151
- setStyledInput() {
152
- var _a, _b;
153
- let fontSize = "";
154
- let fontWeight = "";
155
- let fontFamily = "";
156
- if (this.styled != undefined) {
157
- fontSize = this.styled.fontSize;
158
- fontWeight = this.styled.fontWeight;
159
- fontFamily = this.styled.fontFamily;
160
- }
161
- const textInput = (_b = (_a = this._inputElement) === null || _a === void 0 ? void 0 : _a.shadowRoot) === null || _b === void 0 ? void 0 : _b.querySelector('input');
162
- if (textInput != undefined) {
163
- textInput.style.fontSize = fontSize;
164
- textInput.style.fontWeight = fontWeight;
165
- textInput.style.fontFamily = fontFamily;
166
- }
167
- const span = this._valueBasis;
168
- if (span != undefined) {
169
- span.style.fontSize = fontSize;
170
- span.style.fontWeight = fontWeight;
171
- span.style.fontFamily = fontFamily;
172
- }
173
- }
174
- handleSaveEdition() {
175
- if (!this._newValue) {
176
- ApplicationUtils.ApplicationUtils.alert("Aviso", "Não é possível salvar um campo em branco.").then(() => {
177
- this.setNewValue(this.value, true);
178
- });
179
- return;
180
- }
181
- this.saveEdition.emit({ value: this.value, newValue: this._newValue });
182
- }
183
- handleCancelEdition() {
184
- this.cancelEdition.emit();
185
- }
186
- setNewValue(value, setSelect = false) {
187
- this._newValue = value;
188
- this.calcSizeInput(this._newValue, setSelect);
189
- }
190
- componentDidLoad() {
191
- this.applyFocusSelect();
192
- this.setNewValue(this.value);
193
- }
194
- componentDidRender() {
195
- this.setStyledInput();
196
- }
197
- render() {
198
- core.ElementIDUtils.addIDInfoIfNotExists(this._element, 'input');
199
- return (index.h(index.Host, null, index.h("span", { class: "text-edit__hidden-value", ref: elem => this._valueBasis = elem }), index.h("ez-text-input", { "data-element-id": core.ElementIDUtils.getInternalIDInfo("textInput"), onInput: () => { this.calcSizeInput(this._newValue); }, class: "text-edit__form-input", value: this._newValue, ref: (elem) => this._inputElement = elem, mode: "slim", onEzChange: (evt) => this.setNewValue(evt === null || evt === void 0 ? void 0 : evt.detail), noBorder: true }), index.h("ez-button", { class: "text-edit__icon-check", mode: "icon", iconName: "check", size: "small", onClick: () => { this.handleSaveEdition(); } }), index.h("ez-button", { class: "text-edit__icon-close", mode: "icon", iconName: "close", size: "small", onClick: () => { this.handleCancelEdition(); } })));
200
- }
201
- get _element() { return index.getElement(this); }
202
- };
203
- EzTextEdit.style = ezTextEditCss;
204
-
205
- exports.ez_custom_form_input = EzCustomFormInput;
206
- exports.ez_text_edit = EzTextEdit;
@@ -1,67 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- const index = require('./index-a7b0c73d.js');
6
-
7
- const ALLOWED_ANIMATIONS = ['progress', 'progress-dark', 'pulse', 'false'];
8
-
9
- const ezSkeletonCss = ".skeleton {\n\tbox-sizing: border-box;\n\toutline: none;\n\toverflow: hidden;\n\tposition: relative;\n\n\tbackground:var(--skeleton-background, #eff1f6) no-repeat;\n\n\tborder-radius: var(--skeleton-border-radius, 4px);\n\twidth: var(--skeleton-width, 100%);\n\theight: var(--skeleton-height, 20px);\n\tdisplay: inline-block;\n\tmargin-bottom: var(--skeleton-margin-bottom, 0px);\n\twill-change: transform;\n\n\t&:after,\n\t&:before {\n\t\tbox-sizing: border-box;\n\t}\n\n\t&.circle {\n\t\twidth: var(--skeleton-width, 40px);\n\t\theight: var(--skeleton-height, 40px);\n\t\tmargin-bottom: var(--skeleton-margin-bottom, 5px);\n\t\tborder-radius: var(--skeleton-border-radius, 50%);\n\t}\n\n\t&.rect {\n\t\tborder-radius: var(--skeleton-border-radius, 0px);\n\t}\n\n\t&.progress,\n\t&.progress-dark {\n\t\tanimation: progress 2s cubic-bezier(0.4, 0, 0.2, 1) infinite;\n\t\tbackground-size: 200px 100%;\n\t}\n\n\t&.progress {\n\t\tbackground-image: linear-gradient(\n\t\t\t90deg,\n\t\t\trgba(255, 255, 255, 0),\n\t\t\trgba(255, 255, 255, 0.6),\n\t\t\trgba(255, 255, 255, 0)\n\t\t);\n\t}\n\n\t&.progress-dark {\n\t\tbackground-image: linear-gradient(\n\t\t\t90deg,\n\t\t\ttransparent,\n\t\t\trgba(0, 0, 0, 0.2),\n\t\t\ttransparent\n\t\t);\n\t}\n\n\t&.pulse {\n\t\tanimation: pulse 1.5s cubic-bezier(0.4, 0, 0.2, 1) infinite;\n\t\tanimation-delay: 0.5s;\n\t}\n\n\t@media (prefers-reduced-motion: reduce) {\n\t\t&.pulse,\n\t\t&.progress-dark,\n\t\t&.progress {\n\t\t\tanimation: none;\n\t\t}\n\n\t\t&.progress,\n\t\t&.progress-dark {\n\t\t\tbackground-image: none;\n\t\t}\n\t}\n}\n\n@keyframes progress {\n\t0% {\n\t\tbackground-position: -200px 0;\n\t}\n\t100% {\n\t\tbackground-position: calc(200px + 100%) 0;\n\t}\n}\n\n@keyframes pulse {\n\t0% {\n\t\topacity: 1;\n\t}\n\t50% {\n\t\topacity: 0.4;\n\t}\n\t100% {\n\t\topacity: 1;\n\t}\n}";
10
-
11
- const EzSkeleton = class {
12
- constructor(hostRef) {
13
- index.registerInstance(this, hostRef);
14
- this.items = [];
15
- this.count = 1;
16
- this.variant = 'text';
17
- this.width = null;
18
- this.height = null;
19
- this.marginBottom = null;
20
- this.animation = 'progress';
21
- }
22
- componentWillLoad() {
23
- this.init();
24
- }
25
- componentWillUpdate() {
26
- this.init();
27
- }
28
- init() {
29
- this.items.length = this.count;
30
- this.items.fill(1);
31
- if (!ALLOWED_ANIMATIONS.includes(this.animation)) {
32
- this.animation = 'progress';
33
- }
34
- }
35
- get style() {
36
- let dimenssionsStyles = {
37
- width: null,
38
- height: null,
39
- marginBottom: null
40
- };
41
- if (this.width) {
42
- dimenssionsStyles.width = this.width;
43
- }
44
- if (this.height) {
45
- dimenssionsStyles.height = this.height;
46
- }
47
- if (this.marginBottom) {
48
- dimenssionsStyles.marginBottom = this.marginBottom;
49
- }
50
- return dimenssionsStyles;
51
- }
52
- render() {
53
- return this.items.map((_, index$1) => {
54
- return (index.h("span", { key: index$1, class: {
55
- circle: this.variant === 'circle',
56
- rect: this.variant === 'rect',
57
- progress: this.animation === 'progress',
58
- 'progress-dark': this.animation === 'progress-dark',
59
- pulse: this.animation === 'pulse',
60
- skeleton: true
61
- }, "data-busy": "true", "data-valuemin": "0", "data-valuemax": "100", "data-valuetext": "Loading...", role: "progressbar", tabindex: "0", style: this.style }));
62
- });
63
- }
64
- };
65
- EzSkeleton.style = ezSkeletonCss;
66
-
67
- exports.ez_skeleton = EzSkeleton;
@@ -1,99 +0,0 @@
1
- import { UserInterface } from '@sankhyalabs/core';
2
- import { A as ApplicationUtils } from './ApplicationUtils-eaf91331.js';
3
-
4
- const buildFieldMetadata = (descriptor, config) => {
5
- let { name, label, group } = Object.assign({}, config);
6
- let { readOnly, required } = Object.assign({}, config);
7
- let props;
8
- let userInterface;
9
- if (descriptor) {
10
- label = label || descriptor.label;
11
- name = name || descriptor.name;
12
- required = descriptor.required || (config === null || config === void 0 ? void 0 : config.required);
13
- readOnly = descriptor.readOnly || (config === null || config === void 0 ? void 0 : config.readOnly);
14
- props = descriptor.properties;
15
- userInterface = descriptor.userInterface;
16
- }
17
- return {
18
- name, label, group,
19
- readOnly, required,
20
- props,
21
- userInterface: userInterface || UserInterface.SHORTTEXT
22
- };
23
- };
24
-
25
- class RecordValidationProcessor {
26
- constructor(dataUnit, validationSource, validator) {
27
- this._dataUnit = dataUnit;
28
- this._validationSource = validationSource;
29
- this._validator = validator;
30
- }
31
- validate() {
32
- return new Promise((accept, reject) => {
33
- const records = this._dataUnit.getModifiedRecords();
34
- for (let i = 0; i < records.length; i++) {
35
- const record = records[i];
36
- const invalidResults = [];
37
- let validationResult = this.validateRequired(record);
38
- if (validationResult && !validationResult.isValid) {
39
- invalidResults.push(validationResult);
40
- }
41
- if (this._validator) {
42
- validationResult = this._validator.validateRecord(record);
43
- if (validationResult && !validationResult.isValid) {
44
- invalidResults.push(validationResult);
45
- }
46
- }
47
- if (invalidResults.length > 0) {
48
- this.processValidationResult(invalidResults, record.__record__id__);
49
- reject();
50
- break;
51
- }
52
- }
53
- return accept();
54
- });
55
- }
56
- validateRequired(record) {
57
- const requiredFields = this._validationSource.getRequiredFields();
58
- const invalidFields = [];
59
- new Set(requiredFields).forEach(field => {
60
- const value = record[field];
61
- if (value == undefined || value === "") {
62
- const errorMessage = this._validationSource.getMessageForField(field, record.__record__id__);
63
- if (errorMessage) {
64
- invalidFields.push({ name: field, message: errorMessage });
65
- }
66
- else {
67
- invalidFields.push({ name: field, message: "Essa informação é obrigatória" });
68
- }
69
- }
70
- });
71
- if (invalidFields.length > 0) {
72
- return { isValid: false, invalidFields, infoMessage: "Há pelo menos um campo obrigatório não preenchido." };
73
- }
74
- return undefined;
75
- }
76
- processValidationResult(validationResult, recordId) {
77
- validationResult.forEach(invalidResult => {
78
- const invalidFields = invalidResult.invalidFields;
79
- if (invalidFields) {
80
- invalidFields.forEach(field => {
81
- this.markAsInvalid(field, recordId);
82
- });
83
- }
84
- if (invalidResult.infoMessage) {
85
- ApplicationUtils.info(invalidResult.infoMessage);
86
- }
87
- if (invalidResult.errorMessage) {
88
- const { errorTitle, errorMessage } = invalidResult;
89
- ApplicationUtils.error(errorTitle, errorMessage);
90
- }
91
- });
92
- }
93
- markAsInvalid(field, recordId) {
94
- this._dataUnit.setInvalidField(field.name, field.message, recordId);
95
- this._validationSource.markAsInvalid(field, recordId);
96
- }
97
- }
98
-
99
- export { RecordValidationProcessor as R, buildFieldMetadata as b };