@jsg-developer/vue-pack 0.0.8 → 0.0.9-beta-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.
Files changed (100) hide show
  1. package/THIRD_PARTY_LICENSES.json +1 -1
  2. package/dist/chunks/{ArrayObject-Csiz0aJR.cjs.js → ArrayObject-BA88O7bP.cjs.js} +1 -1
  3. package/dist/chunks/ArrayObject-DYnfWxW-.es.js +4 -0
  4. package/dist/chunks/ColorPicker-CqrPcGbi.es.js +4 -0
  5. package/dist/chunks/{ColorPicker-CrIAXDwh.cjs.js → ColorPicker-W_cn5ezl.cjs.js} +1 -1
  6. package/dist/chunks/ComboboxComponent-BU-VQz2u.es.js +4 -0
  7. package/dist/chunks/{ComboboxComponent-CPTq69Ar.cjs.js → ComboboxComponent-Dwlhjcru.cjs.js} +1 -1
  8. package/dist/chunks/{CurrencyInput-CwoIqJ6_.cjs.js → CurrencyInput-CNQzGqgu.cjs.js} +1 -1
  9. package/dist/chunks/CurrencyInput-DVlgxmiu.es.js +4 -0
  10. package/dist/chunks/DateInput-B1EpMWa0.es.js +4 -0
  11. package/dist/chunks/{DateInput-wbBbKLmh.cjs.js → DateInput-DMFCzQCr.cjs.js} +1 -1
  12. package/dist/chunks/{DateTimeInput-BEpP2CFJ.cjs.js → DateTimeInput-8w4T-EZX.cjs.js} +1 -1
  13. package/dist/chunks/{DateTimeInput-CCrf600J.es.js → DateTimeInput-CC70bKnU.es.js} +1 -1
  14. package/dist/chunks/{DateTimeInput.vue_vue_type_script_setup_true_lang-DF9gRqkl.es.js → DateTimeInput.vue_vue_type_script_setup_true_lang-BLJgRk91.es.js} +1 -1
  15. package/dist/chunks/{DateTimeInput.vue_vue_type_script_setup_true_lang-BGz0eU7k.cjs.js → DateTimeInput.vue_vue_type_script_setup_true_lang-DmmVjDPV.cjs.js} +1 -1
  16. package/dist/chunks/EmailInput-B0F3AHeq.es.js +4 -0
  17. package/dist/chunks/{EmailInput-CNVGAFnD.cjs.js → EmailInput-EU4MR4Jw.cjs.js} +1 -1
  18. package/dist/chunks/{FileArrayInput-CAwxVS0H.cjs.js → FileArrayInput-CR-seczb.cjs.js} +1 -1
  19. package/dist/chunks/{FileArrayInput-DEHJtU_H.es.js → FileArrayInput-DljGrRxA.es.js} +2 -2
  20. package/dist/chunks/{FileArrayInput.vue_vue_type_script_setup_true_lang-BrR9G0CJ.es.js → FileArrayInput.vue_vue_type_script_setup_true_lang-C7UCpQqG.es.js} +1 -1
  21. package/dist/chunks/{FileArrayInput.vue_vue_type_script_setup_true_lang-BMhnxsx_.cjs.js → FileArrayInput.vue_vue_type_script_setup_true_lang-DtC-rygi.cjs.js} +1 -1
  22. package/dist/chunks/{FileInput-D3qv7Xva.cjs.js → FileInput-A1qH_OLh.cjs.js} +1 -1
  23. package/dist/chunks/FileInput-CC5a2_o2.es.js +4 -0
  24. package/dist/chunks/{GroupRenderer-B-LDNqgX.cjs.js → GroupRenderer-BL1UiQs5.cjs.js} +1 -1
  25. package/dist/chunks/GroupRenderer-Cj7o8pSh.es.js +4 -0
  26. package/dist/chunks/{ImageArrayInput-BGOtUALS.cjs.js → ImageArrayInput-B3f9I0U1.cjs.js} +1 -1
  27. package/dist/chunks/{ImageArrayInput-CjLQeJk1.es.js → ImageArrayInput-Bl0af1_X.es.js} +2 -2
  28. package/dist/chunks/ImageArrayInput.vue_vue_type_script_setup_true_lang-NqHOY8OF.es.js +421 -0
  29. package/dist/chunks/ImageArrayInput.vue_vue_type_script_setup_true_lang-d88H9xj4.cjs.js +2 -0
  30. package/dist/chunks/ImageInput-DL8tNIdV.es.js +4 -0
  31. package/dist/chunks/{ImageInput-DiBVxIYB.cjs.js → ImageInput-KmSPSWhK.cjs.js} +1 -1
  32. package/dist/chunks/NumberInput-BOjP2XCy.es.js +4 -0
  33. package/dist/chunks/{NumberInput-uOgJyDTw.cjs.js → NumberInput-C47NQmuA.cjs.js} +1 -1
  34. package/dist/chunks/ObjectInput-DLkhG2Ha.es.js +4 -0
  35. package/dist/chunks/{ObjectInput-DaD5_SCP.cjs.js → ObjectInput-e0FX9gIv.cjs.js} +1 -1
  36. package/dist/chunks/{PasswordInput-De3IIREc.cjs.js → PasswordInput-CgeIq4tr.cjs.js} +1 -1
  37. package/dist/chunks/PasswordInput-CkF4phav.es.js +4 -0
  38. package/dist/chunks/{RateInput-DabVE516.cjs.js → RateInput-C7irYBQy.cjs.js} +1 -1
  39. package/dist/chunks/RateInput-DYD5aMQX.es.js +4 -0
  40. package/dist/chunks/TabelData-DV56gH8Y.cjs.js +1 -0
  41. package/dist/chunks/{TabelData-DmCnbhpq.es.js → TabelData-jJvzQD8f.es.js} +8 -7
  42. package/dist/chunks/TagInput-B6F5GleV.es.js +4 -0
  43. package/dist/chunks/{TagInput-DeJtdDLy.cjs.js → TagInput-DC9jPCR9.cjs.js} +1 -1
  44. package/dist/chunks/{TelInput-BP9pUjqj.cjs.js → TelInput-BTioT0Aa.cjs.js} +1 -1
  45. package/dist/chunks/TelInput-BwtzcLzw.es.js +4 -0
  46. package/dist/chunks/TextAreaInput-B-dcc-ch.es.js +4 -0
  47. package/dist/chunks/{TextAreaInput-HHOxggqB.cjs.js → TextAreaInput-BXlGB91c.cjs.js} +1 -1
  48. package/dist/chunks/{TextAreaQuill-eYXH5fmB.es.js → TextAreaQuill-CJyF1I1R.es.js} +240 -203
  49. package/dist/chunks/TextAreaQuill-DKgdqbEG.cjs.js +1 -0
  50. package/dist/chunks/TextInput-BwgTx7Xt.es.js +4 -0
  51. package/dist/chunks/{TextInput-CdvHKzTG.cjs.js → TextInput-CC8TbO0N.cjs.js} +1 -1
  52. package/dist/chunks/{TimeInput-X--wGzRV.cjs.js → TimeInput-BvUbIEtA.cjs.js} +1 -1
  53. package/dist/chunks/TimeInput-DsiHBSIo.es.js +4 -0
  54. package/dist/chunks/{ToggleInput-D3mXx4T9.cjs.js → ToggleInput-DfAKsRdZ.cjs.js} +1 -1
  55. package/dist/chunks/ToggleInput-mQ_mnG4E.es.js +4 -0
  56. package/dist/chunks/{UrlInput-B7aRJE-9.cjs.js → UrlInput-C8bIoQBb.cjs.js} +1 -1
  57. package/dist/chunks/UrlInput-o1uJulwN.es.js +4 -0
  58. package/dist/chunks/{resize-BCFyG_8Z.es.js → resize-2N3sqejU.es.js} +2384 -2297
  59. package/dist/chunks/resize-DsxsWx52.cjs.js +12 -0
  60. package/dist/init.cjs.js +1 -1
  61. package/dist/init.es.js +1 -1
  62. package/dist/jsgd-vue-pack.cjs.js +1 -1
  63. package/dist/jsgd-vue-pack.es.js +104 -109
  64. package/dist/style.css +1 -1
  65. package/dist/types/components/Form/composables/useFormModal.d.ts +1 -9
  66. package/dist/types/components/UI/Inputs/ImageInput.vue.d.ts +3 -1
  67. package/dist/types/configs/types/field.types.d.ts +15 -28
  68. package/dist/types/configs/types/index.d.ts +1 -0
  69. package/dist/types/configs/types/props.types.d.ts +28 -6
  70. package/dist/types/configs/types/seo.types.d.ts +37 -0
  71. package/dist/types/untils/index.d.ts +1 -0
  72. package/dist/types/untils/seo.d.ts +4 -0
  73. package/dist/vue.cjs.js +1 -1
  74. package/dist/vue.es.js +6 -6
  75. package/package.json +1 -1
  76. package/dist/chunks/ArrayObject-BOxAB7JZ.es.js +0 -4
  77. package/dist/chunks/ColorPicker-DLKQ9Ey-.es.js +0 -4
  78. package/dist/chunks/ComboboxComponent-NlXQEb6_.es.js +0 -4
  79. package/dist/chunks/CurrencyInput-ClxBxxvt.es.js +0 -4
  80. package/dist/chunks/DateInput-Cin-DZ5f.es.js +0 -4
  81. package/dist/chunks/EmailInput-Dy0XZ2Qa.es.js +0 -4
  82. package/dist/chunks/FileInput-CgYkE6-h.es.js +0 -4
  83. package/dist/chunks/GroupRenderer-B9wTfSqo.es.js +0 -4
  84. package/dist/chunks/ImageArrayInput.vue_vue_type_script_setup_true_lang-B1pEayO7.cjs.js +0 -2
  85. package/dist/chunks/ImageArrayInput.vue_vue_type_script_setup_true_lang-DrIW4vyr.es.js +0 -322
  86. package/dist/chunks/ImageInput-C35ZFMDt.es.js +0 -4
  87. package/dist/chunks/NumberInput-Cb45QifM.es.js +0 -4
  88. package/dist/chunks/ObjectInput-DAyAshay.es.js +0 -4
  89. package/dist/chunks/PasswordInput-BPId2jr-.es.js +0 -4
  90. package/dist/chunks/RateInput-D6pg36at.es.js +0 -4
  91. package/dist/chunks/TabelData-C0mYBwlw.cjs.js +0 -1
  92. package/dist/chunks/TagInput-Dd6wqtMS.es.js +0 -4
  93. package/dist/chunks/TelInput-D-CBtvax.es.js +0 -4
  94. package/dist/chunks/TextAreaInput-6XZuCGgS.es.js +0 -4
  95. package/dist/chunks/TextAreaQuill-B9Y9deA0.cjs.js +0 -1
  96. package/dist/chunks/TextInput-BhSOEwQF.es.js +0 -4
  97. package/dist/chunks/TimeInput-C1P44F3V.es.js +0 -4
  98. package/dist/chunks/ToggleInput-CSw8joFu.es.js +0 -4
  99. package/dist/chunks/UrlInput-_14ZDA_x.es.js +0 -4
  100. package/dist/chunks/resize-xk-5mOU-.cjs.js +0 -12
@@ -1,18 +1,18 @@
1
- import { defineComponent as Q, ref as r, computed as M, watch as V, createBlock as D, openBlock as i, Transition as B, withCtx as C, createElementBlock as c, createCommentVNode as f, withModifiers as O, createVNode as P, createElementVNode as e, toDisplayString as I, normalizeClass as A, withDirectives as _, vModelText as R, withKeys as G, inject as ee, onMounted as te, onUnmounted as se, Teleport as le, createTextVNode as F, unref as de, Fragment as ae, renderList as oe } from "vue";
2
- import N from "dompurify";
3
- import { ab as H, U as ne, z as re, a9 as E, a as ie } from "./resize-BCFyG_8Z.es.js";
1
+ import { defineComponent as Q, ref as n, computed as M, watch as I, createBlock as B, openBlock as r, Transition as D, withCtx as E, createElementBlock as j, createCommentVNode as x, withModifiers as G, createVNode as P, createElementVNode as e, toDisplayString as C, normalizeClass as A, withDirectives as V, vModelText as z, withKeys as K, inject as le, onMounted as de, onUnmounted as ae, Teleport as oe, createTextVNode as F, unref as ne, vShow as re, Fragment as ie, renderList as ue } from "vue";
2
+ import H from "dompurify";
3
+ import { ac as N, U as ge, z as je, aa as _, a as ce } from "./resize-2N3sqejU.es.js";
4
4
  import "lodash.isequal";
5
5
  import "zod";
6
- const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsgd-shadow-2xl jsgd-overflow-hidden dark:jsgd-bg-slate-800" }, ue = { class: "jsgd-p-5 jsgd-border-b jsgd-border-slate-200 dark:jsgd-border-slate-700" }, je = { class: "jsgd-text-lg jsgd-font-bold jsgd-text-slate-900 dark:jsgd-text-slate-100" }, ce = { class: "jsgd-p-5 jsgd-flex jsgd-flex-col jsgd-gap-5" }, me = {
6
+ const me = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsgd-shadow-2xl jsgd-overflow-hidden dark:jsgd-bg-slate-800" }, be = { class: "jsgd-p-5 jsgd-border-b jsgd-border-slate-200 dark:jsgd-border-slate-700" }, ve = { class: "jsgd-text-lg jsgd-font-bold jsgd-text-slate-900 dark:jsgd-text-slate-100" }, pe = { class: "jsgd-p-5 jsgd-flex jsgd-flex-col jsgd-gap-5" }, fe = {
7
7
  key: 0,
8
8
  class: "jsgd-flex jsgd-w-full jsgd-p-1 jsgd-bg-slate-100 jsgd-rounded-lg dark:jsgd-bg-slate-700"
9
- }, be = { key: 1 }, ve = {
9
+ }, xe = { key: 1 }, he = {
10
10
  key: 2,
11
11
  class: "jsgd-box-border"
12
- }, pe = ["placeholder"], xe = { key: 3 }, fe = ["accept"], he = {
12
+ }, ke = ["placeholder"], we = { key: 3 }, ye = ["accept"], qe = {
13
13
  key: 0,
14
14
  class: "jsgd-mt-4"
15
- }, ke = ["src"], we = { key: 4 }, ye = { class: "jsgd-p-4 jsgd-bg-slate-50 jsgd-flex jsgd-justify-end jsgd-gap-3 dark:jsgd-bg-slate-900/50" }, qe = ["disabled"], Ue = { key: 0 }, Te = { key: 1 }, Le = /* @__PURE__ */ Q({
15
+ }, Ue = ["src"], Te = { key: 4 }, Le = { class: "jsgd-p-4 jsgd-bg-slate-50 jsgd-flex jsgd-justify-end jsgd-gap-3 dark:jsgd-bg-slate-900/50" }, Me = ["disabled"], Ve = { key: 0 }, Se = { key: 1 }, $e = /* @__PURE__ */ Q({
16
16
  __name: "QuillEmbedModal",
17
17
  props: {
18
18
  show: { type: Boolean },
@@ -22,8 +22,8 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
22
22
  initialText: {}
23
23
  },
24
24
  emits: ["close", "submit"],
25
- setup(g, { emit: S }) {
26
- const s = g, h = S, l = r(""), m = r(""), b = r(null), k = r(""), v = r(null), p = r(!1), u = r("url"), w = M(() => !!s.uploadUrl), z = M(() => {
25
+ setup(u, { emit: S }) {
26
+ const s = u, h = S, l = n(""), b = n(""), v = n(null), k = n(""), p = n(null), f = n(!1), g = n("url"), w = M(() => !!s.uploadUrl), R = M(() => {
27
27
  switch (s.mode) {
28
28
  case "image":
29
29
  return "Insert Image";
@@ -34,30 +34,30 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
34
34
  default:
35
35
  return "Insert Media";
36
36
  }
37
- }), j = M(() => s.mode === "video" ? "e.g., YouTube, Vimeo URL" : "https://...");
38
- V(
37
+ }), c = M(() => s.mode === "video" ? "e.g., YouTube, Vimeo URL" : "https://...");
38
+ I(
39
39
  () => s.show,
40
- (x) => {
41
- x && (u.value = w.value ? "upload" : "url", l.value = s.initialValue || "", k.value = s.initialText || "", m.value = "", b.value = null, v.value = null, p.value = !1);
40
+ (m) => {
41
+ m && (g.value = w.value ? "upload" : "url", l.value = s.initialValue || "", k.value = s.initialText || "", b.value = "", v.value = null, p.value = null, f.value = !1);
42
42
  }
43
43
  );
44
44
  function U() {
45
45
  h("close");
46
46
  }
47
- function T(x) {
48
- const d = x.target;
49
- if (d.files && d.files[0] && (b.value = d.files[0], s.mode === "image")) {
50
- const n = new FileReader();
51
- n.onload = (L) => {
52
- v.value = L.target?.result;
53
- }, n.readAsDataURL(b.value);
47
+ function T(m) {
48
+ const d = m.target;
49
+ if (d.files && d.files[0] && (v.value = d.files[0], s.mode === "image")) {
50
+ const i = new FileReader();
51
+ i.onload = (L) => {
52
+ p.value = L.target?.result;
53
+ }, i.readAsDataURL(v.value);
54
54
  }
55
55
  }
56
56
  async function $() {
57
- p.value = !0;
57
+ f.value = !0;
58
58
  try {
59
- if (u.value === "upload" && w.value) {
60
- if (!b.value) {
59
+ if (g.value === "upload" && w.value) {
60
+ if (!v.value) {
61
61
  alert("Please select a file to upload.");
62
62
  return;
63
63
  }
@@ -65,114 +65,114 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
65
65
  alert("Upload API URL is not configured.");
66
66
  return;
67
67
  }
68
- const x = new FormData();
69
- x.append("file", b.value);
70
- const d = await fetch(s.uploadUrl, { method: "POST", body: x });
68
+ const m = new FormData();
69
+ m.append("file", v.value);
70
+ const d = await fetch(s.uploadUrl, { method: "POST", body: m });
71
71
  if (!d.ok) throw new Error("Upload failed");
72
- const n = await d.json(), L = n.url || n.secure_url || n.path || n.data?.url || n.data?.path || n.data?.secure_url;
72
+ const i = await d.json(), L = i.url || i.secure_url || i.path || i.data?.url || i.data?.path || i.data?.secure_url;
73
73
  if (!L) throw new Error("URL not found in upload response");
74
- h("submit", { url: L, alt: m.value, text: k.value });
74
+ h("submit", { url: L, alt: b.value, text: k.value });
75
75
  } else {
76
76
  if (!l.value) {
77
77
  alert("Please enter a URL.");
78
78
  return;
79
79
  }
80
- h("submit", { url: l.value, alt: m.value, text: k.value });
80
+ h("submit", { url: l.value, alt: b.value, text: k.value });
81
81
  }
82
- } catch (x) {
83
- console.error(x), alert(x.message || "An error occurred.");
82
+ } catch (m) {
83
+ console.error(m), alert(m.message || "An error occurred.");
84
84
  } finally {
85
- p.value = !1;
85
+ f.value = !1;
86
86
  }
87
87
  }
88
- return (x, d) => (i(), D(B, {
88
+ return (m, d) => (r(), B(D, {
89
89
  name: "jsgd-modal-overlay",
90
90
  appear: ""
91
91
  }, {
92
- default: C(() => [
93
- g.show ? (i(), c("div", {
92
+ default: E(() => [
93
+ u.show ? (r(), j("div", {
94
94
  key: 0,
95
95
  class: "jsgd-fixed jsgd-inset-0 jsgd-z-[10000000] jsgd-flex jsgd-items-center jsgd-justify-center jsgd-p-4 jsgd-bg-black/60 jsgd-backdrop-blur-sm",
96
- onClick: O(U, ["self"])
96
+ onClick: G(U, ["self"])
97
97
  }, [
98
- P(B, {
98
+ P(D, {
99
99
  name: "jsgd-modal-container",
100
100
  appear: ""
101
101
  }, {
102
- default: C(() => [
103
- e("div", ge, [
104
- e("div", ue, [
105
- e("h3", je, I(z.value), 1)
102
+ default: E(() => [
103
+ e("div", me, [
104
+ e("div", be, [
105
+ e("h3", ve, C(R.value), 1)
106
106
  ]),
107
- e("div", ce, [
108
- w.value && g.mode !== "link" ? (i(), c("div", me, [
107
+ e("div", pe, [
108
+ w.value && u.mode !== "link" ? (r(), j("div", fe, [
109
109
  e("button", {
110
- onClick: d[0] || (d[0] = (n) => u.value = "upload"),
110
+ onClick: d[0] || (d[0] = (i) => g.value = "upload"),
111
111
  class: A([
112
112
  "jsgd-flex-1 jsgd-py-1.5 jsgd-px-3 jsgd-text-sm jsgd-font-semibold jsgd-rounded-md jsgd-transition-colors jsgd-duration-200",
113
- u.value === "upload" ? "jsgd-bg-white jsgd-text-blue-600 jsgd-shadow-sm dark:jsgd-bg-slate-600 dark:jsgd-text-white" : "jsgd-bg-transparent jsgd-text-slate-500 hover:jsgd-text-slate-700 dark:jsgd-text-slate-400 dark:hover:jsgd-text-slate-200"
113
+ g.value === "upload" ? "jsgd-bg-white jsgd-text-blue-600 jsgd-shadow-sm dark:jsgd-bg-slate-600 dark:jsgd-text-white" : "jsgd-bg-transparent jsgd-text-slate-500 hover:jsgd-text-slate-700 dark:jsgd-text-slate-400 dark:hover:jsgd-text-slate-200"
114
114
  ])
115
115
  }, " Upload ", 2),
116
116
  e("button", {
117
- onClick: d[1] || (d[1] = (n) => u.value = "url"),
117
+ onClick: d[1] || (d[1] = (i) => g.value = "url"),
118
118
  class: A([
119
119
  "jsgd-flex-1 jsgd-py-1.5 jsgd-px-3 jsgd-text-sm jsgd-font-semibold jsgd-rounded-md jsgd-transition-colors jsgd-duration-200",
120
- u.value === "url" ? "jsgd-bg-white jsgd-text-blue-600 jsgd-shadow-sm dark:jsgd-bg-slate-600 dark:jsgd-text-white" : "jsgd-bg-transparent jsgd-text-slate-500 hover:jsgd-text-slate-700 dark:jsgd-text-slate-400 dark:hover:jsgd-text-slate-200"
120
+ g.value === "url" ? "jsgd-bg-white jsgd-text-blue-600 jsgd-shadow-sm dark:jsgd-bg-slate-600 dark:jsgd-text-white" : "jsgd-bg-transparent jsgd-text-slate-500 hover:jsgd-text-slate-700 dark:jsgd-text-slate-400 dark:hover:jsgd-text-slate-200"
121
121
  ])
122
122
  }, " From URL ", 2)
123
- ])) : f("", !0),
124
- g.mode === "link" ? (i(), c("div", be, [
123
+ ])) : x("", !0),
124
+ u.mode === "link" ? (r(), j("div", xe, [
125
125
  d[5] || (d[5] = e("label", { class: "jsgd-block jsgd-text-sm jsgd-font-medium jsgd-mb-1 dark:jsgd-text-slate-300" }, "Text to display", -1)),
126
- _(e("input", {
127
- "onUpdate:modelValue": d[2] || (d[2] = (n) => k.value = n),
126
+ V(e("input", {
127
+ "onUpdate:modelValue": d[2] || (d[2] = (i) => k.value = i),
128
128
  type: "text",
129
129
  placeholder: "If empty, URL will be shown",
130
130
  class: "jsgd-w-full jsgd-py-2 jsgd-px-3 jsgd-rounded-md jsgd-border jsgd-border-slate-300 dark:jsgd-bg-slate-700 dark:jsgd-border-slate-600 dark:jsgd-text-white"
131
131
  }, null, 512), [
132
- [R, k.value]
132
+ [z, k.value]
133
133
  ])
134
- ])) : f("", !0),
135
- u.value === "url" || g.mode === "link" ? (i(), c("div", ve, [
134
+ ])) : x("", !0),
135
+ g.value === "url" || u.mode === "link" ? (r(), j("div", he, [
136
136
  d[6] || (d[6] = e("label", { class: "jsgd-block jsgd-text-sm jsgd-font-medium jsgd-mb-1 dark:jsgd-text-slate-300" }, "URL", -1)),
137
- _(e("input", {
138
- "onUpdate:modelValue": d[3] || (d[3] = (n) => l.value = n),
137
+ V(e("input", {
138
+ "onUpdate:modelValue": d[3] || (d[3] = (i) => l.value = i),
139
139
  type: "text",
140
- placeholder: j.value,
140
+ placeholder: c.value,
141
141
  class: "jsgd-w-full jsgd-py-2 jsgd-px-3 jsgd-rounded-md jsgd-border jsgd-border-slate-300 dark:jsgd-bg-slate-700 dark:jsgd-border-slate-600 dark:jsgd-text-white",
142
- onKeydown: G($, ["enter"])
143
- }, null, 40, pe), [
144
- [R, l.value]
142
+ onKeydown: K($, ["enter"])
143
+ }, null, 40, ke), [
144
+ [z, l.value]
145
145
  ])
146
- ])) : f("", !0),
147
- u.value === "upload" && w.value ? (i(), c("div", xe, [
146
+ ])) : x("", !0),
147
+ g.value === "upload" && w.value ? (r(), j("div", we, [
148
148
  d[7] || (d[7] = e("label", { class: "jsgd-block jsgd-text-sm jsgd-font-medium jsgd-mb-1 dark:jsgd-text-slate-300" }, "Upload File", -1)),
149
149
  e("input", {
150
150
  type: "file",
151
- accept: g.mode === "image" ? "image/*" : "video/*",
151
+ accept: u.mode === "image" ? "image/*" : "video/*",
152
152
  onChange: T,
153
153
  class: "jsgd-w-full jsgd-text-sm jsgd-text-slate-500 file:jsgd-mr-4 file:jsgd-py-2 file:jsgd-px-4 file:jsgd-rounded-full file:jsgd-border-0 file:jsgd-text-sm file:jsgd-font-semibold file:jsgd-bg-blue-50 file:jsgd-text-blue-700 hover:file:jsgd-bg-blue-100 dark:file:jsgd-bg-blue-900/50 dark:file:jsgd-text-blue-300 dark:hover:file:jsgd-bg-blue-900"
154
- }, null, 40, fe),
155
- v.value ? (i(), c("div", he, [
154
+ }, null, 40, ye),
155
+ p.value ? (r(), j("div", qe, [
156
156
  e("img", {
157
- src: v.value,
157
+ src: p.value,
158
158
  class: "jsgd-max-w-full jsgd-max-h-40 jsgd-rounded-md",
159
159
  alt: "Upload Preview"
160
- }, null, 8, ke)
161
- ])) : f("", !0)
162
- ])) : f("", !0),
163
- g.mode === "image" ? (i(), c("div", we, [
160
+ }, null, 8, Ue)
161
+ ])) : x("", !0)
162
+ ])) : x("", !0),
163
+ u.mode === "image" ? (r(), j("div", Te, [
164
164
  d[8] || (d[8] = e("label", { class: "jsgd-block jsgd-text-sm jsgd-font-medium jsgd-mb-1 dark:jsgd-text-slate-300" }, "Alt Text (Optional)", -1)),
165
- _(e("input", {
166
- "onUpdate:modelValue": d[4] || (d[4] = (n) => m.value = n),
165
+ V(e("input", {
166
+ "onUpdate:modelValue": d[4] || (d[4] = (i) => b.value = i),
167
167
  type: "text",
168
168
  placeholder: "Describe the image for accessibility",
169
169
  class: "jsgd-w-full jsgd-py-2 jsgd-px-3 jsgd-rounded-md jsgd-border jsgd-border-slate-300 dark:jsgd-bg-slate-700 dark:jsgd-border-slate-600 dark:jsgd-text-white"
170
170
  }, null, 512), [
171
- [R, m.value]
171
+ [z, b.value]
172
172
  ])
173
- ])) : f("", !0)
173
+ ])) : x("", !0)
174
174
  ]),
175
- e("div", ye, [
175
+ e("div", Le, [
176
176
  e("button", {
177
177
  onClick: U,
178
178
  class: "jsgd-px-4 jsgd-py-2 jsgd-rounded-md jsgd-text-sm jsgd-font-medium jsgd-bg-white jsgd-border jsgd-border-slate-300 hover:jsgd-bg-slate-50 dark:jsgd-bg-slate-700 dark:jsgd-text-slate-200 dark:jsgd-border-slate-600 dark:hover:jsgd-bg-slate-600"
@@ -180,82 +180,82 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
180
180
  e("button", {
181
181
  onClick: $,
182
182
  class: "jsgd-px-4 jsgd-py-2 jsgd-rounded-md jsgd-text-sm jsgd-font-medium jsgd-text-white jsgd-bg-blue-600 hover:jsgd-bg-blue-700 dark:jsgd-bg-blue-500 dark:hover:jsgd-bg-blue-600",
183
- disabled: p.value
183
+ disabled: f.value
184
184
  }, [
185
- p.value ? (i(), c("span", Ue, "Inserting...")) : (i(), c("span", Te, "Insert"))
186
- ], 8, qe)
185
+ f.value ? (r(), j("span", Ve, "Inserting...")) : (r(), j("span", Se, "Insert"))
186
+ ], 8, Me)
187
187
  ])
188
188
  ])
189
189
  ]),
190
190
  _: 1
191
191
  })
192
- ])) : f("", !0)
192
+ ])) : x("", !0)
193
193
  ]),
194
194
  _: 1
195
195
  }));
196
196
  }
197
- }), Me = /* @__PURE__ */ H(Le, [["__scopeId", "data-v-e9ba68c4"]]), Se = { class: "jsgd-w-full jsgd-max-w-sm jsgd-bg-white jsgd-rounded-xl jsgd-shadow-2xl jsgd-overflow-hidden dark:jsgd-bg-slate-800" }, $e = { class: "jsgd-p-5 jsgd-flex jsgd-flex-col jsgd-gap-4" }, Ie = /* @__PURE__ */ Q({
197
+ }), Ce = /* @__PURE__ */ N($e, [["__scopeId", "data-v-e9ba68c4"]]), Ie = { class: "jsgd-w-full jsgd-max-w-sm jsgd-bg-white jsgd-rounded-xl jsgd-shadow-2xl jsgd-overflow-hidden dark:jsgd-bg-slate-800" }, Ae = { class: "jsgd-p-5 jsgd-flex jsgd-flex-col jsgd-gap-4" }, ze = /* @__PURE__ */ Q({
198
198
  __name: "QuillAltModal",
199
199
  props: {
200
200
  show: { type: Boolean },
201
201
  initialValue: {}
202
202
  },
203
203
  emits: ["close", "submit"],
204
- setup(g, { emit: S }) {
205
- const s = g, h = S, l = r("");
206
- V(
204
+ setup(u, { emit: S }) {
205
+ const s = u, h = S, l = n("");
206
+ I(
207
207
  () => s.show,
208
208
  (k) => {
209
209
  k && (l.value = s.initialValue || "");
210
210
  }
211
211
  );
212
- function m() {
212
+ function b() {
213
213
  h("close");
214
214
  }
215
- function b() {
215
+ function v() {
216
216
  h("submit", l.value);
217
217
  }
218
- return (k, v) => (i(), D(B, {
218
+ return (k, p) => (r(), B(D, {
219
219
  name: "jsgd-modal-overlay",
220
220
  appear: ""
221
221
  }, {
222
- default: C(() => [
223
- g.show ? (i(), c("div", {
222
+ default: E(() => [
223
+ u.show ? (r(), j("div", {
224
224
  key: 0,
225
225
  class: "jsgd-fixed jsgd-inset-0 jsgd-z-[10001] jsgd-flex jsgd-items-center jsgd-justify-center jsgd-p-4 jsgd-bg-black/60 jsgd-backdrop-blur-sm",
226
- onClick: O(m, ["self"])
226
+ onClick: G(b, ["self"])
227
227
  }, [
228
- P(B, {
228
+ P(D, {
229
229
  name: "jsgd-modal-container",
230
230
  appear: ""
231
231
  }, {
232
- default: C(() => [
233
- e("div", Se, [
234
- v[3] || (v[3] = e("div", { class: "jsgd-p-5 jsgd-border-b jsgd-border-slate-200 dark:jsgd-border-slate-700" }, [
232
+ default: E(() => [
233
+ e("div", Ie, [
234
+ p[3] || (p[3] = e("div", { class: "jsgd-p-5 jsgd-border-b jsgd-border-slate-200 dark:jsgd-border-slate-700" }, [
235
235
  e("h3", { class: "jsgd-text-lg jsgd-font-bold jsgd-text-slate-900 dark:jsgd-text-slate-100" }, " Edit Image Alt Text ")
236
236
  ], -1)),
237
- e("div", $e, [
237
+ e("div", Ae, [
238
238
  e("div", null, [
239
- v[1] || (v[1] = e("label", { class: "jsgd-block jsgd-text-sm jsgd-font-medium jsgd-mb-1 dark:jsgd-text-slate-300" }, "Alt Text", -1)),
240
- _(e("input", {
241
- "onUpdate:modelValue": v[0] || (v[0] = (p) => l.value = p),
239
+ p[1] || (p[1] = e("label", { class: "jsgd-block jsgd-text-sm jsgd-font-medium jsgd-mb-1 dark:jsgd-text-slate-300" }, "Alt Text", -1)),
240
+ V(e("input", {
241
+ "onUpdate:modelValue": p[0] || (p[0] = (f) => l.value = f),
242
242
  type: "text",
243
243
  placeholder: "Describe the image for accessibility",
244
244
  class: "jsgd-w-full jsgd-py-2 jsgd-px-3 jsgd-rounded-md jsgd-border jsgd-border-slate-300 dark:jsgd-bg-slate-700 dark:jsgd-border-slate-600 dark:jsgd-text-white",
245
- onKeydown: G(b, ["enter"])
245
+ onKeydown: K(v, ["enter"])
246
246
  }, null, 544), [
247
- [R, l.value]
247
+ [z, l.value]
248
248
  ]),
249
- v[2] || (v[2] = e("p", { class: "jsgd-text-xs jsgd-text-slate-500 jsgd-mt-2 dark:jsgd-text-slate-400" }, " Good alt text is descriptive and helps screen readers understand the image content. ", -1))
249
+ p[2] || (p[2] = e("p", { class: "jsgd-text-xs jsgd-text-slate-500 jsgd-mt-2 dark:jsgd-text-slate-400" }, " Good alt text is descriptive and helps screen readers understand the image content. ", -1))
250
250
  ])
251
251
  ]),
252
252
  e("div", { class: "jsgd-p-4 jsgd-bg-slate-50 jsgd-flex jsgd-justify-end jsgd-gap-3 dark:jsgd-bg-slate-900/50" }, [
253
253
  e("button", {
254
- onClick: m,
254
+ onClick: b,
255
255
  class: "jsgd-px-4 jsgd-py-2 jsgd-rounded-md jsgd-text-sm jsgd-font-medium jsgd-bg-white jsgd-border jsgd-border-slate-300 hover:jsgd-bg-slate-50 dark:jsgd-bg-slate-700 dark:jsgd-text-slate-200 dark:jsgd-border-slate-600 dark:hover:jsgd-bg-slate-600"
256
256
  }, " Cancel "),
257
257
  e("button", {
258
- onClick: b,
258
+ onClick: v,
259
259
  class: "jsgd-px-4 jsgd-py-2 jsgd-rounded-md jsgd-text-sm jsgd-font-medium jsgd-text-white jsgd-bg-blue-600 hover:jsgd-bg-blue-700 dark:jsgd-bg-blue-500 dark:hover:jsgd-bg-blue-600"
260
260
  }, " Save ")
261
261
  ])
@@ -263,31 +263,31 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
263
263
  ]),
264
264
  _: 1
265
265
  })
266
- ])) : f("", !0)
266
+ ])) : x("", !0)
267
267
  ]),
268
268
  _: 1
269
269
  }));
270
270
  }
271
- }), Ve = /* @__PURE__ */ H(Ie, [["__scopeId", "data-v-4b0d2e4a"]]), Ae = { class: "editor-header" }, Ce = ["for"], ze = ["id"], Ee = { class: "ql-formats" }, _e = {
271
+ }), Ee = /* @__PURE__ */ N(ze, [["__scopeId", "data-v-4b0d2e4a"]]), Re = { class: "editor-header" }, _e = ["for"], Be = ["id"], De = { class: "ql-formats" }, Pe = {
272
272
  key: 0,
273
273
  viewBox: "0 0 18 18",
274
274
  width: "18",
275
275
  height: "18"
276
- }, Re = {
276
+ }, Fe = {
277
277
  key: 1,
278
278
  viewBox: "0 0 18 18",
279
279
  width: "18",
280
280
  height: "18"
281
- }, De = { class: "editor-relative-container" }, Be = {
281
+ }, He = { class: "editor-relative-container" }, Qe = {
282
282
  key: 0,
283
283
  class: "upload-overlay"
284
- }, Pe = ["id"], Fe = {
284
+ }, Ne = ["id"], Oe = {
285
285
  key: 1,
286
286
  class: "error-message"
287
- }, Qe = /* @__PURE__ */ Q({
287
+ }, Ge = /* @__PURE__ */ Q({
288
288
  __name: "TextAreaQuill",
289
289
  props: {
290
- id: { default: () => ne() },
290
+ id: { default: () => ge() },
291
291
  label: {},
292
292
  placeholder: {},
293
293
  modelValue: {},
@@ -299,24 +299,28 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
299
299
  apiUploadVideo: {}
300
300
  },
301
301
  emits: ["update:modelValue", "push:error", "remove:error"],
302
- setup(g, { emit: S }) {
303
- const s = g, h = S;
302
+ setup(u, { emit: S }) {
303
+ const s = u, h = S;
304
304
  let l = null;
305
- const m = r(!1), b = r([]), k = r(!1), v = r(""), p = r(!1), u = r("link"), w = r(""), z = r("");
306
- let j = null;
307
- const U = r(!1), T = r(null), $ = r(""), x = ee("TableComponents", {
308
- labels: r(re[s.lang ?? "en"])
309
- }), d = M(
310
- () => s.placeholder ?? x.labels.value.placeholder?.quillEditor ?? "Write content here..."
311
- ), n = M(() => {
305
+ const b = n(!1), v = n([]), k = n(!1), p = n(""), f = n(!1), g = n("link"), w = n(""), R = n("");
306
+ let c = null;
307
+ const U = n(!1), T = n(null), $ = n(""), m = n(!1), d = n(""), i = le("TableComponents", {
308
+ labels: n(je[s.lang ?? "en"])
309
+ }), L = M(
310
+ () => s.placeholder ?? i.labels.value.placeholder?.quillEditor ?? "Write content here..."
311
+ ), O = M(() => {
312
312
  const a = [];
313
- return s.validate?.minLength && a.push(E("textMinLength", { min: String(s.validate.minLength) }, s.lang)), s.validate?.maxLength && a.push(E("textMaxLength", { max: String(s.validate.maxLength) }, s.lang)), a.join(", ");
314
- }), L = () => {
315
- m.value = !m.value;
313
+ return s.validate?.minLength && a.push(_("textMinLength", { min: String(s.validate.minLength) }, s.lang)), s.validate?.maxLength && a.push(_("textMaxLength", { max: String(s.validate.maxLength) }, s.lang)), a.join(", ");
314
+ }), W = () => {
315
+ b.value = !b.value;
316
316
  };
317
- V(m, (a) => {
317
+ I(b, (a) => {
318
318
  document.body.style.overflow = a ? "hidden" : "";
319
- }), V(
319
+ });
320
+ const Y = () => {
321
+ m.value = !m.value, m.value ? d.value = l?.root.innerHTML ?? s.modelValue ?? "" : l && (l.root.innerHTML = H.sanitize(d.value));
322
+ };
323
+ I(
320
324
  () => ({
321
325
  val: s.modelValue,
322
326
  disabled: s.disabled,
@@ -324,48 +328,48 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
324
328
  }),
325
329
  ({ val: a, disabled: t, validate: o }) => {
326
330
  if (t) {
327
- b.value = [], h("remove:error", s.id);
331
+ v.value = [], h("remove:error", s.id);
328
332
  return;
329
333
  }
330
334
  const y = String(a ?? "").replace(/<[^>]*>?/gm, "").trim(), q = [];
331
335
  o && (o.minLength && y.length < o.minLength && y.length !== 0 && q.push(
332
- E("textMinLength", { min: String(o.minLength) }, s.lang ?? "en")
336
+ _("textMinLength", { min: String(o.minLength) }, s.lang ?? "en")
333
337
  ), o.maxLength && y.length > o.maxLength && q.push(
334
- E("textMaxLength", { max: String(o.maxLength) }, s.lang ?? "en")
335
- )), b.value = q, q.length ? h("push:error", q, s.id) : h("remove:error", s.id);
338
+ _("textMaxLength", { max: String(o.maxLength) }, s.lang ?? "en")
339
+ )), v.value = q, q.length ? h("push:error", q, s.id) : h("remove:error", s.id);
336
340
  },
337
341
  { deep: !0, immediate: !0 }
338
342
  );
339
- const K = M(() => {
340
- if (u.value === "image") return s.apiUploadImage;
341
- if (u.value === "video") return s.apiUploadVideo;
342
- }), W = () => {
343
- u.value = "image", w.value = "", p.value = !0;
344
- }, Y = () => {
345
- u.value = "video", w.value = "", p.value = !0;
346
- }, J = (a) => {
347
- j = l?.getSelection(), j || (j = { index: l?.getSelection(!0)?.index || 0, length: 0 });
348
- const t = l?.getText(j.index, j.length) || "";
349
- z.value = t, w.value = typeof a == "string" ? a : "", u.value = "link", p.value = !0;
350
- }, X = (a) => {
343
+ const J = M(() => {
344
+ if (g.value === "image") return s.apiUploadImage;
345
+ if (g.value === "video") return s.apiUploadVideo;
346
+ }), X = () => {
347
+ g.value = "image", w.value = "", f.value = !0;
348
+ }, Z = () => {
349
+ g.value = "video", w.value = "", f.value = !0;
350
+ }, ee = (a) => {
351
+ c = l?.getSelection(), c || (c = { index: l?.getSelection(!0)?.index || 0, length: 0 });
352
+ const t = l?.getText(c.index, c.length) || "";
353
+ R.value = t, w.value = typeof a == "string" ? a : "", g.value = "link", f.value = !0;
354
+ }, te = (a) => {
351
355
  if (l) {
352
- if (p.value = !1, u.value === "link") {
353
- if (!j) return;
356
+ if (f.value = !1, g.value === "link") {
357
+ if (!c) return;
354
358
  const t = a.text || a.url;
355
- l.setSelection(j.index, j.length, "silent"), j.length > 0 && l.deleteText(j.index, j.length, "user"), l.insertText(j.index, t, "link", a.url, "user"), l.setSelection(j.index + t.length, 0, "user");
356
- } else if (u.value === "image") {
359
+ l.setSelection(c.index, c.length, "silent"), c.length > 0 && l.deleteText(c.index, c.length, "user"), l.insertText(c.index, t, "link", a.url, "user"), l.setSelection(c.index + t.length, 0, "user");
360
+ } else if (g.value === "image") {
357
361
  const t = l.getSelection(!0), o = a.alt?.replace(/"/g, "&quot;") || "", y = `<img src="${a.url}" alt="${o}" />`;
358
362
  l.clipboard.dangerouslyPasteHTML(t.index, y, "user"), l.setSelection(t.index + 1, 0);
359
- } else if (u.value === "video") {
363
+ } else if (g.value === "video") {
360
364
  const t = l.getSelection(!0);
361
365
  l.insertEmbed(t.index, "video", a.url, "user"), l.setSelection(t.index + 1, 0);
362
366
  }
363
- j = null;
367
+ c = null;
364
368
  }
365
- }, Z = (a) => {
369
+ }, se = (a) => {
366
370
  T.value && T.value.setAttribute("alt", a), U.value = !1, T.value = null;
367
371
  };
368
- return te(async () => {
372
+ return de(async () => {
369
373
  if (typeof window > "u") return;
370
374
  const a = document.getElementById(`editor-container-${s.id}`);
371
375
  if (!a) return;
@@ -379,11 +383,11 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
379
383
  l = new t(a, {
380
384
  theme: "snow",
381
385
  readOnly: s.disabled ?? !1,
382
- placeholder: d.value,
386
+ placeholder: L.value,
383
387
  modules: {
384
388
  toolbar: {
385
389
  container: `#toolbar-container-${s.id}`,
386
- handlers: { image: W, video: Y, link: J }
390
+ handlers: { image: X, video: Z, link: ee }
387
391
  },
388
392
  resize: {
389
393
  locale: {},
@@ -404,59 +408,59 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
404
408
  ]
405
409
  }
406
410
  }
407
- }), l.root.setAttribute("spellcheck", "true"), l.root.setAttribute("lang", s.lang === "id" ? "id" : "en"), s.modelValue && (l.root.innerHTML = N.sanitize(s.modelValue)), l.on("text-change", () => {
411
+ }), l.root.setAttribute("spellcheck", "true"), l.root.setAttribute("lang", s.lang === "id" ? "id" : "en"), s.modelValue && (l.root.innerHTML = H.sanitize(s.modelValue)), l.on("text-change", () => {
408
412
  const o = l.root.innerHTML;
409
- h("update:modelValue", N.sanitize(o), s.id);
413
+ h("update:modelValue", H.sanitize(o), s.id);
410
414
  });
411
- }), V(
415
+ }), I(
412
416
  () => s.disabled,
413
417
  (a) => l?.enable(!a)
414
- ), se(() => {
418
+ ), ae(() => {
415
419
  document.body.style.overflow = "";
416
- }), (a, t) => (i(), D(le, {
420
+ }), (a, t) => (r(), B(oe, {
417
421
  to: "body",
418
- disabled: !m.value
422
+ disabled: !b.value
419
423
  }, [
420
424
  e("div", {
421
- class: A(["rich-text-editor-wrapper", { "editor-maximized": m.value }])
425
+ class: A(["rich-text-editor-wrapper", { "editor-maximized": b.value }])
422
426
  }, [
423
- e("div", Ae, [
427
+ e("div", Re, [
424
428
  e("label", {
425
- for: g.id,
426
- class: A(["jsgd-inline-flex jsgd-items-center jsgd-gap-2 jsgd-text-sm jsgd-font-medium jsgd-mb-2 jsgd-text-slate-900 jsgd-transition-colors jsgd-duration-200 dark:jsgd-text-slate-100", { "jsgd-text-red-500 dark:jsgd-text-red-400": b.value }])
429
+ for: u.id,
430
+ class: A(["jsgd-inline-flex jsgd-items-center jsgd-gap-2 jsgd-text-sm jsgd-font-medium jsgd-mb-2 jsgd-text-slate-900 jsgd-transition-colors jsgd-duration-200 dark:jsgd-text-slate-100", { "jsgd-text-red-500 dark:jsgd-text-red-400": v.value }])
427
431
  }, [
428
- F(I(g.label) + " ", 1),
429
- n.value ? (i(), D(de(ie), {
432
+ F(C(u.label) + " ", 1),
433
+ O.value ? (r(), B(ne(ce), {
430
434
  key: 0,
431
- text: n.value,
435
+ text: O.value,
432
436
  as: "strong"
433
437
  }, {
434
- default: C(() => [...t[2] || (t[2] = [
438
+ default: E(() => [...t[3] || (t[3] = [
435
439
  F(" ❓", -1)
436
440
  ])]),
437
441
  _: 1
438
- }, 8, ["text"])) : f("", !0)
439
- ], 10, Ce)
442
+ }, 8, ["text"])) : x("", !0)
443
+ ], 10, _e)
440
444
  ]),
441
445
  e("div", {
442
- id: `toolbar-container-${g.id}`,
446
+ id: `toolbar-container-${u.id}`,
443
447
  class: "quill-toolbar"
444
448
  }, [
445
- t[5] || (t[5] = e("span", { class: "ql-formats" }, [
449
+ t[7] || (t[7] = e("span", { class: "ql-formats" }, [
446
450
  e("select", { class: "ql-font" }),
447
451
  e("select", { class: "ql-size" })
448
452
  ], -1)),
449
- t[6] || (t[6] = e("span", { class: "ql-formats" }, [
453
+ t[8] || (t[8] = e("span", { class: "ql-formats" }, [
450
454
  e("button", { class: "ql-bold" }),
451
455
  e("button", { class: "ql-italic" }),
452
456
  e("button", { class: "ql-underline" }),
453
457
  e("button", { class: "ql-strike" })
454
458
  ], -1)),
455
- t[7] || (t[7] = e("span", { class: "ql-formats" }, [
459
+ t[9] || (t[9] = e("span", { class: "ql-formats" }, [
456
460
  e("select", { class: "ql-color" }),
457
461
  e("select", { class: "ql-background" })
458
462
  ], -1)),
459
- t[8] || (t[8] = e("span", { class: "ql-formats" }, [
463
+ t[10] || (t[10] = e("span", { class: "ql-formats" }, [
460
464
  e("button", {
461
465
  class: "ql-header",
462
466
  value: "1"
@@ -468,7 +472,7 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
468
472
  e("button", { class: "ql-blockquote" }),
469
473
  e("button", { class: "ql-code-block" })
470
474
  ], -1)),
471
- t[9] || (t[9] = e("span", { class: "ql-formats" }, [
475
+ t[11] || (t[11] = e("span", { class: "ql-formats" }, [
472
476
  e("button", {
473
477
  class: "ql-list",
474
478
  value: "ordered"
@@ -486,26 +490,26 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
486
490
  value: "+1"
487
491
  })
488
492
  ], -1)),
489
- t[10] || (t[10] = e("span", { class: "ql-formats" }, [
493
+ t[12] || (t[12] = e("span", { class: "ql-formats" }, [
490
494
  e("button", {
491
495
  class: "ql-direction",
492
496
  value: "rtl"
493
497
  }),
494
498
  e("select", { class: "ql-align" })
495
499
  ], -1)),
496
- t[11] || (t[11] = e("span", { class: "ql-formats" }, [
500
+ t[13] || (t[13] = e("span", { class: "ql-formats" }, [
497
501
  e("button", { class: "ql-link" }),
498
502
  e("button", { class: "ql-image" }),
499
503
  F(),
500
504
  e("button", { class: "ql-video" })
501
505
  ], -1)),
502
- e("span", Ee, [
506
+ e("span", De, [
503
507
  e("button", {
504
- onClick: L,
508
+ onClick: W,
505
509
  class: "maximize-button",
506
510
  type: "button"
507
511
  }, [
508
- m.value ? (i(), c("svg", Re, [...t[4] || (t[4] = [
512
+ b.value ? (r(), j("svg", Fe, [...t[5] || (t[5] = [
509
513
  e("rect", {
510
514
  class: "ql-stroke",
511
515
  x: "5",
@@ -521,7 +525,7 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
521
525
  class: "ql-stroke",
522
526
  points: "3 15 8 10"
523
527
  }, null, -1)
524
- ])])) : (i(), c("svg", _e, [...t[3] || (t[3] = [
528
+ ])])) : (r(), j("svg", Pe, [...t[4] || (t[4] = [
525
529
  e("rect", {
526
530
  class: "ql-stroke",
527
531
  x: "3",
@@ -558,43 +562,76 @@ const ge = { class: "jsgd-w-full jsgd-max-w-md jsgd-bg-white jsgd-rounded-xl jsg
558
562
  height: "1"
559
563
  }, null, -1)
560
564
  ])]))
561
- ])
565
+ ]),
566
+ e("button", {
567
+ onClick: Y,
568
+ class: "code-view-button",
569
+ type: "button",
570
+ title: "Source"
571
+ }, [...t[6] || (t[6] = [
572
+ e("svg", {
573
+ viewBox: "0 0 18 18",
574
+ width: "18",
575
+ height: "18"
576
+ }, [
577
+ e("polyline", {
578
+ class: "ql-stroke",
579
+ points: "5 3 2 9 5 15"
580
+ }),
581
+ e("polyline", {
582
+ class: "ql-stroke",
583
+ points: "13 3 16 9 13 15"
584
+ })
585
+ ], -1)
586
+ ])])
562
587
  ])
563
- ], 8, ze),
564
- e("div", De, [
565
- k.value ? (i(), c("div", Be, [
566
- t[12] || (t[12] = e("div", { class: "spinner" }, null, -1)),
567
- e("p", null, "Uploading " + I(v.value) + "...", 1)
568
- ])) : f("", !0),
569
- e("div", {
570
- id: `editor-container-${g.id}`,
571
- class: A(["quill-editor-container", { "has-error": g.error }])
572
- }, null, 10, Pe)
588
+ ], 8, Be),
589
+ e("div", He, [
590
+ k.value ? (r(), j("div", Qe, [
591
+ t[14] || (t[14] = e("div", { class: "spinner" }, null, -1)),
592
+ e("p", null, "Uploading " + C(p.value) + "...", 1)
593
+ ])) : x("", !0),
594
+ V(e("div", null, [
595
+ e("div", {
596
+ id: `editor-container-${u.id}`,
597
+ class: A(["quill-editor-container", { "has-error": u.error }])
598
+ }, null, 10, Ne)
599
+ ], 512), [
600
+ [re, !m.value]
601
+ ]),
602
+ m.value ? V((r(), j("textarea", {
603
+ key: 1,
604
+ "onUpdate:modelValue": t[0] || (t[0] = (o) => d.value = o),
605
+ class: "code-view-editor",
606
+ spellcheck: "false"
607
+ }, null, 512)), [
608
+ [z, d.value]
609
+ ]) : x("", !0)
573
610
  ]),
574
- b.value.length !== 0 ? (i(!0), c(ae, { key: 0 }, oe(b.value, (o, y) => (i(), c("p", {
611
+ v.value.length !== 0 ? (r(!0), j(ie, { key: 0 }, ue(v.value, (o, y) => (r(), j("p", {
575
612
  key: y,
576
613
  class: "error-message"
577
- }, I(o), 1))), 128)) : f("", !0),
578
- typeof s.error == "string" && b.value.length === 0 ? (i(), c("p", Fe, I(g.error), 1)) : f("", !0),
579
- P(Me, {
580
- show: p.value,
581
- mode: u.value,
582
- "upload-url": K.value,
614
+ }, C(o), 1))), 128)) : x("", !0),
615
+ typeof s.error == "string" && v.value.length === 0 ? (r(), j("p", Oe, C(u.error), 1)) : x("", !0),
616
+ P(Ce, {
617
+ show: f.value,
618
+ mode: g.value,
619
+ "upload-url": J.value,
583
620
  "initial-value": w.value,
584
- "initial-text": z.value,
585
- onClose: t[0] || (t[0] = (o) => p.value = !1),
586
- onSubmit: X
621
+ "initial-text": R.value,
622
+ onClose: t[1] || (t[1] = (o) => f.value = !1),
623
+ onSubmit: te
587
624
  }, null, 8, ["show", "mode", "upload-url", "initial-value", "initial-text"]),
588
- P(Ve, {
625
+ P(Ee, {
589
626
  show: U.value,
590
627
  "initial-value": $.value,
591
- onClose: t[1] || (t[1] = (o) => U.value = !1),
592
- onSubmit: Z
628
+ onClose: t[2] || (t[2] = (o) => U.value = !1),
629
+ onSubmit: se
593
630
  }, null, 8, ["show", "initial-value"])
594
631
  ], 2)
595
632
  ], 8, ["disabled"]));
596
633
  }
597
- }), We = /* @__PURE__ */ H(Qe, [["__scopeId", "data-v-e017e37d"]]);
634
+ }), Ze = /* @__PURE__ */ N(Ge, [["__scopeId", "data-v-c98af8b6"]]);
598
635
  export {
599
- We as default
636
+ Ze as default
600
637
  };