pennsieve-dashboard 0.2.0 → 0.2.2

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,7 +1,7 @@
1
1
  var Os = Object.defineProperty;
2
2
  var Ps = (o, e, t) => e in o ? Os(o, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : o[e] = t;
3
3
  var $ = (o, e, t) => Ps(o, typeof e != "symbol" ? e + "" : e, t);
4
- import { defineComponent as be, createElementBlock as B, openBlock as S, createElementVNode as N, ref as F, reactive as Qt, isRef as $s, isReactive as Bs, markRaw as Us, computed as de, watch as fe, resolveComponent as ie, createBlock as le, withCtx as V, createVNode as Y, Fragment as Le, renderList as tt, unref as he, createTextVNode as Ae, inject as Fs, shallowRef as os, resolveDirective as ls, renderSlot as vt, mergeProps as ni, withDirectives as De, toDisplayString as Re, withKeys as as, vShow as xt, vModelText as Ws, createCommentVNode as kt, toRaw as Gs, normalizeClass as Vs, resolveDynamicComponent as Fi, provide as qs, onBeforeMount as js, onMounted as Ys, onBeforeUnmount as Xs, defineAsyncComponent as Zs, nextTick as Wi } from "vue";
4
+ import { defineComponent as be, createElementBlock as B, openBlock as S, createElementVNode as N, ref as F, reactive as Qt, isRef as $s, isReactive as Bs, markRaw as Us, computed as ye, watch as pe, resolveComponent as ie, createBlock as le, withCtx as V, createVNode as Y, Fragment as Le, renderList as tt, unref as he, createTextVNode as Ae, inject as Fs, shallowRef as os, resolveDirective as ls, renderSlot as vt, mergeProps as ni, withDirectives as De, toDisplayString as Re, withKeys as as, vShow as xt, vModelText as Ws, createCommentVNode as kt, toRaw as Gs, normalizeClass as Vs, resolveDynamicComponent as Fi, onBeforeMount as qs, onMounted as js, onBeforeUnmount as Ys, provide as Xs, defineAsyncComponent as Zs, nextTick as Wi } from "vue";
5
5
  import { defineStore as Ks, storeToRefs as Jt } from "pinia";
6
6
  import { ElTag as Qs, ElTooltip as hs } from "element-plus";
7
7
  /*! Element Plus Icons Vue v2.3.2 */
@@ -90,11 +90,11 @@ var Js = /* @__PURE__ */ be({
90
90
  }), lr = or;
91
91
  const rt = Ks("globalPensieveDashVars", () => {
92
92
  const o = F([]), e = F({}), t = "dashboard-globalVarsStore", i = F([]), s = F([]), r = F({}), l = Qt({}), n = Qt({});
93
- function u(T, k, q = !1) {
94
- l[T] = k, n[T] = q;
93
+ function u(T, E, q = !1) {
94
+ l[T] = E, n[T] = q;
95
95
  }
96
96
  function a(T = {}) {
97
- for (const k of Object.keys(l)) delete l[k];
97
+ for (const E of Object.keys(l)) delete l[E];
98
98
  Object.assign(l, T);
99
99
  }
100
100
  const h = (T) => {
@@ -106,39 +106,38 @@ const rt = Ks("globalPensieveDashVars", () => {
106
106
  function c() {
107
107
  s.value = [...o.value], a({});
108
108
  }
109
- const m = (T) => s.value.find((k) => k.id === T), b = (T, k) => {
110
- i.value.push({ name: T, value: k });
109
+ const m = (T) => s.value.find((E) => E.id === T), b = (T, E) => {
110
+ i.value.push({ name: T, value: E });
111
111
  }, z = () => {
112
112
  i.value = [];
113
113
  }, O = (T) => {
114
- const k = L(T);
115
- r.value = k;
114
+ r.value = L(T);
116
115
  }, C = () => r.value;
117
116
  function L(T) {
118
- const k = {};
119
- if (!T || typeof T != "object") return k;
117
+ const E = {};
118
+ if (!T || typeof T != "object") return E;
120
119
  for (const [q, P] of Object.entries(T))
121
120
  if (P && typeof P == "object" && !($s(P) || Bs(P))) {
122
121
  const M = Object.getPrototypeOf(P) === Object.prototype;
123
- k[q] = M ? { ...P } : Us(P);
122
+ E[q] = M ? { ...P } : Us(P);
124
123
  } else
125
- k[q] = P;
126
- return k;
124
+ E[q] = P;
125
+ return E;
127
126
  }
128
127
  const A = (T) => {
129
- const k = s.value.find((q) => q.id === T);
130
- k && (k.Props = k.Props || {}, k.Props.locked = !k.Props.locked);
131
- }, E = (T) => T.map((k) => {
132
- const q = e.value[k.componentKey];
128
+ const E = s.value.find((q) => q.id === T);
129
+ E && (E.Props = E.Props || {}, E.Props.locked = !E.Props.locked);
130
+ }, k = (T) => T.map((E) => {
131
+ const q = e.value[E.componentKey];
133
132
  return q ? {
134
- ...k,
133
+ ...E,
135
134
  component: q
136
135
  // attach runtime component
137
136
  } : null;
138
- }).filter((k) => !!k);
137
+ }).filter((E) => !!E);
139
138
  function U(T) {
140
139
  }
141
- function _() {
140
+ function y() {
142
141
  }
143
142
  return {
144
143
  DASHBOARD_ITEMS: s,
@@ -149,7 +148,7 @@ const rt = Ks("globalPensieveDashVars", () => {
149
148
  Filters: l,
150
149
  displayFilters: n,
151
150
  registerGridProvider: U,
152
- unregisterGridProvider: _,
151
+ unregisterGridProvider: y,
153
152
  setFilter: u,
154
153
  clearFilter: h,
155
154
  clearAllFilters: p,
@@ -167,10 +166,10 @@ const rt = Ks("globalPensieveDashVars", () => {
167
166
  return;
168
167
  }
169
168
  try {
170
- const k = JSON.parse(T);
171
- s.value = Array.isArray(k.items) ? E(k.items) : [...o.value], a(k.filters ?? {});
172
- } catch (k) {
173
- console.error("Failed to parse globalVarsStore:", k), s.value = [...o.value], a({});
169
+ const E = JSON.parse(T);
170
+ s.value = Array.isArray(E.items) ? k(E.items) : [...o.value], a(E.filters ?? {});
171
+ } catch (E) {
172
+ console.error("Failed to parse globalVarsStore:", E), s.value = [...o.value], a({});
174
173
  }
175
174
  },
176
175
  setOptionServices: O,
@@ -186,17 +185,17 @@ const rt = Ks("globalPensieveDashVars", () => {
186
185
  },
187
186
  emits: ["close-dialog", "update-text-var"],
188
187
  setup(o, { emit: e }) {
189
- const t = rt(), { optionsData: i } = Jt(t), s = e, r = o, l = de({
188
+ const t = rt(), { optionsData: i } = Jt(t), s = e, r = o, l = ye({
190
189
  get: () => r.showDialog,
191
190
  set: (p) => {
192
191
  p || s("close-dialog");
193
192
  }
194
193
  }), n = F(r.reactiveSourceValue ?? ""), u = F(r.manualEntryValue ?? ""), a = F(!!r.hideHeaderValue);
195
- fe(() => r.reactiveSourceValue, (p) => {
194
+ pe(() => r.reactiveSourceValue, (p) => {
196
195
  n.value = p ?? "";
197
- }), fe(() => r.manualEntryValue, (p) => {
196
+ }), pe(() => r.manualEntryValue, (p) => {
198
197
  u.value = p ?? "";
199
- }, { immediate: !0 }), fe(() => r.hideHeaderValue, (p) => {
198
+ }, { immediate: !0 }), pe(() => r.hideHeaderValue, (p) => {
200
199
  a.value = !!p;
201
200
  });
202
201
  function h() {
@@ -296,12 +295,12 @@ const rt = Ks("globalPensieveDashVars", () => {
296
295
  const e = rt(), t = o;
297
296
  Fs("dashboard:globalVars", null);
298
297
  const i = F(t.displayText ?? "");
299
- fe(() => t.displayText, (C) => {
298
+ pe(() => t.displayText, (C) => {
300
299
  i.value = C ?? "";
301
300
  }, { immediate: !0 });
302
- const s = de(() => !!(t.bindedKey && t.bindedKey.trim() !== "")), r = de(() => {
303
- var E;
304
- const C = (E = t.bindedKey) == null ? void 0 : E.trim();
301
+ const s = ye(() => !!(t.bindedKey && t.bindedKey.trim() !== "")), r = ye(() => {
302
+ var k;
303
+ const C = (k = t.bindedKey) == null ? void 0 : k.trim();
305
304
  if (!C) return "—";
306
305
  const L = e.optionsData.find((U) => (U == null ? void 0 : U.name) === C), A = L == null ? void 0 : L.value;
307
306
  return Array.isArray(A) ? A.join(", ") : A && typeof A == "object" ? JSON.stringify(A) : A ?? "—";
@@ -321,14 +320,14 @@ const rt = Ks("globalPensieveDashVars", () => {
321
320
  c.value = !1;
322
321
  }
323
322
  function z({ manualEdit: C, reactiveSource: L, hideHeader: A }) {
324
- const E = e.getDashItem(t.widgetID);
325
- E && (E.hideHeader = A, L && L.trim() !== "" ? (E.Props = E.Props || {}, E.Props.bindedKey = L, E.Props.displayText = null, E.componentName = O(L)) : (E.Props = E.Props || {}, E.Props.bindedKey = null, E.Props.displayText = C ?? "", E.componentName = C ?? "Text"), e.saveToLocalStorage());
323
+ const k = e.getDashItem(t.widgetID);
324
+ k && (k.hideHeader = A, L && L.trim() !== "" ? (k.Props = k.Props || {}, k.Props.bindedKey = L, k.Props.displayText = null, k.componentName = O(L)) : (k.Props = k.Props || {}, k.Props.bindedKey = null, k.Props.displayText = C ?? "", k.componentName = C ?? "Text"));
326
325
  }
327
326
  function O(C) {
328
327
  return C ? C.replace(/([a-z])([A-Z])/g, "$1 $2").replace(/^./, (L) => L.toUpperCase()) : "";
329
328
  }
330
329
  return (C, L) => {
331
- const A = ie("el-input"), E = ls("click-out");
330
+ const A = ie("el-input"), k = ls("click-out");
332
331
  return S(), B(Le, null, [
333
332
  vt(C.$slots, "default", {
334
333
  widgetName: l.value,
@@ -349,8 +348,8 @@ const rt = Ks("globalPensieveDashVars", () => {
349
348
  modelValue: i.value,
350
349
  "onUpdate:modelValue": L[0] || (L[0] = (U) => i.value = U),
351
350
  onFocus: L[1] || (L[1] = (U) => {
352
- var _, y;
353
- return (y = (_ = U.target) == null ? void 0 : _.select) == null ? void 0 : y.call(_);
351
+ var y, _;
352
+ return (_ = (y = U.target) == null ? void 0 : y.select) == null ? void 0 : _.call(y);
354
353
  })
355
354
  }, null, 8, ["modelValue"])
356
355
  ], 512), [
@@ -365,7 +364,7 @@ const rt = Ks("globalPensieveDashVars", () => {
365
364
  [xt, !u.value]
366
365
  ])
367
366
  ], 32)), [
368
- [E, p]
367
+ [k, p]
369
368
  ])
370
369
  ], 16),
371
370
  Y(dr, {
@@ -379,7 +378,7 @@ const rt = Ks("globalPensieveDashVars", () => {
379
378
  ], 64);
380
379
  };
381
380
  }
382
- }), no = /* @__PURE__ */ Ne(fr, [["__scopeId", "data-v-5e485ae3"]]);
381
+ }), no = /* @__PURE__ */ Ne(fr, [["__scopeId", "data-v-bbd00006"]]);
383
382
  function oi() {
384
383
  return { async: !1, breaks: !1, extensions: null, gfm: !0, hooks: null, pedantic: !1, renderer: null, silent: !1, tokenizer: null, walkTokens: null };
385
384
  }
@@ -397,7 +396,7 @@ function H(o, e = "") {
397
396
  }
398
397
  var se = { codeRemoveIndent: /^(?: {1,4}| {0,3}\t)/gm, outputLinkReplace: /\\([\[\]])/g, indentCodeCompensation: /^(\s+)(?:```)/, beginningSpace: /^\s+/, endingHash: /#$/, startingSpaceChar: /^ /, endingSpaceChar: / $/, nonSpaceChar: /[^ ]/, newLineCharGlobal: /\n/g, tabCharGlobal: /\t/g, multipleSpaceGlobal: /\s+/g, blankLine: /^[ \t]*$/, doubleBlankLine: /\n[ \t]*\n[ \t]*$/, blockquoteStart: /^ {0,3}>/, blockquoteSetextReplace: /\n {0,3}((?:=+|-+) *)(?=\n|$)/g, blockquoteSetextReplace2: /^ {0,3}>[ \t]?/gm, listReplaceTabs: /^\t+/, listReplaceNesting: /^ {1,4}(?=( {4})*[^ ])/g, listIsTask: /^\[[ xX]\] /, listReplaceTask: /^\[[ xX]\] +/, anyLine: /\n.*\n/, hrefBrackets: /^<(.*)>$/, tableDelimiter: /[:|]/, tableAlignChars: /^\||\| *$/g, tableRowBlankLine: /\n[ \t]*$/, tableAlignRight: /^ *-+: *$/, tableAlignCenter: /^ *:-+: *$/, tableAlignLeft: /^ *:-+ *$/, startATag: /^<a /i, endATag: /^<\/a>/i, startPreScriptTag: /^<(pre|code|kbd|script)(\s|>)/i, endPreScriptTag: /^<\/(pre|code|kbd|script)(\s|>)/i, startAngleBracket: /^</, endAngleBracket: />$/, pedanticHrefTitle: /^([^'"]*[^\s])\s+(['"])(.*)\2/, unicodeAlphaNumeric: /[\p{L}\p{N}]/u, escapeTest: /[&<>"']/, escapeReplace: /[&<>"']/g, escapeTestNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/, escapeReplaceNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g, unescapeTest: /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig, caret: /(^|[^\[])\^/g, percentDecode: /%25/g, findPipe: /\|/g, splitPipe: / \|/, slashPipe: /\\\|/g, carriageReturn: /\r\n|\r/g, spaceLine: /^ +$/gm, notSpaceStart: /^\S*/, endingNewline: /\n$/, listItemRegex: (o) => new RegExp(`^( {0,3}${o})((?:[ ][^\\n]*)?(?:\\n|$))`), nextBulletRegex: (o) => new RegExp(`^ {0,${Math.min(3, o - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`), hrRegex: (o) => new RegExp(`^ {0,${Math.min(3, o - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`), fencesBeginRegex: (o) => new RegExp(`^ {0,${Math.min(3, o - 1)}}(?:\`\`\`|~~~)`), headingBeginRegex: (o) => new RegExp(`^ {0,${Math.min(3, o - 1)}}#`), htmlBeginRegex: (o) => new RegExp(`^ {0,${Math.min(3, o - 1)}}<(?:[a-z].*>|!--)`, "i") }, gr = /^(?:[ \t]*(?:\n|$))+/, mr = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/, _r = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, nt = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, yr = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, li = /(?:[*+-]|\d{1,9}[.)])/, ds = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/, ps = H(ds).replace(/bull/g, li).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/\|table/g, "").getRegex(), br = H(ds).replace(/bull/g, li).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/table/g, / {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(), ai = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, wr = /^[^\n]+/, hi = /(?!\s*\])(?:\\.|[^\[\]\\])+/, vr = H(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", hi).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), xr = H(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, li).getRegex(), zt = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", ui = /<!--(?:-?>|[\s\S]*?(?:-->|$))/, kr = H("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))", "i").replace("comment", ui).replace("tag", zt).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), fs = H(ai).replace("hr", nt).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", zt).getRegex(), Er = H(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", fs).getRegex(), ci = { blockquote: Er, code: mr, def: vr, fences: _r, heading: yr, hr: nt, html: kr, lheading: ps, list: xr, newline: gr, paragraph: fs, table: et, text: wr }, Gi = H("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", nt).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3} )[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", zt).getRegex(), Tr = { ...ci, lheading: br, table: Gi, paragraph: H(ai).replace("hr", nt).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", Gi).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", zt).getRegex() }, Rr = { ...ci, html: H(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment", ui).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(), def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/, heading: /^(#{1,6})(.*)(?:\n+|$)/, fences: et, lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/, paragraph: H(ai).replace("hr", nt).replace("heading", ` *#{1,6} *[^
399
398
  ]`).replace("lheading", ps).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex() }, Sr = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, Cr = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, gs = /^( {2,}|\\)\n(?!\s*$)/, Ar = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, Nt = /[\p{P}\p{S}]/u, di = /[\s\p{P}\p{S}]/u, ms = /[^\s\p{P}\p{S}]/u, Dr = H(/^((?![*_])punctSpace)/, "u").replace(/punctSpace/g, di).getRegex(), _s = /(?!~)[\p{P}\p{S}]/u, Lr = /(?!~)[\s\p{P}\p{S}]/u, zr = /(?:[^\s\p{P}\p{S}]|~)/u, Nr = /\[[^[\]]*?\]\((?:\\.|[^\\\(\)]|\((?:\\.|[^\\\(\)])*\))*\)|`[^`]*?`|<(?! )[^<>]*?>/g, ys = /^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/, Mr = H(ys, "u").replace(/punct/g, Nt).getRegex(), Ir = H(ys, "u").replace(/punct/g, _s).getRegex(), bs = "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)", Hr = H(bs, "gu").replace(/notPunctSpace/g, ms).replace(/punctSpace/g, di).replace(/punct/g, Nt).getRegex(), Or = H(bs, "gu").replace(/notPunctSpace/g, zr).replace(/punctSpace/g, Lr).replace(/punct/g, _s).getRegex(), Pr = H("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)", "gu").replace(/notPunctSpace/g, ms).replace(/punctSpace/g, di).replace(/punct/g, Nt).getRegex(), $r = H(/\\(punct)/, "gu").replace(/punct/g, Nt).getRegex(), Br = H(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme", /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email", /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(), Ur = H(ui).replace("(?:-->|$)", "-->").getRegex(), Fr = H("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment", Ur).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), Et = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/, Wr = H(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label", Et).replace("href", /<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), ws = H(/^!?\[(label)\]\[(ref)\]/).replace("label", Et).replace("ref", hi).getRegex(), vs = H(/^!?\[(ref)\](?:\[\])?/).replace("ref", hi).getRegex(), Gr = H("reflink|nolink(?!\\()", "g").replace("reflink", ws).replace("nolink", vs).getRegex(), pi = { _backpedal: et, anyPunctuation: $r, autolink: Br, blockSkip: Nr, br: gs, code: Cr, del: et, emStrongLDelim: Mr, emStrongRDelimAst: Hr, emStrongRDelimUnd: Pr, escape: Sr, link: Wr, nolink: vs, punctuation: Dr, reflink: ws, reflinkSearch: Gr, tag: Fr, text: Ar, url: et }, Vr = { ...pi, link: H(/^!?\[(label)\]\((.*?)\)/).replace("label", Et).getRegex(), reflink: H(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", Et).getRegex() }, ei = { ...pi, emStrongRDelimAst: Or, emStrongLDelim: Ir, url: H(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/, "i").replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(), _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/, del: /^(~~?)(?=[^\s~])((?:\\.|[^\\])*?(?:\\.|[^\s~\\]))\1(?=[^~]|$)/, text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/ }, qr = { ...ei, br: H(gs).replace("{2,}", "*").getRegex(), text: H(ei.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex() }, mt = { normal: ci, gfm: Tr, pedantic: Rr }, je = { normal: pi, gfm: ei, breaks: qr, pedantic: Vr }, jr = { "&": "&amp;", "<": "&lt;", ">": "&gt;", '"': "&quot;", "'": "&#39;" }, Vi = (o) => jr[o];
400
- function me(o, e) {
399
+ function ge(o, e) {
401
400
  if (e) {
402
401
  if (se.escapeTest.test(o)) return o.replace(se.escapeReplace, Vi);
403
402
  } else if (se.escapeTestNoEncode.test(o)) return o.replace(se.escapeReplaceNoEncode, Vi);
@@ -555,20 +554,20 @@ ${h}` : h;
555
554
  `, 1)[0], m = !p.trim(), b = 0;
556
555
  if (this.options.pedantic ? (b = 2, h = p.trimStart()) : m ? b = e[1].length + 1 : (b = e[2].search(this.rules.other.nonSpaceChar), b = b > 4 ? 1 : b, h = p.slice(b), b += e[1].length), m && this.rules.other.blankLine.test(c) && (a += c + `
557
556
  `, o = o.substring(c.length + 1), u = !0), !u) {
558
- let C = this.rules.other.nextBulletRegex(b), L = this.rules.other.hrRegex(b), A = this.rules.other.fencesBeginRegex(b), E = this.rules.other.headingBeginRegex(b), U = this.rules.other.htmlBeginRegex(b);
557
+ let C = this.rules.other.nextBulletRegex(b), L = this.rules.other.hrRegex(b), A = this.rules.other.fencesBeginRegex(b), k = this.rules.other.headingBeginRegex(b), U = this.rules.other.htmlBeginRegex(b);
559
558
  for (; o; ) {
560
- let _ = o.split(`
561
- `, 1)[0], y;
562
- if (c = _, this.options.pedantic ? (c = c.replace(this.rules.other.listReplaceNesting, " "), y = c) : y = c.replace(this.rules.other.tabCharGlobal, " "), A.test(c) || E.test(c) || U.test(c) || C.test(c) || L.test(c)) break;
563
- if (y.search(this.rules.other.nonSpaceChar) >= b || !c.trim()) h += `
564
- ` + y.slice(b);
559
+ let y = o.split(`
560
+ `, 1)[0], _;
561
+ if (c = y, this.options.pedantic ? (c = c.replace(this.rules.other.listReplaceNesting, " "), _ = c) : _ = c.replace(this.rules.other.tabCharGlobal, " "), A.test(c) || k.test(c) || U.test(c) || C.test(c) || L.test(c)) break;
562
+ if (_.search(this.rules.other.nonSpaceChar) >= b || !c.trim()) h += `
563
+ ` + _.slice(b);
565
564
  else {
566
- if (m || p.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || A.test(p) || E.test(p) || L.test(p)) break;
565
+ if (m || p.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || A.test(p) || k.test(p) || L.test(p)) break;
567
566
  h += `
568
567
  ` + c;
569
568
  }
570
- !m && !c.trim() && (m = !0), a += _ + `
571
- `, o = o.substring(_.length + 1), p = y.slice(b);
569
+ !m && !c.trim() && (m = !0), a += y + `
570
+ `, o = o.substring(y.length + 1), p = _.slice(b);
572
571
  }
573
572
  }
574
573
  s.loose || (l ? s.loose = !0 : this.rules.other.doubleBlankLine.test(a) && (l = !0));
@@ -960,8 +959,8 @@ ${h}` : h;
960
959
  var r;
961
960
  let i = (r = (e || "").match(se.notSpaceStart)) == null ? void 0 : r[0], s = o.replace(se.endingNewline, "") + `
962
961
  `;
963
- return i ? '<pre><code class="language-' + me(i) + '">' + (t ? s : me(s, !0)) + `</code></pre>
964
- ` : "<pre><code>" + (t ? s : me(s, !0)) + `</code></pre>
962
+ return i ? '<pre><code class="language-' + ge(i) + '">' + (t ? s : ge(s, !0)) + `</code></pre>
963
+ ` : "<pre><code>" + (t ? s : ge(s, !0)) + `</code></pre>
965
964
  `;
966
965
  }
967
966
  blockquote({ tokens: o }) {
@@ -999,7 +998,7 @@ ${this.parser.parse(o)}</blockquote>
999
998
  let e = "";
1000
999
  if (o.task) {
1001
1000
  let i = this.checkbox({ checked: !!o.checked });
1002
- o.loose ? ((t = o.tokens[0]) == null ? void 0 : t.type) === "paragraph" ? (o.tokens[0].text = i + " " + o.tokens[0].text, o.tokens[0].tokens && o.tokens[0].tokens.length > 0 && o.tokens[0].tokens[0].type === "text" && (o.tokens[0].tokens[0].text = i + " " + me(o.tokens[0].tokens[0].text), o.tokens[0].tokens[0].escaped = !0)) : o.tokens.unshift({ type: "text", raw: i + " ", text: i + " ", escaped: !0 }) : e += i + " ";
1001
+ o.loose ? ((t = o.tokens[0]) == null ? void 0 : t.type) === "paragraph" ? (o.tokens[0].text = i + " " + o.tokens[0].text, o.tokens[0].tokens && o.tokens[0].tokens.length > 0 && o.tokens[0].tokens[0].type === "text" && (o.tokens[0].tokens[0].text = i + " " + ge(o.tokens[0].tokens[0].text), o.tokens[0].tokens[0].escaped = !0)) : o.tokens.unshift({ type: "text", raw: i + " ", text: i + " ", escaped: !0 }) : e += i + " ";
1003
1002
  }
1004
1003
  return e += this.parser.parse(o.tokens, !!o.loose), `<li>${e}</li>
1005
1004
  `;
@@ -1045,7 +1044,7 @@ ${o}</tr>
1045
1044
  return `<em>${this.parser.parseInline(o)}</em>`;
1046
1045
  }
1047
1046
  codespan({ text: o }) {
1048
- return `<code>${me(o, !0)}</code>`;
1047
+ return `<code>${ge(o, !0)}</code>`;
1049
1048
  }
1050
1049
  br(o) {
1051
1050
  return "<br>";
@@ -1058,18 +1057,18 @@ ${o}</tr>
1058
1057
  if (s === null) return i;
1059
1058
  o = s;
1060
1059
  let r = '<a href="' + o + '"';
1061
- return e && (r += ' title="' + me(e) + '"'), r += ">" + i + "</a>", r;
1060
+ return e && (r += ' title="' + ge(e) + '"'), r += ">" + i + "</a>", r;
1062
1061
  }
1063
1062
  image({ href: o, title: e, text: t, tokens: i }) {
1064
1063
  i && (t = this.parser.parseInline(i, this.parser.textRenderer));
1065
1064
  let s = qi(o);
1066
- if (s === null) return me(t);
1065
+ if (s === null) return ge(t);
1067
1066
  o = s;
1068
1067
  let r = `<img src="${o}" alt="${t}"`;
1069
- return e && (r += ` title="${me(e)}"`), r += ">", r;
1068
+ return e && (r += ` title="${ge(e)}"`), r += ">", r;
1070
1069
  }
1071
1070
  text(o) {
1072
- return "tokens" in o && o.tokens ? this.parser.parseInline(o.tokens) : "escaped" in o && o.escaped ? o.text : me(o.text);
1071
+ return "tokens" in o && o.tokens ? this.parser.parseInline(o.tokens) : "escaped" in o && o.escaped ? o.text : ge(o.text);
1073
1072
  }
1074
1073
  }, fi = class {
1075
1074
  strong({ text: o }) {
@@ -1410,7 +1409,7 @@ ${o}</tr>
1410
1409
  return (t) => {
1411
1410
  if (t.message += `
1412
1411
  Please report this to https://github.com/markedjs/marked.`, o) {
1413
- let i = "<p>An error occurred:</p><pre>" + me(t.message + "", !0) + "</pre>";
1412
+ let i = "<p>An error occurred:</p><pre>" + ge(t.message + "", !0) + "</pre>";
1414
1413
  return e ? Promise.resolve(i) : i;
1415
1414
  }
1416
1415
  if (e) return Promise.reject(t);
@@ -1618,17 +1617,17 @@ function Rs() {
1618
1617
  const v = t.createElement("template");
1619
1618
  v.content && v.content.ownerDocument && (t = v.content.ownerDocument);
1620
1619
  }
1621
- let E, U = "";
1620
+ let k, U = "";
1622
1621
  const {
1623
- implementation: _,
1624
- createNodeIterator: y,
1622
+ implementation: y,
1623
+ createNodeIterator: _,
1625
1624
  createDocumentFragment: T,
1626
- getElementsByTagName: k
1625
+ getElementsByTagName: E
1627
1626
  } = t, {
1628
1627
  importNode: q
1629
1628
  } = i;
1630
1629
  let P = ss();
1631
- e.isSupported = typeof xs == "function" && typeof A == "function" && _ && _.createHTMLDocument !== void 0;
1630
+ e.isSupported = typeof xs == "function" && typeof A == "function" && y && y.createHTMLDocument !== void 0;
1632
1631
  const {
1633
1632
  MUSTACHE_EXPR: M,
1634
1633
  ERB_EXPR: Se,
@@ -1690,9 +1689,9 @@ function Rs() {
1690
1689
  throw Ke('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
1691
1690
  if (typeof d.TRUSTED_TYPES_POLICY.createScriptURL != "function")
1692
1691
  throw Ke('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');
1693
- E = d.TRUSTED_TYPES_POLICY, U = E.createHTML("");
1692
+ k = d.TRUSTED_TYPES_POLICY, U = k.createHTML("");
1694
1693
  } else
1695
- E === void 0 && (E = yn(m, s)), E !== null && typeof U == "string" && (U = E.createHTML(""));
1694
+ k === void 0 && (k = yn(m, s)), k !== null && typeof U == "string" && (U = k.createHTML(""));
1696
1695
  re && re(d), Ue = d;
1697
1696
  }
1698
1697
  }, Li = D({}, [...jt, ...Yt, ...ln]), zi = D({}, [...Xt, ...an]), Is = function(d) {
@@ -1703,7 +1702,7 @@ function Rs() {
1703
1702
  });
1704
1703
  const w = wt(d.tagName), W = wt(g.tagName);
1705
1704
  return Ft[d.namespaceURI] ? d.namespaceURI === pt ? g.namespaceURI === we ? w === "svg" : g.namespaceURI === dt ? w === "svg" && (W === "annotation-xml" || ft[W]) : !!Li[w] : d.namespaceURI === dt ? g.namespaceURI === we ? w === "math" : g.namespaceURI === pt ? w === "math" && gt[W] : !!zi[w] : d.namespaceURI === we ? g.namespaceURI === pt && !gt[W] || g.namespaceURI === dt && !ft[W] ? !1 : !zi[w] && (Ls[w] || !Li[w]) : !!(Ve === "application/xhtml+xml" && Ft[d.namespaceURI]) : !1;
1706
- }, ge = function(d) {
1705
+ }, fe = function(d) {
1707
1706
  Xe(e.removed, {
1708
1707
  element: d
1709
1708
  });
@@ -1727,7 +1726,7 @@ function Rs() {
1727
1726
  if (g.removeAttribute(d), d === "is")
1728
1727
  if (Oe || ut)
1729
1728
  try {
1730
- ge(g);
1729
+ fe(g);
1731
1730
  } catch {
1732
1731
  }
1733
1732
  else
@@ -1744,23 +1743,23 @@ function Rs() {
1744
1743
  w = j && j[0];
1745
1744
  }
1746
1745
  Ve === "application/xhtml+xml" && Be === we && (d = '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' + d + "</body></html>");
1747
- const W = E ? E.createHTML(d) : d;
1746
+ const W = k ? k.createHTML(d) : d;
1748
1747
  if (Be === we)
1749
1748
  try {
1750
1749
  g = new c().parseFromString(W, Ve);
1751
1750
  } catch {
1752
1751
  }
1753
1752
  if (!g || !g.documentElement) {
1754
- g = _.createDocument(Be, "template", null);
1753
+ g = y.createDocument(Be, "template", null);
1755
1754
  try {
1756
1755
  g.documentElement.innerHTML = Ut ? U : W;
1757
1756
  } catch {
1758
1757
  }
1759
1758
  }
1760
1759
  const J = g.body || g.documentElement;
1761
- return d && w && J.insertBefore(t.createTextNode(w), J.childNodes[0] || null), Be === we ? k.call(g, Ce ? "html" : "body")[0] : Ce ? g.documentElement : J;
1760
+ return d && w && J.insertBefore(t.createTextNode(w), J.childNodes[0] || null), Be === we ? E.call(g, Ce ? "html" : "body")[0] : Ce ? g.documentElement : J;
1762
1761
  }, Mi = function(d) {
1763
- return y.call(
1762
+ return _.call(
1764
1763
  d.ownerDocument || d,
1765
1764
  d,
1766
1765
  // eslint-disable-next-line no-bitwise
@@ -1780,13 +1779,13 @@ function Rs() {
1780
1779
  const Hi = function(d) {
1781
1780
  let g = null;
1782
1781
  if (ve(P.beforeSanitizeElements, d, null), Gt(d))
1783
- return ge(d), !0;
1782
+ return fe(d), !0;
1784
1783
  const w = Z(d.nodeName);
1785
1784
  if (ve(P.uponSanitizeElement, d, {
1786
1785
  tagName: w,
1787
1786
  allowedTags: X
1788
1787
  }), ht && d.hasChildNodes() && !Ii(d.firstElementChild) && te(/<[/\w!]/g, d.innerHTML) && te(/<[/\w!]/g, d.textContent) || d.nodeType === Je.progressingInstruction || ht && d.nodeType === Je.comment && te(/<[/\w]/g, d.data))
1789
- return ge(d), !0;
1788
+ return fe(d), !0;
1790
1789
  if (!X[w] || We[w]) {
1791
1790
  if (!We[w] && Pi(w) && (G.tagNameCheck instanceof RegExp && te(G.tagNameCheck, w) || G.tagNameCheck instanceof Function && G.tagNameCheck(w)))
1792
1791
  return !1;
@@ -1800,9 +1799,9 @@ function Rs() {
1800
1799
  }
1801
1800
  }
1802
1801
  }
1803
- return ge(d), !0;
1802
+ return fe(d), !0;
1804
1803
  }
1805
- return d instanceof u && !Is(d) || (w === "noscript" || w === "noembed" || w === "noframes") && te(/<\/no(script|embed|frames)/i, d.innerHTML) ? (ge(d), !0) : (He && d.nodeType === Je.text && (g = d.textContent, _t([M, Se, Ie], (W) => {
1804
+ return d instanceof u && !Is(d) || (w === "noscript" || w === "noembed" || w === "noframes") && te(/<\/no(script|embed|frames)/i, d.innerHTML) ? (fe(d), !0) : (He && d.nodeType === Je.text && (g = d.textContent, _t([M, Se, Ie], (W) => {
1806
1805
  g = Ze(g, W, " ");
1807
1806
  }), d.textContent !== g && (Xe(e.removed, {
1808
1807
  element: d.cloneNode()
@@ -1880,20 +1879,20 @@ function Rs() {
1880
1879
  Fe(j, d);
1881
1880
  continue;
1882
1881
  }
1883
- if (E && typeof m == "object" && typeof m.getAttributeType == "function" && !oe)
1882
+ if (k && typeof m == "object" && typeof m.getAttributeType == "function" && !oe)
1884
1883
  switch (m.getAttributeType(Bi, qe)) {
1885
1884
  case "TrustedHTML": {
1886
- ee = E.createHTML(ee);
1885
+ ee = k.createHTML(ee);
1887
1886
  break;
1888
1887
  }
1889
1888
  case "TrustedScriptURL": {
1890
- ee = E.createScriptURL(ee);
1889
+ ee = k.createScriptURL(ee);
1891
1890
  break;
1892
1891
  }
1893
1892
  }
1894
1893
  if (ee !== Vt)
1895
1894
  try {
1896
- oe ? d.setAttributeNS(oe, j, ee) : d.setAttribute(j, ee), Gt(d) ? ge(d) : Zi(e.removed);
1895
+ oe ? d.setAttributeNS(oe, j, ee) : d.setAttribute(j, ee), Gt(d) ? fe(d) : Zi(e.removed);
1897
1896
  } catch {
1898
1897
  Fe(j, d);
1899
1898
  }
@@ -1927,11 +1926,11 @@ function Rs() {
1927
1926
  else {
1928
1927
  if (!Oe && !He && !Ce && // eslint-disable-next-line unicorn/prefer-includes
1929
1928
  v.indexOf("<") === -1)
1930
- return E && ct ? E.createHTML(v) : v;
1929
+ return k && ct ? k.createHTML(v) : v;
1931
1930
  if (g = Ni(v), !g)
1932
1931
  return Oe ? null : ct ? U : "";
1933
1932
  }
1934
- g && Pt && ge(g.firstChild);
1933
+ g && Pt && fe(g.firstChild);
1935
1934
  const j = Mi(Ge ? v : g);
1936
1935
  for (; W = j.nextNode(); )
1937
1936
  Hi(W), $i(W), W.content instanceof r && Hs(W.content);
@@ -1949,7 +1948,7 @@ function Rs() {
1949
1948
  return Ce && X["!doctype"] && g.ownerDocument && g.ownerDocument.doctype && g.ownerDocument.doctype.name && te(Ts, g.ownerDocument.doctype.name) && (oe = "<!DOCTYPE " + g.ownerDocument.doctype.name + `>
1950
1949
  ` + oe), He && _t([M, Se, Ie], (xe) => {
1951
1950
  oe = Ze(oe, xe, " ");
1952
- }), E && ct ? E.createHTML(oe) : oe;
1951
+ }), k && ct ? k.createHTML(oe) : oe;
1953
1952
  }, e.setConfig = function() {
1954
1953
  let v = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
1955
1954
  Wt(v), Ot = !0;
@@ -1991,14 +1990,14 @@ const wn = ["innerHTML"], vn = "Markdown", xn = /* @__PURE__ */ be({
1991
1990
  breaks: !0
1992
1991
  });
1993
1992
  const r = F(t.markdownText ?? "");
1994
- fe(() => t.markdownText, (h) => {
1993
+ pe(() => t.markdownText, (h) => {
1995
1994
  h !== void 0 && h !== r.value && (r.value = h);
1996
1995
  });
1997
1996
  const l = F(t.mode ? t.mode === "edit" : !1);
1998
- fe(() => t.mode, (h) => {
1997
+ pe(() => t.mode, (h) => {
1999
1998
  h && (l.value = h === "edit");
2000
1999
  });
2001
- const n = de(() => {
2000
+ const n = ye(() => {
2002
2001
  const h = t.inputFormat === "html" ? r.value ?? "" : I.parse(r.value ?? "");
2003
2002
  return t.sanitize === !1 ? h : bn.sanitize(h);
2004
2003
  });
@@ -2030,7 +2029,7 @@ const wn = ["innerHTML"], vn = "Markdown", xn = /* @__PURE__ */ be({
2030
2029
  ], 16)
2031
2030
  ], 64));
2032
2031
  }
2033
- }), oo = /* @__PURE__ */ Ne(xn, [["__scopeId", "data-v-b2d32c29"]]);
2032
+ }), oo = /* @__PURE__ */ Ne(xn, [["__scopeId", "data-v-5bf532d5"]]);
2034
2033
  function kn(o, e, t, i, s) {
2035
2034
  let r = (...l) => (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(o, l));
2036
2035
  return r.prototype = e.prototype, r;
@@ -2332,7 +2331,7 @@ class f {
2332
2331
  ), (i || e.target).dispatchEvent(s);
2333
2332
  }
2334
2333
  }
2335
- class _e {
2334
+ class me {
2336
2335
  constructor(e = {}) {
2337
2336
  this.addedNodes = [], this.removedNodes = [], this.column = e.column || 12, this.maxRow = e.maxRow, this._float = e.float, this.nodes = e.nodes || [], this.onChange = e.onChange;
2338
2337
  }
@@ -2498,7 +2497,7 @@ class _e {
2498
2497
  * @param resizing if out of bound, resize down or move into the grid to fit ?
2499
2498
  */
2500
2499
  prepareNode(e, t) {
2501
- e._id = e._id ?? _e._idSeq++, (e.x === void 0 || e.y === void 0 || e.x === null || e.y === null) && (e.autoPosition = !0);
2500
+ e._id = e._id ?? me._idSeq++, (e.x === void 0 || e.y === void 0 || e.x === null || e.y === null) && (e.autoPosition = !0);
2502
2501
  let i = { x: 0, y: 0, w: 1, h: 1 };
2503
2502
  return f.defaults(e, i), e.autoPosition || delete e.autoPosition, e.noResize || delete e.noResize, e.noMove || delete e.noMove, f.sanitizeMinMax(e), typeof e.x == "string" && (e.x = Number(e.x)), typeof e.y == "string" && (e.y = Number(e.y)), typeof e.w == "string" && (e.w = Number(e.w)), typeof e.h == "string" && (e.h = Number(e.h)), isNaN(e.x) && (e.x = i.x, e.autoPosition = !0), isNaN(e.y) && (e.y = i.y, e.autoPosition = !0), isNaN(e.w) && (e.w = i.w), isNaN(e.h) && (e.h = i.h), this.nodeBoundFix(e, t), e;
2504
2503
  }
@@ -2580,7 +2579,7 @@ class _e {
2580
2579
  return !1;
2581
2580
  if (t.pack = !0, !this.maxRow)
2582
2581
  return this.moveNode(e, t);
2583
- let i, s = new _e({
2582
+ let i, s = new me({
2584
2583
  column: this.column,
2585
2584
  float: this.float,
2586
2585
  nodes: this.nodes.map((l) => l._id === e._id ? (i = { ...l }, i) : { ...l })
@@ -2602,7 +2601,7 @@ class _e {
2602
2601
  willItFit(e) {
2603
2602
  if (delete e._willFitPos, !this.maxRow)
2604
2603
  return !0;
2605
- let t = new _e({
2604
+ let t = new me({
2606
2605
  column: this.column,
2607
2606
  float: this.float,
2608
2607
  nodes: this.nodes.map((s) => ({ ...s }))
@@ -2747,7 +2746,7 @@ class _e {
2747
2746
  return e.forEach((r, l) => {
2748
2747
  if (r._id === void 0) {
2749
2748
  const n = r.id ? this.nodes.find((u) => u.id === r.id) : void 0;
2750
- r._id = (n == null ? void 0 : n._id) ?? _e._idSeq++;
2749
+ r._id = (n == null ? void 0 : n._id) ?? me._idSeq++;
2751
2750
  }
2752
2751
  s[l] = { x: r.x, y: r.y, w: r.w, _id: r._id };
2753
2752
  }), this._layouts = i ? [] : this._layouts || [], this._layouts[t] = s, this;
@@ -2758,7 +2757,7 @@ class _e {
2758
2757
  * @param column corresponding column index to save it under
2759
2758
  */
2760
2759
  cacheOneLayout(e, t) {
2761
- e._id = e._id ?? _e._idSeq++;
2760
+ e._id = e._id ?? me._idSeq++;
2762
2761
  let i = { x: e.x, y: e.y, w: e.w, _id: e._id };
2763
2762
  (e.autoPosition || e.x === void 0) && (delete i.x, delete i.y, e.autoPosition && (i.autoPosition = !0)), this._layouts = this._layouts || [], this._layouts[t] = this._layouts[t] || [];
2764
2763
  let s = this.findCacheLayout(e, t);
@@ -2782,7 +2781,7 @@ class _e {
2782
2781
  return this;
2783
2782
  }
2784
2783
  }
2785
- _e._idSeq = 0;
2784
+ me._idSeq = 0;
2786
2785
  const ae = {
2787
2786
  alwaysShowResizeHandle: "mobile",
2788
2787
  animate: !0,
@@ -2823,8 +2822,8 @@ const ae = {
2823
2822
  };
2824
2823
  class x {
2825
2824
  }
2826
- const pe = typeof window < "u" && typeof document < "u" && ("ontouchstart" in document || "ontouchstart" in window || window.DocumentTouch && document instanceof window.DocumentTouch || navigator.maxTouchPoints > 0 || navigator.msMaxTouchPoints > 0);
2827
- class ye {
2825
+ const de = typeof window < "u" && typeof document < "u" && ("ontouchstart" in document || "ontouchstart" in window || window.DocumentTouch && document instanceof window.DocumentTouch || navigator.maxTouchPoints > 0 || navigator.msMaxTouchPoints > 0);
2826
+ class _e {
2828
2827
  }
2829
2828
  function St(o, e) {
2830
2829
  if (o.touches.length > 1)
@@ -2901,17 +2900,17 @@ function Ss(o, e) {
2901
2900
  ), o.target.dispatchEvent(t);
2902
2901
  }
2903
2902
  function Ct(o) {
2904
- ye.touchHandled || (ye.touchHandled = !0, St(o, "mousedown"));
2903
+ _e.touchHandled || (_e.touchHandled = !0, St(o, "mousedown"));
2905
2904
  }
2906
2905
  function At(o) {
2907
- ye.touchHandled && St(o, "mousemove");
2906
+ _e.touchHandled && St(o, "mousemove");
2908
2907
  }
2909
2908
  function Dt(o) {
2910
- if (!ye.touchHandled)
2909
+ if (!_e.touchHandled)
2911
2910
  return;
2912
- ye.pointerLeaveTimeout && (window.clearTimeout(ye.pointerLeaveTimeout), delete ye.pointerLeaveTimeout);
2911
+ _e.pointerLeaveTimeout && (window.clearTimeout(_e.pointerLeaveTimeout), delete _e.pointerLeaveTimeout);
2913
2912
  const e = !!x.dragElement;
2914
- St(o, "mouseup"), e || St(o, "click"), ye.touchHandled = !1;
2913
+ St(o, "mouseup"), e || St(o, "click"), _e.touchHandled = !1;
2915
2914
  }
2916
2915
  function Lt(o) {
2917
2916
  o.pointerType !== "mouse" && o.target.releasePointerCapture(o.pointerId);
@@ -2920,8 +2919,8 @@ function rs(o) {
2920
2919
  x.dragElement && o.pointerType !== "mouse" && Ss(o, "mouseenter");
2921
2920
  }
2922
2921
  function ns(o) {
2923
- x.dragElement && o.pointerType !== "mouse" && (ye.pointerLeaveTimeout = window.setTimeout(() => {
2924
- delete ye.pointerLeaveTimeout, Ss(o, "mouseleave");
2922
+ x.dragElement && o.pointerType !== "mouse" && (_e.pointerLeaveTimeout = window.setTimeout(() => {
2923
+ delete _e.pointerLeaveTimeout, Ss(o, "mouseleave");
2925
2924
  }, 10));
2926
2925
  }
2927
2926
  class Mt {
@@ -2931,15 +2930,15 @@ class Mt {
2931
2930
  /** @internal */
2932
2931
  _init() {
2933
2932
  const e = document.createElement("div");
2934
- return e.classList.add("ui-resizable-handle"), e.classList.add(`${Mt.prefix}${this.dir}`), e.style.zIndex = "100", e.style.userSelect = "none", this.el = e, this.host.appendChild(this.el), this.el.addEventListener("mousedown", this._mouseDown), pe && (this.el.addEventListener("touchstart", Ct), this.el.addEventListener("pointerdown", Lt)), this;
2933
+ return e.classList.add("ui-resizable-handle"), e.classList.add(`${Mt.prefix}${this.dir}`), e.style.zIndex = "100", e.style.userSelect = "none", this.el = e, this.host.appendChild(this.el), this.el.addEventListener("mousedown", this._mouseDown), de && (this.el.addEventListener("touchstart", Ct), this.el.addEventListener("pointerdown", Lt)), this;
2935
2934
  }
2936
2935
  /** call this when resize handle needs to be removed and cleaned up */
2937
2936
  destroy() {
2938
- return this.moving && this._mouseUp(this.mouseDownEvent), this.el.removeEventListener("mousedown", this._mouseDown), pe && (this.el.removeEventListener("touchstart", Ct), this.el.removeEventListener("pointerdown", Lt)), this.host.removeChild(this.el), delete this.el, delete this.host, this;
2937
+ return this.moving && this._mouseUp(this.mouseDownEvent), this.el.removeEventListener("mousedown", this._mouseDown), de && (this.el.removeEventListener("touchstart", Ct), this.el.removeEventListener("pointerdown", Lt)), this.host.removeChild(this.el), delete this.el, delete this.host, this;
2939
2938
  }
2940
2939
  /** @internal called on mouse down on us: capture move on the entire document (mouse might not stay on us) until we release the mouse */
2941
2940
  _mouseDown(e) {
2942
- this.mouseDownEvent = e, document.addEventListener("mousemove", this._mouseMove, !0), document.addEventListener("mouseup", this._mouseUp, !0), pe && (this.el.addEventListener("touchmove", At), this.el.addEventListener("touchend", Dt)), e.stopPropagation(), e.preventDefault();
2941
+ this.mouseDownEvent = e, document.addEventListener("mousemove", this._mouseMove, !0), document.addEventListener("mouseup", this._mouseUp, !0), de && (this.el.addEventListener("touchmove", At), this.el.addEventListener("touchend", Dt)), e.stopPropagation(), e.preventDefault();
2943
2942
  }
2944
2943
  /** @internal */
2945
2944
  _mouseMove(e) {
@@ -2948,7 +2947,7 @@ class Mt {
2948
2947
  }
2949
2948
  /** @internal */
2950
2949
  _mouseUp(e) {
2951
- this.moving && this._triggerEvent("stop", e), document.removeEventListener("mousemove", this._mouseMove, !0), document.removeEventListener("mouseup", this._mouseUp, !0), pe && (this.el.removeEventListener("touchmove", At), this.el.removeEventListener("touchend", Dt)), delete this.moving, delete this.mouseDownEvent, e.stopPropagation(), e.preventDefault();
2950
+ this.moving && this._triggerEvent("stop", e), document.removeEventListener("mousemove", this._mouseMove, !0), document.removeEventListener("mouseup", this._mouseUp, !0), de && (this.el.removeEventListener("touchmove", At), this.el.removeEventListener("touchend", Dt)), delete this.moving, delete this.mouseDownEvent, e.stopPropagation(), e.preventDefault();
2952
2951
  }
2953
2952
  /** @internal */
2954
2953
  _triggerEvent(e, t) {
@@ -3157,10 +3156,10 @@ class st extends gi {
3157
3156
  super.off(e);
3158
3157
  }
3159
3158
  enable() {
3160
- this.disabled !== !1 && (super.enable(), this.dragEl.addEventListener("mousedown", this._mouseDown), pe && (this.dragEl.addEventListener("touchstart", Ct), this.dragEl.addEventListener("pointerdown", Lt)), this.el.classList.remove("ui-draggable-disabled"));
3159
+ this.disabled !== !1 && (super.enable(), this.dragEl.addEventListener("mousedown", this._mouseDown), de && (this.dragEl.addEventListener("touchstart", Ct), this.dragEl.addEventListener("pointerdown", Lt)), this.el.classList.remove("ui-draggable-disabled"));
3161
3160
  }
3162
3161
  disable(e = !1) {
3163
- this.disabled !== !0 && (super.disable(), this.dragEl.removeEventListener("mousedown", this._mouseDown), pe && (this.dragEl.removeEventListener("touchstart", Ct), this.dragEl.removeEventListener("pointerdown", Lt)), e || this.el.classList.add("ui-draggable-disabled"));
3162
+ this.disabled !== !0 && (super.disable(), this.dragEl.removeEventListener("mousedown", this._mouseDown), de && (this.dragEl.removeEventListener("touchstart", Ct), this.dragEl.removeEventListener("pointerdown", Lt)), e || this.el.classList.add("ui-draggable-disabled"));
3164
3163
  }
3165
3164
  destroy() {
3166
3165
  this.dragTimeout && window.clearTimeout(this.dragTimeout), delete this.dragTimeout, this.mouseDownEvent && this._mouseUp(this.mouseDownEvent), this.disable(!0), delete this.el, delete this.helper, delete this.option, super.destroy();
@@ -3171,7 +3170,7 @@ class st extends gi {
3171
3170
  /** @internal call when mouse goes down before a dragstart happens */
3172
3171
  _mouseDown(e) {
3173
3172
  if (!x.mouseHandled)
3174
- return e.button !== 0 || e.target.closest(Tn) || this.option.cancel && e.target.closest(this.option.cancel) || (this.mouseDownEvent = e, delete this.dragging, delete x.dragElement, delete x.dropElement, document.addEventListener("mousemove", this._mouseMove, !0), document.addEventListener("mouseup", this._mouseUp, !0), pe && (this.dragEl.addEventListener("touchmove", At), this.dragEl.addEventListener("touchend", Dt)), e.preventDefault(), document.activeElement && document.activeElement.blur(), x.mouseHandled = !0), !0;
3173
+ return e.button !== 0 || e.target.closest(Tn) || this.option.cancel && e.target.closest(this.option.cancel) || (this.mouseDownEvent = e, delete this.dragging, delete x.dragElement, delete x.dropElement, document.addEventListener("mousemove", this._mouseMove, !0), document.addEventListener("mouseup", this._mouseUp, !0), de && (this.dragEl.addEventListener("touchmove", At), this.dragEl.addEventListener("touchend", Dt)), e.preventDefault(), document.activeElement && document.activeElement.blur(), x.mouseHandled = !0), !0;
3175
3174
  }
3176
3175
  /** @internal method to call actual drag event */
3177
3176
  _callDrag(e) {
@@ -3202,7 +3201,7 @@ class st extends gi {
3202
3201
  /** @internal call when the mouse gets released to drop the item at current location */
3203
3202
  _mouseUp(e) {
3204
3203
  var t;
3205
- if (document.removeEventListener("mousemove", this._mouseMove, !0), document.removeEventListener("mouseup", this._mouseUp, !0), pe && (this.dragEl.removeEventListener("touchmove", At, !0), this.dragEl.removeEventListener("touchend", Dt, !0)), this.dragging) {
3204
+ if (document.removeEventListener("mousemove", this._mouseMove, !0), document.removeEventListener("mouseup", this._mouseUp, !0), de && (this.dragEl.removeEventListener("touchmove", At, !0), this.dragEl.removeEventListener("touchend", Dt, !0)), this.dragging) {
3206
3205
  delete this.dragging, ((t = x.dropElement) == null ? void 0 : t.el) === this.el.parentElement && delete x.dropElement, this.helperContainment.style.position = this.parentOriginStylePosition || null, this.helper === this.el ? this._removeHelperStyle() : this.helper.remove();
3207
3206
  const i = f.initEvent(e, { target: this.el, type: "dragstop" });
3208
3207
  this.option.stop && this.option.stop(i), this.triggerEvent("dragstop", i), x.dropElement && x.dropElement.drop(e);
@@ -3300,10 +3299,10 @@ class Rn extends gi {
3300
3299
  super.off(e);
3301
3300
  }
3302
3301
  enable() {
3303
- this.disabled !== !1 && (super.enable(), this.el.classList.add("ui-droppable"), this.el.classList.remove("ui-droppable-disabled"), this.el.addEventListener("mouseenter", this._mouseEnter), this.el.addEventListener("mouseleave", this._mouseLeave), pe && (this.el.addEventListener("pointerenter", rs), this.el.addEventListener("pointerleave", ns)));
3302
+ this.disabled !== !1 && (super.enable(), this.el.classList.add("ui-droppable"), this.el.classList.remove("ui-droppable-disabled"), this.el.addEventListener("mouseenter", this._mouseEnter), this.el.addEventListener("mouseleave", this._mouseLeave), de && (this.el.addEventListener("pointerenter", rs), this.el.addEventListener("pointerleave", ns)));
3304
3303
  }
3305
3304
  disable(e = !1) {
3306
- this.disabled !== !0 && (super.disable(), this.el.classList.remove("ui-droppable"), e || this.el.classList.add("ui-droppable-disabled"), this.el.removeEventListener("mouseenter", this._mouseEnter), this.el.removeEventListener("mouseleave", this._mouseLeave), pe && (this.el.removeEventListener("pointerenter", rs), this.el.removeEventListener("pointerleave", ns)));
3305
+ this.disabled !== !0 && (super.disable(), this.el.classList.remove("ui-droppable"), e || this.el.classList.add("ui-droppable-disabled"), this.el.removeEventListener("mouseenter", this._mouseEnter), this.el.removeEventListener("mouseleave", this._mouseLeave), de && (this.el.removeEventListener("pointerenter", rs), this.el.removeEventListener("pointerleave", ns)));
3307
3306
  }
3308
3307
  destroy() {
3309
3308
  this.disable(!0), this.el.classList.remove("ui-droppable"), this.el.classList.remove("ui-droppable-disabled"), super.destroy();
@@ -3577,8 +3576,8 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
3577
3576
  e.getAttribute("gs-animate") && (s.animate = f.toBool(e.getAttribute("gs-animate"))), this.opts = f.defaults(t, s), t = null, this._initMargin(), this.opts.column !== 1 && !this.opts.disableOneColumnMode && this._widthOrContainer() <= this.opts.oneColumnSize && (this._prevColumn = this.getColumn(), this.opts.column = 1), this.opts.rtl === "auto" && (this.opts.rtl = e.style.direction === "rtl"), this.opts.rtl && this.el.classList.add("grid-stack-rtl");
3578
3577
  const r = (u = this.el.parentElement) == null ? void 0 : u.parentElement;
3579
3578
  let l = r != null && r.classList.contains(ae.itemClass) ? r.gridstackNode : void 0;
3580
- l && (l.subGrid = this, this.parentGridItem = l, this.el.classList.add("grid-stack-nested"), l.el.classList.add("grid-stack-sub-grid")), this._isAutoCellHeight = this.opts.cellHeight === "auto", this._isAutoCellHeight || this.opts.cellHeight === "initial" ? this.cellHeight(void 0, !1) : (typeof this.opts.cellHeight == "number" && this.opts.cellHeightUnit && this.opts.cellHeightUnit !== ae.cellHeightUnit && (this.opts.cellHeight = this.opts.cellHeight + this.opts.cellHeightUnit, delete this.opts.cellHeightUnit), this.cellHeight(this.opts.cellHeight, !1)), this.opts.alwaysShowResizeHandle === "mobile" && (this.opts.alwaysShowResizeHandle = pe), this._styleSheetClass = "gs-id-" + _e._idSeq++, this.el.classList.add(this._styleSheetClass), this._setStaticClass();
3581
- let n = this.opts.engineClass || R.engineClass || _e;
3579
+ l && (l.subGrid = this, this.parentGridItem = l, this.el.classList.add("grid-stack-nested"), l.el.classList.add("grid-stack-sub-grid")), this._isAutoCellHeight = this.opts.cellHeight === "auto", this._isAutoCellHeight || this.opts.cellHeight === "initial" ? this.cellHeight(void 0, !1) : (typeof this.opts.cellHeight == "number" && this.opts.cellHeightUnit && this.opts.cellHeightUnit !== ae.cellHeightUnit && (this.opts.cellHeight = this.opts.cellHeight + this.opts.cellHeightUnit, delete this.opts.cellHeightUnit), this.cellHeight(this.opts.cellHeight, !1)), this.opts.alwaysShowResizeHandle === "mobile" && (this.opts.alwaysShowResizeHandle = de), this._styleSheetClass = "gs-id-" + me._idSeq++, this.el.classList.add(this._styleSheetClass), this._setStaticClass();
3580
+ let n = this.opts.engineClass || R.engineClass || me;
3582
3581
  if (this.engine = new n({
3583
3582
  column: this.getColumn(),
3584
3583
  float: this.opts.float,
@@ -4506,8 +4505,8 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
4506
4505
  n.x = Math.round(C / r), n.y = Math.round(L / l);
4507
4506
  let A = this._extraDragRow;
4508
4507
  if (this.engine.collide(s, n)) {
4509
- let E = this.getRow(), U = Math.max(0, n.y + s.h - E);
4510
- this.opts.maxRow && E + U > this.opts.maxRow && (U = Math.max(0, this.opts.maxRow - E)), this._extraDragRow = U;
4508
+ let k = this.getRow(), U = Math.max(0, n.y + s.h - k);
4509
+ this.opts.maxRow && k + U > this.opts.maxRow && (U = Math.max(0, this.opts.maxRow - k)), this._extraDragRow = U;
4511
4510
  } else
4512
4511
  this._extraDragRow = 0;
4513
4512
  if (this._extraDragRow !== A && this._updateContainerHeight(), s.x === n.x && s.y === n.y)
@@ -4546,7 +4545,7 @@ Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the
4546
4545
  }
4547
4546
  R.resizeToContentParent = ".grid-stack-item-content";
4548
4547
  R.Utils = f;
4549
- R.Engine = _e;
4548
+ R.Engine = me;
4550
4549
  R.GDRev = "9.5.1";
4551
4550
  const Cn = { class: "tw-flex tw-flex-row tw-flex-wrap tw-gap-2" }, An = { class: "color-primary" }, Dn = { class: "color-secondary" }, Ln = {
4552
4551
  key: 1,
@@ -4560,10 +4559,10 @@ const Cn = { class: "tw-flex tw-flex-row tw-flex-wrap tw-gap-2" }, An = { class:
4560
4559
  order: {}
4561
4560
  },
4562
4561
  setup(o) {
4563
- const e = o, t = rt(), i = de(() => ({ ...t.Filters })), s = de(() => ({ ...t.displayFilters })), r = de(() => {
4562
+ const e = o, t = rt(), i = ye(() => ({ ...t.Filters })), s = ye(() => ({ ...t.displayFilters })), r = ye(() => {
4564
4563
  const h = i.value;
4565
4564
  return Object.keys(h).map((p) => ({ key: p, value: h[p] })).filter(({ value: p }) => !(p == null || typeof p == "string" && p.trim() === "" || Array.isArray(p) && p.length === 0));
4566
- }), l = de(() => {
4565
+ }), l = ye(() => {
4567
4566
  var p;
4568
4567
  const h = r.value.filter((c) => s.value.hasOwnProperty(c.key) && s.value[c.key]);
4569
4568
  if ((p = e.order) != null && p.length) {
@@ -4656,7 +4655,7 @@ const Cn = { class: "tw-flex tw-flex-row tw-flex-wrap tw-gap-2" }, An = { class:
4656
4655
  },
4657
4656
  setup(o) {
4658
4657
  const e = rt(), t = o, i = F(null);
4659
- fe(() => t.widgetName, (u) => {
4658
+ pe(() => t.widgetName, (u) => {
4660
4659
  i.value = u;
4661
4660
  }, { immediate: !0 });
4662
4661
  const s = F(!1), r = F(null);
@@ -4745,11 +4744,11 @@ const Cn = { class: "tw-flex tw-flex-row tw-flex-wrap tw-gap-2" }, An = { class:
4745
4744
  const t = e, i = o;
4746
4745
  let s = F(null);
4747
4746
  const r = F(!1);
4748
- fe(() => i.isLocked, (u) => {
4747
+ pe(() => i.isLocked, (u) => {
4749
4748
  r.value = u;
4750
4749
  }, { immediate: !0 });
4751
4750
  const l = F(null);
4752
- fe(() => i.hideWidgetsHeader, (u) => {
4751
+ pe(() => i.hideWidgetsHeader, (u) => {
4753
4752
  l.value = u;
4754
4753
  }, { immediate: !0 });
4755
4754
  function n() {
@@ -4837,54 +4836,57 @@ const Cn = { class: "tw-flex tw-flex-row tw-flex-wrap tw-gap-2" }, An = { class:
4837
4836
  options: {}
4838
4837
  },
4839
4838
  setup(o) {
4840
- const e = o, t = rt(), { DASHBOARD_ITEMS: i } = Jt(t), s = {
4841
- apiUrl: de(() => {
4842
- var _;
4843
- return (_ = t.Services) == null ? void 0 : _.ApiUrl;
4844
- }),
4845
- s3Url: de(() => {
4846
- var _;
4847
- return (_ = t.Services) == null ? void 0 : _.s3Url;
4848
- }),
4849
- services: de(() => t.Services),
4850
- filters: t.Filters,
4851
- setFilter: t.setFilter,
4852
- clearFilter: t.clearFilter,
4853
- resetFilters: t.resetFilters
4854
- };
4855
- qs("dashboard:globalVars", s);
4856
- let r = F("Edit Grid"), l = null;
4857
- const n = F(null);
4858
- let u = F(!0), a = 0;
4859
- const h = F([]), { ComponentRegistry: p } = Jt(t), c = Qt({});
4860
- js(() => {
4861
- var _;
4862
- m(), t.loadFromLocalStorage(), a = ((_ = i.value) == null ? void 0 : _.length) + 1;
4863
- }), Ys(() => {
4839
+ const e = o, t = rt(), { DASHBOARD_ITEMS: i } = Jt(t);
4840
+ let s = F("Edit Grid"), r = null;
4841
+ const l = F(null);
4842
+ let n = F(!0), u = 0;
4843
+ const a = F([]), { ComponentRegistry: h } = Jt(t), p = Qt({});
4844
+ qs(() => {
4845
+ var y;
4846
+ c(), m(), t.loadFromLocalStorage(), u = ((y = i.value) == null ? void 0 : y.length) + 1;
4847
+ }), js(() => {
4864
4848
  z(), C();
4865
- }), Xs(() => {
4849
+ }), Ys(() => {
4866
4850
  O(), t.unregisterGridProvider();
4867
4851
  });
4852
+ function c() {
4853
+ var y, _;
4854
+ t.DefaultLayout = (y = e.options) == null ? void 0 : y.defaultLayout, t.setOptionServices((_ = e.options) == null ? void 0 : _.services);
4855
+ }
4868
4856
  function m() {
4869
- var _, y;
4870
- t.DefaultLayout = (_ = e.options) == null ? void 0 : _.defaultLayout, t.setOptionServices((y = e.options) == null ? void 0 : y.services);
4857
+ const y = {
4858
+ apiUrl: ye(() => {
4859
+ var _;
4860
+ return (_ = t.Services) == null ? void 0 : _.ApiUrl;
4861
+ }),
4862
+ s3Url: ye(() => {
4863
+ var _;
4864
+ return (_ = t.Services) == null ? void 0 : _.s3Url;
4865
+ }),
4866
+ services: t.Services,
4867
+ filters: t.Filters,
4868
+ setFilter: t.setFilter,
4869
+ clearFilter: t.clearFilter,
4870
+ resetFilters: t.resetFilters
4871
+ };
4872
+ Xs("dashboard:globalVars", y);
4871
4873
  }
4872
4874
  async function b() {
4873
- if (t.resetGridLayout(), await Wi(), !!l) {
4874
- l.batchUpdate(), l.removeAll();
4875
- for (const _ of i.value) {
4876
- const y = document.getElementById(_.id);
4877
- if (!y) {
4878
- console.warn("makeWidget: element not found for id", _.id);
4875
+ if (t.resetGridLayout(), await Wi(), !!r) {
4876
+ r.batchUpdate(), r.removeAll();
4877
+ for (const y of i.value) {
4878
+ const _ = document.getElementById(y.id);
4879
+ if (!_) {
4880
+ console.warn("makeWidget: element not found for id", y.id);
4879
4881
  continue;
4880
4882
  }
4881
- y.classList.add("grid-stack-item"), _.w != null && y.setAttribute("gs-w", String(_.w)), _.h != null && y.setAttribute("gs-h", String(_.h)), _.x != null && y.setAttribute("gs-x", String(_.x)), _.y != null && y.setAttribute("gs-y", String(_.y)), _.x == null && _.y == null && _.autoPosition && y.setAttribute("gs-auto-position", "true"), !y.gridstackNode && l.makeWidget(y);
4883
+ _.classList.add("grid-stack-item"), y.w != null && _.setAttribute("gs-w", String(y.w)), y.h != null && _.setAttribute("gs-h", String(y.h)), y.x != null && _.setAttribute("gs-x", String(y.x)), y.y != null && _.setAttribute("gs-y", String(y.y)), y.x == null && y.y == null && y.autoPosition && _.setAttribute("gs-auto-position", "true"), !_.gridstackNode && r.makeWidget(_);
4882
4884
  }
4883
- l.commit();
4885
+ r.commit();
4884
4886
  }
4885
4887
  }
4886
4888
  function z() {
4887
- const _ = {
4889
+ const y = {
4888
4890
  float: !0,
4889
4891
  column: 12,
4890
4892
  cellHeight: "70px",
@@ -4895,92 +4897,92 @@ const Cn = { class: "tw-flex tw-flex-row tw-flex-wrap tw-gap-2" }, An = { class:
4895
4897
  handles: "e,se,s,sw,w,n"
4896
4898
  }
4897
4899
  };
4898
- l = R.init(_), t.registerGridProvider(() => l), l.setStatic(u.value);
4900
+ r = R.init(y), t.registerGridProvider(() => r), r.setStatic(n.value);
4899
4901
  }
4900
4902
  function O() {
4901
- l && (l.destroy(!1), l = null);
4903
+ r && (r.destroy(!1), r = null);
4902
4904
  }
4903
- fe(
4905
+ pe(
4904
4906
  () => {
4905
- var _;
4906
- return (_ = e.options) == null ? void 0 : _.availableWidgets;
4907
+ var y;
4908
+ return (y = e.options) == null ? void 0 : y.availableWidgets;
4907
4909
  },
4908
- (_) => {
4909
- p.value = {}, h.value = [], _ && _.forEach((y, T) => {
4910
- let k, q;
4911
- if (y && typeof y == "object" && "name" in y && "component" in y)
4912
- k = y.name, q = y.component;
4913
- else if (y && typeof y == "object" && "name" in y && "loader" in y)
4914
- k = y.name, q = Zs(async () => {
4915
- const P = await y.loader();
4910
+ (y) => {
4911
+ h.value = {}, a.value = [], y && y.forEach((_, T) => {
4912
+ let E, q;
4913
+ if (_ && typeof _ == "object" && "name" in _ && "component" in _)
4914
+ E = _.name, q = _.component;
4915
+ else if (_ && typeof _ == "object" && "name" in _ && "loader" in _)
4916
+ E = _.name, q = Zs(async () => {
4917
+ const P = await _.loader();
4916
4918
  return P.default ?? P;
4917
4919
  });
4918
- else if (y && (typeof y == "function" || typeof y == "object"))
4919
- q = y, k = y.name || `Widget${T + 1}`;
4920
- else if (typeof y == "function")
4920
+ else if (_ && (typeof _ == "function" || typeof _ == "object"))
4921
+ q = _, E = _.name || `Widget${T + 1}`;
4922
+ else if (typeof _ == "function")
4921
4923
  return;
4922
- !k || !q || p.value[k] || (p.value[k] = q, h.value.push(k));
4924
+ !E || !q || h.value[E] || (h.value[E] = q, a.value.push(E));
4923
4925
  });
4924
4926
  },
4925
4927
  { immediate: !0, deep: !0 }
4926
4928
  );
4927
4929
  function C() {
4928
- const _ = e.options.globalData;
4929
- if (_) {
4930
+ const y = e.options.globalData;
4931
+ if (y) {
4930
4932
  t.clearOptionsDataItems();
4931
- for (const y in _)
4932
- t.addOptionsDataItems(y, _[y]);
4933
+ for (const _ in y)
4934
+ t.addOptionsDataItems(_, y[_]);
4933
4935
  }
4934
4936
  }
4935
- fe(() => u.value, (_) => {
4936
- l.setStatic(_), r.value = _ ? "Edit Grid" : "Save Grid";
4937
+ pe(() => n.value, (y) => {
4938
+ r.setStatic(y), s.value = y ? "Edit Grid" : "Save Grid";
4937
4939
  });
4938
- function L(_) {
4939
- if (!_)
4940
+ function L(y) {
4941
+ if (!y)
4940
4942
  return;
4941
- const y = `${_}-${a}`, T = {
4942
- id: y,
4943
+ const _ = `${y}-${u}`, T = {
4944
+ id: _,
4943
4945
  w: 2,
4944
4946
  h: 6,
4945
4947
  autoPosition: !0,
4946
- component: p.value[_],
4947
- componentKey: _,
4948
- componentName: _,
4948
+ component: h.value[y],
4949
+ componentKey: y,
4950
+ componentName: y,
4949
4951
  Props: {}
4950
4952
  };
4951
- a++, i.value.push(T), Wi(() => {
4952
- l == null || l.makeWidget(`#${y}`);
4953
+ u++, i.value.push(T), Wi(() => {
4954
+ r == null || r.makeWidget(`#${_}`);
4953
4955
  });
4954
4956
  }
4955
- function A(_) {
4956
- var y = i.value.findIndex((k) => k.id == _);
4957
- i.value.splice(y, 1);
4958
- const T = `#${_}`;
4959
- l.removeWidget(T, !1);
4957
+ function A(y) {
4958
+ var _ = i.value.findIndex((E) => E.id == y);
4959
+ i.value.splice(_, 1);
4960
+ const T = `#${y}`;
4961
+ r.removeWidget(T, !1);
4960
4962
  }
4961
- function E({ id: _, isLocked: y }) {
4962
- const T = c[_];
4963
- T && l && l.update(T, {
4964
- locked: !y,
4965
- noMove: !y,
4966
- noResize: !y
4967
- }), t.toggleWidgetLock(_);
4963
+ function k({ id: y, isLocked: _ }) {
4964
+ const T = p[y];
4965
+ T && r && r.update(T, {
4966
+ locked: !_,
4967
+ noMove: !_,
4968
+ noResize: !_
4969
+ }), t.toggleWidgetLock(y);
4968
4970
  }
4969
4971
  function U() {
4970
- u.value = !u.value, u.value;
4972
+ n.value = !n.value, n.value;
4971
4973
  }
4972
- return (_, y) => {
4973
- const T = ie("el-button"), k = ie("el-option"), q = ie("el-select"), P = ie("el-col");
4974
+ return (y, _) => {
4975
+ const T = ie("el-button"), E = ie("el-option"), q = ie("el-select"), P = ie("el-col");
4974
4976
  return S(), B("div", qn, [
4975
- _.hideHeader ? (S(), B("div", Xn, [
4976
- y[3] || (y[3] = Ae("x ", -1)),
4977
+ y.hideHeader ? (S(), B("div", Xn, [
4978
+ _[3] || (_[3] = Ae("x ", -1)),
4977
4979
  N("span", Zn, [
4978
4980
  Y(T, {
4979
4981
  class: "edit-button",
4980
- onClick: y[1] || (y[1] = (M) => U())
4982
+ onClick: _[1] || (_[1] = (M) => U())
4981
4983
  }, {
4982
4984
  default: V(() => [
4983
- Ae(Re(he(r)), 1)
4985
+ Ae(Re(he(s)), 1)
4984
4986
  ]),
4985
4987
  _: 1
4986
4988
  })
@@ -4989,22 +4991,22 @@ const Cn = { class: "tw-flex tw-flex-row tw-flex-wrap tw-gap-2" }, An = { class:
4989
4991
  N("span", Yn, [
4990
4992
  Y(T, {
4991
4993
  class: "edit-button",
4992
- onClick: y[0] || (y[0] = (M) => U())
4994
+ onClick: _[0] || (_[0] = (M) => U())
4993
4995
  }, {
4994
4996
  default: V(() => [
4995
- Ae(Re(he(r)), 1)
4997
+ Ae(Re(he(s)), 1)
4996
4998
  ]),
4997
4999
  _: 1
4998
5000
  })
4999
5001
  ]),
5000
5002
  Y(Mn)
5001
5003
  ])),
5002
- he(u) ? kt("", !0) : (S(), le(P, { key: 2 }, {
5004
+ he(n) ? kt("", !0) : (S(), le(P, { key: 2 }, {
5003
5005
  default: V(() => [
5004
5006
  N("div", Kn, [
5005
5007
  Y(q, { placeholder: "Add New Widget" }, {
5006
5008
  default: V(() => [
5007
- (S(!0), B(Le, null, tt(h.value, (M) => (S(), le(k, {
5009
+ (S(!0), B(Le, null, tt(a.value, (M) => (S(), le(E, {
5008
5010
  key: M,
5009
5011
  label: M,
5010
5012
  value: M,
@@ -5015,9 +5017,9 @@ const Cn = { class: "tw-flex tw-flex-row tw-flex-wrap tw-gap-2" }, An = { class:
5015
5017
  }),
5016
5018
  N("div", Qn, [
5017
5019
  Y(T, {
5018
- onClick: y[2] || (y[2] = (M) => b())
5020
+ onClick: _[2] || (_[2] = (M) => b())
5019
5021
  }, {
5020
- default: V(() => [...y[4] || (y[4] = [
5022
+ default: V(() => [..._[4] || (_[4] = [
5021
5023
  Ae("Reset Grid Layout", -1)
5022
5024
  ])]),
5023
5025
  _: 1
@@ -5029,7 +5031,7 @@ const Cn = { class: "tw-flex tw-flex-row tw-flex-wrap tw-gap-2" }, An = { class:
5029
5031
  })),
5030
5032
  N("div", {
5031
5033
  ref_key: "root",
5032
- ref: n,
5034
+ ref: l,
5033
5035
  class: "grid-stack tw-h-screen"
5034
5036
  }, [
5035
5037
  (S(!0), B(Le, null, tt(he(i), (M) => {
@@ -5037,7 +5039,7 @@ const Cn = { class: "tw-flex tw-flex-row tw-flex-wrap tw-gap-2" }, An = { class:
5037
5039
  return S(), B("div", {
5038
5040
  class: "grid-stack-item",
5039
5041
  ref_for: !0,
5040
- ref: (at) => c[M.id] = at,
5042
+ ref: (at) => p[M.id] = at,
5041
5043
  "gs-x": M.x,
5042
5044
  "gs-y": M.y,
5043
5045
  "gs-w": M.w,
@@ -5053,8 +5055,8 @@ const Cn = { class: "tw-flex tw-flex-row tw-flex-wrap tw-gap-2" }, An = { class:
5053
5055
  Y(Vn, {
5054
5056
  widgetID: M.id,
5055
5057
  onRemoveWidget: (at) => A(M.id),
5056
- onToggleLock: E,
5057
- "static-mode": he(u),
5058
+ onToggleLock: k,
5059
+ "static-mode": he(n),
5058
5060
  componentTag: M.component,
5059
5061
  componentProperties: M.Props,
5060
5062
  componentName: M.componentName,
@@ -5067,7 +5069,7 @@ const Cn = { class: "tw-flex tw-flex-row tw-flex-wrap tw-gap-2" }, An = { class:
5067
5069
  ]);
5068
5070
  };
5069
5071
  }
5070
- }), lo = /* @__PURE__ */ Ne(eo, [["__scopeId", "data-v-4ac6b9b5"]]);
5072
+ }), lo = /* @__PURE__ */ Ne(eo, [["__scopeId", "data-v-240ef3ec"]]);
5071
5073
  export {
5072
5074
  oo as MarkdownWidget,
5073
5075
  lo as PennsieveDashboard,