@builder.io/sdk-solid 1.0.32 → 1.0.35

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/edge/index.js CHANGED
@@ -1,6 +1,5 @@
1
1
  import { delegateEvents, createComponent, spread, mergeProps, insert, effect, setAttribute, className, style, template, Dynamic, memo, use } from 'solid-js/web';
2
2
  import { createContext, useContext, Show, For, createSignal, createMemo, onMount, createEffect, on } from 'solid-js';
3
- import { css } from 'solid-styled-components';
4
3
 
5
4
  var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
6
5
  get: (a, b) => (typeof require !== "undefined" ? require : a)[b]
@@ -4031,7 +4030,7 @@ function BlockStyles(props) {
4031
4030
  }
4032
4031
  return true;
4033
4032
  });
4034
- const css5 = createMemo(() => {
4033
+ const css = createMemo(() => {
4035
4034
  const processedBlock = getProcessedBlock({
4036
4035
  block: props.block,
4037
4036
  localState: props.context.localState,
@@ -4081,13 +4080,13 @@ function BlockStyles(props) {
4081
4080
  });
4082
4081
  return createComponent(Show, {
4083
4082
  get when() {
4084
- return memo(() => !!(TARGET !== "reactNative" && css5()))() && canShowBlock();
4083
+ return memo(() => !!(TARGET !== "reactNative" && css()))() && canShowBlock();
4085
4084
  },
4086
4085
  get children() {
4087
4086
  return createComponent(inlined_styles_default, {
4088
4087
  id: "builderio-block",
4089
4088
  get styles() {
4090
- return css5();
4089
+ return css();
4091
4090
  }
4092
4091
  });
4093
4092
  }
@@ -4565,6 +4564,11 @@ function Block(props) {
4565
4564
  });
4566
4565
  }
4567
4566
  var block_default = Block;
4567
+ var _tmpl$2 = /* @__PURE__ */ template(`<style>.dynamic-1bb6a3a2 {
4568
+ display: flex;
4569
+ flex-direction: column;
4570
+ align-items: stretch;
4571
+ }`);
4568
4572
  function BlocksWrapper(props) {
4569
4573
  const className = createMemo(() => {
4570
4574
  return "builder-blocks" + (!props.blocks?.length ? " no-blocks" : "");
@@ -4591,13 +4595,9 @@ function BlocksWrapper(props) {
4591
4595
  }, "*");
4592
4596
  }
4593
4597
  }
4594
- return createComponent(Dynamic, mergeProps({
4598
+ return [createComponent(Dynamic, mergeProps({
4595
4599
  get ["class"]() {
4596
- return className() + " " + css({
4597
- display: "flex",
4598
- flexDirection: "column",
4599
- alignItems: "stretch"
4600
- });
4600
+ return className() + " dynamic-1bb6a3a2";
4601
4601
  },
4602
4602
  get ["builder-path"]() {
4603
4603
  return props.path;
@@ -4619,7 +4619,7 @@ function BlocksWrapper(props) {
4619
4619
  get children() {
4620
4620
  return props.children;
4621
4621
  }
4622
- }));
4622
+ })), _tmpl$2()];
4623
4623
  }
4624
4624
  var blocks_wrapper_default = BlocksWrapper;
4625
4625
 
@@ -4688,7 +4688,11 @@ var getColumnsClass = (id2) => {
4688
4688
  };
4689
4689
 
4690
4690
  // src/blocks/columns/columns.tsx
4691
- var _tmpl$2 = /* @__PURE__ */ template(`<div>`);
4691
+ var _tmpl$3 = /* @__PURE__ */ template(`<div>`);
4692
+ var _tmpl$22 = /* @__PURE__ */ template(`<style>.div-f2f53158 {
4693
+ display: flex;
4694
+ line-height: normal;
4695
+ }`);
4692
4696
  function Columns(props) {
4693
4697
  const [gutterSize, setGutterSize] = createSignal(typeof props.space === "number" ? props.space || 0 : 20);
4694
4698
  const [cols, setCols] = createSignal(props.columns || []);
@@ -4800,14 +4804,11 @@ function Columns(props) {
4800
4804
  style: mapStyleObjToStrIfNeeded(columnCssVars(index))
4801
4805
  };
4802
4806
  }
4803
- return (() => {
4804
- const _el$ = _tmpl$2();
4807
+ return [(() => {
4808
+ const _el$ = _tmpl$3();
4805
4809
  spread(_el$, mergeProps({
4806
4810
  get ["class"]() {
4807
- return getColumnsClass(props.builderBlock?.id) + " " + css({
4808
- display: "flex",
4809
- lineHeight: "normal"
4810
- });
4811
+ return getColumnsClass(props.builderBlock?.id) + " div-f2f53158";
4811
4812
  },
4812
4813
  get style() {
4813
4814
  return columnsCssVars();
@@ -4866,13 +4867,13 @@ function Columns(props) {
4866
4867
  }
4867
4868
  }), null);
4868
4869
  return _el$;
4869
- })();
4870
+ })(), _tmpl$22()];
4870
4871
  }
4871
4872
  var columns_default = Columns;
4872
- var _tmpl$3 = /* @__PURE__ */ template(`<span>`);
4873
+ var _tmpl$4 = /* @__PURE__ */ template(`<span>`);
4873
4874
  function FragmentComponent(props) {
4874
4875
  return (() => {
4875
- const _el$ = _tmpl$3();
4876
+ const _el$ = _tmpl$4();
4876
4877
  insert(_el$, () => props.children);
4877
4878
  return _el$;
4878
4879
  })();
@@ -4927,9 +4928,27 @@ function getSrcSet(url) {
4927
4928
  }
4928
4929
 
4929
4930
  // src/blocks/image/image.tsx
4930
- var _tmpl$4 = /* @__PURE__ */ template(`<source type=image/webp>`);
4931
- var _tmpl$22 = /* @__PURE__ */ template(`<picture><img>`);
4932
- var _tmpl$32 = /* @__PURE__ */ template(`<div>`);
4931
+ var _tmpl$5 = /* @__PURE__ */ template(`<source type=image/webp>`);
4932
+ var _tmpl$23 = /* @__PURE__ */ template(`<picture><img>`);
4933
+ var _tmpl$32 = /* @__PURE__ */ template(`<div class="builder-image-sizer div-54b38751">`);
4934
+ var _tmpl$42 = /* @__PURE__ */ template(`<div class=div-54b38751-2>`);
4935
+ var _tmpl$52 = /* @__PURE__ */ template(`<style>.img-54b38751 {
4936
+ opacity: 1;
4937
+ transition: opacity 0.2s ease-in-out;
4938
+ }.div-54b38751 {
4939
+ width: 100%;
4940
+ pointer-events: none;
4941
+ font-size: 0;
4942
+ }.div-54b38751-2 {
4943
+ display: flex;
4944
+ flex-direction: column;
4945
+ align-items: stretch;
4946
+ position: absolute;
4947
+ top: 0;
4948
+ left: 0;
4949
+ width: 100%;
4950
+ height: 100%;
4951
+ }`);
4933
4952
  function Image(props) {
4934
4953
  const srcSetToUse = createMemo(() => {
4935
4954
  const imageToUse = props.image || props.src;
@@ -4966,23 +4985,20 @@ function Image(props) {
4966
4985
  const out = props.aspectRatio ? aspectRatioStyles : void 0;
4967
4986
  return out;
4968
4987
  });
4969
- return [(() => {
4970
- const _el$ = _tmpl$22(), _el$3 = _el$.firstChild;
4988
+ return [[(() => {
4989
+ const _el$ = _tmpl$23(), _el$3 = _el$.firstChild;
4971
4990
  insert(_el$, createComponent(Show, {
4972
4991
  get when() {
4973
4992
  return webpSrcSet();
4974
4993
  },
4975
4994
  get children() {
4976
- const _el$2 = _tmpl$4();
4995
+ const _el$2 = _tmpl$5();
4977
4996
  effect(() => setAttribute(_el$2, "srcset", webpSrcSet()));
4978
4997
  return _el$2;
4979
4998
  }
4980
4999
  }), _el$3);
4981
5000
  effect((_p$) => {
4982
- const _v$ = "builder-image" + (props.className ? " " + props.className : "") + " " + css({
4983
- opacity: "1",
4984
- transition: "opacity 0.2s ease-in-out"
4985
- }), _v$2 = props.highPriority ? "eager" : "lazy", _v$3 = props.highPriority ? "high" : "auto", _v$4 = props.altText, _v$5 = props.altText ? void 0 : "presentation", _v$6 = {
5001
+ const _v$ = "builder-image" + (props.className ? " " + props.className : "") + " img-54b38751", _v$2 = props.highPriority ? "eager" : "lazy", _v$3 = props.highPriority ? "high" : "auto", _v$4 = props.altText, _v$5 = props.altText ? void 0 : "presentation", _v$6 = {
4986
5002
  "object-position": props.backgroundPosition || "center",
4987
5003
  "object-fit": props.backgroundSize || "cover",
4988
5004
  ...aspectRatioCss()
@@ -5015,19 +5031,7 @@ function Image(props) {
5015
5031
  },
5016
5032
  get children() {
5017
5033
  const _el$4 = _tmpl$32();
5018
- effect((_p$) => {
5019
- const _v$10 = "builder-image-sizer " + css({
5020
- width: "100%",
5021
- pointerEvents: "none",
5022
- fontSize: "0"
5023
- }), _v$11 = props.aspectRatio * 100 + "%";
5024
- _v$10 !== _p$._v$10 && className(_el$4, _p$._v$10 = _v$10);
5025
- _v$11 !== _p$._v$11 && ((_p$._v$11 = _v$11) != null ? _el$4.style.setProperty("padding-top", _v$11) : _el$4.style.removeProperty("padding-top"));
5026
- return _p$;
5027
- }, {
5028
- _v$10: void 0,
5029
- _v$11: void 0
5030
- });
5034
+ effect(() => props.aspectRatio * 100 + "%" != null ? _el$4.style.setProperty("padding-top", props.aspectRatio * 100 + "%") : _el$4.style.removeProperty("padding-top"));
5031
5035
  return _el$4;
5032
5036
  }
5033
5037
  }), createComponent(Show, {
@@ -5042,27 +5046,17 @@ function Image(props) {
5042
5046
  return !props.fitContent && props.builderBlock?.children?.length;
5043
5047
  },
5044
5048
  get children() {
5045
- const _el$5 = _tmpl$32();
5049
+ const _el$5 = _tmpl$42();
5046
5050
  insert(_el$5, () => props.children);
5047
- effect(() => className(_el$5, css({
5048
- display: "flex",
5049
- flexDirection: "column",
5050
- alignItems: "stretch",
5051
- position: "absolute",
5052
- top: "0",
5053
- left: "0",
5054
- width: "100%",
5055
- height: "100%"
5056
- })));
5057
5051
  return _el$5;
5058
5052
  }
5059
- })];
5053
+ })], _tmpl$52()];
5060
5054
  }
5061
5055
  var image_default = Image;
5062
- var _tmpl$5 = /* @__PURE__ */ template(`<section>`);
5056
+ var _tmpl$6 = /* @__PURE__ */ template(`<section>`);
5063
5057
  function SectionComponent(props) {
5064
5058
  return (() => {
5065
- const _el$ = _tmpl$5();
5059
+ const _el$ = _tmpl$6();
5066
5060
  spread(_el$, mergeProps({}, () => props.attributes, {
5067
5061
  get style() {
5068
5062
  return {
@@ -5407,8 +5401,8 @@ var convertOrderNumberToString = (order) => {
5407
5401
  };
5408
5402
 
5409
5403
  // src/blocks/accordion/accordion.tsx
5410
- var _tmpl$6 = /* @__PURE__ */ template(`<div class=builder-accordion>`);
5411
- var _tmpl$23 = /* @__PURE__ */ template(`<div>`);
5404
+ var _tmpl$7 = /* @__PURE__ */ template(`<div class=builder-accordion>`);
5405
+ var _tmpl$24 = /* @__PURE__ */ template(`<div>`);
5412
5406
  function Accordion(props) {
5413
5407
  const [open, setOpen] = createSignal([]);
5414
5408
  const onlyOneAtATime = createMemo(() => {
@@ -5498,7 +5492,7 @@ function Accordion(props) {
5498
5492
  }
5499
5493
  }
5500
5494
  return (() => {
5501
- const _el$ = _tmpl$6();
5495
+ const _el$ = _tmpl$7();
5502
5496
  insert(_el$, createComponent(For, {
5503
5497
  get each() {
5504
5498
  return props.items;
@@ -5506,7 +5500,7 @@ function Accordion(props) {
5506
5500
  children: (item, _index) => {
5507
5501
  const index = _index();
5508
5502
  return [(() => {
5509
- const _el$2 = _tmpl$23();
5503
+ const _el$2 = _tmpl$24();
5510
5504
  _el$2.$$click = (event) => onClick(index);
5511
5505
  setAttribute(_el$2, "data-index", index);
5512
5506
  insert(_el$2, createComponent(blocks_default, {
@@ -5548,7 +5542,7 @@ function Accordion(props) {
5548
5542
  return open().includes(index);
5549
5543
  },
5550
5544
  get children() {
5551
- const _el$3 = _tmpl$23();
5545
+ const _el$3 = _tmpl$24();
5552
5546
  insert(_el$3, createComponent(blocks_default, {
5553
5547
  get blocks() {
5554
5548
  return item.detail;
@@ -5869,7 +5863,7 @@ var componentInfo5 = {
5869
5863
  name: "image",
5870
5864
  type: "file",
5871
5865
  bubble: true,
5872
- allowedFileTypes: ["jpeg", "jpg", "png", "svg"],
5866
+ allowedFileTypes: ["jpeg", "jpg", "png", "svg", "webp"],
5873
5867
  required: true,
5874
5868
  defaultValue: "https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",
5875
5869
  onChange: (options) => {
@@ -6037,10 +6031,10 @@ var componentInfo7 = {
6037
6031
  defaultValue: "children"
6038
6032
  }]
6039
6033
  };
6040
- var _tmpl$7 = /* @__PURE__ */ template(`<div>`);
6034
+ var _tmpl$8 = /* @__PURE__ */ template(`<div>`);
6041
6035
  function Slot(props) {
6042
6036
  return (() => {
6043
- const _el$ = _tmpl$7();
6037
+ const _el$ = _tmpl$8();
6044
6038
  _el$.style.setProperty("pointer-events", "auto");
6045
6039
  spread(_el$, mergeProps(() => !props.builderContext.context?.symbolId && {
6046
6040
  "builder-slot": props.name
@@ -6239,8 +6233,8 @@ var componentInfo9 = {
6239
6233
  }]
6240
6234
  }]
6241
6235
  };
6242
- var _tmpl$8 = /* @__PURE__ */ template(`<div>`);
6243
- var _tmpl$24 = /* @__PURE__ */ template(`<div><div class=builder-tabs-wrap>`);
6236
+ var _tmpl$9 = /* @__PURE__ */ template(`<div>`);
6237
+ var _tmpl$25 = /* @__PURE__ */ template(`<div><div class=builder-tabs-wrap>`);
6244
6238
  var _tmpl$33 = /* @__PURE__ */ template(`<span>`);
6245
6239
  function Tabs(props) {
6246
6240
  const [activeTab, setActiveTab] = createSignal(props.defaultActiveTab ? props.defaultActiveTab - 1 : 0);
@@ -6255,7 +6249,7 @@ function Tabs(props) {
6255
6249
  }
6256
6250
  }
6257
6251
  return (() => {
6258
- const _el$ = _tmpl$24(), _el$2 = _el$.firstChild;
6252
+ const _el$ = _tmpl$25(), _el$2 = _el$.firstChild;
6259
6253
  _el$2.style.setProperty("display", "flex");
6260
6254
  _el$2.style.setProperty("flex-direction", "row");
6261
6255
  _el$2.style.setProperty("overflow", "auto");
@@ -6307,7 +6301,7 @@ function Tabs(props) {
6307
6301
  return activeTabContent(activeTab());
6308
6302
  },
6309
6303
  get children() {
6310
- const _el$3 = _tmpl$8();
6304
+ const _el$3 = _tmpl$9();
6311
6305
  insert(_el$3, createComponent(blocks_default, {
6312
6306
  get parent() {
6313
6307
  return props.builderBlock.id;
@@ -6358,10 +6352,10 @@ var componentInfo10 = {
6358
6352
  textAlign: "center"
6359
6353
  }
6360
6354
  };
6361
- var _tmpl$9 = /* @__PURE__ */ template(`<div class=builder-text>`);
6355
+ var _tmpl$10 = /* @__PURE__ */ template(`<div class=builder-text>`);
6362
6356
  function Text(props) {
6363
6357
  return (() => {
6364
- const _el$ = _tmpl$9();
6358
+ const _el$ = _tmpl$10();
6365
6359
  _el$.style.setProperty("outline", "none");
6366
6360
  effect(() => _el$.innerHTML = props.text?.toString() || "");
6367
6361
  return _el$;
@@ -6393,7 +6387,7 @@ var componentInfo11 = {
6393
6387
  advanced: true
6394
6388
  }]
6395
6389
  };
6396
- var _tmpl$10 = /* @__PURE__ */ template(`<div>`);
6390
+ var _tmpl$11 = /* @__PURE__ */ template(`<div>`);
6397
6391
  function CustomCode(props) {
6398
6392
  const [scriptsInserted, setScriptsInserted] = createSignal([]);
6399
6393
  const [scriptsRun, setScriptsRun] = createSignal([]);
@@ -6427,7 +6421,7 @@ function CustomCode(props) {
6427
6421
  }
6428
6422
  });
6429
6423
  return (() => {
6430
- const _el$ = _tmpl$10();
6424
+ const _el$ = _tmpl$11();
6431
6425
  const _ref$ = elementRef;
6432
6426
  typeof _ref$ === "function" ? use(_ref$, _el$) : elementRef = _el$;
6433
6427
  effect((_p$) => {
@@ -6458,7 +6452,7 @@ var componentInfo12 = {
6458
6452
  const url = options.get("url");
6459
6453
  if (url) {
6460
6454
  options.set("content", "Loading...");
6461
- const apiKey = "ae0e60e78201a3f2b0de4b";
6455
+ const apiKey = _iframelyApiKey;
6462
6456
  return fetch(`https://iframe.ly/api/iframely?url=${url}&api_key=${apiKey}`).then((res) => res.json()).then((data) => {
6463
6457
  if (options.get("url") === url) {
6464
6458
  if (data.html) {
@@ -6487,7 +6481,7 @@ var SCRIPT_MIME_TYPES = ["text/javascript", "application/javascript", "applicati
6487
6481
  var isJsScript = (script) => SCRIPT_MIME_TYPES.includes(script.type);
6488
6482
 
6489
6483
  // src/blocks/embed/embed.tsx
6490
- var _tmpl$11 = /* @__PURE__ */ template(`<div class=builder-embed>`);
6484
+ var _tmpl$12 = /* @__PURE__ */ template(`<div class=builder-embed>`);
6491
6485
  function Embed(props) {
6492
6486
  const [scriptsInserted, setScriptsInserted] = createSignal([]);
6493
6487
  const [scriptsRun, setScriptsRun] = createSignal([]);
@@ -6524,7 +6518,7 @@ function Embed(props) {
6524
6518
  }
6525
6519
  createEffect(on(() => [onUpdateFn_0_elem(), onUpdateFn_0_ranInitFn__()], onUpdateFn_0));
6526
6520
  return (() => {
6527
- const _el$ = _tmpl$11();
6521
+ const _el$ = _tmpl$12();
6528
6522
  const _ref$ = elem;
6529
6523
  typeof _ref$ === "function" ? use(_ref$, _el$) : elem = _el$;
6530
6524
  effect(() => _el$.innerHTML = props.content);
@@ -6781,8 +6775,13 @@ var get = (obj, path, defaultValue) => {
6781
6775
  };
6782
6776
 
6783
6777
  // src/blocks/form/form/form.tsx
6784
- var _tmpl$12 = /* @__PURE__ */ template(`<pre>`);
6785
- var _tmpl$25 = /* @__PURE__ */ template(`<form>`);
6778
+ var _tmpl$13 = /* @__PURE__ */ template(`<pre class="builder-form-error-text pre-2e825338">`);
6779
+ var _tmpl$26 = /* @__PURE__ */ template(`<form>`);
6780
+ var _tmpl$34 = /* @__PURE__ */ template(`<style>.pre-2e825338 {
6781
+ padding: 10px;
6782
+ color: red;
6783
+ text-align: center;
6784
+ }`);
6786
6785
  function FormComponent(props) {
6787
6786
  const [formState, setFormState] = createSignal("unsubmitted");
6788
6787
  const [responseData, setResponseData] = createSignal(null);
@@ -6967,8 +6966,8 @@ function FormComponent(props) {
6967
6966
  }
6968
6967
  }
6969
6968
  let formRef;
6970
- return (() => {
6971
- const _el$ = _tmpl$25();
6969
+ return [(() => {
6970
+ const _el$ = _tmpl$26();
6972
6971
  _el$.addEventListener("submit", (event) => onSubmit(event));
6973
6972
  const _ref$ = formRef;
6974
6973
  typeof _ref$ === "function" ? use(_ref$, _el$) : formRef = _el$;
@@ -7051,13 +7050,8 @@ function FormComponent(props) {
7051
7050
  return memo(() => submissionState() === "error")() && responseData();
7052
7051
  },
7053
7052
  get children() {
7054
- const _el$2 = _tmpl$12();
7053
+ const _el$2 = _tmpl$13();
7055
7054
  insert(_el$2, () => JSON.stringify(responseData(), null, 2));
7056
- effect(() => className(_el$2, "builder-form-error-text " + css({
7057
- padding: "10px",
7058
- color: "red",
7059
- textAlign: "center"
7060
- })));
7061
7055
  return _el$2;
7062
7056
  }
7063
7057
  }), null);
@@ -7078,7 +7072,7 @@ function FormComponent(props) {
7078
7072
  }
7079
7073
  }), null);
7080
7074
  return _el$;
7081
- })();
7075
+ })(), _tmpl$34()];
7082
7076
  }
7083
7077
  var form_default = FormComponent;
7084
7078
 
@@ -7135,10 +7129,10 @@ var componentInfo14 = {
7135
7129
  borderColor: "#ccc"
7136
7130
  }
7137
7131
  };
7138
- var _tmpl$13 = /* @__PURE__ */ template(`<input>`);
7132
+ var _tmpl$14 = /* @__PURE__ */ template(`<input>`);
7139
7133
  function FormInputComponent(props) {
7140
7134
  return (() => {
7141
- const _el$ = _tmpl$13();
7135
+ const _el$ = _tmpl$14();
7142
7136
  spread(_el$, mergeProps({}, () => props.attributes, {
7143
7137
  get key() {
7144
7138
  return isEditing() && props.defaultValue ? props.defaultValue : "default-key";
@@ -7211,11 +7205,11 @@ var componentInfo15 = {
7211
7205
  static: true,
7212
7206
  noWrap: true
7213
7207
  };
7214
- var _tmpl$14 = /* @__PURE__ */ template(`<select>`);
7215
- var _tmpl$26 = /* @__PURE__ */ template(`<option>`);
7208
+ var _tmpl$15 = /* @__PURE__ */ template(`<select>`);
7209
+ var _tmpl$27 = /* @__PURE__ */ template(`<option>`);
7216
7210
  function SelectComponent(props) {
7217
7211
  return (() => {
7218
- const _el$ = _tmpl$14();
7212
+ const _el$ = _tmpl$15();
7219
7213
  spread(_el$, mergeProps({}, () => props.attributes, {
7220
7214
  get value() {
7221
7215
  return props.value;
@@ -7237,7 +7231,7 @@ function SelectComponent(props) {
7237
7231
  children: (option, _index) => {
7238
7232
  const index = _index();
7239
7233
  return (() => {
7240
- const _el$2 = _tmpl$26();
7234
+ const _el$2 = _tmpl$27();
7241
7235
  insert(_el$2, () => option.name || option.value);
7242
7236
  effect(() => setAttribute(_el$2, "key", `${option.name}-${index}`));
7243
7237
  effect(() => _el$2.value = option.value);
@@ -7277,10 +7271,10 @@ var componentInfo16 = {
7277
7271
  // TODO: defaultChildren
7278
7272
  // canHaveChildren: true,
7279
7273
  };
7280
- var _tmpl$15 = /* @__PURE__ */ template(`<button type=submit>`);
7274
+ var _tmpl$16 = /* @__PURE__ */ template(`<button type=submit>`);
7281
7275
  function SubmitButton(props) {
7282
7276
  return (() => {
7283
- const _el$ = _tmpl$15();
7277
+ const _el$ = _tmpl$16();
7284
7278
  spread(_el$, mergeProps({}, () => props.attributes), false, true);
7285
7279
  insert(_el$, () => props.text);
7286
7280
  return _el$;
@@ -7304,10 +7298,10 @@ var componentInfo17 = {
7304
7298
  noWrap: true,
7305
7299
  static: true
7306
7300
  };
7307
- var _tmpl$16 = /* @__PURE__ */ template(`<img>`);
7301
+ var _tmpl$17 = /* @__PURE__ */ template(`<img>`);
7308
7302
  function ImgComponent(props) {
7309
7303
  return (() => {
7310
- const _el$ = _tmpl$16();
7304
+ const _el$ = _tmpl$17();
7311
7305
  spread(_el$, mergeProps({
7312
7306
  get style() {
7313
7307
  return {
@@ -7413,9 +7407,9 @@ var componentInfo18 = {
7413
7407
  advanced: true
7414
7408
  }]
7415
7409
  };
7416
- var _tmpl$17 = /* @__PURE__ */ template(`<source type=video/mp4>`);
7417
- var _tmpl$27 = /* @__PURE__ */ template(`<div>`);
7418
- var _tmpl$34 = /* @__PURE__ */ template(`<div><video class=builder-video>`);
7410
+ var _tmpl$18 = /* @__PURE__ */ template(`<source type=video/mp4>`);
7411
+ var _tmpl$28 = /* @__PURE__ */ template(`<div>`);
7412
+ var _tmpl$35 = /* @__PURE__ */ template(`<div><video class=builder-video>`);
7419
7413
  function Video(props) {
7420
7414
  const videoProps = createMemo(() => {
7421
7415
  return {
@@ -7442,7 +7436,7 @@ function Video(props) {
7442
7436
  };
7443
7437
  });
7444
7438
  return (() => {
7445
- const _el$ = _tmpl$34(), _el$2 = _el$.firstChild;
7439
+ const _el$ = _tmpl$35(), _el$2 = _el$.firstChild;
7446
7440
  _el$.style.setProperty("position", "relative");
7447
7441
  spread(_el$2, mergeProps(spreadProps, {
7448
7442
  get preload() {
@@ -7476,7 +7470,7 @@ function Video(props) {
7476
7470
  return !props.lazyLoad;
7477
7471
  },
7478
7472
  get children() {
7479
- const _el$3 = _tmpl$17();
7473
+ const _el$3 = _tmpl$18();
7480
7474
  effect(() => setAttribute(_el$3, "src", props.video));
7481
7475
  return _el$3;
7482
7476
  }
@@ -7486,7 +7480,7 @@ function Video(props) {
7486
7480
  return props.aspectRatio && !(props.fitContent && props.builderBlock?.children?.length);
7487
7481
  },
7488
7482
  get children() {
7489
- const _el$4 = _tmpl$27();
7483
+ const _el$4 = _tmpl$28();
7490
7484
  _el$4.style.setProperty("width", "100%");
7491
7485
  _el$4.style.setProperty("pointer-events", "none");
7492
7486
  _el$4.style.setProperty("font-size", "0px");
@@ -7499,7 +7493,7 @@ function Video(props) {
7499
7493
  return props.builderBlock?.children?.length && props.fitContent;
7500
7494
  },
7501
7495
  get children() {
7502
- const _el$5 = _tmpl$27();
7496
+ const _el$5 = _tmpl$28();
7503
7497
  _el$5.style.setProperty("display", "flex");
7504
7498
  _el$5.style.setProperty("flex-direction", "column");
7505
7499
  _el$5.style.setProperty("align-items", "stretch");
@@ -7512,7 +7506,7 @@ function Video(props) {
7512
7506
  return props.builderBlock?.children?.length && !props.fitContent;
7513
7507
  },
7514
7508
  get children() {
7515
- const _el$6 = _tmpl$27();
7509
+ const _el$6 = _tmpl$28();
7516
7510
  _el$6.style.setProperty("pointer-events", "none");
7517
7511
  _el$6.style.setProperty("display", "flex");
7518
7512
  _el$6.style.setProperty("flex-direction", "column");
@@ -7658,10 +7652,10 @@ var getUpdateVariantVisibilityScript = ({
7658
7652
  }) => `window.${UPDATE_VARIANT_VISIBILITY_SCRIPT_FN_NAME}(
7659
7653
  "${variationId}", "${contentId}", ${isHydrationTarget}
7660
7654
  )`;
7661
- var _tmpl$18 = /* @__PURE__ */ template(`<script>`);
7655
+ var _tmpl$19 = /* @__PURE__ */ template(`<script>`);
7662
7656
  function InlinedScript(props) {
7663
7657
  return (() => {
7664
- const _el$ = _tmpl$18();
7658
+ const _el$ = _tmpl$19();
7665
7659
  effect((_p$) => {
7666
7660
  const _v$ = props.scriptStr, _v$2 = props.id;
7667
7661
  _v$ !== _p$._v$ && (_el$.innerHTML = _p$._v$ = _v$);
@@ -8162,12 +8156,15 @@ var getInteractionPropertiesForEvent = (event) => {
8162
8156
  // src/functions/is-from-trusted-host.ts
8163
8157
  var DEFAULT_TRUSTED_HOSTS = ["*.beta.builder.io", "beta.builder.io", "builder.io", "localhost", "qa.builder.io"];
8164
8158
  function isFromTrustedHost(trustedHosts, e) {
8159
+ if (!e.origin.startsWith("http") && !e.origin.startsWith("https")) {
8160
+ return false;
8161
+ }
8165
8162
  const url = new URL(e.origin), hostname = url.hostname;
8166
8163
  return (trustedHosts || DEFAULT_TRUSTED_HOSTS).findIndex((trustedHost) => trustedHost.startsWith("*.") ? hostname.endsWith(trustedHost.slice(1)) : trustedHost === hostname) > -1;
8167
8164
  }
8168
8165
 
8169
8166
  // src/constants/sdk-version.ts
8170
- var SDK_VERSION = "1.0.32";
8167
+ var SDK_VERSION = "1.0.35";
8171
8168
 
8172
8169
  // src/functions/register.ts
8173
8170
  var registry = {};
@@ -9149,7 +9146,7 @@ var fetchSymbolContent = async ({
9149
9146
  };
9150
9147
 
9151
9148
  // src/blocks/symbol/symbol.tsx
9152
- var _tmpl$19 = /* @__PURE__ */ template(`<div>`);
9149
+ var _tmpl$20 = /* @__PURE__ */ template(`<div>`);
9153
9150
  function Symbol2(props) {
9154
9151
  const [contentToUse, setContentToUse] = createSignal(props.symbol?.content);
9155
9152
  const blocksWrapper = createMemo(() => {
@@ -9181,7 +9178,7 @@ function Symbol2(props) {
9181
9178
  }
9182
9179
  createEffect(on(() => [onUpdateFn_0_props_symbol()], onUpdateFn_0));
9183
9180
  return (() => {
9184
- const _el$ = _tmpl$19();
9181
+ const _el$ = _tmpl$20();
9185
9182
  spread(_el$, mergeProps({
9186
9183
  get ["class"]() {
9187
9184
  return className();