@sankhyalabs/ezui 0.0.0-bugfix-dev-KB-6165.0 → 0.0.0-bugfix-dev-KB-17130.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (273) hide show
  1. package/README.md +8 -10
  2. package/dist/cjs/{ApplicationUtils-2e444734.js → ApplicationUtils-c9d1205c.js} +56 -6
  3. package/dist/cjs/{RecordValidationProcessor-edd23705.js → RecordValidationProcessor-4c893e04.js} +1 -1
  4. package/dist/cjs/{constants-3a1d64fb.js → constants-2714478b.js} +2 -0
  5. package/dist/cjs/ez-actions-button.cjs.entry.js +56 -28
  6. package/dist/cjs/ez-alert-list.cjs.entry.js +148 -0
  7. package/dist/cjs/ez-alert.cjs.entry.js +1 -1
  8. package/dist/cjs/ez-application.cjs.entry.js +1 -1
  9. package/dist/cjs/ez-badge.cjs.entry.js +1 -1
  10. package/dist/cjs/ez-breadcrumb.cjs.entry.js +1 -1
  11. package/dist/cjs/ez-button.cjs.entry.js +1 -1
  12. package/dist/cjs/ez-calendar.cjs.entry.js +1 -1
  13. package/dist/cjs/ez-card-item_3.cjs.entry.js +182 -0
  14. package/dist/cjs/ez-check.cjs.entry.js +1 -1
  15. package/dist/cjs/ez-chip.cjs.entry.js +1 -1
  16. package/dist/cjs/ez-collapsible-box.cjs.entry.js +3 -4
  17. package/dist/cjs/ez-combo-box.cjs.entry.js +17 -152
  18. package/dist/cjs/ez-date-input.cjs.entry.js +1 -1
  19. package/dist/cjs/ez-date-time-input.cjs.entry.js +1 -1
  20. package/dist/cjs/ez-dialog.cjs.entry.js +31 -5
  21. package/dist/cjs/ez-dropdown.cjs.entry.js +12 -6
  22. package/dist/cjs/ez-file-item.cjs.entry.js +1 -1
  23. package/dist/cjs/ez-form-view.cjs.entry.js +44 -3
  24. package/dist/cjs/ez-form.cjs.entry.js +36 -4
  25. package/dist/cjs/ez-grid.cjs.entry.js +246 -64
  26. package/dist/cjs/ez-guide-navigator.cjs.entry.js +7 -1
  27. package/dist/cjs/ez-icon.cjs.entry.js +2 -2
  28. package/dist/cjs/ez-list.cjs.entry.js +5 -3
  29. package/dist/cjs/ez-loading-bar.cjs.entry.js +1 -1
  30. package/dist/cjs/ez-modal-container.cjs.entry.js +1 -1
  31. package/dist/cjs/ez-modal.cjs.entry.js +2 -2
  32. package/dist/cjs/ez-multi-selection-list.cjs.entry.js +23 -10
  33. package/dist/cjs/ez-number-input.cjs.entry.js +1 -1
  34. package/dist/cjs/ez-popover.cjs.entry.js +1 -1
  35. package/dist/cjs/ez-popup.cjs.entry.js +2 -2
  36. package/dist/cjs/ez-radio-button.cjs.entry.js +1 -1
  37. package/dist/cjs/ez-scroller_3.cjs.entry.js +8 -6
  38. package/dist/cjs/ez-search.cjs.entry.js +615 -32
  39. package/dist/cjs/ez-skeleton.cjs.entry.js +1 -1
  40. package/dist/cjs/ez-split-item.cjs.entry.js +19 -0
  41. package/dist/cjs/ez-split-panel.cjs.entry.js +776 -0
  42. package/dist/cjs/ez-tabselector.cjs.entry.js +1 -1
  43. package/dist/cjs/ez-text-area.cjs.entry.js +1 -1
  44. package/dist/cjs/ez-text-edit.cjs.entry.js +2 -2
  45. package/dist/cjs/ez-text-input.cjs.entry.js +3 -2
  46. package/dist/cjs/ez-time-input.cjs.entry.js +1 -1
  47. package/dist/cjs/ez-toast.cjs.entry.js +1 -1
  48. package/dist/cjs/ez-upload.cjs.entry.js +2 -2
  49. package/dist/cjs/ez-view-stack.cjs.entry.js +1 -1
  50. package/dist/cjs/ezui.cjs.js +2 -2
  51. package/dist/cjs/filter-column.cjs.entry.js +47 -12
  52. package/dist/cjs/{index-1064511f.js → index-a7b0c73d.js} +16 -6
  53. package/dist/cjs/loader.cjs.js +2 -2
  54. package/dist/collection/collection-manifest.json +6 -3
  55. package/dist/collection/components/ez-actions-button/ez-actions-button.css +17 -3
  56. package/dist/collection/components/ez-actions-button/ez-actions-button.js +105 -27
  57. package/dist/collection/components/ez-alert-list/ez-alert-list.css +87 -0
  58. package/dist/collection/components/ez-alert-list/ez-alert-list.js +268 -0
  59. package/dist/collection/components/ez-card-item/ez-card-item.css +17 -0
  60. package/dist/collection/components/ez-collapsible-box/ez-collapsible-box.css +1 -1
  61. package/dist/collection/components/ez-collapsible-box/ez-collapsible-box.js +0 -1
  62. package/dist/collection/components/ez-combo-box/ez-combo-box.js +71 -169
  63. package/dist/collection/components/ez-dialog/ez-dialog.css +1 -1
  64. package/dist/collection/components/ez-dialog/ez-dialog.js +39 -4
  65. package/dist/collection/components/ez-dropdown/ez-dropdown.css +4 -3
  66. package/dist/collection/components/ez-dropdown/ez-dropdown.js +33 -4
  67. package/dist/collection/components/ez-form/ez-form.js +93 -0
  68. package/dist/collection/components/ez-form-view/ez-form-view.js +23 -0
  69. package/dist/collection/components/ez-form-view/fieldbuilder/FieldBuilder.js +4 -1
  70. package/dist/collection/components/ez-form-view/structure/index.js +34 -0
  71. package/dist/collection/components/ez-grid/controller/ag-grid/AgGridController.js +21 -9
  72. package/dist/collection/components/ez-grid/controller/ag-grid/DataSource.js +23 -1
  73. package/dist/collection/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.js +1 -1
  74. package/dist/collection/components/ez-grid/controller/ag-grid/components/cellRendererStatus.js +1 -1
  75. package/dist/collection/components/ez-grid/ez-grid.css +1 -4
  76. package/dist/collection/components/ez-grid/ez-grid.js +91 -51
  77. package/dist/collection/components/ez-grid/interfaces/IColumnFilter.js +1 -0
  78. package/dist/collection/components/ez-grid/interfaces/index.js +1 -0
  79. package/dist/collection/components/ez-grid/subcomponents/filter-column.js +66 -12
  80. package/dist/collection/components/ez-grid/utils/ColumnFilterManager.js +62 -0
  81. package/dist/collection/components/ez-grid/utils/InMemoryFilterColumnDataSource.js +94 -0
  82. package/dist/collection/components/ez-grid/utils/index.js +1 -0
  83. package/dist/collection/components/ez-guide-navigator/ez-guide-navigator.js +22 -0
  84. package/dist/collection/components/ez-icon/ez-icon.css +148 -139
  85. package/dist/collection/components/ez-list/ez-list.css +12 -7
  86. package/dist/collection/components/ez-list/ez-list.js +3 -1
  87. package/dist/collection/components/ez-modal/ez-modal.css +1 -1
  88. package/dist/collection/components/ez-multi-selection-list/ez-multi-selection-list.js +41 -10
  89. package/dist/collection/components/ez-popup/ez-popup.css +2 -2
  90. package/dist/collection/components/ez-search/ez-search.css +330 -0
  91. package/dist/collection/components/ez-search/ez-search.js +746 -55
  92. package/dist/collection/components/ez-split-panel/ez-split-panel.css +8 -0
  93. package/dist/collection/components/ez-split-panel/ez-split-panel.js +122 -0
  94. package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.css +12 -0
  95. package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.js +17 -0
  96. package/dist/collection/components/ez-text-input/ez-text-input.js +20 -1
  97. package/dist/collection/components/ez-tree/ez-tree.css +33 -0
  98. package/dist/collection/components/ez-tree/subcomponents/TreeItem.js +3 -3
  99. package/dist/collection/utils/ApplicationUtils.js +56 -6
  100. package/dist/collection/utils/constants.js +1 -0
  101. package/dist/collection/utils/form/DataBinder.js +12 -1
  102. package/dist/collection/utils/interfaces/IAction.js +1 -0
  103. package/dist/custom-elements/index.d.ts +18 -0
  104. package/dist/custom-elements/index.js +2138 -339
  105. package/dist/esm/{ApplicationUtils-d9a34a16.js → ApplicationUtils-eaf91331.js} +56 -6
  106. package/dist/esm/{RecordValidationProcessor-abc814af.js → RecordValidationProcessor-b00b8b77.js} +1 -1
  107. package/dist/esm/constants-4e0d35b7.js +5 -0
  108. package/dist/esm/ez-actions-button.entry.js +56 -28
  109. package/dist/esm/ez-alert-list.entry.js +144 -0
  110. package/dist/esm/ez-alert.entry.js +1 -1
  111. package/dist/esm/ez-application.entry.js +1 -1
  112. package/dist/esm/ez-badge.entry.js +1 -1
  113. package/dist/esm/ez-breadcrumb.entry.js +1 -1
  114. package/dist/esm/ez-button.entry.js +1 -1
  115. package/dist/esm/ez-calendar.entry.js +1 -1
  116. package/dist/esm/ez-card-item_3.entry.js +176 -0
  117. package/dist/esm/ez-check.entry.js +1 -1
  118. package/dist/esm/ez-chip.entry.js +1 -1
  119. package/dist/esm/ez-collapsible-box.entry.js +3 -4
  120. package/dist/esm/ez-combo-box.entry.js +18 -153
  121. package/dist/esm/ez-date-input.entry.js +1 -1
  122. package/dist/esm/ez-date-time-input.entry.js +1 -1
  123. package/dist/esm/ez-dialog.entry.js +31 -5
  124. package/dist/esm/ez-dropdown.entry.js +12 -6
  125. package/dist/esm/ez-file-item.entry.js +1 -1
  126. package/dist/esm/ez-form-view.entry.js +44 -3
  127. package/dist/esm/ez-form.entry.js +36 -4
  128. package/dist/esm/ez-grid.entry.js +247 -65
  129. package/dist/esm/ez-guide-navigator.entry.js +7 -1
  130. package/dist/esm/ez-icon.entry.js +2 -2
  131. package/dist/esm/ez-list.entry.js +5 -3
  132. package/dist/esm/ez-loading-bar.entry.js +1 -1
  133. package/dist/esm/ez-modal-container.entry.js +1 -1
  134. package/dist/esm/ez-modal.entry.js +2 -2
  135. package/dist/esm/ez-multi-selection-list.entry.js +23 -10
  136. package/dist/esm/ez-number-input.entry.js +1 -1
  137. package/dist/esm/ez-popover.entry.js +1 -1
  138. package/dist/esm/ez-popup.entry.js +2 -2
  139. package/dist/esm/ez-radio-button.entry.js +1 -1
  140. package/dist/esm/ez-scroller_3.entry.js +8 -6
  141. package/dist/esm/ez-search.entry.js +616 -33
  142. package/dist/esm/ez-skeleton.entry.js +1 -1
  143. package/dist/esm/ez-split-item.entry.js +15 -0
  144. package/dist/esm/ez-split-panel.entry.js +772 -0
  145. package/dist/esm/ez-tabselector.entry.js +1 -1
  146. package/dist/esm/ez-text-area.entry.js +1 -1
  147. package/dist/esm/ez-text-edit.entry.js +2 -2
  148. package/dist/esm/ez-text-input.entry.js +3 -2
  149. package/dist/esm/ez-time-input.entry.js +1 -1
  150. package/dist/esm/ez-toast.entry.js +1 -1
  151. package/dist/esm/ez-upload.entry.js +2 -2
  152. package/dist/esm/ez-view-stack.entry.js +1 -1
  153. package/dist/esm/ezui.js +3 -3
  154. package/dist/esm/filter-column.entry.js +47 -12
  155. package/dist/esm/{index-296b8458.js → index-baa5e267.js} +16 -6
  156. package/dist/esm/loader.js +3 -3
  157. package/dist/ezui/ezui.esm.js +1 -1
  158. package/dist/ezui/{p-5cef0264.entry.js → p-0306dff7.entry.js} +1 -1
  159. package/dist/ezui/p-0447d17c.entry.js +1 -0
  160. package/dist/ezui/{p-86a2036d.js → p-04f24913.js} +1 -1
  161. package/dist/ezui/p-05e1f4e7.js +1 -0
  162. package/dist/ezui/p-072e6347.entry.js +1 -0
  163. package/dist/ezui/p-133fae4a.entry.js +1 -0
  164. package/dist/ezui/{p-f4208819.entry.js → p-17be134a.entry.js} +1 -1
  165. package/dist/ezui/{p-cd19a6f8.entry.js → p-1e7a8633.entry.js} +1 -1
  166. package/dist/ezui/{p-60ba28ea.entry.js → p-1f50fa05.entry.js} +1 -1
  167. package/dist/ezui/{p-a5e09759.entry.js → p-20ec22c0.entry.js} +1 -1
  168. package/dist/ezui/p-2187f86c.js +1 -0
  169. package/dist/ezui/{p-e318d280.js → p-23a36bb6.js} +1 -1
  170. package/dist/ezui/{p-ce035beb.entry.js → p-24d3fede.entry.js} +1 -1
  171. package/dist/ezui/p-2a1a0e04.entry.js +1 -0
  172. package/dist/ezui/p-40f72de4.entry.js +1 -0
  173. package/dist/ezui/p-43b03119.entry.js +1 -0
  174. package/dist/ezui/{p-9b347f04.entry.js → p-44caad9a.entry.js} +1 -1
  175. package/dist/ezui/p-49456b34.entry.js +1 -0
  176. package/dist/ezui/p-4a7f113d.entry.js +1 -0
  177. package/dist/ezui/p-51c5e071.entry.js +1 -0
  178. package/dist/ezui/{p-ccb4ccd9.entry.js → p-555c9018.entry.js} +1 -1
  179. package/dist/ezui/{p-d43b22f3.entry.js → p-596634e9.entry.js} +1 -1
  180. package/dist/ezui/p-5bd5e68f.entry.js +1 -0
  181. package/dist/ezui/{p-a01068e1.entry.js → p-5d692ed1.entry.js} +1 -1
  182. package/dist/ezui/{p-95426f93.entry.js → p-5d86cca9.entry.js} +1 -1
  183. package/dist/ezui/p-5e1d036e.entry.js +1 -0
  184. package/dist/ezui/{p-7525e604.entry.js → p-5ed81457.entry.js} +1 -1
  185. package/dist/ezui/{p-c49dbf23.entry.js → p-650e4b6d.entry.js} +1 -1
  186. package/dist/ezui/{p-fd54b5b4.entry.js → p-6e2f8e6b.entry.js} +2 -2
  187. package/dist/ezui/p-6e429cff.entry.js +1 -0
  188. package/dist/ezui/p-76ba9d67.entry.js +1 -0
  189. package/dist/ezui/{p-37673563.entry.js → p-77a4bd35.entry.js} +1 -1
  190. package/dist/ezui/p-796c1a88.entry.js +1 -0
  191. package/dist/ezui/{p-5d6f2550.entry.js → p-85c8baae.entry.js} +1 -1
  192. package/dist/ezui/{p-fa571a4e.entry.js → p-8becebf8.entry.js} +1 -1
  193. package/dist/ezui/p-8defa6d3.entry.js +1 -0
  194. package/dist/ezui/{p-391de0e4.entry.js → p-9050d2cd.entry.js} +1 -1
  195. package/dist/ezui/{p-028f264f.entry.js → p-9cad9b6e.entry.js} +1 -1
  196. package/dist/ezui/{p-b11f035c.entry.js → p-9f5fa3f9.entry.js} +1 -1
  197. package/dist/ezui/p-a08b309b.entry.js +1 -0
  198. package/dist/ezui/{p-2da09f70.entry.js → p-a80b1287.entry.js} +1 -1
  199. package/dist/ezui/p-af15c277.entry.js +1 -0
  200. package/dist/ezui/{p-32b4163f.entry.js → p-b041333c.entry.js} +1 -1
  201. package/dist/ezui/p-ba875f37.entry.js +1 -0
  202. package/dist/ezui/p-bc2f844e.entry.js +1 -0
  203. package/dist/ezui/{p-e2dfd935.entry.js → p-c0f1715f.entry.js} +1 -1
  204. package/dist/ezui/{p-83885b21.entry.js → p-cc2dc4f4.entry.js} +1 -1
  205. package/dist/ezui/p-d6ffe679.entry.js +1 -0
  206. package/dist/ezui/p-eb36f072.entry.js +1 -0
  207. package/dist/ezui/p-f56dd1da.entry.js +1 -0
  208. package/dist/types/components/ez-actions-button/ez-actions-button.d.ts +15 -7
  209. package/dist/types/components/ez-alert-list/ez-alert-list.d.ts +76 -0
  210. package/dist/types/components/ez-combo-box/ez-combo-box.d.ts +12 -15
  211. package/dist/types/components/ez-dialog/ez-dialog.d.ts +8 -2
  212. package/dist/types/components/ez-dropdown/ez-dropdown.d.ts +5 -0
  213. package/dist/types/components/ez-form/ez-form.d.ts +19 -1
  214. package/dist/types/components/ez-form-view/ez-form-view.d.ts +5 -0
  215. package/dist/types/components/ez-form-view/structure/index.d.ts +15 -0
  216. package/dist/types/components/ez-grid/controller/EzGridController.d.ts +9 -6
  217. package/dist/types/components/ez-grid/controller/ag-grid/AgGridController.d.ts +2 -3
  218. package/dist/types/components/ez-grid/controller/ag-grid/DataSource.d.ts +1 -0
  219. package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.d.ts +1 -1
  220. package/dist/types/components/ez-grid/ez-grid.d.ts +13 -5
  221. package/dist/types/components/ez-grid/interfaces/IColumnFilter.d.ts +4 -0
  222. package/dist/types/components/ez-grid/interfaces/index.d.ts +1 -0
  223. package/dist/types/components/ez-grid/subcomponents/filter-column.d.ts +8 -0
  224. package/dist/types/components/ez-grid/utils/ColumnFilterManager.d.ts +9 -0
  225. package/dist/types/components/ez-grid/utils/InMemoryFilterColumnDataSource.d.ts +19 -0
  226. package/dist/types/components/ez-grid/utils/index.d.ts +1 -0
  227. package/dist/types/components/ez-guide-navigator/ez-guide-navigator.d.ts +4 -0
  228. package/dist/types/components/ez-guide-navigator/interfaces/IGuideItem.d.ts +1 -0
  229. package/dist/types/components/ez-multi-selection-list/ez-multi-selection-list.d.ts +4 -0
  230. package/dist/types/components/ez-multi-selection-list/interfaces/IMultiSelectionListDataSource.d.ts +2 -0
  231. package/dist/types/components/ez-search/ez-search.d.ts +112 -10
  232. package/dist/types/components/ez-split-panel/structure/item/ez-split-item.d.ts +3 -0
  233. package/dist/types/components/ez-text-input/ez-text-input.d.ts +4 -0
  234. package/dist/types/components/ez-tree/interfaces/ITreeItem.d.ts +1 -0
  235. package/dist/types/components/ez-tree/subcomponents/TreeItem.d.ts +1 -0
  236. package/dist/types/components.d.ts +236 -17
  237. package/dist/types/utils/ApplicationUtils.d.ts +24 -0
  238. package/dist/types/utils/constants.d.ts +1 -0
  239. package/dist/types/utils/form/DataBinder.d.ts +1 -0
  240. package/dist/types/utils/index.d.ts +1 -0
  241. package/dist/types/utils/interfaces/AbstractFieldMetadata.d.ts +2 -1
  242. package/dist/types/utils/interfaces/IAction.d.ts +7 -0
  243. package/package.json +4 -3
  244. package/react/components.d.ts +3 -0
  245. package/react/components.js +3 -0
  246. package/react/components.js.map +1 -1
  247. package/dist/cjs/ez-card-item.cjs.entry.js +0 -52
  248. package/dist/cjs/ez-filter-input_2.cjs.entry.js +0 -137
  249. package/dist/esm/constants-6dab64f7.js +0 -4
  250. package/dist/esm/ez-card-item.entry.js +0 -48
  251. package/dist/esm/ez-filter-input_2.entry.js +0 -132
  252. package/dist/ezui/p-050247dc.entry.js +0 -1
  253. package/dist/ezui/p-1e7c4986.entry.js +0 -1
  254. package/dist/ezui/p-244dfe8a.entry.js +0 -1
  255. package/dist/ezui/p-27a01a26.js +0 -1
  256. package/dist/ezui/p-2a0e1679.entry.js +0 -1
  257. package/dist/ezui/p-4535da17.entry.js +0 -1
  258. package/dist/ezui/p-4c8b029b.entry.js +0 -1
  259. package/dist/ezui/p-4e31b69b.entry.js +0 -1
  260. package/dist/ezui/p-5495fa45.entry.js +0 -1
  261. package/dist/ezui/p-5ce6548c.entry.js +0 -1
  262. package/dist/ezui/p-68352e41.entry.js +0 -1
  263. package/dist/ezui/p-87e85160.entry.js +0 -1
  264. package/dist/ezui/p-8bd3903b.entry.js +0 -1
  265. package/dist/ezui/p-90fa4cb3.entry.js +0 -1
  266. package/dist/ezui/p-9285b53e.entry.js +0 -1
  267. package/dist/ezui/p-a510a4c5.entry.js +0 -1
  268. package/dist/ezui/p-d51aa09b.entry.js +0 -1
  269. package/dist/ezui/p-db528b31.entry.js +0 -1
  270. package/dist/ezui/p-e67d0bd5.entry.js +0 -1
  271. package/dist/ezui/p-e7fa0ad6.entry.js +0 -1
  272. package/dist/ezui/p-f15ec3bb.js +0 -1
  273. package/dist/ezui/p-ff82b176.entry.js +0 -1
@@ -0,0 +1,772 @@
1
+ import { r as registerInstance, h, H as Host, g as getElement } from './index-baa5e267.js';
2
+ import { StringUtils } from '@sankhyalabs/core';
3
+
4
+ var numeric = function (value, unit) { return Number(value.slice(0, -1 * unit.length)); };
5
+
6
+ var parseValue = function (value) {
7
+ if (value.endsWith('px'))
8
+ { return { value: value, type: 'px', numeric: numeric(value, 'px') } }
9
+ if (value.endsWith('fr'))
10
+ { return { value: value, type: 'fr', numeric: numeric(value, 'fr') } }
11
+ if (value.endsWith('%'))
12
+ { return { value: value, type: '%', numeric: numeric(value, '%') } }
13
+ if (value === 'auto') { return { value: value, type: 'auto' } }
14
+ return null
15
+ };
16
+
17
+ var parse = function (rule) { return rule.split(' ').map(parseValue); };
18
+
19
+ var getSizeAtTrack = function (index, tracks, gap, end) {
20
+ if ( gap === void 0 ) { gap = 0; }
21
+ if ( end === void 0 ) { end = false; }
22
+
23
+ var newIndex = end ? index + 1 : index;
24
+ var trackSum = tracks
25
+ .slice(0, newIndex)
26
+ .reduce(function (accum, value) { return accum + value.numeric; }, 0);
27
+ var gapSum = gap ? index * gap : 0;
28
+
29
+ return trackSum + gapSum
30
+ };
31
+
32
+ var getStyles = function (rule, ownRules, matchedRules) { return ownRules.concat( matchedRules)
33
+ .map(function (r) { return r.style[rule]; })
34
+ .filter(function (style) { return style !== undefined && style !== ''; }); };
35
+
36
+ var getGapValue = function (unit, size) {
37
+ if (size.endsWith(unit)) {
38
+ return Number(size.slice(0, -1 * unit.length))
39
+ }
40
+ return null
41
+ };
42
+
43
+ var firstNonZero = function (tracks) {
44
+ // eslint-disable-next-line no-plusplus
45
+ for (var i = 0; i < tracks.length; i++) {
46
+ if (tracks[i].numeric > 0) {
47
+ return i
48
+ }
49
+ }
50
+ return null
51
+ };
52
+
53
+ var NOOP = function () { return false; };
54
+
55
+ var defaultWriteStyle = function (element, gridTemplateProp, style) {
56
+ // eslint-disable-next-line no-param-reassign
57
+ element.style[gridTemplateProp] = style;
58
+ };
59
+
60
+ var getOption = function (options, propName, def) {
61
+ var value = options[propName];
62
+ if (value !== undefined) {
63
+ return value
64
+ }
65
+ return def
66
+ };
67
+
68
+ function getMatchedCSSRules (el) {
69
+ var ref;
70
+
71
+ return (ref = [])
72
+ .concat.apply(
73
+ ref, Array.from(el.ownerDocument.styleSheets).map(function (s) {
74
+ var rules = [];
75
+
76
+ try {
77
+ rules = Array.from(s.cssRules || []);
78
+ } catch (e) {
79
+ // Ignore results on security error
80
+ }
81
+
82
+ return rules
83
+ })
84
+ )
85
+ .filter(function (r) {
86
+ var matches = false;
87
+ try {
88
+ matches = el.matches(r.selectorText);
89
+ } catch (e) {
90
+ // Ignore matching erros
91
+ }
92
+
93
+ return matches
94
+ });
95
+ }
96
+
97
+ var gridTemplatePropColumns = 'grid-template-columns';
98
+ var gridTemplatePropRows = 'grid-template-rows';
99
+
100
+ var Gutter = function Gutter(direction, options, parentOptions) {
101
+ this.direction = direction;
102
+ this.element = options.element;
103
+ this.track = options.track;
104
+
105
+ if (direction === 'column') {
106
+ this.gridTemplateProp = gridTemplatePropColumns;
107
+ this.gridGapProp = 'grid-column-gap';
108
+ this.cursor = getOption(
109
+ parentOptions,
110
+ 'columnCursor',
111
+ getOption(parentOptions, 'cursor', 'col-resize')
112
+ );
113
+ this.snapOffset = getOption(
114
+ parentOptions,
115
+ 'columnSnapOffset',
116
+ getOption(parentOptions, 'snapOffset', 30)
117
+ );
118
+ this.dragInterval = getOption(
119
+ parentOptions,
120
+ 'columnDragInterval',
121
+ getOption(parentOptions, 'dragInterval', 1)
122
+ );
123
+ this.clientAxis = 'clientX';
124
+ this.optionStyle = getOption(parentOptions, 'gridTemplateColumns');
125
+ } else if (direction === 'row') {
126
+ this.gridTemplateProp = gridTemplatePropRows;
127
+ this.gridGapProp = 'grid-row-gap';
128
+ this.cursor = getOption(
129
+ parentOptions,
130
+ 'rowCursor',
131
+ getOption(parentOptions, 'cursor', 'row-resize')
132
+ );
133
+ this.snapOffset = getOption(
134
+ parentOptions,
135
+ 'rowSnapOffset',
136
+ getOption(parentOptions, 'snapOffset', 30)
137
+ );
138
+ this.dragInterval = getOption(
139
+ parentOptions,
140
+ 'rowDragInterval',
141
+ getOption(parentOptions, 'dragInterval', 1)
142
+ );
143
+ this.clientAxis = 'clientY';
144
+ this.optionStyle = getOption(parentOptions, 'gridTemplateRows');
145
+ }
146
+
147
+ this.onDragStart = getOption(parentOptions, 'onDragStart', NOOP);
148
+ this.onDragEnd = getOption(parentOptions, 'onDragEnd', NOOP);
149
+ this.onDrag = getOption(parentOptions, 'onDrag', NOOP);
150
+ this.writeStyle = getOption(
151
+ parentOptions,
152
+ 'writeStyle',
153
+ defaultWriteStyle
154
+ );
155
+
156
+ this.startDragging = this.startDragging.bind(this);
157
+ this.stopDragging = this.stopDragging.bind(this);
158
+ this.drag = this.drag.bind(this);
159
+
160
+ this.minSizeStart = options.minSizeStart;
161
+ this.minSizeEnd = options.minSizeEnd;
162
+
163
+ if (options.element) {
164
+ this.element.addEventListener('mousedown', this.startDragging);
165
+ this.element.addEventListener('touchstart', this.startDragging);
166
+ }
167
+ };
168
+
169
+ Gutter.prototype.getDimensions = function getDimensions () {
170
+ var ref = this.grid.getBoundingClientRect();
171
+ var width = ref.width;
172
+ var height = ref.height;
173
+ var top = ref.top;
174
+ var bottom = ref.bottom;
175
+ var left = ref.left;
176
+ var right = ref.right;
177
+
178
+ if (this.direction === 'column') {
179
+ this.start = top;
180
+ this.end = bottom;
181
+ this.size = height;
182
+ } else if (this.direction === 'row') {
183
+ this.start = left;
184
+ this.end = right;
185
+ this.size = width;
186
+ }
187
+ };
188
+
189
+ Gutter.prototype.getSizeAtTrack = function getSizeAtTrack$1 (track, end) {
190
+ return getSizeAtTrack(
191
+ track,
192
+ this.computedPixels,
193
+ this.computedGapPixels,
194
+ end
195
+ )
196
+ };
197
+
198
+ Gutter.prototype.getSizeOfTrack = function getSizeOfTrack (track) {
199
+ return this.computedPixels[track].numeric
200
+ };
201
+
202
+ Gutter.prototype.getRawTracks = function getRawTracks () {
203
+ var tracks = getStyles(
204
+ this.gridTemplateProp,
205
+ [this.grid],
206
+ getMatchedCSSRules(this.grid)
207
+ );
208
+ if (!tracks.length) {
209
+ if (this.optionStyle) { return this.optionStyle }
210
+
211
+ throw Error('Unable to determine grid template tracks from styles.')
212
+ }
213
+ return tracks[0]
214
+ };
215
+
216
+ Gutter.prototype.getGap = function getGap () {
217
+ var gap = getStyles(
218
+ this.gridGapProp,
219
+ [this.grid],
220
+ getMatchedCSSRules(this.grid)
221
+ );
222
+ if (!gap.length) {
223
+ return null
224
+ }
225
+ return gap[0]
226
+ };
227
+
228
+ Gutter.prototype.getRawComputedTracks = function getRawComputedTracks () {
229
+ return window.getComputedStyle(this.grid)[this.gridTemplateProp]
230
+ };
231
+
232
+ Gutter.prototype.getRawComputedGap = function getRawComputedGap () {
233
+ return window.getComputedStyle(this.grid)[this.gridGapProp]
234
+ };
235
+
236
+ Gutter.prototype.setTracks = function setTracks (raw) {
237
+ this.tracks = raw.split(' ');
238
+ this.trackValues = parse(raw);
239
+ };
240
+
241
+ Gutter.prototype.setComputedTracks = function setComputedTracks (raw) {
242
+ this.computedTracks = raw.split(' ');
243
+ this.computedPixels = parse(raw);
244
+ };
245
+
246
+ Gutter.prototype.setGap = function setGap (raw) {
247
+ this.gap = raw;
248
+ };
249
+
250
+ Gutter.prototype.setComputedGap = function setComputedGap (raw) {
251
+ this.computedGap = raw;
252
+ this.computedGapPixels = getGapValue('px', this.computedGap) || 0;
253
+ };
254
+
255
+ Gutter.prototype.getMousePosition = function getMousePosition (e) {
256
+ if ('touches' in e) { return e.touches[0][this.clientAxis] }
257
+ return e[this.clientAxis]
258
+ };
259
+
260
+ Gutter.prototype.startDragging = function startDragging (e) {
261
+ if ('button' in e && e.button !== 0) {
262
+ return
263
+ }
264
+
265
+ // Don't actually drag the element. We emulate that in the drag function.
266
+ e.preventDefault();
267
+
268
+ if (this.element) {
269
+ this.grid = this.element.parentNode;
270
+ } else {
271
+ this.grid = e.target.parentNode;
272
+ }
273
+
274
+ this.getDimensions();
275
+ this.setTracks(this.getRawTracks());
276
+ this.setComputedTracks(this.getRawComputedTracks());
277
+ this.setGap(this.getGap());
278
+ this.setComputedGap(this.getRawComputedGap());
279
+
280
+ var trackPercentage = this.trackValues.filter(
281
+ function (track) { return track.type === '%'; }
282
+ );
283
+ var trackFr = this.trackValues.filter(function (track) { return track.type === 'fr'; });
284
+
285
+ this.totalFrs = trackFr.length;
286
+
287
+ if (this.totalFrs) {
288
+ var track = firstNonZero(trackFr);
289
+
290
+ if (track !== null) {
291
+ this.frToPixels =
292
+ this.computedPixels[track].numeric / trackFr[track].numeric;
293
+ }
294
+ }
295
+
296
+ if (trackPercentage.length) {
297
+ var track$1 = firstNonZero(trackPercentage);
298
+
299
+ if (track$1 !== null) {
300
+ this.percentageToPixels =
301
+ this.computedPixels[track$1].numeric /
302
+ trackPercentage[track$1].numeric;
303
+ }
304
+ }
305
+
306
+ // get start of gutter track
307
+ var gutterStart = this.getSizeAtTrack(this.track, false) + this.start;
308
+ this.dragStartOffset = this.getMousePosition(e) - gutterStart;
309
+
310
+ this.aTrack = this.track - 1;
311
+
312
+ if (this.track < this.tracks.length - 1) {
313
+ this.bTrack = this.track + 1;
314
+ } else {
315
+ throw Error(
316
+ ("Invalid track index: " + (this.track) + ". Track must be between two other tracks and only " + (this.tracks.length) + " tracks were found.")
317
+ )
318
+ }
319
+
320
+ this.aTrackStart = this.getSizeAtTrack(this.aTrack, false) + this.start;
321
+ this.bTrackEnd = this.getSizeAtTrack(this.bTrack, true) + this.start;
322
+
323
+ // Set the dragging property of the pair object.
324
+ this.dragging = true;
325
+
326
+ // All the binding. `window` gets the stop events in case we drag out of the elements.
327
+ window.addEventListener('mouseup', this.stopDragging);
328
+ window.addEventListener('touchend', this.stopDragging);
329
+ window.addEventListener('touchcancel', this.stopDragging);
330
+ window.addEventListener('mousemove', this.drag);
331
+ window.addEventListener('touchmove', this.drag);
332
+
333
+ // Disable selection. Disable!
334
+ this.grid.addEventListener('selectstart', NOOP);
335
+ this.grid.addEventListener('dragstart', NOOP);
336
+
337
+ this.grid.style.userSelect = 'none';
338
+ this.grid.style.webkitUserSelect = 'none';
339
+ this.grid.style.MozUserSelect = 'none';
340
+ this.grid.style.pointerEvents = 'none';
341
+
342
+ // Set the cursor at multiple levels
343
+ this.grid.style.cursor = this.cursor;
344
+ window.document.body.style.cursor = this.cursor;
345
+
346
+ this.onDragStart(this.direction, this.track);
347
+ };
348
+
349
+ Gutter.prototype.stopDragging = function stopDragging () {
350
+ this.dragging = false;
351
+
352
+ // Remove the stored event listeners. This is why we store them.
353
+ this.cleanup();
354
+
355
+ this.onDragEnd(this.direction, this.track);
356
+
357
+ if (this.needsDestroy) {
358
+ if (this.element) {
359
+ this.element.removeEventListener(
360
+ 'mousedown',
361
+ this.startDragging
362
+ );
363
+ this.element.removeEventListener(
364
+ 'touchstart',
365
+ this.startDragging
366
+ );
367
+ }
368
+ this.destroyCb();
369
+ this.needsDestroy = false;
370
+ this.destroyCb = null;
371
+ }
372
+ };
373
+
374
+ Gutter.prototype.drag = function drag (e) {
375
+ var mousePosition = this.getMousePosition(e);
376
+
377
+ var gutterSize = this.getSizeOfTrack(this.track);
378
+ var minMousePosition =
379
+ this.aTrackStart +
380
+ this.minSizeStart +
381
+ this.dragStartOffset +
382
+ this.computedGapPixels;
383
+ var maxMousePosition =
384
+ this.bTrackEnd -
385
+ this.minSizeEnd -
386
+ this.computedGapPixels -
387
+ (gutterSize - this.dragStartOffset);
388
+ var minMousePositionOffset = minMousePosition + this.snapOffset;
389
+ var maxMousePositionOffset = maxMousePosition - this.snapOffset;
390
+
391
+ if (mousePosition < minMousePositionOffset) {
392
+ mousePosition = minMousePosition;
393
+ }
394
+
395
+ if (mousePosition > maxMousePositionOffset) {
396
+ mousePosition = maxMousePosition;
397
+ }
398
+
399
+ if (mousePosition < minMousePosition) {
400
+ mousePosition = minMousePosition;
401
+ } else if (mousePosition > maxMousePosition) {
402
+ mousePosition = maxMousePosition;
403
+ }
404
+
405
+ var aTrackSize =
406
+ mousePosition -
407
+ this.aTrackStart -
408
+ this.dragStartOffset -
409
+ this.computedGapPixels;
410
+ var bTrackSize =
411
+ this.bTrackEnd -
412
+ mousePosition +
413
+ this.dragStartOffset -
414
+ gutterSize -
415
+ this.computedGapPixels;
416
+
417
+ if (this.dragInterval > 1) {
418
+ var aTrackSizeIntervaled =
419
+ Math.round(aTrackSize / this.dragInterval) * this.dragInterval;
420
+ bTrackSize -= aTrackSizeIntervaled - aTrackSize;
421
+ aTrackSize = aTrackSizeIntervaled;
422
+ }
423
+
424
+ if (aTrackSize < this.minSizeStart) {
425
+ aTrackSize = this.minSizeStart;
426
+ }
427
+
428
+ if (bTrackSize < this.minSizeEnd) {
429
+ bTrackSize = this.minSizeEnd;
430
+ }
431
+
432
+ if (this.trackValues[this.aTrack].type === 'px') {
433
+ this.tracks[this.aTrack] = aTrackSize + "px";
434
+ } else if (this.trackValues[this.aTrack].type === 'fr') {
435
+ if (this.totalFrs === 1) {
436
+ this.tracks[this.aTrack] = '1fr';
437
+ } else {
438
+ var targetFr = aTrackSize / this.frToPixels;
439
+ this.tracks[this.aTrack] = targetFr + "fr";
440
+ }
441
+ } else if (this.trackValues[this.aTrack].type === '%') {
442
+ var targetPercentage = aTrackSize / this.percentageToPixels;
443
+ this.tracks[this.aTrack] = targetPercentage + "%";
444
+ }
445
+
446
+ if (this.trackValues[this.bTrack].type === 'px') {
447
+ this.tracks[this.bTrack] = bTrackSize + "px";
448
+ } else if (this.trackValues[this.bTrack].type === 'fr') {
449
+ if (this.totalFrs === 1) {
450
+ this.tracks[this.bTrack] = '1fr';
451
+ } else {
452
+ var targetFr$1 = bTrackSize / this.frToPixels;
453
+ this.tracks[this.bTrack] = targetFr$1 + "fr";
454
+ }
455
+ } else if (this.trackValues[this.bTrack].type === '%') {
456
+ var targetPercentage$1 = bTrackSize / this.percentageToPixels;
457
+ this.tracks[this.bTrack] = targetPercentage$1 + "%";
458
+ }
459
+
460
+ var style = this.tracks.join(' ');
461
+ this.writeStyle(this.grid, this.gridTemplateProp, style);
462
+ this.onDrag(this.direction, this.track, style);
463
+ };
464
+
465
+ Gutter.prototype.cleanup = function cleanup () {
466
+ window.removeEventListener('mouseup', this.stopDragging);
467
+ window.removeEventListener('touchend', this.stopDragging);
468
+ window.removeEventListener('touchcancel', this.stopDragging);
469
+ window.removeEventListener('mousemove', this.drag);
470
+ window.removeEventListener('touchmove', this.drag);
471
+
472
+ if (this.grid) {
473
+ this.grid.removeEventListener('selectstart', NOOP);
474
+ this.grid.removeEventListener('dragstart', NOOP);
475
+
476
+ this.grid.style.userSelect = '';
477
+ this.grid.style.webkitUserSelect = '';
478
+ this.grid.style.MozUserSelect = '';
479
+ this.grid.style.pointerEvents = '';
480
+
481
+ this.grid.style.cursor = '';
482
+ }
483
+
484
+ window.document.body.style.cursor = '';
485
+ };
486
+
487
+ Gutter.prototype.destroy = function destroy (immediate, cb) {
488
+ if ( immediate === void 0 ) immediate = true;
489
+
490
+ if (immediate || this.dragging === false) {
491
+ this.cleanup();
492
+ if (this.element) {
493
+ this.element.removeEventListener(
494
+ 'mousedown',
495
+ this.startDragging
496
+ );
497
+ this.element.removeEventListener(
498
+ 'touchstart',
499
+ this.startDragging
500
+ );
501
+ }
502
+
503
+ if (cb) {
504
+ cb();
505
+ }
506
+ } else {
507
+ this.needsDestroy = true;
508
+ if (cb) {
509
+ this.destroyCb = cb;
510
+ }
511
+ }
512
+ };
513
+
514
+ var getTrackOption = function (options, track, defaultValue) {
515
+ if (track in options) {
516
+ return options[track]
517
+ }
518
+
519
+ return defaultValue
520
+ };
521
+
522
+ var createGutter = function (direction, options) { return function (gutterOptions) {
523
+ if (gutterOptions.track < 1) {
524
+ throw Error(
525
+ ("Invalid track index: " + (gutterOptions.track) + ". Track must be between two other tracks.")
526
+ )
527
+ }
528
+
529
+ var trackMinSizes =
530
+ direction === 'column'
531
+ ? options.columnMinSizes || {}
532
+ : options.rowMinSizes || {};
533
+ var trackMinSize = direction === 'column' ? 'columnMinSize' : 'rowMinSize';
534
+
535
+ return new Gutter(
536
+ direction,
537
+ Object.assign({}, {minSizeStart: getTrackOption(
538
+ trackMinSizes,
539
+ gutterOptions.track - 1,
540
+ getOption(
541
+ options,
542
+ trackMinSize,
543
+ getOption(options, 'minSize', 0)
544
+ )
545
+ ),
546
+ minSizeEnd: getTrackOption(
547
+ trackMinSizes,
548
+ gutterOptions.track + 1,
549
+ getOption(
550
+ options,
551
+ trackMinSize,
552
+ getOption(options, 'minSize', 0)
553
+ )
554
+ )},
555
+ gutterOptions),
556
+ options
557
+ )
558
+ }; };
559
+
560
+ var Grid = function Grid(options) {
561
+ var this$1 = this;
562
+
563
+ this.columnGutters = {};
564
+ this.rowGutters = {};
565
+
566
+ this.options = Object.assign({}, {columnGutters: options.columnGutters || [],
567
+ rowGutters: options.rowGutters || [],
568
+ columnMinSizes: options.columnMinSizes || {},
569
+ rowMinSizes: options.rowMinSizes || {}},
570
+ options);
571
+
572
+ this.options.columnGutters.forEach(function (gutterOptions) {
573
+ this$1.columnGutters[gutterOptions.track] = createGutter(
574
+ 'column',
575
+ this$1.options
576
+ )(gutterOptions);
577
+ });
578
+
579
+ this.options.rowGutters.forEach(function (gutterOptions) {
580
+ this$1.rowGutters[gutterOptions.track] = createGutter(
581
+ 'row',
582
+ this$1.options
583
+ )(gutterOptions);
584
+ });
585
+ };
586
+
587
+ Grid.prototype.addColumnGutter = function addColumnGutter (element, track) {
588
+ if (this.columnGutters[track]) {
589
+ this.columnGutters[track].destroy();
590
+ }
591
+
592
+ this.columnGutters[track] = createGutter(
593
+ 'column',
594
+ this.options
595
+ )({
596
+ element: element,
597
+ track: track,
598
+ });
599
+ };
600
+
601
+ Grid.prototype.addRowGutter = function addRowGutter (element, track) {
602
+ if (this.rowGutters[track]) {
603
+ this.rowGutters[track].destroy();
604
+ }
605
+
606
+ this.rowGutters[track] = createGutter(
607
+ 'row',
608
+ this.options
609
+ )({
610
+ element: element,
611
+ track: track,
612
+ });
613
+ };
614
+
615
+ Grid.prototype.removeColumnGutter = function removeColumnGutter (track, immediate) {
616
+ var this$1 = this;
617
+ if ( immediate === void 0 ) immediate = true;
618
+
619
+ if (this.columnGutters[track]) {
620
+ this.columnGutters[track].destroy(immediate, function () {
621
+ delete this$1.columnGutters[track];
622
+ });
623
+ }
624
+ };
625
+
626
+ Grid.prototype.removeRowGutter = function removeRowGutter (track, immediate) {
627
+ var this$1 = this;
628
+ if ( immediate === void 0 ) immediate = true;
629
+
630
+ if (this.rowGutters[track]) {
631
+ this.rowGutters[track].destroy(immediate, function () {
632
+ delete this$1.rowGutters[track];
633
+ });
634
+ }
635
+ };
636
+
637
+ Grid.prototype.handleDragStart = function handleDragStart (e, direction, track) {
638
+ if (direction === 'column') {
639
+ if (this.columnGutters[track]) {
640
+ this.columnGutters[track].destroy();
641
+ }
642
+
643
+ this.columnGutters[track] = createGutter(
644
+ 'column',
645
+ this.options
646
+ )({
647
+ track: track,
648
+ });
649
+ this.columnGutters[track].startDragging(e);
650
+ } else if (direction === 'row') {
651
+ if (this.rowGutters[track]) {
652
+ this.rowGutters[track].destroy();
653
+ }
654
+
655
+ this.rowGutters[track] = createGutter(
656
+ 'row',
657
+ this.options
658
+ )({
659
+ track: track,
660
+ });
661
+ this.rowGutters[track].startDragging(e);
662
+ }
663
+ };
664
+
665
+ Grid.prototype.destroy = function destroy (immediate) {
666
+ var this$1 = this;
667
+ if ( immediate === void 0 ) immediate = true;
668
+
669
+ Object.keys(this.columnGutters).forEach(function (track) { return this$1.columnGutters[track].destroy(immediate, function () {
670
+ delete this$1.columnGutters[track];
671
+ }); }
672
+ );
673
+ Object.keys(this.rowGutters).forEach(function (track) { return this$1.rowGutters[track].destroy(immediate, function () {
674
+ delete this$1.rowGutters[track];
675
+ }); }
676
+ );
677
+ };
678
+
679
+ function index (options) { return new Grid(options); }
680
+
681
+ const ezSplitPanelCss = ".ez-split-gutter{cursor:grab;background-color:transparent}";
682
+
683
+ const SplitPanel = class {
684
+ constructor(hostRef) {
685
+ registerInstance(this, hostRef);
686
+ this._items = [];
687
+ this.direction = 'column';
688
+ }
689
+ componentDidLoad() {
690
+ this._panelID = StringUtils.generateUUID();
691
+ this._element.dataset.panelId = this._panelID;
692
+ let itemsElements = Array.from(this._element.children);
693
+ this._items = itemsElements.filter(child => { var _a; return ((_a = child.tagName) === null || _a === void 0 ? void 0 : _a.toUpperCase()) === 'EZ-SPLIT-ITEM'; });
694
+ let trackCount = 1;
695
+ this._items.forEach((item, index) => {
696
+ item.dataset.trackNumber = trackCount.toString();
697
+ if (this._items.length > 1 && index != this._items.length - 1) {
698
+ this.addItemGutter(item);
699
+ }
700
+ trackCount += 2;
701
+ });
702
+ this.initSplit();
703
+ }
704
+ initSplit() {
705
+ if (!this._items.length) {
706
+ return;
707
+ }
708
+ this._element.style[this.direction == 'row' ? 'grid-template-rows' : 'grid-template-columns'] = this.getGridTemplate();
709
+ index(this.getGutters());
710
+ }
711
+ getGutters() {
712
+ const gutters = {
713
+ columnGutters: [],
714
+ rowGutters: []
715
+ };
716
+ if (!this._items.length) {
717
+ return gutters;
718
+ }
719
+ const proToChange = this.direction == 'row' ? 'rowGutters' : 'columnGutters';
720
+ this._items.forEach((item, index) => {
721
+ if (index == this._items.length - 1)
722
+ return;
723
+ let gutterTrack = item.dataset.trackNumber;
724
+ if (index === (this._items.length - 1)) {
725
+ gutterTrack = this._items.length.toString();
726
+ }
727
+ gutters[proToChange].push({
728
+ track: Number(gutterTrack),
729
+ element: this._element.querySelector(`ez-split-panel[data-panel-id="${this._panelID}"] > [data-item-track="${item.dataset.trackNumber}"]`)
730
+ });
731
+ });
732
+ return gutters;
733
+ }
734
+ addItemGutter(item) {
735
+ const gutter = document.createElement('div');
736
+ gutter.classList.add("ez-split-gutter");
737
+ gutter.classList.add(this.direction);
738
+ gutter.dataset.itemTrack = `${item.dataset.trackNumber}`;
739
+ gutter.dataset.trackNumber = (Number(item.dataset.trackNumber) + 1).toString();
740
+ item.parentNode.insertBefore(gutter, item.nextSibling);
741
+ }
742
+ getElementStyle() {
743
+ const style = {
744
+ 'display': "grid",
745
+ 'height': '100%',
746
+ 'width': '100%'
747
+ };
748
+ return style;
749
+ }
750
+ getGridTemplate() {
751
+ let template = '';
752
+ this._items.forEach((_col, index) => {
753
+ if (index === this._items.length - 1) {
754
+ template += ` 1fr`;
755
+ return;
756
+ }
757
+ if (index === 0) {
758
+ template += `1fr 5px`;
759
+ return;
760
+ }
761
+ template += ` 1fr 5px`;
762
+ });
763
+ return template;
764
+ }
765
+ render() {
766
+ return (h(Host, { style: this.getElementStyle() }));
767
+ }
768
+ get _element() { return getElement(this); }
769
+ };
770
+ SplitPanel.style = ezSplitPanelCss;
771
+
772
+ export { SplitPanel as ez_split_panel };