@builder.io/sdk-qwik 0.1.15 → 0.1.16
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/README.md +57 -0
- package/lib/index.qwik.cjs +448 -430
- package/lib/index.qwik.mjs +450 -432
- package/package.json +2 -2
- package/types/blocks/columns/columns.d.ts +3 -3
- package/types/blocks/image/image.d.ts +2 -2
- package/types/blocks/symbol/symbol.d.ts +2 -2
- package/types/components/render-block/block-styles.d.ts +2 -2
- package/types/components/render-block/render-block.d.ts +4 -2
- package/types/components/render-block/render-component.d.ts +2 -2
- package/types/components/render-block/render-repeated-block.d.ts +2 -2
- package/types/components/render-blocks.d.ts +1 -1
- package/types/components/render-content/components/render-styles.d.ts +1 -1
- package/types/components/render-content/render-content.d.ts +3 -3
- package/types/context/builder.context.d.ts +1 -1
- package/types/context/types.d.ts +1 -1
- package/types/functions/get-content/index.d.ts +5 -5
- package/types/functions/get-global-this.d.ts +4 -2
package/lib/index.qwik.cjs
CHANGED
|
@@ -2,36 +2,37 @@
|
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
3
|
const qwik = require("@builder.io/qwik");
|
|
4
4
|
const jsxRuntime = require("@builder.io/qwik/jsx-runtime");
|
|
5
|
-
const Button = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
6
|
-
qwik.useStylesScopedQrl(qwik.inlinedQrl(STYLES$3, "Button_component_useStylesScoped_a1JZ0Q0Q2Oc"));
|
|
7
|
-
return /* @__PURE__ */
|
|
8
|
-
children: props.link ? /* @__PURE__ */
|
|
5
|
+
const Button = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
6
|
+
qwik.useStylesScopedQrl(/* @__PURE__ */ qwik.inlinedQrl(STYLES$3, "Button_component_useStylesScoped_a1JZ0Q0Q2Oc"));
|
|
7
|
+
return /* @__PURE__ */ qwik._jsxC(jsxRuntime.Fragment, {
|
|
8
|
+
children: props.link ? /* @__PURE__ */ qwik._jsxQ("a", {
|
|
9
|
+
...props.attributes
|
|
10
|
+
}, {
|
|
9
11
|
role: "button",
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
}),
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
}, "jc_0");
|
|
12
|
+
href: qwik._fnSignal((p0) => p0.link, [
|
|
13
|
+
props
|
|
14
|
+
], "p0.link"),
|
|
15
|
+
target: qwik._fnSignal((p0) => p0.openLinkInNewTab ? "_blank" : void 0, [
|
|
16
|
+
props
|
|
17
|
+
], 'p0.openLinkInNewTab?"_blank":undefined')
|
|
18
|
+
}, qwik._fnSignal((p0) => p0.text, [
|
|
19
|
+
props
|
|
20
|
+
], "p0.text"), 2, "jc_0") : /* @__PURE__ */ qwik._jsxQ("button", {
|
|
21
|
+
class: (() => {
|
|
22
|
+
props.attributes.class;
|
|
23
|
+
})(),
|
|
24
|
+
...props.attributes
|
|
25
|
+
}, null, qwik._fnSignal((p0) => p0.text, [
|
|
26
|
+
props
|
|
27
|
+
], "p0.text"), 2, null)
|
|
28
|
+
}, 1, "jc_1");
|
|
28
29
|
}, "Button_component_gJoMUICXoUQ"));
|
|
29
30
|
const STYLES$3 = `
|
|
30
31
|
.button-Button {
|
|
31
32
|
all: unset;
|
|
32
33
|
}
|
|
33
34
|
`;
|
|
34
|
-
const builderContext = qwik.
|
|
35
|
+
const builderContext = qwik.createContextId("Builder");
|
|
35
36
|
const TARGET = "qwik";
|
|
36
37
|
function isBrowser() {
|
|
37
38
|
return typeof window !== "undefined" && typeof document !== "undefined";
|
|
@@ -177,19 +178,11 @@ const tag$1 = function tag2(props, state) {
|
|
|
177
178
|
const RenderInlinedStyles = (props) => {
|
|
178
179
|
const state = {};
|
|
179
180
|
state.tag = tag$1();
|
|
180
|
-
return /* @__PURE__ */
|
|
181
|
-
children: /* @__PURE__ */
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
[qwik._IMMUTABLE]: {
|
|
186
|
-
dangerouslySetInnerHTML: qwik._wrapSignal(props, "styles")
|
|
187
|
-
}
|
|
188
|
-
}),
|
|
189
|
-
[qwik._IMMUTABLE]: {
|
|
190
|
-
children: false
|
|
191
|
-
}
|
|
192
|
-
}, "zz_0");
|
|
181
|
+
return /* @__PURE__ */ qwik._jsxC(jsxRuntime.Fragment, {
|
|
182
|
+
children: /* @__PURE__ */ qwik._jsxQ("style", {
|
|
183
|
+
dangerouslySetInnerHTML: qwik._wrapSignal(props, "styles")
|
|
184
|
+
}, null, null, 3, "zz_0")
|
|
185
|
+
}, 1, "zz_2");
|
|
193
186
|
};
|
|
194
187
|
const useBlock$1 = function useBlock2(props, state) {
|
|
195
188
|
return getProcessedBlock({
|
|
@@ -235,21 +228,19 @@ const css = function css2(props, state) {
|
|
|
235
228
|
].join(" ");
|
|
236
229
|
};
|
|
237
230
|
const BlockStyles = (props) => {
|
|
238
|
-
|
|
239
|
-
|
|
231
|
+
qwik._jsxBranch();
|
|
232
|
+
return /* @__PURE__ */ qwik._jsxC(jsxRuntime.Fragment, {
|
|
233
|
+
children: css(props) && canShowBlock$1(props) ? /* @__PURE__ */ qwik._jsxC(RenderInlinedStyles, {
|
|
240
234
|
styles: css(props)
|
|
241
|
-
}, "LQ_0") : null
|
|
242
|
-
|
|
243
|
-
children: false
|
|
244
|
-
}
|
|
245
|
-
}, "LQ_1");
|
|
235
|
+
}, 3, "LQ_0") : null
|
|
236
|
+
}, 1, "LQ_1");
|
|
246
237
|
};
|
|
247
238
|
function capitalizeFirstLetter(string) {
|
|
248
239
|
return string.charAt(0).toUpperCase() + string.slice(1);
|
|
249
240
|
}
|
|
250
241
|
const getEventHandlerName = (key) => `on${capitalizeFirstLetter(key)}$`;
|
|
251
242
|
function createEventHandler(value, options) {
|
|
252
|
-
return qwik.inlinedQrl((event) => {
|
|
243
|
+
return /* @__PURE__ */ qwik.inlinedQrl((event) => {
|
|
253
244
|
const [options2, value2] = qwik.useLexicalScope();
|
|
254
245
|
return evaluate({
|
|
255
246
|
code: value2,
|
|
@@ -382,40 +373,37 @@ const getRepeatItemData = ({ block, context }) => {
|
|
|
382
373
|
return repeatArray;
|
|
383
374
|
};
|
|
384
375
|
const RenderComponent = (props) => {
|
|
385
|
-
return /* @__PURE__ */
|
|
386
|
-
children: props.componentRef ? /* @__PURE__ */
|
|
376
|
+
return /* @__PURE__ */ qwik._jsxC(jsxRuntime.Fragment, {
|
|
377
|
+
children: props.componentRef ? /* @__PURE__ */ qwik._jsxC(props.componentRef, {
|
|
387
378
|
...props.componentOptions,
|
|
388
379
|
children: [
|
|
389
380
|
(props.blockChildren || []).map(function(child) {
|
|
390
|
-
return /* @__PURE__ */
|
|
381
|
+
return /* @__PURE__ */ qwik._jsxC(RenderBlock, {
|
|
391
382
|
block: child,
|
|
392
383
|
get context() {
|
|
393
384
|
return props.context;
|
|
394
385
|
},
|
|
395
386
|
[qwik._IMMUTABLE]: {
|
|
396
|
-
context: qwik.
|
|
387
|
+
context: qwik._wrapProp(props, "context")
|
|
397
388
|
}
|
|
398
|
-
}, "render-block-" + child.id);
|
|
389
|
+
}, 3, "render-block-" + child.id);
|
|
399
390
|
}),
|
|
400
391
|
(props.blockChildren || []).map(function(child) {
|
|
401
|
-
return /* @__PURE__ */
|
|
392
|
+
return /* @__PURE__ */ qwik._jsxC(BlockStyles, {
|
|
402
393
|
block: child,
|
|
403
394
|
get context() {
|
|
404
395
|
return props.context;
|
|
405
396
|
},
|
|
406
397
|
[qwik._IMMUTABLE]: {
|
|
407
|
-
context: qwik.
|
|
398
|
+
context: qwik._wrapProp(props, "context")
|
|
408
399
|
}
|
|
409
|
-
}, "block-style-" + child.id);
|
|
400
|
+
}, 3, "block-style-" + child.id);
|
|
410
401
|
})
|
|
411
402
|
]
|
|
412
|
-
}) : null
|
|
413
|
-
|
|
414
|
-
children: false
|
|
415
|
-
}
|
|
416
|
-
}, "R9_0");
|
|
403
|
+
}, 0, "R9_0") : null
|
|
404
|
+
}, 1, "R9_1");
|
|
417
405
|
};
|
|
418
|
-
const RenderRepeatedBlock = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
406
|
+
const RenderRepeatedBlock = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
419
407
|
qwik.useContextProvider(builderContext, qwik.useStore({
|
|
420
408
|
content: props.repeatContext.content,
|
|
421
409
|
state: props.repeatContext.state,
|
|
@@ -424,7 +412,7 @@ const RenderRepeatedBlock = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((p
|
|
|
424
412
|
registeredComponents: props.repeatContext.registeredComponents,
|
|
425
413
|
inheritedStyles: props.repeatContext.inheritedStyles
|
|
426
414
|
}));
|
|
427
|
-
return /* @__PURE__ */
|
|
415
|
+
return /* @__PURE__ */ qwik._jsxC(RenderBlock, {
|
|
428
416
|
get block() {
|
|
429
417
|
return props.block;
|
|
430
418
|
},
|
|
@@ -432,10 +420,14 @@ const RenderRepeatedBlock = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((p
|
|
|
432
420
|
return props.repeatContext;
|
|
433
421
|
},
|
|
434
422
|
[qwik._IMMUTABLE]: {
|
|
435
|
-
block: qwik.
|
|
436
|
-
|
|
423
|
+
block: qwik._fnSignal((p0) => p0.block, [
|
|
424
|
+
props
|
|
425
|
+
], "p0.block"),
|
|
426
|
+
context: qwik._fnSignal((p0) => p0.repeatContext, [
|
|
427
|
+
props
|
|
428
|
+
], "p0.repeatContext")
|
|
437
429
|
}
|
|
438
|
-
}, "K5_0");
|
|
430
|
+
}, 3, "K5_0");
|
|
439
431
|
}, "RenderRepeatedBlock_component_nRyVBtbGKc8"));
|
|
440
432
|
const component = function component2(props, state) {
|
|
441
433
|
return getComponent({
|
|
@@ -521,6 +513,7 @@ const childrenContext = function childrenContext2(props, state) {
|
|
|
521
513
|
};
|
|
522
514
|
return {
|
|
523
515
|
apiKey: props.context.apiKey,
|
|
516
|
+
apiVersion: props.context.apiVersion,
|
|
524
517
|
state: props.context.state,
|
|
525
518
|
content: props.context.content,
|
|
526
519
|
context: props.context.context,
|
|
@@ -530,17 +523,18 @@ const childrenContext = function childrenContext2(props, state) {
|
|
|
530
523
|
};
|
|
531
524
|
};
|
|
532
525
|
const RenderBlock = (props) => {
|
|
526
|
+
qwik._jsxBranch();
|
|
533
527
|
const state = {};
|
|
534
528
|
state.tag = tag(props);
|
|
535
|
-
return /* @__PURE__ */
|
|
536
|
-
children: canShowBlock(props) ? !component(props)?.noWrap ? /* @__PURE__ */
|
|
529
|
+
return /* @__PURE__ */ qwik._jsxC(jsxRuntime.Fragment, {
|
|
530
|
+
children: canShowBlock(props) ? !component(props)?.noWrap ? /* @__PURE__ */ qwik._jsxC(jsxRuntime.Fragment, {
|
|
537
531
|
children: [
|
|
538
|
-
isEmptyHtmlElement(tag(props)) ? /* @__PURE__ */
|
|
532
|
+
isEmptyHtmlElement(tag(props)) ? /* @__PURE__ */ qwik._jsxC(state.tag, {
|
|
539
533
|
...attributes(props),
|
|
540
534
|
...actions(props)
|
|
541
|
-
}) : null,
|
|
535
|
+
}, 2, "9d_0") : null,
|
|
542
536
|
!isEmptyHtmlElement(tag(props)) && repeatItemData(props) ? (repeatItemData(props) || []).map(function(data, index) {
|
|
543
|
-
return /* @__PURE__ */
|
|
537
|
+
return /* @__PURE__ */ qwik._jsxC(RenderRepeatedBlock, {
|
|
544
538
|
get repeatContext() {
|
|
545
539
|
return data.context;
|
|
546
540
|
},
|
|
@@ -548,45 +542,38 @@ const RenderBlock = (props) => {
|
|
|
548
542
|
return data.block;
|
|
549
543
|
},
|
|
550
544
|
[qwik._IMMUTABLE]: {
|
|
551
|
-
repeatContext: qwik.
|
|
552
|
-
block: qwik.
|
|
545
|
+
repeatContext: qwik._wrapProp(data, "context"),
|
|
546
|
+
block: qwik._wrapProp(data, "block")
|
|
553
547
|
}
|
|
554
|
-
}, index);
|
|
548
|
+
}, 3, index);
|
|
555
549
|
}) : null,
|
|
556
|
-
!isEmptyHtmlElement(tag(props)) && !repeatItemData(props) ? /* @__PURE__ */
|
|
550
|
+
!isEmptyHtmlElement(tag(props)) && !repeatItemData(props) ? /* @__PURE__ */ qwik._jsxC(state.tag, {
|
|
557
551
|
...attributes(props),
|
|
558
552
|
...actions(props),
|
|
559
553
|
children: [
|
|
560
|
-
/* @__PURE__ */
|
|
554
|
+
/* @__PURE__ */ qwik._jsxC(RenderComponent, {
|
|
561
555
|
...renderComponentProps(props)
|
|
562
|
-
}, "
|
|
556
|
+
}, 2, "9d_1"),
|
|
563
557
|
(childrenWithoutParentComponent(props) || []).map(function(child) {
|
|
564
|
-
return /* @__PURE__ */
|
|
558
|
+
return /* @__PURE__ */ qwik._jsxC(RenderBlock, {
|
|
565
559
|
block: child,
|
|
566
560
|
context: childrenContext(props)
|
|
567
|
-
}, "render-block-" + child.id);
|
|
561
|
+
}, 3, "render-block-" + child.id);
|
|
568
562
|
}),
|
|
569
563
|
(childrenWithoutParentComponent(props) || []).map(function(child) {
|
|
570
|
-
return /* @__PURE__ */
|
|
564
|
+
return /* @__PURE__ */ qwik._jsxC(BlockStyles, {
|
|
571
565
|
block: child,
|
|
572
566
|
context: childrenContext(props)
|
|
573
|
-
}, "block-style-" + child.id);
|
|
567
|
+
}, 3, "block-style-" + child.id);
|
|
574
568
|
})
|
|
575
569
|
]
|
|
576
|
-
}) : null
|
|
577
|
-
]
|
|
578
|
-
|
|
579
|
-
children: false
|
|
580
|
-
}
|
|
581
|
-
}, "9d_1") : /* @__PURE__ */ jsxRuntime.jsx(RenderComponent, {
|
|
570
|
+
}, 0, "9d_2") : null
|
|
571
|
+
]
|
|
572
|
+
}, 1, "9d_3") : /* @__PURE__ */ qwik._jsxC(RenderComponent, {
|
|
582
573
|
...renderComponentProps(props)
|
|
583
|
-
}, "
|
|
584
|
-
|
|
585
|
-
children: false
|
|
586
|
-
}
|
|
587
|
-
}, "9d_3");
|
|
574
|
+
}, 2, "9d_4") : null
|
|
575
|
+
}, 1, "9d_5");
|
|
588
576
|
};
|
|
589
|
-
const RenderBlock$1 = RenderBlock;
|
|
590
577
|
const className = function className2(props, state, builderContext2) {
|
|
591
578
|
return "builder-blocks" + (!props.blocks?.length ? " no-blocks" : "");
|
|
592
579
|
};
|
|
@@ -610,22 +597,13 @@ const onMouseEnter = function onMouseEnter2(props, state, builderContext2) {
|
|
|
610
597
|
}
|
|
611
598
|
}, "*");
|
|
612
599
|
};
|
|
613
|
-
const RenderBlocks = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
614
|
-
qwik.useStylesScopedQrl(qwik.inlinedQrl(STYLES$2, "RenderBlocks_component_useStylesScoped_0XKYzaR059E"));
|
|
600
|
+
const RenderBlocks = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
601
|
+
qwik.useStylesScopedQrl(/* @__PURE__ */ qwik.inlinedQrl(STYLES$2, "RenderBlocks_component_useStylesScoped_0XKYzaR059E"));
|
|
615
602
|
const builderContext$1 = qwik.useContext(builderContext);
|
|
616
603
|
const state = {};
|
|
617
|
-
return /* @__PURE__ */
|
|
604
|
+
return /* @__PURE__ */ qwik._jsxQ("div", {
|
|
618
605
|
class: className(props) + " div-RenderBlocks",
|
|
619
|
-
|
|
620
|
-
return props.path;
|
|
621
|
-
},
|
|
622
|
-
get "builder-parent-id"() {
|
|
623
|
-
return props.parent;
|
|
624
|
-
},
|
|
625
|
-
get style() {
|
|
626
|
-
return props.styleProp;
|
|
627
|
-
},
|
|
628
|
-
onClick$: qwik.inlinedQrl((event) => {
|
|
606
|
+
onClick$: /* @__PURE__ */ qwik.inlinedQrl((event) => {
|
|
629
607
|
const [builderContext2, props2, state2] = qwik.useLexicalScope();
|
|
630
608
|
return onClick$1(props2);
|
|
631
609
|
}, "RenderBlocks_component_div_onClick_RzhhZa265Yg", [
|
|
@@ -633,35 +611,44 @@ const RenderBlocks = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) =
|
|
|
633
611
|
props,
|
|
634
612
|
state
|
|
635
613
|
]),
|
|
636
|
-
onMouseEnter$: qwik.inlinedQrl((event) => {
|
|
614
|
+
onMouseEnter$: /* @__PURE__ */ qwik.inlinedQrl((event) => {
|
|
637
615
|
const [builderContext2, props2, state2] = qwik.useLexicalScope();
|
|
638
616
|
return onMouseEnter(props2);
|
|
639
617
|
}, "RenderBlocks_component_div_onMouseEnter_nG7I7RYG3JQ", [
|
|
640
618
|
builderContext$1,
|
|
641
619
|
props,
|
|
642
620
|
state
|
|
643
|
-
])
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
}
|
|
664
|
-
|
|
621
|
+
])
|
|
622
|
+
}, {
|
|
623
|
+
"builder-path": qwik._fnSignal((p0) => p0.path, [
|
|
624
|
+
props
|
|
625
|
+
], "p0.path"),
|
|
626
|
+
"builder-parent-id": qwik._fnSignal((p0) => p0.parent, [
|
|
627
|
+
props
|
|
628
|
+
], "p0.parent"),
|
|
629
|
+
style: qwik._fnSignal((p0) => p0.styleProp, [
|
|
630
|
+
props
|
|
631
|
+
], "p0.styleProp")
|
|
632
|
+
}, [
|
|
633
|
+
props.blocks ? (props.blocks || []).map(function(block) {
|
|
634
|
+
return /* @__PURE__ */ qwik._jsxC(RenderBlock, {
|
|
635
|
+
block,
|
|
636
|
+
context: builderContext$1,
|
|
637
|
+
[qwik._IMMUTABLE]: {
|
|
638
|
+
context: qwik._IMMUTABLE
|
|
639
|
+
}
|
|
640
|
+
}, 3, "render-block-" + block.id);
|
|
641
|
+
}) : null,
|
|
642
|
+
props.blocks ? (props.blocks || []).map(function(block) {
|
|
643
|
+
return /* @__PURE__ */ qwik._jsxC(BlockStyles, {
|
|
644
|
+
block,
|
|
645
|
+
context: builderContext$1,
|
|
646
|
+
[qwik._IMMUTABLE]: {
|
|
647
|
+
context: qwik._IMMUTABLE
|
|
648
|
+
}
|
|
649
|
+
}, 3, "block-style-" + block.id);
|
|
650
|
+
}) : null
|
|
651
|
+
], 0, "9R_0");
|
|
665
652
|
}, "RenderBlocks_component_MYUZ0j1uLsw"));
|
|
666
653
|
const STYLES$2 = `
|
|
667
654
|
.div-RenderBlocks {
|
|
@@ -696,25 +683,23 @@ const columnCssVars = function columnCssVars2(props, state, builderContext2, ind
|
|
|
696
683
|
index === 0 ? 0 : state.gutterSize;
|
|
697
684
|
const width = getColumnCssWidth(props, state, builderContext2, index);
|
|
698
685
|
const gutterPixels = `${state.gutterSize}px`;
|
|
699
|
-
const mobileWidth = "100%";
|
|
700
|
-
const mobileMarginLeft = 0;
|
|
701
686
|
return {
|
|
702
687
|
width,
|
|
703
688
|
"margin-left": gutterPixels,
|
|
704
689
|
"--column-width-mobile": getMobileStyle(props, state, builderContext2, {
|
|
705
|
-
stackedStyle:
|
|
690
|
+
stackedStyle: "100%",
|
|
706
691
|
desktopStyle: width
|
|
707
692
|
}),
|
|
708
693
|
"--column-margin-left-mobile": getMobileStyle(props, state, builderContext2, {
|
|
709
|
-
stackedStyle:
|
|
694
|
+
stackedStyle: 0,
|
|
710
695
|
desktopStyle: gutterPixels
|
|
711
696
|
}),
|
|
712
697
|
"--column-width-tablet": getTabletStyle(props, state, builderContext2, {
|
|
713
|
-
stackedStyle:
|
|
698
|
+
stackedStyle: "100%",
|
|
714
699
|
desktopStyle: width
|
|
715
700
|
}),
|
|
716
701
|
"--column-margin-left-tablet": getTabletStyle(props, state, builderContext2, {
|
|
717
|
-
stackedStyle:
|
|
702
|
+
stackedStyle: 0,
|
|
718
703
|
desktopStyle: gutterPixels
|
|
719
704
|
})
|
|
720
705
|
};
|
|
@@ -750,8 +735,9 @@ const columnsStyles = function columnsStyles2(props, state, builderContext2) {
|
|
|
750
735
|
},
|
|
751
736
|
`;
|
|
752
737
|
};
|
|
753
|
-
const Columns = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
754
|
-
qwik.
|
|
738
|
+
const Columns = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
739
|
+
qwik._jsxBranch();
|
|
740
|
+
qwik.useStylesScopedQrl(/* @__PURE__ */ qwik.inlinedQrl(STYLES$1, "Columns_component_useStylesScoped_s7JLZz7MCCQ"));
|
|
755
741
|
const builderContext$1 = qwik.useContext(builderContext);
|
|
756
742
|
const state = qwik.useStore({
|
|
757
743
|
cols: props.columns || [],
|
|
@@ -759,40 +745,41 @@ const Columns = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
|
759
745
|
gutterSize: typeof props.space === "number" ? props.space || 0 : 20,
|
|
760
746
|
stackAt: props.stackColumnsAt || "tablet"
|
|
761
747
|
});
|
|
762
|
-
return /* @__PURE__ */
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
748
|
+
return /* @__PURE__ */ qwik._jsxQ("div", {
|
|
749
|
+
style: columnsCssVars(props, state, builderContext$1)
|
|
750
|
+
}, {
|
|
751
|
+
class: qwik._fnSignal((p0) => `builder-columns ${p0.builderBlock.id}-breakpoints div-Columns`, [
|
|
752
|
+
props
|
|
753
|
+
], '`builder-columns ${p0.builderBlock.id}-breakpoints`+" div-Columns"')
|
|
754
|
+
}, [
|
|
755
|
+
/* @__PURE__ */ qwik._jsxC(RenderInlinedStyles, {
|
|
756
|
+
styles: columnsStyles(props, state, builderContext$1)
|
|
757
|
+
}, 3, "c0_0"),
|
|
758
|
+
(props.columns || []).map(function(column, index) {
|
|
759
|
+
return /* @__PURE__ */ qwik._jsxQ("div", {
|
|
760
|
+
style: columnCssVars(props, state, builderContext$1, index)
|
|
761
|
+
}, {
|
|
762
|
+
class: "builder-column div-Columns-2"
|
|
763
|
+
}, /* @__PURE__ */ qwik._jsxC(RenderBlocks, {
|
|
764
|
+
get blocks() {
|
|
765
|
+
return column.blocks;
|
|
766
|
+
},
|
|
767
|
+
path: `component.options.columns.${index}.blocks`,
|
|
768
|
+
get parent() {
|
|
769
|
+
return props.builderBlock.id;
|
|
770
|
+
},
|
|
771
|
+
styleProp: {
|
|
772
|
+
flexGrow: "1"
|
|
773
|
+
},
|
|
774
|
+
[qwik._IMMUTABLE]: {
|
|
775
|
+
blocks: qwik._wrapProp(column, "blocks"),
|
|
776
|
+
parent: qwik._fnSignal((p0) => p0.builderBlock.id, [
|
|
777
|
+
props
|
|
778
|
+
], "p0.builderBlock.id")
|
|
779
|
+
}
|
|
780
|
+
}, 3, "c0_1"), 1, index);
|
|
781
|
+
})
|
|
782
|
+
], 1, "c0_2");
|
|
796
783
|
}, "Columns_component_7yLj4bxdI6c"));
|
|
797
784
|
const STYLES$1 = `
|
|
798
785
|
.div-Columns {
|
|
@@ -805,10 +792,8 @@ const STYLES$1 = `
|
|
|
805
792
|
align-items: stretch;
|
|
806
793
|
}
|
|
807
794
|
`;
|
|
808
|
-
const FragmentComponent = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
809
|
-
return /* @__PURE__ */
|
|
810
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(qwik.Slot, {}, "oj_0")
|
|
811
|
-
});
|
|
795
|
+
const FragmentComponent = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
796
|
+
return /* @__PURE__ */ qwik._jsxQ("span", null, null, /* @__PURE__ */ qwik._jsxC(qwik.Slot, null, 3, "oj_0"), 1, "oj_1");
|
|
812
797
|
}, "FragmentComponent_component_T0AypnadAK0"));
|
|
813
798
|
function removeProtocol(path) {
|
|
814
799
|
return path.replace(/http(s)?:/, "");
|
|
@@ -866,17 +851,16 @@ function getSrcSet(url) {
|
|
|
866
851
|
}
|
|
867
852
|
const srcSetToUse = function srcSetToUse2(props, state) {
|
|
868
853
|
const imageToUse = props.image || props.src;
|
|
869
|
-
|
|
870
|
-
if (!url || !(url.match(/builder\.io/) || url.match(/cdn\.shopify\.com/)))
|
|
854
|
+
if (!imageToUse || !(imageToUse.match(/builder\.io/) || imageToUse.match(/cdn\.shopify\.com/)))
|
|
871
855
|
return props.srcset;
|
|
872
856
|
if (props.srcset && props.image?.includes("builder.io/api/v1/image")) {
|
|
873
857
|
if (!props.srcset.includes(props.image.split("?")[0])) {
|
|
874
858
|
console.debug("Removed given srcset");
|
|
875
|
-
return getSrcSet(
|
|
859
|
+
return getSrcSet(imageToUse);
|
|
876
860
|
}
|
|
877
861
|
} else if (props.image && !props.srcset)
|
|
878
|
-
return getSrcSet(
|
|
879
|
-
return getSrcSet(
|
|
862
|
+
return getSrcSet(imageToUse);
|
|
863
|
+
return getSrcSet(imageToUse);
|
|
880
864
|
};
|
|
881
865
|
const webpSrcSet = function webpSrcSet2(props, state) {
|
|
882
866
|
if (srcSetToUse(props)?.match(/builder\.io/) && !props.noWebp)
|
|
@@ -895,62 +879,57 @@ const aspectRatioCss = function aspectRatioCss2(props, state) {
|
|
|
895
879
|
const out = props.aspectRatio ? aspectRatioStyles : void 0;
|
|
896
880
|
return out;
|
|
897
881
|
};
|
|
898
|
-
const Image = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
899
|
-
qwik.
|
|
900
|
-
|
|
882
|
+
const Image = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
883
|
+
qwik._jsxBranch();
|
|
884
|
+
qwik.useStylesScopedQrl(/* @__PURE__ */ qwik.inlinedQrl(STYLES, "Image_component_useStylesScoped_fBMYiVf9fuU"));
|
|
885
|
+
return /* @__PURE__ */ qwik._jsxC(qwik.Fragment, {
|
|
901
886
|
children: [
|
|
902
|
-
/* @__PURE__ */
|
|
903
|
-
|
|
904
|
-
webpSrcSet(props)
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
children: false
|
|
936
|
-
}
|
|
937
|
-
}),
|
|
938
|
-
props.aspectRatio && !(props.builderBlock?.children?.length && props.fitContent) ? /* @__PURE__ */ jsxRuntime.jsx("div", {
|
|
887
|
+
/* @__PURE__ */ qwik._jsxQ("picture", null, null, [
|
|
888
|
+
webpSrcSet(props) ? /* @__PURE__ */ qwik._jsxQ("source", {
|
|
889
|
+
srcSet: webpSrcSet(props)
|
|
890
|
+
}, {
|
|
891
|
+
type: "image/webp"
|
|
892
|
+
}, null, 3, "0A_0") : null,
|
|
893
|
+
/* @__PURE__ */ qwik._jsxQ("img", {
|
|
894
|
+
style: {
|
|
895
|
+
objectPosition: props.backgroundPosition || "center",
|
|
896
|
+
objectFit: props.backgroundSize || "cover",
|
|
897
|
+
...aspectRatioCss(props)
|
|
898
|
+
},
|
|
899
|
+
srcSet: srcSetToUse(props)
|
|
900
|
+
}, {
|
|
901
|
+
loading: "lazy",
|
|
902
|
+
alt: qwik._fnSignal((p0) => p0.altText, [
|
|
903
|
+
props
|
|
904
|
+
], "p0.altText"),
|
|
905
|
+
role: qwik._fnSignal((p0) => p0.altText ? "presentation" : void 0, [
|
|
906
|
+
props
|
|
907
|
+
], 'p0.altText?"presentation":undefined'),
|
|
908
|
+
class: qwik._fnSignal((p0) => "builder-image" + (p0.className ? " " + p0.className : "") + " img-Image", [
|
|
909
|
+
props
|
|
910
|
+
], '"builder-image"+(p0.className?" "+p0.className:"")+" img-Image"'),
|
|
911
|
+
src: qwik._fnSignal((p0) => p0.image, [
|
|
912
|
+
props
|
|
913
|
+
], "p0.image"),
|
|
914
|
+
sizes: qwik._fnSignal((p0) => p0.sizes, [
|
|
915
|
+
props
|
|
916
|
+
], "p0.sizes")
|
|
917
|
+
}, null, 3, null)
|
|
918
|
+
], 1, null),
|
|
919
|
+
props.aspectRatio && !(props.builderBlock?.children?.length && props.fitContent) ? /* @__PURE__ */ qwik._jsxQ("div", null, {
|
|
939
920
|
class: "builder-image-sizer div-Image",
|
|
940
|
-
style: {
|
|
941
|
-
paddingTop:
|
|
942
|
-
}
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
}
|
|
953
|
-
}, "0A_2");
|
|
921
|
+
style: qwik._fnSignal((p0) => ({
|
|
922
|
+
paddingTop: p0.aspectRatio * 100 + "%"
|
|
923
|
+
}), [
|
|
924
|
+
props
|
|
925
|
+
], '{paddingTop:p0.aspectRatio*100+"%"}')
|
|
926
|
+
}, null, 3, "0A_1") : null,
|
|
927
|
+
props.builderBlock?.children?.length && props.fitContent ? /* @__PURE__ */ qwik._jsxC(qwik.Slot, null, 3, "0A_2") : null,
|
|
928
|
+
!props.fitContent && props.children ? /* @__PURE__ */ qwik._jsxQ("div", null, {
|
|
929
|
+
class: "div-Image-2"
|
|
930
|
+
}, /* @__PURE__ */ qwik._jsxC(qwik.Slot, null, 3, "0A_3"), 1, "0A_4") : null
|
|
931
|
+
]
|
|
932
|
+
}, 1, "0A_5");
|
|
954
933
|
}, "Image_component_LRxDkFa1EfU"));
|
|
955
934
|
const STYLES = `
|
|
956
935
|
.img-Image {
|
|
@@ -1287,7 +1266,6 @@ const componentInfo$7 = {
|
|
|
1287
1266
|
required: true,
|
|
1288
1267
|
defaultValue: "https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",
|
|
1289
1268
|
onChange: serializeFn((options) => {
|
|
1290
|
-
const DEFAULT_ASPECT_RATIO = 0.7041;
|
|
1291
1269
|
options.delete("srcset");
|
|
1292
1270
|
options.delete("noWebp");
|
|
1293
1271
|
function loadImage(url, timeout = 6e4) {
|
|
@@ -1318,10 +1296,10 @@ const componentInfo$7 = {
|
|
|
1318
1296
|
if (blob.type.includes("svg"))
|
|
1319
1297
|
options.set("noWebp", true);
|
|
1320
1298
|
});
|
|
1321
|
-
if (value && (!aspectRatio || aspectRatio ===
|
|
1299
|
+
if (value && (!aspectRatio || aspectRatio === 0.7041))
|
|
1322
1300
|
return loadImage(value).then((img) => {
|
|
1323
1301
|
const possiblyUpdatedAspectRatio = options.get("aspectRatio");
|
|
1324
|
-
if (options.get("image") === value && (!possiblyUpdatedAspectRatio || possiblyUpdatedAspectRatio ===
|
|
1302
|
+
if (options.get("image") === value && (!possiblyUpdatedAspectRatio || possiblyUpdatedAspectRatio === 0.7041)) {
|
|
1325
1303
|
if (img.width && img.height) {
|
|
1326
1304
|
options.set("aspectRatio", round2(img.height / img.width));
|
|
1327
1305
|
options.set("height", img.height);
|
|
@@ -1455,8 +1433,8 @@ const componentInfo$6 = {
|
|
|
1455
1433
|
}
|
|
1456
1434
|
]
|
|
1457
1435
|
};
|
|
1458
|
-
const SectionComponent = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
1459
|
-
return /* @__PURE__ */
|
|
1436
|
+
const SectionComponent = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
1437
|
+
return /* @__PURE__ */ qwik._jsxQ("section", {
|
|
1460
1438
|
...props.attributes,
|
|
1461
1439
|
style: {
|
|
1462
1440
|
width: "100%",
|
|
@@ -1469,9 +1447,8 @@ const SectionComponent = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((prop
|
|
|
1469
1447
|
alignItems: "stretch",
|
|
1470
1448
|
marginLeft: "auto",
|
|
1471
1449
|
marginRight: "auto"
|
|
1472
|
-
}
|
|
1473
|
-
|
|
1474
|
-
});
|
|
1450
|
+
}
|
|
1451
|
+
}, null, /* @__PURE__ */ qwik._jsxC(qwik.Slot, null, 3, "2Y_0"), 0, "2Y_1");
|
|
1475
1452
|
}, "SectionComponent_component_ZWF9iD5WeLg"));
|
|
1476
1453
|
const componentInfo$5 = {
|
|
1477
1454
|
name: "Symbol",
|
|
@@ -1608,8 +1585,7 @@ const setCookie = async ({ name, value, expires, canTrack }) => {
|
|
|
1608
1585
|
console.warn("[COOKIE] SET error: ", err);
|
|
1609
1586
|
}
|
|
1610
1587
|
};
|
|
1611
|
-
const
|
|
1612
|
-
const getContentTestKey = (id) => `${BUILDER_STORE_PREFIX}.${id}`;
|
|
1588
|
+
const getContentTestKey = (id) => `${"builderio.variations"}.${id}`;
|
|
1613
1589
|
const getContentVariationCookie = ({ contentId, canTrack }) => getCookie({
|
|
1614
1590
|
name: getContentTestKey(contentId),
|
|
1615
1591
|
canTrack
|
|
@@ -1623,11 +1599,11 @@ const checkIsBuilderContentWithVariations = (item) => checkIsDefined(item.id) &&
|
|
|
1623
1599
|
const getRandomVariationId = ({ id, variations }) => {
|
|
1624
1600
|
let n = 0;
|
|
1625
1601
|
const random = Math.random();
|
|
1626
|
-
for (const
|
|
1627
|
-
const testRatio = variations[
|
|
1602
|
+
for (const id2 in variations) {
|
|
1603
|
+
const testRatio = variations[id2]?.testRatio;
|
|
1628
1604
|
n += testRatio;
|
|
1629
1605
|
if (random < n)
|
|
1630
|
-
return
|
|
1606
|
+
return id2;
|
|
1631
1607
|
}
|
|
1632
1608
|
return id;
|
|
1633
1609
|
};
|
|
@@ -1704,8 +1680,6 @@ function flatten(object, path = null, separator = ".") {
|
|
|
1704
1680
|
};
|
|
1705
1681
|
}, {});
|
|
1706
1682
|
}
|
|
1707
|
-
const BUILDER_SEARCHPARAMS_PREFIX = "builder.";
|
|
1708
|
-
const BUILDER_OPTIONS_PREFIX = "options.";
|
|
1709
1683
|
const convertSearchParamsToQueryObject = (searchParams) => {
|
|
1710
1684
|
const options = {};
|
|
1711
1685
|
searchParams.forEach((value, key) => {
|
|
@@ -1719,8 +1693,8 @@ const getBuilderSearchParams = (_options) => {
|
|
|
1719
1693
|
const options = normalizeSearchParams(_options);
|
|
1720
1694
|
const newOptions = {};
|
|
1721
1695
|
Object.keys(options).forEach((key) => {
|
|
1722
|
-
if (key.startsWith(
|
|
1723
|
-
const trimmedKey = key.replace(
|
|
1696
|
+
if (key.startsWith("builder.")) {
|
|
1697
|
+
const trimmedKey = key.replace("builder.", "").replace("options.", "");
|
|
1724
1698
|
newOptions[trimmedKey] = options[key];
|
|
1725
1699
|
}
|
|
1726
1700
|
});
|
|
@@ -1753,31 +1727,42 @@ const generateContentUrl = (options) => {
|
|
|
1753
1727
|
if (userAttributes)
|
|
1754
1728
|
url.searchParams.set("userAttributes", JSON.stringify(userAttributes));
|
|
1755
1729
|
if (query) {
|
|
1756
|
-
const
|
|
1730
|
+
const flattened2 = flatten({
|
|
1757
1731
|
query
|
|
1758
1732
|
});
|
|
1759
|
-
for (const
|
|
1760
|
-
url.searchParams.set(
|
|
1733
|
+
for (const key in flattened2)
|
|
1734
|
+
url.searchParams.set(key, JSON.stringify(flattened2[key]));
|
|
1761
1735
|
}
|
|
1762
1736
|
return url;
|
|
1763
1737
|
};
|
|
1764
1738
|
async function getContent(options) {
|
|
1765
|
-
|
|
1739
|
+
const allContent = await getAllContent({
|
|
1766
1740
|
...options,
|
|
1767
1741
|
limit: 1
|
|
1768
|
-
})
|
|
1742
|
+
});
|
|
1743
|
+
if ("results" in allContent)
|
|
1744
|
+
return allContent?.results[0] || null;
|
|
1745
|
+
return null;
|
|
1769
1746
|
}
|
|
1770
1747
|
async function getAllContent(options) {
|
|
1771
1748
|
const url = generateContentUrl(options);
|
|
1772
1749
|
const res = await fetch$1(url.href);
|
|
1773
1750
|
const content = await res.json();
|
|
1751
|
+
if ("status" in content && !("results" in content)) {
|
|
1752
|
+
console.error("[Builder.io]: Error fetching data. ", content, options);
|
|
1753
|
+
return content;
|
|
1754
|
+
}
|
|
1774
1755
|
const canTrack = options.canTrack !== false;
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1756
|
+
try {
|
|
1757
|
+
if (canTrack && Array.isArray(content.results))
|
|
1758
|
+
for (const item of content.results)
|
|
1759
|
+
await handleABTesting({
|
|
1760
|
+
item,
|
|
1761
|
+
canTrack
|
|
1762
|
+
});
|
|
1763
|
+
} catch (e) {
|
|
1764
|
+
console.error("[Builder.io]: Could not setup A/B testing. ", e);
|
|
1765
|
+
}
|
|
1781
1766
|
return content;
|
|
1782
1767
|
}
|
|
1783
1768
|
const fetchContent = function fetchContent2(props, state, builderContext2) {
|
|
@@ -1796,7 +1781,7 @@ const fetchContent = function fetchContent2(props, state, builderContext2) {
|
|
|
1796
1781
|
console.error("[Builder.io]: Could not fetch symbol content: ", err);
|
|
1797
1782
|
});
|
|
1798
1783
|
};
|
|
1799
|
-
const Symbol$1 = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
1784
|
+
const Symbol$1 = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
1800
1785
|
const builderContext$1 = qwik.useContext(builderContext);
|
|
1801
1786
|
const state = qwik.useStore({
|
|
1802
1787
|
className: [
|
|
@@ -1809,15 +1794,15 @@ const Symbol$1 = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
|
1809
1794
|
].filter(Boolean).join(" "),
|
|
1810
1795
|
contentToUse: props.symbol?.content
|
|
1811
1796
|
});
|
|
1812
|
-
qwik.
|
|
1797
|
+
qwik.useVisibleTaskQrl(/* @__PURE__ */ qwik.inlinedQrl(() => {
|
|
1813
1798
|
const [builderContext2, props2, state2] = qwik.useLexicalScope();
|
|
1814
1799
|
fetchContent(props2, state2, builderContext2);
|
|
1815
|
-
}, "
|
|
1800
|
+
}, "Symbol_component_useVisibleTask_oMPs8W5ZhwE", [
|
|
1816
1801
|
builderContext$1,
|
|
1817
1802
|
props,
|
|
1818
1803
|
state
|
|
1819
1804
|
]));
|
|
1820
|
-
qwik.useTaskQrl(qwik.inlinedQrl(({ track: track2 }) => {
|
|
1805
|
+
qwik.useTaskQrl(/* @__PURE__ */ qwik.inlinedQrl(({ track: track2 }) => {
|
|
1821
1806
|
const [builderContext2, props2, state2] = qwik.useLexicalScope();
|
|
1822
1807
|
track2(() => props2.symbol);
|
|
1823
1808
|
fetchContent(props2, state2, builderContext2);
|
|
@@ -1826,42 +1811,68 @@ const Symbol$1 = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
|
1826
1811
|
props,
|
|
1827
1812
|
state
|
|
1828
1813
|
]));
|
|
1829
|
-
return /* @__PURE__ */
|
|
1830
|
-
...props.attributes
|
|
1831
|
-
|
|
1832
|
-
|
|
1814
|
+
return /* @__PURE__ */ qwik._jsxQ("div", {
|
|
1815
|
+
...props.attributes
|
|
1816
|
+
}, {
|
|
1817
|
+
class: qwik._fnSignal((p0) => p0.className, [
|
|
1818
|
+
state
|
|
1819
|
+
], "p0.className")
|
|
1820
|
+
}, /* @__PURE__ */ qwik._jsxC(RenderContent, {
|
|
1821
|
+
get apiVersion() {
|
|
1822
|
+
return builderContext$1.apiVersion;
|
|
1833
1823
|
},
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
data: {
|
|
1824
|
+
get apiKey() {
|
|
1825
|
+
return builderContext$1.apiKey;
|
|
1826
|
+
},
|
|
1827
|
+
get context() {
|
|
1828
|
+
return builderContext$1.context;
|
|
1829
|
+
},
|
|
1830
|
+
get customComponents() {
|
|
1831
|
+
return Object.values(builderContext$1.registeredComponents);
|
|
1832
|
+
},
|
|
1833
|
+
get data() {
|
|
1834
|
+
return {
|
|
1846
1835
|
...props.symbol?.data,
|
|
1847
1836
|
...builderContext$1.state,
|
|
1848
1837
|
...state.contentToUse?.data?.state
|
|
1849
|
-
}
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
context: qwik._wrapSignal(builderContext$1, "context"),
|
|
1858
|
-
content: qwik._wrapSignal(state, "contentToUse")
|
|
1859
|
-
}
|
|
1860
|
-
}, "Wt_0"),
|
|
1838
|
+
};
|
|
1839
|
+
},
|
|
1840
|
+
get model() {
|
|
1841
|
+
return props.symbol?.model;
|
|
1842
|
+
},
|
|
1843
|
+
get content() {
|
|
1844
|
+
return state.contentToUse;
|
|
1845
|
+
},
|
|
1861
1846
|
[qwik._IMMUTABLE]: {
|
|
1862
|
-
|
|
1847
|
+
apiVersion: qwik._fnSignal((p0) => p0.apiVersion, [
|
|
1848
|
+
builderContext$1
|
|
1849
|
+
], "p0.apiVersion"),
|
|
1850
|
+
apiKey: qwik._fnSignal((p0) => p0.apiKey, [
|
|
1851
|
+
builderContext$1
|
|
1852
|
+
], "p0.apiKey"),
|
|
1853
|
+
context: qwik._fnSignal((p0) => p0.context, [
|
|
1854
|
+
builderContext$1
|
|
1855
|
+
], "p0.context"),
|
|
1856
|
+
customComponents: qwik._fnSignal((p0) => Object.values(p0.registeredComponents), [
|
|
1857
|
+
builderContext$1
|
|
1858
|
+
], "Object.values(p0.registeredComponents)"),
|
|
1859
|
+
data: qwik._fnSignal((p0, p1, p2) => ({
|
|
1860
|
+
...p1.symbol?.data,
|
|
1861
|
+
...p0.state,
|
|
1862
|
+
...p2.contentToUse?.data?.state
|
|
1863
|
+
}), [
|
|
1864
|
+
builderContext$1,
|
|
1865
|
+
props,
|
|
1866
|
+
state
|
|
1867
|
+
], "{...p1.symbol?.data,...p0.state,...p2.contentToUse?.data?.state}"),
|
|
1868
|
+
model: qwik._fnSignal((p0) => p0.symbol?.model, [
|
|
1869
|
+
props
|
|
1870
|
+
], "p0.symbol?.model"),
|
|
1871
|
+
content: qwik._fnSignal((p0) => p0.contentToUse, [
|
|
1872
|
+
state
|
|
1873
|
+
], "p0.contentToUse")
|
|
1863
1874
|
}
|
|
1864
|
-
});
|
|
1875
|
+
}, 3, "Wt_0"), 0, "Wt_1");
|
|
1865
1876
|
}, "Symbol_component_WVvggdkUPdk"));
|
|
1866
1877
|
const componentInfo$4 = {
|
|
1867
1878
|
name: "Text",
|
|
@@ -1883,19 +1894,17 @@ const componentInfo$4 = {
|
|
|
1883
1894
|
textAlign: "center"
|
|
1884
1895
|
}
|
|
1885
1896
|
};
|
|
1886
|
-
const Text = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
1887
|
-
return /* @__PURE__ */
|
|
1888
|
-
class: "builder-text",
|
|
1889
|
-
get dangerouslySetInnerHTML() {
|
|
1890
|
-
return props.text;
|
|
1891
|
-
},
|
|
1897
|
+
const Text = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
1898
|
+
return /* @__PURE__ */ qwik._jsxQ("span", {
|
|
1892
1899
|
style: {
|
|
1893
1900
|
outline: "none"
|
|
1894
|
-
},
|
|
1895
|
-
[qwik._IMMUTABLE]: {
|
|
1896
|
-
dangerouslySetInnerHTML: qwik._wrapSignal(props, "text")
|
|
1897
1901
|
}
|
|
1898
|
-
}
|
|
1902
|
+
}, {
|
|
1903
|
+
class: "builder-text",
|
|
1904
|
+
dangerouslySetInnerHTML: qwik._fnSignal((p0) => p0.text, [
|
|
1905
|
+
props
|
|
1906
|
+
], "p0.text")
|
|
1907
|
+
}, null, 3, "yO_0");
|
|
1899
1908
|
}, "Text_component_15p0cKUxgIE"));
|
|
1900
1909
|
const componentInfo$3 = {
|
|
1901
1910
|
name: "Video",
|
|
@@ -2034,25 +2043,27 @@ const spreadProps = function spreadProps2(props, state) {
|
|
|
2034
2043
|
...videoProps(props)
|
|
2035
2044
|
};
|
|
2036
2045
|
};
|
|
2037
|
-
const Video = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
2038
|
-
return /* @__PURE__ */
|
|
2039
|
-
...spreadProps(props)
|
|
2040
|
-
|
|
2046
|
+
const Video = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
2047
|
+
return /* @__PURE__ */ qwik._jsxQ("video", {
|
|
2048
|
+
...spreadProps(props)
|
|
2049
|
+
}, {
|
|
2050
|
+
style: qwik._fnSignal((p0) => ({
|
|
2041
2051
|
width: "100%",
|
|
2042
2052
|
height: "100%",
|
|
2043
|
-
...
|
|
2044
|
-
objectFit:
|
|
2045
|
-
objectPosition:
|
|
2053
|
+
...p0.attributes?.style,
|
|
2054
|
+
objectFit: p0.fit,
|
|
2055
|
+
objectPosition: p0.position,
|
|
2046
2056
|
borderRadius: 1
|
|
2047
|
-
},
|
|
2048
|
-
|
|
2049
|
-
|
|
2050
|
-
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
|
|
2054
|
-
|
|
2055
|
-
|
|
2057
|
+
}), [
|
|
2058
|
+
props
|
|
2059
|
+
], '{width:"100%",height:"100%",...p0.attributes?.style,objectFit:p0.fit,objectPosition:p0.position,borderRadius:1}'),
|
|
2060
|
+
src: qwik._fnSignal((p0) => p0.video || "no-src", [
|
|
2061
|
+
props
|
|
2062
|
+
], 'p0.video||"no-src"'),
|
|
2063
|
+
poster: qwik._fnSignal((p0) => p0.posterImage, [
|
|
2064
|
+
props
|
|
2065
|
+
], "p0.posterImage")
|
|
2066
|
+
}, null, 2, "j7_0");
|
|
2056
2067
|
}, "Video_component_qdcTZflYyoQ"));
|
|
2057
2068
|
const componentInfo$2 = {
|
|
2058
2069
|
name: "Embed",
|
|
@@ -2068,8 +2079,7 @@ const componentInfo$2 = {
|
|
|
2068
2079
|
const url = options.get("url");
|
|
2069
2080
|
if (url) {
|
|
2070
2081
|
options.set("content", "Loading...");
|
|
2071
|
-
|
|
2072
|
-
return fetch(`https://iframe.ly/api/iframely?url=${url}&api_key=${apiKey}`).then((res) => res.json()).then((data) => {
|
|
2082
|
+
return fetch(`https://iframe.ly/api/iframely?url=${url}&api_key=${"ae0e60e78201a3f2b0de4b"}`).then((res) => res.json()).then((data) => {
|
|
2073
2083
|
if (options.get("url") === url) {
|
|
2074
2084
|
if (data.html)
|
|
2075
2085
|
options.set("content", data.html);
|
|
@@ -2098,9 +2108,9 @@ const SCRIPT_MIME_TYPES = [
|
|
|
2098
2108
|
];
|
|
2099
2109
|
const isJsScript = (script) => SCRIPT_MIME_TYPES.includes(script.type);
|
|
2100
2110
|
const findAndRunScripts$1 = function findAndRunScripts2(props, state, elem) {
|
|
2101
|
-
if (!elem || !elem.getElementsByTagName)
|
|
2111
|
+
if (!elem.value || !elem.value.getElementsByTagName)
|
|
2102
2112
|
return;
|
|
2103
|
-
const scripts = elem.getElementsByTagName("script");
|
|
2113
|
+
const scripts = elem.value.getElementsByTagName("script");
|
|
2104
2114
|
for (let i = 0; i < scripts.length; i++) {
|
|
2105
2115
|
const script = scripts[i];
|
|
2106
2116
|
if (script.src && !state.scriptsInserted.includes(script.src)) {
|
|
@@ -2118,18 +2128,18 @@ const findAndRunScripts$1 = function findAndRunScripts2(props, state, elem) {
|
|
|
2118
2128
|
}
|
|
2119
2129
|
}
|
|
2120
2130
|
};
|
|
2121
|
-
const Embed = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
2122
|
-
const elem = qwik.
|
|
2131
|
+
const Embed = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
2132
|
+
const elem = qwik.useSignal();
|
|
2123
2133
|
const state = qwik.useStore({
|
|
2124
2134
|
ranInitFn: false,
|
|
2125
2135
|
scriptsInserted: [],
|
|
2126
2136
|
scriptsRun: []
|
|
2127
2137
|
});
|
|
2128
|
-
qwik.useTaskQrl(qwik.inlinedQrl(({ track: track2 }) => {
|
|
2138
|
+
qwik.useTaskQrl(/* @__PURE__ */ qwik.inlinedQrl(({ track: track2 }) => {
|
|
2129
2139
|
const [elem2, props2, state2] = qwik.useLexicalScope();
|
|
2130
|
-
track2(() => elem2);
|
|
2140
|
+
track2(() => elem2.value);
|
|
2131
2141
|
track2(() => state2.ranInitFn);
|
|
2132
|
-
if (elem2 && !state2.ranInitFn) {
|
|
2142
|
+
if (elem2.value && !state2.ranInitFn) {
|
|
2133
2143
|
state2.ranInitFn = true;
|
|
2134
2144
|
findAndRunScripts$1(props2, state2, elem2);
|
|
2135
2145
|
}
|
|
@@ -2138,32 +2148,32 @@ const Embed = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
|
2138
2148
|
props,
|
|
2139
2149
|
state
|
|
2140
2150
|
]));
|
|
2141
|
-
return /* @__PURE__ */
|
|
2151
|
+
return /* @__PURE__ */ qwik._jsxQ("div", {
|
|
2152
|
+
ref: elem
|
|
2153
|
+
}, {
|
|
2142
2154
|
class: "builder-embed",
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
[qwik._IMMUTABLE]: {
|
|
2148
|
-
dangerouslySetInnerHTML: qwik._wrapSignal(props, "content")
|
|
2149
|
-
}
|
|
2150
|
-
});
|
|
2155
|
+
dangerouslySetInnerHTML: qwik._fnSignal((p0) => p0.content, [
|
|
2156
|
+
props
|
|
2157
|
+
], "p0.content")
|
|
2158
|
+
}, null, 3, "9r_0");
|
|
2151
2159
|
}, "Embed_component_Uji08ORjXbE"));
|
|
2152
|
-
const ImgComponent = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
2153
|
-
return /* @__PURE__ */
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
|
|
2162
|
-
|
|
2163
|
-
|
|
2164
|
-
|
|
2165
|
-
|
|
2166
|
-
|
|
2160
|
+
const ImgComponent = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
2161
|
+
return /* @__PURE__ */ qwik._jsxQ("img", {
|
|
2162
|
+
...props.attributes
|
|
2163
|
+
}, {
|
|
2164
|
+
style: qwik._fnSignal((p0) => ({
|
|
2165
|
+
objectFit: p0.backgroundSize || "cover",
|
|
2166
|
+
objectPosition: p0.backgroundPosition || "center"
|
|
2167
|
+
}), [
|
|
2168
|
+
props
|
|
2169
|
+
], '{objectFit:p0.backgroundSize||"cover",objectPosition:p0.backgroundPosition||"center"}'),
|
|
2170
|
+
alt: qwik._fnSignal((p0) => p0.altText, [
|
|
2171
|
+
props
|
|
2172
|
+
], "p0.altText"),
|
|
2173
|
+
src: qwik._fnSignal((p0) => p0.imgSrc || p0.image, [
|
|
2174
|
+
props
|
|
2175
|
+
], "p0.imgSrc||p0.image")
|
|
2176
|
+
}, null, 2, isEditing() && props.imgSrc || "default-key");
|
|
2167
2177
|
}, "ImgComponent_component_FXvIDBSffO8"));
|
|
2168
2178
|
const componentInfo$1 = {
|
|
2169
2179
|
name: "Raw:Img",
|
|
@@ -2187,8 +2197,8 @@ const componentInfo$1 = {
|
|
|
2187
2197
|
static: true
|
|
2188
2198
|
};
|
|
2189
2199
|
const findAndRunScripts = function findAndRunScripts22(props, state, elem) {
|
|
2190
|
-
if (elem && elem.getElementsByTagName && typeof window !== "undefined") {
|
|
2191
|
-
const scripts = elem.getElementsByTagName("script");
|
|
2200
|
+
if (elem.value && elem.value.getElementsByTagName && typeof window !== "undefined") {
|
|
2201
|
+
const scripts = elem.value.getElementsByTagName("script");
|
|
2192
2202
|
for (let i = 0; i < scripts.length; i++) {
|
|
2193
2203
|
const script = scripts[i];
|
|
2194
2204
|
if (script.src) {
|
|
@@ -2216,30 +2226,30 @@ const findAndRunScripts = function findAndRunScripts22(props, state, elem) {
|
|
|
2216
2226
|
}
|
|
2217
2227
|
}
|
|
2218
2228
|
};
|
|
2219
|
-
const CustomCode = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
2220
|
-
const elem = qwik.
|
|
2229
|
+
const CustomCode = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
2230
|
+
const elem = qwik.useSignal();
|
|
2221
2231
|
const state = qwik.useStore({
|
|
2222
2232
|
scriptsInserted: [],
|
|
2223
2233
|
scriptsRun: []
|
|
2224
2234
|
});
|
|
2225
|
-
qwik.
|
|
2235
|
+
qwik.useVisibleTaskQrl(/* @__PURE__ */ qwik.inlinedQrl(() => {
|
|
2226
2236
|
const [elem2, props2, state2] = qwik.useLexicalScope();
|
|
2227
2237
|
findAndRunScripts(props2, state2, elem2);
|
|
2228
|
-
}, "
|
|
2238
|
+
}, "CustomCode_component_useVisibleTask_S5QgEQZj6YE", [
|
|
2229
2239
|
elem,
|
|
2230
2240
|
props,
|
|
2231
2241
|
state
|
|
2232
2242
|
]));
|
|
2233
|
-
return /* @__PURE__ */
|
|
2234
|
-
ref: elem
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
|
|
2239
|
-
|
|
2240
|
-
|
|
2241
|
-
|
|
2242
|
-
});
|
|
2243
|
+
return /* @__PURE__ */ qwik._jsxQ("div", {
|
|
2244
|
+
ref: elem
|
|
2245
|
+
}, {
|
|
2246
|
+
class: qwik._fnSignal((p0) => "builder-custom-code" + (p0.replaceNodes ? " replace-nodes" : ""), [
|
|
2247
|
+
props
|
|
2248
|
+
], '"builder-custom-code"+(p0.replaceNodes?" replace-nodes":"")'),
|
|
2249
|
+
dangerouslySetInnerHTML: qwik._fnSignal((p0) => p0.code, [
|
|
2250
|
+
props
|
|
2251
|
+
], "p0.code")
|
|
2252
|
+
}, null, 3, "bY_0");
|
|
2243
2253
|
}, "CustomCode_component_uYOSy7w7Zqw"));
|
|
2244
2254
|
const componentInfo = {
|
|
2245
2255
|
name: "Custom Code",
|
|
@@ -2353,12 +2363,11 @@ function uuidv4() {
|
|
|
2353
2363
|
function uuid() {
|
|
2354
2364
|
return uuidv4().replace(/-/g, "");
|
|
2355
2365
|
}
|
|
2356
|
-
const SESSION_LOCAL_STORAGE_KEY = "builderSessionId";
|
|
2357
2366
|
const getSessionId = async ({ canTrack }) => {
|
|
2358
2367
|
if (!canTrack)
|
|
2359
2368
|
return void 0;
|
|
2360
2369
|
const sessionId = await getCookie({
|
|
2361
|
-
name:
|
|
2370
|
+
name: "builderSessionId",
|
|
2362
2371
|
canTrack
|
|
2363
2372
|
});
|
|
2364
2373
|
if (checkIsDefined(sessionId))
|
|
@@ -2374,7 +2383,7 @@ const getSessionId = async ({ canTrack }) => {
|
|
|
2374
2383
|
};
|
|
2375
2384
|
const createSessionId = () => uuid();
|
|
2376
2385
|
const setSessionId = ({ id, canTrack }) => setCookie({
|
|
2377
|
-
name:
|
|
2386
|
+
name: "builderSessionId",
|
|
2378
2387
|
value: id,
|
|
2379
2388
|
canTrack
|
|
2380
2389
|
});
|
|
@@ -2397,12 +2406,11 @@ const setLocalStorageItem = ({ key, canTrack, value }) => {
|
|
|
2397
2406
|
console.debug("[LocalStorage] SET error: ", err);
|
|
2398
2407
|
}
|
|
2399
2408
|
};
|
|
2400
|
-
const VISITOR_LOCAL_STORAGE_KEY = "builderVisitorId";
|
|
2401
2409
|
const getVisitorId = ({ canTrack }) => {
|
|
2402
2410
|
if (!canTrack)
|
|
2403
2411
|
return void 0;
|
|
2404
2412
|
const visitorId = getLocalStorageItem({
|
|
2405
|
-
key:
|
|
2413
|
+
key: "builderVisitorId",
|
|
2406
2414
|
canTrack
|
|
2407
2415
|
});
|
|
2408
2416
|
if (checkIsDefined(visitorId))
|
|
@@ -2418,7 +2426,7 @@ const getVisitorId = ({ canTrack }) => {
|
|
|
2418
2426
|
};
|
|
2419
2427
|
const createVisitorId = () => uuid();
|
|
2420
2428
|
const setVisitorId = ({ id, canTrack }) => setLocalStorageItem({
|
|
2421
|
-
key:
|
|
2429
|
+
key: "builderVisitorId",
|
|
2422
2430
|
value: id,
|
|
2423
2431
|
canTrack
|
|
2424
2432
|
});
|
|
@@ -2744,7 +2752,7 @@ const getCss = ({ cssCode, contentId }) => {
|
|
|
2744
2752
|
return cssCode;
|
|
2745
2753
|
return cssCode?.replace(/&/g, `div[builder-content-id="${contentId}"]`) || "";
|
|
2746
2754
|
};
|
|
2747
|
-
const RenderContentStyles = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
2755
|
+
const RenderContentStyles = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
2748
2756
|
const state = qwik.useStore({
|
|
2749
2757
|
injectedStyles: `
|
|
2750
2758
|
${getCss({
|
|
@@ -2769,14 +2777,16 @@ ${getFontCss({
|
|
|
2769
2777
|
}
|
|
2770
2778
|
`
|
|
2771
2779
|
});
|
|
2772
|
-
return /* @__PURE__ */
|
|
2780
|
+
return /* @__PURE__ */ qwik._jsxC(RenderInlinedStyles, {
|
|
2773
2781
|
get styles() {
|
|
2774
2782
|
return state.injectedStyles;
|
|
2775
2783
|
},
|
|
2776
2784
|
[qwik._IMMUTABLE]: {
|
|
2777
|
-
styles: qwik.
|
|
2785
|
+
styles: qwik._fnSignal((p0) => p0.injectedStyles, [
|
|
2786
|
+
state
|
|
2787
|
+
], "p0.injectedStyles")
|
|
2778
2788
|
}
|
|
2779
|
-
}, "V0_0");
|
|
2789
|
+
}, 3, "V0_0");
|
|
2780
2790
|
}, "RenderContentStyles_component_Og0xL34Zbvc"));
|
|
2781
2791
|
const getContextStateInitialValue = ({ content, data, locale }) => {
|
|
2782
2792
|
const defaultValues = {};
|
|
@@ -2848,9 +2858,9 @@ const processMessage = function processMessage2(props, state, elementRef, event)
|
|
|
2848
2858
|
break;
|
|
2849
2859
|
}
|
|
2850
2860
|
case "builder.contentUpdate": {
|
|
2851
|
-
const
|
|
2852
|
-
const key =
|
|
2853
|
-
const contentData =
|
|
2861
|
+
const messageContent = data.data;
|
|
2862
|
+
const key = messageContent.key || messageContent.alias || messageContent.entry || messageContent.modelName;
|
|
2863
|
+
const contentData = messageContent.data;
|
|
2854
2864
|
if (key === props.model) {
|
|
2855
2865
|
mergeNewContent(props, state, elementRef, contentData);
|
|
2856
2866
|
state.forceReRenderCount = state.forceReRenderCount + 1;
|
|
@@ -2900,7 +2910,7 @@ const handleRequest = function handleRequest2(props, state, elementRef, { url, k
|
|
|
2900
2910
|
};
|
|
2901
2911
|
setContextState(props, state, elementRef, newState);
|
|
2902
2912
|
}).catch((err) => {
|
|
2903
|
-
console.
|
|
2913
|
+
console.error("error fetching dynamic data", url, err);
|
|
2904
2914
|
});
|
|
2905
2915
|
};
|
|
2906
2916
|
const runHttpRequests = function runHttpRequests2(props, state, elementRef) {
|
|
@@ -2926,8 +2936,9 @@ const emitStateUpdate = function emitStateUpdate2(props, state, elementRef) {
|
|
|
2926
2936
|
}
|
|
2927
2937
|
}));
|
|
2928
2938
|
};
|
|
2929
|
-
const RenderContent = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props) => {
|
|
2930
|
-
|
|
2939
|
+
const RenderContent = /* @__PURE__ */ qwik.componentQrl(/* @__PURE__ */ qwik.inlinedQrl((props) => {
|
|
2940
|
+
qwik._jsxBranch();
|
|
2941
|
+
const elementRef = qwik.useSignal();
|
|
2931
2942
|
const state = qwik.useStore({
|
|
2932
2943
|
allRegisteredComponents: [
|
|
2933
2944
|
...getDefaultRegisteredComponents(),
|
|
@@ -2961,7 +2972,7 @@ const RenderContent = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props)
|
|
|
2961
2972
|
apiVersion: props.apiVersion,
|
|
2962
2973
|
registeredComponents: state.allRegisteredComponents
|
|
2963
2974
|
}));
|
|
2964
|
-
qwik.
|
|
2975
|
+
qwik.useVisibleTaskQrl(/* @__PURE__ */ qwik.inlinedQrl(() => {
|
|
2965
2976
|
const [elementRef2, props2, state2] = qwik.useLexicalScope();
|
|
2966
2977
|
if (!props2.apiKey)
|
|
2967
2978
|
console.error("[Builder.io]: No API key provided to `RenderContent` component. This can cause issues. Please provide an API key using the `apiKey` prop.");
|
|
@@ -3013,12 +3024,12 @@ const RenderContent = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props)
|
|
|
3013
3024
|
runHttpRequests(props2, state2, elementRef2);
|
|
3014
3025
|
emitStateUpdate(props2, state2);
|
|
3015
3026
|
}
|
|
3016
|
-
}, "
|
|
3027
|
+
}, "RenderContent_component_useVisibleTask_n50dgqWW6pY", [
|
|
3017
3028
|
elementRef,
|
|
3018
3029
|
props,
|
|
3019
3030
|
state
|
|
3020
3031
|
]));
|
|
3021
|
-
qwik.useTaskQrl(qwik.inlinedQrl(({ track: track2 }) => {
|
|
3032
|
+
qwik.useTaskQrl(/* @__PURE__ */ qwik.inlinedQrl(({ track: track2 }) => {
|
|
3022
3033
|
const [elementRef2, props2, state2] = qwik.useLexicalScope();
|
|
3023
3034
|
track2(() => props2.content);
|
|
3024
3035
|
if (props2.content)
|
|
@@ -3028,7 +3039,7 @@ const RenderContent = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props)
|
|
|
3028
3039
|
props,
|
|
3029
3040
|
state
|
|
3030
3041
|
]));
|
|
3031
|
-
qwik.useTaskQrl(qwik.inlinedQrl(({ track: track2 }) => {
|
|
3042
|
+
qwik.useTaskQrl(/* @__PURE__ */ qwik.inlinedQrl(({ track: track2 }) => {
|
|
3032
3043
|
const [elementRef2, props2, state2] = qwik.useLexicalScope();
|
|
3033
3044
|
track2(() => state2.useContent?.data?.jsCode);
|
|
3034
3045
|
track2(() => state2.contentState);
|
|
@@ -3038,7 +3049,7 @@ const RenderContent = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props)
|
|
|
3038
3049
|
props,
|
|
3039
3050
|
state
|
|
3040
3051
|
]));
|
|
3041
|
-
qwik.useTaskQrl(qwik.inlinedQrl(({ track: track2 }) => {
|
|
3052
|
+
qwik.useTaskQrl(/* @__PURE__ */ qwik.inlinedQrl(({ track: track2 }) => {
|
|
3042
3053
|
const [elementRef2, props2, state2] = qwik.useLexicalScope();
|
|
3043
3054
|
track2(() => state2.useContent?.data?.httpRequests);
|
|
3044
3055
|
runHttpRequests(props2, state2, elementRef2);
|
|
@@ -3047,7 +3058,7 @@ const RenderContent = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props)
|
|
|
3047
3058
|
props,
|
|
3048
3059
|
state
|
|
3049
3060
|
]));
|
|
3050
|
-
qwik.useTaskQrl(qwik.inlinedQrl(({ track: track2 }) => {
|
|
3061
|
+
qwik.useTaskQrl(/* @__PURE__ */ qwik.inlinedQrl(({ track: track2 }) => {
|
|
3051
3062
|
const [elementRef2, props2, state2] = qwik.useLexicalScope();
|
|
3052
3063
|
track2(() => state2.contentState);
|
|
3053
3064
|
emitStateUpdate(props2, state2);
|
|
@@ -3056,53 +3067,60 @@ const RenderContent = /* @__PURE__ */ qwik.componentQrl(qwik.inlinedQrl((props)
|
|
|
3056
3067
|
props,
|
|
3057
3068
|
state
|
|
3058
3069
|
]));
|
|
3059
|
-
qwik.
|
|
3060
|
-
|
|
3061
|
-
|
|
3062
|
-
|
|
3063
|
-
|
|
3064
|
-
|
|
3065
|
-
|
|
3066
|
-
|
|
3067
|
-
|
|
3068
|
-
|
|
3069
|
-
|
|
3070
|
-
return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, {
|
|
3071
|
-
children: state.useContent ? /* @__PURE__ */ jsxRuntime.jsxs("div", {
|
|
3072
|
-
ref: elementRef,
|
|
3073
|
-
onClick$: qwik.inlinedQrl((event) => {
|
|
3070
|
+
return /* @__PURE__ */ qwik._jsxC(jsxRuntime.Fragment, {
|
|
3071
|
+
children: state.useContent ? /* @__PURE__ */ qwik._jsxQ("div", {
|
|
3072
|
+
ref: elementRef
|
|
3073
|
+
}, {
|
|
3074
|
+
"builder-content-id": qwik._fnSignal((p0) => p0.useContent?.id, [
|
|
3075
|
+
state
|
|
3076
|
+
], "p0.useContent?.id"),
|
|
3077
|
+
"builder-model": qwik._fnSignal((p0) => p0.model, [
|
|
3078
|
+
props
|
|
3079
|
+
], "p0.model"),
|
|
3080
|
+
onClick$: /* @__PURE__ */ qwik.inlinedQrl((event) => {
|
|
3074
3081
|
const [elementRef2, props2, state2] = qwik.useLexicalScope();
|
|
3075
3082
|
return onClick(props2, state2, elementRef2, event);
|
|
3076
3083
|
}, "RenderContent_component__Fragment_div_onClick_wLg5o3ZkpC0", [
|
|
3077
3084
|
elementRef,
|
|
3078
3085
|
props,
|
|
3079
3086
|
state
|
|
3080
|
-
])
|
|
3081
|
-
|
|
3082
|
-
|
|
3083
|
-
|
|
3084
|
-
|
|
3085
|
-
|
|
3086
|
-
|
|
3087
|
-
|
|
3088
|
-
|
|
3089
|
-
|
|
3090
|
-
|
|
3091
|
-
|
|
3092
|
-
|
|
3093
|
-
|
|
3094
|
-
|
|
3095
|
-
|
|
3096
|
-
|
|
3097
|
-
|
|
3098
|
-
|
|
3099
|
-
|
|
3100
|
-
|
|
3101
|
-
|
|
3102
|
-
|
|
3103
|
-
|
|
3087
|
+
])
|
|
3088
|
+
}, [
|
|
3089
|
+
/* @__PURE__ */ qwik._jsxC(RenderContentStyles, {
|
|
3090
|
+
get contentId() {
|
|
3091
|
+
return state.useContent?.id;
|
|
3092
|
+
},
|
|
3093
|
+
get cssCode() {
|
|
3094
|
+
return state.useContent?.data?.cssCode;
|
|
3095
|
+
},
|
|
3096
|
+
get customFonts() {
|
|
3097
|
+
return state.useContent?.data?.customFonts;
|
|
3098
|
+
},
|
|
3099
|
+
[qwik._IMMUTABLE]: {
|
|
3100
|
+
contentId: qwik._fnSignal((p0) => p0.useContent?.id, [
|
|
3101
|
+
state
|
|
3102
|
+
], "p0.useContent?.id"),
|
|
3103
|
+
cssCode: qwik._fnSignal((p0) => p0.useContent?.data?.cssCode, [
|
|
3104
|
+
state
|
|
3105
|
+
], "p0.useContent?.data?.cssCode"),
|
|
3106
|
+
customFonts: qwik._fnSignal((p0) => p0.useContent?.data?.customFonts, [
|
|
3107
|
+
state
|
|
3108
|
+
], "p0.useContent?.data?.customFonts")
|
|
3109
|
+
}
|
|
3110
|
+
}, 3, "03_0"),
|
|
3111
|
+
/* @__PURE__ */ qwik._jsxC(RenderBlocks, {
|
|
3112
|
+
get blocks() {
|
|
3113
|
+
return state.useContent?.data?.blocks;
|
|
3114
|
+
},
|
|
3115
|
+
[qwik._IMMUTABLE]: {
|
|
3116
|
+
blocks: qwik._fnSignal((p0) => p0.useContent?.data?.blocks, [
|
|
3117
|
+
state
|
|
3118
|
+
], "p0.useContent?.data?.blocks")
|
|
3119
|
+
}
|
|
3120
|
+
}, 3, state.forceReRenderCount)
|
|
3121
|
+
], 1, "03_1") : null
|
|
3122
|
+
}, 1, "03_2");
|
|
3104
3123
|
}, "RenderContent_component_hEAI0ahViXM"));
|
|
3105
|
-
const RenderContent$1 = RenderContent;
|
|
3106
3124
|
const settings = {};
|
|
3107
3125
|
function setEditorSettings(newSettings) {
|
|
3108
3126
|
if (isBrowser()) {
|
|
@@ -3119,7 +3137,7 @@ exports.Columns = Columns;
|
|
|
3119
3137
|
exports.Fragment = FragmentComponent;
|
|
3120
3138
|
exports.Image = Image;
|
|
3121
3139
|
exports.RenderBlocks = RenderBlocks;
|
|
3122
|
-
exports.RenderContent = RenderContent
|
|
3140
|
+
exports.RenderContent = RenderContent;
|
|
3123
3141
|
exports.Section = SectionComponent;
|
|
3124
3142
|
exports.Symbol = Symbol$1;
|
|
3125
3143
|
exports.Text = Text;
|