@builder.io/sdk-solid 2.0.2 → 2.0.5

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.
@@ -690,6 +690,9 @@ function assign(target, ..._args) {
690
690
  return to;
691
691
  }
692
692
  function bindAnimations(animations) {
693
+ if (TARGET === "reactNative") {
694
+ return;
695
+ }
693
696
  for (const animation of animations) {
694
697
  switch (animation.trigger) {
695
698
  case "pageLoad":
@@ -1630,6 +1633,7 @@ function Columns(props) {
1630
1633
  return breakpointSizes[size].max;
1631
1634
  }
1632
1635
  function columnsStyles() {
1636
+ const childColumnDiv = `.${props.builderBlock.id}-breakpoints > .builder-column`;
1633
1637
  return `
1634
1638
  @media (max-width: ${getWidthForBreakpointSize("medium")}px) {
1635
1639
  .${props.builderBlock.id}-breakpoints {
@@ -1637,7 +1641,7 @@ function Columns(props) {
1637
1641
  align-items: stretch;
1638
1642
  }
1639
1643
 
1640
- .${props.builderBlock.id}-breakpoints > .builder-column {
1644
+ ${childColumnDiv} {
1641
1645
  width: var(--column-width-tablet) !important;
1642
1646
  margin-left: var(--column-margin-left-tablet) !important;
1643
1647
  }
@@ -1649,7 +1653,7 @@ function Columns(props) {
1649
1653
  align-items: stretch;
1650
1654
  }
1651
1655
 
1652
- .${props.builderBlock.id}-breakpoints > .builder-column {
1656
+ ${childColumnDiv} {
1653
1657
  width: var(--column-width-mobile) !important;
1654
1658
  margin-left: var(--column-margin-left-mobile) !important;
1655
1659
  }
@@ -1668,7 +1672,7 @@ function Columns(props) {
1668
1672
  }
1669
1673
  return <>
1670
1674
  <div
1671
- class={getColumnsClass(props.builderBlock?.id) + " div-5b8fb3ac"}
1675
+ class={getColumnsClass(props.builderBlock?.id) + " div-3ff242de"}
1672
1676
  style={columnsCssVars()}
1673
1677
  {...{}}
1674
1678
  >
@@ -1697,7 +1701,7 @@ function Columns(props) {
1697
1701
  /></Dynamic_renderer_default>;
1698
1702
  }}</For4>
1699
1703
  </div>
1700
- <style>{`.div-5b8fb3ac {
1704
+ <style>{`.div-3ff242de {
1701
1705
  display: flex;
1702
1706
  line-height: normal;
1703
1707
  }`}</style>
@@ -1712,7 +1716,7 @@ function FragmentComponent(props) {
1712
1716
  var fragment_default = FragmentComponent;
1713
1717
 
1714
1718
  // src/blocks/image/image.tsx
1715
- import { Show as Show7, createMemo as createMemo8 } from "solid-js";
1719
+ import { Show as Show7, onMount as onMount2, createMemo as createMemo8 } from "solid-js";
1716
1720
 
1717
1721
  // src/blocks/image/image.helpers.ts
1718
1722
  function removeProtocol(path) {
@@ -1801,12 +1805,14 @@ function Image(props) {
1801
1805
  const out = props.aspectRatio ? aspectRatioStyles : void 0;
1802
1806
  return out;
1803
1807
  });
1808
+ onMount2(() => {
1809
+ });
1804
1810
  return <>
1805
1811
  <>
1806
1812
  <picture>
1807
1813
  <Show7 when={webpSrcSet()}><source type="image/webp" srcset={webpSrcSet()} /></Show7>
1808
1814
  <img
1809
- class={"builder-image" + (props.className ? " " + props.className : "") + " img-e3b1053e"}
1815
+ class={"builder-image" + (props.className ? " " + props.className : "") + " img-4512e110"}
1810
1816
  loading={props.highPriority ? "eager" : "lazy"}
1811
1817
  fetchpriority={props.highPriority ? "high" : "auto"}
1812
1818
  alt={props.altText}
@@ -1824,22 +1830,22 @@ function Image(props) {
1824
1830
  <Show7
1825
1831
  when={props.aspectRatio && !(props.builderBlock?.children?.length && props.fitContent)}
1826
1832
  ><div
1827
- class="builder-image-sizer div-e3b1053e"
1833
+ class="builder-image-sizer div-4512e110"
1828
1834
  style={{
1829
1835
  "padding-top": props.aspectRatio * 100 + "%"
1830
1836
  }}
1831
1837
  /></Show7>
1832
1838
  <Show7 when={props.builderBlock?.children?.length && props.fitContent}>{props.children}</Show7>
1833
- <Show7 when={!props.fitContent && props.builderBlock?.children?.length}><div class="div-e3b1053e-2">{props.children}</div></Show7>
1839
+ <Show7 when={!props.fitContent && props.builderBlock?.children?.length}><div class="div-4512e110-2">{props.children}</div></Show7>
1834
1840
  </>
1835
- <style>{`.img-e3b1053e {
1841
+ <style>{`.img-4512e110 {
1836
1842
  opacity: 1;
1837
1843
  transition: opacity 0.2s ease-in-out;
1838
- }.div-e3b1053e {
1844
+ }.div-4512e110 {
1839
1845
  width: 100%;
1840
1846
  pointer-events: none;
1841
1847
  font-size: 0;
1842
- }.div-e3b1053e-2 {
1848
+ }.div-4512e110-2 {
1843
1849
  display: flex;
1844
1850
  flex-direction: column;
1845
1851
  align-items: stretch;
@@ -1875,10 +1881,10 @@ function SectionComponent(props) {
1875
1881
  var section_default = SectionComponent;
1876
1882
 
1877
1883
  // src/blocks/symbol/symbol.tsx
1878
- import { onMount as onMount5, on as on3, createEffect as createEffect3, createMemo as createMemo19, createSignal as createSignal19 } from "solid-js";
1884
+ import { onMount as onMount6, on as on3, createEffect as createEffect3, createMemo as createMemo20, createSignal as createSignal20 } from "solid-js";
1879
1885
 
1880
1886
  // src/components/content-variants/content-variants.tsx
1881
- import { Show as Show14, For as For9, onMount as onMount4, createSignal as createSignal18, createMemo as createMemo18 } from "solid-js";
1887
+ import { Show as Show14, For as For9, onMount as onMount5, createSignal as createSignal19, createMemo as createMemo19 } from "solid-js";
1882
1888
 
1883
1889
  // src/helpers/url.ts
1884
1890
  var getTopLevelDomain = (host) => {
@@ -2072,7 +2078,7 @@ var handleABTesting = async ({
2072
2078
  var getDefaultCanTrack = (canTrack) => checkIsDefined(canTrack) ? canTrack : true;
2073
2079
 
2074
2080
  // src/components/content/content.tsx
2075
- import { Show as Show13, createSignal as createSignal17 } from "solid-js";
2081
+ import { Show as Show13, createSignal as createSignal18 } from "solid-js";
2076
2082
 
2077
2083
  // src/blocks/accordion/component-info.ts
2078
2084
  var defaultTitle = {
@@ -3085,7 +3091,8 @@ var tabs_default = Tabs;
3085
3091
  // src/blocks/text/component-info.ts
3086
3092
  var componentInfo10 = {
3087
3093
  shouldReceiveBuilderProps: {
3088
- builderBlock: TARGET === "reactNative" ? true : false
3094
+ builderBlock: TARGET === "reactNative" ? true : false,
3095
+ builderContext: true
3089
3096
  },
3090
3097
  name: "Text",
3091
3098
  static: true,
@@ -3107,10 +3114,31 @@ var componentInfo10 = {
3107
3114
  };
3108
3115
 
3109
3116
  // src/blocks/text/text.tsx
3117
+ import { createMemo as createMemo11 } from "solid-js";
3110
3118
  function Text(props) {
3119
+ const processedText = createMemo11(() => {
3120
+ const context = props.builderContext;
3121
+ const {
3122
+ context: contextContext,
3123
+ localState,
3124
+ rootState,
3125
+ rootSetState
3126
+ } = context;
3127
+ return String(props.text?.toString() || "").replace(
3128
+ /{{([^}]+)}}/g,
3129
+ (match, group) => evaluate({
3130
+ code: group,
3131
+ context: contextContext,
3132
+ localState,
3133
+ rootState,
3134
+ rootSetState,
3135
+ enableCache: false
3136
+ })
3137
+ );
3138
+ });
3111
3139
  return <><div
3112
3140
  class="builder-text"
3113
- innerHTML={props.text?.toString() || ""}
3141
+ innerHTML={processedText()}
3114
3142
  style={{
3115
3143
  outline: "none"
3116
3144
  }}
@@ -3144,12 +3172,12 @@ var componentInfo11 = {
3144
3172
  };
3145
3173
 
3146
3174
  // src/blocks/custom-code/custom-code.tsx
3147
- import { onMount as onMount2, createSignal as createSignal11 } from "solid-js";
3175
+ import { onMount as onMount3, createSignal as createSignal12 } from "solid-js";
3148
3176
  function CustomCode(props) {
3149
- const [scriptsInserted, setScriptsInserted] = createSignal11([]);
3150
- const [scriptsRun, setScriptsRun] = createSignal11([]);
3177
+ const [scriptsInserted, setScriptsInserted] = createSignal12([]);
3178
+ const [scriptsRun, setScriptsRun] = createSignal12([]);
3151
3179
  let elementRef;
3152
- onMount2(() => {
3180
+ onMount3(() => {
3153
3181
  if (!elementRef?.getElementsByTagName || typeof window === "undefined") {
3154
3182
  return;
3155
3183
  }
@@ -3208,7 +3236,7 @@ var componentInfo12 = {
3208
3236
  };
3209
3237
 
3210
3238
  // src/blocks/embed/embed.tsx
3211
- import { on, createEffect, createMemo as createMemo12, createSignal as createSignal12 } from "solid-js";
3239
+ import { on, createEffect, createMemo as createMemo13, createSignal as createSignal13 } from "solid-js";
3212
3240
 
3213
3241
  // src/blocks/embed/helpers.ts
3214
3242
  var SCRIPT_MIME_TYPES = ["text/javascript", "application/javascript", "application/ecmascript"];
@@ -3216,9 +3244,9 @@ var isJsScript = (script) => SCRIPT_MIME_TYPES.includes(script.type);
3216
3244
 
3217
3245
  // src/blocks/embed/embed.tsx
3218
3246
  function Embed(props) {
3219
- const [scriptsInserted, setScriptsInserted] = createSignal12([]);
3220
- const [scriptsRun, setScriptsRun] = createSignal12([]);
3221
- const [ranInitFn, setRanInitFn] = createSignal12(false);
3247
+ const [scriptsInserted, setScriptsInserted] = createSignal13([]);
3248
+ const [scriptsRun, setScriptsRun] = createSignal13([]);
3249
+ const [ranInitFn, setRanInitFn] = createSignal13(false);
3222
3250
  function findAndRunScripts() {
3223
3251
  if (!elem || !elem.getElementsByTagName)
3224
3252
  return;
@@ -3241,8 +3269,8 @@ function Embed(props) {
3241
3269
  }
3242
3270
  }
3243
3271
  let elem;
3244
- const onUpdateFn_0_elem = createMemo12(() => elem);
3245
- const onUpdateFn_0_ranInitFn__ = createMemo12(() => ranInitFn());
3272
+ const onUpdateFn_0_elem = createMemo13(() => elem);
3273
+ const onUpdateFn_0_ranInitFn__ = createMemo13(() => ranInitFn());
3246
3274
  function onUpdateFn_0() {
3247
3275
  if (elem && !ranInitFn()) {
3248
3276
  setRanInitFn(true);
@@ -3497,7 +3525,7 @@ var componentInfo13 = {
3497
3525
  };
3498
3526
 
3499
3527
  // src/blocks/form/form/form.tsx
3500
- import { Show as Show10, For as For7, createSignal as createSignal13 } from "solid-js";
3528
+ import { Show as Show10, For as For7, createSignal as createSignal14 } from "solid-js";
3501
3529
 
3502
3530
  // src/functions/get-env.ts
3503
3531
  var validEnvList = ["production", "qa", "test", "development", "dev", "cdn-qa", "cloud", "fast", "cdn2", "cdn-prod"];
@@ -3514,9 +3542,9 @@ var get = (obj, path, defaultValue) => {
3514
3542
 
3515
3543
  // src/blocks/form/form/form.tsx
3516
3544
  function FormComponent(props) {
3517
- const [formState, setFormState] = createSignal13("unsubmitted");
3518
- const [responseData, setResponseData] = createSignal13(null);
3519
- const [formErrorMessage, setFormErrorMessage] = createSignal13("");
3545
+ const [formState, setFormState] = createSignal14("unsubmitted");
3546
+ const [responseData, setResponseData] = createSignal14(null);
3547
+ const [formErrorMessage, setFormErrorMessage] = createSignal14("");
3520
3548
  function mergeNewRootState(newData) {
3521
3549
  const combinedState = {
3522
3550
  ...props.builderContext.rootState,
@@ -4089,9 +4117,9 @@ var componentInfo19 = {
4089
4117
  };
4090
4118
 
4091
4119
  // src/blocks/video/video.tsx
4092
- import { Show as Show11, createMemo as createMemo14 } from "solid-js";
4120
+ import { Show as Show11, createMemo as createMemo15 } from "solid-js";
4093
4121
  function Video(props) {
4094
- const videoProps = createMemo14(() => {
4122
+ const videoProps = createMemo15(() => {
4095
4123
  return {
4096
4124
  ...props.autoPlay === true ? {
4097
4125
  autoPlay: true
@@ -4110,7 +4138,7 @@ function Video(props) {
4110
4138
  } : {}
4111
4139
  };
4112
4140
  });
4113
- const spreadProps = createMemo14(() => {
4141
+ const spreadProps = createMemo15(() => {
4114
4142
  return {
4115
4143
  ...videoProps()
4116
4144
  };
@@ -4248,17 +4276,14 @@ var serializeFn = (fnValue) => {
4248
4276
  const appendFunction = !fnStr.startsWith("function") && !fnStr.startsWith("(");
4249
4277
  return `return (${appendFunction ? "function " : ""}${fnStr}).apply(this, arguments)`;
4250
4278
  };
4251
- var serializeValue = (value) => typeof value === "function" ? serializeFn(value) : fastClone(value);
4252
- var serializeComponentInfo = ({
4253
- inputs,
4254
- ...info
4255
- }) => ({
4256
- ...fastClone(info),
4257
- inputs: inputs?.map((input) => Object.entries(input).reduce((acc, [key, value]) => ({
4258
- ...acc,
4259
- [key]: serializeValue(value)
4260
- }), {}))
4261
- });
4279
+ function serializeComponentInfo(info) {
4280
+ return JSON.parse(JSON.stringify(info, (key, value) => {
4281
+ if (typeof value === "function") {
4282
+ return serializeFn(value);
4283
+ }
4284
+ return value;
4285
+ }));
4286
+ }
4262
4287
 
4263
4288
  // src/components/content-variants/inlined-fns.ts
4264
4289
  var UPDATE_COOKIES_AND_STYLES_SCRIPT = "function updateCookiesAndStyles(contentId, variants, isHydrationTarget) {\n function getAndSetVariantId() {\n function setCookie(name, value, days) {\n let expires = '';\n if (days) {\n const date = new Date();\n date.setTime(date.getTime() + days * 24 * 60 * 60 * 1000);\n expires = '; expires=' + date.toUTCString();\n }\n document.cookie = name + '=' + (value || '') + expires + '; path=/' + '; Secure; SameSite=None';\n }\n function getCookie(name) {\n const nameEQ = name + '=';\n const ca = document.cookie.split(';');\n for (let i = 0; i < ca.length; i++) {\n let c = ca[i];\n while (c.charAt(0) === ' ') c = c.substring(1, c.length);\n if (c.indexOf(nameEQ) === 0) return c.substring(nameEQ.length, c.length);\n }\n return null;\n }\n const cookieName = `builder.tests.${contentId}`;\n const variantInCookie = getCookie(cookieName);\n const availableIDs = variants.map(vr => vr.id).concat(contentId);\n if (variantInCookie && availableIDs.includes(variantInCookie)) {\n return variantInCookie;\n }\n let n = 0;\n const random = Math.random();\n for (let i = 0; i < variants.length; i++) {\n const variant = variants[i];\n const testRatio = variant.testRatio;\n n += testRatio;\n if (random < n) {\n setCookie(cookieName, variant.id);\n return variant.id;\n }\n }\n setCookie(cookieName, contentId);\n return contentId;\n }\n const winningVariantId = getAndSetVariantId();\n const styleEl = document.currentScript?.previousElementSibling;\n if (isHydrationTarget) {\n styleEl.remove();\n const thisScriptEl = document.currentScript;\n thisScriptEl?.remove();\n } else {\n const newStyleStr = variants.concat({\n id: contentId\n }).filter(variant => variant.id !== winningVariantId).map(value => {\n return `.variant-${value.id} { display: none; }\n `;\n }).join('');\n styleEl.innerHTML = newStyleStr;\n }\n}";
@@ -4319,11 +4344,11 @@ var Inlined_script_default = InlinedScript;
4319
4344
  // src/components/content/components/enable-editor.tsx
4320
4345
  import {
4321
4346
  Show as Show12,
4322
- onMount as onMount3,
4347
+ onMount as onMount4,
4323
4348
  on as on2,
4324
4349
  createEffect as createEffect2,
4325
- createMemo as createMemo15,
4326
- createSignal as createSignal15
4350
+ createMemo as createMemo16,
4351
+ createSignal as createSignal16
4327
4352
  } from "solid-js";
4328
4353
  import { Dynamic as Dynamic5 } from "solid-js/web";
4329
4354
 
@@ -4821,7 +4846,7 @@ function isFromTrustedHost(trustedHosts, e) {
4821
4846
  }
4822
4847
 
4823
4848
  // src/constants/sdk-version.ts
4824
- var SDK_VERSION = "2.0.2";
4849
+ var SDK_VERSION = "2.0.5";
4825
4850
 
4826
4851
  // src/functions/register.ts
4827
4852
  var registry = {};
@@ -5098,12 +5123,12 @@ var getWrapperClassName = (variationId) => {
5098
5123
 
5099
5124
  // src/components/content/components/enable-editor.tsx
5100
5125
  function EnableEditor(props) {
5101
- const [ContentWrapper, setContentWrapper] = createSignal15(
5126
+ const [ContentWrapper, setContentWrapper] = createSignal16(
5102
5127
  props.contentWrapper || "div"
5103
5128
  );
5104
- const [httpReqsData, setHttpReqsData] = createSignal15({});
5105
- const [httpReqsPending, setHttpReqsPending] = createSignal15({});
5106
- const [clicked, setClicked] = createSignal15(false);
5129
+ const [httpReqsData, setHttpReqsData] = createSignal16({});
5130
+ const [httpReqsPending, setHttpReqsPending] = createSignal16({});
5131
+ const [clicked, setClicked] = createSignal16(false);
5107
5132
  function mergeNewRootState(newData) {
5108
5133
  const combinedState = {
5109
5134
  ...props.builderContextSignal.rootState,
@@ -5137,7 +5162,7 @@ function EnableEditor(props) {
5137
5162
  content: newContentValue
5138
5163
  }));
5139
5164
  }
5140
- const showContentProps = createMemo15(() => {
5165
+ const showContentProps = createMemo16(() => {
5141
5166
  return props.showContent ? {} : {
5142
5167
  hidden: true,
5143
5168
  "aria-hidden": true
@@ -5256,7 +5281,7 @@ function EnableEditor(props) {
5256
5281
  }
5257
5282
  }
5258
5283
  let elementRef;
5259
- onMount3(() => {
5284
+ onMount4(() => {
5260
5285
  if (isBrowser()) {
5261
5286
  if (isEditing()) {
5262
5287
  window.addEventListener("message", processMessage);
@@ -5317,7 +5342,7 @@ function EnableEditor(props) {
5317
5342
  }
5318
5343
  }
5319
5344
  });
5320
- onMount3(() => {
5345
+ onMount4(() => {
5321
5346
  if (!props.apiKey) {
5322
5347
  logger.error(
5323
5348
  "No API key provided to `Content` component. This can cause issues. Please provide an API key using the `apiKey` prop."
@@ -5327,14 +5352,14 @@ function EnableEditor(props) {
5327
5352
  runHttpRequests();
5328
5353
  emitStateUpdate();
5329
5354
  });
5330
- const onUpdateFn_0_props_content = createMemo15(() => props.content);
5355
+ const onUpdateFn_0_props_content = createMemo16(() => props.content);
5331
5356
  function onUpdateFn_0() {
5332
5357
  if (props.content) {
5333
5358
  mergeNewContent(props.content);
5334
5359
  }
5335
5360
  }
5336
5361
  createEffect2(on2(() => [onUpdateFn_0_props_content()], onUpdateFn_0));
5337
- const onUpdateFn_1_props_builderContextSignal_content__data__jsCode = createMemo15(() => props.builderContextSignal.content?.data?.jsCode);
5362
+ const onUpdateFn_1_props_builderContextSignal_content__data__jsCode = createMemo16(() => props.builderContextSignal.content?.data?.jsCode);
5338
5363
  function onUpdateFn_1() {
5339
5364
  evaluateJsCode();
5340
5365
  }
@@ -5344,7 +5369,7 @@ function EnableEditor(props) {
5344
5369
  onUpdateFn_1
5345
5370
  )
5346
5371
  );
5347
- const onUpdateFn_2_props_builderContextSignal_content__data__httpRequests = createMemo15(() => props.builderContextSignal.content?.data?.httpRequests);
5372
+ const onUpdateFn_2_props_builderContextSignal_content__data__httpRequests = createMemo16(() => props.builderContextSignal.content?.data?.httpRequests);
5348
5373
  function onUpdateFn_2() {
5349
5374
  runHttpRequests();
5350
5375
  }
@@ -5356,7 +5381,7 @@ function EnableEditor(props) {
5356
5381
  onUpdateFn_2
5357
5382
  )
5358
5383
  );
5359
- const onUpdateFn_3_props_builderContextSignal_rootState = createMemo15(
5384
+ const onUpdateFn_3_props_builderContextSignal_rootState = createMemo16(
5360
5385
  () => props.builderContextSignal.rootState
5361
5386
  );
5362
5387
  function onUpdateFn_3() {
@@ -5368,14 +5393,14 @@ function EnableEditor(props) {
5368
5393
  onUpdateFn_3
5369
5394
  )
5370
5395
  );
5371
- const onUpdateFn_4_props_data = createMemo15(() => props.data);
5396
+ const onUpdateFn_4_props_data = createMemo16(() => props.data);
5372
5397
  function onUpdateFn_4() {
5373
5398
  if (props.data) {
5374
5399
  mergeNewRootState(props.data);
5375
5400
  }
5376
5401
  }
5377
5402
  createEffect2(on2(() => [onUpdateFn_4_props_data()], onUpdateFn_4));
5378
- const onUpdateFn_5_props_locale = createMemo15(() => props.locale);
5403
+ const onUpdateFn_5_props_locale = createMemo16(() => props.locale);
5379
5404
  function onUpdateFn_5() {
5380
5405
  if (props.locale) {
5381
5406
  mergeNewRootState({
@@ -5402,9 +5427,9 @@ function EnableEditor(props) {
5402
5427
  var Enable_editor_default = EnableEditor;
5403
5428
 
5404
5429
  // src/components/content/components/styles.tsx
5405
- import { createSignal as createSignal16 } from "solid-js";
5430
+ import { createSignal as createSignal17 } from "solid-js";
5406
5431
  function ContentStyles(props) {
5407
- const [injectedStyles, setInjectedStyles] = createSignal16(
5432
+ const [injectedStyles, setInjectedStyles] = createSignal17(
5408
5433
  `
5409
5434
  ${getCss({
5410
5435
  cssCode: props.cssCode,
@@ -5462,7 +5487,7 @@ var getContentInitialValue = ({
5462
5487
 
5463
5488
  // src/components/content/content.tsx
5464
5489
  function ContentComponent(props) {
5465
- const [scriptStr, setScriptStr] = createSignal17(
5490
+ const [scriptStr, setScriptStr] = createSignal18(
5466
5491
  getUpdateVariantVisibilityScript({
5467
5492
  // eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
5468
5493
  variationId: props.content?.testVariationId,
@@ -5470,7 +5495,7 @@ function ContentComponent(props) {
5470
5495
  contentId: props.content?.id
5471
5496
  })
5472
5497
  );
5473
- const [registeredComponents, setRegisteredComponents] = createSignal17(
5498
+ const [registeredComponents, setRegisteredComponents] = createSignal18(
5474
5499
  [
5475
5500
  ...getDefaultRegisteredComponents(),
5476
5501
  ...props.customComponents?.filter(({ models }) => {
@@ -5491,7 +5516,7 @@ function ContentComponent(props) {
5491
5516
  {}
5492
5517
  )
5493
5518
  );
5494
- const [builderContextSignal, setBuilderContextSignal] = createSignal17({
5519
+ const [builderContextSignal, setBuilderContextSignal] = createSignal18({
5495
5520
  content: getContentInitialValue({
5496
5521
  content: props.content,
5497
5522
  data: props.data
@@ -5581,13 +5606,13 @@ var Content_default = ContentComponent;
5581
5606
 
5582
5607
  // src/components/content-variants/content-variants.tsx
5583
5608
  function ContentVariants(props) {
5584
- const [shouldRenderVariants, setShouldRenderVariants] = createSignal18(
5609
+ const [shouldRenderVariants, setShouldRenderVariants] = createSignal19(
5585
5610
  checkShouldRenderVariants({
5586
5611
  canTrack: getDefaultCanTrack(props.canTrack),
5587
5612
  content: props.content
5588
5613
  })
5589
5614
  );
5590
- const updateCookieAndStylesScriptStr = createMemo18(() => {
5615
+ const updateCookieAndStylesScriptStr = createMemo19(() => {
5591
5616
  return getUpdateCookieAndStylesScript(
5592
5617
  getVariants(props.content).map((value) => ({
5593
5618
  id: value.testVariationId,
@@ -5596,10 +5621,10 @@ function ContentVariants(props) {
5596
5621
  props.content?.id || ""
5597
5622
  );
5598
5623
  });
5599
- const hideVariantsStyleString = createMemo18(() => {
5624
+ const hideVariantsStyleString = createMemo19(() => {
5600
5625
  return getVariants(props.content).map((value) => `.variant-${value.testVariationId} { display: none; } `).join("");
5601
5626
  });
5602
- const defaultContent = createMemo18(() => {
5627
+ const defaultContent = createMemo19(() => {
5603
5628
  return shouldRenderVariants() ? {
5604
5629
  ...props.content,
5605
5630
  testVariationId: props.content?.id
@@ -5608,7 +5633,7 @@ function ContentVariants(props) {
5608
5633
  canTrack: getDefaultCanTrack(props.canTrack)
5609
5634
  });
5610
5635
  });
5611
- onMount4(() => {
5636
+ onMount5(() => {
5612
5637
  setShouldRenderVariants(false);
5613
5638
  });
5614
5639
  return <><>
@@ -5708,14 +5733,14 @@ var fetchSymbolContent = async ({
5708
5733
 
5709
5734
  // src/blocks/symbol/symbol.tsx
5710
5735
  function Symbol(props) {
5711
- const [contentToUse, setContentToUse] = createSignal19(props.symbol?.content);
5712
- const blocksWrapper = createMemo19(() => {
5736
+ const [contentToUse, setContentToUse] = createSignal20(props.symbol?.content);
5737
+ const blocksWrapper = createMemo20(() => {
5713
5738
  return "div";
5714
5739
  });
5715
- const contentWrapper = createMemo19(() => {
5740
+ const contentWrapper = createMemo20(() => {
5716
5741
  return "div";
5717
5742
  });
5718
- const className = createMemo19(() => {
5743
+ const className = createMemo20(() => {
5719
5744
  return [
5720
5745
  ...[props.attributes[getClassPropName()]],
5721
5746
  "builder-symbol",
@@ -5735,9 +5760,9 @@ function Symbol(props) {
5735
5760
  }
5736
5761
  });
5737
5762
  }
5738
- onMount5(() => {
5763
+ onMount6(() => {
5739
5764
  });
5740
- const onUpdateFn_0_props_symbol = createMemo19(() => props.symbol);
5765
+ const onUpdateFn_0_props_symbol = createMemo20(() => props.symbol);
5741
5766
  function onUpdateFn_0() {
5742
5767
  setContent();
5743
5768
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@builder.io/sdk-solid",
3
- "version": "2.0.2",
3
+ "version": "2.0.5",
4
4
  "description": "",
5
5
  "files": [
6
6
  "dist",