@builder.io/sdk-react 4.0.3 → 4.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/browser/blocks-exports.cjs +6 -6
- package/lib/browser/blocks-exports.mjs +18 -11
- package/lib/browser/index.cjs +1 -1
- package/lib/browser/index.mjs +1 -1
- package/lib/browser/{server-entry-e6ae7704.js → server-entry-66a925df.js} +1 -1
- package/lib/browser/{server-entry-c40e781d.cjs → server-entry-e6bf2d7b.cjs} +1 -1
- package/lib/browser/server-entry.cjs +1 -1
- package/lib/browser/server-entry.mjs +1 -1
- package/lib/edge/{accordion-8934ef4b.cjs → accordion-7464a303.cjs} +1 -1
- package/lib/edge/{accordion-e657c96d.js → accordion-b4b4d9f1.js} +1 -1
- package/lib/edge/{blocks-a6ffbf92.cjs → blocks-e91ba3d4.cjs} +10 -10
- package/lib/edge/{blocks-513223a7.js → blocks-e93076da.js} +243 -241
- package/lib/edge/blocks-exports.cjs +1 -1
- package/lib/edge/blocks-exports.mjs +2 -2
- package/lib/edge/{button-3522aac2.js → button-33f21c52.js} +2 -2
- package/lib/edge/{button-49563e3b.cjs → button-fda4fec5.cjs} +1 -1
- package/lib/edge/{columns-ea0b3b30.js → columns-55e99fb4.js} +3 -3
- package/lib/edge/{columns-092b6fac.cjs → columns-f7fd551f.cjs} +1 -1
- package/lib/edge/{content-variants-6c1e3b13.js → content-variants-2ebd741d.js} +45 -41
- package/lib/edge/{content-variants-75ff40ca.cjs → content-variants-e6b3bd34.cjs} +1 -1
- package/lib/edge/{custom-code-ae3262be.cjs → custom-code-c66cd781.cjs} +1 -1
- package/lib/edge/{custom-code-1a43bbd7.js → custom-code-d7aa74ff.js} +1 -1
- package/lib/edge/{embed-8d302933.cjs → embed-2c418cac.cjs} +1 -1
- package/lib/edge/{embed-106f0066.js → embed-7384956f.js} +1 -1
- package/lib/edge/{form-0c0d5bf5.js → form-5148ead0.js} +3 -3
- package/lib/edge/{form-46e4d997.cjs → form-61cd3cc1.cjs} +1 -1
- package/lib/edge/{get-class-prop-name-dad1ee7e.cjs → get-class-prop-name-5ff8e9ef.cjs} +1 -1
- package/lib/edge/{get-class-prop-name-e44df0c8.js → get-class-prop-name-f91e4605.js} +1 -1
- package/lib/edge/{image-38917f45.js → image-1729f079.js} +20 -19
- package/lib/edge/{image-590e36ae.cjs → image-a6fbd15b.cjs} +3 -3
- package/lib/edge/{img-8bdeb666.js → img-595b9ae3.js} +1 -1
- package/lib/edge/{img-e49acb58.cjs → img-8770a93f.cjs} +1 -1
- package/lib/edge/index.cjs +1 -1
- package/lib/edge/index.mjs +1 -1
- package/lib/edge/{input-92aaa4f2.cjs → input-10b2e145.cjs} +1 -1
- package/lib/edge/{input-d6338de6.js → input-cab27192.js} +1 -1
- package/lib/edge/{personalization-container-965bec51.cjs → personalization-container-1ba57b3b.cjs} +1 -1
- package/lib/edge/{personalization-container-1307218b.js → personalization-container-9984806a.js} +4 -4
- package/lib/edge/{select-5ce728b4.cjs → select-36b1bb81.cjs} +1 -1
- package/lib/edge/{select-1538b41a.js → select-e1dc1504.js} +1 -1
- package/lib/edge/{server-entry-2e94ad2c.js → server-entry-74debd65.js} +1 -1
- package/lib/edge/{server-entry-46e686b9.cjs → server-entry-f10ae31d.cjs} +1 -1
- package/lib/edge/server-entry.cjs +1 -1
- package/lib/edge/server-entry.mjs +1 -1
- package/lib/edge/{slot-516f176d.js → slot-c6535e6d.js} +3 -3
- package/lib/edge/{slot-3b6aa7ec.cjs → slot-e8473a94.cjs} +1 -1
- package/lib/edge/{symbol-cd10b6f0.cjs → symbol-9177d14c.cjs} +1 -1
- package/lib/edge/{symbol-3b2e7ebf.js → symbol-fc7d42ee.js} +2 -2
- package/lib/edge/{tabs-f0945019.js → tabs-955ab7dd.js} +3 -3
- package/lib/edge/{tabs-cec51291.cjs → tabs-980a2753.cjs} +1 -1
- package/lib/node/blocks-exports.cjs +6 -6
- package/lib/node/blocks-exports.mjs +20 -13
- package/lib/node/index.cjs +1 -1
- package/lib/node/index.mjs +3 -3
- package/lib/node/init.cjs +1 -1
- package/lib/node/init.mjs +3 -3
- package/lib/node/{server-entry-6b05381c.cjs → server-entry-a7413c09.cjs} +1 -1
- package/lib/node/{server-entry-c1000f54.js → server-entry-d38415f3.js} +1 -1
- package/lib/node/server-entry.cjs +1 -1
- package/lib/node/server-entry.mjs +1 -1
- package/lib/node/{setIvm-4ae0308c.cjs → setIvm-0a044ac8.cjs} +1 -1
- package/lib/node/{setIvm-011d6eb2.js → setIvm-9fe8e65a.js} +1 -1
- package/lib/node/setIvm.cjs +1 -1
- package/lib/node/setIvm.mjs +2 -2
- package/lib/node/{should-force-browser-runtime-in-node-5d513614.cjs → should-force-browser-runtime-in-node-e4a9bd6b.cjs} +1 -1
- package/lib/node/{should-force-browser-runtime-in-node-abf8d0a7.js → should-force-browser-runtime-in-node-eb6e6ea4.js} +1 -1
- package/package.json +1 -1
- package/types/blocks/image/image.types.d.ts +1 -0
- package/types/constants/sdk-version.d.ts +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./server-entry-
|
|
1
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./server-entry-f10ae31d.cjs"),e=require("react"),r=e.lazy(()=>Promise.resolve().then(()=>require("./button-fda4fec5.cjs"))),n=e.lazy(()=>Promise.resolve().then(()=>require("./columns-f7fd551f.cjs"))),s=e.lazy(()=>Promise.resolve().then(()=>require("./fragment-b6e3a326.cjs"))),i=e.lazy(()=>Promise.resolve().then(()=>require("./image-a6fbd15b.cjs"))),l=e.lazy(()=>Promise.resolve().then(()=>require("./section-d655ea14.cjs"))),c=e.lazy(()=>Promise.resolve().then(()=>require("./symbol-9177d14c.cjs"))),a=e.lazy(()=>Promise.resolve().then(()=>require("./text-e6dbb721.cjs"))),u=e.lazy(()=>Promise.resolve().then(()=>require("./video-cc58dd83.cjs"))),m=e.lazy(()=>Promise.resolve().then(()=>require("./blocks-e91ba3d4.cjs")).then(t=>t.blocks)),y=e.lazy(()=>Promise.resolve().then(()=>require("./content-variants-e6b3bd34.cjs")).then(t=>t.contentVariants)),v=e.createContext({content:null,context:{},localState:void 0,rootSetState(){},rootState:{},apiKey:null,apiVersion:void 0,componentInfos:{},inheritedStyles:{},BlocksWrapper:"div",BlocksWrapperProps:{},nonce:"",model:""});exports.setClientUserAttributes=o.setClientUserAttributes;exports.Blocks=m;exports.BuilderContext=v;exports.Button=r;exports.Columns=n;exports.Content=y;exports.Fragment=s;exports.Image=i;exports.Section=l;exports.Symbol=c;exports.Text=a;exports.Video=u;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { setClientUserAttributes as C } from "./server-entry-
|
|
2
|
+
import { setClientUserAttributes as C } from "./server-entry-74debd65.js";
|
|
3
3
|
import { lazy as t, createContext as e } from "react";
|
|
4
|
-
const s = t(() => import("./button-
|
|
4
|
+
const s = t(() => import("./button-33f21c52.js")), r = t(() => import("./columns-55e99fb4.js")), i = t(() => import("./fragment-1492bc7f.js")), a = t(() => import("./image-1729f079.js")), c = t(() => import("./section-d83e2dd3.js")), m = t(() => import("./symbol-fc7d42ee.js")), l = t(() => import("./text-5915f038.js")), p = t(() => import("./video-52df64e2.js")), u = t(() => import("./blocks-e93076da.js").then((o) => o.blocks)), d = t(() => import("./content-variants-2ebd741d.js").then((o) => o.contentVariants)), x = e({
|
|
5
5
|
content: null,
|
|
6
6
|
context: {},
|
|
7
7
|
localState: void 0,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import { DynamicRenderer as r } from "./dynamic-renderer-8b343325.js";
|
|
3
|
-
import { getClassPropName as n } from "./get-class-prop-name-
|
|
4
|
-
import "./server-entry-
|
|
3
|
+
import { getClassPropName as n } from "./get-class-prop-name-f91e4605.js";
|
|
4
|
+
import "./server-entry-74debd65.js";
|
|
5
5
|
function b(t) {
|
|
6
6
|
function e() {
|
|
7
7
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime"),r=require("./dynamic-renderer-b29b45ca.cjs"),t=require("./get-class-prop-name-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime"),r=require("./dynamic-renderer-b29b45ca.cjs"),t=require("./get-class-prop-name-5ff8e9ef.cjs");require("./server-entry-f10ae31d.cjs");function u(e){function n(){return{...e.attributes,[t.getClassPropName()]:`${e.link?"":"builder-button"} ${e.attributes[t.getClassPropName()]||""}`,...e.link?{href:e.link,target:e.openLinkInNewTab?"_blank":void 0,role:"link"}:{role:"button"}}}return i.jsx(r.DynamicRenderer,{attributes:n(),TagName:e.link?e.builderLinkComponent||"a":"button",actionAttributes:{},children:e.text})}exports.default=u;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsxs as h, Fragment as $, jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { InlinedStyles as B, Blocks as L, mapStyleObjToStrIfNeeded as W, getSizesForBreakpoints as z } from "./blocks-
|
|
2
|
+
import { InlinedStyles as B, Blocks as L, mapStyleObjToStrIfNeeded as W, getSizesForBreakpoints as z } from "./blocks-e93076da.js";
|
|
3
3
|
import { DynamicRenderer as A } from "./dynamic-renderer-8b343325.js";
|
|
4
|
-
import { getClassPropName as N } from "./get-class-prop-name-
|
|
4
|
+
import { getClassPropName as N } from "./get-class-prop-name-f91e4605.js";
|
|
5
5
|
import "react";
|
|
6
6
|
import "./blocks-exports.mjs";
|
|
7
|
-
import "./server-entry-
|
|
7
|
+
import "./server-entry-74debd65.js";
|
|
8
8
|
const D = (e) => `builder-columns ${e}-breakpoints`;
|
|
9
9
|
function O(e) {
|
|
10
10
|
var f, b;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),o=require("./blocks-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),o=require("./blocks-e91ba3d4.cjs"),j=require("./dynamic-renderer-b29b45ca.cjs"),B=require("./get-class-prop-name-5ff8e9ef.cjs");require("react");require("./blocks-exports.cjs");require("./server-entry-f10ae31d.cjs");const q=t=>`builder-columns ${t}-breakpoints`;function p(t){var f,k;function c(){return typeof t.space=="number"?t.space||0:20}function s(){return t.columns||[]}function u(){return t.stackColumnsAt||"tablet"}function y(e){return e.link?t.builderLinkComponent||"a":"div"}function x(e){var n;return((n=s()[e])==null?void 0:n.width)||100/s().length}function S(e){const n=x(e),i=c()*(s().length-1)*(n/100);return`calc(${n}% - ${i}px)`}function a({stackedStyle:e,desktopStyle:n}){return u()==="tablet"?e:n}function d({stackedStyle:e,desktopStyle:n}){return u()==="never"?n:e}function m(){return t.stackColumnsAt==="never"?"row":t.reverseColumnsWhenStacked?"column-reverse":"column"}function C(){return{"--flex-dir":m(),"--flex-dir-tablet":a({stackedStyle:m(),desktopStyle:"row"})}}function v(e){const n=e===0?0:c(),i=S(e),r=`${n}px`,g="100%",h=0;return{...{display:"flex",flexDirection:"column",alignItems:"stretch"},width:i,["marginLeft"]:r,"--column-width-mobile":d({stackedStyle:g,desktopStyle:i}),"--column-margin-left-mobile":d({stackedStyle:h,desktopStyle:r}),"--column-width-tablet":a({stackedStyle:g,desktopStyle:i}),"--column-margin-left-tablet":a({stackedStyle:h,desktopStyle:r})}}function b(e){var i,r;return o.getSizesForBreakpoints(((r=(i=t.builderContext.content)==null?void 0:i.meta)==null?void 0:r.breakpoints)||{})[e].max}function w(){const e=`.${t.builderBlock.id}-breakpoints > .builder-column`;return`
|
|
2
2
|
@media (max-width: ${b("medium")}px) {
|
|
3
3
|
.${t.builderBlock.id}-breakpoints {
|
|
4
4
|
flex-direction: var(--flex-dir-tablet);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsx as h, jsxs as O, Fragment as Q } from "react/jsx-runtime";
|
|
2
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
|
|
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 ge, _track as X, fetchOneEntry as fe, createEditorListener as he, logFetch as be, serializeIncludingFunctions as Z, logger as ye, handleABTestingSync as xe } from "./server-entry-74debd65.js";
|
|
4
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-
|
|
5
|
+
import { triggerAnimation as Ee, evaluate as re, fastClone as Fe, InlinedStyles as le, ComponentsContext as Pe, Blocks as Ae } from "./blocks-e93076da.js";
|
|
6
6
|
const $ = {
|
|
7
7
|
"@type": "@builder.io/sdk:Element",
|
|
8
8
|
layerName: "Accordion item title",
|
|
@@ -127,7 +127,7 @@ const $ = {
|
|
|
127
127
|
builderComponents: !0,
|
|
128
128
|
builderLinkComponent: !0
|
|
129
129
|
}
|
|
130
|
-
}, Be = y(() => import("./accordion-
|
|
130
|
+
}, Be = y(() => import("./accordion-b4b4d9f1.js")), De = {
|
|
131
131
|
name: "Core:Button",
|
|
132
132
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
|
|
133
133
|
defaultStyles: {
|
|
@@ -443,6 +443,10 @@ const $ = {
|
|
|
443
443
|
name: "altText",
|
|
444
444
|
type: "string",
|
|
445
445
|
helperText: "Text to display when the user has images off"
|
|
446
|
+
}, {
|
|
447
|
+
name: "title",
|
|
448
|
+
type: "string",
|
|
449
|
+
helperText: "Text to display when hovering over the asset"
|
|
446
450
|
}, {
|
|
447
451
|
name: "height",
|
|
448
452
|
type: "number",
|
|
@@ -519,7 +523,7 @@ const $ = {
|
|
|
519
523
|
defaultValue: []
|
|
520
524
|
}]
|
|
521
525
|
}]
|
|
522
|
-
}, $e = y(() => import("./personalization-container-
|
|
526
|
+
}, $e = y(() => import("./personalization-container-9984806a.js")), _e = {
|
|
523
527
|
name: "Core:Section",
|
|
524
528
|
static: !0,
|
|
525
529
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
|
|
@@ -575,7 +579,7 @@ const $ = {
|
|
|
575
579
|
builderContext: !0,
|
|
576
580
|
builderComponents: !0
|
|
577
581
|
}
|
|
578
|
-
}, je = y(() => import("./slot-
|
|
582
|
+
}, je = y(() => import("./slot-c6535e6d.js")), Oe = {
|
|
579
583
|
name: "Symbol",
|
|
580
584
|
noWrap: !0,
|
|
581
585
|
static: !0,
|
|
@@ -755,7 +759,7 @@ const $ = {
|
|
|
755
759
|
builderComponents: !0,
|
|
756
760
|
builderLinkComponent: !0
|
|
757
761
|
}
|
|
758
|
-
}, ze = y(() => import("./tabs-
|
|
762
|
+
}, ze = y(() => import("./tabs-955ab7dd.js")), Je = {
|
|
759
763
|
shouldReceiveBuilderProps: {
|
|
760
764
|
builderBlock: !1,
|
|
761
765
|
builderContext: !0
|
|
@@ -799,7 +803,7 @@ const $ = {
|
|
|
799
803
|
helperText: "Only print and run scripts on the client. Important when scripts influence DOM that could be replaced when client loads",
|
|
800
804
|
advanced: !0
|
|
801
805
|
}]
|
|
802
|
-
}, Ge = y(() => import("./custom-code-
|
|
806
|
+
}, Ge = y(() => import("./custom-code-d7aa74ff.js")), Qe = {
|
|
803
807
|
name: "Embed",
|
|
804
808
|
static: !0,
|
|
805
809
|
inputs: [{
|
|
@@ -814,7 +818,7 @@ const $ = {
|
|
|
814
818
|
defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
|
|
815
819
|
hideFromUI: !0
|
|
816
820
|
}]
|
|
817
|
-
}, Xe = y(() => import("./embed-
|
|
821
|
+
}, Xe = y(() => import("./embed-7384956f.js")), Ze = {
|
|
818
822
|
name: "Form:Form",
|
|
819
823
|
// editableTags: ['builder-form-error']
|
|
820
824
|
defaults: {
|
|
@@ -1051,7 +1055,7 @@ const $ = {
|
|
|
1051
1055
|
builderComponents: !0,
|
|
1052
1056
|
builderLinkComponent: !0
|
|
1053
1057
|
}
|
|
1054
|
-
}, et = y(() => import("./form-
|
|
1058
|
+
}, et = y(() => import("./form-5148ead0.js")), tt = {
|
|
1055
1059
|
name: "Form:Input",
|
|
1056
1060
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fad6f37889d9e40bbbbc72cdb5875d6ca",
|
|
1057
1061
|
inputs: [
|
|
@@ -1102,7 +1106,7 @@ const $ = {
|
|
|
1102
1106
|
borderStyle: "solid",
|
|
1103
1107
|
borderColor: "#ccc"
|
|
1104
1108
|
}
|
|
1105
|
-
}, nt = y(() => import("./input-
|
|
1109
|
+
}, nt = y(() => import("./input-cab27192.js")), at = {
|
|
1106
1110
|
name: "Form:Select",
|
|
1107
1111
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F83acca093fb24aaf94dee136e9a4b045",
|
|
1108
1112
|
defaultStyles: {
|
|
@@ -1144,7 +1148,7 @@ const $ = {
|
|
|
1144
1148
|
}],
|
|
1145
1149
|
static: !0,
|
|
1146
1150
|
noWrap: !0
|
|
1147
|
-
}, it = y(() => import("./select-
|
|
1151
|
+
}, it = y(() => import("./select-e1dc1504.js")), ot = {
|
|
1148
1152
|
name: "Form:SubmitButton",
|
|
1149
1153
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fdf2820ffed1f4349a94c40b3221f5b98",
|
|
1150
1154
|
defaultStyles: {
|
|
@@ -1219,7 +1223,7 @@ const $ = {
|
|
|
1219
1223
|
}],
|
|
1220
1224
|
noWrap: !0,
|
|
1221
1225
|
static: !0
|
|
1222
|
-
}, ut = y(() => import("./img-
|
|
1226
|
+
}, ut = y(() => import("./img-595b9ae3.js")), ct = {
|
|
1223
1227
|
name: "Video",
|
|
1224
1228
|
canHaveChildren: !0,
|
|
1225
1229
|
defaultStyles: {
|
|
@@ -1422,7 +1426,7 @@ const $ = {
|
|
|
1422
1426
|
}).join('');
|
|
1423
1427
|
styleEl.innerHTML = newStyleStr;
|
|
1424
1428
|
}
|
|
1425
|
-
}`,
|
|
1429
|
+
}`, gt = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
|
|
1426
1430
|
if (!navigator.cookieEnabled) {
|
|
1427
1431
|
return;
|
|
1428
1432
|
}
|
|
@@ -1460,12 +1464,12 @@ const $ = {
|
|
|
1460
1464
|
...t,
|
|
1461
1465
|
testVariationId: t.id,
|
|
1462
1466
|
id: e == null ? void 0 : e.id
|
|
1463
|
-
})),
|
|
1467
|
+
})), ft = ({
|
|
1464
1468
|
canTrack: e,
|
|
1465
1469
|
content: t
|
|
1466
1470
|
}) => !(!(H(t).length > 0) || !e || z()), ht = (e) => e === "react" || e === "reactNative", bt = N === "angular", ue = ht(N), yt = () => `
|
|
1467
1471
|
window.${se} = ${pt}
|
|
1468
|
-
window.${de} = ${
|
|
1472
|
+
window.${de} = ${gt}
|
|
1469
1473
|
`, xt = (e, t) => `
|
|
1470
1474
|
window.${se}(
|
|
1471
1475
|
"${t}",${JSON.stringify(e)}, ${ue}, ${bt}
|
|
@@ -1580,7 +1584,7 @@ font-weight: ${o};
|
|
|
1580
1584
|
}
|
|
1581
1585
|
`, Et = (e) => e ? "" : Rt, Ft = (e) => `variant-${e}`;
|
|
1582
1586
|
function Pt(e) {
|
|
1583
|
-
var
|
|
1587
|
+
var g, b, w;
|
|
1584
1588
|
const t = M(null);
|
|
1585
1589
|
T(() => !1);
|
|
1586
1590
|
function n(l) {
|
|
@@ -1676,9 +1680,9 @@ function Pt(e) {
|
|
|
1676
1680
|
x[d] = !0;
|
|
1677
1681
|
const I = V.replace(
|
|
1678
1682
|
/{{([^}]+)}}/g,
|
|
1679
|
-
(S,
|
|
1683
|
+
(S, f) => String(
|
|
1680
1684
|
re({
|
|
1681
|
-
code:
|
|
1685
|
+
code: f,
|
|
1682
1686
|
context: e.context || {},
|
|
1683
1687
|
localState: void 0,
|
|
1684
1688
|
rootState: e.builderContextSignal.rootState,
|
|
@@ -1730,36 +1734,36 @@ function Pt(e) {
|
|
|
1730
1734
|
apiKey: e.apiKey
|
|
1731
1735
|
}), Object.values(
|
|
1732
1736
|
e.builderContextSignal.componentInfos
|
|
1733
|
-
).forEach((
|
|
1737
|
+
).forEach((f) => {
|
|
1734
1738
|
var k, U;
|
|
1735
|
-
if (!((k =
|
|
1736
|
-
const q = pe(
|
|
1739
|
+
if (!((k = f.models) != null && k.length) || f.models.includes(e.model)) {
|
|
1740
|
+
const q = pe(f);
|
|
1737
1741
|
(U = window.parent) == null || U.postMessage(q, "*");
|
|
1738
1742
|
}
|
|
1739
1743
|
}), window.addEventListener(
|
|
1740
1744
|
"builder:component:stateChangeListenerActivated",
|
|
1741
1745
|
R
|
|
1742
1746
|
));
|
|
1743
|
-
const V = e.builderContextSignal.content && L(e.canTrack), I =
|
|
1747
|
+
const V = e.builderContextSignal.content && L(e.canTrack), I = ge({
|
|
1744
1748
|
name: `builder.tests.${(s = e.builderContextSignal.content) == null ? void 0 : s.id}`,
|
|
1745
1749
|
canTrack: !0
|
|
1746
1750
|
}), S = (m = e.builderContextSignal.content) == null ? void 0 : m.testVariationId;
|
|
1747
1751
|
if (V && S === I) {
|
|
1748
|
-
const
|
|
1752
|
+
const f = (p = e.builderContextSignal.content) == null ? void 0 : p.id, k = e.apiKey;
|
|
1749
1753
|
X({
|
|
1750
1754
|
apiHost: e.apiHost,
|
|
1751
1755
|
type: "impression",
|
|
1752
1756
|
canTrack: !0,
|
|
1753
|
-
contentId:
|
|
1757
|
+
contentId: f,
|
|
1754
1758
|
apiKey: k,
|
|
1755
|
-
variationId: I !==
|
|
1759
|
+
variationId: I !== f ? I : void 0
|
|
1756
1760
|
});
|
|
1757
1761
|
}
|
|
1758
1762
|
if (oe() && !A()) {
|
|
1759
|
-
const
|
|
1763
|
+
const f = new URL(location.href).searchParams, k = f.get("builder.preview"), U = f.get(
|
|
1760
1764
|
`builder.overrides.${k}`
|
|
1761
|
-
), q =
|
|
1762
|
-
(k === "BUILDER_STUDIO" || k === e.model && q === e.apiKey && (!e.content || U === e.content.id)) &&
|
|
1765
|
+
), q = f.get("apiKey") || f.get("builder.space");
|
|
1766
|
+
(k === "BUILDER_STUDIO" || k === e.model && q === e.apiKey && (!e.content || U === e.content.id)) && fe({
|
|
1763
1767
|
model: e.model,
|
|
1764
1768
|
apiKey: e.apiKey,
|
|
1765
1769
|
apiVersion: e.builderContextSignal.apiVersion,
|
|
@@ -1793,7 +1797,7 @@ function Pt(e) {
|
|
|
1793
1797
|
{
|
|
1794
1798
|
ref: t,
|
|
1795
1799
|
onClick: (l) => B(l),
|
|
1796
|
-
"builder-content-id": (
|
|
1800
|
+
"builder-content-id": (g = e.builderContextSignal.content) == null ? void 0 : g.id,
|
|
1797
1801
|
"builder-model": e.model,
|
|
1798
1802
|
className: Ft(
|
|
1799
1803
|
((b = e.content) == null ? void 0 : b.testVariationId) || ((w = e.content) == null ? void 0 : w.id)
|
|
@@ -1861,19 +1865,19 @@ function ie(e) {
|
|
|
1861
1865
|
var v, x, F, C, W, B, D, R, P;
|
|
1862
1866
|
const [t, n] = T(
|
|
1863
1867
|
() => {
|
|
1864
|
-
var
|
|
1868
|
+
var g, b;
|
|
1865
1869
|
return vt({
|
|
1866
1870
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
1867
|
-
variationId: (
|
|
1871
|
+
variationId: (g = e.content) == null ? void 0 : g.testVariationId,
|
|
1868
1872
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
1869
1873
|
contentId: (b = e.content) == null ? void 0 : b.id
|
|
1870
1874
|
});
|
|
1871
1875
|
}
|
|
1872
1876
|
);
|
|
1873
|
-
function i(
|
|
1877
|
+
function i(g) {
|
|
1874
1878
|
o((b) => ({
|
|
1875
1879
|
...b,
|
|
1876
|
-
rootState:
|
|
1880
|
+
rootState: g
|
|
1877
1881
|
}));
|
|
1878
1882
|
}
|
|
1879
1883
|
const [r, u] = T(
|
|
@@ -1881,8 +1885,8 @@ function ie(e) {
|
|
|
1881
1885
|
...ee(),
|
|
1882
1886
|
...e.customComponents || []
|
|
1883
1887
|
].reduce(
|
|
1884
|
-
(
|
|
1885
|
-
...
|
|
1888
|
+
(g, { component: b, ...w }) => ({
|
|
1889
|
+
...g,
|
|
1886
1890
|
[w.name]: {
|
|
1887
1891
|
component: b,
|
|
1888
1892
|
...Z(w)
|
|
@@ -1910,8 +1914,8 @@ function ie(e) {
|
|
|
1910
1914
|
...ee(),
|
|
1911
1915
|
...e.customComponents || []
|
|
1912
1916
|
].reduce(
|
|
1913
|
-
(
|
|
1914
|
-
...
|
|
1917
|
+
(g, { component: b, ...w }) => ({
|
|
1918
|
+
...g,
|
|
1915
1919
|
[w.name]: Z(w)
|
|
1916
1920
|
}),
|
|
1917
1921
|
{}
|
|
@@ -1926,9 +1930,9 @@ function ie(e) {
|
|
|
1926
1930
|
e.apiKey || ye.error(
|
|
1927
1931
|
"No API key provided to `Content` component. This can cause issues. Please provide an API key using the `apiKey` prop."
|
|
1928
1932
|
);
|
|
1929
|
-
const
|
|
1930
|
-
|
|
1931
|
-
code:
|
|
1933
|
+
const g = (x = (v = a.content) == null ? void 0 : v.data) == null ? void 0 : x.jsCode;
|
|
1934
|
+
g && re({
|
|
1935
|
+
code: g,
|
|
1932
1936
|
context: e.context || {},
|
|
1933
1937
|
localState: void 0,
|
|
1934
1938
|
rootState: a.rootState,
|
|
@@ -2001,7 +2005,7 @@ function ie(e) {
|
|
|
2001
2005
|
function Dt(e) {
|
|
2002
2006
|
var a;
|
|
2003
2007
|
const [t, n] = T(
|
|
2004
|
-
() =>
|
|
2008
|
+
() => ft({
|
|
2005
2009
|
canTrack: L(e.canTrack),
|
|
2006
2010
|
content: e.content
|
|
2007
2011
|
})
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const f=require("react/jsx-runtime"),o=require("react"),l=require("./server-entry-46e686b9.cjs"),C=require("./blocks-exports.cjs"),R=require("./blocks-a6ffbf92.cjs"),L={"@type":"@builder.io/sdk:Element",layerName:"Accordion item title",responsiveStyles:{large:{marginTop:"10px",position:"relative",display:"flex",alignItems:"stretch",flexDirection:"column",paddingBottom:"10px"}},children:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{textAlign:"left",display:"flex",flexDirection:"column"}},component:{name:"Text",options:{text:"I am an accordion title. Click me!"}}}]},N={"@type":"@builder.io/sdk:Element",layerName:"Accordion item detail",responsiveStyles:{large:{position:"relative",display:"flex",alignItems:"stretch",flexDirection:"column",marginTop:"10px",paddingBottom:"10px"}},children:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{paddingTop:"50px",textAlign:"left",display:"flex",flexDirection:"column",paddingBottom:"50px"}},component:{name:"Text",options:{text:"I am an accordion detail, hello!"}}}]},ee={name:"Builder:Accordion",canHaveChildren:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FagZ9n5CUKRfbL9t6CaJOyVSK4Es2%2Ffab6c1fd3fe542408cbdec078bca7f35",defaultStyles:{display:"flex",flexDirection:"column",alignItems:"stretch"},inputs:[{name:"items",type:"list",broadcast:!0,subFields:[{name:"title",type:"uiBlocks",hideFromUI:!0,defaultValue:[L]},{name:"detail",type:"uiBlocks",hideFromUI:!0,defaultValue:[N]}],defaultValue:[{title:[L],detail:[N]},{title:[L],detail:[N]}],showIf:e=>!e.get("useChildrenForItems")},{name:"oneAtATime",helperText:"Only allow opening one at a time (collapse all others when new item openned)",type:"boolean",defaultValue:!1},{name:"grid",helperText:"Display as a grid",type:"boolean",defaultValue:!1},{name:"gridRowWidth",helperText:"Display as a grid",type:"string",showIf:e=>e.get("grid"),defaultValue:"25%"},{name:"useChildrenForItems",type:"boolean",helperText:"Use child elements for each slide, instead of the array. Useful for dynamically repeating items",advanced:!0,defaultValue:!1,onChange:e=>{e.get("useChildrenForItems")===!0&&e.set("items",[])}}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},te=o.lazy(()=>Promise.resolve().then(()=>require("./accordion-8934ef4b.cjs"))),ne={name:"Core:Button",image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",defaultStyles:{appearance:"none",paddingTop:"15px",paddingBottom:"15px",paddingLeft:"25px",paddingRight:"25px",backgroundColor:"#000000",color:"white",borderRadius:"4px",textAlign:"center",cursor:"pointer"},inputs:[{name:"text",type:"text",defaultValue:"Click me!",bubble:!0},{name:"link",type:"url",bubble:!0},{name:"openLinkInNewTab",type:"boolean",defaultValue:!1,friendlyName:"Open link in new tab"}],static:!0,noWrap:!0,shouldReceiveBuilderProps:{builderLinkComponent:!0}},ae={name:"Columns",isRSC:!0,inputs:[{name:"columns",type:"array",broadcast:!0,subFields:[{name:"blocks",type:"array",hideFromUI:!0,defaultValue:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]},{name:"width",type:"number",hideFromUI:!0,helperText:"Width %, e.g. set to 50 to fill half of the space"},{name:"link",type:"url",helperText:"Optionally set a url that clicking this column will link to"}],defaultValue:[{blocks:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]},{blocks:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]}],onChange:e=>{function t(){n.forEach(i=>{i.delete("width")})}const n=e.get("columns");Array.isArray(n)&&n.find(s=>s.get("width"))&&(n.find(m=>!m.get("width"))||n.reduce((r,p)=>r+p.get("width"),0)!==100)&&t()}},{name:"space",type:"number",defaultValue:20,helperText:"Size of gap between columns",advanced:!0},{name:"stackColumnsAt",type:"string",defaultValue:"tablet",helperText:"Convert horizontal columns to vertical at what device size",enum:["tablet","mobile","never"],advanced:!0},{name:"reverseColumnsWhenStacked",type:"boolean",defaultValue:!1,helperText:"When stacking columns for mobile devices, reverse the ordering",advanced:!0}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},ie={name:"Fragment",static:!0,hidden:!0,canHaveChildren:!0,noWrap:!0},z=["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"],oe=["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"],re={name:"Image",static:!0,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",defaultStyles:{position:"relative",minHeight:"20px",minWidth:"20px",overflow:"hidden"},canHaveChildren:!0,inputs:[{name:"image",type:"file",bubble:!0,allowedFileTypes:z,required:!0,defaultValue:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",onChange:e=>{e.delete("srcset"),e.delete("noWebp");function n(a,r=6e4){return new Promise((p,S)=>{const v=document.createElement("img");let P=!1;v.onload=()=>{P=!0,p(v)},v.addEventListener("error",w=>{console.warn("Image load failed",w.error),S(w.error)}),v.src=a,setTimeout(()=>{P||S(new Error("Image load timed out"))},r)})}function i(a){return Math.round(a*1e3)/1e3}const s=e.get("image"),m=e.get("aspectRatio");if(fetch(s).then(a=>a.blob()).then(a=>{a.type.includes("svg")&&e.set("noWebp",!0)}),s&&(!m||m===.7041))return n(s).then(a=>{const r=e.get("aspectRatio");e.get("image")===s&&(!r||r===.7041)&&a.width&&a.height&&(e.set("aspectRatio",i(a.height/a.width)),e.set("height",a.height),e.set("width",a.width))})}},{name:"backgroundSize",type:"text",defaultValue:"cover",enum:[{label:"contain",value:"contain",helperText:"The image should never get cropped"},{label:"cover",value:"cover",helperText:"The image should fill it's box, cropping when needed"}]},{name:"backgroundPosition",type:"text",defaultValue:"center",enum:["center","top","left","right","bottom","top left","top right","bottom left","bottom right"]},{name:"altText",type:"string",helperText:"Text to display when the user has images off"},{name:"height",type:"number",hideFromUI:!0},{name:"width",type:"number",hideFromUI:!0},{name:"sizes",type:"string",hideFromUI:!0},{name:"srcset",type:"string",hideFromUI:!0},{name:"lazy",type:"boolean",defaultValue:!0,hideFromUI:!0},{name:"fitContent",type:"boolean",helperText:"When child blocks are provided, fit to them instead of using the image's aspect ratio",defaultValue:!0},{name:"highPriority",type:"boolean",advanced:!0,helperText:"Mark this image as high priority compared to other images on the page. This prevents lazy loading of the image and tells the browser to load this image before others on the page."},{name:"aspectRatio",type:"number",helperText:"This is the ratio of height/width, e.g. set to 1.5 for a 300px wide and 200px tall photo. Set to 0 to not force the image to maintain it's aspect ratio",advanced:!0,defaultValue:.7041}],shouldReceiveBuilderProps:{builderBlock:!0}},le={name:"PersonalizationContainer",shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0},noWrap:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F37229ed30d8c41dfb10b8cca1992053a",canHaveChildren:!0,inputs:[{name:"variants",defaultValue:[],behavior:"personalizationVariantList",type:"list",subFields:[{name:"name",type:"text"},{name:"query",friendlyName:"Targeting rules",type:"BuilderQuery",defaultValue:[]},{name:"startDate",type:"date"},{name:"endDate",type:"date"},{name:"blocks",type:"uiBlocks",hideFromUI:!0,defaultValue:[]}]}]},se=o.lazy(()=>Promise.resolve().then(()=>require("./personalization-container-965bec51.cjs"))),de={name:"Core:Section",static:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",inputs:[{name:"maxWidth",type:"number",defaultValue:1200},{name:"lazyLoad",type:"boolean",defaultValue:!1,advanced:!0,description:"Only render this section when in view"}],defaultStyles:{paddingLeft:"20px",paddingRight:"20px",paddingTop:"50px",paddingBottom:"50px",marginTop:"0px",width:"100vw",marginLeft:"calc(50% - 50vw)"},canHaveChildren:!0,defaultChildren:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{textAlign:"center"}},component:{name:"Text",options:{text:"<p><b>I am a section! My content keeps from getting too wide, so that it's easy to read even on big screens.</b></p><p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur</p>"}}}]},ue={name:"Slot",isRSC:!0,description:"Allow child blocks to be inserted into this content when used as a Symbol",docsLink:"https://www.builder.io/c/docs/symbols-with-blocks",image:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F3aad6de36eae43b59b52c85190fdef56",inputs:[{name:"name",type:"string",required:!0,defaultValue:"children"}],shouldReceiveBuilderProps:{builderContext:!0,builderComponents:!0}},ce=o.lazy(()=>Promise.resolve().then(()=>require("./slot-3b6aa7ec.cjs"))),me={name:"Symbol",noWrap:!0,static:!0,isRSC:!0,inputs:[{name:"symbol",type:"uiSymbol"},{name:"dataOnly",helperText:"Make this a data symbol that doesn't display any UI",type:"boolean",defaultValue:!1,advanced:!0,hideFromUI:!0},{name:"inheritState",helperText:"Inherit the parent component state and data",type:"boolean",defaultValue:!1,advanced:!0},{name:"renderToLiquid",helperText:"Render this symbols contents to liquid. Turn off to fetch with javascript and use custom targeting",type:"boolean",defaultValue:!1,advanced:!0,hideFromUI:!0},{name:"useChildren",hideFromUI:!0,type:"boolean"}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},$={"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{paddingLeft:"20px",paddingRight:"20px",paddingTop:"10px",paddingBottom:"10px",minWidth:"100px",textAlign:"center",display:"flex",flexDirection:"column",cursor:"pointer",userSelect:"none"}},component:{name:"Text",options:{text:"New tab"}}},_={"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{height:"200px",display:"flex",marginTop:"20px",flexDirection:"column"}},component:{name:"Text",options:{text:"New tab content "}}},pe={name:"Builder: Tabs",inputs:[{name:"tabs",type:"list",broadcast:!0,subFields:[{name:"label",type:"uiBlocks",hideFromUI:!0,defaultValue:[$]},{name:"content",type:"uiBlocks",hideFromUI:!0,defaultValue:[_]}],defaultValue:[{label:[{...$,component:{name:"Text",options:{text:"Tab 1"}}}],content:[{..._,component:{name:"Text",options:{text:"Tab 1 content"}}}]},{label:[{...$,component:{name:"Text",options:{text:"Tab 2"}}}],content:[{..._,component:{name:"Text",options:{text:"Tab 2 content"}}}]}]},{name:"activeTabStyle",type:"uiStyle",helperText:"CSS styles for the active tab",defaultValue:{backgroundColor:"rgba(0, 0, 0, 0.1)"}},{name:"defaultActiveTab",type:"number",helperText:'Default tab to open to. Set to "1" for the first tab, "2" for the second, or choose "0" for none',defaultValue:1,advanced:!0},{name:"collapsible",type:"boolean",helperText:"If on, clicking an open tab closes it so no tabs are active",defaultValue:!1,advanced:!0},{name:"tabHeaderLayout",type:"enum",helperText:"Change the layout of the tab headers (uses justify-content)",defaultValue:"flex-start",enum:[{label:"Center",value:"center"},{label:"Space between",value:"space-between"},{label:"Space around",value:"space-around"},{label:"Left",value:"flex-start"},{label:"Right",value:"flex-end"}]}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},fe=o.lazy(()=>Promise.resolve().then(()=>require("./tabs-cec51291.cjs"))),ge={shouldReceiveBuilderProps:{builderBlock:!1,builderContext:!0},name:"Text",static:!0,isRSC:!0,image:"https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-text_fields-24px%20(1).svg?alt=media&token=12177b73-0ee3-42ca-98c6-0dd003de1929",inputs:[{name:"text",type:"html",required:!0,autoFocus:!0,bubble:!0,defaultValue:"Enter some text..."}],defaultStyles:{lineHeight:"normal",height:"auto",textAlign:"center"}},he={name:"Custom Code",static:!0,requiredPermissions:["editCode"],inputs:[{name:"code",type:"html",required:!0,defaultValue:"<p>Hello there, I am custom HTML code!</p>",code:!0},{name:"replaceNodes",type:"boolean",helperText:"Preserve server rendered dom nodes",advanced:!0},{name:"scriptsClientOnly",type:"boolean",defaultValue:!1,helperText:"Only print and run scripts on the client. Important when scripts influence DOM that could be replaced when client loads",advanced:!0}]},be=o.lazy(()=>Promise.resolve().then(()=>require("./custom-code-ae3262be.cjs"))),ye={name:"Embed",static:!0,inputs:[{name:"url",type:"url",required:!0,defaultValue:"",helperText:"e.g. enter a youtube url, google map, etc"},{name:"content",type:"html",defaultValue:'<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',hideFromUI:!0}]},xe=o.lazy(()=>Promise.resolve().then(()=>require("./embed-8d302933.cjs"))),ve={name:"Form:Form",defaults:{responsiveStyles:{large:{marginTop:"15px",paddingBottom:"15px"}}},image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fef36d2a846134910b64b88e6d18c5ca5",inputs:[{name:"sendSubmissionsTo",type:"string",enum:[{label:"Send to email",value:"email",helperText:"Send form submissions to the email address of your choosing"},{label:"Custom",value:"custom",helperText:"Handle where the form requests go manually with a little code, e.g. to your own custom backend"}],defaultValue:"email"},{name:"sendSubmissionsToEmail",type:"string",required:!0,defaultValue:"your@email.com",showIf:'options.get("sendSubmissionsTo") === "email"'},{name:"sendWithJs",type:"boolean",helperText:"Set to false to use basic html form action",defaultValue:!0,showIf:'options.get("sendSubmissionsTo") === "custom"'},{name:"name",type:"string",defaultValue:"My form"},{name:"action",type:"string",helperText:"URL to send the form data to",showIf:'options.get("sendSubmissionsTo") === "custom"'},{name:"contentType",type:"string",defaultValue:"application/json",advanced:!0,enum:["application/json","multipart/form-data","application/x-www-form-urlencoded"],showIf:'options.get("sendSubmissionsTo") === "custom" && options.get("sendWithJs") === true'},{name:"method",type:"string",showIf:'options.get("sendSubmissionsTo") === "custom"',defaultValue:"POST",advanced:!0},{name:"previewState",type:"string",enum:["unsubmitted","sending","success","error"],defaultValue:"unsubmitted",helperText:'Choose a state to edit, e.g. choose "success" to show what users see on success and edit the message',showIf:'options.get("sendSubmissionsTo") !== "zapier" && options.get("sendWithJs") === true'},{name:"successUrl",type:"url",helperText:"Optional URL to redirect the user to on form submission success",showIf:'options.get("sendSubmissionsTo") !== "zapier" && options.get("sendWithJs") === true'},{name:"resetFormOnSubmit",type:"boolean",showIf:"options.get('sendSubmissionsTo') === 'custom' && options.get('sendWithJs') === true",advanced:!0},{name:"successMessage",type:"uiBlocks",hideFromUI:!0,defaultValue:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Text",options:{text:"<span>Thanks!</span>"}}}]},{name:"validate",type:"boolean",defaultValue:!0,advanced:!0},{name:"errorMessagePath",type:"text",advanced:!0,helperText:'Path to where to get the error message from in a JSON response to display to the user, e.g. "error.message" for a response like { "error": { "message": "this username is taken" }}'},{name:"errorMessage",type:"uiBlocks",hideFromUI:!0,defaultValue:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},bindings:{"component.options.text":"state.formErrorMessage || block.component.options.text"},component:{name:"Text",options:{text:"<span>Form submission error :( Please check your answers and try again</span>"}}}]},{name:"sendingMessage",type:"uiBlocks",hideFromUI:!0,defaultValue:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Text",options:{text:"<span>Sending...</span>"}}}]},{name:"customHeaders",type:"map",valueType:{type:"string"},advanced:!0,showIf:'options.get("sendSubmissionsTo") === "custom" && options.get("sendWithJs") === true'}],noWrap:!0,canHaveChildren:!0,defaultChildren:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Text",options:{text:"<span>Enter your name</span>"}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Form:Input",options:{name:"name",placeholder:"Jane Doe"}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Text",options:{text:"<span>Enter your email</span>"}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Form:Input",options:{name:"email",placeholder:"jane@doe.com"}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Form:SubmitButton",options:{text:"Submit"}}}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},Se=o.lazy(()=>Promise.resolve().then(()=>require("./form-46e4d997.cjs"))),Te={name:"Form:Input",image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fad6f37889d9e40bbbbc72cdb5875d6ca",inputs:[{name:"type",type:"text",enum:["text","number","email","url","checkbox","radio","range","date","datetime-local","search","tel","time","file","month","week","password","color","hidden"],defaultValue:"text"},{name:"name",type:"string",required:!0,helperText:'Every input in a form needs a unique name describing what it takes, e.g. "email"'},{name:"placeholder",type:"string",defaultValue:"Hello there",helperText:"Text to display when there is no value"},{name:"defaultValue",type:"string"},{name:"value",type:"string",advanced:!0},{name:"required",type:"boolean",helperText:"Is this input required to be filled out to submit a form",defaultValue:!1}],noWrap:!0,static:!0,defaultStyles:{paddingTop:"10px",paddingBottom:"10px",paddingLeft:"10px",paddingRight:"10px",borderRadius:"3px",borderWidth:"1px",borderStyle:"solid",borderColor:"#ccc"}},Ie=o.lazy(()=>Promise.resolve().then(()=>require("./input-92aaa4f2.cjs"))),ke={name:"Form:Select",image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F83acca093fb24aaf94dee136e9a4b045",defaultStyles:{alignSelf:"flex-start"},inputs:[{name:"options",type:"list",required:!0,subFields:[{name:"value",type:"text",required:!0},{name:"name",type:"text"}],defaultValue:[{value:"option 1"},{value:"option 2"}]},{name:"name",type:"string",required:!0,helperText:'Every select in a form needs a unique name describing what it gets, e.g. "email"'},{name:"defaultValue",type:"string"},{name:"value",type:"string",advanced:!0},{name:"required",type:"boolean",defaultValue:!1}],static:!0,noWrap:!0},Ce=o.lazy(()=>Promise.resolve().then(()=>require("./select-5ce728b4.cjs"))),we={name:"Form:SubmitButton",image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fdf2820ffed1f4349a94c40b3221f5b98",defaultStyles:{appearance:"none",paddingTop:"15px",paddingBottom:"15px",paddingLeft:"25px",paddingRight:"25px",backgroundColor:"#3898EC",color:"white",borderRadius:"4px",cursor:"pointer"},inputs:[{name:"text",type:"text",defaultValue:"Click me"}],static:!0,noWrap:!0},Ve=o.lazy(()=>Promise.resolve().then(()=>require("./submit-button-b363e0ed.cjs"))),Ee={name:"Form:TextArea",image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Ff74a2f3de58c4c3e939204e5b6b8f6c3",inputs:[{advanced:!0,name:"value",type:"string"},{name:"name",type:"string",required:!0,helperText:'Every input in a form needs a unique name describing what it gets, e.g. "email"'},{name:"defaultValue",type:"string"},{name:"placeholder",type:"string",defaultValue:"Hello there"},{name:"required",type:"boolean",defaultValue:!1}],defaultStyles:{paddingTop:"10px",paddingBottom:"10px",paddingLeft:"10px",paddingRight:"10px",borderRadius:"3px",borderWidth:"1px",borderStyle:"solid",borderColor:"#ccc"},static:!0,noWrap:!0},Re=o.lazy(()=>Promise.resolve().then(()=>require("./textarea-56a875bc.cjs"))),Fe={name:"Raw:Img",hideFromInsertMenu:!0,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",inputs:[{name:"image",bubble:!0,type:"file",allowedFileTypes:z,required:!0}],noWrap:!0,static:!0},Pe=o.lazy(()=>Promise.resolve().then(()=>require("./img-e49acb58.cjs"))),Ae={name:"Video",canHaveChildren:!0,defaultStyles:{minHeight:"20px",minWidth:"20px"},image:"https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-videocam-24px%20(1).svg?alt=media&token=49a84e4a-b20e-4977-a650-047f986874bb",inputs:[{name:"video",type:"file",allowedFileTypes:oe,bubble:!0,defaultValue:"https://cdn.builder.io/o/assets%2FYJIGb4i01jvw0SRdL5Bt%2Fd27731a526464deba0016216f5f9e570%2Fcompressed?apiKey=YJIGb4i01jvw0SRdL5Bt&token=d27731a526464deba0016216f5f9e570&alt=media&optimized=true",required:!0},{name:"posterImage",type:"file",allowedFileTypes:z,helperText:"Image to show before the video plays"},{name:"autoPlay",type:"boolean",defaultValue:!0},{name:"controls",type:"boolean",defaultValue:!1},{name:"muted",type:"boolean",defaultValue:!0},{name:"loop",type:"boolean",defaultValue:!0},{name:"playsInline",type:"boolean",defaultValue:!0},{name:"fit",type:"text",defaultValue:"cover",enum:["contain","cover","fill","auto"]},{name:"preload",type:"text",defaultValue:"metadata",enum:["auto","metadata","none"]},{name:"fitContent",type:"boolean",helperText:"When child blocks are provided, fit to them instead of using the aspect ratio",defaultValue:!0,advanced:!0},{name:"position",type:"text",defaultValue:"center",enum:["center","top","left","right","bottom","top left","top right","bottom left","bottom right"]},{name:"height",type:"number",advanced:!0},{name:"width",type:"number",advanced:!0},{name:"aspectRatio",type:"number",advanced:!0,defaultValue:.7004048582995948},{name:"lazyLoad",type:"boolean",helperText:'Load this video "lazily" - as in only when a user scrolls near the video. Recommended for optmized performance and bandwidth consumption',defaultValue:!0,advanced:!0}],shouldReceiveBuilderProps:{builderBlock:!0}},We=()=>[{component:be,...he},{component:xe,...ye},{component:Se,...ve},{component:Ie,...Te},{component:Ve,...we},{component:Ce,...ke},{component:Re,...Ee},{component:Pe,...Fe},{component:C.Video,...Ae}],O=()=>[{component:C.Button,...ne},{component:C.Columns,...ae},{component:C.Fragment,...ie},{component:C.Image,...re},{component:C.Section,...de},{component:ce,...ue},{component:C.Symbol,...me},{component:C.Text,...ge},{component:se,...le},{component:fe,...pe},{component:te,...ee},...We()],Be=`function updateCookiesAndStyles(contentId, variants, isHydrationTarget, isAngularSDK) {
|
|
1
|
+
"use strict";const f=require("react/jsx-runtime"),o=require("react"),l=require("./server-entry-f10ae31d.cjs"),C=require("./blocks-exports.cjs"),R=require("./blocks-e91ba3d4.cjs"),L={"@type":"@builder.io/sdk:Element",layerName:"Accordion item title",responsiveStyles:{large:{marginTop:"10px",position:"relative",display:"flex",alignItems:"stretch",flexDirection:"column",paddingBottom:"10px"}},children:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{textAlign:"left",display:"flex",flexDirection:"column"}},component:{name:"Text",options:{text:"I am an accordion title. Click me!"}}}]},N={"@type":"@builder.io/sdk:Element",layerName:"Accordion item detail",responsiveStyles:{large:{position:"relative",display:"flex",alignItems:"stretch",flexDirection:"column",marginTop:"10px",paddingBottom:"10px"}},children:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{paddingTop:"50px",textAlign:"left",display:"flex",flexDirection:"column",paddingBottom:"50px"}},component:{name:"Text",options:{text:"I am an accordion detail, hello!"}}}]},ee={name:"Builder:Accordion",canHaveChildren:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FagZ9n5CUKRfbL9t6CaJOyVSK4Es2%2Ffab6c1fd3fe542408cbdec078bca7f35",defaultStyles:{display:"flex",flexDirection:"column",alignItems:"stretch"},inputs:[{name:"items",type:"list",broadcast:!0,subFields:[{name:"title",type:"uiBlocks",hideFromUI:!0,defaultValue:[L]},{name:"detail",type:"uiBlocks",hideFromUI:!0,defaultValue:[N]}],defaultValue:[{title:[L],detail:[N]},{title:[L],detail:[N]}],showIf:e=>!e.get("useChildrenForItems")},{name:"oneAtATime",helperText:"Only allow opening one at a time (collapse all others when new item openned)",type:"boolean",defaultValue:!1},{name:"grid",helperText:"Display as a grid",type:"boolean",defaultValue:!1},{name:"gridRowWidth",helperText:"Display as a grid",type:"string",showIf:e=>e.get("grid"),defaultValue:"25%"},{name:"useChildrenForItems",type:"boolean",helperText:"Use child elements for each slide, instead of the array. Useful for dynamically repeating items",advanced:!0,defaultValue:!1,onChange:e=>{e.get("useChildrenForItems")===!0&&e.set("items",[])}}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},te=o.lazy(()=>Promise.resolve().then(()=>require("./accordion-7464a303.cjs"))),ne={name:"Core:Button",image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",defaultStyles:{appearance:"none",paddingTop:"15px",paddingBottom:"15px",paddingLeft:"25px",paddingRight:"25px",backgroundColor:"#000000",color:"white",borderRadius:"4px",textAlign:"center",cursor:"pointer"},inputs:[{name:"text",type:"text",defaultValue:"Click me!",bubble:!0},{name:"link",type:"url",bubble:!0},{name:"openLinkInNewTab",type:"boolean",defaultValue:!1,friendlyName:"Open link in new tab"}],static:!0,noWrap:!0,shouldReceiveBuilderProps:{builderLinkComponent:!0}},ae={name:"Columns",isRSC:!0,inputs:[{name:"columns",type:"array",broadcast:!0,subFields:[{name:"blocks",type:"array",hideFromUI:!0,defaultValue:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]},{name:"width",type:"number",hideFromUI:!0,helperText:"Width %, e.g. set to 50 to fill half of the space"},{name:"link",type:"url",helperText:"Optionally set a url that clicking this column will link to"}],defaultValue:[{blocks:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]},{blocks:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]}],onChange:e=>{function t(){n.forEach(i=>{i.delete("width")})}const n=e.get("columns");Array.isArray(n)&&n.find(s=>s.get("width"))&&(n.find(m=>!m.get("width"))||n.reduce((r,p)=>r+p.get("width"),0)!==100)&&t()}},{name:"space",type:"number",defaultValue:20,helperText:"Size of gap between columns",advanced:!0},{name:"stackColumnsAt",type:"string",defaultValue:"tablet",helperText:"Convert horizontal columns to vertical at what device size",enum:["tablet","mobile","never"],advanced:!0},{name:"reverseColumnsWhenStacked",type:"boolean",defaultValue:!1,helperText:"When stacking columns for mobile devices, reverse the ordering",advanced:!0}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},ie={name:"Fragment",static:!0,hidden:!0,canHaveChildren:!0,noWrap:!0},z=["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"],oe=["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"],re={name:"Image",static:!0,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",defaultStyles:{position:"relative",minHeight:"20px",minWidth:"20px",overflow:"hidden"},canHaveChildren:!0,inputs:[{name:"image",type:"file",bubble:!0,allowedFileTypes:z,required:!0,defaultValue:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",onChange:e=>{e.delete("srcset"),e.delete("noWebp");function n(a,r=6e4){return new Promise((p,S)=>{const v=document.createElement("img");let P=!1;v.onload=()=>{P=!0,p(v)},v.addEventListener("error",w=>{console.warn("Image load failed",w.error),S(w.error)}),v.src=a,setTimeout(()=>{P||S(new Error("Image load timed out"))},r)})}function i(a){return Math.round(a*1e3)/1e3}const s=e.get("image"),m=e.get("aspectRatio");if(fetch(s).then(a=>a.blob()).then(a=>{a.type.includes("svg")&&e.set("noWebp",!0)}),s&&(!m||m===.7041))return n(s).then(a=>{const r=e.get("aspectRatio");e.get("image")===s&&(!r||r===.7041)&&a.width&&a.height&&(e.set("aspectRatio",i(a.height/a.width)),e.set("height",a.height),e.set("width",a.width))})}},{name:"backgroundSize",type:"text",defaultValue:"cover",enum:[{label:"contain",value:"contain",helperText:"The image should never get cropped"},{label:"cover",value:"cover",helperText:"The image should fill it's box, cropping when needed"}]},{name:"backgroundPosition",type:"text",defaultValue:"center",enum:["center","top","left","right","bottom","top left","top right","bottom left","bottom right"]},{name:"altText",type:"string",helperText:"Text to display when the user has images off"},{name:"title",type:"string",helperText:"Text to display when hovering over the asset"},{name:"height",type:"number",hideFromUI:!0},{name:"width",type:"number",hideFromUI:!0},{name:"sizes",type:"string",hideFromUI:!0},{name:"srcset",type:"string",hideFromUI:!0},{name:"lazy",type:"boolean",defaultValue:!0,hideFromUI:!0},{name:"fitContent",type:"boolean",helperText:"When child blocks are provided, fit to them instead of using the image's aspect ratio",defaultValue:!0},{name:"highPriority",type:"boolean",advanced:!0,helperText:"Mark this image as high priority compared to other images on the page. This prevents lazy loading of the image and tells the browser to load this image before others on the page."},{name:"aspectRatio",type:"number",helperText:"This is the ratio of height/width, e.g. set to 1.5 for a 300px wide and 200px tall photo. Set to 0 to not force the image to maintain it's aspect ratio",advanced:!0,defaultValue:.7041}],shouldReceiveBuilderProps:{builderBlock:!0}},le={name:"PersonalizationContainer",shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0},noWrap:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F37229ed30d8c41dfb10b8cca1992053a",canHaveChildren:!0,inputs:[{name:"variants",defaultValue:[],behavior:"personalizationVariantList",type:"list",subFields:[{name:"name",type:"text"},{name:"query",friendlyName:"Targeting rules",type:"BuilderQuery",defaultValue:[]},{name:"startDate",type:"date"},{name:"endDate",type:"date"},{name:"blocks",type:"uiBlocks",hideFromUI:!0,defaultValue:[]}]}]},se=o.lazy(()=>Promise.resolve().then(()=>require("./personalization-container-1ba57b3b.cjs"))),de={name:"Core:Section",static:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",inputs:[{name:"maxWidth",type:"number",defaultValue:1200},{name:"lazyLoad",type:"boolean",defaultValue:!1,advanced:!0,description:"Only render this section when in view"}],defaultStyles:{paddingLeft:"20px",paddingRight:"20px",paddingTop:"50px",paddingBottom:"50px",marginTop:"0px",width:"100vw",marginLeft:"calc(50% - 50vw)"},canHaveChildren:!0,defaultChildren:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{textAlign:"center"}},component:{name:"Text",options:{text:"<p><b>I am a section! My content keeps from getting too wide, so that it's easy to read even on big screens.</b></p><p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur</p>"}}}]},ue={name:"Slot",isRSC:!0,description:"Allow child blocks to be inserted into this content when used as a Symbol",docsLink:"https://www.builder.io/c/docs/symbols-with-blocks",image:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F3aad6de36eae43b59b52c85190fdef56",inputs:[{name:"name",type:"string",required:!0,defaultValue:"children"}],shouldReceiveBuilderProps:{builderContext:!0,builderComponents:!0}},ce=o.lazy(()=>Promise.resolve().then(()=>require("./slot-e8473a94.cjs"))),me={name:"Symbol",noWrap:!0,static:!0,isRSC:!0,inputs:[{name:"symbol",type:"uiSymbol"},{name:"dataOnly",helperText:"Make this a data symbol that doesn't display any UI",type:"boolean",defaultValue:!1,advanced:!0,hideFromUI:!0},{name:"inheritState",helperText:"Inherit the parent component state and data",type:"boolean",defaultValue:!1,advanced:!0},{name:"renderToLiquid",helperText:"Render this symbols contents to liquid. Turn off to fetch with javascript and use custom targeting",type:"boolean",defaultValue:!1,advanced:!0,hideFromUI:!0},{name:"useChildren",hideFromUI:!0,type:"boolean"}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},$={"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{paddingLeft:"20px",paddingRight:"20px",paddingTop:"10px",paddingBottom:"10px",minWidth:"100px",textAlign:"center",display:"flex",flexDirection:"column",cursor:"pointer",userSelect:"none"}},component:{name:"Text",options:{text:"New tab"}}},_={"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{height:"200px",display:"flex",marginTop:"20px",flexDirection:"column"}},component:{name:"Text",options:{text:"New tab content "}}},pe={name:"Builder: Tabs",inputs:[{name:"tabs",type:"list",broadcast:!0,subFields:[{name:"label",type:"uiBlocks",hideFromUI:!0,defaultValue:[$]},{name:"content",type:"uiBlocks",hideFromUI:!0,defaultValue:[_]}],defaultValue:[{label:[{...$,component:{name:"Text",options:{text:"Tab 1"}}}],content:[{..._,component:{name:"Text",options:{text:"Tab 1 content"}}}]},{label:[{...$,component:{name:"Text",options:{text:"Tab 2"}}}],content:[{..._,component:{name:"Text",options:{text:"Tab 2 content"}}}]}]},{name:"activeTabStyle",type:"uiStyle",helperText:"CSS styles for the active tab",defaultValue:{backgroundColor:"rgba(0, 0, 0, 0.1)"}},{name:"defaultActiveTab",type:"number",helperText:'Default tab to open to. Set to "1" for the first tab, "2" for the second, or choose "0" for none',defaultValue:1,advanced:!0},{name:"collapsible",type:"boolean",helperText:"If on, clicking an open tab closes it so no tabs are active",defaultValue:!1,advanced:!0},{name:"tabHeaderLayout",type:"enum",helperText:"Change the layout of the tab headers (uses justify-content)",defaultValue:"flex-start",enum:[{label:"Center",value:"center"},{label:"Space between",value:"space-between"},{label:"Space around",value:"space-around"},{label:"Left",value:"flex-start"},{label:"Right",value:"flex-end"}]}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},fe=o.lazy(()=>Promise.resolve().then(()=>require("./tabs-980a2753.cjs"))),ge={shouldReceiveBuilderProps:{builderBlock:!1,builderContext:!0},name:"Text",static:!0,isRSC:!0,image:"https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-text_fields-24px%20(1).svg?alt=media&token=12177b73-0ee3-42ca-98c6-0dd003de1929",inputs:[{name:"text",type:"html",required:!0,autoFocus:!0,bubble:!0,defaultValue:"Enter some text..."}],defaultStyles:{lineHeight:"normal",height:"auto",textAlign:"center"}},he={name:"Custom Code",static:!0,requiredPermissions:["editCode"],inputs:[{name:"code",type:"html",required:!0,defaultValue:"<p>Hello there, I am custom HTML code!</p>",code:!0},{name:"replaceNodes",type:"boolean",helperText:"Preserve server rendered dom nodes",advanced:!0},{name:"scriptsClientOnly",type:"boolean",defaultValue:!1,helperText:"Only print and run scripts on the client. Important when scripts influence DOM that could be replaced when client loads",advanced:!0}]},be=o.lazy(()=>Promise.resolve().then(()=>require("./custom-code-c66cd781.cjs"))),ye={name:"Embed",static:!0,inputs:[{name:"url",type:"url",required:!0,defaultValue:"",helperText:"e.g. enter a youtube url, google map, etc"},{name:"content",type:"html",defaultValue:'<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',hideFromUI:!0}]},xe=o.lazy(()=>Promise.resolve().then(()=>require("./embed-2c418cac.cjs"))),ve={name:"Form:Form",defaults:{responsiveStyles:{large:{marginTop:"15px",paddingBottom:"15px"}}},image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fef36d2a846134910b64b88e6d18c5ca5",inputs:[{name:"sendSubmissionsTo",type:"string",enum:[{label:"Send to email",value:"email",helperText:"Send form submissions to the email address of your choosing"},{label:"Custom",value:"custom",helperText:"Handle where the form requests go manually with a little code, e.g. to your own custom backend"}],defaultValue:"email"},{name:"sendSubmissionsToEmail",type:"string",required:!0,defaultValue:"your@email.com",showIf:'options.get("sendSubmissionsTo") === "email"'},{name:"sendWithJs",type:"boolean",helperText:"Set to false to use basic html form action",defaultValue:!0,showIf:'options.get("sendSubmissionsTo") === "custom"'},{name:"name",type:"string",defaultValue:"My form"},{name:"action",type:"string",helperText:"URL to send the form data to",showIf:'options.get("sendSubmissionsTo") === "custom"'},{name:"contentType",type:"string",defaultValue:"application/json",advanced:!0,enum:["application/json","multipart/form-data","application/x-www-form-urlencoded"],showIf:'options.get("sendSubmissionsTo") === "custom" && options.get("sendWithJs") === true'},{name:"method",type:"string",showIf:'options.get("sendSubmissionsTo") === "custom"',defaultValue:"POST",advanced:!0},{name:"previewState",type:"string",enum:["unsubmitted","sending","success","error"],defaultValue:"unsubmitted",helperText:'Choose a state to edit, e.g. choose "success" to show what users see on success and edit the message',showIf:'options.get("sendSubmissionsTo") !== "zapier" && options.get("sendWithJs") === true'},{name:"successUrl",type:"url",helperText:"Optional URL to redirect the user to on form submission success",showIf:'options.get("sendSubmissionsTo") !== "zapier" && options.get("sendWithJs") === true'},{name:"resetFormOnSubmit",type:"boolean",showIf:"options.get('sendSubmissionsTo') === 'custom' && options.get('sendWithJs') === true",advanced:!0},{name:"successMessage",type:"uiBlocks",hideFromUI:!0,defaultValue:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Text",options:{text:"<span>Thanks!</span>"}}}]},{name:"validate",type:"boolean",defaultValue:!0,advanced:!0},{name:"errorMessagePath",type:"text",advanced:!0,helperText:'Path to where to get the error message from in a JSON response to display to the user, e.g. "error.message" for a response like { "error": { "message": "this username is taken" }}'},{name:"errorMessage",type:"uiBlocks",hideFromUI:!0,defaultValue:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},bindings:{"component.options.text":"state.formErrorMessage || block.component.options.text"},component:{name:"Text",options:{text:"<span>Form submission error :( Please check your answers and try again</span>"}}}]},{name:"sendingMessage",type:"uiBlocks",hideFromUI:!0,defaultValue:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Text",options:{text:"<span>Sending...</span>"}}}]},{name:"customHeaders",type:"map",valueType:{type:"string"},advanced:!0,showIf:'options.get("sendSubmissionsTo") === "custom" && options.get("sendWithJs") === true'}],noWrap:!0,canHaveChildren:!0,defaultChildren:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Text",options:{text:"<span>Enter your name</span>"}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Form:Input",options:{name:"name",placeholder:"Jane Doe"}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Text",options:{text:"<span>Enter your email</span>"}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Form:Input",options:{name:"email",placeholder:"jane@doe.com"}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{marginTop:"10px"}},component:{name:"Form:SubmitButton",options:{text:"Submit"}}}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},Se=o.lazy(()=>Promise.resolve().then(()=>require("./form-61cd3cc1.cjs"))),Te={name:"Form:Input",image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fad6f37889d9e40bbbbc72cdb5875d6ca",inputs:[{name:"type",type:"text",enum:["text","number","email","url","checkbox","radio","range","date","datetime-local","search","tel","time","file","month","week","password","color","hidden"],defaultValue:"text"},{name:"name",type:"string",required:!0,helperText:'Every input in a form needs a unique name describing what it takes, e.g. "email"'},{name:"placeholder",type:"string",defaultValue:"Hello there",helperText:"Text to display when there is no value"},{name:"defaultValue",type:"string"},{name:"value",type:"string",advanced:!0},{name:"required",type:"boolean",helperText:"Is this input required to be filled out to submit a form",defaultValue:!1}],noWrap:!0,static:!0,defaultStyles:{paddingTop:"10px",paddingBottom:"10px",paddingLeft:"10px",paddingRight:"10px",borderRadius:"3px",borderWidth:"1px",borderStyle:"solid",borderColor:"#ccc"}},Ie=o.lazy(()=>Promise.resolve().then(()=>require("./input-10b2e145.cjs"))),ke={name:"Form:Select",image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F83acca093fb24aaf94dee136e9a4b045",defaultStyles:{alignSelf:"flex-start"},inputs:[{name:"options",type:"list",required:!0,subFields:[{name:"value",type:"text",required:!0},{name:"name",type:"text"}],defaultValue:[{value:"option 1"},{value:"option 2"}]},{name:"name",type:"string",required:!0,helperText:'Every select in a form needs a unique name describing what it gets, e.g. "email"'},{name:"defaultValue",type:"string"},{name:"value",type:"string",advanced:!0},{name:"required",type:"boolean",defaultValue:!1}],static:!0,noWrap:!0},Ce=o.lazy(()=>Promise.resolve().then(()=>require("./select-36b1bb81.cjs"))),we={name:"Form:SubmitButton",image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fdf2820ffed1f4349a94c40b3221f5b98",defaultStyles:{appearance:"none",paddingTop:"15px",paddingBottom:"15px",paddingLeft:"25px",paddingRight:"25px",backgroundColor:"#3898EC",color:"white",borderRadius:"4px",cursor:"pointer"},inputs:[{name:"text",type:"text",defaultValue:"Click me"}],static:!0,noWrap:!0},Ve=o.lazy(()=>Promise.resolve().then(()=>require("./submit-button-b363e0ed.cjs"))),Ee={name:"Form:TextArea",image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Ff74a2f3de58c4c3e939204e5b6b8f6c3",inputs:[{advanced:!0,name:"value",type:"string"},{name:"name",type:"string",required:!0,helperText:'Every input in a form needs a unique name describing what it gets, e.g. "email"'},{name:"defaultValue",type:"string"},{name:"placeholder",type:"string",defaultValue:"Hello there"},{name:"required",type:"boolean",defaultValue:!1}],defaultStyles:{paddingTop:"10px",paddingBottom:"10px",paddingLeft:"10px",paddingRight:"10px",borderRadius:"3px",borderWidth:"1px",borderStyle:"solid",borderColor:"#ccc"},static:!0,noWrap:!0},Re=o.lazy(()=>Promise.resolve().then(()=>require("./textarea-56a875bc.cjs"))),Fe={name:"Raw:Img",hideFromInsertMenu:!0,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",inputs:[{name:"image",bubble:!0,type:"file",allowedFileTypes:z,required:!0}],noWrap:!0,static:!0},Pe=o.lazy(()=>Promise.resolve().then(()=>require("./img-8770a93f.cjs"))),Ae={name:"Video",canHaveChildren:!0,defaultStyles:{minHeight:"20px",minWidth:"20px"},image:"https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-videocam-24px%20(1).svg?alt=media&token=49a84e4a-b20e-4977-a650-047f986874bb",inputs:[{name:"video",type:"file",allowedFileTypes:oe,bubble:!0,defaultValue:"https://cdn.builder.io/o/assets%2FYJIGb4i01jvw0SRdL5Bt%2Fd27731a526464deba0016216f5f9e570%2Fcompressed?apiKey=YJIGb4i01jvw0SRdL5Bt&token=d27731a526464deba0016216f5f9e570&alt=media&optimized=true",required:!0},{name:"posterImage",type:"file",allowedFileTypes:z,helperText:"Image to show before the video plays"},{name:"autoPlay",type:"boolean",defaultValue:!0},{name:"controls",type:"boolean",defaultValue:!1},{name:"muted",type:"boolean",defaultValue:!0},{name:"loop",type:"boolean",defaultValue:!0},{name:"playsInline",type:"boolean",defaultValue:!0},{name:"fit",type:"text",defaultValue:"cover",enum:["contain","cover","fill","auto"]},{name:"preload",type:"text",defaultValue:"metadata",enum:["auto","metadata","none"]},{name:"fitContent",type:"boolean",helperText:"When child blocks are provided, fit to them instead of using the aspect ratio",defaultValue:!0,advanced:!0},{name:"position",type:"text",defaultValue:"center",enum:["center","top","left","right","bottom","top left","top right","bottom left","bottom right"]},{name:"height",type:"number",advanced:!0},{name:"width",type:"number",advanced:!0},{name:"aspectRatio",type:"number",advanced:!0,defaultValue:.7004048582995948},{name:"lazyLoad",type:"boolean",helperText:'Load this video "lazily" - as in only when a user scrolls near the video. Recommended for optmized performance and bandwidth consumption',defaultValue:!0,advanced:!0}],shouldReceiveBuilderProps:{builderBlock:!0}},We=()=>[{component:be,...he},{component:xe,...ye},{component:Se,...ve},{component:Ie,...Te},{component:Ve,...we},{component:Ce,...ke},{component:Re,...Ee},{component:Pe,...Fe},{component:C.Video,...Ae}],O=()=>[{component:C.Button,...ne},{component:C.Columns,...ae},{component:C.Fragment,...ie},{component:C.Image,...re},{component:C.Section,...de},{component:ce,...ue},{component:C.Symbol,...me},{component:C.Text,...ge},{component:se,...le},{component:fe,...pe},{component:te,...ee},...We()],Be=`function updateCookiesAndStyles(contentId, variants, isHydrationTarget, isAngularSDK) {
|
|
2
2
|
function getAndSetVariantId() {
|
|
3
3
|
function setCookie(name, value, days) {
|
|
4
4
|
let expires = '';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("react/jsx-runtime"),n=require("react"),l=require("./server-entry-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("react/jsx-runtime"),n=require("react"),l=require("./server-entry-f10ae31d.cjs");function f(c){const r=n.useRef(null),[i,m]=n.useState(()=>[]),[u,g]=n.useState(()=>[]);function o(){var d;if(!r.current||!((d=r.current)!=null&&d.getElementsByTagName)||typeof window=="undefined")return;const a=r.current.getElementsByTagName("script");for(let s=0;s<a.length;s++){const e=a[s];if(e.src){if(i.includes(e.src))continue;i.push(e.src);const t=document.createElement("script");t.async=!0,t.src=e.src,document.head.appendChild(t)}else if(!e.type||["text/javascript","application/javascript","application/ecmascript"].includes(e.type)){if(u.includes(e.innerText))continue;try{u.push(e.innerText),new Function(e.innerText)()}catch(t){l.logger.warn("[BUILDER.IO] `CustomCode`: Error running script:",t)}}}}return n.useEffect(()=>{o()},[]),n.useEffect(()=>{l.isEditing()&&o()},[c.code]),p.jsx("div",{ref:r,className:"builder-custom-code"+(c.replaceNodes?" replace-nodes":""),dangerouslySetInnerHTML:{__html:c.code}})}exports.default=f;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as l } from "react/jsx-runtime";
|
|
2
2
|
import { useRef as f, useState as p, useEffect as d } from "react";
|
|
3
|
-
import { isEditing as m, logger as g } from "./server-entry-
|
|
3
|
+
import { isEditing as m, logger as g } from "./server-entry-74debd65.js";
|
|
4
4
|
function T(r) {
|
|
5
5
|
const n = f(null), [s, y] = p(() => []), [i, h] = p(() => []);
|
|
6
6
|
function o() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("react/jsx-runtime"),r=require("react"),m=require("./server-entry-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("react/jsx-runtime"),r=require("react"),m=require("./server-entry-f10ae31d.cjs"),f=["text/javascript","application/javascript","application/ecmascript"],S=s=>f.includes(s.type);function g(s){const t=r.useRef(null),[i,E]=r.useState(()=>[]),[u,y]=r.useState(()=>[]),[a,l]=r.useState(()=>!1);function p(){if(!t.current||!t.current.getElementsByTagName)return;const o=t.current.getElementsByTagName("script");for(let c=0;c<o.length;c++){const e=o[c];if(e.src&&!i.includes(e.src)){i.push(e.src);const n=document.createElement("script");n.async=!0,n.src=e.src,document.head.appendChild(n)}else if(S(e)&&!u.includes(e.innerText))try{u.push(e.innerText),new Function(e.innerText)()}catch(n){m.logger.warn("[BUILDER.IO] `Embed`: Error running script:",n)}}}return r.useEffect(()=>{t.current&&!a&&(l(!0),p())},[t.current,a]),d.jsx("div",{className:"builder-embed",ref:t,dangerouslySetInnerHTML:{__html:s.content}})}exports.default=g;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as m } from "react/jsx-runtime";
|
|
2
2
|
import { useRef as d, useState as c, useEffect as f } from "react";
|
|
3
|
-
import { logger as E } from "./server-entry-
|
|
3
|
+
import { logger as E } from "./server-entry-74debd65.js";
|
|
4
4
|
const g = ["text/javascript", "application/javascript", "application/ecmascript"], I = (r) => g.includes(r.type);
|
|
5
5
|
function y(r) {
|
|
6
6
|
const e = d(null), [i, S] = c(() => []), [u, T] = c(() => []), [o, p] = c(() => !1);
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { jsxs as k, Fragment as A, jsx as m } from "react/jsx-runtime";
|
|
2
2
|
import { useRef as j, useState as h } from "react";
|
|
3
|
-
import { Blocks as g, set as J, get as O } from "./blocks-
|
|
4
|
-
import { isEditing as U, logFetch as R } from "./server-entry-
|
|
3
|
+
import { Blocks as g, set as J, get as O } from "./blocks-e93076da.js";
|
|
4
|
+
import { isEditing as U, logFetch as R } from "./server-entry-74debd65.js";
|
|
5
5
|
import "./blocks-exports.mjs";
|
|
6
|
-
import "./get-class-prop-name-
|
|
6
|
+
import "./get-class-prop-name-f91e4605.js";
|
|
7
7
|
import "./dynamic-renderer-8b343325.js";
|
|
8
8
|
const $ = ["production", "qa", "test", "development", "dev", "cdn-qa", "cloud", "fast", "cdn2", "cdn-prod"], q = () => {
|
|
9
9
|
const e = process.env.NODE_ENV || "production";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react/jsx-runtime"),h=require("react"),f=require("./blocks-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react/jsx-runtime"),h=require("react"),f=require("./blocks-e91ba3d4.cjs"),j=require("./server-entry-f10ae31d.cjs");require("./blocks-exports.cjs");require("./get-class-prop-name-5ff8e9ef.cjs");require("./dynamic-renderer-b29b45ca.cjs");const P=["production","qa","test","development","dev","cdn-qa","cloud","fast","cdn2","cdn-prod"],D=()=>{const e=process.env.NODE_ENV||"production";return P.includes(e)?e:"production"};function A(e){const s=h.useRef(null),[M,g]=h.useState(()=>"unsubmitted"),[y,S]=h.useState(()=>null),[O,T]=h.useState(()=>"");function q(i){var l,d;const u={...e.builderContext.rootState,...i};e.builderContext.rootSetState?(d=(l=e.builderContext).rootSetState)==null||d.call(l,u):e.builderContext.rootState=u}function m(){return j.isEditing()&&e.previewState||M}function F(i){var l;const u=e.sendWithJs||e.sendSubmissionsTo==="email";if(e.sendSubmissionsTo==="zapier")i.preventDefault();else if(u){if(!(e.action||e.sendSubmissionsTo==="email")){i.preventDefault();return}i.preventDefault();const d=i.currentTarget||i.target,v=e.customHeaders||{};let b;const N=new FormData(d),x=Array.from(d.querySelectorAll("input,select,textarea")).filter(t=>!!t.name).map(t=>{let n;const a=t.name;if(t instanceof HTMLInputElement)if(t.type==="radio"){if(t.checked)return n=t.name,{key:a,value:n}}else if(t.type==="checkbox")n=t.checked;else if(t.type==="number"||t.type==="range"){const r=t.valueAsNumber;isNaN(r)||(n=r)}else t.type==="file"?n=t.files:n=t.value;else n=t.value;return{key:a,value:n}});let c=e.contentType;if(e.sendSubmissionsTo==="email"&&(c="multipart/form-data"),Array.from(x).forEach(({value:t})=>{(t instanceof File||Array.isArray(t)&&t[0]instanceof File||t instanceof FileList)&&(c="multipart/form-data")}),c!=="application/json")b=N;else{const t={};Array.from(x).forEach(({value:n,key:a})=>{f.set(t,a,n)}),b=JSON.stringify(t)}c&&c!=="multipart/form-data"&&(u&&((l=e.action)!=null&&l.includes("zapier.com"))||(v["content-type"]=c));const E=new CustomEvent("presubmit",{detail:{body:b}});if(s.current&&(s.current.dispatchEvent(E),E.defaultPrevented))return;g("sending");const w=`${D()==="dev"?"http://localhost:5000":"https://builder.io"}/api/v1/form-submit?apiKey=${e.builderContext.apiKey}&to=${btoa(e.sendSubmissionsToEmail||"")}&name=${encodeURIComponent(e.name||"")}`,C=e.sendSubmissionsTo==="email"?w:e.action;j.logFetch(C),fetch(C,{body:b,headers:v,method:e.method||"post"}).then(async t=>{let n;const a=t.headers.get("content-type");if(a&&a.indexOf("application/json")!==-1?n=await t.json():n=await t.text(),!t.ok&&e.errorMessagePath){let r=f.get(n,e.errorMessagePath);r&&(typeof r!="string"&&(r=JSON.stringify(r)),T(r),q({formErrorMessage:r}))}if(S(n),g(t.ok?"success":"error"),t.ok){const r=new CustomEvent("submit:success",{detail:{res:t,body:n}});if(s.current){if(s.current.dispatchEvent(r),r.defaultPrevented)return;e.resetFormOnSubmit!==!1&&s.current.reset()}if(e.successUrl)if(s.current){const k=new CustomEvent("route",{detail:{url:e.successUrl}});s.current.dispatchEvent(k),k.defaultPrevented||(location.href=e.successUrl)}else location.href=e.successUrl}},t=>{const n=new CustomEvent("submit:error",{detail:{error:t}});s.current&&(s.current.dispatchEvent(n),n.defaultPrevented)||(S(t),g("error"))})}}return o.jsxs(o.Fragment,{children:[" ",o.jsxs("form",{validate:e.validate,ref:s,action:!e.sendWithJs&&e.action,method:e.method,name:e.name,onSubmit:i=>F(i),...e.attributes,children:[e.children,m()==="error"?o.jsx(f.Blocks,{path:"errorMessage",blocks:e.errorMessage,context:e.builderContext}):null,m()==="sending"?o.jsx(f.Blocks,{path:"sendingMessage",blocks:e.sendingMessage,context:e.builderContext}):null,m()==="error"&&y?o.jsx("pre",{className:"builder-form-error-text pre-7acc3b46",children:JSON.stringify(y,null,2)}):null,m()==="success"?o.jsx(f.Blocks,{path:"successMessage",blocks:e.successMessage,context:e.builderContext}):null]})," ",o.jsx("style",{children:".pre-7acc3b46 { padding: 10px; color: red; text-align: center; }"})," "]})}exports.default=A;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("./server-entry-
|
|
1
|
+
"use strict";const e=require("./server-entry-f10ae31d.cjs"),s=()=>{switch(e.TARGET){case"react":case"reactNative":case"rsc":return"className";case"svelte":case"vue":case"solid":case"qwik":case"angular":return"class"}};exports.getClassPropName=s;
|