@levo-so/studio 0.1.101 → 0.1.103

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. package/{AuthProvider-56TywIOB.js → AuthProvider-C6bvedwF.js} +16 -16
  2. package/Beams-DboMUgCv.js +102 -0
  3. package/{BillingStep-Brc1Mzo3.js → BillingStep-BA3H9BVu.js} +1 -1
  4. package/{Button-XTKnNIl9.js → Button-CZycqusY.js} +249 -138
  5. package/Button-lUfKisu8.js +116 -0
  6. package/CollectionField-xa-jed3_.js +232 -0
  7. package/CollectionInput-CpNGIXJx.js +147 -0
  8. package/DateTimeWidget-DP_nMhqe.js +256 -0
  9. package/Dialog-IrII0ugb.js +130 -0
  10. package/Dots-a8xSboDv.js +100 -0
  11. package/{EntryCard-DTcx6wfA.js → EntryCard-CQpKNX7G.js} +4 -4
  12. package/Grid-BJQvxnks.js +99 -0
  13. package/{LoginCard-CnHmCKUF.js → LoginCard-Cyvm-y_q.js} +3 -3
  14. package/{LoginForm-Ck-xFaDg.js → LoginForm-_44FtvWg.js} +207 -206
  15. package/{LoginModal-BdYM8INu.js → LoginModal-Cyw_XKvz.js} +4 -4
  16. package/{MessageCard-ChDBqLVG.js → MessageCard-C2lNTxFx.js} +2 -2
  17. package/{MessageFooter-AzAtJWMo.js → MessageFooter-59Pziq3i.js} +2 -2
  18. package/{ModalManager-SggxCIno.js → ModalManager-DHkd0Zdb.js} +1 -1
  19. package/{PendingApprovalCard-C6ORDqrY.js → PendingApprovalCard-C8iZjo06.js} +3 -3
  20. package/PhoneWidget-CxxxDXkz.js +100 -0
  21. package/{Popover-BdKCElnb.js → Popover-DOvRAGzc.js} +19 -20
  22. package/PopupRenderer-C7OHYphU-Ct5T6tWM.js +2668 -0
  23. package/RichTextWidget-BqlcssWt.js +113 -0
  24. package/RteThemeProvider-Cfepkyer.js +20 -0
  25. package/{StripePaymentModal-BHIBBvRj.js → StripePaymentModal-DrLMN18M.js} +17 -17
  26. package/Toolbar-BwxoYWO_.js +738 -0
  27. package/Tooltip-NEMQqPyr.js +67 -0
  28. package/VerifyButton-TNkt-SDu.js +177 -0
  29. package/authentication-hnV1BI8s.js +36 -0
  30. package/bookingCard-BDyuBC6X.js +636 -0
  31. package/collection.d.ts +83 -0
  32. package/collection.js +9 -8
  33. package/{dialog-Dw6n_36P.js → dialog-C8-iHixJ.js} +32 -32
  34. package/dist-CG-pwDW0.js +3188 -0
  35. package/generateRadiusScale-BpcgkGtN.js +71 -0
  36. package/getFieldValidations-CSkSV2hW.js +90 -0
  37. package/index.d.ts +96 -9
  38. package/index.js +6021 -7731
  39. package/inlineRteTheme-Ajq9PNpQ.js +9 -0
  40. package/{nodeAlignment-BZbdafVA.js → nodeAlignment-DKCIjzlR.js} +41 -62
  41. package/package.json +38 -40
  42. package/studio.css +1 -1
  43. package/useLogin-B2qE8710.js +127 -0
  44. package/{utils-kDaDLLGt.js → utils-CZLafTgN.js} +1 -1
  45. package/{widgets-CWDiqXm9.js → widgets-eu5zXTf-.js} +58 -125
  46. package/Beams-B0O3uyYF.js +0 -118
  47. package/CollectionInput-cmJ0RXzG.js +0 -132
  48. package/DateTimeWidget-B5lBr0_R.js +0 -255
  49. package/Dots-DjezbpLp.js +0 -137
  50. package/Grid-C9aUfXM-.js +0 -145
  51. package/Input-Btdc1Dee.js +0 -293
  52. package/PhoneWidget-BRIAve47.js +0 -100
  53. package/RichTextWidget-CjEoGecM.js +0 -1136
  54. package/Tooltip-BOq5vSOW.js +0 -68
  55. package/VerifyButton-Bl2QqMpB.js +0 -273
  56. package/bookingCard-D3ZSjq-P.js +0 -577
  57. package/dist-DuTd566a.js +0 -3112
  58. package/getFieldValidations-DZnDgNI0.js +0 -159
  59. /package/{Gradient-B1K9Yi04.js → Gradient-NacpoDCM.js} +0 -0
  60. /package/{Waves-BkaAfGqA.js → Waves-DUuT_IFr.js} +0 -0
  61. /package/{card-BQr9258p.js → card-E2LKF9nT.js} +0 -0
  62. /package/{theme.cssm-2YTdd8Yh.js → theme.cssm-BXDp-ojp.js} +0 -0
@@ -1,29 +1,104 @@
1
1
  "use client";
2
- import { n as e } from "./AuthProvider-56TywIOB.js";
3
- import { n as t } from "./ModalManager-SggxCIno.js";
4
- import * as n from "react";
5
- import { createContext as r, forwardRef as i, memo as a, useContext as o, useEffect as s, useMemo as c, useRef as l, useState as u } from "react";
6
- import { animate as d, scroll as f } from "motion/react";
7
- import { Fragment as p, jsx as m, jsxs as h } from "react/jsx-runtime";
8
- import { cn as g } from "@levo-so/react";
9
- import { LoaderCircle as _ } from "lucide-react";
10
- import * as v from "motion/react-m";
2
+ import "./Dialog-IrII0ugb.js";
3
+ import { a as e, c as t, h as n, l as r, n as i, o as a, r as o } from "./PopupRenderer-C7OHYphU-Ct5T6tWM.js";
4
+ import { n as s } from "./AuthProvider-C6bvedwF.js";
5
+ import { n as c } from "./ModalManager-DHkd0Zdb.js";
6
+ import { c as l } from "react/compiler-runtime";
7
+ import { $isIdentityContextReady as u } from "@levo-so/insights/stores";
8
+ import { cn as d, useLevo as f } from "@levo-so/react";
9
+ import * as p from "react";
10
+ import { Suspense as m, createContext as h, forwardRef as g, lazy as _, memo as v, useContext as ee, useEffect as y, useMemo as b, useRef as x, useState as S } from "react";
11
+ import { Fragment as C, jsx as w, jsxs as T } from "react/jsx-runtime";
12
+ import "clsx";
13
+ import "@tabler/icons-react";
14
+ import { useStore as E } from "@nanostores/react";
15
+ import { animate as te, scroll as ne } from "motion/react";
16
+ import { LoaderCircle as D } from "lucide-react";
17
+ import * as O from "motion/react-m";
18
+ import re from "next/link";
19
+ //#region ../../libraries/popups/dist/index.js
20
+ var ie = async (e, t) => {
21
+ let n = {};
22
+ return t?.site_id && (n.site_id = t.site_id), t?.locale && (n.locale = t.locale), t?.country && (n.country = t.country), (await e.url("/v1/studio/popup/list-active").query(n).get().json())?.content?.data ?? [];
23
+ }, ae = _(() => import("./PopupRenderer-C7OHYphU-Ct5T6tWM.js").then((e) => e.s).then((e) => e.t).then((e) => ({ default: e.PopupRenderer }))), k = (e) => {
24
+ let t = l(9), { siteId: r, pageId: i } = e, { fetch: a, logger: o } = f(), [s, c] = S(null), d = x(!1), p, h;
25
+ if (t[0] !== a || t[1] !== o || t[2] !== r ? (p = () => {
26
+ if (d.current) return;
27
+ let e = () => {
28
+ d.current || (d.current = !0, ie(a, r ? { site_id: r } : void 0).then((e) => {
29
+ n(e), c(e);
30
+ }).catch((e) => {
31
+ o?.error("Failed to fetch popups", { exception: e }), n([]), c([]);
32
+ }).finally(A));
33
+ };
34
+ if (u.get()) {
35
+ e();
36
+ return;
37
+ }
38
+ let t = u.listen((n) => {
39
+ n && (t(), e());
40
+ });
41
+ return () => t();
42
+ }, h = [
43
+ a,
44
+ o,
45
+ r
46
+ ], t[0] = a, t[1] = o, t[2] = r, t[3] = p, t[4] = h) : (p = t[3], h = t[4]), y(p, h), !s || s.length === 0) return null;
47
+ let g;
48
+ t[5] === Symbol.for("react.memo_cache_sentinel") ? (g = {
49
+ position: "relative",
50
+ zIndex: 99999
51
+ }, t[5] = g) : g = t[5];
52
+ let _;
53
+ return t[6] !== i || t[7] !== s ? (_ = /* @__PURE__ */ w("div", {
54
+ style: g,
55
+ children: /* @__PURE__ */ w(m, { children: /* @__PURE__ */ w(ae, {
56
+ popups: s,
57
+ pageId: i
58
+ }) })
59
+ }), t[6] = i, t[7] = s, t[8] = _) : _ = t[8], _;
60
+ };
61
+ function A() {
62
+ return r(!1);
63
+ }
64
+ var j = () => {
65
+ let e = l(3), n = E(t), r = E(o), i = M, a = N, s;
66
+ return e[0] !== r || e[1] !== n ? (s = {
67
+ popups: n,
68
+ isLoading: r,
69
+ openPopup: i,
70
+ closePopup: a
71
+ }, e[0] = r, e[1] = n, e[2] = s) : s = e[2], s;
72
+ };
73
+ function M(e) {
74
+ let n = t.get().find((t) => t.id === e);
75
+ n && a(n, {
76
+ force: !0,
77
+ trigger_type: "manual"
78
+ });
79
+ }
80
+ function N() {
81
+ let t = i.get().active_popup_id;
82
+ t && e(t);
83
+ }
84
+ //#endregion
11
85
  //#region src/providers/BlockContext.tsx
12
- var y = r({
86
+ var P = h({
13
87
  isStudio: !1,
14
88
  renderMode: "live",
15
89
  workspace_id: "",
16
90
  pageSource: []
17
- }), b = ({ children: e, value: t }) => {
18
- let [n, r] = u(t.parsedBlockData);
19
- s(() => {
91
+ }), oe = ({ children: e, value: t }) => {
92
+ let [n, r] = S(t.parsedBlockData);
93
+ y(() => {
20
94
  r((e) => t.parsedBlockData === e ? e : t.parsedBlockData);
21
95
  }, [t.parsedBlockData]);
22
- let i = c(() => ({
96
+ let i = b(() => ({
23
97
  parsedBlockData: n,
24
98
  setParsedBlockData: r,
25
99
  blockData: t.blockData,
26
100
  pageContext: t.pageContext,
101
+ pageMeta: t.pageMeta,
27
102
  blockContext: t.blockContext,
28
103
  isStudio: t.renderMode?.startsWith("studio.") ?? !1,
29
104
  renderMode: t.renderMode,
@@ -34,16 +109,17 @@ var y = r({
34
109
  r,
35
110
  t.blockData,
36
111
  t.pageContext,
112
+ t.pageMeta,
37
113
  t.blockContext,
38
114
  t.renderMode,
39
115
  t.workspace_id,
40
116
  t.pageSource
41
117
  ]);
42
- return /* @__PURE__ */ m(y.Provider, {
118
+ return /* @__PURE__ */ w(P.Provider, {
43
119
  value: i,
44
120
  children: e
45
121
  });
46
- }, x = () => o(y), S = {
122
+ }, F = () => ee(P), I = {
47
123
  opacity: 1,
48
124
  scale: 1,
49
125
  rotate: 0,
@@ -53,7 +129,7 @@ var y = r({
53
129
  y: 0,
54
130
  skewX: 0,
55
131
  skewY: 0
56
- }, C = {
132
+ }, L = {
57
133
  opacity: 0,
58
134
  scale: 1,
59
135
  rotate: 0,
@@ -63,25 +139,25 @@ var y = r({
63
139
  y: 0,
64
140
  skewX: 0,
65
141
  skewY: 0
66
- }, w = {
142
+ }, R = {
67
143
  type: "spring",
68
144
  duration: .5,
69
145
  delay: 0,
70
146
  bounce: .25,
71
147
  ease: "easeOut"
72
- }, T = {
148
+ }, se = {
73
149
  once: !0,
74
150
  amount: "some",
75
151
  margin: "0px 0px -150px 0px"
76
- }, E = (e, t) => {
152
+ }, z = (e, t) => {
77
153
  if (!(!e || !t)) for (let n of e) {
78
154
  if (n.key === t) return n;
79
155
  if (n.fields?.length) {
80
- let e = E(n.fields, t);
156
+ let e = z(n.fields, t);
81
157
  if (e) return e;
82
158
  }
83
159
  }
84
- }, D = (e, t) => {
160
+ }, B = (e, t) => {
85
161
  if (!(!e || !t)) return t.split(".").reduce((e, t) => {
86
162
  if (e == null) return;
87
163
  let n = /^\d+$/.test(t), r = e;
@@ -91,7 +167,7 @@ var y = r({
91
167
  }
92
168
  return r?.[t];
93
169
  }, e);
94
- }, O = (e) => !!e && typeof e == "object" && "selectedVariants" in e, k = (e) => e?.replaceAll(".", "-").replace(/[^a-zA-Z0-9_-]/g, ""), A = (e) => {
170
+ }, V = (e) => !!e && typeof e == "object" && "selectedVariants" in e, H = (e) => e?.replaceAll(".", "-").replace(/[^a-zA-Z0-9_-]/g, ""), U = (e) => {
95
171
  let t = e.split(".");
96
172
  for (let e = t.length - 2; e >= 1; e--) if (t[e] && /^\d+$/.test(t[e])) {
97
173
  let n = t[e - 1], r = parseInt(t[e], 10), i = t.slice(e + 1).join("."), a = [];
@@ -113,15 +189,15 @@ var y = r({
113
189
  };
114
190
  }
115
191
  return { isGroupItem: !1 };
116
- }, j = (e) => {
192
+ }, W = (e) => {
117
193
  let t = [];
118
- return O(e) && Object.entries(e.selectedVariants).forEach(([e, n]) => {
194
+ return V(e) && Object.entries(e.selectedVariants).forEach(([e, n]) => {
119
195
  typeof n == "string" && t.push(`levo-variant-${e}-${n}`);
120
196
  }), t;
121
- }, M = (e, t, n) => c(() => {
122
- let r = j(n), i = `levo-${t}-${k(e)}`, a = A(e);
197
+ }, G = (e, t, n) => b(() => {
198
+ let r = W(n), i = `levo-${t}-${H(e)}`, a = U(e);
123
199
  return a.isGroupItem && a.sharedPath ? [
124
- `levo-${t}-${k(a.sharedPath)}`,
200
+ `levo-${t}-${H(a.sharedPath)}`,
125
201
  i,
126
202
  ...r
127
203
  ].filter(Boolean).join(" ") : [i, ...r].join(" ");
@@ -129,7 +205,7 @@ var y = r({
129
205
  n?.selectedVariants,
130
206
  e,
131
207
  t
132
- ]), N = (e, t, n, r, i, a) => c(() => {
208
+ ]), K = (e, t, n, r, i, a) => b(() => {
133
209
  let { className: o, style: s, config: c, styles: l, content: u, ...d } = e;
134
210
  return {
135
211
  ...d,
@@ -154,7 +230,7 @@ var y = r({
154
230
  r,
155
231
  i,
156
232
  a
157
- ]), P = {
233
+ ]), ce = {
158
234
  id: "7074716021398640563",
159
235
  workspace_id: "WZZKMUBH",
160
236
  name: "Booster Applications",
@@ -863,7 +939,13 @@ var y = r({
863
939
  }
864
940
  ]
865
941
  }]
866
- }, F = (e) => {
942
+ }, q = ({ children: e, ...t }) => {
943
+ let { isStudio: n } = F();
944
+ return n ? e : /* @__PURE__ */ w(re, {
945
+ ...t,
946
+ children: e
947
+ });
948
+ }, le = (e) => {
867
949
  if (e?.action) switch (e.action.type) {
868
950
  case "external_link": {
869
951
  let t = e.action.value;
@@ -874,46 +956,65 @@ var y = r({
874
956
  case "phone": return `tel:${e.action.value}`;
875
957
  default: return;
876
958
  }
877
- }, I = ({ children: n, config: r }) => {
878
- let { openModal: i } = t(), { isLoggedIn: a } = e();
879
- if (r?.action?.type === "login") return a ? /* @__PURE__ */ m("a", {
880
- style: { display: "contents" },
881
- href: r?.action?.value,
882
- children: n
883
- }) : /* @__PURE__ */ m("div", {
884
- style: { display: "contents" },
885
- onClick: () => {
886
- i("login", { redirect_uri: r?.action?.value });
887
- },
888
- children: n
889
- });
890
- let o = F(r), s = r?.action?.options?.openInNewTab ? "_blank" : void 0;
891
- if (o) {
892
- let e = {
893
- href: o,
894
- ...s && {
895
- target: s,
896
- rel: "noopener noreferrer"
897
- }
959
+ }, J = ({ children: e, config: t }) => {
960
+ let { openModal: n } = c(), { isLoggedIn: r } = s(), { openPopup: i } = j(), a = t?.action?.alt;
961
+ if (t?.action?.type === "popup") {
962
+ let n = t.action.value, r = () => {
963
+ n && i(n);
898
964
  };
899
- return /* @__PURE__ */ m("a", {
900
- style: {
901
- display: "contents",
902
- ...e.style
965
+ return /* @__PURE__ */ w("div", {
966
+ style: { display: "contents" },
967
+ role: "button",
968
+ tabIndex: 0,
969
+ "aria-label": a || void 0,
970
+ onClick: r,
971
+ onKeyDown: (e) => {
972
+ (e.key === "Enter" || e.key === " ") && (e.preventDefault(), r());
903
973
  },
904
- ...e,
905
- children: n
974
+ children: e
906
975
  });
907
976
  }
908
- return n;
909
- }, L = {
977
+ if (t?.action?.type === "login") {
978
+ if (r) return /* @__PURE__ */ w(q, {
979
+ href: t?.action?.value || "",
980
+ style: { display: "contents" },
981
+ "aria-label": a || void 0,
982
+ children: e
983
+ });
984
+ let i = () => {
985
+ n("login", { redirect_uri: t?.action?.value });
986
+ };
987
+ return /* @__PURE__ */ w("div", {
988
+ style: { display: "contents" },
989
+ role: "button",
990
+ tabIndex: 0,
991
+ "aria-label": a || void 0,
992
+ onClick: i,
993
+ onKeyDown: (e) => {
994
+ (e.key === "Enter" || e.key === " ") && (e.preventDefault(), i());
995
+ },
996
+ children: e
997
+ });
998
+ }
999
+ let o = le(t), l = t?.action?.options?.openInNewTab ? "_blank" : void 0;
1000
+ return o ? /* @__PURE__ */ w(q, {
1001
+ href: o,
1002
+ style: { display: "contents" },
1003
+ ...l && {
1004
+ target: l,
1005
+ rel: "noopener noreferrer"
1006
+ },
1007
+ ...a && { "aria-label": a },
1008
+ children: e
1009
+ }) : e;
1010
+ }, Y = {
910
1011
  once: !0,
911
1012
  margin: "0px 0px -150px 0px"
912
- }, R = ({ children: e, MotionComponent: t, motionProps: n, scroll: r, entry: i, whileHover: a, exit: o }) => {
913
- let c = l(null);
914
- if (s(() => {
1013
+ }, ue = ({ children: e, MotionComponent: t, motionProps: n, scroll: r, entry: i, whileHover: a, exit: o }) => {
1014
+ let s = x(null);
1015
+ if (y(() => {
915
1016
  if (!r) return;
916
- let e = c.current;
1017
+ let e = s.current;
917
1018
  if (!e || !(e instanceof Element)) return;
918
1019
  let { from: t, to: n, offset: i } = r, a = {}, o = Array.from(new Set([...Object.keys(t), ...Object.keys(n)]));
919
1020
  for (let e of o) {
@@ -921,9 +1022,9 @@ var y = r({
921
1022
  r !== i && typeof r == "number" && typeof i == "number" && (a[e] = [r, i]);
922
1023
  }
923
1024
  if (Object.keys(a).length === 0) return;
924
- let s = d(e, a, { ease: "linear" });
1025
+ let c = te(e, a, { ease: "linear" });
925
1026
  try {
926
- return f(s, {
1027
+ return ne(c, {
927
1028
  target: e,
928
1029
  offset: [i.start, i.end]
929
1030
  });
@@ -937,8 +1038,8 @@ var y = r({
937
1038
  }, [r]), r) {
938
1039
  let i = {};
939
1040
  for (let [e, t] of Object.entries(r.from)) t !== void 0 && (i[e] = t);
940
- return /* @__PURE__ */ m(t, {
941
- ref: c,
1041
+ return /* @__PURE__ */ w(t, {
1042
+ ref: s,
942
1043
  ...n,
943
1044
  style: {
944
1045
  ...n.style || {},
@@ -949,154 +1050,164 @@ var y = r({
949
1050
  children: e
950
1051
  });
951
1052
  }
952
- let u = i ? {
953
- ...S,
1053
+ let c = i ? {
1054
+ ...I,
954
1055
  ...i.to,
955
1056
  transition: i.transition
956
- } : void 0, p = i ? {
957
- once: i.viewport?.once ?? L.once,
1057
+ } : void 0, l = i ? {
1058
+ once: i.viewport?.once ?? Y.once,
958
1059
  amount: i.viewport?.amount,
959
- margin: i.viewport?.margin ?? L.margin
1060
+ margin: i.viewport?.margin ?? Y.margin
960
1061
  } : void 0;
961
- return /* @__PURE__ */ m(t, {
1062
+ return /* @__PURE__ */ w(t, {
962
1063
  ...n,
963
1064
  initial: i?.from,
964
- whileInView: u,
965
- viewport: p,
1065
+ whileInView: c,
1066
+ viewport: l,
966
1067
  whileHover: a,
967
1068
  exit: o,
968
1069
  children: e
969
1070
  });
970
- }, z = (e) => {
971
- let t = v.create(e), n = ({ elementKey: n, children: r, ...i }) => {
972
- let { parsedBlockData: a, renderMode: o } = x(), { config: s, styles: l, content: u, id: d } = a || {}, f = s ? D(s, n) : void 0, p = N(i, n, f, l ? D(l, n) : void 0, u ? D(u, n) : void 0, M(n, d || "", f)), h = p.config?.animation, g = c(() => h?.scroll ? {
1071
+ }, X = (e) => {
1072
+ let t = O.create(e), n = ({ elementKey: n, children: r, ...i }) => {
1073
+ let { parsedBlockData: a, renderMode: o } = F(), { config: s, styles: c, content: l, id: u } = a || {}, d = s ? B(s, n) : void 0, f = c ? B(c, n) : void 0, p = l ? B(l, n) : void 0, m = b(() => {
1074
+ let e = d || {}, t = i.config || {}, n = e.selectedVariants || {}, r = t.selectedVariants || {};
1075
+ return {
1076
+ ...e,
1077
+ ...t,
1078
+ selectedVariants: {
1079
+ ...n,
1080
+ ...r
1081
+ }
1082
+ };
1083
+ }, [d, i.config]), h = K(i, n, m, f, p, G(n, u || "", m)), g = h.config?.animation, _ = b(() => g?.scroll ? {
973
1084
  from: {
974
- ...C,
975
- ...h.scroll.from
1085
+ ...L,
1086
+ ...g.scroll.from
976
1087
  },
977
1088
  to: {
978
- ...S,
979
- ...h.scroll.to
1089
+ ...I,
1090
+ ...g.scroll.to
980
1091
  },
981
- offset: h.scroll.offset ?? {
1092
+ offset: g.scroll.offset ?? {
982
1093
  start: "start end",
983
1094
  end: "end center"
984
1095
  }
985
- } : void 0, [h?.scroll]), _ = c(() => h?.entry ? {
1096
+ } : void 0, [g?.scroll]), v = b(() => g?.entry ? {
986
1097
  from: {
987
- ...C,
988
- ...h.entry.from
1098
+ ...L,
1099
+ ...g.entry.from
989
1100
  },
990
1101
  to: {
991
- ...S,
992
- ...h.entry.to
1102
+ ...I,
1103
+ ...g.entry.to
993
1104
  },
994
- transition: h.entry.transition,
995
- viewport: h.entry.viewport
996
- } : void 0, [h?.entry]);
997
- return !a || p.config?.enabled === !1 ? null : h && Object.keys(h).length > 0 && o !== "studio.block" ? /* @__PURE__ */ m(I, {
998
- config: p?.config || {},
999
- children: /* @__PURE__ */ m(R, {
1105
+ transition: g.entry.transition,
1106
+ viewport: g.entry.viewport
1107
+ } : void 0, [g?.entry]);
1108
+ return !a || h.config?.enabled === !1 ? null : g && Object.keys(g).length > 0 && o !== "studio.block" ? /* @__PURE__ */ w(J, {
1109
+ config: h?.config || {},
1110
+ children: /* @__PURE__ */ w(ue, {
1000
1111
  MotionComponent: t,
1001
- motionProps: p,
1002
- scroll: g,
1003
- entry: _,
1004
- whileHover: h.whileHover,
1005
- exit: h.exit,
1112
+ motionProps: h,
1113
+ scroll: _,
1114
+ entry: v,
1115
+ whileHover: g.whileHover,
1116
+ exit: g.exit,
1006
1117
  children: r
1007
1118
  })
1008
- }) : /* @__PURE__ */ m(I, {
1009
- config: p?.config || {},
1010
- children: /* @__PURE__ */ m(e, {
1011
- ...p,
1119
+ }) : /* @__PURE__ */ w(J, {
1120
+ config: h?.config || {},
1121
+ children: /* @__PURE__ */ w(e, {
1122
+ ...h,
1012
1123
  children: r
1013
1124
  })
1014
1125
  });
1015
1126
  };
1016
- return n.displayName = `withBlockProps(${e.displayName || e.name || "Component"})`, a(n);
1017
- }, B = i(({ className: e, config: t, content: n, elementKey: r, generatedClassName: i, styles: a, noElementKey: o, ...s }, c) => {
1018
- if (!n) return /* @__PURE__ */ m("span", {
1127
+ return n.displayName = `withBlockProps(${e.displayName || e.name || "Component"})`, v(n);
1128
+ }, Z = g(({ className: e, config: t, content: n, elementKey: r, generatedClassName: i, styles: a, noElementKey: o, ...s }, c) => {
1129
+ if (!n) return /* @__PURE__ */ w("span", {
1019
1130
  ref: c,
1020
1131
  style: { display: "none" }
1021
1132
  });
1022
- let { kind: l, data: u } = n, d = t?.icon?.alt, f = g(e, i), p = {
1133
+ let { kind: l, data: u } = n, f = t?.icon?.alt, p = d(e, i), m = {
1023
1134
  "data-levo_element_key": o ? void 0 : r,
1024
1135
  "data-levo_element_type": "Icon",
1025
- className: f,
1136
+ className: p,
1026
1137
  ...s
1027
- }, h = d ? {
1028
- "aria-label": d,
1138
+ }, h = f ? {
1139
+ "aria-label": f,
1029
1140
  role: "img"
1030
1141
  } : {};
1031
1142
  switch (l) {
1032
- case "emoji": return /* @__PURE__ */ m("p", {
1143
+ case "emoji": return /* @__PURE__ */ w("p", {
1033
1144
  style: {
1034
1145
  width: "auto",
1035
1146
  height: "auto",
1036
- ...p.style
1147
+ ...m.style
1037
1148
  },
1038
1149
  ref: c,
1039
- ...p,
1150
+ ...m,
1040
1151
  ...h,
1041
1152
  children: u?.unicode
1042
1153
  });
1043
1154
  case "icon": {
1044
1155
  let e = u;
1045
- return e?.svgCode ? /* @__PURE__ */ m("div", {
1156
+ return e?.svgCode ? /* @__PURE__ */ w("div", {
1046
1157
  ref: c,
1047
- ...p,
1158
+ ...m,
1048
1159
  ...h,
1049
1160
  style: {
1050
1161
  display: a?.display ? void 0 : "inline-block",
1051
- ...p.style
1162
+ ...m.style
1052
1163
  },
1053
1164
  dangerouslySetInnerHTML: { __html: e.svgCode }
1054
- }) : /* @__PURE__ */ m("span", {
1165
+ }) : /* @__PURE__ */ w("span", {
1055
1166
  ref: c,
1056
- ...p
1167
+ ...m
1057
1168
  });
1058
1169
  }
1059
- case "custom": return /* @__PURE__ */ m("img", {
1170
+ case "custom": return /* @__PURE__ */ w("img", {
1060
1171
  ref: c,
1061
1172
  src: u?.location,
1062
1173
  srcSet: u?.srcset?.path,
1063
1174
  decoding: "async",
1064
- alt: d ?? "icon",
1065
- ...p
1175
+ alt: f ?? "icon",
1176
+ ...m
1066
1177
  });
1067
- default: return /* @__PURE__ */ m("span", {
1178
+ default: return /* @__PURE__ */ w("span", {
1068
1179
  ref: c,
1069
- ...p
1180
+ ...m
1070
1181
  });
1071
1182
  }
1072
1183
  });
1073
- B.displayName = "BaseIcon";
1074
- var V = z(B), H = n.forwardRef(({ className: e, isLoading: t, loadingText: n, children: r, config: i = {}, styles: a, content: o, elementKey: s, generatedClassName: c, ...l }, u) => {
1075
- let d = r ?? o, f = i, v = (e, t) => e?.enabled ? /* @__PURE__ */ m(V, {
1184
+ Z.displayName = "BaseIcon";
1185
+ var Q = X(Z), $ = p.forwardRef(({ className: e, isLoading: t, loadingText: n, children: r, config: i = {}, styles: a, content: o, elementKey: s, generatedClassName: c, ...l }, u) => {
1186
+ let f = r ?? o, p = i, m = (e, t) => e?.enabled ? /* @__PURE__ */ w(Q, {
1076
1187
  noElementKey: !0,
1077
1188
  elementKey: `${s}_${t}Icon`
1078
1189
  }) : null;
1079
- return d ? /* @__PURE__ */ m("button", {
1190
+ return f ? /* @__PURE__ */ w("button", {
1080
1191
  "data-levo_element_key": s,
1081
1192
  "data-levo_element_type": "Button",
1082
1193
  type: "button",
1083
- className: g("inline-flex items-center justify-center", e, c),
1194
+ className: d("inline-flex items-center justify-center", e, c),
1084
1195
  ref: u,
1085
1196
  ...l,
1086
- children: t ? /* @__PURE__ */ h(p, { children: [/* @__PURE__ */ m(_, { className: g("h-4 w-4 animate-spin", n ? "mr-2" : "") }), n] }) : /* @__PURE__ */ h(p, { children: [
1087
- v(f?.button_icons?.left, "left"),
1088
- /* @__PURE__ */ m("span", {
1197
+ children: t ? /* @__PURE__ */ T(C, { children: [/* @__PURE__ */ w(D, { className: d("h-4 w-4 animate-spin", n ? "mr-2" : "") }), n] }) : /* @__PURE__ */ T(C, { children: [
1198
+ m(p?.button_icons?.left, "left"),
1199
+ /* @__PURE__ */ w("span", {
1089
1200
  className: "button-content",
1090
- children: d
1201
+ children: f
1091
1202
  }),
1092
- v(f?.button_icons?.right, "right")
1203
+ m(p?.button_icons?.right, "right")
1093
1204
  ] })
1094
- }) : /* @__PURE__ */ m("span", {
1205
+ }) : /* @__PURE__ */ w("span", {
1095
1206
  ref: u,
1096
1207
  style: { display: "none" }
1097
1208
  });
1098
1209
  });
1099
- H.displayName = "BaseButton";
1100
- var U = z(H);
1210
+ $.displayName = "BaseButton";
1211
+ var de = X($);
1101
1212
  //#endregion
1102
- export { S as _, P as a, O as c, N as d, M as f, T as g, w as h, z as i, A as l, C as m, U as n, j as o, E as p, V as r, D as s, H as t, k as u, b as v, x as y };
1213
+ export { I as _, ce as a, k as b, V as c, K as d, G as f, se as g, R as h, X as i, U as l, L as m, de as n, W as o, z as p, Q as r, B as s, $ as t, H as u, oe as v, F as y };