@kong-ui-public/dashboard-renderer 7.7.3 → 7.7.5

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.
@@ -1,20 +1,20 @@
1
1
  var oi = Object.defineProperty;
2
- var _t = (d) => {
3
- throw TypeError(d);
2
+ var _t = (a) => {
3
+ throw TypeError(a);
4
4
  };
5
- var ai = (d, e, t) => e in d ? oi(d, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : d[e] = t;
6
- var bt = (d, e, t) => ai(d, typeof e != "symbol" ? e + "" : e, t), it = (d, e, t) => e.has(d) || _t("Cannot " + t);
7
- var _ = (d, e, t) => (it(d, e, "read from private field"), t ? t.call(d) : e.get(d)), G = (d, e, t) => e.has(d) ? _t("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(d) : e.set(d, t), I = (d, e, t, i) => (it(d, e, "write to private field"), i ? i.call(d, t) : e.set(d, t), t), F = (d, e, t) => (it(d, e, "access private method"), t);
8
- var Te = (d, e, t, i) => ({
5
+ var ai = (a, e, t) => e in a ? oi(a, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : a[e] = t;
6
+ var bt = (a, e, t) => ai(a, typeof e != "symbol" ? e + "" : e, t), it = (a, e, t) => e.has(a) || _t("Cannot " + t);
7
+ var v = (a, e, t) => (it(a, e, "read from private field"), t ? t.call(a) : e.get(a)), G = (a, e, t) => e.has(a) ? _t("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(a) : e.set(a, t), I = (a, e, t, i) => (it(a, e, "write to private field"), i ? i.call(a, t) : e.set(a, t), t), F = (a, e, t) => (it(a, e, "access private method"), t);
8
+ var Te = (a, e, t, i) => ({
9
9
  set _(s) {
10
- I(d, e, s, t);
10
+ I(a, e, s, t);
11
11
  },
12
12
  get _() {
13
- return _(d, e, i);
13
+ return v(a, e, i);
14
14
  }
15
15
  });
16
- import { ref as H, watchEffect as Mt, inject as ve, provide as li, onMounted as at, computed as k, watch as ze, onUnmounted as lt, defineComponent as Z, resolveComponent as ge, createBlock as O, renderSlot as De, createCommentVNode as V, unref as x, openBlock as C, createSlots as Qe, withCtx as $, createElementVNode as oe, toDisplayString as ne, useCssVars as Ye, normalizeClass as je, createVNode as ue, mergeProps as It, createTextVNode as ht, createElementBlock as K, normalizeProps as hi, guardReactiveProps as ui, defineAsyncComponent as Pt, readonly as st, toRef as wt, nextTick as ut, resolveDynamicComponent as qt, toHandlers as di, Fragment as $t, renderList as Gt, normalizeStyle as Et, mergeModels as xt, useModel as ci, getCurrentInstance as fi } from "vue";
17
- import { msToGranularity as rt, getFieldDataSources as Ft, stripUnknownFilters as gi, Timeframe as pi, TimePeriods as Bt, TIMEFRAME_LOOKUP as mi, formatTime as Ct, EXPORT_RECORD_LIMIT as yi } from "@kong-ui-public/analytics-utilities";
16
+ import { ref as H, watchEffect as Mt, inject as ve, provide as li, onMounted as at, computed as k, watch as ze, onUnmounted as lt, defineComponent as Z, resolveComponent as ge, createBlock as O, renderSlot as De, createCommentVNode as V, unref as E, openBlock as x, createSlots as Qe, withCtx as $, createElementVNode as oe, toDisplayString as ne, useCssVars as Ye, normalizeClass as je, createVNode as ue, mergeProps as It, createTextVNode as ht, createElementBlock as K, normalizeProps as hi, guardReactiveProps as ui, defineAsyncComponent as Pt, readonly as st, toRef as wt, nextTick as ut, resolveDynamicComponent as qt, toHandlers as di, Fragment as $t, renderList as Gt, normalizeStyle as Et, mergeModels as xt, useModel as ci, getCurrentInstance as fi } from "vue";
17
+ import { msToGranularity as rt, getFieldDataSources as Ft, stripUnknownFilters as gi, Timeframe as mi, TimePeriods as Bt, TIMEFRAME_LOOKUP as pi, formatTime as Ct, EXPORT_RECORD_LIMIT as yi } from "@kong-ui-public/analytics-utilities";
18
18
  import { handleQueryError as vi, SimpleChart as _i, AnalyticsChart as bi, TopNTable as wi, CsvExportModal as Ei } from "@kong-ui-public/analytics-chart";
19
19
  import xi from "swrv";
20
20
  import "axios";
@@ -22,44 +22,44 @@ import { createI18n as Ci, i18nTComponent as Ri } from "@kong-ui-public/i18n";
22
22
  import { useAnalyticsConfigStore as dt } from "@kong-ui-public/analytics-config-store";
23
23
  import { VisibilityOffIcon as ki, WarningOutlineIcon as Ti, WarningIcon as zi, EditIcon as Di, MoreIcon as Si } from "@kong/icons";
24
24
  import { MetricsProvider as Ni, MetricsConsumer as Li } from "@kong-ui-public/analytics-metric-provider";
25
- var Ut = /* @__PURE__ */ ((d) => (d.VALIDATING = "VALIDATING", d.VALIDATING_HAS_DATA = "VALIDATING_HAS_DATA", d.PENDING = "PENDING", d.SUCCESS = "SUCCESS", d.SUCCESS_HAS_DATA = "SUCCESS_HAS_DATA", d.ERROR = "ERROR", d.STALE_IF_ERROR = "STALE_IF_ERROR", d))(Ut || {});
26
- const Ai = (d) => {
25
+ var Ut = /* @__PURE__ */ ((a) => (a.VALIDATING = "VALIDATING", a.VALIDATING_HAS_DATA = "VALIDATING_HAS_DATA", a.PENDING = "PENDING", a.SUCCESS = "SUCCESS", a.SUCCESS_HAS_DATA = "SUCCESS_HAS_DATA", a.ERROR = "ERROR", a.STALE_IF_ERROR = "STALE_IF_ERROR", a))(Ut || {});
26
+ const Ai = (a) => {
27
27
  var e, t, i, s, r;
28
- return d ? !!// TODO: revisit: currently only the first check ever matters?
29
- ((e = Object.keys(d)) != null && e.length || (t = d.data) != null && t.length || (s = (i = d.data) == null ? void 0 : i.data) != null && s.length || !((r = d.data) != null && r.data) && typeof d.data == "object" && Object.keys(d == null ? void 0 : d.data).length) : !1;
28
+ return a ? !!// TODO: revisit: currently only the first check ever matters?
29
+ ((e = Object.keys(a)) != null && e.length || (t = a.data) != null && t.length || (s = (i = a.data) == null ? void 0 : i.data) != null && s.length || !((r = a.data) != null && r.data) && typeof a.data == "object" && Object.keys(a == null ? void 0 : a.data).length) : !1;
30
30
  };
31
- function Oi(d = H({}), e, t, i = Ai) {
31
+ function Oi(a = H({}), e, t, i = Ai) {
32
32
  const s = H(
33
33
  "PENDING"
34
34
  /* PENDING */
35
35
  );
36
36
  return Mt(() => {
37
- const r = i(d.value);
38
- if (d.value && r && t.value) {
37
+ const r = i(a.value);
38
+ if (a.value && r && t.value) {
39
39
  s.value = "VALIDATING_HAS_DATA";
40
40
  return;
41
41
  }
42
- if (d.value && t.value) {
42
+ if (a.value && t.value) {
43
43
  s.value = "VALIDATING";
44
44
  return;
45
45
  }
46
- if (d.value && e.value) {
46
+ if (a.value && e.value) {
47
47
  s.value = "STALE_IF_ERROR";
48
48
  return;
49
49
  }
50
- if (d.value === void 0 && !e.value) {
50
+ if (a.value === void 0 && !e.value) {
51
51
  s.value = "PENDING";
52
52
  return;
53
53
  }
54
- if (d.value && !e.value && r) {
54
+ if (a.value && !e.value && r) {
55
55
  s.value = "SUCCESS_HAS_DATA";
56
56
  return;
57
57
  }
58
- if (d.value && !e.value) {
58
+ if (a.value && !e.value) {
59
59
  s.value = "SUCCESS";
60
60
  return;
61
61
  }
62
- d.value === void 0 && e && (s.value = "ERROR");
62
+ a.value === void 0 && e && (s.value = "ERROR");
63
63
  }), {
64
64
  state: s,
65
65
  swrvState: Ut
@@ -103,127 +103,127 @@ const Hi = {
103
103
  granularities: $i
104
104
  };
105
105
  function Fi() {
106
- const d = Ci("en-us", Gi);
106
+ const a = Ci("en-us", Gi);
107
107
  return {
108
- i18n: d,
109
- i18nT: Ri(d)
108
+ i18n: a,
109
+ i18nT: Ri(a)
110
110
  // Translation component <i18n-t>
111
111
  };
112
112
  }
113
- const Xe = 170, Wt = 6, pe = "analytics-query-provider", Rt = "{entity-id}", Bi = "{cp-id}", Ui = "{timeframe}", Wi = 30 * 1e3, Ki = 3e5, Vi = 36e5;
113
+ const Xe = 170, Wt = 6, me = "analytics-query-provider", Rt = "{entity-id}", Bi = "{cp-id}", Ui = "{timeframe}", Wi = 30 * 1e3, Ki = 3e5, Vi = 36e5;
114
114
  function Qi() {
115
- const d = ve(pe);
115
+ const a = ve(me);
116
116
  return {
117
- evaluateFeatureFlag: (t, i) => d ? d.evaluateFeatureFlagFn(t, i) : i
117
+ evaluateFeatureFlag: (t, i) => a ? a.evaluateFeatureFlagFn(t, i) : i
118
118
  };
119
119
  }
120
- function Yi(d) {
121
- return d && d.__esModule && Object.prototype.hasOwnProperty.call(d, "default") ? d.default : d;
120
+ function Yi(a) {
121
+ return a && a.__esModule && Object.prototype.hasOwnProperty.call(a, "default") ? a.default : a;
122
122
  }
123
123
  var Kt = { exports: {} };
124
- (function(d) {
124
+ (function(a) {
125
125
  var e = Object.prototype.hasOwnProperty, t = "~";
126
126
  function i() {
127
127
  }
128
128
  Object.create && (i.prototype = /* @__PURE__ */ Object.create(null), new i().__proto__ || (t = !1));
129
- function s(u, a, h) {
130
- this.fn = u, this.context = a, this.once = h || !1;
129
+ function s(d, h, u) {
130
+ this.fn = d, this.context = h, this.once = u || !1;
131
131
  }
132
- function r(u, a, h, l, f) {
133
- if (typeof h != "function")
132
+ function r(d, h, u, l, f) {
133
+ if (typeof u != "function")
134
134
  throw new TypeError("The listener must be a function");
135
- var p = new s(h, l || u, f), g = t ? t + a : a;
136
- return u._events[g] ? u._events[g].fn ? u._events[g] = [u._events[g], p] : u._events[g].push(p) : (u._events[g] = p, u._eventsCount++), u;
135
+ var m = new s(u, l || d, f), g = t ? t + h : h;
136
+ return d._events[g] ? d._events[g].fn ? d._events[g] = [d._events[g], m] : d._events[g].push(m) : (d._events[g] = m, d._eventsCount++), d;
137
137
  }
138
- function o(u, a) {
139
- --u._eventsCount === 0 ? u._events = new i() : delete u._events[a];
138
+ function o(d, h) {
139
+ --d._eventsCount === 0 ? d._events = new i() : delete d._events[h];
140
140
  }
141
141
  function n() {
142
142
  this._events = new i(), this._eventsCount = 0;
143
143
  }
144
144
  n.prototype.eventNames = function() {
145
- var a = [], h, l;
146
- if (this._eventsCount === 0) return a;
147
- for (l in h = this._events)
148
- e.call(h, l) && a.push(t ? l.slice(1) : l);
149
- return Object.getOwnPropertySymbols ? a.concat(Object.getOwnPropertySymbols(h)) : a;
150
- }, n.prototype.listeners = function(a) {
151
- var h = t ? t + a : a, l = this._events[h];
145
+ var h = [], u, l;
146
+ if (this._eventsCount === 0) return h;
147
+ for (l in u = this._events)
148
+ e.call(u, l) && h.push(t ? l.slice(1) : l);
149
+ return Object.getOwnPropertySymbols ? h.concat(Object.getOwnPropertySymbols(u)) : h;
150
+ }, n.prototype.listeners = function(h) {
151
+ var u = t ? t + h : h, l = this._events[u];
152
152
  if (!l) return [];
153
153
  if (l.fn) return [l.fn];
154
- for (var f = 0, p = l.length, g = new Array(p); f < p; f++)
154
+ for (var f = 0, m = l.length, g = new Array(m); f < m; f++)
155
155
  g[f] = l[f].fn;
156
156
  return g;
157
- }, n.prototype.listenerCount = function(a) {
158
- var h = t ? t + a : a, l = this._events[h];
157
+ }, n.prototype.listenerCount = function(h) {
158
+ var u = t ? t + h : h, l = this._events[u];
159
159
  return l ? l.fn ? 1 : l.length : 0;
160
- }, n.prototype.emit = function(a, h, l, f, p, g) {
161
- var y = t ? t + a : a;
160
+ }, n.prototype.emit = function(h, u, l, f, m, g) {
161
+ var y = t ? t + h : h;
162
162
  if (!this._events[y]) return !1;
163
- var m = this._events[y], D = arguments.length, P, z;
164
- if (m.fn) {
165
- switch (m.once && this.removeListener(a, m.fn, void 0, !0), D) {
163
+ var p = this._events[y], D = arguments.length, P, z;
164
+ if (p.fn) {
165
+ switch (p.once && this.removeListener(h, p.fn, void 0, !0), D) {
166
166
  case 1:
167
- return m.fn.call(m.context), !0;
167
+ return p.fn.call(p.context), !0;
168
168
  case 2:
169
- return m.fn.call(m.context, h), !0;
169
+ return p.fn.call(p.context, u), !0;
170
170
  case 3:
171
- return m.fn.call(m.context, h, l), !0;
171
+ return p.fn.call(p.context, u, l), !0;
172
172
  case 4:
173
- return m.fn.call(m.context, h, l, f), !0;
173
+ return p.fn.call(p.context, u, l, f), !0;
174
174
  case 5:
175
- return m.fn.call(m.context, h, l, f, p), !0;
175
+ return p.fn.call(p.context, u, l, f, m), !0;
176
176
  case 6:
177
- return m.fn.call(m.context, h, l, f, p, g), !0;
177
+ return p.fn.call(p.context, u, l, f, m, g), !0;
178
178
  }
179
179
  for (z = 1, P = new Array(D - 1); z < D; z++)
180
180
  P[z - 1] = arguments[z];
181
- m.fn.apply(m.context, P);
181
+ p.fn.apply(p.context, P);
182
182
  } else {
183
- var Q = m.length, B;
183
+ var Q = p.length, B;
184
184
  for (z = 0; z < Q; z++)
185
- switch (m[z].once && this.removeListener(a, m[z].fn, void 0, !0), D) {
185
+ switch (p[z].once && this.removeListener(h, p[z].fn, void 0, !0), D) {
186
186
  case 1:
187
- m[z].fn.call(m[z].context);
187
+ p[z].fn.call(p[z].context);
188
188
  break;
189
189
  case 2:
190
- m[z].fn.call(m[z].context, h);
190
+ p[z].fn.call(p[z].context, u);
191
191
  break;
192
192
  case 3:
193
- m[z].fn.call(m[z].context, h, l);
193
+ p[z].fn.call(p[z].context, u, l);
194
194
  break;
195
195
  case 4:
196
- m[z].fn.call(m[z].context, h, l, f);
196
+ p[z].fn.call(p[z].context, u, l, f);
197
197
  break;
198
198
  default:
199
199
  if (!P) for (B = 1, P = new Array(D - 1); B < D; B++)
200
200
  P[B - 1] = arguments[B];
201
- m[z].fn.apply(m[z].context, P);
201
+ p[z].fn.apply(p[z].context, P);
202
202
  }
203
203
  }
204
204
  return !0;
205
- }, n.prototype.on = function(a, h, l) {
206
- return r(this, a, h, l, !1);
207
- }, n.prototype.once = function(a, h, l) {
208
- return r(this, a, h, l, !0);
209
- }, n.prototype.removeListener = function(a, h, l, f) {
210
- var p = t ? t + a : a;
211
- if (!this._events[p]) return this;
212
- if (!h)
213
- return o(this, p), this;
214
- var g = this._events[p];
205
+ }, n.prototype.on = function(h, u, l) {
206
+ return r(this, h, u, l, !1);
207
+ }, n.prototype.once = function(h, u, l) {
208
+ return r(this, h, u, l, !0);
209
+ }, n.prototype.removeListener = function(h, u, l, f) {
210
+ var m = t ? t + h : h;
211
+ if (!this._events[m]) return this;
212
+ if (!u)
213
+ return o(this, m), this;
214
+ var g = this._events[m];
215
215
  if (g.fn)
216
- g.fn === h && (!f || g.once) && (!l || g.context === l) && o(this, p);
216
+ g.fn === u && (!f || g.once) && (!l || g.context === l) && o(this, m);
217
217
  else {
218
- for (var y = 0, m = [], D = g.length; y < D; y++)
219
- (g[y].fn !== h || f && !g[y].once || l && g[y].context !== l) && m.push(g[y]);
220
- m.length ? this._events[p] = m.length === 1 ? m[0] : m : o(this, p);
218
+ for (var y = 0, p = [], D = g.length; y < D; y++)
219
+ (g[y].fn !== u || f && !g[y].once || l && g[y].context !== l) && p.push(g[y]);
220
+ p.length ? this._events[m] = p.length === 1 ? p[0] : p : o(this, m);
221
221
  }
222
222
  return this;
223
- }, n.prototype.removeAllListeners = function(a) {
224
- var h;
225
- return a ? (h = t ? t + a : a, this._events[h] && o(this, h)) : (this._events = new i(), this._eventsCount = 0), this;
226
- }, n.prototype.off = n.prototype.removeListener, n.prototype.addListener = n.prototype.on, n.prefixed = t, n.EventEmitter = n, d.exports = n;
223
+ }, n.prototype.removeAllListeners = function(h) {
224
+ var u;
225
+ return h ? (u = t ? t + h : h, this._events[u] && o(this, u)) : (this._events = new i(), this._eventsCount = 0), this;
226
+ }, n.prototype.off = n.prototype.removeListener, n.prototype.addListener = n.prototype.on, n.prefixed = t, n.EventEmitter = n, a.exports = n;
227
227
  })(Kt);
228
228
  var ji = Kt.exports;
229
229
  const Xi = /* @__PURE__ */ Yi(ji);
@@ -237,11 +237,11 @@ class Zi extends Error {
237
237
  super(), this.name = "AbortError", this.message = e;
238
238
  }
239
239
  }
240
- const kt = (d) => globalThis.DOMException === void 0 ? new Zi(d) : new DOMException(d), Tt = (d) => {
241
- const e = d.reason === void 0 ? kt("This operation was aborted.") : d.reason;
240
+ const kt = (a) => globalThis.DOMException === void 0 ? new Zi(a) : new DOMException(a), Tt = (a) => {
241
+ const e = a.reason === void 0 ? kt("This operation was aborted.") : a.reason;
242
242
  return e instanceof Error ? e : kt(e);
243
243
  };
244
- function Ji(d, e) {
244
+ function Ji(a, e) {
245
245
  const {
246
246
  milliseconds: t,
247
247
  fallback: i,
@@ -249,50 +249,50 @@ function Ji(d, e) {
249
249
  customTimers: r = { setTimeout, clearTimeout }
250
250
  } = e;
251
251
  let o, n;
252
- const a = new Promise((h, l) => {
252
+ const h = new Promise((u, l) => {
253
253
  if (typeof t != "number" || Math.sign(t) !== 1)
254
254
  throw new TypeError(`Expected \`milliseconds\` to be a positive number, got \`${t}\``);
255
255
  if (e.signal) {
256
- const { signal: p } = e;
257
- p.aborted && l(Tt(p)), n = () => {
258
- l(Tt(p));
259
- }, p.addEventListener("abort", n, { once: !0 });
256
+ const { signal: m } = e;
257
+ m.aborted && l(Tt(m)), n = () => {
258
+ l(Tt(m));
259
+ }, m.addEventListener("abort", n, { once: !0 });
260
260
  }
261
261
  if (t === Number.POSITIVE_INFINITY) {
262
- d.then(h, l);
262
+ a.then(u, l);
263
263
  return;
264
264
  }
265
265
  const f = new Vt();
266
266
  o = r.setTimeout.call(void 0, () => {
267
267
  if (i) {
268
268
  try {
269
- h(i());
270
- } catch (p) {
271
- l(p);
269
+ u(i());
270
+ } catch (m) {
271
+ l(m);
272
272
  }
273
273
  return;
274
274
  }
275
- typeof d.cancel == "function" && d.cancel(), s === !1 ? h() : s instanceof Error ? l(s) : (f.message = s ?? `Promise timed out after ${t} milliseconds`, l(f));
275
+ typeof a.cancel == "function" && a.cancel(), s === !1 ? u() : s instanceof Error ? l(s) : (f.message = s ?? `Promise timed out after ${t} milliseconds`, l(f));
276
276
  }, t), (async () => {
277
277
  try {
278
- h(await d);
279
- } catch (p) {
280
- l(p);
278
+ u(await a);
279
+ } catch (m) {
280
+ l(m);
281
281
  }
282
282
  })();
283
283
  }).finally(() => {
284
- a.clear(), n && e.signal && e.signal.removeEventListener("abort", n);
284
+ h.clear(), n && e.signal && e.signal.removeEventListener("abort", n);
285
285
  });
286
- return a.clear = () => {
286
+ return h.clear = () => {
287
287
  r.clearTimeout.call(void 0, o), o = void 0;
288
- }, a;
288
+ }, h;
289
289
  }
290
- function es(d, e, t) {
291
- let i = 0, s = d.length;
290
+ function es(a, e, t) {
291
+ let i = 0, s = a.length;
292
292
  for (; s > 0; ) {
293
293
  const r = Math.trunc(s / 2);
294
294
  let o = i + r;
295
- t(d[o], e) <= 0 ? (i = ++o, s -= r + 1) : s = r;
295
+ t(a[o], e) <= 0 ? (i = ++o, s -= r + 1) : s = r;
296
296
  }
297
297
  return i;
298
298
  }
@@ -311,29 +311,29 @@ class ts {
311
311
  id: t.id,
312
312
  run: e
313
313
  };
314
- if (this.size === 0 || _(this, ie)[this.size - 1].priority >= t.priority) {
315
- _(this, ie).push(i);
314
+ if (this.size === 0 || v(this, ie)[this.size - 1].priority >= t.priority) {
315
+ v(this, ie).push(i);
316
316
  return;
317
317
  }
318
- const s = es(_(this, ie), i, (r, o) => o.priority - r.priority);
319
- _(this, ie).splice(s, 0, i);
318
+ const s = es(v(this, ie), i, (r, o) => o.priority - r.priority);
319
+ v(this, ie).splice(s, 0, i);
320
320
  }
321
321
  setPriority(e, t) {
322
- const i = _(this, ie).findIndex((r) => r.id === e);
322
+ const i = v(this, ie).findIndex((r) => r.id === e);
323
323
  if (i === -1)
324
324
  throw new ReferenceError(`No promise function with the id "${e}" exists in the queue.`);
325
- const [s] = _(this, ie).splice(i, 1);
325
+ const [s] = v(this, ie).splice(i, 1);
326
326
  this.enqueue(s.run, { priority: t, id: e });
327
327
  }
328
328
  dequeue() {
329
- const e = _(this, ie).shift();
329
+ const e = v(this, ie).shift();
330
330
  return e == null ? void 0 : e.run;
331
331
  }
332
332
  filter(e) {
333
- return _(this, ie).filter((t) => t.priority === e.priority).map((t) => t.run);
333
+ return v(this, ie).filter((t) => t.priority === e.priority).map((t) => t.run);
334
334
  }
335
335
  get size() {
336
- return _(this, ie).length;
336
+ return v(this, ie).length;
337
337
  }
338
338
  }
339
339
  ie = new WeakMap();
@@ -382,7 +382,7 @@ class is extends Xi {
382
382
  I(this, be, t.carryoverConcurrencyCount), I(this, we, t.intervalCap === Number.POSITIVE_INFINITY || t.interval === 0), I(this, Le, t.intervalCap), I(this, Ee, t.interval), I(this, W, new t.queueClass()), I(this, Oe, t.queueClass), this.concurrency = t.concurrency, this.timeout = t.timeout, I(this, He, t.throwOnTimeout === !0), I(this, ce, t.autoStart === !1);
383
383
  }
384
384
  get concurrency() {
385
- return _(this, Ce);
385
+ return v(this, Ce);
386
386
  }
387
387
  set concurrency(t) {
388
388
  if (!(typeof t == "number" && t >= 1))
@@ -426,23 +426,23 @@ class is extends Xi {
426
426
  Here, the promise function with `id: '🦀'` executes last.
427
427
  */
428
428
  setPriority(t, i) {
429
- _(this, W).setPriority(t, i);
429
+ v(this, W).setPriority(t, i);
430
430
  }
431
431
  async add(t, i = {}) {
432
432
  return i.id ?? (i.id = (Te(this, Ve)._++).toString()), i = {
433
433
  timeout: this.timeout,
434
- throwOnTimeout: _(this, He),
434
+ throwOnTimeout: v(this, He),
435
435
  ...i
436
436
  }, new Promise((s, r) => {
437
- _(this, W).enqueue(async () => {
437
+ v(this, W).enqueue(async () => {
438
438
  var o;
439
439
  Te(this, re)._++, Te(this, fe)._++;
440
440
  try {
441
441
  (o = i.signal) == null || o.throwIfAborted();
442
442
  let n = t({ signal: i.signal });
443
443
  i.timeout && (n = Ji(Promise.resolve(n), { milliseconds: i.timeout })), i.signal && (n = Promise.race([n, F(this, T, Jt).call(this, i.signal)]));
444
- const u = await n;
445
- s(u), this.emit("completed", u);
444
+ const d = await n;
445
+ s(d), this.emit("completed", d);
446
446
  } catch (n) {
447
447
  if (n instanceof Vt && !i.throwOnTimeout) {
448
448
  s();
@@ -462,7 +462,7 @@ class is extends Xi {
462
462
  Start (or resume) executing enqueued tasks within concurrency limit. No need to call this if queue is not paused (via `options.autoStart = false` or by `.pause()` method.)
463
463
  */
464
464
  start() {
465
- return _(this, ce) ? (I(this, ce, !1), F(this, T, $e).call(this), this) : this;
465
+ return v(this, ce) ? (I(this, ce, !1), F(this, T, $e).call(this), this) : this;
466
466
  }
467
467
  /**
468
468
  Put queue execution on hold.
@@ -474,7 +474,7 @@ class is extends Xi {
474
474
  Clear the queue.
475
475
  */
476
476
  clear() {
477
- I(this, W, new (_(this, Oe))());
477
+ I(this, W, new (v(this, Oe))());
478
478
  }
479
479
  /**
480
480
  Can be called multiple times. Useful if you for example add additional items at a later time.
@@ -482,7 +482,7 @@ class is extends Xi {
482
482
  @returns A promise that settles when the queue becomes empty.
483
483
  */
484
484
  async onEmpty() {
485
- _(this, W).size !== 0 && await F(this, T, Ge).call(this, "empty");
485
+ v(this, W).size !== 0 && await F(this, T, Ge).call(this, "empty");
486
486
  }
487
487
  /**
488
488
  @returns A promise that settles when the queue size is less than the given limit: `queue.size < limit`.
@@ -492,7 +492,7 @@ class is extends Xi {
492
492
  Note that this only limits the number of items waiting to start. There could still be up to `concurrency` jobs already running that this call does not include in its calculation.
493
493
  */
494
494
  async onSizeLessThan(t) {
495
- _(this, W).size < t || await F(this, T, Ge).call(this, "next", () => _(this, W).size < t);
495
+ v(this, W).size < t || await F(this, T, Ge).call(this, "next", () => v(this, W).size < t);
496
496
  }
497
497
  /**
498
498
  The difference with `.onEmpty` is that `.onIdle` guarantees that all work from the queue has finished. `.onEmpty` merely signals that the queue is empty, but it could mean that some promises haven't completed yet.
@@ -500,13 +500,13 @@ class is extends Xi {
500
500
  @returns A promise that settles when the queue becomes empty, and all promises have completed; `queue.size === 0 && queue.pending === 0`.
501
501
  */
502
502
  async onIdle() {
503
- _(this, re) === 0 && _(this, W).size === 0 || await F(this, T, Ge).call(this, "idle");
503
+ v(this, re) === 0 && v(this, W).size === 0 || await F(this, T, Ge).call(this, "idle");
504
504
  }
505
505
  /**
506
506
  Size of the queue, the number of queued items waiting to run.
507
507
  */
508
508
  get size() {
509
- return _(this, W).size;
509
+ return v(this, W).size;
510
510
  }
511
511
  /**
512
512
  Size of the queue, filtered by the given options.
@@ -514,58 +514,58 @@ class is extends Xi {
514
514
  For example, this can be used to find the number of items remaining in the queue with a specific priority level.
515
515
  */
516
516
  sizeBy(t) {
517
- return _(this, W).filter(t).length;
517
+ return v(this, W).filter(t).length;
518
518
  }
519
519
  /**
520
520
  Number of running items (no longer in the queue).
521
521
  */
522
522
  get pending() {
523
- return _(this, re);
523
+ return v(this, re);
524
524
  }
525
525
  /**
526
526
  Whether the queue is currently paused.
527
527
  */
528
528
  get isPaused() {
529
- return _(this, ce);
529
+ return v(this, ce);
530
530
  }
531
531
  }
532
532
  be = new WeakMap(), we = new WeakMap(), fe = new WeakMap(), Le = new WeakMap(), Ee = new WeakMap(), Ae = new WeakMap(), se = new WeakMap(), xe = new WeakMap(), W = new WeakMap(), Oe = new WeakMap(), re = new WeakMap(), Ce = new WeakMap(), ce = new WeakMap(), He = new WeakMap(), Ve = new WeakMap(), T = new WeakSet(), Qt = function() {
533
- return _(this, we) || _(this, fe) < _(this, Le);
533
+ return v(this, we) || v(this, fe) < v(this, Le);
534
534
  }, Yt = function() {
535
- return _(this, re) < _(this, Ce);
535
+ return v(this, re) < v(this, Ce);
536
536
  }, jt = function() {
537
537
  Te(this, re)._--, F(this, T, qe).call(this), this.emit("next");
538
538
  }, Xt = function() {
539
539
  F(this, T, ot).call(this), F(this, T, nt).call(this), I(this, xe, void 0);
540
540
  }, Zt = function() {
541
541
  const t = Date.now();
542
- if (_(this, se) === void 0) {
543
- const i = _(this, Ae) - t;
542
+ if (v(this, se) === void 0) {
543
+ const i = v(this, Ae) - t;
544
544
  if (i < 0)
545
- I(this, fe, _(this, be) ? _(this, re) : 0);
545
+ I(this, fe, v(this, be) ? v(this, re) : 0);
546
546
  else
547
- return _(this, xe) === void 0 && I(this, xe, setTimeout(() => {
547
+ return v(this, xe) === void 0 && I(this, xe, setTimeout(() => {
548
548
  F(this, T, Xt).call(this);
549
549
  }, i)), !0;
550
550
  }
551
551
  return !1;
552
552
  }, qe = function() {
553
- if (_(this, W).size === 0)
554
- return _(this, se) && clearInterval(_(this, se)), I(this, se, void 0), this.emit("empty"), _(this, re) === 0 && this.emit("idle"), !1;
555
- if (!_(this, ce)) {
556
- const t = !_(this, T, Zt);
557
- if (_(this, T, Qt) && _(this, T, Yt)) {
558
- const i = _(this, W).dequeue();
553
+ if (v(this, W).size === 0)
554
+ return v(this, se) && clearInterval(v(this, se)), I(this, se, void 0), this.emit("empty"), v(this, re) === 0 && this.emit("idle"), !1;
555
+ if (!v(this, ce)) {
556
+ const t = !v(this, T, Zt);
557
+ if (v(this, T, Qt) && v(this, T, Yt)) {
558
+ const i = v(this, W).dequeue();
559
559
  return i ? (this.emit("active"), i(), t && F(this, T, nt).call(this), !0) : !1;
560
560
  }
561
561
  }
562
562
  return !1;
563
563
  }, nt = function() {
564
- _(this, we) || _(this, se) !== void 0 || (I(this, se, setInterval(() => {
564
+ v(this, we) || v(this, se) !== void 0 || (I(this, se, setInterval(() => {
565
565
  F(this, T, ot).call(this);
566
- }, _(this, Ee))), I(this, Ae, Date.now() + _(this, Ee)));
566
+ }, v(this, Ee))), I(this, Ae, Date.now() + v(this, Ee)));
567
567
  }, ot = function() {
568
- _(this, fe) === 0 && _(this, re) === 0 && _(this, se) && (clearInterval(_(this, se)), I(this, se, void 0)), I(this, fe, _(this, be) ? _(this, re) : 0), F(this, T, $e).call(this);
568
+ v(this, fe) === 0 && v(this, re) === 0 && v(this, se) && (clearInterval(v(this, se)), I(this, se, void 0)), I(this, fe, v(this, be) ? v(this, re) : 0), F(this, T, $e).call(this);
569
569
  }, /**
570
570
  Executes all queued functions until it reaches the limit.
571
571
  */
@@ -587,7 +587,7 @@ $e = function() {
587
587
  });
588
588
  };
589
589
  const ss = () => {
590
- const d = dt(), e = ve(pe);
590
+ const a = dt(), e = ve(me);
591
591
  if (!e)
592
592
  return;
593
593
  if (e.queryFnOverride) {
@@ -596,38 +596,38 @@ const ss = () => {
596
596
  }
597
597
  const t = new is({
598
598
  carryoverConcurrencyCount: !0,
599
- concurrency: d.maxParallelRequests,
600
- interval: d.requestInterval,
601
- intervalCap: d.requestIntervalCap
599
+ concurrency: a.maxParallelRequests,
600
+ interval: a.requestInterval,
601
+ intervalCap: a.requestIntervalCap
602
602
  }), i = {
603
603
  ...e,
604
604
  queryFnOverride: !0,
605
605
  queryFn: (s, r) => t.add(() => e.queryFn(s, r), { throwOnTimeout: !0 })
606
606
  };
607
- li(pe, i);
607
+ li(me, i);
608
608
  };
609
609
  function rs({
610
- queryBridge: d,
610
+ queryBridge: a,
611
611
  context: e,
612
612
  definition: t,
613
613
  chartData: i
614
614
  }) {
615
- const s = H(""), r = H(""), o = H(void 0), n = H(void 0), u = dt();
615
+ const s = H(""), r = H(""), o = H(void 0), n = H(void 0), d = dt();
616
616
  at(async () => {
617
617
  var R, M;
618
- s.value = await ((R = d == null ? void 0 : d.exploreBaseUrl) == null ? void 0 : R.call(d)) ?? "", r.value = await ((M = d == null ? void 0 : d.requestsBaseUrl) == null ? void 0 : M.call(d)) ?? "";
618
+ s.value = await ((R = a == null ? void 0 : a.exploreBaseUrl) == null ? void 0 : R.call(a)) ?? "", r.value = await ((M = a == null ? void 0 : a.requestsBaseUrl) == null ? void 0 : M.call(a)) ?? "";
619
619
  });
620
- const a = k(() => u.analytics && u.percentiles), h = k(() => !["golden_signals", "top_n", "gauge"].includes(t.value.chart.type)), l = k(() => r.value && t.value.query && t.value.query.datasource !== "llm_usage" && a.value), f = k(() => s.value && t.value.query && ["basic", "api_usage", "llm_usage", void 0].includes(t.value.query.datasource) && a.value), p = k(() => i.value ? rt(i.value.meta.granularity_ms) : void 0), g = k(() => {
620
+ const h = k(() => d.analytics && d.percentiles), u = k(() => !["golden_signals", "top_n", "gauge"].includes(t.value.chart.type)), l = k(() => r.value && t.value.query && t.value.query.datasource !== "llm_usage" && h.value), f = k(() => s.value && t.value.query && ["basic", "api_usage", "llm_usage", void 0].includes(t.value.query.datasource) && h.value), m = k(() => i.value ? rt(i.value.meta.granularity_ms) : void 0), g = k(() => {
621
621
  var Y;
622
622
  const R = [...e.value.filters, ...t.value.query.filters ?? []], M = ((Y = t.value.query) == null ? void 0 : Y.datasource) ?? "api_usage";
623
623
  return R.filter((de) => Ft(de.field).some((J) => M === J));
624
624
  }), y = k(() => {
625
- if (!f.value || !h.value)
625
+ if (!f.value || !u.value)
626
626
  return "";
627
627
  const R = g.value, M = t.value.query.time_range || e.value.timeSpec, Y = Q(M, R);
628
628
  return B(Y);
629
- }), m = k(() => {
630
- if (!l.value || !h.value)
629
+ }), p = k(() => {
630
+ if (!l.value || !u.value)
631
631
  return "";
632
632
  const R = g.value, M = P(
633
633
  t.value.query.time_range || e.value.timeSpec,
@@ -658,7 +658,7 @@ function rs({
658
658
  metrics: t.value.query.metrics ?? [],
659
659
  dimensions: Y,
660
660
  time_range: R,
661
- granularity: t.value.query.granularity || p.value
661
+ granularity: t.value.query.granularity || m.value
662
662
  };
663
663
  }, B = (R) => {
664
664
  if (!f.value)
@@ -670,8 +670,8 @@ function rs({
670
670
  R && (o.value = { href: "" }), M && (n.value = { href: "" });
671
671
  }), {
672
672
  exploreLinkKebabMenu: y,
673
- requestsLinkKebabMenu: m,
674
- canShowKebabMenu: h,
673
+ requestsLinkKebabMenu: p,
674
+ canShowKebabMenu: u,
675
675
  canGenerateRequestsLink: l,
676
676
  canGenerateExploreLink: f,
677
677
  requestsLinkZoomActions: o,
@@ -682,22 +682,22 @@ function rs({
682
682
  buildRequestLink: D
683
683
  };
684
684
  }
685
- const ns = (d, e, t) => {
685
+ const ns = (a, e, t) => {
686
686
  const i = [];
687
- return e && i.push(...e), i.push(...gi(d, t)), i;
687
+ return e && i.push(...e), i.push(...gi(a, t)), i;
688
688
  };
689
689
  function os() {
690
- const d = ve(pe), e = new AbortController();
690
+ const a = ve(me), e = new AbortController();
691
691
  return lt(() => {
692
692
  e.abort();
693
693
  }), { issueQuery: async (i, s, r) => {
694
- if (!d)
694
+ if (!a)
695
695
  throw new Error("Query bridge is not defined");
696
696
  const {
697
697
  datasource: o,
698
698
  limit: n,
699
- ...u
700
- } = i, a = o || "basic", h = ns(a, i.filters, s.filters);
699
+ ...d
700
+ } = i, h = o || "basic", u = ns(h, i.filters, s.filters);
701
701
  let l = i.time_range;
702
702
  l ? l.tz || (l = {
703
703
  ...l,
@@ -707,15 +707,15 @@ function os() {
707
707
  tz: s.tz
708
708
  };
709
709
  const f = {
710
- datasource: a,
710
+ datasource: h,
711
711
  query: {
712
- ...u,
712
+ ...d,
713
713
  time_range: l,
714
- filters: h,
714
+ filters: u,
715
715
  limit: r ?? n
716
716
  }
717
717
  };
718
- return d.queryFn(f, e);
718
+ return a.queryFn(f, e);
719
719
  } };
720
720
  }
721
721
  const ye = {
@@ -734,8 +734,8 @@ const ye = {
734
734
  refreshCounter: {}
735
735
  },
736
736
  emits: ["chart-data", "queryComplete"],
737
- setup(d, { emit: e }) {
738
- const t = d, i = e, { issueQuery: s } = ye.useIssueQuery(), r = ve(pe), o = () => t.queryReady && r ? JSON.stringify([t.query, t.context, t.refreshCounter]) : null, { data: n, error: u, isValidating: a } = xi(o, async () => {
737
+ setup(a, { emit: e }) {
738
+ const t = a, i = e, { issueQuery: s } = ye.useIssueQuery(), r = ve(me), o = () => t.queryReady && r ? JSON.stringify([t.query, t.context, t.refreshCounter]) : null, { data: n, error: d, isValidating: h } = xi(o, async () => {
739
739
  try {
740
740
  const y = await s(t.query, t.context, t.limitOverride);
741
741
  return f.value = null, y;
@@ -748,22 +748,22 @@ const ye = {
748
748
  refreshInterval: t.context.refreshInterval,
749
749
  revalidateOnFocus: !1,
750
750
  shouldRetryOnError: !1
751
- }), { state: h, swrvState: l } = Oi(n, u, a), f = H(null), p = k(() => h.value === l.ERROR || !!f.value), g = k(() => !t.queryReady || h.value === l.PENDING);
751
+ }), { state: u, swrvState: l } = Oi(n, d, h), f = H(null), m = k(() => u.value === l.ERROR || !!f.value), g = k(() => !t.queryReady || u.value === l.PENDING);
752
752
  return ze(n, (y) => {
753
753
  y && i("chart-data", y);
754
- }), (y, m) => {
754
+ }), (y, p) => {
755
755
  const D = ge("KSkeleton"), P = ge("KEmptyState");
756
- return g.value || !x(n) && !p.value ? (C(), O(D, {
756
+ return g.value || !E(n) && !m.value ? (x(), O(D, {
757
757
  key: 0,
758
758
  class: "chart-skeleton",
759
759
  type: "table"
760
- })) : p.value && f.value ? (C(), O(P, {
760
+ })) : m.value && f.value ? (x(), O(P, {
761
761
  key: 1,
762
762
  "action-button-visible": !1,
763
763
  "data-testid": "chart-empty-state"
764
764
  }, Qe({
765
765
  icon: $(() => [
766
- f.value.type === "forbidden" ? (C(), O(x(ki), { key: 0 })) : (C(), O(x(Ti), { key: 1 }))
766
+ f.value.type === "forbidden" ? (x(), O(E(ki), { key: 0 })) : (x(), O(E(Ti), { key: 1 }))
767
767
  ]),
768
768
  title: $(() => [
769
769
  oe("p", null, ne(f.value.message), 1)
@@ -777,9 +777,9 @@ const ye = {
777
777
  ]),
778
778
  key: "0"
779
779
  } : void 0
780
- ]), 1024)) : x(n) ? De(y.$slots, "default", {
780
+ ]), 1024)) : E(n) ? De(y.$slots, "default", {
781
781
  key: 2,
782
- data: x(n)
782
+ data: E(n)
783
783
  }) : V("", !0);
784
784
  };
785
785
  }
@@ -795,33 +795,33 @@ const ye = {
795
795
  requestsLink: {},
796
796
  exploreLink: {}
797
797
  },
798
- setup(d) {
798
+ setup(a) {
799
799
  Ye((i) => ({
800
- "088169ae": `${i.height}px`
800
+ v088169ae: `${i.height}px`
801
801
  }));
802
- const e = d, t = k(() => e.chartOptions.type === "single_value");
803
- return (i, s) => (C(), O(ct, {
804
- context: i.context,
805
- query: i.query,
806
- "query-ready": i.queryReady,
807
- "refresh-counter": i.refreshCounter
802
+ const e = a, t = k(() => e.chartOptions.type === "single_value");
803
+ return (i, s) => (x(), O(ct, {
804
+ context: a.context,
805
+ query: a.query,
806
+ "query-ready": a.queryReady,
807
+ "refresh-counter": a.refreshCounter
808
808
  }, {
809
809
  default: $(({ data: r }) => [
810
810
  oe("div", {
811
811
  class: je(["analytics-chart", { "single-value": t.value }])
812
812
  }, [
813
- ue(x(_i), {
813
+ ue(E(_i), {
814
814
  "chart-data": r,
815
- "chart-options": i.chartOptions,
816
- "synthetics-data-key": t.value ? void 0 : i.chartOptions.synthetics_data_key
815
+ "chart-options": a.chartOptions,
816
+ "synthetics-data-key": t.value ? void 0 : a.chartOptions.synthetics_data_key
817
817
  }, null, 8, ["chart-data", "chart-options", "synthetics-data-key"])
818
818
  ], 2)
819
819
  ]),
820
820
  _: 1
821
821
  }, 8, ["context", "query", "query-ready", "refresh-counter"]));
822
822
  }
823
- }), _e = (d, e) => {
824
- const t = d.__vccOpts || d;
823
+ }), _e = (a, e) => {
824
+ const t = a.__vccOpts || a;
825
825
  for (const [i, s] of e)
826
826
  t[i] = s;
827
827
  return t;
@@ -839,29 +839,29 @@ const ye = {
839
839
  extraProps: {}
840
840
  },
841
841
  emits: ["edit-tile", "chart-data", "zoom-time-range", "view-requests", "select-chart-range"],
842
- setup(d, { emit: e }) {
843
- const t = d, i = e, { i18n: s } = ye.useI18n(), r = k(() => ({
842
+ setup(a, { emit: e }) {
843
+ const t = a, i = e, { i18n: s } = ye.useI18n(), r = k(() => ({
844
844
  type: t.chartOptions.type,
845
845
  stacked: t.chartOptions.stacked ?? !1,
846
846
  chartDatasetColors: t.chartOptions.chart_dataset_colors,
847
847
  threshold: t.chartOptions.threshold
848
848
  })), o = k(() => t.context.zoomable), n = () => {
849
849
  i("edit-tile");
850
- }, u = (a) => {
851
- i("chart-data", a);
850
+ }, d = (h) => {
851
+ i("chart-data", h);
852
852
  };
853
- return (a, h) => {
853
+ return (h, u) => {
854
854
  const l = ge("KDropdownItem");
855
- return C(), O(ct, {
855
+ return x(), O(ct, {
856
856
  context: a.context,
857
857
  query: a.query,
858
858
  "query-ready": a.queryReady,
859
859
  "refresh-counter": a.refreshCounter,
860
- onChartData: u
860
+ onChartData: d
861
861
  }, {
862
862
  default: $(({ data: f }) => [
863
863
  oe("div", ls, [
864
- ue(x(bi), It({
864
+ ue(E(bi), It({
865
865
  "chart-data": f,
866
866
  "chart-options": r.value,
867
867
  "explore-link": a.exploreLink,
@@ -871,15 +871,15 @@ const ye = {
871
871
  "timeseries-zoom": o.value,
872
872
  "tooltip-title": ""
873
873
  }, a.extraProps, {
874
- onSelectChartRange: h[0] || (h[0] = (p) => i("select-chart-range", p)),
875
- onZoomTimeRange: h[1] || (h[1] = (p) => i("zoom-time-range", p))
874
+ onSelectChartRange: u[0] || (u[0] = (m) => i("select-chart-range", m)),
875
+ onZoomTimeRange: u[1] || (u[1] = (m) => i("zoom-time-range", m))
876
876
  }), Qe({ _: 2 }, [
877
877
  a.context.editable ? {
878
878
  name: "menu-items",
879
879
  fn: $(() => [
880
880
  ue(l, { onClick: n }, {
881
881
  default: $(() => [
882
- ht(ne(x(s).t("renderer.edit")), 1)
882
+ ht(ne(E(s).t("renderer.edit")), 1)
883
883
  ]),
884
884
  _: 1
885
885
  })
@@ -905,15 +905,15 @@ const ye = {
905
905
  requestsLink: {},
906
906
  exploreLink: {}
907
907
  },
908
- setup(d) {
909
- return (e, t) => (C(), O(ft, {
910
- "chart-options": e.chartOptions,
911
- context: e.context,
908
+ setup(a) {
909
+ return (e, t) => (x(), O(ft, {
910
+ "chart-options": a.chartOptions,
911
+ context: a.context,
912
912
  "extra-props": { showAnnotations: !1 },
913
- height: e.height,
914
- query: e.query,
915
- "query-ready": e.queryReady,
916
- "refresh-counter": e.refreshCounter
913
+ height: a.height,
914
+ query: a.query,
915
+ "query-ready": a.queryReady,
916
+ "refresh-counter": a.refreshCounter
917
917
  }, null, 8, ["chart-options", "context", "height", "query", "query-ready", "refresh-counter"]));
918
918
  }
919
919
  }), St = /* @__PURE__ */ Z({
@@ -929,17 +929,17 @@ const ye = {
929
929
  exploreLink: {}
930
930
  },
931
931
  emits: ["zoom-time-range", "select-chart-range"],
932
- setup(d, { emit: e }) {
932
+ setup(a, { emit: e }) {
933
933
  const t = e;
934
- return (i, s) => (C(), O(ft, {
935
- "chart-options": i.chartOptions,
936
- context: i.context,
937
- "explore-link": i.exploreLink,
938
- height: i.height,
939
- query: i.query,
940
- "query-ready": i.queryReady,
941
- "refresh-counter": i.refreshCounter,
942
- "requests-link": i.requestsLink,
934
+ return (i, s) => (x(), O(ft, {
935
+ "chart-options": a.chartOptions,
936
+ context: a.context,
937
+ "explore-link": a.exploreLink,
938
+ height: a.height,
939
+ query: a.query,
940
+ "query-ready": a.queryReady,
941
+ "refresh-counter": a.refreshCounter,
942
+ "requests-link": a.requestsLink,
943
943
  onSelectChartRange: s[0] || (s[0] = (r) => t("select-chart-range", r)),
944
944
  onZoomTimeRange: s[1] || (s[1] = (r) => t("zoom-time-range", r))
945
945
  }, null, 8, ["chart-options", "context", "explore-link", "height", "query", "query-ready", "refresh-counter", "requests-link"]));
@@ -956,11 +956,11 @@ const ye = {
956
956
  requestsLink: {},
957
957
  exploreLink: {}
958
958
  },
959
- setup(d) {
960
- const e = d, t = k(() => {
959
+ setup(a) {
960
+ const e = a, t = k(() => {
961
961
  const s = e.context.timeSpec;
962
962
  if (s.type === "absolute")
963
- return new pi({
963
+ return new mi({
964
964
  key: "custom",
965
965
  timeframeText: "custom",
966
966
  display: "custom",
@@ -994,10 +994,10 @@ const ye = {
994
994
  refreshCounter: e.refreshCounter
995
995
  };
996
996
  });
997
- return (s, r) => (C(), K("div", us, [
998
- ue(x(Ni), hi(ui(i.value)), {
997
+ return (s, r) => (x(), K("div", us, [
998
+ ue(E(Ni), hi(ui(i.value)), {
999
999
  default: $(() => [
1000
- ue(x(Li))
1000
+ ue(E(Li))
1001
1001
  ]),
1002
1002
  _: 1
1003
1003
  }, 16)
@@ -1011,10 +1011,10 @@ const ye = {
1011
1011
  props: {
1012
1012
  entityLinkData: {}
1013
1013
  },
1014
- setup(d) {
1015
- return (e, t) => (C(), K("div", gs, ne(e.entityLinkData.label), 1));
1014
+ setup(a) {
1015
+ return (e, t) => (x(), K("div", gs, ne(a.entityLinkData.label), 1));
1016
1016
  }
1017
- }), ps = /* @__PURE__ */ Z({
1017
+ }), ms = /* @__PURE__ */ Z({
1018
1018
  __name: "TopNTableRenderer",
1019
1019
  props: {
1020
1020
  query: {},
@@ -1026,8 +1026,8 @@ const ye = {
1026
1026
  requestsLink: {},
1027
1027
  exploreLink: {}
1028
1028
  },
1029
- setup(d) {
1030
- const e = d, t = ve(pe), i = Pt(async () => {
1029
+ setup(a) {
1030
+ const e = a, t = ve(me), i = Pt(async () => {
1031
1031
  if (t != null && t.fetchComponent)
1032
1032
  try {
1033
1033
  return await t.fetchComponent("EntityLink");
@@ -1039,33 +1039,33 @@ const ye = {
1039
1039
  var o;
1040
1040
  if ((o = e.chartOptions) != null && o.entity_link)
1041
1041
  if (r.id.includes(":")) {
1042
- const [n, u] = r.id.split(":");
1043
- return e.chartOptions.entity_link.replace(Bi, n).replace(Rt, u);
1042
+ const [n, d] = r.id.split(":");
1043
+ return e.chartOptions.entity_link.replace(Bi, n).replace(Rt, d);
1044
1044
  } else
1045
1045
  return e.chartOptions.entity_link.replace(Rt, r.id);
1046
1046
  return "";
1047
1047
  };
1048
- return (r, o) => (C(), O(ct, {
1049
- context: r.context,
1050
- query: r.query,
1051
- "query-ready": r.queryReady,
1052
- "refresh-counter": r.refreshCounter
1048
+ return (r, o) => (x(), O(ct, {
1049
+ context: a.context,
1050
+ query: a.query,
1051
+ "query-ready": a.queryReady,
1052
+ "refresh-counter": a.refreshCounter
1053
1053
  }, {
1054
1054
  default: $(({ data: n }) => [
1055
- ue(x(wi), {
1055
+ ue(E(wi), {
1056
1056
  data: n,
1057
- "synthetics-data-key": r.chartOptions.synthetics_data_key
1057
+ "synthetics-data-key": a.chartOptions.synthetics_data_key
1058
1058
  }, Qe({ _: 2 }, [
1059
1059
  e.chartOptions.entity_link ? {
1060
1060
  name: "name",
1061
- fn: $(({ record: u }) => [
1062
- ue(x(i), {
1061
+ fn: $(({ record: d }) => [
1062
+ ue(E(i), {
1063
1063
  "entity-link-data": {
1064
- id: u.id,
1065
- label: u.name,
1066
- deleted: u.deleted
1064
+ id: d.id,
1065
+ label: d.name,
1066
+ deleted: d.deleted
1067
1067
  },
1068
- "external-link": s(u)
1068
+ "external-link": s(d)
1069
1069
  }, null, 8, ["entity-link-data", "external-link"])
1070
1070
  ]),
1071
1071
  key: "0"
@@ -1075,7 +1075,7 @@ const ye = {
1075
1075
  _: 1
1076
1076
  }, 8, ["context", "query", "query-ready", "refresh-counter"]));
1077
1077
  }
1078
- }), ms = /* @__PURE__ */ Z({
1078
+ }), ps = /* @__PURE__ */ Z({
1079
1079
  __name: "DonutChartRenderer",
1080
1080
  props: {
1081
1081
  query: {},
@@ -1087,14 +1087,14 @@ const ye = {
1087
1087
  requestsLink: {},
1088
1088
  exploreLink: {}
1089
1089
  },
1090
- setup(d) {
1091
- return (e, t) => (C(), O(ft, {
1092
- "chart-options": e.chartOptions,
1093
- context: e.context,
1094
- height: e.height,
1095
- query: e.query,
1096
- "query-ready": e.queryReady,
1097
- "refresh-counter": e.refreshCounter
1090
+ setup(a) {
1091
+ return (e, t) => (x(), O(ft, {
1092
+ "chart-options": a.chartOptions,
1093
+ context: a.context,
1094
+ height: a.height,
1095
+ query: a.query,
1096
+ "query-ready": a.queryReady,
1097
+ "refresh-counter": a.refreshCounter
1098
1098
  }, null, 8, ["chart-options", "context", "height", "query", "query-ready", "refresh-counter"]));
1099
1099
  }
1100
1100
  }), ys = ["data-testid"], vs = {
@@ -1112,14 +1112,14 @@ const ye = {
1112
1112
  tileId: {}
1113
1113
  },
1114
1114
  emits: ["edit-tile", "duplicate-tile", "remove-tile", "tile-time-range-zoom"],
1115
- setup(d, { emit: e }) {
1116
- Ye((v) => ({
1117
- "1eb84fc4": `${v.height}px`
1115
+ setup(a, { emit: e }) {
1116
+ Ye((w) => ({
1117
+ v1eb84fc4: `${w.height}px`
1118
1118
  }));
1119
- const t = parseInt(ei, 10), i = d, s = e, r = Pt(() => import("./GeoMapRenderer-Do3o2zvx.js")), o = ve(pe), { i18n: n } = ye.useI18n(), u = H(), a = H({ status: "loading" }), h = H(!1), l = H(), f = H(!1), p = H(!0), {
1119
+ const t = parseInt(ei, 10), i = a, s = e, r = Pt(() => import("./GeoMapRenderer-BRvbFVZX.js")), o = ve(me), { i18n: n } = ye.useI18n(), d = H(), h = H({ status: "loading" }), u = H(!1), l = H(), f = H(!1), m = H(!0), {
1120
1120
  exploreLinkKebabMenu: g,
1121
1121
  requestsLinkKebabMenu: y,
1122
- canShowKebabMenu: m,
1122
+ canShowKebabMenu: p,
1123
1123
  canGenerateRequestsLink: D,
1124
1124
  canGenerateExploreLink: P,
1125
1125
  requestsLinkZoomActions: z,
@@ -1130,36 +1130,36 @@ const ye = {
1130
1130
  buildRequestsQueryZoomActions: Y
1131
1131
  } = ye.useContextLinks({
1132
1132
  queryBridge: o,
1133
- chartData: st(u),
1133
+ chartData: st(d),
1134
1134
  definition: st(wt(i, "definition")),
1135
1135
  context: st(wt(i, "context"))
1136
1136
  }), { issueQuery: de } = ye.useIssueQuery();
1137
1137
  ze(() => i.definition, async () => {
1138
- await ut(), l.value && (f.value = l.value.scrollWidth > l.value.clientWidth), p.value = !0;
1138
+ await ut(), l.value && (f.value = l.value.scrollWidth > l.value.clientWidth), m.value = !0;
1139
1139
  }, { immediate: !0, deep: !0 });
1140
- const Me = k(() => n.t("csvExport.defaultFilename")), J = k(() => m.value && (Ie.value || i.context.editable) || !!q.value), Ie = k(() => !!g.value || ("allow_csv_export" in i.definition.chart ? i.definition.chart.allow_csv_export : !0) || i.context.editable), E = {
1140
+ const Me = k(() => n.t("csvExport.defaultFilename")), J = k(() => p.value && (Ie.value || i.context.editable) || !!q.value), Ie = k(() => !!g.value || ("allow_csv_export" in i.definition.chart ? i.definition.chart.allow_csv_export : !0) || i.context.editable), C = {
1141
1141
  timeseries_line: St,
1142
1142
  timeseries_bar: St,
1143
1143
  horizontal_bar: Dt,
1144
1144
  vertical_bar: Dt,
1145
1145
  gauge: zt,
1146
- donut: ms,
1146
+ donut: ps,
1147
1147
  golden_signals: cs,
1148
- top_n: ps,
1148
+ top_n: ms,
1149
1149
  slottable: void 0,
1150
1150
  single_value: zt,
1151
1151
  choropleth_map: r
1152
1152
  }, S = k(() => {
1153
- var v, L;
1153
+ var w, L;
1154
1154
  return {
1155
- ...(v = N.value) != null && v.rendererEvents.supportsRequests ? { "select-chart-range": ri } : {},
1155
+ ...(w = N.value) != null && w.rendererEvents.supportsRequests ? { "select-chart-range": ri } : {},
1156
1156
  ...(L = N.value) != null && L.rendererEvents.supportsZoom ? { "zoom-time-range": si } : {}
1157
1157
  };
1158
1158
  }), N = k(() => {
1159
1159
  var te, j;
1160
- const v = E[i.definition.chart.type], L = !!((te = v == null ? void 0 : v.emits) != null && te.includes("select-chart-range")), A = !!((j = v == null ? void 0 : v.emits) != null && j.includes("zoom-time-range"));
1161
- return v && {
1162
- component: v,
1160
+ const w = C[i.definition.chart.type], L = !!((te = w == null ? void 0 : w.emits) != null && te.includes("select-chart-range")), A = !!((j = w == null ? void 0 : w.emits) != null && j.includes("zoom-time-range"));
1161
+ return w && {
1162
+ component: w,
1163
1163
  rendererProps: {
1164
1164
  query: i.definition.query,
1165
1165
  context: i.context,
@@ -1177,95 +1177,95 @@ const ye = {
1177
1177
  };
1178
1178
  }), q = k(() => {
1179
1179
  var L;
1180
- const v = (L = i.definition.query) == null ? void 0 : L.time_range;
1181
- if ((v == null ? void 0 : v.type) === "relative") {
1182
- const A = Bt.get(mi[v.time_range]);
1183
- return A ? A.display : (console.warn("Did not recognize the given relative time range:", v.time_range), v.time_range);
1184
- } else if ((v == null ? void 0 : v.type) === "absolute") {
1185
- const A = v.tz || "Etc/UTC";
1186
- return `${Ct(v.start, { short: !0, tz: A })} - ${Ct(v.end, { short: !0, tz: A })}`;
1180
+ const w = (L = i.definition.query) == null ? void 0 : L.time_range;
1181
+ if ((w == null ? void 0 : w.type) === "relative") {
1182
+ const A = Bt.get(pi[w.time_range]);
1183
+ return A ? A.display : (console.warn("Did not recognize the given relative time range:", w.time_range), w.time_range);
1184
+ } else if ((w == null ? void 0 : w.type) === "absolute") {
1185
+ const A = w.tz || "Etc/UTC";
1186
+ return `${Ct(w.start, { short: !0, tz: A })} - ${Ct(w.end, { short: !0, tz: A })}`;
1187
1187
  }
1188
1188
  return null;
1189
- }), ee = k(() => u.value ? rt(u.value.meta.granularity_ms) : void 0), me = k(() => ["timeseries_line", "timeseries_bar"].includes(i.definition.chart.type)), Re = k(() => {
1189
+ }), ee = k(() => d.value ? rt(d.value.meta.granularity_ms) : void 0), pe = k(() => ["timeseries_line", "timeseries_bar"].includes(i.definition.chart.type)), Re = k(() => {
1190
1190
  var L, A;
1191
- if (!me.value || !i.queryReady || p.value)
1191
+ if (!pe.value || !i.queryReady || m.value)
1192
1192
  return !1;
1193
- const v = (A = (L = i.definition) == null ? void 0 : L.query) == null ? void 0 : A.granularity;
1194
- return !v || !ee.value ? !1 : v !== ee.value;
1193
+ const w = (A = (L = i.definition) == null ? void 0 : L.query) == null ? void 0 : A.granularity;
1194
+ return !w || !ee.value ? !1 : w !== ee.value;
1195
1195
  }), Pe = k(() => {
1196
1196
  var A, te, j;
1197
- const v = rt(((A = u.value) == null ? void 0 : A.meta.granularity_ms) ?? 0) ?? "unknown", L = ((j = (te = i.definition) == null ? void 0 : te.query) == null ? void 0 : j.granularity) ?? "unknown";
1197
+ const w = rt(((A = d.value) == null ? void 0 : A.meta.granularity_ms) ?? 0) ?? "unknown", L = ((j = (te = i.definition) == null ? void 0 : te.query) == null ? void 0 : j.granularity) ?? "unknown";
1198
1198
  return n.t("query_aged_out_warning", {
1199
- currentGranularity: n.t(`granularities.${v}`),
1199
+ currentGranularity: n.t(`granularities.${w}`),
1200
1200
  savedGranularity: n.t(`granularities.${L}`)
1201
1201
  });
1202
1202
  }), ke = k(() => {
1203
1203
  var A, te;
1204
- const v = [...i.context.filters, ...i.definition.query.filters ?? []], L = ((te = (A = i.definition) == null ? void 0 : A.query) == null ? void 0 : te.datasource) ?? "api_usage";
1205
- return v.filter((j) => Ft(j.field).some((ni) => L === ni));
1204
+ const w = [...i.context.filters, ...i.definition.query.filters ?? []], L = ((te = (A = i.definition) == null ? void 0 : A.query) == null ? void 0 : te.datasource) ?? "api_usage";
1205
+ return w.filter((j) => Ft(j.field).some((ni) => L === ni));
1206
1206
  }), Je = () => {
1207
1207
  s("edit-tile", i.definition);
1208
- }, mt = () => {
1208
+ }, pt = () => {
1209
1209
  s("duplicate-tile", i.definition);
1210
1210
  }, et = () => {
1211
1211
  s("remove-tile", i.definition);
1212
- }, tt = (v) => {
1213
- u.value = v, p.value = !1;
1212
+ }, tt = (w) => {
1213
+ d.value = w, m.value = !1;
1214
1214
  }, yt = () => {
1215
- h.value = !1;
1215
+ u.value = !1;
1216
1216
  }, ii = async () => {
1217
- var v;
1218
- if (h.value = !0, a.value = { status: "loading" }, ((v = o == null ? void 0 : o.staticConfig) == null ? void 0 : v.increaseCsvExportLimit) ?? !0)
1217
+ var w;
1218
+ if (u.value = !0, h.value = { status: "loading" }, ((w = o == null ? void 0 : o.staticConfig) == null ? void 0 : w.increaseCsvExportLimit) ?? !0)
1219
1219
  de(i.definition.query, i.context, yi).then((L) => {
1220
- a.value = { status: "success", chartData: L };
1220
+ h.value = { status: "success", chartData: L };
1221
1221
  }).catch((L) => {
1222
- a.value = { status: "error", error: L };
1222
+ h.value = { status: "error", error: L };
1223
1223
  });
1224
- else if (u.value)
1225
- a.value = { status: "success", chartData: u.value };
1224
+ else if (d.value)
1225
+ h.value = { status: "success", chartData: d.value };
1226
1226
  else {
1227
- const L = ze(u, (A) => {
1228
- A && (a.value = { status: "success", chartData: A }, L());
1227
+ const L = ze(d, (A) => {
1228
+ A && (h.value = { status: "success", chartData: A }, L());
1229
1229
  });
1230
1230
  }
1231
- }, si = (v) => {
1231
+ }, si = (w) => {
1232
1232
  const L = {
1233
1233
  tileId: i.tileId.toString(),
1234
- timeRange: v
1234
+ timeRange: w
1235
1235
  };
1236
1236
  s("tile-time-range-zoom", L);
1237
- }, ri = (v) => {
1238
- const L = ke.value, A = Y(v, L), te = B(v, L);
1237
+ }, ri = (w) => {
1238
+ const L = ke.value, A = Y(w, L), te = B(w, L);
1239
1239
  z.value = D.value ? { href: M(A) } : void 0, Q.value = P.value ? { href: R(te) } : void 0;
1240
1240
  };
1241
- return (v, L) => {
1241
+ return (w, L) => {
1242
1242
  const A = ge("KTooltip"), te = ge("KBadge"), j = ge("KDropdownItem"), vt = ge("KDropdown");
1243
- return C(), K("div", {
1244
- class: je(["tile-boundary", { editable: v.context.editable }]),
1245
- "data-testid": `tile-${v.tileId}`
1243
+ return x(), K("div", {
1244
+ class: je(["tile-boundary", { editable: a.context.editable }]),
1245
+ "data-testid": `tile-${a.tileId}`
1246
1246
  }, [
1247
- v.definition.chart.type !== "slottable" ? (C(), K("div", vs, [
1247
+ a.definition.chart.type !== "slottable" ? (x(), K("div", vs, [
1248
1248
  ue(A, {
1249
1249
  class: "title-tooltip",
1250
1250
  disabled: !f.value,
1251
1251
  "max-width": "500",
1252
- text: v.definition.chart.chart_title
1252
+ text: a.definition.chart.chart_title
1253
1253
  }, {
1254
1254
  default: $(() => [
1255
1255
  oe("div", {
1256
1256
  ref_key: "titleRef",
1257
1257
  ref: l,
1258
1258
  class: "title"
1259
- }, ne(v.definition.chart.chart_title), 513)
1259
+ }, ne(a.definition.chart.chart_title), 513)
1260
1260
  ]),
1261
1261
  _: 1
1262
1262
  }, 8, ["disabled", "text"]),
1263
- J.value ? (C(), K("div", {
1263
+ J.value ? (x(), K("div", {
1264
1264
  key: 0,
1265
1265
  class: "tile-actions",
1266
- "data-testid": `tile-actions-${v.tileId}`
1266
+ "data-testid": `tile-actions-${a.tileId}`
1267
1267
  }, [
1268
- q.value ? (C(), O(te, {
1268
+ q.value ? (x(), O(te, {
1269
1269
  key: 0,
1270
1270
  "data-testid": "time-range-badge",
1271
1271
  tooltip: Re.value ? Pe.value : void 0,
@@ -1279,113 +1279,113 @@ const ye = {
1279
1279
  Re.value ? {
1280
1280
  name: "icon",
1281
1281
  fn: $(() => [
1282
- ue(x(zi), { size: x(fs) }, null, 8, ["size"])
1282
+ ue(E(zi), { size: E(fs) }, null, 8, ["size"])
1283
1283
  ]),
1284
1284
  key: "0"
1285
1285
  } : void 0
1286
1286
  ]), 1032, ["tooltip"])) : V("", !0),
1287
- x(m) && v.context.editable && !v.isFullscreen ? (C(), O(x(Di), {
1287
+ E(p) && a.context.editable && !a.isFullscreen ? (x(), O(E(Di), {
1288
1288
  key: 1,
1289
1289
  class: "edit-icon",
1290
- color: x(Nt),
1291
- "data-testid": `edit-tile-${v.tileId}`,
1292
- size: x(Lt),
1290
+ color: E(Nt),
1291
+ "data-testid": `edit-tile-${a.tileId}`,
1292
+ size: E(Lt),
1293
1293
  onClick: Je
1294
1294
  }, null, 8, ["color", "data-testid", "size"])) : V("", !0),
1295
- x(m) && Ie.value && !v.isFullscreen ? (C(), O(vt, {
1295
+ E(p) && Ie.value && !a.isFullscreen ? (x(), O(vt, {
1296
1296
  key: 2,
1297
1297
  class: "dropdown",
1298
- "data-testid": `chart-action-menu-${v.tileId}`,
1298
+ "data-testid": `chart-action-menu-${a.tileId}`,
1299
1299
  "kpop-attributes": { placement: "bottom-end" }
1300
1300
  }, {
1301
1301
  items: $(() => [
1302
- x(g) ? (C(), O(j, {
1302
+ E(g) ? (x(), O(j, {
1303
1303
  key: 0,
1304
- "data-testid": `chart-jump-to-explore-${v.tileId}`,
1305
- item: { label: x(n).t("jumpToExplore"), to: x(g) }
1304
+ "data-testid": `chart-jump-to-explore-${a.tileId}`,
1305
+ item: { label: E(n).t("jumpToExplore"), to: E(g) }
1306
1306
  }, null, 8, ["data-testid", "item"])) : V("", !0),
1307
- x(y) ? (C(), O(j, {
1307
+ E(y) ? (x(), O(j, {
1308
1308
  key: 1,
1309
- "data-testid": `chart-jump-to-requests-${v.tileId}`,
1310
- item: { label: x(n).t("jumpToRequests"), to: x(y) }
1309
+ "data-testid": `chart-jump-to-requests-${a.tileId}`,
1310
+ item: { label: E(n).t("jumpToRequests"), to: E(y) }
1311
1311
  }, null, 8, ["data-testid", "item"])) : V("", !0),
1312
- !("allow_csv_export" in v.definition.chart) || v.definition.chart.allow_csv_export ? (C(), O(j, {
1312
+ !("allow_csv_export" in a.definition.chart) || a.definition.chart.allow_csv_export ? (x(), O(j, {
1313
1313
  key: 2,
1314
1314
  class: "chart-export-button",
1315
- "data-testid": `chart-csv-export-${v.tileId}`,
1315
+ "data-testid": `chart-csv-export-${a.tileId}`,
1316
1316
  onClick: ii
1317
1317
  }, {
1318
1318
  default: $(() => [
1319
1319
  oe("span", {
1320
1320
  class: "chart-export-trigger",
1321
- "data-testid": `csv-export-button-${v.tileId}`
1322
- }, ne(x(n).t("csvExport.exportAsCsv")), 9, ws)
1321
+ "data-testid": `csv-export-button-${a.tileId}`
1322
+ }, ne(E(n).t("csvExport.exportAsCsv")), 9, ws)
1323
1323
  ]),
1324
1324
  _: 1
1325
1325
  }, 8, ["data-testid"])) : V("", !0),
1326
- v.context.editable ? (C(), O(j, {
1326
+ a.context.editable ? (x(), O(j, {
1327
1327
  key: 3,
1328
- "data-testid": `duplicate-tile-${v.tileId}`,
1329
- onClick: mt
1328
+ "data-testid": `duplicate-tile-${a.tileId}`,
1329
+ onClick: pt
1330
1330
  }, {
1331
1331
  default: $(() => [
1332
- ht(ne(x(n).t("renderer.duplicateTile")), 1)
1332
+ ht(ne(E(n).t("renderer.duplicateTile")), 1)
1333
1333
  ]),
1334
1334
  _: 1
1335
1335
  }, 8, ["data-testid"])) : V("", !0),
1336
- v.context.editable ? (C(), O(j, {
1336
+ a.context.editable ? (x(), O(j, {
1337
1337
  key: 4,
1338
- "data-testid": `remove-tile-${v.tileId}`,
1338
+ "data-testid": `remove-tile-${a.tileId}`,
1339
1339
  onClick: et
1340
1340
  }, {
1341
1341
  default: $(() => [
1342
- oe("span", Es, ne(x(n).t("renderer.delete")), 1)
1342
+ oe("span", Es, ne(E(n).t("renderer.delete")), 1)
1343
1343
  ]),
1344
1344
  _: 1
1345
1345
  }, 8, ["data-testid"])) : V("", !0)
1346
1346
  ]),
1347
1347
  default: $(() => [
1348
- ue(x(Si), {
1348
+ ue(E(Si), {
1349
1349
  class: "kebab-action-menu",
1350
- color: x(Nt),
1351
- "data-testid": `kebab-action-menu-${v.tileId}`,
1352
- size: x(Lt)
1350
+ color: E(Nt),
1351
+ "data-testid": `kebab-action-menu-${a.tileId}`,
1352
+ size: E(Lt)
1353
1353
  }, null, 8, ["color", "data-testid", "size"])
1354
1354
  ]),
1355
1355
  _: 1
1356
1356
  }, 8, ["data-testid"])) : V("", !0)
1357
- ], 8, _s)) : "description" in v.definition.chart ? (C(), K("div", {
1357
+ ], 8, _s)) : "description" in a.definition.chart ? (x(), K("div", {
1358
1358
  key: 1,
1359
1359
  class: "header-description",
1360
- "data-testid": `tile-description-${v.tileId}`
1361
- }, ne(v.definition.chart.description), 9, xs)) : V("", !0),
1362
- h.value ? (C(), O(x(Ei), {
1360
+ "data-testid": `tile-description-${a.tileId}`
1361
+ }, ne(a.definition.chart.description), 9, xs)) : V("", !0),
1362
+ u.value ? (x(), O(E(Ei), {
1363
1363
  key: 2,
1364
- "data-testid": `csv-export-modal-${v.tileId}`,
1365
- "export-state": a.value,
1364
+ "data-testid": `csv-export-modal-${a.tileId}`,
1365
+ "export-state": h.value,
1366
1366
  filename: Me.value,
1367
1367
  onCloseModal: yt
1368
1368
  }, null, 8, ["data-testid", "export-state", "filename"])) : V("", !0)
1369
1369
  ])) : V("", !0),
1370
1370
  oe("div", {
1371
1371
  class: "tile-content",
1372
- "data-testid": `tile-content-${v.tileId}`
1372
+ "data-testid": `tile-content-${a.tileId}`
1373
1373
  }, [
1374
- N.value ? (C(), O(qt(N.value.component), It({ key: 0 }, N.value.rendererProps, di(S.value), { onChartData: tt }), null, 16)) : V("", !0)
1374
+ N.value ? (x(), O(qt(N.value.component), It({ key: 0 }, N.value.rendererProps, di(S.value), { onChartData: tt }), null, 16)) : V("", !0)
1375
1375
  ], 8, Cs)
1376
1376
  ], 10, ys);
1377
1377
  };
1378
1378
  }
1379
- }), ks = /* @__PURE__ */ _e(Rs, [["__scopeId", "data-v-543445fd"]]), Ts = (d, e) => {
1379
+ }), ks = /* @__PURE__ */ _e(Rs, [["__scopeId", "data-v-543445fd"]]), Ts = (a, e) => {
1380
1380
  let t = 0;
1381
1381
  const i = /* @__PURE__ */ new Map();
1382
1382
  e.forEach((r) => {
1383
- const o = r.layout.position.row, n = i.get(o), u = r.layout.size.rows === 1 && !!r.layout.size.fit_to_content;
1384
- t = Math.max(t, o + r.layout.size.rows), n === void 0 ? i.set(o, u) : i.set(o, n && u);
1383
+ const o = r.layout.position.row, n = i.get(o), d = r.layout.size.rows === 1 && !!r.layout.size.fit_to_content;
1384
+ t = Math.max(t, o + r.layout.size.rows), n === void 0 ? i.set(o, d) : i.set(o, n && d);
1385
1385
  });
1386
1386
  const s = [];
1387
1387
  for (let r = 0; r < t; r++)
1388
- i.get(r) ? s.push("auto") : s.push(`${d}px`);
1388
+ i.get(r) ? s.push("auto") : s.push(`${a}px`);
1389
1389
  return s;
1390
1390
  }, zs = /* @__PURE__ */ Z({
1391
1391
  __name: "GridLayout",
@@ -1400,12 +1400,12 @@ const ye = {
1400
1400
  required: !0
1401
1401
  }
1402
1402
  },
1403
- setup(d) {
1403
+ setup(a) {
1404
1404
  Ye((n) => ({
1405
- "2a38e79e": x(Wt),
1406
- "4cc71de6": r.value
1405
+ v2a38e79e: E(Wt),
1406
+ v4cc71de6: r.value
1407
1407
  }));
1408
- const e = d, t = H(null), i = H(0), s = new ResizeObserver((n) => {
1408
+ const e = a, t = H(null), i = H(0), s = new ResizeObserver((n) => {
1409
1409
  window.requestAnimationFrame(() => {
1410
1410
  !Array.isArray(n) || !n.length || (i.value = n[0].contentRect.width);
1411
1411
  });
@@ -1415,8 +1415,8 @@ const ye = {
1415
1415
  }), lt(() => {
1416
1416
  t.value && s.unobserve(t.value);
1417
1417
  });
1418
- const r = k(() => Ts(e.tileHeight, e.tiles).join(" ")), o = k(() => e.tiles.map((n, u) => ({
1419
- key: `tile-${u}`,
1418
+ const r = k(() => Ts(e.tileHeight, e.tiles).join(" ")), o = k(() => e.tiles.map((n, d) => ({
1419
+ key: `tile-${d}`,
1420
1420
  tile: n,
1421
1421
  style: {
1422
1422
  "grid-column-start": n.layout.position.col + 1,
@@ -1425,28 +1425,28 @@ const ye = {
1425
1425
  "grid-row-end": n.layout.position.row + 1 + n.layout.size.rows
1426
1426
  }
1427
1427
  })));
1428
- return (n, u) => (C(), K("div", {
1428
+ return (n, d) => (x(), K("div", {
1429
1429
  ref_key: "gridContainer",
1430
1430
  ref: t,
1431
1431
  class: "kong-ui-public-grid-layout"
1432
1432
  }, [
1433
- (C(!0), K($t, null, Gt(o.value, (a) => (C(), K("div", {
1434
- key: a.key,
1433
+ (x(!0), K($t, null, Gt(o.value, (h) => (x(), K("div", {
1434
+ key: h.key,
1435
1435
  class: je(["grid-cell", {
1436
- "empty-cell": !a.tile
1436
+ "empty-cell": !h.tile
1437
1437
  }]),
1438
- style: Et(a.style)
1438
+ style: Et(h.style)
1439
1439
  }, [
1440
1440
  De(n.$slots, "tile", {
1441
- style: Et(a.style),
1442
- tile: a.tile
1441
+ style: Et(h.style),
1442
+ tile: h.tile
1443
1443
  }, void 0, !0)
1444
1444
  ], 6))), 128))
1445
1445
  ], 512));
1446
1446
  }
1447
1447
  }), Ds = /* @__PURE__ */ _e(zs, [["__scopeId", "data-v-354b7177"]]);
1448
- function Ss(d, e, t, i, s) {
1449
- const r = (...o) => (console.warn("gridstack.js: Function `" + t + "` is deprecated in " + s + " and has been replaced with `" + i + "`. It will be **removed** in a future release"), e.apply(d, o));
1448
+ function Ss(a, e, t, i, s) {
1449
+ const r = (...o) => (console.warn("gridstack.js: Function `" + t + "` is deprecated in " + s + " and has been replaced with `" + i + "`. It will be **removed** in a future release"), e.apply(a, o));
1450
1450
  return r.prototype = e.prototype, r;
1451
1451
  }
1452
1452
  class c {
@@ -1652,10 +1652,10 @@ class c {
1652
1652
  static updateScrollPosition(e, t, i) {
1653
1653
  const s = e.getBoundingClientRect(), r = window.innerHeight || document.documentElement.clientHeight;
1654
1654
  if (s.top < 0 || s.bottom > r) {
1655
- const o = s.bottom - r, n = s.top, u = this.getScrollElement(e);
1656
- if (u !== null) {
1657
- const a = u.scrollTop;
1658
- s.top < 0 && i < 0 ? e.offsetHeight > r ? u.scrollTop += i : u.scrollTop += Math.abs(n) > Math.abs(i) ? i : n : i > 0 && (e.offsetHeight > r ? u.scrollTop += i : u.scrollTop += o > i ? i : o), t.top += u.scrollTop - a;
1655
+ const o = s.bottom - r, n = s.top, d = this.getScrollElement(e);
1656
+ if (d !== null) {
1657
+ const h = d.scrollTop;
1658
+ s.top < 0 && i < 0 ? e.offsetHeight > r ? d.scrollTop += i : d.scrollTop += Math.abs(n) > Math.abs(i) ? i : n : i > 0 && (e.offsetHeight > r ? d.scrollTop += i : d.scrollTop += o > i ? i : o), t.top += d.scrollTop - h;
1659
1659
  }
1660
1660
  }
1661
1661
  }
@@ -1667,8 +1667,8 @@ class c {
1667
1667
  * @param distance Distance from the V edges to start scrolling
1668
1668
  */
1669
1669
  static updateScrollResize(e, t, i) {
1670
- const s = this.getScrollElement(t), r = s.clientHeight, o = s === this.getScrollElement() ? 0 : s.getBoundingClientRect().top, n = e.clientY - o, u = n < i, a = n > r - i;
1671
- u ? s.scrollBy({ behavior: "smooth", top: n - i }) : a && s.scrollBy({ behavior: "smooth", top: i - (r - n) });
1670
+ const s = this.getScrollElement(t), r = s.clientHeight, o = s === this.getScrollElement() ? 0 : s.getBoundingClientRect().top, n = e.clientY - o, d = n < i, h = n > r - i;
1671
+ d ? s.scrollBy({ behavior: "smooth", top: n - i }) : h && s.scrollBy({ behavior: "smooth", top: i - (r - n) });
1672
1672
  }
1673
1673
  /** single level clone, returning a new object with same top fields. This will share sub objects and arrays */
1674
1674
  static clone(e) {
@@ -1807,19 +1807,19 @@ class le {
1807
1807
  !this._loading && this._useEntireRowArea(e, t) && (r = { x: 0, w: this.column, y: t.y, h: t.h }, i = this.collide(e, r, s.skip));
1808
1808
  let o = !1;
1809
1809
  const n = { nested: !0, pack: !1 };
1810
- let u = 0;
1810
+ let d = 0;
1811
1811
  for (; i = i || this.collide(e, r, s.skip); ) {
1812
- if (u++ > this.nodes.length * 2)
1812
+ if (d++ > this.nodes.length * 2)
1813
1813
  throw new Error("Infinite collide check");
1814
- let a;
1814
+ let h;
1815
1815
  if (i.locked || this._loading || e._moving && !e._skipDown && t.y > e.y && !this.float && // can take space we had, or before where we're going
1816
1816
  (!this.collide(i, { ...i, y: e.y }, e) || !this.collide(i, { ...i, y: t.y - i.h }, e))) {
1817
1817
  e._skipDown = e._skipDown || t.y > e.y;
1818
- const h = { ...t, y: i.y + i.h, ...n };
1819
- a = this._loading && c.samePos(e, h) ? !0 : this.moveNode(e, h), (i.locked || this._loading) && a ? c.copyPos(t, e) : !i.locked && a && s.pack && (this._packNodes(), t.y = i.y + i.h, c.copyPos(e, t)), o = o || a;
1818
+ const u = { ...t, y: i.y + i.h, ...n };
1819
+ h = this._loading && c.samePos(e, u) ? !0 : this.moveNode(e, u), (i.locked || this._loading) && h ? c.copyPos(t, e) : !i.locked && h && s.pack && (this._packNodes(), t.y = i.y + i.h, c.copyPos(e, t)), o = o || h;
1820
1820
  } else
1821
- a = this.moveNode(i, { ...i, y: t.y + t.h, skip: e, ...n });
1822
- if (!a)
1821
+ h = this.moveNode(i, { ...i, y: t.y + t.h, skip: e, ...n });
1822
+ if (!h)
1823
1823
  return o;
1824
1824
  i = void 0;
1825
1825
  }
@@ -1841,14 +1841,14 @@ class le {
1841
1841
  const s = e._rect, r = { ...t.rect };
1842
1842
  r.y > s.y ? (r.h += r.y - s.y, r.y = s.y) : r.h += s.y - r.y, r.x > s.x ? (r.w += r.x - s.x, r.x = s.x) : r.w += s.x - r.x;
1843
1843
  let o, n = 0.5;
1844
- for (let u of i) {
1845
- if (u.locked || !u._rect)
1844
+ for (let d of i) {
1845
+ if (d.locked || !d._rect)
1846
1846
  break;
1847
- const a = u._rect;
1848
- let h = Number.MAX_VALUE, l = Number.MAX_VALUE;
1849
- s.y < a.y ? h = (r.y + r.h - a.y) / a.h : s.y + s.h > a.y + a.h && (h = (a.y + a.h - r.y) / a.h), s.x < a.x ? l = (r.x + r.w - a.x) / a.w : s.x + s.w > a.x + a.w && (l = (a.x + a.w - r.x) / a.w);
1850
- const f = Math.min(l, h);
1851
- f > n && (n = f, o = u);
1847
+ const h = d._rect;
1848
+ let u = Number.MAX_VALUE, l = Number.MAX_VALUE;
1849
+ s.y < h.y ? u = (r.y + r.h - h.y) / h.h : s.y + s.h > h.y + h.h && (u = (h.y + h.h - r.y) / h.h), s.x < h.x ? l = (r.x + r.w - h.x) / h.w : s.x + s.w > h.x + h.w && (l = (h.x + h.w - r.x) / h.w);
1850
+ const f = Math.min(l, u);
1851
+ f > n && (n = f, o = d);
1852
1852
  }
1853
1853
  return t.collide = o, o;
1854
1854
  }
@@ -1922,9 +1922,9 @@ class le {
1922
1922
  const s = this._inColumnResize;
1923
1923
  s || (this._inColumnResize = !0);
1924
1924
  const r = this.nodes;
1925
- return this.nodes = [], r.forEach((o, n, u) => {
1926
- let a;
1927
- o.locked || (o.autoPosition = !0, e === "list" && n && (a = u[n - 1])), this.addNode(o, !1, a);
1925
+ return this.nodes = [], r.forEach((o, n, d) => {
1926
+ let h;
1927
+ o.locked || (o.autoPosition = !0, e === "list" && n && (h = d[n - 1])), this.addNode(o, !1, h);
1928
1928
  }), s || delete this._inColumnResize, i || this.batchUpdate(!1), this;
1929
1929
  }
1930
1930
  /** enable/disable floating widgets (default: `false`) See [example](http://gridstackjs.com/demo/float.html) */
@@ -2022,11 +2022,11 @@ class le {
2022
2022
  const r = s ? s.y * i + (s.x + s.w) : 0;
2023
2023
  let o = !1;
2024
2024
  for (let n = r; !o; ++n) {
2025
- const u = n % i, a = Math.floor(n / i);
2026
- if (u + e.w > i)
2025
+ const d = n % i, h = Math.floor(n / i);
2026
+ if (d + e.w > i)
2027
2027
  continue;
2028
- const h = { x: u, y: a, w: e.w, h: e.h };
2029
- t.find((l) => c.isIntercepted(h, l)) || ((e.x !== u || e.y !== a) && (e._dirty = !0), e.x = u, e.y = a, delete e.autoPosition, o = !0);
2028
+ const u = { x: d, y: h, w: e.w, h: e.h };
2029
+ t.find((l) => c.isIntercepted(u, l)) || ((e.x !== d || e.y !== h) && (e._dirty = !0), e.x = d, e.y = h, delete e.autoPosition, o = !0);
2030
2030
  }
2031
2031
  return o;
2032
2032
  }
@@ -2072,7 +2072,7 @@ class le {
2072
2072
  return this._notify(), !0;
2073
2073
  }
2074
2074
  return r ? (s.nodes.filter((o) => o._dirty).forEach((o) => {
2075
- const n = this.nodes.find((u) => u._id === o._id);
2075
+ const n = this.nodes.find((d) => d._id === o._id);
2076
2076
  n && (c.copyPos(n, o), n._dirty = !0);
2077
2077
  }), this._notify(), !0) : !1;
2078
2078
  }
@@ -2093,7 +2093,7 @@ class le {
2093
2093
  }
2094
2094
  /** return true if the passed in node was actually moved (checks for no-op and locked) */
2095
2095
  moveNode(e, t) {
2096
- var a, h;
2096
+ var h, u;
2097
2097
  if (!e || /*node.locked ||*/
2098
2098
  !t)
2099
2099
  return !1;
@@ -2103,17 +2103,17 @@ class le {
2103
2103
  if (c.copyPos(r, t), this.nodeBoundFix(r, s), c.copyPos(t, r), !t.forceCollide && c.samePos(e, t))
2104
2104
  return !1;
2105
2105
  const o = c.copyPos({}, e), n = this.collideAll(e, r, t.skip);
2106
- let u = !0;
2106
+ let d = !0;
2107
2107
  if (n.length) {
2108
2108
  const l = e._moving && !t.nested;
2109
2109
  let f = l ? this.directionCollideCoverage(e, t, n) : n[0];
2110
- if (l && f && ((h = (a = e.grid) == null ? void 0 : a.opts) != null && h.subGridDynamic) && !e.grid._isTemp) {
2111
- const p = c.areaIntercept(t.rect, f._rect), g = c.area(t.rect), y = c.area(f._rect);
2112
- p / (g < y ? g : y) > 0.8 && (f.grid.makeSubGrid(f.el, void 0, e), f = void 0);
2110
+ if (l && f && ((u = (h = e.grid) == null ? void 0 : h.opts) != null && u.subGridDynamic) && !e.grid._isTemp) {
2111
+ const m = c.areaIntercept(t.rect, f._rect), g = c.area(t.rect), y = c.area(f._rect);
2112
+ m / (g < y ? g : y) > 0.8 && (f.grid.makeSubGrid(f.el, void 0, e), f = void 0);
2113
2113
  }
2114
- f ? u = !this._fixCollisions(e, r, f, t) : (u = !1, i && delete t.pack);
2114
+ f ? d = !this._fixCollisions(e, r, f, t) : (d = !1, i && delete t.pack);
2115
2115
  }
2116
- return u && !c.samePos(e, r) && (e._dirty = !0, c.copyPos(e, r)), t.pack && this._packNodes()._notify(), !c.samePos(e, o);
2116
+ return d && !c.samePos(e, r) && (e._dirty = !0, c.copyPos(e, r)), t.pack && this._packNodes()._notify(), !c.samePos(e, o);
2117
2117
  }
2118
2118
  getRow() {
2119
2119
  return this.nodes.reduce((e, t) => Math.max(e, t.y + t.h), 0);
@@ -2131,8 +2131,8 @@ class le {
2131
2131
  var o;
2132
2132
  const i = (o = this._layouts) == null ? void 0 : o.length, s = i && this.column !== i - 1 ? this._layouts[i - 1] : null, r = [];
2133
2133
  return this.sortNodes(), this.nodes.forEach((n) => {
2134
- const u = s == null ? void 0 : s.find((h) => h._id === n._id), a = { ...n, ...u || {} };
2135
- c.removeInternalForSave(a, !e), t && t(n, a), r.push(a);
2134
+ const d = s == null ? void 0 : s.find((u) => u._id === n._id), h = { ...n, ...d || {} };
2135
+ c.removeInternalForSave(h, !e), t && t(n, h), r.push(h);
2136
2136
  }), r;
2137
2137
  }
2138
2138
  /** @internal called whenever a node is added or moved - updates the cached layouts */
@@ -2171,19 +2171,19 @@ class le {
2171
2171
  s && this.sortNodes(1), t < e && this.cacheLayout(this.nodes, e), this.batchUpdate();
2172
2172
  let r = [], o = s ? this.nodes : c.sort(this.nodes, -1);
2173
2173
  if (t > e && this._layouts) {
2174
- const u = this._layouts[t] || [], a = this._layouts.length - 1;
2175
- !u.length && e !== a && ((n = this._layouts[a]) != null && n.length) && (e = a, this._layouts[a].forEach((h) => {
2176
- const l = o.find((f) => f._id === h._id);
2177
- l && (!s && !h.autoPosition && (l.x = h.x ?? l.x, l.y = h.y ?? l.y), l.w = h.w ?? l.w, (h.x == null || h.y === void 0) && (l.autoPosition = !0));
2178
- })), u.forEach((h) => {
2179
- const l = o.findIndex((f) => f._id === h._id);
2174
+ const d = this._layouts[t] || [], h = this._layouts.length - 1;
2175
+ !d.length && e !== h && ((n = this._layouts[h]) != null && n.length) && (e = h, this._layouts[h].forEach((u) => {
2176
+ const l = o.find((f) => f._id === u._id);
2177
+ l && (!s && !u.autoPosition && (l.x = u.x ?? l.x, l.y = u.y ?? l.y), l.w = u.w ?? l.w, (u.x == null || u.y === void 0) && (l.autoPosition = !0));
2178
+ })), d.forEach((u) => {
2179
+ const l = o.findIndex((f) => f._id === u._id);
2180
2180
  if (l !== -1) {
2181
2181
  const f = o[l];
2182
2182
  if (s) {
2183
- f.w = h.w;
2183
+ f.w = u.w;
2184
2184
  return;
2185
2185
  }
2186
- (h.autoPosition || isNaN(h.x) || isNaN(h.y)) && this.findEmptyPosition(h, r), h.autoPosition || (f.x = h.x ?? f.x, f.y = h.y ?? f.y, f.w = h.w ?? f.w, r.push(f)), o.splice(l, 1);
2186
+ (u.autoPosition || isNaN(u.x) || isNaN(u.y)) && this.findEmptyPosition(u, r), u.autoPosition || (f.x = u.x ?? f.x, f.y = u.y ?? f.y, f.w = u.w ?? f.w, r.push(f)), o.splice(l, 1);
2187
2187
  }
2188
2188
  });
2189
2189
  }
@@ -2194,16 +2194,16 @@ class le {
2194
2194
  if (typeof i == "function")
2195
2195
  i(t, e, r, o);
2196
2196
  else {
2197
- const u = s || i === "none" ? 1 : t / e, a = i === "move" || i === "moveScale", h = i === "scale" || i === "moveScale";
2197
+ const d = s || i === "none" ? 1 : t / e, h = i === "move" || i === "moveScale", u = i === "scale" || i === "moveScale";
2198
2198
  o.forEach((l) => {
2199
- l.x = t === 1 ? 0 : a ? Math.round(l.x * u) : Math.min(l.x, t - 1), l.w = t === 1 || e === 1 ? 1 : h ? Math.round(l.w * u) || 1 : Math.min(l.w, t), r.push(l);
2199
+ l.x = t === 1 ? 0 : h ? Math.round(l.x * d) : Math.min(l.x, t - 1), l.w = t === 1 || e === 1 ? 1 : u ? Math.round(l.w * d) || 1 : Math.min(l.w, t), r.push(l);
2200
2200
  }), o = [];
2201
2201
  }
2202
- r = c.sort(r, -1), this._inColumnResize = !0, this.nodes = [], r.forEach((u) => {
2203
- this.addNode(u, !1), delete u._orig;
2202
+ r = c.sort(r, -1), this._inColumnResize = !0, this.nodes = [], r.forEach((d) => {
2203
+ this.addNode(d, !1), delete d._orig;
2204
2204
  });
2205
2205
  }
2206
- return this.nodes.forEach((u) => delete u._orig), this.batchUpdate(!1, !s), delete this._inColumnResize, this;
2206
+ return this.nodes.forEach((d) => delete d._orig), this.batchUpdate(!1, !s), delete this._inColumnResize, this;
2207
2207
  }
2208
2208
  /**
2209
2209
  * call to cache the given layout internally to the given location so we can restore back when column changes size
@@ -2215,7 +2215,7 @@ class le {
2215
2215
  const s = [];
2216
2216
  return e.forEach((r, o) => {
2217
2217
  if (r._id === void 0) {
2218
- const n = r.id ? this.nodes.find((u) => u.id === r.id) : void 0;
2218
+ const n = r.id ? this.nodes.find((d) => d.id === r.id) : void 0;
2219
2219
  r._id = (n == null ? void 0 : n._id) ?? le._idSeq++;
2220
2220
  }
2221
2221
  s[o] = { x: r.x, y: r.y, w: r.w, _id: r._id };
@@ -2282,39 +2282,39 @@ const X = {
2282
2282
  // styleInHead: false,
2283
2283
  //removable
2284
2284
  };
2285
- class w {
2285
+ class b {
2286
2286
  }
2287
2287
  const ae = typeof window < "u" && typeof document < "u" && ("ontouchstart" in document || "ontouchstart" in window || window.DocumentTouch && document instanceof window.DocumentTouch || navigator.maxTouchPoints > 0 || navigator.msMaxTouchPoints > 0);
2288
2288
  class he {
2289
2289
  }
2290
- function Fe(d, e) {
2291
- d.touches.length > 1 || (d.cancelable && d.preventDefault(), c.simulateMouseEvent(d.changedTouches[0], e));
2290
+ function Fe(a, e) {
2291
+ a.touches.length > 1 || (a.cancelable && a.preventDefault(), c.simulateMouseEvent(a.changedTouches[0], e));
2292
2292
  }
2293
- function ti(d, e) {
2294
- d.cancelable && d.preventDefault(), c.simulateMouseEvent(d, e);
2293
+ function ti(a, e) {
2294
+ a.cancelable && a.preventDefault(), c.simulateMouseEvent(a, e);
2295
2295
  }
2296
- function Be(d) {
2297
- he.touchHandled || (he.touchHandled = !0, Fe(d, "mousedown"));
2296
+ function Be(a) {
2297
+ he.touchHandled || (he.touchHandled = !0, Fe(a, "mousedown"));
2298
2298
  }
2299
- function Ue(d) {
2300
- he.touchHandled && Fe(d, "mousemove");
2299
+ function Ue(a) {
2300
+ he.touchHandled && Fe(a, "mousemove");
2301
2301
  }
2302
- function We(d) {
2302
+ function We(a) {
2303
2303
  if (!he.touchHandled)
2304
2304
  return;
2305
2305
  he.pointerLeaveTimeout && (window.clearTimeout(he.pointerLeaveTimeout), delete he.pointerLeaveTimeout);
2306
- const e = !!w.dragElement;
2307
- Fe(d, "mouseup"), e || Fe(d, "click"), he.touchHandled = !1;
2306
+ const e = !!b.dragElement;
2307
+ Fe(a, "mouseup"), e || Fe(a, "click"), he.touchHandled = !1;
2308
2308
  }
2309
- function Ke(d) {
2310
- d.pointerType !== "mouse" && d.target.releasePointerCapture(d.pointerId);
2309
+ function Ke(a) {
2310
+ a.pointerType !== "mouse" && a.target.releasePointerCapture(a.pointerId);
2311
2311
  }
2312
- function Ot(d) {
2313
- w.dragElement && d.pointerType !== "mouse" && ti(d, "mouseenter");
2312
+ function Ot(a) {
2313
+ b.dragElement && a.pointerType !== "mouse" && ti(a, "mouseenter");
2314
2314
  }
2315
- function Ht(d) {
2316
- w.dragElement && d.pointerType !== "mouse" && (he.pointerLeaveTimeout = window.setTimeout(() => {
2317
- delete he.pointerLeaveTimeout, ti(d, "mouseleave");
2315
+ function Ht(a) {
2316
+ b.dragElement && a.pointerType !== "mouse" && (he.pointerLeaveTimeout = window.setTimeout(() => {
2317
+ delete he.pointerLeaveTimeout, ti(a, "mouseleave");
2318
2318
  }, 10));
2319
2319
  }
2320
2320
  class Ze {
@@ -2438,17 +2438,17 @@ class Se extends gt {
2438
2438
  }
2439
2439
  /** @internal turns auto hide on/off */
2440
2440
  _setupAutoHide(e) {
2441
- return e ? (this.el.classList.add("ui-resizable-autohide"), this.el.addEventListener("mouseover", this._mouseOver), this.el.addEventListener("mouseout", this._mouseOut)) : (this.el.classList.remove("ui-resizable-autohide"), this.el.removeEventListener("mouseover", this._mouseOver), this.el.removeEventListener("mouseout", this._mouseOut), w.overResizeElement === this && delete w.overResizeElement), this;
2441
+ return e ? (this.el.classList.add("ui-resizable-autohide"), this.el.addEventListener("mouseover", this._mouseOver), this.el.addEventListener("mouseout", this._mouseOut)) : (this.el.classList.remove("ui-resizable-autohide"), this.el.removeEventListener("mouseover", this._mouseOver), this.el.removeEventListener("mouseout", this._mouseOut), b.overResizeElement === this && delete b.overResizeElement), this;
2442
2442
  }
2443
2443
  /** @internal */
2444
2444
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
2445
2445
  _mouseOver(e) {
2446
- w.overResizeElement || w.dragElement || (w.overResizeElement = this, this.el.classList.remove("ui-resizable-autohide"));
2446
+ b.overResizeElement || b.dragElement || (b.overResizeElement = this, this.el.classList.remove("ui-resizable-autohide"));
2447
2447
  }
2448
2448
  /** @internal */
2449
2449
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
2450
2450
  _mouseOut(e) {
2451
- w.overResizeElement === this && (delete w.overResizeElement, this.el.classList.add("ui-resizable-autohide"));
2451
+ b.overResizeElement === this && (delete b.overResizeElement, this.el.classList.add("ui-resizable-autohide"));
2452
2452
  }
2453
2453
  /** @internal */
2454
2454
  _setupHandlers() {
@@ -2504,15 +2504,15 @@ class Se extends gt {
2504
2504
  left: this.originalRect.left,
2505
2505
  top: this.originalRect.top - this.scrolled
2506
2506
  }, r = e.clientX - i.clientX, o = this.sizeToContent ? 0 : e.clientY - i.clientY;
2507
- let n, u;
2508
- t.indexOf("e") > -1 ? s.width += r : t.indexOf("w") > -1 && (s.width -= r, s.left += r, n = !0), t.indexOf("s") > -1 ? s.height += o : t.indexOf("n") > -1 && (s.height -= o, s.top += o, u = !0);
2509
- const a = this._constrainSize(s.width, s.height, n, u);
2510
- return Math.round(s.width) !== Math.round(a.width) && (t.indexOf("w") > -1 && (s.left += s.width - a.width), s.width = a.width), Math.round(s.height) !== Math.round(a.height) && (t.indexOf("n") > -1 && (s.top += s.height - a.height), s.height = a.height), s;
2507
+ let n, d;
2508
+ t.indexOf("e") > -1 ? s.width += r : t.indexOf("w") > -1 && (s.width -= r, s.left += r, n = !0), t.indexOf("s") > -1 ? s.height += o : t.indexOf("n") > -1 && (s.height -= o, s.top += o, d = !0);
2509
+ const h = this._constrainSize(s.width, s.height, n, d);
2510
+ return Math.round(s.width) !== Math.round(h.width) && (t.indexOf("w") > -1 && (s.left += s.width - h.width), s.width = h.width), Math.round(s.height) !== Math.round(h.height) && (t.indexOf("n") > -1 && (s.top += s.height - h.height), s.height = h.height), s;
2511
2511
  }
2512
2512
  /** @internal constrain the size to the set min/max values */
2513
2513
  _constrainSize(e, t, i, s) {
2514
- const r = this.option, o = (i ? r.maxWidthMoveLeft : r.maxWidth) || Number.MAX_SAFE_INTEGER, n = r.minWidth / this.rectScale.x || e, u = (s ? r.maxHeightMoveUp : r.maxHeight) || Number.MAX_SAFE_INTEGER, a = r.minHeight / this.rectScale.y || t, h = Math.min(o, Math.max(n, e)), l = Math.min(u, Math.max(a, t));
2515
- return { width: h, height: l };
2514
+ const r = this.option, o = (i ? r.maxWidthMoveLeft : r.maxWidth) || Number.MAX_SAFE_INTEGER, n = r.minWidth / this.rectScale.x || e, d = (s ? r.maxHeightMoveUp : r.maxHeight) || Number.MAX_SAFE_INTEGER, h = r.minHeight / this.rectScale.y || t, u = Math.min(o, Math.max(n, e)), l = Math.min(d, Math.max(h, t));
2515
+ return { width: u, height: l };
2516
2516
  }
2517
2517
  /** @internal */
2518
2518
  _applyChange() {
@@ -2569,8 +2569,8 @@ class Ne extends gt {
2569
2569
  }
2570
2570
  /** @internal call when mouse goes down before a dragstart happens */
2571
2571
  _mouseDown(e) {
2572
- if (!w.mouseHandled)
2573
- return e.button !== 0 || !this.dragEls.find((t) => t === e.target) && e.target.closest(Ns) || this.option.cancel && e.target.closest(this.option.cancel) || (this.mouseDownEvent = e, delete this.dragging, delete w.dragElement, delete w.dropElement, document.addEventListener("mousemove", this._mouseMove, { capture: !0, passive: !0 }), document.addEventListener("mouseup", this._mouseUp, !0), ae && (e.currentTarget.addEventListener("touchmove", Ue), e.currentTarget.addEventListener("touchend", We)), e.preventDefault(), document.activeElement && document.activeElement.blur(), w.mouseHandled = !0), !0;
2572
+ if (!b.mouseHandled)
2573
+ return e.button !== 0 || !this.dragEls.find((t) => t === e.target) && e.target.closest(Ns) || this.option.cancel && e.target.closest(this.option.cancel) || (this.mouseDownEvent = e, delete this.dragging, delete b.dragElement, delete b.dropElement, document.addEventListener("mousemove", this._mouseMove, { capture: !0, passive: !0 }), document.addEventListener("mouseup", this._mouseUp, !0), ae && (e.currentTarget.addEventListener("touchmove", Ue), e.currentTarget.addEventListener("touchend", We)), e.preventDefault(), document.activeElement && document.activeElement.blur(), b.mouseHandled = !0), !0;
2574
2574
  }
2575
2575
  /** @internal method to call actual drag event */
2576
2576
  _callDrag(e) {
@@ -2584,15 +2584,15 @@ class Ne extends gt {
2584
2584
  var i;
2585
2585
  const t = this.mouseDownEvent;
2586
2586
  if (this.lastDrag = e, this.dragging)
2587
- if (this._dragFollow(e), w.pauseDrag) {
2588
- const s = Number.isInteger(w.pauseDrag) ? w.pauseDrag : 100;
2587
+ if (this._dragFollow(e), b.pauseDrag) {
2588
+ const s = Number.isInteger(b.pauseDrag) ? b.pauseDrag : 100;
2589
2589
  this.dragTimeout && window.clearTimeout(this.dragTimeout), this.dragTimeout = window.setTimeout(() => this._callDrag(e), s);
2590
2590
  } else
2591
2591
  this._callDrag(e);
2592
2592
  else if (Math.abs(e.x - t.x) + Math.abs(e.y - t.y) > 3) {
2593
- this.dragging = !0, w.dragElement = this;
2593
+ this.dragging = !0, b.dragElement = this;
2594
2594
  const s = (i = this.el.gridstackNode) == null ? void 0 : i.grid;
2595
- s ? w.dropElement = s.el.ddElement.ddDroppable : delete w.dropElement, this.helper = this._createHelper(), this._setupHelperContainmentStyle(), this.dragTransform = c.getValuesFromTransformedElement(this.helperContainment), this.dragOffset = this._getDragOffset(e, this.el, this.helperContainment), this._setupHelperStyle(e);
2595
+ s ? b.dropElement = s.el.ddElement.ddDroppable : delete b.dropElement, this.helper = this._createHelper(), this._setupHelperContainmentStyle(), this.dragTransform = c.getValuesFromTransformedElement(this.helperContainment), this.dragOffset = this._getDragOffset(e, this.el, this.helperContainment), this._setupHelperStyle(e);
2596
2596
  const r = c.initEvent(e, { target: this.el, type: "dragstart" });
2597
2597
  this.option.start && this.option.start(r, this.ui()), this.triggerEvent("dragstart", r), document.addEventListener("keydown", this._keyEvent);
2598
2598
  }
@@ -2602,16 +2602,16 @@ class Ne extends gt {
2602
2602
  _mouseUp(e) {
2603
2603
  var t, i;
2604
2604
  if (document.removeEventListener("mousemove", this._mouseMove, !0), document.removeEventListener("mouseup", this._mouseUp, !0), ae && e.currentTarget && (e.currentTarget.removeEventListener("touchmove", Ue, !0), e.currentTarget.removeEventListener("touchend", We, !0)), this.dragging) {
2605
- delete this.dragging, (t = this.el.gridstackNode) == null || delete t._origRotate, document.removeEventListener("keydown", this._keyEvent), ((i = w.dropElement) == null ? void 0 : i.el) === this.el.parentElement && delete w.dropElement, this.helperContainment.style.position = this.parentOriginStylePosition || null, this.helper !== this.el && this.helper.remove(), this._removeHelperStyle();
2605
+ delete this.dragging, (t = this.el.gridstackNode) == null || delete t._origRotate, document.removeEventListener("keydown", this._keyEvent), ((i = b.dropElement) == null ? void 0 : i.el) === this.el.parentElement && delete b.dropElement, this.helperContainment.style.position = this.parentOriginStylePosition || null, this.helper !== this.el && this.helper.remove(), this._removeHelperStyle();
2606
2606
  const s = c.initEvent(e, { target: this.el, type: "dragstop" });
2607
- this.option.stop && this.option.stop(s), this.triggerEvent("dragstop", s), w.dropElement && w.dropElement.drop(e);
2607
+ this.option.stop && this.option.stop(s), this.triggerEvent("dragstop", s), b.dropElement && b.dropElement.drop(e);
2608
2608
  }
2609
- delete this.helper, delete this.mouseDownEvent, delete w.dragElement, delete w.dropElement, delete w.mouseHandled, e.preventDefault();
2609
+ delete this.helper, delete this.mouseDownEvent, delete b.dragElement, delete b.dropElement, delete b.mouseHandled, e.preventDefault();
2610
2610
  }
2611
2611
  /** @internal call when keys are being pressed - use Esc to cancel, R to rotate */
2612
2612
  _keyEvent(e) {
2613
2613
  var s, r;
2614
- const t = this.el.gridstackNode, i = (t == null ? void 0 : t.grid) || ((r = (s = w.dropElement) == null ? void 0 : s.el) == null ? void 0 : r.gridstack);
2614
+ const t = this.el.gridstackNode, i = (t == null ? void 0 : t.grid) || ((r = (s = b.dropElement) == null ? void 0 : s.el) == null ? void 0 : r.gridstack);
2615
2615
  if (e.key === "Escape")
2616
2616
  t && t._origRotate && (t._orig = t._origRotate, delete t._origRotate), i == null || i.cancelDrag(), this._mouseUp(this.mouseDownEvent);
2617
2617
  else if (t && i && (e.key === "r" || e.key === "R")) {
@@ -2707,20 +2707,20 @@ class Ls extends gt {
2707
2707
  }
2708
2708
  /** @internal called when the cursor enters our area - prepare for a possible drop and track leaving */
2709
2709
  _mouseEnter(e) {
2710
- if (!w.dragElement || !this._canDrop(w.dragElement.el))
2710
+ if (!b.dragElement || !this._canDrop(b.dragElement.el))
2711
2711
  return;
2712
- e.preventDefault(), e.stopPropagation(), w.dropElement && w.dropElement !== this && w.dropElement._mouseLeave(e, !0), w.dropElement = this;
2712
+ e.preventDefault(), e.stopPropagation(), b.dropElement && b.dropElement !== this && b.dropElement._mouseLeave(e, !0), b.dropElement = this;
2713
2713
  const t = c.initEvent(e, { target: this.el, type: "dropover" });
2714
- this.option.over && this.option.over(t, this._ui(w.dragElement)), this.triggerEvent("dropover", t), this.el.classList.add("ui-droppable-over");
2714
+ this.option.over && this.option.over(t, this._ui(b.dragElement)), this.triggerEvent("dropover", t), this.el.classList.add("ui-droppable-over");
2715
2715
  }
2716
2716
  /** @internal called when the item is leaving our area, stop tracking if we had moving item */
2717
2717
  _mouseLeave(e, t = !1) {
2718
2718
  var s;
2719
- if (!w.dragElement || w.dropElement !== this)
2719
+ if (!b.dragElement || b.dropElement !== this)
2720
2720
  return;
2721
2721
  e.preventDefault(), e.stopPropagation();
2722
2722
  const i = c.initEvent(e, { target: this.el, type: "dropout" });
2723
- if (this.option.out && this.option.out(i, this._ui(w.dragElement)), this.triggerEvent("dropout", i), w.dropElement === this && (delete w.dropElement, !t)) {
2723
+ if (this.option.out && this.option.out(i, this._ui(b.dragElement)), this.triggerEvent("dropout", i), b.dropElement === this && (delete b.dropElement, !t)) {
2724
2724
  let r, o = this.el.parentElement;
2725
2725
  for (; !r && o; )
2726
2726
  r = (s = o.ddElement) == null ? void 0 : s.ddDroppable, o = o.parentElement;
@@ -2731,7 +2731,7 @@ class Ls extends gt {
2731
2731
  drop(e) {
2732
2732
  e.preventDefault();
2733
2733
  const t = c.initEvent(e, { target: this.el, type: "drop" });
2734
- this.option.drop && this.option.drop(t, this._ui(w.dragElement)), this.triggerEvent("drop", t);
2734
+ this.option.drop && this.option.drop(t, this._ui(b.dragElement)), this.triggerEvent("drop", t);
2735
2735
  }
2736
2736
  /** @internal true if element matches the string/method accept option */
2737
2737
  _canDrop(e) {
@@ -2749,9 +2749,9 @@ class Ls extends gt {
2749
2749
  };
2750
2750
  }
2751
2751
  }
2752
- class pt {
2752
+ class mt {
2753
2753
  static init(e) {
2754
- return e.ddElement || (e.ddElement = new pt(e)), e.ddElement;
2754
+ return e.ddElement || (e.ddElement = new mt(e)), e.ddElement;
2755
2755
  }
2756
2756
  constructor(e) {
2757
2757
  this.el = e;
@@ -2792,13 +2792,13 @@ class As {
2792
2792
  r.setupResizable({ [i]: s });
2793
2793
  else {
2794
2794
  const n = r.el.gridstackNode.grid;
2795
- let u = r.el.getAttribute("gs-resize-handles") || n.opts.resizable.handles || "e,s,se";
2796
- u === "all" && (u = "n,e,s,w,se,sw,ne,nw");
2797
- const a = !n.opts.alwaysShowResizeHandle;
2795
+ let d = r.el.getAttribute("gs-resize-handles") || n.opts.resizable.handles || "e,s,se";
2796
+ d === "all" && (d = "n,e,s,w,se,sw,ne,nw");
2797
+ const h = !n.opts.alwaysShowResizeHandle;
2798
2798
  r.setupResizable({
2799
2799
  ...n.opts.resizable,
2800
- handles: u,
2801
- autoHide: a,
2800
+ handles: d,
2801
+ autoHide: h,
2802
2802
  start: t.start,
2803
2803
  stop: t.stop,
2804
2804
  resize: t.resize
@@ -2851,7 +2851,7 @@ class As {
2851
2851
  }
2852
2852
  on(e, t, i) {
2853
2853
  return this._getDDElements(e).forEach((s) => s.on(t, (r) => {
2854
- i(r, w.dragElement ? w.dragElement.el : r.target, w.dragElement ? w.dragElement.helper : null);
2854
+ i(r, b.dragElement ? b.dragElement.el : r.target, b.dragElement ? b.dragElement.helper : null);
2855
2855
  })), this;
2856
2856
  }
2857
2857
  off(e, t) {
@@ -2860,7 +2860,7 @@ class As {
2860
2860
  /** @internal returns a list of DD elements, creating them on the fly by default unless option is to destroy or disable */
2861
2861
  _getDDElements(e, t) {
2862
2862
  const i = e.gridstack || t !== "destroy" && t !== "disable", s = c.getElements(e);
2863
- return s.length ? s.map((o) => o.ddElement || (i ? pt.init(o) : null)).filter((o) => o) : [];
2863
+ return s.length ? s.map((o) => o.ddElement || (i ? mt.init(o) : null)).filter((o) => o) : [];
2864
2864
  }
2865
2865
  }
2866
2866
  /*!
@@ -2871,7 +2871,7 @@ class As {
2871
2871
  * see root license https://github.com/gridstack/gridstack.js/tree/master/LICENSE
2872
2872
  */
2873
2873
  const U = new As();
2874
- class b {
2874
+ class _ {
2875
2875
  /**
2876
2876
  * initializing the HTML element, or selector string, into a grid will return the grid. Calling it again will
2877
2877
  * simply return the existing instance (ignore any passed options). There is also an initAll() version that support
@@ -2888,8 +2888,8 @@ class b {
2888
2888
  static init(e = {}, t = ".grid-stack") {
2889
2889
  if (typeof document > "u")
2890
2890
  return null;
2891
- const i = b.getGridElement(t);
2892
- return i ? (i.gridstack || (i.gridstack = new b(i, c.cloneDeep(e))), i.gridstack) : (console.error(typeof t == "string" ? 'GridStack.initAll() no grid was found with selector "' + t + `" - element missing or wrong selector ?
2891
+ const i = _.getGridElement(t);
2892
+ return i ? (i.gridstack || (i.gridstack = new _(i, c.cloneDeep(e))), i.gridstack) : (console.error(typeof t == "string" ? 'GridStack.initAll() no grid was found with selector "' + t + `" - element missing or wrong selector ?
2893
2893
  Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the default selector.` : "GridStack.init() no grid element was passed."), null);
2894
2894
  }
2895
2895
  /**
@@ -2903,8 +2903,8 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
2903
2903
  */
2904
2904
  static initAll(e = {}, t = ".grid-stack") {
2905
2905
  const i = [];
2906
- return typeof document > "u" || (b.getGridElements(t).forEach((s) => {
2907
- s.gridstack || (s.gridstack = new b(s, c.cloneDeep(e))), i.push(s.gridstack);
2906
+ return typeof document > "u" || (_.getGridElements(t).forEach((s) => {
2907
+ s.gridstack || (s.gridstack = new _(s, c.cloneDeep(e))), i.push(s.gridstack);
2908
2908
  }), i.length === 0 && console.error('GridStack.initAll() no grid was found with selector "' + t + `" - element missing or wrong selector ?
2909
2909
  Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the default selector.`)), i;
2910
2910
  }
@@ -2923,14 +2923,14 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
2923
2923
  const o = i.gridstack;
2924
2924
  return t && (o.opts = { ...o.opts, ...t }), t.children !== void 0 && o.load(t.children), o;
2925
2925
  }
2926
- return (!e.classList.contains("grid-stack") || b.addRemoveCB) && (b.addRemoveCB ? i = b.addRemoveCB(e, t, !0, !0) : i = c.createDiv(["grid-stack", t.class], e)), b.init(t, i);
2926
+ return (!e.classList.contains("grid-stack") || _.addRemoveCB) && (_.addRemoveCB ? i = _.addRemoveCB(e, t, !0, !0) : i = c.createDiv(["grid-stack", t.class], e)), _.init(t, i);
2927
2927
  }
2928
2928
  /** call this method to register your engine instead of the default one.
2929
2929
  * See instead `GridStackOptions.engineClass` if you only need to
2930
2930
  * replace just one instance.
2931
2931
  */
2932
2932
  static registerEngine(e) {
2933
- b.engineClass = e;
2933
+ _.engineClass = e;
2934
2934
  }
2935
2935
  /** @internal create placeholder DIV as needed */
2936
2936
  get placeholder() {
@@ -2947,7 +2947,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
2947
2947
  * @param opts grid options - public for classes to access, but use methods to modify!
2948
2948
  */
2949
2949
  constructor(e, t = {}) {
2950
- var l, f, p;
2950
+ var l, f, m;
2951
2951
  this.el = e, this.opts = t, this.animationDelay = 310, this._gsEventHandler = {}, this._extraDragRow = 0, this.dragTransform = { xScale: 1, yScale: 1, xOffset: 0, yOffset: 0 }, e.gridstack = this, this.opts = t = t || {}, e.classList.contains("grid-stack") || this.el.classList.add("grid-stack"), t.row && (t.minRow = t.maxRow = t.row, delete t.row);
2952
2952
  const i = c.toNumber(e.getAttribute("gs-row"));
2953
2953
  t.column === "auto" && delete t.column, t.alwaysShowResizeHandle !== void 0 && (t._alwaysShowResizeHandle = t.alwaysShowResizeHandle);
@@ -2956,7 +2956,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
2956
2956
  if (r.oneColumnModeDomSort && (delete r.oneColumnModeDomSort, console.log("warning: Gridstack oneColumnModeDomSort no longer supported. Use GridStackOptions.columnOpts instead.")), r.oneColumnSize || r.disableOneColumnMode === !1) {
2957
2957
  const g = r.oneColumnSize || 768;
2958
2958
  delete r.oneColumnSize, delete r.disableOneColumnMode, t.columnOpts = t.columnOpts || {}, s = t.columnOpts.breakpoints = t.columnOpts.breakpoints || [];
2959
- let y = s.find((m) => m.c === 1);
2959
+ let y = s.find((p) => p.c === 1);
2960
2960
  y ? y.w = g : (y = { c: 1, w: g }, s.push(y, { c: 12, w: g + 1 }));
2961
2961
  }
2962
2962
  const o = t.columnOpts;
@@ -2977,27 +2977,27 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
2977
2977
  }
2978
2978
  };
2979
2979
  e.getAttribute("gs-animate") && (n.animate = c.toBool(e.getAttribute("gs-animate"))), t = c.defaults(t, n), this._initMargin(), this.checkDynamicColumn(), this.el.classList.add("gs-" + t.column), t.rtl === "auto" && (t.rtl = e.style.direction === "rtl"), t.rtl && this.el.classList.add("grid-stack-rtl");
2980
- const u = this.el.closest("." + X.itemClass), a = u == null ? void 0 : u.gridstackNode;
2981
- a && (a.subGrid = this, this.parentGridNode = a, this.el.classList.add("grid-stack-nested"), a.el.classList.add("grid-stack-sub-grid")), this._isAutoCellHeight = t.cellHeight === "auto", this._isAutoCellHeight || t.cellHeight === "initial" ? this.cellHeight(void 0, !1) : (typeof t.cellHeight == "number" && t.cellHeightUnit && t.cellHeightUnit !== X.cellHeightUnit && (t.cellHeight = t.cellHeight + t.cellHeightUnit, delete t.cellHeightUnit), this.cellHeight(t.cellHeight, !1)), t.alwaysShowResizeHandle === "mobile" && (t.alwaysShowResizeHandle = ae), this._styleSheetClass = "gs-id-" + le._idSeq++, this.el.classList.add(this._styleSheetClass), this._setStaticClass();
2982
- const h = t.engineClass || b.engineClass || le;
2983
- if (this.engine = new h({
2980
+ const d = this.el.closest("." + X.itemClass), h = d == null ? void 0 : d.gridstackNode;
2981
+ h && (h.subGrid = this, this.parentGridNode = h, this.el.classList.add("grid-stack-nested"), h.el.classList.add("grid-stack-sub-grid")), this._isAutoCellHeight = t.cellHeight === "auto", this._isAutoCellHeight || t.cellHeight === "initial" ? this.cellHeight(void 0, !1) : (typeof t.cellHeight == "number" && t.cellHeightUnit && t.cellHeightUnit !== X.cellHeightUnit && (t.cellHeight = t.cellHeight + t.cellHeightUnit, delete t.cellHeightUnit), this.cellHeight(t.cellHeight, !1)), t.alwaysShowResizeHandle === "mobile" && (t.alwaysShowResizeHandle = ae), this._styleSheetClass = "gs-id-" + le._idSeq++, this.el.classList.add(this._styleSheetClass), this._setStaticClass();
2982
+ const u = t.engineClass || _.engineClass || le;
2983
+ if (this.engine = new u({
2984
2984
  column: this.getColumn(),
2985
2985
  float: t.float,
2986
2986
  maxRow: t.maxRow,
2987
2987
  onChange: (g) => {
2988
2988
  let y = 0;
2989
- this.engine.nodes.forEach((m) => {
2990
- y = Math.max(y, m.y + m.h);
2991
- }), g.forEach((m) => {
2992
- const D = m.el;
2993
- D && (m._removeDOM ? (D && D.remove(), delete m._removeDOM) : this._writePosAttr(D, m));
2989
+ this.engine.nodes.forEach((p) => {
2990
+ y = Math.max(y, p.y + p.h);
2991
+ }), g.forEach((p) => {
2992
+ const D = p.el;
2993
+ D && (p._removeDOM ? (D && D.remove(), delete p._removeDOM) : this._writePosAttr(D, p));
2994
2994
  }), this._updateStyles(!1, y);
2995
2995
  }
2996
2996
  }), this._updateStyles(!1, 0), t.auto && (this.batchUpdate(), this.engine._loading = !0, this.getGridItems().forEach((g) => this._prepareElement(g)), delete this.engine._loading, this.batchUpdate(!1)), t.children) {
2997
2997
  const g = t.children;
2998
2998
  delete t.children, g.length && this.load(g);
2999
2999
  }
3000
- this.setAnimation(), t.subGridDynamic && !w.pauseDrag && (w.pauseDrag = !0), ((p = t.draggable) == null ? void 0 : p.pause) !== void 0 && (w.pauseDrag = t.draggable.pause), this._setupRemoveDrop(), this._setupAcceptWidget(), this._updateResizeEvent();
3000
+ this.setAnimation(), t.subGridDynamic && !b.pauseDrag && (b.pauseDrag = !0), ((m = t.draggable) == null ? void 0 : m.pause) !== void 0 && (b.pauseDrag = t.draggable.pause), this._setupRemoveDrop(), this._setupAcceptWidget(), this._updateResizeEvent();
3001
3001
  }
3002
3002
  /**
3003
3003
  * add a new widget and returns it.
@@ -3020,7 +3020,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3020
3020
  if (e.ELEMENT_NODE)
3021
3021
  return console.error("V11: GridStack.addWidget() does not support HTMLElement anymore. use makeWidget()"), this.makeWidget(e);
3022
3022
  let t, i = e;
3023
- if (i.grid = this, i != null && i.el ? t = i.el : b.addRemoveCB ? t = b.addRemoveCB(this.el, e, !0, !1) : t = this.createWidgetDivs(i), !t)
3023
+ if (i.grid = this, i != null && i.el ? t = i.el : _.addRemoveCB ? t = _.addRemoveCB(this.el, e, !0, !1) : t = this.createWidgetDivs(i), !t)
3024
3024
  return;
3025
3025
  if (i = t.gridstackNode, i && t.parentElement === this.el && this.engine.nodes.find((r) => r._id === i._id))
3026
3026
  return t;
@@ -3032,11 +3032,11 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3032
3032
  const t = c.createDiv(["grid-stack-item", this.opts.itemClass]), i = c.createDiv(["grid-stack-item-content"], t);
3033
3033
  return c.lazyLoad(e) ? e.visibleObservable || (e.visibleObservable = new IntersectionObserver(([s]) => {
3034
3034
  var r, o;
3035
- s.isIntersecting && ((r = e.visibleObservable) == null || r.disconnect(), delete e.visibleObservable, b.renderCB(i, e), (o = e.grid) == null || o.prepareDragDrop(e.el));
3035
+ s.isIntersecting && ((r = e.visibleObservable) == null || r.disconnect(), delete e.visibleObservable, _.renderCB(i, e), (o = e.grid) == null || o.prepareDragDrop(e.el));
3036
3036
  }), window.setTimeout(() => {
3037
3037
  var s;
3038
3038
  return (s = e.visibleObservable) == null ? void 0 : s.observe(t);
3039
- })) : b.renderCB(i, e), t;
3039
+ })) : _.renderCB(i, e), t;
3040
3040
  }
3041
3041
  /**
3042
3042
  * Convert an existing gridItem element into a sub-grid with the given (optional) options, else inherit them
@@ -3048,9 +3048,9 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3048
3048
  * @returns newly created grid
3049
3049
  */
3050
3050
  makeSubGrid(e, t, i, s = !0) {
3051
- var p, g, y;
3051
+ var m, g, y;
3052
3052
  let r = e.gridstackNode;
3053
- if (r || (r = this.makeWidget(e).gridstackNode), (p = r.subGrid) != null && p.el)
3053
+ if (r || (r = this.makeWidget(e).gridstackNode), (m = r.subGrid) != null && m.el)
3054
3054
  return r.subGrid;
3055
3055
  let o, n = this;
3056
3056
  for (; n && !o; )
@@ -3067,15 +3067,15 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3067
3067
  ...o || {},
3068
3068
  ...t || r.subGridOpts || {}
3069
3069
  }), r.subGridOpts = t;
3070
- let u;
3071
- t.column === "auto" && (u = !0, t.column = Math.max(r.w || 1, (i == null ? void 0 : i.w) || 1), delete t.columnOpts);
3072
- let a = r.el.querySelector(".grid-stack-item-content"), h, l;
3073
- if (s && (this._removeDD(r.el), l = { ...r, x: 0, y: 0 }, c.removeInternalForSave(l), delete l.subGridOpts, r.content && (l.content = r.content, delete r.content), b.addRemoveCB ? h = b.addRemoveCB(this.el, l, !0, !1) : (h = c.createDiv(["grid-stack-item"]), h.appendChild(a), a = c.createDiv(["grid-stack-item-content"], r.el)), this.prepareDragDrop(r.el)), i) {
3074
- const m = u ? t.column : r.w, D = r.h + i.h, P = r.el.style;
3075
- P.transition = "none", this.update(r.el, { w: m, h: D }), setTimeout(() => P.transition = null);
3070
+ let d;
3071
+ t.column === "auto" && (d = !0, t.column = Math.max(r.w || 1, (i == null ? void 0 : i.w) || 1), delete t.columnOpts);
3072
+ let h = r.el.querySelector(".grid-stack-item-content"), u, l;
3073
+ if (s && (this._removeDD(r.el), l = { ...r, x: 0, y: 0 }, c.removeInternalForSave(l), delete l.subGridOpts, r.content && (l.content = r.content, delete r.content), _.addRemoveCB ? u = _.addRemoveCB(this.el, l, !0, !1) : (u = c.createDiv(["grid-stack-item"]), u.appendChild(h), h = c.createDiv(["grid-stack-item-content"], r.el)), this.prepareDragDrop(r.el)), i) {
3074
+ const p = d ? t.column : r.w, D = r.h + i.h, P = r.el.style;
3075
+ P.transition = "none", this.update(r.el, { w: p, h: D }), setTimeout(() => P.transition = null);
3076
3076
  }
3077
- const f = r.subGrid = b.addGrid(a, t);
3078
- return i != null && i._moving && (f._isTemp = !0), u && (f._autoColumn = !0), s && f.makeWidget(h, l), i && (i._moving ? window.setTimeout(() => c.simulateMouseEvent(i._event, "mouseenter", f.el), 0) : f.makeWidget(r.el, r)), this.resizeToContentCheck(!1, r), f;
3077
+ const f = r.subGrid = _.addGrid(h, t);
3078
+ return i != null && i._moving && (f._isTemp = !0), d && (f._autoColumn = !0), s && f.makeWidget(u, l), i && (i._moving ? window.setTimeout(() => c.simulateMouseEvent(i._event, "mouseenter", f.el), 0) : f.makeWidget(r.el, r)), this.resizeToContentCheck(!1, r), f;
3079
3079
  }
3080
3080
  /**
3081
3081
  * called when an item was converted into a nested grid to accommodate a dragged over item, but then item leaves - return back
@@ -3097,7 +3097,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3097
3097
  * @param saveCB callback for each node -> widget, so application can insert additional data to be saved into the widget data structure.
3098
3098
  * @returns list of widgets or full grid option, including .children list of widgets
3099
3099
  */
3100
- save(e = !0, t = !1, i = b.saveCB) {
3100
+ save(e = !0, t = !1, i = _.saveCB) {
3101
3101
  const s = this.engine.save(e, i);
3102
3102
  if (s.forEach((r) => {
3103
3103
  var o;
@@ -3127,38 +3127,38 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3127
3127
  * @example
3128
3128
  * see http://gridstackjs.com/demo/serialization.html
3129
3129
  */
3130
- load(e, t = b.addRemoveCB || !0) {
3131
- var a;
3130
+ load(e, t = _.addRemoveCB || !0) {
3131
+ var h;
3132
3132
  e = c.cloneDeep(e);
3133
3133
  const i = this.getColumn();
3134
- e.forEach((h) => {
3135
- h.w = h.w || 1, h.h = h.h || 1;
3134
+ e.forEach((u) => {
3135
+ u.w = u.w || 1, u.h = u.h || 1;
3136
3136
  }), e = c.sort(e), this.engine.skipCacheUpdate = this._ignoreLayoutsNodeChange = !0;
3137
3137
  let s = 0;
3138
- e.forEach((h) => {
3139
- s = Math.max(s, (h.x || 0) + h.w);
3138
+ e.forEach((u) => {
3139
+ s = Math.max(s, (u.x || 0) + u.w);
3140
3140
  }), s > this.engine.defaultColumn && (this.engine.defaultColumn = s), s > i && this.engine.cacheLayout(e, s, !0);
3141
- const r = b.addRemoveCB;
3142
- typeof t == "function" && (b.addRemoveCB = t);
3141
+ const r = _.addRemoveCB;
3142
+ typeof t == "function" && (_.addRemoveCB = t);
3143
3143
  const o = [];
3144
3144
  this.batchUpdate();
3145
3145
  const n = !this.engine.nodes.length;
3146
3146
  n && this.setAnimation(!1), !n && t && [...this.engine.nodes].forEach((l) => {
3147
3147
  if (!l.id)
3148
3148
  return;
3149
- c.find(e, l.id) || (b.addRemoveCB && b.addRemoveCB(this.el, l, !1, !1), o.push(l), this.removeWidget(l.el, !0, !1));
3149
+ c.find(e, l.id) || (_.addRemoveCB && _.addRemoveCB(this.el, l, !1, !1), o.push(l), this.removeWidget(l.el, !0, !1));
3150
3150
  }), this.engine._loading = !0;
3151
- const u = [];
3152
- return this.engine.nodes = this.engine.nodes.filter((h) => c.find(e, h.id) ? (u.push(h), !1) : !0), e.forEach((h) => {
3151
+ const d = [];
3152
+ return this.engine.nodes = this.engine.nodes.filter((u) => c.find(e, u.id) ? (d.push(u), !1) : !0), e.forEach((u) => {
3153
3153
  var f;
3154
- const l = c.find(u, h.id);
3154
+ const l = c.find(d, u.id);
3155
3155
  if (l) {
3156
- if (c.shouldSizeToContent(l) && (h.h = l.h), this.engine.nodeBoundFix(h), (h.autoPosition || h.x === void 0 || h.y === void 0) && (h.w = h.w || l.w, h.h = h.h || l.h, this.engine.findEmptyPosition(h)), this.engine.nodes.push(l), c.samePos(l, h) && this.engine.nodes.length > 1 && (this.moveNode(l, { ...h, forceCollide: !0 }), c.copyPos(h, l)), this.update(l.el, h), (f = h.subGridOpts) != null && f.children) {
3157
- const p = l.el.querySelector(".grid-stack");
3158
- p && p.gridstack && p.gridstack.load(h.subGridOpts.children);
3156
+ if (c.shouldSizeToContent(l) && (u.h = l.h), this.engine.nodeBoundFix(u), (u.autoPosition || u.x === void 0 || u.y === void 0) && (u.w = u.w || l.w, u.h = u.h || l.h, this.engine.findEmptyPosition(u)), this.engine.nodes.push(l), c.samePos(l, u) && this.engine.nodes.length > 1 && (this.moveNode(l, { ...u, forceCollide: !0 }), c.copyPos(u, l)), this.update(l.el, u), (f = u.subGridOpts) != null && f.children) {
3157
+ const m = l.el.querySelector(".grid-stack");
3158
+ m && m.gridstack && m.gridstack.load(u.subGridOpts.children);
3159
3159
  }
3160
- } else t && this.addWidget(h);
3161
- }), delete this.engine._loading, this.engine.removedNodes = o, this.batchUpdate(!1), delete this._ignoreLayoutsNodeChange, delete this.engine.skipCacheUpdate, r ? b.addRemoveCB = r : delete b.addRemoveCB, n && ((a = this.opts) != null && a.animate) && this.setAnimation(this.opts.animate, !0), this;
3160
+ } else t && this.addWidget(u);
3161
+ }), delete this.engine._loading, this.engine.removedNodes = o, this.batchUpdate(!1), delete this._ignoreLayoutsNodeChange, delete this.engine.skipCacheUpdate, r ? _.addRemoveCB = r : delete _.addRemoveCB, n && ((h = this.opts) != null && h.animate) && this.setAnimation(this.opts.animate, !0), this;
3162
3162
  }
3163
3163
  /**
3164
3164
  * use before calling a bunch of `addWidget()` to prevent un-necessary relayouts in between (more efficient)
@@ -3238,7 +3238,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3238
3238
  i = e.breakpoints[n++].c || t;
3239
3239
  }
3240
3240
  if (i !== t) {
3241
- const n = (o = e.breakpoints) == null ? void 0 : o.find((u) => u.c === i);
3241
+ const n = (o = e.breakpoints) == null ? void 0 : o.find((d) => d.c === i);
3242
3242
  return this.column(i, (n == null ? void 0 : n.layout) || e.layout), !0;
3243
3243
  }
3244
3244
  return !1;
@@ -3316,8 +3316,8 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3316
3316
  const i = this.el.getBoundingClientRect();
3317
3317
  let s;
3318
3318
  t ? s = { top: i.top + document.documentElement.scrollTop, left: i.left } : s = { top: this.el.offsetTop, left: this.el.offsetLeft };
3319
- const r = e.left - s.left, o = e.top - s.top, n = i.width / this.getColumn(), u = i.height / parseInt(this.el.getAttribute("gs-current-row"));
3320
- return { x: Math.floor(r / n), y: Math.floor(o / u) };
3319
+ const r = e.left - s.left, o = e.top - s.top, n = i.width / this.getColumn(), d = i.height / parseInt(this.el.getAttribute("gs-current-row"));
3320
+ return { x: Math.floor(r / n), y: Math.floor(o / d) };
3321
3321
  }
3322
3322
  /** returns the current number of rows, which will be at least `minRow` if set */
3323
3323
  getRow() {
@@ -3347,7 +3347,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3347
3347
  * grid.makeWidget('2', {w:2, content: 'hello'});
3348
3348
  */
3349
3349
  makeWidget(e, t) {
3350
- const i = b.getElement(e);
3350
+ const i = _.getElement(e);
3351
3351
  if (!i)
3352
3352
  return;
3353
3353
  i.parentElement || this.el.appendChild(i), this._prepareElement(i, !0, t);
@@ -3379,11 +3379,11 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3379
3379
  * @param triggerEvent if `false` (quiet mode) element will not be added to removed list and no 'removed' callbacks will be called (Default? true).
3380
3380
  */
3381
3381
  removeWidget(e, t = !0, i = !0) {
3382
- return e ? (b.getElements(e).forEach((s) => {
3382
+ return e ? (_.getElements(e).forEach((s) => {
3383
3383
  if (s.parentElement && s.parentElement !== this.el)
3384
3384
  return;
3385
3385
  let r = s.gridstackNode;
3386
- r || (r = this.engine.nodes.find((o) => s === o.el)), r && (t && b.addRemoveCB && b.addRemoveCB(this.el, r, !1, !1), delete s.gridstackNode, this._removeDD(s), this.engine.removeNode(r, t, i), t && s.parentElement && s.remove());
3386
+ r || (r = this.engine.nodes.find((o) => s === o.el)), r && (t && _.addRemoveCB && _.addRemoveCB(this.el, r, !1, !1), delete s.gridstackNode, this._removeDD(s), this.engine.removeNode(r, t, i), t && s.parentElement && s.remove());
3387
3387
  }), i && (this._triggerRemoveEvent(), this._triggerChangeEvent()), this) : (console.error("Error: GridStack.removeWidget(undefined) called"), this);
3388
3388
  }
3389
3389
  /**
@@ -3393,7 +3393,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3393
3393
  */
3394
3394
  removeAll(e = !0, t = !0) {
3395
3395
  return this.engine.nodes.forEach((i) => {
3396
- e && b.addRemoveCB && b.addRemoveCB(this.el, i, !1, !1), delete i.el.gridstackNode, this.opts.staticGrid || this._removeDD(i.el);
3396
+ e && _.addRemoveCB && _.addRemoveCB(this.el, i, !1, !1), delete i.el.gridstackNode, this.opts.staticGrid || this._removeDD(i.el);
3397
3397
  }), this.engine.removeAll(e, t), t && this._triggerRemoveEvent(), this;
3398
3398
  }
3399
3399
  /**
@@ -3438,8 +3438,8 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3438
3438
  * @param opt new widget options (x,y,w,h, etc..). Only those set will be updated.
3439
3439
  */
3440
3440
  update(e, t) {
3441
- return b.getElements(e).forEach((i) => {
3442
- var h;
3441
+ return _.getElements(e).forEach((i) => {
3442
+ var u;
3443
3443
  const s = i == null ? void 0 : i.gridstackNode;
3444
3444
  if (!s)
3445
3445
  return;
@@ -3451,16 +3451,16 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3451
3451
  n[l] = r[l] !== void 0 ? r[l] : s[l], delete r[l];
3452
3452
  })), !n && (r.minW || r.minH || r.maxW || r.maxH) && (n = {}), r.content !== void 0) {
3453
3453
  const l = i.querySelector(".grid-stack-item-content");
3454
- l && l.textContent !== r.content && (s.content = r.content, b.renderCB(l, r), (h = s.subGrid) != null && h.el && (l.appendChild(s.subGrid.el), s.subGrid.opts.styleInHead || s.subGrid._updateStyles(!0))), delete r.content;
3454
+ l && l.textContent !== r.content && (s.content = r.content, _.renderCB(l, r), (u = s.subGrid) != null && u.el && (l.appendChild(s.subGrid.el), s.subGrid.opts.styleInHead || s.subGrid._updateStyles(!0))), delete r.content;
3455
3455
  }
3456
- let u = !1, a = !1;
3456
+ let d = !1, h = !1;
3457
3457
  for (const l in r)
3458
- l[0] !== "_" && s[l] !== r[l] && (s[l] = r[l], u = !0, a = a || !this.opts.staticGrid && (l === "noResize" || l === "noMove" || l === "locked"));
3458
+ l[0] !== "_" && s[l] !== r[l] && (s[l] = r[l], d = !0, h = h || !this.opts.staticGrid && (l === "noResize" || l === "noMove" || l === "locked"));
3459
3459
  if (c.sanitizeMinMax(s), n) {
3460
3460
  const l = n.w !== void 0 && n.w !== s.w;
3461
3461
  this.moveNode(s, n), l && s.subGrid ? s.subGrid.onResize(this.hasAnimationCSS() ? s.w : void 0) : this.resizeToContentCheck(l, s), delete s._orig;
3462
3462
  }
3463
- (n || u) && this._writeAttr(i, s), a && this.prepareDragDrop(s.el);
3463
+ (n || d) && this._writeAttr(i, s), h && this.prepareDragDrop(s.el);
3464
3464
  }), this;
3465
3465
  }
3466
3466
  moveNode(e, t) {
@@ -3474,7 +3474,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3474
3474
  * @param useNodeH set to true if GridStackNode.h should be used instead of actual container height when we don't need to wait for animation to finish to get actual DOM heights
3475
3475
  */
3476
3476
  resizeToContent(e) {
3477
- var f, p;
3477
+ var f, m;
3478
3478
  if (!e || (e.classList.remove("size-to-content-max"), !e.clientHeight))
3479
3479
  return;
3480
3480
  const t = e.gridstackNode;
@@ -3487,50 +3487,50 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3487
3487
  if (!s)
3488
3488
  return;
3489
3489
  let r = t.h ? t.h * s : e.clientHeight, o;
3490
- if (t.resizeToContentParent && (o = e.querySelector(t.resizeToContentParent)), o || (o = e.querySelector(b.resizeToContentParent)), !o)
3490
+ if (t.resizeToContentParent && (o = e.querySelector(t.resizeToContentParent)), o || (o = e.querySelector(_.resizeToContentParent)), !o)
3491
3491
  return;
3492
- const n = e.clientHeight - o.clientHeight, u = t.h ? t.h * s - n : o.clientHeight;
3493
- let a;
3492
+ const n = e.clientHeight - o.clientHeight, d = t.h ? t.h * s - n : o.clientHeight;
3493
+ let h;
3494
3494
  if (t.subGrid) {
3495
- a = t.subGrid.getRow() * t.subGrid.getCellHeight(!0);
3495
+ h = t.subGrid.getRow() * t.subGrid.getCellHeight(!0);
3496
3496
  const g = t.subGrid.el.getBoundingClientRect(), y = t.subGrid.el.parentElement.getBoundingClientRect();
3497
- a += g.top - y.top;
3497
+ h += g.top - y.top;
3498
3498
  } else {
3499
- if ((p = (f = t.subGridOpts) == null ? void 0 : f.children) != null && p.length)
3499
+ if ((m = (f = t.subGridOpts) == null ? void 0 : f.children) != null && m.length)
3500
3500
  return;
3501
3501
  {
3502
3502
  const g = o.firstElementChild;
3503
3503
  if (!g) {
3504
- console.error(`Error: GridStack.resizeToContent() widget id:${t.id} '${b.resizeToContentParent}'.firstElementChild is null, make sure to have a div like container. Skipping sizing.`);
3504
+ console.error(`Error: GridStack.resizeToContent() widget id:${t.id} '${_.resizeToContentParent}'.firstElementChild is null, make sure to have a div like container. Skipping sizing.`);
3505
3505
  return;
3506
3506
  }
3507
- a = g.getBoundingClientRect().height || u;
3507
+ h = g.getBoundingClientRect().height || d;
3508
3508
  }
3509
3509
  }
3510
- if (u === a)
3510
+ if (d === h)
3511
3511
  return;
3512
- r += a - u;
3513
- let h = Math.ceil(r / s);
3512
+ r += h - d;
3513
+ let u = Math.ceil(r / s);
3514
3514
  const l = Number.isInteger(t.sizeToContent) ? t.sizeToContent : 0;
3515
- l && h > l && (h = l, e.classList.add("size-to-content-max")), t.minH && h < t.minH ? h = t.minH : t.maxH && h > t.maxH && (h = t.maxH), h !== t.h && (i._ignoreLayoutsNodeChange = !0, i.moveNode(t, { h }), delete i._ignoreLayoutsNodeChange);
3515
+ l && u > l && (u = l, e.classList.add("size-to-content-max")), t.minH && u < t.minH ? u = t.minH : t.maxH && u > t.maxH && (u = t.maxH), u !== t.h && (i._ignoreLayoutsNodeChange = !0, i.moveNode(t, { h: u }), delete i._ignoreLayoutsNodeChange);
3516
3516
  }
3517
3517
  /** call the user resize (so they can do extra work) else our build in version */
3518
3518
  resizeToContentCBCheck(e) {
3519
- b.resizeToContentCB ? b.resizeToContentCB(e) : this.resizeToContent(e);
3519
+ _.resizeToContentCB ? _.resizeToContentCB(e) : this.resizeToContent(e);
3520
3520
  }
3521
3521
  /** rotate (by swapping w & h) the passed in node - called when user press 'r' during dragging
3522
3522
  * @param els widget or selector of objects to modify
3523
3523
  * @param relative optional pixel coord relative to upper/left corner to rotate around (will keep that cell under cursor)
3524
3524
  */
3525
3525
  rotate(e, t) {
3526
- return b.getElements(e).forEach((i) => {
3526
+ return _.getElements(e).forEach((i) => {
3527
3527
  const s = i.gridstackNode;
3528
3528
  if (!c.canBeRotated(s))
3529
3529
  return;
3530
3530
  const r = { w: s.h, h: s.w, minH: s.minW, minW: s.minH, maxH: s.maxW, maxW: s.maxH };
3531
3531
  if (t) {
3532
- const n = t.left > 0 ? Math.floor(t.left / this.cellWidth()) : 0, u = t.top > 0 ? Math.floor(t.top / this.opts.cellHeight) : 0;
3533
- r.x = s.x + n - (s.h - (u + 1)), r.y = s.y + u - n;
3532
+ const n = t.left > 0 ? Math.floor(t.left / this.cellWidth()) : 0, d = t.top > 0 ? Math.floor(t.top / this.opts.cellHeight) : 0;
3533
+ r.x = s.x + n - (s.h - (d + 1)), r.y = s.y + d - n;
3534
3534
  }
3535
3535
  Object.keys(r).forEach((n) => {
3536
3536
  r[n] === void 0 && delete r[n];
@@ -3633,8 +3633,8 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3633
3633
  }), !this._styles)
3634
3634
  return this;
3635
3635
  this._styles._max = 0, c.addCSSRule(this._styles, r, `height: ${i}${s}`);
3636
- const n = this.opts.marginTop + this.opts.marginUnit, u = this.opts.marginBottom + this.opts.marginUnit, a = this.opts.marginRight + this.opts.marginUnit, h = this.opts.marginLeft + this.opts.marginUnit, l = `${r} > .grid-stack-item-content`, f = `.${this._styleSheetClass} > .grid-stack-placeholder > .placeholder-content`;
3637
- c.addCSSRule(this._styles, l, `top: ${n}; right: ${a}; bottom: ${u}; left: ${h};`), c.addCSSRule(this._styles, f, `top: ${n}; right: ${a}; bottom: ${u}; left: ${h};`), c.addCSSRule(this._styles, `${r} > .ui-resizable-n`, `top: ${n};`), c.addCSSRule(this._styles, `${r} > .ui-resizable-s`, `bottom: ${u}`), c.addCSSRule(this._styles, `${r} > .ui-resizable-ne`, `right: ${a}; top: ${n}`), c.addCSSRule(this._styles, `${r} > .ui-resizable-e`, `right: ${a}`), c.addCSSRule(this._styles, `${r} > .ui-resizable-se`, `right: ${a}; bottom: ${u}`), c.addCSSRule(this._styles, `${r} > .ui-resizable-nw`, `left: ${h}; top: ${n}`), c.addCSSRule(this._styles, `${r} > .ui-resizable-w`, `left: ${h}`), c.addCSSRule(this._styles, `${r} > .ui-resizable-sw`, `left: ${h}; bottom: ${u}`);
3636
+ const n = this.opts.marginTop + this.opts.marginUnit, d = this.opts.marginBottom + this.opts.marginUnit, h = this.opts.marginRight + this.opts.marginUnit, u = this.opts.marginLeft + this.opts.marginUnit, l = `${r} > .grid-stack-item-content`, f = `.${this._styleSheetClass} > .grid-stack-placeholder > .placeholder-content`;
3637
+ c.addCSSRule(this._styles, l, `top: ${n}; right: ${h}; bottom: ${d}; left: ${u};`), c.addCSSRule(this._styles, f, `top: ${n}; right: ${h}; bottom: ${d}; left: ${u};`), c.addCSSRule(this._styles, `${r} > .ui-resizable-n`, `top: ${n};`), c.addCSSRule(this._styles, `${r} > .ui-resizable-s`, `bottom: ${d}`), c.addCSSRule(this._styles, `${r} > .ui-resizable-ne`, `right: ${h}; top: ${n}`), c.addCSSRule(this._styles, `${r} > .ui-resizable-e`, `right: ${h}`), c.addCSSRule(this._styles, `${r} > .ui-resizable-se`, `right: ${h}; bottom: ${d}`), c.addCSSRule(this._styles, `${r} > .ui-resizable-nw`, `left: ${u}; top: ${n}`), c.addCSSRule(this._styles, `${r} > .ui-resizable-w`, `left: ${u}`), c.addCSSRule(this._styles, `${r} > .ui-resizable-sw`, `left: ${u}; bottom: ${d}`);
3638
3638
  }
3639
3639
  if (t = t || this._styles._max, t > this._styles._max) {
3640
3640
  const o = (n) => i * n + s;
@@ -3752,7 +3752,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3752
3752
  }
3753
3753
  /** @internal */
3754
3754
  static getGridElement(e) {
3755
- return b.getElement(e);
3755
+ return _.getElement(e);
3756
3756
  }
3757
3757
  /** @internal */
3758
3758
  static getGridElements(e) {
@@ -3782,7 +3782,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3782
3782
  * @param root optional root which defaults to document (for shadow dom pass the parent HTMLDocument)
3783
3783
  */
3784
3784
  static setupDragIn(e, t, i, s = document) {
3785
- (t == null ? void 0 : t.pause) !== void 0 && (w.pauseDrag = t.pause), t = { appendTo: "body", helper: "clone", ...t || {} }, (typeof e == "string" ? c.getElements(e, s) : e).forEach((o, n) => {
3785
+ (t == null ? void 0 : t.pause) !== void 0 && (b.pauseDrag = t.pause), t = { appendTo: "body", helper: "clone", ...t || {} }, (typeof e == "string" ? c.getElements(e, s) : e).forEach((o, n) => {
3786
3786
  U.isDraggable(o) || U.dragIn(o, t), i != null && i[n] && (o.gridstackNode = i[n]);
3787
3787
  });
3788
3788
  }
@@ -3793,7 +3793,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3793
3793
  * @param val if true widget will be draggable, assuming the parent grid isn't noMove or static.
3794
3794
  */
3795
3795
  movable(e, t) {
3796
- return this.opts.staticGrid ? this : (b.getElements(e).forEach((i) => {
3796
+ return this.opts.staticGrid ? this : (_.getElements(e).forEach((i) => {
3797
3797
  const s = i.gridstackNode;
3798
3798
  s && (t ? delete s.noMove : s.noMove = !0, this.prepareDragDrop(s.el));
3799
3799
  }), this);
@@ -3804,7 +3804,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3804
3804
  * @param val if true widget will be resizable, assuming the parent grid isn't noResize or static.
3805
3805
  */
3806
3806
  resizable(e, t) {
3807
- return this.opts.staticGrid ? this : (b.getElements(e).forEach((i) => {
3807
+ return this.opts.staticGrid ? this : (_.getElements(e).forEach((i) => {
3808
3808
  const s = i.gridstackNode;
3809
3809
  s && (t ? delete s.noResize : s.noResize = !0, this.prepareDragDrop(s.el));
3810
3810
  }), this);
@@ -3858,7 +3858,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3858
3858
  cancelDrag() {
3859
3859
  var t;
3860
3860
  const e = (t = this._placeholder) == null ? void 0 : t.gridstackNode;
3861
- e && (e._isExternal ? (e._isAboutToRemove = !0, this.engine.removeNode(e)) : e._isAboutToRemove && b._itemRemoving(e.el, !1), this.engine.restoreInitial());
3861
+ e && (e._isExternal ? (e._isAboutToRemove = !0, this.engine.removeNode(e)) : e._isAboutToRemove && _._itemRemoving(e.el, !1), this.engine.restoreInitial());
3862
3862
  }
3863
3863
  /** @internal removes any drag&drop present (called during destroy) */
3864
3864
  _removeDD(e) {
@@ -3877,20 +3877,20 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3877
3877
  return;
3878
3878
  if (!((f = n.grid) != null && f.el)) {
3879
3879
  o.style.transform = `scale(${1 / this.dragTransform.xScale},${1 / this.dragTransform.yScale})`;
3880
- const p = o.getBoundingClientRect();
3881
- o.style.left = p.x + (this.dragTransform.xScale - 1) * (s.clientX - p.x) / this.dragTransform.xScale + "px", o.style.top = p.y + (this.dragTransform.yScale - 1) * (s.clientY - p.y) / this.dragTransform.yScale + "px", o.style.transformOrigin = "0px 0px";
3880
+ const m = o.getBoundingClientRect();
3881
+ o.style.left = m.x + (this.dragTransform.xScale - 1) * (s.clientX - m.x) / this.dragTransform.xScale + "px", o.style.top = m.y + (this.dragTransform.yScale - 1) * (s.clientY - m.y) / this.dragTransform.yScale + "px", o.style.transformOrigin = "0px 0px";
3882
3882
  }
3883
- let { top: u, left: a } = o.getBoundingClientRect();
3884
- const h = this.el.getBoundingClientRect();
3885
- a -= h.left, u -= h.top;
3883
+ let { top: d, left: h } = o.getBoundingClientRect();
3884
+ const u = this.el.getBoundingClientRect();
3885
+ h -= u.left, d -= u.top;
3886
3886
  const l = {
3887
3887
  position: {
3888
- top: u * this.dragTransform.xScale,
3889
- left: a * this.dragTransform.yScale
3888
+ top: d * this.dragTransform.xScale,
3889
+ left: h * this.dragTransform.yScale
3890
3890
  }
3891
3891
  };
3892
3892
  if (n._temporaryRemoved) {
3893
- if (n.x = Math.max(0, Math.round(a / t)), n.y = Math.max(0, Math.round(u / e)), delete n.autoPosition, this.engine.nodeBoundFix(n), !this.engine.willItFit(n)) {
3893
+ if (n.x = Math.max(0, Math.round(h / t)), n.y = Math.max(0, Math.round(d / e)), delete n.autoPosition, this.engine.nodeBoundFix(n), !this.engine.willItFit(n)) {
3894
3894
  if (n.autoPosition = !0, !this.engine.willItFit(n)) {
3895
3895
  U.off(r, "drag");
3896
3896
  return;
@@ -3926,42 +3926,42 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3926
3926
  if ((n == null ? void 0 : n.grid) === this && !n._temporaryRemoved)
3927
3927
  return !1;
3928
3928
  if (n != null && n._sidebarOrig && (n.w = n._sidebarOrig.w, n.h = n._sidebarOrig.h), n != null && n.grid && n.grid !== this && !n._temporaryRemoved && n.grid._leave(r, o), o = o || r, t = this.cellWidth(), e = this.getCellHeight(!0), !n) {
3929
- const h = o.getAttribute("data-gs-widget") || o.getAttribute("gridstacknode");
3930
- if (h) {
3929
+ const u = o.getAttribute("data-gs-widget") || o.getAttribute("gridstacknode");
3930
+ if (u) {
3931
3931
  try {
3932
- n = JSON.parse(h);
3932
+ n = JSON.parse(u);
3933
3933
  } catch {
3934
- console.error("Gridstack dropover: Bad JSON format: ", h);
3934
+ console.error("Gridstack dropover: Bad JSON format: ", u);
3935
3935
  }
3936
3936
  o.removeAttribute("data-gs-widget"), o.removeAttribute("gridstacknode");
3937
3937
  }
3938
3938
  n || (n = this._readAttr(o)), n._sidebarOrig = { w: n.w, h: n.h };
3939
3939
  }
3940
3940
  n.grid || (n.el || (n = { ...n }), n._isExternal = !0, o.gridstackNode = n);
3941
- const u = n.w || Math.round(o.offsetWidth / t) || 1, a = n.h || Math.round(o.offsetHeight / e) || 1;
3942
- return n.grid && n.grid !== this ? (r._gridstackNodeOrig || (r._gridstackNodeOrig = n), r.gridstackNode = n = { ...n, w: u, h: a, grid: this }, delete n.x, delete n.y, this.engine.cleanupNode(n).nodeBoundFix(n), n._initDD = n._isExternal = // DOM needs to be re-parented on a drop
3943
- n._temporaryRemoved = !0) : (n.w = u, n.h = a, n._temporaryRemoved = !0), b._itemRemoving(n.el, !1), U.on(r, "drag", i), i(s, r, o), !1;
3941
+ const d = n.w || Math.round(o.offsetWidth / t) || 1, h = n.h || Math.round(o.offsetHeight / e) || 1;
3942
+ return n.grid && n.grid !== this ? (r._gridstackNodeOrig || (r._gridstackNodeOrig = n), r.gridstackNode = n = { ...n, w: d, h, grid: this }, delete n.x, delete n.y, this.engine.cleanupNode(n).nodeBoundFix(n), n._initDD = n._isExternal = // DOM needs to be re-parented on a drop
3943
+ n._temporaryRemoved = !0) : (n.w = d, n.h = h, n._temporaryRemoved = !0), _._itemRemoving(n.el, !1), U.on(r, "drag", i), i(s, r, o), !1;
3944
3944
  }).on(this.el, "dropout", (s, r, o) => {
3945
3945
  const n = (o == null ? void 0 : o.gridstackNode) || r.gridstackNode;
3946
3946
  return n && (!n.grid || n.grid === this) && (this._leave(r, o), this._isTemp && this.removeAsSubGrid(n)), !1;
3947
3947
  }).on(this.el, "drop", (s, r, o) => {
3948
- var p, g, y;
3948
+ var m, g, y;
3949
3949
  const n = (o == null ? void 0 : o.gridstackNode) || r.gridstackNode;
3950
3950
  if ((n == null ? void 0 : n.grid) === this && !n._isExternal)
3951
3951
  return !1;
3952
- const u = !!this.placeholder.parentElement, a = r !== o;
3952
+ const d = !!this.placeholder.parentElement, h = r !== o;
3953
3953
  this.placeholder.remove(), delete this.placeholder.gridstackNode;
3954
- const h = u && this.opts.animate;
3955
- h && this.setAnimation(!1);
3954
+ const u = d && this.opts.animate;
3955
+ u && this.setAnimation(!1);
3956
3956
  const l = r._gridstackNodeOrig;
3957
- if (delete r._gridstackNodeOrig, u && (l != null && l.grid) && l.grid !== this) {
3958
- const m = l.grid;
3959
- m.engine.removeNodeFromLayoutCache(l), m.engine.removedNodes.push(l), m._triggerRemoveEvent()._triggerChangeEvent(), m.parentGridNode && !m.engine.nodes.length && m.opts.subGridDynamic && m.removeAsSubGrid();
3957
+ if (delete r._gridstackNodeOrig, d && (l != null && l.grid) && l.grid !== this) {
3958
+ const p = l.grid;
3959
+ p.engine.removeNodeFromLayoutCache(l), p.engine.removedNodes.push(l), p._triggerRemoveEvent()._triggerChangeEvent(), p.parentGridNode && !p.engine.nodes.length && p.opts.subGridDynamic && p.removeAsSubGrid();
3960
3960
  }
3961
- if (!n || (u && (this.engine.cleanupNode(n), n.grid = this), (p = n.grid) == null || delete p._isTemp, U.off(r, "drag"), o !== r ? (o.remove(), r = o) : r.remove(), this._removeDD(r), !u))
3961
+ if (!n || (d && (this.engine.cleanupNode(n), n.grid = this), (m = n.grid) == null || delete m._isTemp, U.off(r, "drag"), o !== r ? (o.remove(), r = o) : r.remove(), this._removeDD(r), !d))
3962
3962
  return !1;
3963
3963
  const f = (y = (g = n.subGrid) == null ? void 0 : g.el) == null ? void 0 : y.gridstack;
3964
- return c.copyPos(n, this._readAttr(this.placeholder)), c.removePositioningStyles(r), a && (n.content || n.subGridOpts || b.addRemoveCB) ? (delete n.el, r = this.addWidget(n)) : (this._prepareElement(r, !0, n), this.el.appendChild(r), this.resizeToContentCheck(!1, n), f && (f.parentGridNode = n, f.opts.styleInHead || f._updateStyles(!0)), this._updateContainerHeight()), this.engine.addedNodes.push(n), this._triggerAddEvent(), this._triggerChangeEvent(), this.engine.endUpdate(), this._gsEventHandler.dropped && this._gsEventHandler.dropped({ ...s, type: "dropped" }, l && l.grid ? l : void 0, n), h && this.setAnimation(this.opts.animate, !0), !1;
3964
+ return c.copyPos(n, this._readAttr(this.placeholder)), c.removePositioningStyles(r), h && (n.content || n.subGridOpts || _.addRemoveCB) ? (delete n.el, r = this.addWidget(n)) : (this._prepareElement(r, !0, n), this.el.appendChild(r), this.resizeToContentCheck(!1, n), f && (f.parentGridNode = n, f.opts.styleInHead || f._updateStyles(!0)), this._updateContainerHeight()), this.engine.addedNodes.push(n), this._triggerAddEvent(), this._triggerChangeEvent(), this.engine.endUpdate(), this._gsEventHandler.dropped && this._gsEventHandler.dropped({ ...s, type: "dropped" }, l && l.grid ? l : void 0, n), u && this.setAnimation(this.opts.animate, !0), !1;
3965
3965
  }), this;
3966
3966
  }
3967
3967
  /** @internal mark item for removal */
@@ -3976,7 +3976,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3976
3976
  if (typeof this.opts.removable != "string")
3977
3977
  return this;
3978
3978
  const e = document.querySelector(this.opts.removable);
3979
- return e ? (!this.opts.staticGrid && !U.isDroppable(e) && U.droppable(e, this.opts.removableOptions).on(e, "dropover", (t, i) => b._itemRemoving(i, !0)).on(e, "dropout", (t, i) => b._itemRemoving(i, !1)), this) : this;
3979
+ return e ? (!this.opts.staticGrid && !U.isDroppable(e) && U.droppable(e, this.opts.removableOptions).on(e, "dropover", (t, i) => _._itemRemoving(i, !0)).on(e, "dropout", (t, i) => _._itemRemoving(i, !1)), this) : this;
3980
3980
  }
3981
3981
  /**
3982
3982
  * prepares the element for drag&drop - this is normally called by makeWidget() unless are are delay loading
@@ -3991,31 +3991,31 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3991
3991
  if ((t || o) && (i._initDD && (this._removeDD(e), delete i._initDD), o && e.classList.add("ui-draggable-disabled", "ui-resizable-disabled"), !t))
3992
3992
  return this;
3993
3993
  if (!i._initDD) {
3994
- let n, u;
3995
- const a = (f, p) => {
3996
- this._gsEventHandler[f.type] && this._gsEventHandler[f.type](f, f.target), n = this.cellWidth(), u = this.getCellHeight(!0), this._onStartMoving(e, f, p, i, n, u);
3997
- }, h = (f, p) => {
3998
- this._dragOrResize(e, f, p, i, n, u);
3994
+ let n, d;
3995
+ const h = (f, m) => {
3996
+ this._gsEventHandler[f.type] && this._gsEventHandler[f.type](f, f.target), n = this.cellWidth(), d = this.getCellHeight(!0), this._onStartMoving(e, f, m, i, n, d);
3997
+ }, u = (f, m) => {
3998
+ this._dragOrResize(e, f, m, i, n, d);
3999
3999
  }, l = (f) => {
4000
4000
  this.placeholder.remove(), delete this.placeholder.gridstackNode, delete i._moving, delete i._event, delete i._lastTried;
4001
- const p = i.w !== i._orig.w, g = f.target;
4001
+ const m = i.w !== i._orig.w, g = f.target;
4002
4002
  if (!(!g.gridstackNode || g.gridstackNode.grid !== this)) {
4003
4003
  if (i.el = g, i._isAboutToRemove) {
4004
4004
  const y = e.gridstackNode.grid;
4005
4005
  y._gsEventHandler[f.type] && y._gsEventHandler[f.type](f, g), y.engine.nodes.push(i), y.removeWidget(e, !0, !0);
4006
4006
  } else
4007
4007
  c.removePositioningStyles(g), i._temporaryRemoved ? (c.copyPos(i, i._orig), this._writePosAttr(g, i), this.engine.addNode(i)) : this._writePosAttr(g, i), this._gsEventHandler[f.type] && this._gsEventHandler[f.type](f, g);
4008
- this._extraDragRow = 0, this._updateContainerHeight(), this._triggerChangeEvent(), this.engine.endUpdate(), f.type === "resizestop" && (Number.isInteger(i.sizeToContent) && (i.sizeToContent = i.h), this.resizeToContentCheck(p, i));
4008
+ this._extraDragRow = 0, this._updateContainerHeight(), this._triggerChangeEvent(), this.engine.endUpdate(), f.type === "resizestop" && (Number.isInteger(i.sizeToContent) && (i.sizeToContent = i.h), this.resizeToContentCheck(m, i));
4009
4009
  }
4010
4010
  };
4011
4011
  U.draggable(e, {
4012
- start: a,
4012
+ start: h,
4013
4013
  stop: l,
4014
- drag: h
4014
+ drag: u
4015
4015
  }).resizable(e, {
4016
- start: a,
4016
+ start: h,
4017
4017
  stop: l,
4018
- resize: h
4018
+ resize: u
4019
4019
  }), i._initDD = !0;
4020
4020
  }
4021
4021
  return U.draggable(e, s ? "disable" : "enable").resizable(e, r ? "disable" : "enable"), this;
@@ -4026,8 +4026,8 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
4026
4026
  if (this.engine.cleanNodes().beginUpdate(s), this._writePosAttr(this.placeholder, s), this.el.appendChild(this.placeholder), this.placeholder.gridstackNode = s, (n = s.grid) != null && n.el)
4027
4027
  this.dragTransform = c.getValuesFromTransformedElement(e);
4028
4028
  else if (this.placeholder && this.placeholder.closest(".grid-stack")) {
4029
- const u = this.placeholder.closest(".grid-stack");
4030
- this.dragTransform = c.getValuesFromTransformedElement(u);
4029
+ const d = this.placeholder.closest(".grid-stack");
4030
+ this.dragTransform = c.getValuesFromTransformedElement(d);
4031
4031
  } else
4032
4032
  this.dragTransform = {
4033
4033
  xScale: 1,
@@ -4036,21 +4036,21 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
4036
4036
  yOffset: 0
4037
4037
  };
4038
4038
  if (s.el = this.placeholder, s._lastUiPosition = i.position, s._prevYPix = i.position.top, s._moving = t.type === "dragstart", delete s._lastTried, t.type === "dropover" && s._temporaryRemoved && (this.engine.addNode(s), s._moving = !0), this.engine.cacheRects(r, o, this.opts.marginTop, this.opts.marginRight, this.opts.marginBottom, this.opts.marginLeft), t.type === "resizestart") {
4039
- const u = this.getColumn() - s.x, a = (this.opts.maxRow || Number.MAX_SAFE_INTEGER) - s.y;
4040
- U.resizable(e, "option", "minWidth", r * Math.min(s.minW || 1, u)).resizable(e, "option", "minHeight", o * Math.min(s.minH || 1, a)).resizable(e, "option", "maxWidth", r * Math.min(s.maxW || Number.MAX_SAFE_INTEGER, u)).resizable(e, "option", "maxWidthMoveLeft", r * Math.min(s.maxW || Number.MAX_SAFE_INTEGER, s.x + s.w)).resizable(e, "option", "maxHeight", o * Math.min(s.maxH || Number.MAX_SAFE_INTEGER, a)).resizable(e, "option", "maxHeightMoveUp", o * Math.min(s.maxH || Number.MAX_SAFE_INTEGER, s.y + s.h));
4039
+ const d = this.getColumn() - s.x, h = (this.opts.maxRow || Number.MAX_SAFE_INTEGER) - s.y;
4040
+ U.resizable(e, "option", "minWidth", r * Math.min(s.minW || 1, d)).resizable(e, "option", "minHeight", o * Math.min(s.minH || 1, h)).resizable(e, "option", "maxWidth", r * Math.min(s.maxW || Number.MAX_SAFE_INTEGER, d)).resizable(e, "option", "maxWidthMoveLeft", r * Math.min(s.maxW || Number.MAX_SAFE_INTEGER, s.x + s.w)).resizable(e, "option", "maxHeight", o * Math.min(s.maxH || Number.MAX_SAFE_INTEGER, h)).resizable(e, "option", "maxHeightMoveUp", o * Math.min(s.maxH || Number.MAX_SAFE_INTEGER, s.y + s.h));
4041
4041
  }
4042
4042
  }
4043
4043
  /** @internal handles actual drag/resize */
4044
4044
  _dragOrResize(e, t, i, s, r, o) {
4045
4045
  const n = { ...s._orig };
4046
- let u, a = this.opts.marginLeft, h = this.opts.marginRight, l = this.opts.marginTop, f = this.opts.marginBottom;
4047
- const p = Math.round(o * 0.1), g = Math.round(r * 0.1);
4048
- if (a = Math.min(a, g), h = Math.min(h, g), l = Math.min(l, p), f = Math.min(f, p), t.type === "drag") {
4046
+ let d, h = this.opts.marginLeft, u = this.opts.marginRight, l = this.opts.marginTop, f = this.opts.marginBottom;
4047
+ const m = Math.round(o * 0.1), g = Math.round(r * 0.1);
4048
+ if (h = Math.min(h, g), u = Math.min(u, g), l = Math.min(l, m), f = Math.min(f, m), t.type === "drag") {
4049
4049
  if (s._temporaryRemoved)
4050
4050
  return;
4051
- const m = i.position.top - s._prevYPix;
4052
- s._prevYPix = i.position.top, this.opts.draggable.scroll !== !1 && c.updateScrollPosition(e, i.position, m);
4053
- const D = i.position.left + (i.position.left > s._lastUiPosition.left ? -h : a), P = i.position.top + (i.position.top > s._lastUiPosition.top ? -f : l);
4051
+ const p = i.position.top - s._prevYPix;
4052
+ s._prevYPix = i.position.top, this.opts.draggable.scroll !== !1 && c.updateScrollPosition(e, i.position, p);
4053
+ const D = i.position.left + (i.position.left > s._lastUiPosition.left ? -u : h), P = i.position.top + (i.position.top > s._lastUiPosition.top ? -f : l);
4054
4054
  n.x = Math.round(D / r), n.y = Math.round(P / o);
4055
4055
  const z = this._extraDragRow;
4056
4056
  if (this.engine.collide(s, n)) {
@@ -4062,22 +4062,22 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
4062
4062
  if (this._extraDragRow !== z && this._updateContainerHeight(), s.x === n.x && s.y === n.y)
4063
4063
  return;
4064
4064
  } else if (t.type === "resize") {
4065
- if (n.x < 0 || (c.updateScrollResize(t, e, o), n.w = Math.round((i.size.width - a) / r), n.h = Math.round((i.size.height - l) / o), s.w === n.w && s.h === n.h) || s._lastTried && s._lastTried.w === n.w && s._lastTried.h === n.h)
4065
+ if (n.x < 0 || (c.updateScrollResize(t, e, o), n.w = Math.round((i.size.width - h) / r), n.h = Math.round((i.size.height - l) / o), s.w === n.w && s.h === n.h) || s._lastTried && s._lastTried.w === n.w && s._lastTried.h === n.h)
4066
4066
  return;
4067
- const m = i.position.left + a, D = i.position.top + l;
4068
- n.x = Math.round(m / r), n.y = Math.round(D / o), u = !0;
4067
+ const p = i.position.left + h, D = i.position.top + l;
4068
+ n.x = Math.round(p / r), n.y = Math.round(D / o), d = !0;
4069
4069
  }
4070
4070
  s._event = t, s._lastTried = n;
4071
4071
  const y = {
4072
- x: i.position.left + a,
4072
+ x: i.position.left + h,
4073
4073
  y: i.position.top + l,
4074
- w: (i.size ? i.size.width : s.w * r) - a - h,
4074
+ w: (i.size ? i.size.width : s.w * r) - h - u,
4075
4075
  h: (i.size ? i.size.height : s.h * o) - l - f
4076
4076
  };
4077
- if (this.engine.moveNodeCheck(s, { ...n, cellWidth: r, cellHeight: o, rect: y, resizing: u })) {
4078
- s._lastUiPosition = i.position, this.engine.cacheRects(r, o, l, h, f, a), delete s._skipDown, u && s.subGrid && s.subGrid.onResize(), this._extraDragRow = 0, this._updateContainerHeight();
4079
- const m = t.target;
4080
- s._sidebarOrig || this._writePosAttr(m, s), this._gsEventHandler[t.type] && this._gsEventHandler[t.type](t, m);
4077
+ if (this.engine.moveNodeCheck(s, { ...n, cellWidth: r, cellHeight: o, rect: y, resizing: d })) {
4078
+ s._lastUiPosition = i.position, this.engine.cacheRects(r, o, l, u, f, h), delete s._skipDown, d && s.subGrid && s.subGrid.onResize(), this._extraDragRow = 0, this._updateContainerHeight();
4079
+ const p = t.target;
4080
+ s._sidebarOrig || this._writePosAttr(p, s), this._gsEventHandler[t.type] && this._gsEventHandler[t.type](t, p);
4081
4081
  }
4082
4082
  }
4083
4083
  /** @internal called when item leaving our area by either cursor dropout event
@@ -4091,20 +4091,20 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
4091
4091
  return;
4092
4092
  i._temporaryRemoved = !0, this.engine.removeNode(i), i.el = i._isExternal && t ? t : e;
4093
4093
  const s = i._sidebarOrig;
4094
- i._isExternal && this.engine.cleanupNode(i), i._sidebarOrig = s, this.opts.removable === !0 && b._itemRemoving(e, !0), e._gridstackNodeOrig ? (e.gridstackNode = e._gridstackNodeOrig, delete e._gridstackNodeOrig) : i._isExternal && this.engine.restoreInitial();
4094
+ i._isExternal && this.engine.cleanupNode(i), i._sidebarOrig = s, this.opts.removable === !0 && _._itemRemoving(e, !0), e._gridstackNodeOrig ? (e.gridstackNode = e._gridstackNodeOrig, delete e._gridstackNodeOrig) : i._isExternal && this.engine.restoreInitial();
4095
4095
  }
4096
4096
  // legacy method removed
4097
4097
  commit() {
4098
4098
  return Ss(this, this.batchUpdate(!1), "commit", "batchUpdate", "5.2"), this;
4099
4099
  }
4100
4100
  }
4101
- b.renderCB = (d, e) => {
4102
- d && (e != null && e.content) && (d.textContent = e.content);
4101
+ _.renderCB = (a, e) => {
4102
+ a && (e != null && e.content) && (a.textContent = e.content);
4103
4103
  };
4104
- b.resizeToContentParent = ".grid-stack-item-content";
4105
- b.Utils = c;
4106
- b.Engine = le;
4107
- b.GDRev = "11.5.1";
4104
+ _.resizeToContentParent = ".grid-stack-item-content";
4105
+ _.Utils = c;
4106
+ _.Engine = le;
4107
+ _.GDRev = "11.5.1";
4108
4108
  const Os = ["data-id", "data-testid", "gs-h", "gs-w", "gs-x", "gs-y"], Hs = { class: "grid-stack-item-content" }, Ms = /* @__PURE__ */ Z({
4109
4109
  __name: "DraggableGridLayout",
4110
4110
  props: {
@@ -4112,12 +4112,12 @@ const Os = ["data-id", "data-testid", "gs-h", "gs-w", "gs-x", "gs-y"], Hs = { cl
4112
4112
  tileHeight: { default: Xe }
4113
4113
  },
4114
4114
  emits: ["update-tiles"],
4115
- setup(d, { expose: e, emit: t }) {
4116
- const i = d, s = t, r = H(null), o = H(new Map(i.tiles.map((p) => [`${p.id}`, p])));
4115
+ setup(a, { expose: e, emit: t }) {
4116
+ const i = a, s = t, r = H(null), o = H(new Map(i.tiles.map((m) => [`${m.id}`, m])));
4117
4117
  let n = null;
4118
- const u = (p) => `[data-id="${p}"]`, a = (p) => p.map((g) => {
4119
- var m;
4120
- const y = o.value.get(`${(m = g.el) == null ? void 0 : m.getAttribute("data-id")}`);
4118
+ const d = (m) => `[data-id="${m}"]`, h = (m) => m.map((g) => {
4119
+ var p;
4120
+ const y = o.value.get(`${(p = g.el) == null ? void 0 : p.getAttribute("data-id")}`);
4121
4121
  if (y)
4122
4122
  return {
4123
4123
  ...y,
@@ -4126,53 +4126,53 @@ const Os = ["data-id", "data-testid", "gs-h", "gs-w", "gs-x", "gs-y"], Hs = { cl
4126
4126
  size: { cols: Number(g.w), rows: Number(g.h) }
4127
4127
  }
4128
4128
  };
4129
- }).filter((g) => g !== void 0), h = (p, g) => {
4130
- n && (a(g).forEach((m) => {
4131
- o.value.set(`${m.id}`, m);
4129
+ }).filter((g) => g !== void 0), u = (m, g) => {
4130
+ n && (h(g).forEach((p) => {
4131
+ o.value.set(`${p.id}`, p);
4132
4132
  }), s("update-tiles", Array.from(o.value.values())));
4133
- }, l = (p, g) => {
4133
+ }, l = (m, g) => {
4134
4134
  g.forEach((y) => {
4135
- var m;
4136
- o.value.delete(`${(m = y.el) == null ? void 0 : m.getAttribute("data-id")}`);
4135
+ var p;
4136
+ o.value.delete(`${(p = y.el) == null ? void 0 : p.getAttribute("data-id")}`);
4137
4137
  }), s("update-tiles", Array.from(o.value.values()));
4138
4138
  };
4139
4139
  at(() => {
4140
- r.value && (n = b.init({
4140
+ r.value && (n = _.init({
4141
4141
  margin: 10,
4142
4142
  column: Wt,
4143
4143
  cellHeight: i.tileHeight,
4144
4144
  resizable: { handles: "se, sw" },
4145
4145
  handle: ".tile-header"
4146
- }, r.value), n.on("change", h), n.on("added", h), n.on("removed", l));
4146
+ }, r.value), n.on("change", u), n.on("added", u), n.on("removed", l));
4147
4147
  }), lt(() => {
4148
4148
  n && n.destroy(!1);
4149
4149
  });
4150
- const f = (p) => {
4150
+ const f = (m) => {
4151
4151
  if (n && r.value) {
4152
- const g = r.value.querySelector(u(p));
4152
+ const g = r.value.querySelector(d(m));
4153
4153
  g && n.removeWidget(g);
4154
4154
  }
4155
4155
  };
4156
- return ze(() => i.tiles.length, async (p, g) => {
4157
- if (p > g && n) {
4156
+ return ze(() => i.tiles.length, async (m, g) => {
4157
+ if (m > g && n) {
4158
4158
  const y = i.tiles.slice(g);
4159
- for (const m of y)
4160
- o.value.set(`${m.id}`, m), await ut(), n.makeWidget(u(m.id), {
4159
+ for (const p of y)
4160
+ o.value.set(`${p.id}`, p), await ut(), n.makeWidget(d(p.id), {
4161
4161
  autoPosition: !0,
4162
- w: m.layout.size.cols,
4163
- h: m.layout.size.rows
4162
+ w: p.layout.size.cols,
4163
+ h: p.layout.size.rows
4164
4164
  });
4165
4165
  }
4166
4166
  }), Mt(() => {
4167
- i.tiles.forEach((p) => {
4168
- o.value.set(`${p.id}`, p);
4167
+ i.tiles.forEach((m) => {
4168
+ o.value.set(`${m.id}`, m);
4169
4169
  });
4170
- }), e({ removeWidget: f }), (p, g) => (C(), K("div", {
4170
+ }), e({ removeWidget: f }), (m, g) => (x(), K("div", {
4171
4171
  ref_key: "gridContainer",
4172
4172
  ref: r,
4173
4173
  class: "grid-stack"
4174
4174
  }, [
4175
- (C(!0), K($t, null, Gt(i.tiles, (y) => (C(), K("div", {
4175
+ (x(!0), K($t, null, Gt(i.tiles, (y) => (x(), K("div", {
4176
4176
  key: y.id,
4177
4177
  class: "grid-stack-item",
4178
4178
  "data-id": `${y.id}`,
@@ -4184,7 +4184,7 @@ const Os = ["data-id", "data-testid", "gs-h", "gs-w", "gs-x", "gs-y"], Hs = { cl
4184
4184
  "gs-y": y.layout.position.row
4185
4185
  }, [
4186
4186
  oe("div", Hs, [
4187
- De(p.$slots, "tile", { tile: y }, void 0, !0)
4187
+ De(m.$slots, "tile", { tile: y }, void 0, !0)
4188
4188
  ])
4189
4189
  ], 8, Os))), 128))
4190
4190
  ], 512));
@@ -4204,25 +4204,25 @@ const Os = ["data-id", "data-testid", "gs-h", "gs-w", "gs-x", "gs-y"], Hs = { cl
4204
4204
  modelModifiers: {}
4205
4205
  }),
4206
4206
  emits: /* @__PURE__ */ xt(["edit-tile", "tile-time-range-zoom"], ["update:modelValue"]),
4207
- setup(d, { expose: e, emit: t }) {
4208
- Ye((E) => ({
4209
- "82baf22a": l.value
4207
+ setup(a, { expose: e, emit: t }) {
4208
+ Ye((C) => ({
4209
+ v82baf22a: l.value
4210
4210
  }));
4211
- const i = d, s = t, r = ci(d, "modelValue"), { i18n: o } = ye.useI18n(), n = H(0), u = H(null), a = H(), h = H(), l = H("scale(1)"), f = ve(pe);
4211
+ const i = a, s = t, r = ci(a, "modelValue"), { i18n: o } = ye.useI18n(), n = H(0), d = H(null), h = H(), u = H(), l = H("scale(1)"), f = ve(me);
4212
4212
  f || (console.warn("Analytics dashboards require a query bridge supplied via provide / inject."), console.warn("Please ensure your application has a query bridge provided under the key 'analytics-query-provider', as described in"), console.warn("https://github.com/Kong/public-ui-components/blob/main/packages/analytics/dashboard-renderer/README.md#requirements")), ye.useRequestQueue();
4213
- const p = dt(), g = k(() => i.context.timeSpec ? i.context.timeSpec : {
4213
+ const m = dt(), g = k(() => i.context.timeSpec ? i.context.timeSpec : {
4214
4214
  type: "relative",
4215
- time_range: p.defaultQueryTimeForOrg
4216
- }), y = k(() => !!i.context.timeSpec || !p.loading), m = (E, S) => {
4217
- const N = E.layout.position.row - S.layout.position.row;
4218
- return N !== 0 ? N : E.layout.position.col - S.layout.position.col;
4219
- }, D = k(() => r.value.tiles.map((E) => {
4215
+ time_range: m.defaultQueryTimeForOrg
4216
+ }), y = k(() => !!i.context.timeSpec || !m.loading), p = (C, S) => {
4217
+ const N = C.layout.position.row - S.layout.position.row;
4218
+ return N !== 0 ? N : C.layout.position.col - S.layout.position.col;
4219
+ }, D = k(() => r.value.tiles.map((C) => {
4220
4220
  var N;
4221
- let S = E.definition;
4221
+ let S = C.definition;
4222
4222
  if ("description" in S.chart) {
4223
4223
  const q = (N = S.chart.description) == null ? void 0 : N.replace(Ui, () => {
4224
- const me = `renderer.trendRange.${g.value.type === "absolute" ? "custom" : g.value.time_range}`;
4225
- return o.te(me) ? o.t(me) : "";
4224
+ const pe = `renderer.trendRange.${g.value.type === "absolute" ? "custom" : g.value.time_range}`;
4225
+ return o.te(pe) ? o.t(pe) : "";
4226
4226
  });
4227
4227
  S = {
4228
4228
  ...S,
@@ -4232,22 +4232,22 @@ const Os = ["data-id", "data-testid", "gs-h", "gs-w", "gs-x", "gs-y"], Hs = { cl
4232
4232
  }
4233
4233
  };
4234
4234
  }
4235
- return i.context.editable && !E.id && console.warn(
4235
+ return i.context.editable && !C.id && console.warn(
4236
4236
  "No id provided for tile. One will be generated automatically,",
4237
4237
  "however tracking changes to this tile may not work as expected.",
4238
- E
4238
+ C
4239
4239
  ), {
4240
- layout: E.layout,
4240
+ layout: C.layout,
4241
4241
  meta: S,
4242
- type: E.type,
4242
+ type: C.type,
4243
4243
  // Add a unique key to each tile internally.
4244
- id: E.id ?? crypto.randomUUID()
4244
+ id: C.id ?? crypto.randomUUID()
4245
4245
  };
4246
4246
  })), P = k(() => {
4247
- var me, Re, Pe;
4248
- let { tz: E, refreshInterval: S, editable: N } = i.context;
4247
+ var pe, Re, Pe;
4248
+ let { tz: C, refreshInterval: S, editable: N } = i.context;
4249
4249
  const q = [...i.context.filters ?? [], ...r.value.preset_filters ?? []];
4250
- if (E || (E = new Intl.DateTimeFormat().resolvedOptions().timeZone), S === void 0 && (S = Wi), J.value) {
4250
+ if (C || (C = new Intl.DateTimeFormat().resolvedOptions().timeZone), S === void 0 && (S = Wi), J.value) {
4251
4251
  let ke = !1;
4252
4252
  if (g.value.type === "relative")
4253
4253
  ke = ["15m", "1h", "6h", "12h", "24h"].includes(g.value.time_range);
@@ -4259,26 +4259,26 @@ const Os = ["data-id", "data-testid", "gs-h", "gs-w", "gs-x", "gs-y"], Hs = { cl
4259
4259
  g.value.type === "absolute" && g.value.end.getTime() < Je ? S = 0 : ke ? S = Ki : S = Vi;
4260
4260
  }
4261
4261
  N === void 0 && (N = !1);
4262
- const ee = !!((Pe = (Re = (me = fi()) == null ? void 0 : me.vnode) == null ? void 0 : Re.props) != null && Pe.onTileTimeRangeZoom);
4262
+ const ee = !!((Pe = (Re = (pe = fi()) == null ? void 0 : pe.vnode) == null ? void 0 : Re.props) != null && Pe.onTileTimeRangeZoom);
4263
4263
  return {
4264
4264
  filters: q,
4265
- tz: E,
4265
+ tz: C,
4266
4266
  timeSpec: g.value,
4267
4267
  refreshInterval: S,
4268
4268
  editable: N,
4269
4269
  zoomable: ee
4270
4270
  };
4271
- }), z = (E) => {
4272
- s("edit-tile", E);
4273
- }, Q = (E) => E.type === "slottable", B = (E) => {
4274
- const S = Q(E.meta.chart) ? { ...E.meta.chart } : {
4275
- ...E.meta.chart,
4276
- chart_title: E.meta.chart.chart_title ? `Copy of ${E.meta.chart.chart_title}` : ""
4271
+ }), z = (C) => {
4272
+ s("edit-tile", C);
4273
+ }, Q = (C) => C.type === "slottable", B = (C) => {
4274
+ const S = Q(C.meta.chart) ? { ...C.meta.chart } : {
4275
+ ...C.meta.chart,
4276
+ chart_title: C.meta.chart.chart_title ? `Copy of ${C.meta.chart.chart_title}` : ""
4277
4277
  }, N = {
4278
4278
  id: crypto.randomUUID(),
4279
4279
  type: "chart",
4280
4280
  definition: {
4281
- ...E.meta,
4281
+ ...C.meta,
4282
4282
  chart: S
4283
4283
  },
4284
4284
  layout: {
@@ -4286,68 +4286,68 @@ const Os = ["data-id", "data-testid", "gs-h", "gs-w", "gs-x", "gs-y"], Hs = { cl
4286
4286
  col: 0,
4287
4287
  row: 0
4288
4288
  },
4289
- size: E.layout.size
4289
+ size: C.layout.size
4290
4290
  }
4291
4291
  };
4292
4292
  r.value.tiles.push(N);
4293
- }, R = (E) => {
4294
- u.value && u.value.removeWidget(E.id);
4293
+ }, R = (C) => {
4294
+ d.value && d.value.removeWidget(C.id);
4295
4295
  }, M = () => {
4296
4296
  n.value++;
4297
- }, Y = (E) => {
4298
- const S = E.map((N) => ({
4297
+ }, Y = (C) => {
4298
+ const S = C.map((N) => ({
4299
4299
  id: N.id,
4300
4300
  type: N.type,
4301
4301
  layout: N.layout,
4302
4302
  definition: N.meta
4303
4303
  }));
4304
- r.value.tiles = S.sort(m);
4304
+ r.value.tiles = S.sort(p);
4305
4305
  }, de = async () => {
4306
- if (l.value = "scale(1)", await ut(), h.value) {
4307
- const { availWidth: E, availHeight: S } = window.screen, { width: N, height: q } = h.value.getBoundingClientRect(), ee = Math.min(S / q, E / N);
4306
+ if (l.value = "scale(1)", await ut(), u.value) {
4307
+ const { availWidth: C, availHeight: S } = window.screen, { width: N, height: q } = u.value.getBoundingClientRect(), ee = Math.min(S / q, C / N);
4308
4308
  l.value = `scale(${ee})`;
4309
4309
  }
4310
4310
  }, Me = () => {
4311
- a.value && (document.fullscreenElement ? document.exitFullscreen() : a.value.requestFullscreen());
4311
+ h.value && (document.fullscreenElement ? document.exitFullscreen() : h.value.requestFullscreen());
4312
4312
  }, J = H(!1), Ie = () => {
4313
4313
  J.value = document.fullscreenElement !== null, J.value && de();
4314
4314
  };
4315
4315
  return e({
4316
4316
  refresh: M,
4317
4317
  toggleFullscreen: Me
4318
- }), (E, S) => {
4318
+ }), (C, S) => {
4319
4319
  const N = ge("KAlert");
4320
- return C(), K("div", {
4320
+ return x(), K("div", {
4321
4321
  ref_key: "dashboardContainer",
4322
- ref: a,
4322
+ ref: h,
4323
4323
  class: je(["kong-ui-public-dashboard-renderer", { "is-fullscreen": J.value }]),
4324
4324
  onFullscreenchange: Ie
4325
4325
  }, [
4326
4326
  oe("div", {
4327
4327
  ref_key: "layoutContainer",
4328
- ref: h,
4328
+ ref: u,
4329
4329
  class: "layout"
4330
4330
  }, [
4331
- x(f) && J.value ? (C(), K("div", Ps, [
4332
- De(E.$slots, "fullscreenHeader", {}, void 0, !0)
4331
+ E(f) && J.value ? (x(), K("div", Ps, [
4332
+ De(C.$slots, "fullscreenHeader", {}, void 0, !0)
4333
4333
  ])) : V("", !0),
4334
- x(f) ? (C(), O(qt(E.context.editable && !J.value ? Is : Ds), {
4334
+ E(f) ? (x(), O(qt(a.context.editable && !J.value ? Is : Ds), {
4335
4335
  key: 2,
4336
4336
  ref_key: "gridLayoutRef",
4337
- ref: u,
4337
+ ref: d,
4338
4338
  "tile-height": r.value.tile_height,
4339
4339
  tiles: D.value,
4340
4340
  onUpdateTiles: Y
4341
4341
  }, {
4342
4342
  tile: $(({ tile: q }) => [
4343
- q.meta.chart.type === "slottable" ? (C(), K("div", qs, [
4344
- De(E.$slots, q.meta.chart.id, {}, void 0, !0)
4345
- ])) : (C(), O(ks, {
4343
+ q.meta.chart.type === "slottable" ? (x(), K("div", qs, [
4344
+ De(C.$slots, q.meta.chart.id, {}, void 0, !0)
4345
+ ])) : (x(), O(ks, {
4346
4346
  key: J.value ? `${q.id}-tile` : `${q.id}-tile-fullscreen`,
4347
4347
  class: "tile-container",
4348
4348
  context: P.value,
4349
4349
  definition: q.meta,
4350
- height: q.layout.size.rows * (r.value.tile_height || x(Xe)) + parseInt(x(ei), 10),
4350
+ height: q.layout.size.rows * (r.value.tile_height || E(Xe)) + parseInt(E(ei), 10),
4351
4351
  "is-fullscreen": J.value,
4352
4352
  "query-ready": y.value,
4353
4353
  "refresh-counter": n.value,
@@ -4359,12 +4359,12 @@ const Os = ["data-id", "data-testid", "gs-h", "gs-w", "gs-x", "gs-y"], Hs = { cl
4359
4359
  }, null, 8, ["context", "definition", "height", "is-fullscreen", "query-ready", "refresh-counter", "tile-id", "onDuplicateTile", "onEditTile", "onRemoveTile"]))
4360
4360
  ]),
4361
4361
  _: 3
4362
- }, 40, ["tile-height", "tiles"])) : (C(), O(N, {
4362
+ }, 40, ["tile-height", "tiles"])) : (x(), O(N, {
4363
4363
  key: 1,
4364
4364
  appearance: "danger"
4365
4365
  }, {
4366
4366
  default: $(() => [
4367
- ht(ne(x(o).t("renderer.noQueryBridge")), 1)
4367
+ ht(ne(E(o).t("renderer.noQueryBridge")), 1)
4368
4368
  ]),
4369
4369
  _: 1
4370
4370
  }))
@@ -4379,7 +4379,7 @@ export {
4379
4379
  Rt as E,
4380
4380
  Ki as F,
4381
4381
  Ds as G,
4382
- pe as I,
4382
+ me as I,
4383
4383
  Ui as T,
4384
4384
  ct as _,
4385
4385
  Xe as a,