@blocklet/pages-kit-inner-components 0.4.109 → 0.4.111

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 (31) hide show
  1. package/lib/cjs/add-component.js +1 -1
  2. package/lib/cjs/chunks/{array-DHXwpDtd.js → array-CnXbKOG_.js} +23 -23
  3. package/lib/cjs/chunks/config-color-BBSht7j-.js +21 -0
  4. package/lib/cjs/chunks/{draft-data-UP_7unuZ.js → draft-data-DPTVTTlh.js} +1 -1
  5. package/lib/cjs/chunks/{home-Bouu7xjV.js → home-BXkUy2B8.js} +3 -3
  6. package/lib/cjs/chunks/{publish-button-BSxaxRDn.js → publish-button-B7nhzpwi.js} +1 -1
  7. package/lib/cjs/chunks/state-DDwYX2mu.js +1 -0
  8. package/lib/cjs/home.js +1 -1
  9. package/lib/cjs/locales.js +1 -1
  10. package/lib/cjs/setting.js +2 -2
  11. package/lib/cjs/uploader.js +1 -1
  12. package/lib/es/add-component.js +3 -3
  13. package/lib/es/chunks/{array-CVceCpS9.js → array-nAv4MiIp.js} +369 -344
  14. package/lib/es/chunks/config-color-JrBPRsTv.js +121 -0
  15. package/lib/es/chunks/{draft-data-0n1CKRWr.js → draft-data-BFlmvWXx.js} +3 -3
  16. package/lib/es/chunks/{home-2Nd5wxm6.js → home-Cjs79tsI.js} +4 -4
  17. package/lib/es/chunks/{publish-button-ChN-Liyi.js → publish-button-DhOdksVJ.js} +3 -3
  18. package/lib/es/chunks/{site-state-Bn8mEgOx.js → site-state-BVZLaWr2.js} +3 -3
  19. package/lib/es/chunks/{state-DsXKwImw.js → state-BgKqNapt.js} +12 -12
  20. package/lib/es/components.js +1 -1
  21. package/lib/es/home.js +3 -3
  22. package/lib/es/locales.js +4 -0
  23. package/lib/es/project-html.js +12 -12
  24. package/lib/es/resources.js +1 -1
  25. package/lib/es/setting.js +152 -151
  26. package/lib/es/site-state.js +6 -6
  27. package/lib/es/uploader.js +6 -64
  28. package/package.json +12 -12
  29. package/lib/cjs/chunks/config-color-Da8lKUL0.js +0 -21
  30. package/lib/cjs/chunks/state-BoXTl4DM.js +0 -1
  31. package/lib/es/chunks/config-color-B-ax03qd.js +0 -328
@@ -1,40 +1,40 @@
1
1
  import { jsx as o, jsxs as w, Fragment as J } from "react/jsx-runtime";
2
2
  import "@mui/icons-material";
3
- import { Box as x, Tooltip as Ft, styled as bt, Stack as yt, Typography as P, Container as At, useTheme as Ht, createTheme as Dt, ThemeProvider as Vt, Card as Ut, CircularProgress as Yt, Grid as lt, CardMedia as Mt, CardContent as Jt } from "@mui/material";
4
- import wt, { createContext as vt, useMemo as R, useCallback as E, useContext as kt, forwardRef as Gt, useState as j, useRef as G, Fragment as Xt, isValidElement as _t, useEffect as O } from "react";
5
- import X from "lodash/keyBy";
6
- import { a as z, b as S, E as Kt, f as ot, k as nt } from "./state-DsXKwImw.js";
3
+ import { Box as g, Tooltip as Ft, styled as bt, Stack as yt, Typography as P, Container as Vt, useTheme as Ut, createTheme as Ht, ThemeProvider as Dt, Card as Mt, CircularProgress as Yt, Grid as lt, CardMedia as Jt, CardContent as Gt } from "@mui/material";
4
+ import wt, { createContext as vt, useMemo as R, useCallback as E, useContext as kt, forwardRef as Kt, useState as T, useRef as G, Fragment as Xt, isValidElement as _t, useEffect as O } from "react";
5
+ import K from "lodash/keyBy";
6
+ import { h as j, b as N, E as qt, i as ot, m as nt } from "./state-BgKqNapt.js";
7
7
  import { AIForm as ct, AIFormResult as dt } from "@blocklet/ai-runtime/components";
8
- import { deepmerge as qt } from "@mui/utils";
8
+ import { deepmerge as Qt } from "@mui/utils";
9
9
  import rt from "lodash/pick";
10
- import { ErrorBoundary as Qt } from "react-error-boundary";
10
+ import { ErrorBoundary as Zt } from "react-error-boundary";
11
11
  import { useColorConvert as $t } from "@blocklet/pages-kit/contexts/color";
12
12
  import { cx as b, css as q } from "@emotion/css";
13
13
  import { Icon as Q } from "@iconify/react";
14
- import Zt from "react-markdown";
15
- import te from "remark-gfm";
16
- import { LoadingButton as ee } from "@mui/lab";
17
- import { useTheme as Nt, styled as _ } from "@arcblock/ux/lib/Theme";
18
- import oe from "@arcblock/react-hooks/lib/useBrowser";
14
+ import te from "react-markdown";
15
+ import ee from "remark-gfm";
16
+ import { LoadingButton as oe } from "@mui/lab";
17
+ import { useTheme as St, styled as _ } from "@arcblock/ux/lib/Theme";
18
+ import ne from "@arcblock/react-hooks/lib/useBrowser";
19
19
  import mt from "@arcblock/ux/lib/Colors";
20
- import { ResponsiveImage as St, CustomComponentRenderer as ne } from "@blocklet/pages-kit/components";
21
- import { isGradient as re, isColorString as ie } from "@blocklet/pages-kit/utils/style";
20
+ import { ResponsiveImage as Nt, CustomComponentRenderer as re } from "@blocklet/pages-kit/components";
21
+ import { isGradient as ie, isColorString as ae } from "@blocklet/pages-kit/utils/style";
22
22
  import Ct from "@mui/material/useMediaQuery";
23
23
  import C from "lodash/omit";
24
24
  import { Icon as Pt } from "@iconify-icon/react";
25
- import ae from "@arcblock/ux/lib/Screenshot";
26
- import { Link as se, NavLink as le, useNavigate as ce } from "react-router-dom";
27
- import de from "@arcblock/ux/lib/Button";
25
+ import se from "@arcblock/ux/lib/Screenshot";
26
+ import { Link as le, NavLink as ce, useNavigate as de } from "react-router-dom";
27
+ import me from "@arcblock/ux/lib/Button";
28
28
  import Z from "is-uri";
29
- import { join as Y } from "pathe";
30
- import { withoutTrailingSlash as K, isRelative as me, parseURL as pe } from "ufo";
31
- import { useMessage as ue } from "@blocklet/embed/message";
32
- import { useLatest as he } from "ahooks";
33
- import fe from "lodash/isEqual";
34
- import { EmbedIframe as ge } from "@blocklet/embed/react";
35
- import { TwitterTimelineEmbed as xe } from "react-twitter-embed";
36
- import { useUpdate as be, useMount as ye } from "react-use";
37
- const we = [
29
+ import { join as M } from "pathe";
30
+ import { withoutTrailingSlash as X, isRelative as ue, parseURL as pe } from "ufo";
31
+ import { useMessage as he } from "@blocklet/embed/message";
32
+ import { useLatest as fe } from "ahooks";
33
+ import ge from "lodash/isEqual";
34
+ import { EmbedIframe as xe } from "@blocklet/embed/react";
35
+ import { TwitterTimelineEmbed as be } from "react-twitter-embed";
36
+ import { useUpdate as ye, useMount as we } from "react-use";
37
+ const Bt = "{{CUSTOM_VALUE}}", ve = [
38
38
  {
39
39
  title: "None",
40
40
  value: "none",
@@ -55,7 +55,7 @@ const we = [
55
55
  value: "large",
56
56
  sx: { py: { xs: 7.5, md: 10, lg: 12.5, xl: 15 } }
57
57
  }
58
- ], ve = [
58
+ ], ke = [
59
59
  {
60
60
  title: "None",
61
61
  value: "none",
@@ -76,7 +76,7 @@ const we = [
76
76
  value: "large",
77
77
  sx: { py: { xs: 6, md: 9, lg: 9, xl: 11 } }
78
78
  }
79
- ], ke = [
79
+ ], _e = [
80
80
  {
81
81
  title: "None",
82
82
  value: "none",
@@ -97,17 +97,17 @@ const we = [
97
97
  value: "large",
98
98
  sx: { px: { xs: 7.5, md: 10, lg: 12.5, xl: 15 } }
99
99
  }
100
- ], M = (t, e, n) => {
100
+ ], Y = (t, e, n) => {
101
101
  const i = t.breakpoints.values[n];
102
102
  return `${e}${i ? ` (${i}px)` : ""}`;
103
- }, _e = [
103
+ }, $e = [
104
104
  {
105
105
  title: "100%",
106
106
  value: "full",
107
107
  sx: { maxWidth: "100%" }
108
108
  },
109
109
  {
110
- title: (t) => M(t, "Small", "sm"),
110
+ title: (t) => Y(t, "Small", "sm"),
111
111
  value: "sm",
112
112
  sx: {
113
113
  maxWidth: (t) => t.breakpoints.values.sm,
@@ -116,40 +116,63 @@ const we = [
116
116
  }
117
117
  },
118
118
  {
119
- title: (t) => M(t, "Normal", "md"),
119
+ title: (t) => Y(t, "Normal", "md"),
120
120
  value: "md",
121
121
  sx: { maxWidth: (t) => t.breakpoints.values.md, width: "100%", mx: "auto" }
122
122
  },
123
123
  {
124
- title: (t) => M(t, "Large", "lg"),
124
+ title: (t) => Y(t, "Large", "lg"),
125
125
  value: "lg",
126
126
  sx: { maxWidth: (t) => t.breakpoints.values.lg, width: "100%", mx: "auto" }
127
127
  },
128
128
  {
129
- title: (t) => M(t, "Extra Large", "xl"),
129
+ title: (t) => Y(t, "Extra Large", "xl"),
130
130
  value: "xl",
131
131
  sx: { maxWidth: (t) => t.breakpoints.values.xl, width: "100%", mx: "auto" }
132
+ },
133
+ {
134
+ title: "Custom",
135
+ value: "custom",
136
+ sx: {
137
+ maxWidth: Bt,
138
+ width: "100%",
139
+ mx: "auto"
140
+ }
132
141
  }
133
- ], $e = X(we, "value"), Ne = X(ve, "value"), Se = X(ke, "value"), Ce = X(_e, "value"), Pe = /* @__PURE__ */ new Map([
134
- ["baseSectionPaddingY", $e],
135
- ["maxWidth", Ce],
142
+ ], Se = K(ve, "value"), Ne = K(ke, "value"), Ce = K(_e, "value"), Pe = K($e, "value"), Be = /* @__PURE__ */ new Map([
143
+ ["baseSectionPaddingY", Se],
144
+ ["maxWidth", Pe],
136
145
  ["paddingY", Ne],
137
- ["paddingX", Se]
146
+ ["paddingX", Ce]
138
147
  ]);
139
- function Bt(t) {
140
- var c;
141
- const { type: e, value: n, format: i = "sx", defaultValue: r = null } = t, a = Pe.get(e);
142
- return a && a != null && a[n] && (c = a == null ? void 0 : a[n]) != null && c[i] ? a[n][i] : r;
148
+ function It(t) {
149
+ var l;
150
+ const { type: e, value: n, format: i = "sx", defaultValue: r = null } = t, a = Be.get(e);
151
+ if (!a)
152
+ return r;
153
+ const c = n.startsWith("custom:"), s = c ? "custom" : n;
154
+ if (a != null && a[s] && ((l = a == null ? void 0 : a[s]) != null && l[i])) {
155
+ const d = a[s][i];
156
+ if (c) {
157
+ const m = n.replace("custom:", "");
158
+ try {
159
+ return JSON.parse(JSON.stringify(d || {}).replaceAll(Bt, m));
160
+ } catch {
161
+ }
162
+ }
163
+ return d;
164
+ }
165
+ return r;
143
166
  }
144
- const It = vt({
167
+ const Wt = vt({
145
168
  page: null,
146
169
  getPageMeta: () => ({}),
147
170
  getPageMetaStyle: () => ({})
148
171
  });
149
- function Be() {
150
- return kt(It);
172
+ function Ie() {
173
+ return kt(Wt);
151
174
  }
152
- function yn({
175
+ function wn({
153
176
  page: t,
154
177
  children: e,
155
178
  defaultLocale: n = "en",
@@ -163,14 +186,16 @@ function yn({
163
186
  }, [r, n, i]), c = E(
164
187
  (l = "sx") => {
165
188
  const d = a();
166
- return !d || !d.style ? {} : Object.entries(d.style || {}).reduce((p, [h, u]) => {
167
- if (!u) return p;
168
- const f = Bt({
189
+ return !d || !d.style ? {} : Object.entries(d.style || {}).reduce((u, [h, p]) => {
190
+ if (!p) return u;
191
+ const x = `${h}Custom`;
192
+ d.style[x];
193
+ const y = It({
169
194
  type: h,
170
- value: u,
195
+ value: p,
171
196
  format: l
172
197
  });
173
- return f ? { ...p, ...f } : p;
198
+ return y ? { ...u, ...y } : u;
174
199
  }, {});
175
200
  },
176
201
  [a]
@@ -182,10 +207,10 @@ function yn({
182
207
  }),
183
208
  [r, a, c]
184
209
  );
185
- return /* @__PURE__ */ o(It.Provider, { value: s, children: e });
210
+ return /* @__PURE__ */ o(Wt.Provider, { value: s, children: e });
186
211
  }
187
- const Ie = Gt(({ onClick: t, ...e }, n) => {
188
- const [i, r] = j(!1), a = E(
212
+ const We = Kt(({ onClick: t, ...e }, n) => {
213
+ const [i, r] = T(!1), a = E(
189
214
  async (c) => {
190
215
  try {
191
216
  r(!0), await (t == null ? void 0 : t(c));
@@ -195,9 +220,9 @@ const Ie = Gt(({ onClick: t, ...e }, n) => {
195
220
  },
196
221
  [t]
197
222
  );
198
- return /* @__PURE__ */ o(ee, { ref: n, ...e, loading: e.loading || i, onClick: a });
223
+ return /* @__PURE__ */ o(oe, { ref: n, ...e, loading: e.loading || i, onClick: a });
199
224
  });
200
- function We({
225
+ function Re({
201
226
  tip: t,
202
227
  tipSucceed: e,
203
228
  title: n,
@@ -208,23 +233,23 @@ function We({
208
233
  placement: s = "top",
209
234
  ...l
210
235
  }) {
211
- const [d, m] = j(!1), [p, h] = j(), u = G(), f = () => {
212
- h(void 0), c && (u.current = window.setTimeout(() => {
236
+ const [d, m] = T(!1), [u, h] = T(), p = G(), x = () => {
237
+ h(void 0), c && (p.current = window.setTimeout(() => {
213
238
  m(!1);
214
239
  }, 3e3));
215
240
  }, y = () => {
216
- clearTimeout(u.current);
217
- }, g = d ? a : r, v = p ? /* @__PURE__ */ o(x, { color: "error", children: p.message }) : d && e || t;
218
- return /* @__PURE__ */ o(Ft, { title: v, disableInteractive: !0, placement: s, onClose: f, onOpen: y, children: /* @__PURE__ */ o("span", { children: /* @__PURE__ */ o(
219
- Ie,
241
+ clearTimeout(p.current);
242
+ }, f = d ? a : r, v = u ? /* @__PURE__ */ o(g, { color: "error", children: u.message }) : d && e || t;
243
+ return /* @__PURE__ */ o(Ft, { title: v, disableInteractive: !0, placement: s, onClose: x, onOpen: y, children: /* @__PURE__ */ o("span", { children: /* @__PURE__ */ o(
244
+ We,
220
245
  {
221
- startIcon: g && (typeof g == "string" ? /* @__PURE__ */ o(Q, { icon: g }) : g),
222
- loadingPosition: g ? "start" : void 0,
246
+ startIcon: f && (typeof f == "string" ? /* @__PURE__ */ o(Q, { icon: f }) : f),
247
+ loadingPosition: f ? "start" : void 0,
223
248
  ...l,
224
- onClick: async (N) => {
249
+ onClick: async (S) => {
225
250
  if (l.onClick)
226
251
  try {
227
- await l.onClick(N), m(!0);
252
+ await l.onClick(S), m(!0);
228
253
  } catch (B) {
229
254
  h(B);
230
255
  }
@@ -233,19 +258,19 @@ function We({
233
258
  }
234
259
  ) }) });
235
260
  }
236
- const Re = wt.lazy(() => import("react-syntax-highlighter").then((t) => ({ default: t.Prism }))), je = bt((t) => /* @__PURE__ */ o(
237
- Zt,
261
+ const Te = wt.lazy(() => import("react-syntax-highlighter").then((t) => ({ default: t.Prism }))), je = bt((t) => /* @__PURE__ */ o(
262
+ te,
238
263
  {
239
264
  ...t,
240
- remarkPlugins: [te],
265
+ remarkPlugins: [ee],
241
266
  components: {
242
267
  pre: ze,
243
268
  code: ({ node: e, inline: n, className: i, children: r, ...a }) => {
244
269
  if (!r) return null;
245
270
  const c = /language-(\w+)/.exec(i || "");
246
- return n ? /* @__PURE__ */ o(x, { component: "code", className: i, ...a, children: r }) : /* @__PURE__ */ o(x, { component: Re, language: c == null ? void 0 : c[1], ...a, sx: { borderRadius: 1 }, children: String(r).replace(/\n$/, "") });
271
+ return n ? /* @__PURE__ */ o(g, { component: "code", className: i, ...a, children: r }) : /* @__PURE__ */ o(g, { component: Te, language: c == null ? void 0 : c[1], ...a, sx: { borderRadius: 1 }, children: String(r).replace(/\n$/, "") });
247
272
  },
248
- table: ({ className: e, children: n }) => /* @__PURE__ */ o(x, { sx: { overflow: "auto", my: 1 }, children: /* @__PURE__ */ o("table", { className: e, children: n }) })
273
+ table: ({ className: e, children: n }) => /* @__PURE__ */ o(g, { sx: { overflow: "auto", my: 1 }, children: /* @__PURE__ */ o("table", { className: e, children: n }) })
249
274
  }
250
275
  }
251
276
  ))`
@@ -326,7 +351,7 @@ function ze({ children: t }) {
326
351
  if (!(e != null && e.children)) return null;
327
352
  const n = /language-(\w+)/.exec(e.className || ""), i = n == null ? void 0 : n[1];
328
353
  return /* @__PURE__ */ w(
329
- x,
354
+ g,
330
355
  {
331
356
  component: "div",
332
357
  sx: {
@@ -337,10 +362,10 @@ function ze({ children: t }) {
337
362
  },
338
363
  children: [
339
364
  /* @__PURE__ */ w(yt, { direction: "row", alignItems: "center", p: 0.5, pl: 1.5, borderBottom: 1, borderColor: "grey.200", children: [
340
- /* @__PURE__ */ o(x, { children: i }),
341
- /* @__PURE__ */ o(x, { flex: 1 }),
365
+ /* @__PURE__ */ o(g, { children: i }),
366
+ /* @__PURE__ */ o(g, { flex: 1 }),
342
367
  /* @__PURE__ */ o(
343
- We,
368
+ Re,
344
369
  {
345
370
  autoReset: !0,
346
371
  title: /* @__PURE__ */ o(Q, { icon: "tabler:copy" }),
@@ -357,9 +382,9 @@ function ze({ children: t }) {
357
382
  }
358
383
  );
359
384
  }
360
- function T({ actions: t, center: e, className: n, align: i }) {
385
+ function z({ actions: t, center: e, className: n, align: i }) {
361
386
  return t && (t != null && t.length) ? /* @__PURE__ */ o(
362
- x,
387
+ g,
363
388
  {
364
389
  className: b(
365
390
  "flex gap-4 flex-wrap",
@@ -374,7 +399,7 @@ function T({ actions: t, center: e, className: n, align: i }) {
374
399
  }
375
400
  ) : null;
376
401
  }
377
- const Te = "section", Le = bt(x)`
402
+ const Le = "section", Ee = bt(g)`
378
403
  overflow: hidden;
379
404
 
380
405
  .section__title {
@@ -423,7 +448,7 @@ const Te = "section", Le = bt(x)`
423
448
  margin-bottom: 0.5rem;
424
449
  }
425
450
  }
426
- @media (min-width: ${({ theme: t }) => t.breakpoints.values[Te]}px) {
451
+ @media (min-width: ${({ theme: t }) => t.breakpoints.values[Le]}px) {
427
452
  .section__tag {
428
453
  margin-bottom: 32px;
429
454
  }
@@ -435,7 +460,7 @@ const Te = "section", Le = bt(x)`
435
460
  }
436
461
  }
437
462
  `;
438
- function F({
463
+ function A({
439
464
  title: t,
440
465
  description: e,
441
466
  descriptionMarkdown: n,
@@ -447,13 +472,13 @@ function F({
447
472
  level: l = 2,
448
473
  tag: d,
449
474
  badge: m,
450
- center: p,
475
+ center: u,
451
476
  logo: h,
452
- titleAppearance: u,
453
- descriptionAppearance: f,
477
+ titleAppearance: p,
478
+ descriptionAppearance: x,
454
479
  ...y
455
480
  }) {
456
- const g = $t();
481
+ const f = $t();
457
482
  if (!t && !e && !i && !m && !d && !c && !s && !h) return null;
458
483
  const v = Math.max(Math.min(5, l + 1), 1), k = {
459
484
  1: "xl:!text-3xl lg:!text-2xl md:!text-xl",
@@ -462,8 +487,8 @@ function F({
462
487
  4: "xl:!text-xl lg:!text-lg md:!text-md",
463
488
  5: "xl:!text-lg md:!text-md sm:!text-sm",
464
489
  6: "!text-sm"
465
- }, N = l === 0 ? "big" : `h${v}`, B = l === 0;
466
- return /* @__PURE__ */ w(Le, { className: b("base-info", "lg:text-left", p && "!text-center", r), ...y, children: [
490
+ }, S = l === 0 ? "big" : `h${v}`, B = l === 0;
491
+ return /* @__PURE__ */ w(Ee, { className: b("base-info", "lg:text-left", u && "!text-center", r), ...y, children: [
467
492
  c && /* @__PURE__ */ o("div", { children: c }),
468
493
  (d || m) && /* @__PURE__ */ o("div", { className: b("section__tag", (a == null ? void 0 : a.tag) || (a == null ? void 0 : a.badge)), children: d || m }),
469
494
  h && /* @__PURE__ */ o("img", { className: "w-[120px] m-auto mb-8", src: h, alt: "info", loading: "lazy" }),
@@ -473,7 +498,7 @@ function F({
473
498
  sx: {
474
499
  whiteSpace: "pre-wrap",
475
500
  mb: e ? "2vw" : 0,
476
- ...(u == null ? void 0 : u.color) && { color: `${g(u.color)} !important` }
501
+ ...(p == null ? void 0 : p.color) && { color: `${f(p.color)} !important` }
477
502
  },
478
503
  className: b(
479
504
  "section__title",
@@ -484,15 +509,15 @@ function F({
484
509
  B ? "" : "section__title_non_big"
485
510
  ),
486
511
  component: `h${Math.max(l, 1)}`,
487
- variant: N,
512
+ variant: S,
488
513
  children: t
489
514
  }
490
515
  ),
491
516
  e && (n ? /* @__PURE__ */ o(
492
- x,
517
+ g,
493
518
  {
494
519
  sx: {
495
- ...(f == null ? void 0 : f.color) && { color: `${g(f.color)} !important` }
520
+ ...(x == null ? void 0 : x.color) && { color: `${f(x.color)} !important` }
496
521
  },
497
522
  component: je,
498
523
  className: b(
@@ -510,7 +535,7 @@ function F({
510
535
  {
511
536
  sx: {
512
537
  whiteSpace: "pre-wrap",
513
- ...(f == null ? void 0 : f.color) && { color: `${g(f.color)} !important` }
538
+ ...(x == null ? void 0 : x.color) && { color: `${f(x.color)} !important` }
514
539
  },
515
540
  className: b(
516
541
  "section__description",
@@ -526,11 +551,11 @@ function F({
526
551
  children: e
527
552
  }
528
553
  )),
529
- /* @__PURE__ */ o(T, { actions: i, center: p, className: "mt-8" }),
554
+ /* @__PURE__ */ o(z, { actions: i, center: u, className: "mt-8" }),
530
555
  s && /* @__PURE__ */ o("div", { children: s })
531
556
  ] });
532
557
  }
533
- const A = [
558
+ const F = [
534
559
  "actions",
535
560
  "append",
536
561
  "badge",
@@ -545,10 +570,10 @@ const A = [
545
570
  "titleAppearance",
546
571
  "descriptionAppearance"
547
572
  ];
548
- function Wt(t) {
573
+ function Rt(t) {
549
574
  if (t.type === Xt) {
550
575
  const n = (t.props.children || []).filter((i) => _t(i));
551
- return n.length === 1 ? Wt(n[0]) : n.length > 1;
576
+ return n.length === 1 ? Rt(n[0]) : n.length > 1;
552
577
  }
553
578
  return Array.isArray(t);
554
579
  }
@@ -562,7 +587,7 @@ function it({ children: t, col: e, gap: n, className: i, align: r, sx: a, type:
562
587
  align: "center",
563
588
  type: "default"
564
589
  }) {
565
- const l = Nt(), d = Number(Math.floor(100 / e * 100) / 100), m = {
590
+ const l = St(), d = Number(Math.floor(100 / e * 100) / 100), m = {
566
591
  center: "justify-center items-center",
567
592
  left: "justify-start items-center",
568
593
  right: "justify-end items-center",
@@ -572,43 +597,43 @@ function it({ children: t, col: e, gap: n, className: i, align: r, sx: a, type:
572
597
  "top-right": "justify-end items-start",
573
598
  "bottom-left": "justify-start items-end",
574
599
  "bottom-right": "justify-end items-end"
575
- }, p = m[r] || m.center;
576
- let u = n ?? ({
600
+ }, u = m[r] || m.center;
601
+ let p = n ?? ({
577
602
  2: 6,
578
603
  3: 4,
579
604
  4: 4,
580
605
  5: 3,
581
606
  6: 3
582
607
  }[e] || 0);
583
- Wt(t) || (u = 0);
584
- const y = (e - 1) * u / e;
585
- let g = { ...a, gap: `${u}rem` };
586
- const v = { [I]: { width: "100%" } }, k = {}, N = {}, B = {};
587
- switch (v.gap = "1rem", k.gap = `${u / 2}rem`, e) {
608
+ Rt(t) || (p = 0);
609
+ const y = (e - 1) * p / e;
610
+ let f = { ...a, gap: `${p}rem` };
611
+ const v = { [I]: { width: "100%" } }, k = {}, S = {}, B = {};
612
+ switch (v.gap = "1rem", k.gap = `${p / 2}rem`, e) {
588
613
  case 3:
589
614
  case 4:
590
615
  k[I] = {
591
- width: `calc(50% - ${u / 2}rem)`
616
+ width: `calc(50% - ${p / 2}rem)`
592
617
  };
593
618
  break;
594
619
  case 5:
595
620
  case 6:
596
621
  v[I] = {
597
- width: `calc(50% - ${u / 2 / 2}rem)`
622
+ width: `calc(50% - ${p / 2 / 2}rem)`
598
623
  }, k[I] = {
599
- width: `calc(50% - ${u / 2 / 2}rem)`
600
- }, N[I] = {
601
- width: `calc(33.33% - ${u * 2 / 3}rem)`
624
+ width: `calc(50% - ${p / 2 / 2}rem)`
625
+ }, S[I] = {
626
+ width: `calc(33.33% - ${p * 2 / 3}rem)`
602
627
  };
603
628
  break;
604
629
  }
605
- return g[I] = { width: `calc(${d}% - ${y}rem)` }, g[`@media (max-width: ${l.breakpoints.values.xl}px)`] = B, g[`@media (max-width: ${l.breakpoints.values.lg}px)`] = N, g[`@media (max-width: ${l.breakpoints.values.md}px)`] = k, g[`@media (max-width: ${l.breakpoints.values.sm}px)`] = v, c === "wall" && (g = { ...a, gap: `${u}rem` }, g[I] = { width: `calc(${d}% - ${y}rem)` }, v[I] = { width: `calc(45% - ${u / 2 / 2}rem)` }, g[`@media (max-width: ${l.breakpoints.values.sm}px)`] = v), /* @__PURE__ */ o(x, { className: b("flex flex-wrap flex-row h-full", p, i), sx: g, ...s, children: t });
630
+ return f[I] = { width: `calc(${d}% - ${y}rem)` }, f[`@media (max-width: ${l.breakpoints.values.xl}px)`] = B, f[`@media (max-width: ${l.breakpoints.values.lg}px)`] = S, f[`@media (max-width: ${l.breakpoints.values.md}px)`] = k, f[`@media (max-width: ${l.breakpoints.values.sm}px)`] = v, c === "wall" && (f = { ...a, gap: `${p}rem` }, f[I] = { width: `calc(${d}% - ${y}rem)` }, v[I] = { width: `calc(45% - ${p / 2 / 2}rem)` }, f[`@media (max-width: ${l.breakpoints.values.sm}px)`] = v), /* @__PURE__ */ o(g, { className: b("flex flex-wrap flex-row h-full", u, i), sx: f, ...s, children: t });
606
631
  }
607
- function Ee() {
632
+ function Oe() {
608
633
  const t = navigator.userAgent.toLowerCase();
609
634
  return t.includes("safari") && !t.includes("chrome");
610
635
  }
611
- function Oe(t = "") {
636
+ function Ae(t = "") {
612
637
  if (t.startsWith("data:image/svg+xml,")) return !0;
613
638
  const e = /^(((ht|f)tps?):\/\/)?([^!@#$%^&*?.\s-]([^!@#$%^&*?.\s]{0,63}[^!@#$%^&*?.\s])?\.)+[a-z]{2,6}\/?/, n = /^(\/|\.\/|\.\.\/)(?:[^/]+\/)*[^/]+$/;
614
639
  return e.test(t) || n.test(t);
@@ -619,12 +644,12 @@ function tt(t) {
619
644
  function Fe(t) {
620
645
  return t != null && t.endsWith(".mp4") || t != null && t.endsWith(".m4v") ? "video/mp4" : t != null && t.endsWith(".webm") ? "video/webm" : void 0;
621
646
  }
622
- function Ae(t) {
647
+ function Ve(t) {
623
648
  let e = {};
624
- return typeof t == "string" ? re(t) ? e.image = t : (e.image = S(t), ie(t) && (e.color = t, e.image = "")) : e = t, e;
649
+ return typeof t == "string" ? ie(t) ? e.image = t : (e.image = N(t), ae(t) && (e.color = t, e.image = "")) : e = t, e;
625
650
  }
626
- function He() {
627
- const [t, e] = j(Date.now());
651
+ function Ue() {
652
+ const [t, e] = T(Date.now());
628
653
  return O(() => {
629
654
  const n = () => {
630
655
  e(Date.now());
@@ -634,11 +659,11 @@ function He() {
634
659
  };
635
660
  }, []), t;
636
661
  }
637
- function pt(t, e, n, i, r) {
662
+ function ut(t, e, n, i, r) {
638
663
  let a = null;
639
- const { color: c = "", image: s } = Ae(e);
640
- return s && Oe(s) ? (delete n.backgroundColor, !(t.mobile.apple.device || Ee()) && tt(s) ? a = /* @__PURE__ */ o(
641
- x,
664
+ const { color: c = "", image: s } = Ve(e);
665
+ return s && Ae(s) ? (delete n.backgroundColor, !(t.mobile.apple.device || Oe()) && tt(s) ? a = /* @__PURE__ */ o(
666
+ g,
642
667
  {
643
668
  component: "video",
644
669
  className: "section-bg",
@@ -648,8 +673,8 @@ function pt(t, e, n, i, r) {
648
673
  muted: !0,
649
674
  controls: !1,
650
675
  playsInline: !0,
651
- poster: z(S(i), 1200, "quality"),
652
- src: tt(s) ? s : z(s, 1200, "quality"),
676
+ poster: j(N(i), 1200, "quality"),
677
+ src: tt(s) ? s : j(s, 1200, "quality"),
653
678
  sx: {
654
679
  position: "absolute",
655
680
  zIndex: -9999,
@@ -663,7 +688,7 @@ function pt(t, e, n, i, r) {
663
688
  },
664
689
  s
665
690
  ) : a = /* @__PURE__ */ o(
666
- St,
691
+ Nt,
667
692
  {
668
693
  src: s,
669
694
  sizesAttr: {
@@ -689,10 +714,10 @@ function pt(t, e, n, i, r) {
689
714
  r || s
690
715
  )) : s ? n.backgroundImage = `${s} !important` : c && (n.backgroundColor = `${c} !important`), a;
691
716
  }
692
- function De({ autoWidth: t, children: e, ...n }) {
693
- return t ? /* @__PURE__ */ o(x, { display: "flex", ...n, children: e }) : /* @__PURE__ */ o(At, { ...n, children: e });
717
+ function He({ autoWidth: t, children: e, ...n }) {
718
+ return t ? /* @__PURE__ */ o(g, { display: "flex", ...n, children: e }) : /* @__PURE__ */ o(Vt, { ...n, children: e });
694
719
  }
695
- function H({
720
+ function V({
696
721
  dark: t = !1,
697
722
  children: e,
698
723
  className: n,
@@ -703,23 +728,23 @@ function H({
703
728
  type: s,
704
729
  ...l
705
730
  }) {
706
- const d = { ...i }, m = Ct((u) => u.breakpoints.down("md"));
731
+ const d = { ...i }, m = Ct((p) => p.breakpoints.down("md"));
707
732
  t && (d.color = mt.common.white, d.backgroundColor = `${mt.grey[900]} !important`), r.show && (d.display = "flex");
708
- const p = R(() => !Number(l.boxMaxWidth) || m ? {
733
+ const u = R(() => !Number(l.boxMaxWidth) || m ? {
709
734
  width: "100%"
710
735
  } : s === "wall" && l.boxMaxWidth ? {
711
736
  maxWidth: `${l.boxMaxWidth}px !important`,
712
737
  width: "100%"
713
738
  } : {
714
739
  width: "100%"
715
- }, [l.boxMaxWidth, m, s]), h = Bt({
740
+ }, [l.boxMaxWidth, m, s]), h = It({
716
741
  type: "baseSectionPaddingY",
717
742
  value: a || "normal",
718
743
  // section default is normal
719
744
  defaultValue: ""
720
745
  });
721
746
  return /* @__PURE__ */ o(
722
- Ve,
747
+ De,
723
748
  {
724
749
  component: "section",
725
750
  styles: { ...d, ...h },
@@ -737,11 +762,11 @@ function H({
737
762
  "titleAppearance",
738
763
  "descriptionAppearance"
739
764
  ),
740
- children: /* @__PURE__ */ o(De, { autoWidth: l == null ? void 0 : l.autoWidth, className: b("section-content h-full"), sx: p, children: r.show ? /* @__PURE__ */ o(Rt, { ...c, boxed: r, children: e }) : e })
765
+ children: /* @__PURE__ */ o(He, { autoWidth: l == null ? void 0 : l.autoWidth, className: b("section-content h-full"), sx: u, children: r.show ? /* @__PURE__ */ o(Tt, { ...c, boxed: r, children: e }) : e })
741
766
  }
742
767
  );
743
768
  }
744
- function Rt({
769
+ function Tt({
745
770
  background: t = "",
746
771
  backgroundVideoPoster: e,
747
772
  children: n,
@@ -753,21 +778,21 @@ function Rt({
753
778
  }) {
754
779
  const l = { ...c, ...i }, d = $t();
755
780
  let m = null;
756
- const p = Ct((f) => f.breakpoints.up("sm")), h = oe(), u = He();
757
- return t && (m = pt(
781
+ const u = Ct((x) => x.breakpoints.up("sm")), h = ne(), p = Ue();
782
+ return t && (m = ut(
758
783
  h,
759
784
  typeof t == "string" ? d(t) : t,
760
785
  l,
761
786
  e,
762
- u
763
- )), r.show && (l.borderRadius = "10px", l.padding === void 0 && (l.padding = p ? "50px" : "20px"), r != null && r.border && (l.border = "1px solid #c0c0c0"), r != null && r.background && (m = pt(
787
+ p
788
+ )), r.show && (l.borderRadius = "10px", l.padding === void 0 && (l.padding = u ? "50px" : "20px"), r != null && r.border && (l.border = "1px solid #c0c0c0"), r != null && r.background && (m = ut(
764
789
  h,
765
790
  typeof (r == null ? void 0 : r.background) == "string" ? d(r == null ? void 0 : r.background) : r == null ? void 0 : r.background,
766
791
  l,
767
792
  r == null ? void 0 : r.backgroundVideoPoster,
768
- u
793
+ p
769
794
  ))), /* @__PURE__ */ w(
770
- x,
795
+ g,
771
796
  {
772
797
  ...s,
773
798
  sx: {
@@ -782,7 +807,7 @@ function Rt({
782
807
  }
783
808
  );
784
809
  }
785
- const Ve = _(Rt)`
810
+ const De = _(Tt)`
786
811
  &:nth-of-type(even) {
787
812
  background: #f8f8f8;
788
813
  }
@@ -807,7 +832,7 @@ function $(t, e) {
807
832
  return [n, i];
808
833
  }
809
834
  const zt = ["title", "description", "actions", "badge", "tag", "prepend", "append", "logo"];
810
- function Ue({
835
+ function Me({
811
836
  image: t,
812
837
  imageBorder: e,
813
838
  imageShadow: n,
@@ -816,8 +841,8 @@ function Ue({
816
841
  fullSizeImage: a,
817
842
  ...c
818
843
  }) {
819
- const [s, l] = $(c, A), d = Object.keys(s).length > 0 && Object.values(rt(s, zt)).filter(Boolean).length > 0 && /* @__PURE__ */ o(F, { ...s }), m = _t(t) ? t : /* @__PURE__ */ o(x, { component: "img", src: t, alt: "", className: "block" }), p = ["phone", "macbook"].includes(e), h = t && /* @__PURE__ */ o(
820
- x,
844
+ const [s, l] = $(c, F), d = Object.keys(s).length > 0 && Object.values(rt(s, zt)).filter(Boolean).length > 0 && /* @__PURE__ */ o(A, { ...s }), m = _t(t) ? t : /* @__PURE__ */ o(g, { component: "img", src: t, alt: "", className: "block" }), u = ["phone", "macbook"].includes(e), h = t && /* @__PURE__ */ o(
845
+ g,
821
846
  {
822
847
  className: b(
823
848
  "section__image",
@@ -830,16 +855,16 @@ function Ue({
830
855
  borderRadius: 2,
831
856
  overflow: "hidden",
832
857
  // FIXME: Screenshot 组件无法设置最外层 div 的样式,只能通过父元素设置
833
- "> div": p ? { width: "100%", video: { borderRadius: "0 !important" } } : void 0
858
+ "> div": u ? { width: "100%", video: { borderRadius: "0 !important" } } : void 0
834
859
  },
835
- children: p ? (
860
+ children: u ? (
836
861
  // @ts-ignore
837
- /* @__PURE__ */ o(ae, { type: e, sx: { width: "100%" }, children: m })
862
+ /* @__PURE__ */ o(se, { type: e, sx: { width: "100%" }, children: m })
838
863
  ) : m
839
864
  }
840
865
  );
841
866
  return /* @__PURE__ */ o(
842
- H,
867
+ V,
843
868
  {
844
869
  className: b(
845
870
  "section--block",
@@ -882,15 +907,15 @@ function Ue({
882
907
  }
883
908
  );
884
909
  }
885
- const D = ["editing", "height", "locale", "dev", "sx"];
910
+ const U = ["editing", "height", "locale", "dev", "sx"];
886
911
  function Ye(t) {
887
912
  const { className: e, ...n } = t;
888
- return /* @__PURE__ */ o(Me, { ...n, className: b("BlockBase-root", e) });
913
+ return /* @__PURE__ */ o(Je, { ...n, className: b("BlockBase-root", e) });
889
914
  }
890
- const Me = _(x)`
915
+ const Je = _(g)`
891
916
  position: relative;
892
917
  `;
893
- function Je({
918
+ function Ge({
894
919
  widget: t,
895
920
  reverse: e,
896
921
  projectId: n,
@@ -902,9 +927,9 @@ function Je({
902
927
  placeholder: l,
903
928
  loadingIndicator: d,
904
929
  section: m,
905
- ...p
930
+ ...u
906
931
  }) {
907
- const [{ editing: h }, u] = $(p, D), [f, y] = $(u, A), g = n && i ? { projectId: n, gitRef: "main", assistantId: i, working: !0 } : void 0, v = {
932
+ const [{ editing: h }, p] = $(u, U), [x, y] = $(p, F), f = n && i ? { projectId: n, gitRef: "main", assistantId: i, working: !0 } : void 0, v = {
908
933
  children: a,
909
934
  endIcon: c ? /* @__PURE__ */ o(jt, { icon: c }) : void 0,
910
935
  sx: {
@@ -914,57 +939,57 @@ function Je({
914
939
  opacity: 0.8
915
940
  }
916
941
  }
917
- }, k = [], N = l && /* @__PURE__ */ o(P, { variant: "caption", color: "text.disabled", children: l }), B = d && /* @__PURE__ */ o(P, { variant: "caption", color: "text.disabled", children: d });
918
- Object.keys(f).length > 0 && Object.values(rt(f, zt)).filter(Boolean).length > 0 && k.push(/* @__PURE__ */ o(F, { ...f }, "base-info")), g && (t === "form" ? k.push(/* @__PURE__ */ o(ct, { identifier: g, SubmitProps: v }, "form")) : t === "result" ? k.push(
942
+ }, k = [], S = l && /* @__PURE__ */ o(P, { variant: "caption", color: "text.disabled", children: l }), B = d && /* @__PURE__ */ o(P, { variant: "caption", color: "text.disabled", children: d });
943
+ Object.keys(x).length > 0 && Object.values(rt(x, zt)).filter(Boolean).length > 0 && k.push(/* @__PURE__ */ o(A, { ...x }, "base-info")), f && (t === "form" ? k.push(/* @__PURE__ */ o(ct, { identifier: f, SubmitProps: v }, "form")) : t === "result" ? k.push(
919
944
  /* @__PURE__ */ o(
920
945
  dt,
921
946
  {
922
- identifier: g,
923
- placeholder: N,
947
+ identifier: f,
948
+ placeholder: S,
924
949
  loadingIndicator: B
925
950
  },
926
951
  "result"
927
952
  )
928
953
  ) : k.push(
929
954
  /* @__PURE__ */ w(yt, { width: "100%", gap: 2, direction: "row", children: [
930
- /* @__PURE__ */ o(ct, { identifier: g, BoxProps: { flex: 1 }, SubmitProps: v }),
955
+ /* @__PURE__ */ o(ct, { identifier: f, BoxProps: { flex: 1 }, SubmitProps: v }),
931
956
  /* @__PURE__ */ o(
932
957
  dt,
933
958
  {
934
- identifier: g,
959
+ identifier: f,
935
960
  BoxProps: { flex: 1 },
936
- placeholder: N,
961
+ placeholder: S,
937
962
  loadingIndicator: B
938
963
  }
939
964
  )
940
965
  ] }, "form-result")
941
966
  )), e && k.reverse();
942
- const st = Ht(), Ot = R(
943
- () => Dt(qt(st, { palette: { primary: s ? { main: s } : void 0 } })),
967
+ const st = Ut(), At = R(
968
+ () => Ht(Qt(st, { palette: { primary: s ? { main: s } : void 0 } })),
944
969
  [s, st]
945
970
  );
946
- return /* @__PURE__ */ o(Qt, { fallbackRender: Kt, children: /* @__PURE__ */ o(Vt, { theme: Ot, children: /* @__PURE__ */ o(H, { ...y, sx: h ? { pointerEvents: "none" } : {}, children: /* @__PURE__ */ o(it, { col: k.length, children: k }) }) }) });
971
+ return /* @__PURE__ */ o(Zt, { fallbackRender: qt, children: /* @__PURE__ */ o(Dt, { theme: At, children: /* @__PURE__ */ o(V, { ...y, sx: h ? { pointerEvents: "none" } : {}, children: /* @__PURE__ */ o(it, { col: k.length, children: k }) }) }) });
947
972
  }
948
- const Tt = vt({
973
+ const Lt = vt({
949
974
  pages: [],
950
975
  project: void 0
951
- }), { Provider: wn, Consumer: vn } = Tt;
952
- function Lt() {
953
- return kt(Tt);
976
+ }), { Provider: vn, Consumer: kn } = Lt;
977
+ function Et() {
978
+ return kt(Lt);
954
979
  }
955
- function Ge({ icon: t, className: e = "", size: n = "1rem", ...i }) {
980
+ function Ke({ icon: t, className: e = "", size: n = "1rem", ...i }) {
956
981
  return /* @__PURE__ */ o(Xe, { component: jt, className: b("css-icon", e), size: n, ...i, icon: t });
957
982
  }
958
- const Xe = _(x)`
983
+ const Xe = _(g)`
959
984
  &.css-icon {
960
985
  display: inline-block;
961
986
  width: ${({ size: t }) => t};
962
987
  height: ${({ size: t }) => t};
963
988
  }
964
989
  `;
965
- function Ke({ icon: t, className: e = "", size: n = "1rem", imageMeta: i, ...r }) {
966
- const a = z(S(t), 540), [c, s] = j(!1), l = Nt();
967
- return c ? /* @__PURE__ */ o(Ge, { icon: "i-mdi:image", color: l.palette.grey[500], size: n, className: e, ...r }) : /* @__PURE__ */ o(qe, { className: b("image-icon", e), size: n, ...r, children: /* @__PURE__ */ o(
990
+ function qe({ icon: t, className: e = "", size: n = "1rem", imageMeta: i, ...r }) {
991
+ const a = j(N(t), 540), [c, s] = T(!1), l = St();
992
+ return c ? /* @__PURE__ */ o(Ke, { icon: "i-mdi:image", color: l.palette.grey[500], size: n, className: e, ...r }) : /* @__PURE__ */ o(Qe, { className: b("image-icon", e), size: n, ...r, children: /* @__PURE__ */ o(
968
993
  "img",
969
994
  {
970
995
  className: "image-icon__image",
@@ -977,7 +1002,7 @@ function Ke({ icon: t, className: e = "", size: n = "1rem", imageMeta: i, ...r }
977
1002
  }
978
1003
  ) });
979
1004
  }
980
- const qe = _(x)`
1005
+ const Qe = _(g)`
981
1006
  display: inline-block;
982
1007
  width: ${({ size: t }) => t};
983
1008
  height: ${({ size: t }) => t};
@@ -989,22 +1014,22 @@ const qe = _(x)`
989
1014
  `, at = (t) => typeof t == "string" && /^[\w-_]+:[\w-_]+$/.test(t);
990
1015
  function et({ icon: t, size: e = "1rem", imageMeta: n, ...i }) {
991
1016
  const r = window.isNaN(e) ? e : `${e}px`;
992
- return at(t) ? /* @__PURE__ */ o(Pt, { icon: t }) : /* @__PURE__ */ o(Qe, { component: Ke, imageMeta: n, className: "base-icon", icon: t, size: r, ...i });
1017
+ return at(t) ? /* @__PURE__ */ o(Pt, { icon: t }) : /* @__PURE__ */ o(Ze, { component: qe, imageMeta: n, className: "base-icon", icon: t, size: r, ...i });
993
1018
  }
994
- const Qe = _(x)`
1019
+ const Ze = _(g)`
995
1020
  flex-shrink: 0;
996
1021
  `;
997
1022
  function L({ text: t, children: e, icon: n = "", endIcon: i, color: r = "primary", link: a = "", href: c = "", ...s }) {
998
- const l = n ? /* @__PURE__ */ o(et, { icon: n }) : null, d = i ? /* @__PURE__ */ o(et, { icon: i }) : null, m = a || c, p = { ...s };
999
- return m && (p.href = m, Z(m) && (p.target = p.target || "_blank")), /* @__PURE__ */ o(de, { startIcon: l, endIcon: d, color: r, ...p, children: t || e });
1023
+ const l = n ? /* @__PURE__ */ o(et, { icon: n }) : null, d = i ? /* @__PURE__ */ o(et, { icon: i }) : null, m = a || c, u = { ...s };
1024
+ return m && (u.href = m, Z(m) && (u.target = u.target || "_blank")), /* @__PURE__ */ o(me, { startIcon: l, endIcon: d, color: r, ...u, children: t || e });
1000
1025
  }
1001
- function Et({ editing: t, text: e, ...n }) {
1002
- const { pages: i = [] } = Lt(), r = i.find((a) => a.id === (n.link || n.linkId));
1026
+ function Ot({ editing: t, text: e, ...n }) {
1027
+ const { pages: i = [] } = Et(), r = i.find((a) => a.id === (n.link || n.linkId));
1003
1028
  if (t)
1004
1029
  return /* @__PURE__ */ o(L, { ...C(n, ["link", "linkId"]), children: e });
1005
1030
  if (r) {
1006
1031
  const a = r.path || "/";
1007
- return /* @__PURE__ */ o(se, { to: a, children: /* @__PURE__ */ o(L, { ...C(n, ["link", "linkId"]), children: e }) });
1032
+ return /* @__PURE__ */ o(le, { to: a, children: /* @__PURE__ */ o(L, { ...C(n, ["link", "linkId"]), children: e }) });
1008
1033
  }
1009
1034
  return /* @__PURE__ */ o(L, { ...C(n, "linkId"), children: e });
1010
1035
  }
@@ -1019,7 +1044,7 @@ W.defaultProps = {
1019
1044
  color: "inherit",
1020
1045
  className: ""
1021
1046
  };
1022
- function Ze({
1047
+ function to({
1023
1048
  to: t,
1024
1049
  base: e,
1025
1050
  children: n,
@@ -1030,15 +1055,15 @@ function Ze({
1030
1055
  useRouterLink: s,
1031
1056
  ...l
1032
1057
  }) {
1033
- const { pages: d = [], locale: m = "" } = {}, p = e ? Y("/", e) : e || "";
1034
- let h = a === "auto" ? "_self" : a, u = Y(p, t);
1035
- const f = c ? Z(u) : !1;
1058
+ const { pages: d = [], locale: m = "" } = {}, u = e ? M("/", e) : e || "";
1059
+ let h = a === "auto" ? "_self" : a, p = M(u, t);
1060
+ const x = c ? Z(p) : !1;
1036
1061
  if (e)
1037
- return u = Y(p, m, t), /* @__PURE__ */ o(
1062
+ return p = M(u, m, t), /* @__PURE__ */ o(
1038
1063
  "a",
1039
1064
  {
1040
1065
  className: `no-underline ${i}`,
1041
- href: K(u),
1066
+ href: X(p),
1042
1067
  rel: "noreferrer noopener",
1043
1068
  target: h,
1044
1069
  ...l,
@@ -1046,16 +1071,16 @@ function Ze({
1046
1071
  }
1047
1072
  );
1048
1073
  if (Z(t))
1049
- a === "auto" && (h = "_blank"), u = t;
1074
+ a === "auto" && (h = "_blank"), p = t;
1050
1075
  else {
1051
- me(u) && (u = Y(window.location.pathname, u));
1052
- const y = pe(`${window.location.origin}${u}`), g = d.some((v) => v.pathname === y.pathname);
1053
- if (s || g)
1076
+ ue(p) && (p = M(window.location.pathname, p));
1077
+ const y = pe(`${window.location.origin}${p}`), f = d.some((v) => v.pathname === y.pathname);
1078
+ if (s || f)
1054
1079
  return /* @__PURE__ */ o(
1055
- le,
1080
+ ce,
1056
1081
  {
1057
1082
  end: !0,
1058
- to: K(u),
1083
+ to: X(p),
1059
1084
  className: ({ isActive: v }) => b(i, v ? r : ""),
1060
1085
  ...l,
1061
1086
  children: n
@@ -1066,18 +1091,18 @@ function Ze({
1066
1091
  "a",
1067
1092
  {
1068
1093
  className: `no-underline ${i}`,
1069
- href: K(u),
1094
+ href: X(p),
1070
1095
  rel: "noreferrer noopener",
1071
1096
  target: h,
1072
1097
  ...l,
1073
1098
  children: [
1074
1099
  n,
1075
- f && /* @__PURE__ */ o(W, { icon: "i-mdi:arrow-top-right", size: "0.9em", className: "smart-link__mark", style: { marginLeft: 5 } })
1100
+ x && /* @__PURE__ */ o(W, { icon: "i-mdi:arrow-top-right", size: "0.9em", className: "smart-link__mark", style: { marginLeft: 5 } })
1076
1101
  ]
1077
1102
  }
1078
1103
  );
1079
1104
  }
1080
- function V({
1105
+ function H({
1081
1106
  prepend: t,
1082
1107
  append: e,
1083
1108
  children: n,
@@ -1087,13 +1112,13 @@ function V({
1087
1112
  ...c
1088
1113
  }) {
1089
1114
  let s = {};
1090
- const { pages: l = [] } = Lt(), d = l.find((h) => h.id === c.link), m = !n || wt.Children.toArray(n).every((h) => h === null);
1115
+ const { pages: l = [] } = Et(), d = l.find((h) => h.id === c.link), m = !n || wt.Children.toArray(n).every((h) => h === null);
1091
1116
  return c.link && (s = {
1092
- component: Ze,
1117
+ component: to,
1093
1118
  to: (d == null ? void 0 : d.path) || c.link,
1094
1119
  useRouterLink: !0
1095
1120
  }), /* @__PURE__ */ w(
1096
- to,
1121
+ eo,
1097
1122
  {
1098
1123
  className: b(
1099
1124
  "base-card card",
@@ -1112,7 +1137,7 @@ function V({
1112
1137
  }
1113
1138
  );
1114
1139
  }
1115
- const to = _(x)`
1140
+ const eo = _(g)`
1116
1141
  &.base-card {
1117
1142
  text-align: left;
1118
1143
  border-width: 1px;
@@ -1128,7 +1153,7 @@ const to = _(x)`
1128
1153
  padding: 15px 15px;
1129
1154
  }
1130
1155
  `;
1131
- function U({
1156
+ function D({
1132
1157
  align: t = "left",
1133
1158
  title: e,
1134
1159
  titleProps: n = {},
@@ -1162,7 +1187,7 @@ function U({
1162
1187
  )
1163
1188
  ] });
1164
1189
  }
1165
- function eo({
1190
+ function oo({
1166
1191
  image: t,
1167
1192
  title: e,
1168
1193
  description: n,
@@ -1175,14 +1200,14 @@ function eo({
1175
1200
  align: d,
1176
1201
  ...m
1177
1202
  }) {
1178
- const p = at(t), h = z(S(t), 540);
1203
+ const u = at(t), h = j(N(t), 540);
1179
1204
  return /* @__PURE__ */ w(
1180
- oo,
1205
+ no,
1181
1206
  {
1182
1207
  className: "card-article",
1183
1208
  ...m,
1184
- prepend: /* @__PURE__ */ o("div", { className: "card__image__wrap", children: p && t ? /* @__PURE__ */ o(
1185
- x,
1209
+ prepend: /* @__PURE__ */ o("div", { className: "card__image__wrap", children: u && t ? /* @__PURE__ */ o(
1210
+ g,
1186
1211
  {
1187
1212
  sx: {
1188
1213
  position: "absolute",
@@ -1211,7 +1236,7 @@ function eo({
1211
1236
  ) }),
1212
1237
  children: [
1213
1238
  e || n ? /* @__PURE__ */ o(
1214
- U,
1239
+ D,
1215
1240
  {
1216
1241
  align: d,
1217
1242
  title: e,
@@ -1220,12 +1245,12 @@ function eo({
1220
1245
  descriptionProps: s
1221
1246
  }
1222
1247
  ) : null,
1223
- l != null && l.length ? /* @__PURE__ */ o(T, { align: d, actions: l, className: "mt-4" }) : null
1248
+ l != null && l.length ? /* @__PURE__ */ o(z, { align: d, actions: l, className: "mt-4" }) : null
1224
1249
  ]
1225
1250
  }
1226
1251
  );
1227
1252
  }
1228
- const oo = _(V)`
1253
+ const no = _(H)`
1229
1254
  ${(t) => t.hoverStyle === "none" ? "" : t.link ? `transition: box-shadow ease .3s;
1230
1255
  &:hover {
1231
1256
  box-shadow: 0 0 10px rgba(95, 142, 244, 0.42);
@@ -1246,7 +1271,7 @@ const oo = _(V)`
1246
1271
  height: 100%;
1247
1272
  object-position: top center;
1248
1273
  }
1249
- `, ut = "section";
1274
+ `, pt = "section";
1250
1275
  function ht({
1251
1276
  title: t,
1252
1277
  image: e,
@@ -1258,7 +1283,7 @@ function ht({
1258
1283
  className: s = "",
1259
1284
  ...l
1260
1285
  }) {
1261
- return /* @__PURE__ */ w(no, { className: b("card", `list-type-${c}`, s), align: a, ...l, children: [
1286
+ return /* @__PURE__ */ w(ro, { className: b("card", `list-type-${c}`, s), align: a, ...l, children: [
1262
1287
  e && /* @__PURE__ */ o(
1263
1288
  W,
1264
1289
  {
@@ -1268,18 +1293,18 @@ function ht({
1268
1293
  imageMeta: n
1269
1294
  }
1270
1295
  ),
1271
- t || i ? /* @__PURE__ */ o(U, { align: a, title: t, description: i }) : null,
1272
- r != null && r.length ? /* @__PURE__ */ o(T, { align: a, actions: r, className: "mt-4" }) : null
1296
+ t || i ? /* @__PURE__ */ o(D, { align: a, title: t, description: i }) : null,
1297
+ r != null && r.length ? /* @__PURE__ */ o(z, { align: a, actions: r, className: "mt-4" }) : null
1273
1298
  ] });
1274
1299
  }
1275
- const no = _(V)`
1300
+ const ro = _(H)`
1276
1301
  padding: 5vw 4vw;
1277
1302
  box-sizing: border-box;
1278
1303
  /* min-height: 320px; */
1279
1304
  color: inherit !important;
1280
1305
  border-radius: 0.5rem;
1281
1306
  /* ${({ dark: t, theme: e }) => `background-color:${t ? e.palette.grey[900] : e.palette.common.white};`} */
1282
- @media (max-width: ${({ theme: t }) => t.breakpoints.values[ut]}px) {
1307
+ @media (max-width: ${({ theme: t }) => t.breakpoints.values[pt]}px) {
1283
1308
  padding: 1.5rem 2rem;
1284
1309
  }
1285
1310
  @media (max-width: ${({ theme: t }) => t.breakpoints.values.sm}px) {
@@ -1324,13 +1349,13 @@ const no = _(V)`
1324
1349
  }
1325
1350
  }
1326
1351
 
1327
- @media (min-width: ${({ theme: t }) => t.breakpoints.values[ut]}px) {
1352
+ @media (min-width: ${({ theme: t }) => t.breakpoints.values[pt]}px) {
1328
1353
  padding: 2rem 2rem;
1329
1354
  text-align: left;
1330
1355
  box-sizing: border-box;
1331
1356
  }
1332
1357
  `;
1333
- function ro({
1358
+ function io({
1334
1359
  image: t,
1335
1360
  title: e,
1336
1361
  description: n,
@@ -1343,14 +1368,14 @@ function ro({
1343
1368
  align: d,
1344
1369
  ...m
1345
1370
  }) {
1346
- const p = at(t), h = z(S(t), 540);
1371
+ const u = at(t), h = j(N(t), 540);
1347
1372
  return /* @__PURE__ */ w(
1348
- io,
1373
+ ao,
1349
1374
  {
1350
1375
  className: "card-article",
1351
1376
  ...m,
1352
- prepend: /* @__PURE__ */ o("div", { className: "card__image__wrap", children: p && t ? /* @__PURE__ */ o(
1353
- x,
1377
+ prepend: /* @__PURE__ */ o("div", { className: "card__image__wrap", children: u && t ? /* @__PURE__ */ o(
1378
+ g,
1354
1379
  {
1355
1380
  sx: {
1356
1381
  position: "absolute",
@@ -1365,7 +1390,7 @@ function ro({
1365
1390
  children: /* @__PURE__ */ o(W, { icon: t, color: "primary.main" })
1366
1391
  }
1367
1392
  ) : h && /* @__PURE__ */ o(
1368
- x,
1393
+ g,
1369
1394
  {
1370
1395
  component: "img",
1371
1396
  className: "card__image",
@@ -1380,7 +1405,7 @@ function ro({
1380
1405
  ) }),
1381
1406
  children: [
1382
1407
  e || n ? /* @__PURE__ */ o(
1383
- U,
1408
+ D,
1384
1409
  {
1385
1410
  align: d,
1386
1411
  title: e,
@@ -1389,12 +1414,12 @@ function ro({
1389
1414
  descriptionProps: s
1390
1415
  }
1391
1416
  ) : null,
1392
- l != null && l.length ? /* @__PURE__ */ o(T, { align: d, actions: l, className: "mt-4" }) : null
1417
+ l != null && l.length ? /* @__PURE__ */ o(z, { align: d, actions: l, className: "mt-4" }) : null
1393
1418
  ]
1394
1419
  }
1395
1420
  );
1396
1421
  }
1397
- const io = _(V)`
1422
+ const ao = _(H)`
1398
1423
  ${(t) => t.hoverStyle === "none" ? "" : t.link ? `transition: box-shadow ease .3s;
1399
1424
  &:hover {
1400
1425
  box-shadow: 0 0 10px rgba(95, 142, 244, 0.42);
@@ -1419,7 +1444,7 @@ const io = _(V)`
1419
1444
  max-height: 60px;
1420
1445
  }
1421
1446
  `, ft = "section";
1422
- function ao({
1447
+ function so({
1423
1448
  title: t,
1424
1449
  image: e,
1425
1450
  imageMeta: n,
@@ -1430,15 +1455,15 @@ function ao({
1430
1455
  className: s = "",
1431
1456
  ...l
1432
1457
  }) {
1433
- return /* @__PURE__ */ o(so, { className: b("card", s), ...l, children: /* @__PURE__ */ w(x, { className: "flex items-center", children: [
1458
+ return /* @__PURE__ */ o(lo, { className: b("card", s), ...l, children: /* @__PURE__ */ w(g, { className: "flex items-center", children: [
1434
1459
  e && /* @__PURE__ */ o(W, { icon: e, color: "primary.main", size: i, imageMeta: n }),
1435
- /* @__PURE__ */ w(x, { className: "flex-1 ml-4", children: [
1436
- /* @__PURE__ */ o(U, { align: c, title: t, description: r }),
1437
- /* @__PURE__ */ o(T, { align: c, actions: a, className: "mt-4" })
1460
+ /* @__PURE__ */ w(g, { className: "flex-1 ml-4", children: [
1461
+ /* @__PURE__ */ o(D, { align: c, title: t, description: r }),
1462
+ /* @__PURE__ */ o(z, { align: c, actions: a, className: "mt-4" })
1438
1463
  ] })
1439
1464
  ] }) });
1440
1465
  }
1441
- const so = _(V)`
1466
+ const lo = _(H)`
1442
1467
  padding: 5vw 4vw;
1443
1468
  text-align: left;
1444
1469
  box-sizing: border-box;
@@ -1495,7 +1520,7 @@ const so = _(V)`
1495
1520
  box-sizing: border-box;
1496
1521
  }
1497
1522
  `;
1498
- function lo({
1523
+ function co({
1499
1524
  title: t,
1500
1525
  titleProps: e = {},
1501
1526
  description: n,
@@ -1507,10 +1532,10 @@ function lo({
1507
1532
  hoverStyle: l,
1508
1533
  ...d
1509
1534
  }) {
1510
- return /* @__PURE__ */ w(co, { className: b("card-simple", c, `hover-style__${l}`), align: s, ...d, children: [
1535
+ return /* @__PURE__ */ w(mo, { className: b("card-simple", c, `hover-style__${l}`), align: s, ...d, children: [
1511
1536
  r && /* @__PURE__ */ o(W, { icon: r, color: "primary.main", imageMeta: a }),
1512
1537
  t || n ? /* @__PURE__ */ o(
1513
- U,
1538
+ D,
1514
1539
  {
1515
1540
  align: s,
1516
1541
  title: t,
@@ -1521,7 +1546,7 @@ function lo({
1521
1546
  ) : null
1522
1547
  ] });
1523
1548
  }
1524
- const co = _(V)`
1549
+ const mo = _(H)`
1525
1550
  ${({ dark: t, theme: e }) => `background-color:${t ? e.palette.grey[900] : e.palette.common.white};`}
1526
1551
 
1527
1552
  &.hover-style__default {
@@ -1607,13 +1632,13 @@ const co = _(V)`
1607
1632
  }
1608
1633
  }
1609
1634
  `;
1610
- function mo({ type: t = "default", ...e }) {
1635
+ function uo({ type: t = "default", ...e }) {
1611
1636
  const i = {
1612
- article: eo,
1613
- simple: lo,
1614
- news: ao,
1637
+ article: oo,
1638
+ simple: co,
1639
+ news: so,
1615
1640
  default: ht,
1616
- wall: ro
1641
+ wall: io
1617
1642
  }[t] || ht;
1618
1643
  return /* @__PURE__ */ o(i, { ...t === "news" ? e : C(e, "iconSize") });
1619
1644
  }
@@ -1629,9 +1654,9 @@ function po({
1629
1654
  className: l = "",
1630
1655
  type: d = "default",
1631
1656
  dark: m = !1,
1632
- textAlign: p = "left",
1657
+ textAlign: u = "left",
1633
1658
  hoverStyle: h,
1634
- ...u
1659
+ ...p
1635
1660
  }) {
1636
1661
  return /* @__PURE__ */ o(
1637
1662
  it,
@@ -1641,17 +1666,17 @@ function po({
1641
1666
  col: a,
1642
1667
  gap: c,
1643
1668
  align: e,
1644
- ...u,
1645
- children: n || t.map((f) => /* @__PURE__ */ o(
1646
- mo,
1669
+ ...p,
1670
+ children: n || t.map((x) => /* @__PURE__ */ o(
1671
+ uo,
1647
1672
  {
1648
1673
  borderColor: i,
1649
1674
  iconColor: s,
1650
1675
  type: d,
1651
1676
  listType: r,
1652
1677
  dark: m,
1653
- ...f,
1654
- align: p,
1678
+ ...x,
1679
+ align: u,
1655
1680
  sx: {
1656
1681
  bgcolor: d === "wall" ? void 0 : m ? "grey.900" : "common.white"
1657
1682
  },
@@ -1661,12 +1686,12 @@ function po({
1661
1686
  marginBottom: "-1px"
1662
1687
  } : {}
1663
1688
  },
1664
- f.id
1689
+ x.id
1665
1690
  ))
1666
1691
  }
1667
1692
  );
1668
1693
  }
1669
- const uo = [
1694
+ const ho = [
1670
1695
  "align",
1671
1696
  "cards",
1672
1697
  "list",
@@ -1677,7 +1702,7 @@ const uo = [
1677
1702
  "iconColor",
1678
1703
  "type",
1679
1704
  "textAlign"
1680
- ], ho = _(H)`
1705
+ ], fo = _(V)`
1681
1706
  a .card {
1682
1707
  color: #404040;
1683
1708
  cursor: pointer;
@@ -1693,14 +1718,14 @@ const uo = [
1693
1718
  color: #404040;
1694
1719
  }
1695
1720
  `;
1696
- function fo({ className: t, ...e }) {
1697
- const [n, i] = $(e, A), [r, a] = $(i, uo);
1698
- return /* @__PURE__ */ w(ho, { className: b("section--card-list", t), type: e.type, ...a, children: [
1699
- Object.keys(n).length > 0 && /* @__PURE__ */ o(F, { center: !0, ...n, className: "mb-[2.5vw]" }),
1721
+ function go({ className: t, ...e }) {
1722
+ const [n, i] = $(e, F), [r, a] = $(i, ho);
1723
+ return /* @__PURE__ */ w(fo, { className: b("section--card-list", t), type: e.type, ...a, children: [
1724
+ Object.keys(n).length > 0 && /* @__PURE__ */ o(A, { center: !0, ...n, className: "mb-[2.5vw]" }),
1700
1725
  /* @__PURE__ */ o(po, { ...r, dark: !!e.dark })
1701
1726
  ] });
1702
1727
  }
1703
- const go = _(fo)`
1728
+ const xo = _(go)`
1704
1729
  .card__description {
1705
1730
  white-space: pre-wrap;
1706
1731
  }
@@ -1716,8 +1741,8 @@ const go = _(fo)`
1716
1741
  background: inherit !important;
1717
1742
  }
1718
1743
  `;
1719
- function xo({ section: t, ...e }) {
1720
- const [{ editing: n }, i] = $(e, D), r = R(() => {
1744
+ function bo({ section: t, ...e }) {
1745
+ const [{ editing: n }, i] = $(e, U), r = R(() => {
1721
1746
  var a;
1722
1747
  return {
1723
1748
  ...C(i, ["listBorder", "list", "iconSize", "imageSize"]),
@@ -1726,7 +1751,7 @@ function xo({ section: t, ...e }) {
1726
1751
  return {
1727
1752
  ...C(c, "icon", "iconColor"),
1728
1753
  image: ["news", "simple", "default"].includes(i.type) && c.icon ? c.icon : c.image,
1729
- actions: (l = (s = c.actions) == null ? void 0 : s.map) == null ? void 0 : l.call(s, (d) => /* @__PURE__ */ o(Et, { ...d, editing: n }, d.id)),
1754
+ actions: (l = (s = c.actions) == null ? void 0 : s.map) == null ? void 0 : l.call(s, (d) => /* @__PURE__ */ o(Ot, { ...d, editing: n }, d.id)),
1730
1755
  border: i.listBorder,
1731
1756
  iconSize: i.iconSize,
1732
1757
  imageSize: i.imageSize,
@@ -1735,9 +1760,9 @@ function xo({ section: t, ...e }) {
1735
1760
  })
1736
1761
  };
1737
1762
  }, [i]);
1738
- return /* @__PURE__ */ o(go, { style: n ? { pointerEvents: "none" } : {}, ...r });
1763
+ return /* @__PURE__ */ o(xo, { style: n ? { pointerEvents: "none" } : {}, ...r });
1739
1764
  }
1740
- function bo({
1765
+ function yo({
1741
1766
  properties: t,
1742
1767
  section: e,
1743
1768
  locale: n,
@@ -1745,7 +1770,7 @@ function bo({
1745
1770
  }) {
1746
1771
  var r;
1747
1772
  return (r = e == null ? void 0 : e.config) != null && r.componentId ? /* @__PURE__ */ o(
1748
- ne,
1773
+ re,
1749
1774
  {
1750
1775
  instanceId: e.id,
1751
1776
  componentId: e.config.componentId,
@@ -1756,9 +1781,9 @@ function bo({
1756
1781
  properties: t,
1757
1782
  dev: i
1758
1783
  }
1759
- ) : /* @__PURE__ */ o(x, { textAlign: "center", py: 2, children: /* @__PURE__ */ o(P, { variant: "caption", color: "text.secondary", children: "Please select component to render" }) });
1784
+ ) : /* @__PURE__ */ o(g, { textAlign: "center", py: 2, children: /* @__PURE__ */ o(P, { variant: "caption", color: "text.secondary", children: "Please select component to render" }) });
1760
1785
  }
1761
- function yo({
1786
+ function wo({
1762
1787
  src: t,
1763
1788
  dataId: e,
1764
1789
  isEdit: n = !1,
@@ -1767,7 +1792,7 @@ function yo({
1767
1792
  }
1768
1793
  }) {
1769
1794
  return /* @__PURE__ */ o(
1770
- ge,
1795
+ xe,
1771
1796
  {
1772
1797
  isEdit: n,
1773
1798
  embedId: e,
@@ -1779,12 +1804,12 @@ function yo({
1779
1804
  }
1780
1805
  );
1781
1806
  }
1782
- function wo({ dataId: t, src: e, actions: n, center: i, onLoad: r, ...a }) {
1783
- const [c, s] = $(a, A);
1784
- return /* @__PURE__ */ w(H, { ...s, children: [
1785
- Object.keys(c).length > 0 && /* @__PURE__ */ o(F, { center: i, ...c }),
1807
+ function vo({ dataId: t, src: e, actions: n, center: i, onLoad: r, ...a }) {
1808
+ const [c, s] = $(a, F);
1809
+ return /* @__PURE__ */ w(V, { ...s, children: [
1810
+ Object.keys(c).length > 0 && /* @__PURE__ */ o(A, { center: i, ...c }),
1786
1811
  /* @__PURE__ */ o(
1787
- yo,
1812
+ wo,
1788
1813
  {
1789
1814
  dataId: t,
1790
1815
  src: e,
@@ -1792,10 +1817,10 @@ function wo({ dataId: t, src: e, actions: n, center: i, onLoad: r, ...a }) {
1792
1817
  height: a.iframeHeight ? `${a.iframeHeight}px` : "100%"
1793
1818
  }
1794
1819
  ),
1795
- /* @__PURE__ */ o(T, { actions: n, center: i })
1820
+ /* @__PURE__ */ o(z, { actions: n, center: i })
1796
1821
  ] });
1797
1822
  }
1798
- const kn = {
1823
+ const _n = {
1799
1824
  src: "",
1800
1825
  embedUrl: "",
1801
1826
  title: "",
@@ -1806,21 +1831,21 @@ const kn = {
1806
1831
  config: {},
1807
1832
  id: ""
1808
1833
  };
1809
- function vo({ section: t, id: e, src: n, ...i }) {
1810
- const r = `${e}-${i.locale}`, [{ editing: a }, c] = $(i, D), s = G({}), l = JSON.parse(JSON.stringify(c)), { message: d } = ue(r, "server"), m = he(JSON.parse(JSON.stringify(c.config) || "{}"));
1834
+ function ko({ section: t, id: e, src: n, ...i }) {
1835
+ const r = `${e}-${i.locale}`, [{ editing: a }, c] = $(i, U), s = G({}), l = JSON.parse(JSON.stringify(c)), { message: d } = he(r, "server"), m = fe(JSON.parse(JSON.stringify(c.config) || "{}"));
1811
1836
  return O(() => {
1812
1837
  d && d.onInit(() => m.current);
1813
1838
  }, [d]), O(() => {
1814
- const p = JSON.parse(JSON.stringify(c.config) || "{}");
1815
- fe(s.current, p) || (s.current = p, d == null || d.send("config-set", p));
1816
- }, [d, c.config]), n ? /* @__PURE__ */ o(wo, { ...l, dataId: r, src: n, style: a ? { pointerEvents: "none" } : {} }) : /* @__PURE__ */ o(ko, { children: 'Please set the "src" attribute for this block' });
1839
+ const u = JSON.parse(JSON.stringify(c.config) || "{}");
1840
+ ge(s.current, u) || (s.current = u, d == null || d.send("config-set", u));
1841
+ }, [d, c.config]), n ? /* @__PURE__ */ o(vo, { ...l, dataId: r, src: n, style: a ? { pointerEvents: "none" } : {} }) : /* @__PURE__ */ o(_o, { children: 'Please set the "src" attribute for this block' });
1817
1842
  }
1818
- const ko = _("div")`
1843
+ const _o = _("div")`
1819
1844
  user-select: none;
1820
1845
  color: #999;
1821
1846
  padding: 8px;
1822
1847
  height: 200px;
1823
- `, _o = [
1848
+ `, $o = [
1824
1849
  /youtu\.be\/([^#&?]{11})/,
1825
1850
  // youtu.be/<id>
1826
1851
  /\?v=([^#&?]{11})/,
@@ -1832,30 +1857,30 @@ const ko = _("div")`
1832
1857
  /\/v\/([^#&?]{11})/
1833
1858
  // /v/<id>
1834
1859
  ];
1835
- function $o(t) {
1860
+ function So(t) {
1836
1861
  var e;
1837
1862
  if (/youtu\.?be/.test(t))
1838
- for (const n of _o) {
1863
+ for (const n of $o) {
1839
1864
  const i = (e = n.exec(t)) == null ? void 0 : e[1];
1840
1865
  if (i)
1841
1866
  return i;
1842
1867
  }
1843
1868
  }
1844
1869
  function No(t) {
1845
- const e = $o(t);
1870
+ const e = So(t);
1846
1871
  if (e)
1847
1872
  return `https://youtube.com/embed/${e}`;
1848
1873
  }
1849
- function So({ src: t }) {
1874
+ function Co({ src: t }) {
1850
1875
  return O(() => {
1851
1876
  import("@lottiefiles/lottie-player");
1852
1877
  }, []), /* @__PURE__ */ o("lottie-player", { autoplay: !0, loop: !0, mode: "normal", src: t });
1853
1878
  }
1854
- function Co(t) {
1855
- return /* @__PURE__ */ o(x, { maxHeight: 400, overflow: "hidden auto", children: /* @__PURE__ */ o(xe, { ...t }) });
1879
+ function Po(t) {
1880
+ return /* @__PURE__ */ o(g, { maxHeight: 400, overflow: "hidden auto", children: /* @__PURE__ */ o(be, { ...t }) });
1856
1881
  }
1857
- function Po({ url: t }) {
1858
- const e = G(null), n = 495, [i, r] = j(
1882
+ function Bo({ url: t }) {
1883
+ const e = G(null), n = 495, [i, r] = T(
1859
1884
  e.current ? e.current.offsetWidth * 0.5625 : n
1860
1885
  ), a = E(() => {
1861
1886
  const c = window.innerWidth > 990 ? 1 : window.innerWidth > 522 ? 1.2 : window.innerWidth > 400 ? 1.45 : 1.85, s = e.current ? e.current.offsetWidth * 0.5625 : n;
@@ -1868,7 +1893,7 @@ function Po({ url: t }) {
1868
1893
  window.removeEventListener("resize", a);
1869
1894
  };
1870
1895
  }, [i, a]), /* @__PURE__ */ o(
1871
- x,
1896
+ g,
1872
1897
  {
1873
1898
  component: "iframe",
1874
1899
  ref: e,
@@ -1883,7 +1908,7 @@ function Po({ url: t }) {
1883
1908
  }
1884
1909
  );
1885
1910
  }
1886
- const _n = {
1911
+ const $n = {
1887
1912
  image: "https://www.arcblock.io/static/ead0cabde7f2b7ff34db8f3e8ceca271/afc4b/builder.png",
1888
1913
  badge: "Develop · Deploy · Run",
1889
1914
  title: "The Future is Here: Blockchain and Decentralized Application Development",
@@ -1894,11 +1919,11 @@ const _n = {
1894
1919
  actions: void 0,
1895
1920
  hasImage: !0,
1896
1921
  center: !1
1897
- }, Bo = _(Ue)`
1922
+ }, Io = _(Me)`
1898
1923
  .section__description {
1899
1924
  }
1900
1925
  `;
1901
- function Io({
1926
+ function Wo({
1902
1927
  hasImage: t,
1903
1928
  fullSizeImage: e,
1904
1929
  boxed: n,
@@ -1909,31 +1934,31 @@ function Io({
1909
1934
  section: s,
1910
1935
  ...l
1911
1936
  }) {
1912
- var u, f;
1913
- const [{ editing: d }, m] = $({ ...l, boxed: e ? void 0 : n }, D);
1914
- let p = Wo(m.image, i, e, r, a, c);
1915
- t || (p = null);
1937
+ var p, x;
1938
+ const [{ editing: d }, m] = $({ ...l, boxed: e ? void 0 : n }, U);
1939
+ let u = Ro(m.image, i, e, r, a, c);
1940
+ t || (u = null);
1916
1941
  let h = null;
1917
- return m.actions && (h = (f = (u = m.actions) == null ? void 0 : u.map) == null ? void 0 : f.call(u, (y, g) => /* @__PURE__ */ o(Et, { ...y, editing: d }, g))), /* @__PURE__ */ o(
1918
- Bo,
1942
+ return m.actions && (h = (x = (p = m.actions) == null ? void 0 : p.map) == null ? void 0 : x.call(p, (y, f) => /* @__PURE__ */ o(Ot, { ...y, editing: d }, f))), /* @__PURE__ */ o(
1943
+ Io,
1919
1944
  {
1920
1945
  ...m,
1921
1946
  style: d ? { pointerEvents: "none" } : {},
1922
- image: p,
1947
+ image: u,
1923
1948
  fullSizeImage: t && e,
1924
1949
  actions: h
1925
1950
  }
1926
1951
  );
1927
1952
  }
1928
- function Wo(t, e, n, i, r, a) {
1953
+ function Ro(t, e, n, i, r, a) {
1929
1954
  if (t) {
1930
1955
  if (t.endsWith(".json"))
1931
- return /* @__PURE__ */ o(So, { src: t });
1956
+ return /* @__PURE__ */ o(Co, { src: t });
1932
1957
  if (t.indexOf("twitter.com") !== -1)
1933
- return /* @__PURE__ */ o(Co, { sourceType: "url", url: t });
1958
+ return /* @__PURE__ */ o(Po, { sourceType: "url", url: t });
1934
1959
  const c = No(t);
1935
1960
  if (c)
1936
- return /* @__PURE__ */ o(Po, { url: c });
1961
+ return /* @__PURE__ */ o(Bo, { url: c });
1937
1962
  const { naturalWidth: s, naturalHeight: l, filename: d } = i || {};
1938
1963
  if (tt(t))
1939
1964
  return /* @__PURE__ */ o(
@@ -1951,16 +1976,16 @@ function Wo(t, e, n, i, r, a) {
1951
1976
  width: "100%",
1952
1977
  height: "100%"
1953
1978
  },
1954
- poster: z(S(e), n ? 1200 : 540, r),
1955
- children: /* @__PURE__ */ o("source", { src: S(t), type: Fe(t) })
1979
+ poster: j(N(e), n ? 1200 : 540, r),
1980
+ children: /* @__PURE__ */ o("source", { src: N(t), type: Fe(t) })
1956
1981
  },
1957
1982
  t
1958
1983
  );
1959
1984
  const m = r === "quality" ? 1 : 0.6;
1960
1985
  return /* @__PURE__ */ o(
1961
- St,
1986
+ Nt,
1962
1987
  {
1963
- src: S(t),
1988
+ src: N(t),
1964
1989
  sizesAttr: {
1965
1990
  sm: 600 * m,
1966
1991
  md: 450 * m,
@@ -1980,15 +2005,15 @@ function Wo(t, e, n, i, r, a) {
1980
2005
  }
1981
2006
  return null;
1982
2007
  }
1983
- const $n = ["production", "draft"];
2008
+ const Sn = ["production", "draft"];
1984
2009
  function Nn({ mode: t, version: e } = {}) {
1985
2010
  const n = e && typeof e == "number" ? { mode: t, version: e } : { mode: t };
1986
2011
  return ot.get(`/api/${nt()}/pages`, { params: n }).then((i) => i.data);
1987
2012
  }
1988
- function Sn({ mode: t, pages: e }) {
2013
+ function Cn({ mode: t, pages: e }) {
1989
2014
  return ot.post(`/api/${nt()}/pages/publish`, { mode: t, pages: e }).then((n) => n.data);
1990
2015
  }
1991
- function Ro({
2016
+ function To({
1992
2017
  locale: t,
1993
2018
  sort: e,
1994
2019
  page: n,
@@ -1997,55 +2022,55 @@ function Ro({
1997
2022
  } = {}) {
1998
2023
  return ot.get(`/api/${nt()}/pages/toc`, { params: { locale: t, sort: e, page: n, limit: i, mode: r } }).then((a) => a.data);
1999
2024
  }
2000
- const Cn = {
2025
+ const Pn = {
2001
2026
  style: "list",
2002
2027
  sort: "-updatedAt"
2003
2028
  }, gt = 20;
2004
2029
  function jo({ style: t, sort: e, section: n, ...i }) {
2005
- const [{ editing: r, locale: a }, c] = $(i, D), [s, l] = $(c, A), [d, m] = j(), p = G(!1), h = be(), u = ce(), f = E(async () => {
2006
- if (!p.current) {
2007
- p.current = !0, h();
2030
+ const [{ editing: r, locale: a }, c] = $(i, U), [s, l] = $(c, F), [d, m] = T(), u = G(!1), h = ye(), p = de(), x = E(async () => {
2031
+ if (!u.current) {
2032
+ u.current = !0, h();
2008
2033
  try {
2009
- const y = d ? Math.floor(d.list.length / gt) + 1 : 1, { list: g, total: v } = await Ro({ locale: a, sort: e, page: y, limit: gt });
2034
+ const y = d ? Math.floor(d.list.length / gt) + 1 : 1, { list: f, total: v } = await To({ locale: a, sort: e, page: y, limit: gt });
2010
2035
  m((k) => ({
2011
- list: ((k == null ? void 0 : k.list) ?? []).concat(g),
2036
+ list: ((k == null ? void 0 : k.list) ?? []).concat(f),
2012
2037
  total: v
2013
2038
  }));
2014
2039
  } finally {
2015
- p.current = !1, h();
2040
+ u.current = !1, h();
2016
2041
  }
2017
2042
  }
2018
2043
  }, [d, a, e, h]);
2019
- return ye(() => {
2020
- f();
2021
- }), /* @__PURE__ */ w(H, { ...l, sx: r ? { pointerEvents: "none" } : {}, children: [
2022
- Object.keys(s).length > 0 && /* @__PURE__ */ o(F, { ...s }),
2044
+ return we(() => {
2045
+ x();
2046
+ }), /* @__PURE__ */ w(V, { ...l, sx: r ? { pointerEvents: "none" } : {}, children: [
2047
+ Object.keys(s).length > 0 && /* @__PURE__ */ o(A, { ...s }),
2023
2048
  d ? /* @__PURE__ */ w(J, { children: [
2024
2049
  /* @__PURE__ */ o(lt, { container: !0, spacing: 2, justifyContent: "center", children: d == null ? void 0 : d.list.map((y) => /* @__PURE__ */ o(lt, { item: !0, xs: 12, sm: t === "card" ? 6 : 12, md: t === "card" ? 3 : 12, children: /* @__PURE__ */ w(
2025
2050
  zo,
2026
2051
  {
2027
2052
  elevation: 0,
2028
2053
  className: b(t === "card" && "style-card"),
2029
- onClick: r ? void 0 : () => u(y.slug),
2054
+ onClick: r ? void 0 : () => p(y.slug),
2030
2055
  children: [
2031
2056
  !!y.image && /* @__PURE__ */ o(
2032
- Mt,
2057
+ Jt,
2033
2058
  {
2034
2059
  component: "img",
2035
2060
  alt: "",
2036
- image: z(S(y.image), 540),
2061
+ image: j(N(y.image), 540),
2037
2062
  loading: "lazy"
2038
2063
  }
2039
2064
  ),
2040
- /* @__PURE__ */ w(Jt, { children: [
2065
+ /* @__PURE__ */ w(Gt, { children: [
2041
2066
  /* @__PURE__ */ o(P, { variant: "h6", component: "div", className: xt, children: y.title || y.id }),
2042
2067
  /* @__PURE__ */ o(P, { variant: "body2", className: xt, children: y.description })
2043
2068
  ] })
2044
2069
  ]
2045
2070
  }
2046
2071
  ) }, y.id)) }),
2047
- /* @__PURE__ */ o(x, { textAlign: "center", mt: 2, children: d.total > d.list.length ? /* @__PURE__ */ o(L, { variant: "outlined", color: "secondary", onClick: f, loading: p.current, children: "More" }) : /* @__PURE__ */ o(L, { variant: "outlined", color: "secondary", disabled: !0, children: "No More" }) })
2048
- ] }) : /* @__PURE__ */ o(x, { p: 2, textAlign: "center", children: /* @__PURE__ */ o(Yt, { size: 24 }) })
2072
+ /* @__PURE__ */ o(g, { textAlign: "center", mt: 2, children: d.total > d.list.length ? /* @__PURE__ */ o(L, { variant: "outlined", color: "secondary", onClick: x, loading: u.current, children: "More" }) : /* @__PURE__ */ o(L, { variant: "outlined", color: "secondary", disabled: !0, children: "No More" }) })
2073
+ ] }) : /* @__PURE__ */ o(g, { p: 2, textAlign: "center", children: /* @__PURE__ */ o(Yt, { size: 24 }) })
2049
2074
  ] });
2050
2075
  }
2051
2076
  const xt = q`
@@ -2054,7 +2079,7 @@ const xt = q`
2054
2079
  -webkit-line-clamp: 2;
2055
2080
  overflow: hidden;
2056
2081
  text-overflow: ellipsis;
2057
- `, zo = _(Ut)`
2082
+ `, zo = _(Mt)`
2058
2083
  border: 1px solid #e0e0e0;
2059
2084
  background-color: transparent;
2060
2085
  cursor: pointer;
@@ -2074,38 +2099,38 @@ const xt = q`
2074
2099
  max-height: 50vw;
2075
2100
  }
2076
2101
  }
2077
- `, To = {
2078
- iframe: vo,
2079
- section: Io,
2080
- "section-card-list": xo,
2102
+ `, Lo = {
2103
+ iframe: ko,
2104
+ section: Wo,
2105
+ "section-card-list": bo,
2081
2106
  toc: jo,
2082
- "ai-runtime": Je,
2083
- "custom-component": bo
2107
+ "ai-runtime": Ge,
2108
+ "custom-component": yo
2084
2109
  };
2085
- function Pn({ id: t, type: e, mode: n, config: i, section: r, ...a }) {
2086
- const c = To[e], { getPageMetaStyle: s } = Be(), l = R(() => {
2087
- const { height: p, ...h } = i;
2110
+ function Bn({ id: t, type: e, mode: n, config: i, section: r, ...a }) {
2111
+ const c = Lo[e], { getPageMetaStyle: s } = Ie(), l = R(() => {
2112
+ const { height: u, ...h } = i;
2088
2113
  return h;
2089
2114
  }, [i]), d = R(() => {
2090
- const p = {};
2091
- return e !== "custom-component" && (p.height = i.height), p.sx = s("sx"), p;
2115
+ const u = {};
2116
+ return e !== "custom-component" && (u.height = i.height), u.sx = s("sx"), u;
2092
2117
  }, [i.height, e, s]), m = c && /* @__PURE__ */ o(c, { mode: n, ...l, id: t, section: r });
2093
2118
  return /* @__PURE__ */ o(Ye, { ...a, ...d, children: m });
2094
2119
  }
2095
- function Bn(t) {
2120
+ function In(t) {
2096
2121
  return t != null;
2097
2122
  }
2098
2123
  export {
2099
- Et as A,
2100
- Pn as B,
2124
+ Ot as A,
2125
+ Bn as B,
2101
2126
  jt as I,
2102
- wn as P,
2103
- $n as S,
2104
- Cn as T,
2105
- yn as a,
2106
- kn as b,
2107
- _n as c,
2127
+ vn as P,
2128
+ Sn as S,
2129
+ Pn as T,
2130
+ wn as a,
2131
+ _n as b,
2132
+ $n as c,
2108
2133
  Nn as g,
2109
- Bn as n,
2110
- Sn as p
2134
+ In as n,
2135
+ Cn as p
2111
2136
  };