lf-pagebuilder-vue 0.0.4 → 0.0.6

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,11 +1,12 @@
1
- import { defineComponent as H, ref as S, computed as Q, createElementBlock as i, openBlock as s, Fragment as B, createElementVNode as t, createCommentVNode as F, withModifiers as te, withDirectives as N, vModelText as K, normalizeClass as L, toDisplayString as v, renderList as V, vModelSelect as J, vModelCheckbox as se, createBlock as ie, createTextVNode as T, unref as G, onMounted as oe, createVNode as q, watch as ee, nextTick as be, withCtx as de, vShow as ge, reactive as fe } from "vue";
1
+ import { defineComponent as H, ref as S, computed as K, createElementBlock as r, openBlock as a, Fragment as B, createCommentVNode as P, createElementVNode as t, withModifiers as oe, withDirectives as R, vModelText as Y, normalizeClass as G, toDisplayString as p, renderList as V, vModelSelect as J, vModelCheckbox as te, createBlock as ie, createTextVNode as T, unref as q, onMounted as le, createVNode as L, watch as ee, nextTick as ge, withCtx as de, vShow as fe, reactive as pe } from "vue";
2
2
  import { listComponents as ve } from "libreria-astro-lefebvre";
3
- import { QuillEditor as pe } from "@vueup/vue-quill";
3
+ import { QuillEditor as xe } from "@vueup/vue-quill";
4
4
  import ue from "vuedraggable";
5
- const xe = H({
5
+ const he = H({
6
6
  props: {
7
7
  isComponentMode: Boolean,
8
8
  fullwidthMode: Boolean,
9
+ debugMode: Boolean,
9
10
  toggleComponentModeFunction: Function,
10
11
  toggleFullwidthMode: Function,
11
12
  importConfigurationFunction: Function,
@@ -19,6 +20,7 @@ const xe = H({
19
20
  emits: [
20
21
  "update:sectionSelected",
21
22
  "update:parametersPageConfiguration.global.sidebarEnabled",
23
+ "update:parametersPageConfiguration.global.renderAsBodyPart",
22
24
  "update:parametersPageConfiguration.global.headSlot",
23
25
  "update:parametersPageConfiguration.global.bodyBeginSlot",
24
26
  "update:parametersPageConfiguration.global.footerSlot",
@@ -27,37 +29,37 @@ const xe = H({
27
29
  "update:parametersPageConfiguration.seo.description"
28
30
  ],
29
31
  setup(e) {
30
- const o = e.renderApiDomain || "http://localhost:8003", g = S(""), x = S(!1), f = Q({
32
+ const o = e.renderApiDomain || "http://localhost:8003", g = S(""), h = S(!1), f = K({
31
33
  get() {
32
- var k, A;
34
+ var k, I;
33
35
  const m = (k = e.globalPageConfiguration) == null ? void 0 : k.find((w) => w.section === e.sectionSelected);
34
- return ((A = m == null ? void 0 : m.config) == null ? void 0 : A.width) || "";
36
+ return ((I = m == null ? void 0 : m.config) == null ? void 0 : I.width) || "";
35
37
  },
36
38
  set(m) {
37
- var A;
38
- const k = (A = e.globalPageConfiguration) == null ? void 0 : A.find((w) => w.section === e.sectionSelected);
39
+ var I;
40
+ const k = (I = e.globalPageConfiguration) == null ? void 0 : I.find((w) => w.section === e.sectionSelected);
39
41
  k && (k.config || (k.config = {}), k.config.width = m);
40
42
  }
41
- }), u = () => {
43
+ }), c = () => {
42
44
  const m = {
43
45
  pageConfig: e.globalPageConfiguration,
44
46
  paramsConfig: e.parametersPageConfiguration
45
- }, k = JSON.stringify(m), A = new CustomEvent("lf-pagebuilder:export", {
47
+ }, k = JSON.stringify(m), I = new CustomEvent("lf-pagebuilder:export", {
46
48
  detail: { ...m, inputId: e.inputId }
47
49
  });
48
- document.dispatchEvent(A);
50
+ document.dispatchEvent(I);
49
51
  const w = window.open("", "Preview", "width='100vw',height='100vh'");
50
52
  w && (w.document.body.innerText = k, w.document.close());
51
- }, r = () => {
53
+ }, n = () => {
52
54
  const m = {
53
55
  pageConfig: e.globalPageConfiguration,
54
56
  paramsConfig: e.parametersPageConfiguration
55
57
  }, k = JSON.stringify(m);
56
58
  b(k);
57
- const A = new CustomEvent("lf-pagebuilder:save", {
59
+ const I = new CustomEvent("lf-pagebuilder:save", {
58
60
  detail: { ...m, inputId: e.inputId }
59
61
  });
60
- if (document.dispatchEvent(A), e.inputId) {
62
+ if (document.dispatchEvent(I), e.inputId) {
61
63
  const w = document.getElementById(e.inputId);
62
64
  w && (w.value = k);
63
65
  }
@@ -77,28 +79,28 @@ const xe = H({
77
79
  "Content-Type": "application/json"
78
80
  },
79
81
  body: k
80
- }).then((A) => A.text()).then((A) => {
82
+ }).then((I) => I.text()).then((I) => {
81
83
  const w = window.open("", "Preview", "width='100vw',height='100vh'");
82
84
  if (!w) return;
83
- const c = new DOMParser().parseFromString(A, "text/html"), $ = [];
84
- function j(R, Y = 0) {
85
- if (!R || R.nodeType !== 1) return;
86
- const Z = R.tagName.toLowerCase();
87
- ["h1", "h2", "h3", "h4", "h5", "h6", "a", "p", "article", "section", "header", "footer"].includes(Z) && $.push({
85
+ const u = new DOMParser().parseFromString(I, "text/html"), C = [];
86
+ function j(N, X = 0) {
87
+ if (!N || N.nodeType !== 1) return;
88
+ const Z = N.tagName.toLowerCase();
89
+ ["h1", "h2", "h3", "h4", "h5", "h6", "a", "p", "article", "section", "header", "footer"].includes(Z) && C.push({
88
90
  tag: Z,
89
- text: (R.textContent || "").trim().slice(0, 80),
90
- depth: Y
91
- }), Array.from(R.children).forEach((_) => j(_, Y + 1));
91
+ text: (N.textContent || "").trim().slice(0, 80),
92
+ depth: X
93
+ }), Array.from(N.children).forEach((_) => j(_, X + 1));
92
94
  }
93
- j(c.body);
95
+ j(u.body);
94
96
  let D = '<h2>Estructura SEO</h2><ul style="font-family:monospace">';
95
- $.forEach((R) => {
96
- D += `<li style="margin-left:${R.depth * 20}px"><b>${R.tag}</b>: ${R.text}</li>`;
97
+ C.forEach((N) => {
98
+ D += `<li style="margin-left:${N.depth * 20}px"><b>${N.tag}</b>: ${N.text}</li>`;
97
99
  }), D += "</ul>", w.document.body.innerHTML = D, w.document.close();
98
100
  });
99
101
  },
100
102
  importConfig: g,
101
- showAdvancedConfig: x,
103
+ showAdvancedConfig: h,
102
104
  previewFunction: () => {
103
105
  const m = {
104
106
  pageConfig: e.globalPageConfiguration,
@@ -110,25 +112,25 @@ const xe = H({
110
112
  "Content-Type": "application/json"
111
113
  },
112
114
  body: k
113
- }).then((A) => A.text()).then((A) => {
115
+ }).then((I) => I.text()).then((I) => {
114
116
  const w = window.open("", "Preview", "width='100vw',height='100vh'");
115
- w && (w.document.body.innerHTML = A, w.document.querySelectorAll("script").forEach((c) => {
117
+ w && (w.document.body.innerHTML = I, w.document.querySelectorAll("script").forEach((u) => {
116
118
  var j;
117
- const $ = w.document.createElement("script");
118
- c.src ? $.src = c.src : $.textContent = c.textContent, (j = c.parentNode) == null || j.replaceChild($, c);
119
+ const C = w.document.createElement("script");
120
+ u.src ? C.src = u.src : C.textContent = u.textContent, (j = u.parentNode) == null || j.replaceChild(C, u);
119
121
  }), w.document.close());
120
122
  });
121
123
  },
122
124
  importFunction: () => {
123
125
  e.importConfigurationFunction && e.importConfigurationFunction(g.value), g.value = "";
124
126
  },
125
- exportFunction: u,
126
- saveButtonAction: r,
127
+ exportFunction: c,
128
+ saveButtonAction: n,
127
129
  loadFromLocalStorage: () => {
128
130
  const m = e.inputId ? `pageBuilderConfig_${e.inputId}` : "pageBuilderConfig", k = localStorage.getItem(m);
129
131
  if (k && e.importConfigurationFunction) {
130
- const A = JSON.parse(k);
131
- e.importConfigurationFunction(A);
132
+ const I = JSON.parse(k);
133
+ e.importConfigurationFunction(I);
132
134
  }
133
135
  },
134
136
  toggleExpandScreen: () => {
@@ -138,265 +140,282 @@ const xe = H({
138
140
  sectionWidth: f
139
141
  };
140
142
  }
141
- }), he = (e, o) => {
143
+ }), we = (e, o) => {
142
144
  const g = e.__vccOpts || e;
143
- for (const [x, f] of o)
144
- g[x] = f;
145
+ for (const [h, f] of o)
146
+ g[h] = f;
145
147
  return g;
146
- }, we = { class: "flex justify-end items-center w-full p-3 gap-3" }, ye = { class: "flex justify-between gap-3 px-5 py-3 bg-white mx-3 rounded-xl border border-slate-200 mb-6 sticky top-2 z-9999 shadow-lg backdrop-blur-sm" }, Ce = { class: "flex gap-2" }, $e = { class: "flex gap-2" }, ke = ["value"], Se = ["value"], Fe = { value: "full" }, Pe = { value: "1/2" }, je = { value: "1/3" }, Ie = { value: "2/3" }, Me = { value: "1/4" }, Ae = { value: "3/4" }, Be = { value: "1/5" }, Ee = { value: "2/5" }, Te = { value: "3/5" }, De = { value: "4/5" }, Oe = { key: 0 }, Ne = { key: 1 }, Re = { class: "flex items-center gap-2" }, Ve = {
148
+ }, ye = {
147
149
  key: 0,
150
+ class: "flex justify-end items-center w-full p-3 gap-3"
151
+ }, Ce = { class: "flex justify-between gap-3 px-5 py-3 bg-white mx-3 rounded-xl border border-slate-200 mb-6 sticky top-2 z-9999 shadow-lg backdrop-blur-sm" }, $e = { class: "flex gap-2" }, ke = { class: "flex gap-2" }, Se = ["value"], Pe = ["value"], Fe = { value: "full" }, je = { value: "1/2" }, Me = { value: "1/3" }, Ie = { value: "2/3" }, Ae = { value: "1/4" }, Be = { value: "3/4" }, Ee = { value: "1/5" }, Te = { value: "2/5" }, De = { value: "3/5" }, Oe = { value: "4/5" }, Re = { key: 0 }, Ne = { key: 1 }, Ve = { class: "flex items-center gap-2" }, Ue = {
152
+ key: 1,
148
153
  class: "bg-white border border-slate-200 rounded-2xl p-5 mx-3 mb-6 shadow-lg"
149
- }, Ue = { class: "flex flex-row gap-4 w-full" }, ze = { class: "border border-slate-200 rounded-xl p-5 w-full bg-gradient-to-br from-slate-50 to-white" }, qe = { class: "flex flex-col gap-3 border-b border-slate-200 pb-4 w-full" }, Le = { class: "mb-3" }, Ge = { class: "flex items-center gap-3 cursor-pointer group" }, Je = { class: "mb-3" }, He = { class: "mb-3" }, We = { class: "mb-3" }, Ke = { class: "border border-slate-200 rounded-xl p-5 w-full bg-gradient-to-br from-slate-50 to-white" }, Qe = { class: "flex justify-between items-center mb-4" }, Xe = { class: "flex flex-col gap-3 border-b border-slate-200 pb-4 w-full" }, Ye = { class: "mb-3" }, Ze = { class: "mb-3" }, _e = { class: "mb-3" };
150
- function et(e, o, g, x, f, u) {
151
- return s(), i(B, null, [
152
- t("div", we, [
153
- o[28] || (o[28] = t("span", { class: "bg-rose-50 px-3 py-1 rounded-full border border-rose-200 text-rose-400 text-xs font-medium me-4" }, "Todo lo de esta barra desaparecerá →", -1)),
154
+ }, ze = { class: "flex flex-row gap-4 w-full" }, qe = { class: "border border-slate-200 rounded-xl p-5 w-full bg-gradient-to-br from-slate-50 to-white" }, Le = { class: "flex flex-col gap-3 border-b border-slate-200 pb-4 w-full" }, Ge = { class: "mb-3" }, Je = { class: "flex items-center gap-3 cursor-pointer group" }, He = { class: "mb-3" }, We = { class: "flex items-center gap-3 cursor-pointer group" }, Ye = { class: "mb-3" }, Ke = { class: "mb-3" }, Qe = { class: "mb-3" }, Xe = { class: "border border-slate-200 rounded-xl p-5 w-full bg-gradient-to-br from-slate-50 to-white" }, Ze = { class: "flex justify-between items-center mb-4" }, _e = { class: "flex flex-col gap-3 border-b border-slate-200 pb-4 w-full" }, et = { class: "mb-3" }, tt = { class: "mb-3" }, ot = { class: "mb-3" };
155
+ function lt(e, o, g, h, f, c) {
156
+ return a(), r(B, null, [
157
+ e.debugMode ? (a(), r("div", ye, [
158
+ o[30] || (o[30] = t("span", { class: "bg-rose-50 px-3 py-1 rounded-full border border-rose-200 text-rose-400 text-xs font-medium me-4" }, "Todo lo de esta barra desaparecerá →", -1)),
154
159
  t("form", {
155
- onSubmit: o[2] || (o[2] = te(() => {
160
+ onSubmit: o[2] || (o[2] = oe(() => {
156
161
  }, ["prevent"])),
157
162
  class: "flex gap-2"
158
163
  }, [
159
- N(t("input", {
160
- "onUpdate:modelValue": o[0] || (o[0] = (r) => e.importConfig = r),
164
+ R(t("input", {
165
+ "onUpdate:modelValue": o[0] || (o[0] = (n) => e.importConfig = n),
161
166
  type: "text",
162
167
  class: "bg-white border border-slate-200 rounded-lg px-3 py-1.5 text-sm focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400",
163
168
  name: "",
164
169
  id: "",
165
170
  placeholder: "Pegar configuración..."
166
171
  }, null, 512), [
167
- [K, e.importConfig]
172
+ [Y, e.importConfig]
168
173
  ]),
169
174
  t("button", {
170
- onClick: o[1] || (o[1] = (r) => e.importFunction()),
175
+ onClick: o[1] || (o[1] = (n) => e.importFunction()),
171
176
  class: "cursor-pointer bg-white hover:bg-slate-700 hover:text-white border border-slate-200 hover:border-slate-700 rounded-lg px-3 py-1.5 text-sm font-medium transition-all duration-200 shadow-sm hover:shadow-md"
172
177
  }, "🏯 Importar")
173
178
  ], 32),
174
179
  t("button", {
175
- onClick: o[3] || (o[3] = (r) => e.exportFunction()),
180
+ onClick: o[3] || (o[3] = (n) => e.exportFunction()),
176
181
  class: "cursor-pointer bg-white hover:bg-slate-700 hover:text-white border border-slate-200 hover:border-slate-700 rounded-lg px-3 py-1.5 text-sm font-medium transition-all duration-200 shadow-sm hover:shadow-md"
177
182
  }, "🚀 Exportar")
178
- ]),
179
- t("div", ye, [
180
- t("div", Ce, [
183
+ ])) : P("", !0),
184
+ t("div", Ce, [
185
+ t("div", $e, [
181
186
  t("button", {
182
- class: L([[e.isComponentMode ? "bg-gradient-to-r from-slate-600 to-slate-700 border-slate-700 text-white shadow-md" : "bg-white hover:bg-slate-100"], "cursor-pointer border border-slate-200 rounded-lg py-1.5 px-3 text-sm font-medium transition-all duration-200"]),
183
- onClick: o[4] || (o[4] = (r) => {
187
+ class: G([[e.isComponentMode ? "bg-gradient-to-r from-slate-600 to-slate-700 border-slate-700 text-white shadow-md" : "bg-white hover:bg-slate-100"], "cursor-pointer border border-slate-200 rounded-lg py-1.5 px-3 text-sm font-medium transition-all duration-200"]),
188
+ onClick: o[4] || (o[4] = (n) => {
184
189
  var b;
185
190
  return (b = e.toggleComponentModeFunction) == null ? void 0 : b.call(e);
186
191
  })
187
- }, v(e.isComponentMode ? "⚒️ Modo Configuración" : "👁️ Modo Visual"), 3),
192
+ }, p(e.isComponentMode ? "⚒️ Modo Configuración" : "👁️ Modo Visual"), 3),
188
193
  t("button", {
189
- class: L([[e.fullwidthMode ? "bg-white hover:bg-slate-100" : "bg-gradient-to-r from-slate-600 to-slate-700 border-slate-700 text-white shadow-md"], "cursor-pointer border border-slate-200 rounded-lg py-1.5 px-3 text-sm font-medium transition-all duration-200"]),
190
- onClick: o[5] || (o[5] = (r) => {
194
+ class: G([[e.fullwidthMode ? "bg-white hover:bg-slate-100" : "bg-gradient-to-r from-slate-600 to-slate-700 border-slate-700 text-white shadow-md"], "cursor-pointer border border-slate-200 rounded-lg py-1.5 px-3 text-sm font-medium transition-all duration-200"]),
195
+ onClick: o[5] || (o[5] = (n) => {
191
196
  var b;
192
197
  return (b = e.toggleFullwidthMode) == null ? void 0 : b.call(e);
193
198
  })
194
- }, v(e.fullwidthMode ? "⚒️ Comps. Plegados" : "👁️ Comps. Desplegados"), 3)
199
+ }, p(e.fullwidthMode ? "⚒️ Comps. Plegados" : "👁️ Comps. Desplegados"), 3)
195
200
  ]),
196
- t("div", $e, [
201
+ t("div", ke, [
197
202
  t("select", {
198
203
  value: e.sectionSelected,
199
- onChange: o[6] || (o[6] = (r) => e.$emit("update:sectionSelected", r.target.value)),
204
+ onChange: o[6] || (o[6] = (n) => e.$emit("update:sectionSelected", n.target.value)),
200
205
  class: "bg-white border border-slate-200 rounded-lg px-3 py-1.5 cursor-pointer text-sm focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 transition-colors"
201
206
  }, [
202
- (s(!0), i(B, null, V(e.availableSections, (r, b) => (s(), i("option", {
207
+ (a(!0), r(B, null, V(e.availableSections, (n, b) => (a(), r("option", {
203
208
  key: b,
204
- value: r
205
- }, v(r), 9, Se))), 128))
206
- ], 40, ke),
207
- N(t("select", {
209
+ value: n
210
+ }, p(n), 9, Pe))), 128))
211
+ ], 40, Se),
212
+ R(t("select", {
208
213
  class: "bg-white border border-slate-200 rounded-lg px-3 py-1.5 cursor-pointer text-sm focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 transition-colors",
209
- "onUpdate:modelValue": o[7] || (o[7] = (r) => e.sectionWidth = r)
214
+ "onUpdate:modelValue": o[7] || (o[7] = (n) => e.sectionWidth = n)
210
215
  }, [
211
- o[29] || (o[29] = t("option", {
216
+ o[31] || (o[31] = t("option", {
212
217
  disabled: "",
213
218
  value: ""
214
219
  }, "Selecciona el ancho de la sección", -1)),
215
- t("option", Fe, "Sección " + v(e.sectionSelected) + " ocupa todo el ancho de la página", 1),
216
- t("option", Pe, "Sección " + v(e.sectionSelected) + " ocupa 1/2 del ancho de la página", 1),
217
- t("option", je, "Sección " + v(e.sectionSelected) + " ocupa 1/3 del ancho de la página", 1),
218
- t("option", Ie, "Sección " + v(e.sectionSelected) + " ocupa 2/3 del ancho de la página", 1),
219
- t("option", Me, "Sección " + v(e.sectionSelected) + " ocupa 1/4 del ancho de la página", 1),
220
- t("option", Ae, "Sección " + v(e.sectionSelected) + " ocupa 3/4 del ancho de la página", 1),
221
- t("option", Be, "Sección " + v(e.sectionSelected) + " ocupa 1/5 del ancho de la página", 1),
222
- t("option", Ee, "Sección " + v(e.sectionSelected) + " ocupa 2/5 del ancho de la página", 1),
223
- t("option", Te, "Sección " + v(e.sectionSelected) + " ocupa 3/5 del ancho de la página", 1),
224
- t("option", De, "Sección " + v(e.sectionSelected) + " ocupa 4/5 del ancho de la página", 1)
220
+ t("option", Fe, "Sección " + p(e.sectionSelected) + " ocupa todo el ancho de la página", 1),
221
+ t("option", je, "Sección " + p(e.sectionSelected) + " ocupa 1/2 del ancho de la página", 1),
222
+ t("option", Me, "Sección " + p(e.sectionSelected) + " ocupa 1/3 del ancho de la página", 1),
223
+ t("option", Ie, "Sección " + p(e.sectionSelected) + " ocupa 2/3 del ancho de la página", 1),
224
+ t("option", Ae, "Sección " + p(e.sectionSelected) + " ocupa 1/4 del ancho de la página", 1),
225
+ t("option", Be, "Sección " + p(e.sectionSelected) + " ocupa 3/4 del ancho de la página", 1),
226
+ t("option", Ee, "Sección " + p(e.sectionSelected) + " ocupa 1/5 del ancho de la página", 1),
227
+ t("option", Te, "Sección " + p(e.sectionSelected) + " ocupa 2/5 del ancho de la página", 1),
228
+ t("option", De, "Sección " + p(e.sectionSelected) + " ocupa 3/5 del ancho de la página", 1),
229
+ t("option", Oe, "Sección " + p(e.sectionSelected) + " ocupa 4/5 del ancho de la página", 1)
225
230
  ], 512), [
226
231
  [J, e.sectionWidth]
227
232
  ]),
228
233
  t("button", {
229
- class: L([
234
+ class: G([
230
235
  "cursor-pointer border rounded-lg py-1.5 px-3 text-sm font-medium transition-all duration-200 flex items-center gap-2",
231
236
  e.showAdvancedConfig ? "bg-gradient-to-r from-amber-500 to-orange-500 border-amber-500 text-white shadow-md" : "bg-white border-slate-200 hover:bg-slate-100"
232
237
  ]),
233
- onClick: o[8] || (o[8] = (r) => e.showAdvancedConfig = !e.showAdvancedConfig)
238
+ onClick: o[8] || (o[8] = (n) => e.showAdvancedConfig = !e.showAdvancedConfig)
234
239
  }, [
235
- o[30] || (o[30] = t("span", null, "⚙️ Página", -1)),
236
- e.showAdvancedConfig ? (s(), i("span", Oe, "▲")) : (s(), i("span", Ne, "▼"))
240
+ o[32] || (o[32] = t("span", null, "⚙️ Página", -1)),
241
+ e.showAdvancedConfig ? (a(), r("span", Re, "▲")) : (a(), r("span", Ne, "▼"))
237
242
  ], 2)
238
243
  ]),
239
- t("div", Re, [
244
+ t("div", Ve, [
240
245
  t("button", {
241
- onClick: o[9] || (o[9] = (r) => e.previewFunction()),
246
+ onClick: o[9] || (o[9] = (n) => e.previewFunction()),
242
247
  class: "cursor-pointer bg-white hover:bg-violet-500 hover:text-white hover:border-violet-500 border border-slate-200 rounded-lg px-3 py-1.5 text-sm font-medium transition-all duration-200 shadow-sm hover:shadow-md"
243
248
  }, "🔎 Preview"),
244
249
  t("button", {
245
- onClick: o[10] || (o[10] = (r) => e.saveButtonAction()),
250
+ onClick: o[10] || (o[10] = (n) => e.saveButtonAction()),
246
251
  title: "No es un guardado real, simplemente almacena la configuración en el navegador para recuperarla luego",
247
252
  class: "cursor-pointer bg-gradient-to-r from-emerald-500 to-teal-500 hover:from-emerald-600 hover:to-teal-600 text-white border border-emerald-500 rounded-lg px-3 py-1.5 text-sm font-medium transition-all duration-200 shadow-sm hover:shadow-md"
248
253
  }, "💾 Guardar"),
249
- t("button", {
250
- onClick: o[11] || (o[11] = (r) => e.loadFromLocalStorage()),
254
+ e.debugMode ? (a(), r("button", {
255
+ key: 0,
256
+ onClick: o[11] || (o[11] = (n) => e.loadFromLocalStorage()),
251
257
  class: "cursor-pointer bg-white hover:bg-blue-500 hover:text-white hover:border-blue-500 border border-slate-200 rounded-lg px-3 py-1.5 text-sm font-medium transition-all duration-200 shadow-sm hover:shadow-md"
252
- }, "⤵️ Cargar"),
258
+ }, "⤵️ Cargar")) : P("", !0),
253
259
  t("button", {
254
- onClick: o[12] || (o[12] = (r) => e.toggleExpandScreen()),
260
+ onClick: o[12] || (o[12] = (n) => e.toggleExpandScreen()),
255
261
  title: "Expandir / Contraer Pagebuilder",
256
262
  class: "cursor-pointer bg-white hover:bg-slate-700 hover:text-white hover:border-slate-700 border border-slate-200 rounded-lg px-3 py-1.5 text-xl transition-all duration-200 shadow-sm hover:shadow-md ms-2"
257
263
  }, "◳")
258
264
  ])
259
265
  ]),
260
- e.showAdvancedConfig && e.parametersPageConfiguration ? (s(), i("div", Ve, [
261
- t("div", Ue, [
262
- t("div", ze, [
263
- o[35] || (o[35] = t("h2", { class: "text-lg font-bold mb-4 text-slate-700" }, "Configuración Avanzada", -1)),
264
- o[36] || (o[36] = t("h3", { class: "font-semibold mb-3 text-slate-600" }, "Configuración Global", -1)),
265
- t("div", qe, [
266
- t("div", Le, [
267
- t("label", Ge, [
268
- N(t("input", {
266
+ e.showAdvancedConfig && e.parametersPageConfiguration ? (a(), r("div", Ue, [
267
+ t("div", ze, [
268
+ t("div", qe, [
269
+ o[38] || (o[38] = t("h2", { class: "text-lg font-bold mb-4 text-slate-700" }, "Configuración Avanzada", -1)),
270
+ o[39] || (o[39] = t("h3", { class: "font-semibold mb-3 text-slate-600" }, "Configuración Global", -1)),
271
+ t("div", Le, [
272
+ t("div", Ge, [
273
+ t("label", Je, [
274
+ R(t("input", {
275
+ type: "checkbox",
276
+ "onUpdate:modelValue": o[13] || (o[13] = (n) => e.parametersPageConfiguration.global.sidebarEnabled = n),
277
+ onChange: o[14] || (o[14] = (n) => e.$emit("update:parametersPageConfiguration.global.sidebarEnabled", n.target.value)),
278
+ class: "w-5 h-5 rounded border-slate-300 text-emerald-500 focus:ring-emerald-500 cursor-pointer"
279
+ }, null, 544), [
280
+ [te, e.parametersPageConfiguration.global.sidebarEnabled]
281
+ ]),
282
+ o[33] || (o[33] = t("span", { class: "text-slate-600 group-hover:text-slate-800 transition-colors" }, "Sidebar Habilitado", -1))
283
+ ])
284
+ ]),
285
+ t("div", He, [
286
+ t("label", We, [
287
+ R(t("input", {
269
288
  type: "checkbox",
270
- "onUpdate:modelValue": o[13] || (o[13] = (r) => e.parametersPageConfiguration.global.sidebarEnabled = r),
271
- onChange: o[14] || (o[14] = (r) => e.$emit("update:parametersPageConfiguration.global.sidebarEnabled", r.target.value)),
289
+ "onUpdate:modelValue": o[15] || (o[15] = (n) => e.parametersPageConfiguration.global.renderAsBodyPart = n),
290
+ onChange: o[16] || (o[16] = (n) => e.$emit("update:parametersPageConfiguration.global.renderAsBodyPart", n.target.value)),
272
291
  class: "w-5 h-5 rounded border-slate-300 text-emerald-500 focus:ring-emerald-500 cursor-pointer"
273
292
  }, null, 544), [
274
- [se, e.parametersPageConfiguration.global.sidebarEnabled]
293
+ [te, e.parametersPageConfiguration.global.renderAsBodyPart]
275
294
  ]),
276
- o[31] || (o[31] = t("span", { class: "text-slate-600 group-hover:text-slate-800 transition-colors" }, "Sidebar Habilitado", -1))
295
+ o[34] || (o[34] = t("span", { class: "text-slate-600 group-hover:text-slate-800 transition-colors" }, "Renderizar como parte del BODY (Sin etiquetas HTML, HEAD, BODY)", -1))
277
296
  ])
278
297
  ]),
279
- t("div", Je, [
280
- o[32] || (o[32] = t("label", {
298
+ t("div", Ye, [
299
+ o[35] || (o[35] = t("label", {
281
300
  for: "headSlot",
282
301
  class: "block text-sm font-medium text-slate-600 mb-2"
283
302
  }, " Código al final de la sección <head> ", -1)),
284
- N(t("textarea", {
303
+ R(t("textarea", {
285
304
  id: "headSlot",
286
- "onUpdate:modelValue": o[15] || (o[15] = (r) => e.parametersPageConfiguration.global.headSlot = r),
287
- onInput: o[16] || (o[16] = (r) => e.$emit("update:parametersPageConfiguration.global.headSlot", r.target.value)),
305
+ "onUpdate:modelValue": o[17] || (o[17] = (n) => e.parametersPageConfiguration.global.headSlot = n),
306
+ onInput: o[18] || (o[18] = (n) => e.$emit("update:parametersPageConfiguration.global.headSlot", n.target.value)),
288
307
  class: "w-full px-4 py-3 border border-slate-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-white text-sm font-mono transition-colors",
289
308
  placeholder: "Contenido para el head",
290
309
  rows: "3"
291
310
  }, null, 544), [
292
- [K, e.parametersPageConfiguration.global.headSlot]
311
+ [Y, e.parametersPageConfiguration.global.headSlot]
293
312
  ])
294
313
  ]),
295
- t("div", He, [
296
- o[33] || (o[33] = t("label", {
314
+ t("div", Ke, [
315
+ o[36] || (o[36] = t("label", {
297
316
  for: "bodyBeginSlot",
298
317
  class: "block text-sm font-medium text-slate-600 mb-2"
299
318
  }, " Código al principio de la sección <body> ", -1)),
300
- N(t("textarea", {
319
+ R(t("textarea", {
301
320
  id: "bodyBeginSlot",
302
- "onUpdate:modelValue": o[17] || (o[17] = (r) => e.parametersPageConfiguration.global.bodyBeginSlot = r),
303
- onInput: o[18] || (o[18] = (r) => e.$emit("update:parametersPageConfiguration.global.bodyBeginSlot", r.target.value)),
321
+ "onUpdate:modelValue": o[19] || (o[19] = (n) => e.parametersPageConfiguration.global.bodyBeginSlot = n),
322
+ onInput: o[20] || (o[20] = (n) => e.$emit("update:parametersPageConfiguration.global.bodyBeginSlot", n.target.value)),
304
323
  class: "w-full px-4 py-3 border border-slate-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-white text-sm font-mono transition-colors",
305
324
  placeholder: "Contenido para el inicio del body",
306
325
  rows: "3"
307
326
  }, null, 544), [
308
- [K, e.parametersPageConfiguration.global.bodyBeginSlot]
327
+ [Y, e.parametersPageConfiguration.global.bodyBeginSlot]
309
328
  ])
310
329
  ]),
311
- t("div", We, [
312
- o[34] || (o[34] = t("label", {
330
+ t("div", Qe, [
331
+ o[37] || (o[37] = t("label", {
313
332
  for: "footerSlot",
314
333
  class: "block text-sm font-medium text-slate-600 mb-2"
315
334
  }, " Código al final de la sección <body>, dentro de la etiqueta <footer> ", -1)),
316
- N(t("textarea", {
335
+ R(t("textarea", {
317
336
  id: "footerSlot",
318
- "onUpdate:modelValue": o[19] || (o[19] = (r) => e.parametersPageConfiguration.global.footerSlot = r),
319
- onInput: o[20] || (o[20] = (r) => e.$emit("update:parametersPageConfiguration.global.footerSlot", r.target.value)),
337
+ "onUpdate:modelValue": o[21] || (o[21] = (n) => e.parametersPageConfiguration.global.footerSlot = n),
338
+ onInput: o[22] || (o[22] = (n) => e.$emit("update:parametersPageConfiguration.global.footerSlot", n.target.value)),
320
339
  class: "w-full px-4 py-3 border border-slate-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-white text-sm font-mono transition-colors",
321
340
  placeholder: "Contenido para el footer",
322
341
  rows: "3"
323
342
  }, null, 544), [
324
- [K, e.parametersPageConfiguration.global.footerSlot]
343
+ [Y, e.parametersPageConfiguration.global.footerSlot]
325
344
  ])
326
345
  ])
327
346
  ])
328
347
  ]),
329
- t("div", Ke, [
330
- t("div", Qe, [
331
- o[37] || (o[37] = t("h2", { class: "text-lg font-bold text-slate-700" }, "Configuración SEO", -1)),
348
+ t("div", Xe, [
349
+ t("div", Ze, [
350
+ o[40] || (o[40] = t("h2", { class: "text-lg font-bold text-slate-700" }, "Configuración SEO", -1)),
332
351
  t("button", {
333
- onClick: o[21] || (o[21] = (r) => e.validateSeo()),
352
+ onClick: o[23] || (o[23] = (n) => e.validateSeo()),
334
353
  class: "cursor-pointer bg-gradient-to-r from-violet-500 to-purple-500 hover:from-violet-600 hover:to-purple-600 text-white border border-violet-500 rounded-lg px-4 py-1.5 text-sm font-medium transition-all duration-200 shadow-sm hover:shadow-md"
335
354
  }, "🦄 Validar SEO")
336
355
  ]),
337
- t("div", Xe, [
338
- t("div", Ye, [
339
- o[39] || (o[39] = t("label", {
356
+ t("div", _e, [
357
+ t("div", et, [
358
+ o[42] || (o[42] = t("label", {
340
359
  for: "robotsIndex",
341
360
  class: "block text-sm font-medium text-slate-600 mb-2"
342
361
  }, " Indexación de robots ", -1)),
343
- N(t("select", {
362
+ R(t("select", {
344
363
  id: "robotsIndex",
345
- "onUpdate:modelValue": o[22] || (o[22] = (r) => e.parametersPageConfiguration.seo.robots = r),
346
- onChange: o[23] || (o[23] = (r) => e.$emit("update:parametersPageConfiguration.seo.robots", r.target.value)),
364
+ "onUpdate:modelValue": o[24] || (o[24] = (n) => e.parametersPageConfiguration.seo.robots = n),
365
+ onChange: o[25] || (o[25] = (n) => e.$emit("update:parametersPageConfiguration.seo.robots", n.target.value)),
347
366
  class: "w-full px-4 py-2.5 border border-slate-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-white text-sm transition-colors cursor-pointer"
348
- }, [...o[38] || (o[38] = [
367
+ }, [...o[41] || (o[41] = [
349
368
  t("option", { value: "index, follow" }, "Index Follow", -1),
350
369
  t("option", { value: "noindex, nofollow" }, "Noindex Nofollow", -1)
351
370
  ])], 544), [
352
371
  [J, e.parametersPageConfiguration.seo.robots]
353
372
  ])
354
373
  ]),
355
- t("div", Ze, [
356
- o[40] || (o[40] = t("label", {
374
+ t("div", tt, [
375
+ o[43] || (o[43] = t("label", {
357
376
  for: "pageTitle",
358
377
  class: "block text-sm font-medium text-slate-600 mb-2"
359
378
  }, " Título de la página ", -1)),
360
- N(t("input", {
379
+ R(t("input", {
361
380
  id: "pageTitle",
362
381
  type: "text",
363
- "onUpdate:modelValue": o[24] || (o[24] = (r) => e.parametersPageConfiguration.seo.title = r),
364
- onInput: o[25] || (o[25] = (r) => e.$emit("update:parametersPageConfiguration.seo.title", r.target.value)),
382
+ "onUpdate:modelValue": o[26] || (o[26] = (n) => e.parametersPageConfiguration.seo.title = n),
383
+ onInput: o[27] || (o[27] = (n) => e.$emit("update:parametersPageConfiguration.seo.title", n.target.value)),
365
384
  class: "w-full px-4 py-2.5 border border-slate-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-white text-sm transition-colors",
366
385
  placeholder: "Ingresa el título de la página"
367
386
  }, null, 544), [
368
- [K, e.parametersPageConfiguration.seo.title]
387
+ [Y, e.parametersPageConfiguration.seo.title]
369
388
  ])
370
389
  ]),
371
- t("div", _e, [
372
- o[41] || (o[41] = t("label", {
390
+ t("div", ot, [
391
+ o[44] || (o[44] = t("label", {
373
392
  for: "pageDescription",
374
393
  class: "block text-sm font-medium text-slate-600 mb-2"
375
394
  }, " Descripción de la página ", -1)),
376
- N(t("textarea", {
395
+ R(t("textarea", {
377
396
  id: "pageDescription",
378
- "onUpdate:modelValue": o[26] || (o[26] = (r) => e.parametersPageConfiguration.seo.description = r),
379
- onInput: o[27] || (o[27] = (r) => e.$emit("update:parametersPageConfiguration.seo.description", r.target.value)),
397
+ "onUpdate:modelValue": o[28] || (o[28] = (n) => e.parametersPageConfiguration.seo.description = n),
398
+ onInput: o[29] || (o[29] = (n) => e.$emit("update:parametersPageConfiguration.seo.description", n.target.value)),
380
399
  class: "w-full px-4 py-3 border border-slate-200 rounded-lg focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-white text-sm transition-colors",
381
400
  placeholder: "Ingresa la descripción de la página",
382
401
  rows: "3"
383
402
  }, null, 544), [
384
- [K, e.parametersPageConfiguration.seo.description]
403
+ [Y, e.parametersPageConfiguration.seo.description]
385
404
  ])
386
405
  ])
387
406
  ])
388
407
  ])
389
408
  ])
390
- ])) : F("", !0)
409
+ ])) : P("", !0)
391
410
  ], 64);
392
411
  }
393
- const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
412
+ const nt = /* @__PURE__ */ we(he, [["render", lt]]), at = {
394
413
  key: 0,
395
414
  class: "absolute top-0 left-0 bg-white/90 w-full h-full z-100"
396
- }, lt = { class: "w-full flex justify-end p-4" }, nt = ["for"], at = {
415
+ }, rt = { class: "w-full flex justify-end p-4" }, st = ["for"], it = {
397
416
  key: 0,
398
417
  class: "text-red-500"
399
- }, rt = ["id", "name", "placeholder", "required", "value", "onInput"], st = ["id", "name", "data-mandatoryCrops", "placeholder", "required", "value", "onInput"], it = ["id", "name", "required", "value", "onInput"], dt = ["value"], ut = ["id", "name", "required", "checked", "onChange"], ae = /* @__PURE__ */ H({
418
+ }, dt = ["id", "name", "placeholder", "required", "value", "onInput"], ut = ["id", "name", "data-mandatoryCrops", "placeholder", "required", "value", "onInput"], ct = ["id", "name", "required", "value", "onInput"], mt = ["value"], bt = ["id", "name", "required", "checked", "onChange"], re = /* @__PURE__ */ H({
400
419
  __name: "FieldsForm",
401
420
  props: {
402
421
  object: {
@@ -413,111 +432,111 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
413
432
  }
414
433
  },
415
434
  setup(e) {
416
- const o = e, g = (x, f) => {
417
- const u = (o.object.fields || []).find((r) => r.name === x);
418
- u && (u.example_value = f);
435
+ const o = e, g = (h, f) => {
436
+ const c = (o.object.fields || []).find((n) => n.name === h);
437
+ c && (c.example_value = f);
419
438
  };
420
- return (x, f) => (s(), i(B, null, [
421
- e.showForm ? (s(), i("div", ot)) : F("", !0),
439
+ return (h, f) => (a(), r(B, null, [
440
+ e.showForm ? (a(), r("div", at)) : P("", !0),
422
441
  t("div", {
423
- class: L(e.showForm ? "relative top-0 w-full text-slate-600 border-1 my-2 px-4 pt-2 pb-3 w-full border-slate-200 bg-slate-50 inline-block rounded-lg flex flex-col z-101" : "hidden")
442
+ class: G(e.showForm ? "relative top-0 w-full text-slate-600 border-1 my-2 px-4 pt-2 pb-3 w-full border-slate-200 bg-slate-50 inline-block rounded-lg flex flex-col z-101" : "hidden")
424
443
  }, [
425
- t("div", lt, [
444
+ t("div", rt, [
426
445
  t("span", {
427
446
  onClick: f[0] || (f[0] = //@ts-ignore
428
- (...u) => e.toggleShowForm && e.toggleShowForm(...u)),
447
+ (...c) => e.toggleShowForm && e.toggleShowForm(...c)),
429
448
  class: "cursor-pointer hover:scale-125 transition-all duration-300"
430
449
  }, "❌")
431
450
  ]),
432
451
  t("form", null, [
433
- (s(!0), i(B, null, V(e.object.fields, (u, r) => (s(), i("div", {
434
- key: r,
452
+ (a(!0), r(B, null, V(e.object.fields, (c, n) => (a(), r("div", {
453
+ key: n,
435
454
  class: "mb-4"
436
455
  }, [
437
456
  t("label", {
438
- for: `${e.object.id}-${u.name}-${r}`,
457
+ for: `${e.object.id}-${c.name}-${n}`,
439
458
  class: "block text-sm font-medium mb-1"
440
459
  }, [
441
- T(v(u.label) + " ", 1),
442
- u.mandatory ? (s(), i("span", at, "*")) : F("", !0)
443
- ], 8, nt),
444
- u.type === "text" ? (s(), i("input", {
460
+ T(p(c.label) + " ", 1),
461
+ c.mandatory ? (a(), r("span", it, "*")) : P("", !0)
462
+ ], 8, st),
463
+ c.type === "text" ? (a(), r("input", {
445
464
  key: 0,
446
- id: `${e.object.id}-${u.name}-${r}`,
447
- name: `${e.object.id}-${u.name}-${r}`,
465
+ id: `${e.object.id}-${c.name}-${n}`,
466
+ name: `${e.object.id}-${c.name}-${n}`,
448
467
  type: "text",
449
468
  class: "w-full px-3 py-2 border border-slate-300 rounded focus:outline-none focus:ring-2 focus:ring-blue-400",
450
- placeholder: u.label,
451
- required: u.mandatory,
452
- value: u.example_value,
453
- onInput: (b) => g(u.name, b.target.value)
454
- }, null, 40, rt)) : F("", !0),
455
- u.type === "image" ? (s(), i("input", {
469
+ placeholder: c.label,
470
+ required: c.mandatory,
471
+ value: c.example_value,
472
+ onInput: (b) => g(c.name, b.target.value)
473
+ }, null, 40, dt)) : P("", !0),
474
+ c.type === "image" ? (a(), r("input", {
456
475
  key: 1,
457
- id: `${e.object.id}-${u.name}-${r}`,
458
- name: `${e.object.id}-${u.name}-${r}`,
459
- "data-mandatoryCrops": u.image_cuts ? JSON.stringify(u.image_cuts) : null,
476
+ id: `${e.object.id}-${c.name}-${n}`,
477
+ name: `${e.object.id}-${c.name}-${n}`,
478
+ "data-mandatoryCrops": c.image_cuts ? JSON.stringify(c.image_cuts) : null,
460
479
  type: "text",
461
480
  class: "js-limbo w-full px-3 py-2 border border-slate-300 rounded focus:outline-none focus:ring-2 focus:ring-blue-400",
462
- placeholder: u.label,
463
- required: u.mandatory,
464
- value: u.example_value,
465
- onInput: (b) => g(u.name, b.target.value)
466
- }, null, 40, st)) : u.type === "textArea" ? (s(), ie(G(pe), {
481
+ placeholder: c.label,
482
+ required: c.mandatory,
483
+ value: c.example_value,
484
+ onInput: (b) => g(c.name, b.target.value)
485
+ }, null, 40, ut)) : c.type === "textArea" ? (a(), ie(q(xe), {
467
486
  key: 2,
468
487
  theme: "snow",
469
- id: `${e.object.id}-${u.name}-${r}`,
470
- name: `${e.object.id}-${u.name}-${r}`,
488
+ id: `${e.object.id}-${c.name}-${n}`,
489
+ name: `${e.object.id}-${c.name}-${n}`,
471
490
  rows: "3",
472
491
  class: "w-full px-3 py-2 border border-slate-300 rounded focus:outline-none focus:ring-2 focus:ring-blue-400 z-9999",
473
- placeholder: u.label,
474
- required: u.mandatory,
492
+ placeholder: c.label,
493
+ required: c.mandatory,
475
494
  "onUpdate:content": (b) => {
476
- g(u.name, b);
495
+ g(c.name, b);
477
496
  },
478
- content: u.example_value,
479
- modelValue: u.example_value,
480
- "onUpdate:modelValue": (b) => u.example_value = b,
497
+ content: c.example_value,
498
+ modelValue: c.example_value,
499
+ "onUpdate:modelValue": (b) => c.example_value = b,
481
500
  contentType: "html"
482
- }, null, 8, ["id", "name", "placeholder", "required", "onUpdate:content", "content", "modelValue", "onUpdate:modelValue"])) : u.type === "select" ? (s(), i("select", {
501
+ }, null, 8, ["id", "name", "placeholder", "required", "onUpdate:content", "content", "modelValue", "onUpdate:modelValue"])) : c.type === "select" ? (a(), r("select", {
483
502
  key: 3,
484
- id: `${e.object.id}-${u.name}-${r}`,
485
- name: `${e.object.id}-${u.name}-${r}`,
503
+ id: `${e.object.id}-${c.name}-${n}`,
504
+ name: `${e.object.id}-${c.name}-${n}`,
486
505
  class: "w-full px-3 py-2 border border-slate-300 rounded focus:outline-none focus:ring-2 focus:ring-blue-400",
487
- required: u.mandatory,
488
- value: u.example_value,
489
- onInput: (b) => g(u.name, b.target.value)
506
+ required: c.mandatory,
507
+ value: c.example_value,
508
+ onInput: (b) => g(c.name, b.target.value)
490
509
  }, [
491
510
  f[1] || (f[1] = t("option", {
492
511
  disabled: "",
493
512
  value: ""
494
513
  }, "Seleccione una opción", -1)),
495
- (s(!0), i(B, null, V(u.options || [], (b, C) => (s(), i("option", {
496
- key: C,
514
+ (a(!0), r(B, null, V(c.options || [], (b, $) => (a(), r("option", {
515
+ key: $,
497
516
  value: b
498
- }, v(b), 9, dt))), 128))
499
- ], 40, it)) : u.type === "boolean" ? (s(), i("input", {
517
+ }, p(b), 9, mt))), 128))
518
+ ], 40, ct)) : c.type === "boolean" ? (a(), r("input", {
500
519
  key: 4,
501
- id: `${e.object.id}-${u.name}-${r}`,
502
- name: `${e.object.id}-${u.name}-${r}`,
520
+ id: `${e.object.id}-${c.name}-${n}`,
521
+ name: `${e.object.id}-${c.name}-${n}`,
503
522
  type: "checkbox",
504
523
  class: "h-4 w-4 text-blue-600 focus:ring-blue-500 border-slate-300 rounded inline-block",
505
- required: u.mandatory,
506
- checked: u.example_value,
507
- onChange: (b) => g(u.name, b.target.checked)
508
- }, null, 40, ut)) : F("", !0)
524
+ required: c.mandatory,
525
+ checked: c.example_value,
526
+ onChange: (b) => g(c.name, b.target.checked)
527
+ }, null, 40, bt)) : P("", !0)
509
528
  ]))), 128))
510
529
  ])
511
530
  ], 2)
512
531
  ], 64));
513
532
  }
514
- }), ct = { class: "space-y-4" }, mt = ["disabled"], bt = ["value"], gt = { class: "space-y-3" }, ft = {
533
+ }), gt = { class: "space-y-4" }, ft = ["disabled"], pt = ["value"], vt = { class: "space-y-3" }, xt = {
515
534
  key: 0,
516
535
  class: "overflow-y-auto space-y-3"
517
- }, vt = { class: "block text-sm font-semibold text-slate-600 mb-2" }, pt = ["onChange", "disabled"], xt = ["value"], ht = ["onChange", "disabled"], wt = ["onInput", "disabled", "placeholder"], yt = ["disabled"], Ct = {
536
+ }, ht = { class: "block text-sm font-semibold text-slate-600 mb-2" }, wt = ["onChange", "disabled"], yt = ["value"], Ct = ["onChange", "disabled"], $t = ["onInput", "disabled", "placeholder"], kt = ["disabled"], St = {
518
537
  key: 0,
519
538
  class: "animate-spin"
520
- }, $t = { key: 1 }, kt = /* @__PURE__ */ H({
539
+ }, Pt = { key: 1 }, Ft = /* @__PURE__ */ H({
521
540
  __name: "SourceFilter",
522
541
  props: {
523
542
  onSubmit: {
@@ -534,13 +553,13 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
534
553
  }
535
554
  },
536
555
  setup(e) {
537
- const o = e, g = S(!1), x = S(null), f = S({}), u = Q(() => {
538
- const a = o.isProduction;
556
+ const o = e, g = S(!1), h = S(null), f = S({}), c = K(() => {
557
+ const s = o.isProduction;
539
558
  return [
540
559
  {
541
560
  id: "origen1",
542
561
  name: "El Derecho",
543
- apiUrl: a ? "https://elderecho.com/feed" : "https://led-dev-elderecho-dev.eu.els.local/feed",
562
+ apiUrl: s ? "https://elderecho.com/feed" : "https://led-dev-elderecho-dev.eu.els.local/feed",
544
563
  filters: [
545
564
  { id: "title", label: "Título del Post", type: "text" },
546
565
  { id: "category", label: "Slug de la Categoría", type: "text" },
@@ -554,7 +573,7 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
554
573
  {
555
574
  id: "origen2",
556
575
  name: "Formación",
557
- apiUrl: a ? "https://lefebvre.es/formacion/feed" : "http://led-dev-lefebvre-dev.eu.els.local/formacion/feed",
576
+ apiUrl: s ? "https://lefebvre.es/formacion/feed" : "http://led-dev-lefebvre-dev.eu.els.local/formacion/feed",
558
577
  filters: [
559
578
  { id: "id", label: "ID del curso", type: "text" },
560
579
  { id: "title", label: "Título del Post", type: "text" },
@@ -566,41 +585,41 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
566
585
  {
567
586
  id: "origen3",
568
587
  name: "Derecholocal",
569
- apiUrl: a ? "https://derecholocal.es/feed" : "https://led-dev-derecholocal-dev.eu.els.local/feed",
588
+ apiUrl: s ? "https://derecholocal.es/feed" : "https://led-dev-derecholocal-dev.eu.els.local/feed",
570
589
  filters: []
571
590
  },
572
591
  {
573
592
  id: "origen4",
574
593
  name: "EspacioAsesoría",
575
- apiUrl: a ? "https://espacioasesoria.com/feed" : "https://led-dev-espacioasesoria-dev.eu.els.local/feed",
594
+ apiUrl: s ? "https://espacioasesoria.com/feed" : "https://led-dev-espacioasesoria-dev.eu.els.local/feed",
576
595
  filters: []
577
596
  },
578
597
  {
579
598
  id: "origen5",
580
599
  name: "EspacioPymes",
581
- apiUrl: a ? "https://espaciopymes.com/feed" : "https://led-dev-espaciopymes-dev.eu.els.local/feed",
600
+ apiUrl: s ? "https://espaciopymes.com/feed" : "https://led-dev-espaciopymes-dev.eu.els.local/feed",
582
601
  filters: []
583
602
  }
584
603
  ];
585
- }), r = Q(() => {
586
- if (!x.value)
604
+ }), n = K(() => {
605
+ if (!h.value)
587
606
  return [];
588
- const a = u.value.find((l) => l.id === x.value);
589
- return a ? a.filters : [];
590
- }), b = (a, l) => {
591
- f.value[a] = l;
592
- }, C = () => {
607
+ const s = c.value.find((l) => l.id === h.value);
608
+ return s ? s.filters : [];
609
+ }), b = (s, l) => {
610
+ f.value[s] = l;
611
+ }, $ = () => {
593
612
  f.value = {};
594
- }, I = async () => {
613
+ }, M = async () => {
595
614
  g.value = !0;
596
- const a = u.value.find((n) => n.id === x.value);
597
- if (!a) {
615
+ const s = c.value.find((i) => i.id === h.value);
616
+ if (!s) {
598
617
  console.error("Origen no encontrado"), g.value = !1;
599
618
  return;
600
619
  }
601
- const l = new URL(a.apiUrl);
602
- Object.keys(f.value).forEach((n) => {
603
- f.value[n] && l.searchParams.append(n, f.value[n]);
620
+ const l = new URL(s.apiUrl);
621
+ Object.keys(f.value).forEach((i) => {
622
+ f.value[i] && l.searchParams.append(i, f.value[i]);
604
623
  });
605
624
  try {
606
625
  const m = await (await fetch(l.toString(), {
@@ -608,110 +627,110 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
608
627
  headers: {
609
628
  Accept: "text/xml, application/xml"
610
629
  }
611
- })).text(), A = new DOMParser().parseFromString(m, "text/xml"), w = Array.from(A.querySelectorAll("item")).map((d) => {
612
- const c = {};
613
- return Array.from(d.children).forEach(($) => {
614
- $.children.length > 0 ? Array.from($.children).forEach((j) => {
615
- const D = `${$.nodeName}_${j.nodeName}`;
616
- c[D] = j.textContent || "";
617
- }) : c[$.nodeName] = $.textContent || "";
618
- }), c;
630
+ })).text(), I = new DOMParser().parseFromString(m, "text/xml"), w = Array.from(I.querySelectorAll("item")).map((d) => {
631
+ const u = {};
632
+ return Array.from(d.children).forEach((C) => {
633
+ C.children.length > 0 ? Array.from(C.children).forEach((j) => {
634
+ const D = `${C.nodeName}_${j.nodeName}`;
635
+ u[D] = j.textContent || "";
636
+ }) : u[C.nodeName] = C.textContent || "";
637
+ }), u;
619
638
  });
620
639
  o.onSubmit(w);
621
- } catch (n) {
622
- console.error("Error al aplicar filtros:", n), o.onSubmit([]);
640
+ } catch (i) {
641
+ console.error("Error al aplicar filtros:", i), o.onSubmit([]);
623
642
  } finally {
624
- const n = {
625
- name: a.name,
643
+ const i = {
644
+ name: s.name,
626
645
  url: l.toString()
627
646
  };
628
- o.updateFeedCriteria(n), g.value = !1;
647
+ o.updateFeedCriteria(i), g.value = !1;
629
648
  }
630
649
  };
631
- return (a, l) => (s(), i("div", ct, [
650
+ return (s, l) => (a(), r("div", gt, [
632
651
  t("div", null, [
633
652
  l[1] || (l[1] = t("label", { class: "block text-sm font-semibold text-slate-600 mb-2" }, "Seleccionar origen:", -1)),
634
- N(t("select", {
635
- "onUpdate:modelValue": l[0] || (l[0] = (n) => x.value = n),
653
+ R(t("select", {
654
+ "onUpdate:modelValue": l[0] || (l[0] = (i) => h.value = i),
636
655
  class: "w-full px-3 py-2.5 bg-white border border-slate-200 rounded-lg shadow-sm focus:border-emerald-400 focus:ring-2 focus:ring-emerald-500/20 transition-all duration-200 disabled:bg-slate-100 disabled:cursor-not-allowed cursor-pointer",
637
- onChange: C,
656
+ onChange: $,
638
657
  disabled: g.value
639
658
  }, [
640
- (s(!0), i(B, null, V(u.value, (n) => (s(), i("option", {
641
- key: n.id,
642
- value: n.id
643
- }, v(n.name), 9, bt))), 128))
644
- ], 40, mt), [
645
- [J, x.value]
659
+ (a(!0), r(B, null, V(c.value, (i) => (a(), r("option", {
660
+ key: i.id,
661
+ value: i.id
662
+ }, p(i.name), 9, pt))), 128))
663
+ ], 40, ft), [
664
+ [J, h.value]
646
665
  ])
647
666
  ]),
648
- t("div", gt, [
649
- r.value.length > 0 ? (s(), i("div", ft, [
650
- (s(!0), i(B, null, V(r.value, (n) => (s(), i("div", {
651
- key: n.id,
667
+ t("div", vt, [
668
+ n.value.length > 0 ? (a(), r("div", xt, [
669
+ (a(!0), r(B, null, V(n.value, (i) => (a(), r("div", {
670
+ key: i.id,
652
671
  class: "bg-gradient-to-br from-slate-50 to-white p-4 rounded-xl border border-slate-200"
653
672
  }, [
654
- t("label", vt, v(n.label) + ":", 1),
655
- n.type === "select" ? (s(), i("select", {
673
+ t("label", ht, p(i.label) + ":", 1),
674
+ i.type === "select" ? (a(), r("select", {
656
675
  key: 0,
657
676
  class: "w-full px-3 py-2.5 bg-white border border-slate-200 rounded-lg shadow-sm focus:border-emerald-400 focus:ring-2 focus:ring-emerald-500/20 transition-all duration-200 disabled:bg-slate-100 disabled:cursor-not-allowed cursor-pointer",
658
- onChange: (m) => b(n.id, m.target.value),
677
+ onChange: (m) => b(i.id, m.target.value),
659
678
  disabled: g.value
660
679
  }, [
661
680
  l[2] || (l[2] = t("option", { value: "" }, "Seleccionar...", -1)),
662
- (s(!0), i(B, null, V(n.options, (m) => (s(), i("option", {
681
+ (a(!0), r(B, null, V(i.options, (m) => (a(), r("option", {
663
682
  key: m,
664
683
  value: m
665
- }, v(m), 9, xt))), 128))
666
- ], 40, pt)) : n.type === "date" ? (s(), i("input", {
684
+ }, p(m), 9, yt))), 128))
685
+ ], 40, wt)) : i.type === "date" ? (a(), r("input", {
667
686
  key: 1,
668
687
  type: "date",
669
688
  class: "w-full px-3 py-2.5 bg-white border border-slate-200 rounded-lg shadow-sm focus:border-emerald-400 focus:ring-2 focus:ring-emerald-500/20 transition-all duration-200 disabled:bg-slate-100 disabled:cursor-not-allowed",
670
- onChange: (m) => b(n.id, m.target.value),
689
+ onChange: (m) => b(i.id, m.target.value),
671
690
  disabled: g.value
672
- }, null, 40, ht)) : n.type === "text" ? (s(), i("input", {
691
+ }, null, 40, Ct)) : i.type === "text" ? (a(), r("input", {
673
692
  key: 2,
674
693
  type: "text",
675
694
  class: "w-full px-3 py-2.5 bg-white border border-slate-200 rounded-lg shadow-sm focus:border-emerald-400 focus:ring-2 focus:ring-emerald-500/20 transition-all duration-200 disabled:bg-slate-100 disabled:cursor-not-allowed",
676
- onInput: (m) => b(n.id, m.target.value),
695
+ onInput: (m) => b(i.id, m.target.value),
677
696
  disabled: g.value,
678
- placeholder: n.label
679
- }, null, 40, wt)) : F("", !0)
697
+ placeholder: i.label
698
+ }, null, 40, $t)) : P("", !0)
680
699
  ]))), 128))
681
- ])) : F("", !0),
700
+ ])) : P("", !0),
682
701
  t("button", {
683
- onClick: I,
702
+ onClick: M,
684
703
  class: "cursor-pointer w-full bg-gradient-to-r from-emerald-500 to-teal-500 text-white font-semibold px-4 py-3 rounded-xl shadow-md hover:from-emerald-600 hover:to-teal-600 hover:shadow-lg transform hover:-translate-y-0.5 transition-all duration-200 disabled:from-slate-300 disabled:to-slate-400 disabled:cursor-not-allowed disabled:transform-none disabled:shadow-none flex items-center justify-center gap-2",
685
704
  disabled: g.value
686
705
  }, [
687
- g.value ? (s(), i("span", Ct, "⏳")) : (s(), i("span", $t, "🔍")),
688
- T(" " + v(g.value ? "Conectando con el feed..." : "Aplicar Filtros"), 1)
689
- ], 8, yt)
706
+ g.value ? (a(), r("span", St, "⏳")) : (a(), r("span", Pt, "🔍")),
707
+ T(" " + p(g.value ? "Conectando con el feed..." : "Aplicar Filtros"), 1)
708
+ ], 8, kt)
690
709
  ])
691
710
  ]));
692
711
  }
693
- }), St = { class: "fixed top-0 left-0 w-full h-full bg-gradient-to-br from-slate-50 via-white to-slate-100 flex flex-col z-9999 p-6" }, Ft = { class: "w-full flex justify-between items-center mb-4" }, Pt = { class: "w-full flex-1 bg-white/60 rounded-2xl flex gap-5 p-5 overflow-hidden backdrop-blur-sm border border-slate-200 shadow-inner" }, jt = { class: "flex-1 flex flex-col gap-5" }, It = { class: "flex flex-col bg-white rounded-2xl shadow-lg border border-slate-200 p-5 overflow-y-auto" }, Mt = {
712
+ }), jt = { class: "fixed top-0 left-0 w-full h-full bg-gradient-to-br from-slate-50 via-white to-slate-100 flex flex-col z-9999 p-6" }, Mt = { class: "w-full flex justify-between items-center mb-4" }, It = { class: "w-full flex-1 bg-white/60 rounded-2xl flex gap-5 p-5 overflow-hidden backdrop-blur-sm border border-slate-200 shadow-inner" }, At = { class: "flex-1 flex flex-col gap-5" }, Bt = { class: "flex flex-col bg-white rounded-2xl shadow-lg border border-slate-200 p-5 overflow-y-auto" }, Et = {
694
713
  key: 0,
695
714
  class: "mb-4 p-4 bg-gradient-to-br from-emerald-50 to-teal-50 rounded-xl border border-emerald-200 w-full flex-shrink-0 text-sm font-medium text-emerald-700"
696
- }, At = { class: "list-none mt-3 space-y-2 text-slate-600" }, Bt = { class: "flex items-start gap-2" }, Et = { class: "font-semibold text-slate-700" }, Tt = { class: "flex items-start gap-2" }, Dt = { class: "font-semibold text-slate-700" }, Ot = { class: "font-semibold text-slate-700" }, Nt = { class: "flex items-start gap-2" }, Rt = { class: "flex flex-wrap gap-2 mt-1" }, Vt = { class: "font-semibold text-slate-700" }, Ut = { class: "text-emerald-600" }, zt = { class: "flex flex-col gap-4 w-full" }, qt = { class: "flex items-center gap-3 cursor-pointer group" }, Lt = {
715
+ }, Tt = { class: "list-none mt-3 space-y-2 text-slate-600" }, Dt = { class: "flex items-start gap-2" }, Ot = { class: "font-semibold text-slate-700" }, Rt = { class: "flex items-start gap-2" }, Nt = { class: "font-semibold text-slate-700" }, Vt = { class: "font-semibold text-slate-700" }, Ut = { class: "flex items-start gap-2" }, zt = { class: "flex flex-wrap gap-2 mt-1" }, qt = { class: "font-semibold text-slate-700" }, Lt = { class: "text-emerald-600" }, Gt = { class: "flex flex-col gap-4 w-full" }, Jt = { class: "flex items-center gap-3 cursor-pointer group" }, Ht = {
697
716
  key: 0,
698
717
  class: "flex flex-col gap-4 ml-8 p-4 bg-gradient-to-br from-slate-50 to-white rounded-xl border border-slate-200"
699
- }, Gt = { class: "flex flex-col gap-2" }, Jt = { class: "flex flex-col gap-2" }, Ht = { class: "flex-1 flex flex-col bg-white rounded-2xl shadow-lg border border-slate-200 p-5 overflow-y-auto" }, Wt = { class: "flex-1 flex flex-col bg-white rounded-2xl shadow-lg border border-slate-200 p-5 overflow-y-auto" }, Kt = {
718
+ }, Wt = { class: "flex flex-col gap-2" }, Yt = { class: "flex flex-col gap-2" }, Kt = { class: "flex-1 flex flex-col bg-white rounded-2xl shadow-lg border border-slate-200 p-5 overflow-y-auto" }, Qt = { class: "flex-1 flex flex-col bg-white rounded-2xl shadow-lg border border-slate-200 p-5 overflow-y-auto" }, Xt = {
700
719
  key: 0,
701
720
  class: "flex-1 flex flex-col items-center justify-center text-slate-400"
702
- }, Qt = {
721
+ }, Zt = {
703
722
  key: 1,
704
723
  class: "space-y-3"
705
- }, Xt = ["onClick"], Yt = { class: "font-bold text-slate-800 mb-2" }, Zt = { class: "text-sm text-slate-600 line-clamp-2" }, _t = { class: "flex-1 flex flex-col bg-white rounded-2xl shadow-lg border border-slate-200 p-5 overflow-y-auto" }, eo = {
724
+ }, _t = ["onClick"], eo = { class: "font-bold text-slate-800 mb-2" }, to = { class: "text-sm text-slate-600 line-clamp-2" }, oo = { class: "flex-1 flex flex-col bg-white rounded-2xl shadow-lg border border-slate-200 p-5 overflow-y-auto" }, lo = {
706
725
  key: 0,
707
726
  class: "flex-1 flex flex-col items-center justify-center text-slate-400"
708
- }, to = {
727
+ }, no = {
709
728
  key: 1,
710
729
  class: "space-y-3"
711
- }, oo = { class: "block text-sm font-bold text-slate-700 mb-2 flex items-center gap-2" }, lo = ["onUpdate:modelValue"], no = ["value"], ao = {
730
+ }, ao = { class: "block text-sm font-bold text-slate-700 mb-2 flex items-center gap-2" }, ro = ["onUpdate:modelValue"], so = ["value"], io = {
712
731
  key: 0,
713
732
  class: "mt-3 p-3 bg-gradient-to-br from-emerald-50 to-teal-50 rounded-lg border border-emerald-200"
714
- }, ro = { class: "mt-1 text-sm font-medium text-slate-700 break-words" }, so = /* @__PURE__ */ H({
733
+ }, uo = { class: "mt-1 text-sm font-medium text-slate-700 break-words" }, co = /* @__PURE__ */ H({
715
734
  __name: "FeedComponent",
716
735
  props: {
717
736
  object: {
@@ -732,69 +751,69 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
732
751
  }
733
752
  },
734
753
  setup(e) {
735
- const o = e, g = S(null), x = S(null), f = S(!1), u = S(1), r = S("horizontal"), b = S({}), C = S(null), I = (w) => {
754
+ const o = e, g = S(null), h = S(null), f = S(!1), c = S(1), n = S("horizontal"), b = S({}), $ = S(null), M = (w) => {
736
755
  g.value = w;
737
- }, a = (w) => {
738
- x.value = w;
756
+ }, s = (w) => {
757
+ h.value = w;
739
758
  }, l = () => {
740
759
  const w = o.object.fields.filter((d) => d.mappedTo).map((d) => {
741
- var c;
760
+ var u;
742
761
  return {
743
762
  fieldName: d.name,
744
763
  mappedTo: d.mappedTo,
745
- value: ((c = x.value) == null ? void 0 : c[d.mappedTo]) ?? null
764
+ value: ((u = h.value) == null ? void 0 : u[d.mappedTo]) ?? null
746
765
  };
747
766
  });
748
- C.value = {
767
+ $.value = {
749
768
  ...b.value,
750
769
  dynamicUpdate: f.value,
751
- elementCount: u.value,
752
- orientation: r.value,
753
- mapping: w.map(({ fieldName: d, mappedTo: c }) => ({ fieldName: d, mappedTo: c }))
754
- }, o.updateObjectByFeedContent && o.updateObjectByFeedContent(w, C.value), o.toggleFeedSection();
755
- }, n = (w) => {
770
+ elementCount: c.value,
771
+ orientation: n.value,
772
+ mapping: w.map(({ fieldName: d, mappedTo: u }) => ({ fieldName: d, mappedTo: u }))
773
+ }, o.updateObjectByFeedContent && o.updateObjectByFeedContent(w, $.value), o.toggleFeedSection();
774
+ }, i = (w) => {
756
775
  b.value = w;
757
776
  }, m = () => {
758
777
  var w;
759
- (w = o.object) != null && w.repeat_data && (C.value = o.object.repeat_data, f.value = o.object.repeat_data.dynamicUpdate || !1, u.value = o.object.repeat_data.elementCount || 1, r.value = o.object.repeat_data.orientation || "horizontal", b.value = {
778
+ (w = o.object) != null && w.repeat_data && ($.value = o.object.repeat_data, f.value = o.object.repeat_data.dynamicUpdate || !1, c.value = o.object.repeat_data.elementCount || 1, n.value = o.object.repeat_data.orientation || "horizontal", b.value = {
760
779
  name: o.object.repeat_data.name,
761
780
  url: o.object.repeat_data.url
762
781
  });
763
782
  }, k = () => {
764
- C.value = null, f.value = !1, u.value = 1, r.value = "horizontal", b.value = {}, o.updateObjectByFeedContent && o.updateObjectByFeedContent([], null);
765
- }, A = () => {
783
+ $.value = null, f.value = !1, c.value = 1, n.value = "horizontal", b.value = {}, o.updateObjectByFeedContent && o.updateObjectByFeedContent([], null);
784
+ }, I = () => {
766
785
  var w;
767
- C.value && (C.value = {
768
- ...C.value,
786
+ $.value && ($.value = {
787
+ ...$.value,
769
788
  dynamicUpdate: f.value,
770
- elementCount: u.value,
771
- orientation: r.value
772
- }, o.updateObjectByFeedContent && o.updateObjectByFeedContent(((w = C.value.mapping) == null ? void 0 : w.map((d) => ({
789
+ elementCount: c.value,
790
+ orientation: n.value
791
+ }, o.updateObjectByFeedContent && o.updateObjectByFeedContent(((w = $.value.mapping) == null ? void 0 : w.map((d) => ({
773
792
  fieldName: d.fieldName,
774
793
  mappedTo: d.mappedTo,
775
794
  value: null
776
- }))) || [], C.value));
795
+ }))) || [], $.value));
777
796
  };
778
- return oe(() => {
797
+ return le(() => {
779
798
  m();
780
- }), (w, d) => (s(), i("div", St, [
781
- t("div", Ft, [
799
+ }), (w, d) => (a(), r("div", jt, [
800
+ t("div", Mt, [
782
801
  d[5] || (d[5] = t("h2", { class: "text-2xl font-bold bg-gradient-to-r from-slate-700 to-slate-500 bg-clip-text text-transparent flex items-center gap-3" }, [
783
802
  t("span", { class: "text-3xl" }, "🍺"),
784
803
  T(" Configuración de Feed ")
785
804
  ], -1)),
786
805
  t("button", {
787
806
  onClick: d[0] || (d[0] = //@ts-ignore
788
- (...c) => e.toggleFeedSection && e.toggleFeedSection(...c)),
807
+ (...u) => e.toggleFeedSection && e.toggleFeedSection(...u)),
789
808
  class: "cursor-pointer group w-10 h-10 flex items-center justify-center bg-white hover:bg-red-50 border border-red-200 hover:border-red-400 text-red-400 hover:text-red-600 rounded-full font-semibold shadow-sm hover:shadow-lg transition-all duration-200"
790
809
  }, [...d[4] || (d[4] = [
791
810
  t("span", { class: "text-lg" }, "✕", -1)
792
811
  ])])
793
812
  ]),
794
- t("div", Pt, [
795
- t("div", jt, [
796
- t("div", It, [
797
- C.value && C.value.dynamicUpdate ? (s(), i("div", Mt, [
813
+ t("div", It, [
814
+ t("div", At, [
815
+ t("div", Bt, [
816
+ $.value && $.value.dynamicUpdate ? (a(), r("div", Et, [
798
817
  t("div", { class: "flex justify-between items-start" }, [
799
818
  d[8] || (d[8] = t("p", { class: "flex items-center gap-2" }, [
800
819
  t("span", { class: "text-emerald-500" }, "✓"),
@@ -802,7 +821,7 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
802
821
  ], -1)),
803
822
  t("div", { class: "flex items-center gap-2" }, [
804
823
  t("button", {
805
- onClick: A,
824
+ onClick: I,
806
825
  class: "cursor-pointer px-3 py-1.5 bg-white hover:bg-emerald-50 text-emerald-500 hover:text-emerald-600 border border-emerald-200 hover:border-emerald-300 rounded-lg text-xs font-semibold transition-all duration-200 flex items-center gap-1 shadow-sm"
807
826
  }, [...d[6] || (d[6] = [
808
827
  t("span", null, "💾", -1),
@@ -817,70 +836,70 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
817
836
  ])])
818
837
  ])
819
838
  ]),
820
- t("ul", At, [
821
- t("li", Bt, [
839
+ t("ul", Tt, [
840
+ t("li", Dt, [
822
841
  d[9] || (d[9] = t("span", { class: "text-emerald-400" }, "→", -1)),
823
842
  d[10] || (d[10] = T(" Conectar con ", -1)),
824
- t("span", Et, v(C.value.name), 1)
843
+ t("span", Ot, p($.value.name), 1)
825
844
  ]),
826
- t("li", Tt, [
845
+ t("li", Rt, [
827
846
  d[11] || (d[11] = t("span", { class: "text-emerald-400" }, "→", -1)),
828
847
  d[12] || (d[12] = T(" Recuperar ", -1)),
829
- t("span", Dt, v(C.value.elementCount), 1),
848
+ t("span", Nt, p($.value.elementCount), 1),
830
849
  d[13] || (d[13] = T(" items (", -1)),
831
- t("span", Ot, v(C.value.orientation), 1),
850
+ t("span", Vt, p($.value.orientation), 1),
832
851
  d[14] || (d[14] = T(")", -1))
833
852
  ]),
834
- t("li", Nt, [
853
+ t("li", Ut, [
835
854
  d[17] || (d[17] = t("span", { class: "text-emerald-400" }, "→", -1)),
836
855
  t("div", null, [
837
856
  d[16] || (d[16] = T(" Mapeo: ", -1)),
838
- t("div", Rt, [
839
- (s(!0), i(B, null, V(C.value.mapping, (c, $) => (s(), i("span", {
840
- key: $,
857
+ t("div", zt, [
858
+ (a(!0), r(B, null, V($.value.mapping, (u, C) => (a(), r("span", {
859
+ key: C,
841
860
  class: "inline-flex items-center gap-1 px-2 py-0.5 bg-white rounded-full text-xs border border-slate-200"
842
861
  }, [
843
- t("span", Vt, v(c.fieldName), 1),
862
+ t("span", qt, p(u.fieldName), 1),
844
863
  d[15] || (d[15] = t("span", { class: "text-slate-400" }, "←", -1)),
845
- t("span", Ut, v(c.mappedTo), 1)
864
+ t("span", Lt, p(u.mappedTo), 1)
846
865
  ]))), 128))
847
866
  ])
848
867
  ])
849
868
  ])
850
869
  ])
851
- ])) : F("", !0),
852
- t("div", zt, [
853
- t("label", qt, [
854
- N(t("input", {
870
+ ])) : P("", !0),
871
+ t("div", Gt, [
872
+ t("label", Jt, [
873
+ R(t("input", {
855
874
  type: "checkbox",
856
- "onUpdate:modelValue": d[1] || (d[1] = (c) => f.value = c),
875
+ "onUpdate:modelValue": d[1] || (d[1] = (u) => f.value = u),
857
876
  class: "w-5 h-5 text-emerald-500 border-2 border-slate-300 rounded focus:ring-emerald-500 cursor-pointer"
858
877
  }, null, 512), [
859
- [se, f.value]
878
+ [te, f.value]
860
879
  ]),
861
880
  d[18] || (d[18] = t("span", { class: "font-medium text-slate-700 group-hover:text-slate-900 transition-colors" }, "Actualizar dinámicamente según criterios del feed", -1))
862
881
  ]),
863
- f.value ? (s(), i("div", Lt, [
864
- t("div", Gt, [
882
+ f.value ? (a(), r("div", Ht, [
883
+ t("div", Wt, [
865
884
  d[19] || (d[19] = t("label", { class: "text-sm font-semibold text-slate-600" }, "Cantidad de elementos:", -1)),
866
- N(t("input", {
885
+ R(t("input", {
867
886
  type: "number",
868
- "onUpdate:modelValue": d[2] || (d[2] = (c) => u.value = c),
887
+ "onUpdate:modelValue": d[2] || (d[2] = (u) => c.value = u),
869
888
  min: "1",
870
889
  class: "w-32 px-3 py-2 border border-slate-200 rounded-lg focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 transition-colors"
871
890
  }, null, 512), [
872
891
  [
873
- K,
874
- u.value,
892
+ Y,
893
+ c.value,
875
894
  void 0,
876
895
  { number: !0 }
877
896
  ]
878
897
  ])
879
898
  ]),
880
- t("div", Jt, [
899
+ t("div", Yt, [
881
900
  d[21] || (d[21] = t("label", { class: "text-sm font-semibold text-slate-600" }, "Orientación:", -1)),
882
- N(t("select", {
883
- "onUpdate:modelValue": d[3] || (d[3] = (c) => r.value = c),
901
+ R(t("select", {
902
+ "onUpdate:modelValue": d[3] || (d[3] = (u) => n.value = u),
884
903
  class: "w-48 px-3 py-2 border border-slate-200 rounded-lg focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-white transition-colors cursor-pointer"
885
904
  }, [...d[20] || (d[20] = [
886
905
  t("option", {
@@ -889,74 +908,74 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
889
908
  }, "Horizontal", -1),
890
909
  t("option", { value: "vertical" }, "Vertical", -1)
891
910
  ])], 512), [
892
- [J, r.value]
911
+ [J, n.value]
893
912
  ])
894
913
  ])
895
- ])) : F("", !0)
914
+ ])) : P("", !0)
896
915
  ])
897
916
  ]),
898
- t("div", Ht, [
917
+ t("div", Kt, [
899
918
  d[22] || (d[22] = t("h3", { class: "text-lg font-bold mb-5 text-slate-700 pb-2 flex items-center gap-2 border-b border-slate-100" }, [
900
919
  t("span", { class: "text-xl" }, "🔍"),
901
920
  T(" Orígenes y Filtros ")
902
921
  ], -1)),
903
- q(kt, {
904
- onSubmit: I,
905
- updateFeedCriteria: n,
922
+ L(Ft, {
923
+ onSubmit: M,
924
+ updateFeedCriteria: i,
906
925
  isProduction: e.isProduction
907
926
  }, null, 8, ["isProduction"])
908
927
  ])
909
928
  ]),
910
- t("div", Wt, [
929
+ t("div", Qt, [
911
930
  d[24] || (d[24] = t("h3", { class: "text-lg font-bold mb-5 text-slate-700 pb-2 flex items-center gap-2 border-b border-slate-100" }, [
912
931
  t("span", { class: "text-xl" }, "📰"),
913
932
  T(" Noticias ")
914
933
  ], -1)),
915
- !g.value || g.value.length === 0 ? (s(), i("div", Kt, [...d[23] || (d[23] = [
934
+ !g.value || g.value.length === 0 ? (a(), r("div", Xt, [...d[23] || (d[23] = [
916
935
  t("span", { class: "text-5xl mb-3 opacity-50" }, "📭", -1),
917
936
  t("p", { class: "text-sm font-medium" }, "No hay noticias disponibles", -1),
918
937
  t("p", { class: "text-xs mt-1 text-slate-300" }, "Selecciona un origen para cargar noticias", -1)
919
- ])])) : (s(), i("ul", Qt, [
920
- (s(!0), i(B, null, V(g.value, (c, $) => (s(), i("li", {
921
- key: $,
938
+ ])])) : (a(), r("ul", Zt, [
939
+ (a(!0), r(B, null, V(g.value, (u, C) => (a(), r("li", {
940
+ key: C,
922
941
  class: "p-4 bg-gradient-to-br from-slate-50 to-white rounded-xl shadow-sm hover:shadow-md cursor-pointer hover:scale-[1.01] transition-all duration-200 border border-slate-200 hover:border-emerald-300",
923
- onClick: (j) => a(c)
942
+ onClick: (j) => s(u)
924
943
  }, [
925
- t("h4", Yt, v(c.title || c.titulo || "Sin título"), 1),
926
- t("p", Zt, v(c.description || c.descripcion || c.content || "Sin descripción"), 1)
927
- ], 8, Xt))), 128))
944
+ t("h4", eo, p(u.title || u.titulo || "Sin título"), 1),
945
+ t("p", to, p(u.description || u.descripcion || u.content || "Sin descripción"), 1)
946
+ ], 8, _t))), 128))
928
947
  ]))
929
948
  ]),
930
- t("div", _t, [
949
+ t("div", oo, [
931
950
  d[30] || (d[30] = t("h3", { class: "text-lg font-bold mb-5 text-slate-700 pb-2 flex items-center gap-2 border-b border-slate-100" }, [
932
951
  t("span", { class: "text-xl" }, "🔗"),
933
952
  T(" Relacionar Noticia ")
934
953
  ], -1)),
935
- x.value ? (s(), i("div", to, [
936
- (s(!0), i(B, null, V(e.object.fields, (c, $) => (s(), i("div", {
937
- key: $,
954
+ h.value ? (a(), r("div", no, [
955
+ (a(!0), r(B, null, V(e.object.fields, (u, C) => (a(), r("div", {
956
+ key: C,
938
957
  class: "p-4 bg-gradient-to-br from-slate-50 to-white rounded-xl border border-slate-200"
939
958
  }, [
940
- t("label", oo, [
959
+ t("label", ao, [
941
960
  d[26] || (d[26] = t("span", { class: "text-base" }, "⚙️", -1)),
942
- T(" " + v(c.name), 1)
961
+ T(" " + p(u.name), 1)
943
962
  ]),
944
- N(t("select", {
945
- "onUpdate:modelValue": (j) => c.mappedTo = j,
963
+ R(t("select", {
964
+ "onUpdate:modelValue": (j) => u.mappedTo = j,
946
965
  class: "w-full px-3 py-2.5 border border-slate-200 rounded-lg focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 transition-all bg-white cursor-pointer"
947
966
  }, [
948
967
  d[27] || (d[27] = t("option", { value: "" }, "-- Seleccionar campo --", -1)),
949
- (s(!0), i(B, null, V(x.value, (j, D) => (s(), i("option", {
968
+ (a(!0), r(B, null, V(h.value, (j, D) => (a(), r("option", {
950
969
  key: D,
951
970
  value: D
952
- }, v(D), 9, no))), 128))
953
- ], 8, lo), [
954
- [J, c.mappedTo]
971
+ }, p(D), 9, so))), 128))
972
+ ], 8, ro), [
973
+ [J, u.mappedTo]
955
974
  ]),
956
- c.mappedTo ? (s(), i("div", ao, [
975
+ u.mappedTo ? (a(), r("div", io, [
957
976
  d[28] || (d[28] = t("span", { class: "text-xs font-semibold text-emerald-600 uppercase tracking-wide" }, "Vista previa:", -1)),
958
- t("p", ro, v(x.value[c.mappedTo]), 1)
959
- ])) : F("", !0)
977
+ t("p", uo, p(h.value[u.mappedTo]), 1)
978
+ ])) : P("", !0)
960
979
  ]))), 128)),
961
980
  t("button", {
962
981
  onClick: l,
@@ -965,7 +984,7 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
965
984
  t("span", { class: "text-lg" }, "✓", -1),
966
985
  t("span", null, "Alimentar el componente", -1)
967
986
  ])])
968
- ])) : (s(), i("div", eo, [...d[25] || (d[25] = [
987
+ ])) : (a(), r("div", lo, [...d[25] || (d[25] = [
969
988
  t("span", { class: "text-5xl mb-3 opacity-50" }, "👆", -1),
970
989
  t("p", { class: "text-sm font-medium text-center" }, [
971
990
  T("Selecciona una noticia"),
@@ -977,29 +996,29 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
977
996
  ])
978
997
  ]));
979
998
  }
980
- }), io = { class: "absolute -top-2.5 left-3 text-[11px] font-medium tracking-wide bg-gradient-to-r from-slate-700 to-slate-600 text-white px-3 py-0.5 rounded-full shadow-sm" }, uo = { class: "w-full text-right flex justify-between items-center mt-1" }, co = { class: "flex gap-3 items-center" }, mo = { class: "bg-rose-50 border border-rose-200 text-rose-500 px-2 py-0.5 text-[10px] font-semibold uppercase tracking-wider rounded-md" }, bo = {
999
+ }), mo = { class: "absolute -top-2.5 left-3 text-[11px] font-medium tracking-wide bg-gradient-to-r from-slate-700 to-slate-600 text-white px-3 py-0.5 rounded-full shadow-sm" }, bo = { class: "w-full text-right flex justify-between items-center mt-1" }, go = { class: "flex gap-3 items-center" }, fo = { class: "bg-rose-50 border border-rose-200 text-rose-500 px-2 py-0.5 text-[10px] font-semibold uppercase tracking-wider rounded-md" }, po = {
981
1000
  key: 0,
982
1001
  class: "flex-1 flex justify-center"
983
- }, go = { class: "flex justify-end items-center gap-3" }, fo = { class: "bg-violet-50 border border-violet-200 text-violet-600 rounded-md px-2 py-0.5 text-[10px] font-semibold uppercase tracking-wider" }, vo = {
1002
+ }, vo = { class: "flex justify-end items-center gap-3" }, xo = { class: "bg-violet-50 border border-violet-200 text-violet-600 rounded-md px-2 py-0.5 text-[10px] font-semibold uppercase tracking-wider" }, ho = {
984
1003
  key: 0,
985
1004
  class: "flex gap-1 bg-slate-50 rounded-lg p-1"
986
- }, po = {
1005
+ }, wo = {
987
1006
  key: 0,
988
1007
  class: "text-[10px] bg-amber-100 text-amber-700 px-1.5 rounded-full font-medium"
989
- }, xo = { class: "mt-2 flex items-center" }, ho = { class: "font-medium text-slate-700" }, wo = { key: 0 }, yo = { key: 1 }, Co = {
1008
+ }, yo = { class: "mt-2 flex items-center" }, Co = { class: "font-medium text-slate-700" }, $o = { key: 0 }, ko = { key: 1 }, So = {
990
1009
  key: 0,
991
1010
  class: "mt-3 p-3 bg-gradient-to-r from-sky-50 to-blue-50 rounded-lg text-sm text-slate-600 border border-sky-100"
992
- }, $o = { class: "mt-3 flex gap-1.5 flex-wrap" }, ko = { class: "absolute top-0 left-0 w-full h-full opacity-0 group-hover:opacity-100 bg-gradient-to-br from-white/90 via-slate-50/95 to-slate-100/90 backdrop-blur-[2px] z-99 transition-all duration-300 rounded-xl" }, So = { class: "flex justify-center h-full items-center p-4 gap-3" }, Fo = {
1011
+ }, Po = { class: "mt-3 flex gap-1.5 flex-wrap" }, Fo = { class: "absolute top-0 left-0 w-full h-full opacity-0 group-hover:opacity-100 bg-gradient-to-br from-white/90 via-slate-50/95 to-slate-100/90 backdrop-blur-[2px] z-99 transition-all duration-300 rounded-xl" }, jo = { class: "flex justify-center h-full items-center p-4 gap-3" }, Mo = {
993
1012
  key: 0,
994
1013
  title: "Mover componente",
995
1014
  class: "handle cursor-grab flex items-center bg-white border border-slate-200 px-4 py-2 rounded-xl hover:bg-slate-700 hover:border-slate-700 hover:text-white shadow-sm hover:shadow-md transition-all duration-200 group/btn"
996
- }, Po = {
1015
+ }, Io = {
997
1016
  key: 1,
998
1017
  class: "flex-1 flex justify-center items-center"
999
- }, jo = { class: "flex flex-col items-center" }, Io = {
1018
+ }, Ao = { class: "flex flex-col items-center" }, Bo = {
1000
1019
  key: 0,
1001
1020
  class: "text-[10px] mt-0.5 opacity-70"
1002
- }, Mo = ["id"], ce = /* @__PURE__ */ H({
1021
+ }, Eo = ["id"], ce = /* @__PURE__ */ H({
1003
1022
  __name: "InitialComponent",
1004
1023
  props: {
1005
1024
  object: {
@@ -1023,49 +1042,49 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1023
1042
  }
1024
1043
  },
1025
1044
  setup(e) {
1026
- const o = e, g = Math.random().toString(36).substring(2, 15), x = S(!1), f = S(!1), u = S(null), r = S(null), b = S(!1), C = S(!1);
1045
+ const o = e, g = Math.random().toString(36).substring(2, 15), h = S(!1), f = S(!1), c = S(null), n = S(null), b = S(!1), $ = S(!1);
1027
1046
  ee(() => o.isComponentMode, (d) => {
1028
- d || I();
1047
+ d || M();
1029
1048
  }), ee(() => o.object, () => {
1030
- I();
1049
+ M();
1031
1050
  }, { deep: !0 }), ee(b, async (d) => {
1032
- d && (await be(), w());
1051
+ d && (await ge(), w());
1033
1052
  });
1034
- const I = () => {
1035
- u.value && clearTimeout(u.value), u.value = setTimeout(() => {
1053
+ const M = () => {
1054
+ c.value && clearTimeout(c.value), c.value = setTimeout(() => {
1036
1055
  w();
1037
1056
  }, 500);
1038
- }, a = () => {
1057
+ }, s = () => {
1039
1058
  if (o.isComponentMode) return;
1040
- const d = new IntersectionObserver((c) => {
1041
- c.forEach(($) => {
1042
- $.isIntersecting && !b.value && (b.value = !0, d.disconnect());
1059
+ const d = new IntersectionObserver((u) => {
1060
+ u.forEach((C) => {
1061
+ C.isIntersecting && !b.value && (b.value = !0, d.disconnect());
1043
1062
  });
1044
1063
  }, { threshold: 0.1 });
1045
- r.value && d.observe(r.value);
1046
- }, l = (d, c) => {
1047
- const $ = (o.object.fields || []).find((j) => j.name === d);
1048
- $ && ($.example_value = c);
1049
- }, n = (d, c) => {
1050
- d.forEach(($) => {
1051
- $.value !== void 0 && l($.fieldName, $.value);
1052
- }), o.object.repeat_data = c;
1064
+ n.value && d.observe(n.value);
1065
+ }, l = (d, u) => {
1066
+ const C = (o.object.fields || []).find((j) => j.name === d);
1067
+ C && (C.example_value = u);
1068
+ }, i = (d, u) => {
1069
+ d.forEach((C) => {
1070
+ C.value !== void 0 && l(C.fieldName, C.value);
1071
+ }), o.object.repeat_data = u;
1053
1072
  }, m = () => {
1054
1073
  f.value = !f.value;
1055
1074
  }, k = () => {
1056
- C.value = !C.value;
1057
- }, A = () => {
1075
+ $.value = !$.value;
1076
+ }, I = () => {
1058
1077
  w(!0).then((d) => {
1059
- const c = window.open("", "Preview", "width=1200,height=800");
1060
- if (!c) {
1078
+ const u = window.open("", "Preview", "width=1200,height=800");
1079
+ if (!u) {
1061
1080
  alert("El navegador bloqueó la ventana emergente. Por favor, permite los popups para este sitio.");
1062
1081
  return;
1063
1082
  }
1064
- c.document.body.innerHTML = d, c.document.querySelectorAll("script").forEach((j) => {
1065
- var R;
1066
- const D = c.document.createElement("script");
1067
- j.src ? D.src = j.src : D.textContent = j.textContent, (R = j.parentNode) == null || R.replaceChild(D, j);
1068
- }), c.document.close();
1083
+ u.document.body.innerHTML = d, u.document.querySelectorAll("script").forEach((j) => {
1084
+ var N;
1085
+ const D = u.document.createElement("script");
1086
+ j.src ? D.src = j.src : D.textContent = j.textContent, (N = j.parentNode) == null || N.replaceChild(D, j);
1087
+ }), u.document.close();
1069
1088
  });
1070
1089
  }, w = (d = !1) => {
1071
1090
  var j;
@@ -1073,41 +1092,41 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1073
1092
  const D = '<div style="color:white; padding: 1em 2em;background-color:#001978;border-radius:1em;border:4px solid #711978;">Componente que contiene elementos repetidos: TODO: GENERAR PREVIEW DE REPETIDORES</div>';
1074
1093
  if (d)
1075
1094
  return Promise.resolve(D);
1076
- const R = document.getElementById(g);
1077
- return R && (R.innerHTML = D), Promise.resolve("");
1095
+ const N = document.getElementById(g);
1096
+ return N && (N.innerHTML = D), Promise.resolve("");
1078
1097
  }
1079
- const c = o.renderApiDomain ? o.renderApiDomain + "/api/preview-comp/" : "http://localhost:8003/api/preview-comp/", $ = JSON.stringify({ obj: o.object }, null, 2);
1080
- return fetch(c, {
1098
+ const u = o.renderApiDomain ? o.renderApiDomain + "/api/preview-comp/" : "http://localhost:8003/api/preview-comp/", C = JSON.stringify({ obj: o.object }, null, 2);
1099
+ return fetch(u, {
1081
1100
  method: "POST",
1082
1101
  headers: { "Content-Type": "application/json" },
1083
- body: $
1102
+ body: C
1084
1103
  }).then((D) => D.text()).then((D) => {
1085
1104
  if (d)
1086
1105
  return D;
1087
- const R = document.getElementById(g);
1088
- return R && (R.innerHTML = D), "";
1106
+ const N = document.getElementById(g);
1107
+ return N && (N.innerHTML = D), "";
1089
1108
  });
1090
1109
  };
1091
- return oe(() => {
1092
- a();
1093
- }), (d, c) => (s(), i("div", null, [
1094
- C.value ? (s(), ie(so, {
1110
+ return le(() => {
1111
+ s();
1112
+ }), (d, u) => (a(), r("div", null, [
1113
+ $.value ? (a(), ie(co, {
1095
1114
  key: 0,
1096
- updateObjectByFeedContent: n,
1115
+ updateObjectByFeedContent: i,
1097
1116
  toggleFeedSection: k,
1098
1117
  object: e.object,
1099
1118
  isProduction: e.isProduction
1100
- }, null, 8, ["object", "isProduction"])) : F("", !0),
1119
+ }, null, 8, ["object", "isProduction"])) : P("", !0),
1101
1120
  t("div", {
1102
1121
  ref_key: "rootElement",
1103
- ref: r,
1104
- class: L(["min-h-[100px] relative group hover:shadow-lg hover:shadow-slate-200/50 duration-300 ease-out js-draggable-element text-slate-600 border border-slate-200 hover:border-slate-300 px-5 pt-3 pb-4 w-full bg-white inline-block rounded-xl flex flex-col mb-3 z-0 shadow-sm", { "overflow-hidden": !e.isComponentMode }])
1122
+ ref: n,
1123
+ class: G(["min-h-[100px] relative group hover:shadow-lg hover:shadow-slate-200/50 duration-300 ease-out js-draggable-element text-slate-600 border border-slate-200 hover:border-slate-300 px-5 pt-3 pb-4 w-full bg-white inline-block rounded-xl flex flex-col mb-3 z-0 shadow-sm", { "overflow-hidden": !e.isComponentMode }])
1105
1124
  }, [
1106
- e.isComponentMode ? (s(), i(B, { key: 0 }, [
1107
- t("span", io, v(e.object.component_name), 1),
1108
- t("div", uo, [
1109
- t("div", co, [
1110
- c[8] || (c[8] = t("div", { class: "handle cursor-grab text-slate-400 hover:text-slate-600 text-lg transition-colors" }, [
1125
+ e.isComponentMode ? (a(), r(B, { key: 0 }, [
1126
+ t("span", mo, p(e.object.component_name), 1),
1127
+ t("div", bo, [
1128
+ t("div", go, [
1129
+ u[8] || (u[8] = t("div", { class: "handle cursor-grab text-slate-400 hover:text-slate-600 text-lg transition-colors" }, [
1111
1130
  t("svg", {
1112
1131
  class: "w-5 h-5",
1113
1132
  fill: "currentColor",
@@ -1116,28 +1135,28 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1116
1135
  t("path", { d: "M7 2a2 2 0 1 0 .001 4.001A2 2 0 0 0 7 2zm0 6a2 2 0 1 0 .001 4.001A2 2 0 0 0 7 8zm0 6a2 2 0 1 0 .001 4.001A2 2 0 0 0 7 14zm6-8a2 2 0 1 0-.001-4.001A2 2 0 0 0 13 6zm0 2a2 2 0 1 0 .001 4.001A2 2 0 0 0 13 8zm0 6a2 2 0 1 0 .001 4.001A2 2 0 0 0 13 14z" })
1117
1136
  ])
1118
1137
  ], -1)),
1119
- t("span", mo, v(e.object.category), 1)
1138
+ t("span", fo, p(e.object.category), 1)
1120
1139
  ]),
1121
- e.fullwidthMode ? (s(), i("div", bo, [
1140
+ e.fullwidthMode ? (a(), r("div", po, [
1122
1141
  t("div", {
1123
1142
  class: "bg-gradient-to-r from-emerald-500 to-teal-500 hover:from-emerald-600 hover:to-teal-600 text-white rounded-lg px-4 py-1.5 text-xs font-medium cursor-pointer shadow-sm hover:shadow transition-all duration-200",
1124
- onClick: c[0] || (c[0] = ($) => {
1143
+ onClick: u[0] || (u[0] = (C) => {
1125
1144
  var j;
1126
1145
  return (j = e.addComponentToColumn) == null ? void 0 : j.call(e, e.object);
1127
1146
  })
1128
1147
  }, "Seleccionar")
1129
- ])) : F("", !0),
1130
- t("div", go, [
1131
- t("span", fo, v(e.object.framework), 1),
1132
- e.insideComponentBox ? F("", !0) : (s(), i("div", vo, [
1148
+ ])) : P("", !0),
1149
+ t("div", vo, [
1150
+ t("span", xo, p(e.object.framework), 1),
1151
+ e.insideComponentBox ? P("", !0) : (a(), r("div", ho, [
1133
1152
  t("div", {
1134
1153
  title: "Previsualizar Dummy",
1135
- onClick: c[1] || (c[1] = ($) => A()),
1154
+ onClick: u[1] || (u[1] = (C) => I()),
1136
1155
  class: "p-1.5 rounded-md hover:bg-white hover:shadow-sm cursor-pointer transition-all duration-200 text-base"
1137
1156
  }, "🔍"),
1138
1157
  t("div", {
1139
1158
  title: "Editar configuración",
1140
- onClick: c[2] || (c[2] = ($) => f.value = !f.value),
1159
+ onClick: u[2] || (u[2] = (C) => f.value = !f.value),
1141
1160
  class: "p-1.5 rounded-md hover:bg-white hover:shadow-sm cursor-pointer transition-all duration-200 text-base"
1142
1161
  }, "⚙️"),
1143
1162
  t("div", {
@@ -1145,43 +1164,43 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1145
1164
  onClick: k,
1146
1165
  class: "p-1.5 rounded-md hover:bg-white hover:shadow-sm cursor-pointer transition-all duration-200 text-base flex items-center gap-1"
1147
1166
  }, [
1148
- c[9] || (c[9] = T("⚡ ", -1)),
1149
- e.object.repeat_data ? (s(), i("span", po, v(e.object.repeat_data.elementCount), 1)) : F("", !0)
1167
+ u[9] || (u[9] = T("⚡ ", -1)),
1168
+ e.object.repeat_data ? (a(), r("span", wo, p(e.object.repeat_data.elementCount), 1)) : P("", !0)
1150
1169
  ]),
1151
- e.removeComponent ? (s(), i("div", {
1170
+ e.removeComponent ? (a(), r("div", {
1152
1171
  key: 0,
1153
1172
  title: "Eliminar componente",
1154
- onClick: c[3] || (c[3] = ($) => e.removeComponent(e.object, e.section || "")),
1173
+ onClick: u[3] || (u[3] = (C) => e.removeComponent(e.object, e.section || "")),
1155
1174
  class: "p-1.5 rounded-md hover:bg-red-50 hover:shadow-sm cursor-pointer transition-all duration-200 text-base"
1156
- }, "🗑️")) : F("", !0)
1175
+ }, "🗑️")) : P("", !0)
1157
1176
  ]))
1158
1177
  ])
1159
1178
  ]),
1160
- q(ae, {
1179
+ L(re, {
1161
1180
  toggleShowForm: m,
1162
1181
  object: e.object,
1163
1182
  showForm: f.value
1164
1183
  }, null, 8, ["object", "showForm"]),
1165
- t("div", xo, [
1166
- t("span", ho, v(e.object.name), 1),
1184
+ t("div", yo, [
1185
+ t("span", Co, p(e.object.name), 1),
1167
1186
  t("button", {
1168
- onClick: c[4] || (c[4] = ($) => x.value = !x.value),
1187
+ onClick: u[4] || (u[4] = (C) => h.value = !h.value),
1169
1188
  class: "ms-2 cursor-pointer text-xs text-slate-400 hover:text-slate-600 transition-colors w-5 h-5 rounded-full hover:bg-slate-100 flex items-center justify-center"
1170
1189
  }, [
1171
- x.value ? (s(), i("span", yo, "▲")) : (s(), i("span", wo, "▼"))
1190
+ h.value ? (a(), r("span", ko, "▲")) : (a(), r("span", $o, "▼"))
1172
1191
  ])
1173
1192
  ]),
1174
- x.value ? (s(), i("div", Co, v(e.object.description), 1)) : F("", !0),
1175
- t("div", $o, [
1176
- (s(!0), i(B, null, V(e.object.tags, ($, j) => (s(), i("span", {
1193
+ h.value ? (a(), r("div", So, p(e.object.description), 1)) : P("", !0),
1194
+ t("div", Po, [
1195
+ (a(!0), r(B, null, V(e.object.tags, (C, j) => (a(), r("span", {
1177
1196
  key: j,
1178
1197
  class: "bg-slate-50 text-slate-500 px-2.5 py-1 rounded-full text-[11px] font-medium border border-slate-100 hover:border-slate-200 hover:bg-slate-100 transition-colors cursor-default"
1179
- }, v($), 1))), 128))
1198
+ }, p(C), 1))), 128))
1180
1199
  ])
1181
- ], 64)) : b.value ? (s(), i(B, { key: 1 }, [
1182
- t("div", ko, [
1183
- t("div", So, [
1184
- e.insideComponentBox && !e.fullwidthMode || !e.insideComponentBox ? (s(), i("div", Fo, [...c[10] || (c[10] = [
1200
+ ], 64)) : b.value ? (a(), r(B, { key: 1 }, [
1201
+ t("div", Fo, [
1202
+ t("div", jo, [
1203
+ e.insideComponentBox && !e.fullwidthMode || !e.insideComponentBox ? (a(), r("div", Mo, [...u[10] || (u[10] = [
1185
1204
  t("div", { class: "flex flex-col items-center" }, [
1186
1205
  t("svg", {
1187
1206
  class: "w-6 h-6 mb-1 text-slate-400 group-hover/btn:text-white",
@@ -1192,28 +1211,28 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1192
1211
  ]),
1193
1212
  t("span", { class: "text-xs font-medium" }, "Mover")
1194
1213
  ], -1)
1195
- ])])) : F("", !0),
1196
- e.insideComponentBox && e.fullwidthMode ? (s(), i("div", Po, [
1214
+ ])])) : P("", !0),
1215
+ e.insideComponentBox && e.fullwidthMode ? (a(), r("div", Io, [
1197
1216
  t("div", {
1198
1217
  title: "Agregar componente a la columna",
1199
- onClick: c[5] || (c[5] = ($) => {
1218
+ onClick: u[5] || (u[5] = (C) => {
1200
1219
  var j;
1201
1220
  return (j = e.addComponentToColumn) == null ? void 0 : j.call(e, e.object);
1202
1221
  }),
1203
1222
  class: "cursor-pointer flex items-center bg-gradient-to-r from-emerald-500 to-teal-500 hover:from-emerald-600 hover:to-teal-600 text-white px-6 py-3 rounded-xl shadow-md hover:shadow-lg transition-all duration-200"
1204
- }, [...c[11] || (c[11] = [
1223
+ }, [...u[11] || (u[11] = [
1205
1224
  t("div", { class: "flex flex-col items-center" }, [
1206
1225
  t("span", { class: "text-2xl mb-1" }, "🚀"),
1207
1226
  t("span", { class: "text-sm font-medium" }, "Seleccionar")
1208
1227
  ], -1)
1209
1228
  ])])
1210
- ])) : F("", !0),
1211
- e.insideComponentBox ? F("", !0) : (s(), i(B, { key: 2 }, [
1229
+ ])) : P("", !0),
1230
+ e.insideComponentBox ? P("", !0) : (a(), r(B, { key: 2 }, [
1212
1231
  t("div", {
1213
1232
  title: "Configurar componente",
1214
- onClick: c[6] || (c[6] = ($) => f.value = !f.value),
1233
+ onClick: u[6] || (u[6] = (C) => f.value = !f.value),
1215
1234
  class: "cursor-pointer flex items-center bg-white border border-slate-200 px-4 py-2 rounded-xl hover:bg-slate-700 hover:border-slate-700 hover:text-white shadow-sm hover:shadow-md transition-all duration-200 group/btn"
1216
- }, [...c[12] || (c[12] = [
1235
+ }, [...u[12] || (u[12] = [
1217
1236
  t("div", { class: "flex flex-col items-center" }, [
1218
1237
  t("span", { class: "text-xl mb-1" }, "⚙️"),
1219
1238
  t("span", { class: "text-xs font-medium" }, "Configurar")
@@ -1224,52 +1243,52 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1224
1243
  onClick: k,
1225
1244
  class: "cursor-pointer flex items-center bg-white border border-slate-200 px-4 py-2 rounded-xl hover:bg-amber-500 hover:border-amber-500 hover:text-white shadow-sm hover:shadow-md transition-all duration-200 group/btn"
1226
1245
  }, [
1227
- t("div", jo, [
1228
- c[13] || (c[13] = t("span", { class: "text-xl mb-1" }, "⚡", -1)),
1229
- c[14] || (c[14] = t("span", { class: "text-xs font-medium" }, "Beber de contenido", -1)),
1230
- e.object.repeat_data && e.object.repeat_data.dynamicUpdate ? (s(), i("span", Io, "Carga " + v(e.object.repeat_data.elementCount) + " elementos", 1)) : F("", !0)
1246
+ t("div", Ao, [
1247
+ u[13] || (u[13] = t("span", { class: "text-xl mb-1" }, "⚡", -1)),
1248
+ u[14] || (u[14] = t("span", { class: "text-xs font-medium" }, "Beber de contenido", -1)),
1249
+ e.object.repeat_data && e.object.repeat_data.dynamicUpdate ? (a(), r("span", Bo, "Carga " + p(e.object.repeat_data.elementCount) + " elementos", 1)) : P("", !0)
1231
1250
  ])
1232
1251
  ]),
1233
- e.removeComponent ? (s(), i("div", {
1252
+ e.removeComponent ? (a(), r("div", {
1234
1253
  key: 0,
1235
1254
  title: "Eliminar componente",
1236
- onClick: c[7] || (c[7] = ($) => e.removeComponent(e.object, e.section || "")),
1255
+ onClick: u[7] || (u[7] = (C) => e.removeComponent(e.object, e.section || "")),
1237
1256
  class: "cursor-pointer flex items-center bg-white border border-slate-200 px-4 py-2 rounded-xl hover:bg-red-500 hover:border-red-500 hover:text-white shadow-sm hover:shadow-md transition-all duration-200 group/btn"
1238
- }, [...c[15] || (c[15] = [
1257
+ }, [...u[15] || (u[15] = [
1239
1258
  t("div", { class: "flex flex-col items-center" }, [
1240
1259
  t("span", { class: "text-xl mb-1" }, "🗑️"),
1241
1260
  t("span", { class: "text-xs font-medium" }, "Eliminar")
1242
1261
  ], -1)
1243
- ])])) : F("", !0)
1262
+ ])])) : P("", !0)
1244
1263
  ], 64))
1245
1264
  ])
1246
1265
  ]),
1247
- q(ae, {
1266
+ L(re, {
1248
1267
  toggleShowForm: m,
1249
1268
  object: e.object,
1250
1269
  showForm: f.value
1251
1270
  }, null, 8, ["object", "showForm"]),
1252
1271
  t("div", {
1253
- id: G(g),
1272
+ id: q(g),
1254
1273
  class: "w-full h-full flex items-center justify-center"
1255
- }, null, 8, Mo)
1256
- ], 64)) : F("", !0)
1274
+ }, null, 8, Eo)
1275
+ ], 64)) : P("", !0)
1257
1276
  ], 2)
1258
1277
  ]));
1259
1278
  }
1260
- }), Ao = { class: "absolute top-1 left-2 px-2 flex gap-3 items-center" }, Bo = {
1279
+ }), To = { class: "absolute top-1 left-2 px-2 flex gap-3 items-center" }, Do = {
1261
1280
  key: 0,
1262
1281
  class: "text-[10px] font-medium text-slate-400 bg-white/80 backdrop-blur-sm px-2 py-0.5 rounded-full shadow-sm"
1263
- }, Eo = { class: "text-slate-600" }, To = {
1282
+ }, Oo = { class: "text-slate-600" }, Ro = {
1264
1283
  key: 1,
1265
1284
  class: "text-[10px] font-medium text-slate-400 bg-white/80 backdrop-blur-sm px-2 py-0.5 rounded-full shadow-sm"
1266
- }, Do = { class: "text-slate-600" }, Oo = {
1285
+ }, No = { class: "text-slate-600" }, Vo = {
1267
1286
  key: 2,
1268
1287
  class: "text-[10px] font-medium text-slate-400 bg-white/80 backdrop-blur-sm px-2 py-0.5 rounded-full shadow-sm"
1269
- }, No = { class: "text-slate-600" }, Ro = {
1288
+ }, Uo = { class: "text-slate-600" }, zo = {
1270
1289
  key: 0,
1271
1290
  class: "my-4 w-full rounded-xl bg-white border border-slate-200 p-4 z-10 hidden group-hover:block shadow-lg"
1272
- }, Vo = { class: "p-4 bg-gradient-to-br from-slate-50 to-white rounded-lg w-full" }, Uo = { class: "flex flex-col" }, zo = ["for"], qo = ["id"], Lo = ["value"], Go = { class: "flex flex-col" }, Jo = ["for"], Ho = ["id"], Wo = ["value"], Ko = { class: "flex flex-col" }, Qo = ["for"], Xo = ["id"], Yo = ["value"], Zo = { class: "absolute bottom-0 flex flex-col gap-1 w-full opacity-0 transition-all duration-300 group-hover:opacity-100" }, _o = { class: "flex justify-between gap-2 bg-white/90 backdrop-blur-sm rounded-t-xl px-3 py-1.5 shadow-sm border border-b-0 border-slate-200" }, el = { class: "flex gap-1" }, tl = /* @__PURE__ */ H({
1291
+ }, qo = { class: "p-4 bg-gradient-to-br from-slate-50 to-white rounded-lg w-full" }, Lo = { class: "flex flex-col" }, Go = ["for"], Jo = ["id"], Ho = ["value"], Wo = { class: "flex flex-col" }, Yo = ["for"], Ko = ["id"], Qo = ["value"], Xo = { class: "flex flex-col" }, Zo = ["for"], _o = ["id"], el = ["value"], tl = { class: "absolute bottom-0 flex flex-col gap-1 w-full opacity-0 transition-all duration-300 group-hover:opacity-100" }, ol = { class: "flex justify-between gap-2 bg-white/90 backdrop-blur-sm rounded-t-xl px-3 py-1.5 shadow-sm border border-b-0 border-slate-200" }, ll = { class: "flex gap-1" }, nl = /* @__PURE__ */ H({
1273
1292
  __name: "ColConfig",
1274
1293
  props: {
1275
1294
  globalPageConfiguration: Array,
@@ -1314,189 +1333,189 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1314
1333
  { label: "Columna (componentes unos encima de otros)", value: "flex-col" },
1315
1334
  { label: "Fila (componentes unos al lado de otros)", value: "flex-row" }
1316
1335
  ]
1317
- }, x = S(""), f = S(""), u = S(""), r = S(!1), b = Q(() => {
1318
- var l, n, m, k;
1319
- const I = (l = o.globalPageConfiguration) == null ? void 0 : l.find(
1320
- (A) => A.section === o.section
1321
- ), a = (k = (m = (n = I == null ? void 0 : I.rows) == null ? void 0 : n[o.rowIndex]) == null ? void 0 : m.columns) == null ? void 0 : k[o.columnIndex];
1322
- return (a == null ? void 0 : a.config) || {};
1323
- }), C = (I, a) => {
1336
+ }, h = S(""), f = S(""), c = S(""), n = S(!1), b = K(() => {
1337
+ var l, i, m, k;
1338
+ const M = (l = o.globalPageConfiguration) == null ? void 0 : l.find(
1339
+ (I) => I.section === o.section
1340
+ ), s = (k = (m = (i = M == null ? void 0 : M.rows) == null ? void 0 : i[o.rowIndex]) == null ? void 0 : m.columns) == null ? void 0 : k[o.columnIndex];
1341
+ return (s == null ? void 0 : s.config) || {};
1342
+ }), $ = (M, s) => {
1324
1343
  var k;
1325
- const l = x.value || g.width[0].value, n = f.value || g.gap[0].value, m = u.value || "";
1326
- (k = o.updateColConfig) == null || k.call(o, I, a, o.section || "", l, n, m), r.value = !1;
1344
+ const l = h.value || g.width[0].value, i = f.value || g.gap[0].value, m = c.value || "";
1345
+ (k = o.updateColConfig) == null || k.call(o, M, s, o.section || "", l, i, m), n.value = !1;
1327
1346
  };
1328
- return (I, a) => (s(), i(B, null, [
1329
- t("div", Ao, [
1330
- b.value.width !== void 0 ? (s(), i("span", Bo, [
1331
- a[12] || (a[12] = T(" Ancho: ", -1)),
1332
- t("span", Eo, v(b.value.width), 1)
1333
- ])) : F("", !0),
1334
- b.value.gap !== void 0 ? (s(), i("span", To, [
1335
- a[13] || (a[13] = T(" Gap: ", -1)),
1336
- t("span", Do, v(b.value.gap), 1)
1337
- ])) : F("", !0),
1338
- b.value.flexDirection !== void 0 ? (s(), i("span", Oo, [
1339
- a[14] || (a[14] = T(" Flex: ", -1)),
1340
- t("span", No, v(b.value.flexDirection), 1)
1341
- ])) : F("", !0)
1347
+ return (M, s) => (a(), r(B, null, [
1348
+ t("div", To, [
1349
+ b.value.width !== void 0 ? (a(), r("span", Do, [
1350
+ s[12] || (s[12] = T(" Ancho: ", -1)),
1351
+ t("span", Oo, p(b.value.width), 1)
1352
+ ])) : P("", !0),
1353
+ b.value.gap !== void 0 ? (a(), r("span", Ro, [
1354
+ s[13] || (s[13] = T(" Gap: ", -1)),
1355
+ t("span", No, p(b.value.gap), 1)
1356
+ ])) : P("", !0),
1357
+ b.value.flexDirection !== void 0 ? (a(), r("span", Vo, [
1358
+ s[14] || (s[14] = T(" Flex: ", -1)),
1359
+ t("span", Uo, p(b.value.flexDirection), 1)
1360
+ ])) : P("", !0)
1342
1361
  ]),
1343
- r.value ? (s(), i("div", Ro, [
1344
- t("div", Vo, [
1362
+ n.value ? (a(), r("div", zo, [
1363
+ t("div", qo, [
1345
1364
  t("form", {
1346
- onSubmit: a[4] || (a[4] = te(() => {
1365
+ onSubmit: s[4] || (s[4] = oe(() => {
1347
1366
  }, ["prevent"])),
1348
1367
  class: "flex gap-5 w-full justify-center items-end flex-wrap"
1349
1368
  }, [
1350
- t("div", Uo, [
1369
+ t("div", Lo, [
1351
1370
  t("label", {
1352
1371
  for: `colwidth-${e.rowIndex}-${e.columnIndex}`,
1353
1372
  class: "block text-sm font-medium text-slate-600 mb-1.5"
1354
- }, "Ancho:", 8, zo),
1355
- N(t("select", {
1356
- "onUpdate:modelValue": a[0] || (a[0] = (l) => x.value = l),
1373
+ }, "Ancho:", 8, Go),
1374
+ R(t("select", {
1375
+ "onUpdate:modelValue": s[0] || (s[0] = (l) => h.value = l),
1357
1376
  id: `colwidth-${e.rowIndex}-${e.columnIndex}`,
1358
1377
  class: "block w-full border border-slate-200 rounded-lg px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-white hover:border-slate-300 transition-colors"
1359
1378
  }, [
1360
- a[15] || (a[15] = t("option", { value: "" }, "Selecciona...", -1)),
1361
- (s(!0), i(B, null, V(g.width, (l) => (s(), i("option", {
1379
+ s[15] || (s[15] = t("option", { value: "" }, "Selecciona...", -1)),
1380
+ (a(!0), r(B, null, V(g.width, (l) => (a(), r("option", {
1362
1381
  key: l.value,
1363
1382
  value: l.value
1364
- }, v(l.label), 9, Lo))), 128))
1365
- ], 8, qo), [
1366
- [J, x.value]
1383
+ }, p(l.label), 9, Ho))), 128))
1384
+ ], 8, Jo), [
1385
+ [J, h.value]
1367
1386
  ])
1368
1387
  ]),
1369
- t("div", Go, [
1388
+ t("div", Wo, [
1370
1389
  t("label", {
1371
1390
  for: `colgap-${e.rowIndex}-${e.columnIndex}`,
1372
1391
  class: "block text-sm font-medium text-slate-600 mb-1.5"
1373
- }, "Gap:", 8, Jo),
1374
- N(t("select", {
1375
- "onUpdate:modelValue": a[1] || (a[1] = (l) => f.value = l),
1392
+ }, "Gap:", 8, Yo),
1393
+ R(t("select", {
1394
+ "onUpdate:modelValue": s[1] || (s[1] = (l) => f.value = l),
1376
1395
  id: `colgap-${e.rowIndex}-${e.columnIndex}`,
1377
1396
  class: "block w-full border border-slate-200 rounded-lg px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-white hover:border-slate-300 transition-colors"
1378
1397
  }, [
1379
- a[16] || (a[16] = t("option", { value: "" }, "Selecciona...", -1)),
1380
- (s(!0), i(B, null, V(g.gap, (l) => (s(), i("option", {
1398
+ s[16] || (s[16] = t("option", { value: "" }, "Selecciona...", -1)),
1399
+ (a(!0), r(B, null, V(g.gap, (l) => (a(), r("option", {
1381
1400
  key: l.value,
1382
1401
  value: l.value
1383
- }, v(l.label), 9, Wo))), 128))
1384
- ], 8, Ho), [
1402
+ }, p(l.label), 9, Qo))), 128))
1403
+ ], 8, Ko), [
1385
1404
  [J, f.value]
1386
1405
  ])
1387
1406
  ]),
1388
- t("div", Ko, [
1407
+ t("div", Xo, [
1389
1408
  t("label", {
1390
1409
  for: `flexdir-${e.rowIndex}-${e.columnIndex}`,
1391
1410
  class: "block text-sm font-medium text-slate-600 mb-1.5"
1392
- }, "Dirección:", 8, Qo),
1393
- N(t("select", {
1394
- "onUpdate:modelValue": a[2] || (a[2] = (l) => u.value = l),
1411
+ }, "Dirección:", 8, Zo),
1412
+ R(t("select", {
1413
+ "onUpdate:modelValue": s[2] || (s[2] = (l) => c.value = l),
1395
1414
  id: `flexdir-${e.rowIndex}-${e.columnIndex}`,
1396
1415
  class: "block w-full border border-slate-200 rounded-lg px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-white hover:border-slate-300 transition-colors"
1397
1416
  }, [
1398
- a[17] || (a[17] = t("option", { value: "" }, "Selecciona...", -1)),
1399
- (s(!0), i(B, null, V(g.flexDirection, (l) => (s(), i("option", {
1417
+ s[17] || (s[17] = t("option", { value: "" }, "Selecciona...", -1)),
1418
+ (a(!0), r(B, null, V(g.flexDirection, (l) => (a(), r("option", {
1400
1419
  key: l.value,
1401
1420
  value: l.value
1402
- }, v(l.label), 9, Yo))), 128))
1403
- ], 8, Xo), [
1404
- [J, u.value]
1421
+ }, p(l.label), 9, el))), 128))
1422
+ ], 8, _o), [
1423
+ [J, c.value]
1405
1424
  ])
1406
1425
  ]),
1407
1426
  t("button", {
1408
1427
  type: "submit",
1409
1428
  class: "bg-gradient-to-r from-emerald-500 to-teal-500 hover:from-emerald-600 hover:to-teal-600 text-white px-5 py-2 rounded-lg font-medium shadow-sm hover:shadow-md transition-all duration-200 cursor-pointer",
1410
- onClick: a[3] || (a[3] = (l) => {
1411
- C(e.rowIndex, e.columnIndex), r.value = !1;
1429
+ onClick: s[3] || (s[3] = (l) => {
1430
+ $(e.rowIndex, e.columnIndex), n.value = !1;
1412
1431
  })
1413
1432
  }, " Guardar ")
1414
1433
  ], 32)
1415
1434
  ])
1416
- ])) : F("", !0),
1417
- t("div", Zo, [
1435
+ ])) : P("", !0),
1436
+ t("div", tl, [
1418
1437
  t("div", {
1419
- class: L(["flex flex-row", { "justify-between": e.section && e.section !== "Sidebar", "justify-center": e.section === "Sidebar" }])
1438
+ class: G(["flex flex-row", { "justify-between": e.section && e.section !== "Sidebar", "justify-center": e.section === "Sidebar" }])
1420
1439
  }, [
1421
- e.section && e.section !== "Sidebar" ? (s(), i("button", {
1440
+ e.section && e.section !== "Sidebar" ? (a(), r("button", {
1422
1441
  key: 0,
1423
1442
  title: "Añadir columna a la izquierda",
1424
- onClick: a[5] || (a[5] = (l) => {
1425
- var n;
1426
- return (n = e.addCol) == null ? void 0 : n.call(e, e.rowIndex, e.columnIndex, e.section, "left");
1443
+ onClick: s[5] || (s[5] = (l) => {
1444
+ var i;
1445
+ return (i = e.addCol) == null ? void 0 : i.call(e, e.rowIndex, e.columnIndex, e.section, "left");
1427
1446
  }),
1428
1447
  class: "ms-2 bg-white px-3 py-1 cursor-pointer rounded-t-lg border border-b-0 border-slate-200 hover:bg-emerald-500 hover:border-emerald-500 hover:text-white text-slate-600 transition-all duration-200 shadow-sm hover:shadow-md font-medium"
1429
- }, "+")) : F("", !0),
1430
- t("div", _o, [
1448
+ }, "+")) : P("", !0),
1449
+ t("div", ol, [
1431
1450
  t("button", {
1432
1451
  title: "Configurar columna",
1433
- onClick: a[6] || (a[6] = (l) => r.value = !r.value),
1434
- class: L(["px-2.5 py-1 rounded-lg cursor-pointer transition-all duration-200", r.value ? "bg-amber-100 text-amber-700 shadow-sm" : "bg-slate-100 text-slate-600 hover:bg-amber-500 hover:text-white"])
1452
+ onClick: s[6] || (s[6] = (l) => n.value = !n.value),
1453
+ class: G(["px-2.5 py-1 rounded-lg cursor-pointer transition-all duration-200", n.value ? "bg-amber-100 text-amber-700 shadow-sm" : "bg-slate-100 text-slate-600 hover:bg-amber-500 hover:text-white"])
1435
1454
  }, "⚙️", 2),
1436
- t("div", el, [
1437
- e.section && e.section !== "Sidebar" ? (s(), i("span", {
1455
+ t("div", ll, [
1456
+ e.section && e.section !== "Sidebar" ? (a(), r("span", {
1438
1457
  key: 0,
1439
1458
  title: "Mover columna a la izquierda",
1440
- onClick: a[7] || (a[7] = (l) => {
1441
- var n;
1442
- return (n = e.moveCol) == null ? void 0 : n.call(e, e.rowIndex, e.columnIndex, e.section, "left");
1459
+ onClick: s[7] || (s[7] = (l) => {
1460
+ var i;
1461
+ return (i = e.moveCol) == null ? void 0 : i.call(e, e.rowIndex, e.columnIndex, e.section, "left");
1443
1462
  }),
1444
1463
  class: "bg-slate-100 px-2.5 py-1 cursor-pointer rounded-lg transition-all duration-200 text-slate-400 hover:bg-blue-500 hover:text-white"
1445
- }, "◁")) : F("", !0),
1446
- e.fullwidthMode ? (s(), i("span", {
1464
+ }, "◁")) : P("", !0),
1465
+ e.fullwidthMode ? (a(), r("span", {
1447
1466
  key: 1,
1448
1467
  title: "Añadir componente",
1449
- onClick: a[8] || (a[8] = (l) => {
1450
- var n;
1451
- return (n = e.addComponentFunction) == null ? void 0 : n.call(e, e.rowIndex, e.columnIndex, e.section || "");
1468
+ onClick: s[8] || (s[8] = (l) => {
1469
+ var i;
1470
+ return (i = e.addComponentFunction) == null ? void 0 : i.call(e, e.rowIndex, e.columnIndex, e.section || "");
1452
1471
  }),
1453
1472
  class: "bg-slate-100 px-2.5 py-1 cursor-pointer rounded-lg transition-all duration-200 text-slate-400 hover:bg-violet-500 hover:text-white"
1454
- }, " 📦 ")) : F("", !0),
1455
- e.section && e.section !== "Sidebar" ? (s(), i("span", {
1473
+ }, " 📦 ")) : P("", !0),
1474
+ e.section && e.section !== "Sidebar" ? (a(), r("span", {
1456
1475
  key: 2,
1457
1476
  title: "Mover columna a la derecha",
1458
- onClick: a[9] || (a[9] = (l) => {
1459
- var n;
1460
- return (n = e.moveCol) == null ? void 0 : n.call(e, e.rowIndex, e.columnIndex, e.section, "right");
1477
+ onClick: s[9] || (s[9] = (l) => {
1478
+ var i;
1479
+ return (i = e.moveCol) == null ? void 0 : i.call(e, e.rowIndex, e.columnIndex, e.section, "right");
1461
1480
  }),
1462
1481
  class: "bg-slate-100 px-2.5 py-1 cursor-pointer rounded-lg transition-all duration-200 text-slate-400 hover:bg-blue-500 hover:text-white"
1463
- }, "▷ ")) : F("", !0)
1482
+ }, "▷ ")) : P("", !0)
1464
1483
  ]),
1465
1484
  t("button", {
1466
1485
  title: "Eliminar columna",
1467
- onClick: a[10] || (a[10] = (l) => {
1468
- var n;
1469
- return (n = e.removeCol) == null ? void 0 : n.call(e, e.rowIndex, e.columnIndex, e.section || "");
1486
+ onClick: s[10] || (s[10] = (l) => {
1487
+ var i;
1488
+ return (i = e.removeCol) == null ? void 0 : i.call(e, e.rowIndex, e.columnIndex, e.section || "");
1470
1489
  }),
1471
1490
  class: "bg-slate-100 px-2.5 py-1 rounded-lg cursor-pointer transition-all duration-200 text-slate-600 hover:bg-red-500 hover:text-white"
1472
1491
  }, "🗑️")
1473
1492
  ]),
1474
- e.section && e.section !== "Sidebar" ? (s(), i("button", {
1493
+ e.section && e.section !== "Sidebar" ? (a(), r("button", {
1475
1494
  key: 1,
1476
1495
  title: "Añadir columna a la derecha",
1477
- onClick: a[11] || (a[11] = (l) => {
1478
- var n;
1479
- return (n = e.addCol) == null ? void 0 : n.call(e, e.rowIndex, e.columnIndex, e.section, "right");
1496
+ onClick: s[11] || (s[11] = (l) => {
1497
+ var i;
1498
+ return (i = e.addCol) == null ? void 0 : i.call(e, e.rowIndex, e.columnIndex, e.section, "right");
1480
1499
  }),
1481
1500
  class: "me-2 bg-white px-3 py-1 cursor-pointer rounded-t-lg border border-b-0 border-slate-200 hover:bg-emerald-500 hover:border-emerald-500 hover:text-white text-slate-600 transition-all duration-200 shadow-sm hover:shadow-md font-medium"
1482
- }, "+")) : F("", !0)
1501
+ }, "+")) : P("", !0)
1483
1502
  ], 2)
1484
1503
  ])
1485
1504
  ], 64));
1486
1505
  }
1487
- }), ol = { class: "absolute -top-1 px-2 gap-4 w-full justify-between hidden css-pb-row-config" }, ll = { class: "flex gap-1.5" }, nl = { class: "flex gap-4 items-center" }, al = { class: "inline-block" }, rl = {
1506
+ }), al = { class: "absolute -top-1 px-2 gap-4 w-full justify-between hidden css-pb-row-config" }, rl = { class: "flex gap-1.5" }, sl = { class: "flex gap-4 items-center" }, il = { class: "inline-block" }, dl = {
1488
1507
  key: 0,
1489
1508
  class: "text-xs font-medium text-slate-400 bg-slate-50 px-2 py-1 rounded-full"
1490
- }, sl = { class: "text-slate-600" }, il = {
1509
+ }, ul = { class: "text-slate-600" }, cl = {
1491
1510
  key: 1,
1492
1511
  class: "text-xs font-medium text-slate-400 bg-slate-50 px-2 py-1 rounded-full"
1493
- }, dl = { class: "text-slate-600" }, ul = {
1512
+ }, ml = { class: "text-slate-600" }, bl = {
1494
1513
  key: 2,
1495
1514
  class: "text-xs font-medium text-slate-400 bg-slate-50 px-2 py-1 rounded-full"
1496
- }, cl = { class: "text-slate-600" }, ml = { class: "flex gap-1.5" }, bl = {
1515
+ }, gl = { class: "text-slate-600" }, fl = { class: "flex gap-1.5" }, pl = {
1497
1516
  key: 0,
1498
1517
  class: "z-1"
1499
- }, gl = { class: "p-5 bg-white rounded-xl shadow-lg border border-slate-100 w-full mt-8" }, fl = { class: "flex flex-col" }, vl = ["for"], pl = ["id"], xl = ["value"], hl = { class: "flex flex-col" }, wl = ["for"], yl = ["id"], Cl = ["value"], $l = { class: "flex flex-col" }, kl = ["for"], Sl = ["id"], Fl = ["value"], Pl = /* @__PURE__ */ H({
1518
+ }, vl = { class: "p-5 bg-white rounded-xl shadow-lg border border-slate-100 w-full mt-8" }, xl = { class: "flex flex-col" }, hl = ["for"], wl = ["id"], yl = ["value"], Cl = { class: "flex flex-col" }, $l = ["for"], kl = ["id"], Sl = ["value"], Pl = { class: "flex flex-col" }, Fl = ["for"], jl = ["id"], Ml = ["value"], Il = /* @__PURE__ */ H({
1500
1519
  __name: "RowConfig",
1501
1520
  props: {
1502
1521
  rowIndex: {
@@ -1537,24 +1556,24 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1537
1556
  { label: "3/5", value: "3/5" },
1538
1557
  { label: "4/5", value: "4/5" }
1539
1558
  ]
1540
- }, x = S(""), f = S(""), u = S(""), r = S(!1), b = S(!1), C = Q(() => {
1541
- var l, n;
1542
- const a = (l = o.globalPageConfiguration) == null ? void 0 : l.find(
1559
+ }, h = S(""), f = S(""), c = S(""), n = S(!1), b = S(!1), $ = K(() => {
1560
+ var l, i;
1561
+ const s = (l = o.globalPageConfiguration) == null ? void 0 : l.find(
1543
1562
  (m) => m.section === o.section
1544
1563
  );
1545
- return (n = a == null ? void 0 : a.rows) != null && n[o.rowIndex] ? a.rows[o.rowIndex].config || {} : {};
1546
- }), I = (a) => {
1564
+ return (i = s == null ? void 0 : s.rows) != null && i[o.rowIndex] ? s.rows[o.rowIndex].config || {} : {};
1565
+ }), M = (s) => {
1547
1566
  var k;
1548
- const l = x.value || g.padding[0].value, n = f.value || g.gap[0].value, m = u.value || g.width[0].value;
1549
- (k = o.updateRowConfig) == null || k.call(o, a, o.section || "", l, n, m), r.value = !1;
1567
+ const l = h.value || g.padding[0].value, i = f.value || g.gap[0].value, m = c.value || g.width[0].value;
1568
+ (k = o.updateRowConfig) == null || k.call(o, s, o.section || "", l, i, m), n.value = !1;
1550
1569
  };
1551
- return (a, l) => (s(), i(B, null, [
1552
- t("div", ol, [
1570
+ return (s, l) => (a(), r(B, null, [
1571
+ t("div", al, [
1553
1572
  t("div", null, [
1554
- t("div", ll, [
1573
+ t("div", rl, [
1555
1574
  t("button", {
1556
1575
  title: "Agregar fila",
1557
- onClick: l[0] || (l[0] = (n) => {
1576
+ onClick: l[0] || (l[0] = (i) => {
1558
1577
  var m;
1559
1578
  (m = e.addRow) == null || m.call(e, e.rowIndex, e.section || ""), b.value = !1;
1560
1579
  }),
@@ -1562,7 +1581,7 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1562
1581
  }, "+"),
1563
1582
  t("button", {
1564
1583
  title: "Mover fila hacia arriba",
1565
- onClick: l[1] || (l[1] = (n) => {
1584
+ onClick: l[1] || (l[1] = (i) => {
1566
1585
  var m;
1567
1586
  (m = e.moveRow) == null || m.call(e, e.rowIndex, e.section || "", "up"), b.value = !1;
1568
1587
  }),
@@ -1570,7 +1589,7 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1570
1589
  }, "△"),
1571
1590
  t("button", {
1572
1591
  title: "Mover fila hacia abajo",
1573
- onClick: l[2] || (l[2] = (n) => {
1592
+ onClick: l[2] || (l[2] = (i) => {
1574
1593
  var m;
1575
1594
  (m = e.moveRow) == null || m.call(e, e.rowIndex, e.section || "", "down"), b.value = !1;
1576
1595
  }),
@@ -1578,32 +1597,32 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1578
1597
  }, "▽")
1579
1598
  ])
1580
1599
  ]),
1581
- t("div", nl, [
1582
- t("div", al, [
1600
+ t("div", sl, [
1601
+ t("div", il, [
1583
1602
  t("button", {
1584
1603
  title: "Configurar la fila",
1585
- onClick: l[3] || (l[3] = (n) => r.value = !r.value),
1586
- class: L(["cursor-pointer rounded-b-lg border border-t-0 px-3 py-1 transition-all duration-200 shadow-sm hover:shadow-md", r.value ? "bg-amber-100 border-amber-300 text-amber-700" : "bg-white border-slate-200 text-slate-600 hover:bg-amber-500 hover:border-amber-500 hover:text-white"])
1604
+ onClick: l[3] || (l[3] = (i) => n.value = !n.value),
1605
+ class: G(["cursor-pointer rounded-b-lg border border-t-0 px-3 py-1 transition-all duration-200 shadow-sm hover:shadow-md", n.value ? "bg-amber-100 border-amber-300 text-amber-700" : "bg-white border-slate-200 text-slate-600 hover:bg-amber-500 hover:border-amber-500 hover:text-white"])
1587
1606
  }, "⚙️", 2)
1588
1607
  ]),
1589
- C.value.padding !== void 0 ? (s(), i("span", rl, [
1608
+ $.value.padding !== void 0 ? (a(), r("span", dl, [
1590
1609
  l[10] || (l[10] = T(" Padding: ", -1)),
1591
- t("span", sl, v(C.value.padding), 1)
1592
- ])) : F("", !0),
1593
- C.value.gap !== void 0 ? (s(), i("span", il, [
1610
+ t("span", ul, p($.value.padding), 1)
1611
+ ])) : P("", !0),
1612
+ $.value.gap !== void 0 ? (a(), r("span", cl, [
1594
1613
  l[11] || (l[11] = T(" Gap: ", -1)),
1595
- t("span", dl, v(C.value.gap), 1)
1596
- ])) : F("", !0),
1597
- C.value.width !== void 0 ? (s(), i("span", ul, [
1614
+ t("span", ml, p($.value.gap), 1)
1615
+ ])) : P("", !0),
1616
+ $.value.width !== void 0 ? (a(), r("span", bl, [
1598
1617
  l[12] || (l[12] = T(" Ancho: ", -1)),
1599
- t("span", cl, v(C.value.width), 1)
1600
- ])) : F("", !0)
1618
+ t("span", gl, p($.value.width), 1)
1619
+ ])) : P("", !0)
1601
1620
  ]),
1602
1621
  t("div", null, [
1603
- t("div", ml, [
1622
+ t("div", fl, [
1604
1623
  t("button", {
1605
1624
  title: "Eliminar fila",
1606
- onClick: l[4] || (l[4] = (n) => {
1625
+ onClick: l[4] || (l[4] = (i) => {
1607
1626
  var m;
1608
1627
  (m = e.removeRow) == null || m.call(e, e.rowIndex, e.section || ""), b.value = !1;
1609
1628
  }),
@@ -1612,83 +1631,83 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1612
1631
  ])
1613
1632
  ])
1614
1633
  ]),
1615
- r.value ? (s(), i("div", bl, [
1616
- t("div", gl, [
1634
+ n.value ? (a(), r("div", pl, [
1635
+ t("div", vl, [
1617
1636
  t("form", {
1618
- onSubmit: l[9] || (l[9] = te(() => {
1637
+ onSubmit: l[9] || (l[9] = oe(() => {
1619
1638
  }, ["prevent"])),
1620
1639
  class: "flex gap-6 w-full justify-center items-end flex-wrap"
1621
1640
  }, [
1622
- t("div", fl, [
1641
+ t("div", xl, [
1623
1642
  t("label", {
1624
1643
  for: `padding-${e.rowIndex}`,
1625
1644
  class: "block text-sm font-medium text-slate-600 mb-1.5"
1626
- }, "Padding:", 8, vl),
1627
- N(t("select", {
1628
- "onUpdate:modelValue": l[5] || (l[5] = (n) => x.value = n),
1645
+ }, "Padding:", 8, hl),
1646
+ R(t("select", {
1647
+ "onUpdate:modelValue": l[5] || (l[5] = (i) => h.value = i),
1629
1648
  id: `padding-${e.rowIndex}`,
1630
1649
  class: "block w-full border border-slate-200 rounded-lg px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-slate-50 hover:bg-white transition-colors"
1631
1650
  }, [
1632
1651
  l[13] || (l[13] = t("option", { value: "" }, "Selecciona...", -1)),
1633
- (s(!0), i(B, null, V(g.padding, (n) => (s(), i("option", {
1634
- key: n.value,
1635
- value: n.value
1636
- }, v(n.label), 9, xl))), 128))
1637
- ], 8, pl), [
1638
- [J, x.value]
1652
+ (a(!0), r(B, null, V(g.padding, (i) => (a(), r("option", {
1653
+ key: i.value,
1654
+ value: i.value
1655
+ }, p(i.label), 9, yl))), 128))
1656
+ ], 8, wl), [
1657
+ [J, h.value]
1639
1658
  ])
1640
1659
  ]),
1641
- t("div", hl, [
1660
+ t("div", Cl, [
1642
1661
  t("label", {
1643
1662
  for: `gap-${e.rowIndex}`,
1644
1663
  class: "block text-sm font-medium text-slate-600 mb-1.5"
1645
- }, "Gap:", 8, wl),
1646
- N(t("select", {
1647
- "onUpdate:modelValue": l[6] || (l[6] = (n) => f.value = n),
1664
+ }, "Gap:", 8, $l),
1665
+ R(t("select", {
1666
+ "onUpdate:modelValue": l[6] || (l[6] = (i) => f.value = i),
1648
1667
  id: `gap-${e.rowIndex}`,
1649
1668
  class: "block w-full border border-slate-200 rounded-lg px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-slate-50 hover:bg-white transition-colors"
1650
1669
  }, [
1651
1670
  l[14] || (l[14] = t("option", { value: "" }, "Selecciona...", -1)),
1652
- (s(!0), i(B, null, V(g.gap, (n) => (s(), i("option", {
1653
- key: n.value,
1654
- value: n.value
1655
- }, v(n.label), 9, Cl))), 128))
1656
- ], 8, yl), [
1671
+ (a(!0), r(B, null, V(g.gap, (i) => (a(), r("option", {
1672
+ key: i.value,
1673
+ value: i.value
1674
+ }, p(i.label), 9, Sl))), 128))
1675
+ ], 8, kl), [
1657
1676
  [J, f.value]
1658
1677
  ])
1659
1678
  ]),
1660
- t("div", $l, [
1679
+ t("div", Pl, [
1661
1680
  t("label", {
1662
1681
  for: `width-${e.rowIndex}`,
1663
1682
  class: "block text-sm font-medium text-slate-600 mb-1.5"
1664
- }, "Ancho:", 8, kl),
1665
- N(t("select", {
1666
- "onUpdate:modelValue": l[7] || (l[7] = (n) => u.value = n),
1683
+ }, "Ancho:", 8, Fl),
1684
+ R(t("select", {
1685
+ "onUpdate:modelValue": l[7] || (l[7] = (i) => c.value = i),
1667
1686
  id: `width-${e.rowIndex}`,
1668
1687
  class: "block w-full border border-slate-200 rounded-lg px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-400 bg-slate-50 hover:bg-white transition-colors"
1669
1688
  }, [
1670
1689
  l[15] || (l[15] = t("option", { value: "" }, "Selecciona...", -1)),
1671
- (s(!0), i(B, null, V(g.width, (n) => (s(), i("option", {
1672
- key: n.value,
1673
- value: n.value
1674
- }, v(n.label), 9, Fl))), 128))
1675
- ], 8, Sl), [
1676
- [J, u.value]
1690
+ (a(!0), r(B, null, V(g.width, (i) => (a(), r("option", {
1691
+ key: i.value,
1692
+ value: i.value
1693
+ }, p(i.label), 9, Ml))), 128))
1694
+ ], 8, jl), [
1695
+ [J, c.value]
1677
1696
  ])
1678
1697
  ]),
1679
1698
  t("button", {
1680
1699
  type: "submit",
1681
1700
  class: "bg-gradient-to-r from-emerald-500 to-teal-500 hover:from-emerald-600 hover:to-teal-600 text-white px-5 py-2 rounded-lg font-medium shadow-sm hover:shadow-md transition-all duration-200 cursor-pointer",
1682
- onClick: l[8] || (l[8] = (n) => {
1683
- I(e.rowIndex), b.value = !1;
1701
+ onClick: l[8] || (l[8] = (i) => {
1702
+ M(e.rowIndex), b.value = !1;
1684
1703
  })
1685
1704
  }, " Guardar ")
1686
1705
  ], 32)
1687
1706
  ])
1688
- ])) : F("", !0)
1707
+ ])) : P("", !0)
1689
1708
  ], 64));
1690
1709
  }
1691
- }), jl = ["id"], Il = { class: "flex flex-row w-full gap-3 mt-6" }, Ml = ["id"], Al = /* @__PURE__ */ H({
1710
+ }), Al = ["id"], Bl = { class: "flex flex-row w-full gap-3 mt-6" }, El = ["id"], Tl = /* @__PURE__ */ H({
1692
1711
  __name: "BodySection",
1693
1712
  props: {
1694
1713
  isComponentMode: Boolean,
@@ -1712,19 +1731,19 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1712
1731
  }
1713
1732
  },
1714
1733
  setup(e) {
1715
- const o = e, g = S(!1), x = Q(() => {
1716
- var u;
1717
- const f = (u = o.globalPageConfiguration) == null ? void 0 : u.find(
1718
- (r) => r.section === o.sectionSelected
1734
+ const o = e, g = S(!1), h = K(() => {
1735
+ var c;
1736
+ const f = (c = o.globalPageConfiguration) == null ? void 0 : c.find(
1737
+ (n) => n.section === o.sectionSelected
1719
1738
  );
1720
1739
  return (f == null ? void 0 : f.rows) || [];
1721
1740
  });
1722
- return (f, u) => (s(!0), i(B, null, V(x.value, (r, b) => (s(), i("div", {
1741
+ return (f, c) => (a(!0), r(B, null, V(h.value, (n, b) => (a(), r("div", {
1723
1742
  key: "row-" + b,
1724
1743
  id: "row-" + e.sectionSelected + "-" + b,
1725
1744
  class: "flex flex-col gap-3 w-full p-5 bg-white border border-slate-200 rounded-2xl js-row relative items-center hover:border-slate-300 hover:shadow-lg transition-all duration-300 css-pb-row group/row"
1726
1745
  }, [
1727
- q(Pl, {
1746
+ L(Il, {
1728
1747
  moveRow: e.moveRow,
1729
1748
  addRow: e.addRow,
1730
1749
  removeRow: e.removeRow,
@@ -1733,28 +1752,28 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1733
1752
  rowIndex: b,
1734
1753
  section: e.sectionSelected
1735
1754
  }, null, 8, ["moveRow", "addRow", "removeRow", "globalPageConfiguration", "updateRowConfig", "rowIndex", "section"]),
1736
- t("div", Il, [
1737
- (s(!0), i(B, null, V(r.columns, (C, I) => (s(), i("div", {
1738
- class: L([
1755
+ t("div", Bl, [
1756
+ (a(!0), r(B, null, V(n.columns, ($, M) => (a(), r("div", {
1757
+ class: G([
1739
1758
  "hover:shadow-md overflow-hidden dragging-zone border relative border-slate-200 shadow-sm w-full p-5 pt-10 min-h-[200px] rounded-xl flex flex-col gap-3 items-center before:content-['Columna'] before:absolute before:text-slate-300 before:text-7xl before:font-bold before:bottom-4 before:left-2 before:-rotate-12 before:opacity-30 before:duration-300 before:transition-opacity group hover:before:opacity-50 transition-all duration-300",
1740
1759
  g.value ? "bg-gradient-to-b from-emerald-50 to-emerald-100 border-emerald-300 shadow-emerald-100" : "bg-gradient-to-b from-slate-50 to-slate-100"
1741
1760
  ]),
1742
- key: "column-" + I,
1743
- id: "col-" + e.sectionSelected + "-" + b + "-" + I
1761
+ key: "column-" + M,
1762
+ id: "col-" + e.sectionSelected + "-" + b + "-" + M
1744
1763
  }, [
1745
- q(G(ue), {
1764
+ L(q(ue), {
1746
1765
  class: "h-full w-full mb-4",
1747
- list: C.components,
1766
+ list: $.components,
1748
1767
  group: { name: "draggingGroup", pull: !0, put: !0 },
1749
1768
  "item-key": "name",
1750
1769
  handle: ".handle",
1751
- onStart: u[0] || (u[0] = (a) => g.value = !0),
1752
- onEnd: u[1] || (u[1] = (a) => g.value = !1)
1770
+ onStart: c[0] || (c[0] = (s) => g.value = !0),
1771
+ onEnd: c[1] || (c[1] = (s) => g.value = !1)
1753
1772
  }, {
1754
- item: de(({ element: a }) => [
1755
- q(ce, {
1773
+ item: de(({ element: s }) => [
1774
+ L(ce, {
1756
1775
  renderApiDomain: e.renderApiDomain,
1757
- object: a,
1776
+ object: s,
1758
1777
  "is-component-mode": e.isComponentMode,
1759
1778
  removeComponent: e.removeComponent,
1760
1779
  section: e.sectionSelected,
@@ -1763,7 +1782,7 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1763
1782
  ]),
1764
1783
  _: 1
1765
1784
  }, 8, ["list"]),
1766
- q(tl, {
1785
+ L(nl, {
1767
1786
  section: e.sectionSelected,
1768
1787
  globalPageConfiguration: e.globalPageConfiguration,
1769
1788
  updateColConfig: e.updateColConfig,
@@ -1773,16 +1792,16 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1773
1792
  removeCol: e.removeCol,
1774
1793
  moveCol: e.moveCol,
1775
1794
  rowIndex: b,
1776
- columnIndex: I
1795
+ columnIndex: M
1777
1796
  }, null, 8, ["section", "globalPageConfiguration", "updateColConfig", "addComponentFunction", "fullwidthMode", "addCol", "removeCol", "moveCol", "rowIndex", "columnIndex"])
1778
- ], 10, Ml))), 128))
1797
+ ], 10, El))), 128))
1779
1798
  ])
1780
- ], 8, jl))), 128));
1799
+ ], 8, Al))), 128));
1781
1800
  }
1782
- }), Bl = { class: "flex justify-between items-center mb-4" }, El = { class: "text-xs" }, Tl = { class: "flex flex-wrap gap-2 mb-4 bg-white border border-slate-200 p-4 rounded-xl shadow-sm" }, Dl = ["value", "checked"], Ol = { class: "my-3" }, Nl = { class: "relative" }, Rl = { class: "component-library dragging-zone w-full p-5 min-h-[200px] border border-slate-200 bg-white rounded-xl flex flex-col gap-4 items-center shadow-sm" }, Vl = {
1801
+ }), Dl = { class: "flex justify-between items-center mb-4" }, Ol = { class: "text-xs" }, Rl = { class: "flex flex-wrap gap-2 mb-4 bg-white border border-slate-200 p-4 rounded-xl shadow-sm" }, Nl = ["value", "checked"], Vl = { class: "my-3" }, Ul = { class: "relative" }, zl = { class: "component-library dragging-zone w-full p-5 min-h-[200px] border border-slate-200 bg-white rounded-xl flex flex-col gap-4 items-center shadow-sm" }, ql = {
1783
1802
  key: 0,
1784
1803
  class: "text-center py-8 text-slate-400"
1785
- }, re = /* @__PURE__ */ H({
1804
+ }, se = /* @__PURE__ */ H({
1786
1805
  __name: "ComponentsBox",
1787
1806
  props: {
1788
1807
  isComponentMode: Boolean,
@@ -1809,25 +1828,25 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1809
1828
  "Formulario",
1810
1829
  "Título",
1811
1830
  "SEO"
1812
- ], g = S(!0), x = S([]), f = S(""), u = S(ve()), r = Q(() => {
1813
- const I = f.value.toLowerCase(), a = Object.values(u.value), l = (n) => (n.name.toLowerCase() + n.description.toLowerCase() + n.tags.join(" ").toLowerCase()).includes(I);
1814
- return x.value.length > 0 ? a.filter(
1815
- (n) => x.value.includes(n.category) && l(n)
1816
- ) : a.filter(l);
1817
- }), b = (I) => {
1818
- f.value = I.target.value;
1819
- }, C = (I) => {
1820
- const a = I.target, l = a.value;
1821
- a.checked ? x.value.includes(l) || x.value.push(l) : x.value = x.value.filter((n) => n !== l);
1831
+ ], g = S(!0), h = S([]), f = S(""), c = S(ve()), n = K(() => {
1832
+ const M = f.value.toLowerCase(), s = Object.values(c.value), l = (i) => (i.name.toLowerCase() + i.description.toLowerCase() + i.tags.join(" ").toLowerCase()).includes(M);
1833
+ return h.value.length > 0 ? s.filter(
1834
+ (i) => h.value.includes(i.category) && l(i)
1835
+ ) : s.filter(l);
1836
+ }), b = (M) => {
1837
+ f.value = M.target.value;
1838
+ }, $ = (M) => {
1839
+ const s = M.target, l = s.value;
1840
+ s.checked ? h.value.includes(l) || h.value.push(l) : h.value = h.value.filter((i) => i !== l);
1822
1841
  };
1823
- return (I, a) => (s(), i(B, null, [
1824
- a[6] || (a[6] = t("h1", { class: "text-center text-2xl font-semibold mb-4 text-slate-700 tracking-tight" }, "Componentes", -1)),
1825
- t("div", Bl, [
1842
+ return (M, s) => (a(), r(B, null, [
1843
+ s[6] || (s[6] = t("h1", { class: "text-center text-2xl font-semibold mb-4 text-slate-700 tracking-tight" }, "Componentes", -1)),
1844
+ t("div", Dl, [
1826
1845
  t("button", {
1827
- onClick: a[0] || (a[0] = (l) => g.value = !g.value),
1846
+ onClick: s[0] || (s[0] = (l) => g.value = !g.value),
1828
1847
  class: "mb-3 px-4 py-2 bg-white rounded-lg border border-slate-200 hover:border-slate-300 hover:shadow-sm transition-all duration-200 cursor-pointer text-slate-600 font-medium flex items-center gap-2"
1829
1848
  }, [
1830
- a[2] || (a[2] = t("svg", {
1849
+ s[2] || (s[2] = t("svg", {
1831
1850
  class: "w-4 h-4",
1832
1851
  fill: "none",
1833
1852
  stroke: "currentColor",
@@ -1840,37 +1859,37 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1840
1859
  d: "M3 4a1 1 0 011-1h16a1 1 0 011 1v2.586a1 1 0 01-.293.707l-6.414 6.414a1 1 0 00-.293.707V17l-4 4v-6.586a1 1 0 00-.293-.707L3.293 7.293A1 1 0 013 6.586V4z"
1841
1860
  })
1842
1861
  ], -1)),
1843
- a[3] || (a[3] = t("span", null, "Filtros", -1)),
1844
- t("span", El, v(g.value ? "▲" : "▼"), 1)
1862
+ s[3] || (s[3] = t("span", null, "Filtros", -1)),
1863
+ t("span", Ol, p(g.value ? "▲" : "▼"), 1)
1845
1864
  ]),
1846
1865
  t("button", {
1847
- class: L([[e.isComponentMode ? "bg-gradient-to-r from-slate-600 to-slate-700 border-slate-700 text-white shadow-md" : "bg-white hover:bg-slate-100"], "cursor-pointer border border-slate-200 rounded-lg py-1.5 px-3 text-sm font-medium transition-all duration-200"]),
1848
- onClick: a[1] || (a[1] = (l) => {
1849
- var n;
1850
- return (n = e.toggleComponentModeFunction) == null ? void 0 : n.call(e);
1866
+ class: G([[e.isComponentMode ? "bg-gradient-to-r from-slate-600 to-slate-700 border-slate-700 text-white shadow-md" : "bg-white hover:bg-slate-100"], "cursor-pointer border border-slate-200 rounded-lg py-1.5 px-3 text-sm font-medium transition-all duration-200"]),
1867
+ onClick: s[1] || (s[1] = (l) => {
1868
+ var i;
1869
+ return (i = e.toggleComponentModeFunction) == null ? void 0 : i.call(e);
1851
1870
  })
1852
- }, v(e.isComponentMode ? "⚒️ Modo Configuración" : "👁️ Modo Visual"), 3)
1871
+ }, p(e.isComponentMode ? "⚒️ Modo Configuración" : "👁️ Modo Visual"), 3)
1853
1872
  ]),
1854
- N(t("div", Tl, [
1855
- (s(), i(B, null, V(o, (l) => t("label", {
1873
+ R(t("div", Rl, [
1874
+ (a(), r(B, null, V(o, (l) => t("label", {
1856
1875
  key: l,
1857
- class: L(["flex items-center gap-2 text-xs bg-slate-50 hover:bg-slate-100 px-3 py-2 rounded-lg cursor-pointer transition-colors duration-200 border border-transparent hover:border-slate-200", { "bg-emerald-50 border-emerald-200 text-emerald-700": x.value.includes(l) }])
1876
+ class: G(["flex items-center gap-2 text-xs bg-slate-50 hover:bg-slate-100 px-3 py-2 rounded-lg cursor-pointer transition-colors duration-200 border border-transparent hover:border-slate-200", { "bg-emerald-50 border-emerald-200 text-emerald-700": h.value.includes(l) }])
1858
1877
  }, [
1859
1878
  t("input", {
1860
1879
  type: "checkbox",
1861
1880
  value: l,
1862
- checked: x.value.includes(l),
1863
- onInput: C,
1881
+ checked: h.value.includes(l),
1882
+ onInput: $,
1864
1883
  class: "w-4 h-4 rounded border-slate-300 text-emerald-500 focus:ring-emerald-500"
1865
- }, null, 40, Dl),
1866
- T(" " + v(l), 1)
1884
+ }, null, 40, Nl),
1885
+ T(" " + p(l), 1)
1867
1886
  ], 2)), 64))
1868
1887
  ], 512), [
1869
- [ge, g.value]
1888
+ [fe, g.value]
1870
1889
  ]),
1871
- t("div", Ol, [
1872
- t("div", Nl, [
1873
- a[4] || (a[4] = t("svg", {
1890
+ t("div", Vl, [
1891
+ t("div", Ul, [
1892
+ s[4] || (s[4] = t("svg", {
1874
1893
  class: "absolute left-3 top-1/2 -translate-y-1/2 w-5 h-5 text-slate-400",
1875
1894
  fill: "none",
1876
1895
  stroke: "currentColor",
@@ -1891,16 +1910,16 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1891
1910
  }, null, 32)
1892
1911
  ])
1893
1912
  ]),
1894
- t("div", Rl, [
1895
- q(G(ue), {
1913
+ t("div", zl, [
1914
+ L(q(ue), {
1896
1915
  class: "w-full flex flex-col gap-4",
1897
- list: r.value,
1916
+ list: n.value,
1898
1917
  group: { name: "draggingGroup", pull: "clone", put: !1 },
1899
1918
  itemKey: "name",
1900
1919
  clone: (l) => JSON.parse(JSON.stringify(l))
1901
1920
  }, {
1902
1921
  item: de(({ element: l }) => [
1903
- q(ce, {
1922
+ L(ce, {
1904
1923
  renderApiDomain: e.renderApiDomain,
1905
1924
  object: l,
1906
1925
  "is-component-mode": e.isComponentMode,
@@ -1913,7 +1932,7 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1913
1932
  ]),
1914
1933
  _: 1
1915
1934
  }, 8, ["list", "clone"]),
1916
- r.value.length === 0 ? (s(), i("div", Vl, [...a[5] || (a[5] = [
1935
+ n.value.length === 0 ? (a(), r("div", ql, [...s[5] || (s[5] = [
1917
1936
  t("svg", {
1918
1937
  class: "w-12 h-12 mx-auto mb-3 opacity-50",
1919
1938
  fill: "none",
@@ -1929,23 +1948,25 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1929
1948
  ], -1),
1930
1949
  t("p", { class: "text-sm font-medium" }, "No se encontraron componentes", -1),
1931
1950
  t("p", { class: "text-xs mt-1" }, "Intenta con otros filtros o términos de búsqueda", -1)
1932
- ])])) : F("", !0)
1951
+ ])])) : P("", !0)
1933
1952
  ])
1934
1953
  ], 64));
1935
1954
  }
1936
- }), Ul = { class: "flex flex-col w-full transition-all duration-300 lf-page-builder bg-gradient-to-br from-slate-50 to-slate-100 min-h-screen" }, zl = { class: "relative flex flex-row flex-wrap" }, ql = { class: "w-full flex justify-end py-4 pe-4" }, Ll = { class: "w-3/4" }, Gl = {
1955
+ }), Ll = { class: "flex flex-col w-full transition-all duration-300 lf-page-builder bg-gradient-to-br from-slate-50 to-slate-100 min-h-screen" }, Gl = { class: "relative flex flex-row flex-wrap" }, Jl = { class: "w-full flex justify-end py-4 pe-4" }, Hl = { class: "w-3/4" }, Wl = {
1937
1956
  key: 1,
1938
1957
  class: "w-1/4 px-3 overflow-y-auto h-screen sticky top-0"
1939
- }, Ql = /* @__PURE__ */ H({
1958
+ }, Zl = /* @__PURE__ */ H({
1940
1959
  __name: "Pagebuilder",
1941
1960
  props: {
1942
1961
  isProduction: { type: Boolean },
1962
+ debugMode: { type: Boolean },
1943
1963
  inputId: {}
1944
1964
  },
1945
1965
  setup(e) {
1946
- const o = e, g = o.isProduction ?? !1, x = o.inputId ?? null, f = g ? "https://render-api.lefebvre.es" : "https://led-dev-astro-render-api-dev.eu.els.local", u = S(!0), r = S(void 0), b = S([]), C = S({ rowIndex: null, columnIndex: null, section: null }), I = S(!1), a = S(!1), l = S({
1966
+ const o = e, g = o.isProduction ?? !1, h = o.debugMode ?? !1, f = o.inputId ?? null, c = g ? "https://render-api.lefebvre.es" : "https://led-dev-astro-render-api-dev.eu.els.local", n = S(!0), b = S(void 0), $ = S([]), M = S({ rowIndex: null, columnIndex: null, section: null }), s = S(!1), l = S(!1), i = S({
1947
1967
  global: {
1948
1968
  sidebarEnabled: !1,
1969
+ renderAsBodyPart: !1,
1949
1970
  headSlot: "",
1950
1971
  bodyBeginSlot: "",
1951
1972
  footerSlot: ""
@@ -1955,7 +1976,7 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1955
1976
  description: "",
1956
1977
  robots: "index, follow"
1957
1978
  }
1958
- }), n = fe([
1979
+ }), m = pe([
1959
1980
  {
1960
1981
  section: "Header",
1961
1982
  config: { width: "full" },
@@ -1977,187 +1998,188 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
1977
1998
  rows: [{ config: {}, columns: [{ config: {}, components: [] }] }]
1978
1999
  }
1979
2000
  ]);
1980
- oe(() => {
1981
- m();
2001
+ le(() => {
2002
+ k();
1982
2003
  });
1983
- const m = () => {
1984
- if (b.value = ["Header", "Footer", "Body", "Sidebar"], r.value = "Body", x) {
1985
- const y = document.getElementById(x);
2004
+ const k = () => {
2005
+ if ($.value = ["Header", "Footer", "Body", "Sidebar"], b.value = "Body", f) {
2006
+ const y = document.getElementById(f);
1986
2007
  if (y) {
1987
- const h = y.value;
1988
- if (h)
2008
+ const x = y.value;
2009
+ if (x)
1989
2010
  try {
1990
- const p = typeof h == "string" ? JSON.parse(h) : h;
1991
- (p && typeof p == "object" && !Array.isArray(p) ? Object.keys(p).length > 0 : Array.isArray(p) ? p.length > 0 : !1) && ne(h);
1992
- } catch (p) {
1993
- console.error("Error parsing input value:", p);
2011
+ const v = typeof x == "string" ? JSON.parse(x) : x;
2012
+ (v && typeof v == "object" && !Array.isArray(v) ? Object.keys(v).length > 0 : Array.isArray(v) ? v.length > 0 : !1) && ae(x);
2013
+ } catch (v) {
2014
+ console.error("Error parsing input value:", v);
1994
2015
  }
1995
2016
  }
1996
2017
  }
1997
- }, k = () => {
1998
- a.value = !a.value;
1999
- }, A = () => {
2000
- u.value = !u.value;
2001
- }, w = (y, h, p, P, M) => {
2018
+ }, I = () => {
2019
+ l.value = !l.value;
2020
+ }, w = () => {
2021
+ n.value = !n.value;
2022
+ }, d = (y, x, v, F, A) => {
2002
2023
  var O;
2003
- const E = n.find((U) => U.section === h);
2024
+ const E = m.find((U) => U.section === x);
2004
2025
  (O = E == null ? void 0 : E.rows) != null && O[y] && (E.rows[y].config = {
2005
- padding: p,
2006
- gap: P,
2007
- width: M
2026
+ padding: v,
2027
+ gap: F,
2028
+ width: A
2008
2029
  });
2009
- }, d = (y, h, p, P, M, E) => {
2030
+ }, u = (y, x, v, F, A, E) => {
2010
2031
  var U, z, W;
2011
- const O = n.find((X) => X.section === p);
2012
- (W = (z = (U = O == null ? void 0 : O.rows) == null ? void 0 : U[y]) == null ? void 0 : z.columns) != null && W[h] && (O.rows[y].columns[h].config = {
2013
- width: P,
2014
- gap: M,
2032
+ const O = m.find((Q) => Q.section === v);
2033
+ (W = (z = (U = O == null ? void 0 : O.rows) == null ? void 0 : U[y]) == null ? void 0 : z.columns) != null && W[x] && (O.rows[y].columns[x].config = {
2034
+ width: F,
2035
+ gap: A,
2015
2036
  flexDirection: E
2016
2037
  });
2017
- }, c = async (y, h) => {
2018
- const p = n.find((P) => P.section === h);
2019
- if (p) {
2020
- const P = {
2038
+ }, C = async (y, x) => {
2039
+ const v = m.find((F) => F.section === x);
2040
+ if (v) {
2041
+ const F = {
2021
2042
  config: {},
2022
2043
  columns: [{ config: {}, components: [] }]
2023
2044
  };
2024
- y !== null && y >= 0 && y < p.rows.length ? p.rows.splice(y + 1, 0, P) : p.rows.push(P);
2045
+ y !== null && y >= 0 && y < v.rows.length ? v.rows.splice(y + 1, 0, F) : v.rows.push(F);
2025
2046
  }
2026
- await new Promise((P) => {
2047
+ await new Promise((F) => {
2027
2048
  setTimeout(() => {
2028
- const M = document.getElementById(`row-${h}-${(y ?? 0) + 1}`);
2029
- M ? (M.scrollIntoView({ behavior: "smooth", block: "center" }), M.classList.add("selected-delay"), setTimeout(() => {
2030
- M.classList.remove("selected-delay"), P();
2031
- }, 3e3)) : P();
2049
+ const A = document.getElementById(`row-${x}-${(y ?? 0) + 1}`);
2050
+ A ? (A.scrollIntoView({ behavior: "smooth", block: "center" }), A.classList.add("selected-delay"), setTimeout(() => {
2051
+ A.classList.remove("selected-delay"), F();
2052
+ }, 3e3)) : F();
2032
2053
  }, 0);
2033
2054
  });
2034
- }, $ = (y, h) => {
2035
- const p = n.find((P) => P.section === h);
2036
- !(p != null && p.rows) || p.rows.length <= 1 || p.rows.splice(y, 1);
2037
- }, j = (y, h, p = "down") => {
2055
+ }, j = (y, x) => {
2056
+ const v = m.find((F) => F.section === x);
2057
+ !(v != null && v.rows) || v.rows.length <= 1 || v.rows.splice(y, 1);
2058
+ }, D = (y, x, v = "down") => {
2038
2059
  var U;
2039
- const P = n.find((z) => z.section === h);
2040
- if (!((U = P == null ? void 0 : P.rows) != null && U[y]) || p === "up" && y === 0 || p === "down" && y === P.rows.length - 1)
2060
+ const F = m.find((z) => z.section === x);
2061
+ if (!((U = F == null ? void 0 : F.rows) != null && U[y]) || v === "up" && y === 0 || v === "down" && y === F.rows.length - 1)
2041
2062
  return;
2042
- const M = P.rows, E = M.splice(y, 1)[0], O = p === "down" ? y + 1 : y - 1;
2043
- M.splice(O, 0, E);
2044
- }, D = async (y, h, p, P = "right") => {
2063
+ const A = F.rows, E = A.splice(y, 1)[0], O = v === "down" ? y + 1 : y - 1;
2064
+ A.splice(O, 0, E);
2065
+ }, N = async (y, x, v, F = "right") => {
2045
2066
  var O;
2046
- const M = P === "left" ? h : h + 1, E = n.find((U) => U.section === p);
2047
- (O = E == null ? void 0 : E.rows) != null && O[y] && E.rows[y].columns.splice(M, 0, {
2067
+ const A = F === "left" ? x : x + 1, E = m.find((U) => U.section === v);
2068
+ (O = E == null ? void 0 : E.rows) != null && O[y] && E.rows[y].columns.splice(A, 0, {
2048
2069
  config: {},
2049
2070
  components: []
2050
2071
  }), await new Promise((U) => {
2051
2072
  setTimeout(() => {
2052
- const z = document.getElementById(`col-${p}-${y}-${M}`);
2073
+ const z = document.getElementById(`col-${v}-${y}-${A}`);
2053
2074
  z ? (z.scrollIntoView({ behavior: "smooth", block: "center" }), z.classList.add("selected-delay"), setTimeout(() => {
2054
2075
  z.classList.remove("selected-delay"), U();
2055
2076
  }, 3e3)) : U();
2056
2077
  }, 0);
2057
2078
  });
2058
- }, R = (y, h, p) => {
2079
+ }, X = (y, x, v) => {
2059
2080
  var E, O;
2060
- const P = n.find((U) => U.section === p), M = (O = (E = P == null ? void 0 : P.rows) == null ? void 0 : E[y]) == null ? void 0 : O.columns;
2061
- !M || M.length <= 1 || M.splice(h, 1);
2062
- }, Y = (y, h, p, P = "right") => {
2081
+ const F = m.find((U) => U.section === v), A = (O = (E = F == null ? void 0 : F.rows) == null ? void 0 : E[y]) == null ? void 0 : O.columns;
2082
+ !A || A.length <= 1 || A.splice(x, 1);
2083
+ }, Z = (y, x, v, F = "right") => {
2063
2084
  var z;
2064
- const M = n.find((W) => W.section === p);
2065
- if (!((z = M == null ? void 0 : M.rows) != null && z[y]) || P === "left" && h === 0 || P === "right" && h === M.rows[y].columns.length - 1)
2085
+ const A = m.find((W) => W.section === v);
2086
+ if (!((z = A == null ? void 0 : A.rows) != null && z[y]) || F === "left" && x === 0 || F === "right" && x === A.rows[y].columns.length - 1)
2066
2087
  return;
2067
- const E = M.rows[y].columns, O = E.splice(h, 1)[0], U = P === "right" ? h + 1 : h - 1;
2088
+ const E = A.rows[y].columns, O = E.splice(x, 1)[0], U = F === "right" ? x + 1 : x - 1;
2068
2089
  E.splice(U, 0, O);
2069
- }, Z = (y, h) => {
2070
- var P;
2071
- const p = n.find((M) => M.section === h);
2072
- (P = p == null ? void 0 : p.rows) == null || P.forEach((M) => {
2073
- M.columns.forEach((E) => {
2090
+ }, _ = (y, x) => {
2091
+ var F;
2092
+ const v = m.find((A) => A.section === x);
2093
+ (F = v == null ? void 0 : v.rows) == null || F.forEach((A) => {
2094
+ A.columns.forEach((E) => {
2074
2095
  const O = E.components.indexOf(y);
2075
2096
  O !== -1 && E.components.splice(O, 1);
2076
2097
  });
2077
2098
  });
2078
- }, _ = (y, h, p) => {
2079
- I.value = !0, C.value = { rowIndex: y, columnIndex: h, section: p };
2080
- }, le = (y) => {
2081
- var M, E, O, U;
2082
- const { rowIndex: h, columnIndex: p, section: P } = C.value;
2083
- if (h !== null && p !== null) {
2084
- const z = JSON.parse(JSON.stringify(y)), W = n.find((me) => me.section === P), X = (U = (O = (E = (M = W == null ? void 0 : W.rows) == null ? void 0 : M[h]) == null ? void 0 : E.columns) == null ? void 0 : O[p]) == null ? void 0 : U.components;
2085
- X == null || X.push(z);
2086
- }
2087
- I.value = !1;
2099
+ }, me = (y, x, v) => {
2100
+ s.value = !0, M.value = { rowIndex: y, columnIndex: x, section: v };
2088
2101
  }, ne = (y) => {
2089
- const h = typeof y == "string" ? JSON.parse(y) : y;
2090
- n.length = 0, n.push(...h.pageConfig || []), h.paramsConfig && (l.value = { ...l.value, ...h.paramsConfig });
2102
+ var A, E, O, U;
2103
+ const { rowIndex: x, columnIndex: v, section: F } = M.value;
2104
+ if (x !== null && v !== null) {
2105
+ const z = JSON.parse(JSON.stringify(y)), W = m.find((be) => be.section === F), Q = (U = (O = (E = (A = W == null ? void 0 : W.rows) == null ? void 0 : A[x]) == null ? void 0 : E.columns) == null ? void 0 : O[v]) == null ? void 0 : U.components;
2106
+ Q == null || Q.push(z);
2107
+ }
2108
+ s.value = !1;
2109
+ }, ae = (y) => {
2110
+ const x = typeof y == "string" ? JSON.parse(y) : y;
2111
+ m.length = 0, m.push(...x.pageConfig || []), x.paramsConfig && (i.value = { ...i.value, ...x.paramsConfig });
2091
2112
  };
2092
- return (y, h) => (s(), i("div", Ul, [
2093
- q(tt, {
2094
- sectionSelected: r.value,
2095
- "onUpdate:sectionSelected": h[0] || (h[0] = (p) => r.value = p),
2096
- parametersPageConfiguration: l.value,
2097
- "onUpdate:parametersPageConfiguration": h[1] || (h[1] = (p) => l.value = p),
2098
- globalPageConfiguration: n,
2099
- availableSections: b.value,
2100
- importConfigurationFunction: ne,
2101
- isComponentMode: a.value,
2102
- toggleComponentModeFunction: k,
2103
- fullwidthMode: u.value,
2104
- toggleFullwidthMode: A,
2105
- renderApiDomain: G(f),
2106
- inputId: G(x)
2107
- }, null, 8, ["sectionSelected", "parametersPageConfiguration", "globalPageConfiguration", "availableSections", "isComponentMode", "fullwidthMode", "renderApiDomain", "inputId"]),
2108
- t("div", zl, [
2109
- u.value ? (s(), i("div", {
2113
+ return (y, x) => (a(), r("div", Ll, [
2114
+ L(nt, {
2115
+ sectionSelected: b.value,
2116
+ "onUpdate:sectionSelected": x[0] || (x[0] = (v) => b.value = v),
2117
+ parametersPageConfiguration: i.value,
2118
+ "onUpdate:parametersPageConfiguration": x[1] || (x[1] = (v) => i.value = v),
2119
+ globalPageConfiguration: m,
2120
+ availableSections: $.value,
2121
+ importConfigurationFunction: ae,
2122
+ isComponentMode: l.value,
2123
+ toggleComponentModeFunction: I,
2124
+ fullwidthMode: n.value,
2125
+ toggleFullwidthMode: w,
2126
+ renderApiDomain: q(c),
2127
+ inputId: q(f),
2128
+ debugMode: q(h)
2129
+ }, null, 8, ["sectionSelected", "parametersPageConfiguration", "globalPageConfiguration", "availableSections", "isComponentMode", "fullwidthMode", "renderApiDomain", "inputId", "debugMode"]),
2130
+ t("div", Gl, [
2131
+ n.value ? (a(), r("div", {
2110
2132
  key: 0,
2111
- class: L(["w-full overflow-y-auto fixed top-0 left-0 h-full bg-gradient-to-br from-slate-100 via-white to-slate-50 z-9999 px-4 flex justify-start flex flex-col items-center backdrop-blur-sm", I.value ? "" : "hidden"])
2133
+ class: G(["w-full overflow-y-auto fixed top-0 left-0 h-full bg-gradient-to-br from-slate-100 via-white to-slate-50 z-9999 px-4 flex justify-start flex flex-col items-center backdrop-blur-sm", s.value ? "" : "hidden"])
2112
2134
  }, [
2113
- t("div", ql, [
2135
+ t("div", Jl, [
2114
2136
  t("div", {
2115
2137
  class: "cursor-pointer w-10 h-10 flex items-center justify-center rounded-full bg-white shadow-md hover:shadow-lg hover:bg-red-50 text-slate-400 hover:text-red-500 transition-all duration-200 text-xl font-light",
2116
- onClick: h[2] || (h[2] = (p) => I.value = !1)
2138
+ onClick: x[2] || (x[2] = (v) => s.value = !1)
2117
2139
  }, "✕")
2118
2140
  ]),
2119
- t("div", Ll, [
2120
- q(re, {
2121
- renderApiDomain: G(f),
2122
- isComponentMode: a.value,
2123
- fullwidthMode: u.value,
2124
- columnToInsert: C.value,
2125
- addComponentToColumn: le,
2126
- toggleComponentModeFunction: k,
2127
- isProduction: G(g)
2141
+ t("div", Hl, [
2142
+ L(se, {
2143
+ renderApiDomain: q(c),
2144
+ isComponentMode: l.value,
2145
+ fullwidthMode: n.value,
2146
+ columnToInsert: M.value,
2147
+ addComponentToColumn: ne,
2148
+ toggleComponentModeFunction: I,
2149
+ isProduction: q(g)
2128
2150
  }, null, 8, ["renderApiDomain", "isComponentMode", "fullwidthMode", "columnToInsert", "isProduction"])
2129
2151
  ])
2130
- ], 2)) : (s(), i("div", Gl, [
2131
- q(re, {
2132
- renderApiDomain: G(f),
2133
- isComponentMode: a.value,
2134
- fullwidthMode: u.value,
2135
- columnToInsert: C.value,
2136
- addComponentToColumn: le,
2137
- toggleComponentModeFunction: k,
2138
- isProduction: G(g)
2152
+ ], 2)) : (a(), r("div", Wl, [
2153
+ L(se, {
2154
+ renderApiDomain: q(c),
2155
+ isComponentMode: l.value,
2156
+ fullwidthMode: n.value,
2157
+ columnToInsert: M.value,
2158
+ addComponentToColumn: ne,
2159
+ toggleComponentModeFunction: I,
2160
+ isProduction: q(g)
2139
2161
  }, null, 8, ["renderApiDomain", "isComponentMode", "fullwidthMode", "columnToInsert", "isProduction"])
2140
2162
  ])),
2141
2163
  t("div", {
2142
- class: L([u.value ? "w-full px-4" : "w-3/4 ps-3", "flex flex-col gap-5"])
2164
+ class: G([n.value ? "w-full px-4" : "w-3/4 ps-3", "flex flex-col gap-5"])
2143
2165
  }, [
2144
- q(Al, {
2145
- globalPageConfiguration: n,
2146
- isComponentMode: a.value,
2147
- removeComponent: Z,
2148
- addComponentFunction: _,
2149
- fullwidthMode: u.value,
2150
- addCol: D,
2151
- addRow: c,
2152
- removeRow: $,
2153
- removeCol: R,
2154
- moveCol: Y,
2155
- updateRowConfig: w,
2156
- updateColConfig: d,
2157
- moveRow: j,
2158
- sectionSelected: r.value,
2159
- renderApiDomain: G(f),
2160
- isProduction: G(g)
2166
+ L(Tl, {
2167
+ globalPageConfiguration: m,
2168
+ isComponentMode: l.value,
2169
+ removeComponent: _,
2170
+ addComponentFunction: me,
2171
+ fullwidthMode: n.value,
2172
+ addCol: N,
2173
+ addRow: C,
2174
+ removeRow: j,
2175
+ removeCol: X,
2176
+ moveCol: Z,
2177
+ updateRowConfig: d,
2178
+ updateColConfig: u,
2179
+ moveRow: D,
2180
+ sectionSelected: b.value,
2181
+ renderApiDomain: q(c),
2182
+ isProduction: q(g)
2161
2183
  }, null, 8, ["globalPageConfiguration", "isComponentMode", "fullwidthMode", "sectionSelected", "renderApiDomain", "isProduction"])
2162
2184
  ], 2)
2163
2185
  ])
@@ -2165,15 +2187,15 @@ const tt = /* @__PURE__ */ he(xe, [["render", et]]), ot = {
2165
2187
  }
2166
2188
  });
2167
2189
  export {
2168
- Al as BodySection,
2169
- tl as ColConfig,
2170
- re as ComponentsBox,
2171
- so as FeedComponent,
2172
- ae as FieldsForm,
2173
- tt as GlobalConfig,
2190
+ Tl as BodySection,
2191
+ nl as ColConfig,
2192
+ se as ComponentsBox,
2193
+ co as FeedComponent,
2194
+ re as FieldsForm,
2195
+ nt as GlobalConfig,
2174
2196
  ce as InitialComponent,
2175
- Ql as Pagebuilder,
2176
- Pl as RowConfig,
2177
- kt as SourceFilter,
2178
- Ql as default
2197
+ Zl as Pagebuilder,
2198
+ Il as RowConfig,
2199
+ Ft as SourceFilter,
2200
+ Zl as default
2179
2201
  };