@orchidui/dashboard 1.8.1-6 → 1.8.1-60

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,15 +1,15 @@
1
1
  var pt = Object.defineProperty;
2
2
  var gt = (n, V, r) => V in n ? pt(n, V, { enumerable: !0, configurable: !0, writable: !0, value: r }) : n[V] = r;
3
3
  var We = (n, V, r) => gt(n, typeof V != "symbol" ? V + "" : V, r);
4
- import { ref as v, computed as ke, openBlock as m, createBlock as X, unref as w, normalizeClass as A, withCtx as W, createVNode as T, createCommentVNode as D, createSlots as vt, renderSlot as ze, createElementBlock as E, normalizeStyle as te, onMounted as Je, createElementVNode as h, Fragment as ge, renderList as Ke, toDisplayString as Fe, createTextVNode as ve, watch as we, withKeys as ot, inject as Re, reactive as _e, provide as Be, nextTick as mt, withDirectives as ft, vShow as ht, defineComponent as bt, defineAsyncComponent as it } from "vue";
4
+ import { ref as v, computed as $e, openBlock as m, createBlock as X, unref as w, normalizeClass as Q, withCtx as W, createVNode as T, createCommentVNode as D, createSlots as vt, renderSlot as ze, createElementBlock as E, normalizeStyle as te, onMounted as Je, watch as fe, createElementVNode as h, Fragment as ge, renderList as Ke, toDisplayString as Fe, createTextVNode as ve, withKeys as ot, inject as Re, reactive as _e, provide as Be, nextTick as mt, withDirectives as ft, vShow as ht, defineComponent as bt, defineAsyncComponent as it } from "vue";
5
5
  import { Q as Y, a as yt } from "./QuillEditor-BHWfmp5D.js";
6
- import { BaseInput as st, Dropdown as rt, Input as $e, Icon as Q, Modal as xt, Select as Ze, Slider as Qe } from "@orchidui/core";
7
- import { hslToRgb as et, hsl2Hex as tt, rgb2Hex as lt, rgbaToHex8 as kt, hexToRgb as je, rgbToHue as Ae, rgbToHsl as at, hex8ToRgba as $t, parseRgba as wt, parseRgb as St } from "./Dashboard/ColorPicker/components/converters.js";
6
+ import { BaseInput as st, Dropdown as rt, Input as we, Icon as A, Modal as xt, Select as Ze, Slider as Ae } from "@orchidui/core";
7
+ import { hslToRgb as et, hsl2Hex as tt, rgb2Hex as lt, rgbaToHex8 as kt, hexToRgb as je, rgbToHue as Qe, rgbToHsl as at, hex8ToRgba as $t, parseRgba as wt, parseRgb as St } from "./Dashboard/ColorPicker/components/converters.js";
8
8
  import { PieChart as Ct } from "./Dashboard/Charts/PieChart/OcPieChart.js";
9
9
  import { LineChart as Ol } from "./Dashboard/Charts/LineChart/OcLineChart.js";
10
- import { BarChart as Ql } from "./Dashboard/Charts/BarChart/OcBarChart.js";
10
+ import { BarChart as Al } from "./Dashboard/Charts/BarChart/OcBarChart.js";
11
11
  import { BarRaceChart as Nl } from "./Dashboard/Charts/BarRaceChart/OcBarRaceChart.js";
12
- import { _ as Xl } from "./OcCard-w0EuBfr4.js";
12
+ import { _ as Xl } from "./OcCard-BpqC7suH.js";
13
13
  const It = { key: 1 }, Vt = {
14
14
  __name: "OcColorPicker",
15
15
  props: {
@@ -25,13 +25,17 @@ const It = { key: 1 }, Vt = {
25
25
  hideInputColor: Boolean,
26
26
  presetColors: {
27
27
  type: Array
28
+ },
29
+ placement: {
30
+ type: String,
31
+ default: "auto"
28
32
  }
29
33
  },
30
34
  emits: ["update:model-value"],
31
35
  setup(n, { emit: V }) {
32
36
  const r = n, b = V, u = v(!1), f = v(r.modelValue), C = (M) => {
33
37
  M && (f.value = M, b("update:model-value", M));
34
- }, c = ke(() => r.variant === "gradient" ? {
38
+ }, p = $e(() => r.variant === "gradient" ? {
35
39
  class: "w-[20px] h-[20px] hide-svg-icon",
36
40
  style: {
37
41
  background: f.value
@@ -61,7 +65,7 @@ const It = { key: 1 }, Vt = {
61
65
  f.value = M, b("update:model-value", M), u.value = !1;
62
66
  };
63
67
  return (M, F) => (m(), X(w(st), {
64
- class: A(n.hideInputColor ? "w-[40px]" : ""),
68
+ class: Q(n.hideInputColor ? "w-[40px]" : ""),
65
69
  onClick: F[1] || (F[1] = () => {
66
70
  var U;
67
71
  return (U = a.value) == null ? void 0 : U.toggleDropdown();
@@ -77,7 +81,10 @@ const It = { key: 1 }, Vt = {
77
81
  L
78
82
  ],
79
83
  "max-menu-height": 800,
80
- placement: "auto"
84
+ placement: n.placement,
85
+ "popper-options": {
86
+ strategy: "fixed"
87
+ }
81
88
  }, {
82
89
  menu: W(() => [
83
90
  B.value ? D("", !0) : (m(), X(w(xl), {
@@ -95,17 +102,17 @@ const It = { key: 1 }, Vt = {
95
102
  default: W(() => [
96
103
  n.hideInputColor ? (m(), E("div", It, [
97
104
  ze(M.$slots, "picker-icon", {}, () => [
98
- T(w(Q), {
105
+ T(w(A), {
99
106
  class: "cursor-pointer",
100
107
  style: te(`color: ${f.value}`),
101
108
  name: "drop"
102
109
  }, null, 8, ["style"])
103
110
  ])
104
- ])) : (m(), X(w($e), {
111
+ ])) : (m(), X(w(we), {
105
112
  key: 0,
106
113
  "model-value": f.value,
107
114
  icon: "drop",
108
- "icon-props": c.value,
115
+ "icon-props": p.value,
109
116
  placeholder: "#FFFFFF",
110
117
  "onUpdate:modelValue": C
111
118
  }, vt({ _: 2 }, [
@@ -119,12 +126,12 @@ const It = { key: 1 }, Vt = {
119
126
  ]), 1032, ["model-value", "icon-props"]))
120
127
  ]),
121
128
  _: 3
122
- }, 8, ["modelValue"])
129
+ }, 8, ["modelValue", "placement"])
123
130
  ]),
124
131
  _: 3
125
132
  }, 8, ["class"]));
126
133
  }
127
- }, Lt = ["id"], Tt = { class: "flex items-center gap-x-3 px-5" }, Bt = { class: "flex items-center gap-x-5 cursor-pointer" }, Rt = { class: "flex flex-col py-2 overflow-hidden" }, Et = ["onClick"], Mt = { class: "flex gap-x-3 items-center px-5" }, Ut = { class: "flex items-center gap-x-3 px-5" }, Dt = { class: "flex gap-x-3 items-center px-5" }, Ht = { class: "flex gap-x-3 items-center px-5" }, Ot = { class: "flex items-center" }, At = { class: "grid cursor-pointer px-5" }, Qt = {
134
+ }, Lt = ["id"], Tt = { class: "flex items-center gap-x-3 px-5" }, Bt = { class: "flex items-center gap-x-5 cursor-pointer" }, Rt = { class: "flex flex-col py-2 overflow-hidden" }, Et = ["onClick"], Mt = { class: "flex gap-x-3 items-center px-5" }, Ut = { class: "flex items-center gap-x-3 px-5" }, Dt = { class: "flex gap-x-3 items-center px-5" }, Ht = { class: "flex gap-x-3 items-center px-5" }, Ot = { class: "flex items-center" }, Qt = { class: "grid cursor-pointer px-5" }, At = {
128
135
  key: 5,
129
136
  class: "flex gap-x-3 items-center px-5"
130
137
  }, Ft = { class: "flex" }, Nt = { class: "mt-1 mx-2 cursor-pointer" }, Rl = {
@@ -193,10 +200,10 @@ const It = { key: 1 }, Vt = {
193
200
  "alignment"
194
201
  ],
195
202
  "text-only": ["changes", "font-size", "font-style", "link", "quote", "list", "alignment"]
196
- }, f = ke(() => u[r.variant]), C = Y.import("attributors/style/size");
197
- C.whitelist = r.fontSizes.map((p) => p.value), Y.register(C, !0);
198
- const c = Y.import("attributors/style/align");
199
- Y.register(c, !0);
203
+ }, f = $e(() => u[r.variant]), C = Y.import("attributors/style/size");
204
+ C.whitelist = r.fontSizes.map((c) => c.value), Y.register(C, !0);
205
+ const p = Y.import("attributors/style/align");
206
+ Y.register(p, !0);
200
207
  const a = Y.import("attributors/style/background");
201
208
  Y.register(a, !0);
202
209
  const H = Y.import("attributors/style/color");
@@ -211,112 +218,114 @@ const It = { key: 1 }, Vt = {
211
218
  We(B, "blotName", "divider"), We(B, "tagName", "hr"), Y.register(B);
212
219
  const j = v(
213
220
  Math.random().toString(36).replace(/[^a-zA-Z]+/g, "")
214
- ), M = v(!1), F = v(!1), U = v(!1), le = v(!1), J = v(!1), z = v(!1), R = v(!1), N = v(""), ae = v(""), ee = v(""), x = v(), Se = v(!1), ue = v(r.image), ie = (p) => {
215
- M.value = x.value.getQuill().history.stack.undo.length > 0, F.value = x.value.getQuill().history.stack.redo.length > 0, U.value = x.value.getQuill().getFormat().bold, le.value = x.value.getQuill().getFormat().italic, J.value = x.value.getQuill().getFormat().underline, R.value = x.value.getQuill().getFormat().blockquote, ae.value = x.value.getQuill().getFormat().list, ee.value = x.value.getQuill().getFormat().align;
221
+ ), M = v(!1), F = v(!1), U = v(!1), le = v(!1), J = v(!1), z = v(!1), R = v(!1), N = v(""), ae = v(""), ee = v(""), y = v(), Se = v(!1), ue = v(r.image), ie = (c) => {
222
+ console.log(c, 123), M.value = y.value.getQuill().history.stack.undo.length > 0, F.value = y.value.getQuill().history.stack.redo.length > 0, U.value = y.value.getQuill().getFormat().bold, le.value = y.value.getQuill().getFormat().italic, J.value = y.value.getQuill().getFormat().underline, R.value = y.value.getQuill().getFormat().blockquote, ae.value = y.value.getQuill().getFormat().list, ee.value = y.value.getQuill().getFormat().align;
216
223
  let o = document.createElement("div");
217
- o.innerHTML = p, Se.value && (o.innerText ? b("update:modelValue", p || "") : b("update:modelValue", ""), o.remove());
224
+ o.innerHTML = c, Se.value && (o.innerText ? b("update:modelValue", c || "") : b("update:modelValue", ""), o.remove());
218
225
  }, Ne = () => {
219
- if (x.value.getQuill().getSelection(!0)) {
220
- const o = x.value.getQuill().getSelection(!0);
221
- x.value.getQuill().insertText(o.index, `
222
- `, Y.sources.USER), x.value.getQuill().insertEmbed(o.index + 1, "divider", !0, Y.sources.USER), x.value.getQuill().setSelection(o.index + 2, Y.sources.SILENT);
226
+ if (y.value.getQuill().getSelection(!0)) {
227
+ const o = y.value.getQuill().getSelection(!0);
228
+ y.value.getQuill().insertText(o.index, `
229
+ `, Y.sources.USER), y.value.getQuill().insertEmbed(o.index + 1, "divider", !0, Y.sources.USER), y.value.getQuill().setSelection(o.index + 2, Y.sources.SILENT);
223
230
  }
224
231
  }, Ee = () => {
225
- x.value.getQuill().history.undo(), ie(r.modelValue);
232
+ y.value.getQuill().history.undo(), ie(r.modelValue);
226
233
  }, Me = () => {
227
- x.value.getQuill().history.redo(), ie(r.modelValue);
234
+ y.value.getQuill().history.redo(), ie(r.modelValue);
228
235
  }, Ce = () => {
229
- var p;
230
- x.value.getQuill().format("bold", !U.value), (p = x.value.getQuill().getSelection()) != null && p.length || (U.value = !U.value);
236
+ var c;
237
+ y.value.getQuill().format("bold", !U.value), (c = y.value.getQuill().getSelection()) != null && c.length || (U.value = !U.value);
231
238
  }, ne = () => {
232
- var p;
233
- x.value.getQuill().format("italic", !le.value), (p = x.value.getQuill().getSelection()) != null && p.length || (le.value = !le.value);
239
+ var c;
240
+ y.value.getQuill().format("italic", !le.value), (c = y.value.getQuill().getSelection()) != null && c.length || (le.value = !le.value);
234
241
  }, Ie = () => {
235
- var p;
236
- x.value.getQuill().format("underline", !J.value), (p = x.value.getQuill().getSelection()) != null && p.length || (J.value = !J.value);
237
- }, Ue = (p) => {
238
- x.value.getQuill().format("size", p), N.value = p, z.value = !1;
242
+ var c;
243
+ y.value.getQuill().format("underline", !J.value), (c = y.value.getQuill().getSelection()) != null && c.length || (J.value = !J.value);
244
+ }, Ue = (c) => {
245
+ y.value.getQuill().format("size", c), N.value = c, z.value = !1;
239
246
  }, me = () => {
240
- const p = x.value.getQuill().getSelection();
241
- p && p.length > 0 && x.value.getQuill().theme.tooltip.edit();
247
+ const c = y.value.getQuill().getSelection();
248
+ c && c.length > 0 && y.value.getQuill().theme.tooltip.edit();
242
249
  }, Pe = () => {
243
- x.value.getQuill().format("blockquote", !R.value);
244
- }, oe = (p) => {
245
- const o = x.value.getQuill().getSelection();
246
- o && (x.value.getQuill().clipboard.dangerouslyPasteHTML(o.index, `<img src="${p}" />`), ue.value = p, b("update:image", ue.value));
250
+ y.value.getQuill().format("blockquote", !R.value);
251
+ }, oe = (c) => {
252
+ const o = y.value.getQuill().getSelection();
253
+ o && (y.value.getQuill().clipboard.dangerouslyPasteHTML(o.index, `<img src="${c}" />`), ue.value = c, b("update:image", ue.value));
247
254
  }, De = () => {
248
- x.value.getQuill().getSelection() || x.value.getQuill().setSelection(x.value.getQuill().getLength() - 1);
249
- const p = document.createElement("input");
250
- p.type = "file", p.accept = "jpg,.jpeg,.png,.webp,.gif", p.onchange = () => {
251
- const o = p.files[0], y = new FileReader();
252
- y.onload = () => oe(y.result), y.readAsDataURL(o);
253
- }, p.click();
254
- }, He = (p) => /^data:image\/(png|jpg|jpeg|gif);base64,/.test(p), P = (p) => {
255
+ y.value.getQuill().getSelection() || y.value.getQuill().setSelection(y.value.getQuill().getLength() - 1);
256
+ const c = document.createElement("input");
257
+ c.type = "file", c.accept = "jpg,.jpeg,.png,.webp,.gif", c.onchange = () => {
258
+ const o = c.files[0], x = new FileReader();
259
+ x.onload = () => oe(x.result), x.readAsDataURL(o);
260
+ }, c.click();
261
+ }, He = (c) => /^data:image\/(png|jpg|jpeg|gif);base64,/.test(c), P = (c) => {
255
262
  setTimeout(() => {
256
- var y;
257
- if (p) {
258
- const G = x.value.getHTML(), se = document.createElement("div");
263
+ var x;
264
+ if (c) {
265
+ const G = y.value.getHTML(), se = document.createElement("div");
259
266
  se.innerHTML = G;
260
- let ye = se.getElementsByTagName("img");
261
- if (ye && ye.length > 0)
262
- for (let pe = 0; pe < ye.length; pe++) {
263
- const xe = (y = ye[pe]) == null ? void 0 : y.getAttribute("src");
264
- He(xe) && b("update:image", xe);
267
+ let xe = se.getElementsByTagName("img");
268
+ if (xe && xe.length > 0)
269
+ for (let pe = 0; pe < xe.length; pe++) {
270
+ const ke = (x = xe[pe]) == null ? void 0 : x.getAttribute("src");
271
+ He(ke) && b("update:image", ke);
265
272
  }
266
273
  }
267
274
  }, 100);
268
- const { items: o } = p.clipboardData;
269
- o.length && o[0].getAsString((y) => {
270
- He(y) && (x.value.getQuill().getSelection() || x.value.getQuill().setSelection(x.value.getQuill().getLength() - 1));
275
+ const { items: o } = c.clipboardData;
276
+ o.length && o[0].getAsString((x) => {
277
+ He(x) && (y.value.getQuill().getSelection() || y.value.getQuill().setSelection(y.value.getQuill().getLength() - 1));
271
278
  });
272
279
  }, _ = () => {
273
- x.value.getQuill().theme.tooltip.edit("video");
274
- }, Ve = (p) => {
275
- x.value.getQuill().format("list", p), ae.value = p;
276
- }, fe = (p = void 0) => {
277
- x.value.getQuill().format("align", p), ee.value = p;
280
+ y.value.getQuill().theme.tooltip.edit("video");
281
+ }, Ve = (c) => {
282
+ y.value.getQuill().format("list", c), ae.value = c;
283
+ }, he = (c = void 0) => {
284
+ y.value.getQuill().format("align", c), ee.value = c;
278
285
  }, de = v(""), Xe = () => {
279
- x.value.getQuill().format("color", de.value);
286
+ y.value.getQuill().format("color", de.value);
280
287
  };
281
288
  Je(() => {
282
289
  Ue(r.initialFontSize || r.fontSizes[0].value), Se.value = !0;
283
290
  });
284
- const he = v(100), ce = v(!1), Le = (p) => {
285
- var y, G;
286
- he.value = p;
287
- const o = (y = window.getSelection()) == null ? void 0 : y.focusNode;
288
- o && o.nodeName !== "#text" && (x.value.getQuill().format("width", `${he.value}%`), (G = o == null ? void 0 : o.querySelector("img")) == null || G.setAttribute("style", "margin:auto;display:block;"));
289
- }, be = (p = "left") => {
290
- var y, G;
291
- const o = (y = window.getSelection()) == null ? void 0 : y.focusNode;
291
+ const be = v(100), ce = v(!1), Le = (c) => {
292
+ var x, G;
293
+ be.value = c;
294
+ const o = (x = window.getSelection()) == null ? void 0 : x.focusNode;
295
+ o && o.nodeName !== "#text" && (y.value.getQuill().format("width", `${be.value}%`), (G = o == null ? void 0 : o.querySelector("img")) == null || G.setAttribute("style", "margin:auto;display:block;"));
296
+ }, ye = (c = "left") => {
297
+ var x, G;
298
+ const o = (x = window.getSelection()) == null ? void 0 : x.focusNode;
292
299
  if (o && o.nodeName !== "#text") {
293
300
  let se = "float:left";
294
- p == "center" ? se = "" : p == "right" && (se = "float:right"), (G = o == null ? void 0 : o.querySelector("img")) == null || G.setAttribute("style", `margin:auto;display:block;${se}`);
301
+ c == "center" ? se = "" : c == "right" && (se = "float:right"), (G = o == null ? void 0 : o.querySelector("img")) == null || G.setAttribute("style", `margin:auto;display:block;${se}`);
295
302
  }
296
303
  }, Oe = () => {
297
304
  var o;
298
- const p = (o = window.getSelection()) == null ? void 0 : o.focusNode;
299
- ce.value = p.innerHTML && p.innerHTML.includes("<img");
300
- }, K = v(!1), q = v(3), Te = v(3), qe = ke(() => {
301
- let p = [];
305
+ const c = (o = window.getSelection()) == null ? void 0 : o.focusNode;
306
+ ce.value = c.innerHTML && c.innerHTML.includes("<img");
307
+ }, K = v(!1), q = v(3), Te = v(3), qe = $e(() => {
308
+ let c = [];
302
309
  for (let o = 1; o < 30; o++)
303
- p.push({
310
+ c.push({
304
311
  label: o.toString(),
305
312
  value: o.toString()
306
313
  });
307
- return p;
308
- }), Ge = ke(() => {
309
- let p = [];
314
+ return c;
315
+ }), Ge = $e(() => {
316
+ let c = [];
310
317
  for (let o = 1; o < 12; o++)
311
- p.push({
318
+ c.push({
312
319
  label: o.toString(),
313
320
  value: o.toString()
314
321
  });
315
- return p;
322
+ return c;
316
323
  }), Ye = () => {
317
- x.value.getQuill().getModule("better-table").insertTable(parseInt(q.value), parseInt(Te.value)), K.value = !1;
324
+ y.value.getQuill().getModule("better-table").insertTable(parseInt(q.value), parseInt(Te.value)), K.value = !1;
318
325
  };
319
- return (p, o) => (m(), X(w(st), {
326
+ return fe(() => r.modelValue, (c) => {
327
+ c || y.value.getQuill().setContents([], "silent");
328
+ }), (c, o) => (m(), X(w(st), {
320
329
  label: n.label,
321
330
  hint: n.hint,
322
331
  "error-message": n.errorMessage,
@@ -329,7 +338,7 @@ const It = { key: 1 }, Vt = {
329
338
  T(w(xt), {
330
339
  title: "Insert table",
331
340
  modelValue: K.value,
332
- "onUpdate:modelValue": o[2] || (o[2] = (y) => K.value = y),
341
+ "onUpdate:modelValue": o[2] || (o[2] = (x) => K.value = x),
333
342
  class: "!w-full !h-full",
334
343
  confirmButtonProps: {
335
344
  label: "Save",
@@ -339,14 +348,14 @@ const It = { key: 1 }, Vt = {
339
348
  default: W(() => [
340
349
  T(w(Ze), {
341
350
  modelValue: Te.value,
342
- "onUpdate:modelValue": o[0] || (o[0] = (y) => Te.value = y),
351
+ "onUpdate:modelValue": o[0] || (o[0] = (x) => Te.value = x),
343
352
  options: Ge.value,
344
353
  label: "Table cell",
345
354
  class: "mb-3"
346
355
  }, null, 8, ["modelValue", "options"]),
347
356
  T(w(Ze), {
348
357
  modelValue: q.value,
349
- "onUpdate:modelValue": o[1] || (o[1] = (y) => q.value = y),
358
+ "onUpdate:modelValue": o[1] || (o[1] = (x) => q.value = x),
350
359
  options: qe.value,
351
360
  label: "Table rows"
352
361
  }, null, 8, ["modelValue", "options"])
@@ -354,14 +363,14 @@ const It = { key: 1 }, Vt = {
354
363
  _: 1
355
364
  }, 8, ["modelValue", "confirmButtonProps"]),
356
365
  h("div", {
357
- class: A(["grid", { "has-error": n.errorMessage }]),
366
+ class: Q(["grid", { "has-error": n.errorMessage }]),
358
367
  onClick: Oe
359
368
  }, [
360
369
  j.value ? (m(), X(w(yt), {
361
370
  key: 0,
362
371
  id: `#${j.value}`,
363
372
  ref_key: "quill",
364
- ref: x,
373
+ ref: y,
365
374
  content: n.modelValue,
366
375
  options: {
367
376
  bounds: `#${j.value}`
@@ -380,15 +389,15 @@ const It = { key: 1 }, Vt = {
380
389
  }, [
381
390
  f.value.includes("changes") ? (m(), E(ge, { key: 0 }, [
382
391
  h("div", Tt, [
383
- T(w(Q), {
384
- class: A(M.value ? "text-oc-text cursor-pointer" : "text-oc-text-300"),
392
+ T(w(A), {
393
+ class: Q(M.value ? "text-oc-text cursor-pointer" : "text-oc-text-300"),
385
394
  width: "20",
386
395
  height: "20",
387
396
  name: "text-editor/undo",
388
397
  onClick: Ee
389
398
  }, null, 8, ["class"]),
390
- T(w(Q), {
391
- class: A(F.value ? "text-oc-text cursor-pointer" : "text-oc-text-300"),
399
+ T(w(A), {
400
+ class: Q(F.value ? "text-oc-text cursor-pointer" : "text-oc-text-300"),
392
401
  width: "20",
393
402
  height: "20",
394
403
  name: "text-editor/redo",
@@ -400,28 +409,28 @@ const It = { key: 1 }, Vt = {
400
409
  f.value.includes("font-size") ? (m(), E(ge, { key: 1 }, [
401
410
  T(w(rt), {
402
411
  modelValue: z.value,
403
- "onUpdate:modelValue": o[3] || (o[3] = (y) => z.value = y),
412
+ "onUpdate:modelValue": o[3] || (o[3] = (x) => z.value = x),
404
413
  class: "px-5"
405
414
  }, {
406
415
  menu: W(() => [
407
416
  h("div", Rt, [
408
- (m(!0), E(ge, null, Ke(n.fontSizes, (y) => (m(), E("div", {
409
- key: y.value,
410
- class: A(["min-w-[120px] cursor-pointer py-2 px-3 hover:bg-oc-gray-50", N.value === y.value ? "font-medium" : ""]),
411
- onClick: (G) => Ue(y.value)
412
- }, Fe(y.label), 11, Et))), 128))
417
+ (m(!0), E(ge, null, Ke(n.fontSizes, (x) => (m(), E("div", {
418
+ key: x.value,
419
+ class: Q(["min-w-[120px] cursor-pointer py-2 px-3 hover:bg-oc-gray-50", N.value === x.value ? "font-medium" : ""]),
420
+ onClick: (G) => Ue(x.value)
421
+ }, Fe(x.label), 11, Et))), 128))
413
422
  ])
414
423
  ]),
415
424
  default: W(() => {
416
- var y;
425
+ var x;
417
426
  return [
418
427
  h("div", Bt, [
419
- ve(Fe((y = n.fontSizes.find((G) => G.value === N.value)) == null ? void 0 : y.label) + " ", 1),
420
- T(w(Q), {
428
+ ve(Fe((x = n.fontSizes.find((G) => G.value === N.value)) == null ? void 0 : x.label) + " ", 1),
429
+ T(w(A), {
421
430
  width: "20",
422
431
  height: "20",
423
432
  name: "chevron-down",
424
- class: A(["transition-all", z.value ? "rotate-180" : ""])
433
+ class: Q(["transition-all", z.value ? "rotate-180" : ""])
425
434
  }, null, 8, ["class"])
426
435
  ])
427
436
  ];
@@ -432,22 +441,22 @@ const It = { key: 1 }, Vt = {
432
441
  ], 64)) : D("", !0),
433
442
  f.value.includes("font-style") ? (m(), E(ge, { key: 2 }, [
434
443
  h("div", Mt, [
435
- T(w(Q), {
436
- class: A(["cursor-pointer", U.value ? "text-oc-text" : "text-oc-text-300"]),
444
+ T(w(A), {
445
+ class: Q(["cursor-pointer", U.value ? "text-oc-text" : "text-oc-text-300"]),
437
446
  width: "20",
438
447
  height: "20",
439
448
  name: "text-editor/bold",
440
449
  onClick: Ce
441
450
  }, null, 8, ["class"]),
442
- T(w(Q), {
443
- class: A(["cursor-pointer", le.value ? "text-oc-text" : "text-oc-text-300"]),
451
+ T(w(A), {
452
+ class: Q(["cursor-pointer", le.value ? "text-oc-text" : "text-oc-text-300"]),
444
453
  width: "20",
445
454
  height: "20",
446
455
  name: "text-editor/italic",
447
456
  onClick: ne
448
457
  }, null, 8, ["class"]),
449
- T(w(Q), {
450
- class: A(["cursor-pointer", J.value ? "text-oc-text" : "text-oc-text-300"]),
458
+ T(w(A), {
459
+ class: Q(["cursor-pointer", J.value ? "text-oc-text" : "text-oc-text-300"]),
451
460
  width: "20",
452
461
  height: "20",
453
462
  name: "text-editor/underline",
@@ -457,7 +466,7 @@ const It = { key: 1 }, Vt = {
457
466
  o[18] || (o[18] = h("div", { class: "border-l border-oc-gray-200" }, null, -1))
458
467
  ], 64)) : D("", !0),
459
468
  h("div", Ut, [
460
- f.value.includes("link") ? (m(), X(w(Q), {
469
+ f.value.includes("link") ? (m(), X(w(A), {
461
470
  key: 0,
462
471
  class: "cursor-pointer",
463
472
  width: "20",
@@ -465,7 +474,7 @@ const It = { key: 1 }, Vt = {
465
474
  name: "text-editor/link",
466
475
  onClick: me
467
476
  })) : D("", !0),
468
- f.value.includes("image") ? (m(), X(w(Q), {
477
+ f.value.includes("image") ? (m(), X(w(A), {
469
478
  key: 1,
470
479
  class: "cursor-pointer",
471
480
  width: "20",
@@ -473,15 +482,15 @@ const It = { key: 1 }, Vt = {
473
482
  name: "text-editor/image",
474
483
  onClick: De
475
484
  })) : D("", !0),
476
- f.value.includes("quote") ? (m(), X(w(Q), {
485
+ f.value.includes("quote") ? (m(), X(w(A), {
477
486
  key: 2,
478
- class: A(["cursor-pointer", R.value ? "text-oc-text" : "text-oc-text-300"]),
487
+ class: Q(["cursor-pointer", R.value ? "text-oc-text" : "text-oc-text-300"]),
479
488
  width: "20",
480
489
  height: "20",
481
490
  name: "text-editor/quote",
482
491
  onClick: Pe
483
492
  }, null, 8, ["class"])) : D("", !0),
484
- f.value.includes("media") ? (m(), X(w(Q), {
493
+ f.value.includes("media") ? (m(), X(w(A), {
485
494
  key: 3,
486
495
  class: "cursor-pointer",
487
496
  width: "20",
@@ -489,63 +498,63 @@ const It = { key: 1 }, Vt = {
489
498
  name: "text-editor/media",
490
499
  onClick: _
491
500
  })) : D("", !0),
492
- T(w(Q), {
501
+ T(w(A), {
493
502
  class: "cursor-pointer",
494
503
  width: "20",
495
504
  height: "20",
496
505
  name: "table",
497
- onClick: o[4] || (o[4] = (y) => K.value = !K.value)
506
+ onClick: o[4] || (o[4] = (x) => K.value = !K.value)
498
507
  })
499
508
  ]),
500
509
  f.value.includes("list") ? (m(), E(ge, { key: 3 }, [
501
510
  o[19] || (o[19] = h("div", { class: "border-l border-oc-gray-200" }, null, -1)),
502
511
  h("div", Dt, [
503
- T(w(Q), {
504
- class: A(["cursor-pointer", ae.value === "bullet" ? "text-oc-text" : "text-oc-text-300"]),
512
+ T(w(A), {
513
+ class: Q(["cursor-pointer", ae.value === "bullet" ? "text-oc-text" : "text-oc-text-300"]),
505
514
  width: "20",
506
515
  height: "20",
507
516
  name: "text-editor/bullet",
508
- onClick: o[5] || (o[5] = (y) => Ve("bullet"))
517
+ onClick: o[5] || (o[5] = (x) => Ve("bullet"))
509
518
  }, null, 8, ["class"]),
510
- T(w(Q), {
511
- class: A(["cursor-pointer", ae.value === "ordered" ? "text-oc-text" : "text-oc-text-300"]),
519
+ T(w(A), {
520
+ class: Q(["cursor-pointer", ae.value === "ordered" ? "text-oc-text" : "text-oc-text-300"]),
512
521
  width: "20",
513
522
  height: "20",
514
523
  name: "text-editor/number",
515
- onClick: o[6] || (o[6] = (y) => Ve("ordered"))
524
+ onClick: o[6] || (o[6] = (x) => Ve("ordered"))
516
525
  }, null, 8, ["class"])
517
526
  ])
518
527
  ], 64)) : D("", !0),
519
528
  f.value.includes("alignment") ? (m(), E(ge, { key: 4 }, [
520
529
  o[20] || (o[20] = h("div", { class: "border-l border-oc-gray-200" }, null, -1)),
521
530
  h("div", Ht, [
522
- T(w(Q), {
523
- class: A(["cursor-pointer", ee.value ? "text-oc-text-300" : "text-oc-text"]),
531
+ T(w(A), {
532
+ class: Q(["cursor-pointer", ee.value ? "text-oc-text-300" : "text-oc-text"]),
524
533
  width: "20",
525
534
  height: "20",
526
535
  name: "text-editor/left",
527
- onClick: o[7] || (o[7] = (y) => fe())
536
+ onClick: o[7] || (o[7] = (x) => he())
528
537
  }, null, 8, ["class"]),
529
- T(w(Q), {
530
- class: A(["cursor-pointer", ee.value === "center" ? "text-oc-text" : "text-oc-text-300"]),
538
+ T(w(A), {
539
+ class: Q(["cursor-pointer", ee.value === "center" ? "text-oc-text" : "text-oc-text-300"]),
531
540
  width: "20",
532
541
  height: "20",
533
542
  name: "text-editor/center",
534
- onClick: o[8] || (o[8] = (y) => fe("center"))
543
+ onClick: o[8] || (o[8] = (x) => he("center"))
535
544
  }, null, 8, ["class"]),
536
- T(w(Q), {
537
- class: A(["cursor-pointer", ee.value === "right" ? "text-oc-text" : "text-oc-text-300"]),
545
+ T(w(A), {
546
+ class: Q(["cursor-pointer", ee.value === "right" ? "text-oc-text" : "text-oc-text-300"]),
538
547
  width: "20",
539
548
  height: "20",
540
549
  name: "text-editor/right",
541
- onClick: o[9] || (o[9] = (y) => fe("right"))
550
+ onClick: o[9] || (o[9] = (x) => he("right"))
542
551
  }, null, 8, ["class"]),
543
- T(w(Q), {
544
- class: A(["cursor-pointer", ee.value === "justify" ? "text-oc-text" : "text-oc-text-300"]),
552
+ T(w(A), {
553
+ class: Q(["cursor-pointer", ee.value === "justify" ? "text-oc-text" : "text-oc-text-300"]),
545
554
  width: "20",
546
555
  height: "20",
547
556
  name: "text-editor/justify",
548
- onClick: o[10] || (o[10] = (y) => fe("justify"))
557
+ onClick: o[10] || (o[10] = (x) => he("justify"))
549
558
  }, null, 8, ["class"])
550
559
  ])
551
560
  ], 64)) : D("", !0),
@@ -554,13 +563,13 @@ const It = { key: 1 }, Vt = {
554
563
  T(w(Vt), {
555
564
  modelValue: de.value,
556
565
  "onUpdate:modelValue": [
557
- o[11] || (o[11] = (y) => de.value = y),
566
+ o[11] || (o[11] = (x) => de.value = x),
558
567
  Xe
559
568
  ],
560
569
  "hide-input-color": ""
561
570
  }, {
562
571
  "picker-icon": W(() => [
563
- h("div", At, [
572
+ h("div", Qt, [
564
573
  h("div", {
565
574
  style: te(`color:${de.value}`)
566
575
  }, "A", 4),
@@ -574,36 +583,36 @@ const It = { key: 1 }, Vt = {
574
583
  }, 8, ["modelValue"])
575
584
  ]),
576
585
  o[23] || (o[23] = h("div", { class: "border-l border-oc-gray-200" }, null, -1)),
577
- ce.value ? (m(), E("div", Qt, [
578
- T(w(Qe), {
586
+ ce.value ? (m(), E("div", At, [
587
+ T(w(Ae), {
579
588
  label: "Image width",
580
589
  class: "w-[120px]",
581
- "model-value": he.value,
590
+ "model-value": be.value,
582
591
  "min-limit": 0,
583
592
  "max-limit": 100,
584
593
  "onUpdate:modelValue": Le
585
594
  }, null, 8, ["model-value"]),
586
595
  h("div", Ft, [
587
- T(w(Q), {
596
+ T(w(A), {
588
597
  class: "cursor-pointer",
589
598
  width: "20",
590
599
  height: "20",
591
600
  name: "text-editor/left",
592
- onClick: o[12] || (o[12] = (y) => be())
601
+ onClick: o[12] || (o[12] = (x) => ye())
593
602
  }),
594
- T(w(Q), {
603
+ T(w(A), {
595
604
  class: "cursor-pointer",
596
605
  width: "20",
597
606
  height: "20",
598
607
  name: "text-editor/center",
599
- onClick: o[13] || (o[13] = (y) => be("center"))
608
+ onClick: o[13] || (o[13] = (x) => ye("center"))
600
609
  }),
601
- T(w(Q), {
610
+ T(w(A), {
602
611
  class: "cursor-pointer",
603
612
  width: "20",
604
613
  height: "20",
605
614
  name: "text-editor/right",
606
- onClick: o[14] || (o[14] = (y) => be("right"))
615
+ onClick: o[14] || (o[14] = (x) => ye("right"))
607
616
  })
608
617
  ])
609
618
  ])) : D("", !0),
@@ -614,7 +623,7 @@ const It = { key: 1 }, Vt = {
614
623
  viewBox: "0 0 15 15",
615
624
  fill: "none",
616
625
  xmlns: "http://www.w3.org/2000/svg",
617
- onClick: o[15] || (o[15] = (y) => Ne())
626
+ onClick: o[15] || (o[15] = (x) => Ne())
618
627
  }, o[21] || (o[21] = [
619
628
  h("path", {
620
629
  "fill-rule": "evenodd",
@@ -644,16 +653,16 @@ const It = { key: 1 }, Vt = {
644
653
  "update:modelValue": []
645
654
  },
646
655
  setup(n, { emit: V }) {
647
- const r = n, b = V, u = v(""), f = (c) => {
648
- u.value = c, u.value = `#${c.replace(/#/g, "")}`;
656
+ const r = n, b = V, u = v(""), f = (p) => {
657
+ u.value = p, u.value = `#${p.replace(/#/g, "")}`;
649
658
  }, C = () => {
650
- let c = u.value;
651
- if (c === r.modelValue) return;
652
- if (!/^#[0-9a-fA-F]+$/.test(c)) {
659
+ let p = u.value;
660
+ if (p === r.modelValue) return;
661
+ if (!/^#[0-9a-fA-F]+$/.test(p)) {
653
662
  u.value = r.modelValue;
654
663
  return;
655
664
  }
656
- let a = c.replace(/#/g, "");
665
+ let a = p.replace(/#/g, "");
657
666
  switch (a.length) {
658
667
  case 0:
659
668
  a = r.modelValue.replace("#", "");
@@ -674,13 +683,13 @@ const It = { key: 1 }, Vt = {
674
683
  }
675
684
  u.value = `#${a.toUpperCase()}`, b("update:modelValue", u.value);
676
685
  };
677
- return we(
686
+ return fe(
678
687
  () => r.modelValue,
679
- (c, a) => {
680
- c !== a && (u.value = c);
688
+ (p, a) => {
689
+ p !== a && (u.value = p);
681
690
  },
682
691
  { immediate: !0 }
683
- ), (c, a) => (m(), X(w($e), {
692
+ ), (p, a) => (m(), X(w(we), {
684
693
  class: "w-[158px]",
685
694
  placeholder: "#FFFFFF",
686
695
  "model-value": u.value,
@@ -712,7 +721,7 @@ const It = { key: 1 }, Vt = {
712
721
  r: 0,
713
722
  g: 0,
714
723
  b: 0
715
- }), f = v(), C = v(), c = v(), a = (O, L) => {
724
+ }), f = v(), C = v(), p = v(), a = (O, L) => {
716
725
  var j, M, F;
717
726
  let B = 255;
718
727
  if (r.inputType == "HSL" && (B = 100, O == "r" && (B = 360)), !isNaN(parseInt(L))) {
@@ -724,7 +733,7 @@ const It = { key: 1 }, Vt = {
724
733
  U <= B && (u.value.g = U, r.inputType == "RGB" ? H("g") : Z()), (M = C.value) == null || M.focus();
725
734
  } else if (O == "b") {
726
735
  let U = parseInt(L);
727
- U <= B && (u.value.b = U, r.inputType == "RGB" ? H("b") : Z()), (F = c.value) == null || F.focus();
736
+ U <= B && (u.value.b = U, r.inputType == "RGB" ? H("b") : Z()), (F = p.value) == null || F.focus();
728
737
  }
729
738
  }
730
739
  }, H = (O) => {
@@ -743,13 +752,13 @@ const It = { key: 1 }, Vt = {
743
752
  l: parseInt(u.value.b)
744
753
  });
745
754
  };
746
- return r.inputType === "RGB" ? we(
755
+ return r.inputType === "RGB" ? fe(
747
756
  () => r.rgbValue,
748
757
  (O, L) => {
749
758
  O !== L && (u.value = O);
750
759
  },
751
760
  { immediate: !0, deep: !0 }
752
- ) : we(
761
+ ) : fe(
753
762
  () => r.hslValue,
754
763
  (O) => {
755
764
  u.value = {
@@ -760,23 +769,23 @@ const It = { key: 1 }, Vt = {
760
769
  },
761
770
  { immediate: !0, deep: !0 }
762
771
  ), (O, L) => (m(), E("div", Xt, [
763
- T(w($e), {
772
+ T(w(we), {
764
773
  ref_key: "rInputEl",
765
774
  ref: f,
766
775
  "model-value": u.value.r,
767
776
  placeholder: "100",
768
777
  "onUpdate:modelValue": L[0] || (L[0] = (B) => a("r", B))
769
778
  }, null, 8, ["model-value"]),
770
- T(w($e), {
779
+ T(w(we), {
771
780
  ref_key: "gInputEl",
772
781
  ref: C,
773
782
  "model-value": u.value.g,
774
783
  placeholder: "100",
775
784
  "onUpdate:modelValue": L[1] || (L[1] = (B) => a("g", B))
776
785
  }, null, 8, ["model-value"]),
777
- T(w($e), {
786
+ T(w(we), {
778
787
  ref_key: "bInputEl",
779
- ref: c,
788
+ ref: p,
780
789
  "model-value": u.value.b,
781
790
  placeholder: "100",
782
791
  "onUpdate:modelValue": L[2] || (L[2] = (B) => a("b", B))
@@ -794,19 +803,19 @@ const It = { key: 1 }, Vt = {
794
803
  "update:modelValue": []
795
804
  },
796
805
  setup(n, { emit: V }) {
797
- const r = n, b = V, u = v(""), f = (c) => {
798
- u.value = c;
806
+ const r = n, b = V, u = v(""), f = (p) => {
807
+ u.value = p;
799
808
  }, C = () => {
800
- let c = parseInt(u.value);
801
- c && c <= 100 ? b("update:modelValue", c) : u.value = r.modelValue;
809
+ let p = parseInt(u.value);
810
+ p && p <= 100 ? b("update:modelValue", p) : u.value = r.modelValue;
802
811
  };
803
- return we(
812
+ return fe(
804
813
  () => r.modelValue,
805
- (c, a) => {
806
- c !== a && (u.value = c);
814
+ (p, a) => {
815
+ p !== a && (u.value = p);
807
816
  },
808
817
  { immediate: !0 }
809
- ), (c, a) => (m(), X(w($e), {
818
+ ), (p, a) => (m(), X(w(we), {
810
819
  class: "w-[75px]",
811
820
  placeholder: "100",
812
821
  "model-value": u.value,
@@ -830,7 +839,7 @@ const It = { key: 1 }, Vt = {
830
839
  const b = v(n.modelValue), u = V, f = (C) => {
831
840
  b.value = C, u("update:model-value", C);
832
841
  };
833
- return (C, c) => (m(), X(w(Ze), {
842
+ return (C, p) => (m(), X(w(Ze), {
834
843
  class: "!w-[80px]",
835
844
  "model-value": b.value,
836
845
  options: [
@@ -884,16 +893,16 @@ const It = { key: 1 }, Vt = {
884
893
  setup(n, { emit: V }) {
885
894
  const r = Re("gradientBar"), b = v(), u = V, f = (L) => {
886
895
  L.preventDefault();
887
- }, C = v("left:0"), c = v(!1), a = (L) => {
896
+ }, C = v("left:0"), p = v(!1), a = (L) => {
888
897
  u("onMouseDown", L);
889
898
  }, H = () => {
890
899
  let L = b.value.querySelector(".select");
891
900
  C.value = L == null ? void 0 : L.getAttribute("style");
892
901
  }, Z = () => {
893
902
  var B;
894
- H(), (((B = b.value.querySelectorAll(".gradient-handle")) == null ? void 0 : B.length) ?? 2) > 2 ? c.value = !0 : c.value = !1;
903
+ H(), (((B = b.value.querySelectorAll(".gradient-handle")) == null ? void 0 : B.length) ?? 2) > 2 ? p.value = !0 : p.value = !1;
895
904
  }, O = (L) => {
896
- c.value = !1, u("onAddColor", L);
905
+ p.value = !1, u("onAddColor", L);
897
906
  };
898
907
  return (L, B) => (m(), E("div", {
899
908
  ref_key: "gradientSlider",
@@ -903,18 +912,18 @@ const It = { key: 1 }, Vt = {
903
912
  }, [
904
913
  h("button", {
905
914
  type: "button",
906
- class: A(["absolute top-[-18px] text-oc-accent-3 rounded-[4px] border-2 border-oc-gray-200 p-2 bg-oc-bg-light", c.value ? "" : "!hidden"]),
915
+ class: Q(["absolute top-[-18px] text-oc-accent-3 rounded-[4px] border-2 border-oc-gray-200 p-2 bg-oc-bg-light", p.value ? "" : "!hidden"]),
907
916
  style: te(C.value),
908
917
  onClick: B[0] || (B[0] = (j) => L.$emit("onDeleteColor"))
909
918
  }, [
910
- T(w(Q), {
919
+ T(w(A), {
911
920
  name: "bin",
912
921
  width: "14",
913
922
  height: "14"
914
923
  })
915
924
  ], 6),
916
925
  h("div", {
917
- class: A(["gradient-bar", {
926
+ class: Q(["gradient-bar", {
918
927
  "mt-[20px]": n.gradientType === "linear",
919
928
  "mt-[12px]": n.gradientType === "radial"
920
929
  }]),
@@ -974,9 +983,9 @@ const It = { key: 1 }, Vt = {
974
983
  Je(() => {
975
984
  r.value = !0, b.value = !0;
976
985
  });
977
- const u = V, f = (C, c) => {
986
+ const u = V, f = (C, p) => {
978
987
  let a = parseInt(C);
979
- switch (c) {
988
+ switch (p) {
980
989
  case "angle":
981
990
  C > 360 ? a = 360 : C < 0 && (a = 0), u("update:angle", a), u("onInput");
982
991
  break;
@@ -988,51 +997,51 @@ const It = { key: 1 }, Vt = {
988
997
  break;
989
998
  }
990
999
  };
991
- return (C, c) => (m(), E("div", el, [
992
- n.gradientType == "linear" && r.value ? (m(), X(w(Qe), {
1000
+ return (C, p) => (m(), E("div", el, [
1001
+ n.gradientType == "linear" && r.value ? (m(), X(w(Ae), {
993
1002
  key: 0,
994
1003
  label: "Angle",
995
1004
  "model-value": n.angle,
996
1005
  "min-limit": 0,
997
1006
  "max-limit": 360,
998
- "onUpdate:modelValue": c[0] || (c[0] = (a) => f(a, "angle"))
1007
+ "onUpdate:modelValue": p[0] || (p[0] = (a) => f(a, "angle"))
999
1008
  }, {
1000
- "min-limit-label": W(() => c[3] || (c[3] = [
1009
+ "min-limit-label": W(() => p[3] || (p[3] = [
1001
1010
  ve("0 ")
1002
1011
  ])),
1003
- "max-limit-label": W(() => c[4] || (c[4] = [
1012
+ "max-limit-label": W(() => p[4] || (p[4] = [
1004
1013
  ve("360"),
1005
1014
  h("span", null, "°", -1)
1006
1015
  ])),
1007
1016
  _: 1
1008
1017
  }, 8, ["model-value"])) : D("", !0),
1009
1018
  n.gradientType == "radial" && b.value ? (m(), E("div", tl, [
1010
- T(w(Qe), {
1019
+ T(w(Ae), {
1011
1020
  label: "Position X",
1012
1021
  "model-value": n.percentageX,
1013
1022
  "min-limit": 0,
1014
1023
  "max-limit": 100,
1015
- "onUpdate:modelValue": c[1] || (c[1] = (a) => f(a, "percentageX"))
1024
+ "onUpdate:modelValue": p[1] || (p[1] = (a) => f(a, "percentageX"))
1016
1025
  }, {
1017
- "min-limit-label": W(() => c[5] || (c[5] = [
1026
+ "min-limit-label": W(() => p[5] || (p[5] = [
1018
1027
  ve("0")
1019
1028
  ])),
1020
- "max-limit-label": W(() => c[6] || (c[6] = [
1029
+ "max-limit-label": W(() => p[6] || (p[6] = [
1021
1030
  ve("100%")
1022
1031
  ])),
1023
1032
  _: 1
1024
1033
  }, 8, ["model-value"]),
1025
- T(w(Qe), {
1034
+ T(w(Ae), {
1026
1035
  label: "Position Y",
1027
1036
  "model-value": n.percentageY,
1028
1037
  "min-limit": 0,
1029
1038
  "max-limit": 100,
1030
- "onUpdate:modelValue": c[2] || (c[2] = (a) => f(a, "percentageY"))
1039
+ "onUpdate:modelValue": p[2] || (p[2] = (a) => f(a, "percentageY"))
1031
1040
  }, {
1032
- "min-limit-label": W(() => c[7] || (c[7] = [
1041
+ "min-limit-label": W(() => p[7] || (p[7] = [
1033
1042
  ve("0")
1034
1043
  ])),
1035
- "max-limit-label": W(() => c[8] || (c[8] = [
1044
+ "max-limit-label": W(() => p[8] || (p[8] = [
1036
1045
  ve("100%")
1037
1046
  ])),
1038
1047
  _: 1
@@ -1051,7 +1060,7 @@ const It = { key: 1 }, Vt = {
1051
1060
  ref_key: "pickerWrap",
1052
1061
  ref: r,
1053
1062
  class: "cp-picker-wrap",
1054
- onMousedown: C[0] || (C[0] = (c) => f.$emit("onMouseDown", c)),
1063
+ onMousedown: C[0] || (C[0] = (p) => f.$emit("onMouseDown", p)),
1055
1064
  onDragstart: u
1056
1065
  }, [
1057
1066
  h("canvas", {
@@ -1097,7 +1106,7 @@ const It = { key: 1 }, Vt = {
1097
1106
  return (V, r) => (m(), E("div", nl, [
1098
1107
  h("button", {
1099
1108
  type: "button",
1100
- class: A(n.mode == "solid" ? "active" : ""),
1109
+ class: Q(n.mode == "solid" ? "active" : ""),
1101
1110
  style: { padding: "7px" },
1102
1111
  onClick: r[0] || (r[0] = (b) => V.$emit("onChangeMode", "solid"))
1103
1112
  }, [
@@ -1116,7 +1125,7 @@ const It = { key: 1 }, Vt = {
1116
1125
  ], 2),
1117
1126
  h("button", {
1118
1127
  type: "button",
1119
- class: A(n.gradientType == "linear" && n.mode != "solid" ? "active" : ""),
1128
+ class: Q(n.gradientType == "linear" && n.mode != "solid" ? "active" : ""),
1120
1129
  style: te(`${n.iconClasses.linear ? "" : "padding: 7px;"}`),
1121
1130
  onClick: r[1] || (r[1] = (b) => V.$emit("onChangeMode", "linear"))
1122
1131
  }, [
@@ -1135,7 +1144,7 @@ const It = { key: 1 }, Vt = {
1135
1144
  ], 6),
1136
1145
  h("button", {
1137
1146
  type: "button",
1138
- class: A(n.gradientType == "radial" && n.mode != "solid" ? "active" : ""),
1147
+ class: Q(n.gradientType == "radial" && n.mode != "solid" ? "active" : ""),
1139
1148
  style: te(`${n.iconClasses.radial ? "" : "padding: 6px;"}`),
1140
1149
  onClick: r[2] || (r[2] = (b) => V.$emit("onChangeMode", "radial"))
1141
1150
  }, [
@@ -1197,13 +1206,13 @@ const It = { key: 1 }, Vt = {
1197
1206
  },
1198
1207
  emits: ["update:modelValue", "last-used-pick"],
1199
1208
  setup(n, { emit: V }) {
1200
- const r = n, b = v(r.variant == "gradient" ? "gradient" : "solid"), u = v(null), f = V, C = v(r.modelValue), c = (t) => {
1209
+ const r = n, b = v(r.variant == "gradient" ? "gradient" : "solid"), u = v(null), f = V, C = v(r.modelValue), p = (t) => {
1201
1210
  C.value = t, F.value && f("update:modelValue", t);
1202
1211
  }, a = v([
1203
1212
  { id: 1, r: 68, g: 71, b: 119, a: 100, percent: 0, hue: 0, select: !0 },
1204
1213
  { id: 2, r: 0, g: 0, b: 255, a: 100, percent: 100, hue: 0, select: !1 }
1205
1214
  ]), H = v(r.lastUsedColors);
1206
- we(
1215
+ fe(
1207
1216
  () => r.lastUsedColors,
1208
1217
  () => {
1209
1218
  H.value = r.lastUsedColors;
@@ -1212,7 +1221,7 @@ const It = { key: 1 }, Vt = {
1212
1221
  deep: !0
1213
1222
  }
1214
1223
  );
1215
- const Z = ke(() => r.variant !== "gradient" ? H.value.filter((t) => !t.includes("linear") && !t.includes("radial")) : H.value), O = v(!1), L = v("linear"), B = _e({
1224
+ const Z = $e(() => r.variant !== "gradient" ? H.value.filter((t) => !t.includes("linear") && !t.includes("radial")) : H.value), O = v(!1), L = v("linear"), B = _e({
1216
1225
  angle: 90,
1217
1226
  percentageX: 50,
1218
1227
  percentageY: 50
@@ -1222,9 +1231,9 @@ const It = { key: 1 }, Vt = {
1222
1231
  l: 0
1223
1232
  });
1224
1233
  Be("gradientBar", le), Be("canvas", J), Be("pickerWrap", z), Be("pickerPointer", R), Be("opacitySlider", U);
1225
- let ae = 0, ee = 0, x = 0, Se = 0, ue = 0, ie = 0;
1234
+ let ae = 0, ee = 0, y = 0, Se = 0, ue = 0, ie = 0;
1226
1235
  const Ne = (t) => {
1227
- !z.value || !R.value || (ue = z.value.offsetHeight - R.value.offsetHeight, ie = z.value.offsetWidth - R.value.offsetWidth, x = t.clientX - t.target.getBoundingClientRect().left, Se = t.clientY - t.target.getBoundingClientRect().top, ae = x - R.value.offsetWidth / 2, ee = Se - R.value.offsetHeight / 2, R.value.style.left = `${ae}px`, R.value.style.top = `${ee}px`, Ce(!1), G(), window.addEventListener("mousemove", Ee), window.addEventListener("mouseup", Me));
1236
+ !z.value || !R.value || (ue = z.value.offsetHeight - R.value.offsetHeight, ie = z.value.offsetWidth - R.value.offsetWidth, y = t.clientX - t.target.getBoundingClientRect().left, Se = t.clientY - t.target.getBoundingClientRect().top, ae = y - R.value.offsetWidth / 2, ee = Se - R.value.offsetHeight / 2, R.value.style.left = `${ae}px`, R.value.style.top = `${ee}px`, Ce(!1), G(), window.addEventListener("mousemove", Ee), window.addEventListener("mouseup", Me));
1228
1237
  }, Ee = (t) => {
1229
1238
  t.preventDefault();
1230
1239
  const e = z.value.getBoundingClientRect(), l = t.clientX - e.left - R.value.offsetWidth / 2, i = t.clientY - e.top - R.value.offsetHeight / 2;
@@ -1301,9 +1310,9 @@ const It = { key: 1 }, Vt = {
1301
1310
  }
1302
1311
  }
1303
1312
  }
1304
- window.addEventListener("mousemove", de), window.addEventListener("mouseup", fe);
1313
+ window.addEventListener("mousemove", de), window.addEventListener("mouseup", he);
1305
1314
  }
1306
- }, fe = () => {
1315
+ }, he = () => {
1307
1316
  window.removeEventListener("mousemove", de), window.removeEventListener("mouseup", Ve);
1308
1317
  }, de = (t) => {
1309
1318
  var d, k;
@@ -1331,8 +1340,8 @@ const It = { key: 1 }, Vt = {
1331
1340
  };
1332
1341
  a.value[i].select = !1;
1333
1342
  const k = (I = u.value) == null ? void 0 : I.querySelector(".gradient-handle.select");
1334
- k == null || k.classList.remove("select"), a.value = [...a.value, d], be(d), _ = ($ = u.value) == null ? void 0 : $.querySelector(`#clr-gb-${d.id}`), q();
1335
- }, he = (t) => {
1343
+ k == null || k.classList.remove("select"), a.value = [...a.value, d], ye(d), _ = ($ = u.value) == null ? void 0 : $.querySelector(`#clr-gb-${d.id}`), q();
1344
+ }, be = (t) => {
1336
1345
  if (t.r == 0 && t.g == 0 && t.b == 0)
1337
1346
  return !0;
1338
1347
  if (t.r == 255 && t.g == 255 && t.b == 255)
@@ -1349,7 +1358,7 @@ const It = { key: 1 }, Vt = {
1349
1358
  }
1350
1359
  }, ce = (t, e, l, i, s) => {
1351
1360
  setTimeout(() => {
1352
- if (he({ r: t, g: e, b: l })) {
1361
+ if (be({ r: t, g: e, b: l })) {
1353
1362
  let d = me();
1354
1363
  d && (R.value.style.left = `${d.x}px`, R.value.style.top = `${d.y}px`);
1355
1364
  } else {
@@ -1358,12 +1367,12 @@ const It = { key: 1 }, Vt = {
1358
1367
  }
1359
1368
  }, 0);
1360
1369
  }, Le = () => {
1361
- a.value.forEach((l) => be(l)), Te();
1370
+ a.value.forEach((l) => ye(l)), Te();
1362
1371
  const t = a.value[0];
1363
1372
  ne.value = t.hue, Ie(!0);
1364
1373
  let e = me();
1365
1374
  e && (R.value.style.left = `${e.x}px`, R.value.style.top = `${e.y}px`), K(), q();
1366
- }, be = (t) => {
1375
+ }, ye = (t) => {
1367
1376
  if (b.value == "gradient") {
1368
1377
  let e = document.createElement("div");
1369
1378
  e.id = `clr-gb-${t.id}`, e.classList.add("gradient-handle"), e.style.left = He(t.percent);
@@ -1402,7 +1411,7 @@ const It = { key: 1 }, Vt = {
1402
1411
  }
1403
1412
  le.value.style.backgroundImage = e;
1404
1413
  let i = (t = u.value) == null ? void 0 : t.querySelector("#ck-cp-target-background");
1405
- i && (i.style.backgroundImage = l, F.value && c(i.style.backgroundImage));
1414
+ i && (i.style.backgroundImage = l, F.value && p(i.style.backgroundImage));
1406
1415
  } else {
1407
1416
  const { r: e, g: l, b: i, a: s } = a.value[0];
1408
1417
  let d = "";
@@ -1420,11 +1429,11 @@ const It = { key: 1 }, Vt = {
1420
1429
  d = lt(e, l, i);
1421
1430
  break;
1422
1431
  }
1423
- c(d);
1432
+ p(d);
1424
1433
  }
1425
1434
  }, Te = () => {
1426
1435
  a.value.forEach((t) => {
1427
- t.hue = Ae(t.r, t.g, t.b);
1436
+ t.hue = Qe(t.r, t.g, t.b);
1428
1437
  });
1429
1438
  }, qe = (t) => {
1430
1439
  L.value = t, q();
@@ -1447,8 +1456,8 @@ const It = { key: 1 }, Vt = {
1447
1456
  t == null || t.classList.add("active"), new EyeDropper().open().then((i) => {
1448
1457
  const { sRGBHex: s } = i, d = a.value.find((I) => I.select == !0), k = je(s);
1449
1458
  if (k) {
1450
- const I = Ae(k.r, k.g, k.b);
1451
- if (d && (d.hue = I, d.r = k.r, d.g = k.g, d.b = k.b), he(k)) {
1459
+ const I = Qe(k.r, k.g, k.b);
1460
+ if (d && (d.hue = I, d.r = k.r, d.g = k.g, d.b = k.b), be(k)) {
1452
1461
  const $ = me();
1453
1462
  $ && (R.value.style.left = `${$.x}px`, R.value.style.top = `${$.y}px`);
1454
1463
  } else {
@@ -1463,13 +1472,13 @@ const It = { key: 1 }, Vt = {
1463
1472
  }).catch(() => {
1464
1473
  t == null || t.classList.remove("active");
1465
1474
  });
1466
- }, p = (t) => {
1475
+ }, c = (t) => {
1467
1476
  const { value: e, type: l } = t;
1468
1477
  if (l != "a") {
1469
1478
  const i = a.value.find((s) => s.select == !0);
1470
1479
  if (i) {
1471
1480
  i.r = parseInt(e.r), i.g = parseInt(e.g), i.b = parseInt(e.b);
1472
- const s = Ae(i.r, i.g, i.b);
1481
+ const s = Qe(i.r, i.g, i.b);
1473
1482
  i.hue = s, ce(i.r, i.g, i.b, i.hue, !0), q(), K();
1474
1483
  }
1475
1484
  } else
@@ -1481,11 +1490,11 @@ const It = { key: 1 }, Vt = {
1481
1490
  const { r: l, g: i, b: s } = et(N.h, N.s / 100, N.l / 100);
1482
1491
  e.hue = N.h, e.r = l, e.g = i, e.b = s, ce(e.r, e.g, e.b, e.hue, !0), q(), K();
1483
1492
  }
1484
- }, y = () => {
1493
+ }, x = () => {
1485
1494
  if (j.value) {
1486
1495
  const t = je(j.value);
1487
1496
  if (t) {
1488
- const e = Ae(t.r, t.g, t.b), l = a.value.find((i) => i.select == !0);
1497
+ const e = Qe(t.r, t.g, t.b), l = a.value.find((i) => i.select == !0);
1489
1498
  l && (l.r = t.r, l.g = t.g, l.b = t.b, l.hue = e, ce(t.r, t.g, t.b, l.hue, !0), q(), K(), pe(M.value));
1490
1499
  }
1491
1500
  }
@@ -1496,7 +1505,7 @@ const It = { key: 1 }, Vt = {
1496
1505
  f("last-used-pick", t);
1497
1506
  };
1498
1507
  window.EyeDropper && (O.value = !0);
1499
- const ye = (t = "") => {
1508
+ const xe = (t = "") => {
1500
1509
  if (b.value == "gradient") {
1501
1510
  let e = t.includes("linear") ? "linear" : "radial", l = [];
1502
1511
  if (L.value = e, e == "linear") {
@@ -1593,16 +1602,16 @@ const It = { key: 1 }, Vt = {
1593
1602
  }
1594
1603
  M.value = t;
1595
1604
  }
1596
- }, xe = (t) => {
1597
- t && ye(t), Le();
1605
+ }, ke = (t) => {
1606
+ t && xe(t), Le();
1598
1607
  };
1599
- we(
1608
+ fe(
1600
1609
  () => r.modelValue,
1601
1610
  (t, e) => {
1602
1611
  t !== e && t !== C.value && (a.value.forEach((l) => {
1603
1612
  const i = P == null ? void 0 : P.querySelector(`#clr-gb-${l.id}`);
1604
1613
  i == null || i.remove();
1605
- }), xe(t));
1614
+ }), ke(t));
1606
1615
  }
1607
1616
  );
1608
1617
  const ut = (t) => {
@@ -1613,18 +1622,18 @@ const It = { key: 1 }, Vt = {
1613
1622
  var e;
1614
1623
  P = (e = u.value) == null ? void 0 : e.querySelector(".gradient-bar"), qe(t), Le();
1615
1624
  }, 200)) : t === "solid" && (b.value = "solid", a.value = a.value.map((e) => (e.select = !1, e)), a.value[0].select = !0, setTimeout(() => {
1616
- xe(r.modelValue);
1625
+ ke(r.modelValue);
1617
1626
  }, 200));
1618
1627
  };
1619
1628
  return Je(() => {
1620
1629
  var t;
1621
- b.value = r.modelValue.includes("linear") || r.modelValue.includes("radial") ? "gradient" : "solid", b.value == "gradient" && (P = (t = u.value) == null ? void 0 : t.querySelector(".gradient-bar")), xe(r.modelValue), pe(M.value), mt(() => {
1630
+ b.value = r.modelValue.includes("linear") || r.modelValue.includes("radial") ? "gradient" : "solid", b.value == "gradient" && (P = (t = u.value) == null ? void 0 : t.querySelector(".gradient-bar")), ke(r.modelValue), pe(M.value), mt(() => {
1622
1631
  F.value = !0;
1623
1632
  });
1624
1633
  }), (t, e) => (m(), E("div", {
1625
1634
  ref_key: "pickerTemplateRef",
1626
1635
  ref: u,
1627
- class: A(["ck-cp-container", n.disabled ? "ck-cp-disabled " : ""]),
1636
+ class: Q(["ck-cp-container", n.disabled ? "ck-cp-disabled " : ""]),
1628
1637
  "cp-theme": n.theme
1629
1638
  }, [
1630
1639
  n.variant == "gradient" ? (m(), E("div", rl, [
@@ -1673,7 +1682,7 @@ const It = { key: 1 }, Vt = {
1673
1682
  T(al, { onOnMouseDown: Ne }),
1674
1683
  h("div", vl, [
1675
1684
  T(_t, {
1676
- class: A(O.value ? "max-w-[90%]" : ""),
1685
+ class: Q(O.value ? "max-w-[90%]" : ""),
1677
1686
  modelValue: ne.value,
1678
1687
  "onUpdate:modelValue": e[3] || (e[3] = (l) => ne.value = l),
1679
1688
  onOnInput: e[4] || (e[4] = (l) => Ie(!1)),
@@ -1718,13 +1727,13 @@ const It = { key: 1 }, Vt = {
1718
1727
  modelValue: j.value,
1719
1728
  "onUpdate:modelValue": [
1720
1729
  e[7] || (e[7] = (l) => j.value = l),
1721
- y
1730
+ x
1722
1731
  ]
1723
1732
  }, null, 8, ["modelValue"])) : D("", !0),
1724
1733
  M.value == "RGB" ? (m(), X(nt, {
1725
1734
  key: 1,
1726
1735
  "rgb-value": a.value.find((l) => l.select == !0),
1727
- onUpdateRgbValue: p
1736
+ onUpdateRgbValue: c
1728
1737
  }, null, 8, ["rgb-value"])) : D("", !0),
1729
1738
  M.value == "HSL" ? (m(), X(nt, {
1730
1739
  key: 2,
@@ -1780,7 +1789,7 @@ const It = { key: 1 }, Vt = {
1780
1789
  }
1781
1790
  },
1782
1791
  setup(n) {
1783
- const V = n, r = ke(() => ({
1792
+ const V = n, r = $e(() => ({
1784
1793
  grid: {
1785
1794
  containLabel: !1
1786
1795
  },
@@ -1829,7 +1838,7 @@ const It = { key: 1 }, Vt = {
1829
1838
  () => import("./OcLottieAnimation-EBkAB8-y.js")
1830
1839
  );
1831
1840
  export {
1832
- Ql as BarChart,
1841
+ Al as BarChart,
1833
1842
  Nl as BarRaceChart,
1834
1843
  Xl as Card,
1835
1844
  Ml as CodeBlock,