@builder.io/sdk-react 4.0.1 → 4.0.3

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 (72) hide show
  1. package/lib/browser/blocks-exports.cjs +40 -37
  2. package/lib/browser/blocks-exports.mjs +859 -842
  3. package/lib/browser/index.cjs +1 -1
  4. package/lib/browser/index.mjs +1 -1
  5. package/lib/browser/{server-entry-0e0758cb.cjs → server-entry-c40e781d.cjs} +2 -2
  6. package/lib/{node/server-entry-a017e97a.js → browser/server-entry-e6ae7704.js} +2 -2
  7. package/lib/browser/server-entry.cjs +1 -1
  8. package/lib/browser/server-entry.mjs +1 -1
  9. package/lib/edge/{accordion-02a74a7b.cjs → accordion-8934ef4b.cjs} +1 -1
  10. package/lib/edge/{accordion-46e5b47a.js → accordion-e657c96d.js} +1 -1
  11. package/lib/edge/{blocks-27f4c960.js → blocks-513223a7.js} +2 -2
  12. package/lib/edge/{blocks-43b7cd64.cjs → blocks-a6ffbf92.cjs} +1 -1
  13. package/lib/edge/blocks-exports.cjs +1 -1
  14. package/lib/edge/blocks-exports.mjs +2 -2
  15. package/lib/edge/{button-c26a8cc8.js → button-3522aac2.js} +2 -2
  16. package/lib/edge/{button-b1f2e20e.cjs → button-49563e3b.cjs} +1 -1
  17. package/lib/edge/{columns-5a3e9ac8.cjs → columns-092b6fac.cjs} +1 -1
  18. package/lib/edge/{columns-9a6cd1b4.js → columns-ea0b3b30.js} +3 -3
  19. package/lib/edge/{content-variants-3085ec74.js → content-variants-6c1e3b13.js} +316 -307
  20. package/lib/edge/content-variants-75ff40ca.cjs +137 -0
  21. package/lib/edge/custom-code-1a43bbd7.js +52 -0
  22. package/lib/edge/custom-code-ae3262be.cjs +1 -0
  23. package/lib/edge/embed-106f0066.js +38 -0
  24. package/lib/edge/embed-8d302933.cjs +1 -0
  25. package/lib/edge/{form-f2aa1c12.js → form-0c0d5bf5.js} +3 -3
  26. package/lib/edge/{form-bf3ca65d.cjs → form-46e4d997.cjs} +1 -1
  27. package/lib/edge/{get-class-prop-name-7cdcaf94.cjs → get-class-prop-name-dad1ee7e.cjs} +1 -1
  28. package/lib/edge/{get-class-prop-name-e41a3976.js → get-class-prop-name-e44df0c8.js} +1 -1
  29. package/lib/edge/{img-2a060e61.js → img-8bdeb666.js} +1 -1
  30. package/lib/edge/{img-2c718c5f.cjs → img-e49acb58.cjs} +1 -1
  31. package/lib/edge/index.cjs +1 -1
  32. package/lib/edge/index.mjs +1 -1
  33. package/lib/edge/{input-213f973c.cjs → input-92aaa4f2.cjs} +1 -1
  34. package/lib/edge/{input-f270ae3b.js → input-d6338de6.js} +1 -1
  35. package/lib/edge/{personalization-container-b85b14c3.js → personalization-container-1307218b.js} +4 -4
  36. package/lib/edge/{personalization-container-b03bc073.cjs → personalization-container-965bec51.cjs} +1 -1
  37. package/lib/edge/{select-e12e1a87.js → select-1538b41a.js} +1 -1
  38. package/lib/edge/{select-d6ff55b2.cjs → select-5ce728b4.cjs} +1 -1
  39. package/lib/edge/{server-entry-b94c45af.js → server-entry-2e94ad2c.js} +2 -1
  40. package/lib/edge/{server-entry-d0313f00.cjs → server-entry-46e686b9.cjs} +2 -2
  41. package/lib/edge/server-entry.cjs +1 -1
  42. package/lib/edge/server-entry.mjs +1 -1
  43. package/lib/edge/{slot-5ee0ac5d.cjs → slot-3b6aa7ec.cjs} +1 -1
  44. package/lib/edge/{slot-2670ac48.js → slot-516f176d.js} +3 -3
  45. package/lib/edge/{symbol-a0b2e083.js → symbol-3b2e7ebf.js} +2 -2
  46. package/lib/edge/{symbol-7e58faf5.cjs → symbol-cd10b6f0.cjs} +1 -1
  47. package/lib/edge/{tabs-1f475bd4.cjs → tabs-cec51291.cjs} +1 -1
  48. package/lib/edge/{tabs-931291c4.js → tabs-f0945019.js} +3 -3
  49. package/lib/node/blocks-exports.cjs +40 -37
  50. package/lib/node/blocks-exports.mjs +831 -814
  51. package/lib/node/index.cjs +1 -1
  52. package/lib/node/index.mjs +3 -3
  53. package/lib/node/init.cjs +1 -1
  54. package/lib/node/init.mjs +3 -3
  55. package/lib/node/{server-entry-24943b12.cjs → server-entry-6b05381c.cjs} +2 -2
  56. package/lib/{browser/server-entry-403d3877.js → node/server-entry-c1000f54.js} +3 -1
  57. package/lib/node/server-entry.cjs +1 -1
  58. package/lib/node/server-entry.mjs +1 -1
  59. package/lib/node/{setIvm-0a7e7bf0.js → setIvm-011d6eb2.js} +1 -1
  60. package/lib/node/{setIvm-dcd69a69.cjs → setIvm-4ae0308c.cjs} +1 -1
  61. package/lib/node/setIvm.cjs +1 -1
  62. package/lib/node/setIvm.mjs +2 -2
  63. package/lib/node/{should-force-browser-runtime-in-node-0ca8d8b1.cjs → should-force-browser-runtime-in-node-5d513614.cjs} +1 -1
  64. package/lib/node/{should-force-browser-runtime-in-node-c51ac820.js → should-force-browser-runtime-in-node-abf8d0a7.js} +1 -1
  65. package/package.json +1 -1
  66. package/types/components/content-variants/inlined-fns.d.ts +1 -1
  67. package/types/constants/sdk-version.d.ts +1 -1
  68. package/lib/edge/content-variants-eff73ca9.cjs +0 -134
  69. package/lib/edge/custom-code-7786788e.js +0 -43
  70. package/lib/edge/custom-code-8119ea3f.cjs +0 -1
  71. package/lib/edge/embed-32bdd007.cjs +0 -1
  72. package/lib/edge/embed-5c1bbe12.js +0 -37
@@ -1,9 +1,9 @@
1
- import { jsx as y, jsxs as $, Fragment as J } from "react/jsx-runtime";
2
- import { lazy as v, useRef as _, useState as I, useEffect as V } from "react";
3
- import { isBrowser as j, TARGET as O, isEditing as P, isPreviewing as ne, registerInsertMenu as se, setupBrowserForEditing as de, createRegisterComponentMessage as ue, getDefaultCanTrack as U, _track as Y, fetchOneEntry as ce, createEditorListener as me, logFetch as pe, serializeIncludingFunctions as G, logger as fe, handleABTestingSync as ge } from "./server-entry-b94c45af.js";
4
- import { Video as he, Button as be, Columns as ye, Fragment as xe, Image as ve, Section as Se, Symbol as Te, Text as Ie, BuilderContext as ke } from "./blocks-exports.mjs";
5
- import { triggerAnimation as Ce, evaluate as ae, fastClone as we, InlinedStyles as ie, ComponentsContext as Ve, Blocks as Re } from "./blocks-27f4c960.js";
6
- const H = {
1
+ import { jsx as h, jsxs as O, Fragment as Q } from "react/jsx-runtime";
2
+ import { lazy as y, useRef as M, useState as T, useEffect as E } from "react";
3
+ import { isBrowser as z, TARGET as N, isEditing as A, isPreviewing as oe, registerInsertMenu as ce, setupBrowserForEditing as me, createRegisterComponentMessage as pe, getDefaultCanTrack as L, getCookieSync as fe, _track as X, fetchOneEntry as ge, createEditorListener as he, logFetch as be, serializeIncludingFunctions as Z, logger as ye, handleABTestingSync as xe } from "./server-entry-2e94ad2c.js";
4
+ import { Video as ve, Button as Se, Columns as Te, Fragment as Ie, Image as ke, Section as Ce, Symbol as we, Text as Ve, BuilderContext as Re } from "./blocks-exports.mjs";
5
+ import { triggerAnimation as Ee, evaluate as re, fastClone as Fe, InlinedStyles as le, ComponentsContext as Pe, Blocks as Ae } from "./blocks-513223a7.js";
6
+ const $ = {
7
7
  "@type": "@builder.io/sdk:Element",
8
8
  layerName: "Accordion item title",
9
9
  responsiveStyles: {
@@ -32,7 +32,7 @@ const H = {
32
32
  }
33
33
  }
34
34
  }]
35
- }, L = {
35
+ }, _ = {
36
36
  "@type": "@builder.io/sdk:Element",
37
37
  layerName: "Accordion item detail",
38
38
  responsiveStyles: {
@@ -63,7 +63,7 @@ const H = {
63
63
  }
64
64
  }
65
65
  }]
66
- }, Ee = {
66
+ }, We = {
67
67
  name: "Builder:Accordion",
68
68
  canHaveChildren: !0,
69
69
  image: "https://cdn.builder.io/api/v1/image/assets%2FagZ9n5CUKRfbL9t6CaJOyVSK4Es2%2Ffab6c1fd3fe542408cbdec078bca7f35",
@@ -80,19 +80,19 @@ const H = {
80
80
  name: "title",
81
81
  type: "uiBlocks",
82
82
  hideFromUI: !0,
83
- defaultValue: [H]
83
+ defaultValue: [$]
84
84
  }, {
85
85
  name: "detail",
86
86
  type: "uiBlocks",
87
87
  hideFromUI: !0,
88
- defaultValue: [L]
88
+ defaultValue: [_]
89
89
  }],
90
90
  defaultValue: [{
91
- title: [H],
92
- detail: [L]
91
+ title: [$],
92
+ detail: [_]
93
93
  }, {
94
- title: [H],
95
- detail: [L]
94
+ title: [$],
95
+ detail: [_]
96
96
  }],
97
97
  showIf: (e) => !e.get("useChildrenForItems")
98
98
  }, {
@@ -127,7 +127,7 @@ const H = {
127
127
  builderComponents: !0,
128
128
  builderLinkComponent: !0
129
129
  }
130
- }, Fe = v(() => import("./accordion-46e5b47a.js")), Pe = {
130
+ }, Be = y(() => import("./accordion-e657c96d.js")), De = {
131
131
  name: "Core:Button",
132
132
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
133
133
  defaultStyles: {
@@ -163,7 +163,7 @@ const H = {
163
163
  shouldReceiveBuilderProps: {
164
164
  builderLinkComponent: !0
165
165
  }
166
- }, We = {
166
+ }, Ue = {
167
167
  // TODO: ways to statically preprocess JSON for references, functions, etc
168
168
  name: "Columns",
169
169
  isRSC: !0,
@@ -342,7 +342,7 @@ const H = {
342
342
  });
343
343
  }
344
344
  const n = e.get("columns");
345
- Array.isArray(n) && n.find((r) => r.get("width")) && (n.find((d) => !d.get("width")) || n.reduce((o, u) => o + u.get("width"), 0) !== 100) && t();
345
+ Array.isArray(n) && n.find((r) => r.get("width")) && (n.find((u) => !u.get("width")) || n.reduce((o, c) => o + c.get("width"), 0) !== 100) && t();
346
346
  }
347
347
  }, {
348
348
  name: "space",
@@ -370,13 +370,13 @@ const H = {
370
370
  builderComponents: !0,
371
371
  builderLinkComponent: !0
372
372
  }
373
- }, Ae = {
373
+ }, He = {
374
374
  name: "Fragment",
375
375
  static: !0,
376
376
  hidden: !0,
377
377
  canHaveChildren: !0,
378
378
  noWrap: !0
379
- }, M = ["jpeg", "jpg", "png", "svg", "webp", "gif", "jfif", "pjpeg", "pjp", "apng", "avif", "tif", "tiff", "heif", "bmp", "eps", "raw", "cr2", "nef", "orf", "sr2", "psd", "heic", "dib", "ai"], Be = ["mp4", "webm", "mkv", "flv", "vob", "ogv", "ogg", "drc", "gif", "gifv", "mng", "avi", "mov", "qt", "mts", "m2ts", "ts", "wmv", "yuv", "rm", "rmvb", "viv", "asf", "amv", "m4p", "mpeg", "mpe", "m2v", "m4v", "svi", "3gp", "3g2", "mxf", "roq", "nsv", "f4v", "f4p", "f4a", "f4b"], De = {
379
+ }, Y = ["jpeg", "jpg", "png", "svg", "webp", "gif", "jfif", "pjpeg", "pjp", "apng", "avif", "tif", "tiff", "heif", "bmp", "eps", "raw", "cr2", "nef", "orf", "sr2", "psd", "heic", "dib", "ai"], Le = ["mp4", "webm", "mkv", "flv", "vob", "ogv", "ogg", "drc", "gif", "gifv", "mng", "avi", "mov", "qt", "mts", "m2ts", "ts", "wmv", "yuv", "rm", "rmvb", "viv", "asf", "amv", "m4p", "mpeg", "mpe", "m2v", "m4v", "svi", "3gp", "3g2", "mxf", "roq", "nsv", "f4v", "f4p", "f4a", "f4b"], Ne = {
380
380
  name: "Image",
381
381
  static: !0,
382
382
  image: "https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-insert_photo-24px.svg?alt=media&token=4e5d0ef4-f5e8-4e57-b3a9-38d63a9b9dc4",
@@ -391,31 +391,31 @@ const H = {
391
391
  name: "image",
392
392
  type: "file",
393
393
  bubble: !0,
394
- allowedFileTypes: M,
394
+ allowedFileTypes: Y,
395
395
  required: !0,
396
396
  defaultValue: "https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",
397
397
  onChange: (e) => {
398
398
  e.delete("srcset"), e.delete("noWebp");
399
399
  function n(a, o = 6e4) {
400
- return new Promise((u, T) => {
401
- const S = document.createElement("img");
402
- let R = !1;
403
- S.onload = () => {
404
- R = !0, u(S);
405
- }, S.addEventListener("error", (k) => {
406
- console.warn("Image load failed", k.error), T(k.error);
407
- }), S.src = a, setTimeout(() => {
408
- R || T(new Error("Image load timed out"));
400
+ return new Promise((c, v) => {
401
+ const x = document.createElement("img");
402
+ let F = !1;
403
+ x.onload = () => {
404
+ F = !0, c(x);
405
+ }, x.addEventListener("error", (C) => {
406
+ console.warn("Image load failed", C.error), v(C.error);
407
+ }), x.src = a, setTimeout(() => {
408
+ F || v(new Error("Image load timed out"));
409
409
  }, o);
410
410
  });
411
411
  }
412
412
  function i(a) {
413
413
  return Math.round(a * 1e3) / 1e3;
414
414
  }
415
- const r = e.get("image"), d = e.get("aspectRatio");
415
+ const r = e.get("image"), u = e.get("aspectRatio");
416
416
  if (fetch(r).then((a) => a.blob()).then((a) => {
417
417
  a.type.includes("svg") && e.set("noWebp", !0);
418
- }), r && (!d || d === 0.7041))
418
+ }), r && (!u || u === 0.7041))
419
419
  return n(r).then((a) => {
420
420
  const o = e.get("aspectRatio");
421
421
  e.get("image") === r && (!o || o === 0.7041) && a.width && a.height && (e.set("aspectRatio", i(a.height / a.width)), e.set("height", a.height), e.set("width", a.width));
@@ -484,7 +484,7 @@ const H = {
484
484
  shouldReceiveBuilderProps: {
485
485
  builderBlock: !0
486
486
  }
487
- }, Ue = {
487
+ }, qe = {
488
488
  name: "PersonalizationContainer",
489
489
  shouldReceiveBuilderProps: {
490
490
  builderBlock: !0,
@@ -519,7 +519,7 @@ const H = {
519
519
  defaultValue: []
520
520
  }]
521
521
  }]
522
- }, He = v(() => import("./personalization-container-b85b14c3.js")), Le = {
522
+ }, $e = y(() => import("./personalization-container-1307218b.js")), _e = {
523
523
  name: "Core:Section",
524
524
  static: !0,
525
525
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
@@ -558,7 +558,7 @@ const H = {
558
558
  }
559
559
  }
560
560
  }]
561
- }, Ne = {
561
+ }, Ke = {
562
562
  name: "Slot",
563
563
  isRSC: !0,
564
564
  description: "Allow child blocks to be inserted into this content when used as a Symbol",
@@ -575,7 +575,7 @@ const H = {
575
575
  builderContext: !0,
576
576
  builderComponents: !0
577
577
  }
578
- }, qe = v(() => import("./slot-2670ac48.js")), $e = {
578
+ }, je = y(() => import("./slot-516f176d.js")), Oe = {
579
579
  name: "Symbol",
580
580
  noWrap: !0,
581
581
  static: !0,
@@ -614,7 +614,7 @@ const H = {
614
614
  builderComponents: !0,
615
615
  builderLinkComponent: !0
616
616
  }
617
- }, N = {
617
+ }, K = {
618
618
  "@type": "@builder.io/sdk:Element",
619
619
  responsiveStyles: {
620
620
  large: {
@@ -636,7 +636,7 @@ const H = {
636
636
  text: "New tab"
637
637
  }
638
638
  }
639
- }, q = {
639
+ }, j = {
640
640
  "@type": "@builder.io/sdk:Element",
641
641
  responsiveStyles: {
642
642
  large: {
@@ -652,7 +652,7 @@ const H = {
652
652
  text: "New tab content "
653
653
  }
654
654
  }
655
- }, _e = {
655
+ }, Me = {
656
656
  name: "Builder: Tabs",
657
657
  inputs: [{
658
658
  name: "tabs",
@@ -662,16 +662,16 @@ const H = {
662
662
  name: "label",
663
663
  type: "uiBlocks",
664
664
  hideFromUI: !0,
665
- defaultValue: [N]
665
+ defaultValue: [K]
666
666
  }, {
667
667
  name: "content",
668
668
  type: "uiBlocks",
669
669
  hideFromUI: !0,
670
- defaultValue: [q]
670
+ defaultValue: [j]
671
671
  }],
672
672
  defaultValue: [{
673
673
  label: [{
674
- ...N,
674
+ ...K,
675
675
  component: {
676
676
  name: "Text",
677
677
  options: {
@@ -680,7 +680,7 @@ const H = {
680
680
  }
681
681
  }],
682
682
  content: [{
683
- ...q,
683
+ ...j,
684
684
  component: {
685
685
  name: "Text",
686
686
  options: {
@@ -690,7 +690,7 @@ const H = {
690
690
  }]
691
691
  }, {
692
692
  label: [{
693
- ...N,
693
+ ...K,
694
694
  component: {
695
695
  name: "Text",
696
696
  options: {
@@ -699,7 +699,7 @@ const H = {
699
699
  }
700
700
  }],
701
701
  content: [{
702
- ...q,
702
+ ...j,
703
703
  component: {
704
704
  name: "Text",
705
705
  options: {
@@ -755,7 +755,7 @@ const H = {
755
755
  builderComponents: !0,
756
756
  builderLinkComponent: !0
757
757
  }
758
- }, je = v(() => import("./tabs-931291c4.js")), Ke = {
758
+ }, ze = y(() => import("./tabs-f0945019.js")), Je = {
759
759
  shouldReceiveBuilderProps: {
760
760
  builderBlock: !1,
761
761
  builderContext: !0
@@ -777,7 +777,7 @@ const H = {
777
777
  height: "auto",
778
778
  textAlign: "center"
779
779
  }
780
- }, Oe = {
780
+ }, Ye = {
781
781
  name: "Custom Code",
782
782
  static: !0,
783
783
  requiredPermissions: ["editCode"],
@@ -799,7 +799,7 @@ const H = {
799
799
  helperText: "Only print and run scripts on the client. Important when scripts influence DOM that could be replaced when client loads",
800
800
  advanced: !0
801
801
  }]
802
- }, Me = v(() => import("./custom-code-7786788e.js")), ze = {
802
+ }, Ge = y(() => import("./custom-code-1a43bbd7.js")), Qe = {
803
803
  name: "Embed",
804
804
  static: !0,
805
805
  inputs: [{
@@ -814,7 +814,7 @@ const H = {
814
814
  defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
815
815
  hideFromUI: !0
816
816
  }]
817
- }, Je = v(() => import("./embed-5c1bbe12.js")), Ye = {
817
+ }, Xe = y(() => import("./embed-106f0066.js")), Ze = {
818
818
  name: "Form:Form",
819
819
  // editableTags: ['builder-form-error']
820
820
  defaults: {
@@ -1051,7 +1051,7 @@ const H = {
1051
1051
  builderComponents: !0,
1052
1052
  builderLinkComponent: !0
1053
1053
  }
1054
- }, Ge = v(() => import("./form-f2aa1c12.js")), Qe = {
1054
+ }, et = y(() => import("./form-0c0d5bf5.js")), tt = {
1055
1055
  name: "Form:Input",
1056
1056
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fad6f37889d9e40bbbbc72cdb5875d6ca",
1057
1057
  inputs: [
@@ -1102,7 +1102,7 @@ const H = {
1102
1102
  borderStyle: "solid",
1103
1103
  borderColor: "#ccc"
1104
1104
  }
1105
- }, Xe = v(() => import("./input-f270ae3b.js")), Ze = {
1105
+ }, nt = y(() => import("./input-d6338de6.js")), at = {
1106
1106
  name: "Form:Select",
1107
1107
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F83acca093fb24aaf94dee136e9a4b045",
1108
1108
  defaultStyles: {
@@ -1144,7 +1144,7 @@ const H = {
1144
1144
  }],
1145
1145
  static: !0,
1146
1146
  noWrap: !0
1147
- }, et = v(() => import("./select-e12e1a87.js")), tt = {
1147
+ }, it = y(() => import("./select-1538b41a.js")), ot = {
1148
1148
  name: "Form:SubmitButton",
1149
1149
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fdf2820ffed1f4349a94c40b3221f5b98",
1150
1150
  defaultStyles: {
@@ -1169,7 +1169,7 @@ const H = {
1169
1169
  // that only shows if advanced setting is flipped
1170
1170
  // TODO: defaultChildren
1171
1171
  // canHaveChildren: true,
1172
- }, nt = v(() => import("./submit-button-b48361a7.js")), at = {
1172
+ }, rt = y(() => import("./submit-button-b48361a7.js")), lt = {
1173
1173
  name: "Form:TextArea",
1174
1174
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Ff74a2f3de58c4c3e939204e5b6b8f6c3",
1175
1175
  inputs: [{
@@ -1205,7 +1205,7 @@ const H = {
1205
1205
  },
1206
1206
  static: !0,
1207
1207
  noWrap: !0
1208
- }, it = v(() => import("./textarea-d29025e9.js")), ot = {
1208
+ }, st = y(() => import("./textarea-d29025e9.js")), dt = {
1209
1209
  // friendlyName?
1210
1210
  name: "Raw:Img",
1211
1211
  hideFromInsertMenu: !0,
@@ -1214,12 +1214,12 @@ const H = {
1214
1214
  name: "image",
1215
1215
  bubble: !0,
1216
1216
  type: "file",
1217
- allowedFileTypes: M,
1217
+ allowedFileTypes: Y,
1218
1218
  required: !0
1219
1219
  }],
1220
1220
  noWrap: !0,
1221
1221
  static: !0
1222
- }, rt = v(() => import("./img-2a060e61.js")), lt = {
1222
+ }, ut = y(() => import("./img-8bdeb666.js")), ct = {
1223
1223
  name: "Video",
1224
1224
  canHaveChildren: !0,
1225
1225
  defaultStyles: {
@@ -1230,14 +1230,14 @@ const H = {
1230
1230
  inputs: [{
1231
1231
  name: "video",
1232
1232
  type: "file",
1233
- allowedFileTypes: Be,
1233
+ allowedFileTypes: Le,
1234
1234
  bubble: !0,
1235
1235
  defaultValue: "https://cdn.builder.io/o/assets%2FYJIGb4i01jvw0SRdL5Bt%2Fd27731a526464deba0016216f5f9e570%2Fcompressed?apiKey=YJIGb4i01jvw0SRdL5Bt&token=d27731a526464deba0016216f5f9e570&alt=media&optimized=true",
1236
1236
  required: !0
1237
1237
  }, {
1238
1238
  name: "posterImage",
1239
1239
  type: "file",
1240
- allowedFileTypes: M,
1240
+ allowedFileTypes: Y,
1241
1241
  helperText: "Image to show before the video plays"
1242
1242
  }, {
1243
1243
  name: "autoPlay",
@@ -1303,67 +1303,67 @@ const H = {
1303
1303
  shouldReceiveBuilderProps: {
1304
1304
  builderBlock: !0
1305
1305
  }
1306
- }, st = () => [{
1307
- component: Me,
1308
- ...Oe
1309
- }, {
1310
- component: Je,
1311
- ...ze
1312
- }, {
1306
+ }, mt = () => [{
1313
1307
  component: Ge,
1314
1308
  ...Ye
1315
1309
  }, {
1316
1310
  component: Xe,
1317
1311
  ...Qe
1318
- }, {
1319
- component: nt,
1320
- ...tt
1321
1312
  }, {
1322
1313
  component: et,
1323
1314
  ...Ze
1324
1315
  }, {
1325
- component: it,
1326
- ...at
1316
+ component: nt,
1317
+ ...tt
1327
1318
  }, {
1328
1319
  component: rt,
1329
1320
  ...ot
1330
1321
  }, {
1331
- component: he,
1332
- ...lt
1333
- }], Q = () => [{
1334
- component: be,
1335
- ...Pe
1322
+ component: it,
1323
+ ...at
1336
1324
  }, {
1337
- component: ye,
1338
- ...We
1325
+ component: st,
1326
+ ...lt
1339
1327
  }, {
1340
- component: xe,
1341
- ...Ae
1328
+ component: ut,
1329
+ ...dt
1342
1330
  }, {
1343
1331
  component: ve,
1332
+ ...ct
1333
+ }], ee = () => [{
1334
+ component: Se,
1344
1335
  ...De
1345
1336
  }, {
1346
- component: Se,
1347
- ...Le
1337
+ component: Te,
1338
+ ...Ue
1348
1339
  }, {
1349
- component: qe,
1340
+ component: Ie,
1341
+ ...He
1342
+ }, {
1343
+ component: ke,
1350
1344
  ...Ne
1351
1345
  }, {
1352
- component: Te,
1353
- ...$e
1346
+ component: Ce,
1347
+ ..._e
1354
1348
  }, {
1355
- component: Ie,
1349
+ component: je,
1356
1350
  ...Ke
1357
1351
  }, {
1358
- component: He,
1359
- ...Ue
1352
+ component: we,
1353
+ ...Oe
1360
1354
  }, {
1361
- component: je,
1362
- ..._e
1355
+ component: Ve,
1356
+ ...Je
1357
+ }, {
1358
+ component: $e,
1359
+ ...qe
1363
1360
  }, {
1364
- component: Fe,
1365
- ...Ee
1366
- }, ...st()], dt = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget) {
1361
+ component: ze,
1362
+ ...Me
1363
+ }, {
1364
+ component: Be,
1365
+ ...We
1366
+ }, ...mt()], pt = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget, isAngularSDK) {
1367
1367
  function getAndSetVariantId() {
1368
1368
  function setCookie(name, value, days) {
1369
1369
  let expires = '';
@@ -1405,7 +1405,10 @@ const H = {
1405
1405
  return contentId;
1406
1406
  }
1407
1407
  const winningVariantId = getAndSetVariantId();
1408
- const styleEl = document.currentScript?.previousElementSibling;
1408
+ let styleEl = document.currentScript?.previousElementSibling;
1409
+ if (isAngularSDK) {
1410
+ styleEl = document.currentScript?.parentElement?.previousElementSibling?.querySelector('style');
1411
+ }
1409
1412
  if (isHydrationTarget) {
1410
1413
  styleEl.remove();
1411
1414
  const thisScriptEl = document.currentScript;
@@ -1419,7 +1422,7 @@ const H = {
1419
1422
  }).join('');
1420
1423
  styleEl.innerHTML = newStyleStr;
1421
1424
  }
1422
- }`, ut = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
1425
+ }`, ft = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
1423
1426
  if (!navigator.cookieEnabled) {
1424
1427
  return;
1425
1428
  }
@@ -1453,27 +1456,27 @@ const H = {
1453
1456
  thisScriptEl?.remove();
1454
1457
  }
1455
1458
  return;
1456
- }`, oe = "builderIoAbTest", re = "builderIoRenderContent", D = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
1459
+ }`, se = "builderIoAbTest", de = "builderIoRenderContent", H = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
1457
1460
  ...t,
1458
1461
  testVariationId: t.id,
1459
1462
  id: e == null ? void 0 : e.id
1460
- })), ct = ({
1463
+ })), gt = ({
1461
1464
  canTrack: e,
1462
1465
  content: t
1463
- }) => !(!(D(t).length > 0) || !e || j()), mt = (e) => e === "react" || e === "reactNative", le = mt(O), pt = () => `
1464
- window.${oe} = ${dt}
1465
- window.${re} = ${ut}
1466
- `, ft = (e, t) => `
1467
- window.${oe}(
1468
- "${t}",${JSON.stringify(e)}, ${le}
1469
- )`, gt = ({
1466
+ }) => !(!(H(t).length > 0) || !e || z()), ht = (e) => e === "react" || e === "reactNative", bt = N === "angular", ue = ht(N), yt = () => `
1467
+ window.${se} = ${pt}
1468
+ window.${de} = ${ft}
1469
+ `, xt = (e, t) => `
1470
+ window.${se}(
1471
+ "${t}",${JSON.stringify(e)}, ${ue}, ${bt}
1472
+ )`, vt = ({
1470
1473
  contentId: e,
1471
1474
  variationId: t
1472
- }) => `window.${re}(
1473
- "${t}", "${e}", ${le}
1475
+ }) => `window.${de}(
1476
+ "${t}", "${e}", ${ue}
1474
1477
  )`;
1475
- function K(e) {
1476
- return /* @__PURE__ */ y(
1478
+ function J(e) {
1479
+ return /* @__PURE__ */ h(
1477
1480
  "script",
1478
1481
  {
1479
1482
  dangerouslySetInnerHTML: { __html: e.scriptStr },
@@ -1482,10 +1485,10 @@ function K(e) {
1482
1485
  }
1483
1486
  );
1484
1487
  }
1485
- function X(e) {
1488
+ function te(e) {
1486
1489
  return Math.round(e * 1e3) / 1e3;
1487
1490
  }
1488
- const ht = (e, t, n = !0) => {
1491
+ const St = (e, t, n = !0) => {
1489
1492
  if (!(e instanceof HTMLElement))
1490
1493
  return null;
1491
1494
  let i = n ? e : e.parentElement;
@@ -1496,37 +1499,37 @@ const ht = (e, t, n = !0) => {
1496
1499
  return i;
1497
1500
  } while (i = i.parentElement);
1498
1501
  return null;
1499
- }, bt = (e) => ht(e, (t) => {
1502
+ }, Tt = (e) => St(e, (t) => {
1500
1503
  const n = t.getAttribute("builder-id") || t.id;
1501
1504
  return (n == null ? void 0 : n.indexOf("builder-")) === 0;
1502
- }), Z = ({
1505
+ }), ne = ({
1503
1506
  event: e,
1504
1507
  target: t
1505
1508
  }) => {
1506
- const n = t.getBoundingClientRect(), i = e.clientX - n.left, r = e.clientY - n.top, d = X(i / n.width), a = X(r / n.height);
1509
+ const n = t.getBoundingClientRect(), i = e.clientX - n.left, r = e.clientY - n.top, u = te(i / n.width), a = te(r / n.height);
1507
1510
  return {
1508
- x: d,
1511
+ x: u,
1509
1512
  y: a
1510
1513
  };
1511
- }, yt = (e) => {
1512
- const t = e.target, n = t && bt(t), i = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
1514
+ }, It = (e) => {
1515
+ const t = e.target, n = t && Tt(t), i = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
1513
1516
  return {
1514
1517
  targetBuilderElement: i || void 0,
1515
1518
  metadata: {
1516
- targetOffset: t ? Z({
1519
+ targetOffset: t ? ne({
1517
1520
  event: e,
1518
1521
  target: t
1519
1522
  }) : void 0,
1520
- builderTargetOffset: n ? Z({
1523
+ builderTargetOffset: n ? ne({
1521
1524
  event: e,
1522
1525
  target: n
1523
1526
  }) : void 0,
1524
1527
  builderElementIndex: n && i ? [].slice.call(document.getElementsByClassName(i)).indexOf(n) : void 0
1525
1528
  }
1526
1529
  };
1527
- }, xt = ["svelte", "qwik", "vue"], ee = () => xt.includes(O) && (P() || ne()), vt = (e) => {
1528
- var d, a;
1529
- const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = (a = e.fileUrl) != null ? a : (d = e == null ? void 0 : e.files) == null ? void 0 : d.regular;
1530
+ }, kt = ["svelte", "qwik", "vue"], ae = () => kt.includes(N) && (A() || oe()), Ct = (e) => {
1531
+ var u, a;
1532
+ const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = (a = e.fileUrl) != null ? a : (u = e == null ? void 0 : e.files) == null ? void 0 : u.regular;
1530
1533
  let r = "";
1531
1534
  if (i && t && n && (r += `
1532
1535
  @font-face {
@@ -1539,26 +1542,26 @@ font-weight: 400;
1539
1542
  for (const o in e.files) {
1540
1543
  if (!(String(Number(o)) === o))
1541
1544
  continue;
1542
- const T = e.files[o];
1543
- T && T !== i && (r += `
1545
+ const v = e.files[o];
1546
+ v && v !== i && (r += `
1544
1547
  @font-face {
1545
1548
  font-family: "${t}";
1546
- src: url('${T}') format('woff2');
1549
+ src: url('${v}') format('woff2');
1547
1550
  font-display: fallback;
1548
1551
  font-weight: ${o};
1549
1552
  }
1550
1553
  `.trim());
1551
1554
  }
1552
1555
  return r;
1553
- }, St = ({
1556
+ }, wt = ({
1554
1557
  customFonts: e
1555
1558
  }) => {
1556
1559
  var t;
1557
- return ((t = e == null ? void 0 : e.map((n) => vt(n))) == null ? void 0 : t.join(" ")) || "";
1558
- }, Tt = ({
1560
+ return ((t = e == null ? void 0 : e.map((n) => Ct(n))) == null ? void 0 : t.join(" ")) || "";
1561
+ }, Vt = ({
1559
1562
  cssCode: e,
1560
1563
  contentId: t
1561
- }) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", It = `
1564
+ }) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", Rt = `
1562
1565
  .builder-button {
1563
1566
  all: unset;
1564
1567
  }
@@ -1575,38 +1578,39 @@ font-weight: ${o};
1575
1578
  text-align: inherit;
1576
1579
  font-family: inherit;
1577
1580
  }
1578
- `, kt = (e) => e ? "" : It, Ct = (e) => `variant-${e}`;
1579
- function wt(e) {
1580
- var b, x, C;
1581
- const t = _(null);
1581
+ `, Et = (e) => e ? "" : Rt, Ft = (e) => `variant-${e}`;
1582
+ function Pt(e) {
1583
+ var f, b, w;
1584
+ const t = M(null);
1585
+ T(() => !1);
1582
1586
  function n(l) {
1583
- var p, f;
1587
+ var m, p;
1584
1588
  const s = {
1585
1589
  ...e.builderContextSignal.rootState,
1586
1590
  ...l
1587
1591
  };
1588
- e.builderContextSignal.rootSetState ? (f = (p = e.builderContextSignal).rootSetState) == null || f.call(p, s) : e.setBuilderContextSignal((c) => ({
1589
- ...c,
1592
+ e.builderContextSignal.rootSetState ? (p = (m = e.builderContextSignal).rootSetState) == null || p.call(m, s) : e.setBuilderContextSignal((d) => ({
1593
+ ...d,
1590
1594
  rootState: s
1591
1595
  }));
1592
1596
  }
1593
1597
  function i(l) {
1594
- var p, f, c, m, g;
1598
+ var m, p, d, V, I;
1595
1599
  const s = {
1596
1600
  ...e.builderContextSignal.content,
1597
1601
  ...l,
1598
1602
  data: {
1599
- ...(p = e.builderContextSignal.content) == null ? void 0 : p.data,
1603
+ ...(m = e.builderContextSignal.content) == null ? void 0 : m.data,
1600
1604
  ...l == null ? void 0 : l.data
1601
1605
  },
1602
1606
  meta: {
1603
- ...(f = e.builderContextSignal.content) == null ? void 0 : f.meta,
1607
+ ...(p = e.builderContextSignal.content) == null ? void 0 : p.meta,
1604
1608
  ...l == null ? void 0 : l.meta,
1605
- breakpoints: ((c = l == null ? void 0 : l.meta) == null ? void 0 : c.breakpoints) || ((g = (m = e.builderContextSignal.content) == null ? void 0 : m.meta) == null ? void 0 : g.breakpoints)
1609
+ breakpoints: ((d = l == null ? void 0 : l.meta) == null ? void 0 : d.breakpoints) || ((I = (V = e.builderContextSignal.content) == null ? void 0 : V.meta) == null ? void 0 : I.breakpoints)
1606
1610
  }
1607
1611
  };
1608
- e.setBuilderContextSignal((h) => ({
1609
- ...h,
1612
+ e.setBuilderContextSignal((S) => ({
1613
+ ...S,
1610
1614
  content: s
1611
1615
  }));
1612
1616
  }
@@ -1616,25 +1620,25 @@ function wt(e) {
1616
1620
  "aria-hidden": !0
1617
1621
  };
1618
1622
  }
1619
- const [d, a] = I(
1623
+ const [u, a] = T(
1620
1624
  () => e.contentWrapper || "div"
1621
1625
  );
1622
1626
  function o(l) {
1623
- return me({
1627
+ return he({
1624
1628
  model: e.model,
1625
1629
  trustedHosts: e.trustedHosts,
1626
1630
  callbacks: {
1627
1631
  configureSdk: (s) => {
1628
- var c;
1629
- const { breakpoints: p, contentId: f } = s;
1630
- !f || f !== ((c = e.builderContextSignal.content) == null ? void 0 : c.id) || p && i({
1632
+ var d;
1633
+ const { breakpoints: m, contentId: p } = s;
1634
+ !p || p !== ((d = e.builderContextSignal.content) == null ? void 0 : d.id) || m && i({
1631
1635
  meta: {
1632
- breakpoints: p
1636
+ breakpoints: m
1633
1637
  }
1634
1638
  });
1635
1639
  },
1636
1640
  animation: (s) => {
1637
- Ce(s);
1641
+ Ee(s);
1638
1642
  },
1639
1643
  contentUpdate: (s) => {
1640
1644
  i(s);
@@ -1645,36 +1649,36 @@ function wt(e) {
1645
1649
  }
1646
1650
  })(l);
1647
1651
  }
1648
- const [u, T] = I(() => ({})), [S, R] = I(() => ({})), [k, W] = I(() => !1);
1649
- function A(l) {
1650
- var s, p;
1652
+ const [c, v] = T(() => ({})), [x, F] = T(() => ({})), [C, W] = T(() => !1);
1653
+ function B(l) {
1654
+ var s, m;
1651
1655
  if (e.builderContextSignal.content) {
1652
- const f = (s = e.builderContextSignal.content) == null ? void 0 : s.testVariationId, c = (p = e.builderContextSignal.content) == null ? void 0 : p.id;
1653
- Y({
1656
+ const p = (s = e.builderContextSignal.content) == null ? void 0 : s.testVariationId, d = (m = e.builderContextSignal.content) == null ? void 0 : m.id;
1657
+ X({
1654
1658
  apiHost: e.apiHost,
1655
1659
  type: "click",
1656
- canTrack: U(e.canTrack),
1657
- contentId: c,
1660
+ canTrack: L(e.canTrack),
1661
+ contentId: d,
1658
1662
  apiKey: e.apiKey,
1659
- variationId: f !== c ? f : void 0,
1660
- ...yt(l),
1661
- unique: !k
1663
+ variationId: p !== d ? p : void 0,
1664
+ ...It(l),
1665
+ unique: !C
1662
1666
  });
1663
1667
  }
1664
- k || W(!0);
1668
+ C || W(!0);
1665
1669
  }
1666
- function B() {
1667
- var s, p, f;
1668
- const l = (f = (p = (s = e.builderContextSignal.content) == null ? void 0 : s.data) == null ? void 0 : p.httpRequests) != null ? f : {};
1669
- Object.entries(l).forEach(([c, m]) => {
1670
- if (!m || S[c] || u[c] && !P())
1670
+ function D() {
1671
+ var s, m, p;
1672
+ const l = (p = (m = (s = e.builderContextSignal.content) == null ? void 0 : s.data) == null ? void 0 : m.httpRequests) != null ? p : {};
1673
+ Object.entries(l).forEach(([d, V]) => {
1674
+ if (!V || x[d] || c[d] && !A())
1671
1675
  return;
1672
- S[c] = !0;
1673
- const g = m.replace(
1676
+ x[d] = !0;
1677
+ const I = V.replace(
1674
1678
  /{{([^}]+)}}/g,
1675
- (h, F) => String(
1676
- ae({
1677
- code: F,
1679
+ (S, g) => String(
1680
+ re({
1681
+ code: g,
1678
1682
  context: e.context || {},
1679
1683
  localState: void 0,
1680
1684
  rootState: e.builderContextSignal.rootState,
@@ -1682,24 +1686,24 @@ function wt(e) {
1682
1686
  })
1683
1687
  )
1684
1688
  );
1685
- pe(g), fetch(g).then((h) => h.json()).then((h) => {
1689
+ be(I), fetch(I).then((S) => S.json()).then((S) => {
1686
1690
  n({
1687
- [c]: h
1688
- }), u[c] = !0;
1689
- }).catch((h) => {
1690
- console.error("error fetching dynamic data", m, h);
1691
+ [d]: S
1692
+ }), c[d] = !0;
1693
+ }).catch((S) => {
1694
+ console.error("error fetching dynamic data", V, S);
1691
1695
  }).finally(() => {
1692
- S[c] = !1;
1696
+ x[d] = !1;
1693
1697
  });
1694
1698
  });
1695
1699
  }
1696
- function w() {
1697
- P() && window.dispatchEvent(
1700
+ function R() {
1701
+ A() && window.dispatchEvent(
1698
1702
  new CustomEvent(
1699
1703
  "builder:component:stateChange",
1700
1704
  {
1701
1705
  detail: {
1702
- state: we(e.builderContextSignal.rootState),
1706
+ state: Fe(e.builderContextSignal.rootState),
1703
1707
  ref: {
1704
1708
  name: e.model
1705
1709
  }
@@ -1708,11 +1712,11 @@ function wt(e) {
1708
1712
  )
1709
1713
  );
1710
1714
  }
1711
- const E = _(!1);
1712
- return E.current || (B(), w(), E.current = !0), V(() => {
1713
- var l, s, p, f;
1714
- if (j()) {
1715
- if (P() && !e.isNestedRender && (window.addEventListener("message", o), se(), de({
1715
+ const P = M(!1);
1716
+ return P.current || (D(), R(), P.current = !0), E(() => {
1717
+ var l, s, m, p, d;
1718
+ if (z()) {
1719
+ A() && !e.isNestedRender && (window.addEventListener("message", o), ce(), me({
1716
1720
  ...e.locale ? {
1717
1721
  locale: e.locale
1718
1722
  } : {},
@@ -1726,71 +1730,76 @@ function wt(e) {
1726
1730
  apiKey: e.apiKey
1727
1731
  }), Object.values(
1728
1732
  e.builderContextSignal.componentInfos
1729
- ).forEach((m) => {
1730
- var g, h;
1731
- if (!((g = m.models) != null && g.length) || m.models.includes(e.model)) {
1732
- const F = ue(m);
1733
- (h = window.parent) == null || h.postMessage(F, "*");
1733
+ ).forEach((g) => {
1734
+ var k, U;
1735
+ if (!((k = g.models) != null && k.length) || g.models.includes(e.model)) {
1736
+ const q = pe(g);
1737
+ (U = window.parent) == null || U.postMessage(q, "*");
1734
1738
  }
1735
1739
  }), window.addEventListener(
1736
1740
  "builder:component:stateChangeListenerActivated",
1737
- w
1738
- )), e.builderContextSignal.content && U(e.canTrack)) {
1739
- const m = (s = e.builderContextSignal.content) == null ? void 0 : s.testVariationId, g = (p = e.builderContextSignal.content) == null ? void 0 : p.id, h = e.apiKey;
1740
- Y({
1741
+ R
1742
+ ));
1743
+ const V = e.builderContextSignal.content && L(e.canTrack), I = fe({
1744
+ name: `builder.tests.${(s = e.builderContextSignal.content) == null ? void 0 : s.id}`,
1745
+ canTrack: !0
1746
+ }), S = (m = e.builderContextSignal.content) == null ? void 0 : m.testVariationId;
1747
+ if (V && S === I) {
1748
+ const g = (p = e.builderContextSignal.content) == null ? void 0 : p.id, k = e.apiKey;
1749
+ X({
1741
1750
  apiHost: e.apiHost,
1742
1751
  type: "impression",
1743
1752
  canTrack: !0,
1744
1753
  contentId: g,
1745
- apiKey: h,
1746
- variationId: m !== g ? m : void 0
1754
+ apiKey: k,
1755
+ variationId: I !== g ? I : void 0
1747
1756
  });
1748
1757
  }
1749
- if (ne() && !P()) {
1750
- const m = new URL(location.href).searchParams, g = m.get("builder.preview"), h = m.get(
1751
- `builder.overrides.${g}`
1752
- ), F = m.get("apiKey") || m.get("builder.space");
1753
- (g === "BUILDER_STUDIO" || g === e.model && F === e.apiKey && (!e.content || h === e.content.id)) && ce({
1758
+ if (oe() && !A()) {
1759
+ const g = new URL(location.href).searchParams, k = g.get("builder.preview"), U = g.get(
1760
+ `builder.overrides.${k}`
1761
+ ), q = g.get("apiKey") || g.get("builder.space");
1762
+ (k === "BUILDER_STUDIO" || k === e.model && q === e.apiKey && (!e.content || U === e.content.id)) && ge({
1754
1763
  model: e.model,
1755
1764
  apiKey: e.apiKey,
1756
1765
  apiVersion: e.builderContextSignal.apiVersion,
1757
- ...g === "BUILDER_STUDIO" && ((f = e.context) != null && f.symbolId) ? {
1766
+ ...k === "BUILDER_STUDIO" && ((d = e.context) != null && d.symbolId) ? {
1758
1767
  query: {
1759
1768
  id: e.context.symbolId
1760
1769
  }
1761
1770
  } : {}
1762
- }).then((z) => {
1763
- z && i(z);
1771
+ }).then((G) => {
1772
+ G && i(G);
1764
1773
  });
1765
1774
  }
1766
1775
  }
1767
- }, []), V(() => {
1776
+ }, []), E(() => {
1768
1777
  e.content && i(e.content);
1769
- }, [e.content]), V(() => {
1770
- w();
1771
- }, [e.builderContextSignal.rootState]), V(() => {
1778
+ }, [e.content]), E(() => {
1779
+ R();
1780
+ }, [e.builderContextSignal.rootState]), E(() => {
1772
1781
  e.data && n(e.data);
1773
- }, [e.data]), V(() => {
1782
+ }, [e.data]), E(() => {
1774
1783
  e.locale && n({
1775
1784
  locale: e.locale
1776
1785
  });
1777
- }, [e.locale]), V(() => () => {
1778
- j() && (window.removeEventListener("message", o), window.removeEventListener(
1786
+ }, [e.locale]), E(() => () => {
1787
+ z() && (window.removeEventListener("message", o), window.removeEventListener(
1779
1788
  "builder:component:stateChangeListenerActivated",
1780
- w
1789
+ R
1781
1790
  ));
1782
- }, []), /* @__PURE__ */ y(ke.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content || ee() ? /* @__PURE__ */ y(
1783
- d,
1791
+ }, []), /* @__PURE__ */ h(Re.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content || ae() ? /* @__PURE__ */ h(
1792
+ u,
1784
1793
  {
1785
1794
  ref: t,
1786
- onClick: (l) => A(l),
1787
- "builder-content-id": (b = e.builderContextSignal.content) == null ? void 0 : b.id,
1795
+ onClick: (l) => B(l),
1796
+ "builder-content-id": (f = e.builderContextSignal.content) == null ? void 0 : f.id,
1788
1797
  "builder-model": e.model,
1789
- className: Ct(
1790
- ((x = e.content) == null ? void 0 : x.testVariationId) || ((C = e.content) == null ? void 0 : C.id)
1798
+ className: Ft(
1799
+ ((b = e.content) == null ? void 0 : b.testVariationId) || ((w = e.content) == null ? void 0 : w.id)
1791
1800
  ),
1792
1801
  style: {
1793
- display: !e.builderContextSignal.content && ee() ? "none" : void 0
1802
+ display: !e.builderContextSignal.content && ae() ? "none" : void 0
1794
1803
  },
1795
1804
  ...r(),
1796
1805
  ...e.contentWrapperProps,
@@ -1798,21 +1807,21 @@ function wt(e) {
1798
1807
  }
1799
1808
  ) : null });
1800
1809
  }
1801
- function Vt(e) {
1802
- const [t, n] = I(
1810
+ function At(e) {
1811
+ const [t, n] = T(
1803
1812
  () => `
1804
- ${Tt({
1813
+ ${Vt({
1805
1814
  cssCode: e.cssCode,
1806
1815
  contentId: e.contentId
1807
1816
  })}
1808
- ${St({
1817
+ ${wt({
1809
1818
  customFonts: e.customFonts
1810
1819
  })}
1811
- ${kt(e.isNestedRender)}
1820
+ ${Et(e.isNestedRender)}
1812
1821
  `.trim()
1813
1822
  );
1814
- return /* @__PURE__ */ y(
1815
- ie,
1823
+ return /* @__PURE__ */ h(
1824
+ le,
1816
1825
  {
1817
1826
  id: "builderio-content",
1818
1827
  styles: t,
@@ -1820,15 +1829,15 @@ ${kt(e.isNestedRender)}
1820
1829
  }
1821
1830
  );
1822
1831
  }
1823
- const Rt = ({
1832
+ const Wt = ({
1824
1833
  content: e,
1825
1834
  data: t,
1826
1835
  locale: n
1827
1836
  }) => {
1828
- var d, a, o;
1829
- const i = {}, r = ((d = e == null ? void 0 : e.data) == null ? void 0 : d.state) || {};
1830
- return (o = (a = e == null ? void 0 : e.data) == null ? void 0 : a.inputs) == null || o.forEach((u) => {
1831
- u.name && u.defaultValue !== void 0 && (i[u.name] = u.defaultValue);
1837
+ var u, a, o;
1838
+ const i = {}, r = ((u = e == null ? void 0 : e.data) == null ? void 0 : u.state) || {};
1839
+ return (o = (a = e == null ? void 0 : e.data) == null ? void 0 : a.inputs) == null || o.forEach((c) => {
1840
+ c.name && c.defaultValue !== void 0 && (i[c.name] = c.defaultValue);
1832
1841
  }), {
1833
1842
  ...i,
1834
1843
  ...r,
@@ -1837,7 +1846,7 @@ const Rt = ({
1837
1846
  locale: n
1838
1847
  } : {}
1839
1848
  };
1840
- }, Et = ({
1849
+ }, Bt = ({
1841
1850
  content: e,
1842
1851
  data: t
1843
1852
  }) => e ? {
@@ -1848,46 +1857,46 @@ const Rt = ({
1848
1857
  },
1849
1858
  meta: e == null ? void 0 : e.meta
1850
1859
  } : void 0;
1851
- function te(e) {
1852
- var T, S, R, k, W, A, B, w, E;
1853
- const [t, n] = I(
1860
+ function ie(e) {
1861
+ var v, x, F, C, W, B, D, R, P;
1862
+ const [t, n] = T(
1854
1863
  () => {
1855
- var b, x;
1856
- return gt({
1864
+ var f, b;
1865
+ return vt({
1857
1866
  // eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
1858
- variationId: (b = e.content) == null ? void 0 : b.testVariationId,
1867
+ variationId: (f = e.content) == null ? void 0 : f.testVariationId,
1859
1868
  // eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
1860
- contentId: (x = e.content) == null ? void 0 : x.id
1869
+ contentId: (b = e.content) == null ? void 0 : b.id
1861
1870
  });
1862
1871
  }
1863
1872
  );
1864
- function i(b) {
1865
- o((x) => ({
1866
- ...x,
1867
- rootState: b
1873
+ function i(f) {
1874
+ o((b) => ({
1875
+ ...b,
1876
+ rootState: f
1868
1877
  }));
1869
1878
  }
1870
- const [r, d] = I(
1879
+ const [r, u] = T(
1871
1880
  () => [
1872
- ...Q(),
1881
+ ...ee(),
1873
1882
  ...e.customComponents || []
1874
1883
  ].reduce(
1875
- (b, { component: x, ...C }) => ({
1876
- ...b,
1877
- [C.name]: {
1878
- component: x,
1879
- ...G(C)
1884
+ (f, { component: b, ...w }) => ({
1885
+ ...f,
1886
+ [w.name]: {
1887
+ component: b,
1888
+ ...Z(w)
1880
1889
  }
1881
1890
  }),
1882
1891
  {}
1883
1892
  )
1884
- ), [a, o] = I(() => ({
1885
- content: Et({
1893
+ ), [a, o] = T(() => ({
1894
+ content: Bt({
1886
1895
  content: e.content,
1887
1896
  data: e.data
1888
1897
  }),
1889
1898
  localState: void 0,
1890
- rootState: Rt({
1899
+ rootState: Wt({
1891
1900
  content: e.content,
1892
1901
  data: e.data,
1893
1902
  locale: e.locale
@@ -1898,12 +1907,12 @@ function te(e) {
1898
1907
  apiKey: e.apiKey,
1899
1908
  apiVersion: e.apiVersion,
1900
1909
  componentInfos: [
1901
- ...Q(),
1910
+ ...ee(),
1902
1911
  ...e.customComponents || []
1903
1912
  ].reduce(
1904
- (b, { component: x, ...C }) => ({
1905
- ...b,
1906
- [C.name]: G(C)
1913
+ (f, { component: b, ...w }) => ({
1914
+ ...f,
1915
+ [w.name]: Z(w)
1907
1916
  }),
1908
1917
  {}
1909
1918
  ),
@@ -1912,31 +1921,31 @@ function te(e) {
1912
1921
  BlocksWrapperProps: e.blocksWrapperProps || {},
1913
1922
  nonce: e.nonce || "",
1914
1923
  model: e.model
1915
- })), u = _(!1);
1916
- if (!u.current) {
1917
- e.apiKey || fe.error(
1924
+ })), c = M(!1);
1925
+ if (!c.current) {
1926
+ e.apiKey || ye.error(
1918
1927
  "No API key provided to `Content` component. This can cause issues. Please provide an API key using the `apiKey` prop."
1919
1928
  );
1920
- const b = (S = (T = a.content) == null ? void 0 : T.data) == null ? void 0 : S.jsCode;
1921
- b && ae({
1922
- code: b,
1929
+ const f = (x = (v = a.content) == null ? void 0 : v.data) == null ? void 0 : x.jsCode;
1930
+ f && re({
1931
+ code: f,
1923
1932
  context: e.context || {},
1924
1933
  localState: void 0,
1925
1934
  rootState: a.rootState,
1926
- rootSetState: (x) => {
1927
- Object.assign(a.rootState, x);
1935
+ rootSetState: (b) => {
1936
+ Object.assign(a.rootState, b);
1928
1937
  },
1929
1938
  isExpression: !1
1930
- }), u.current = !0;
1939
+ }), c.current = !0;
1931
1940
  }
1932
- return /* @__PURE__ */ y(
1933
- Ve.Provider,
1941
+ return /* @__PURE__ */ h(
1942
+ Pe.Provider,
1934
1943
  {
1935
1944
  value: {
1936
1945
  registeredComponents: r
1937
1946
  },
1938
- children: /* @__PURE__ */ $(
1939
- wt,
1947
+ children: /* @__PURE__ */ O(
1948
+ Pt,
1940
1949
  {
1941
1950
  apiHost: e.apiHost,
1942
1951
  nonce: e.nonce,
@@ -1956,28 +1965,28 @@ function te(e) {
1956
1965
  isNestedRender: e.isNestedRender,
1957
1966
  setBuilderContextSignal: o,
1958
1967
  children: [
1959
- e.isSsrAbTest ? /* @__PURE__ */ y(
1960
- K,
1968
+ e.isSsrAbTest ? /* @__PURE__ */ h(
1969
+ J,
1961
1970
  {
1962
1971
  id: "builderio-variant-visibility",
1963
1972
  scriptStr: t,
1964
1973
  nonce: e.nonce || ""
1965
1974
  }
1966
1975
  ) : null,
1967
- /* @__PURE__ */ y(
1968
- Vt,
1976
+ /* @__PURE__ */ h(
1977
+ At,
1969
1978
  {
1970
1979
  nonce: e.nonce || "",
1971
1980
  isNestedRender: e.isNestedRender,
1972
- contentId: (R = a.content) == null ? void 0 : R.id,
1973
- cssCode: (W = (k = a.content) == null ? void 0 : k.data) == null ? void 0 : W.cssCode,
1974
- customFonts: (B = (A = a.content) == null ? void 0 : A.data) == null ? void 0 : B.customFonts
1981
+ contentId: (F = a.content) == null ? void 0 : F.id,
1982
+ cssCode: (W = (C = a.content) == null ? void 0 : C.data) == null ? void 0 : W.cssCode,
1983
+ customFonts: (D = (B = a.content) == null ? void 0 : B.data) == null ? void 0 : D.customFonts
1975
1984
  }
1976
1985
  ),
1977
- /* @__PURE__ */ y(
1978
- Re,
1986
+ /* @__PURE__ */ h(
1987
+ Ae,
1979
1988
  {
1980
- blocks: (E = (w = a.content) == null ? void 0 : w.data) == null ? void 0 : E.blocks,
1989
+ blocks: (P = (R = a.content) == null ? void 0 : R.data) == null ? void 0 : P.blocks,
1981
1990
  context: a,
1982
1991
  registeredComponents: r,
1983
1992
  linkComponent: e.linkComponent
@@ -1989,66 +1998,66 @@ function te(e) {
1989
1998
  }
1990
1999
  );
1991
2000
  }
1992
- function Ft(e) {
2001
+ function Dt(e) {
1993
2002
  var a;
1994
- const [t, n] = I(
1995
- () => ct({
1996
- canTrack: U(e.canTrack),
2003
+ const [t, n] = T(
2004
+ () => gt({
2005
+ canTrack: L(e.canTrack),
1997
2006
  content: e.content
1998
2007
  })
1999
2008
  );
2000
2009
  function i() {
2001
2010
  var o;
2002
- return ft(
2003
- D(e.content).map((u) => ({
2004
- id: u.testVariationId,
2005
- testRatio: u.testRatio
2011
+ return xt(
2012
+ H(e.content).map((c) => ({
2013
+ id: c.testVariationId,
2014
+ testRatio: c.testRatio
2006
2015
  })),
2007
2016
  ((o = e.content) == null ? void 0 : o.id) || ""
2008
2017
  );
2009
2018
  }
2010
2019
  function r() {
2011
- return D(e.content).map((o) => `.variant-${o.testVariationId} { display: none; } `).join("");
2020
+ return H(e.content).map((o) => `.variant-${o.testVariationId} { display: none; } `).join("");
2012
2021
  }
2013
- function d() {
2022
+ function u() {
2014
2023
  var o;
2015
2024
  return t ? {
2016
2025
  ...e.content,
2017
2026
  testVariationId: (o = e.content) == null ? void 0 : o.id
2018
- } : ge({
2027
+ } : xe({
2019
2028
  item: e.content,
2020
- canTrack: U(e.canTrack)
2029
+ canTrack: L(e.canTrack)
2021
2030
  });
2022
2031
  }
2023
- return V(() => {
2024
- }, []), /* @__PURE__ */ $(J, { children: [
2025
- !e.isNestedRender && O !== "reactNative" ? /* @__PURE__ */ y(
2026
- K,
2032
+ return E(() => {
2033
+ }, []), /* @__PURE__ */ O(Q, { children: [
2034
+ !e.isNestedRender && N !== "reactNative" ? /* @__PURE__ */ h(
2035
+ J,
2027
2036
  {
2028
2037
  id: "builderio-init-variants-fns",
2029
- scriptStr: pt(),
2038
+ scriptStr: yt(),
2030
2039
  nonce: e.nonce || ""
2031
2040
  }
2032
2041
  ) : null,
2033
- t ? /* @__PURE__ */ $(J, { children: [
2034
- /* @__PURE__ */ y(
2035
- ie,
2042
+ t ? /* @__PURE__ */ O(Q, { children: [
2043
+ /* @__PURE__ */ h(
2044
+ le,
2036
2045
  {
2037
2046
  id: "builderio-variants",
2038
2047
  styles: r(),
2039
2048
  nonce: e.nonce || ""
2040
2049
  }
2041
2050
  ),
2042
- /* @__PURE__ */ y(
2043
- K,
2051
+ /* @__PURE__ */ h(
2052
+ J,
2044
2053
  {
2045
2054
  id: "builderio-variants-visibility",
2046
2055
  scriptStr: i(),
2047
2056
  nonce: e.nonce || ""
2048
2057
  }
2049
2058
  ),
2050
- (a = D(e.content)) == null ? void 0 : a.map((o) => /* @__PURE__ */ y(
2051
- te,
2059
+ (a = H(e.content)) == null ? void 0 : a.map((o) => /* @__PURE__ */ h(
2060
+ ie,
2052
2061
  {
2053
2062
  apiHost: e.apiHost,
2054
2063
  isNestedRender: e.isNestedRender,
@@ -2075,13 +2084,13 @@ function Ft(e) {
2075
2084
  o.testVariationId
2076
2085
  ))
2077
2086
  ] }) : null,
2078
- /* @__PURE__ */ y(
2079
- te,
2087
+ /* @__PURE__ */ h(
2088
+ ie,
2080
2089
  {
2081
2090
  apiHost: e.apiHost,
2082
2091
  nonce: e.nonce,
2083
2092
  isNestedRender: e.isNestedRender,
2084
- content: d(),
2093
+ content: u(),
2085
2094
  showContent: !0,
2086
2095
  model: e.model,
2087
2096
  data: e.data,
@@ -2103,11 +2112,11 @@ function Ft(e) {
2103
2112
  )
2104
2113
  ] });
2105
2114
  }
2106
- const Ut = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2115
+ const $t = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2107
2116
  __proto__: null,
2108
- default: Ft
2117
+ default: Dt
2109
2118
  }, Symbol.toStringTag, { value: "Module" }));
2110
2119
  export {
2111
- K as InlinedScript,
2112
- Ut as contentVariants
2120
+ J as InlinedScript,
2121
+ $t as contentVariants
2113
2122
  };