@adyen/bento-vue3 1.67.0 → 1.68.1

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 (177) hide show
  1. package/dist/@types/index.d.ts +2154 -2110
  2. package/dist/action-bar.js +1 -1
  3. package/dist/assets/accordion-item.css +1 -1
  4. package/dist/assets/action-bar.css +1 -1
  5. package/dist/assets/base-modal.css +1 -1
  6. package/dist/assets/button-actions.css +1 -1
  7. package/dist/assets/card.css +1 -1
  8. package/dist/assets/checkbox.css +1 -1
  9. package/dist/assets/data-grid.css +1 -1
  10. package/dist/assets/dialog-page.css +1 -1
  11. package/dist/assets/dropdown.css +1 -1
  12. package/dist/assets/file-uploader.css +1 -1
  13. package/dist/assets/filter-bar.css +1 -1
  14. package/dist/assets/header-meta.css +1 -0
  15. package/dist/assets/header-with-views.css +1 -1
  16. package/dist/assets/header.css +1 -1
  17. package/dist/assets/input-field-phone-number.css +1 -1
  18. package/dist/assets/input-field.css +1 -1
  19. package/dist/assets/inspector.css +1 -1
  20. package/dist/assets/menu.css +1 -1
  21. package/dist/assets/modal-fullscreen.css +1 -1
  22. package/dist/assets/popover.css +1 -1
  23. package/dist/assets/sidepanel.css +1 -1
  24. package/dist/assets/summary-grid.css +1 -1
  25. package/dist/assets/textarea.css +1 -1
  26. package/dist/assets/use-cached-selected-values.css +1 -1
  27. package/dist/button.js +1 -1
  28. package/dist/card.js +1 -1
  29. package/dist/checkbox.js +2 -2
  30. package/dist/chunks/{action-bar.ComuZPet.js → action-bar.C93kgr7l.js} +4 -4
  31. package/dist/chunks/{action-bar.ComuZPet.js.map → action-bar.C93kgr7l.js.map} +1 -1
  32. package/dist/chunks/{base-modal.DzJrvis_.js → base-modal.C3_r3rmc.js} +120 -183
  33. package/dist/chunks/base-modal.C3_r3rmc.js.map +1 -0
  34. package/dist/chunks/{button-actions-with-menu.B0nWCTwZ.js → button-actions-with-menu.DUccmaB2.js} +3 -3
  35. package/dist/chunks/{button-actions-with-menu.B0nWCTwZ.js.map → button-actions-with-menu.DUccmaB2.js.map} +1 -1
  36. package/dist/chunks/{button-actions.BwpznQ6c.js → button-actions.CZdO9YOk.js} +7 -7
  37. package/dist/chunks/button-actions.CZdO9YOk.js.map +1 -0
  38. package/dist/chunks/{card.JBOvn2BO.js → card.CS34Mi_G.js} +2 -2
  39. package/dist/chunks/{card.JBOvn2BO.js.map → card.CS34Mi_G.js.map} +1 -1
  40. package/dist/chunks/{checkbox-group.Dc5Olq0c.js → checkbox-group.JRo6xNpe.js} +2 -2
  41. package/dist/chunks/{checkbox-group.Dc5Olq0c.js.map → checkbox-group.JRo6xNpe.js.map} +1 -1
  42. package/dist/chunks/{checkbox.fkPJvdUo.js → checkbox.DGrG3GN1.js} +70 -67
  43. package/dist/chunks/checkbox.DGrG3GN1.js.map +1 -0
  44. package/dist/chunks/{code-snippet.vrlSqi9k.js → code-snippet.D5M76Qy6.js} +3 -3
  45. package/dist/chunks/{code-snippet.vrlSqi9k.js.map → code-snippet.D5M76Qy6.js.map} +1 -1
  46. package/dist/chunks/{country.BhAcCmRx.js → country.Q95voxeL.js} +2 -2
  47. package/dist/chunks/{country.BhAcCmRx.js.map → country.Q95voxeL.js.map} +1 -1
  48. package/dist/chunks/{dashboard-section.Bg0dfNs-.js → dashboard-section.CUcq2ahu.js} +2 -2
  49. package/dist/chunks/{dashboard-section.Bg0dfNs-.js.map → dashboard-section.CUcq2ahu.js.map} +1 -1
  50. package/dist/chunks/{dashed-underline.DgE-UB-x.js → dashed-underline.DkzQkpaf.js} +2 -2
  51. package/dist/chunks/{dashed-underline.DgE-UB-x.js.map → dashed-underline.DkzQkpaf.js.map} +1 -1
  52. package/dist/chunks/{data-grid-template.Df7j2oxe.js → data-grid-template.CDsV2GFG.js} +2 -2
  53. package/dist/chunks/{data-grid-template.Df7j2oxe.js.map → data-grid-template.CDsV2GFG.js.map} +1 -1
  54. package/dist/chunks/data-grid.BbZSu-mA.js +3861 -0
  55. package/dist/chunks/data-grid.BbZSu-mA.js.map +1 -0
  56. package/dist/chunks/{date-picker.CZ6zU-NJ.js → date-picker.CAoXTiZR.js} +2 -2
  57. package/dist/chunks/{date-picker.CZ6zU-NJ.js.map → date-picker.CAoXTiZR.js.map} +1 -1
  58. package/dist/chunks/{date-range-picker.Dw4R9bIs.js → date-range-picker.DtV4L3L6.js} +5 -5
  59. package/dist/chunks/{date-range-picker.Dw4R9bIs.js.map → date-range-picker.DtV4L3L6.js.map} +1 -1
  60. package/dist/chunks/dropdown-default-textbox.Ce5D3ipi.js.map +1 -1
  61. package/dist/chunks/dropdown-tag.B3fptORX.js +230 -0
  62. package/dist/chunks/dropdown-tag.B3fptORX.js.map +1 -0
  63. package/dist/chunks/dropdown.CMOYmQLB.js +814 -0
  64. package/dist/chunks/dropdown.CMOYmQLB.js.map +1 -0
  65. package/dist/chunks/es6.n1ewaW31.js.map +1 -1
  66. package/dist/chunks/{filter-bar.XonJn7ao.js → filter-bar.DoHMLZ4O.js} +848 -833
  67. package/dist/chunks/filter-bar.DoHMLZ4O.js.map +1 -0
  68. package/dist/chunks/{footer-actions.CdJLLWNR.js → footer-actions.Bje-DDqw.js} +2 -2
  69. package/dist/chunks/{footer-actions.CdJLLWNR.js.map → footer-actions.Bje-DDqw.js.map} +1 -1
  70. package/dist/chunks/header-meta.Yt43-cUI.js +234 -0
  71. package/dist/chunks/header-meta.Yt43-cUI.js.map +1 -0
  72. package/dist/chunks/{header-with-views.CHbH1_1V.js → header-with-views.C9ql_Wem.js} +697 -678
  73. package/dist/chunks/header-with-views.C9ql_Wem.js.map +1 -0
  74. package/dist/chunks/header.wiq0wlgm.js +141 -0
  75. package/dist/chunks/header.wiq0wlgm.js.map +1 -0
  76. package/dist/chunks/{input-field-password.DWZAf1Oh.js → input-field-password.DN0Jro1V.js} +4 -4
  77. package/dist/chunks/{input-field-password.DWZAf1Oh.js.map → input-field-password.DN0Jro1V.js.map} +1 -1
  78. package/dist/chunks/{input-field-phone-number.CbpRItYf.js → input-field-phone-number.BhPsrafR.js} +548 -532
  79. package/dist/chunks/{input-field-phone-number.CbpRItYf.js.map → input-field-phone-number.BhPsrafR.js.map} +1 -1
  80. package/dist/chunks/{input-field.DExw_Cow.js → input-field.su5Cq8Dt.js} +30 -29
  81. package/dist/chunks/input-field.su5Cq8Dt.js.map +1 -0
  82. package/dist/chunks/{menu.CeLJ1gIz.js → menu.C-3obPGl.js} +182 -180
  83. package/dist/chunks/{menu.CeLJ1gIz.js.map → menu.C-3obPGl.js.map} +1 -1
  84. package/dist/chunks/{modal-fullscreen.CZnLS-fQ.js → modal-fullscreen.DBTnoSX9.js} +90 -77
  85. package/dist/chunks/modal-fullscreen.DBTnoSX9.js.map +1 -0
  86. package/dist/chunks/{modal.vue_vue_type_script_setup_true_lang.CP7dV1Yy.js → modal.vue_vue_type_script_setup_true_lang.Cd-mQUJ8.js} +10 -10
  87. package/dist/chunks/{modal.vue_vue_type_script_setup_true_lang.CP7dV1Yy.js.map → modal.vue_vue_type_script_setup_true_lang.Cd-mQUJ8.js.map} +1 -1
  88. package/dist/chunks/{pagination.DL9LmFMJ.js → pagination.fYQak4C8.js} +2 -2
  89. package/dist/chunks/{pagination.DL9LmFMJ.js.map → pagination.fYQak4C8.js.map} +1 -1
  90. package/dist/chunks/popover.DYgCCUCJ.js +200 -0
  91. package/dist/chunks/popover.DYgCCUCJ.js.map +1 -0
  92. package/dist/chunks/popover.types.V8old-GW.js +6 -0
  93. package/dist/chunks/popover.types.V8old-GW.js.map +1 -0
  94. package/dist/chunks/{rich-text-editor.Dl9PsYbk.js → rich-text-editor.Dx78coVL.js} +2 -2
  95. package/dist/chunks/{rich-text-editor.Dl9PsYbk.js.map → rich-text-editor.Dx78coVL.js.map} +1 -1
  96. package/dist/chunks/{search-bar.a-jzP1UA.js → search-bar.CUrcP_wf.js} +3 -3
  97. package/dist/chunks/{search-bar.a-jzP1UA.js.map → search-bar.CUrcP_wf.js.map} +1 -1
  98. package/dist/chunks/{secondary-nav.UrmIAVGD.js → secondary-nav.j3ddtYoZ.js} +2 -2
  99. package/dist/chunks/{secondary-nav.UrmIAVGD.js.map → secondary-nav.j3ddtYoZ.js.map} +1 -1
  100. package/dist/chunks/{sidepanel.BuNmgmpj.js → sidepanel.DPN__L3Q.js} +2 -2
  101. package/dist/chunks/{sidepanel.BuNmgmpj.js.map → sidepanel.DPN__L3Q.js.map} +1 -1
  102. package/dist/chunks/{summary-grid.types.CoSCUI1V.js → summary-grid.types.CjbbSZBJ.js} +4 -4
  103. package/dist/chunks/summary-grid.types.CjbbSZBJ.js.map +1 -0
  104. package/dist/chunks/{textarea.DXSe9MHH.js → textarea.BBhN67-I.js} +41 -40
  105. package/dist/chunks/textarea.BBhN67-I.js.map +1 -0
  106. package/dist/chunks/{timeline-item.BRHwCA1F.js → timeline-item.CuCII37W.js} +3 -3
  107. package/dist/chunks/{timeline-item.BRHwCA1F.js.map → timeline-item.CuCII37W.js.map} +1 -1
  108. package/dist/chunks/{tutorial.vue_vue_type_script_setup_true_lang.CAf69UYO.js → tutorial.vue_vue_type_script_setup_true_lang.nYHtTHqy.js} +28 -27
  109. package/dist/chunks/{tutorial.vue_vue_type_script_setup_true_lang.CAf69UYO.js.map → tutorial.vue_vue_type_script_setup_true_lang.nYHtTHqy.js.map} +1 -1
  110. package/dist/chunks/{use-cached-selected-values.D7dOPJSO.js → use-cached-selected-values.Dyoz6cUK.js} +579 -563
  111. package/dist/chunks/use-cached-selected-values.Dyoz6cUK.js.map +1 -0
  112. package/dist/chunks/{use-country-items.4kZgVg_l.js → use-country-items.Duh4bMqW.js} +2 -2
  113. package/dist/chunks/{use-country-items.4kZgVg_l.js.map → use-country-items.Duh4bMqW.js.map} +1 -1
  114. package/dist/chunks/{use-country-phon-code.DVgE19zT.js → use-country-phon-code.BOaJ9PDl.js} +507 -498
  115. package/dist/chunks/{use-country-phon-code.DVgE19zT.js.map → use-country-phon-code.BOaJ9PDl.js.map} +1 -1
  116. package/dist/code-snippet.js +1 -1
  117. package/dist/country.js +2 -2
  118. package/dist/dashboard-template.js +1 -1
  119. package/dist/dashed-underline.js +1 -1
  120. package/dist/data-grid-template.js +1 -1
  121. package/dist/data-grid.js +1 -1
  122. package/dist/date-picker.js +1 -1
  123. package/dist/date-range-picker.js +1 -1
  124. package/dist/dropdown.js +3 -3
  125. package/dist/filter-bar.js +1 -1
  126. package/dist/header-with-views.js +1 -1
  127. package/dist/header.js +1 -1
  128. package/dist/index.js +156 -155
  129. package/dist/index.js.map +1 -1
  130. package/dist/input-field-password.js +1 -1
  131. package/dist/input-field-phone-number.js +1 -1
  132. package/dist/input-field.js +1 -1
  133. package/dist/internal.js +15 -14
  134. package/dist/menu.js +1 -1
  135. package/dist/modal-fullscreen.js +1 -1
  136. package/dist/modal.js +11 -11
  137. package/dist/pagination.js +1 -1
  138. package/dist/popover.js +3 -2
  139. package/dist/popover.js.map +1 -1
  140. package/dist/rich-text-editor.js +1 -1
  141. package/dist/search-bar.js +2 -2
  142. package/dist/secondary-nav.js +1 -1
  143. package/dist/sidepanel.js +1 -1
  144. package/dist/styles/bento-dark.css +10 -2
  145. package/dist/styles/bento-light.css +10 -2
  146. package/dist/styles/bento.css +10 -2
  147. package/dist/styles/legacy.css +10 -2
  148. package/dist/styles/styleguide.css +10 -2
  149. package/dist/summary-grid.js +1 -1
  150. package/dist/textarea.js +1 -1
  151. package/dist/timeline.js +1 -1
  152. package/dist/tutorial.js +1 -1
  153. package/dist/web-types.json +1 -1
  154. package/package.json +23 -6
  155. package/dist/assets/info-icon-with-popover.css +0 -1
  156. package/dist/chunks/base-modal.DzJrvis_.js.map +0 -1
  157. package/dist/chunks/button-actions.BwpznQ6c.js.map +0 -1
  158. package/dist/chunks/checkbox.fkPJvdUo.js.map +0 -1
  159. package/dist/chunks/data-grid.rDZadZwc.js +0 -3781
  160. package/dist/chunks/data-grid.rDZadZwc.js.map +0 -1
  161. package/dist/chunks/dropdown-tag.BlHovDol.js +0 -202
  162. package/dist/chunks/dropdown-tag.BlHovDol.js.map +0 -1
  163. package/dist/chunks/dropdown.B5ZaFDn_.js +0 -957
  164. package/dist/chunks/dropdown.B5ZaFDn_.js.map +0 -1
  165. package/dist/chunks/filter-bar.XonJn7ao.js.map +0 -1
  166. package/dist/chunks/header-with-views.CHbH1_1V.js.map +0 -1
  167. package/dist/chunks/header.CJJWPB5Z.js +0 -254
  168. package/dist/chunks/header.CJJWPB5Z.js.map +0 -1
  169. package/dist/chunks/info-icon-with-popover.DVH46dPy.js +0 -97
  170. package/dist/chunks/info-icon-with-popover.DVH46dPy.js.map +0 -1
  171. package/dist/chunks/input-field.DExw_Cow.js.map +0 -1
  172. package/dist/chunks/modal-fullscreen.CZnLS-fQ.js.map +0 -1
  173. package/dist/chunks/popover.VI3TrUkL.js +0 -350
  174. package/dist/chunks/popover.VI3TrUkL.js.map +0 -1
  175. package/dist/chunks/summary-grid.types.CoSCUI1V.js.map +0 -1
  176. package/dist/chunks/textarea.DXSe9MHH.js.map +0 -1
  177. package/dist/chunks/use-cached-selected-values.D7dOPJSO.js.map +0 -1
@@ -0,0 +1,3861 @@
1
+ import { ref as A, onMounted as qe, nextTick as he, watch as Ee, onUnmounted as tn, reactive as gt, toRefs as vt, computed as b, watchEffect as ll, onBeforeUpdate as ol, createElementBlock as L, openBlock as u, mergeProps as ne, createCommentVNode as B, createElementVNode as O, toDisplayString as K, defineComponent as Ie, normalizeClass as de, Fragment as ve, renderList as ye, unref as o, toHandlers as ot, createBlock as G, withCtx as V, createVNode as X, renderSlot as Ne, withModifiers as sl, normalizeStyle as Me, resolveComponent as Re, withDirectives as mt, createTextVNode as ge, vShow as il, toRef as rt, resolveDirective as al, Transition as nn, createSlots as He, resolveDynamicComponent as Ze, useSlots as ht, provide as ln, inject as dt, withKeys as $t, normalizeProps as rl, guardReactiveProps as dl } from "vue";
2
+ import { C as ul } from "./checkmark-circle-fill._6-d40ru.js";
3
+ import { W as cl } from "./warning-filled.AiUbXzzg.js";
4
+ /* empty css */
5
+ import { _ as ae } from "./_plugin-vue_export-helper.CHgC5LLL.js";
6
+ import { C as on } from "./cross.B92GxFTY.js";
7
+ import { N as Dt } from "./minus-small.DYIyF5XW.js";
8
+ import { l as kt, B as fl } from "./events.FNmSWp_P.js";
9
+ import { E as Ae, B as gl, T as vl } from "./tooltip.VYPUHERk.js";
10
+ import { c as ml } from "./popper-container.types.BCZMbVFD.js";
11
+ import { B as hl } from "./dashed-underline.DkzQkpaf.js";
12
+ import { B as Ke, p as sn } from "./typography.DN5eC5ch.js";
13
+ import { u as Ue } from "./i18n.B6g5VX0q.js";
14
+ import { B as Cl } from "./action-bar.C93kgr7l.js";
15
+ import { B as wl } from "./pagination.fYQak4C8.js";
16
+ import { B as Ct } from "./loading-indicator.DEepb9Wl.js";
17
+ import { u as wt } from "./use-has-slot.B7eQSabc.js";
18
+ import { u as _l } from "./aria-label.CaUURpnB.js";
19
+ import { g as bl } from "./get-slot-text.DQlZEsId.js";
20
+ import { B as at } from "./filter-bar.DoHMLZ4O.js";
21
+ import { B as yl } from "./empty-state.D7llINgF.js";
22
+ import { E as El } from "./tabs.keys.Cb4Vw5Jh.js";
23
+ import { D as Sl } from "./data-grid-template.keys.2_AkxuNT.js";
24
+ import { o as _t } from "./resize.Bqks3WUm.js";
25
+ import { B as pl } from "./popover.DYgCCUCJ.js";
26
+ import { B as an } from "./button.AB0SOQMn.js";
27
+ import { B as rn } from "./toggle.BuKXexA6.js";
28
+ import { B as Ll } from "./search-bar.CUrcP_wf.js";
29
+ import { u as Rl } from "./dropdown.CMOYmQLB.js";
30
+ import { B as Al } from "./directive.Cbdox5VL.js";
31
+ import { g as ut } from "./generate-uid.NJ8tVoha.js";
32
+ import { S as Ol } from "./search.PczW-onY.js";
33
+ import { B as bt } from "./toggle-button.NQwrfSr1.js";
34
+ import { B as nt } from "./checkbox.DGrG3GN1.js";
35
+ import { B as Tl } from "./info-icon.DprUQ9fj.js";
36
+ import { B as ct, O as Nl, D as Il } from "./menu.C-3obPGl.js";
37
+ import { B as Mt } from "./popover.types.V8old-GW.js";
38
+ import { A as $l } from "./dialog-page.C80HOigq.js";
39
+ import { H as Dl, S as kl } from "./show.CT4Augxb.js";
40
+ import { b as dn } from "./focus-trap.CljZgv9i.js";
41
+ import { u as Ml } from "./use-expandable-content-height.GkjjbmPy.js";
42
+ import { E as Fl } from "./link.BBpxiclu.js";
43
+ import { C as Ul } from "./copy.RUoQOydT.js";
44
+ import { C as zl } from "./chevron-down.DCQ6ZLaq.js";
45
+ import { C as Pl } from "./chevron-up.kfuLRpZb.js";
46
+ import { d as Ft, e as Ut } from "./button-actions.CZdO9YOk.js";
47
+ import "../assets/data-grid.css";
48
+ const zt = (e) => {
49
+ if (!e)
50
+ return 0;
51
+ const i = window.getComputedStyle(e);
52
+ let a = e.offsetHeight;
53
+ const t = window.getComputedStyle(e, "::after");
54
+ if (t.content !== "none" && t.position === "absolute") {
55
+ const n = parseFloat(t.height), l = parseFloat(t.bottom);
56
+ !isNaN(n) && !isNaN(l) && l < 0 && l + n <= 0 && (a += n);
57
+ }
58
+ const c = parseFloat(i.top);
59
+ return !isNaN(c) && c < 0 && (a += c), a;
60
+ }, Pt = (e, i, a = A(!1), t = null) => {
61
+ const c = A(0);
62
+ let n = null, l = null;
63
+ const g = () => {
64
+ const f = i.value ? zt(e.value) : 0, C = a.value && t ? zt(t.value) : 0;
65
+ c.value = f + C;
66
+ };
67
+ return qe(() => {
68
+ he(() => {
69
+ const f = Ee(
70
+ e,
71
+ () => {
72
+ e != null && e.value && (he(() => f()), n = _t(e.value, g), l = new MutationObserver(g), l.observe(e.value, { attributes: !0, attributeFilter: ["class"] }));
73
+ },
74
+ { immediate: !0 }
75
+ );
76
+ Ee(
77
+ [i, a],
78
+ () => {
79
+ g();
80
+ },
81
+ { immediate: !0 }
82
+ );
83
+ });
84
+ }), tn(() => {
85
+ n == null || n.disconnect(), l == null || l.disconnect();
86
+ }), c;
87
+ };
88
+ var ft = /* @__PURE__ */ ((e) => (e.WRAP = "wrap", e.ELLIPSIS = "ellipsis", e))(ft || {}), De = /* @__PURE__ */ ((e) => (e.OUTLINE = "outline", e.SCROLL = "scroll", e.STICKY_FILTERS = "sticky-filters", e.OVERFLOW_SHADOW_LEFT = "overflow-shadow-left", e.OVERFLOW_SHADOW_RIGHT = "overflow-shadow-right", e.NO_SPACING_TOP = "no-spacing-top", e.FIT_CONTENT = "fit-content", e))(De || {}), Fe = /* @__PURE__ */ ((e) => (e.ASCENDING = "asc", e.DESCENDING = "desc", e))(Fe || {}), z = /* @__PURE__ */ ((e) => (e.COLUMNS = "columns", e.COLUMN_RESIZE = "column-resize", e.ITEMS_PAGE = "items-page", e.NAVIGATE = "navigate", e.NESTED_CONTENT_TOGGLED = "nested-content-toggled", e.FILTER_SEARCH_INPUT = "filter-search-input", e.FILTER_SEARCH_CLEAR = "filter-search-clear", e.UPDATE_COLUMNS = "update:columns", e.UPDATE_CONDENSED = "update:condensed", e.UPDATE_FILTERS = "update:filters", e.UPDATE_FILTER_VALUES = "update:filter-values", e.UPDATE_FILTER_SEARCH_TERM = "update:filter-search-term", e.UPDATE_PAGINATION = "update:pagination", e.UPDATE_SELECTION = "update:selection", e.UPDATE_SHOW_MORE = "update:show-more", e.UPDATE_SORT_BY = "update:sort-by", e.ROW_CLICK = "row-click", e.SELECT = "select", e.SELECT_ALL_ACROSS_PAGES = "select-all-across-pages", e.SORT = "sort", e))(z || {}), lt = /* @__PURE__ */ ((e) => (e.ASCENDING = "ascending", e.DESCENDING = "descending", e.NONE = "none", e))(lt || {}), te = /* @__PURE__ */ ((e) => (e.COLUMN_RESIZE = "column-resize", e.COLUMN_RESIZING = "column-resizing", e.SELECT_ALL_ROWS = "select-all-rows", e.SELECT_ALL_ACROSS_PAGES = "select-all-across-pages", e.DESELECT_ALL = "deselect-all", e.COLUMN_MOVE = "column-move", e.COLUMN_UPDATE = "column-update", e.COLUMN_MENU_OPEN = "column-menu-open", e.COLUMN_MENU_CLOSE = "column-menu-close", e.COLUMN_HOVER = "column-hover", e.COLUMN_DRAG_START = "column-dragstart", e.COLUMN_DRAG_ENTER = "column-dragenter", e.COLUMN_DRAG_END = "column-dragend", e.COLUMN_DROP = "column-drop", e))(te || {});
89
+ const Bl = (e, i) => {
90
+ const a = A(null), t = A(!1), c = A(void 0), n = e.value.reduce((M, m) => (M[m.field] = null, M), {}), l = gt(n), g = vt(l);
91
+ let f = 0, C = "";
92
+ const R = b(
93
+ () => Object.fromEntries(e.value.map(({ field: M, width: m, minWidth: w }) => [M, { width: m, minWidth: w }]))
94
+ );
95
+ ll(() => c.value = R.value);
96
+ let v = null, F = null;
97
+ const _ = (M) => {
98
+ const m = M.clientX - f, w = C, s = c.value[w].width + m;
99
+ c.value[w].width = s > R.value[w].minWidth ? s : R.value[w].minWidth, i(te.COLUMN_RESIZING, c.value), f = M.clientX;
100
+ }, y = () => {
101
+ t.value = !1, v == null || v(), F == null || F(), C && i(te.COLUMN_RESIZE, {
102
+ field: C,
103
+ width: c.value[C].width
104
+ }), v = null, F = null, C = "", f = null;
105
+ }, T = (M, m, w) => {
106
+ if (w.preventDefault(), M) {
107
+ if (t.value = !0, w.buttons !== 1) {
108
+ y();
109
+ return;
110
+ }
111
+ C = m, f = w.clientX, v = kt(window, "mousemove", _), F = kt(window, "mouseup", y);
112
+ }
113
+ };
114
+ return Ee(
115
+ () => t.value,
116
+ (M, m) => {
117
+ !M && m && (i(te.COLUMN_HOVER, a.value), a.value = null);
118
+ }
119
+ ), {
120
+ resizeData: c,
121
+ allColumnRefs: g,
122
+ startResize: T,
123
+ isResizing: t,
124
+ columnHoverEventToEmitAfterResizing: a
125
+ };
126
+ }, Wl = 100, Bt = 50, be = "b-actions-column", Gl = 32, Hl = 56, Vl = 56, xl = 80, Zl = 36, jl = 1, un = 16, ql = 20, Kl = (e, i, a) => {
127
+ const t = {}, c = [], n = (g) => {
128
+ const f = t[g];
129
+ f && f.frozen !== !0 && (t[g].frozen = !0, c.push(g));
130
+ };
131
+ function l() {
132
+ if (c.length === a.length)
133
+ return;
134
+ const g = { min: {} };
135
+ let f = e, C = i, R = 0;
136
+ c.forEach((v) => {
137
+ f -= t[v].computedWidth, C -= t[v].flex;
138
+ });
139
+ for (let v = 0, F = a.length; v < F; v += 1) {
140
+ const _ = a[v];
141
+ if (t[_.field] && t[_.field].frozen === !0)
142
+ continue;
143
+ let T = f / C * _.flex;
144
+ T < _.minWidth && (R += _.minWidth - T, T = _.minWidth, g.min[_.field] = !0), t[_.field] = {
145
+ frozen: !1,
146
+ computedWidth: T,
147
+ flex: _.flex
148
+ };
149
+ }
150
+ R > 0 ? Object.keys(g.min).forEach((v) => {
151
+ n(v);
152
+ }) : a.forEach(({ field: v }) => {
153
+ n(v);
154
+ }), l();
155
+ }
156
+ return l(), t;
157
+ }, Wt = (e, i) => {
158
+ let a = jl;
159
+ return i && (a += un * 2), e != null && e.offsetWidth ? e.offsetWidth + a : 0;
160
+ }, Yl = (e) => {
161
+ var i, a, t, c, n;
162
+ return (i = e == null ? void 0 : e.hasNestedContent) != null && i.value || (a = e == null ? void 0 : e.hasNestedRows) != null && a.value ? (t = e == null ? void 0 : e.hasSelectableColumn) != null && t.value ? (c = e == null ? void 0 : e.hasSelectableAcrossPages) != null && c.value ? xl : Vl : Zl : (n = e == null ? void 0 : e.hasSelectableAcrossPages) != null && n.value ? Hl : Gl;
163
+ }, Xl = (e, i, a, t, c, n) => {
164
+ const l = A(e.value), g = A(i), f = A(a), C = A(t), R = A(c), v = A(!1), F = A(0);
165
+ Ee(
166
+ () => e.value,
167
+ (r, p) => {
168
+ var J, ue;
169
+ const U = (r == null ? void 0 : r.map(({ field: le }) => le).toString()) === (p == null ? void 0 : p.map(({ field: le }) => le).toString());
170
+ if (!((J = n == null ? void 0 : n.allowColumnDragAndDrop) != null && J.value) || !U) {
171
+ l.value = e.value;
172
+ return;
173
+ }
174
+ l.value = ((ue = l.value) == null ? void 0 : ue.length) === 0 ? e.value : e.value.sort((le, Ce) => {
175
+ const we = l.value.findIndex((me) => me.field === le.field), ce = l.value.findIndex((me) => me.field === Ce.field);
176
+ return we === -1 ? 1 : ce === -1 ? -1 : we - ce;
177
+ });
178
+ }
179
+ );
180
+ const _ = A();
181
+ let y = null;
182
+ const T = b(() => {
183
+ var we, ce, me;
184
+ const r = [];
185
+ let p = 0, U = 0;
186
+ const J = {};
187
+ let ue = l.value.filter((Q) => Q.visible !== !1);
188
+ const le = l.value.filter((Q) => Q.visible === !1);
189
+ if ((we = n == null ? void 0 : n.hasSelectableColumn) != null && we.value || (ce = n == null ? void 0 : n.hasNestedContent) != null && ce.value || (me = n == null ? void 0 : n.hasNestedRows) != null && me.value) {
190
+ const Q = Yl(n);
191
+ ue = [
192
+ {
193
+ field: be,
194
+ label: "",
195
+ minWidth: Q,
196
+ width: Q,
197
+ frozen: !0,
198
+ padding: { left: !1, right: !1 }
199
+ },
200
+ ...ue
201
+ ];
202
+ }
203
+ ue.forEach((Q) => {
204
+ const h = { ...Q };
205
+ let j;
206
+ h.flex && h.flex > 0 ? (p += h.flex, j = 0, r.push(h)) : j = Math.max(
207
+ (h == null ? void 0 : h.width) ?? Wl,
208
+ (h == null ? void 0 : h.minWidth) ?? Bt
209
+ ), U += j, h.width = j, h.minWidth = (h == null ? void 0 : h.minWidth) ?? Bt, J[h.field] = h;
210
+ }), U += F.value;
211
+ const Ce = Math.max(_.value - U, 0);
212
+ if (p > 0 && _.value > 0) {
213
+ const Q = Kl(Ce, p, r);
214
+ Object.keys(Q).forEach((h) => {
215
+ J[h].width = Q[h].computedWidth;
216
+ });
217
+ }
218
+ return le.forEach((Q) => {
219
+ const h = { ...Q };
220
+ J[h.field] = h;
221
+ }), Object.values(J);
222
+ }), M = A(void 0), m = (r) => {
223
+ M.value = { ...M.value, ...r };
224
+ }, w = async () => {
225
+ l.value.some((r) => r == null ? void 0 : r.autoWidth) && (v.value = !0, await he(), await he(), l == null || l.value.filter((r) => r == null ? void 0 : r.autoWidth).forEach(({ field: r, minWidth: p }) => {
226
+ var le, Ce, we, ce;
227
+ const U = Wt(
228
+ (le = C.value) == null ? void 0 : le[r],
229
+ (Ce = n == null ? void 0 : n.hasColumnPanel) == null ? void 0 : Ce.value
230
+ ), J = (ce = (we = R.value) == null ? void 0 : we[r]) == null ? void 0 : ce.reduce(
231
+ (me, Q) => Math.max(me, Wt(Q)),
232
+ 0
233
+ ), ue = Math.max(U, J ?? 0);
234
+ (p === void 0 || ue > p) && m({
235
+ [r]: {
236
+ width: ue
237
+ }
238
+ });
239
+ }), v.value = !1);
240
+ };
241
+ Ee([() => l.value, () => g.value], async () => {
242
+ l.value.some((r) => r == null ? void 0 : r.autoWidth) && await w();
243
+ });
244
+ const s = b(
245
+ () => T.value.map((r) => {
246
+ var p, U;
247
+ return {
248
+ ...r,
249
+ // Override column width with resized ones
250
+ width: ((U = (p = M.value) == null ? void 0 : p[r.field]) == null ? void 0 : U.width) ?? r.width
251
+ };
252
+ })
253
+ ), E = b(
254
+ () => {
255
+ var r;
256
+ return ((r = s.value) == null ? void 0 : r.filter(({ visible: p }) => p !== !1).reduce((p, U) => U.width + p, 0)) + F.value;
257
+ }
258
+ ), I = b(
259
+ () => _.value <= E.value
260
+ ), D = b(() => ({
261
+ width: _.value > E.value ? "100%" : "fit-content"
262
+ }));
263
+ return qe(() => {
264
+ var p;
265
+ const r = n != null && n.isDataGridTemplate ? ql : 0;
266
+ he(() => {
267
+ f.value && (_.value = f.value.getBoundingClientRect().width - r);
268
+ const U = Ee(
269
+ f,
270
+ () => {
271
+ f.value && (he(() => U()), y = _t(f.value, ({ width: J }) => {
272
+ _.value = J - r;
273
+ }));
274
+ },
275
+ { immediate: !0 }
276
+ );
277
+ }), (p = document == null ? void 0 : document.fonts) != null && p.ready ? document.fonts.ready.then(() => {
278
+ w();
279
+ }) : w();
280
+ }), tn(() => {
281
+ y == null || y.disconnect();
282
+ }), ol(() => {
283
+ var r;
284
+ R.value && ((r = Object.keys(R.value)) == null ? void 0 : r.length) > 0 && Object.keys(R.value).forEach((U) => {
285
+ R.value[U] = [];
286
+ });
287
+ }), {
288
+ columnDefs: s,
289
+ gridRowWidthStyle: D,
290
+ onColumnWidthOverride: m,
291
+ isMeasuringColumnWidths: v,
292
+ isTotalWidthOfColumnsTakingUpAllAvailableGridWidth: I,
293
+ columns: l,
294
+ totalWidthOfAllColumns: E,
295
+ rowActionsMaxWidth: F
296
+ };
297
+ }, Jl = (e, i, a, t, c, n, l) => {
298
+ const g = A(e.value ?? []), f = gt({
299
+ allItemsSelected: !1,
300
+ isIndeterminate: !1
301
+ }), C = b(
302
+ () => a.value.flatMap((s) => {
303
+ var E;
304
+ return [s, ((E = s == null ? void 0 : s.children) == null ? void 0 : E.length) > 0 ? s == null ? void 0 : s.children : []];
305
+ }).flat()
306
+ ), R = b(
307
+ () => {
308
+ var s, E;
309
+ return ((s = a.value) == null ? void 0 : s.length) > 0 && ((E = C.value) == null ? void 0 : E.filter((I) => !c(I)).every((I) => g.value.includes(t(I))));
310
+ }
311
+ ), v = b(() => {
312
+ var s;
313
+ return !(n != null && n.value) || ((s = l == null ? void 0 : l.value) == null ? void 0 : s.totalCount) === void 0 ? !1 : g.value.length === l.value.totalCount;
314
+ }), F = () => {
315
+ i(z.SELECT, g.value), i(z.UPDATE_SELECTION, g.value);
316
+ }, _ = (s) => {
317
+ var E, I, D;
318
+ if (g.value = s, R.value) {
319
+ f.allItemsSelected = !0;
320
+ const r = ((E = a.value) == null ? void 0 : E.length) > 0 && a.value.every((p) => g.value.includes(t(p)));
321
+ f.isIndeterminate = (n == null ? void 0 : n.value) && !v.value || !r;
322
+ } else
323
+ f.allItemsSelected = !1, f.isIndeterminate = ((I = g.value) == null ? void 0 : I.length) > 0 && ((D = a.value) == null ? void 0 : D.length) > 0 && a.value.some(
324
+ (r) => {
325
+ var p;
326
+ return g.value.includes(t(r)) || ((p = r == null ? void 0 : r.children) == null ? void 0 : p.some((U) => g.value.includes(t(U))));
327
+ }
328
+ );
329
+ }, y = (s) => {
330
+ he(() => {
331
+ var E, I, D;
332
+ if (f.allItemsSelected = s, s) {
333
+ g.value = (I = (E = C.value) == null ? void 0 : E.filter(
334
+ (p) => !c(p) && ((p == null ? void 0 : p.children) === void 0 || p.children.every((U) => !c(U)))
335
+ )) == null ? void 0 : I.map((p) => t(p));
336
+ const r = ((D = a.value) == null ? void 0 : D.length) > 0 && a.value.every((p) => g.value.includes(t(p)));
337
+ f.isIndeterminate = (n == null ? void 0 : n.value) && !v.value || g.value.length > 0 && !r;
338
+ } else
339
+ g.value = [], f.isIndeterminate = !1;
340
+ F();
341
+ });
342
+ }, T = () => {
343
+ he(() => {
344
+ _([]), F();
345
+ });
346
+ }, M = (s, E) => {
347
+ he(() => {
348
+ var I;
349
+ _(((I = E == null ? void 0 : E.children) == null ? void 0 : I.length) > 0 ? m(s, E) : s), F();
350
+ });
351
+ }, m = (s, E) => {
352
+ var r;
353
+ const I = t(E), D = (r = E.children) == null ? void 0 : r.filter((p) => !c(p)).map((p) => t(p));
354
+ if (s.includes(I)) {
355
+ const p = s;
356
+ return D.forEach((U) => {
357
+ p.includes(U) || p.push(U);
358
+ }), p;
359
+ }
360
+ return s.filter((p) => !D.includes(p));
361
+ }, w = (s, E, I) => {
362
+ he(() => {
363
+ var r, p;
364
+ const D = t(E);
365
+ s.includes(t(I)) ? _(
366
+ !s.includes(D) && ((r = E == null ? void 0 : E.children) != null && r.every((U) => s.includes(t(U)))) ? [...s, D] : s
367
+ ) : _(
368
+ s.includes(D) && !((p = E == null ? void 0 : E.children) != null && p.every((U) => s.includes(t(U)))) ? s.filter((U) => U !== D) : s
369
+ ), F();
370
+ });
371
+ };
372
+ return Ee(
373
+ () => e.value,
374
+ () => {
375
+ _(e.value ?? []);
376
+ },
377
+ { immediate: !0 }
378
+ ), Ee(
379
+ () => a.value,
380
+ () => {
381
+ const s = a.value.filter((E) => g.value.includes(t(E))).flatMap(
382
+ (E) => {
383
+ var I;
384
+ return ((I = E == null ? void 0 : E.children) == null ? void 0 : I.length) > 0 ? E.children.map((D) => t(D)).filter((D) => !g.value.includes(D)) : [];
385
+ }
386
+ );
387
+ (s == null ? void 0 : s.length) > 0 ? (_([...g.value, ...s]), F()) : _(g.value);
388
+ }
389
+ ), {
390
+ onAllRowSelect: y,
391
+ onRowSelect: M,
392
+ onNestedRowSelect: w,
393
+ onDeselectAll: T,
394
+ allItemsSelectedState: f,
395
+ selectedItems: g,
396
+ isEveryItemSelected: R,
397
+ isEveryItemAcrossPagesSelected: v
398
+ };
399
+ }, Ql = (e, i, a) => ({ isSorting: (l) => e.value.some((g) => g.field === l), getSortingDirection: (l) => {
400
+ var g;
401
+ return (g = e.value.find((f) => f.field === l)) == null ? void 0 : g.direction;
402
+ }, sortByColumnField: (l) => {
403
+ var C;
404
+ if (!i.value.some((R) => R.field === l && R.sortable))
405
+ return;
406
+ const f = [{
407
+ field: l,
408
+ direction: ((C = e.value.find((R) => R.field === l)) == null ? void 0 : C.direction) === Fe.ASCENDING ? Fe.DESCENDING : Fe.ASCENDING
409
+ }];
410
+ a("sort", f);
411
+ } });
412
+ var _e = ((e) => (e[e.ARROW_DOWN = Ae.ARROW_DOWN] = "ARROW_DOWN", e[e.ARROW_UP = Ae.ARROW_UP] = "ARROW_UP", e[e.ARROW_LEFT = Ae.ARROW_LEFT] = "ARROW_LEFT", e[e.ARROW_RIGHT = Ae.ARROW_RIGHT] = "ARROW_RIGHT", e[e.PAGE_UP = Ae.PAGE_UP] = "PAGE_UP", e[e.PAGE_DOWN = Ae.PAGE_DOWN] = "PAGE_DOWN", e[e.END = Ae.END] = "END", e[e.HOME = Ae.HOME] = "HOME", e))(_e || {});
413
+ const je = "b-row-actions-column", eo = (e, i, a, t, c, n) => {
414
+ const l = b(() => n.value || t.value ? !0 : a.value.some((w) => w.infoIconTooltip || w.sortable)), g = b(() => {
415
+ let w = a.value.filter(({ visible: s }) => s !== !1);
416
+ return c.value && (w = [
417
+ ...w,
418
+ { field: je, label: "" }
419
+ ]), w;
420
+ }), f = b(() => g.value.length), C = b(() => {
421
+ if (!e.value)
422
+ return [];
423
+ const w = Object.keys(e.value)[0];
424
+ if (!w || !e.value[w])
425
+ return [];
426
+ const s = [];
427
+ if (l.value)
428
+ for (const I of g.value) {
429
+ const D = i.value[I.field];
430
+ s.push(D);
431
+ }
432
+ const E = e.value[w].length;
433
+ for (let I = 0; I < E; I++)
434
+ for (const D of g.value) {
435
+ const r = e.value[D.field];
436
+ r != null && r[I] && s.push(r[I]);
437
+ }
438
+ return s;
439
+ }), R = (w) => Math.floor(w / f.value), v = (w, s, E) => {
440
+ const I = C.value.length - 1, D = f.value - 1, r = R(w), p = w - f.value * r;
441
+ return {
442
+ [_e.PAGE_UP]: p + (l.value ? f.value : 0),
443
+ [_e.PAGE_DOWN]: I - D + p,
444
+ [_e.END]: E ? I : f.value * r + D,
445
+ [_e.HOME]: E ? l.value ? f.value : 0 : f.value * r
446
+ }[s];
447
+ }, F = (w, s) => {
448
+ const E = R(w), D = {
449
+ [_e.ARROW_DOWN]: f.value,
450
+ [_e.ARROW_UP]: E === 0 && !l.value ? 0 : -f.value,
451
+ [_e.ARROW_LEFT]: -1,
452
+ [_e.ARROW_RIGHT]: 1
453
+ }[s], r = w + D;
454
+ return r < 0 || r >= C.value.length ? w : r;
455
+ }, _ = (w) => [
456
+ _e.PAGE_UP,
457
+ _e.PAGE_DOWN,
458
+ _e.END,
459
+ _e.HOME
460
+ ].includes(w), y = (w, s, E) => {
461
+ const I = C.value.indexOf(w);
462
+ return _(s) ? v(I, s, E) : F(I, s);
463
+ }, T = (w, s, E) => {
464
+ if (!C.value.includes(w))
465
+ return;
466
+ const I = y(w, s, E);
467
+ C.value[I].focus();
468
+ }, M = (w) => w in _e;
469
+ return {
470
+ isNavigationKeyCode: M,
471
+ focusOnNextGridcell: T,
472
+ navigationInput: (w) => {
473
+ const { ctrlKey: s, key: E, target: I } = w, D = E;
474
+ let r = I;
475
+ r.getAttribute("role") !== "menuitem" && (C.value.includes(r) || (r = I.closest('[role="gridcell"], [role="columnheader"]')), C.value.includes(r) && M(D) && T(r, D, s));
476
+ }
477
+ };
478
+ }, to = 90, no = (e, i, a, t, c) => {
479
+ const n = A(e), l = A(i), g = A(a), f = A(t), C = b(() => n.value !== "none"), R = b(() => n.value === "automatic"), v = () => {
480
+ c(z.UPDATE_SHOW_MORE);
481
+ };
482
+ return Ee(
483
+ () => l.value,
484
+ () => {
485
+ R.value && g.value.offsetHeight / l.value * 100 > to && !f.value && v();
486
+ }
487
+ ), { isLazyLoad: C, isInfiniteScroll: R, verticalScrollPosition: l, emitLazyLoadEvent: v };
488
+ }, lo = (e, i, a) => {
489
+ const t = A(e), c = A(i), n = gt({
490
+ dragging: null,
491
+ dragToLeft: null,
492
+ target: null
493
+ }), l = (_, y = 0) => {
494
+ const T = t.value.findIndex((w) => w.field === _.field), M = T + y;
495
+ if (M < 0 || M > t.value.length - 1)
496
+ return;
497
+ const m = [...t.value];
498
+ m.splice(M, 0, m.splice(T, 1)[0]), a(z.COLUMNS, m), a(z.UPDATE_COLUMNS, m);
499
+ }, g = (_, y) => {
500
+ n.dragging = _, y.dataTransfer.setData("text", ""), y.dataTransfer.dropEffect = "move";
501
+ }, f = (_, y) => {
502
+ n.target = _;
503
+ const T = y.currentTarget.getBoundingClientRect(), M = T.left + T.width / 2, m = y.clientX ?? 0;
504
+ n.dragToLeft = m <= M;
505
+ }, C = (_) => {
506
+ var y, T;
507
+ if (((y = n.dragging) == null ? void 0 : y.field) !== _.field) {
508
+ const M = t.value.findIndex((D) => {
509
+ var r;
510
+ return D.field === ((r = n.dragging) == null ? void 0 : r.field);
511
+ }), m = t.value.findIndex((D) => D.field === _.field), w = n.dragToLeft ? m : m + 1, s = w > M ? w - 1 : w;
512
+ let E = [...t.value];
513
+ E.splice(
514
+ s === -1 ? 0 : s,
515
+ 0,
516
+ E.splice(M, 1)[0]
517
+ );
518
+ const I = t.value.findIndex((D) => !(D != null && D.frozen));
519
+ ((T = n.dragging) == null ? void 0 : T.frozen) !== _.frozen && w !== I && (E = E.map(
520
+ (D) => {
521
+ var r;
522
+ return ((r = n.dragging) == null ? void 0 : r.field) === D.field ? { ...D, frozen: !!(_ != null && _.frozen) } : D;
523
+ }
524
+ )), a(z.COLUMNS, E), a(z.UPDATE_COLUMNS, E);
525
+ }
526
+ n.dragging = null, n.target = null;
527
+ }, R = () => {
528
+ n.dragging = null, n.dragToLeft = null, n.target = null;
529
+ }, v = b(() => c.value ? {
530
+ [te.COLUMN_DRAG_START]: (_, y) => g(_, y),
531
+ [te.COLUMN_DRAG_ENTER]: (_, y) => f(_, y),
532
+ [te.COLUMN_DROP]: (_) => C(_),
533
+ [te.COLUMN_DRAG_END]: () => R()
534
+ } : {}), F = b(() => (_) => c.value ? {
535
+ dragenter: (y) => {
536
+ y.preventDefault(), f(_, y);
537
+ },
538
+ drop: () => {
539
+ C(_);
540
+ },
541
+ dragover: (y) => {
542
+ y.preventDefault();
543
+ }
544
+ } : {});
545
+ return {
546
+ // Values
547
+ draggingColumns: n,
548
+ // Methods
549
+ draggingEventsForColumns: v,
550
+ draggingEventsForRowCell: F,
551
+ onMoveColumnByOffset: l
552
+ };
553
+ }, oo = (e, i) => {
554
+ const a = A(e), t = b(
555
+ () => [...a.value].sort((v, F) => v.frozen === F.frozen ? 0 : v.frozen ? -1 : 1)
556
+ ), c = b(
557
+ () => t.value.filter((v) => v.frozen && v.visible !== !1)
558
+ ), n = b(
559
+ () => t.value.filter((v) => !v.frozen && v.visible !== !1)
560
+ ), l = b(
561
+ () => [
562
+ { columnSet: c.value, id: "frozen", isFrozenColumns: !0 },
563
+ { columnSet: n.value, id: "unfrozen" }
564
+ ].filter(({ columnSet: v }) => v.length)
565
+ ), g = b(
566
+ () => a.value.filter((v) => (v == null ? void 0 : v.visible) !== !1 && (v == null ? void 0 : v.field) !== be).length === 1
567
+ ), f = (v) => i(z.UPDATE_CONDENSED, v), C = (v) => {
568
+ i(z.COLUMNS, v), i(z.UPDATE_COLUMNS, v);
569
+ };
570
+ return {
571
+ // Values
572
+ columnSets: l,
573
+ isOnlyOneVisibleColumn: g,
574
+ sortedColumns: t,
575
+ // Methods
576
+ onConfigSettingsUpdate: f,
577
+ onConfigSettingsColumnsUpdate: C,
578
+ onConfigSettingsColumnUpdate: (v) => {
579
+ const F = t.value.map(
580
+ (_) => (_ == null ? void 0 : _.field) === v.field ? v : _
581
+ );
582
+ C(F);
583
+ }
584
+ };
585
+ }, so = (e, i, a, t, c, n, l) => {
586
+ const g = A(0), f = A(!1), C = A(!1);
587
+ Ee([() => g.value, () => n.value], ([y]) => {
588
+ e.value.scrollLeft = y, i.value.scrollLeft = y, f.value = !!y, C.value = i.value.scrollWidth - i.value.offsetWidth > y;
589
+ }), qe(async () => {
590
+ var y, T;
591
+ await he(), await he(), ((y = i.value) == null ? void 0 : y.offsetWidth) < ((T = i.value) == null ? void 0 : T.scrollWidth) && (C.value = !0);
592
+ });
593
+ const R = (y) => {
594
+ if (g.value = y.target.scrollLeft, a.value = e.value.scrollHeight - y.target.scrollTop, t != null && t.value) {
595
+ const T = y.target.scrollLeft;
596
+ t.value.scrollLeft !== T && (t.value.scrollLeft = T);
597
+ }
598
+ }, v = (y) => {
599
+ y.key === "Tab" || y.key !== "ArrowRight" && y.key !== "ArrowLeft" || (y.preventDefault(), e.value.scrollLeft = 0, e.value.style.overflowX = "hidden", setTimeout(() => {
600
+ e.value && (e.value.style.overflowX = "auto");
601
+ }));
602
+ }, F = (y) => {
603
+ const T = y.target.scrollLeft;
604
+ e.value.scrollLeft !== T && (e.value.scrollLeft = T);
605
+ }, _ = b(() => {
606
+ var y, T, M, m;
607
+ return (y = l == null ? void 0 : l.pagination) != null && y.value && ((T = l == null ? void 0 : l.stickyPagination) != null && T.value || l != null && l.isDataGridTemplate) && !((M = l == null ? void 0 : l.isLazyLoad) != null && M.value) ? { bottom: `${(((m = c.value) == null ? void 0 : m.clientHeight) ?? 0) + 1}px` } : {};
608
+ });
609
+ return {
610
+ // Values
611
+ scrollLeftPosition: g,
612
+ hasLeftOverflow: f,
613
+ hasRightOverflow: C,
614
+ horizontalScrollbarConditionalStyles: _,
615
+ // Methods
616
+ updateScrollPosition: R,
617
+ updateScrollPositionOnFrozenColumnsNavigation: v,
618
+ syncVirtualScrollerWithBody: F
619
+ };
620
+ }, io = (e, i, a, t) => {
621
+ const c = A(null), n = b(() => {
622
+ var T, M, m, w;
623
+ if (!c.value || c.value.field === be)
624
+ return {
625
+ hoveredOverColumnField: "",
626
+ isSeparatorOffset: !1,
627
+ noBorderLeft: !1,
628
+ noBorderRight: !1
629
+ };
630
+ const l = (M = (T = e.value.find((s) => s.isFrozenColumns)) == null ? void 0 : T.columnSet) == null ? void 0 : M.filter((s) => s.field !== be), g = e.value.find((s) => !(s != null && s.isFrozenColumns)), f = c.value.frozen && (l == null ? void 0 : l[0].field) === c.value.field, C = !c.value.frozen && ((m = g == null ? void 0 : g.columnSet) == null ? void 0 : m[0].field) === c.value.field, R = (i.value || a.value) && f, v = (i.value || a.value) && !l && C, F = l && C, _ = (l == null ? void 0 : l.length) > 0 && c.value.frozen && (l == null ? void 0 : l[l.length - 1].field) === c.value.field, y = a.value && t.value && !c.value.frozen && ((w = g == null ? void 0 : g.columnSet) == null ? void 0 : w[g.columnSet.length - 1].field) === c.value.field;
631
+ return {
632
+ hoveredOverColumnField: c.value.field,
633
+ isSeparatorOffset: y,
634
+ noBorderLeft: !!R || !!v || !!F,
635
+ noBorderRight: !!_ || !!y
636
+ };
637
+ });
638
+ return {
639
+ hoveredOverColumn: c,
640
+ hoveredOverColumnState: n
641
+ };
642
+ }, yt = (e) => {
643
+ const a = dn(e).filter((t) => t.node !== e);
644
+ return (a == null ? void 0 : a.length) > 0 ? (a[0].node.focus(), !0) : !1;
645
+ }, We = (e) => {
646
+ const i = dn(e), a = i == null ? void 0 : i.filter((t) => t.node !== e);
647
+ if ((a == null ? void 0 : a.length) > 0)
648
+ return a.forEach((t) => t.node.setAttribute("tabindex", "-1")), a;
649
+ }, cn = (e) => {
650
+ (e == null ? void 0 : e.length) > 0 && e.forEach((i) => i == null ? void 0 : i.node.setAttribute("tabindex", "0"));
651
+ }, Gt = () => {
652
+ const e = window.getSelection().getRangeAt(0).cloneContents(), i = e.querySelectorAll('[role="row"]');
653
+ let a = "<table>", t = "";
654
+ const c = (n) => {
655
+ n.forEach((l) => {
656
+ const g = l.closest("[role]").getAttribute("role") === "gridcell" ? "td" : "th", f = l.textContent.trim();
657
+ f && (a += `<${g}>${f}</${g}>`, t += `${f} `);
658
+ });
659
+ };
660
+ if (!i.length) {
661
+ const n = e.querySelectorAll(
662
+ '[role="gridcell"] > .b-typography:first-of-type, [role="columnheader"] .b-typography'
663
+ );
664
+ if (n.length)
665
+ a += "<tr>", c(n), a += "</tr>";
666
+ else {
667
+ navigator.clipboard.writeText(e.textContent);
668
+ return;
669
+ }
670
+ }
671
+ i.forEach((n) => {
672
+ const l = n.querySelectorAll(
673
+ '[role="gridcell"] > .b-typography:first-of-type, [role="columnheader"] .b-typography'
674
+ );
675
+ if (a += "<tr>", l.length)
676
+ c(l);
677
+ else {
678
+ const g = n.textContent.trim();
679
+ a += `<td>${g}</td>`, t += `${g} `;
680
+ }
681
+ a += "</tr>", t += `
682
+ `;
683
+ }), a += "</table>", navigator.clipboard.write([
684
+ new ClipboardItem({
685
+ "text/html": new Blob([a], { type: "text/html" }),
686
+ "text/plain": new Blob([t || e.textContent.trim()], { type: "text/plain" })
687
+ })
688
+ ]);
689
+ };
690
+ let Ht = 0;
691
+ const ao = {
692
+ beforeCreate() {
693
+ this.uuid = Ht.toString(), Ht += 1;
694
+ }
695
+ }, ro = { key: 0 }, uo = ["clip-path"], co = ["id"];
696
+ function fo(e, i, a, t, c, n) {
697
+ return u(), L("svg", ne({ role: "img" }, e.$attrs, {
698
+ class: "ui-assets-icons-16",
699
+ xmlns: "http://www.w3.org/2000/svg",
700
+ width: "16",
701
+ height: "16",
702
+ fill: "none"
703
+ }), [
704
+ e.$attrs["svg-title"] ? (u(), L("title", ro, K(e.$attrs["svg-title"]), 1)) : B("", !0),
705
+ O("g", {
706
+ fill: "#001222",
707
+ "clip-path": "url(#uia-ui-assets/icons-16-arrow_up_down_sort__a" + e.uuid + ")"
708
+ }, i[0] || (i[0] = [
709
+ O("path", { d: "M9.06077 4.00011L5.00011 -0.0605469L0.939453 4.00011L2.00011 5.06077L4.25 2.81089V10.75H5.75V2.81066L8.00011 5.06077L9.06077 4.00011Z" }, null, -1),
710
+ O("path", { d: "M10.25 13.1893L8.00011 10.9395L6.93945 12.0001L11.0001 16.0608L15.0608 12.0001L14.0001 10.9395L11.75 13.1896V5.25H10.25V13.1893Z" }, null, -1)
711
+ ]), 8, uo),
712
+ O("defs", null, [
713
+ O("clipPath", {
714
+ id: "uia-ui-assets/icons-16-arrow_up_down_sort__a" + e.uuid
715
+ }, i[1] || (i[1] = [
716
+ O("rect", {
717
+ width: "16",
718
+ height: "16",
719
+ fill: "#fff"
720
+ }, null, -1)
721
+ ]), 8, co)
722
+ ])
723
+ ], 16);
724
+ }
725
+ const go = /* @__PURE__ */ ae(ao, [["render", fo]]);
726
+ let Vt = 0;
727
+ const vo = {
728
+ beforeCreate() {
729
+ this.uuid = Vt.toString(), Vt += 1;
730
+ }
731
+ }, mo = { key: 0 };
732
+ function ho(e, i, a, t, c, n) {
733
+ return u(), L("svg", ne({ role: "img" }, e.$attrs, {
734
+ class: "ui-assets-icons-16",
735
+ xmlns: "http://www.w3.org/2000/svg",
736
+ width: "16",
737
+ height: "16",
738
+ fill: "none"
739
+ }), [
740
+ e.$attrs["svg-title"] ? (u(), L("title", mo, K(e.$attrs["svg-title"]), 1)) : B("", !0),
741
+ i[0] || (i[0] = O("path", {
742
+ fill: "#001222",
743
+ d: "M12.1933 8.7454L7.93903 12.9996L8.99969 14.0603L15.0604 7.99963L8.99969 1.93896L7.93903 2.99963L12.1848 7.24541L1.24902 7.25658L1.25056 8.75658L12.1933 8.7454Z"
744
+ }, null, -1))
745
+ ], 16);
746
+ }
747
+ const Co = /* @__PURE__ */ ae(vo, [["render", ho]]);
748
+ let xt = 0;
749
+ const wo = {
750
+ beforeCreate() {
751
+ this.uuid = xt.toString(), xt += 1;
752
+ }
753
+ }, _o = { key: 0 }, bo = ["clip-path"], yo = ["id"];
754
+ function Eo(e, i, a, t, c, n) {
755
+ return u(), L("svg", ne({ role: "img" }, e.$attrs, {
756
+ class: "ui-assets-icons-16",
757
+ xmlns: "http://www.w3.org/2000/svg",
758
+ width: "16",
759
+ height: "16",
760
+ fill: "none"
761
+ }), [
762
+ e.$attrs["svg-title"] ? (u(), L("title", _o, K(e.$attrs["svg-title"]), 1)) : B("", !0),
763
+ O("g", {
764
+ "clip-path": "url(#uia-ui-assets/icons-16-freeze__a" + e.uuid + ")"
765
+ }, i[0] || (i[0] = [
766
+ O("path", {
767
+ fill: "#001222",
768
+ d: "M7.99989 14.0605L9.49989 15.5605L10.5605 14.4999L8.75 12.6893V10.9334L10.169 10.116L11.6861 10.9939L12.3501 13.4688L13.7988 13.0801L13.2488 11.0301L15.2988 10.4801L14.9101 9.03129L12.4363 9.695L10.9199 8.81745V7.18276L12.4365 6.3051L14.9101 6.96875L15.2988 5.51999L13.2488 4.96999L13.7988 2.91999L12.3501 2.53129L11.686 5.00635L10.1693 5.88407L8.75 5.06648L8.75 3.31043L10.5605 1.49989L9.49989 0.439226L7.99989 1.93923L6.49989 0.439226L5.43923 1.49989L7.25 3.31066V5.06639L5.83078 5.88392L4.31419 5.00626L3.65018 2.53129L2.20141 2.91998L2.384 3.60052L2.38063 3.60143L2.75032 4.97028L0.701408 5.51999L1.0901 6.96875L1.7708 6.78612L1.77173 6.78955L3.56437 6.30541L5.07992 7.18246L5.07992 8.81775L3.564 9.69502L1.0901 9.03129L0.701408 10.4801L2.75141 11.0301L2.20141 13.0801L3.65018 13.4687L4.31414 10.994L5.83106 10.1161L7.25 10.9335V12.6891L5.43923 14.4999L6.49989 15.5605L7.99989 14.0605ZM9.41992 7.18345V8.81644L7.99992 9.63441L6.57992 8.81644L6.57992 7.18345L7.99992 6.36548L9.41992 7.18345Z"
769
+ }, null, -1)
770
+ ]), 8, bo),
771
+ O("defs", null, [
772
+ O("clipPath", {
773
+ id: "uia-ui-assets/icons-16-freeze__a" + e.uuid
774
+ }, i[1] || (i[1] = [
775
+ O("rect", {
776
+ width: "16",
777
+ height: "16",
778
+ fill: "#fff",
779
+ transform: "matrix(1 0 0 -1 0 16)"
780
+ }, null, -1)
781
+ ]), 8, yo)
782
+ ])
783
+ ], 16);
784
+ }
785
+ const fn = /* @__PURE__ */ ae(wo, [["render", Eo]]);
786
+ let Zt = 0;
787
+ const So = {
788
+ beforeCreate() {
789
+ this.uuid = Zt.toString(), Zt += 1;
790
+ }
791
+ }, po = { key: 0 }, Lo = ["clip-path"], Ro = ["id"];
792
+ function Ao(e, i, a, t, c, n) {
793
+ return u(), L("svg", ne({ role: "img" }, e.$attrs, {
794
+ class: "ui-assets-icons-16",
795
+ xmlns: "http://www.w3.org/2000/svg",
796
+ width: "16",
797
+ height: "16",
798
+ fill: "none"
799
+ }), [
800
+ e.$attrs["svg-title"] ? (u(), L("title", po, K(e.$attrs["svg-title"]), 1)) : B("", !0),
801
+ O("g", {
802
+ fill: "#001222",
803
+ "clip-path": "url(#uia-ui-assets/icons-16-sort_ascending__a" + e.uuid + ")"
804
+ }, i[0] || (i[0] = [
805
+ O("path", { d: "M12.0001 1.93945L16.0608 6.00011L15.0001 7.06077L12.75 4.81066V12.75H11.25V4.81089L9.00011 7.06077L7.93945 6.00011L12.0001 1.93945Z" }, null, -1),
806
+ O("path", { d: "M6.75 7.25H1.25V8.75H6.75V7.25Z" }, null, -1),
807
+ O("path", { d: "M1.25 11.25H8.75V12.75H1.25V11.25Z" }, null, -1),
808
+ O("path", { d: "M6.75 3.25H1.25V4.75H6.75V3.25Z" }, null, -1)
809
+ ]), 8, Lo),
810
+ O("defs", null, [
811
+ O("clipPath", {
812
+ id: "uia-ui-assets/icons-16-sort_ascending__a" + e.uuid
813
+ }, i[1] || (i[1] = [
814
+ O("rect", {
815
+ width: "16",
816
+ height: "16",
817
+ fill: "#fff"
818
+ }, null, -1)
819
+ ]), 8, Ro)
820
+ ])
821
+ ], 16);
822
+ }
823
+ const Oo = /* @__PURE__ */ ae(So, [["render", Ao]]);
824
+ let jt = 0;
825
+ const To = {
826
+ beforeCreate() {
827
+ this.uuid = jt.toString(), jt += 1;
828
+ }
829
+ }, No = { key: 0 }, Io = ["clip-path"], $o = ["id"];
830
+ function Do(e, i, a, t, c, n) {
831
+ return u(), L("svg", ne({ role: "img" }, e.$attrs, {
832
+ class: "ui-assets-icons-16",
833
+ xmlns: "http://www.w3.org/2000/svg",
834
+ width: "16",
835
+ height: "16",
836
+ fill: "none"
837
+ }), [
838
+ e.$attrs["svg-title"] ? (u(), L("title", No, K(e.$attrs["svg-title"]), 1)) : B("", !0),
839
+ O("g", {
840
+ fill: "#001222",
841
+ "clip-path": "url(#uia-ui-assets/icons-16-sort_descending__a" + e.uuid + ")"
842
+ }, i[0] || (i[0] = [
843
+ O("path", { d: "M12.75 3.25V11.1896L15.0001 8.93945L16.0608 10.0001L12.0001 14.0608L7.93945 10.0001L9.00011 8.93945L11.25 11.1893V3.25H12.75Z" }, null, -1),
844
+ O("path", { d: "M6.75 7.25H1.25V8.75H6.75V7.25Z" }, null, -1),
845
+ O("path", { d: "M1.25 3.25H9.09V4.75H1.25V3.25Z" }, null, -1),
846
+ O("path", { d: "M6.75 11.25H1.25V12.75H6.75V11.25Z" }, null, -1)
847
+ ]), 8, Io),
848
+ O("defs", null, [
849
+ O("clipPath", {
850
+ id: "uia-ui-assets/icons-16-sort_descending__a" + e.uuid
851
+ }, i[1] || (i[1] = [
852
+ O("rect", {
853
+ width: "16",
854
+ height: "16",
855
+ fill: "#fff"
856
+ }, null, -1)
857
+ ]), 8, $o)
858
+ ])
859
+ ], 16);
860
+ }
861
+ const ko = /* @__PURE__ */ ae(To, [["render", Do]]);
862
+ let qt = 0;
863
+ const Mo = {
864
+ beforeCreate() {
865
+ this.uuid = qt.toString(), qt += 1;
866
+ }
867
+ }, Fo = { key: 0 };
868
+ function Uo(e, i, a, t, c, n) {
869
+ return u(), L("svg", ne({ role: "img" }, e.$attrs, {
870
+ class: "ui-assets-icons-16",
871
+ xmlns: "http://www.w3.org/2000/svg",
872
+ width: "16",
873
+ height: "16",
874
+ fill: "none"
875
+ }), [
876
+ e.$attrs["svg-title"] ? (u(), L("title", Fo, K(e.$attrs["svg-title"]), 1)) : B("", !0),
877
+ i[0] || (i[0] = O("path", {
878
+ fill: "#001222",
879
+ d: "M8 11.25L12.5 5.25H3.5L8 11.25Z"
880
+ }, null, -1))
881
+ ], 16);
882
+ }
883
+ const zo = /* @__PURE__ */ ae(Mo, [["render", Uo]]), gn = {
884
+ "en-US": {
885
+ columnActions: "{name} column actions",
886
+ deselectAll: "Deselect all",
887
+ freezeColumn: "Freeze column",
888
+ hideColumn: "Hide column",
889
+ moveColumnLeft: "Move column left",
890
+ moveColumnRight: "Move column right",
891
+ rowActionsColumn: "Row actions column",
892
+ selectAll: "Select all",
893
+ selectAllMenu: "Select all menu",
894
+ selectPage: "Select this page",
895
+ selectionMenu: "Selection menu",
896
+ showColumn: "Show column",
897
+ sortColumn: "Sort {name} column",
898
+ sortColumnInAscendingOrder: "Sort {name} column in ascending order",
899
+ sortColumnInDescendingOrder: "Sort {name} column in descending order",
900
+ unfreezeColumn: "Unfreeze column"
901
+ },
902
+ "ja-JP": {
903
+ freezeColumn: "列を固定",
904
+ hideColumn: "列を非表示",
905
+ moveColumnLeft: "列を左へ移動",
906
+ moveColumnRight: "列を右へ移動",
907
+ selectAll: "すべて選択",
908
+ unfreezeColumn: "列の固定を解除"
909
+ },
910
+ "pt-BR": {
911
+ freezeColumn: "Congelar coluna",
912
+ hideColumn: "Ocultar coluna",
913
+ moveColumnLeft: "Mover coluna para a esquerda",
914
+ moveColumnRight: "Mover coluna para a direita",
915
+ selectAll: "Selecionar tudo",
916
+ unfreezeColumn: "Descongelar coluna"
917
+ }
918
+ }, Po = ["aria-colindex", "aria-label", "aria-sort", "data-testid", "draggable", "tabindex"], Bo = { class: "b-data-grid-columns__select-column-menu-button" }, Wo = ["aria-label"], Go = { class: "b-data-grid-columns__label" }, Ho = {
919
+ key: 0,
920
+ class: "b-data-grid-columns__column-info-icon"
921
+ }, Vo = {
922
+ key: 1,
923
+ class: "b-data-grid-columns__column-sort"
924
+ }, xo = ["data-testid", "onMousedown"], Zo = {
925
+ key: 0,
926
+ class: "b-data-grid-columns__column-separator"
927
+ }, jo = ["aria-label", "aria-colindex"], qo = {
928
+ i18n: { messages: gn },
929
+ name: "data-grid-columns"
930
+ }, Ko = /* @__PURE__ */ Ie({
931
+ ...qo,
932
+ props: {
933
+ /**
934
+ * Column definitions using 'key' to relate to data object.
935
+ */
936
+ columns: {
937
+ type: Array,
938
+ required: !0
939
+ },
940
+ /**
941
+ * Columns being dragged, contains dragging column and a target column
942
+ */
943
+ draggingColumns: {
944
+ type: Object,
945
+ default: void 0
946
+ },
947
+ /**
948
+ * Toggle the columns draggable events.
949
+ */
950
+ hasDraggableColumns: {
951
+ type: Boolean,
952
+ default: !0
953
+ },
954
+ /**
955
+ * If resize is enabled
956
+ */
957
+ hasResizableColumns: {
958
+ type: Boolean,
959
+ default: !0
960
+ },
961
+ /**
962
+ * Signifies if the column panel is enabled.
963
+ */
964
+ hasColumnPanel: {
965
+ type: Boolean,
966
+ default: !1
967
+ },
968
+ /**
969
+ * If set to true, aligns the first column panel to the right of its button.
970
+ */
971
+ hasFirstColumnPanelRightAligned: {
972
+ type: Boolean,
973
+ default: !1
974
+ },
975
+ /**
976
+ * If the data grid has overflow on the left side
977
+ */
978
+ hasLeftOverflow: {
979
+ type: Boolean,
980
+ default: !1
981
+ },
982
+ /**
983
+ * The column hovered over state and whether the hovered over column should show a border right or left.
984
+ */
985
+ hoveredOverColumnState: {
986
+ type: Object,
987
+ required: !0
988
+ },
989
+ /**
990
+ * Toggled to true when the DataGrid has auto width columns and is measuring the
991
+ */
992
+ isMeasuringColumnWidths: {
993
+ type: Boolean,
994
+ default: !1
995
+ },
996
+ /**
997
+ * Used to disable hiding the last visible column.
998
+ */
999
+ isOnlyOneVisibleColumn: {
1000
+ type: Boolean,
1001
+ default: !1
1002
+ },
1003
+ /**
1004
+ * If these columns are frozen (pinned) columns
1005
+ */
1006
+ isFrozenColumns: {
1007
+ type: Boolean,
1008
+ default: !1
1009
+ },
1010
+ /**
1011
+ * Show frozen columns separator
1012
+ */
1013
+ showFrozenColumnsSeparator: {
1014
+ type: Boolean,
1015
+ default: !1
1016
+ },
1017
+ /**
1018
+ * The column all items selected state
1019
+ */
1020
+ allItemsSelectedState: {
1021
+ type: Object,
1022
+ default: void 0
1023
+ },
1024
+ /**
1025
+ * Determines if the user has enabled row selection
1026
+ */
1027
+ selectable: {
1028
+ type: Boolean,
1029
+ default: !1
1030
+ },
1031
+ /**
1032
+ * Adds an extra option when selecting all, to select items in other pages too
1033
+ */
1034
+ selectableAcrossPages: {
1035
+ type: Boolean,
1036
+ default: !1
1037
+ },
1038
+ /**
1039
+ * Determines which state of row selection is currently active. Used to display the "Select all" menu options.
1040
+ */
1041
+ selectionState: {
1042
+ type: String,
1043
+ default: void 0
1044
+ },
1045
+ /**
1046
+ * Sortby handles proper rendering of sort icon in header. Sorting currently is only supported server side.
1047
+ * It does make sure the currently sorted column has a more visible sort icon, and the sort icon points in the right direction.
1048
+ */
1049
+ sortBy: {
1050
+ type: Array,
1051
+ // NOTE: is an array to allow multi-sorting in the future
1052
+ default: () => []
1053
+ },
1054
+ /**
1055
+ * Truncates all data grid column headers
1056
+ */
1057
+ truncateColumnHeaders: {
1058
+ type: Boolean,
1059
+ default: !1
1060
+ },
1061
+ /**
1062
+ * The maximum width of the row actions in all rows
1063
+ */
1064
+ rowActionsMaximumWidth: {
1065
+ type: Number,
1066
+ default: 0
1067
+ }
1068
+ },
1069
+ emits: ["sort", "column-hover"],
1070
+ setup(e, { expose: i, emit: a }) {
1071
+ const t = e, c = a, n = 100, { t: l } = Ue({ messages: gn }), { columns: g, sortBy: f } = vt(t), C = A({}), R = A({}), v = A(), F = A(), _ = (d) => c(te.SELECT_ALL_ROWS, d), y = (d) => d.field === be, T = b(
1072
+ () => [
1073
+ t.selectionState !== "page" && {
1074
+ text: l("selectPage"),
1075
+ handler: () => _(!0)
1076
+ },
1077
+ {
1078
+ text: l("selectAll"),
1079
+ handler: () => c(te.SELECT_ALL_ACROSS_PAGES)
1080
+ },
1081
+ t.selectionState !== "none" && {
1082
+ text: l("deselectAll"),
1083
+ handler: () => c(te.DESELECT_ALL)
1084
+ }
1085
+ ].filter(Boolean)
1086
+ ), { startResize: M, isResizing: m, columnHoverEventToEmitAfterResizing: w } = Bl(g, c), { isSorting: s, getSortingDirection: E, sortByColumnField: I } = Ql(f, g, c), D = (d) => {
1087
+ var oe;
1088
+ if (!d.sortable)
1089
+ return null;
1090
+ const W = (oe = t.sortBy.find(({ field: ee }) => ee === d.field)) == null ? void 0 : oe.direction;
1091
+ return W ? {
1092
+ [Fe.ASCENDING]: lt.ASCENDING,
1093
+ [Fe.DESCENDING]: lt.DESCENDING
1094
+ }[W] : lt.NONE;
1095
+ }, r = b(() => (d) => t.hasDraggableColumns ? {
1096
+ dragstart: (W) => {
1097
+ c(te.COLUMN_DRAG_START, d, W);
1098
+ },
1099
+ dragover: (W) => {
1100
+ W.preventDefault();
1101
+ },
1102
+ dragenter: (W) => {
1103
+ W.preventDefault(), c(te.COLUMN_DRAG_ENTER, d, W);
1104
+ },
1105
+ drop: () => {
1106
+ c(te.COLUMN_DROP, d);
1107
+ },
1108
+ dragend: () => {
1109
+ c(te.COLUMN_DRAG_END);
1110
+ }
1111
+ } : {}), p = b(() => (d) => [
1112
+ {
1113
+ text: l("moveColumnLeft"),
1114
+ handler: () => c(te.COLUMN_MOVE, d, -1),
1115
+ icon: $l,
1116
+ disabled: t.columns[0].field === d.field
1117
+ },
1118
+ {
1119
+ text: l("moveColumnRight"),
1120
+ handler: () => c(te.COLUMN_MOVE, d, 1),
1121
+ icon: Co,
1122
+ disabled: t.columns[t.columns.length - 1].field === d.field
1123
+ },
1124
+ {
1125
+ text: d != null && d.frozen ? l("unfreezeColumn") : l("freezeColumn"),
1126
+ handler: () => c(te.COLUMN_UPDATE, { ...d, frozen: !(d != null && d.frozen) }),
1127
+ icon: fn
1128
+ },
1129
+ {
1130
+ text: (d == null ? void 0 : d.visible) !== !1 ? l("hideColumn") : l("showColumn"),
1131
+ handler: () => {
1132
+ c(te.COLUMN_UPDATE, {
1133
+ ...d,
1134
+ visible: (d == null ? void 0 : d.visible) === !1
1135
+ });
1136
+ },
1137
+ icon: (d == null ? void 0 : d.visible) !== !1 ? Dl : kl,
1138
+ disabled: (d == null ? void 0 : d.mandatory) || (d == null ? void 0 : d.visible) !== !1 && t.isOnlyOneVisibleColumn
1139
+ }
1140
+ ]), U = (d) => {
1141
+ v.value = d.field, F.value && clearTimeout(F.value);
1142
+ }, J = () => {
1143
+ const d = setTimeout(() => {
1144
+ v.value = "";
1145
+ }, n);
1146
+ F.value = d;
1147
+ }, ue = (d) => {
1148
+ let W = {
1149
+ mouseenter: () => {
1150
+ U(d), m.value ? w.value = d : c("column-hover", d);
1151
+ },
1152
+ mouseleave: () => {
1153
+ J(), m.value ? w.value = null : c("column-hover", null);
1154
+ },
1155
+ focus: () => {
1156
+ U(d), y(d) && yt(C.value[d.field]);
1157
+ },
1158
+ focusout: (N) => {
1159
+ var oe, ee;
1160
+ (ee = (oe = C.value) == null ? void 0 : oe[d.field]) != null && ee.contains(N == null ? void 0 : N.relatedTarget) || J();
1161
+ }
1162
+ };
1163
+ return y(d) || (W = {
1164
+ ...W,
1165
+ ...r.value(d)
1166
+ }), W;
1167
+ }, le = (d) => d.infoIconTooltip || d.sortable || t.hasColumnPanel, Ce = (d, W) => {
1168
+ var N;
1169
+ ((N = C.value) == null ? void 0 : N[W]) === void 0 && (C.value = { ...C.value, [W]: null }), d !== null && (C.value[W] = d);
1170
+ }, we = b(() => {
1171
+ var W;
1172
+ const d = {
1173
+ "b-data-grid-columns--is-measuring": t.isMeasuringColumnWidths
1174
+ };
1175
+ return (W = g.value[0]) != null && W.frozen ? {
1176
+ ...d,
1177
+ "b-data-grid-columns--frozen": !0,
1178
+ "b-data-grid-columns--frozen-separator": t.showFrozenColumnsSeparator,
1179
+ "b-data-grid-columns--overflow-shadow-left": t.hasLeftOverflow
1180
+ } : {
1181
+ ...d,
1182
+ "b-data-grid-columns--unfrozen": !0
1183
+ };
1184
+ }), ce = b(() => ({
1185
+ "b-data-grid-columns__select-column--all": t.selectableAcrossPages
1186
+ })), me = (d, W) => d && W === 0 ? Mt.BOTTOM_START : Mt.BOTTOM_END, Q = (d, W) => {
1187
+ var N, oe, ee, Ge, ze, S, k, Y, H, se;
1188
+ return {
1189
+ "b-data-grid-columns__column--column-hovered": d.field === t.hoveredOverColumnState.hoveredOverColumnField,
1190
+ "b-data-grid-columns__column--column-hovered-no-border-left": d.field === t.hoveredOverColumnState.hoveredOverColumnField && t.hoveredOverColumnState.noBorderLeft,
1191
+ "b-data-grid-columns__column--column-hovered-no-border-right": d.field === t.hoveredOverColumnState.hoveredOverColumnField && t.hoveredOverColumnState.noBorderRight,
1192
+ "b-data-grid-columns__column--last-frozen-frozen-column": t.isFrozenColumns && W === g.value.length - 1,
1193
+ "b-data-grid-columns__column--sortable": d.sortable,
1194
+ "b-data-grid-columns__column--padding-left-unset": ((N = d == null ? void 0 : d.padding) == null ? void 0 : N.left) === !1,
1195
+ "b-data-grid-columns__column--padding-right-unset": ((oe = d == null ? void 0 : d.padding) == null ? void 0 : oe.right) === !1,
1196
+ "b-data-grid-columns__column--numeric": d == null ? void 0 : d.numeric,
1197
+ "b-data-grid-columns__column--frozen": d == null ? void 0 : d.frozen,
1198
+ "b-data-grid-columns__column--is-re-ordering": (d == null ? void 0 : d.field) === ((Ge = (ee = t.draggingColumns) == null ? void 0 : ee.dragging) == null ? void 0 : Ge.field),
1199
+ "b-data-grid-columns__column--is-re-ordering-target-left": (d == null ? void 0 : d.field) === ((S = (ze = t.draggingColumns) == null ? void 0 : ze.target) == null ? void 0 : S.field) && ((k = t.draggingColumns) == null ? void 0 : k.dragToLeft),
1200
+ "b-data-grid-columns__column--is-re-ordering-target-right": (d == null ? void 0 : d.field) === ((H = (Y = t.draggingColumns) == null ? void 0 : Y.target) == null ? void 0 : H.field) && !((se = t.draggingColumns) != null && se.dragToLeft),
1201
+ "b-data-grid-columns__column--with-sorting-or-column-panel": d.sortable || d.infoIconTooltip || t.hasColumnPanel && v.value === d.field || t.selectableAcrossPages
1202
+ };
1203
+ }, h = (d) => ({
1204
+ "b-data-grid-columns__column-header-and-actions--numeric": d == null ? void 0 : d.numeric
1205
+ }), j = (d) => ({
1206
+ "b-data-grid-columns__column-actions--numeric": d == null ? void 0 : d.numeric
1207
+ }), Z = (d) => ({
1208
+ "b-data-grid-columns__column-separator-container--is-resizeable": t.hasResizableColumns,
1209
+ "b-data-grid-columns__column-separator-container--is-offset": t.hoveredOverColumnState.hoveredOverColumnField === d.field && t.hoveredOverColumnState.isSeparatorOffset
1210
+ }), x = b(() => ({
1211
+ "b-data-grid-columns__column-header--truncated": t.truncateColumnHeaders
1212
+ }));
1213
+ return i({
1214
+ columnHeaderRefs: C
1215
+ }), (d, W) => (u(), L("div", {
1216
+ class: de(["b-data-grid-columns", we.value]),
1217
+ "data-testid": "data-grid-columns"
1218
+ }, [
1219
+ (u(!0), L(ve, null, ye(o(g), (N, oe) => (u(), L("div", ne({
1220
+ key: N.field,
1221
+ ref_for: !0,
1222
+ ref: (ee) => Ce(ee, N.field),
1223
+ "aria-colindex": oe + 1,
1224
+ "aria-label": N.label,
1225
+ "aria-sort": D(N),
1226
+ class: [Q(N, oe), "b-data-grid-columns__column"],
1227
+ "data-testid": `${N.field}-column-header`,
1228
+ draggable: e.hasDraggableColumns && !o(m) && !y(N),
1229
+ role: "columnheader",
1230
+ tabindex: N.sortable || e.hasColumnPanel || N.infoIconTooltip ? "0" : "-1",
1231
+ style: { width: N.autoWidth && e.isMeasuringColumnWidths ? "auto" : `${N.width}px` }
1232
+ }, ot(ue(N), !0)), [
1233
+ y(N) && e.selectable ? (u(), L("div", {
1234
+ key: 0,
1235
+ class: de(["b-data-grid-columns__select-column", ce.value])
1236
+ }, [
1237
+ e.selectableAcrossPages ? B("", !0) : (u(), G(o(nt), {
1238
+ key: 0,
1239
+ "aria-label": o(l)("selectAll"),
1240
+ "model-value": e.allItemsSelectedState.allItemsSelected,
1241
+ "data-testid": "checkbox-select-all",
1242
+ indeterminate: e.allItemsSelectedState.isIndeterminate,
1243
+ value: "data-grid-select-all",
1244
+ "onUpdate:modelValue": _
1245
+ }, null, 8, ["aria-label", "model-value", "indeterminate"])),
1246
+ e.selectableAcrossPages ? (u(), L(ve, { key: 1 }, [
1247
+ e.selectionState === "all" ? (u(), G(o(nt), {
1248
+ key: 0,
1249
+ "aria-label": o(l)("deselectAll"),
1250
+ "model-value": e.allItemsSelectedState.allItemsSelected,
1251
+ "data-testid": "checkbox-deselect-all",
1252
+ value: "data-grid-deselect-all",
1253
+ class: "b-data-grid-columns__deselect-all-checkbox",
1254
+ onInput: W[0] || (W[0] = (ee) => d.$emit(o(te).DESELECT_ALL))
1255
+ }, null, 8, ["aria-label", "model-value"])) : (u(), G(o(ct), {
1256
+ key: 1,
1257
+ "aria-label": o(l)("selectAllMenu"),
1258
+ button: { variant: "tertiary", condensed: !0 },
1259
+ data: T.value,
1260
+ class: "b-data-grid-columns__select-column-menu",
1261
+ "disable-arrow-down-opening-menu": "",
1262
+ "menu-fixed-positioning": "",
1263
+ "menu-position": "bottom-start"
1264
+ }, {
1265
+ iconLeft: V(() => [
1266
+ O("div", Bo, [
1267
+ X(o(nt), {
1268
+ indeterminate: e.allItemsSelectedState.isIndeterminate,
1269
+ "model-value": e.allItemsSelectedState.allItemsSelected,
1270
+ "aria-hidden": "true",
1271
+ class: "b-data-grid-columns__select-column-menu-checkbox",
1272
+ "data-testid": "checkbox-select-all",
1273
+ tabindex: "-1",
1274
+ value: "data-grid-select-all"
1275
+ }, null, 8, ["indeterminate", "model-value"]),
1276
+ X(o(zo), {
1277
+ "svg-title": o(l)("selectionMenu"),
1278
+ "aria-hidden": "true"
1279
+ }, null, 8, ["svg-title"])
1280
+ ])
1281
+ ]),
1282
+ _: 1
1283
+ }, 8, ["aria-label", "data"]))
1284
+ ], 64)) : B("", !0)
1285
+ ], 2)) : (u(), L(ve, { key: 1 }, [
1286
+ O("div", {
1287
+ "aria-label": o(l)("columnActions", { name: N.label }),
1288
+ "aria-live": "polite",
1289
+ role: "region",
1290
+ class: de(["b-data-grid-columns__column-header-and-actions", h(N)])
1291
+ }, [
1292
+ X(o(Ke), {
1293
+ el: "div",
1294
+ strongest: "",
1295
+ class: de(["b-data-grid-columns__column-header", x.value])
1296
+ }, {
1297
+ default: V(() => [
1298
+ Ne(d.$slots, `head-${N.field}`, { column: N }, () => [
1299
+ O("span", Go, K(N.label), 1)
1300
+ ], !0)
1301
+ ]),
1302
+ _: 2
1303
+ }, 1032, ["class"]),
1304
+ le(N) ? (u(), L("div", {
1305
+ key: 0,
1306
+ class: de(["b-data-grid-columns__column-actions", j(N)])
1307
+ }, [
1308
+ N.infoIconTooltip ? (u(), L("div", Ho, [
1309
+ X(o(Tl), {
1310
+ "tooltip-text": N.infoIconTooltip
1311
+ }, null, 8, ["tooltip-text"])
1312
+ ])) : B("", !0),
1313
+ N.sortable ? (u(), L("div", Vo, [
1314
+ X(o(bt), {
1315
+ condensed: "",
1316
+ toggled: o(s)(N.field),
1317
+ variant: "tertiary",
1318
+ onClick: (ee) => o(I)(N.field)
1319
+ }, {
1320
+ iconLeft: V(() => [
1321
+ o(E)(N.field) ? o(E)(N.field) === o(Fe).ASCENDING ? (u(), G(o(Oo), {
1322
+ key: 1,
1323
+ "svg-title": o(l)("sortColumnInDescendingOrder", { name: N.label })
1324
+ }, null, 8, ["svg-title"])) : o(E)(N.field) === o(Fe).DESCENDING ? (u(), G(o(ko), {
1325
+ key: 2,
1326
+ "svg-title": o(l)("sortColumnInAscendingOrder", { name: N.label })
1327
+ }, null, 8, ["svg-title"])) : B("", !0) : (u(), G(o(go), {
1328
+ key: 0,
1329
+ "svg-title": o(l)("sortColumn", { name: N.label })
1330
+ }, null, 8, ["svg-title"]))
1331
+ ]),
1332
+ _: 2
1333
+ }, 1032, ["toggled", "onClick"])
1334
+ ])) : B("", !0),
1335
+ e.hasColumnPanel && v.value === N.field ? (u(), G(o(ct), {
1336
+ key: 2,
1337
+ ref_for: !0,
1338
+ ref: (ee) => R.value[N.field] = ee,
1339
+ class: "b-data-grid-columns__menu",
1340
+ "disable-arrow-down-opening-menu": "",
1341
+ data: p.value(N),
1342
+ "menu-position": me(e.hasFirstColumnPanelRightAligned, oe),
1343
+ "menu-fixed-positioning": !0,
1344
+ button: { variant: "tertiary", condensed: !0 },
1345
+ onOpen: W[1] || (W[1] = (ee) => d.$emit(o(te).COLUMN_MENU_OPEN)),
1346
+ onClose: W[2] || (W[2] = (ee) => d.$emit(o(te).COLUMN_MENU_CLOSE))
1347
+ }, null, 8, ["data", "menu-position"])) : B("", !0)
1348
+ ], 2)) : B("", !0)
1349
+ ], 10, Wo),
1350
+ O("div", {
1351
+ "data-testid": `data-grid-column-${N.field}`,
1352
+ class: de(["b-data-grid-columns__column-separator-container", Z(N)]),
1353
+ role: "presentation",
1354
+ onMousedown: (ee) => o(M)(e.hasResizableColumns, N.field, ee),
1355
+ onClick: W[3] || (W[3] = sl(() => {
1356
+ }, ["stop"]))
1357
+ }, [
1358
+ !e.isFrozenColumns || e.isFrozenColumns && oe !== o(g).length - 1 ? (u(), L("div", Zo)) : B("", !0)
1359
+ ], 42, xo)
1360
+ ], 64))
1361
+ ], 16, Po))), 128)),
1362
+ e.rowActionsMaximumWidth && !e.isFrozenColumns ? (u(), L(ve, { key: 0 }, [
1363
+ W[4] || (W[4] = O("div", {
1364
+ role: "presentation",
1365
+ class: "b-data-grid-columns__row-actions-filler"
1366
+ }, null, -1)),
1367
+ O("div", {
1368
+ ref: (N) => Ce(N, o(je)),
1369
+ "aria-label": o(l)("rowActionsColumn"),
1370
+ "aria-colindex": o(g).length + 1,
1371
+ class: "b-data-grid-columns__column",
1372
+ role: "columnheader",
1373
+ tabindex: "0",
1374
+ style: Me({ minWidth: `${e.rowActionsMaximumWidth}px` })
1375
+ }, null, 12, jo)
1376
+ ], 64)) : B("", !0)
1377
+ ], 2));
1378
+ }
1379
+ }), Yo = /* @__PURE__ */ ae(Ko, [["__scopeId", "data-v-15a1b61b"]]);
1380
+ var ke = /* @__PURE__ */ ((e) => (e.CONFIG_SETTINGS = "config-settings", e.UPDATE_COLUMNS = "update:columns", e))(ke || {});
1381
+ let Kt = 0;
1382
+ const Xo = {
1383
+ beforeCreate() {
1384
+ this.uuid = Kt.toString(), Kt += 1;
1385
+ }
1386
+ }, Jo = { key: 0 }, Qo = ["clip-path"], es = ["id"];
1387
+ function ts(e, i, a, t, c, n) {
1388
+ return u(), L("svg", ne({ role: "img" }, e.$attrs, {
1389
+ class: "ui-assets-icons-16",
1390
+ xmlns: "http://www.w3.org/2000/svg",
1391
+ width: "16",
1392
+ height: "16",
1393
+ fill: "none"
1394
+ }), [
1395
+ e.$attrs["svg-title"] ? (u(), L("title", Jo, K(e.$attrs["svg-title"]), 1)) : B("", !0),
1396
+ O("g", {
1397
+ fill: "#001222",
1398
+ "clip-path": "url(#uia-ui-assets/icons-16-settings__a" + e.uuid + ")"
1399
+ }, i[0] || (i[0] = [
1400
+ O("path", { d: "M8 5.25C6.48122 5.25 5.25 6.48122 5.25 8C5.25 9.51878 6.48122 10.75 8 10.75C9.51878 10.75 10.75 9.51878 10.75 8C10.75 6.48122 9.51878 5.25 8 5.25ZM6.75 8C6.75 7.30964 7.30964 6.75 8 6.75C8.69036 6.75 9.25 7.30964 9.25 8C9.25 8.69036 8.69036 9.25 8 9.25C7.30964 9.25 6.75 8.69036 6.75 8Z" }, null, -1),
1401
+ O("path", { d: "M6.84701 0.973015L6.59985 0.35083L5.9537 0.526056C4.64534 0.880867 3.48225 1.56808 2.55285 2.48641L2.07533 2.95826L2.49158 3.48495C2.79648 3.87074 2.85279 4.419 2.58992 4.87589C2.32905 5.32931 1.82436 5.55631 1.33473 5.48726L0.677319 5.39455L0.505539 6.03586C0.33838 6.65992 0.25 7.32519 0.25 7.99991C0.25 8.67463 0.33838 9.3399 0.505539 9.96396L0.677319 10.6053L1.33473 10.5126C1.82436 10.4435 2.32905 10.6705 2.58992 11.1239C2.85279 11.5808 2.79648 12.1291 2.49158 12.5149L2.07533 13.0416L2.55285 13.5134C3.48225 14.4317 4.64534 15.119 5.9537 15.4738L6.59985 15.649L6.84701 15.0268C7.02659 14.5748 7.47549 14.2499 8 14.2499C8.52452 14.2499 8.97341 14.5748 9.15299 15.0268L9.40016 15.649L10.0463 15.4738C11.3547 15.119 12.5177 14.4317 13.4471 13.5134L13.9247 13.0416L13.5084 12.5149C13.2035 12.1291 13.1472 11.5808 13.4101 11.1239C13.671 10.6705 14.1756 10.4435 14.6653 10.5126L15.3227 10.6053L15.4945 9.96396C15.6616 9.3399 15.75 8.67463 15.75 7.99991C15.75 7.32519 15.6616 6.65992 15.4945 6.03586L15.3227 5.39455L14.6653 5.48726C14.1756 5.55631 13.671 5.32931 13.4101 4.87589C13.1472 4.419 13.2035 3.87074 13.5084 3.48495L13.9247 2.95826L13.4471 2.48641C12.5177 1.56808 11.3547 0.880867 10.0463 0.526056L9.40016 0.35083L9.15299 0.973015C8.97341 1.42506 8.52452 1.74991 8 1.74991C7.47549 1.74991 7.02659 1.42506 6.84701 0.973015ZM3.89008 5.62393C4.33946 4.84286 4.36394 3.9353 4.03405 3.16853C4.55803 2.73795 5.15349 2.39116 5.80146 2.14902C6.30062 2.81653 7.10051 3.24991 8 3.24991C8.89949 3.24991 9.69938 2.81653 10.1985 2.14902C10.8465 2.39116 11.442 2.73795 11.966 3.16853C11.6361 3.9353 11.6605 4.84287 12.1099 5.62393C12.5612 6.40839 13.3382 6.88092 14.1658 6.97982C14.221 7.31075 14.25 7.65319 14.25 7.99991C14.25 8.34663 14.221 8.68908 14.1658 9.02001C13.3382 9.11891 12.5612 9.59143 12.1099 10.3759C11.6605 11.157 11.6361 12.0645 11.9659 12.8313C11.442 13.2619 10.8465 13.6087 10.1985 13.8508C9.69938 13.1833 8.89949 12.7499 8 12.7499C7.10051 12.7499 6.30062 13.1833 5.80146 13.8508C5.15349 13.6087 4.55803 13.2619 4.03405 12.8313C4.36394 12.0645 4.33946 11.157 3.89008 10.3759C3.43875 9.59143 2.66177 9.1189 1.8342 9.02C1.77896 8.68908 1.75 8.34663 1.75 7.99991C1.75 7.65319 1.77896 7.31074 1.8342 6.97982C2.66177 6.88092 3.43875 6.40839 3.89008 5.62393Z" }, null, -1)
1402
+ ]), 8, Qo),
1403
+ O("defs", null, [
1404
+ O("clipPath", {
1405
+ id: "uia-ui-assets/icons-16-settings__a" + e.uuid
1406
+ }, i[1] || (i[1] = [
1407
+ O("rect", {
1408
+ width: "16",
1409
+ height: "16",
1410
+ fill: "#fff"
1411
+ }, null, -1)
1412
+ ]), 8, es)
1413
+ ])
1414
+ ], 16);
1415
+ }
1416
+ const ns = /* @__PURE__ */ ae(Xo, [["render", ts]]), Yt = {
1417
+ "en-US": {
1418
+ toggleColumnFreeze: "Toggle {label} column freeze",
1419
+ toggleColumnVisibility: "Toggle {label} column visibility"
1420
+ }
1421
+ }, ls = Ie({
1422
+ i18n: { messages: Yt },
1423
+ name: "bento-data-grid",
1424
+ components: {
1425
+ BentoFreezeIcon: fn,
1426
+ BentoToggle: rn
1427
+ },
1428
+ props: {
1429
+ /**
1430
+ * Is column visibitlity toggle disabled
1431
+ */
1432
+ isColumnVisibilityToggleDisabled: {
1433
+ type: Boolean,
1434
+ required: !0
1435
+ },
1436
+ /**
1437
+ * Column definition
1438
+ */
1439
+ column: {
1440
+ type: Object,
1441
+ required: !0
1442
+ }
1443
+ },
1444
+ emits: ["visible-column", "updated-column"],
1445
+ setup(e, { emit: i }) {
1446
+ const { t: a } = Ue({ messages: Yt }), t = A(!1), c = b(() => {
1447
+ var v;
1448
+ return (v = e.column) == null ? void 0 : v.frozen;
1449
+ }), n = b(() => {
1450
+ var v;
1451
+ return ((v = e.column) == null ? void 0 : v.visible) !== !1;
1452
+ }), l = () => {
1453
+ i("visible-column", { ...e.column, visible: !n.value });
1454
+ }, g = () => {
1455
+ i("updated-column", { ...e.column, frozen: !c.value });
1456
+ }, f = () => {
1457
+ c.value || (t.value = !0);
1458
+ }, C = () => {
1459
+ c.value || (t.value = !1);
1460
+ }, R = b(() => ({
1461
+ "b-data-grid-config-settings-column-row__freeze-icon--frozen": c.value
1462
+ }));
1463
+ return {
1464
+ // Values
1465
+ isFreezeIconOptionShown: t,
1466
+ isColumnFrozen: c,
1467
+ freezeIconConditionalClasses: R,
1468
+ isColumnVisible: n,
1469
+ // Methods
1470
+ toggleColumnVisibility: l,
1471
+ showFreezeIcon: f,
1472
+ hideFreezeIcon: C,
1473
+ toggleColumnFreeze: g,
1474
+ // Translations
1475
+ t: a
1476
+ };
1477
+ }
1478
+ });
1479
+ function os(e, i, a, t, c, n) {
1480
+ const l = Re("bento-toggle"), g = Re("bento-freeze-icon");
1481
+ return u(), L("div", {
1482
+ class: "b-data-grid-config-settings-column-row",
1483
+ onMouseover: i[0] || (i[0] = (...f) => e.showFreezeIcon && e.showFreezeIcon(...f)),
1484
+ onMouseleave: i[1] || (i[1] = (...f) => e.hideFreezeIcon && e.hideFreezeIcon(...f))
1485
+ }, [
1486
+ X(l, {
1487
+ "aria-label": e.t("toggleColumnVisibility", { label: e.column.label }),
1488
+ disabled: e.isColumnVisibilityToggleDisabled,
1489
+ "label-position": "after",
1490
+ value: e.isColumnVisible,
1491
+ onInput: e.toggleColumnVisibility
1492
+ }, {
1493
+ default: V(() => [
1494
+ ge(K(e.column.label), 1)
1495
+ ]),
1496
+ _: 1
1497
+ }, 8, ["aria-label", "disabled", "value", "onInput"]),
1498
+ mt(X(g, {
1499
+ "aria-label": e.t("toggleColumnFreeze", { label: e.column.label }),
1500
+ class: de(["b-data-grid-config-settings-column-row__freeze-icon", e.freezeIconConditionalClasses]),
1501
+ onClick: e.toggleColumnFreeze
1502
+ }, null, 8, ["aria-label", "class", "onClick"]), [
1503
+ [il, e.isColumnFrozen || e.isFreezeIconOptionShown]
1504
+ ])
1505
+ ], 32);
1506
+ }
1507
+ const ss = /* @__PURE__ */ ae(ls, [["render", os], ["__scopeId", "data-v-bb87a729"]]), Xt = {
1508
+ "en-US": {
1509
+ closeConfigSettingsPanel: "Close configuration settings panel",
1510
+ closeSearch: "Close search",
1511
+ columnVisibilitySearchFilter: "Column visibility search filter",
1512
+ columns: "Columns",
1513
+ condensed: "Condensed",
1514
+ condensedToggle: "Condensed toggle",
1515
+ configSettingsPanel: "Configuration settings Panel",
1516
+ displayOptions: "Display options",
1517
+ noColumnsMatch: "No columns match this search",
1518
+ search: "Search",
1519
+ showAllColumns: "Show all columns ({numberOfColumns})",
1520
+ size: "Size",
1521
+ toggleConfigSettingsPanelVisibility: "Toggle Configuration settings panel visibility"
1522
+ },
1523
+ "ja-JP": {
1524
+ condensed: "凝縮",
1525
+ search: "検索",
1526
+ size: "サイズ"
1527
+ },
1528
+ "pt-BR": {
1529
+ condensed: "Condensado",
1530
+ search: "Buscar",
1531
+ size: "Tamanho"
1532
+ }
1533
+ }, is = Ie({
1534
+ i18n: { messages: Xt },
1535
+ name: "bento-data-grid",
1536
+ components: {
1537
+ BentoButton: an,
1538
+ BentoCrossIcon: on,
1539
+ BentoPopover: pl,
1540
+ BentoSettingsIcon: ns,
1541
+ BentoToggleButton: bt,
1542
+ BentoDataGridConfigSettingsConfigRow: ss,
1543
+ BentoSearchBar: Ll,
1544
+ BentoSearchIcon: Ol,
1545
+ BentoToggle: rn,
1546
+ BentoTypography: Ke
1547
+ },
1548
+ directives: { BentoClickOutsideDirective: Al },
1549
+ props: {
1550
+ /**
1551
+ * Column definitions
1552
+ */
1553
+ columns: {
1554
+ type: Array,
1555
+ required: !0
1556
+ },
1557
+ /**
1558
+ * Sets the row cells to the condensed padding state.
1559
+ */
1560
+ condensed: {
1561
+ type: Boolean,
1562
+ default: !1
1563
+ }
1564
+ },
1565
+ emits: [ke.CONFIG_SETTINGS, ke.UPDATE_COLUMNS],
1566
+ setup(e, { emit: i }) {
1567
+ const { t: a } = Ue({ messages: Xt }), t = A(null), c = ut("data-grid-config-settings-popover"), n = A(null), l = A(!1), g = A(!0), f = A(null), C = A(""), R = rt(e, "columns"), v = A(!1), F = Rl(C, R), _ = () => {
1568
+ C.value = "";
1569
+ }, y = b(
1570
+ () => !e.columns.some((r) => r.visible === !1 && !r.mandatory)
1571
+ ), T = () => {
1572
+ _(), v.value = !v.value, v.value ? he(() => {
1573
+ var r;
1574
+ return (r = n.value.$refs.bentoInputField) == null ? void 0 : r.focusInput();
1575
+ }) : he(() => {
1576
+ var r, p;
1577
+ return (p = (r = f == null ? void 0 : f.value) == null ? void 0 : r.$el) == null ? void 0 : p.focus();
1578
+ }), g.value = y.value;
1579
+ }, M = (r) => r.mandatory ?? !1, m = (r) => {
1580
+ const p = e.columns.map((U) => ({
1581
+ ...U,
1582
+ visible: r.field === U.field ? r.visible : U.visible
1583
+ }));
1584
+ i(ke.UPDATE_COLUMNS, p);
1585
+ }, w = (r) => {
1586
+ r ? i(
1587
+ ke.UPDATE_COLUMNS,
1588
+ e.columns.map((p) => ({ ...p, visible: !0 }))
1589
+ ) : i(
1590
+ ke.UPDATE_COLUMNS,
1591
+ e.columns.map((p) => ({ ...p, visible: (p == null ? void 0 : p.mandatory) === !0 }))
1592
+ );
1593
+ }, s = (r) => {
1594
+ const p = e.columns.map((U) => ({
1595
+ ...U,
1596
+ frozen: r.field === U.field ? !!(r != null && r.frozen) : !!(U != null && U.frozen)
1597
+ }));
1598
+ i(ke.UPDATE_COLUMNS, p);
1599
+ }, E = (r) => {
1600
+ l.value = r, g.value = y.value;
1601
+ };
1602
+ return {
1603
+ // Values
1604
+ configSettingsButtonRef: t,
1605
+ popoverId: c,
1606
+ isConfigSettingsPanelOpen: l,
1607
+ allColumnsVisbilityToggleState: g,
1608
+ filteredColumnVisibilityColumns: F,
1609
+ searchTerm: C,
1610
+ isColumnVisibilityFilterShown: v,
1611
+ searchBarRef: n,
1612
+ searchButtonRef: f,
1613
+ DATAGRID_ACTIONS_COLUMN_FIELD_NAME: be,
1614
+ // Methods
1615
+ setConfigSettingsPanelVisibility: E,
1616
+ emitCondensedToggle: (r) => i(ke.CONFIG_SETTINGS, r),
1617
+ toggleAllColumnVisibility: w,
1618
+ clearAction: _,
1619
+ toggleColumnFilter: T,
1620
+ emitVisibleColumns: m,
1621
+ emitFrozenColumns: s,
1622
+ onClickOutside: () => E(!1),
1623
+ isColumnVisibilityToggleDisabled: M,
1624
+ // Translations
1625
+ t: a
1626
+ };
1627
+ }
1628
+ }), as = { class: "b-data-grid-config-settings" }, rs = { class: "b-data-grid-config-settings__button-and-separator" }, ds = {
1629
+ ref: "configSettingsButtonRef",
1630
+ class: "b-data-grid-config-settings__button-container"
1631
+ }, us = { class: "b-data-grid-config-settings__panel-header" }, cs = { class: "b-data-grid-config-settings__condensed-view-settings" }, fs = { class: "b-data-grid-config-settings__column-visibility-settings" }, gs = { class: "b-data-grid-config-settings__column-visibility-header" }, vs = {
1632
+ key: 0,
1633
+ class: "b-data-grid-config-settings__column-visibility-search"
1634
+ }, ms = {
1635
+ key: 1,
1636
+ class: "b-data-grid-config-settings__column-visibility-show-all"
1637
+ }, hs = { class: "b-data-grid-config-settings__column-visibility-toggles" };
1638
+ function Cs(e, i, a, t, c, n) {
1639
+ const l = Re("bento-settings-icon"), g = Re("bento-toggle-button"), f = Re("bento-typography"), C = Re("bento-cross-icon"), R = Re("bento-button"), v = Re("bento-toggle"), F = Re("bento-search-icon"), _ = Re("bento-search-bar"), y = Re("bento-data-grid-config-settings-config-row"), T = Re("bento-popover"), M = al("bento-click-outside-directive");
1640
+ return mt((u(), L("div", as, [
1641
+ O("div", rs, [
1642
+ O("div", ds, [
1643
+ X(g, {
1644
+ "aria-controls": e.isConfigSettingsPanelOpen ? e.popoverId : null,
1645
+ variant: "tertiary",
1646
+ condensed: "",
1647
+ toggled: e.isConfigSettingsPanelOpen,
1648
+ onClick: i[0] || (i[0] = (m) => e.setConfigSettingsPanelVisibility(!e.isConfigSettingsPanelOpen))
1649
+ }, {
1650
+ iconLeft: V(() => [
1651
+ X(l, {
1652
+ "svg-title": e.t("toggleConfigSettingsPanelVisibility")
1653
+ }, null, 8, ["svg-title"])
1654
+ ]),
1655
+ _: 1
1656
+ }, 8, ["aria-controls", "toggled"])
1657
+ ], 512)
1658
+ ]),
1659
+ e.configSettingsButtonRef ? (u(), G(T, {
1660
+ key: 0,
1661
+ id: e.popoverId,
1662
+ open: e.isConfigSettingsPanelOpen,
1663
+ class: "b-data-grid-config-settings__panel",
1664
+ "aria-label": e.t("configSettingsPanel"),
1665
+ "target-element": e.configSettingsButtonRef,
1666
+ position: "bottom-end"
1667
+ }, {
1668
+ default: V(() => [
1669
+ O("div", us, [
1670
+ X(f, {
1671
+ el: "span",
1672
+ strongest: ""
1673
+ }, {
1674
+ default: V(() => [
1675
+ ge(K(e.t("displayOptions")), 1)
1676
+ ]),
1677
+ _: 1
1678
+ }),
1679
+ X(R, {
1680
+ variant: "tertiary",
1681
+ onClick: i[1] || (i[1] = (m) => e.setConfigSettingsPanelVisibility(!1))
1682
+ }, {
1683
+ iconLeft: V(() => [
1684
+ X(C, {
1685
+ "svg-title": e.t("closeConfigSettingsPanel")
1686
+ }, null, 8, ["svg-title"])
1687
+ ]),
1688
+ _: 1
1689
+ })
1690
+ ]),
1691
+ O("div", cs, [
1692
+ X(f, {
1693
+ class: "b-data-grid-config-settings__condensed-view-title",
1694
+ el: "span",
1695
+ stronger: ""
1696
+ }, {
1697
+ default: V(() => [
1698
+ ge(K(e.t("size")), 1)
1699
+ ]),
1700
+ _: 1
1701
+ }),
1702
+ X(v, {
1703
+ "label-position": "after",
1704
+ "aria-label": e.t("condensedToggle"),
1705
+ value: e.condensed,
1706
+ onInput: e.emitCondensedToggle
1707
+ }, {
1708
+ default: V(() => [
1709
+ ge(K(e.t("condensed")), 1)
1710
+ ]),
1711
+ _: 1
1712
+ }, 8, ["aria-label", "value", "onInput"])
1713
+ ]),
1714
+ O("div", fs, [
1715
+ O("div", gs, [
1716
+ X(f, {
1717
+ class: "b-data-grid-config-settings__column-visibility-title",
1718
+ el: "span",
1719
+ stronger: ""
1720
+ }, {
1721
+ default: V(() => [
1722
+ ge(K(e.t("columns")), 1)
1723
+ ]),
1724
+ _: 1
1725
+ }),
1726
+ e.isColumnVisibilityFilterShown ? (u(), G(R, {
1727
+ key: 1,
1728
+ variant: "tertiary",
1729
+ onClick: e.toggleColumnFilter
1730
+ }, {
1731
+ iconLeft: V(() => [
1732
+ X(C)
1733
+ ]),
1734
+ default: V(() => [
1735
+ ge(" " + K(e.t("closeSearch")), 1)
1736
+ ]),
1737
+ _: 1
1738
+ }, 8, ["onClick"])) : (u(), G(R, {
1739
+ key: 0,
1740
+ ref: "searchButtonRef",
1741
+ variant: "tertiary",
1742
+ onClick: e.toggleColumnFilter
1743
+ }, {
1744
+ iconLeft: V(() => [
1745
+ X(F)
1746
+ ]),
1747
+ default: V(() => [
1748
+ ge(K(e.t("search")), 1)
1749
+ ]),
1750
+ _: 1
1751
+ }, 8, ["onClick"]))
1752
+ ]),
1753
+ e.isColumnVisibilityFilterShown ? (u(), L("div", vs, [
1754
+ X(_, {
1755
+ ref: "searchBarRef",
1756
+ value: e.searchTerm,
1757
+ "input-field-aria-label": e.t("columnVisibilitySearchFilter").toString(),
1758
+ onInput: i[2] || (i[2] = (m) => e.searchTerm = m),
1759
+ onClear: e.clearAction,
1760
+ onEscapePressed: e.toggleColumnFilter
1761
+ }, null, 8, ["value", "input-field-aria-label", "onClear", "onEscapePressed"])
1762
+ ])) : (u(), L("div", ms, [
1763
+ X(v, {
1764
+ "label-position": "after",
1765
+ value: e.allColumnsVisbilityToggleState,
1766
+ onInput: e.toggleAllColumnVisibility
1767
+ }, {
1768
+ default: V(() => [
1769
+ ge(K(e.t("showAllColumns", { numberOfColumns: e.columns.length })), 1)
1770
+ ]),
1771
+ _: 1
1772
+ }, 8, ["value", "onInput"])
1773
+ ])),
1774
+ O("div", hs, [
1775
+ (u(!0), L(ve, null, ye(e.filteredColumnVisibilityColumns, (m) => (u(), L("div", {
1776
+ key: m.field
1777
+ }, [
1778
+ m.field !== e.DATAGRID_ACTIONS_COLUMN_FIELD_NAME ? (u(), G(y, {
1779
+ key: 0,
1780
+ column: m,
1781
+ "is-column-visibility-toggle-disabled": e.isColumnVisibilityToggleDisabled(m),
1782
+ onVisibleColumn: e.emitVisibleColumns,
1783
+ onUpdatedColumn: e.emitFrozenColumns
1784
+ }, null, 8, ["column", "is-column-visibility-toggle-disabled", "onVisibleColumn", "onUpdatedColumn"])) : B("", !0)
1785
+ ]))), 128)),
1786
+ e.filteredColumnVisibilityColumns.length === 0 ? (u(), G(f, {
1787
+ key: 0,
1788
+ el: "span",
1789
+ class: "b-data-grid-config-settings__column-visibility-empty-search-message"
1790
+ }, {
1791
+ default: V(() => [
1792
+ ge(K(e.t("noColumnsMatch")), 1)
1793
+ ]),
1794
+ _: 1
1795
+ })) : B("", !0)
1796
+ ])
1797
+ ])
1798
+ ]),
1799
+ _: 1
1800
+ }, 8, ["id", "open", "aria-label", "target-element"])) : B("", !0)
1801
+ ])), [
1802
+ [M, e.onClickOutside]
1803
+ ]);
1804
+ }
1805
+ const ws = /* @__PURE__ */ ae(is, [["render", Cs], ["__scopeId", "data-v-f5950a53"]]), st = {
1806
+ "en-US": {
1807
+ gettingYourData: "Getting your data",
1808
+ loading: "Loading",
1809
+ selectRow: "Select row",
1810
+ showMore: "Show more",
1811
+ sortAscending: "{field} sort ascending",
1812
+ sortDescending: "{field} sort descending",
1813
+ sortInactive: "{field} sort inactive"
1814
+ },
1815
+ "ja-JP": {
1816
+ loading: "読み込み中",
1817
+ showMore: "表示内容を増やす"
1818
+ },
1819
+ "pt-BR": {
1820
+ loading: "Carregando",
1821
+ showMore: "Mostrar mais"
1822
+ }
1823
+ }, _s = { class: "b-data-grid-lazy-load" }, bs = {
1824
+ i18n: { messages: st }
1825
+ }, ys = /* @__PURE__ */ Ie({
1826
+ ...bs,
1827
+ __name: "data-grid-lazy-load",
1828
+ props: {
1829
+ loading: { type: Boolean },
1830
+ isInfiniteScroll: { type: Boolean }
1831
+ },
1832
+ setup(e) {
1833
+ const { t: i } = Ue({ messages: st });
1834
+ return (a, t) => (u(), L("div", _s, [
1835
+ a.loading && a.isInfiniteScroll ? (u(), G(o(Ct), { key: 0 })) : B("", !0),
1836
+ a.loading && !a.isInfiniteScroll ? (u(), G(o(Ft), {
1837
+ key: 1,
1838
+ variant: "secondary",
1839
+ state: o(Ut).LOADING
1840
+ }, {
1841
+ default: V(() => [
1842
+ ge(K(o(i)("loading")), 1)
1843
+ ]),
1844
+ _: 1
1845
+ }, 8, ["state"])) : B("", !0),
1846
+ !a.loading && !a.isInfiniteScroll ? (u(), G(o(Ft), {
1847
+ key: 2,
1848
+ state: o(Ut).START,
1849
+ variant: "secondary",
1850
+ onClick: t[0] || (t[0] = (c) => a.$emit(o(z).UPDATE_SHOW_MORE))
1851
+ }, {
1852
+ default: V(() => [
1853
+ ge(K(o(i)("showMore")), 1)
1854
+ ]),
1855
+ _: 1
1856
+ }, 8, ["state"])) : B("", !0)
1857
+ ]));
1858
+ }
1859
+ }), Es = /* @__PURE__ */ ae(ys, [["__scopeId", "data-v-a4824c2d"]]);
1860
+ let Jt = 0;
1861
+ const Ss = {
1862
+ beforeCreate() {
1863
+ this.uuid = Jt.toString(), Jt += 1;
1864
+ }
1865
+ }, ps = { key: 0 };
1866
+ function Ls(e, i, a, t, c, n) {
1867
+ return u(), L("svg", ne({ role: "img" }, e.$attrs, {
1868
+ class: "ui-assets-icons-16",
1869
+ xmlns: "http://www.w3.org/2000/svg",
1870
+ width: "16",
1871
+ height: "16",
1872
+ fill: "none"
1873
+ }), [
1874
+ e.$attrs["svg-title"] ? (u(), L("title", ps, K(e.$attrs["svg-title"]), 1)) : B("", !0),
1875
+ i[0] || (i[0] = O("path", {
1876
+ fill: "#001222",
1877
+ d: "M12.9243 1.86372C12.0456 0.985043 10.621 0.985041 9.74234 1.86372L1.25 10.3561V14.7501H5.64399L14.1363 6.25772C15.015 5.37904 15.015 3.95442 14.1363 3.07574L12.9243 1.86372ZM10.803 2.92438C11.0959 2.63149 11.5708 2.63149 11.8637 2.92438L13.0757 4.1364C13.3686 4.42929 13.3686 4.90416 13.0757 5.19706L12.3333 5.93947L10.0606 3.6668L10.803 2.92438ZM8.99993 4.72746L11.2726 7.00013L5.02267 13.2501H2.75V10.9774L8.99993 4.72746Z"
1878
+ }, null, -1))
1879
+ ], 16);
1880
+ }
1881
+ const Rs = /* @__PURE__ */ ae(Ss, [["render", Ls]]), vn = {
1882
+ "en-US": {
1883
+ copy: "Copy",
1884
+ edit: "Edit",
1885
+ more: "More",
1886
+ open: "Open"
1887
+ },
1888
+ "ja-JP": {
1889
+ copy: "コピー",
1890
+ edit: "編集",
1891
+ more: "表示を増やす",
1892
+ open: "を開く"
1893
+ },
1894
+ "pt-BR": {
1895
+ copy: "Copiar",
1896
+ edit: "Editar",
1897
+ more: "Mais",
1898
+ open: "Abrir"
1899
+ }
1900
+ }, As = { class: "b-data-grid-cell-actions" }, Os = {
1901
+ i18n: { messages: vn },
1902
+ name: "data-grid-cell-actions"
1903
+ }, Ts = /* @__PURE__ */ Ie({
1904
+ ...Os,
1905
+ props: {
1906
+ /**
1907
+ * Column definitions using 'key' to relate to data object.
1908
+ */
1909
+ cellActions: {
1910
+ type: [Array, Function],
1911
+ required: !0,
1912
+ validator: (e) => (e == null ? void 0 : e.length) <= 2
1913
+ },
1914
+ /**
1915
+ * The column field key.
1916
+ */
1917
+ columnKey: {
1918
+ type: String,
1919
+ default: void 0
1920
+ },
1921
+ /**
1922
+ * Disables any opening of the cell actions menus using the down arrow key.
1923
+ */
1924
+ disableArrowDownOpeningMenu: {
1925
+ type: Boolean,
1926
+ default: !1
1927
+ },
1928
+ /**
1929
+ * Set to true if the datagrid has been scrolled and the right side has overflowing space.
1930
+ */
1931
+ hasRightOverflow: {
1932
+ type: Boolean,
1933
+ default: !1
1934
+ },
1935
+ /**
1936
+ * Set if set to true will teleport the action menu component
1937
+ */
1938
+ teleportMenu: {
1939
+ type: Boolean,
1940
+ default: !1
1941
+ },
1942
+ /**
1943
+ * The row data item object.
1944
+ */
1945
+ rowDataItem: {
1946
+ type: Object,
1947
+ required: !0
1948
+ }
1949
+ },
1950
+ emits: ["menu-open", "menu-close", "menu-item-click"],
1951
+ setup(e, { emit: i }) {
1952
+ const { t: a } = Ue({ messages: vn }), t = e, c = i, n = b(() => t.columnKey === void 0), l = b(() => ({
1953
+ "b-data-grid-cell-actions__background-gradient--with-row-actions-and-overflow": n.value && t.hasRightOverflow
1954
+ })), g = b(() => ({
1955
+ "b-data-grid-cell-actions__actions--with-row-actions": n.value
1956
+ })), f = b(() => !n.value || n.value && t.hasRightOverflow);
1957
+ function C(m) {
1958
+ return typeof m == "function";
1959
+ }
1960
+ const R = b(() => {
1961
+ var w;
1962
+ const m = C(t.cellActions) ? (w = t.cellActions) == null ? void 0 : w.call(t, t.rowDataItem, t.columnKey) : t.cellActions;
1963
+ return (m == null ? void 0 : m.length) > 2 && sn(
1964
+ "WARNING: BentoDataGrid Cell actions can only have a maximum of 2 actions, if you need more consider using the menuData property instead."
1965
+ ), m == null ? void 0 : m.slice(0, 2);
1966
+ }), v = b(() => (m, w) => {
1967
+ if (!(!w && m.isShort || w && !m.isShort))
1968
+ switch (m.variant) {
1969
+ case "copy":
1970
+ return a("copy");
1971
+ case "edit":
1972
+ return a("edit");
1973
+ case "open":
1974
+ return a("open");
1975
+ case "more":
1976
+ return a("more");
1977
+ default:
1978
+ return m.title;
1979
+ }
1980
+ }), F = (m) => (m == null ? void 0 : m.event) !== void 0 ? {
1981
+ click: (w) => {
1982
+ w.stopPropagation(), m.event(t.rowDataItem, t.columnKey);
1983
+ }
1984
+ } : {}, _ = (m) => ({
1985
+ ...m,
1986
+ handler: () => {
1987
+ m != null && m.handler && typeof m.handler == "function" && (m == null || m.handler()), m != null && m.event && typeof m.event == "function" && (m == null || m.event(t.rowDataItem, t.columnKey));
1988
+ }
1989
+ }), y = (m) => m.map((w) => {
1990
+ const s = w;
1991
+ return s != null && s.items && (s.items = y(s.items)), { ..._(s) };
1992
+ }), T = (m) => {
1993
+ var w, s;
1994
+ return (m == null ? void 0 : m.getCopyData) !== void 0 ? m.getCopyData(t.rowDataItem, t.columnKey) : t.columnKey ? (s = (w = t.rowDataItem) == null ? void 0 : w[t.columnKey]) == null ? void 0 : s.toString() : "";
1995
+ }, M = (m) => m.iconLeft || (m == null ? void 0 : m.variant) === "more";
1996
+ return (m, w) => (u(), G(nn, {
1997
+ name: "b-data-grid-cell-actions__animation",
1998
+ appear: ""
1999
+ }, {
2000
+ default: V(() => [
2001
+ O("div", As, [
2002
+ f.value ? (u(), L("div", {
2003
+ key: 0,
2004
+ class: de(["b-data-grid-cell-actions__background-gradient", l.value])
2005
+ }, null, 2)) : B("", !0),
2006
+ O("div", {
2007
+ class: de(["b-data-grid-cell-actions__actions", g.value]),
2008
+ role: "group"
2009
+ }, [
2010
+ (u(!0), L(ve, null, ye(R.value, (s, E) => (u(), L("div", {
2011
+ key: E,
2012
+ class: "b-data-grid-cell-actions__action"
2013
+ }, [
2014
+ s.menuData ? (u(), G(o(ct), {
2015
+ key: 0,
2016
+ data: y(s.menuData),
2017
+ button: {
2018
+ condensed: !0,
2019
+ variant: "secondary",
2020
+ disabled: s.disabled
2021
+ },
2022
+ "disable-arrow-down-opening-menu": e.disableArrowDownOpeningMenu,
2023
+ teleport: e.teleportMenu,
2024
+ onOpen: w[0] || (w[0] = (I) => c("menu-open")),
2025
+ onClose: w[1] || (w[1] = (I) => c("menu-close")),
2026
+ onMenuItemClick: w[2] || (w[2] = (I) => c("menu-item-click"))
2027
+ }, He({ _: 2 }, [
2028
+ M(s) ? {
2029
+ name: "iconLeft",
2030
+ fn: V(() => [
2031
+ (s == null ? void 0 : s.variant) === "more" ? (u(), G(o(Nl), {
2032
+ key: 0,
2033
+ "svg-title": v.value(s, !0)
2034
+ }, null, 8, ["svg-title"])) : (u(), G(Ze(s.iconLeft), {
2035
+ key: 1,
2036
+ "svg-title": v.value(s, !0)
2037
+ }, null, 8, ["svg-title"]))
2038
+ ]),
2039
+ key: "0"
2040
+ } : void 0,
2041
+ s != null && s.isShort ? void 0 : {
2042
+ name: "default",
2043
+ fn: V(() => [
2044
+ ge(K(v.value(s)), 1)
2045
+ ]),
2046
+ key: "1"
2047
+ }
2048
+ ]), 1032, ["data", "button", "disable-arrow-down-opening-menu", "teleport"])) : s.variant === "copy" ? (u(), G(o(Ul), {
2049
+ key: 1,
2050
+ text: T(s),
2051
+ "button-text": v.value(s),
2052
+ button: {
2053
+ condensed: !0,
2054
+ variant: "secondary"
2055
+ }
2056
+ }, null, 8, ["text", "button-text"])) : (u(), G(o(an), ne({
2057
+ key: 2,
2058
+ condensed: "",
2059
+ variant: "secondary",
2060
+ critical: s.critical,
2061
+ disabled: s.disabled,
2062
+ link: s.link
2063
+ }, ot(F(s))), He({ _: 2 }, [
2064
+ s.iconLeft || s.variant === "edit" ? {
2065
+ name: "iconLeft",
2066
+ fn: V(() => [
2067
+ (s == null ? void 0 : s.variant) === "edit" ? (u(), G(o(Rs), {
2068
+ key: 0,
2069
+ "svg-title": v.value(s, !0)
2070
+ }, null, 8, ["svg-title"])) : (u(), G(Ze(s.iconLeft), {
2071
+ key: 1,
2072
+ "svg-title": s.title
2073
+ }, null, 8, ["svg-title"]))
2074
+ ]),
2075
+ key: "0"
2076
+ } : void 0,
2077
+ s != null && s.isShort ? void 0 : {
2078
+ name: "default",
2079
+ fn: V(() => [
2080
+ ge(K(v.value(s)), 1)
2081
+ ]),
2082
+ key: "1"
2083
+ },
2084
+ s.iconRight || s.variant === "open" ? {
2085
+ name: "iconRight",
2086
+ fn: V(() => [
2087
+ (s == null ? void 0 : s.variant) === "open" ? (u(), G(o(Fl), {
2088
+ key: 0,
2089
+ "svg-title": v.value(s, !0)
2090
+ }, null, 8, ["svg-title"])) : (u(), G(Ze(s.iconRight), {
2091
+ key: 1,
2092
+ "svg-title": s.title
2093
+ }, null, 8, ["svg-title"]))
2094
+ ]),
2095
+ key: "2"
2096
+ } : void 0
2097
+ ]), 1040, ["critical", "disabled", "link"]))
2098
+ ]))), 128))
2099
+ ], 2)
2100
+ ])
2101
+ ]),
2102
+ _: 1
2103
+ }));
2104
+ }
2105
+ }), mn = /* @__PURE__ */ ae(Ts, [["__scopeId", "data-v-9c1c2f7b"]]), hn = Symbol("data-grid slashed zero key");
2106
+ var re = /* @__PURE__ */ ((e) => (e.ACTION_COL_NESTED_CONTENT_AND_SELECTION_ENABLED = "action-col-nested-content-and-selection-enabled", e.ACTION_COL_NESTED_CONTENT_ENABLED = "action-col-nested-content-enabled", e.ACTION_COL_SELECTION_ENABLED = "action-col-selection-enabled", e.COLUMN_HOVERED = "column-hovered", e.COLUMN_HOVERED_NO_BORDER_LEFT = "column-hovered-no-border-left", e.COLUMN_HOVERED_NO_BORDER_RIGHT = "column-hovered-no-border-right", e.CONDENSED = "condensed", e.FROZEN = "frozen", e.IS_COLUMN_REORDERING = "is-column-re-ordering", e.IS_COLUMN_REORDERING_TARGET_LEFT = "is-column-re-order-target-left", e.IS_COLUMN_REORDERING_TARGET_RIGHT = "is-column-re-order-target-right", e.LAST_FROZEN_COLUMN_CELL = "last-frozen-column-cell", e.NESTED_CONTENT_ENABLED = "nested-content-toggle-enabled", e.NUMERIC = "numeric", e.OVERFLOW_ELLIPSIS = "overflow-ellipsis", e.PADDING_LEFT_UNSET = "padding-left-unset", e.PADDING_RIGHT_UNSET = "padding-right-unset", e.SLASHED_ZERO = "slashed-zero", e))(re || {});
2107
+ const Qt = () => {
2108
+ const e = document.activeElement;
2109
+ return e ? e.matches(":focus-visible") || e.matches(".focus-visible") : !1;
2110
+ }, Cn = {
2111
+ "en-US": {
2112
+ collapseNestedContent: "Collapse nested content",
2113
+ expandNestedContent: "Expand nested content",
2114
+ selectRow: "Select row"
2115
+ }
2116
+ }, Ns = ["aria-hidden", "data-testid", "data-cellindex", "tabindex", "aria-colindex"], Is = ["title"], $s = {
2117
+ key: 0,
2118
+ class: "b-data-grid-cell__cell-actions"
2119
+ }, Ds = {
2120
+ i18n: { messages: Cn },
2121
+ name: "data-grid-cell"
2122
+ }, ks = /* @__PURE__ */ Ie({
2123
+ ...Ds,
2124
+ props: {
2125
+ draggingEventsForRowCell: {
2126
+ type: Function,
2127
+ required: !0
2128
+ },
2129
+ /**
2130
+ * The columns sets including
2131
+ */
2132
+ columnSets: {
2133
+ type: Array,
2134
+ required: !0
2135
+ },
2136
+ /**
2137
+ * The columns set we are iterating over
2138
+ */
2139
+ column: {
2140
+ type: Object,
2141
+ required: !0
2142
+ },
2143
+ colIndex: {
2144
+ type: Number,
2145
+ required: !0
2146
+ },
2147
+ columnSetIndex: {
2148
+ type: Number,
2149
+ required: !0
2150
+ },
2151
+ /**
2152
+ * Sets the row cells to the condensed padding state.
2153
+ */
2154
+ condensed: {
2155
+ type: Boolean,
2156
+ default: !1
2157
+ },
2158
+ /**
2159
+ * Columns being dragged, contains dragging column and a target column
2160
+ */
2161
+ draggingColumns: {
2162
+ type: Object,
2163
+ default: void 0
2164
+ },
2165
+ /**
2166
+ * A customisable method to retrieve a unique identifier for a data item in the array of data supplied.
2167
+ * This is used selecting and performance reasons and must exist in each data item.
2168
+ */
2169
+ getDataItemId: {
2170
+ type: Function,
2171
+ default: (e) => e.id
2172
+ },
2173
+ /**
2174
+ * The column hovered over state and whether the hovered over column should show a border right or left.
2175
+ */
2176
+ hoveredOverColumnState: {
2177
+ type: Object,
2178
+ required: !0
2179
+ },
2180
+ /**
2181
+ * A customisable method to determine if a row is not selectable.
2182
+ * The default is that every row is selectable.
2183
+ */
2184
+ isDataItemDisabled: {
2185
+ type: Function,
2186
+ default: () => !1
2187
+ },
2188
+ isMeasuringColumnWidths: {
2189
+ type: Boolean,
2190
+ default: !1
2191
+ },
2192
+ /**
2193
+ * Determines if the nested content is visible.
2194
+ */
2195
+ isNestedContentExpanded: {
2196
+ type: Boolean,
2197
+ default: !1
2198
+ },
2199
+ /**
2200
+ * Determines if the nest content slot is enabled for this data row.
2201
+ */
2202
+ nestedContent: {
2203
+ type: Boolean,
2204
+ default: !1
2205
+ },
2206
+ /**
2207
+ * The IDs of the rows this cell controls to show / hide them.
2208
+ */
2209
+ nestedRowsElementIds: {
2210
+ type: Array,
2211
+ default: () => []
2212
+ },
2213
+ /**
2214
+ * The row data object
2215
+ */
2216
+ rowData: {
2217
+ type: Object,
2218
+ required: !0
2219
+ },
2220
+ rowIndex: {
2221
+ type: Number,
2222
+ required: !0
2223
+ },
2224
+ /**
2225
+ * The row selection checkbox indeterminate state.
2226
+ */
2227
+ selectionIsIndeterminate: {
2228
+ type: Boolean,
2229
+ default: !1
2230
+ },
2231
+ /**
2232
+ * Determines if the row selection is enabled.
2233
+ */
2234
+ selectable: {
2235
+ type: Boolean,
2236
+ default: !1
2237
+ },
2238
+ selectedItems: {
2239
+ type: Array,
2240
+ required: !0
2241
+ }
2242
+ },
2243
+ emits: ["on-frozen-columns-key-press", "select-row", "register-row-cell-element", "cell-hovered", "nested-content-toggled"],
2244
+ setup(e, { expose: i, emit: a }) {
2245
+ const t = ht(), c = wt(t), { t: n } = Ue({ messages: Cn }), l = e, g = a, f = A(null), C = A(null), R = A(!1), v = A([]), F = A(!1), _ = A(), y = A(!1), T = b(() => {
2246
+ var h;
2247
+ return !!((h = l.rowData) != null && h[l.column.field]);
2248
+ }), M = b(
2249
+ () => {
2250
+ var h;
2251
+ return l.column.field === be && ((h = l.nestedRowsElementIds) == null ? void 0 : h.length) > 0 ? l.nestedRowsElementIds.join(" ") : void 0;
2252
+ }
2253
+ ), m = b(
2254
+ () => l.column.field === be && !l.selectable && !l.nestedContent
2255
+ ), w = b(() => r(l.rowIndex, l.colIndex, l.columnSetIndex) === 0 && !y.value ? "0" : l.column.field === be ? "-1" : F.value ? "0" : "-1"), s = (h, j) => (h == null ? void 0 : h.overflow) === ft.ELLIPSIS ? `${j}` : void 0, E = (h) => h ?? "-", I = (h) => l.columnSets.slice(0, h).reduce((j, { columnSet: Z }) => j + Z.length, 0), D = (h, j) => h + I(j), r = (h, j, Z) => I() * h + D(j, Z), p = (h) => {
2256
+ var j;
2257
+ (h === null || !f.value.contains(h) && !((j = v.value) != null && j.map((Z) => Z.value).some((Z) => Z === h || (Z == null ? void 0 : Z.contains(h))))) && (R.value = !1);
2258
+ }, U = () => {
2259
+ R.value = !1;
2260
+ }, J = A(!1), ue = (h) => {
2261
+ const j = {
2262
+ ...l.draggingEventsForRowCell(h),
2263
+ // Focus on the first interactive child in the grid cell if one exists
2264
+ focus: async () => {
2265
+ if (!Qt())
2266
+ return;
2267
+ F.value = !0, y.value = !0, cn(_.value), await he(), yt(f.value) && (J.value = !0);
2268
+ },
2269
+ focusout: () => {
2270
+ Qt() && (J.value = !1);
2271
+ },
2272
+ keydown: (x) => {
2273
+ x.key !== Ae.TAB && (J.value = !1, F.value = !1, We(f.value));
2274
+ }
2275
+ }, Z = { ...j };
2276
+ return h.frozen && (Z.keyup = (x) => g("on-frozen-columns-key-press", x), Z.keydown = (x) => {
2277
+ j.keydown(x), g("on-frozen-columns-key-press", x);
2278
+ }), h.cellActions && (Z.mouseenter = () => {
2279
+ R.value = !0;
2280
+ }, Z.mouseleave = (x) => {
2281
+ R.value = !1, p(x == null ? void 0 : x.relatedTarget);
2282
+ }, Z.mouseleave = (x) => {
2283
+ p(x == null ? void 0 : x.relatedTarget);
2284
+ }, Z.focus = async (x) => {
2285
+ j.focus(x), await he(), R.value = !0;
2286
+ }, Z.focusout = (x) => {
2287
+ j.focusout(x), p(x == null ? void 0 : x.relatedTarget);
2288
+ }), Z;
2289
+ };
2290
+ qe(() => {
2291
+ _.value = We(f.value);
2292
+ });
2293
+ const le = () => {
2294
+ g("nested-content-toggled");
2295
+ };
2296
+ Ee(
2297
+ () => R.value,
2298
+ () => {
2299
+ R.value === !0 ? g("cell-hovered", l.rowIndex) : g("cell-hovered", -1);
2300
+ }
2301
+ ), ln(Il, {
2302
+ registerMenuContainerElement: (h) => {
2303
+ v.value.push(h);
2304
+ },
2305
+ menuMouseLeave: (h) => {
2306
+ f.value.contains(h == null ? void 0 : h.relatedTarget) || (R.value = !1);
2307
+ }
2308
+ });
2309
+ const ce = dt(hn, A(!1)), me = (h) => {
2310
+ var j, Z, x, d, W, N, oe;
2311
+ return {
2312
+ [`b-data-grid-cell--${re.COLUMN_HOVERED}`]: (h == null ? void 0 : h.field) === l.hoveredOverColumnState.hoveredOverColumnField,
2313
+ [`b-data-grid-cell--${re.COLUMN_HOVERED_NO_BORDER_LEFT}`]: (h == null ? void 0 : h.field) === l.hoveredOverColumnState.hoveredOverColumnField && l.hoveredOverColumnState.noBorderLeft,
2314
+ [`b-data-grid-cell--${re.COLUMN_HOVERED_NO_BORDER_RIGHT}`]: (h == null ? void 0 : h.field) === l.hoveredOverColumnState.hoveredOverColumnField && l.hoveredOverColumnState.noBorderRight,
2315
+ [`b-data-grid-cell--${re.PADDING_LEFT_UNSET}`]: ((j = h == null ? void 0 : h.padding) == null ? void 0 : j.left) === !1,
2316
+ [`b-data-grid-cell--${re.PADDING_RIGHT_UNSET}`]: ((Z = h == null ? void 0 : h.padding) == null ? void 0 : Z.right) === !1,
2317
+ [`b-data-grid-cell--${re.NUMERIC}`]: h == null ? void 0 : h.numeric,
2318
+ [`b-data-grid-cell--${re.CONDENSED}`]: l.condensed,
2319
+ [`b-data-grid-cell--${re.OVERFLOW_ELLIPSIS}`]: (h == null ? void 0 : h.overflow) === ft.ELLIPSIS,
2320
+ [`b-data-grid-cell--${re.IS_COLUMN_REORDERING}`]: ((x = l.draggingColumns.dragging) == null ? void 0 : x.field) === h.field,
2321
+ [`b-data-grid-cell--${re.IS_COLUMN_REORDERING_TARGET_LEFT}`]: ((d = l.draggingColumns.target) == null ? void 0 : d.field) === h.field && ((W = l.draggingColumns) == null ? void 0 : W.dragToLeft),
2322
+ [`b-data-grid-cell--${re.IS_COLUMN_REORDERING_TARGET_RIGHT}`]: ((N = l.draggingColumns.target) == null ? void 0 : N.field) === h.field && !((oe = l.draggingColumns) != null && oe.dragToLeft),
2323
+ [`b-data-grid-cell--${re.FROZEN}`]: h == null ? void 0 : h.frozen,
2324
+ [`b-data-grid-cell--${re.NESTED_CONTENT_ENABLED}`]: l.nestedContent,
2325
+ [`b-data-grid-cell--${re.ACTION_COL_NESTED_CONTENT_ENABLED}`]: l.nestedContent && !l.selectable && h.field === be,
2326
+ [`b-data-grid-cell--${re.ACTION_COL_NESTED_CONTENT_AND_SELECTION_ENABLED}`]: l.nestedContent && l.selectable && h.field === be,
2327
+ [`b-data-grid-cell--${re.ACTION_COL_SELECTION_ENABLED}`]: h.field === be && l.selectable,
2328
+ [`b-data-grid-cell--${re.SLASHED_ZERO}`]: ce.value
2329
+ };
2330
+ }, Q = b(() => ({
2331
+ "b-data-grid-cell__cell-content--is-focused-on-inside-interactive-element": J.value
2332
+ }));
2333
+ return i({
2334
+ gridcellRef: f
2335
+ }), (h, j) => {
2336
+ var Z;
2337
+ return u(), L("div", ne({
2338
+ key: `cell-${e.column.field}`,
2339
+ ref_key: "gridcellRef",
2340
+ ref: f,
2341
+ "aria-hidden": m.value,
2342
+ "data-testid": `cell-${e.column.field}`,
2343
+ "data-cellindex": r(e.rowIndex, e.colIndex, e.columnSetIndex),
2344
+ class: ["b-data-grid-cell", me(e.column)],
2345
+ role: "gridcell",
2346
+ tabindex: w.value,
2347
+ "aria-colindex": D(e.colIndex, e.columnSetIndex) + 1,
2348
+ style: {
2349
+ width: e.column.autoWidth && e.isMeasuringColumnWidths ? "auto" : `${e.column.width}px`
2350
+ }
2351
+ }, ot(ue(e.column), !0)), [
2352
+ e.column.field === o(be) ? (u(), L(ve, { key: 0 }, [
2353
+ e.selectable ? (u(), G(o(nt), {
2354
+ key: 0,
2355
+ class: "b-data-grid-cell__select-cell",
2356
+ "aria-label": o(n)("selectRow"),
2357
+ disabled: e.isDataItemDisabled(e.rowData),
2358
+ indeterminate: e.selectionIsIndeterminate,
2359
+ "model-value": e.selectedItems,
2360
+ value: e.getDataItemId(e.rowData),
2361
+ tabindex: F.value ? 0 : -1,
2362
+ "onUpdate:modelValue": j[0] || (j[0] = (x) => h.$emit("select-row", x))
2363
+ }, null, 8, ["aria-label", "disabled", "indeterminate", "model-value", "value", "tabindex"])) : B("", !0),
2364
+ e.nestedContent ? (u(), G(o(bt), {
2365
+ key: 1,
2366
+ ref: "menuButtonRef",
2367
+ "aria-haspopup": "true",
2368
+ "aria-controls": M.value,
2369
+ condensed: "",
2370
+ variant: "tertiary",
2371
+ toggled: e.isNestedContentExpanded,
2372
+ onClick: le
2373
+ }, {
2374
+ iconLeft: V(() => [
2375
+ e.isNestedContentExpanded ? (u(), G(o(Pl), {
2376
+ key: 0,
2377
+ class: "b-accordion-item__icon",
2378
+ "svg-title": o(n)("collapseNestedContent")
2379
+ }, null, 8, ["svg-title"])) : (u(), G(o(zl), {
2380
+ key: 1,
2381
+ class: "b-accordion-item__icon",
2382
+ "svg-title": o(n)("expandNestedContent")
2383
+ }, null, 8, ["svg-title"]))
2384
+ ]),
2385
+ _: 1
2386
+ }, 8, ["aria-controls", "toggled"])) : B("", !0)
2387
+ ], 64)) : (u(), L(ve, { key: 1 }, [
2388
+ X(o(Ke), {
2389
+ el: "div",
2390
+ class: de(["b-data-grid-cell__cell-content", Q.value]),
2391
+ "data-testid": "cell-content"
2392
+ }, {
2393
+ default: V(() => [
2394
+ Ne(h.$slots, `item-${e.column.field}`, {
2395
+ item: e.rowData,
2396
+ rowIndex: e.rowIndex
2397
+ }, () => [
2398
+ O("span", {
2399
+ title: s(e.column, e.rowData[e.column.field])
2400
+ }, K(E(e.rowData[e.column.field])), 9, Is)
2401
+ ], !0)
2402
+ ]),
2403
+ _: 3
2404
+ }, 8, ["class"]),
2405
+ ((Z = e.column.cellActions) == null ? void 0 : Z.length) > 0 ? (u(), L("div", $s, [
2406
+ R.value && (T.value || o(c)(`item-${e.column.field}`)) ? (u(), G(mn, {
2407
+ key: 0,
2408
+ ref_key: "cellActionsRef",
2409
+ ref: C,
2410
+ "cell-actions": e.column.cellActions,
2411
+ "column-key": e.column.field,
2412
+ "row-data-item": e.rowData,
2413
+ "teleport-menu": "",
2414
+ onMenuItemClick: U
2415
+ }, null, 8, ["cell-actions", "column-key", "row-data-item"])) : B("", !0)
2416
+ ])) : B("", !0)
2417
+ ], 64))
2418
+ ], 16, Ns);
2419
+ };
2420
+ }
2421
+ }), Ms = /* @__PURE__ */ ae(ks, [["__scopeId", "data-v-305d8373"]]), Fs = { class: "b-data-grid-row-container" }, Us = ["id", "aria-selected"], zs = ["data-testid"], Ps = ["aria-colindex", "data-cellindex"], Bs = {
2422
+ key: 0,
2423
+ class: "b-data-grid-row-container__row-nested-rows-loading-container"
2424
+ }, Ws = { key: 2 }, Gs = {
2425
+ name: "data-grid-row"
2426
+ }, Hs = /* @__PURE__ */ Ie({
2427
+ ...Gs,
2428
+ props: {
2429
+ /**
2430
+ * Row actions property that generates which button to show in row actions area
2431
+ */
2432
+ rowActions: {
2433
+ type: [Function, Array],
2434
+ default: void 0
2435
+ },
2436
+ /**
2437
+ * When true, will emit a 'rowClick' event when a row is clicked. Will add cursor: pointer to rows.
2438
+ */
2439
+ allowRowClicks: { type: Boolean, default: !1 },
2440
+ /**
2441
+ * The columns sets including
2442
+ */
2443
+ columnSets: {
2444
+ type: Array,
2445
+ required: !0
2446
+ },
2447
+ /**
2448
+ * Sets the row cells to the condensed padding state.
2449
+ */
2450
+ condensed: {
2451
+ type: Boolean,
2452
+ default: !1
2453
+ },
2454
+ /**
2455
+ * Columns being dragged, contains dragging column and a target column
2456
+ */
2457
+ draggingColumns: {
2458
+ type: Object,
2459
+ default: void 0
2460
+ },
2461
+ /**
2462
+ * Dragging event handlers for each row cell
2463
+ */
2464
+ draggingEventsForRowCell: {
2465
+ type: Function,
2466
+ required: !0
2467
+ },
2468
+ /**
2469
+ * A customisable method to retrieve a unique identifier for a data item in the array of data supplied.
2470
+ * This is used selecting and performance reasons and must exist in each data item.
2471
+ */
2472
+ getDataItemId: {
2473
+ type: Function,
2474
+ default: (e) => e.id
2475
+ },
2476
+ /**
2477
+ * Set to true if the datagrid has been scrolled and the left side has overflowing space.
2478
+ */
2479
+ hasLeftOverflow: {
2480
+ type: Boolean,
2481
+ default: !1
2482
+ },
2483
+ /**
2484
+ * Enables the nested content slot functionality.
2485
+ */
2486
+ hasNestedContent: {
2487
+ type: Boolean,
2488
+ default: !1
2489
+ },
2490
+ /**
2491
+ * Enables the nested content slot functionality.
2492
+ */
2493
+ hasNestedRows: {
2494
+ type: Boolean,
2495
+ default: !1
2496
+ },
2497
+ /**
2498
+ * Set to true if the datagrid has been scrolled and the right side has overflowing space.
2499
+ */
2500
+ hasRightOverflow: {
2501
+ type: Boolean,
2502
+ default: !1
2503
+ },
2504
+ /**
2505
+ * Highlighted row IDs.
2506
+ */
2507
+ highlightedRows: {
2508
+ type: Array,
2509
+ default: () => []
2510
+ },
2511
+ /**
2512
+ * The row index of a currently hovered row.
2513
+ */
2514
+ hoveredRowIndex: {
2515
+ type: Number,
2516
+ default: -1
2517
+ },
2518
+ /**
2519
+ * The column hovered over state and whether the hovered over column should show a border right or left.
2520
+ */
2521
+ hoveredOverColumnState: {
2522
+ type: Object,
2523
+ required: !0
2524
+ },
2525
+ /**
2526
+ * A customisable method to determine if a row is not selectable.
2527
+ * The default is that every row is selectable.
2528
+ */
2529
+ isDataItemDisabled: {
2530
+ type: Function,
2531
+ default: () => !1
2532
+ },
2533
+ /**
2534
+ * If the row is the last child in it's parent container.
2535
+ */
2536
+ isRowLastChild: {
2537
+ type: Boolean,
2538
+ default: !1
2539
+ },
2540
+ /**
2541
+ * If columns are being measured for the autoWidth functionality.
2542
+ */
2543
+ isMeasuringColumnWidths: {
2544
+ type: Boolean,
2545
+ default: !1
2546
+ },
2547
+ /**
2548
+ * Determines if this row is nested inside another row.
2549
+ */
2550
+ isNestedRow: {
2551
+ type: Boolean,
2552
+ default: !1
2553
+ },
2554
+ /**
2555
+ * The maximum width of the row actions in all rows
2556
+ */
2557
+ rowActionsMaximumWidth: {
2558
+ type: Number,
2559
+ default: 0
2560
+ },
2561
+ /**
2562
+ * The row data object
2563
+ */
2564
+ rowData: {
2565
+ type: Object,
2566
+ required: !0
2567
+ },
2568
+ /**
2569
+ * The row index.
2570
+ */
2571
+ rowIndex: {
2572
+ type: Number,
2573
+ required: !0
2574
+ },
2575
+ /**
2576
+ * The row ID to be using for the ID attribute.
2577
+ */
2578
+ rowId: {
2579
+ type: Number,
2580
+ default: void 0
2581
+ },
2582
+ /**
2583
+ * The number of rows that this row is within.
2584
+ */
2585
+ rowSetSize: {
2586
+ type: Number,
2587
+ default: 0
2588
+ },
2589
+ /**
2590
+ * Determines whether to render frozen seperator on the row.
2591
+ */
2592
+ showFrozenColumnsSeparator: {
2593
+ type: Boolean,
2594
+ default: !1
2595
+ },
2596
+ /**
2597
+ * Determines if the row selection is enabled.
2598
+ */
2599
+ selectable: {
2600
+ type: Boolean,
2601
+ default: !1
2602
+ },
2603
+ /**
2604
+ * The array of IDs for the selected rows.
2605
+ */
2606
+ selectedItems: {
2607
+ type: Array,
2608
+ required: !0
2609
+ },
2610
+ /**
2611
+ * Enables / Disables the nested-content slot
2612
+ */
2613
+ shouldShowNestedContent: {
2614
+ type: Function,
2615
+ default: (e) => !0
2616
+ },
2617
+ /**
2618
+ * Returns the nested rows for a given BentoDatagridDataItem.
2619
+ */
2620
+ shouldShowNestedRows: {
2621
+ type: Function,
2622
+ default: (e) => !0
2623
+ }
2624
+ },
2625
+ emits: ["cell-hovered", "on-frozen-columns-key-press", "select-row", "select-nested-row", "row-click", "nested-content-toggled"],
2626
+ setup(e, { expose: i, emit: a }) {
2627
+ const t = ht(), c = wt(t), n = e, l = a, g = A({}), f = A(!1), C = A(), R = A(), v = ut("nested-content-slot"), F = A(!1), _ = A();
2628
+ qe(() => {
2629
+ R.value && (_.value = We(R.value));
2630
+ });
2631
+ const y = b(() => n.shouldShowNestedRows(n.rowData)), T = b(
2632
+ () => {
2633
+ var S, k;
2634
+ return !n.isNestedRow && n.hasNestedRows && y.value && ((k = (S = n.rowData) == null ? void 0 : S.children) == null ? void 0 : k.length) > 0;
2635
+ }
2636
+ ), M = b(
2637
+ () => {
2638
+ var S, k;
2639
+ return !n.isNestedRow && n.hasNestedRows && y.value && (((S = n.rowData) == null ? void 0 : S.children) === void 0 || ((k = n == null ? void 0 : n.rowData) == null ? void 0 : k.children.length) === 0);
2640
+ }
2641
+ ), m = b(
2642
+ () => n.hasNestedContent && n.shouldShowNestedContent(n.rowData) || n.hasNestedRows && y.value && !n.isNestedRow
2643
+ ), w = b(() => {
2644
+ if (n.hasNestedContent || n.hasNestedRows) {
2645
+ const S = f.value.toString();
2646
+ return {
2647
+ "aria-expanded": m.value ? S : void 0,
2648
+ "aria-level": n.isNestedRow ? "2" : "1",
2649
+ "aria-posinset": n.rowIndex + 1,
2650
+ "aria-setsize": n.rowSetSize
2651
+ };
2652
+ }
2653
+ return { "aria-rowindex": n.rowIndex + 1 };
2654
+ }), s = b(() => {
2655
+ if (M.value)
2656
+ return {
2657
+ "aria-busy": "true",
2658
+ "aria-live": "polite"
2659
+ };
2660
+ if (!(T.value || !n.hasNestedContent || !n.shouldShowNestedContent(n.rowData)))
2661
+ return {
2662
+ "aria-level": n.isNestedRow ? "3" : "2",
2663
+ "aria-posinset": "1",
2664
+ "aria-setsize": "1",
2665
+ id: v,
2666
+ role: "row",
2667
+ tabindex: "-1"
2668
+ };
2669
+ }), E = b(() => {
2670
+ var S, k;
2671
+ return T.value ? (k = (S = n.rowData) == null ? void 0 : S.children) == null ? void 0 : k.reduce((Y, H, se) => (Y[se] = ut("nested-row"), Y), {}) : [];
2672
+ }), I = b(() => {
2673
+ var S;
2674
+ if (f.value) {
2675
+ if (n.hasNestedContent && n.shouldShowNestedContent(n.rowData))
2676
+ return [v];
2677
+ if (T.value && ((S = Object.keys(E.value)) == null ? void 0 : S.length) > 0) {
2678
+ const k = Object.values(E.value);
2679
+ if ((k == null ? void 0 : k.length) > 0)
2680
+ return k;
2681
+ }
2682
+ return [];
2683
+ }
2684
+ }), D = b(() => {
2685
+ var k, Y;
2686
+ const S = (Y = (k = n.rowData) == null ? void 0 : k.children) == null ? void 0 : Y.map((H) => n.getDataItemId(H));
2687
+ if ((S == null ? void 0 : S.length) > 0) {
2688
+ const H = S.every((fe) => {
2689
+ var Se;
2690
+ return (Se = n == null ? void 0 : n.selectedItems) == null ? void 0 : Se.includes(fe);
2691
+ }), se = S.some((fe) => {
2692
+ var Se;
2693
+ return (Se = n == null ? void 0 : n.selectedItems) == null ? void 0 : Se.includes(fe);
2694
+ });
2695
+ return !H && se;
2696
+ }
2697
+ return !1;
2698
+ }), r = (S, k) => {
2699
+ const Y = S;
2700
+ S !== null && (Y != null && Y.gridcellRef) && (g.value[k] = Y.gridcellRef);
2701
+ }, p = (S) => E.value[S], U = (S) => {
2702
+ if (!n.selectable)
2703
+ return null;
2704
+ const k = n.getDataItemId(S);
2705
+ return n.selectedItems.includes(k).toString();
2706
+ }, J = (S) => {
2707
+ var H;
2708
+ if (!n.allowRowClicks)
2709
+ return;
2710
+ let k = !1;
2711
+ const Y = ["button", "input", "a"];
2712
+ for (let se = 0; se < Y.length; se++)
2713
+ if ((H = S == null ? void 0 : S.target) != null && H.closest(Y[se])) {
2714
+ k = !0;
2715
+ break;
2716
+ }
2717
+ k || l("row-click", n.rowData, S);
2718
+ }, ue = (S) => {
2719
+ l("select-row", S, n.rowData);
2720
+ }, le = (S, k) => {
2721
+ l("select-nested-row", k, n.rowData, S);
2722
+ }, Ce = () => {
2723
+ F.value = !0;
2724
+ }, we = () => {
2725
+ F.value = !1;
2726
+ }, ce = () => {
2727
+ var S;
2728
+ cn([(S = _.value) == null ? void 0 : S[0]]), yt(R.value);
2729
+ }, me = () => {
2730
+ We(R.value);
2731
+ }, Q = (S) => {
2732
+ var k, Y;
2733
+ S.key !== Ae.TAB && We(R.value), S.key === Ae.ARROW_RIGHT && ((k = _.value) == null ? void 0 : k.length) > 1 && _.value[0].node === document.activeElement ? (We(R.value), _.value[1].node.setAttribute("tabindex", "0"), _.value[1].node.focus(), S.stopPropagation(), S.preventDefault()) : S.key === Ae.ARROW_LEFT && ((Y = _.value) == null ? void 0 : Y.length) > 1 && _.value[1].node === document.activeElement && (We(R.value), _.value[0].node.setAttribute("tabindex", "0"), _.value[0].node.focus(), S.stopPropagation(), S.preventDefault());
2734
+ }, h = () => n.columnSets.reduce((S, { columnSet: k }) => S + k.length, 0), j = () => h() * n.rowIndex + h(), { updateContentHeight: Z, contentHeight: x } = Ml(C, f), d = b(() => {
2735
+ var S;
2736
+ if (n.hasNestedContent || n.hasNestedRows)
2737
+ return {
2738
+ paddingLeft: `${T.value || M.value ? 0 : g.value[be].clientWidth + un}px`,
2739
+ "max-height": (n.hasNestedContent || n.hasNestedRows) && x.value && !((S = x == null ? void 0 : x.value) != null && S.includes("null")) ? x.value : 0
2740
+ };
2741
+ });
2742
+ Ee(
2743
+ () => C.value,
2744
+ () => {
2745
+ let S = null;
2746
+ !S && C.value && (S = _t(C.value, () => {
2747
+ C.value && Z();
2748
+ }));
2749
+ }
2750
+ );
2751
+ const W = () => {
2752
+ f.value = !f.value, Z(), l("nested-content-toggled", n.rowData);
2753
+ };
2754
+ Ee(
2755
+ () => {
2756
+ var S;
2757
+ return (S = n.rowData) == null ? void 0 : S.children;
2758
+ },
2759
+ (S, k) => {
2760
+ var Y, H;
2761
+ ((H = (Y = n == null ? void 0 : n.rowData) == null ? void 0 : Y.children) == null ? void 0 : H.length) > 0 && k === void 0 && !f.value && Z();
2762
+ }
2763
+ );
2764
+ const N = (S, k) => ({
2765
+ "b-data-grid-row-container__row--disabled": n.isDataItemDisabled(S),
2766
+ "b-data-grid-row-container__row--row-clicks-enabled": n.allowRowClicks,
2767
+ "b-data-grid-row-container__row--highlighted": n.highlightedRows.includes(n.getDataItemId(S)) || n.selectedItems.includes(n.getDataItemId(S)),
2768
+ "b-data-grid-row-container__row--hovered": n.hoveredRowIndex === k,
2769
+ "b-data-grid-row-container__row--is-last-child": n.isRowLastChild && !f.value,
2770
+ "b-data-grid-row-container__row--nested-row": n.isNestedRow
2771
+ }), oe = (S) => ({
2772
+ "b-data-grid-row-container__row-cell-set--frozen": S,
2773
+ [`b-data-grid-row-container__row-cell-set--${De.OVERFLOW_SHADOW_LEFT}`]: S && n.hasLeftOverflow,
2774
+ "b-data-grid-row-container__row-cell-set--frozen-separator": S && n.showFrozenColumnsSeparator,
2775
+ "b-data-grid-row-container__row-cell-set--unfrozen": !S,
2776
+ "b-data-grid-row-container__row-cell-set--is-measuring": n.isMeasuringColumnWidths
2777
+ }), ee = b(() => ({
2778
+ "b-data-grid-row-container__row-nested-slot--is-last-child": n.isRowLastChild,
2779
+ "b-data-grid-row-container__row-nested-slot": !T.value && n.shouldShowNestedContent(n.rowData)
2780
+ })), Ge = b(() => ({
2781
+ "b-data-grid-row-container__row-actions-container--row-actions-menu-open": F.value
2782
+ })), ze = b(() => ({
2783
+ minWidth: `${n.rowActionsMaximumWidth}px`
2784
+ }));
2785
+ return i({
2786
+ gridcellRefs: g,
2787
+ rowActionsRef: R
2788
+ }), (S, k) => {
2789
+ var Y;
2790
+ return u(), L("div", Fs, [
2791
+ (u(), L("div", ne(w.value, {
2792
+ id: (Y = e.rowId) == null ? void 0 : Y.toString(),
2793
+ key: e.rowIndex,
2794
+ class: ["b-data-grid-row-container__row", N(e.rowData, e.rowIndex)],
2795
+ role: "row",
2796
+ "aria-selected": U(e.rowData),
2797
+ onClick: J,
2798
+ onKeyup: [
2799
+ $t(J, ["enter"]),
2800
+ $t(J, ["space"])
2801
+ ]
2802
+ }), [
2803
+ (u(!0), L(ve, null, ye(e.columnSets, ({ columnSet: H, id: se, isFrozenColumns: fe }, Se) => (u(), L(ve, null, [
2804
+ H != null && H.length ? (u(), L("div", {
2805
+ key: `data-grid-rows-${se}`,
2806
+ class: de(["b-data-grid-row-container__cells", oe(fe)]),
2807
+ "data-testid": `data-grid-${se}-rows`
2808
+ }, [
2809
+ (u(!0), L(ve, null, ye(H, (Pe, Ye) => (u(), G(o(Ms), {
2810
+ key: `cell-${Pe.field}`,
2811
+ ref_for: !0,
2812
+ ref: (Oe) => r(Oe, Pe.field),
2813
+ class: "b-data-grid-row-container__cell",
2814
+ column: Pe,
2815
+ "column-set-index": Se,
2816
+ "col-index": Ye,
2817
+ "column-sets": e.columnSets,
2818
+ condensed: e.condensed,
2819
+ "dragging-columns": e.draggingColumns,
2820
+ "dragging-events-for-row-cell": e.draggingEventsForRowCell,
2821
+ "get-data-item-id": e.getDataItemId,
2822
+ "hovered-over-column-state": e.hoveredOverColumnState,
2823
+ "is-data-item-disabled": e.isDataItemDisabled,
2824
+ "is-measuring-column-widths": e.isMeasuringColumnWidths,
2825
+ "is-nested-content-expanded": f.value,
2826
+ "nested-content": m.value,
2827
+ "nested-rows-element-ids": I.value,
2828
+ "row-data": e.rowData,
2829
+ "row-index": e.rowIndex,
2830
+ "selection-is-indeterminate": D.value,
2831
+ selectable: e.selectable,
2832
+ "selected-items": e.selectedItems,
2833
+ onCellHovered: k[0] || (k[0] = (Oe) => l("cell-hovered", Oe)),
2834
+ onOnFrozenColumnsKeyPress: k[1] || (k[1] = (Oe) => l("on-frozen-columns-key-press", Oe)),
2835
+ onSelectRow: ue,
2836
+ onNestedContentToggled: W
2837
+ }, He({ _: 2 }, [
2838
+ ye(o(t), (Oe, Xe) => ({
2839
+ name: Xe,
2840
+ fn: V((it) => [
2841
+ Ne(S.$slots, Xe, ne({ ref_for: !0 }, it), void 0, !0)
2842
+ ])
2843
+ }))
2844
+ ]), 1032, ["column", "column-set-index", "col-index", "column-sets", "condensed", "dragging-columns", "dragging-events-for-row-cell", "get-data-item-id", "hovered-over-column-state", "is-data-item-disabled", "is-measuring-column-widths", "is-nested-content-expanded", "nested-content", "nested-rows-element-ids", "row-data", "row-index", "selection-is-indeterminate", "selectable", "selected-items"]))), 128))
2845
+ ], 10, zs)) : B("", !0),
2846
+ !fe && e.rowActions ? (u(), L("div", {
2847
+ key: `data-grid-row-actions-${se}`,
2848
+ ref_for: !0,
2849
+ ref_key: "rowActionsRef",
2850
+ ref: R,
2851
+ "aria-colindex": h().toString(),
2852
+ class: de(["b-data-grid-row-container__row-actions-container", Ge.value]),
2853
+ style: Me(ze.value),
2854
+ "data-cellindex": j(),
2855
+ tabindex: "-1",
2856
+ role: "gridcell",
2857
+ onFocus: ce,
2858
+ "on:focusOut": me,
2859
+ onKeydown: Q
2860
+ }, [
2861
+ X(o(mn), {
2862
+ class: "b-data-grid-row-container__row-actions",
2863
+ "disable-arrow-down-opening-menu": "",
2864
+ "cell-actions": e.rowActions,
2865
+ "has-right-overflow": e.hasRightOverflow,
2866
+ "row-data-item": e.rowData,
2867
+ "teleport-menu": "",
2868
+ onMenuOpen: Ce,
2869
+ onMenuClose: we
2870
+ }, null, 8, ["cell-actions", "has-right-overflow", "row-data-item"])
2871
+ ], 46, Ps)) : B("", !0)
2872
+ ], 64))), 256))
2873
+ ], 16, Us)),
2874
+ e.hasNestedContent && o(c)("nested-slot") && e.shouldShowNestedContent(e.rowData) || e.hasNestedRows && y.value ? (u(), G(nn, {
2875
+ key: `${e.rowIndex}-nest-content`,
2876
+ name: "b-data-grid-row-container__animation--nested-content"
2877
+ }, {
2878
+ default: V(() => [
2879
+ f.value ? (u(), L("div", ne({ key: 0 }, s.value, {
2880
+ class: ee.value,
2881
+ "data-testid": "nested-content-container",
2882
+ style: d.value
2883
+ }), [
2884
+ O("div", {
2885
+ ref_key: "nestedContentRef",
2886
+ ref: C
2887
+ }, [
2888
+ M.value ? (u(), L("div", Bs, [
2889
+ X(o(Ct))
2890
+ ])) : T.value ? (u(!0), L(ve, { key: 1 }, ye(e.rowData.children, (H, se) => (u(), G(wn, ne({ ref_for: !0 }, n, {
2891
+ id: p(se),
2892
+ key: `child-${se}`,
2893
+ "row-data": H,
2894
+ "row-index": se,
2895
+ "row-set-size": e.rowData.children.length,
2896
+ "is-nested-row": "",
2897
+ onCellHovered: k[2] || (k[2] = (fe) => l("cell-hovered", fe)),
2898
+ onRowClick: k[3] || (k[3] = (fe) => l("row-click", ...fe)),
2899
+ onOnFrozenColumnsKeyPress: k[4] || (k[4] = (fe) => l("on-frozen-columns-key-press", fe)),
2900
+ onSelectRow: (fe) => le(H, fe)
2901
+ }), He({ _: 2 }, [
2902
+ ye(o(t), (fe, Se) => ({
2903
+ name: Se,
2904
+ fn: V((Pe) => [
2905
+ Ne(S.$slots, Se, ne({ ref_for: !0 }, Pe), void 0, !0)
2906
+ ])
2907
+ }))
2908
+ ]), 1040, ["id", "row-data", "row-index", "row-set-size", "onSelectRow"]))), 128)) : o(c)("nested-slot") && e.shouldShowNestedContent(e.rowData) ? (u(), L("div", Ws, [
2909
+ Ne(S.$slots, "nested-slot", { item: e.rowData }, void 0, !0)
2910
+ ])) : B("", !0)
2911
+ ], 512)
2912
+ ], 16)) : B("", !0)
2913
+ ]),
2914
+ _: 3
2915
+ })) : B("", !0)
2916
+ ]);
2917
+ };
2918
+ }
2919
+ }), wn = /* @__PURE__ */ ae(Hs, [["__scopeId", "data-v-d6354e28"]]);
2920
+ let en = 0;
2921
+ const Vs = {
2922
+ beforeCreate() {
2923
+ this.uuid = en.toString(), en += 1;
2924
+ }
2925
+ }, xs = { key: 0 }, Zs = ["clip-path"], js = ["id"];
2926
+ function qs(e, i, a, t, c, n) {
2927
+ return u(), L("svg", ne({ role: "img" }, e.$attrs, {
2928
+ class: "ui-assets-icons-16",
2929
+ xmlns: "http://www.w3.org/2000/svg",
2930
+ width: "16",
2931
+ height: "16",
2932
+ fill: "none"
2933
+ }), [
2934
+ e.$attrs["svg-title"] ? (u(), L("title", xs, K(e.$attrs["svg-title"]), 1)) : B("", !0),
2935
+ O("g", {
2936
+ "clip-path": "url(#uia-ui-assets/icons-16-warning_circle_fill__a" + e.uuid + ")"
2937
+ }, i[0] || (i[0] = [
2938
+ O("path", {
2939
+ fill: "#001222",
2940
+ d: "M0.25 8C0.25 3.71979 3.71979 0.25 8 0.25C12.2802 0.25 15.75 3.71979 15.75 8C15.75 12.2802 12.2802 15.75 8 15.75C3.71979 15.75 0.25 12.2802 0.25 8ZM8.75 8.75V4.25H7.25V8.75H8.75ZM8 11.5C8.41421 11.5 8.75 11.1642 8.75 10.75C8.75 10.3358 8.41421 10 8 10C7.58579 10 7.25 10.3358 7.25 10.75C7.25 11.1642 7.58579 11.5 8 11.5Z"
2941
+ }, null, -1)
2942
+ ]), 8, Zs),
2943
+ O("defs", null, [
2944
+ O("clipPath", {
2945
+ id: "uia-ui-assets/icons-16-warning_circle_fill__a" + e.uuid
2946
+ }, i[1] || (i[1] = [
2947
+ O("rect", {
2948
+ width: "16",
2949
+ height: "16",
2950
+ fill: "#fff"
2951
+ }, null, -1)
2952
+ ]), 8, js)
2953
+ ])
2954
+ ], 16);
2955
+ }
2956
+ const Ks = /* @__PURE__ */ ae(Vs, [["render", qs]]), Ys = ["aria-label"], Xs = {}, Js = /* @__PURE__ */ Ie({
2957
+ ...Xs,
2958
+ __name: "data-grid-static-icon",
2959
+ props: {
2960
+ colored: { type: Boolean, default: !1 },
2961
+ tooltipText: {},
2962
+ variant: { default: "no-value" }
2963
+ },
2964
+ setup(e) {
2965
+ const i = e, a = b(() => {
2966
+ switch (i.variant) {
2967
+ case "checkmark":
2968
+ return ul;
2969
+ case "warning":
2970
+ return cl;
2971
+ case "error":
2972
+ return Ks;
2973
+ case "cross":
2974
+ return on;
2975
+ case "no-value":
2976
+ return Dt;
2977
+ default:
2978
+ return Dt;
2979
+ }
2980
+ }), t = b(() => ({
2981
+ "b-data-grid-static-icon--colored": i.colored && i.variant !== "no-value"
2982
+ })), c = b(() => `b-data-grid-static-icon__${i.variant}`), n = b(() => ml.AUTO);
2983
+ return (l, g) => mt((u(), L("div", {
2984
+ "aria-label": l.tooltipText,
2985
+ class: de(["b-data-grid-static-icon", t.value]),
2986
+ tabindex: "0"
2987
+ }, [
2988
+ (u(), G(Ze(a.value), {
2989
+ class: de(c.value),
2990
+ "svg-title": l.tooltipText
2991
+ }, null, 8, ["class", "svg-title"]))
2992
+ ], 10, Ys)), [
2993
+ [o(gl), l.tooltipText, n.value]
2994
+ ]);
2995
+ }
2996
+ }), ia = /* @__PURE__ */ ae(Js, [["__scopeId", "data-v-3ee55e9a"]]), _n = {
2997
+ "de-DE": {
2998
+ numberResults: "1 Ergebnis | {count} Ergebnisse"
2999
+ },
3000
+ "en-US": {
3001
+ numberResults: "1 result | {count} results"
3002
+ },
3003
+ "es-ES": {
3004
+ numberResults: "1 resultado | {count} resultados"
3005
+ },
3006
+ "fr-FR": {
3007
+ numberResults: "1 résultat | {count} résultats"
3008
+ },
3009
+ "ja-JP": {
3010
+ numberResults: "結果が見つかりませんでした | {count}件の結果"
3011
+ },
3012
+ "pt-BR": {
3013
+ numberResults: "1 resultado | {count} resultados"
3014
+ }
3015
+ }, Qs = { class: "b-data-grid-summary-cell" }, ei = { class: "b-data-grid-summary-cell__list" }, ti = {
3016
+ i18n: { messages: _n }
3017
+ }, ni = /* @__PURE__ */ Ie({
3018
+ ...ti,
3019
+ __name: "data-grid-summary-cell",
3020
+ props: {
3021
+ label: {},
3022
+ items: {},
3023
+ dashedUnderline: { default: () => ({}) },
3024
+ searchTerm: { default: "" },
3025
+ tooltipText: { default: null }
3026
+ },
3027
+ setup(e) {
3028
+ const { tc: i } = Ue({ messages: _n }), a = e, t = A(), c = b(() => {
3029
+ var C;
3030
+ return {
3031
+ popoverPosition: "right",
3032
+ // Default is right but can be overriden
3033
+ ...a.dashedUnderline,
3034
+ popoverTitle: ((C = a == null ? void 0 : a.dashedUnderline) == null ? void 0 : C.popoverTitle) ?? a.label,
3035
+ // We force teleport as this is needed for the popover to appear above all the data grid elements
3036
+ teleport: {
3037
+ disabled: !1
3038
+ }
3039
+ };
3040
+ }), n = b(() => {
3041
+ var C;
3042
+ return ((C = a.searchTerm) == null ? void 0 : C.toLowerCase()) ?? "";
3043
+ }), l = (C) => a.searchTerm && C.toLowerCase().includes(n.value) ? "mark" : "span", g = b(() => a.searchTerm ? a.items.filter((C) => C.toLowerCase().includes(n.value)).length : 0), f = b(
3044
+ () => a.tooltipText ?? (g.value > 0 ? i("numberResults", g.value) : "")
3045
+ );
3046
+ return (C, R) => (u(), L("div", Qs, [
3047
+ C.items.length > 1 ? (u(), G(o(hl), ne({
3048
+ key: 0,
3049
+ ref_key: "dashedUnderlineRef",
3050
+ ref: t
3051
+ }, c.value), {
3052
+ "popover-content": V(() => [
3053
+ X(o(Ke), { class: "b-data-grid-summary-cell__popover-content" }, {
3054
+ default: V(() => [
3055
+ O("ul", ei, [
3056
+ (u(!0), L(ve, null, ye(C.items, (v) => (u(), L("li", { key: v }, [
3057
+ (u(), G(Ze(l(v)), null, {
3058
+ default: V(() => [
3059
+ ge(K(v), 1)
3060
+ ]),
3061
+ _: 2
3062
+ }, 1024))
3063
+ ]))), 128))
3064
+ ])
3065
+ ]),
3066
+ _: 1
3067
+ })
3068
+ ]),
3069
+ default: V(() => [
3070
+ ge(K(C.label) + " ", 1)
3071
+ ]),
3072
+ _: 1
3073
+ }, 16)) : (u(), L(ve, { key: 1 }, [
3074
+ ge(K(C.items[0]), 1)
3075
+ ], 64)),
3076
+ t.value && f.value ? (u(), G(o(vl), {
3077
+ key: 2,
3078
+ content: f.value,
3079
+ "disabled-focus-trap": !0,
3080
+ position: o(fl).RIGHT,
3081
+ "fallback-position": ["left", "bottom"],
3082
+ "is-shown": !!f.value,
3083
+ "target-element": t.value
3084
+ }, null, 8, ["content", "position", "is-shown", "target-element"])) : B("", !0)
3085
+ ]));
3086
+ }
3087
+ }), aa = /* @__PURE__ */ ae(ni, [["__scopeId", "data-v-c415d240"]]), li = ["aria-rowcount", "aria-colcount", "aria-label", "role"], oi = {
3088
+ key: 1,
3089
+ class: "b-data-grid__header"
3090
+ }, si = ["tabindex"], ii = ["tabindex", "aria-busy"], ai = {
3091
+ key: 0,
3092
+ class: "b-data-grid__loading"
3093
+ }, ri = {
3094
+ key: 1,
3095
+ class: "b-data-grid__empty-state"
3096
+ }, di = {
3097
+ key: 5,
3098
+ class: "b-data-grid__footer"
3099
+ }, ui = {
3100
+ i18n: { messages: st },
3101
+ name: "bento-data-grid"
3102
+ }, ci = /* @__PURE__ */ Ie({
3103
+ ...ui,
3104
+ props: {
3105
+ /**
3106
+ * When true, will emit a 'rowClick' event when a row is clicked. Will add cursor: pointer to rows.
3107
+ */
3108
+ allowRowClicks: { type: Boolean, default: !1 },
3109
+ /**
3110
+ * When true, column headers will become draggable, allowing users to rearrange columns.
3111
+ */
3112
+ allowColumnDragAndDrop: { type: Boolean, default: !0 },
3113
+ /**
3114
+ * List of actions that will be rendered in the action bar when user selects items.
3115
+ *
3116
+ * Each object in the list should have a `title`, an `event` and,
3117
+ * optionally, an `icon`.
3118
+ *
3119
+ * The component will display 4 actions and the hide the rest inside a menu.
3120
+ *
3121
+ * @see BentoButton for a list of all the other props supported by each button action.
3122
+ */
3123
+ bulkActions: {
3124
+ type: Array,
3125
+ default: null
3126
+ },
3127
+ /**
3128
+ * Sets the row cells to the condensed padding state.
3129
+ */
3130
+ condensed: {
3131
+ type: Boolean,
3132
+ default: !1
3133
+ },
3134
+ /**
3135
+ * Column definitions using 'key' to relate to data object.
3136
+ */
3137
+ columns: {
3138
+ type: Array,
3139
+ required: !0
3140
+ },
3141
+ /**
3142
+ * Enables / hides the display options panel and the column contextual menu functionality.
3143
+ */
3144
+ columnPanel: { type: Boolean, default: !1 },
3145
+ /**
3146
+ * An array of data objects to display.
3147
+ */
3148
+ data: {
3149
+ type: Array,
3150
+ required: !0
3151
+ },
3152
+ /**
3153
+ * Empty state props that will be passed down to inner empty-state component
3154
+ */
3155
+ emptyState: {
3156
+ type: Object,
3157
+ default: void 0
3158
+ },
3159
+ /**
3160
+ * filter-bar value (i.e. filters) that will be passed down to inner filter-bar component
3161
+ * {@see BentoFilterBarModel}
3162
+ */
3163
+ filters: {
3164
+ // TODO: Change this to BentoFilterBarProps['value'] when the interface is available
3165
+ type: Array,
3166
+ default: void 0
3167
+ },
3168
+ /**
3169
+ * Defines the layout (multi-line or one-line) to be used in the filter bar for different
3170
+ * container sizes:
3171
+ * - Large (>=700px): Always multi-line
3172
+ * - Medium (>=430px & <700px)
3173
+ * - Small (<430px)
3174
+ *
3175
+ * @default
3176
+ * {
3177
+ * medium: 'multi-line',
3178
+ * small: 'one-line'
3179
+ * }
3180
+ */
3181
+ filtersContainerSizeLayout: {
3182
+ type: Object,
3183
+ default: void 0
3184
+ },
3185
+ /**
3186
+ * An array of the values for each filter set in `value`.
3187
+ * {@see BentoFilterValues}
3188
+ */
3189
+ filterValues: {
3190
+ type: at.props.filterValues.type,
3191
+ default: () => []
3192
+ },
3193
+ // TODO: Move this prop as a part of "config" BentoFilterBarModel = Array<BentoFilterModel | BentoFilterSearchModel> in Bento 2.0.
3194
+ // It was not done now because it's a breaking change for the types.
3195
+ /**
3196
+ * Filter's search bar properties with which the placeholder, hint and other
3197
+ * "bento-search-bar" properties can be set. @see {@link BentoFilterBarSearchBarProps}
3198
+ */
3199
+ filterSearchConfig: {
3200
+ type: Object,
3201
+ default: void 0
3202
+ },
3203
+ /**
3204
+ * Filter bar search term useful to filter all the data by text
3205
+ */
3206
+ filterSearchTerm: {
3207
+ type: at.props.searchTerm.type,
3208
+ default: void 0
3209
+ },
3210
+ /**
3211
+ * Allows the grid to be rendered inside a confined space.
3212
+ * This makes the data-grid expand to fill the height of its parent container, with the grid body becoming scrollable.
3213
+ */
3214
+ fitContent: { type: Boolean, default: !1 },
3215
+ /**
3216
+ * A customisable method to retrieve a unique identifier for a data item in the array of data supplied.
3217
+ * This is used selecting and performance reasons and must exist in each data item.
3218
+ */
3219
+ getDataItemId: {
3220
+ type: Function,
3221
+ default: (e) => e.id
3222
+ },
3223
+ /**
3224
+ * Row actions propery that generates which button to show in row actions area
3225
+ */
3226
+ rowActions: {
3227
+ type: [Function, Array],
3228
+ default: void 0
3229
+ },
3230
+ /**
3231
+ * If resize is enabled
3232
+ */
3233
+ hasResizableColumns: {
3234
+ type: Boolean,
3235
+ default: !0
3236
+ },
3237
+ /**
3238
+ * Enables the nested content slot functionality.
3239
+ */
3240
+ hasNestedContent: {
3241
+ type: Boolean,
3242
+ default: !1
3243
+ },
3244
+ /**
3245
+ * Enables the nested content slot functionality.
3246
+ */
3247
+ hasNestedRows: {
3248
+ type: Boolean,
3249
+ default: !1
3250
+ },
3251
+ /**
3252
+ * Highlighted items
3253
+ */
3254
+ highlightedRows: {
3255
+ type: Array,
3256
+ default: () => []
3257
+ },
3258
+ /**
3259
+ * A customisable method to determine if a row is not selectable.
3260
+ * The default is that every row is selectable.
3261
+ */
3262
+ isDataItemDisabled: {
3263
+ type: Function,
3264
+ default: () => !1
3265
+ },
3266
+ /**
3267
+ * The type of `Lazy Load`.
3268
+ * Type "automatic" will enable infinite scrolling
3269
+ * Type "button" will enable lazy loading with "Show more" button
3270
+ * @values automatic, button, none
3271
+ */
3272
+ lazyLoadType: {
3273
+ type: String,
3274
+ default: "none",
3275
+ validator: (e) => ["automatic", "button", "none"].includes(e)
3276
+ },
3277
+ /**
3278
+ * If the loading indicator should be shown.
3279
+ */
3280
+ loading: {
3281
+ type: Boolean,
3282
+ default: !1
3283
+ },
3284
+ /**
3285
+ * Enables / Disables the table's surrounding border.
3286
+ */
3287
+ outline: {
3288
+ type: Boolean,
3289
+ default: !1
3290
+ },
3291
+ /**
3292
+ * Renders the data grid with no top spacing, to render inside containers that already have spacing
3293
+ */
3294
+ noSpacingTop: {
3295
+ type: Boolean,
3296
+ default: !1
3297
+ },
3298
+ /**
3299
+ * Pagination props that will be passed down to inner pagination component
3300
+ */
3301
+ pagination: {
3302
+ type: Object,
3303
+ default: void 0
3304
+ },
3305
+ /**
3306
+ * Adds an extra option when selecting all items that allows user to select items in other pages too.
3307
+ */
3308
+ selectableAcrossPages: {
3309
+ type: Boolean,
3310
+ default: !1
3311
+ },
3312
+ /**
3313
+ * Renders a font numeric style with slashed zeros instead of normal ones.
3314
+ */
3315
+ slashedZero: { type: Boolean, default: !1 },
3316
+ /**
3317
+ * Sticks the horizontal scrollbar to the bottom of the screen if the data-grid is larger than the screen height.
3318
+ */
3319
+ stickyHorizontalScrollbar: {
3320
+ type: Boolean,
3321
+ default: !1
3322
+ },
3323
+ /**
3324
+ * Make pagination stick to the bottom of the page when the data-grid is bigger than the screen.
3325
+ * Because styles have to be applied to pagination container element, this has to be a data-grid prop (rather than a pagination prop).
3326
+ */
3327
+ stickyPagination: {
3328
+ type: Boolean,
3329
+ default: !1
3330
+ },
3331
+ /**
3332
+ * Make data-grid filters stick to the top of the page along with the data-grid headers.
3333
+ * Defaults to true.
3334
+ */
3335
+ stickyFilters: {
3336
+ type: Boolean,
3337
+ default: !0
3338
+ },
3339
+ /**
3340
+ * Enables / Disables rows to be selected via a checkbox. On select the "select" event will be emitted.
3341
+ */
3342
+ selectable: {
3343
+ type: Boolean,
3344
+ default: !1
3345
+ },
3346
+ /**
3347
+ * Selected items
3348
+ */
3349
+ selection: {
3350
+ type: Array,
3351
+ default: () => []
3352
+ },
3353
+ /**
3354
+ * Enables / Disables the nested-content slot
3355
+ */
3356
+ shouldShowNestedContent: {
3357
+ type: Function,
3358
+ default: (e) => !0
3359
+ },
3360
+ /**
3361
+ * Returns the nested rows for a given BentoDatagridDataItem.
3362
+ */
3363
+ shouldShowNestedRows: {
3364
+ type: Function,
3365
+ default: (e) => !0
3366
+ },
3367
+ /**
3368
+ * Sortby handles proper rendering of sort icon in header. Sorting currently is only supported server side.
3369
+ * It does make sure the currently sorted column has a more visible sort icon, and the sort icon points in the right direction.
3370
+ */
3371
+ sortBy: {
3372
+ type: Array,
3373
+ // NOTE: is an array to allow multi-sorting in the future
3374
+ default: () => []
3375
+ },
3376
+ /**
3377
+ * Title of the data grid to be rendered as tab title when a data grid is passed in a tab layout.
3378
+ */
3379
+ tabTitle: {
3380
+ type: String,
3381
+ default: null
3382
+ },
3383
+ /**
3384
+ * Truncates all data grid column headers
3385
+ */
3386
+ truncateColumnHeaders: {
3387
+ type: Boolean,
3388
+ default: !1
3389
+ }
3390
+ },
3391
+ emits: [
3392
+ z.COLUMNS,
3393
+ z.COLUMN_RESIZE,
3394
+ z.ITEMS_PAGE,
3395
+ z.FILTER_SEARCH_INPUT,
3396
+ z.FILTER_SEARCH_CLEAR,
3397
+ z.NAVIGATE,
3398
+ z.NESTED_CONTENT_TOGGLED,
3399
+ z.UPDATE_COLUMNS,
3400
+ z.UPDATE_CONDENSED,
3401
+ z.UPDATE_FILTER_VALUES,
3402
+ z.UPDATE_FILTERS,
3403
+ z.UPDATE_FILTER_SEARCH_TERM,
3404
+ z.UPDATE_SHOW_MORE,
3405
+ z.UPDATE_PAGINATION,
3406
+ z.UPDATE_SELECTION,
3407
+ z.UPDATE_SORT_BY,
3408
+ z.ROW_CLICK,
3409
+ z.SELECT,
3410
+ z.SELECT_ALL_ACROSS_PAGES,
3411
+ z.SORT
3412
+ ],
3413
+ setup(e, { expose: i, emit: a }) {
3414
+ const t = e, c = ht(), n = wt(c), l = A(null), g = A(), f = A({}), C = A(null), R = A(null), v = A(), F = A(null), _ = A(null), y = A(null), {
3415
+ allowColumnDragAndDrop: T,
3416
+ columns: M,
3417
+ columnPanel: m,
3418
+ data: w,
3419
+ lazyLoadType: s,
3420
+ loading: E,
3421
+ hasNestedContent: I,
3422
+ hasNestedRows: D,
3423
+ selectable: r,
3424
+ selection: p,
3425
+ selectableAcrossPages: U,
3426
+ stickyPagination: J,
3427
+ outline: ue,
3428
+ pagination: le
3429
+ } = vt(t), Ce = A(-1), { t: we } = Ue({ messages: st }), ce = b(() => W.value.filter(($) => $.frozen).length), me = dt(
3430
+ Sl,
3431
+ () => ({
3432
+ additionalContentSlotRef: A(null),
3433
+ isDataGridTemplate: !1,
3434
+ stickyAditionalContent: A(!1),
3435
+ stickyTabs: A(!1),
3436
+ tabsRef: A(null)
3437
+ })
3438
+ ), { additionalContentSlotRef: Q, isDataGridTemplate: h, stickyTabs: j, tabsRef: Z, stickyAdditionalContent: x } = me(), d = b(() => h ? 0 : null), {
3439
+ columnDefs: W,
3440
+ onColumnWidthOverride: N,
3441
+ gridRowWidthStyle: oe,
3442
+ isMeasuringColumnWidths: ee,
3443
+ isTotalWidthOfColumnsTakingUpAllAvailableGridWidth: Ge,
3444
+ columns: ze,
3445
+ totalWidthOfAllColumns: S,
3446
+ rowActionsMaxWidth: k
3447
+ } = Xl(M, w, l, f, C, {
3448
+ hasColumnPanel: m,
3449
+ hasSelectableColumn: r,
3450
+ hasSelectableAcrossPages: U,
3451
+ hasNestedContent: I,
3452
+ hasNestedRows: D,
3453
+ allowColumnDragAndDrop: T,
3454
+ isDataGridTemplate: h
3455
+ }), Y = a, H = ($, ...P) => {
3456
+ ($ === z.COLUMNS || $ === z.UPDATE_COLUMNS) && ([ze.value] = P), Y($, ...P);
3457
+ }, se = Pt(
3458
+ Z,
3459
+ j,
3460
+ x,
3461
+ Q
3462
+ ), fe = b(
3463
+ () => t.stickyFilters ? `${se.value}px` : null
3464
+ ), Se = Pt(R, rt(t, "stickyFilters")), Pe = b(
3465
+ () => `${Se.value + se.value}px`
3466
+ ), {
3467
+ sortedColumns: Ye,
3468
+ columnSets: Oe,
3469
+ isOnlyOneVisibleColumn: Xe,
3470
+ onConfigSettingsUpdate: it,
3471
+ onConfigSettingsColumnsUpdate: bn,
3472
+ onConfigSettingsColumnUpdate: yn
3473
+ } = oo(W, H), { hoveredOverColumn: En, hoveredOverColumnState: Et } = io(
3474
+ Oe,
3475
+ r,
3476
+ ue,
3477
+ Ge
3478
+ ), { draggingColumns: St, draggingEventsForColumns: Sn, draggingEventsForRowCell: pn, onMoveColumnByOffset: Ln } = lo(Ye, T, H), pt = b(() => !!t.selectableAcrossPages && !!t.pagination), {
3479
+ onAllRowSelect: Lt,
3480
+ onRowSelect: Rn,
3481
+ onNestedRowSelect: An,
3482
+ onDeselectAll: On,
3483
+ selectedItems: Je,
3484
+ allItemsSelectedState: Tn,
3485
+ isEveryItemSelected: Nn,
3486
+ isEveryItemAcrossPagesSelected: In
3487
+ } = Jl(
3488
+ p,
3489
+ H,
3490
+ w,
3491
+ t.getDataItemId,
3492
+ t.isDataItemDisabled,
3493
+ pt,
3494
+ le
3495
+ ), { navigationInput: Qe } = eo(
3496
+ C,
3497
+ f,
3498
+ Ye,
3499
+ r,
3500
+ b(() => t.rowActions !== void 0),
3501
+ m
3502
+ ), { isLazyLoad: Ve, isInfiniteScroll: $n, verticalScrollPosition: Dn, emitLazyLoadEvent: kn } = no(
3503
+ s,
3504
+ _,
3505
+ l,
3506
+ E,
3507
+ H
3508
+ ), {
3509
+ updateScrollPosition: et,
3510
+ updateScrollPositionOnFrozenColumnsNavigation: Mn,
3511
+ syncVirtualScrollerWithBody: Rt,
3512
+ hasLeftOverflow: tt,
3513
+ hasRightOverflow: At,
3514
+ horizontalScrollbarConditionalStyles: Fn
3515
+ } = so(
3516
+ l,
3517
+ g,
3518
+ Dn,
3519
+ y,
3520
+ F,
3521
+ S,
3522
+ {
3523
+ isLazyLoad: Ve,
3524
+ pagination: le,
3525
+ stickyPagination: J,
3526
+ isDataGridTemplate: h
3527
+ }
3528
+ ), Un = () => {
3529
+ v.value.isClearAllVisible ? v.value.clearAllFilters() : v.value.isResetAllVisible && v.value.resetAllFilters();
3530
+ }, zn = b(() => {
3531
+ var $, P;
3532
+ return {
3533
+ ...t.emptyState,
3534
+ variant: (($ = t.emptyState) == null ? void 0 : $.variant) === "embedded" || ((P = t.emptyState) == null ? void 0 : P.variant) === "basic" ? t.emptyState.variant : "basic"
3535
+ };
3536
+ }), Pn = b(() => ({
3537
+ [`b-data-grid--${De.OUTLINE}`]: t.outline,
3538
+ [`b-data-grid--${De.SCROLL}`]: t.fitContent || Ve.value,
3539
+ [`b-data-grid--${De.STICKY_FILTERS}`]: t.filters && t.stickyFilters,
3540
+ [`b-data-grid--${De.OVERFLOW_SHADOW_LEFT}`]: tt.value && !ce.value,
3541
+ [`b-data-grid--${De.OVERFLOW_SHADOW_RIGHT}`]: At.value && t.rowActions === void 0,
3542
+ [`b-data-grid--${De.NO_SPACING_TOP}`]: t.noSpacingTop,
3543
+ [`b-data-grid--${De.FIT_CONTENT}`]: t.fitContent
3544
+ })), Bn = b(() => ({
3545
+ "b-data-grid__body--sticky-horizontal-scrollbar": t.stickyHorizontalScrollbar
3546
+ })), Wn = b(() => Oe.value.findIndex(($) => $.columnSet.length)), Ot = b(() => !((t.selectable || t.hasNestedContent || t.hasNestedRows) && ce.value === 1) || tt.value), Gn = b(() => ({
3547
+ "b-data-grid__filters--sticky": !!t.stickyFilters || h
3548
+ })), Hn = b(() => {
3549
+ var $, P, ie, q, pe, Te;
3550
+ return {
3551
+ "b-data-grid__pagination--padding-left-unset": ((ie = (P = ($ = t.columns) == null ? void 0 : $[0]) == null ? void 0 : P.padding) == null ? void 0 : ie.left) === !1,
3552
+ "b-data-grid__pagination--padding-right-unset": ((Te = (pe = (q = t.columns) == null ? void 0 : q[t.columns.length - 1]) == null ? void 0 : pe.padding) == null ? void 0 : Te.right) === !1,
3553
+ "b-data-grid__pagination--sticky": !!t.stickyPagination || h
3554
+ };
3555
+ }), Vn = ($) => {
3556
+ const P = $;
3557
+ $ !== null && (P != null && P.columnHeaderRefs) && Object.entries(P == null ? void 0 : P.columnHeaderRefs).forEach(([ie, q]) => {
3558
+ f.value[ie] = q;
3559
+ });
3560
+ }, xn = ($, P) => {
3561
+ var q, pe, Te, Be;
3562
+ const ie = $;
3563
+ if ($ !== null && ie != null && ie.gridcellRefs) {
3564
+ const Le = t.rowActions !== void 0 && (ie == null ? void 0 : ie.rowActionsRef);
3565
+ Object.entries(ie == null ? void 0 : ie.gridcellRefs).map(([$e, xe]) => {
3566
+ var It;
3567
+ ((It = C.value) == null ? void 0 : It[$e]) === void 0 && (C.value = { ...C.value, [$e]: [] }), C.value[$e][P] = xe;
3568
+ }), Le && (((q = C.value) == null ? void 0 : q[je]) === void 0 && (C.value = { ...C.value, [je]: [] }), C.value[je][P] = (pe = ie.rowActionsRef) == null ? void 0 : pe[0], k.value = Math.max(
3569
+ k.value,
3570
+ ((Be = (Te = ie.rowActionsRef) == null ? void 0 : Te[0]) == null ? void 0 : Be.offsetWidth) ?? 0
3571
+ ));
3572
+ }
3573
+ }, Zn = ($, P) => {
3574
+ t.allowRowClicks && H(z.ROW_CLICK, $, P);
3575
+ }, jn = ($) => {
3576
+ Ce.value = $;
3577
+ }, qn = b(() => t.hasNestedContent || t.hasNestedRows ? "treegrid" : "grid"), Tt = _l({
3578
+ label: c != null && c.header ? bl(c)("header") : null,
3579
+ defaultFallback: "data grid"
3580
+ }), Kn = b(() => {
3581
+ var $;
3582
+ return In.value ? "all" : Nn.value ? "page" : (($ = Je.value) == null ? void 0 : $.length) > 0 ? "single" : "none";
3583
+ }), Nt = b(() => {
3584
+ var $;
3585
+ return (($ = Je.value) == null ? void 0 : $.length) ?? 0;
3586
+ }), Yn = b(() => t.bulkActions && Nt.value > 0), Xn = ($) => H(z.COLUMN_RESIZE, $), Jn = ($) => {
3587
+ H(z.UPDATE_SORT_BY, $), H(z.SORT, $);
3588
+ }, Qn = ($, P) => {
3589
+ H(z.NAVIGATE, $), H(z.UPDATE_PAGINATION, {
3590
+ ...t.pagination,
3591
+ size: P,
3592
+ page: $
3593
+ });
3594
+ }, el = ($) => {
3595
+ H(z.ITEMS_PAGE, $);
3596
+ }, tl = () => {
3597
+ H(z.FILTER_SEARCH_CLEAR);
3598
+ }, nl = ($) => {
3599
+ H(z.UPDATE_FILTER_SEARCH_TERM, $), H(z.FILTER_SEARCH_INPUT, $);
3600
+ };
3601
+ return b(() => M.value.some(($) => $.mandatory)).value || sn(
3602
+ "WARNING: At least one BentoDataGrid column should be set as mandatory to ensure data is always displayed correctly."
3603
+ ), dt(El, () => null)(t.tabTitle), ln(hn, rt(t, "slashedZero")), i({ onEmptyStateClearResetButtonClick: Un }), ($, P) => {
3604
+ var ie;
3605
+ return u(), L("div", {
3606
+ class: de(["b-data-grid", Pn.value]),
3607
+ "aria-rowcount": o(w).length,
3608
+ "aria-colcount": o(M).length,
3609
+ "aria-label": o(Tt),
3610
+ role: qn.value,
3611
+ onCopy: P[11] || (P[11] = //@ts-ignore
3612
+ (...q) => o(Gt) && o(Gt)(...q))
3613
+ }, [
3614
+ e.filters ? (u(), L("div", {
3615
+ key: 0,
3616
+ ref_key: "filtersRef",
3617
+ ref: R,
3618
+ class: de(["b-data-grid__filters", Gn.value]),
3619
+ style: Me({ top: fe.value })
3620
+ }, [
3621
+ e.filters ? (u(), G(o(at), {
3622
+ key: 0,
3623
+ ref_key: "filterBarRef",
3624
+ ref: v,
3625
+ config: e.filters,
3626
+ "container-size-layout": e.filtersContainerSizeLayout,
3627
+ "filter-values": e.filterValues,
3628
+ search: e.filterSearchConfig,
3629
+ "search-term": e.filterSearchTerm,
3630
+ onSearchInput: nl,
3631
+ onSearchClear: tl,
3632
+ onInput: P[0] || (P[0] = (q) => $.$emit(o(z).UPDATE_FILTERS, q)),
3633
+ "onUpdate:filterValues": P[1] || (P[1] = (q) => $.$emit(o(z).UPDATE_FILTER_VALUES, q))
3634
+ }, null, 8, ["config", "container-size-layout", "filter-values", "search", "search-term"])) : B("", !0)
3635
+ ], 6)) : B("", !0),
3636
+ $.$slots.header ? (u(), L("div", oi, [
3637
+ Ne($.$slots, "header", {}, void 0, !0)
3638
+ ])) : B("", !0),
3639
+ O("div", {
3640
+ class: "b-data-grid__column-headers",
3641
+ style: Me({ top: Pe.value })
3642
+ }, [
3643
+ o(m) ? (u(), G(o(ws), {
3644
+ key: 0,
3645
+ class: "b-data-grid__config-settings",
3646
+ columns: o(ze),
3647
+ condensed: e.condensed,
3648
+ onConfigSettings: o(it),
3649
+ "onUpdate:columns": o(bn)
3650
+ }, null, 8, ["columns", "condensed", "onConfigSettings", "onUpdate:columns"])) : B("", !0),
3651
+ O("div", {
3652
+ ref_key: "columnsRef",
3653
+ ref: g,
3654
+ role: "rowgroup",
3655
+ class: "b-data-grid__columns-row",
3656
+ tabindex: d.value,
3657
+ onScroll: P[4] || (P[4] = //@ts-ignore
3658
+ (...q) => o(et) && o(et)(...q)),
3659
+ onKeydown: P[5] || (P[5] = //@ts-ignore
3660
+ (...q) => o(Qe) && o(Qe)(...q))
3661
+ }, [
3662
+ O("div", {
3663
+ style: Me(o(oe)),
3664
+ class: "b-data-grid__columns",
3665
+ role: "row"
3666
+ }, [
3667
+ (u(!0), L(ve, null, ye(o(Oe), ({ columnSet: q, id: pe, isFrozenColumns: Te }, Be) => (u(), L(ve, null, [
3668
+ q != null && q.length ? (u(), G(o(Yo), ne({
3669
+ key: `data-grid-columns-${pe}`,
3670
+ ref_for: !0,
3671
+ ref: (Le) => Vn(Le),
3672
+ columns: q,
3673
+ "has-resizable-columns": e.hasResizableColumns,
3674
+ "sort-by": e.sortBy,
3675
+ "all-items-selected-state": o(Tn),
3676
+ "is-frozen-columns": Te,
3677
+ "show-frozen-columns-separator": Ot.value,
3678
+ "dragging-columns": o(St),
3679
+ "has-draggable-columns": o(T),
3680
+ "has-column-panel": o(m),
3681
+ "has-left-overflow": o(tt),
3682
+ "has-first-column-panel-right-aligned": Be === Wn.value,
3683
+ "hovered-over-column-state": o(Et),
3684
+ "is-measuring-column-widths": o(ee),
3685
+ "is-only-one-visible-column": o(Xe),
3686
+ selectable: o(r),
3687
+ "selectable-across-pages": pt.value,
3688
+ "selected-items": o(Je),
3689
+ "selection-state": Kn.value,
3690
+ "truncate-column-headers": e.truncateColumnHeaders,
3691
+ "row-actions-maximum-width": o(k)
3692
+ }, ot(o(Sn)), {
3693
+ onColumnHover: P[2] || (P[2] = (Le) => En.value = Le),
3694
+ onColumnMove: o(Ln),
3695
+ onColumnUpdate: o(yn),
3696
+ onColumnResize: Xn,
3697
+ onColumnResizing: o(N),
3698
+ onSelectAllRows: o(Lt),
3699
+ onSelectAllAcrossPages: P[3] || (P[3] = (Le) => H(o(z).SELECT_ALL_ACROSS_PAGES)),
3700
+ onDeselectAll: o(On),
3701
+ onSort: Jn
3702
+ }), He({ _: 2 }, [
3703
+ ye(o(c), (Le, $e) => ({
3704
+ name: $e,
3705
+ fn: V((xe) => [
3706
+ Ne($.$slots, $e, ne({ ref_for: !0 }, xe), void 0, !0)
3707
+ ])
3708
+ }))
3709
+ ]), 1040, ["columns", "has-resizable-columns", "sort-by", "all-items-selected-state", "is-frozen-columns", "show-frozen-columns-separator", "dragging-columns", "has-draggable-columns", "has-column-panel", "has-left-overflow", "has-first-column-panel-right-aligned", "hovered-over-column-state", "is-measuring-column-widths", "is-only-one-visible-column", "selectable", "selectable-across-pages", "selected-items", "selection-state", "truncate-column-headers", "row-actions-maximum-width", "onColumnMove", "onColumnUpdate", "onColumnResizing", "onSelectAllRows", "onDeselectAll"])) : B("", !0)
3710
+ ], 64))), 256))
3711
+ ], 4)
3712
+ ], 40, si)
3713
+ ], 4),
3714
+ O("div", {
3715
+ ref_key: "body",
3716
+ ref: l,
3717
+ "data-testid": "data-grid-body",
3718
+ class: de(["b-data-grid__body", Bn.value]),
3719
+ tabindex: o(E) ? "0" : "-1",
3720
+ "aria-busy": o(E),
3721
+ "aria-live": "polite",
3722
+ onScroll: P[8] || (P[8] = //@ts-ignore
3723
+ (...q) => o(et) && o(et)(...q))
3724
+ }, [
3725
+ o(E) && !o(Ve) ? (u(), L("div", ai, [
3726
+ X(o(Ct), {
3727
+ class: "b-data-grid__loading-indicator",
3728
+ large: ""
3729
+ }),
3730
+ X(o(Ke), {
3731
+ el: "span",
3732
+ variant: "caption"
3733
+ }, {
3734
+ default: V(() => [
3735
+ ge(K(o(we)("gettingYourData")), 1)
3736
+ ]),
3737
+ _: 1
3738
+ })
3739
+ ])) : ((ie = o(w)) == null ? void 0 : ie.length) === 0 && e.emptyState ? (u(), L("div", ri, [
3740
+ X(o(yl), rl(dl(zn.value)), null, 16)
3741
+ ])) : (u(), L("div", {
3742
+ key: 2,
3743
+ class: "b-data-grid__rows",
3744
+ role: "rowgroup",
3745
+ onKeydown: P[7] || (P[7] = //@ts-ignore
3746
+ (...q) => o(Qe) && o(Qe)(...q))
3747
+ }, [
3748
+ (u(!0), L(ve, null, ye(o(w), (q, pe) => {
3749
+ var Te, Be;
3750
+ return u(), G(o(wn), {
3751
+ key: pe,
3752
+ ref_for: !0,
3753
+ ref: (Le) => xn(Le, pe),
3754
+ style: Me(o(oe)),
3755
+ "allow-row-clicks": e.allowRowClicks,
3756
+ "column-sets": o(Oe),
3757
+ condensed: e.condensed,
3758
+ "dragging-columns": o(St),
3759
+ "dragging-events-for-row-cell": o(pn),
3760
+ "get-data-item-id": e.getDataItemId,
3761
+ "has-nested-content": o(I),
3762
+ "has-nested-rows": o(D),
3763
+ "has-left-overflow": o(tt),
3764
+ "has-right-overflow": o(At),
3765
+ "highlighted-rows": e.highlightedRows,
3766
+ "hovered-row-index": Ce.value,
3767
+ "hovered-over-column-state": o(Et),
3768
+ "is-data-item-disabled": e.isDataItemDisabled,
3769
+ "is-row-last-child": pe + 1 === ((Te = o(w)) == null ? void 0 : Te.length),
3770
+ "is-measuring-column-widths": o(ee),
3771
+ "row-actions-maximum-width": o(k),
3772
+ "row-actions": e.rowActions,
3773
+ "row-data": q,
3774
+ "row-index": pe,
3775
+ "row-set-size": (Be = o(w)) == null ? void 0 : Be.length,
3776
+ "show-frozen-columns-separator": Ot.value,
3777
+ "should-show-nested-content": e.shouldShowNestedContent,
3778
+ "should-show-nested-rows": e.shouldShowNestedRows,
3779
+ selectable: o(r),
3780
+ "selected-items": o(Je),
3781
+ onCellHovered: jn,
3782
+ onNestedContentToggled: P[6] || (P[6] = (Le) => H(o(z).NESTED_CONTENT_TOGGLED, Le)),
3783
+ onRowClick: Zn,
3784
+ onOnFrozenColumnsKeyPress: o(Mn),
3785
+ onSelectRow: o(Rn),
3786
+ onSelectNestedRow: o(An)
3787
+ }, He({ _: 2 }, [
3788
+ ye(o(c), (Le, $e) => ({
3789
+ name: $e,
3790
+ fn: V((xe) => [
3791
+ Ne($.$slots, $e, ne({ ref_for: !0 }, xe), void 0, !0)
3792
+ ])
3793
+ }))
3794
+ ]), 1032, ["style", "allow-row-clicks", "column-sets", "condensed", "dragging-columns", "dragging-events-for-row-cell", "get-data-item-id", "has-nested-content", "has-nested-rows", "has-left-overflow", "has-right-overflow", "highlighted-rows", "hovered-row-index", "hovered-over-column-state", "is-data-item-disabled", "is-row-last-child", "is-measuring-column-widths", "row-actions-maximum-width", "row-actions", "row-data", "row-index", "row-set-size", "show-frozen-columns-separator", "should-show-nested-content", "should-show-nested-rows", "selectable", "selected-items", "onOnFrozenColumnsKeyPress", "onSelectRow", "onSelectNestedRow"]);
3795
+ }), 128))
3796
+ ], 32))
3797
+ ], 42, ii),
3798
+ o(Ve) ? (u(), G(o(Es), {
3799
+ key: 2,
3800
+ loading: o(E),
3801
+ "is-infinite-scroll": o($n),
3802
+ "onUpdate:showMore": o(kn)
3803
+ }, null, 8, ["loading", "is-infinite-scroll", "onUpdate:showMore"])) : B("", !0),
3804
+ e.stickyHorizontalScrollbar ? (u(), L("div", {
3805
+ key: 3,
3806
+ ref_key: "virtualHorizontalScrollbarRef",
3807
+ ref: y,
3808
+ class: "b-data-grid__horizontal-scrollbar",
3809
+ "aria-hidden": "true",
3810
+ "data-testid": "sticky-horizontal-scrollbar",
3811
+ style: Me(o(Fn)),
3812
+ onScroll: P[9] || (P[9] = //@ts-ignore
3813
+ (...q) => o(Rt) && o(Rt)(...q))
3814
+ }, [
3815
+ O("div", {
3816
+ style: Me({ width: `${o(S)}px`, height: "15px" })
3817
+ }, null, 4)
3818
+ ], 36)) : B("", !0),
3819
+ o(le) && !o(Ve) ? (u(), L("div", {
3820
+ key: 4,
3821
+ ref_key: "paginationContainerRef",
3822
+ ref: F,
3823
+ "data-testid": "pagination-container",
3824
+ class: de(["b-data-grid__pagination", Hn.value])
3825
+ }, [
3826
+ X(o(wl), ne(o(le), {
3827
+ "aria-label": `${o(Tt)} navigation`,
3828
+ onNavigate: Qn,
3829
+ onItemsPage: el
3830
+ }), {
3831
+ default: V(() => [
3832
+ o(n)("pagination-slot") ? Ne($.$slots, "pagination-slot", { key: 0 }, void 0, !0) : B("", !0)
3833
+ ]),
3834
+ _: 3
3835
+ }, 16, ["aria-label"])
3836
+ ], 2)) : B("", !0),
3837
+ $.$slots.footer ? (u(), L("div", di, [
3838
+ Ne($.$slots, "footer", {}, void 0, !0)
3839
+ ])) : B("", !0),
3840
+ Yn.value ? (u(), G(o(Cl), {
3841
+ key: 6,
3842
+ actions: e.bulkActions,
3843
+ "item-counter": Nt.value,
3844
+ "extra-bottom-spacing": o(J),
3845
+ onClose: P[10] || (P[10] = (q) => o(Lt)(!1))
3846
+ }, null, 8, ["actions", "item-counter", "extra-bottom-spacing"])) : B("", !0)
3847
+ ], 42, li);
3848
+ };
3849
+ }
3850
+ }), ra = /* @__PURE__ */ ae(ci, [["__scopeId", "data-v-47ed24f7"]]);
3851
+ export {
3852
+ ft as B,
3853
+ ia as a,
3854
+ aa as b,
3855
+ De as c,
3856
+ ra as d,
3857
+ Fe as e,
3858
+ z as f,
3859
+ lt as g
3860
+ };
3861
+ //# sourceMappingURL=data-grid.BbZSu-mA.js.map