@sme.up/ketchup 5.0.0 → 5.2.1-SNAPSHOT

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 (224) hide show
  1. package/README.md +1 -1
  2. package/dist/cjs/{cell-utils-720be0c8.js → cell-utils-d96b2993.js} +4 -4
  3. package/dist/cjs/{f-button-dbf3cd3a.js → f-button-2b9b99b1.js} +2 -2
  4. package/dist/cjs/{f-cell-93d984ad.js → f-cell-8351cb84.js} +8 -96
  5. package/dist/cjs/{f-chip-438213eb.js → f-chip-df59e1b0.js} +3 -3
  6. package/dist/cjs/{f-image-21865ab7.js → f-image-12bab3b5.js} +2 -2
  7. package/dist/cjs/f-text-field-e7c35b5b.js +94 -0
  8. package/dist/cjs/f-text-field-mdc-a67f5dfe.js +2852 -0
  9. package/dist/cjs/{index-ab119fad.js → index-eb556444.js} +6 -1
  10. package/dist/cjs/ketchup.cjs.js +3 -3
  11. package/dist/cjs/kup-accordion.cjs.entry.js +5 -5
  12. package/dist/cjs/kup-autocomplete_27.cjs.entry.js +641 -3331
  13. package/dist/cjs/kup-calendar.cjs.entry.js +8 -8
  14. package/dist/cjs/kup-cell.cjs.entry.js +9 -8
  15. package/dist/cjs/kup-dash-list.cjs.entry.js +5 -5
  16. package/dist/cjs/kup-dash_2.cjs.entry.js +5 -5
  17. package/dist/cjs/kup-drawer.cjs.entry.js +8 -5
  18. package/dist/cjs/kup-echart.cjs.entry.js +210 -60
  19. package/dist/cjs/kup-field.cjs.entry.js +3 -3
  20. package/dist/cjs/kup-iframe.cjs.entry.js +4 -4
  21. package/dist/cjs/kup-lazy.cjs.entry.js +4 -4
  22. package/dist/cjs/kup-magic-box.cjs.entry.js +7 -7
  23. package/dist/cjs/{kup-manager-09c0c1fc.js → kup-manager-5c03da64.js} +3061 -2642
  24. package/dist/cjs/kup-nav-bar.cjs.entry.js +6 -6
  25. package/dist/cjs/kup-numeric-picker.cjs.entry.js +423 -0
  26. package/dist/cjs/kup-photo-frame.cjs.entry.js +179 -0
  27. package/dist/cjs/kup-probe.cjs.entry.js +3 -3
  28. package/dist/cjs/kup-qlik.cjs.entry.js +3 -3
  29. package/dist/cjs/kup-snackbar.cjs.entry.js +6 -6
  30. package/dist/cjs/loader.cjs.js +3 -3
  31. package/dist/cjs/{utils-a60ab5fa.js → utils-e99921c1.js} +4 -38
  32. package/dist/collection/assets/card.js +30 -30
  33. package/dist/collection/assets/data-table.js +24 -74
  34. package/dist/collection/assets/echart.js +481 -0
  35. package/dist/collection/assets/index.js +87 -79
  36. package/dist/collection/assets/kupdata.js +29 -41
  37. package/dist/collection/assets/kuptooltip.js +608 -0
  38. package/dist/collection/assets/list.js +6 -6
  39. package/dist/collection/assets/nav-bar.js +4 -4
  40. package/dist/collection/assets/probe.js +18 -18
  41. package/dist/collection/collection-manifest.json +3 -1
  42. package/dist/collection/components/kup-autocomplete/kup-autocomplete.js +4 -4
  43. package/dist/collection/components/kup-box/kup-box.js +9 -9
  44. package/dist/collection/components/kup-button-list/kup-button-list.js +4 -4
  45. package/dist/collection/components/kup-card/built-in/kup-card-built-in.js +10 -0
  46. package/dist/collection/components/kup-card/built-in/kup-card-column-drop-menu.js +20 -20
  47. package/dist/collection/components/kup-card/built-in/kup-card-numeric.js +153 -0
  48. package/dist/collection/components/kup-card/kup-card.css +35 -0
  49. package/dist/collection/components/kup-card/kup-card.js +1 -0
  50. package/dist/collection/components/kup-chip/kup-chip.js +4 -4
  51. package/dist/collection/components/kup-combobox/kup-combobox.js +5 -5
  52. package/dist/collection/components/kup-data-table/kup-data-table-declarations.js +0 -2
  53. package/dist/collection/components/kup-data-table/kup-data-table-helper.js +31 -32
  54. package/dist/collection/components/kup-data-table/kup-data-table-state.js +1 -1
  55. package/dist/collection/components/kup-data-table/kup-data-table.js +112 -159
  56. package/dist/collection/components/kup-date-picker/kup-date-picker.js +1 -1
  57. package/dist/collection/components/kup-drawer/kup-drawer.js +4 -1
  58. package/dist/collection/components/kup-dropdown-button/kup-dropdown-button.css +3 -3
  59. package/dist/collection/components/kup-dropdown-button/kup-dropdown-button.js +14 -14
  60. package/dist/collection/components/kup-echart/kup-echart-declarations.js +3 -0
  61. package/dist/collection/components/kup-echart/kup-echart.js +246 -58
  62. package/dist/collection/components/kup-image/assets/svg/instagram.svg +1 -0
  63. package/dist/collection/components/kup-image/assets/svg/pinterest.svg +1 -0
  64. package/dist/collection/components/kup-image/assets/svg/reddit.svg +1 -0
  65. package/dist/collection/components/kup-list/kup-list-helper.js +26 -26
  66. package/dist/collection/components/kup-list/kup-list.css +35 -3
  67. package/dist/collection/components/kup-list/kup-list.js +52 -44
  68. package/dist/collection/components/kup-magic-box/kup-magic-box.js +3 -3
  69. package/dist/collection/components/kup-nav-bar/kup-nav-bar.js +2 -2
  70. package/dist/collection/components/kup-numeric-picker/kup-numeric-picker-declarations.js +16 -0
  71. package/dist/collection/components/kup-numeric-picker/kup-numeric-picker.css +50 -0
  72. package/dist/collection/components/kup-numeric-picker/kup-numeric-picker.js +895 -0
  73. package/dist/collection/components/kup-photo-frame/kup-photo-frame-declarations.js +10 -0
  74. package/dist/collection/components/kup-photo-frame/kup-photo-frame.css +70 -0
  75. package/dist/collection/components/kup-photo-frame/kup-photo-frame.js +382 -0
  76. package/dist/collection/components/kup-tab-bar/kup-tab-bar.css +1 -1
  77. package/dist/collection/components/kup-time-picker/kup-time-picker.js +8 -8
  78. package/dist/collection/components/kup-tree/kup-tree.js +25 -38
  79. package/dist/collection/f-components/f-paginator/f-paginator.js +6 -6
  80. package/dist/collection/managers/kup-data/kup-data-cell-helper.js +2 -2
  81. package/dist/collection/managers/kup-data/kup-data-column-helper.js +27 -3
  82. package/dist/collection/managers/kup-data/kup-data-declarations.js +2 -1
  83. package/dist/collection/managers/kup-data/kup-data-node-helper.js +1 -1
  84. package/dist/collection/managers/kup-data/kup-data-row-helper.js +2 -2
  85. package/dist/collection/managers/kup-data/kup-data.js +337 -155
  86. package/dist/collection/managers/kup-dates/kup-dates.js +2 -2
  87. package/dist/collection/managers/kup-debug/kup-debug.js +7 -6
  88. package/dist/collection/managers/kup-dynamic-position/kup-dynamic-position.js +1 -1
  89. package/dist/collection/managers/kup-language/kup-language.js +2 -2
  90. package/dist/collection/managers/kup-manager/kup-manager.js +25 -1
  91. package/dist/collection/managers/kup-math/kup-math-declarations.js +13 -0
  92. package/dist/collection/managers/kup-math/kup-math-helper.js +39 -0
  93. package/dist/collection/managers/kup-math/kup-math.js +161 -0
  94. package/dist/collection/managers/kup-objects/kup-objects.js +48 -1
  95. package/dist/collection/managers/kup-theme/kup-theme-declarations.js +1 -0
  96. package/dist/collection/managers/kup-theme/kup-theme.js +2 -2
  97. package/dist/collection/managers/kup-tooltip/kup-tooltip-declarations.js +1 -0
  98. package/dist/collection/managers/kup-tooltip/kup-tooltip.js +191 -0
  99. package/dist/collection/types/GenericTypes.js +1 -0
  100. package/dist/collection/utils/cell-utils.js +2 -3
  101. package/dist/collection/utils/kup-column-menu/kup-column-menu.js +1 -1
  102. package/dist/collection/utils/utils.js +3 -74
  103. package/dist/esm/{cell-utils-b80ccb8c.js → cell-utils-f4bdbbc8.js} +4 -4
  104. package/dist/esm/{f-button-9e835467.js → f-button-54a49fd8.js} +2 -2
  105. package/dist/esm/{f-cell-f8bb2e04.js → f-cell-d5dac50b.js} +8 -95
  106. package/dist/esm/{f-chip-953c6915.js → f-chip-a3035b4b.js} +3 -3
  107. package/dist/esm/{f-image-78c5265e.js → f-image-d32465e3.js} +2 -2
  108. package/dist/esm/f-text-field-c25cc63f.js +92 -0
  109. package/dist/esm/f-text-field-mdc-9fbbefc3.js +2850 -0
  110. package/dist/esm/{index-78f3699d.js → index-baeab1ac.js} +6 -2
  111. package/dist/esm/ketchup.js +3 -3
  112. package/dist/esm/kup-accordion.entry.js +5 -5
  113. package/dist/esm/kup-autocomplete_27.entry.js +625 -3315
  114. package/dist/esm/kup-calendar.entry.js +8 -8
  115. package/dist/esm/kup-cell.entry.js +9 -8
  116. package/dist/esm/kup-dash-list.entry.js +5 -5
  117. package/dist/esm/kup-dash_2.entry.js +5 -5
  118. package/dist/esm/kup-drawer.entry.js +8 -5
  119. package/dist/esm/kup-echart.entry.js +210 -60
  120. package/dist/esm/kup-field.entry.js +3 -3
  121. package/dist/esm/kup-iframe.entry.js +4 -4
  122. package/dist/esm/kup-lazy.entry.js +4 -4
  123. package/dist/esm/kup-magic-box.entry.js +7 -7
  124. package/dist/esm/{kup-manager-bba62291.js → kup-manager-9316a184.js} +3062 -2642
  125. package/dist/esm/kup-nav-bar.entry.js +6 -6
  126. package/dist/esm/kup-numeric-picker.entry.js +419 -0
  127. package/dist/esm/kup-photo-frame.entry.js +175 -0
  128. package/dist/esm/kup-probe.entry.js +3 -3
  129. package/dist/esm/kup-qlik.entry.js +3 -3
  130. package/dist/esm/kup-snackbar.entry.js +6 -6
  131. package/dist/esm/loader.js +3 -3
  132. package/dist/esm/{utils-d1569956.js → utils-f24319a0.js} +5 -37
  133. package/dist/ketchup/assets/svg/instagram.svg +1 -0
  134. package/dist/ketchup/assets/svg/pinterest.svg +1 -0
  135. package/dist/ketchup/assets/svg/reddit.svg +1 -0
  136. package/dist/ketchup/ketchup.esm.js +1 -1
  137. package/dist/ketchup/p-09d708c4.entry.js +1 -0
  138. package/dist/ketchup/p-11e72a8c.entry.js +1 -0
  139. package/dist/ketchup/p-12773ca8.js +9 -0
  140. package/dist/ketchup/p-203d6295.entry.js +1 -0
  141. package/dist/ketchup/p-34748c91.js +1 -0
  142. package/dist/ketchup/p-34b74425.js +1 -0
  143. package/dist/ketchup/p-40f97429.js +1 -0
  144. package/dist/ketchup/p-4173422f.entry.js +1 -0
  145. package/dist/ketchup/p-41741c28.entry.js +1 -0
  146. package/dist/ketchup/p-44192f30.entry.js +1 -0
  147. package/dist/ketchup/{p-ebf4cf56.js → p-44f8da2a.js} +1 -1
  148. package/dist/ketchup/{p-fa540f82.js → p-4f56932b.js} +1 -1
  149. package/dist/ketchup/p-669bde31.js +1 -0
  150. package/dist/ketchup/p-67842f1e.entry.js +1 -0
  151. package/dist/ketchup/{p-f993f813.js → p-7a74ad17.js} +1 -1
  152. package/dist/ketchup/p-7ba8fa4a.entry.js +39 -0
  153. package/dist/ketchup/p-7de0d7e1.js +1 -0
  154. package/dist/ketchup/p-8418e8fa.entry.js +1 -0
  155. package/dist/ketchup/p-96bf19aa.entry.js +1 -0
  156. package/dist/ketchup/p-9a61d8dc.entry.js +1 -0
  157. package/dist/ketchup/p-b0ddcce9.entry.js +9 -0
  158. package/dist/ketchup/{p-aa27f9f7.entry.js → p-b6c21223.entry.js} +2 -2
  159. package/dist/ketchup/p-bb8844bf.entry.js +1 -0
  160. package/dist/ketchup/p-c58a2a81.entry.js +1 -0
  161. package/dist/ketchup/p-ca3d585b.entry.js +1 -0
  162. package/dist/ketchup/p-e6709c26.entry.js +1 -0
  163. package/dist/ketchup/p-e8e3c9da.entry.js +1 -0
  164. package/dist/ketchup/p-ecb7069b.js +135 -0
  165. package/dist/types/components/kup-button-list/kup-button-list-declarations.d.ts +2 -1
  166. package/dist/types/components/kup-card/built-in/kup-card-built-in.d.ts +7 -0
  167. package/dist/types/components/kup-card/built-in/kup-card-numeric.d.ts +2 -0
  168. package/dist/types/components/kup-card/kup-card-declarations.d.ts +26 -1
  169. package/dist/types/components/kup-data-table/kup-data-table-declarations.d.ts +2 -2
  170. package/dist/types/components/kup-data-table/kup-data-table-state.d.ts +1 -1
  171. package/dist/types/components/kup-data-table/kup-data-table.d.ts +7 -15
  172. package/dist/types/components/kup-dropdown-button/kup-dropdown-button.d.ts +1 -1
  173. package/dist/types/components/kup-echart/kup-echart-declarations.d.ts +3 -0
  174. package/dist/types/components/kup-echart/kup-echart.d.ts +12 -1
  175. package/dist/types/components/kup-list/kup-list-declarations.d.ts +3 -7
  176. package/dist/types/components/kup-list/kup-list-helper.d.ts +6 -6
  177. package/dist/types/components/kup-list/kup-list.d.ts +2 -2
  178. package/dist/types/components/kup-numeric-picker/kup-numeric-picker-declarations.d.ts +19 -0
  179. package/dist/types/components/kup-numeric-picker/kup-numeric-picker.d.ts +121 -0
  180. package/dist/types/components/kup-photo-frame/kup-photo-frame-declarations.d.ts +9 -0
  181. package/dist/types/components/kup-photo-frame/kup-photo-frame.d.ts +61 -0
  182. package/dist/types/components.d.ts +249 -28
  183. package/dist/types/managers/kup-data/kup-data-column-helper.d.ts +9 -1
  184. package/dist/types/managers/kup-data/kup-data-declarations.d.ts +4 -25
  185. package/dist/types/managers/kup-data/kup-data-node-helper.d.ts +1 -1
  186. package/dist/types/managers/kup-data/kup-data.d.ts +63 -27
  187. package/dist/types/managers/kup-manager/kup-manager-declarations.d.ts +21 -0
  188. package/dist/types/managers/kup-manager/kup-manager.d.ts +4 -0
  189. package/dist/types/managers/kup-math/kup-math-declarations.d.ts +27 -0
  190. package/dist/types/managers/kup-math/kup-math-helper.d.ts +17 -0
  191. package/dist/types/managers/kup-math/kup-math.d.ts +61 -0
  192. package/dist/types/managers/kup-objects/kup-objects.d.ts +22 -0
  193. package/dist/types/managers/kup-tooltip/kup-tooltip-declarations.d.ts +8 -0
  194. package/dist/types/managers/kup-tooltip/kup-tooltip.d.ts +40 -0
  195. package/dist/types/types/GenericTypes.d.ts +1 -0
  196. package/dist/types/utils/utils.d.ts +0 -18
  197. package/package.json +3 -3
  198. package/CHANGELOG.md +0 -5
  199. package/dist/collection/managers/kup-data/kup-data-dataset-helper.js +0 -262
  200. package/dist/collection/managers/kup-data/kup-data-helper.js +0 -61
  201. package/dist/collection/utils/state-utils.js +0 -9
  202. package/dist/ketchup/p-0032a782.entry.js +0 -1
  203. package/dist/ketchup/p-18c4d083.entry.js +0 -1
  204. package/dist/ketchup/p-199c972e.entry.js +0 -1
  205. package/dist/ketchup/p-29800a2e.js +0 -1
  206. package/dist/ketchup/p-34aa8d8a.entry.js +0 -1
  207. package/dist/ketchup/p-542279e9.entry.js +0 -1
  208. package/dist/ketchup/p-5b26a7a8.entry.js +0 -39
  209. package/dist/ketchup/p-5c97e7ab.js +0 -1
  210. package/dist/ketchup/p-6817ca85.entry.js +0 -1
  211. package/dist/ketchup/p-76e674ca.entry.js +0 -1
  212. package/dist/ketchup/p-78aa6f1b.js +0 -1
  213. package/dist/ketchup/p-842b66aa.entry.js +0 -1
  214. package/dist/ketchup/p-894981c0.entry.js +0 -143
  215. package/dist/ketchup/p-8ac2fa75.entry.js +0 -1
  216. package/dist/ketchup/p-907c9e11.entry.js +0 -1
  217. package/dist/ketchup/p-9ae9149b.entry.js +0 -1
  218. package/dist/ketchup/p-b0d1bdd8.js +0 -9
  219. package/dist/ketchup/p-e1e4c951.entry.js +0 -1
  220. package/dist/ketchup/p-eba369d9.entry.js +0 -1
  221. package/dist/ketchup/p-ed0b8666.js +0 -1
  222. package/dist/types/managers/kup-data/kup-data-dataset-helper.d.ts +0 -42
  223. package/dist/types/managers/kup-data/kup-data-helper.d.ts +0 -11
  224. package/dist/types/utils/state-utils.d.ts +0 -1
@@ -2,7 +2,7 @@ import { Component, Element, Event, forceUpdate, h, Host, Method, Prop, State, W
2
2
  import { FixedCellsClasses, FixedCellsCSSVarsBase, GroupLabelDisplayMode, LoadMoreMode, PaginatorPos, ShowGrid, SortMode, TotalMode, TotalLabel, KupDataTableProps, fieldColumn, iconColumn, keyColumn, SelectionMode, } from './kup-data-table-declarations';
3
3
  import { getColumnByName } from '../../utils/cell-utils';
4
4
  import { calcTotals, normalizeRows, filterRows, groupRows, paginateRows, sortRows, } from './kup-data-table-helper';
5
- import { numberToFormattedStringNumber, identify, deepEqual, getProps, setProps, } from '../../utils/utils';
5
+ import { numberToFormattedStringNumber, identify, getProps, setProps, } from '../../utils/utils';
6
6
  import { ItemsDisplayMode, } from '../kup-list/kup-list-declarations';
7
7
  import { kupManagerInstance, } from '../../managers/kup-manager/kup-manager';
8
8
  import { KupDataTableState } from './kup-data-table-state';
@@ -379,8 +379,6 @@ export class KupDataTable {
379
379
  this.pageSelected = state.pageSelected;
380
380
  this.sortableColumnsMutateData =
381
381
  state.sortableColumnsMutateData;
382
- this.selectRow = state.selectRow;
383
- this.selectRowsById = state.selectRowsById;
384
382
  this.dragEnabled = state.dragEnabled;
385
383
  this.dropEnabled = state.dropEnabled;
386
384
  this.showFooter = state.showFooter;
@@ -391,116 +389,116 @@ export class KupDataTable {
391
389
  persistState() {
392
390
  if (this.store && this.stateId) {
393
391
  let somethingChanged = false;
394
- if (!deepEqual(this.state.filters, this.filters)) {
392
+ if (!this.kupManager.objects.deepEqual(this.state.filters, this.filters)) {
395
393
  this.state.filters = Object.assign({}, this.filters);
396
394
  somethingChanged = true;
397
395
  }
398
- if (!deepEqual(this.state.groups, this.groups)) {
396
+ if (!this.kupManager.objects.deepEqual(this.state.groups, this.groups)) {
399
397
  this.state.groups = [...this.groups];
400
398
  somethingChanged = true;
401
399
  }
402
- if (!deepEqual(this.state.sort, this.sort)) {
400
+ if (!this.kupManager.objects.deepEqual(this.state.sort, this.sort)) {
403
401
  this.state.sort = [...this.sort];
404
402
  somethingChanged = true;
405
403
  }
406
- if (!deepEqual(this.state.expandGroups, this.expandGroups)) {
404
+ if (!this.kupManager.objects.deepEqual(this.state.expandGroups, this.expandGroups)) {
407
405
  this.state.expandGroups = this.expandGroups;
408
406
  somethingChanged = true;
409
407
  }
410
- if (!deepEqual(this.state.groupLabelDisplay, this.groupLabelDisplay)) {
408
+ if (!this.kupManager.objects.deepEqual(this.state.groupLabelDisplay, this.groupLabelDisplay)) {
411
409
  this.state.groupLabelDisplay = this.groupLabelDisplay;
412
410
  somethingChanged = true;
413
411
  }
414
- if (!deepEqual(this.state.density, this.density)) {
412
+ if (!this.kupManager.objects.deepEqual(this.state.density, this.density)) {
415
413
  this.state.density = this.density;
416
414
  somethingChanged = true;
417
415
  }
418
- if (!deepEqual(this.state.enableExtraColumns, this.enableExtraColumns)) {
416
+ if (!this.kupManager.objects.deepEqual(this.state.enableExtraColumns, this.enableExtraColumns)) {
419
417
  this.state.enableExtraColumns = this.enableExtraColumns;
420
418
  somethingChanged = true;
421
419
  }
422
- if (!deepEqual(this.state.enableSortableColumns, this.enableSortableColumns)) {
420
+ if (!this.kupManager.objects.deepEqual(this.state.enableSortableColumns, this.enableSortableColumns)) {
423
421
  this.state.enableSortableColumns = this.enableSortableColumns;
424
422
  somethingChanged = true;
425
423
  }
426
- if (!deepEqual(this.state.forceOneLine, this.forceOneLine)) {
424
+ if (!this.kupManager.objects.deepEqual(this.state.forceOneLine, this.forceOneLine)) {
427
425
  this.state.forceOneLine = this.forceOneLine;
428
426
  somethingChanged = true;
429
427
  }
430
- if (!deepEqual(this.state.globalFilter, this.globalFilter)) {
428
+ if (!this.kupManager.objects.deepEqual(this.state.globalFilter, this.globalFilter)) {
431
429
  this.state.globalFilter = this.globalFilter;
432
430
  somethingChanged = true;
433
431
  }
434
- if (!deepEqual(this.state.globalFilterValue, this.globalFilterValue)) {
432
+ if (!this.kupManager.objects.deepEqual(this.state.globalFilterValue, this.globalFilterValue)) {
435
433
  this.state.globalFilterValue = this.globalFilterValue;
436
434
  somethingChanged = true;
437
435
  }
438
- if (!deepEqual(this.state.headerIsPersistent, this.headerIsPersistent)) {
436
+ if (!this.kupManager.objects.deepEqual(this.state.headerIsPersistent, this.headerIsPersistent)) {
439
437
  this.state.headerIsPersistent = this.headerIsPersistent;
440
438
  somethingChanged = true;
441
439
  }
442
- if (!deepEqual(this.state.lazyLoadRows, this.lazyLoadRows)) {
440
+ if (!this.kupManager.objects.deepEqual(this.state.lazyLoadRows, this.lazyLoadRows)) {
443
441
  this.state.lazyLoadRows = this.lazyLoadRows;
444
442
  somethingChanged = true;
445
443
  }
446
- if (!deepEqual(this.state.loadMoreLimit, this.loadMoreLimit)) {
444
+ if (!this.kupManager.objects.deepEqual(this.state.loadMoreLimit, this.loadMoreLimit)) {
447
445
  this.state.loadMoreLimit = this.loadMoreLimit;
448
446
  somethingChanged = true;
449
447
  }
450
- if (!deepEqual(this.state.selection, this.selection)) {
448
+ if (!this.kupManager.objects.deepEqual(this.state.selection, this.selection)) {
451
449
  this.state.selection = this.selection;
452
450
  somethingChanged = true;
453
451
  }
454
- if (!deepEqual(this.state.rowsPerPage, this.currentRowsPerPage)) {
452
+ if (!this.kupManager.objects.deepEqual(this.state.rowsPerPage, this.currentRowsPerPage)) {
455
453
  this.state.rowsPerPage = this.currentRowsPerPage;
456
454
  somethingChanged = true;
457
455
  }
458
- if (!deepEqual(this.state.showFilters, this.showFilters)) {
456
+ if (!this.kupManager.objects.deepEqual(this.state.showFilters, this.showFilters)) {
459
457
  this.state.showFilters = this.showFilters;
460
458
  somethingChanged = true;
461
459
  }
462
- if (!deepEqual(this.state.showGroups, this.showGroups)) {
460
+ if (!this.kupManager.objects.deepEqual(this.state.showGroups, this.showGroups)) {
463
461
  this.state.showGroups = this.showGroups;
464
462
  somethingChanged = true;
465
463
  }
466
- if (!deepEqual(this.state.showHeader, this.showHeader)) {
464
+ if (!this.kupManager.objects.deepEqual(this.state.showHeader, this.showHeader)) {
467
465
  this.state.showHeader = this.showHeader;
468
466
  somethingChanged = true;
469
467
  }
470
- if (!deepEqual(this.state.showLoadMore, this.showLoadMore)) {
468
+ if (!this.kupManager.objects.deepEqual(this.state.showLoadMore, this.showLoadMore)) {
471
469
  this.state.showLoadMore = this.showLoadMore;
472
470
  somethingChanged = true;
473
471
  }
474
- if (!deepEqual(this.state.sortEnabled, this.sortEnabled)) {
472
+ if (!this.kupManager.objects.deepEqual(this.state.sortEnabled, this.sortEnabled)) {
475
473
  this.state.sortEnabled = this.sortEnabled;
476
474
  somethingChanged = true;
477
475
  }
478
- if (!deepEqual(this.state.sortableColumnsMutateData, this.sortableColumnsMutateData)) {
476
+ if (!this.kupManager.objects.deepEqual(this.state.sortableColumnsMutateData, this.sortableColumnsMutateData)) {
479
477
  this.state.sortableColumnsMutateData =
480
478
  this.sortableColumnsMutateData;
481
479
  somethingChanged = true;
482
480
  }
483
- if (!deepEqual(this.state.pageSelected, this.currentPage)) {
481
+ if (!this.kupManager.objects.deepEqual(this.state.pageSelected, this.currentPage)) {
484
482
  this.state.pageSelected = this.currentPage;
485
483
  somethingChanged = true;
486
484
  }
487
- if (!deepEqual(this.state.dragEnabled, this.dragEnabled)) {
485
+ if (!this.kupManager.objects.deepEqual(this.state.dragEnabled, this.dragEnabled)) {
488
486
  this.state.dragEnabled = this.dragEnabled;
489
487
  somethingChanged = true;
490
488
  }
491
- if (!deepEqual(this.state.dropEnabled, this.dropEnabled)) {
489
+ if (!this.kupManager.objects.deepEqual(this.state.dropEnabled, this.dropEnabled)) {
492
490
  this.state.dropEnabled = this.dropEnabled;
493
491
  somethingChanged = true;
494
492
  }
495
- if (!deepEqual(this.state.showFooter, this.showFooter)) {
493
+ if (!this.kupManager.objects.deepEqual(this.state.showFooter, this.showFooter)) {
496
494
  this.state.showFooter = this.showFooter;
497
495
  somethingChanged = true;
498
496
  }
499
- if (!deepEqual(this.state.totals, this.totals)) {
497
+ if (!this.kupManager.objects.deepEqual(this.state.totals, this.totals)) {
500
498
  this.state.totals = Object.assign({}, this.totals);
501
499
  somethingChanged = true;
502
500
  }
503
- if (!deepEqual(this.state.selectRowsById, this.selectedRows.reduce((accumulator, row, currentIndex) => {
501
+ if (!this.kupManager.objects.deepEqual(this.state.selectRowsById, this.selectedRows.reduce((accumulator, row, currentIndex) => {
504
502
  const prefix = currentIndex > 0 ? ';' : '';
505
503
  return accumulator + prefix + row.id;
506
504
  }, ''))) {
@@ -605,14 +603,18 @@ export class KupDataTable {
605
603
  async getProps(descriptions) {
606
604
  return getProps(this, KupDataTableProps, descriptions);
607
605
  }
606
+ /**
607
+ * This method will get the selected rows of the component.
608
+ */
609
+ async getSelectedRows() {
610
+ return this.selectedRows;
611
+ }
608
612
  /**
609
613
  * Hides the given column.
610
614
  * @param {KupDataColumn} column - Column to hide.
611
615
  */
612
616
  async hideColumn(column) {
613
- this.kupManager.data.datasetOperations.column.hide(this.data, [
614
- column.name,
615
- ]);
617
+ this.kupManager.data.column.hide(this.data, [column.name]);
616
618
  this.kupColumnRemove.emit({
617
619
  comp: this,
618
620
  id: this.rootElement.id,
@@ -627,7 +629,7 @@ export class KupDataTable {
627
629
  * @returns {string|KupDataColumn} Returns the new column created or a string containing the error message if something went wrong.
628
630
  */
629
631
  async newColumn(type, options) {
630
- const result = this.kupManager.data.datasetOperations.column.new(this.data, type, options);
632
+ const result = this.kupManager.data.column.new(this.data, type, options);
631
633
  const error = !!(typeof result === 'string' || result instanceof String);
632
634
  if (!error) {
633
635
  this.refresh();
@@ -729,15 +731,20 @@ export class KupDataTable {
729
731
  }
730
732
  /**
731
733
  * This method will set the selected rows of the component.
732
- * @param {string} rowsById - String containing the ids separated by ";".
734
+ * @param {string|number[]} rowsIdentifiers - Array of ids (dataset) or indexes (rendered rows).
733
735
  * @param {boolean} emitEvent - The event will always be emitted unless emitEvent is set to false.
734
736
  */
735
- async setSelectedRows(rowsById, emitEvent) {
737
+ async setSelectedRows(rowsIdentifiers, emitEvent) {
736
738
  this.selectedRows = [];
737
- if (rowsById) {
738
- this.selectedRows = this.renderedRows.filter((r) => {
739
- return rowsById.split(';').indexOf(r.id) >= 0;
740
- });
739
+ for (let index = 0; index < rowsIdentifiers.length; index++) {
740
+ const id = rowsIdentifiers[index];
741
+ if (typeof id === 'number') {
742
+ this.selectedRows.push(this.renderedRows[id]);
743
+ }
744
+ else {
745
+ const row = this.renderedRows.find((row) => row.id === id);
746
+ this.selectedRows.push(row);
747
+ }
741
748
  }
742
749
  if (emitEvent !== false) {
743
750
  this.kupRowSelected.emit({
@@ -897,7 +904,6 @@ export class KupDataTable {
897
904
  this.groups = [];
898
905
  // update data
899
906
  this.data = Object.assign({}, totalsMatrixData);
900
- // console.log(this.data);
901
907
  // calc totals
902
908
  // distinct becomes count
903
909
  // count becomes sum
@@ -952,7 +958,7 @@ export class KupDataTable {
952
958
  if (column) {
953
959
  this.filters = {};
954
960
  }
955
- return this.kupManager.data.datasetOperations.transpose(this.data, column);
961
+ return this.kupManager.data.transpose(this.data, column);
956
962
  }
957
963
  updateStickyHeaderSize() {
958
964
  const navBar = document.querySelectorAll('.header')[0];
@@ -1425,20 +1431,6 @@ export class KupDataTable {
1425
1431
  this.didLoadObservers();
1426
1432
  this.didLoadEventHandling();
1427
1433
  this.didLoadInteractables();
1428
- if (this.selectRowsById) {
1429
- this.setSelectedRows(this.selectRowsById);
1430
- }
1431
- else if (this.selectRow && this.selectRow > 0) {
1432
- if (this.selectRow <= this.renderedRows.length) {
1433
- this.selectedRows = [];
1434
- this.selectedRows.push(this.renderedRows[this.selectRow - 1]);
1435
- this.kupAutoRowSelect.emit({
1436
- comp: this,
1437
- id: this.rootElement.id,
1438
- selectedRow: this.selectedRows[0],
1439
- });
1440
- }
1441
- }
1442
1434
  this.lazyLoadCells = true;
1443
1435
  this.kupDidLoad.emit({ comp: this, id: this.rootElement.id });
1444
1436
  this.kupManager.resize.observe(this.rootElement);
@@ -1645,7 +1637,7 @@ export class KupDataTable {
1645
1637
  this.detailCard.style.transform = 'translate(' + x + 'px,' + y + 'px)';
1646
1638
  this.rootElement.shadowRoot.append(this.detailCard);
1647
1639
  }
1648
- getEventDetails(path) {
1640
+ getEventDetails(path, e) {
1649
1641
  let isHeader, isBody, isFooter, td, textfield, th, tr, filterRemove;
1650
1642
  if (path) {
1651
1643
  for (let i = path.length - 1; i >= 0; i--) {
@@ -1729,6 +1721,7 @@ export class KupDataTable {
1729
1721
  column: column ? column : null,
1730
1722
  filterRemove: filterRemove ? filterRemove : null,
1731
1723
  isGroupRow: isGroupRow,
1724
+ originalEvent: e,
1732
1725
  row: row ? row : null,
1733
1726
  td: td ? td : null,
1734
1727
  textfield: textfield ? textfield : null,
@@ -1737,7 +1730,7 @@ export class KupDataTable {
1737
1730
  };
1738
1731
  }
1739
1732
  clickHandler(e) {
1740
- const details = this.getEventDetails(this.getEventPath(e));
1733
+ const details = this.getEventDetails(this.getEventPath(e), e);
1741
1734
  if (details.area === 'header') {
1742
1735
  if (details.th && details.column) {
1743
1736
  if (details.filterRemove) {
@@ -1776,7 +1769,7 @@ export class KupDataTable {
1776
1769
  return details;
1777
1770
  }
1778
1771
  contextMenuHandler(e) {
1779
- const details = this.getEventDetails(this.getEventPath(e));
1772
+ const details = this.getEventDetails(this.getEventPath(e), e);
1780
1773
  if (details.area === 'header') {
1781
1774
  if (details.th && details.column) {
1782
1775
  this.openColumnMenu(details.column.name);
@@ -1806,7 +1799,7 @@ export class KupDataTable {
1806
1799
  return details;
1807
1800
  }
1808
1801
  dblClickHandler(e) {
1809
- const details = this.getEventDetails(this.getEventPath(e));
1802
+ const details = this.getEventDetails(this.getEventPath(e), e);
1810
1803
  if (details.area === 'body') {
1811
1804
  if (this.selection == SelectionMode.MULTIPLE) {
1812
1805
  this.resetSelectedRows();
@@ -2681,47 +2674,39 @@ export class KupDataTable {
2681
2674
  if (this.isOpenedTotalMenuForColumn(column.name)) {
2682
2675
  const listData = [
2683
2676
  {
2684
- text: translation[TotalLabel.COUNT],
2685
- value: TotalMode.COUNT,
2686
- selected: false,
2677
+ id: TotalMode.COUNT,
2678
+ value: translation[TotalLabel.COUNT],
2687
2679
  },
2688
2680
  {
2689
- text: translation[TotalLabel.DISTINCT],
2690
- value: TotalMode.DISTINCT,
2691
- selected: false,
2681
+ id: TotalMode.DISTINCT,
2682
+ value: translation[TotalLabel.DISTINCT],
2692
2683
  },
2693
2684
  ];
2694
2685
  if (this.kupManager.objects.isNumber(column.obj)) {
2695
2686
  // TODO Move these objects in declarations
2696
2687
  listData.push({
2697
- text: translation[TotalLabel.SUM],
2698
- value: TotalMode.SUM,
2699
- selected: false,
2688
+ id: TotalMode.SUM,
2700
2689
  separator: true,
2690
+ value: translation[TotalLabel.SUM],
2701
2691
  }, {
2702
- text: translation[TotalLabel.AVERAGE],
2703
- value: TotalMode.AVERAGE,
2704
- selected: false,
2692
+ id: TotalMode.AVERAGE,
2693
+ value: translation[TotalLabel.AVERAGE],
2705
2694
  }, {
2706
- text: translation[TotalLabel.MIN],
2707
- value: TotalMode.MIN,
2708
- selected: false,
2695
+ id: TotalMode.MIN,
2696
+ value: translation[TotalLabel.MIN],
2709
2697
  }, {
2710
- text: translation[TotalLabel.MAX],
2711
- value: TotalMode.MAX,
2712
- selected: false,
2698
+ id: TotalMode.MAX,
2699
+ value: translation[TotalLabel.MAX],
2713
2700
  });
2714
2701
  }
2715
2702
  else if (this.kupManager.objects.isDate(column.obj)) {
2716
2703
  listData.push({
2717
- text: translation[TotalLabel.MIN],
2718
- value: TotalMode.MIN,
2719
- selected: false,
2704
+ id: TotalMode.MIN,
2720
2705
  separator: true,
2706
+ value: translation[TotalLabel.MIN],
2721
2707
  }, {
2722
- text: translation[TotalLabel.MAX],
2723
- value: TotalMode.MAX,
2724
- selected: false,
2708
+ id: TotalMode.MAX,
2709
+ value: translation[TotalLabel.MAX],
2725
2710
  });
2726
2711
  }
2727
2712
  if (this.totals) {
@@ -2729,10 +2714,9 @@ export class KupDataTable {
2729
2714
  if (selectedItem) {
2730
2715
  selectedItem.selected = true;
2731
2716
  listData.push({
2732
- text: translation[TotalLabel.CANC],
2733
- value: TotalLabel.CANC,
2734
- selected: false,
2717
+ id: TotalLabel.CANC,
2735
2718
  separator: true,
2719
+ value: translation[TotalLabel.CANC],
2736
2720
  });
2737
2721
  }
2738
2722
  }
@@ -3196,42 +3180,42 @@ export class KupDataTable {
3196
3180
  createListData(codes, icons, selectedCode) {
3197
3181
  const listItems = [];
3198
3182
  for (let i = 0; i < codes.length; i++) {
3199
- let text = null;
3183
+ let value = null;
3200
3184
  switch (codes[i]) {
3201
3185
  //This whole customization panel thingy must be purged, for now -- it's ugly
3202
3186
  case 'big':
3203
- text = KupLanguageFontsize.BIG;
3187
+ value = KupLanguageFontsize.BIG;
3204
3188
  break;
3205
3189
  case 'Col':
3206
- text = KupLanguageGrid.COLUMN;
3190
+ value = KupLanguageGrid.COLUMN;
3207
3191
  break;
3208
3192
  case 'Complete':
3209
- text = KupLanguageGrid.COMPLETE;
3193
+ value = KupLanguageGrid.COMPLETE;
3210
3194
  break;
3211
3195
  case 'dense':
3212
- text = KupLanguageDensity.DENSE;
3196
+ value = KupLanguageDensity.DENSE;
3213
3197
  break;
3214
3198
  case 'medium':
3215
- text = KupLanguageDensity.MEDIUM;
3199
+ value = KupLanguageDensity.MEDIUM;
3216
3200
  break;
3217
3201
  case 'None':
3218
- text = KupLanguageGrid.NONE;
3202
+ value = KupLanguageGrid.NONE;
3219
3203
  break;
3220
3204
  case 'small':
3221
- text = KupLanguageFontsize.SMALL;
3205
+ value = KupLanguageFontsize.SMALL;
3222
3206
  break;
3223
3207
  case 'Row':
3224
- text = KupLanguageGrid.ROW;
3208
+ value = KupLanguageGrid.ROW;
3225
3209
  break;
3226
3210
  case 'wide':
3227
- text = KupLanguageDensity.WIDE;
3211
+ value = KupLanguageDensity.WIDE;
3228
3212
  break;
3229
3213
  }
3230
3214
  listItems[i] = {
3231
- text: this.kupManager.language.translate(text),
3232
- value: codes[i],
3233
- selected: selectedCode == codes[i],
3234
3215
  icon: icons[i],
3216
+ id: codes[i],
3217
+ selected: selectedCode == codes[i],
3218
+ value: this.kupManager.language.translate(value),
3235
3219
  };
3236
3220
  }
3237
3221
  return listItems;
@@ -4299,40 +4283,6 @@ export class KupDataTable {
4299
4283
  "reflect": false,
4300
4284
  "defaultValue": "SelectionMode.SINGLE"
4301
4285
  },
4302
- "selectRow": {
4303
- "type": "number",
4304
- "mutable": false,
4305
- "complexType": {
4306
- "original": "number",
4307
- "resolved": "number",
4308
- "references": {}
4309
- },
4310
- "required": false,
4311
- "optional": false,
4312
- "docs": {
4313
- "tags": [],
4314
- "text": "Selects the row at the specified rendered rows prosition (base 1)."
4315
- },
4316
- "attribute": "select-row",
4317
- "reflect": false
4318
- },
4319
- "selectRowsById": {
4320
- "type": "string",
4321
- "mutable": false,
4322
- "complexType": {
4323
- "original": "string",
4324
- "resolved": "string",
4325
- "references": {}
4326
- },
4327
- "required": false,
4328
- "optional": false,
4329
- "docs": {
4330
- "tags": [],
4331
- "text": "Semicolon separated rows id to select."
4332
- },
4333
- "attribute": "select-rows-by-id",
4334
- "reflect": false
4335
- },
4336
4286
  "showCustomization": {
4337
4287
  "type": "boolean",
4338
4288
  "mutable": false,
@@ -4744,26 +4694,6 @@ export class KupDataTable {
4744
4694
  }
4745
4695
  }
4746
4696
  }
4747
- }, {
4748
- "method": "kupAutoRowSelect",
4749
- "name": "kup-datatable-autorowselect",
4750
- "bubbles": true,
4751
- "cancelable": false,
4752
- "composed": true,
4753
- "docs": {
4754
- "tags": [],
4755
- "text": "When a row is auto selected via selectRow prop"
4756
- },
4757
- "complexType": {
4758
- "original": "KupDatatableAutoRowSelectEventPayload",
4759
- "resolved": "KupDatatableAutoRowSelectEventPayload",
4760
- "references": {
4761
- "KupDatatableAutoRowSelectEventPayload": {
4762
- "location": "import",
4763
- "path": "./kup-data-table-declarations"
4764
- }
4765
- }
4766
- }
4767
4697
  }, {
4768
4698
  "method": "kupRowSelected",
4769
4699
  "name": "kup-datatable-rowselected",
@@ -5026,6 +4956,29 @@ export class KupDataTable {
5026
4956
  }]
5027
4957
  }
5028
4958
  },
4959
+ "getSelectedRows": {
4960
+ "complexType": {
4961
+ "signature": "() => Promise<Array<KupDataTableRow>>",
4962
+ "parameters": [],
4963
+ "references": {
4964
+ "Promise": {
4965
+ "location": "global"
4966
+ },
4967
+ "KupDataTableRow": {
4968
+ "location": "import",
4969
+ "path": "./kup-data-table-declarations"
4970
+ },
4971
+ "Array": {
4972
+ "location": "global"
4973
+ }
4974
+ },
4975
+ "return": "Promise<KupDataTableRow[]>"
4976
+ },
4977
+ "docs": {
4978
+ "text": "This method will get the selected rows of the component.",
4979
+ "tags": []
4980
+ }
4981
+ },
5029
4982
  "hideColumn": {
5030
4983
  "complexType": {
5031
4984
  "signature": "(column: KupDataColumn) => Promise<void>",
@@ -5237,13 +5190,13 @@ export class KupDataTable {
5237
5190
  },
5238
5191
  "setSelectedRows": {
5239
5192
  "complexType": {
5240
- "signature": "(rowsById: string, emitEvent?: boolean) => Promise<void>",
5193
+ "signature": "(rowsIdentifiers: string[] | number[], emitEvent?: boolean) => Promise<void>",
5241
5194
  "parameters": [{
5242
5195
  "tags": [{
5243
5196
  "name": "param",
5244
- "text": "rowsById - String containing the ids separated by \";\"."
5197
+ "text": "rowsIdentifiers - Array of ids (dataset) or indexes (rendered rows)."
5245
5198
  }],
5246
- "text": "- String containing the ids separated by \";\"."
5199
+ "text": "- Array of ids (dataset) or indexes (rendered rows)."
5247
5200
  }, {
5248
5201
  "tags": [{
5249
5202
  "name": "param",
@@ -5262,7 +5215,7 @@ export class KupDataTable {
5262
5215
  "text": "This method will set the selected rows of the component.",
5263
5216
  "tags": [{
5264
5217
  "name": "param",
5265
- "text": "rowsById - String containing the ids separated by \";\"."
5218
+ "text": "rowsIdentifiers - Array of ids (dataset) or indexes (rendered rows)."
5266
5219
  }, {
5267
5220
  "name": "param",
5268
5221
  "text": "emitEvent - The event will always be emitted unless emitEvent is set to false."
@@ -344,7 +344,7 @@ export class KupDatePicker {
344
344
  resetStatus: true,
345
345
  },
346
346
  };
347
- return (h("kup-card", { ref: (el) => (this.pickerContainerEl = el), data: data, layoutFamily: KupCardFamily.BUILT_IN, sizeX: "300px", sizeY: "300px", isMenu: true, "onkup-card-click": (ev) => {
347
+ return (h("kup-card", { ref: (el) => (this.pickerContainerEl = el), data: data, layoutFamily: KupCardFamily.BUILT_IN, sizeX: "300px", sizeY: "auto", isMenu: true, "onkup-card-click": (ev) => {
348
348
  if (ev.detail.value != null && ev.detail.value != '')
349
349
  this.onKupDatePickerItemClick(ev.detail.value);
350
350
  } }));
@@ -125,7 +125,10 @@ export class KupDrawer {
125
125
  render() {
126
126
  return (h(Host, { "kup-opened": this.opened },
127
127
  h("style", null, this.kupManager.theme.setKupStyle(this.rootElement)),
128
- h("div", { class: "backdrop", onPointerDown: () => this.close() }),
128
+ h("div", { class: "backdrop", onPointerDown: (e) => {
129
+ e.stopPropagation();
130
+ this.close();
131
+ } }),
129
132
  h("div", { id: componentWrapperId },
130
133
  h("div", { class: drawerClass }, this.content()))));
131
134
  }
@@ -39,12 +39,12 @@
39
39
  .f-button.dropdown-button__dropdown-action .button.button--disabled {
40
40
  box-shadow: none;
41
41
  }
42
- .f-button.dropdown-button__dropdown-action .button.button--outlined {
43
- border-left: none;
44
- }
45
42
  .f-button.dropdown-button__dropdown-action .button.toggled .button__icon {
46
43
  transform: rotate(180deg);
47
44
  }
45
+ .f-button.dropdown-button__dropdown-action:not(.dropdown-only) .button--outlined:not(.dropdown-only) {
46
+ border-left: none;
47
+ }
48
48
 
49
49
  /*-------------------------------------------------*/
50
50
  /* C o m p o n e n t C l a s s e s */