@shifl-inc/ui 0.5.0 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/shifl-ui.js CHANGED
@@ -1,17 +1,17 @@
1
- import { ref as b, computed as k, onMounted as de, onUnmounted as ge, watch as j, nextTick as He, defineComponent as ze, createElementBlock as l, openBlock as o, withModifiers as U, createElementVNode as h, createCommentVNode as z, createTextVNode as se, toDisplayString as L, Fragment as N, renderList as E, normalizeClass as G, createBlock as O, Teleport as Re, normalizeStyle as W, createVNode as Ne, unref as D, resolveDynamicComponent as fe, createStaticVNode as It, provide as Ot, inject as Zt } from "vue";
2
- function jt(a) {
1
+ import { ref as b, computed as k, onMounted as de, onUnmounted as ge, watch as j, nextTick as Re, defineComponent as ze, createElementBlock as l, openBlock as o, withModifiers as q, createElementVNode as g, createCommentVNode as D, createTextVNode as se, toDisplayString as $, Fragment as x, renderList as V, normalizeClass as G, createBlock as Z, Teleport as He, normalizeStyle as K, createVNode as Ne, unref as E, resolveDynamicComponent as fe, createStaticVNode as Ft, provide as Kt, inject as Wt } from "vue";
2
+ function Jt(a) {
3
3
  const r = (a.columns || []).map((_) => ({
4
4
  ..._,
5
5
  freeze: _.freeze ?? !1,
6
6
  visible: _.visible ?? !0,
7
7
  protected: _.protected ?? !1
8
- })), g = a.apiConfig ? "server" : a.searchMode || "client";
8
+ })), d = a.apiConfig ? "server" : a.searchMode || "client";
9
9
  return {
10
10
  ...a,
11
11
  columns: r,
12
12
  rows: a.rows ?? [],
13
13
  search: a.search ?? [],
14
- searchMode: g,
14
+ searchMode: d,
15
15
  filters: a.filters ?? [],
16
16
  paginationMeta: a.paginationMeta ? {
17
17
  show: a.paginationMeta.show ?? !0,
@@ -24,98 +24,98 @@ function jt(a) {
24
24
  } : void 0
25
25
  };
26
26
  }
27
- function Ft(a) {
28
- const r = [...a], g = b([...a]);
29
- function _(f) {
30
- g.value = g.value.map(
31
- (d) => d.key === f ? { ...d, visible: !d.visible } : d
27
+ function qt(a) {
28
+ const r = [...a], d = b([...a]);
29
+ function _(h) {
30
+ d.value = d.value.map(
31
+ (u) => u.key === h ? { ...u, visible: !u.visible } : u
32
32
  );
33
33
  }
34
- function c(f) {
35
- g.value = g.value.map((d) => ({ ...d, visible: f }));
34
+ function c(h) {
35
+ d.value = d.value.map((u) => ({ ...u, visible: h }));
36
36
  }
37
- function v(f) {
38
- const d = g.value.map(
39
- (w) => w.key === f ? { ...w, freeze: !w.freeze } : w
40
- ), m = d.filter((w) => w.freeze), P = d.filter((w) => !w.freeze);
41
- g.value = [...m, ...P];
37
+ function v(h) {
38
+ const u = d.value.map(
39
+ (w) => w.key === h ? { ...w, freeze: !w.freeze } : w
40
+ ), m = u.filter((w) => w.freeze), S = u.filter((w) => !w.freeze);
41
+ d.value = [...m, ...S];
42
42
  }
43
- function S(f, d) {
44
- if (f === d || d < 0 || d >= g.value.length) return;
45
- const m = g.value.findIndex((p) => !p.freeze), P = m === -1 ? g.value.length : m;
46
- if (f < P || d < P) return;
47
- const w = [...g.value], [u] = w.splice(f, 1);
48
- w.splice(d, 0, u), g.value = w;
43
+ function T(h, u) {
44
+ if (h === u || u < 0 || u >= d.value.length) return;
45
+ const m = d.value.findIndex((p) => !p.freeze), S = m === -1 ? d.value.length : m;
46
+ if (h < S || u < S) return;
47
+ const w = [...d.value], [f] = w.splice(h, 1);
48
+ w.splice(u, 0, f), d.value = w;
49
49
  }
50
- function T() {
51
- g.value = [...r];
50
+ function P() {
51
+ d.value = [...r];
52
52
  }
53
- const M = k(() => g.value.filter((f) => f.visible));
53
+ const M = k(() => d.value.filter((h) => h.visible));
54
54
  return {
55
- columns: g,
55
+ columns: d,
56
56
  visibleColumns: M,
57
57
  toggleColumnVisibility: _,
58
58
  setAllVisible: c,
59
59
  toggleFreeze: v,
60
- moveColumn: S,
61
- resetColumns: T
60
+ moveColumn: T,
61
+ resetColumns: P
62
62
  };
63
63
  }
64
- function Kt(a) {
64
+ function Ut(a) {
65
65
  const r = b(a);
66
- function g(c) {
66
+ function d(c) {
67
67
  var v;
68
68
  r.value = ((v = r.value) == null ? void 0 : v.key) === c && r.value.order === "asc" ? { key: c, order: "desc" } : { key: c, order: "asc" };
69
69
  }
70
70
  function _(c) {
71
71
  if (!r.value) return c;
72
- const { key: v, order: S } = r.value;
73
- return [...c].sort((T, M) => {
74
- const f = T[v], d = M[v];
75
- if (f === d) return 0;
76
- if (f == null) return 1;
77
- if (d == null) return -1;
78
- const m = String(f).localeCompare(String(d), void 0, {
72
+ const { key: v, order: T } = r.value;
73
+ return [...c].sort((P, M) => {
74
+ const h = P[v], u = M[v];
75
+ if (h === u) return 0;
76
+ if (h == null) return 1;
77
+ if (u == null) return -1;
78
+ const m = String(h).localeCompare(String(u), void 0, {
79
79
  numeric: !0
80
80
  });
81
- return S === "asc" ? m : -m;
81
+ return T === "asc" ? m : -m;
82
82
  });
83
83
  }
84
84
  return {
85
85
  sort: r,
86
- setSort: g,
86
+ setSort: d,
87
87
  applySort: _
88
88
  };
89
89
  }
90
- function Wt() {
91
- function a(r, g, _) {
90
+ function Yt() {
91
+ function a(r, d, _) {
92
92
  const c = (_ || "").trim().toLowerCase();
93
- return c ? r.filter((v) => (g && g.length ? g.map((T) => v[T]) : Object.values(v)).some(
94
- (T) => String(T ?? "").toLowerCase().includes(c)
93
+ return c ? r.filter((v) => (d && d.length ? d.map((P) => v[P]) : Object.values(v)).some(
94
+ (P) => String(P ?? "").toLowerCase().includes(c)
95
95
  )) : r;
96
96
  }
97
97
  return {
98
98
  applyGlobalFilter: a
99
99
  };
100
100
  }
101
- function Jt() {
101
+ function Qt() {
102
102
  const a = b({
103
103
  rowIndex: null,
104
104
  position: null
105
105
  });
106
- function r(v, S, T = 200) {
107
- const M = S.getBoundingClientRect();
108
- let f = M.left;
109
- f + T > window.innerWidth - 8 && (f = window.innerWidth - T + 8), a.value = {
106
+ function r(v, T, P = 200) {
107
+ const M = T.getBoundingClientRect();
108
+ let h = M.left;
109
+ h + P > window.innerWidth - 8 && (h = window.innerWidth - P + 8), a.value = {
110
110
  rowIndex: v,
111
111
  position: {
112
112
  top: M.bottom,
113
113
  // 4px below trigger
114
- left: f
114
+ left: h
115
115
  }
116
116
  };
117
117
  }
118
- function g() {
118
+ function d() {
119
119
  a.value = {
120
120
  rowIndex: null,
121
121
  position: null
@@ -125,7 +125,7 @@ function Jt() {
125
125
  return a.value.rowIndex === v;
126
126
  }
127
127
  function c(v) {
128
- v.key === "Escape" && a.value.rowIndex !== null && g();
128
+ v.key === "Escape" && a.value.rowIndex !== null && d();
129
129
  }
130
130
  return de(() => {
131
131
  document.addEventListener("keydown", c);
@@ -134,183 +134,184 @@ function Jt() {
134
134
  }), {
135
135
  menuState: a,
136
136
  openMenu: r,
137
- closeMenu: g,
137
+ closeMenu: d,
138
138
  isMenuOpen: _
139
139
  };
140
140
  }
141
- function qt(a, r) {
142
- const g = b(!1), _ = b(null), c = b([]), v = b(void 0);
143
- let S = null;
144
- function T(u) {
141
+ function Xt(a, r) {
142
+ const d = b(!1), _ = b(null), c = b([]), v = b(void 0);
143
+ let T = null;
144
+ function P(f) {
145
145
  const p = new URLSearchParams();
146
- if (u.search && p.append("search", u.search), u.page !== void 0 && p.append("page", String(u.page)), u.perPage !== void 0 && p.append("per_page", String(u.perPage)), u.sort && (p.append("sort", u.sort.key), p.append("order", u.sort.order)), u.filters && u.filters.length > 0 && u.filters.forEach((C) => {
146
+ if (f.search && p.append("search", f.search), f.page !== void 0 && p.append("page", String(f.page)), f.perPage !== void 0 && p.append("per_page", String(f.perPage)), f.sort && (p.append("sort", f.sort.key), p.append("order", f.sort.order)), f.filters && f.filters.length > 0 && f.filters.forEach((C) => {
147
147
  if (C.value !== void 0 && C.value !== null && C.value !== "") {
148
- const A = `filters[${C.key}]`;
149
- Array.isArray(C.value) ? C.value.forEach(($) => p.append(`${A}[]`, String($))) : p.append(A, String(C.value));
148
+ const L = `filters[${C.key}]`;
149
+ Array.isArray(C.value) ? C.value.forEach((A) => p.append(`${L}[]`, String(A))) : p.append(L, String(C.value));
150
150
  }
151
151
  }), r != null && r.additionalParams) {
152
- const C = typeof r.additionalParams == "function" ? r.additionalParams(u) : r.additionalParams;
153
- Object.entries(C).forEach(([A, $]) => {
154
- $ != null && $ !== "" && (Array.isArray($) ? $.forEach((x) => p.append(`${A}[]`, String(x))) : p.append(A, String($)));
152
+ const C = typeof r.additionalParams == "function" ? r.additionalParams(f) : r.additionalParams;
153
+ Object.entries(C).forEach(([L, A]) => {
154
+ A != null && A !== "" && (Array.isArray(A) ? A.forEach((N) => p.append(`${L}[]`, String(N))) : p.append(L, String(A)));
155
155
  });
156
156
  }
157
157
  return p;
158
158
  }
159
- function M(u) {
160
- var p, C, A;
161
- return r != null && r.bodyBuilder ? r.bodyBuilder(u) : {
162
- search: u.search,
163
- page: u.page,
164
- per_page: u.perPage,
165
- sort: (p = u.sort) == null ? void 0 : p.key,
166
- order: (C = u.sort) == null ? void 0 : C.order,
167
- filters: (A = u.filters) == null ? void 0 : A.reduce(
168
- ($, x) => (x.value !== void 0 && x.value !== null && x.value !== "" && ($[x.key] = x.value), $),
159
+ function M(f) {
160
+ var p, C, L;
161
+ return r != null && r.bodyBuilder ? r.bodyBuilder(f) : {
162
+ search: f.search,
163
+ page: f.page,
164
+ per_page: f.perPage,
165
+ sort: (p = f.sort) == null ? void 0 : p.key,
166
+ order: (C = f.sort) == null ? void 0 : C.order,
167
+ // tabName: context.tabName,
168
+ filters: (L = f.filters) == null ? void 0 : L.reduce(
169
+ (A, N) => (N.value !== void 0 && N.value !== null && N.value !== "" && (A[N.key] = N.value), A),
169
170
  {}
170
171
  ),
171
- ...typeof (r == null ? void 0 : r.additionalParams) == "function" ? r.additionalParams(u) : (r == null ? void 0 : r.additionalParams) || {}
172
+ ...typeof (r == null ? void 0 : r.additionalParams) == "function" ? r.additionalParams(f) : (r == null ? void 0 : r.additionalParams) || {}
172
173
  };
173
174
  }
174
- function f() {
175
- const u = {
175
+ function h() {
176
+ const f = {
176
177
  "Content-Type": "application/json",
177
178
  ...(r == null ? void 0 : r.headers) || {}
178
179
  };
179
180
  if (r != null && r.getAuthToken) {
180
181
  const p = r.getAuthToken();
181
- p && (u.Authorization = `Bearer ${p}`);
182
+ p && (f.Authorization = `Bearer ${p}`);
182
183
  }
183
- return u;
184
+ return f;
184
185
  }
185
- function d(u) {
186
+ function u(f) {
186
187
  if (r != null && r.responseTransformer)
187
- return r.responseTransformer(u);
188
- const p = u;
188
+ return r.responseTransformer(f);
189
+ const p = f;
189
190
  return {
190
191
  data: p.data || p.rows || [],
191
192
  meta: p.meta
192
193
  };
193
194
  }
194
- async function m(u) {
195
+ async function m(f) {
195
196
  if (!a) {
196
197
  _.value = new Error("API URL is required");
197
198
  return;
198
199
  }
199
- g.value = !0, _.value = null;
200
+ d.value = !0, _.value = null;
200
201
  try {
201
- const p = (r == null ? void 0 : r.method) || "GET", C = f();
202
- let A = a, $;
202
+ const p = (r == null ? void 0 : r.method) || "GET", C = h();
203
+ let L = a, A;
203
204
  if (p === "GET") {
204
- const V = r != null && r.paramsBuilder ? r.paramsBuilder(u) : T(u);
205
- if (V instanceof URLSearchParams) {
206
- const F = V.toString();
207
- A = F ? `${a}?${F}` : a;
205
+ const ee = r != null && r.paramsBuilder ? r.paramsBuilder(f) : P(f);
206
+ if (ee instanceof URLSearchParams) {
207
+ const H = ee.toString();
208
+ L = H ? `${a}?${H}` : a;
208
209
  } else {
209
- const F = new URLSearchParams();
210
- Object.entries(V).forEach(([X, Z]) => {
211
- Z != null && Z !== "" && (Array.isArray(Z) ? Z.forEach((ae) => F.append(`${X}[]`, String(ae))) : F.append(X, String(Z)));
210
+ const H = new URLSearchParams();
211
+ Object.entries(ee).forEach(([Y, I]) => {
212
+ I != null && I !== "" && (Array.isArray(I) ? I.forEach((oe) => H.append(`${Y}[]`, String(oe))) : H.append(Y, String(I)));
212
213
  });
213
- const Q = F.toString();
214
- A = Q ? `${a}?${Q}` : a;
214
+ const ae = H.toString();
215
+ L = ae ? `${a}?${ae}` : a;
215
216
  }
216
217
  } else
217
- $ = M(u);
218
- const x = await fetch(A, {
218
+ A = M(f);
219
+ const N = await fetch(L, {
219
220
  method: p,
220
221
  headers: C,
221
- body: $ ? JSON.stringify($) : void 0
222
+ body: A ? JSON.stringify(A) : void 0
222
223
  });
223
- if (!x.ok)
224
- throw new Error(`API request failed: ${x.status} ${x.statusText}`);
225
- const he = await x.json(), ie = d(he);
224
+ if (!N.ok)
225
+ throw new Error(`API request failed: ${N.status} ${N.statusText}`);
226
+ const he = await N.json(), ie = u(he);
226
227
  c.value = ie.data, v.value = ie.meta;
227
228
  } catch (p) {
228
229
  _.value = p instanceof Error ? p : new Error("Unknown error occurred"), c.value = [], v.value = void 0;
229
230
  } finally {
230
- g.value = !1;
231
+ d.value = !1;
231
232
  }
232
233
  }
233
- function P(u, p = !1) {
234
- S && (clearTimeout(S), S = null);
234
+ function S(f, p = !1) {
235
+ T && (clearTimeout(T), T = null);
235
236
  const C = (r == null ? void 0 : r.debounceMs) ?? 300;
236
- p || !u.search ? m(u) : S = setTimeout(() => {
237
- m(u);
237
+ p || !f.search ? m(f) : T = setTimeout(() => {
238
+ m(f);
238
239
  }, C);
239
240
  }
240
- function w(u) {
241
- P(u, !0);
241
+ function w(f) {
242
+ S(f, !0);
242
243
  }
243
244
  return {
244
- loading: k(() => g.value),
245
+ loading: k(() => d.value),
245
246
  error: k(() => _.value),
246
247
  data: k(() => c.value),
247
248
  paginationMeta: k(() => v.value),
248
249
  fetchData: m,
249
- fetchDataDebounced: P,
250
+ fetchDataDebounced: S,
250
251
  refresh: w
251
252
  };
252
253
  }
253
- function Ut(a, r) {
254
- var M, f;
255
- const g = (r == null ? void 0 : r.search) || b(void 0), _ = (r == null ? void 0 : r.filters) || b(a.filters), c = (r == null ? void 0 : r.sort) || b(a.sort), v = (r == null ? void 0 : r.pagination) || b({
254
+ function en(a, r) {
255
+ var M, h;
256
+ const d = (r == null ? void 0 : r.search) || b(void 0), _ = (r == null ? void 0 : r.filters) || b(a.filters), c = (r == null ? void 0 : r.sort) || b(a.sort), v = (r == null ? void 0 : r.pagination) || b({
256
257
  page: ((M = a.paginationMeta) == null ? void 0 : M.currentPage) || 1,
257
- perPage: ((f = a.paginationMeta) == null ? void 0 : f.perPage) || 20
258
- }), S = (r == null ? void 0 : r.extraState) || b(void 0), T = (r == null ? void 0 : r.tabName) || b(void 0);
258
+ perPage: ((h = a.paginationMeta) == null ? void 0 : h.perPage) || 20
259
+ }), T = (r == null ? void 0 : r.extraState) || b(void 0), P = (r == null ? void 0 : r.tabName) || b(void 0);
259
260
  if (a.apiConfig && a.searchMode === "server") {
260
- let d = function() {
261
+ let u = function() {
261
262
  var p, C;
262
263
  return {
263
- search: g.value,
264
+ search: d.value,
264
265
  filters: _.value,
265
266
  sort: c.value,
266
267
  page: (p = v.value) == null ? void 0 : p.page,
267
268
  perPage: (C = v.value) == null ? void 0 : C.perPage,
268
- extraState: S.value,
269
- tabName: T.value
269
+ extraState: T.value,
270
+ tabName: P.value
270
271
  };
271
272
  }, m = function(p) {
272
- var C, A, $, x;
273
- return u ? p.search !== u.search || p.page !== u.page || p.perPage !== u.perPage || p.tabName !== u.tabName || ((C = p.sort) == null ? void 0 : C.key) !== ((A = u.sort) == null ? void 0 : A.key) || (($ = p.sort) == null ? void 0 : $.order) !== ((x = u.sort) == null ? void 0 : x.order) || JSON.stringify(p.filters) !== JSON.stringify(u.filters) || JSON.stringify(p.extraState) !== JSON.stringify(u.extraState) : !0;
273
+ var C, L, A, N;
274
+ return f ? p.search !== f.search || p.page !== f.page || p.perPage !== f.perPage || p.tabName !== f.tabName || ((C = p.sort) == null ? void 0 : C.key) !== ((L = f.sort) == null ? void 0 : L.key) || ((A = p.sort) == null ? void 0 : A.order) !== ((N = f.sort) == null ? void 0 : N.order) || JSON.stringify(p.filters) !== JSON.stringify(f.filters) || JSON.stringify(p.extraState) !== JSON.stringify(f.extraState) : !0;
274
275
  };
275
- const P = qt(a.apiConfig.apiUrl, a.apiConfig);
276
- let w = !1, u = null;
276
+ const S = Xt(a.apiConfig.apiUrl, a.apiConfig);
277
+ let w = !1, f = null;
277
278
  return j(
278
- [g, _, c, v, S, T],
279
+ [d, _, c, v, T, P],
279
280
  () => {
280
281
  if (w)
281
282
  return;
282
- const p = d();
283
+ const p = u();
283
284
  if (!m(p))
284
285
  return;
285
- u = p;
286
- const C = g.value !== void 0;
287
- P.fetchDataDebounced(p, !C);
286
+ f = p;
287
+ const C = d.value !== void 0;
288
+ S.fetchDataDebounced(p, !C);
288
289
  },
289
290
  { immediate: !0, deep: !0 }
290
- ), j(P.paginationMeta, (p) => {
291
+ ), j(S.paginationMeta, (p) => {
291
292
  if (p && v.value) {
292
293
  const C = p.perPage || v.value.perPage;
293
- C !== v.value.perPage && (w = !0, v.value.perPage = C, He(() => {
294
+ C !== v.value.perPage && (w = !0, v.value.perPage = C, Re(() => {
294
295
  w = !1;
295
296
  }));
296
297
  }
297
298
  }), {
298
- rows: P.data,
299
- loading: P.loading,
300
- error: P.error,
301
- paginationMeta: P.paginationMeta,
299
+ rows: S.data,
300
+ loading: S.loading,
301
+ error: S.error,
302
+ paginationMeta: S.paginationMeta,
302
303
  refresh: () => {
303
- var C, A;
304
+ var C, L;
304
305
  const p = {
305
- search: g.value,
306
+ search: d.value,
306
307
  filters: _.value,
307
308
  sort: c.value,
308
309
  page: (C = v.value) == null ? void 0 : C.page,
309
- perPage: (A = v.value) == null ? void 0 : A.perPage,
310
- extraState: S.value,
311
- tabName: T.value
310
+ perPage: (L = v.value) == null ? void 0 : L.perPage,
311
+ extraState: T.value,
312
+ tabName: P.value
312
313
  };
313
- P.refresh(p);
314
+ S.refresh(p);
314
315
  }
315
316
  };
316
317
  }
@@ -323,7 +324,7 @@ function Ut(a, r) {
323
324
  }
324
325
  };
325
326
  }
326
- const Yt = { class: "shifl-column-manager__header" }, Qt = { class: "shifl-column-manager__title-wrapper" }, Xt = { class: "shifl-column-manager__title" }, en = { key: 0 }, tn = { key: 1 }, nn = { class: "shifl-column-manager__controls" }, rn = { class: "shifl-column-manager__controls-left" }, sn = { class: "shifl-column-manager__content" }, an = { class: "shifl-column-manager__list" }, on = ["draggable", "onDragstart", "onDragover", "onDrop"], ln = ["aria-label", "disabled"], un = ["checked", "disabled", "onChange"], cn = { class: "shifl-column-manager__label-text" }, fn = { class: "shifl-column-manager__footer" }, dn = /* @__PURE__ */ ze({
327
+ const tn = { class: "shifl-column-manager__header" }, nn = { class: "shifl-column-manager__title-wrapper" }, rn = { class: "shifl-column-manager__title" }, sn = { key: 0 }, an = { key: 1 }, on = { class: "shifl-column-manager__controls" }, ln = { class: "shifl-column-manager__controls-left" }, un = { class: "shifl-column-manager__content" }, cn = { class: "shifl-column-manager__list" }, fn = ["draggable", "onDragstart", "onDragover", "onDrop"], dn = ["aria-label", "disabled"], gn = ["checked", "disabled", "onChange"], hn = { class: "shifl-column-manager__label-text" }, pn = { class: "shifl-column-manager__footer" }, mn = /* @__PURE__ */ ze({
327
328
  __name: "GridColumnManager",
328
329
  props: {
329
330
  titlePrefix: {},
@@ -331,123 +332,123 @@ const Yt = { class: "shifl-column-manager__header" }, Qt = { class: "shifl-colum
331
332
  },
332
333
  emits: ["close", "toggle", "move", "toggleFreeze", "selectAll", "deselectAll", "restoreDefault"],
333
334
  setup(a, { emit: r }) {
334
- const g = a, _ = k(() => g.columns), c = r, v = b(null);
335
- function S(f) {
336
- var d, m;
337
- (d = g.columns[f]) != null && d.freeze || (m = g.columns[f]) != null && m.protected || (v.value = f);
335
+ const d = a, _ = k(() => d.columns), c = r, v = b(null);
336
+ function T(h) {
337
+ var u, m;
338
+ (u = d.columns[h]) != null && u.freeze || (m = d.columns[h]) != null && m.protected || (v.value = h);
338
339
  }
339
- function T(f) {
340
+ function P(h) {
340
341
  }
341
- function M(f) {
342
- v.value === null || v.value === f || (c("move", v.value, f), v.value = null);
342
+ function M(h) {
343
+ v.value === null || v.value === h || (c("move", v.value, h), v.value = null);
343
344
  }
344
- return (f, d) => (o(), l("div", {
345
+ return (h, u) => (o(), l("div", {
345
346
  class: "shifl-column-manager__backdrop",
346
- onClick: d[7] || (d[7] = U((m) => f.$emit("close"), ["self"]))
347
+ onClick: u[7] || (u[7] = q((m) => h.$emit("close"), ["self"]))
347
348
  }, [
348
- h("div", {
349
+ g("div", {
349
350
  class: "shifl-column-manager__dialog",
350
351
  role: "dialog",
351
352
  "aria-modal": "true",
352
- onClick: d[6] || (d[6] = U(() => {
353
+ onClick: u[6] || (u[6] = q(() => {
353
354
  }, ["stop"]))
354
355
  }, [
355
- h("header", Yt, [
356
- h("div", Qt, [
357
- h("h2", Xt, [
358
- a.titlePrefix ? (o(), l("span", en, L(a.titlePrefix), 1)) : z("", !0),
359
- a.titlePrefix ? (o(), l("span", tn, ">")) : z("", !0),
360
- d[8] || (d[8] = se("Edit Columns ", -1))
356
+ g("header", tn, [
357
+ g("div", nn, [
358
+ g("h2", rn, [
359
+ a.titlePrefix ? (o(), l("span", sn, $(a.titlePrefix), 1)) : D("", !0),
360
+ a.titlePrefix ? (o(), l("span", an, ">")) : D("", !0),
361
+ u[8] || (u[8] = se("Edit Columns ", -1))
361
362
  ])
362
363
  ]),
363
- h("button", {
364
+ g("button", {
364
365
  type: "button",
365
366
  class: "shifl-column-manager__close",
366
- onClick: d[0] || (d[0] = (m) => f.$emit("close"))
367
- }, [...d[9] || (d[9] = [
368
- h("span", null, "✕", -1)
367
+ onClick: u[0] || (u[0] = (m) => h.$emit("close"))
368
+ }, [...u[9] || (u[9] = [
369
+ g("span", null, "✕", -1)
369
370
  ])])
370
371
  ]),
371
- h("div", nn, [
372
- h("div", rn, [
373
- h("button", {
372
+ g("div", on, [
373
+ g("div", ln, [
374
+ g("button", {
374
375
  type: "button",
375
376
  class: "shifl-column-manager__link-button",
376
- onClick: d[1] || (d[1] = (m) => f.$emit("selectAll"))
377
+ onClick: u[1] || (u[1] = (m) => h.$emit("selectAll"))
377
378
  }, " Select All "),
378
- h("button", {
379
+ g("button", {
379
380
  type: "button",
380
381
  class: "shifl-column-manager__link-button",
381
- onClick: d[2] || (d[2] = (m) => f.$emit("deselectAll"))
382
+ onClick: u[2] || (u[2] = (m) => h.$emit("deselectAll"))
382
383
  }, " Deselect All ")
383
384
  ]),
384
- h("button", {
385
+ g("button", {
385
386
  type: "button",
386
387
  class: "shifl-column-manager__link-button shifl-column-manager__link-button--primary",
387
- onClick: d[3] || (d[3] = (m) => f.$emit("restoreDefault"))
388
+ onClick: u[3] || (u[3] = (m) => h.$emit("restoreDefault"))
388
389
  }, " Restore Default ")
389
390
  ]),
390
- h("div", sn, [
391
- h("ul", an, [
392
- (o(!0), l(N, null, E(_.value, (m, P) => (o(), l("li", {
391
+ g("div", un, [
392
+ g("ul", cn, [
393
+ (o(!0), l(x, null, V(_.value, (m, S) => (o(), l("li", {
393
394
  key: m.key,
394
395
  class: G(["shifl-column-manager__item", {
395
396
  "shifl-column-manager__item--disabled": m.freeze || m.protected
396
397
  }]),
397
398
  draggable: !m.freeze && !m.protected,
398
- onDragstart: (w) => S(P),
399
- onDragover: U((w) => void 0, ["prevent"]),
400
- onDrop: U((w) => M(P), ["prevent"])
399
+ onDragstart: (w) => T(S),
400
+ onDragover: q((w) => void 0, ["prevent"]),
401
+ onDrop: q((w) => M(S), ["prevent"])
401
402
  }, [
402
- h("button", {
403
+ g("button", {
403
404
  type: "button",
404
405
  class: G(["shifl-column-manager__drag-handle", {
405
406
  "shifl-column-manager__drag-handle--disabled": m.freeze || m.protected
406
407
  }]),
407
408
  "aria-label": `Move ${m.label}`,
408
409
  disabled: m.freeze || m.protected
409
- }, [...d[10] || (d[10] = [
410
- h("span", null, "⋮⋮", -1)
411
- ])], 10, ln),
412
- h("label", {
410
+ }, [...u[10] || (u[10] = [
411
+ g("span", null, "⋮⋮", -1)
412
+ ])], 10, dn),
413
+ g("label", {
413
414
  class: G(["shifl-column-manager__checkbox-label", {
414
415
  "shifl-column-manager__checkbox-label--disabled": m.freeze || m.protected
415
416
  }])
416
417
  }, [
417
- h("input", {
418
+ g("input", {
418
419
  type: "checkbox",
419
420
  class: "shifl-column-manager__checkbox",
420
421
  checked: m.visible,
421
422
  disabled: m.freeze || m.protected,
422
- onChange: (w) => f.$emit("toggle", m.key)
423
- }, null, 40, un),
424
- d[11] || (d[11] = h("span", { class: "shifl-column-manager__checkbox-custom" }, null, -1)),
425
- h("span", cn, L(m.label), 1)
423
+ onChange: (w) => h.$emit("toggle", m.key)
424
+ }, null, 40, gn),
425
+ u[11] || (u[11] = g("span", { class: "shifl-column-manager__checkbox-custom" }, null, -1)),
426
+ g("span", hn, $(m.label), 1)
426
427
  ], 2)
427
- ], 42, on))), 128))
428
+ ], 42, fn))), 128))
428
429
  ])
429
430
  ]),
430
- h("footer", fn, [
431
- h("button", {
431
+ g("footer", pn, [
432
+ g("button", {
432
433
  type: "button",
433
434
  class: "shifl-column-manager__button shifl-column-manager__button--primary",
434
- onClick: d[4] || (d[4] = (m) => f.$emit("close"))
435
+ onClick: u[4] || (u[4] = (m) => h.$emit("close"))
435
436
  }, " Update "),
436
- h("button", {
437
+ g("button", {
437
438
  type: "button",
438
439
  class: "shifl-column-manager__button shifl-column-manager__button--secondary",
439
- onClick: d[5] || (d[5] = (m) => f.$emit("close"))
440
+ onClick: u[5] || (u[5] = (m) => h.$emit("close"))
440
441
  }, " Cancel ")
441
442
  ])
442
443
  ])
443
444
  ]));
444
445
  }
445
- }), Y = (a, r) => {
446
- const g = a.__vccOpts || a;
446
+ }), U = (a, r) => {
447
+ const d = a.__vccOpts || a;
447
448
  for (const [_, c] of r)
448
- g[_] = c;
449
- return g;
450
- }, gn = /* @__PURE__ */ Y(dn, [["__scopeId", "data-v-40ca0ed0"]]), hn = { class: "shifl-grid__tooltip-content" }, pn = ["innerHTML"], mn = /* @__PURE__ */ ze({
449
+ d[_] = c;
450
+ return d;
451
+ }, vn = /* @__PURE__ */ U(mn, [["__scopeId", "data-v-40ca0ed0"]]), _n = { class: "shifl-grid__tooltip-content" }, yn = ["innerHTML"], bn = /* @__PURE__ */ ze({
451
452
  __name: "GridTooltip",
452
453
  props: {
453
454
  content: {},
@@ -456,59 +457,59 @@ const Yt = { class: "shifl-column-manager__header" }, Qt = { class: "shifl-colum
456
457
  isHtml: { type: Boolean }
457
458
  },
458
459
  setup(a) {
459
- const r = a, g = b(null), _ = b({}), c = k(() => r.content.includes(`
460
+ const r = a, d = b(null), _ = b({}), c = k(() => r.content.includes(`
460
461
  `)), v = k(() => c.value ? r.content.split(`
461
- `).filter((f) => f.trim().length > 0) : []), S = b("top"), T = b({});
462
+ `).filter((h) => h.trim().length > 0) : []), T = b("top"), P = b({});
462
463
  function M() {
463
- if (!r.triggerElement || !g.value) return;
464
- const f = r.triggerElement.getBoundingClientRect(), d = g.value.getBoundingClientRect(), m = window.innerWidth, P = window.innerHeight;
465
- let w = f.bottom + 8, u = f.left + window.scrollX;
466
- u + d.width > m - 16 && (u = m - d.width - 16), u < 16 && (u = 16), w + d.height > P - 16 ? (w = f.top - d.height - 8, S.value = "bottom") : S.value = "top", _.value = {
464
+ if (!r.triggerElement || !d.value) return;
465
+ const h = r.triggerElement.getBoundingClientRect(), u = d.value.getBoundingClientRect(), m = window.innerWidth, S = window.innerHeight;
466
+ let w = h.bottom + 8, f = h.left + window.scrollX;
467
+ f + u.width > m - 16 && (f = m - u.width - 16), f < 16 && (f = 16), w + u.height > S - 16 ? (w = h.top - u.height - 8, T.value = "bottom") : T.value = "top", _.value = {
467
468
  position: "fixed",
468
469
  top: `${w}px`,
469
- left: `${u}px`,
470
+ left: `${f}px`,
470
471
  zIndex: "10000"
471
472
  };
472
- const p = f.left + f.width / 2 - u;
473
- T.value = {
473
+ const p = h.left + h.width / 2 - f;
474
+ P.value = {
474
475
  left: `${p}px`
475
476
  };
476
477
  }
477
478
  return j(
478
479
  () => r.visible,
479
- async (f) => {
480
- f && (await He(), M());
480
+ async (h) => {
481
+ h && (await Re(), M());
481
482
  }
482
483
  ), de(() => {
483
- r.visible && He(() => M());
484
+ r.visible && Re(() => M());
484
485
  }), ge(() => {
485
- }), (f, d) => (o(), O(Re, { to: "body" }, [
486
+ }), (h, u) => (o(), Z(He, { to: "body" }, [
486
487
  a.visible ? (o(), l("div", {
487
488
  key: 0,
488
489
  ref_key: "tooltipRef",
489
- ref: g,
490
+ ref: d,
490
491
  class: "shifl-grid__tooltip",
491
- style: W(_.value)
492
+ style: K(_.value)
492
493
  }, [
493
- h("div", {
494
- class: G(["shifl-grid__tooltip-arrow", S.value]),
495
- style: W(T.value)
494
+ g("div", {
495
+ class: G(["shifl-grid__tooltip-arrow", T.value]),
496
+ style: K(P.value)
496
497
  }, null, 6),
497
- h("div", hn, [
498
+ g("div", _n, [
498
499
  a.isHtml ? (o(), l("div", {
499
500
  key: 0,
500
501
  innerHTML: a.content
501
- }, null, 8, pn)) : c.value ? (o(!0), l(N, { key: 1 }, E(v.value, (m, P) => (o(), l("div", {
502
- key: P,
502
+ }, null, 8, yn)) : c.value ? (o(!0), l(x, { key: 1 }, V(v.value, (m, S) => (o(), l("div", {
503
+ key: S,
503
504
  class: "shifl-grid__tooltip-line"
504
- }, L(m), 1))), 128)) : (o(), l(N, { key: 2 }, [
505
- se(L(a.content), 1)
505
+ }, $(m), 1))), 128)) : (o(), l(x, { key: 2 }, [
506
+ se($(a.content), 1)
506
507
  ], 64))
507
508
  ])
508
- ], 4)) : z("", !0)
509
+ ], 4)) : D("", !0)
509
510
  ]));
510
511
  }
511
- }), vn = /* @__PURE__ */ Y(mn, [["__scopeId", "data-v-239005f1"]]), _n = {}, yn = {
512
+ }), kn = /* @__PURE__ */ U(bn, [["__scopeId", "data-v-239005f1"]]), Cn = {}, Mn = {
512
513
  width: "14",
513
514
  height: "15",
514
515
  viewBox: "0 0 14 15",
@@ -516,24 +517,24 @@ const Yt = { class: "shifl-column-manager__header" }, Qt = { class: "shifl-colum
516
517
  xmlns: "http://www.w3.org/2000/svg",
517
518
  class: "shifl-smart-tracking-icon"
518
519
  };
519
- function bn(a, r) {
520
- return o(), l("svg", yn, [...r[0] || (r[0] = [
521
- h("path", {
520
+ function wn(a, r) {
521
+ return o(), l("svg", Mn, [...r[0] || (r[0] = [
522
+ g("path", {
522
523
  d: "M1.03223 9.27441C1.22778 9.27445 1.40954 9.32951 1.57812 9.43066L3.86523 10.8594C4.1957 11.0618 4.3916 11.4202 4.3916 11.8047C4.39151 12.189 4.19562 12.5467 3.86523 12.749L1.57812 14.1797C1.41642 14.2806 1.22754 14.334 1.03223 14.334V14.3408C0.465713 14.3408 0.000165713 13.8751 0 13.3086V10.3066C0.000236867 9.74022 0.465756 9.27443 1.03223 9.27441ZM1.01172 13.3018L3.3252 11.8916C3.32796 11.8884 3.3728 11.8374 3.37305 11.8047C3.37305 11.771 3.35218 11.737 3.3252 11.7168L1.03906 10.2871L1.01172 13.3018ZM6.07129 3.37305C6.35041 3.37318 6.5771 3.59977 6.57715 3.87891C6.57715 4.15809 6.35044 4.38463 6.07129 4.38477H5.05957C4.03708 4.38477 3.20433 5.06537 3.2041 5.90234C3.2041 6.73947 4.03694 7.4209 5.05957 7.4209H7.08301C8.66344 7.42096 9.95019 8.55525 9.9502 9.9502C9.95009 11.3451 8.66338 12.4794 7.08301 12.4795H6.07129C5.79202 12.4795 5.56543 12.2529 5.56543 11.9736C5.56548 11.6944 5.79205 11.4678 6.07129 11.4678H7.08301C8.10552 11.4677 8.93739 10.7872 8.9375 9.9502C8.93749 9.11311 8.10558 8.43267 7.08301 8.43262H5.05957C3.47908 8.43262 2.19238 7.29733 2.19238 5.90234C2.19259 4.50751 3.4792 3.37305 5.05957 3.37305H6.07129ZM10.7939 0C12.0694 0.000131868 13.2591 0.779675 13.7549 1.94043C14.6093 3.9666 13.0453 5.42741 11.9033 6.49316L11.8818 6.51367C11.7964 6.59308 11.711 6.67193 11.6289 6.75C11.4057 6.96444 11.1095 7.08195 10.7939 7.08203C10.4783 7.08203 10.1803 6.9642 9.95703 6.74902C9.86266 6.65937 9.76511 6.56666 9.66602 6.47363L9.66016 6.46875C8.53029 5.40836 6.98418 3.95585 7.83203 1.94238C8.32854 0.77953 9.51841 6.29203e-06 10.7939 0ZM10.7939 1.01172C9.91775 1.01173 9.10234 1.54537 8.76367 2.33789C8.22961 3.60525 9.04604 4.50453 10.3525 5.73145L10.4229 5.79688C10.5024 5.87104 10.5804 5.94604 10.6572 6.01953C10.7267 6.08617 10.861 6.08446 10.9277 6.02051L10.9307 6.01758C11.0223 5.93066 11.1172 5.84284 11.2129 5.75391C12.5356 4.51951 13.3612 3.61352 12.8223 2.33594C12.4849 1.54493 11.6691 1.0127 10.793 1.0127L10.7939 1.01172ZM10.7998 2.53027C11.1719 2.53041 11.4734 2.83199 11.4736 3.2041C11.4736 3.57637 11.172 3.87877 10.7998 3.87891C10.4275 3.87882 10.1221 3.57641 10.1221 3.2041C10.1223 2.8319 10.4207 2.53027 10.793 2.53027H10.7998Z",
523
524
  fill: "#05963F"
524
525
  }, null, -1)
525
526
  ])]);
526
527
  }
527
- const kn = /* @__PURE__ */ Y(_n, [["render", bn]]), Cn = {}, Mn = {
528
+ const Sn = /* @__PURE__ */ U(Cn, [["render", wn]]), Tn = {}, Pn = {
528
529
  width: "14",
529
530
  height: "10",
530
531
  viewBox: "0 0 14 10",
531
532
  fill: "none",
532
533
  xmlns: "http://www.w3.org/2000/svg"
533
534
  };
534
- function wn(a, r) {
535
- return o(), l("svg", Mn, [...r[0] || (r[0] = [
536
- h("path", {
535
+ function $n(a, r) {
536
+ return o(), l("svg", Pn, [...r[0] || (r[0] = [
537
+ g("path", {
537
538
  "fill-rule": "evenodd",
538
539
  "clip-rule": "evenodd",
539
540
  d: "M0 0.666667C0 0.298477 0.314186 2.98023e-08 0.701754 2.98023e-08H4.2807C4.66827 2.98023e-08 4.98246 0.298477 4.98246 0.666667C4.98246 1.03486 4.66827 1.33333 4.2807 1.33333H0.701754C0.314186 1.33333 0 1.03486 0 0.666667ZM10.0301 0.195262C10.3042 -0.0650874 10.7485 -0.0650874 11.0225 0.195262L13.1278 2.19526C13.4018 2.45561 13.4018 2.87772 13.1278 3.13807C12.8537 3.39842 12.4094 3.39842 12.1354 3.13807L11.2281 2.27614V8.66667C11.2281 9.03486 10.9139 9.33333 10.5263 9.33333C10.1387 9.33333 9.82456 9.03486 9.82456 8.66667V2.27614L8.91727 3.13807C8.64322 3.39842 8.19889 3.39842 7.92484 3.13807C7.65079 2.87772 7.65079 2.45561 7.92484 2.19526L10.0301 0.195262ZM0 4.66667C0 4.29848 0.314186 4 0.701754 4H5.61404C6.0016 4 6.31579 4.29848 6.31579 4.66667C6.31579 5.03486 6.0016 5.33333 5.61404 5.33333H0.701754C0.314186 5.33333 0 5.03486 0 4.66667ZM0 8.66667C0 8.29848 0.314186 8 0.701754 8H7.01754C7.40511 8 7.7193 8.29848 7.7193 8.66667C7.7193 9.03486 7.40511 9.33333 7.01754 9.33333H0.701754C0.314186 9.33333 0 9.03486 0 8.66667Z",
@@ -541,91 +542,91 @@ function wn(a, r) {
541
542
  }, null, -1)
542
543
  ])]);
543
544
  }
544
- const Sn = /* @__PURE__ */ Y(Cn, [["render", wn]]), Tn = {}, Pn = {
545
+ const Ln = /* @__PURE__ */ U(Tn, [["render", $n]]), An = {}, Nn = {
545
546
  width: "14",
546
547
  height: "10",
547
548
  viewBox: "0 0 14 10",
548
549
  fill: "none",
549
550
  xmlns: "http://www.w3.org/2000/svg"
550
551
  };
551
- function $n(a, r) {
552
- return o(), l("svg", Pn, [...r[0] || (r[0] = [
553
- h("path", {
552
+ function xn(a, r) {
553
+ return o(), l("svg", Nn, [...r[0] || (r[0] = [
554
+ g("path", {
554
555
  d: "M4.28125 8C4.66872 8.00011 4.98242 8.29887 4.98242 8.66699C4.98242 9.03511 4.66872 9.33387 4.28125 9.33398H0.702148C0.314581 9.33398 8.1338e-07 9.03518 0 8.66699C0 8.2988 0.31458 8 0.702148 8H4.28125ZM10.5264 0C10.9139 0 11.2285 0.298802 11.2285 0.666992V7.05762L12.1357 6.19531C12.4097 5.93519 12.8539 5.93524 13.1279 6.19531C13.402 6.45566 13.402 6.87832 13.1279 7.13867L11.0225 9.13867C10.7484 9.39867 10.3042 9.39886 10.0303 9.13867L7.9248 7.13867C7.65082 6.87834 7.65082 6.45565 7.9248 6.19531C8.19886 5.93496 8.64392 5.93496 8.91797 6.19531L9.8252 7.05762V0.666992C9.8252 0.298891 10.1389 0.000143144 10.5264 0ZM5.61426 4C6.00183 4 6.31641 4.2988 6.31641 4.66699C6.31641 5.03518 6.00183 5.33398 5.61426 5.33398H0.702148C0.314581 5.33398 6.77817e-07 5.03518 0 4.66699C0 4.2988 0.31458 4 0.702148 4H5.61426ZM7.01758 0C7.40515 0 7.71973 0.298802 7.71973 0.666992C7.71973 1.03518 7.40515 1.33398 7.01758 1.33398H0.702148C0.31458 1.33398 5.42254e-07 1.03518 0 0.666992C0 0.298802 0.31458 0 0.702148 0H7.01758Z",
555
556
  fill: "#1A6D9E"
556
557
  }, null, -1)
557
558
  ])]);
558
559
  }
559
- const Ln = /* @__PURE__ */ Y(Tn, [["render", $n]]), An = {}, Nn = {
560
+ const Rn = /* @__PURE__ */ U(An, [["render", xn]]), Hn = {}, zn = {
560
561
  width: "21",
561
562
  height: "13",
562
563
  viewBox: "0 0 21 13",
563
564
  fill: "none",
564
565
  xmlns: "http://www.w3.org/2000/svg"
565
566
  };
566
- function xn(a, r) {
567
- return o(), l("svg", Nn, [...r[0] || (r[0] = [
568
- h("path", {
567
+ function Dn(a, r) {
568
+ return o(), l("svg", zn, [...r[0] || (r[0] = [
569
+ g("path", {
569
570
  d: "M19.6426 4.61523C19.9311 4.61524 20.1317 4.90139 20.0342 5.17285L17.499 12.2246C17.4395 12.3899 17.2821 12.5 17.1064 12.5H1.5459C1.35628 12.5 1.19044 12.3719 1.14258 12.1885L0.0136719 7.83887C-0.0548101 7.575 0.14438 7.31738 0.416992 7.31738H12.6016L14.71 4.61523H19.6426ZM3.51465 8.82324C3.11322 8.82324 2.78728 9.15265 2.78711 9.55859C2.78711 9.96468 3.11312 10.2939 3.51465 10.2939C3.9161 10.2938 4.24121 9.96462 4.24121 9.55859C4.24104 9.15271 3.91599 8.82334 3.51465 8.82324ZM7.87695 8.82324C7.47553 8.82324 7.14958 9.15265 7.14941 9.55859C7.14941 9.96468 7.47542 10.2939 7.87695 10.2939C8.27846 10.2939 8.60352 9.96466 8.60352 9.55859C8.60335 9.15267 8.27835 8.82327 7.87695 8.82324ZM12.2393 8.82324C11.8378 8.82324 11.5119 9.15265 11.5117 9.55859C11.5117 9.96468 11.8377 10.2939 12.2393 10.2939C12.6407 10.2938 12.9658 9.96458 12.9658 9.55859C12.9657 9.15275 12.6405 8.82341 12.2393 8.82324ZM10.3291 3.67676C10.5591 3.67679 10.7459 3.86283 10.7461 4.09277V5.46582C10.746 5.69585 10.5591 5.88278 10.3291 5.88281H1.75C1.51993 5.88281 1.33309 5.69587 1.33301 5.46582V4.09277C1.3332 3.86282 1.52 3.67676 1.75 3.67676H10.3291ZM8.91406 0C9.14418 0 9.33105 0.186874 9.33105 0.416992V1.78906C9.33105 2.01918 9.14418 2.20605 8.91406 2.20605H3.2041C2.97398 2.20605 2.78711 2.01918 2.78711 1.78906V0.416992C2.78711 0.186874 2.97398 1.52829e-06 3.2041 0H8.91406Z",
570
571
  fill: "#9CA5B4"
571
572
  }, null, -1)
572
573
  ])]);
573
574
  }
574
- const rt = /* @__PURE__ */ Y(An, [["render", xn]]), Hn = {}, Rn = {
575
+ const lt = /* @__PURE__ */ U(Hn, [["render", Dn]]), En = {}, Vn = {
575
576
  width: "16",
576
577
  height: "16",
577
578
  viewBox: "0 0 16 16",
578
579
  fill: "none",
579
580
  xmlns: "http://www.w3.org/2000/svg"
580
581
  };
581
- function zn(a, r) {
582
- return o(), l("svg", Rn, [...r[0] || (r[0] = [
583
- h("path", {
582
+ function Bn(a, r) {
583
+ return o(), l("svg", Vn, [...r[0] || (r[0] = [
584
+ g("path", {
584
585
  d: "M7.99976 0.799561C11.9761 0.799561 15.1998 4.0234 15.2 7.99976C15.2 11.9762 11.9762 15.2 7.99976 15.2C4.0234 15.1998 0.799561 11.9761 0.799561 7.99976C0.799666 4.02346 4.02346 0.799666 7.99976 0.799561ZM7.99976 1.87964C4.61984 1.87974 1.87974 4.61984 1.87964 7.99976C1.87964 11.3798 4.61977 14.1198 7.99976 14.1199C11.3798 14.1199 14.1199 11.3798 14.1199 7.99976C14.1198 4.61977 11.3798 1.87964 7.99976 1.87964ZM7.9978 6.91968C8.27087 6.91973 8.49698 7.12223 8.53296 7.3855L8.53784 7.45874L8.53979 11.4197C8.5399 11.7178 8.29882 11.9595 8.00073 11.9597C7.72754 11.9599 7.50169 11.7572 7.46558 11.4939L7.46069 11.4207L7.45776 7.45972C7.45757 7.16153 7.69962 6.91987 7.9978 6.91968ZM8.00073 4.40112C8.39742 4.40137 8.71923 4.72319 8.71948 5.11987C8.71948 5.51677 8.39757 5.83935 8.00073 5.8396C7.60368 5.8396 7.28101 5.51692 7.28101 5.11987C7.28126 4.72304 7.60384 4.40112 8.00073 4.40112Z",
585
586
  fill: "#69758C"
586
587
  }, null, -1)
587
588
  ])]);
588
589
  }
589
- const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid relative" }, Vn = { class: "shifl-grid__controls" }, Bn = { class: "shifl-grid__table" }, Gn = ["onClick"], In = { class: "shifl-grid__header-content" }, On = {
590
+ const Gn = /* @__PURE__ */ U(En, [["render", Bn]]), In = { class: "shifl-grid relative" }, On = { class: "shifl-grid__controls" }, Zn = { class: "shifl-grid__table" }, jn = ["onClick"], Fn = { class: "shifl-grid__header-content" }, Kn = {
590
591
  key: 0,
591
592
  class: "shifl-grid__header-label"
592
- }, Zn = {
593
+ }, Wn = {
593
594
  key: 1,
594
595
  class: "shifl-grid__sort-icon"
595
- }, jn = { key: 0 }, Fn = ["colspan"], Kn = {
596
+ }, Jn = { key: 0 }, qn = ["colspan"], Un = {
596
597
  key: 0,
597
598
  class: "shifl-grid__smart-tracking-icon"
598
- }, Wn = ["onClick"], Jn = { key: 0 }, qn = ["innerHTML"], Un = {
599
+ }, Yn = ["onClick"], Qn = { key: 0 }, Xn = ["innerHTML"], er = {
599
600
  key: 2,
600
601
  class: "shifl-grid__composite-cell"
601
- }, Yn = {
602
+ }, tr = {
602
603
  key: 3,
603
604
  class: "shifl-grid__type-cell"
604
- }, Qn = {
605
+ }, nr = {
605
606
  key: 0,
606
607
  class: "shifl-grid__container-badge"
607
- }, Xn = {
608
+ }, rr = {
608
609
  key: 0,
609
610
  class: "shifl-grid__cell-blank"
610
- }, er = {
611
+ }, sr = {
611
612
  key: 1,
612
613
  class: "shifl-grid__tags-cell"
613
- }, tr = { class: "shifl-grid__tags-wrapper" }, nr = ["onMouseenter"], rr = {
614
+ }, ir = { class: "shifl-grid__tags-wrapper" }, ar = ["onMouseenter"], or = {
614
615
  key: 5,
615
616
  class: "shifl-grid__chips-container"
616
- }, sr = {
617
+ }, lr = {
617
618
  key: 6,
618
619
  class: "shifl-grid__truncated-cell"
619
- }, ir = ["onMouseenter"], ar = ["onMouseenter"], or = ["href"], lr = {
620
+ }, ur = ["onMouseenter"], cr = ["onMouseenter"], fr = ["href"], dr = {
620
621
  key: 8,
621
622
  class: "shifl-grid__progress-cell"
622
- }, ur = { class: "shifl-grid__progress-bar" }, cr = { class: "shifl-grid__progress-text" }, fr = {
623
+ }, gr = { class: "shifl-grid__progress-bar" }, hr = { class: "shifl-grid__progress-text" }, pr = {
623
624
  key: 0,
624
625
  class: "shifl-grid__pagination"
625
- }, dr = { class: "shifl-grid__pagination-left" }, gr = { class: "shifl-grid__pagination-range" }, hr = { class: "shifl-grid__pagination-range-numbers" }, pr = { class: "shifl-grid__pagination-right" }, mr = { class: "shifl-grid__pagination-rows" }, vr = ["value", "disabled"], _r = { class: "shifl-grid__pagination-nav" }, yr = ["disabled"], br = { class: "shifl-grid__pagination-pages" }, kr = ["disabled", "onClick"], Cr = {
626
+ }, mr = { class: "shifl-grid__pagination-left" }, vr = { class: "shifl-grid__pagination-range" }, _r = { class: "shifl-grid__pagination-range-numbers" }, yr = { class: "shifl-grid__pagination-right" }, br = { class: "shifl-grid__pagination-rows" }, kr = ["value", "disabled"], Cr = { class: "shifl-grid__pagination-nav" }, Mr = ["disabled"], wr = { class: "shifl-grid__pagination-pages" }, Sr = ["disabled", "onClick"], Tr = {
626
627
  key: 1,
627
628
  class: "shifl-grid__pagination-ellipsis"
628
- }, Mr = ["disabled"], wr = ["onClick"], Sr = ["innerHTML"], Tr = /* @__PURE__ */ ze({
629
+ }, Pr = ["disabled"], $r = ["onClick"], Lr = ["innerHTML"], Ar = /* @__PURE__ */ ze({
629
630
  __name: "ShiflGrid",
630
631
  props: {
631
632
  config: {},
@@ -634,32 +635,35 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
634
635
  },
635
636
  emits: ["action-click", "search-change", "pagination-change"],
636
637
  setup(a, { emit: r }) {
637
- var tt, nt;
638
- const g = a, _ = r, c = k(() => jt(g.config)), v = b(g.search), S = b(c.value.filters), T = b(c.value.sort), M = b({
639
- page: ((tt = c.value.paginationMeta) == null ? void 0 : tt.currentPage) || 1,
640
- perPage: ((nt = c.value.paginationMeta) == null ? void 0 : nt.perPage) || 20
641
- }), f = Ut(c.value, {
638
+ var rt, st, it, at, ot;
639
+ const d = a, _ = r, c = k(() => Jt(d.config)), v = b(d.search), T = b(c.value.filters), P = b(c.value.sort), M = b({
640
+ page: ((rt = c.value.paginationMeta) == null ? void 0 : rt.currentPage) || 1,
641
+ perPage: ((st = c.value.paginationMeta) == null ? void 0 : st.perPage) || 20
642
+ }), h = b(
643
+ typeof ((it = c.value.apiConfig) == null ? void 0 : it.additionalParams) == "function" || (ot = (at = c.value.apiConfig) == null ? void 0 : at.additionalParams) == null ? void 0 : ot.tabName
644
+ ), u = en(c.value, {
642
645
  search: v,
643
- filters: S,
644
- sort: T,
645
- pagination: M
646
- }), d = k(() => c.value.columns.filter((e) => !e.smartTrackingColumn)), {
647
- columns: m,
648
- visibleColumns: P,
649
- toggleColumnVisibility: w,
650
- setAllVisible: u,
651
- toggleFreeze: p,
652
- moveColumn: C,
646
+ filters: T,
647
+ sort: P,
648
+ pagination: M,
649
+ tabName: h
650
+ }), m = k(() => c.value.columns.filter((e) => !e.smartTrackingColumn)), {
651
+ columns: S,
652
+ visibleColumns: w,
653
+ toggleColumnVisibility: f,
654
+ setAllVisible: p,
655
+ toggleFreeze: C,
656
+ moveColumn: L,
653
657
  resetColumns: A
654
- } = Ft(d.value), { sort: $, setSort: x, applySort: he } = Kt(c.value.sort), { applyGlobalFilter: ie } = Wt(), { menuState: V, openMenu: F, closeMenu: Q } = Jt(), X = b(!1), Z = b({}), ae = b(null), De = b(null), pe = b(null), me = b(!1), Ee = b(""), ve = b(null), _e = b(!1), at = b({});
658
+ } = qt(m.value), { sort: N, setSort: he, applySort: ie } = Ut(c.value.sort), { applyGlobalFilter: ee } = Yt(), { menuState: H, openMenu: ae, closeMenu: Y } = Qt(), I = b(!1), oe = b({}), De = b(null), Ee = b(null), pe = b(null), me = b(!1), Ve = b(""), ve = b(null), _e = b(!1), ft = b({});
655
659
  b({});
656
- const ee = b(
660
+ const Q = b(
657
661
  {}
658
662
  );
659
663
  j(
660
664
  () => c.value.filters,
661
665
  (e) => {
662
- S.value = e;
666
+ T.value = e;
663
667
  },
664
668
  { deep: !0 }
665
669
  ), j(
@@ -672,84 +676,96 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
672
676
  () => c.value.columns,
673
677
  (e) => {
674
678
  const t = e.filter((n) => !n.smartTrackingColumn);
675
- m.value = [...t];
679
+ S.value = [...t];
676
680
  },
677
681
  { deep: !0 }
678
682
  ), j(
679
683
  () => c.value.sort,
680
684
  (e) => {
681
- e && ($.value = e, T.value = e);
685
+ e && (N.value = e, P.value = e);
686
+ },
687
+ { deep: !0 }
688
+ ), j(
689
+ () => {
690
+ var e;
691
+ return (e = c.value.apiConfig) == null ? void 0 : e.additionalParams;
692
+ },
693
+ (e) => {
694
+ if (e && typeof e != "function") {
695
+ const t = e;
696
+ t.tabName !== void 0 && h.value !== t.tabName && (h.value = t.tabName);
697
+ }
682
698
  },
683
699
  { deep: !0 }
684
700
  ), j(
685
- () => g.search,
701
+ () => d.search,
686
702
  (e, t) => {
687
703
  var n;
688
704
  if (v.value = e, c.value.searchMode === "server")
689
705
  _("search-change", e || "");
690
706
  else if (c.value.searchMode === "client" && e !== t) {
691
- const s = ((n = R.value) == null ? void 0 : n.perPage) || 20;
707
+ const s = ((n = z.value) == null ? void 0 : n.perPage) || 20;
692
708
  M.value = { page: 1, perPage: s }, _("pagination-change", 1, s);
693
709
  }
694
710
  },
695
711
  { immediate: !0 }
696
712
  ), j(
697
- () => $.value,
713
+ () => N.value,
698
714
  (e) => {
699
- T.value = e;
715
+ P.value = e;
700
716
  }
701
717
  );
702
- const Ve = k(() => f.rows.value || []), ye = k(() => {
718
+ const ye = k(() => u.rows.value || []), be = k(() => {
703
719
  if ((c.value.searchMode || "client") === "server")
704
- return Ve.value;
705
- const t = g.search || "";
706
- return ie(Ve.value, c.value.search, t);
707
- }), be = k(() => {
720
+ return ye.value;
721
+ const t = d.search || "";
722
+ return ee(ye.value, c.value.search, t);
723
+ }), ke = k(() => {
708
724
  var t;
709
- return (c.value.searchMode || "client") === "client" ? ye.value.length : ((t = f.paginationMeta.value) == null ? void 0 : t.total) || 0;
710
- }), ke = k(() => (c.value.searchMode || "client") === "server" ? ye.value : he(ye.value)), Be = k(() => {
725
+ return (c.value.searchMode || "client") === "client" ? be.value.length : ((t = u.paginationMeta.value) == null ? void 0 : t.total) || 0;
726
+ }), Ce = k(() => (c.value.searchMode || "client") === "server" ? be.value : ie(be.value)), Be = k(() => {
711
727
  if ((c.value.searchMode || "client") === "server")
712
- return ke.value;
713
- const t = R.value;
728
+ return Ce.value;
729
+ const t = z.value;
714
730
  if (!t || !t.show)
715
- return ke.value;
731
+ return Ce.value;
716
732
  const n = t.perPage || 20, i = ((t.currentPage || 1) - 1) * n, y = i + n;
717
- return ke.value.slice(i, y);
718
- }), R = k(() => {
733
+ return Ce.value.slice(i, y);
734
+ }), z = k(() => {
719
735
  var e;
720
- return c.value.searchMode === "server" && f.paginationMeta.value ? {
736
+ return c.value.searchMode === "server" && u.paginationMeta.value ? {
721
737
  show: !0,
722
738
  // Default to showing pagination
723
- ...f.paginationMeta.value,
724
- currentPage: ((e = M.value) == null ? void 0 : e.page) || f.paginationMeta.value.currentPage || 1
739
+ ...u.paginationMeta.value,
740
+ currentPage: ((e = M.value) == null ? void 0 : e.page) || u.paginationMeta.value.currentPage || 1
725
741
  } : c.value.paginationMeta;
726
- }), J = k(() => g.loading !== void 0 ? g.loading : f.loading.value), ot = k(() => {
742
+ }), W = k(() => d.loading !== void 0 ? d.loading : u.loading.value), dt = k(() => {
727
743
  var e;
728
- return ((e = R.value) == null ? void 0 : e.perPage) === 100;
729
- }), lt = k(() => {
744
+ return ((e = z.value) == null ? void 0 : e.perPage) === 100;
745
+ }), gt = k(() => {
730
746
  var e;
731
- return ((e = R.value) == null ? void 0 : e.perPage) || 10;
747
+ return ((e = z.value) == null ? void 0 : e.perPage) || 10;
732
748
  }), Ge = k(() => {
733
- const e = R.value;
749
+ const e = z.value;
734
750
  if (!e || e.show === !1)
735
751
  return { from: 0, to: 0 };
736
- const t = be.value, n = e.perPage || 20, s = e.currentPage || 1;
752
+ const t = ke.value, n = e.perPage || 20, s = e.currentPage || 1;
737
753
  if ((c.value.searchMode || "client") === "server" && e.from !== void 0 && e.to !== void 0)
738
754
  return { from: e.from, to: e.to };
739
- const y = (s - 1) * n + 1, H = Math.min(s * n, t);
740
- return t === 0 ? { from: 0, to: 0 } : { from: y, to: H };
741
- }), q = k(() => {
755
+ const y = (s - 1) * n + 1, R = Math.min(s * n, t);
756
+ return t === 0 ? { from: 0, to: 0 } : { from: y, to: R };
757
+ }), J = k(() => {
742
758
  var e;
743
- return ((e = R.value) == null ? void 0 : e.currentPage) || 1;
744
- }), Ce = k(() => {
745
- const e = R.value;
759
+ return ((e = z.value) == null ? void 0 : e.currentPage) || 1;
760
+ }), Me = k(() => {
761
+ const e = z.value;
746
762
  if (!e || e.show === !1) return 1;
747
- const t = be.value;
763
+ const t = ke.value;
748
764
  if (t === 0) return 1;
749
765
  const n = e.perPage || 20, s = Math.ceil(t / n);
750
766
  return Math.max(1, s);
751
- }), Ie = k(() => q.value <= 1), Oe = k(() => q.value >= Ce.value), ut = k(() => {
752
- const e = Ce.value, t = q.value, n = [];
767
+ }), Ie = k(() => J.value <= 1), Oe = k(() => J.value >= Me.value), ht = k(() => {
768
+ const e = Me.value, t = J.value, n = [];
753
769
  if (e <= 7)
754
770
  for (let s = 1; s <= e; s++)
755
771
  n.push(s);
@@ -769,42 +785,42 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
769
785
  }
770
786
  return n;
771
787
  });
772
- function ct(e) {
788
+ function pt(e) {
773
789
  var n;
774
- if (e < 1 || e > Ce.value || e === q.value || J.value) return;
775
- const t = ((n = R.value) == null ? void 0 : n.perPage) || 20;
790
+ if (e < 1 || e > Me.value || e === J.value || W.value) return;
791
+ const t = ((n = z.value) == null ? void 0 : n.perPage) || 20;
776
792
  M.value = { page: e, perPage: t }, _("pagination-change", e, t);
777
793
  }
778
- function ft() {
794
+ function mt() {
779
795
  var n;
780
- if (Ie.value || J.value) return;
781
- const e = ((n = R.value) == null ? void 0 : n.perPage) || 20, t = q.value - 1;
796
+ if (Ie.value || W.value) return;
797
+ const e = ((n = z.value) == null ? void 0 : n.perPage) || 20, t = J.value - 1;
782
798
  M.value = { page: t, perPage: e }, _("pagination-change", t, e);
783
799
  }
784
- function dt() {
800
+ function vt() {
785
801
  var n;
786
- if (Oe.value || J.value) return;
787
- const e = ((n = R.value) == null ? void 0 : n.perPage) || 20, t = q.value + 1;
802
+ if (Oe.value || W.value) return;
803
+ const e = ((n = z.value) == null ? void 0 : n.perPage) || 20, t = J.value + 1;
788
804
  M.value = { page: t, perPage: e }, _("pagination-change", t, e);
789
805
  }
790
- function gt(e) {
806
+ function _t(e) {
791
807
  var s;
792
- if (J.value) return;
808
+ if (W.value) return;
793
809
  const t = e.target, n = parseInt(t.value, 10);
794
- n && n !== (((s = R.value) == null ? void 0 : s.perPage) || 20) && (M.value = { page: 1, perPage: n }, _("pagination-change", 1, n));
810
+ n && n !== (((s = z.value) == null ? void 0 : s.perPage) || 20) && (M.value = { page: 1, perPage: n }, _("pagination-change", 1, n));
795
811
  }
796
- const ht = k(() => {
812
+ const yt = k(() => {
797
813
  const e = c.value.columns.find((n) => n.smartTrackingColumn);
798
814
  if (!(e != null && e.smartTrackingColumn)) return !1;
799
815
  const t = e.smartTrackingColumn.dataKey;
800
- return c.value.rows.some((n) => {
816
+ return ye.value.some((n) => {
801
817
  const s = n[t];
802
818
  return s === !0 || s === 1 || s === "true" || s === "1";
803
819
  });
804
- }), Me = k(() => c.value.columns.find((e) => e.smartTrackingColumn)), te = k(() => {
820
+ }), we = k(() => c.value.columns.find((e) => e.smartTrackingColumn)), X = k(() => {
805
821
  var n;
806
- const e = P.value.filter((s) => !s.smartTrackingColumn);
807
- if (ht.value && Me.value) {
822
+ const e = w.value.filter((s) => !s.smartTrackingColumn);
823
+ if (yt.value && we.value) {
808
824
  const s = {
809
825
  key: "_smart_tracking",
810
826
  label: "",
@@ -815,35 +831,35 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
815
831
  visible: !0,
816
832
  protected: !0,
817
833
  sortable: !1,
818
- width: ((n = Me.value.smartTrackingColumn) == null ? void 0 : n.width) || "36px",
819
- smartTrackingColumn: Me.value.smartTrackingColumn,
834
+ width: ((n = we.value.smartTrackingColumn) == null ? void 0 : n.width) || "36px",
835
+ smartTrackingColumn: we.value.smartTrackingColumn,
820
836
  cellType: "icon"
821
837
  }, i = e.findIndex((y) => y.key === "ref");
822
838
  i >= 0 ? e.splice(i, 0, s) : e.unshift(s);
823
839
  }
824
840
  const t = e.find((s) => s.key === "ref");
825
841
  return t && (t.freeze = !0, t.protected = !0), e;
826
- }), pt = k(() => {
842
+ }), bt = k(() => {
827
843
  let e = 0;
828
844
  const t = {};
829
- for (const n of te.value) {
845
+ for (const n of X.value) {
830
846
  n.freeze && (t[n.key] = e);
831
847
  const s = parseInt(n.width ?? "160", 10);
832
848
  Number.isNaN(s) || (e += s);
833
849
  }
834
850
  return t;
835
851
  }), Ze = b(0);
836
- function mt(e) {
852
+ function kt(e) {
837
853
  const t = e.target;
838
854
  Ze.value = t.scrollLeft;
839
855
  }
840
- function vt(e) {
841
- const t = m.value.find((n) => n.key === e);
842
- !(t != null && t.sortable) || ue(t) || Ae(t) || x(e);
856
+ function Ct(e) {
857
+ const t = S.value.find((n) => n.key === e);
858
+ !(t != null && t.sortable) || ue(t) || Ae(t) || he(e);
843
859
  }
844
- function we(e, t) {
860
+ function Se(e, t) {
845
861
  if (e == null || e === "" || e === void 0)
846
- return oe(t.blankStyle);
862
+ return te(t.blankStyle);
847
863
  const n = t.cellType;
848
864
  if (Array.isArray(n)) {
849
865
  const s = n.find((i) => typeof i == "string" && i !== "icon");
@@ -865,7 +881,7 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
865
881
  return typeof e == "object" ? JSON.stringify(e) : String(e);
866
882
  }
867
883
  }
868
- function oe(e) {
884
+ function te(e) {
869
885
  switch (e) {
870
886
  case "dash":
871
887
  return "--";
@@ -909,16 +925,16 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
909
925
  function We(e) {
910
926
  return typeof e == "boolean" ? e ? "Yes" : "No" : e === 1 || e === "1" || e === "true" || e === "True" ? "Yes" : e === 0 || e === "0" || e === "false" || e === "False" ? "No" : String(e);
911
927
  }
912
- function _t(e) {
928
+ function Mt(e) {
913
929
  if (typeof e == "number")
914
930
  return Math.min(100, Math.max(0, e));
915
931
  const t = Number(e);
916
932
  return Number.isNaN(t) ? 0 : Math.min(100, Math.max(0, t));
917
933
  }
918
934
  function Je(e) {
919
- return typeof e == "string" && e.toLowerCase() === "ocean", rt;
935
+ return typeof e == "string" && e.toLowerCase() === "ocean", lt;
920
936
  }
921
- function yt(e) {
937
+ function wt(e) {
922
938
  const t = e.toLowerCase();
923
939
  return ["supplier", "suppliers", "po", "pos", "product_description"].includes(t);
924
940
  }
@@ -927,21 +943,21 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
927
943
  const t = e.key.toLowerCase();
928
944
  return t === "tag" || t === "tags";
929
945
  }
930
- function bt(e) {
946
+ function St(e) {
931
947
  return e.cellType === "status" ? !0 : e.key.toLowerCase() === "status";
932
948
  }
933
- function kt(e) {
949
+ function Tt(e) {
934
950
  return e.cellType === "icon" ? !0 : e.key.toLowerCase() === "type";
935
951
  }
936
- function Ct(e) {
952
+ function Pt(e) {
937
953
  return Array.isArray(e.cellType) && e.cellType.length > 0;
938
954
  }
939
- function Mt(e) {
955
+ function $t(e) {
940
956
  return Array.isArray(e.cellType) ? e.cellType.filter((t) => typeof t == "string") : e.cellType && typeof e.cellType == "string" ? [e.cellType] : [];
941
957
  }
942
958
  function Ue(e, t, n) {
943
959
  if (e == null || e === "" || e === void 0)
944
- return oe(n.blankStyle);
960
+ return te(n.blankStyle);
945
961
  switch (t) {
946
962
  case "number":
947
963
  return je(e);
@@ -956,7 +972,7 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
956
972
  return typeof e == "object" ? JSON.stringify(e) : String(e);
957
973
  }
958
974
  }
959
- function wt(e) {
975
+ function Lt(e) {
960
976
  return {
961
977
  number: "shifl-grid__composite-number",
962
978
  currency: "shifl-grid__composite-currency",
@@ -965,11 +981,12 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
965
981
  text: "shifl-grid__composite-text"
966
982
  }[e] || "shifl-grid__composite-text";
967
983
  }
968
- function St(e, t) {
984
+ function At(e, t) {
969
985
  if (e == null || e === "")
970
- return oe(t.blankStyle);
986
+ return te(t.blankStyle);
971
987
  if (Array.isArray(e)) {
972
- if (e.length === 0) return "";
988
+ if (e.length === 0)
989
+ return te(t.blankStyle);
973
990
  const n = e.join(", ");
974
991
  return Ye(n, 45);
975
992
  }
@@ -978,17 +995,17 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
978
995
  function Ye(e, t) {
979
996
  return e.length <= t ? e : e.substring(0, t) + "...";
980
997
  }
981
- function Se(e) {
998
+ function Te(e) {
982
999
  const t = e.toLowerCase();
983
1000
  return ["po", "pos", "supplier", "suppliers", "tag", "tags"].includes(t);
984
1001
  }
985
- function Tt(e, t) {
986
- return e == null || Se(t) ? !1 : Array.isArray(e) ? e.length === 0 ? !1 : e.join(", ").length > 30 : typeof e == "string" ? e.length > 30 : !1;
1002
+ function Nt(e, t) {
1003
+ return e == null || Te(t) ? !1 : Array.isArray(e) ? e.length === 0 ? !1 : e.join(", ").length > 30 : typeof e == "string" ? e.length > 30 : !1;
987
1004
  }
988
- function Pt(e) {
1005
+ function xt(e) {
989
1006
  return e == null ? !1 : Array.isArray(e) ? e.length === 0 ? !1 : e.join(", ").length > 45 : typeof e == "string" ? e.length > 45 : !1;
990
1007
  }
991
- function $t(e) {
1008
+ function Rt(e) {
992
1009
  if (e == null) return 0;
993
1010
  if (Array.isArray(e)) {
994
1011
  if (e.length === 0 || e.join(", ").length <= 45) return 0;
@@ -1004,21 +1021,21 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
1004
1021
  }
1005
1022
  return typeof e == "string" && e.length > 45 ? 1 : 0;
1006
1023
  }
1007
- function Te(e, t, n, s) {
1024
+ function Pe(e, t, n, s) {
1008
1025
  let i = "", y = !1;
1009
- const H = te.value.find((B) => B.key === e);
1010
- if (H && qe(H)) {
1026
+ const R = X.value.find((B) => B.key === e);
1027
+ if (R && qe(R)) {
1011
1028
  const B = Qe(n);
1012
- B.length > 0 && (y = !0, i = B.map((K) => `<span class="shifl-grid__tooltip-badge" style="border-left-color: ${Xe(K)} !important">${K.name}</span>`).join(""));
1029
+ B.length > 0 && (y = !0, i = B.map((F) => `<span class="shifl-grid__tooltip-badge" style="border-left-color: ${tt(F)} !important">${F.name}</span>`).join(""));
1013
1030
  } else Array.isArray(n) ? n.length > 0 && (i = n.join(`
1014
1031
  `)) : n != null && (i = String(n));
1015
- Ee.value = i, _e.value = y, ve.value = s, me.value = !0;
1032
+ Ve.value = i, _e.value = y, ve.value = s, me.value = !0;
1016
1033
  }
1017
- function Pe() {
1034
+ function $e() {
1018
1035
  me.value = !1, ve.value = null, _e.value = !1;
1019
1036
  }
1020
- function Lt(e, t, n) {
1021
- n && (at.value[`${e}-${t}`] = n);
1037
+ function Ht(e, t, n) {
1038
+ n && (ft.value[`${e}-${t}`] = n);
1022
1039
  }
1023
1040
  function le(e) {
1024
1041
  return e == null ? [] : Array.isArray(e) ? e.map((t) => typeof t == "object" && t !== null && "name" in t ? String(t.name) : String(t)).filter((t) => t.length > 0) : typeof e == "string" ? e.split(",").map((t) => t.trim()).filter((t) => t.length > 0) : [String(e)];
@@ -1032,49 +1049,49 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
1032
1049
  color: void 0
1033
1050
  }).filter((t) => t.name.length > 0) : typeof e == "string" ? e.split(",").map((t) => t.trim()).filter((t) => t.length > 0).map((t) => ({ name: t, color: void 0 })) : [{ name: String(e), color: void 0 }];
1034
1051
  }
1035
- function $e(e, t, n) {
1052
+ function Xe(e, t, n) {
1036
1053
  const s = le(e);
1037
1054
  if (s.length === 0) return [];
1038
1055
  const i = `${t}-${n}`;
1039
- if (ee.value[i])
1040
- return ee.value[i];
1041
- const y = 130, H = 8, B = 4;
1042
- let K = 0;
1043
- const I = [];
1056
+ if (Q.value[i])
1057
+ return Q.value[i];
1058
+ const y = 130, R = 8, B = 4;
1059
+ let F = 0;
1060
+ const O = [];
1044
1061
  for (const ne of s) {
1045
- const re = ne.length * 8 + H + B;
1046
- if (K + re > y && I.length > 0)
1062
+ const re = ne.length * 8 + R + B;
1063
+ if (F + re > y && O.length > 0)
1047
1064
  break;
1048
- I.push(ne), K += re;
1065
+ O.push(ne), F += re;
1049
1066
  }
1050
- return ee.value[i] = I, I;
1067
+ return Q.value[i] = O, O;
1051
1068
  }
1052
- function At(e, t, n) {
1069
+ function et(e, t, n) {
1053
1070
  const s = Qe(e);
1054
1071
  if (s.length === 0) return [];
1055
1072
  const i = `${t}-${n}-objects`;
1056
- if (ee.value[i])
1057
- return ee.value[i];
1058
- const y = 130, H = 8, B = 4;
1059
- let K = 0;
1060
- const I = [];
1073
+ if (Q.value[i])
1074
+ return Q.value[i];
1075
+ const y = 130, R = 8, B = 4;
1076
+ let F = 0;
1077
+ const O = [];
1061
1078
  for (const ne of s) {
1062
- const re = ne.name.length * 8 + H + B;
1063
- if (K + re > y && I.length > 0)
1079
+ const re = ne.name.length * 8 + R + B;
1080
+ if (F + re > y && O.length > 0)
1064
1081
  break;
1065
- I.push(ne), K += re;
1082
+ O.push(ne), F += re;
1066
1083
  }
1067
- return ee.value[i] = I, I;
1084
+ return Q.value[i] = O, O;
1068
1085
  }
1069
- function Nt(e, t, n) {
1070
- const s = le(e), i = $e(e, t, n);
1086
+ function zt(e, t, n) {
1087
+ const s = le(e), i = Xe(e, t, n);
1071
1088
  return s.length > i.length;
1072
1089
  }
1073
- function xt(e, t, n) {
1074
- const s = le(e), i = $e(e, t, n);
1090
+ function Dt(e, t, n) {
1091
+ const s = le(e), i = Xe(e, t, n);
1075
1092
  return s.length - i.length;
1076
1093
  }
1077
- function Ht(e) {
1094
+ function Et(e) {
1078
1095
  const t = e.toLowerCase(), n = {
1079
1096
  "high priority": "var(--shifl-color-error-r70)",
1080
1097
  express: "var(--shifl-color-primary-b80)",
@@ -1092,12 +1109,12 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
1092
1109
  for (const [s, i] of Object.entries(n))
1093
1110
  if (t.includes(s) || s.includes(t))
1094
1111
  return i;
1095
- return Rt(e);
1112
+ return Vt(e);
1096
1113
  }
1097
- function Xe(e) {
1098
- return e.color && e.color !== "" ? e.color : Ht(e.name);
1114
+ function tt(e) {
1115
+ return e.color && e.color !== "" ? e.color : Et(e.name);
1099
1116
  }
1100
- function Rt(e) {
1117
+ function Vt(e) {
1101
1118
  let t = 0;
1102
1119
  for (let s = 0; s < e.length; s++)
1103
1120
  t = e.charCodeAt(s) + ((t << 5) - t);
@@ -1119,19 +1136,19 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
1119
1136
  minWidth: e.width ?? "160px"
1120
1137
  } }, i = Ze.value > 0;
1121
1138
  if (e.freeze) {
1122
- const y = pt.value[e.key] ?? 0;
1139
+ const y = bt.value[e.key] ?? 0;
1123
1140
  s.position = "sticky", s.left = `${y}px`, s.background = "#ffffff", s.boxShadow = i ? "2px 0 6px rgba(0, 0, 0, 0.12)" : "none", s.zIndex = t ? 40 : 10;
1124
1141
  }
1125
1142
  return t && (s.position = "sticky", s.top = "0px"), s;
1126
1143
  }
1127
- const zt = k(() => m.value.filter((e) => !e.smartTrackingColumn));
1144
+ const Bt = k(() => S.value.filter((e) => !e.smartTrackingColumn));
1128
1145
  function ue(e) {
1129
1146
  return !!e.actionColumn;
1130
1147
  }
1131
1148
  function Ae(e) {
1132
1149
  return !!e.smartTrackingColumn;
1133
1150
  }
1134
- function Dt(e, t) {
1151
+ function Gt(e, t) {
1135
1152
  if (!e.smartTrackingColumn) return !1;
1136
1153
  const n = e.smartTrackingColumn.dataKey, s = t[n];
1137
1154
  if (s === !0 || s === 1) return !0;
@@ -1146,54 +1163,54 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
1146
1163
  const n = e.actionColumn.icon;
1147
1164
  return n ? typeof n == "function" ? n(t) : n : null;
1148
1165
  }
1149
- function Et(e, t, n, s) {
1166
+ function It(e, t, n, s) {
1150
1167
  if (!n.actionColumn) return;
1151
1168
  const i = s.currentTarget;
1152
- if (V.value.rowIndex === e) {
1153
- Q();
1169
+ if (H.value.rowIndex === e) {
1170
+ Y();
1154
1171
  return;
1155
1172
  }
1156
- De.value = n, pe.value = t, F(e, i);
1173
+ Ee.value = n, pe.value = t, ae(e, i);
1157
1174
  }
1158
- function Vt(e, t) {
1175
+ function Ot(e, t) {
1159
1176
  return !(e != null && e.actionColumn) || !t ? [] : (typeof e.actionColumn.actions == "function" ? e.actionColumn.actions(t) : e.actionColumn.actions).filter((s) => s.show ? s.show(t) : !0);
1160
1177
  }
1161
- function Bt(e, t, n) {
1162
- _("action-click", e.key, t, n), Q();
1178
+ function Zt(e, t, n) {
1179
+ _("action-click", e.key, t, n), Y();
1163
1180
  }
1164
- function Gt(e, t) {
1165
- t && (Z.value[e] = t);
1181
+ function jt(e, t) {
1182
+ t && (oe.value[e] = t);
1166
1183
  }
1167
- function et(e) {
1168
- if (V.value.rowIndex === null) return;
1169
- const t = e.target, n = ae.value, s = Object.values(Z.value), i = n == null ? void 0 : n.contains(t), y = s.some((H) => H.contains(t));
1170
- !i && !y && Q();
1184
+ function nt(e) {
1185
+ if (H.value.rowIndex === null) return;
1186
+ const t = e.target, n = De.value, s = Object.values(oe.value), i = n == null ? void 0 : n.contains(t), y = s.some((R) => R.contains(t));
1187
+ !i && !y && Y();
1171
1188
  }
1172
1189
  return de(() => {
1173
- document.addEventListener("click", et);
1190
+ document.addEventListener("click", nt);
1174
1191
  }), ge(() => {
1175
- document.removeEventListener("click", et);
1176
- }), (e, t) => (o(), l("div", En, [
1177
- h("div", Vn, [
1178
- h("button", {
1192
+ document.removeEventListener("click", nt);
1193
+ }), (e, t) => (o(), l("div", In, [
1194
+ g("div", On, [
1195
+ g("button", {
1179
1196
  type: "button",
1180
1197
  class: "shifl-grid__pill-button whitespace-nowrap",
1181
- onClick: t[0] || (t[0] = (n) => X.value = !0)
1198
+ onClick: t[0] || (t[0] = (n) => I.value = !0)
1182
1199
  }, " Edit Column ")
1183
1200
  ]),
1184
- h("div", {
1185
- class: G(["shifl-grid__viewport", { "shifl-grid__viewport--scroll": ot.value }]),
1186
- onScroll: mt
1201
+ g("div", {
1202
+ class: G(["shifl-grid__viewport", { "shifl-grid__viewport--scroll": dt.value }]),
1203
+ onScroll: kt
1187
1204
  }, [
1188
- h("table", Bn, [
1189
- h("thead", null, [
1190
- h("tr", null, [
1191
- (o(!0), l(N, null, E(te.value, (n) => {
1205
+ g("table", Zn, [
1206
+ g("thead", null, [
1207
+ g("tr", null, [
1208
+ (o(!0), l(x, null, V(X.value, (n) => {
1192
1209
  var s;
1193
1210
  return o(), l("th", {
1194
1211
  key: n.key,
1195
- style: W(Le(n, !0)),
1196
- onClick: () => vt(n.key),
1212
+ style: K(Le(n, !0)),
1213
+ onClick: () => Ct(n.key),
1197
1214
  class: G([
1198
1215
  "shifl-grid__header-cell",
1199
1216
  `shifl-grid__header-align-${n != null && n.align ? n.align : "left"}`,
@@ -1204,39 +1221,39 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
1204
1221
  }
1205
1222
  ])
1206
1223
  }, [
1207
- h("div", In, [
1208
- n.label ? (o(), l("span", On, L(n.label), 1)) : z("", !0),
1209
- ((s = D($)) == null ? void 0 : s.key) === n.key && !ue(n) && !Ae(n) ? (o(), l("span", Zn, [
1210
- D($).order === "asc" ? (o(), O(Sn, { key: 0 })) : (o(), O(Ln, { key: 1 }))
1211
- ])) : z("", !0)
1224
+ g("div", Fn, [
1225
+ n.label ? (o(), l("span", Kn, $(n.label), 1)) : D("", !0),
1226
+ ((s = E(N)) == null ? void 0 : s.key) === n.key && !ue(n) && !Ae(n) ? (o(), l("span", Wn, [
1227
+ E(N).order === "asc" ? (o(), Z(Ln, { key: 0 })) : (o(), Z(Rn, { key: 1 }))
1228
+ ])) : D("", !0)
1212
1229
  ])
1213
- ], 14, Gn);
1230
+ ], 14, jn);
1214
1231
  }), 128))
1215
1232
  ])
1216
1233
  ]),
1217
- h("tbody", null, [
1218
- J.value ? (o(!0), l(N, { key: 0 }, E(lt.value, (n) => (o(), l("tr", {
1234
+ g("tbody", null, [
1235
+ W.value ? (o(!0), l(x, { key: 0 }, V(gt.value, (n) => (o(), l("tr", {
1219
1236
  key: `skeleton-${n}`,
1220
1237
  class: "shifl-grid__skeleton-row"
1221
1238
  }, [
1222
- (o(!0), l(N, null, E(te.value, (s) => (o(), l("td", {
1239
+ (o(!0), l(x, null, V(X.value, (s) => (o(), l("td", {
1223
1240
  key: s.key,
1224
- style: W(Le(s, !1)),
1241
+ style: K(Le(s, !1)),
1225
1242
  class: G({ "shifl-grid__cell--sticky": s.freeze })
1226
1243
  }, [...t[6] || (t[6] = [
1227
- h("div", { class: "shifl-grid__skeleton-cell" }, null, -1)
1244
+ g("div", { class: "shifl-grid__skeleton-cell" }, null, -1)
1228
1245
  ])], 6))), 128))
1229
- ]))), 128)) : (o(), l(N, { key: 1 }, [
1230
- Be.value.length ? z("", !0) : (o(), l("tr", jn, [
1231
- h("td", {
1232
- colspan: te.value.length,
1246
+ ]))), 128)) : (o(), l(x, { key: 1 }, [
1247
+ Be.value.length ? D("", !0) : (o(), l("tr", Jn, [
1248
+ g("td", {
1249
+ colspan: X.value.length,
1233
1250
  class: "text-center text-gray-500 py-6"
1234
- }, " No data ", 8, Fn)
1251
+ }, " No data ", 8, qn)
1235
1252
  ])),
1236
- (o(!0), l(N, null, E(Be.value, (n, s) => (o(), l("tr", { key: s }, [
1237
- (o(!0), l(N, null, E(te.value, (i) => (o(), l("td", {
1253
+ (o(!0), l(x, null, V(Be.value, (n, s) => (o(), l("tr", { key: s }, [
1254
+ (o(!0), l(x, null, V(X.value, (i) => (o(), l("td", {
1238
1255
  key: i.key,
1239
- style: W(Le(i, !1)),
1256
+ style: K(Le(i, !1)),
1240
1257
  class: G([
1241
1258
  { "shifl-grid__cell--sticky": i.freeze },
1242
1259
  { "shifl-grid__cell--action": ue(i) },
@@ -1244,123 +1261,123 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
1244
1261
  { "shifl-grid__icon": i.cellType === "icon" }
1245
1262
  ])
1246
1263
  }, [
1247
- Ae(i) ? (o(), l(N, { key: 0 }, [
1248
- Dt(i, n) ? (o(), l("div", Kn, [
1249
- Ne(kn)
1250
- ])) : z("", !0)
1264
+ Ae(i) ? (o(), l(x, { key: 0 }, [
1265
+ Gt(i, n) ? (o(), l("div", Un, [
1266
+ Ne(Sn)
1267
+ ])) : D("", !0)
1251
1268
  ], 64)) : ue(i) ? (o(), l("button", {
1252
1269
  key: 1,
1253
1270
  type: "button",
1254
1271
  class: "shifl-grid__action-icon",
1255
1272
  ref_for: !0,
1256
- ref: (y) => Gt(s, y),
1257
- onClick: U((y) => Et(s, n, i, y), ["stop"])
1273
+ ref: (y) => jt(s, y),
1274
+ onClick: q((y) => It(s, n, i, y), ["stop"])
1258
1275
  }, [
1259
1276
  ce(i, n) ? typeof ce(i, n) == "string" ? (o(), l("span", {
1260
1277
  key: 1,
1261
1278
  innerHTML: ce(i, n),
1262
1279
  class: "w-4 h-4 inline-block"
1263
- }, null, 8, qn)) : (o(), O(fe(ce(i, n)), {
1280
+ }, null, 8, Xn)) : (o(), Z(fe(ce(i, n)), {
1264
1281
  key: 2,
1265
1282
  class: "w-4 h-4"
1266
- })) : (o(), l("span", Jn, "⋯"))
1267
- ], 8, Wn)) : Ct(i) ? (o(), l("div", Un, [
1268
- (o(!0), l(N, null, E(Mt(i), (y, H) => (o(), l(N, { key: H }, [
1269
- y === "icon" ? (o(), O(fe(Je(n[i.key])), {
1283
+ })) : (o(), l("span", Qn, "⋯"))
1284
+ ], 8, Yn)) : Pt(i) ? (o(), l("div", er, [
1285
+ (o(!0), l(x, null, V($t(i), (y, R) => (o(), l(x, { key: R }, [
1286
+ y === "icon" ? (o(), Z(fe(Je(n[i.key])), {
1270
1287
  key: 0,
1271
1288
  class: "shifl-grid__type-icon"
1272
1289
  })) : (o(), l("span", {
1273
1290
  key: 1,
1274
- class: G(wt(y))
1275
- }, L(Ue(n[i.key], y, i)), 3))
1291
+ class: G(Lt(y))
1292
+ }, $(Ue(n[i.key], y, i)), 3))
1276
1293
  ], 64))), 128))
1277
- ])) : kt(i) ? (o(), l("div", Yn, [
1278
- (o(), O(fe(Je(n[i.key])), { class: "shifl-grid__type-icon" })),
1279
- n.container_count != null ? (o(), l("span", Qn, " (" + L(n.container_count) + ") ", 1)) : z("", !0)
1280
- ])) : qe(i) ? (o(), l(N, { key: 4 }, [
1281
- n[i.key] == null || $e(n[i.key], i.key, s).length === 0 ? (o(), l("div", Xn, L(oe(i.blankStyle)), 1)) : (o(), l("div", er, [
1282
- h("div", tr, [
1283
- h("div", {
1294
+ ])) : Tt(i) ? (o(), l("div", tr, [
1295
+ (o(), Z(fe(Je(n[i.key])), { class: "shifl-grid__type-icon" })),
1296
+ n.container_count != null ? (o(), l("span", nr, " (" + $(n.container_count) + ") ", 1)) : D("", !0)
1297
+ ])) : qe(i) ? (o(), l(x, { key: 4 }, [
1298
+ n[i.key] == null || et(n[i.key], i.key, s).length === 0 ? (o(), l("div", rr, $(te(i.blankStyle)), 1)) : (o(), l("div", sr, [
1299
+ g("div", ir, [
1300
+ g("div", {
1284
1301
  ref_for: !0,
1285
1302
  ref: "(el) => setTagsRef(col.key, rowIndex, el as HTMLElement)",
1286
1303
  class: "shifl-grid__chips-container shifl-grid__chips-container--single-line"
1287
1304
  }, [
1288
- (o(!0), l(N, null, E(At(
1305
+ (o(!0), l(x, null, V(et(
1289
1306
  n[i.key],
1290
1307
  i.key,
1291
1308
  s
1292
- ), (y, H) => (o(), l("span", {
1293
- key: H,
1309
+ ), (y, R) => (o(), l("span", {
1310
+ key: R,
1294
1311
  class: "shifl-grid__chip shifl-grid__chip--tag",
1295
- style: W({ borderLeftColor: Xe(y) })
1296
- }, L(y.name), 5))), 128))
1312
+ style: K({ borderLeftColor: tt(y) })
1313
+ }, $(y.name), 5))), 128))
1297
1314
  ], 512)
1298
1315
  ]),
1299
- Nt(n[i.key], i.key, s) ? (o(), l("button", {
1316
+ zt(n[i.key], i.key, s) ? (o(), l("button", {
1300
1317
  key: 0,
1301
1318
  type: "button",
1302
1319
  class: "shifl-grid__counter-button",
1303
- onMouseenter: (y) => Te(
1320
+ onMouseenter: (y) => Pe(
1304
1321
  i.key,
1305
1322
  s,
1306
1323
  n[i.key],
1307
1324
  y.currentTarget
1308
1325
  ),
1309
- onMouseleave: Pe
1310
- }, " +" + L(xt(n[i.key], i.key, s)), 41, nr)) : z("", !0)
1326
+ onMouseleave: $e
1327
+ }, " +" + $(Dt(n[i.key], i.key, s)), 41, ar)) : D("", !0)
1311
1328
  ]))
1312
- ], 64)) : bt(i) ? (o(), l("div", rr, [
1313
- (o(!0), l(N, null, E(le(n[i.key]), (y, H) => (o(), l("span", {
1314
- key: H,
1329
+ ], 64)) : St(i) ? (o(), l("div", or, [
1330
+ (o(!0), l(x, null, V(le(n[i.key]), (y, R) => (o(), l("span", {
1331
+ key: R,
1315
1332
  class: "shifl-grid__chip shifl-grid__chip--status"
1316
- }, L(y), 1))), 128))
1317
- ])) : i.truncate !== !1 && (i.truncate === !0 || yt(i.key)) ? (o(), l("div", sr, [
1318
- h("span", {
1333
+ }, $(y), 1))), 128))
1334
+ ])) : i.truncate !== !1 && (i.truncate === !0 || wt(i.key)) ? (o(), l("div", lr, [
1335
+ g("span", {
1319
1336
  class: "shifl-grid__truncated-text",
1320
1337
  ref_for: !0,
1321
- ref: (y) => Lt(i.key, s, y)
1322
- }, L(St(n[i.key], i)), 513),
1323
- Se(i.key) && Pt(n[i.key]) ? (o(), l("button", {
1338
+ ref: (y) => Ht(i.key, s, y)
1339
+ }, $(At(n[i.key], i)), 513),
1340
+ Te(i.key) && xt(n[i.key]) ? (o(), l("button", {
1324
1341
  key: 0,
1325
1342
  type: "button",
1326
1343
  class: "shifl-grid__counter-button",
1327
- onMouseenter: (y) => Te(
1344
+ onMouseenter: (y) => Pe(
1328
1345
  i.key,
1329
1346
  s,
1330
1347
  n[i.key],
1331
1348
  y.currentTarget
1332
1349
  ),
1333
- onMouseleave: Pe
1334
- }, " +" + L($t(n[i.key])), 41, ir)) : !Se(i.key) && Tt(n[i.key], i.key) ? (o(), l("button", {
1350
+ onMouseleave: $e
1351
+ }, " +" + $(Rt(n[i.key])), 41, ur)) : !Te(i.key) && Nt(n[i.key], i.key) ? (o(), l("button", {
1335
1352
  key: 1,
1336
1353
  type: "button",
1337
1354
  class: "shifl-grid__info-icon-button",
1338
- onMouseenter: (y) => Te(
1355
+ onMouseenter: (y) => Pe(
1339
1356
  i.key,
1340
1357
  s,
1341
1358
  n[i.key],
1342
1359
  y.currentTarget
1343
1360
  ),
1344
- onMouseleave: Pe
1361
+ onMouseleave: $e
1345
1362
  }, [
1346
- Ne(Dn)
1347
- ], 40, ar)) : z("", !0)
1363
+ Ne(Gn)
1364
+ ], 40, cr)) : D("", !0)
1348
1365
  ])) : i.cellType === "link" ? (o(), l("a", {
1349
1366
  key: 7,
1350
1367
  href: String(n[i.key] || ""),
1351
1368
  class: "shifl-grid__link-cell",
1352
- onClick: t[1] || (t[1] = U(() => {
1369
+ onClick: t[1] || (t[1] = q(() => {
1353
1370
  }, ["stop"]))
1354
- }, L(we(n[i.key], i)), 9, or)) : i.cellType === "progress" ? (o(), l("div", lr, [
1355
- h("div", ur, [
1356
- h("div", {
1371
+ }, $(Se(n[i.key], i)), 9, fr)) : i.cellType === "progress" ? (o(), l("div", dr, [
1372
+ g("div", gr, [
1373
+ g("div", {
1357
1374
  class: "shifl-grid__progress-fill",
1358
- style: W({ width: `${_t(n[i.key])}%` })
1375
+ style: K({ width: `${Mt(n[i.key])}%` })
1359
1376
  }, null, 4)
1360
1377
  ]),
1361
- h("span", cr, L(we(n[i.key], i)), 1)
1362
- ])) : (o(), l(N, { key: 9 }, [
1363
- se(L(we(n[i.key], i)), 1)
1378
+ g("span", hr, $(Se(n[i.key], i)), 1)
1379
+ ])) : (o(), l(x, { key: 9 }, [
1380
+ se($(Se(n[i.key], i)), 1)
1364
1381
  ], 64))
1365
1382
  ], 6))), 128))
1366
1383
  ]))), 128))
@@ -1368,117 +1385,117 @@ const Dn = /* @__PURE__ */ Y(Hn, [["render", zn]]), En = { class: "shifl-grid re
1368
1385
  ])
1369
1386
  ])
1370
1387
  ], 34),
1371
- R.value && R.value.show !== !1 ? (o(), l("div", fr, [
1372
- h("div", dr, [
1373
- h("span", gr, [
1388
+ z.value && z.value.show !== !1 ? (o(), l("div", pr, [
1389
+ g("div", mr, [
1390
+ g("span", vr, [
1374
1391
  t[7] || (t[7] = se(" Showing ", -1)),
1375
- h("span", hr, L(Ge.value.from) + "–" + L(Ge.value.to), 1),
1376
- se(" of " + L(be.value), 1)
1392
+ g("span", _r, $(Ge.value.from) + "–" + $(Ge.value.to), 1),
1393
+ se(" of " + $(ke.value), 1)
1377
1394
  ])
1378
1395
  ]),
1379
- h("div", pr, [
1380
- h("div", mr, [
1381
- t[9] || (t[9] = h("label", { class: "shifl-grid__pagination-label" }, "Row per page", -1)),
1382
- h("select", {
1383
- value: R.value.perPage || 20,
1384
- disabled: J.value,
1385
- onChange: gt,
1396
+ g("div", yr, [
1397
+ g("div", br, [
1398
+ t[9] || (t[9] = g("label", { class: "shifl-grid__pagination-label" }, "Row per page", -1)),
1399
+ g("select", {
1400
+ value: z.value.perPage || 20,
1401
+ disabled: W.value,
1402
+ onChange: _t,
1386
1403
  class: "shifl-grid__pagination-select"
1387
1404
  }, [...t[8] || (t[8] = [
1388
- It('<option value="20">20</option><option value="30">30</option><option value="50">50</option><option value="75">75</option><option value="100">100</option>', 5)
1389
- ])], 40, vr)
1405
+ Ft('<option value="20">20</option><option value="30">30</option><option value="50">50</option><option value="75">75</option><option value="100">100</option>', 5)
1406
+ ])], 40, kr)
1390
1407
  ]),
1391
- h("div", _r, [
1392
- h("button", {
1408
+ g("div", Cr, [
1409
+ g("button", {
1393
1410
  type: "button",
1394
1411
  class: "shifl-grid__pagination-button",
1395
- disabled: Ie.value || g.loading,
1396
- onClick: ft,
1412
+ disabled: Ie.value || d.loading,
1413
+ onClick: mt,
1397
1414
  "aria-label": "Previous page"
1398
- }, " ‹ ", 8, yr),
1399
- h("div", br, [
1400
- (o(!0), l(N, null, E(ut.value, (n) => (o(), l(N, { key: n }, [
1415
+ }, " ‹ ", 8, Mr),
1416
+ g("div", wr, [
1417
+ (o(!0), l(x, null, V(ht.value, (n) => (o(), l(x, { key: n }, [
1401
1418
  n !== -1 ? (o(), l("button", {
1402
1419
  key: 0,
1403
1420
  type: "button",
1404
- class: G(["shifl-grid__pagination-page", { "shifl-grid__pagination-page--active": n === q.value }]),
1405
- disabled: J.value,
1406
- onClick: (s) => ct(n)
1407
- }, L(n), 11, kr)) : (o(), l("span", Cr, "…"))
1421
+ class: G(["shifl-grid__pagination-page", { "shifl-grid__pagination-page--active": n === J.value }]),
1422
+ disabled: W.value,
1423
+ onClick: (s) => pt(n)
1424
+ }, $(n), 11, Sr)) : (o(), l("span", Tr, "…"))
1408
1425
  ], 64))), 128))
1409
1426
  ]),
1410
- h("button", {
1427
+ g("button", {
1411
1428
  type: "button",
1412
1429
  class: "shifl-grid__pagination-button",
1413
- disabled: Oe.value || g.loading,
1414
- onClick: dt,
1430
+ disabled: Oe.value || d.loading,
1431
+ onClick: vt,
1415
1432
  "aria-label": "Next page"
1416
- }, " › ", 8, Mr)
1433
+ }, " › ", 8, Pr)
1417
1434
  ])
1418
1435
  ])
1419
- ])) : z("", !0),
1420
- (o(), O(Re, { to: "body" }, [
1421
- D(V).rowIndex !== null && D(V).position ? (o(), l("div", {
1436
+ ])) : D("", !0),
1437
+ (o(), Z(He, { to: "body" }, [
1438
+ E(H).rowIndex !== null && E(H).position ? (o(), l("div", {
1422
1439
  key: 0,
1423
1440
  ref_key: "actionMenuRef",
1424
- ref: ae,
1441
+ ref: De,
1425
1442
  class: "shifl-grid__action-menu",
1426
- style: W(`
1443
+ style: K(`
1427
1444
  position: fixed !important;
1428
- top: ${D(V).position.top}px !important;
1429
- left: ${D(V).position.left}px !important;
1445
+ top: ${E(H).position.top}px !important;
1446
+ left: ${E(H).position.left}px !important;
1430
1447
  z-index: 1000 !important;`),
1431
- onClick: t[2] || (t[2] = U(() => {
1448
+ onClick: t[2] || (t[2] = q(() => {
1432
1449
  }, ["stop"]))
1433
1450
  }, [
1434
- (o(!0), l(N, null, E(Vt(De.value, pe.value), (n) => (o(), l("div", {
1451
+ (o(!0), l(x, null, V(Ot(Ee.value, pe.value), (n) => (o(), l("div", {
1435
1452
  key: n.key,
1436
1453
  class: G(["shifl-grid__action-menu-item", { "shifl-grid__action-menu-item--danger": n.danger }]),
1437
- onClick: () => Bt(n, pe.value, D(V).rowIndex)
1454
+ onClick: () => Zt(n, pe.value, E(H).rowIndex)
1438
1455
  }, [
1439
1456
  n.icon && typeof n.icon == "string" ? (o(), l("span", {
1440
1457
  key: 0,
1441
1458
  innerHTML: n.icon,
1442
1459
  class: "w-4 h-4 inline-block"
1443
- }, null, 8, Sr)) : n.icon ? (o(), O(fe(typeof n.icon == "function" ? n.icon() : n.icon), {
1460
+ }, null, 8, Lr)) : n.icon ? (o(), Z(fe(typeof n.icon == "function" ? n.icon() : n.icon), {
1444
1461
  key: 1,
1445
1462
  class: "w-4 h-4"
1446
- })) : z("", !0),
1447
- h("span", null, L(n.label), 1)
1448
- ], 10, wr))), 128))
1449
- ], 4)) : z("", !0)
1463
+ })) : D("", !0),
1464
+ g("span", null, $(n.label), 1)
1465
+ ], 10, $r))), 128))
1466
+ ], 4)) : D("", !0)
1450
1467
  ])),
1451
- Ne(vn, {
1452
- content: Ee.value,
1468
+ Ne(kn, {
1469
+ content: Ve.value,
1453
1470
  visible: me.value,
1454
1471
  "trigger-element": ve.value,
1455
1472
  "is-html": _e.value
1456
1473
  }, null, 8, ["content", "visible", "trigger-element", "is-html"]),
1457
- (o(), O(Re, { to: "body" }, [
1458
- X.value ? (o(), O(gn, {
1474
+ (o(), Z(He, { to: "body" }, [
1475
+ I.value ? (o(), Z(vn, {
1459
1476
  key: 0,
1460
1477
  "title-prefix": a.config.name,
1461
- columns: zt.value,
1462
- onClose: t[3] || (t[3] = (n) => X.value = !1),
1463
- onToggle: D(w),
1464
- onToggleFreeze: D(p),
1465
- onMove: D(C),
1466
- onSelectAll: t[4] || (t[4] = (n) => D(u)(!0)),
1467
- onDeselectAll: t[5] || (t[5] = (n) => D(u)(!1)),
1468
- onRestoreDefault: D(A)
1469
- }, null, 8, ["title-prefix", "columns", "onToggle", "onToggleFreeze", "onMove", "onRestoreDefault"])) : z("", !0)
1478
+ columns: Bt.value,
1479
+ onClose: t[3] || (t[3] = (n) => I.value = !1),
1480
+ onToggle: E(f),
1481
+ onToggleFreeze: E(C),
1482
+ onMove: E(L),
1483
+ onSelectAll: t[4] || (t[4] = (n) => E(p)(!0)),
1484
+ onDeselectAll: t[5] || (t[5] = (n) => E(p)(!1)),
1485
+ onRestoreDefault: E(A)
1486
+ }, null, 8, ["title-prefix", "columns", "onToggle", "onToggleFreeze", "onMove", "onRestoreDefault"])) : D("", !0)
1470
1487
  ]))
1471
1488
  ]));
1472
1489
  }
1473
- }), $r = {
1490
+ }), xr = {
1474
1491
  install(a) {
1475
- a.component("ShiflGrid", Tr);
1492
+ a.component("ShiflGrid", Ar);
1476
1493
  }
1477
1494
  };
1478
- function Lr() {
1495
+ function Rr() {
1479
1496
  const a = b(/* @__PURE__ */ new Set());
1480
- function r(g) {
1481
- const _ = g.id ?? JSON.stringify(g), c = new Set(a.value);
1497
+ function r(d) {
1498
+ const _ = d.id ?? JSON.stringify(d), c = new Set(a.value);
1482
1499
  c.has(_) ? c.delete(_) : c.add(_), a.value = c;
1483
1500
  }
1484
1501
  return {
@@ -1486,12 +1503,12 @@ function Lr() {
1486
1503
  toggleRow: r
1487
1504
  };
1488
1505
  }
1489
- function Ar() {
1506
+ function Hr() {
1490
1507
  return {
1491
1508
  // placeholder
1492
1509
  };
1493
1510
  }
1494
- const st = Symbol("shifl-grid-theme"), it = {
1511
+ const ut = Symbol("shifl-grid-theme"), ct = {
1495
1512
  surface: "var(--shifl-surface)",
1496
1513
  surfaceAlt: "var(--shifl-surface-alt)",
1497
1514
  border: "var(--shifl-border)",
@@ -1501,19 +1518,19 @@ const st = Symbol("shifl-grid-theme"), it = {
1501
1518
  accentStrong: "var(--shifl-accent-strong)",
1502
1519
  focus: "var(--shifl-focus)"
1503
1520
  };
1504
- function Nr(a) {
1505
- const r = b({ ...it, ...a });
1506
- return Ot(st, r), r;
1521
+ function zr(a) {
1522
+ const r = b({ ...ct, ...a });
1523
+ return Kt(ut, r), r;
1507
1524
  }
1508
- function xr() {
1509
- const a = Zt(st);
1510
- return k(() => (a == null ? void 0 : a.value) ?? it);
1525
+ function Dr() {
1526
+ const a = Wt(ut);
1527
+ return k(() => (a == null ? void 0 : a.value) ?? ct);
1511
1528
  }
1512
1529
  const xe = {
1513
1530
  sm: 640,
1514
1531
  lg: 1024
1515
1532
  };
1516
- function Hr() {
1533
+ function Er() {
1517
1534
  const a = b(typeof window < "u" ? window.innerWidth : 0);
1518
1535
  function r() {
1519
1536
  a.value = window.innerWidth;
@@ -1528,34 +1545,34 @@ function Hr() {
1528
1545
  isTablet: k(() => a.value >= xe.sm && a.value < xe.lg)
1529
1546
  };
1530
1547
  }
1531
- function Rr() {
1548
+ function Vr() {
1532
1549
  return {
1533
1550
  // placeholder
1534
1551
  };
1535
1552
  }
1536
- function zr() {
1553
+ function Br() {
1537
1554
  return {
1538
1555
  // placeholder
1539
1556
  };
1540
1557
  }
1541
- function Dr() {
1558
+ function Gr() {
1542
1559
  return {
1543
1560
  // placeholder
1544
1561
  };
1545
1562
  }
1546
1563
  export {
1547
- Tr as ShiflGrid,
1548
- $r as ShiflGridPlugin,
1549
- Nr as provideGridTheme,
1550
- Hr as useBreakpoints,
1551
- Ft as useGridColumns,
1552
- Ut as useGridData,
1553
- Ar as useGridEditing,
1554
- Wt as useGridFilter,
1555
- Rr as useGridInfiniteScroll,
1556
- Lr as useGridSelection,
1557
- Kt as useGridSort,
1558
- xr as useGridTheme,
1559
- Dr as useGridTour,
1560
- zr as useVirtualScroll
1564
+ Ar as ShiflGrid,
1565
+ xr as ShiflGridPlugin,
1566
+ zr as provideGridTheme,
1567
+ Er as useBreakpoints,
1568
+ qt as useGridColumns,
1569
+ en as useGridData,
1570
+ Hr as useGridEditing,
1571
+ Yt as useGridFilter,
1572
+ Vr as useGridInfiniteScroll,
1573
+ Rr as useGridSelection,
1574
+ Ut as useGridSort,
1575
+ Dr as useGridTheme,
1576
+ Gr as useGridTour,
1577
+ Br as useVirtualScroll
1561
1578
  };