builder-settings-types 0.0.217 → 0.0.218

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,8 @@
1
- const V = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
2
- let M = (c = 21) => {
1
+ const O = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
2
+ let I = (c = 21) => {
3
3
  let t = "", e = crypto.getRandomValues(new Uint8Array(c |= 0));
4
4
  for (; c--; )
5
- t += V[e[c] & 63];
5
+ t += O[e[c] & 63];
6
6
  return t;
7
7
  };
8
8
  function L(c) {
@@ -22,7 +22,7 @@ function L(c) {
22
22
  const e = Object.getPrototypeOf(c);
23
23
  return e !== Object.prototype && Object.setPrototypeOf(t, e), t;
24
24
  }
25
- function N(c) {
25
+ function H(c) {
26
26
  switch (c) {
27
27
  case "number":
28
28
  return 0;
@@ -40,12 +40,12 @@ function N(c) {
40
40
  return "";
41
41
  }
42
42
  }
43
- class p {
43
+ class g {
44
44
  constructor(t = {}) {
45
- this.props = t, this.id = t.id || M(), this.value = this.props.default, this.desktop = this.props.default, this.title = t.title || "", this.includeGetJson = t.includeGetJson !== void 0 ? t.includeGetJson : !0;
45
+ this.props = t, this.id = t.id || I(), this.value = this.props.default, this.desktop = this.props.default, this.title = t.title || "", this.includeGetJson = t.includeGetJson !== void 0 ? t.includeGetJson : !0;
46
46
  }
47
47
  static SetUploadUrl(t) {
48
- window.DefaultUploadUrl = t, p.DefaultUploadUrl = t;
48
+ window.DefaultUploadUrl = t, g.DefaultUploadUrl = t;
49
49
  }
50
50
  destroy() {
51
51
  throw new Error("Method not implemented.");
@@ -67,23 +67,23 @@ class p {
67
67
  t = { ...this.props.inputProps, ...t };
68
68
  const e = document.createElement("div");
69
69
  if (e.className = t.wrapperClassName || "", t.title || t.icon) {
70
- const a = document.createElement("div");
71
- if (a.className = "icon-container", t.icon) {
70
+ const o = document.createElement("div");
71
+ if (o.className = "icon-container", t.icon) {
72
72
  const l = this.createIcon(t.icon, t.iconClassName);
73
- a.appendChild(l);
73
+ o.appendChild(l);
74
74
  }
75
75
  if (t.title) {
76
76
  const l = this.createLabel(t.title, t.labelClassName);
77
- a.appendChild(l);
77
+ o.appendChild(l);
78
78
  }
79
- e.appendChild(a);
79
+ e.appendChild(o);
80
80
  }
81
81
  const i = document.createElement("div");
82
82
  i.className = t.wrapperClassName || "";
83
83
  const s = document.createElement("input");
84
- this.inputEl = s, s.value = String(t.value || N(t.inputType)), s.type = t.inputType, s.placeholder = t.placeholder || "", s.className = t.inputClassName || "";
85
- const n = (a) => {
86
- const l = a.target;
84
+ this.inputEl = s, s.value = String(t.value || H(t.inputType)), s.type = t.inputType, s.placeholder = t.placeholder || "", s.className = t.inputClassName || "";
85
+ const n = (o) => {
86
+ const l = o.target;
87
87
  let h = l.value;
88
88
  switch (t.inputType) {
89
89
  case "number":
@@ -108,10 +108,10 @@ class p {
108
108
  h = l.value;
109
109
  }
110
110
  this.value = h, this.onChange && this.onChange(this.value), this.props.detectChange && this.props.detectChange(this.value);
111
- }, o = (a) => {
112
- a.target, this.onBlur && this.onBlur(this.value);
111
+ }, a = (o) => {
112
+ o.target, this.onBlur && this.onBlur(this.value);
113
113
  };
114
- return s.addEventListener("input", n), s.addEventListener("change", n), s.addEventListener("blur", o), t.inputCustomizer && t.inputCustomizer(s), i.appendChild(s), e.appendChild(i), e;
114
+ return s.addEventListener("input", n), s.addEventListener("change", n), s.addEventListener("blur", a), t.inputCustomizer && t.inputCustomizer(s), i.appendChild(s), e.appendChild(i), e;
115
115
  }
116
116
  createLabel(t, e) {
117
117
  const i = document.createElement("span");
@@ -122,31 +122,31 @@ class p {
122
122
  return i.className = "input-icon " + (e || ""), i.innerHTML = t, i;
123
123
  }
124
124
  }
125
- function S(c) {
125
+ function T(c) {
126
126
  let t = 0, e = c.parentElement;
127
127
  for (; e; )
128
128
  e.classList.contains("setting-group") && e !== c && t++, e = e.parentElement;
129
129
  return t;
130
130
  }
131
- function x(c, t) {
131
+ function b(c, t) {
132
132
  const e = Math.min(Math.max(t, 0), 5);
133
133
  c.setAttribute("data-nesting-level", e.toString()), e > 0 ? c.style.setProperty("--visual-indent", `${e * 2}px`) : (c.style.removeProperty("--visual-indent"), c.style.marginLeft = "");
134
134
  }
135
- function k(c, t = 0) {
135
+ function M(c, t = 0) {
136
136
  c.querySelectorAll(":scope > .setting-group-content > .setting-group").forEach((i) => {
137
137
  const s = i, n = t + 1;
138
- x(s, n), k(s, n);
138
+ b(s, n), M(s, n);
139
139
  });
140
140
  }
141
- const I = {
141
+ const B = {
142
142
  maxLevel: 5,
143
143
  spacingMultiplier: 1,
144
144
  visualIndentMultiplier: 2,
145
145
  enableAutoDetection: !0
146
146
  };
147
- class O {
147
+ class A {
148
148
  constructor(t = {}) {
149
- this.observedElements = /* @__PURE__ */ new Set(), this.config = { ...I, ...t }, this.config.enableAutoDetection && this.setupAutoDetection();
149
+ this.observedElements = /* @__PURE__ */ new Set(), this.config = { ...B, ...t }, this.config.enableAutoDetection && this.setupAutoDetection();
150
150
  }
151
151
  /**
152
152
  * Setup automatic detection using MutationObserver
@@ -180,7 +180,7 @@ class O {
180
180
  * Update nesting for a specific element
181
181
  */
182
182
  updateElementNesting(t) {
183
- const e = S(t);
183
+ const e = T(t);
184
184
  this.applyNestingWithConfig(t, e);
185
185
  }
186
186
  /**
@@ -228,23 +228,23 @@ class O {
228
228
  this.observer && (this.observer.disconnect(), this.observer = void 0), this.observedElements.clear();
229
229
  }
230
230
  }
231
- const H = new O();
231
+ const N = new A();
232
232
  function w(c, t) {
233
233
  for (const e in c)
234
- if (c.hasOwnProperty(e)) {
234
+ if (Object.prototype.hasOwnProperty.call(c, e)) {
235
235
  const i = c[e];
236
236
  t(e, i);
237
237
  }
238
238
  }
239
- const g = class g {
239
+ const p = class p {
240
240
  constructor(t) {
241
241
  this.elementRef = null, this.isHidden = !1, this.custom = !1, this.initialValues = {}, this.changeTimeout = null, this.isHandlingChange = !1, this.changeHandlers = /* @__PURE__ */ new Set(), this.blurTimeout = null, this.lastChangeTime = 0, this.handleBlur = () => {
242
- }, this.pendingBlurHandler = null, this.originalDefaultValues = {}, this.nestingLevel = 0, this.parentNestingLevel = 0, this.id = t.id || M(), this.title = t.title, this.settings = t.settings, this.description = t.description, this.icon = t.icon, this.isCollapsed = t.collapsed ?? !1, this.isMain = t.main ?? !1, this.custom = t.custom ?? !1, this.hideCondition = t.hideCondition, this.onBlur = t.onBlur, this.parentNestingLevel = t.parentNestingLevel ?? 0, this.nestingLevel = this.parentNestingLevel, this.includeGetJson = t.includeGetJson ?? !0, Object.assign(this, t.settings), this.initialValues = this.getValues(), this.originalDefaultValues = this.getDefaultValues(), this.propagateNestingLevel();
242
+ }, this.pendingBlurHandler = null, this.originalDefaultValues = {}, this.nestingLevel = 0, this.parentNestingLevel = 0, this.id = t.id || I(), this.title = t.title, this.settings = t.settings, this.description = t.description, this.icon = t.icon, this.isCollapsed = t.collapsed ?? !1, this.isMain = t.main ?? !1, this.custom = t.custom ?? !1, this.hideCondition = t.hideCondition, this.onBlur = t.onBlur, this.parentNestingLevel = t.parentNestingLevel ?? 0, this.nestingLevel = this.parentNestingLevel, this.includeGetJson = t.includeGetJson ?? !0, this.addItemCfg = t.addItem, Object.assign(this, t.settings), this.initialValues = this.getValues(), this.originalDefaultValues = this.getDefaultValues(), this.propagateNestingLevel();
243
243
  }
244
244
  propagateNestingLevel() {
245
245
  const t = this.nestingLevel + 1;
246
246
  w(this.settings, (e, i) => {
247
- i instanceof g && (i.parentNestingLevel = this.nestingLevel, i.nestingLevel = t, i.propagateNestingLevel());
247
+ i instanceof p && (i.parentNestingLevel = this.nestingLevel, i.nestingLevel = t, i.propagateNestingLevel());
248
248
  });
249
249
  }
250
250
  getNestingLevel() {
@@ -254,7 +254,7 @@ const g = class g {
254
254
  this.nestingLevel = t, this.propagateNestingLevel(), this.elementRef && this.updateNestingStyles();
255
255
  }
256
256
  updateNestingStyles() {
257
- this.elementRef && (x(this.elementRef, this.nestingLevel), k(this.elementRef, this.nestingLevel));
257
+ this.elementRef && (b(this.elementRef, this.nestingLevel), M(this.elementRef, this.nestingLevel));
258
258
  }
259
259
  static hide() {
260
260
  this.hiddenElements.forEach((t) => {
@@ -279,41 +279,35 @@ const g = class g {
279
279
  };
280
280
  return this.changeHandlers.clear(), w(this.settings, (i, s) => {
281
281
  var n;
282
- if (s instanceof g)
283
- s.setOnChange((o) => {
282
+ if (s instanceof p)
283
+ s.setOnChange(() => {
284
284
  const a = this.getValues();
285
285
  this.initialValues = a, t(a);
286
286
  }), this.changeHandlers.add(() => t(this.getValues()));
287
- else if (s instanceof p) {
288
- const o = () => {
289
- e();
290
- };
291
- this.changeHandlers.add(o), s.setOnChange(o);
287
+ else if (s instanceof g) {
288
+ const a = () => e();
289
+ this.changeHandlers.add(a), s.setOnChange(a);
292
290
  } else {
293
- const o = () => {
294
- e();
295
- };
296
- this.changeHandlers.add(o), (n = s.setOnChange) == null || n.call(s, o);
291
+ const a = () => e();
292
+ this.changeHandlers.add(a), (n = s.setOnChange) == null || n.call(s, a);
297
293
  }
298
294
  }), this;
299
295
  }
300
296
  setOnBlur(t) {
301
297
  return this.onBlur = t, this.pendingBlurHandler = t, this.handleBlur = (e) => {
302
- (e == null ? void 0 : e.target) instanceof HTMLElement && e.target.closest(".setting-group") !== this.elementRef || (this.blurTimeout && clearTimeout(this.blurTimeout), this.blurTimeout = setTimeout(() => {
303
- t();
304
- }, 100));
298
+ (e == null ? void 0 : e.target) instanceof HTMLElement && e.target.closest(".setting-group") !== this.elementRef || (this.blurTimeout && clearTimeout(this.blurTimeout), this.blurTimeout = setTimeout(() => t(), 100));
305
299
  }, this.elementRef && this.setupBlurHandlers(), this;
306
300
  }
307
301
  setupBlurHandlers() {
308
- this.elementRef && this.elementRef.removeEventListener(
302
+ this.elementRef && (this.elementRef.removeEventListener(
309
303
  "focusout",
310
304
  this.handleBlur
311
- ), this.elementRef && this.elementRef.addEventListener(
305
+ ), this.elementRef.addEventListener(
312
306
  "focusout",
313
307
  this.handleBlur,
314
308
  !0
315
- ), w(this.settings, (t, e) => {
316
- e instanceof g && e.setOnBlur(() => {
309
+ )), w(this.settings, (t, e) => {
310
+ e instanceof p && e.setOnBlur(() => {
317
311
  this.onBlur && this.onBlur();
318
312
  });
319
313
  });
@@ -340,28 +334,28 @@ const g = class g {
340
334
  main: this.isMain,
341
335
  custom: this.custom,
342
336
  hideCondition: this.hideCondition,
343
- parentNestingLevel: this.parentNestingLevel
344
- }, i = T(e);
337
+ parentNestingLevel: this.parentNestingLevel,
338
+ includeGetJson: this.includeGetJson,
339
+ addItem: this.addItemCfg
340
+ }, i = R(e);
345
341
  return i.initialValues = this.getValues(), i;
346
342
  }
347
343
  setValue(t) {
348
344
  if (!t || typeof t != "object") return;
349
345
  Object.entries(t).forEach(([i, s]) => {
350
346
  const n = this.settings[i];
351
- n && (n instanceof g || n instanceof p) && typeof n.setValue == "function" && n.setValue(s);
347
+ n && (n instanceof p || n instanceof g) && typeof n.setValue == "function" && n.setValue(s);
352
348
  }), setTimeout(() => {
353
349
  this.forceChildUIRefresh();
354
350
  }, 0);
355
351
  const e = this.getValues();
356
352
  this.initialValues = e, this.onChange && this.onChange(e);
357
353
  }
358
- /**
359
- * Force UI refresh for all child settings
360
- */
354
+ /** Force UI refresh for all child settings */
361
355
  forceChildUIRefresh() {
362
356
  Object.entries(this.settings).forEach(([t, e]) => {
363
357
  try {
364
- if (e instanceof g) {
358
+ if (e instanceof p) {
365
359
  const i = e.getValues();
366
360
  e.setValue(i);
367
361
  } else if (typeof e.setValue == "function") {
@@ -373,17 +367,54 @@ const g = class g {
373
367
  }
374
368
  });
375
369
  }
370
+ /** Attach change/blur bubbling for a newly added child */
371
+ wireChild(t) {
372
+ var i, s, n;
373
+ const e = () => {
374
+ var o;
375
+ const a = this.getValues();
376
+ this.initialValues = a, (o = this.onChange) == null || o.call(this, a), this.updateVisibility();
377
+ };
378
+ t instanceof p ? (t.setOnChange(() => e()), (i = t.setOnBlur) == null || i.call(t, () => {
379
+ var a;
380
+ return (a = this.onBlur) == null ? void 0 : a.call(this);
381
+ })) : t instanceof g ? (t.setOnChange(() => e()), (s = t.setOnBlur) == null || s.call(t, () => {
382
+ var a;
383
+ return (a = this.onBlur) == null ? void 0 : a.call(this);
384
+ })) : (n = t.setOnChange) == null || n.call(t, () => e());
385
+ }
386
+ addSetting(t, e) {
387
+ var s;
388
+ if (this.settings[t] = e, this.wireChild(e), this.elementRef) {
389
+ const n = this.elementRef.querySelector(
390
+ ".setting-group-content"
391
+ );
392
+ if (n) {
393
+ e instanceof p && e.setNestingLevel(this.nestingLevel + 1);
394
+ const a = e.draw(), o = n.querySelector(".sg-add-button-bottom");
395
+ o ? n.insertBefore(a, o) : n.appendChild(a), N.trackElement(a), b(a, this.nestingLevel + 1), M(a, this.nestingLevel + 1);
396
+ const l = a.style.display;
397
+ a.style.display = "none", a.offsetHeight, a.style.display = l, this.updateNestingStyles();
398
+ }
399
+ }
400
+ const i = this.getValues();
401
+ this.initialValues = i, (s = this.onChange) == null || s.call(this, i);
402
+ }
403
+ getNextIndexFromPrefix(t) {
404
+ const e = Object.keys(this.settings).filter((i) => i.startsWith(t)).map((i) => {
405
+ const s = Number(i.slice(t.length));
406
+ return Number.isFinite(s) ? s : -1;
407
+ }).filter((i) => i >= 0);
408
+ return e.length ? Math.max(...e) + 1 : 0;
409
+ }
376
410
  calculateChanges(t, e) {
377
411
  const i = {};
378
412
  return (/* @__PURE__ */ new Set([
379
413
  ...Object.keys(t),
380
414
  ...Object.keys(e)
381
415
  ])).forEach((n) => {
382
- const o = t[n], a = e[n];
383
- JSON.stringify(o) !== JSON.stringify(a) && (i[n] = {
384
- from: o,
385
- to: a
386
- });
416
+ const a = t[n], o = e[n];
417
+ JSON.stringify(a) !== JSON.stringify(o) && (i[n] = { from: a, to: o });
387
418
  }), i;
388
419
  }
389
420
  hide() {
@@ -396,53 +427,52 @@ const g = class g {
396
427
  if (t === void 0) {
397
428
  const e = {};
398
429
  for (const i in this.settings)
399
- if (this.settings.hasOwnProperty(i)) {
430
+ if (Object.prototype.hasOwnProperty.call(this.settings, i)) {
400
431
  const s = this.settings[i];
401
- s instanceof g ? e[i] = s.getValues() : e[i] = s.value;
432
+ s instanceof p ? e[i] = s.getValues() : e[i] = s.value;
402
433
  }
403
434
  return e;
404
435
  } else {
405
436
  const e = this.settings[t];
406
- return e ? e instanceof g ? e.getValues() : e.value : void 0;
437
+ return e ? e instanceof p ? e.getValues() : e.value : void 0;
407
438
  }
408
439
  }
409
440
  getValuesForJson(t) {
410
441
  if (t === void 0) {
411
- if (this.includeGetJson === !1)
412
- return null;
442
+ if (this.includeGetJson === !1) return null;
413
443
  const e = {};
414
444
  for (const i in this.settings)
415
- if (this.settings.hasOwnProperty(i)) {
445
+ if (Object.prototype.hasOwnProperty.call(this.settings, i)) {
416
446
  const s = this.settings[i];
417
- s instanceof g ? e[i] = s.getValuesForJson() : s.includeGetJson === !1 ? e[i] = null : e[i] = s.value;
447
+ s instanceof p ? e[i] = s.getValuesForJson() : s.includeGetJson === !1 ? e[i] = null : e[i] = s.value;
418
448
  }
419
449
  return e;
420
450
  } else {
421
451
  const e = this.settings[t];
422
- return e ? e instanceof g ? e.includeGetJson === !1 ? null : e.getValuesForJson() : e.includeGetJson === !1 ? null : e.value : void 0;
452
+ return e ? e instanceof p ? e.includeGetJson === !1 ? null : e.getValuesForJson() : e.includeGetJson === !1 ? null : e.value : void 0;
423
453
  }
424
454
  }
425
455
  getDefaultValues(t) {
426
456
  if (t === void 0) {
427
457
  const e = {};
428
458
  for (const i in this.settings)
429
- if (this.settings.hasOwnProperty(i)) {
459
+ if (Object.prototype.hasOwnProperty.call(this.settings, i)) {
430
460
  const s = this.settings[i];
431
- s instanceof g ? e[i] = s.getDefaultValues() : e[i] = s.default !== void 0 ? s.default : s.value;
461
+ s instanceof p ? e[i] = s.getDefaultValues() : e[i] = s.default !== void 0 ? s.default : s.value;
432
462
  }
433
463
  return e;
434
464
  } else {
435
465
  const e = this.settings[t];
436
- return e ? e instanceof g ? e.getDefaultValues() : e.default !== void 0 ? e.default : e.value : void 0;
466
+ return e ? e instanceof p ? e.getDefaultValues() : e.default !== void 0 ? e.default : e.value : void 0;
437
467
  }
438
468
  }
439
469
  getMobileValues(t) {
440
470
  if (t === void 0) {
441
471
  const e = {};
442
472
  for (const i in this.settings)
443
- if (this.settings.hasOwnProperty(i)) {
473
+ if (Object.prototype.hasOwnProperty.call(this.settings, i)) {
444
474
  const s = this.settings[i];
445
- if (s instanceof g)
475
+ if (s instanceof p)
446
476
  e[i] = s.getMobileValues();
447
477
  else if (typeof s.getMobileValue == "function") {
448
478
  const n = s.getMobileValue();
@@ -454,19 +484,18 @@ const g = class g {
454
484
  } else {
455
485
  const e = this.settings[t];
456
486
  if (!e) return;
457
- if (e instanceof g)
458
- return e.getMobileValues();
487
+ if (e instanceof p) return e.getMobileValues();
459
488
  if (typeof e.getMobileValue == "function") {
460
489
  const i = e.getMobileValue();
461
490
  return i !== void 0 ? i : e.value;
462
- } else
463
- return e.value;
491
+ }
492
+ return e.value;
464
493
  }
465
494
  }
466
495
  setMobileValues(t) {
467
496
  if (!(!t || typeof t != "object") && (Object.entries(t).forEach(([e, i]) => {
468
497
  const s = this.settings[e];
469
- s && (s instanceof g ? typeof i == "object" && i !== null && s.setMobileValues(i) : typeof s.setMobileValue == "function" && s.setMobileValue(i));
498
+ s && (s instanceof p ? typeof i == "object" && i !== null && s.setMobileValues(i) : typeof s.setMobileValue == "function" && s.setMobileValue(i));
470
499
  }), this.setValue(t), this.onChange)) {
471
500
  const e = this.getValues();
472
501
  this.onChange(e);
@@ -481,7 +510,7 @@ const g = class g {
481
510
  }
482
511
  draw() {
483
512
  const t = document.createElement("div");
484
- t.className = "setting-group", t.id = `setting-group-${this.id}`, g.hiddenElements.add(t), this.hideCondition && this.hideCondition() && (t.style.display = "none"), this.isMain && t.classList.add("main-group"), this.custom && t.classList.add("custom_class"), x(t, this.nestingLevel);
513
+ t.className = "setting-group", t.id = `setting-group-${this.id}`, p.hiddenElements.add(t), this.hideCondition && this.hideCondition() && (t.style.display = "none"), this.isMain && t.classList.add("main-group"), this.custom && t.classList.add("custom_class"), b(t, this.nestingLevel);
485
514
  const e = document.createElement("div");
486
515
  e.className = "setting-group-title", this.isCollapsed && e.classList.add("collapsed-view"), e.setAttribute("role", "button"), e.setAttribute(
487
516
  "aria-expanded",
@@ -499,28 +528,28 @@ const g = class g {
499
528
  const r = document.createElement("span");
500
529
  r.className = "info-marker", r.innerHTML = `
501
530
  <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
502
- <path d="M8 5.33333V8M8 10.6667H8.00667M14 8C14 11.3137 11.3137 14 8 14C4.68629 14 2 11.3137 2 8C2 4.68629 4.68629 2 8 2C11.3137 2 14 4.68629 14 8Z"
531
+ <path d="M8 5.33333V8M8 10.6667H8.00667M14 8C14 11.3137 11.3137 14 8 14C4.68629 14 2 11.3137 2 8C2 4.68629 4.68629 2 8 2C11.3137 2 14 4.68629 14 8Z"
503
532
  stroke="currentColor" stroke-width="1.33333" stroke-linecap="round" stroke-linejoin="round"/>
504
533
  </svg>
505
534
  `, r.title = this.description, n.appendChild(r);
506
535
  }
507
- const o = document.createElement("span");
508
- o.className = "setting-group-arrow", o.innerHTML = `
536
+ const a = document.createElement("span");
537
+ a.className = "setting-group-arrow", a.innerHTML = `
509
538
  <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
510
539
  <path d="M4 6L8 10L12 6" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
511
540
  </svg>
512
- `, this.isCollapsed && o.classList.add("rotated"), n.appendChild(o);
513
- const a = document.createElement("div");
514
- if (a.className = "setting-group-content", this.isCollapsed && (a.classList.add("collapsed"), e.classList.add("collapsed-view"), o.classList.add("rotated"), t.classList.add("collapsed")), this.isMain && a.classList.add("main-content"), this.description && !this.isCollapsed) {
541
+ `, this.isCollapsed && a.classList.add("rotated"), n.appendChild(a);
542
+ const o = document.createElement("div");
543
+ if (o.className = "setting-group-content", this.isCollapsed && (o.classList.add("collapsed"), e.classList.add("collapsed-view"), a.classList.add("rotated"), t.classList.add("collapsed")), this.isMain && o.classList.add("main-content"), this.description && !this.isCollapsed) {
515
544
  const r = document.createElement("div");
516
- r.className = "setting-group-description", r.textContent = this.description, a.appendChild(r);
545
+ r.className = "setting-group-description", r.textContent = this.description, o.appendChild(r);
517
546
  }
518
547
  const l = () => {
519
- this.isCollapsed = !this.isCollapsed, a.classList.toggle("collapsed"), e.classList.toggle("collapsed-view"), o.classList.toggle("rotated"), t.classList.toggle("collapsed", this.isCollapsed), e.setAttribute(
548
+ this.isCollapsed = !this.isCollapsed, o.classList.toggle("collapsed"), e.classList.toggle("collapsed-view"), a.classList.toggle("rotated"), t.classList.toggle("collapsed", this.isCollapsed), e.setAttribute(
520
549
  "aria-expanded",
521
550
  (!this.isCollapsed).toString()
522
551
  );
523
- const r = a.querySelector(
552
+ const r = o.querySelector(
524
553
  ".setting-group-description"
525
554
  ), d = n.querySelector(".info-marker");
526
555
  if (this.description)
@@ -529,17 +558,17 @@ const g = class g {
529
558
  const u = document.createElement("span");
530
559
  u.className = "info-marker", u.innerHTML = `
531
560
  <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
532
- <path d="M8 5.33333V8M8 10.6667H8.00667M14 8C14 11.3137 11.3137 14 8 14C4.68629 14 2 11.3137 2 8C2 4.68629 4.68629 2 8 2C11.3137 2 14 4.68629 14 8Z"
561
+ <path d="M8 5.33333V8M8 10.6667H8.00667M14 8C14 11.3137 11.3137 14 8 14C4.68629 14 2 11.3137 2 8C2 4.68629 4.68629 2 8 2C11.3137 2 14 4.68629 14 8Z"
533
562
  stroke="currentColor" stroke-width="1.33333" stroke-linecap="round" stroke-linejoin="round"/>
534
563
  </svg>
535
- `, u.title = this.description, n.insertBefore(u, o);
564
+ `, u.title = this.description, n.insertBefore(u, a);
536
565
  }
537
566
  } else {
538
567
  if (!r) {
539
568
  const u = document.createElement("div");
540
- u.className = "setting-group-description", u.textContent = this.description, a.insertBefore(
569
+ u.className = "setting-group-description", u.textContent = this.description, o.insertBefore(
541
570
  u,
542
- a.firstChild
571
+ o.firstChild
543
572
  );
544
573
  }
545
574
  d && d.remove();
@@ -549,15 +578,30 @@ const g = class g {
549
578
  (r.key === "Enter" || r.key === " ") && (r.preventDefault(), l());
550
579
  }, Object.keys(this.settings).length > 0) {
551
580
  for (const r in this.settings)
552
- if (this.settings.hasOwnProperty(r)) {
581
+ if (Object.prototype.hasOwnProperty.call(this.settings, r)) {
553
582
  const d = this.settings[r];
554
- d instanceof g && d.setNestingLevel(this.nestingLevel + 1), a.appendChild(d.draw());
583
+ d instanceof p && d.setNestingLevel(this.nestingLevel + 1), o.appendChild(d.draw());
555
584
  }
556
585
  } else {
557
586
  const r = document.createElement("div");
558
- r.className = "setting-group-empty", r.textContent = "No settings in this group", a.appendChild(r);
587
+ r.className = "setting-group-empty", r.textContent = "No settings in this group", o.appendChild(r);
588
+ }
589
+ if (this.addItemCfg) {
590
+ const r = document.createElement("button");
591
+ r.type = "button", r.className = "sg-add-button-bottom", r.style.marginTop = "8px";
592
+ const d = this.addItemCfg.buttonIconSvg ?? `
593
+ <svg width="16" height="16" viewBox="0 0 16 16" fill="none"
594
+ xmlns="http://www.w3.org/2000/svg">
595
+ <path d="M8 3.333v9.334M3.333 8h9.334" stroke="currentColor"
596
+ stroke-width="1.5" stroke-linecap="round"/>
597
+ </svg>`;
598
+ r.innerHTML = `${d}<span style="margin-left:4px;">${this.addItemCfg.buttonLabel ?? "Add"}</span>`, r.addEventListener("click", (u) => {
599
+ u.stopPropagation(), u.preventDefault();
600
+ const V = this.getNextIndexFromPrefix(this.addItemCfg.keyPrefix), x = this.addItemCfg.createItem(V), S = `${this.addItemCfg.keyPrefix}${V}`;
601
+ this.addSetting(S, x), this.addItemCfg.expandNewItem !== !1 && x.expand && x.expand();
602
+ }), o.appendChild(r);
559
603
  }
560
- return e.appendChild(i), e.appendChild(n), t.appendChild(e), t.appendChild(a), this.elementRef = t, H.trackElement(t), setTimeout(() => {
604
+ return e.appendChild(i), e.appendChild(n), t.appendChild(e), t.appendChild(o), this.elementRef = t, N.trackElement(t), setTimeout(() => {
561
605
  this.updateNestingStyles();
562
606
  }, 0), this.pendingBlurHandler && (this.setupBlurHandlers(), this.pendingBlurHandler = null), t;
563
607
  }
@@ -594,10 +638,10 @@ const g = class g {
594
638
  let i = e;
595
639
  const s = Object.keys(this.settings), n = Object.keys(e);
596
640
  if (!s.some(
597
- (a) => n.includes(a)
641
+ (o) => n.includes(o)
598
642
  ) && n.length === 1) {
599
- const a = n[0];
600
- i = e[a];
643
+ const o = n[0];
644
+ i = e[o];
601
645
  }
602
646
  this.setValue(i);
603
647
  } catch (e) {
@@ -605,9 +649,9 @@ const g = class g {
605
649
  }
606
650
  }
607
651
  };
608
- g.hiddenElements = /* @__PURE__ */ new Set();
609
- let f = g;
610
- class ct extends f {
652
+ p.hiddenElements = /* @__PURE__ */ new Set();
653
+ let f = p;
654
+ class pt extends f {
611
655
  constructor(t) {
612
656
  super(t);
613
657
  const e = Object.keys(this.settings)[0];
@@ -641,28 +685,28 @@ class ct extends f {
641
685
  s.textContent = this.title, i.appendChild(s);
642
686
  const n = document.createElement("div");
643
687
  n.className = "tabs-header", this.tabsContainer = n;
644
- const o = document.createElement("div");
645
- if (o.className = "tab-content", this.contentContainers = {}, Object.keys(this.settings).forEach((a, l) => {
688
+ const a = document.createElement("div");
689
+ if (a.className = "tab-content", this.contentContainers = {}, Object.keys(this.settings).forEach((o, l) => {
646
690
  const h = document.createElement("button");
647
- h.className = "tab-button", h.type = "button", h.setAttribute("data-tab-id", a), h.textContent = a, h.addEventListener("click", () => this.switchToTab(a)), n.appendChild(h);
691
+ h.className = "tab-button", h.type = "button", h.setAttribute("data-tab-id", o), h.textContent = o, h.addEventListener("click", () => this.switchToTab(o)), n.appendChild(h);
648
692
  const r = document.createElement("div");
649
- r.className = "tab-panel", this.contentContainers[a] = r;
650
- const d = this.settings[a];
651
- d && (d instanceof f && d.setNestingLevel(this.getNestingLevel() + 1), r.appendChild(d.draw())), o.appendChild(r), l === 0 && !this.activeTabId && (this.activeTabId = a);
652
- }), e.appendChild(i), e.appendChild(n), e.appendChild(o), !this.activeTabId) {
653
- const a = Object.keys(this.settings)[0];
654
- this.activeTabId = a || "";
693
+ r.className = "tab-panel", this.contentContainers[o] = r;
694
+ const d = this.settings[o];
695
+ d && (d instanceof f && d.setNestingLevel(this.getNestingLevel() + 1), r.appendChild(d.draw())), a.appendChild(r), l === 0 && !this.activeTabId && (this.activeTabId = o);
696
+ }), e.appendChild(i), e.appendChild(n), e.appendChild(a), !this.activeTabId) {
697
+ const o = Object.keys(this.settings)[0];
698
+ this.activeTabId = o || "";
655
699
  }
656
700
  return this.updateTabUI(), t;
657
701
  }
658
702
  }
659
- function T(c) {
703
+ function R(c) {
660
704
  return new f(c);
661
705
  }
662
- function dt(c) {
706
+ function gt(c) {
663
707
  return c;
664
708
  }
665
- class B extends p {
709
+ class $ extends g {
666
710
  constructor(t = {}) {
667
711
  super(t), this.inputType = "text", t.onChange && this.setOnChange(t.onChange);
668
712
  }
@@ -682,12 +726,12 @@ class B extends p {
682
726
  });
683
727
  }
684
728
  }
685
- const A = "<svg xmlns='http://www.w3.org/2000/svg' width='18' height='19' viewBox='0 0 18 19' fill='none'><path d='M8.99999 15.8542C9.79613 16.5667 10.8475 17 12 17C14.4853 17 16.5 14.9853 16.5 12.5C16.5 10.4248 15.0953 8.67769 13.1849 8.15763M4.81513 8.15762C2.9047 8.67768 1.5 10.4248 1.5 12.5C1.5 14.9853 3.51472 17 6 17C8.48528 17 10.5 14.9853 10.5 12.5C10.5 11.9146 10.3882 11.3554 10.1849 10.8424M13.5 6.5C13.5 8.98528 11.4853 11 9 11C6.51472 11 4.5 8.98528 4.5 6.5C4.5 4.01472 6.51472 2 9 2C11.4853 2 13.5 4.01472 13.5 6.5Z' stroke='#667085' stroke-linecap='round' stroke-linejoin='round'/></svg>";
686
- class m extends B {
729
+ const F = "<svg xmlns='http://www.w3.org/2000/svg' width='18' height='19' viewBox='0 0 18 19' fill='none'><path d='M8.99999 15.8542C9.79613 16.5667 10.8475 17 12 17C14.4853 17 16.5 14.9853 16.5 12.5C16.5 10.4248 15.0953 8.67769 13.1849 8.15763M4.81513 8.15762C2.9047 8.67768 1.5 10.4248 1.5 12.5C1.5 14.9853 3.51472 17 6 17C8.48528 17 10.5 14.9853 10.5 12.5C10.5 11.9146 10.3882 11.3554 10.1849 10.8424M13.5 6.5C13.5 8.98528 11.4853 11 9 11C6.51472 11 4.5 8.98528 4.5 6.5C4.5 4.01472 6.51472 2 9 2C11.4853 2 13.5 4.01472 13.5 6.5Z' stroke='#667085' stroke-linecap='round' stroke-linejoin='round'/></svg>";
730
+ class m extends $ {
687
731
  constructor(t) {
688
732
  super({
689
733
  ...t,
690
- icon: t.icon || A,
734
+ icon: t.icon || F,
691
735
  title: t.title || "Color",
692
736
  default: t.default ? m.normalizeColorValue(t.default) : "#000000"
693
737
  }), this.inputType = "color", this.element = null, this.colorInputEl = null, this.textInputEl = null, this.detectChange = t.detectChange;
@@ -702,11 +746,11 @@ class m extends B {
702
746
  const e = t.split(",").map((r) => parseInt(r.trim()));
703
747
  if (e.length !== 3 || e.some(isNaN))
704
748
  return console.warn(`Invalid RGB value "${t}", using default "#000000"`), "#000000";
705
- const [i, s, n] = e, o = Math.max(0, Math.min(255, i)), a = Math.max(0, Math.min(255, s)), l = Math.max(0, Math.min(255, n)), h = (r) => {
749
+ const [i, s, n] = e, a = Math.max(0, Math.min(255, i)), o = Math.max(0, Math.min(255, s)), l = Math.max(0, Math.min(255, n)), h = (r) => {
706
750
  const d = r.toString(16);
707
751
  return d.length === 1 ? "0" + d : d;
708
752
  };
709
- return `#${h(o)}${h(a)}${h(l)}`;
753
+ return `#${h(a)}${h(o)}${h(l)}`;
710
754
  }
711
755
  setValue(t) {
712
756
  if (t === void 0) {
@@ -750,10 +794,10 @@ class m extends B {
750
794
  s.type = "color", s.className = "color-picker", s.value = this.value || "#000000", s.setAttribute("aria-label", "Choose color"), s.setAttribute("title", "Click to open color picker"), this.colorInputEl = s;
751
795
  const n = document.createElement("div");
752
796
  n.className = "color-preview";
753
- const o = this.value || "#000000";
754
- n.style.backgroundColor = o;
755
- const a = document.createElement("input");
756
- return a.type = "text", a.className = "color-text-input", a.value = this.value || "", a.placeholder = "#000000", a.setAttribute("pattern", "#[0-9A-Fa-f]{6}"), a.setAttribute("title", "Enter a hex color value (e.g., #ff0000)"), a.setAttribute("aria-label", "Hex color value"), a.setAttribute("maxlength", "7"), this.textInputEl = a, this.textInputEl.addEventListener("input", (l) => {
797
+ const a = this.value || "#000000";
798
+ n.style.backgroundColor = a;
799
+ const o = document.createElement("input");
800
+ return o.type = "text", o.className = "color-text-input", o.value = this.value || "", o.placeholder = "#000000", o.setAttribute("pattern", "#[0-9A-Fa-f]{6}"), o.setAttribute("title", "Enter a hex color value (e.g., #ff0000)"), o.setAttribute("aria-label", "Hex color value"), o.setAttribute("maxlength", "7"), this.textInputEl = o, this.textInputEl.addEventListener("input", (l) => {
757
801
  var r, d;
758
802
  let h = l.target.value.trim();
759
803
  if (this.textInputEl && i(this.textInputEl)) {
@@ -768,7 +812,7 @@ class m extends B {
768
812
  var d, u;
769
813
  const h = l.target.value, r = m.normalizeColorValue(h);
770
814
  this.value = r, (d = this.onChange) == null || d.call(this, r), (u = this.detectChange) == null || u.call(this, r), this.textInputEl && (this.textInputEl.value = r), n.style.backgroundColor = r;
771
- }), e.appendChild(s), e.appendChild(n), e.appendChild(a), t.appendChild(e), this.element = t, t;
815
+ }), e.appendChild(s), e.appendChild(n), e.appendChild(o), t.appendChild(e), this.element = t, t;
772
816
  }
773
817
  getElement() {
774
818
  return this.element;
@@ -786,17 +830,17 @@ class m extends B {
786
830
  return this.isValidHex() ? this.hexToRgb(this.value) : "0, 0, 0";
787
831
  }
788
832
  }
789
- const R = `
833
+ const z = `
790
834
  <svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
791
835
  <path d="M8.99999 15.8542C9.79613 16.5667 10.8475 17 12 17C14.4853 17 16.5 14.9853 16.5 12.5C16.5 10.4248 15.0953 8.67769 13.1849 8.15763M4.81513 8.15762C2.9047 8.67768 1.5 10.4248 1.5 12.5C1.5 14.9853 3.51472 17 6 17C8.48528 17 10.5 14.9853 10.5 12.5C10.5 11.9146 10.3882 11.3554 10.1849 10.8424M13.5 6.5C13.5 8.98528 11.4853 11 9 11C6.51472 11 4.5 8.98528 4.5 6.5C4.5 4.01472 6.51472 2 9 2C11.4853 2 13.5 4.01472 13.5 6.5Z" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
792
836
  <path d="M9 17C13.4183 17 17 13.4183 17 9C17 4.58172 13.4183 1 9 1C4.58172 1 1 4.58172 1 9C1 13.4183 4.58172 17 9 17Z" stroke="#667085" stroke-width="0.5" stroke-linecap="round" stroke-linejoin="round" opacity="0.5"/>
793
837
  <path d="M9 1V17C4.58172 17 1 13.4183 1 9C1 4.58172 4.58172 1 9 1Z" fill="#667085" stroke="#667085" stroke-width="0.5" stroke-linecap="round" stroke-linejoin="round" opacity="0.5"/>
794
838
  </svg>`;
795
- class C extends p {
839
+ class C extends g {
796
840
  constructor(t = {}) {
797
841
  super({
798
842
  ...t,
799
- icon: t.icon || R,
843
+ icon: t.icon || z,
800
844
  title: t.title || "Color & Opacity",
801
845
  default: t.default || "#000000FF"
802
846
  }), this.inputType = "color", this.element = null, this.colorInputEl = null, this.textInputEl = null, this.opacityInputEl = null, this.colorPreviewEl = null, this.detectChange = t.detectChange, this.value && (this.value = C.normalizeHexWithOpacity(this.value));
@@ -824,8 +868,8 @@ class C extends p {
824
868
  }
825
869
  updateColorPreview() {
826
870
  if (!this.colorPreviewEl || !this.value) return;
827
- const t = this.getRgbColor(), e = this.getOpacityPercent() / 100, i = t.replace("#", ""), s = parseInt(i.substring(0, 2), 16), n = parseInt(i.substring(2, 4), 16), o = parseInt(i.substring(4, 6), 16);
828
- this.colorPreviewEl.style.backgroundColor = `rgba(${s}, ${n}, ${o}, ${e})`;
871
+ const t = this.getRgbColor(), e = this.getOpacityPercent() / 100, i = t.replace("#", ""), s = parseInt(i.substring(0, 2), 16), n = parseInt(i.substring(2, 4), 16), a = parseInt(i.substring(4, 6), 16);
872
+ this.colorPreviewEl.style.backgroundColor = `rgba(${s}, ${n}, ${a}, ${e})`;
829
873
  }
830
874
  handleColorChange(t) {
831
875
  const e = this.getOpacityPercent(), i = C.combineColorOpacity(t, e);
@@ -842,41 +886,41 @@ class C extends p {
842
886
  draw() {
843
887
  const t = document.createElement("div");
844
888
  if (t.className = "color-with-opacity-setting-wrapper " + (this.props.wrapperClassName || ""), this.props.title || this.props.icon) {
845
- const o = document.createElement("div");
846
- if (o.className = "icon-container", this.props.icon) {
847
- const a = document.createElement("span");
848
- a.className = "input-icon", a.innerHTML = this.props.icon, o.appendChild(a);
889
+ const a = document.createElement("div");
890
+ if (a.className = "icon-container", this.props.icon) {
891
+ const o = document.createElement("span");
892
+ o.className = "input-icon", o.innerHTML = this.props.icon, a.appendChild(o);
849
893
  }
850
894
  if (this.props.title) {
851
- const a = document.createElement("span");
852
- a.className = "input-label", a.textContent = this.props.title, o.appendChild(a);
895
+ const o = document.createElement("span");
896
+ o.className = "input-label", o.textContent = this.props.title, a.appendChild(o);
853
897
  }
854
- t.appendChild(o);
898
+ t.appendChild(a);
855
899
  }
856
900
  const e = document.createElement("div");
857
- e.className = "color-with-opacity-input-wrapper", this.colorInputEl = document.createElement("input"), this.colorInputEl.type = "color", this.colorInputEl.className = "color-with-opacity-picker", this.colorPreviewEl = document.createElement("div"), this.colorPreviewEl.className = "color-with-opacity-preview", this.textInputEl = document.createElement("input"), this.textInputEl.type = "text", this.textInputEl.className = "color-with-opacity-text-input", this.textInputEl.placeholder = "#000000FF", this.updateInputElements(), this.updateColorPreview(), this.colorInputEl.addEventListener("input", (o) => {
858
- const a = o.target;
859
- this.handleColorChange(a.value), this.textInputEl && (this.textInputEl.value = this.value || "#000000FF"), this.updateColorPreview();
860
- }), this.textInputEl.addEventListener("input", (o) => {
861
- const a = o.target;
862
- this.handleTextInput(a.value) ? (this.colorInputEl && (this.colorInputEl.value = this.getRgbColor()), this.updateColorPreview(), e.classList.remove("error")) : a.value.trim() === "" ? e.classList.remove("error") : e.classList.add("error");
863
- }), this.textInputEl.addEventListener("blur", (o) => {
864
- const a = o.target;
865
- a.value.trim() === "" && (a.value = this.value || "#000000FF", e.classList.remove("error"));
901
+ e.className = "color-with-opacity-input-wrapper", this.colorInputEl = document.createElement("input"), this.colorInputEl.type = "color", this.colorInputEl.className = "color-with-opacity-picker", this.colorPreviewEl = document.createElement("div"), this.colorPreviewEl.className = "color-with-opacity-preview", this.textInputEl = document.createElement("input"), this.textInputEl.type = "text", this.textInputEl.className = "color-with-opacity-text-input", this.textInputEl.placeholder = "#000000FF", this.updateInputElements(), this.updateColorPreview(), this.colorInputEl.addEventListener("input", (a) => {
902
+ const o = a.target;
903
+ this.handleColorChange(o.value), this.textInputEl && (this.textInputEl.value = this.value || "#000000FF"), this.updateColorPreview();
904
+ }), this.textInputEl.addEventListener("input", (a) => {
905
+ const o = a.target;
906
+ this.handleTextInput(o.value) ? (this.colorInputEl && (this.colorInputEl.value = this.getRgbColor()), this.updateColorPreview(), e.classList.remove("error")) : o.value.trim() === "" ? e.classList.remove("error") : e.classList.add("error");
907
+ }), this.textInputEl.addEventListener("blur", (a) => {
908
+ const o = a.target;
909
+ o.value.trim() === "" && (o.value = this.value || "#000000FF", e.classList.remove("error"));
866
910
  }), this.colorPreviewEl.addEventListener("click", () => {
867
- var o;
868
- (o = this.colorInputEl) == null || o.click();
911
+ var a;
912
+ (a = this.colorInputEl) == null || a.click();
869
913
  }), e.appendChild(this.colorInputEl), e.appendChild(this.colorPreviewEl), e.appendChild(this.textInputEl);
870
914
  const i = document.createElement("div");
871
915
  i.className = "color-with-opacity-opacity-wrapper", this.opacityInputEl = document.createElement("input"), this.opacityInputEl.type = "number", this.opacityInputEl.className = "color-with-opacity-opacity-input", this.opacityInputEl.value = this.getOpacityPercent().toString(), this.opacityInputEl.min = "0", this.opacityInputEl.max = "100", this.opacityInputEl.step = "1", this.opacityInputEl.placeholder = "100";
872
916
  const s = document.createElement("span");
873
- s.className = "color-with-opacity-opacity-suffix", s.textContent = "%", this.opacityInputEl.addEventListener("input", (o) => {
874
- const a = o.target, l = parseFloat(a.value);
917
+ s.className = "color-with-opacity-opacity-suffix", s.textContent = "%", this.opacityInputEl.addEventListener("input", (a) => {
918
+ const o = a.target, l = parseFloat(o.value);
875
919
  isNaN(l) || (this.handleOpacityChange(l), this.textInputEl && (this.textInputEl.value = this.value || "#000000FF"), this.updateColorPreview());
876
- }), this.opacityInputEl.addEventListener("blur", (o) => {
877
- const a = o.target;
878
- let l = parseFloat(a.value);
879
- isNaN(l) && (l = this.getOpacityPercent()), l = Math.max(0, Math.min(100, l)), a.value = l.toString(), this.handleOpacityChange(l), this.textInputEl && (this.textInputEl.value = this.value || "#000000FF"), this.updateColorPreview();
920
+ }), this.opacityInputEl.addEventListener("blur", (a) => {
921
+ const o = a.target;
922
+ let l = parseFloat(o.value);
923
+ isNaN(l) && (l = this.getOpacityPercent()), l = Math.max(0, Math.min(100, l)), o.value = l.toString(), this.handleOpacityChange(l), this.textInputEl && (this.textInputEl.value = this.value || "#000000FF"), this.updateColorPreview();
880
924
  }), i.appendChild(this.opacityInputEl), i.appendChild(s);
881
925
  const n = document.createElement("div");
882
926
  return n.className = "color-with-opacity-controls-wrapper", n.appendChild(e), n.appendChild(i), t.appendChild(n), this.element = t, this.updateInputElements(), this.updateColorPreview(), t;
@@ -889,8 +933,8 @@ class C extends p {
889
933
  }
890
934
  getRgbaValue() {
891
935
  if (!this.value) return "rgba(0, 0, 0, 1)";
892
- const t = this.getRgbColor(), e = this.getOpacityPercent() / 100, i = t.replace("#", ""), s = parseInt(i.substring(0, 2), 16), n = parseInt(i.substring(2, 4), 16), o = parseInt(i.substring(4, 6), 16);
893
- return `rgba(${s}, ${n}, ${o}, ${e})`;
936
+ const t = this.getRgbColor(), e = this.getOpacityPercent() / 100, i = t.replace("#", ""), s = parseInt(i.substring(0, 2), 16), n = parseInt(i.substring(2, 4), 16), a = parseInt(i.substring(4, 6), 16);
937
+ return `rgba(${s}, ${n}, ${a}, ${e})`;
894
938
  }
895
939
  getColorAndOpacity() {
896
940
  return {
@@ -899,7 +943,7 @@ class C extends p {
899
943
  };
900
944
  }
901
945
  }
902
- class ut extends p {
946
+ class mt extends g {
903
947
  constructor(t = {}) {
904
948
  super(t), this.inputType = "text", t.onChange && this.setOnChange(t.onChange);
905
949
  }
@@ -911,27 +955,27 @@ class ut extends p {
911
955
  if (t.className = "html-setting-wrapper " + (this.props.wrapperClassName || ""), this.props.title || this.props.icon) {
912
956
  const n = document.createElement("div");
913
957
  if (n.className = "icon-container", this.props.icon) {
914
- const o = this.createIcon(this.props.icon);
915
- n.appendChild(o);
958
+ const a = this.createIcon(this.props.icon);
959
+ n.appendChild(a);
916
960
  }
917
961
  if (this.props.title) {
918
- const o = this.createLabel(this.props.title);
919
- n.appendChild(o);
962
+ const a = this.createLabel(this.props.title);
963
+ n.appendChild(a);
920
964
  }
921
965
  t.appendChild(n);
922
966
  }
923
967
  const e = document.createElement("textarea");
924
968
  this.textareaEl = e, e.value = this.value || "", e.placeholder = this.props.placeholder || "Paste your HTML here...", e.className = "html-setting-textarea " + (this.props.textareaClassName || ""), e.rows = this.props.rows || 6, this.props.maxLength !== void 0 && (e.maxLength = this.props.maxLength), this.props.className && e.classList.add(this.props.className);
925
969
  const i = (n) => {
926
- const a = n.target.value;
927
- this.value = a, this.onChange && this.onChange(this.value), this.props.detectChange && this.props.detectChange(this.value);
970
+ const o = n.target.value;
971
+ this.value = o, this.onChange && this.onChange(this.value), this.props.detectChange && this.props.detectChange(this.value);
928
972
  }, s = (n) => {
929
973
  this.onBlur && this.value !== void 0 && this.onBlur(this.value);
930
974
  };
931
975
  return e.addEventListener("input", i), e.addEventListener("change", i), e.addEventListener("blur", s), t.appendChild(e), t;
932
976
  }
933
977
  }
934
- class v extends p {
978
+ class v extends g {
935
979
  constructor(t) {
936
980
  super(t), this.inputType = "number", this.inputElement = null, this.mobileValue = t.mobile, this.validateProps(), this.value = this.validateValue(this.value);
937
981
  }
@@ -954,12 +998,12 @@ class v extends p {
954
998
  const i = document.createElement("input");
955
999
  if (i.type = "number", i.className = "number-setting-input " + (this.props.inputClassName || ""), i.value = String(this.value ?? ""), i.placeholder = this.props.placeholder || "", this.props.minValue !== void 0 && (i.min = String(this.props.minValue)), this.props.maxValue !== void 0 && (i.max = String(this.props.maxValue)), this.props.step !== void 0 && (i.step = String(this.props.step)), i.addEventListener("input", () => {
956
1000
  const s = this.props.minValue ?? Number.MIN_SAFE_INTEGER, n = this.props.maxValue ?? Number.MAX_SAFE_INTEGER;
957
- let o = Number(i.value);
958
- o < s && (o = s), o > n && (o = n), String(o) !== i.value && (i.value = String(o)), this.setValue(o);
1001
+ let a = Number(i.value);
1002
+ a < s && (a = s), a > n && (a = n), String(a) !== i.value && (i.value = String(a)), this.setValue(a);
959
1003
  }), i.addEventListener("blur", () => {
960
- var n, o;
1004
+ var n, a;
961
1005
  const s = this.validateValue(Number(i.value));
962
- s !== Number(i.value) && (i.value = String(s), this.setValue(s)), (o = (n = this.props).onBlur) == null || o.call(n);
1006
+ s !== Number(i.value) && (i.value = String(s), this.setValue(s)), (a = (n = this.props).onBlur) == null || a.call(n);
963
1007
  }), e.appendChild(i), this.props.suffix && this.props.suffix !== "none") {
964
1008
  const s = document.createElement("span");
965
1009
  s.className = "suffix-label", s.textContent = this.props.suffix, e.appendChild(s);
@@ -990,12 +1034,12 @@ class v extends p {
990
1034
  );
991
1035
  }
992
1036
  }
993
- const $ = `
1037
+ const G = `
994
1038
  <svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
995
1039
  <path d="M9 17C13.4183 17 17 13.4183 17 9C17 4.58172 13.4183 1 9 1C4.58172 1 1 4.58172 1 9C1 13.4183 4.58172 17 9 17Z" stroke="#667085" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
996
1040
  <path d="M9 1V17C4.58172 17 1 13.4183 1 9C1 4.58172 4.58172 1 9 1Z" fill="#667085" stroke="#667085" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
997
1041
  </svg>`;
998
- class F extends v {
1042
+ class j extends v {
999
1043
  constructor(t = {}) {
1000
1044
  const e = {
1001
1045
  title: "Opacity",
@@ -1004,7 +1048,7 @@ class F extends v {
1004
1048
  maxValue: 100,
1005
1049
  step: 1,
1006
1050
  default: t.default ?? 100,
1007
- icon: $,
1051
+ icon: G,
1008
1052
  ...t
1009
1053
  };
1010
1054
  super(e), this.inputType = "number", this.mobileValue = t.mobile;
@@ -1016,12 +1060,12 @@ class F extends v {
1016
1060
  this.mobileValue = t, t !== void 0 && this.setValue(t);
1017
1061
  }
1018
1062
  }
1019
- const z = `
1063
+ const P = `
1020
1064
  <svg xmlns="http://www.w3.org/2000/svg" class="svg-select" width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-down">
1021
1065
  <polyline points="6 9 12 15 18 9"></polyline>
1022
1066
  </svg>
1023
1067
  `;
1024
- class y extends p {
1068
+ class k extends g {
1025
1069
  constructor(t = {}) {
1026
1070
  if (super(t), this.inputType = "select", this._options = [], this.isOpen = !1, this.selectedOptionIndex = null, this.optionsListEl = null, this.svgContainer = null, this.buttonEl = null, this.isLoading = !1, this.container = null, this.clickOutsideListener = null, this.resizeListener = null, t.options && (this._options = [...t.options]), t.getOptions && this._options.push(...t.getOptions()), t.getOptionsAsync && (this.isLoading = !0), this.value !== void 0) {
1027
1071
  const e = this._options.findIndex((i) => i.value === this.value);
@@ -1042,12 +1086,12 @@ class y extends p {
1042
1086
  if (t.classList.add("select-container"), this.container = t, this.props.icon || this.props.title) {
1043
1087
  const n = document.createElement("div");
1044
1088
  if (n.className = "icon-container", this.props.icon) {
1045
- const o = this.createIcon(this.props.icon);
1046
- n.appendChild(o);
1089
+ const a = this.createIcon(this.props.icon);
1090
+ n.appendChild(a);
1047
1091
  }
1048
1092
  if (this.props.title) {
1049
- const o = this.createLabel(this.props.title);
1050
- n.appendChild(o);
1093
+ const a = this.createLabel(this.props.title);
1094
+ n.appendChild(a);
1051
1095
  }
1052
1096
  t.appendChild(n);
1053
1097
  } else {
@@ -1056,22 +1100,22 @@ class y extends p {
1056
1100
  }
1057
1101
  const e = document.createElement("div");
1058
1102
  e.classList.add("select-button"), this.isLoading ? e.classList.add("loading") : e.textContent = this.selectedOptionIndex !== null ? this._options[this.selectedOptionIndex].name : this.props.placeholder || "Select an option", e.onclick = () => {
1059
- var n, o;
1060
- this.isLoading || (this.isOpen = !this.isOpen, this.isOpen ? this.checkDropdownPosition() : this.cleanupDropdownPosition(), (n = this.optionsListEl) == null || n.classList.toggle("open", this.isOpen), (o = this.svgContainer) == null || o.classList.toggle("open", this.isOpen));
1103
+ var n, a;
1104
+ this.isLoading || (this.isOpen = !this.isOpen, this.isOpen ? this.checkDropdownPosition() : this.cleanupDropdownPosition(), (n = this.optionsListEl) == null || n.classList.toggle("open", this.isOpen), (a = this.svgContainer) == null || a.classList.toggle("open", this.isOpen));
1061
1105
  }, t.appendChild(e), this.buttonEl = e;
1062
1106
  const i = document.createElement("ul");
1063
- i.classList.add("select-options"), this._options.forEach((n, o) => {
1064
- const a = this.createOption(n, o);
1065
- a.onclick = (l) => this.selectOption(l, o, e), i.appendChild(a);
1107
+ i.classList.add("select-options"), this._options.forEach((n, a) => {
1108
+ const o = this.createOption(n, a);
1109
+ o.onclick = (l) => this.selectOption(l, a, e), i.appendChild(o);
1066
1110
  }), document.body.appendChild(i);
1067
1111
  const s = document.createElement("div");
1068
- return s.classList.add("svg-container"), s.innerHTML = z, t.appendChild(s), this.optionsListEl = i, this.svgContainer = s, this.props.getOptionsAsync && (this.isLoading = !0, this.updateButtonText(), this.props.getOptionsAsync().then((n) => {
1112
+ return s.classList.add("svg-container"), s.innerHTML = P, t.appendChild(s), this.optionsListEl = i, this.svgContainer = s, this.props.getOptionsAsync && (this.isLoading = !0, this.updateButtonText(), this.props.getOptionsAsync().then((n) => {
1069
1113
  this._options.push(...n), this.isLoading = !1, this.updateOptionsList(), this.updateButtonText();
1070
1114
  }).catch((n) => {
1071
1115
  console.error("Failed to fetch async options:", n), this.isLoading = !1, this.updateButtonText("Failed to load options");
1072
1116
  })), this.clickOutsideListener && document.removeEventListener("click", this.clickOutsideListener), this.clickOutsideListener = (n) => {
1073
- var o, a;
1074
- this.isOpen && !t.contains(n.target) && (this.isOpen = !1, (o = this.optionsListEl) == null || o.classList.remove("open"), (a = this.svgContainer) == null || a.classList.remove("open"), this.cleanupDropdownPosition());
1117
+ var a, o;
1118
+ this.isOpen && !t.contains(n.target) && (this.isOpen = !1, (a = this.optionsListEl) == null || a.classList.remove("open"), (o = this.svgContainer) == null || o.classList.remove("open"), this.cleanupDropdownPosition());
1075
1119
  }, document.addEventListener("click", this.clickOutsideListener), this.resizeListener && window.removeEventListener("resize", this.resizeListener), this.resizeListener = () => {
1076
1120
  this.isOpen && this.checkDropdownPosition();
1077
1121
  }, window.addEventListener("resize", this.resizeListener), t;
@@ -1093,9 +1137,9 @@ class y extends p {
1093
1137
  }
1094
1138
  }
1095
1139
  selectOption(t, e, i) {
1096
- var n, o, a;
1140
+ var n, a, o;
1097
1141
  const s = this._options[e];
1098
- s && (this.value = s.value, (n = this.onChange) == null || n.call(this, this.value), this.selectedOptionIndex = e, this.isOpen = !1, i.textContent = s.name, (o = this.optionsListEl) == null || o.classList.remove("open"), (a = this.svgContainer) == null || a.classList.remove("open"), this.cleanupDropdownPosition(), this.optionsListEl && this.optionsListEl.querySelectorAll(".select-option").forEach((h, r) => {
1142
+ s && (this.value = s.value, (n = this.onChange) == null || n.call(this, this.value), this.selectedOptionIndex = e, this.isOpen = !1, i.textContent = s.name, (a = this.optionsListEl) == null || a.classList.remove("open"), (o = this.svgContainer) == null || o.classList.remove("open"), this.cleanupDropdownPosition(), this.optionsListEl && this.optionsListEl.querySelectorAll(".select-option").forEach((h, r) => {
1099
1143
  r === e ? h.classList.add("selected") : h.classList.remove("selected");
1100
1144
  }));
1101
1145
  }
@@ -1134,7 +1178,7 @@ class y extends p {
1134
1178
  this.clickOutsideListener && (document.removeEventListener("click", this.clickOutsideListener), this.clickOutsideListener = null), this.resizeListener && (window.removeEventListener("resize", this.resizeListener), this.resizeListener = null), this.cleanupDropdownPosition(), this.optionsListEl && this.optionsListEl.parentNode && this.optionsListEl.parentNode.removeChild(this.optionsListEl), super.destroy();
1135
1179
  }
1136
1180
  }
1137
- class G extends p {
1181
+ class W extends g {
1138
1182
  constructor(t = {}) {
1139
1183
  super(t), this.inputType = "button", this.value || (this.value = "center");
1140
1184
  }
@@ -1179,15 +1223,15 @@ class G extends p {
1179
1223
  `
1180
1224
  }
1181
1225
  ].forEach((n) => {
1182
- const o = document.createElement("button");
1183
- o.className = "align-option-button", o.innerHTML = n.icon, this.value === n.name && o.classList.add("selected"), o.addEventListener("click", () => {
1184
- var a;
1185
- i.querySelectorAll(".align-option-button").forEach((l) => l.classList.remove("selected")), o.classList.add("selected"), this.value = n.name, (a = this.onChange) == null || a.call(this, this.value);
1186
- }), i.appendChild(o);
1226
+ const a = document.createElement("button");
1227
+ a.className = "align-option-button", a.innerHTML = n.icon, this.value === n.name && a.classList.add("selected"), a.addEventListener("click", () => {
1228
+ var o;
1229
+ i.querySelectorAll(".align-option-button").forEach((l) => l.classList.remove("selected")), a.classList.add("selected"), this.value = n.name, (o = this.onChange) == null || o.call(this, this.value);
1230
+ }), i.appendChild(a);
1187
1231
  }), t.appendChild(i), t;
1188
1232
  }
1189
1233
  }
1190
- class pt extends p {
1234
+ class ft extends g {
1191
1235
  constructor(t) {
1192
1236
  super(t), this.inputType = "button", this.bgWithAlpha = "rgba(145, 158, 171, 0.08)";
1193
1237
  }
@@ -1201,22 +1245,22 @@ class pt extends p {
1201
1245
  /^rgba\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)$/i
1202
1246
  );
1203
1247
  if (n) {
1204
- let a = +n[1], l = +n[2], h = +n[3], r = +n[4];
1205
- r >= 1 ? (a = Math.round(a * 0.9), l = Math.round(l * 0.9), h = Math.round(h * 0.9)) : r = Math.min(1, r + 0.12), s = `rgba(${a},${l},${h},${r})`;
1248
+ let o = +n[1], l = +n[2], h = +n[3], r = +n[4];
1249
+ r >= 1 ? (o = Math.round(o * 0.9), l = Math.round(l * 0.9), h = Math.round(h * 0.9)) : r = Math.min(1, r + 0.12), s = `rgba(${o},${l},${h},${r})`;
1206
1250
  }
1207
1251
  t.addEventListener("mouseenter", () => {
1208
1252
  console.log("hoverBg", s), t.style.setProperty("background-color", s, "important");
1209
1253
  }), t.addEventListener("mouseleave", () => {
1210
1254
  t.style.setProperty("background-color", e, "important");
1211
1255
  }), t.addEventListener("click", () => {
1212
- var a, l;
1213
- return (l = (a = this.props).onClick) == null ? void 0 : l.call(a);
1256
+ var o, l;
1257
+ return (l = (o = this.props).onClick) == null ? void 0 : l.call(o);
1214
1258
  });
1215
- const o = document.createElement("div");
1216
- return o.className = "button-setting-wrapper " + (this.props.wrapperClassName || ""), o.appendChild(t), o;
1259
+ const a = document.createElement("div");
1260
+ return a.className = "button-setting-wrapper " + (this.props.wrapperClassName || ""), a.appendChild(t), a;
1217
1261
  }
1218
1262
  }
1219
- class gt extends p {
1263
+ class vt extends g {
1220
1264
  constructor(t = {}) {
1221
1265
  super(t), this.inputType = { width: "number", height: "number" }, this.aspectRatio = 1, this.isUpdating = !1;
1222
1266
  const e = t.width || 0, i = t.height || 0;
@@ -1229,14 +1273,14 @@ class gt extends p {
1229
1273
  suffix: "px",
1230
1274
  minValue: this.minWidth,
1231
1275
  maxValue: this.maxWidth,
1232
- icon: W
1276
+ icon: D
1233
1277
  }), this.heightSetting = new v({
1234
1278
  title: "Height",
1235
1279
  default: this.value.height,
1236
1280
  suffix: "px",
1237
1281
  minValue: this.minHeight,
1238
1282
  maxValue: this.maxHeight,
1239
- icon: j
1283
+ icon: J
1240
1284
  }), this.widthSetting.setOnChange(this.handleWidthChange.bind(this)), this.heightSetting.setOnChange(this.handleHeightChange.bind(this));
1241
1285
  }
1242
1286
  handleWidthChange(t) {
@@ -1306,8 +1350,8 @@ class gt extends p {
1306
1350
  return n.className = "dimension-lock-icon", n.setAttribute("type", "button"), n.setAttribute("aria-pressed", String(this.locked)), n.setAttribute(
1307
1351
  "aria-label",
1308
1352
  this.locked ? "Unlock aspect ratio" : "Lock aspect ratio"
1309
- ), n.title = this.locked ? "Unlock aspect ratio" : "Lock aspect ratio", n.innerHTML = this.getLockSVG(this.locked), n.onclick = (o) => {
1310
- o.preventDefault(), this.toggleLock(n);
1353
+ ), n.title = this.locked ? "Unlock aspect ratio" : "Lock aspect ratio", n.innerHTML = this.getLockSVG(this.locked), n.onclick = (a) => {
1354
+ a.preventDefault(), this.toggleLock(n);
1311
1355
  }, s.appendChild(n), t.appendChild(e), t.appendChild(s), t.appendChild(i), t;
1312
1356
  }
1313
1357
  isLocked() {
@@ -1330,24 +1374,24 @@ class gt extends p {
1330
1374
  }
1331
1375
  }
1332
1376
  }
1333
- const W = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1377
+ const D = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1334
1378
  <path d="M4.5 9.5H13.5M4.5 9.5L6 7.25M4.5 9.5L6 11.75M13.5 9.5L12 7.25M13.5 9.5L12 11.75M15.75 16.25V2.75M2.25 16.25V2.75" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
1335
- </svg>`, j = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1379
+ </svg>`, J = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1336
1380
  <path d="M9 14L9 5M9 14L6.75 12.5M9 14L11.25 12.5M9 5L6.75 6.5M9 5L11.25 6.5M15.75 2.75H2.25M15.75 16.25H2.25" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
1337
- </svg>`, b = `
1381
+ </svg>`, y = `
1338
1382
  <svg xmlns="http://www.w3.org/2000/svg" width="15" height="16" viewBox="0 0 15 16" fill="none">
1339
1383
  <path d="M5 10.5L7.5 8M7.5 8L10 10.5M7.5 8V13.625M12.5 10.9643C13.2634 10.3338 13.75 9.37996 13.75 8.3125C13.75 6.41402 12.211 4.875 10.3125 4.875C10.1759 4.875 10.0482 4.80375 9.97882 4.68609C9.16379 3.30302 7.65902 2.375 5.9375 2.375C3.34867 2.375 1.25 4.47367 1.25 7.0625C1.25 8.35381 1.77215 9.52317 2.61684 10.371" stroke="#475467" stroke-linecap="round" stroke-linejoin="round"/>
1340
1384
  </svg>
1341
- `, P = `
1385
+ `, U = `
1342
1386
  <svg width="91" height="71" viewBox="0 0 91 71" fill="none" xmlns="http://www.w3.org/2000/svg">
1343
1387
  <rect width="91" height="71" rx="4" fill="#F2F4F7"/>
1344
1388
  <path d="M37 31.5L39.5 29M39.5 29L42 31.5M39.5 29V34.625M44.5 31.9643C45.2634 31.3338 45.75 30.38 45.75 29.3125C45.75 27.414 44.211 25.875 42.3125 25.875C42.1759 25.875 42.0482 25.8037 41.9788 25.6861C41.1638 24.303 39.659 23.375 37.9375 23.375C35.3487 23.375 33.25 25.4737 33.25 28.0625C33.25 29.3538 33.7721 30.5232 34.6168 31.371" stroke="#475467" stroke-linecap="round" stroke-linejoin="round"/>
1345
1389
  </svg>
1346
- `, D = `
1390
+ `, _ = `
1347
1391
  <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 12 12" fill="none">
1348
1392
  <path d="M8 3V2.6C8 2.03995 8 1.75992 7.89101 1.54601C7.79513 1.35785 7.64215 1.20487 7.45399 1.10899C7.24008 1 6.96005 1 6.4 1H5.6C5.03995 1 4.75992 1 4.54601 1.10899C4.35785 1.20487 4.20487 1.35785 4.10899 1.54601C4 1.75992 4 2.03995 4 2.6V3M5 5.75V8.25M7 5.75V8.25M1.5 3H10.5M9.5 3V8.6C9.5 9.44008 9.5 9.86012 9.33651 10.181C9.1927 10.4632 8.96323 10.6927 8.68099 10.8365C8.36012 11 7.94008 11 7.1 11H4.9C4.05992 11 3.63988 11 3.31901 10.8365C3.03677 10.6927 2.8073 10.4632 2.66349 10.181C2.5 9.86012 2.5 9.44008 2.5 8.6V3" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
1349
1393
  </svg>
1350
- `, _ = `
1394
+ `, q = `
1351
1395
  <svg xmlns="http://www.w3.org/2000/svg" width="29" height="29" viewBox="0 0 29 29" fill="none">
1352
1396
  <!-- Top dot -->
1353
1397
  <circle cx="14.5" cy="3" r="1.5" fill="#02CC59" opacity="1"/>
@@ -1367,7 +1411,7 @@ const W = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBo
1367
1411
  <circle cx="6.7" cy="6.7" r="1.5" fill="#02CC59" opacity="0.3"/>
1368
1412
  </svg>
1369
1413
  `;
1370
- class U extends p {
1414
+ class Z extends g {
1371
1415
  constructor(t = {}) {
1372
1416
  super(t), this.inputType = "button", this.previewWrapper = null, this.previewEl = null, this.emptyStateEl = null, this.errorContainer = null, this.messageListener = null, this.loadingSpinner = null, this.props.delete === void 0 && (this.props.delete = !0), this.props.maxFileSizeMB === void 0 && (this.props.maxFileSizeMB = 5), !this.value && t.defaultUrl && t.defaultUrl !== "" && (this.value = t.defaultUrl), this.setupMessageListener();
1373
1417
  }
@@ -1417,18 +1461,18 @@ class U extends p {
1417
1461
  );
1418
1462
  if (t && t !== "") {
1419
1463
  this.showLoading(), s && s instanceof HTMLElement && (s.style.display = "none"), e && e.classList.remove("no-image"), i && (i.innerHTML = `
1420
- <span class="upload-icon">${b}</span>
1464
+ <span class="upload-icon">${y}</span>
1421
1465
  <span class="upload-label">Replace</span>
1422
1466
  `);
1423
1467
  const n = () => {
1424
- this.hideLoading(), this.previewWrapper.classList.add("has-image"), this.previewEl.style.display = "block", this.previewEl.removeEventListener("load", n), this.previewEl.removeEventListener("error", o);
1425
- }, o = () => {
1426
- this.hideLoading(), this.showError("Failed to load image. Please try again."), this.previewWrapper.classList.remove("has-image"), this.previewEl.style.display = "none", this.previewWrapper.style.display = "none", s && s instanceof HTMLElement && (s.style.display = "block"), e && e.classList.add("no-image"), this.previewEl.removeEventListener("load", n), this.previewEl.removeEventListener("error", o);
1468
+ this.hideLoading(), this.previewWrapper.classList.add("has-image"), this.previewEl.style.display = "block", this.previewEl.removeEventListener("load", n), this.previewEl.removeEventListener("error", a);
1469
+ }, a = () => {
1470
+ this.hideLoading(), this.showError("Failed to load image. Please try again."), this.previewWrapper.classList.remove("has-image"), this.previewEl.style.display = "none", this.previewWrapper.style.display = "none", s && s instanceof HTMLElement && (s.style.display = "block"), e && e.classList.add("no-image"), this.previewEl.removeEventListener("load", n), this.previewEl.removeEventListener("error", a);
1427
1471
  };
1428
- this.previewEl.addEventListener("load", n), this.previewEl.addEventListener("error", o), this.previewEl.src = t;
1472
+ this.previewEl.addEventListener("load", n), this.previewEl.addEventListener("error", a), this.previewEl.src = t;
1429
1473
  } else
1430
1474
  this.hideLoading(), this.previewWrapper.classList.remove("has-image"), this.previewEl.src = "", this.previewEl.style.display = "none", this.previewWrapper.style.display = "none", s && s instanceof HTMLElement && (s.style.display = "block"), e && e.classList.add("no-image"), i && (i.innerHTML = `
1431
- <span class="upload-icon">${b}</span>
1475
+ <span class="upload-icon">${y}</span>
1432
1476
  <span class="upload-label">Upload</span>
1433
1477
  `);
1434
1478
  }
@@ -1436,24 +1480,24 @@ class U extends p {
1436
1480
  const t = document.createElement("div");
1437
1481
  t.className = "upload-setting-wrapper", t.setAttribute("data-setting-id", this.id), t.addEventListener(
1438
1482
  "focusout",
1439
- (a) => {
1483
+ (o) => {
1440
1484
  var l;
1441
- a.relatedTarget && t.contains(a.relatedTarget) || (l = this.onBlur) == null || l.call(this, this.value ?? "");
1485
+ o.relatedTarget && t.contains(o.relatedTarget) || (l = this.onBlur) == null || l.call(this, this.value ?? "");
1442
1486
  },
1443
1487
  !0
1444
1488
  );
1445
1489
  const e = !!(this.props.title || this.props.icon);
1446
1490
  if (e || t.classList.add("no-label"), e) {
1447
- const a = document.createElement("div");
1448
- if (a.className = "icon-title-container", this.props.icon) {
1491
+ const o = document.createElement("div");
1492
+ if (o.className = "icon-title-container", this.props.icon) {
1449
1493
  const l = this.createIcon(this.props.icon);
1450
- a.appendChild(l);
1494
+ o.appendChild(l);
1451
1495
  }
1452
1496
  if (this.props.title) {
1453
1497
  const l = this.createLabel(this.props.title);
1454
- a.appendChild(l);
1498
+ o.appendChild(l);
1455
1499
  }
1456
- t.appendChild(a);
1500
+ t.appendChild(o);
1457
1501
  }
1458
1502
  this.errorContainer = document.createElement("div"), this.errorContainer.className = "error-message", this.errorContainer.style.display = "none", t.appendChild(this.errorContainer);
1459
1503
  const i = document.createElement("div");
@@ -1461,19 +1505,19 @@ class U extends p {
1461
1505
  const s = this.value && this.value !== "";
1462
1506
  s || i.classList.add("no-image");
1463
1507
  const n = document.createElement("div");
1464
- if (n.className = "preview-placeholder", n.innerHTML = P, this.previewWrapper = document.createElement("div"), this.previewWrapper.className = "preview-wrapper", this.loadingSpinner = document.createElement("div"), this.loadingSpinner.className = "loading-spinner", this.loadingSpinner.innerHTML = _, this.loadingSpinner.style.display = "none", this.previewWrapper.appendChild(this.loadingSpinner), this.previewEl = document.createElement("img"), this.previewEl.className = "upload-preview", this.props.delete) {
1465
- const a = document.createElement("button");
1466
- a.className = "delete-button", a.type = "button", a.title = "Delete image", a.innerHTML = D, this.previewWrapper.appendChild(a), a.onclick = (l) => {
1508
+ if (n.className = "preview-placeholder", n.innerHTML = U, this.previewWrapper = document.createElement("div"), this.previewWrapper.className = "preview-wrapper", this.loadingSpinner = document.createElement("div"), this.loadingSpinner.className = "loading-spinner", this.loadingSpinner.innerHTML = q, this.loadingSpinner.style.display = "none", this.previewWrapper.appendChild(this.loadingSpinner), this.previewEl = document.createElement("img"), this.previewEl.className = "upload-preview", this.props.delete) {
1509
+ const o = document.createElement("button");
1510
+ o.className = "delete-button", o.type = "button", o.title = "Delete image", o.innerHTML = _, this.previewWrapper.appendChild(o), o.onclick = (l) => {
1467
1511
  var h;
1468
1512
  l.stopPropagation(), this.value = "", this.updatePreviewState(null), (h = this.onChange) == null || h.call(this, ""), this.hideError();
1469
1513
  };
1470
1514
  }
1471
1515
  this.previewWrapper.appendChild(this.previewEl);
1472
- const o = document.createElement("button");
1473
- return o.className = "upload-button", o.innerHTML = `
1474
- <span class="upload-icon">${b}</span>
1516
+ const a = document.createElement("button");
1517
+ return a.className = "upload-button", a.innerHTML = `
1518
+ <span class="upload-icon">${y}</span>
1475
1519
  <span class="upload-label">Upload</span>
1476
- `, i.appendChild(n), i.appendChild(this.previewWrapper), i.appendChild(o), t.appendChild(i), s ? this.updatePreviewState(this.value) : this.updatePreviewState(null), o.onclick = () => {
1520
+ `, i.appendChild(n), i.appendChild(this.previewWrapper), i.appendChild(a), t.appendChild(i), s ? this.updatePreviewState(this.value) : this.updatePreviewState(null), a.onclick = () => {
1477
1521
  window.postMessage(
1478
1522
  {
1479
1523
  type: "OPEN_FILE_MANAGER_MODAL",
@@ -1484,14 +1528,14 @@ class U extends p {
1484
1528
  }, t;
1485
1529
  }
1486
1530
  }
1487
- class mt extends v {
1531
+ class Ct extends v {
1488
1532
  constructor(t = {}) {
1489
1533
  super({
1490
1534
  ...t,
1491
1535
  title: t.title || "Height",
1492
1536
  suffix: t.suffix || "px",
1493
1537
  minValue: t.minValue ?? 0,
1494
- icon: t.icon || J,
1538
+ icon: t.icon || K,
1495
1539
  default: t.default ?? 100
1496
1540
  }), this.inputType = "number", this.mobileValue = t.mobile;
1497
1541
  }
@@ -1502,17 +1546,17 @@ class mt extends v {
1502
1546
  this.mobileValue = t, t !== void 0 && this.setValue(t);
1503
1547
  }
1504
1548
  }
1505
- const J = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1549
+ const K = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1506
1550
  <path d="M9 14L9 5M9 14L6.75 12.5M9 14L11.25 12.5M9 5L6.75 6.5M9 5L11.25 6.5M15.75 2.75H2.25M15.75 16.25H2.25" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
1507
1551
  </svg>`;
1508
- class ft extends v {
1552
+ class wt extends v {
1509
1553
  constructor(t = {}) {
1510
1554
  super({
1511
1555
  ...t,
1512
1556
  title: t.title || "Width",
1513
1557
  suffix: t.suffix || "px",
1514
1558
  minValue: t.minValue ?? 0,
1515
- icon: t.icon || q,
1559
+ icon: t.icon || X,
1516
1560
  default: t.default ?? 100
1517
1561
  }), this.inputType = "number", this.mobileValue = t.mobile;
1518
1562
  }
@@ -1523,14 +1567,14 @@ class ft extends v {
1523
1567
  this.mobileValue = t, t !== void 0 && this.setValue(t);
1524
1568
  }
1525
1569
  }
1526
- const q = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1570
+ const X = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1527
1571
  <path d="M4.5 9.5H13.5M4.5 9.5L6 7.25M4.5 9.5L6 11.75M13.5 9.5L12 7.25M13.5 9.5L12 11.75M15.75 16.25V2.75M2.25 16.25V2.75" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
1528
- </svg>`, Z = `
1572
+ </svg>`, Q = `
1529
1573
  <svg xmlns="http://www.w3.org/2000/svg" class="svg-select-api" width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-down">
1530
1574
  <polyline points="6 9 12 15 18 9"></polyline>
1531
1575
  </svg>
1532
1576
  `;
1533
- class vt extends p {
1577
+ class Et extends g {
1534
1578
  constructor(t = {}) {
1535
1579
  if (super(t), this.inputType = "select", this._options = [], this.isOpen = !1, this.selectedOptionIndex = null, this.optionsListEl = null, this.svgContainer = null, this.buttonEl = null, this.isLoading = !1, this.container = null, this.hasInitializedOptions = !1, this.selectedOptionIndex = null, t.default !== void 0 && (this.value = t.default), this.initializeOptions(t), !t.getOptionsAsync && this.value !== void 0) {
1536
1580
  const e = this._options.findIndex(
@@ -1557,44 +1601,44 @@ class vt extends p {
1557
1601
  e.classList.add("has-label");
1558
1602
  const n = document.createElement("div");
1559
1603
  n.className = "select-label", n.textContent = this.props.title, e.appendChild(n);
1560
- const o = document.createElement("span");
1561
- if (o.className = "select-value", this.isLoading)
1562
- o.textContent = this.props.loadingText || "Loading options...";
1604
+ const a = document.createElement("span");
1605
+ if (a.className = "select-value", this.isLoading)
1606
+ a.textContent = this.props.loadingText || "Loading options...";
1563
1607
  else {
1564
- const a = this.selectedOptionIndex !== null && this._options && this.selectedOptionIndex >= 0 && this.selectedOptionIndex < this._options.length ? this._options[this.selectedOptionIndex] : null, l = a && typeof a.name == "string" ? a.name : "Select an option";
1565
- o.textContent = l;
1608
+ const o = this.selectedOptionIndex !== null && this._options && this.selectedOptionIndex >= 0 && this.selectedOptionIndex < this._options.length ? this._options[this.selectedOptionIndex] : null, l = o && typeof o.name == "string" ? o.name : "Select an option";
1609
+ a.textContent = l;
1566
1610
  }
1567
- e.appendChild(o);
1611
+ e.appendChild(a);
1568
1612
  } else {
1569
1613
  const n = document.createElement("span");
1570
1614
  if (this.isLoading)
1571
1615
  n.textContent = this.props.loadingText || "Loading options...";
1572
1616
  else {
1573
- const o = this.selectedOptionIndex !== null && this._options && this.selectedOptionIndex >= 0 && this.selectedOptionIndex < this._options.length ? this._options[this.selectedOptionIndex] : null, a = o && typeof o.name == "string" ? o.name : "Select an option";
1574
- n.textContent = a;
1617
+ const a = this.selectedOptionIndex !== null && this._options && this.selectedOptionIndex >= 0 && this.selectedOptionIndex < this._options.length ? this._options[this.selectedOptionIndex] : null, o = a && typeof a.name == "string" ? a.name : "Select an option";
1618
+ n.textContent = o;
1575
1619
  }
1576
1620
  e.appendChild(n);
1577
1621
  }
1578
1622
  e.onclick = () => {
1579
- var n, o;
1580
- this.isLoading || (this.isOpen = !this.isOpen, (n = this.optionsListEl) == null || n.classList.toggle("open", this.isOpen), (o = this.svgContainer) == null || o.classList.toggle("open", this.isOpen));
1623
+ var n, a;
1624
+ this.isLoading || (this.isOpen = !this.isOpen, (n = this.optionsListEl) == null || n.classList.toggle("open", this.isOpen), (a = this.svgContainer) == null || a.classList.toggle("open", this.isOpen));
1581
1625
  }, t.appendChild(e), this.buttonEl = e;
1582
1626
  const i = document.createElement("ul");
1583
- i.classList.add("select-api-options"), this._options.forEach((n, o) => {
1584
- const a = this.createOption(n, o);
1585
- a.onclick = (l) => this.selectApiOption(l, o, e), i.appendChild(a);
1627
+ i.classList.add("select-api-options"), this._options.forEach((n, a) => {
1628
+ const o = this.createOption(n, a);
1629
+ o.onclick = (l) => this.selectApiOption(l, a, e), i.appendChild(o);
1586
1630
  }), t.appendChild(i);
1587
1631
  const s = document.createElement("div");
1588
- return s.classList.add("svg-container"), s.innerHTML = Z, t.appendChild(s), s.onclick = () => {
1589
- var n, o;
1590
- this.isLoading || (this.isOpen = !this.isOpen, (n = this.optionsListEl) == null || n.classList.toggle("open", this.isOpen), (o = this.svgContainer) == null || o.classList.toggle("open", this.isOpen));
1632
+ return s.classList.add("svg-container"), s.innerHTML = Q, t.appendChild(s), s.onclick = () => {
1633
+ var n, a;
1634
+ this.isLoading || (this.isOpen = !this.isOpen, (n = this.optionsListEl) == null || n.classList.toggle("open", this.isOpen), (a = this.svgContainer) == null || a.classList.toggle("open", this.isOpen));
1591
1635
  }, this.optionsListEl = i, this.svgContainer = s, this.props.getOptionsAsync && !this.hasInitializedOptions ? (this.isLoading = !0, this.updateButtonText(), this.props.getOptionsAsync().then((n) => {
1592
- const o = new Set(
1636
+ const a = new Set(
1593
1637
  this._options.map((l) => JSON.stringify(l.value))
1594
- ), a = n.filter(
1595
- (l) => !o.has(JSON.stringify(l.value))
1638
+ ), o = n.filter(
1639
+ (l) => !a.has(JSON.stringify(l.value))
1596
1640
  );
1597
- if (this._options.push(...a), this.isLoading = !1, this.hasInitializedOptions = !0, this.value !== void 0) {
1641
+ if (this._options.push(...o), this.isLoading = !1, this.hasInitializedOptions = !0, this.value !== void 0) {
1598
1642
  const l = this._options.findIndex(
1599
1643
  (h) => JSON.stringify(h.value) === JSON.stringify(this.value)
1600
1644
  );
@@ -1608,12 +1652,12 @@ class vt extends p {
1608
1652
  !0
1609
1653
  );
1610
1654
  })) : this.props.getOptionsAsync && this._options.length <= 1 && (this.isLoading = !0, this.updateButtonText(), this.props.getOptionsAsync().then((n) => {
1611
- const o = new Set(
1655
+ const a = new Set(
1612
1656
  this._options.map((l) => JSON.stringify(l.value))
1613
- ), a = n.filter(
1614
- (l) => !o.has(JSON.stringify(l.value))
1657
+ ), o = n.filter(
1658
+ (l) => !a.has(JSON.stringify(l.value))
1615
1659
  );
1616
- if (this._options.push(...a), this.isLoading = !1, this.value !== void 0) {
1660
+ if (this._options.push(...o), this.isLoading = !1, this.value !== void 0) {
1617
1661
  const l = this._options.findIndex(
1618
1662
  (h) => JSON.stringify(h.value) === JSON.stringify(this.value)
1619
1663
  );
@@ -1635,16 +1679,16 @@ class vt extends p {
1635
1679
  var l, h, r, d;
1636
1680
  const s = t.target, n = s.querySelector(".select-api-radio") || ((l = s.closest(".select-api-option")) == null ? void 0 : l.querySelector(".select-api-radio"));
1637
1681
  n && (n.checked = !0), this.selectedOptionIndex = e;
1638
- const o = this._options[e].value;
1639
- this.value = o;
1640
- const a = i.querySelector(".select-value");
1641
- if (a)
1642
- a.textContent = this._options[e].name;
1682
+ const a = this._options[e].value;
1683
+ this.value = a;
1684
+ const o = i.querySelector(".select-value");
1685
+ if (o)
1686
+ o.textContent = this._options[e].name;
1643
1687
  else {
1644
1688
  const u = i.firstChild;
1645
1689
  u && u.tagName === "SPAN" && (u.textContent = this._options[e].name);
1646
1690
  }
1647
- this.isOpen = !1, (h = this.optionsListEl) == null || h.classList.remove("open"), (r = this.svgContainer) == null || r.classList.remove("open"), (d = this.onChange) == null || d.call(this, o), this.detectChangeCallback && this.detectChangeCallback(o);
1691
+ this.isOpen = !1, (h = this.optionsListEl) == null || h.classList.remove("open"), (r = this.svgContainer) == null || r.classList.remove("open"), (d = this.onChange) == null || d.call(this, a), this.detectChangeCallback && this.detectChangeCallback(a);
1648
1692
  }
1649
1693
  updateOptionsList() {
1650
1694
  !this.optionsListEl || !this.buttonEl || (this.optionsListEl.innerHTML = "", this._options.forEach((t, e) => {
@@ -1677,13 +1721,13 @@ class vt extends p {
1677
1721
  ), this.updateButtonText();
1678
1722
  }
1679
1723
  }
1680
- class Ct extends p {
1724
+ class bt extends g {
1681
1725
  constructor(t) {
1682
1726
  var e, i;
1683
1727
  super(t), this.inputType = "text", this.value = t.default ?? ((i = (e = t.options) == null ? void 0 : e[0]) == null ? void 0 : i.value) ?? "", this.detectChangeCallback = t.detectChange;
1684
1728
  }
1685
1729
  draw() {
1686
- var o, a;
1730
+ var a, o;
1687
1731
  const t = document.createElement("div");
1688
1732
  t.className = "toggle-setting-container", this.props.icon && t.classList.add("toggle-with-icon");
1689
1733
  const e = document.createElement("div");
@@ -1699,7 +1743,7 @@ class Ct extends p {
1699
1743
  const i = document.createElement("label");
1700
1744
  i.className = "toggle-switch";
1701
1745
  const s = document.createElement("input");
1702
- s.type = "checkbox", s.checked = ((a = (o = this.props.options) == null ? void 0 : o.find((l) => l.value === this.value)) == null ? void 0 : a.status) ?? !1, s.addEventListener("change", () => {
1746
+ s.type = "checkbox", s.checked = ((o = (a = this.props.options) == null ? void 0 : a.find((l) => l.value === this.value)) == null ? void 0 : o.status) ?? !1, s.addEventListener("change", () => {
1703
1747
  var h, r;
1704
1748
  const l = ((r = (h = this.props.options) == null ? void 0 : h.find((d) => d.status === s.checked)) == null ? void 0 : r.value) ?? "";
1705
1749
  this.value = l, this.onChange && this.onChange(this.value), this.detectChangeCallback && this.detectChangeCallback(this.value);
@@ -1722,13 +1766,13 @@ class Ct extends p {
1722
1766
  this.detectChangeCallback = t;
1723
1767
  }
1724
1768
  }
1725
- const K = `<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
1769
+ const Y = `<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
1726
1770
  <path d="M13.3334 5.99996H2.66675M13.3334 9.99996H2.66675M5.33341 12.6666V3.33329M10.6667 12.6666V3.33329" stroke="#667085" stroke-width="1.33333" stroke-linecap="round" stroke-linejoin="round"/>
1727
1771
  </svg>`;
1728
- class wt extends p {
1772
+ class Lt extends g {
1729
1773
  // Store mobile value
1730
1774
  constructor(t = {}) {
1731
- t.rowGap = t.rowGap ?? !0, t.columnGap = t.columnGap ?? !0, t.title = t.title ?? "Gap", t.icon = t.icon ?? K, t.suffix = t.suffix ?? "px", t.minValue = t.minValue ?? 0, super(t), this.inputType = "number", this.inputValues = {}, this.mobileValue = t.mobile, this.value = this.validateValue(t.default ?? 0), t.rowGap && (this.inputValues.row = this.value), t.columnGap && (this.inputValues.column = this.value);
1775
+ t.rowGap = t.rowGap ?? !0, t.columnGap = t.columnGap ?? !0, t.title = t.title ?? "Gap", t.icon = t.icon ?? Y, t.suffix = t.suffix ?? "px", t.minValue = t.minValue ?? 0, super(t), this.inputType = "number", this.inputValues = {}, this.mobileValue = t.mobile, this.value = this.validateValue(t.default ?? 0), t.rowGap && (this.inputValues.row = this.value), t.columnGap && (this.inputValues.column = this.value);
1732
1776
  }
1733
1777
  draw() {
1734
1778
  const t = document.createElement("div");
@@ -1739,27 +1783,27 @@ class wt extends p {
1739
1783
  i.className = "setting-label", i.setAttribute("for", this.id + "-input");
1740
1784
  const s = document.createElement("span");
1741
1785
  if (s.textContent = this.props.title ?? "Gap", i.appendChild(s), this.props.icon) {
1742
- const a = document.createElement("span");
1743
- a.className = "setting-icon", a.innerHTML = this.props.icon, i.insertBefore(a, s);
1786
+ const o = document.createElement("span");
1787
+ o.className = "setting-icon", o.innerHTML = this.props.icon, i.insertBefore(o, s);
1744
1788
  }
1745
1789
  const n = document.createElement("div");
1746
1790
  n.className = `setting-input-wrapper ${this.props.wrapperClassName || ""}`, n.classList.add("gap-setting-wrapper");
1747
- const o = document.createElement("div");
1748
- return o.className = "gap-inputs-container", this.props.rowGap && o.appendChild(this.createGapInput("row", "Row")), this.props.columnGap && o.appendChild(this.createGapInput("column", "Col")), n.appendChild(o), e.appendChild(i), e.appendChild(n), t.appendChild(e), t;
1791
+ const a = document.createElement("div");
1792
+ return a.className = "gap-inputs-container", this.props.rowGap && a.appendChild(this.createGapInput("row", "Row")), this.props.columnGap && a.appendChild(this.createGapInput("column", "Col")), n.appendChild(a), e.appendChild(i), e.appendChild(n), t.appendChild(e), t;
1749
1793
  }
1750
1794
  createGapInput(t, e) {
1751
1795
  const i = document.createElement("div");
1752
1796
  i.className = "gap-input-wrapper";
1753
1797
  const s = document.createElement("input");
1754
1798
  if (s.type = "number", s.className = `gap-input gap-${t}-input ${this.props.inputClassName || ""}`, s.id = `${this.id}-${t}-input`, s.min = String(this.props.minValue ?? 0), this.props.maxValue !== void 0 && (s.max = String(this.props.maxValue)), s.step = String(this.props.step ?? 1), s.value = String(this.inputValues[t] ?? this.value), s.title = e, s.addEventListener("input", (n) => {
1755
- const o = n.target;
1756
- let a = parseFloat(o.value);
1757
- a = this.validateValue(a), String(a) !== o.value && (o.value = String(a)), this.inputValues[t] = a, this.setValue(a);
1799
+ const a = n.target;
1800
+ let o = parseFloat(a.value);
1801
+ o = this.validateValue(o), String(o) !== a.value && (a.value = String(o)), this.inputValues[t] = o, this.setValue(o);
1758
1802
  }), s.addEventListener("blur", (n) => {
1759
1803
  var l, h;
1760
- const o = n.target;
1761
- let a = parseFloat(o.value);
1762
- a = this.validateValue(a), String(a) !== o.value && (o.value = String(a), this.inputValues[t] = a, this.setValue(a)), (h = (l = this.props).onBlur) == null || h.call(l);
1804
+ const a = n.target;
1805
+ let o = parseFloat(a.value);
1806
+ o = this.validateValue(o), String(o) !== a.value && (a.value = String(o), this.inputValues[t] = o, this.setValue(o)), (h = (l = this.props).onBlur) == null || h.call(l);
1763
1807
  }), i.appendChild(s), this.props.suffix && this.props.suffix !== "none") {
1764
1808
  const n = document.createElement("span");
1765
1809
  n.className = "gap-suffix", n.textContent = this.props.suffix, i.appendChild(n), s.style.paddingRight = "30px";
@@ -1779,53 +1823,53 @@ class wt extends p {
1779
1823
  this.mobileValue = t, t !== void 0 && this.setValue(t);
1780
1824
  }
1781
1825
  }
1782
- const X = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1826
+ const tt = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1783
1827
  <path d="M2.25 11.75H15.75M5.85 2.75H12.15C13.4101 2.75 14.0402 2.75 14.5215 2.99524C14.9448 3.21095 15.289 3.55516 15.5048 3.97852C15.75 4.45982 15.75 5.08988 15.75 6.35V12.65C15.75 13.9101 15.75 14.5402 15.5048 15.0215C15.289 15.4448 14.9448 15.789 14.5215 16.0048C14.0402 16.25 13.4101 16.25 12.15 16.25H5.85C4.58988 16.25 3.95982 16.25 3.47852 16.0048C3.05516 15.789 2.71095 15.4448 2.49524 15.0215C2.25 14.5402 2.25 13.9101 2.25 12.65V6.35C2.25 5.08988 2.25 4.45982 2.49524 3.97852C2.71095 3.55516 3.05516 3.21095 3.47852 2.99524C3.95982 2.75 4.58988 2.75 5.85 2.75Z" stroke="#667085" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
1784
1828
  </svg>`;
1785
- class Et extends v {
1829
+ class xt extends v {
1786
1830
  constructor(t = {}) {
1787
1831
  super({
1788
1832
  ...t,
1789
1833
  minValue: t.minValue ?? 0,
1790
1834
  maxValue: t.maxValue ?? 1e3,
1791
- icon: t.icon || X,
1835
+ icon: t.icon || tt,
1792
1836
  title: t.title || "Margin Bottom",
1793
1837
  default: t.default ?? 20,
1794
1838
  wrapperClassName: "margin-bottom-wrapper " + (t.wrapperClassName || "")
1795
1839
  }), this.inputType = "number";
1796
1840
  }
1797
1841
  }
1798
- const Q = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1842
+ const et = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1799
1843
  <path d="M15.75 7.25H2.25m9.9 9h-6.3c-1.26 0-1.89 0-2.371-.245a2.25 2.25 0 0 1-.984-.983c-.245-.482-.245-1.112-.245-2.372v-6.3c0-1.26 0-1.89.245-2.371a2.25 2.25 0 0 1 .984-.984c.48-.245 1.11-.245 2.371-.245h6.3c1.26 0 1.89 0 2.371.245.424.216.768.56.984.984.245.48.245 1.11.245 2.371v6.3c0 1.26 0 1.89-.245 2.371-.216.424-.56.768-.984.984-.48.245-1.11.245-2.371.245"
1800
1844
  stroke="#667085" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
1801
1845
  </svg>`;
1802
- class Lt extends v {
1846
+ class yt extends v {
1803
1847
  constructor(t = {}) {
1804
1848
  super({
1805
1849
  ...t,
1806
1850
  minValue: t.minValue ?? 0,
1807
1851
  maxValue: t.maxValue ?? 1e3,
1808
- icon: t.icon || Q,
1852
+ icon: t.icon || et,
1809
1853
  title: t.title || "Margin Top",
1810
1854
  default: t.default ?? 20,
1811
1855
  wrapperClassName: "margin-top-wrapper " + (t.wrapperClassName || "")
1812
1856
  }), this.inputType = "number";
1813
1857
  }
1814
1858
  }
1815
- const Y = `
1859
+ const it = `
1816
1860
  <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
1817
1861
  <polyline points="3,6 5,6 21,6"></polyline>
1818
1862
  <path d="m19,6v14a2,2 0 0,1-2,2H7a2,2 0 0,1-2-2V6m3,0V4a2,2 0 0,1,2-2h4a2,2 0 0,1,2,2v2"></path>
1819
1863
  <line x1="10" y1="11" x2="10" y2="17"></line>
1820
1864
  <line x1="14" y1="11" x2="14" y2="17"></line>
1821
1865
  </svg>
1822
- `, tt = `
1866
+ `, st = `
1823
1867
  <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
1824
1868
  <line x1="12" y1="5" x2="12" y2="19"></line>
1825
1869
  <line x1="5" y1="12" x2="19" y2="12"></line>
1826
1870
  </svg>
1827
1871
  `;
1828
- class bt extends p {
1872
+ class Mt extends g {
1829
1873
  constructor(t = {}) {
1830
1874
  super(t), this.inputType = {}, this.container = null, this.languagesContainer = null, this.addLanguageSelect = null, this.addButton = null, this.defaultLanguages = [
1831
1875
  { code: "en", name: "English" },
@@ -1867,15 +1911,15 @@ class bt extends p {
1867
1911
  s.classList.add("language-label"), s.textContent = t.toUpperCase();
1868
1912
  const n = document.createElement("div");
1869
1913
  n.classList.add("language-input-group");
1870
- const o = document.createElement("input");
1871
- o.type = "text", o.classList.add("language-input"), o.value = e || "", o.placeholder = this.props.placeholder || "Enter text...", o.addEventListener("input", (l) => {
1914
+ const a = document.createElement("input");
1915
+ a.type = "text", a.classList.add("language-input"), a.value = e || "", a.placeholder = this.props.placeholder || "Enter text...", a.addEventListener("input", (l) => {
1872
1916
  const h = l.target;
1873
1917
  this.updateLanguageValue(t, h.value);
1874
1918
  });
1875
- const a = document.createElement("button");
1876
- return a.type = "button", a.classList.add("delete-language-btn"), a.innerHTML = Y, a.title = `Delete ${t.toUpperCase()}`, a.addEventListener("click", () => {
1919
+ const o = document.createElement("button");
1920
+ return o.type = "button", o.classList.add("delete-language-btn"), o.innerHTML = it, o.title = `Delete ${t.toUpperCase()}`, o.addEventListener("click", () => {
1877
1921
  this.removeLanguage(t);
1878
- }), n.appendChild(o), n.appendChild(a), i.appendChild(s), i.appendChild(n), i;
1922
+ }), n.appendChild(a), n.appendChild(o), i.appendChild(s), i.appendChild(n), i;
1879
1923
  }
1880
1924
  updateLanguageValue(t, e) {
1881
1925
  this.value || (this.value = {}), this.value[t] = e, this.onChange && this.onChange(this.value), this.props.detectChange && this.props.detectChange(this.value);
@@ -1906,9 +1950,9 @@ class bt extends p {
1906
1950
  const s = document.createElement("select");
1907
1951
  s.classList.add("add-language-select"), this.addLanguageSelect = s;
1908
1952
  const n = document.createElement("button");
1909
- return n.type = "button", n.classList.add("add-language-btn"), n.innerHTML = `${tt} Add`, this.addButton = n, n.addEventListener("click", () => {
1910
- const o = s.value;
1911
- o && this.addLanguage(o);
1953
+ return n.type = "button", n.classList.add("add-language-btn"), n.innerHTML = `${st} Add`, this.addButton = n, n.addEventListener("click", () => {
1954
+ const a = s.value;
1955
+ a && this.addLanguage(a);
1912
1956
  }), i.appendChild(s), i.appendChild(n), t.appendChild(e), t.appendChild(i), t;
1913
1957
  }
1914
1958
  draw() {
@@ -1920,9 +1964,9 @@ class bt extends p {
1920
1964
  const e = document.createElement("div");
1921
1965
  e.classList.add("multi-language-content");
1922
1966
  const i = document.createElement("div");
1923
- i.classList.add("languages-container"), this.languagesContainer = i, this.value && Object.entries(this.value).forEach(([n, o]) => {
1924
- const a = this.createLanguageRow(n, o);
1925
- i.appendChild(a);
1967
+ i.classList.add("languages-container"), this.languagesContainer = i, this.value && Object.entries(this.value).forEach(([n, a]) => {
1968
+ const o = this.createLanguageRow(n, a);
1969
+ i.appendChild(o);
1926
1970
  }), e.appendChild(i);
1927
1971
  const s = this.createAddLanguageSection();
1928
1972
  return e.appendChild(s), t.appendChild(e), this.updateAddLanguageSelect(), this.container = t, t;
@@ -1934,7 +1978,7 @@ class bt extends p {
1934
1978
  }), this.updateAddLanguageSelect());
1935
1979
  }
1936
1980
  }
1937
- class xt extends p {
1981
+ class kt extends g {
1938
1982
  constructor(t = {}) {
1939
1983
  super(t), this.inputType = "select";
1940
1984
  const e = [
@@ -1945,7 +1989,7 @@ class xt extends p {
1945
1989
  { name: "Bounce", value: "bounce 1.5s ease-in-out infinite" },
1946
1990
  { name: "Pulse", value: "pulse 1.5s ease-in-out infinite" }
1947
1991
  ];
1948
- this.selectSetting = new y({
1992
+ this.selectSetting = new k({
1949
1993
  title: this.title || "Animation",
1950
1994
  options: e,
1951
1995
  default: this.props.default || "none"
@@ -1961,16 +2005,16 @@ class xt extends p {
1961
2005
  this.selectSetting.destroy(), super.destroy();
1962
2006
  }
1963
2007
  }
1964
- const et = `
2008
+ const nt = `
1965
2009
  <svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1966
2010
  <path d="M5.625 9.5H5.6325M12.375 9.5H12.3825M9 9.5H9.0075M9 12.875H9.0075M9 6.125H9.0075M2.25 6.35L2.25 12.65C2.25 13.9101 2.25 14.5402 2.49524 15.0215C2.71095 15.4448 3.05516 15.789 3.47852 16.0048C3.95982 16.25 4.58988 16.25 5.85 16.25H12.15C13.4101 16.25 14.0402 16.25 14.5215 16.0048C14.9448 15.789 15.289 15.4448 15.5048 15.0215C15.75 14.5402 15.75 13.9101 15.75 12.65V6.35C15.75 5.08988 15.75 4.45982 15.5048 3.97852C15.289 3.55516 14.9448 3.21095 14.5215 2.99524C14.0402 2.75 13.4101 2.75 12.15 2.75L5.85 2.75C4.58988 2.75 3.95982 2.75 3.47852 2.99524C3.05516 3.21095 2.71095 3.55516 2.49524 3.97852C2.25 4.45982 2.25 5.08988 2.25 6.35Z" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
1967
2011
  </svg>
1968
- `, it = `
2012
+ `, at = `
1969
2013
  <svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
1970
2014
  <path d="M6 2.75H5.85C4.58988 2.75 3.95982 2.75 3.47852 2.99524C3.05516 3.21095 2.71095 3.55516 2.49524 3.97852C2.25 4.45982 2.25 5.08988 2.25 6.35V6.5M6 16.25H5.85C4.58988 16.25 3.95982 16.25 3.47852 16.0048C3.05516 15.789 2.71095 15.4448 2.49524 15.0215C2.25 14.5402 2.25 13.9101 2.25 12.65V12.5M15.75 6.5V6.35C15.75 5.08988 15.75 4.45982 15.5048 3.97852C15.289 3.55516 14.9448 3.21095 14.5215 2.99524C14.0402 2.75 13.4101 2.75 12.15 2.75H12M15.75 12.5V12.65C15.75 13.9101 15.75 14.5402 15.5048 15.0215C15.289 15.4448 14.9448 15.789 14.5215 16.0048C14.0402 16.25 13.4101 16.25 12.15 16.25H12" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
1971
2015
  </svg>
1972
2016
  `;
1973
- class yt extends f {
2017
+ class Vt extends f {
1974
2018
  constructor(t) {
1975
2019
  super({
1976
2020
  title: "Border",
@@ -1979,7 +2023,7 @@ class yt extends f {
1979
2023
  settings: {
1980
2024
  size: new v({
1981
2025
  title: "Size",
1982
- icon: it,
2026
+ icon: at,
1983
2027
  default: (t == null ? void 0 : t.size) ?? 0,
1984
2028
  suffix: "px"
1985
2029
  }),
@@ -1988,7 +2032,7 @@ class yt extends f {
1988
2032
  }),
1989
2033
  radius: new v({
1990
2034
  title: "Radius",
1991
- icon: et,
2035
+ icon: nt,
1992
2036
  default: (t == null ? void 0 : t.radius) ?? 12,
1993
2037
  suffix: "px"
1994
2038
  })
@@ -2007,20 +2051,20 @@ class yt extends f {
2007
2051
  `;
2008
2052
  }
2009
2053
  }
2010
- const st = `
2054
+ const ot = `
2011
2055
  <svg xmlns="http://www.w3.org/2000/svg" width="14" height="13" viewBox="0 0 14 13" fill="none">
2012
2056
  <path d="M1 2.75C1 2.05109 1 1.70163 1.11418 1.42597C1.26642 1.05843 1.55843 0.766422 1.92597 0.614181C2.20163 0.5 2.55109 0.5 3.25 0.5H10.75C11.4489 0.5 11.7984 0.5 12.074 0.614181C12.4416 0.766422 12.7336 1.05843 12.8858 1.42597C13 1.70163 13 2.05109 13 2.75M4.75 12.5H9.25M7 0.5V12.5" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
2013
2057
  </svg>
2014
- `, nt = `
2058
+ `, lt = `
2015
2059
  <svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
2016
2060
  <path d="M3 5.75C3 5.05109 3 4.70163 3.11418 4.42597C3.26642 4.05843 3.55843 3.76642 3.92597 3.61418C4.20163 3.5 4.55109 3.5 5.25 3.5H12.75C13.4489 3.5 13.7984 3.5 14.074 3.61418C14.4416 3.76642 14.7336 4.05843 14.8858 4.42597C15 4.70163 15 5.05109 15 5.75M6 15.5H12M7.6875 3.5V15.5M10.3125 3.5V15.5" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
2017
2061
  </svg>
2018
- `, at = `
2062
+ `, rt = `
2019
2063
  <svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
2020
2064
  <path d="M6 5.75H12M9 5.75V13.25M5.85 16.25H12.15C13.4101 16.25 14.0402 16.25 14.5215 16.0048C14.9448 15.789 15.289 15.4448 15.5048 15.0215C15.75 14.5402 15.75 13.9101 15.75 12.65V6.35C15.75 5.08988 15.75 4.45982 15.5048 3.97852C15.289 3.55516 14.9448 3.21095 14.5215 2.99524C14.0402 2.75 13.4101 2.75 12.15 2.75H5.85C4.58988 2.75 3.95982 2.75 3.47852 2.99524C3.05516 3.21095 2.71095 3.55516 2.49524 3.97852C2.25 4.45982 2.25 5.08988 2.25 6.35V12.65C2.25 13.9101 2.25 14.5402 2.49524 15.0215C2.71095 15.4448 3.05516 15.789 3.47852 16.0048C3.95982 16.25 4.58988 16.25 5.85 16.25Z" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
2021
2065
  </svg>
2022
2066
  `;
2023
- class Mt extends f {
2067
+ class Nt extends f {
2024
2068
  constructor(t = {}) {
2025
2069
  const { showAlign: e = t.showAlign ?? !0, ...i } = t;
2026
2070
  super({
@@ -2032,9 +2076,9 @@ class Mt extends f {
2032
2076
  color: new C({
2033
2077
  default: i.colorDefault ?? "0, 0, 30"
2034
2078
  }),
2035
- fontFamily: new y({
2079
+ fontFamily: new k({
2036
2080
  title: "Font",
2037
- icon: st,
2081
+ icon: ot,
2038
2082
  default: i.fontFamilyDefault ?? "Satoshi",
2039
2083
  options: i.fontFamilyOptions ?? [
2040
2084
  { name: "Alt", value: "Croco Sans Black Caps Alt" },
@@ -2045,9 +2089,9 @@ class Mt extends f {
2045
2089
  getOptions: i.fontFamilyGetOptions,
2046
2090
  getOptionsAsync: i.fontFamilyGetOptionsAsync
2047
2091
  }),
2048
- fontWeight: new y({
2092
+ fontWeight: new k({
2049
2093
  title: "Weight",
2050
- icon: nt,
2094
+ icon: lt,
2051
2095
  default: i.fontWeightDefault ?? "400",
2052
2096
  options: i.fontWeightOptions ?? [
2053
2097
  { name: "Regular", value: "400" },
@@ -2059,7 +2103,7 @@ class Mt extends f {
2059
2103
  }),
2060
2104
  fontSize: new v({
2061
2105
  title: "Size",
2062
- icon: at,
2106
+ icon: rt,
2063
2107
  default: i.fontSizeDefault ?? 12,
2064
2108
  suffix: "px",
2065
2109
  mobile: i.fontSizeMobileDefault
@@ -2067,7 +2111,7 @@ class Mt extends f {
2067
2111
  };
2068
2112
  return e ? {
2069
2113
  ...s,
2070
- align: new G({
2114
+ align: new W({
2071
2115
  title: "Align",
2072
2116
  default: i.alignDefault ?? "center"
2073
2117
  })
@@ -2076,8 +2120,8 @@ class Mt extends f {
2076
2120
  });
2077
2121
  }
2078
2122
  getCssCode() {
2079
- var o;
2080
- const t = this.settings.color.value ?? "#000000", e = this.settings.fontFamily.value ?? "Satoshi", i = this.settings.fontWeight.value ?? "bold", s = this.settings.fontSize.value ?? 12, n = ((o = this.settings.align) == null ? void 0 : o.value) ?? "left";
2123
+ var a;
2124
+ const t = this.settings.color.value ?? "#000000", e = this.settings.fontFamily.value ?? "Satoshi", i = this.settings.fontWeight.value ?? "bold", s = this.settings.fontSize.value ?? 12, n = ((a = this.settings.align) == null ? void 0 : a.value) ?? "left";
2081
2125
  return `
2082
2126
  color: ${t};
2083
2127
  font-family: ${e};
@@ -2087,7 +2131,7 @@ class Mt extends f {
2087
2131
  `;
2088
2132
  }
2089
2133
  }
2090
- class E extends p {
2134
+ class E extends g {
2091
2135
  constructor(t) {
2092
2136
  super({
2093
2137
  ...t,
@@ -2095,11 +2139,11 @@ class E extends p {
2095
2139
  }), this.inputType = "number", this.value = t.default !== void 0 ? t.default : "auto";
2096
2140
  }
2097
2141
  draw() {
2098
- const t = this.value === "auto" ? "text" : "number", e = (a) => {
2099
- this.value !== "auto" && (this.props.minValue !== void 0 && (a.min = String(this.props.minValue)), this.props.maxValue !== void 0 && (a.max = String(this.props.maxValue)), this.props.className && a.classList.add(this.props.className), a.addEventListener("input", () => {
2142
+ const t = this.value === "auto" ? "text" : "number", e = (o) => {
2143
+ this.value !== "auto" && (this.props.minValue !== void 0 && (o.min = String(this.props.minValue)), this.props.maxValue !== void 0 && (o.max = String(this.props.maxValue)), this.props.className && o.classList.add(this.props.className), o.addEventListener("input", () => {
2100
2144
  const l = this.props.minValue ?? Number.MIN_SAFE_INTEGER, h = this.props.maxValue ?? Number.MAX_SAFE_INTEGER;
2101
- let r = Number(a.value);
2102
- r < l && (r = l), r > h && (r = h), a.value = String(r);
2145
+ let r = Number(o.value);
2146
+ r < l && (r = l), r > h && (r = h), o.value = String(r);
2103
2147
  }));
2104
2148
  }, i = this.createInput({
2105
2149
  value: this.value,
@@ -2120,9 +2164,9 @@ class E extends p {
2120
2164
  s && (s.style.paddingRight = "35px");
2121
2165
  const n = document.createElement("span");
2122
2166
  n.className = "suffix-label", n.textContent = this.props.suffix, i.appendChild(n);
2123
- const o = i.querySelector("input");
2124
- return o && (o.oninput = (a) => {
2125
- const l = a.target.value.trim();
2167
+ const a = i.querySelector("input");
2168
+ return a && (a.oninput = (o) => {
2169
+ const l = o.target.value.trim();
2126
2170
  if (l.toLowerCase() === "auto")
2127
2171
  this.value = "auto";
2128
2172
  else {
@@ -2133,7 +2177,7 @@ class E extends p {
2133
2177
  }), i;
2134
2178
  }
2135
2179
  }
2136
- class kt extends f {
2180
+ class It extends f {
2137
2181
  constructor(t) {
2138
2182
  super({
2139
2183
  title: "Margins",
@@ -2142,25 +2186,25 @@ class kt extends f {
2142
2186
  settings: {
2143
2187
  marginTop: new E({
2144
2188
  title: "Top",
2145
- icon: ot,
2189
+ icon: ht,
2146
2190
  suffix: "px",
2147
2191
  default: (t == null ? void 0 : t.marginTop) ?? "auto"
2148
2192
  }),
2149
2193
  marginRight: new E({
2150
2194
  title: "Right",
2151
- icon: lt,
2195
+ icon: ct,
2152
2196
  suffix: "px",
2153
2197
  default: (t == null ? void 0 : t.marginRight) ?? 0
2154
2198
  }),
2155
2199
  marginBottom: new E({
2156
2200
  title: "Bottom",
2157
- icon: rt,
2201
+ icon: dt,
2158
2202
  suffix: "px",
2159
2203
  default: (t == null ? void 0 : t.marginBottom) ?? 0
2160
2204
  }),
2161
2205
  marginLeft: new E({
2162
2206
  title: "Left",
2163
- icon: ht,
2207
+ icon: ut,
2164
2208
  suffix: "px",
2165
2209
  default: (t == null ? void 0 : t.marginLeft) ?? 0
2166
2210
  })
@@ -2177,16 +2221,16 @@ class kt extends f {
2177
2221
  `;
2178
2222
  }
2179
2223
  }
2180
- const ot = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
2224
+ const ht = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
2181
2225
  <path d="M2.25 16.25H2.2575M2.25 9.5H2.2575M2.25 12.875H2.2575M2.25 6.125H2.2575M5.625 16.25H5.6325M5.625 9.5H5.6325M12.375 16.25H12.3825M12.375 9.5H12.3825M9 16.25H9.0075M9 9.5H9.0075M9 12.875H9.0075M9 6.125H9.0075M15.75 16.25H15.7575M15.75 9.5H15.7575M15.75 12.875H15.7575M15.75 6.125H15.7575M15.75 2.75H2.25" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
2182
- </svg>`, lt = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
2226
+ </svg>`, ct = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
2183
2227
  <path d="M5.625 2.75H5.6325M5.625 9.5H5.6325M5.625 16.25H5.6325M12.375 2.75H12.3825M12.375 9.5H12.3825M12.375 16.25H12.3825M9 2.75H9.0075M9 9.5H9.0075M9 16.25H9.0075M9 12.875H9.0075M9 6.125H9.0075M2.25 2.75H2.2575M2.25 9.5H2.2575M2.25 16.25H2.2575M2.25 12.875H2.2575M2.25 6.125H2.2575M15.75 16.25V2.75" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
2184
- </svg>`, rt = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
2228
+ </svg>`, dt = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
2185
2229
  <path d="M2.25 2.75H2.2575M2.25 9.5H2.2575M2.25 12.875H2.2575M2.25 6.125H2.2575M5.625 2.75H5.6325M5.625 9.5H5.6325M12.375 2.75H12.3825M12.375 9.5H12.3825M9 2.75H9.0075M9 9.5H9.0075M9 12.875H9.0075M9 6.125H9.0075M15.75 2.75H15.7575M15.75 9.5H15.7575M15.75 12.875H15.7575M15.75 6.125H15.7575M15.75 16.25H2.25" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
2186
- </svg>`, ht = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
2230
+ </svg>`, ut = `<svg xmlns="http://www.w3.org/2000/svg" width="18" height="19" viewBox="0 0 18 19" fill="none">
2187
2231
  <path d="M5.625 2.75H5.6325M5.625 9.5H5.6325M5.625 16.25H5.6325M12.375 2.75H12.3825M12.375 9.5H12.3825M12.375 16.25H12.3825M9 2.75H9.0075M9 9.5H9.0075M9 16.25H9.0075M9 12.875H9.0075M9 6.125H9.0075M15.75 2.75H15.7575M15.75 9.5H15.7575M15.75 16.25H15.7575M15.75 12.875H15.7575M15.75 6.125H15.7575M2.25 16.25V2.75" stroke="#667085" stroke-linecap="round" stroke-linejoin="round"/>
2188
2232
  </svg>`;
2189
- class Vt extends f {
2233
+ class St extends f {
2190
2234
  /**
2191
2235
  * Constructs a new BackgroundSettingSet.
2192
2236
  *
@@ -2216,11 +2260,11 @@ class Vt extends f {
2216
2260
  collapsed: t == null ? void 0 : t.collapsed,
2217
2261
  hideCondition: t == null ? void 0 : t.hideCondition,
2218
2262
  settings: {
2219
- backgroundImage: new U({
2263
+ backgroundImage: new Z({
2220
2264
  ...t == null ? void 0 : t.uploadProps,
2221
2265
  default: (t == null ? void 0 : t.backgroundImage) ?? ""
2222
2266
  }),
2223
- opacity: new F({
2267
+ opacity: new j({
2224
2268
  default: (t == null ? void 0 : t.opacity) ?? 100
2225
2269
  }),
2226
2270
  backgroundColor: new C({
@@ -2235,10 +2279,10 @@ class Vt extends f {
2235
2279
  draw() {
2236
2280
  const t = super.draw(), e = t.querySelector(".setting-group-content");
2237
2281
  if (!e) return t;
2238
- const i = Array.from(e.children), [s, n, o] = i;
2282
+ const i = Array.from(e.children), [s, n, a] = i;
2239
2283
  e.innerHTML = "", e.appendChild(s), e.appendChild(n);
2240
- const a = document.createElement("div");
2241
- return a.className = "bgset-or-label", a.textContent = "OR", e.appendChild(a), e.appendChild(o), t;
2284
+ const o = document.createElement("div");
2285
+ return o.className = "bgset-or-label", o.textContent = "OR", e.appendChild(o), e.appendChild(a), t;
2242
2286
  }
2243
2287
  /**
2244
2288
  * Helper method to generate CSS based on the current settings.
@@ -2255,44 +2299,44 @@ class Vt extends f {
2255
2299
  `;
2256
2300
  }
2257
2301
  }
2258
- function Nt(c) {
2302
+ function Ot(c) {
2259
2303
  return c instanceof f;
2260
2304
  }
2261
- function St(c) {
2262
- return c instanceof p;
2305
+ function Ht(c) {
2306
+ return c instanceof g;
2263
2307
  }
2264
2308
  export {
2265
- G as AlignSetting,
2266
- xt as AnimationSetting,
2267
- Vt as BackgroundSettingSet,
2268
- yt as BorderSettingSet,
2269
- pt as ButtonSetting,
2309
+ W as AlignSetting,
2310
+ kt as AnimationSetting,
2311
+ St as BackgroundSettingSet,
2312
+ Vt as BorderSettingSet,
2313
+ ft as ButtonSetting,
2270
2314
  m as ColorSetting,
2271
2315
  C as ColorWithOpacitySetting,
2272
- gt as DimensionSetting,
2273
- wt as GapSetting,
2274
- Mt as HeaderTypographySettingSet,
2275
- mt as HeightSetting,
2276
- ut as HtmlSetting,
2277
- Et as MarginBottomSetting,
2278
- kt as MarginSettingGroup,
2279
- Lt as MarginTopSetting,
2280
- bt as MultiLanguageSetting,
2316
+ vt as DimensionSetting,
2317
+ Lt as GapSetting,
2318
+ Nt as HeaderTypographySettingSet,
2319
+ Ct as HeightSetting,
2320
+ mt as HtmlSetting,
2321
+ xt as MarginBottomSetting,
2322
+ It as MarginSettingGroup,
2323
+ yt as MarginTopSetting,
2324
+ Mt as MultiLanguageSetting,
2281
2325
  v as NumberSetting,
2282
- F as OpacitySetting,
2283
- vt as SelectApiSettings,
2284
- y as SelectSetting,
2285
- p as Setting,
2326
+ j as OpacitySetting,
2327
+ Et as SelectApiSettings,
2328
+ k as SelectSetting,
2329
+ g as Setting,
2286
2330
  f as SettingGroup,
2287
- B as StringSetting,
2288
- ct as TabSettingGroup,
2289
- ct as TabsSettingGroup,
2290
- Ct as Toggle,
2291
- U as UploadSetting,
2292
- ft as WidthSetting,
2293
- dt as asSettingGroupWithSettings,
2294
- T as createSettingGroup,
2295
- St as isSetting,
2296
- Nt as isSettingGroup,
2331
+ $ as StringSetting,
2332
+ pt as TabSettingGroup,
2333
+ pt as TabsSettingGroup,
2334
+ bt as Toggle,
2335
+ Z as UploadSetting,
2336
+ wt as WidthSetting,
2337
+ gt as asSettingGroupWithSettings,
2338
+ R as createSettingGroup,
2339
+ Ht as isSetting,
2340
+ Ot as isSettingGroup,
2297
2341
  w as iterateSettings
2298
2342
  };