@dcodegroup-au/page-builder 0.8.0 → 0.8.1
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/dist/page-builder.css +1 -1
- package/dist/page-builder.es.js +112 -68
- package/dist/page-builder.umd.js +112 -68
- package/example/src/pages/BestLife.js +1 -0
- package/package.json +1 -1
- package/src/components/builders/VideoGrid.vue +17 -0
- package/src/components/presenters/components/CollectionGridPresenter.vue +38 -17
package/dist/page-builder.css
CHANGED
package/dist/page-builder.es.js
CHANGED
|
@@ -448,11 +448,11 @@ const _hoisted_8$o = { class: "flex flex-col gap-1" };
|
|
|
448
448
|
const _hoisted_9$n = { class: "font-semibold text-gray-900" };
|
|
449
449
|
const _hoisted_10$j = { class: "text-sm text-gray-600" };
|
|
450
450
|
const _hoisted_11$g = ["disabled"];
|
|
451
|
-
const _hoisted_12$
|
|
451
|
+
const _hoisted_12$e = { class: "flex flex-col gap-3" };
|
|
452
452
|
const _hoisted_13$b = ["onClick"];
|
|
453
453
|
const _hoisted_14$9 = ["onClick"];
|
|
454
|
-
const _hoisted_15$
|
|
455
|
-
const _hoisted_16$
|
|
454
|
+
const _hoisted_15$8 = { class: "text-xs text-gray-600" };
|
|
455
|
+
const _hoisted_16$5 = { class: "text-sm font-medium text-gray-900" };
|
|
456
456
|
const _sfc_main$Q = {
|
|
457
457
|
__name: "Items",
|
|
458
458
|
props: {
|
|
@@ -526,7 +526,7 @@ const _sfc_main$Q = {
|
|
|
526
526
|
], 10, _hoisted_11$g)
|
|
527
527
|
])
|
|
528
528
|
]),
|
|
529
|
-
createElementVNode("div", _hoisted_12$
|
|
529
|
+
createElementVNode("div", _hoisted_12$e, [
|
|
530
530
|
(openBlock(true), createElementBlock(Fragment, null, renderList(dataRef.value.data, (item, index) => {
|
|
531
531
|
return openBlock(), createElementBlock("div", {
|
|
532
532
|
class: normalizeClass(["flex items-center gap-4 px-2 py-1 hover:bg-gray-100 rounded-lg", { "bg-gray-200 hover:bg-gray-200": openItemStates.value[index] }])
|
|
@@ -541,8 +541,8 @@ const _sfc_main$Q = {
|
|
|
541
541
|
class: "flex flex-1 flex-col cursor-pointer",
|
|
542
542
|
onClick: ($event) => edit(item, index)
|
|
543
543
|
}, [
|
|
544
|
-
createElementVNode("div", _hoisted_15$
|
|
545
|
-
createElementVNode("div", _hoisted_16$
|
|
544
|
+
createElementVNode("div", _hoisted_15$8, toDisplayString(unref(singularize)(unref(parseName)(unref(type)))) + " #" + toDisplayString(index + 1), 1),
|
|
545
|
+
createElementVNode("div", _hoisted_16$5, toDisplayString(item.title), 1)
|
|
546
546
|
], 8, _hoisted_14$9),
|
|
547
547
|
createVNode(_sfc_main$S, {
|
|
548
548
|
onRemoveItem: ($event) => handleDeleteItem(index),
|
|
@@ -11701,7 +11701,7 @@ const _hoisted_8$n = ["src", "title"];
|
|
|
11701
11701
|
const _hoisted_9$m = ["href"];
|
|
11702
11702
|
const _hoisted_10$i = { class: "file-upload-title" };
|
|
11703
11703
|
const _hoisted_11$f = { class: "file-upload-file-remove" };
|
|
11704
|
-
const _hoisted_12$
|
|
11704
|
+
const _hoisted_12$d = { class: "absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 p-4 rounded-lg flex flex-col justify-center items-center w-full" };
|
|
11705
11705
|
const _sfc_main$O = {
|
|
11706
11706
|
__name: "FileUpload",
|
|
11707
11707
|
props: {
|
|
@@ -11822,7 +11822,7 @@ const _sfc_main$O = {
|
|
|
11822
11822
|
ref_key: "dropzone",
|
|
11823
11823
|
ref: dropzone2
|
|
11824
11824
|
}, null, 512),
|
|
11825
|
-
createElementVNode("div", _hoisted_12$
|
|
11825
|
+
createElementVNode("div", _hoisted_12$d, [
|
|
11826
11826
|
createElementVNode("div", null, [
|
|
11827
11827
|
createVNode(unref(UploadCloud), { class: "w-6 h-6" })
|
|
11828
11828
|
]),
|
|
@@ -45224,17 +45224,17 @@ const _hoisted_8$k = { class: "flex items-center justify-between" };
|
|
|
45224
45224
|
const _hoisted_9$k = { class: "text-lg font-semibold text-gray-900" };
|
|
45225
45225
|
const _hoisted_10$g = { class: "relative flex items-end" };
|
|
45226
45226
|
const _hoisted_11$e = { class: "flex flex-col gap-6" };
|
|
45227
|
-
const _hoisted_12$
|
|
45227
|
+
const _hoisted_12$c = {
|
|
45228
45228
|
key: 0,
|
|
45229
45229
|
class: "flex gap-4"
|
|
45230
45230
|
};
|
|
45231
45231
|
const _hoisted_13$a = { class: "flex items-center gap-2 cursor-pointer" };
|
|
45232
45232
|
const _hoisted_14$8 = ["name", "value", "onUpdate:modelValue", "onChange"];
|
|
45233
|
-
const _hoisted_15$
|
|
45233
|
+
const _hoisted_15$7 = {
|
|
45234
45234
|
key: 1,
|
|
45235
45235
|
class: "flex flex-col gap-1.5"
|
|
45236
45236
|
};
|
|
45237
|
-
const _hoisted_16$
|
|
45237
|
+
const _hoisted_16$4 = ["onUpdate:modelValue", "maxlength"];
|
|
45238
45238
|
const _hoisted_17$2 = ["onUpdate:modelValue", "maxlength"];
|
|
45239
45239
|
const _hoisted_18$2 = { key: 2 };
|
|
45240
45240
|
const _sfc_main$C = {
|
|
@@ -45364,7 +45364,7 @@ const _sfc_main$C = {
|
|
|
45364
45364
|
])
|
|
45365
45365
|
]),
|
|
45366
45366
|
createElementVNode("div", _hoisted_11$e, [
|
|
45367
|
-
!((_a2 = componentData.value) == null ? void 0 : _a2.hasOwnProperty("has_type_switcher")) || ((_b = componentData.value) == null ? void 0 : _b.has_type_switcher) ? (openBlock(), createElementBlock("div", _hoisted_12$
|
|
45367
|
+
!((_a2 = componentData.value) == null ? void 0 : _a2.hasOwnProperty("has_type_switcher")) || ((_b = componentData.value) == null ? void 0 : _b.has_type_switcher) ? (openBlock(), createElementBlock("div", _hoisted_12$c, [
|
|
45368
45368
|
(openBlock(), createElementBlock(Fragment, null, renderList(options, (option) => {
|
|
45369
45369
|
return createElementVNode("label", _hoisted_13$a, [
|
|
45370
45370
|
withDirectives(createElementVNode("input", {
|
|
@@ -45381,7 +45381,7 @@ const _sfc_main$C = {
|
|
|
45381
45381
|
]);
|
|
45382
45382
|
}), 64))
|
|
45383
45383
|
])) : createCommentVNode("", true),
|
|
45384
|
-
!item.hasOwnProperty("content_type") || item.content_type === "content" ? (openBlock(), createElementBlock("div", _hoisted_15$
|
|
45384
|
+
!item.hasOwnProperty("content_type") || item.content_type === "content" ? (openBlock(), createElementBlock("div", _hoisted_15$7, [
|
|
45385
45385
|
["feature_items", "faqs", "pricing"].includes(componentData.value.type) ? (openBlock(), createBlock(_sfc_main$D, {
|
|
45386
45386
|
key: 0,
|
|
45387
45387
|
data: item
|
|
@@ -45405,7 +45405,7 @@ const _sfc_main$C = {
|
|
|
45405
45405
|
placeholder: "Title",
|
|
45406
45406
|
maxlength: ((_a3 = componentData.value) == null ? void 0 : _a3.max_title) ?? 200,
|
|
45407
45407
|
class: "border-1 border-solid border-gray-300 rounded-lg bg-white w-full"
|
|
45408
|
-
}, null, 8, _hoisted_16$
|
|
45408
|
+
}, null, 8, _hoisted_16$4)), [
|
|
45409
45409
|
[vModelText, item.title]
|
|
45410
45410
|
]) : createCommentVNode("", true),
|
|
45411
45411
|
isBulletPoint.value ? withDirectives((openBlock(), createElementBlock("textarea", {
|
|
@@ -45479,7 +45479,7 @@ const _hoisted_8$j = { class: "text-lg font-semibold text-gray-900" };
|
|
|
45479
45479
|
const _hoisted_9$j = { class: "relative flex items-end" };
|
|
45480
45480
|
const _hoisted_10$f = { class: "flex flex-col gap-6" };
|
|
45481
45481
|
const _hoisted_11$d = { class: "flex flex-col gap-1.5" };
|
|
45482
|
-
const _hoisted_12$
|
|
45482
|
+
const _hoisted_12$b = ["onUpdate:modelValue"];
|
|
45483
45483
|
const _sfc_main$B = {
|
|
45484
45484
|
__name: "Logos",
|
|
45485
45485
|
props: {
|
|
@@ -45581,7 +45581,7 @@ const _sfc_main$B = {
|
|
|
45581
45581
|
type: "text",
|
|
45582
45582
|
placeholder: "Enter your url",
|
|
45583
45583
|
class: "border-1 border-solid border-gray-300 rounded-lg bg-white w-full"
|
|
45584
|
-
}, null, 8, _hoisted_12$
|
|
45584
|
+
}, null, 8, _hoisted_12$b), [
|
|
45585
45585
|
[vModelText, item.url]
|
|
45586
45586
|
])
|
|
45587
45587
|
]),
|
|
@@ -45765,8 +45765,9 @@ const _hoisted_6$k = { class: "flex flex-col gap-3" };
|
|
|
45765
45765
|
const _hoisted_7$j = { class: "flex items-center justify-between" };
|
|
45766
45766
|
const _hoisted_8$i = { class: "text-lg font-semibold text-gray-900" };
|
|
45767
45767
|
const _hoisted_9$i = { class: "relative flex items-end" };
|
|
45768
|
-
const _hoisted_10$e =
|
|
45769
|
-
const _hoisted_11$c = { class: "flex flex-col gap-
|
|
45768
|
+
const _hoisted_10$e = ["onUpdate:modelValue"];
|
|
45769
|
+
const _hoisted_11$c = { class: "flex flex-col gap-6" };
|
|
45770
|
+
const _hoisted_12$a = { class: "flex flex-col gap-1.5" };
|
|
45770
45771
|
const _sfc_main$y = {
|
|
45771
45772
|
__name: "VideoGrid",
|
|
45772
45773
|
props: {
|
|
@@ -45841,8 +45842,29 @@ const _sfc_main$y = {
|
|
|
45841
45842
|
}, null, 8, ["onRemoveItem"])
|
|
45842
45843
|
])
|
|
45843
45844
|
]),
|
|
45844
|
-
|
|
45845
|
-
|
|
45845
|
+
createVNode(_sfc_main$P, {
|
|
45846
|
+
"is-vertical": "",
|
|
45847
|
+
field: "line.title",
|
|
45848
|
+
"label-text": "Youtube URL",
|
|
45849
|
+
class: "w-full",
|
|
45850
|
+
value: item.youtube_url
|
|
45851
|
+
}, {
|
|
45852
|
+
default: withCtx(() => [
|
|
45853
|
+
withDirectives(createElementVNode("input", {
|
|
45854
|
+
"onUpdate:modelValue": ($event) => item.youtube_url = $event,
|
|
45855
|
+
name: "youtube_url.youtube_url",
|
|
45856
|
+
type: "text",
|
|
45857
|
+
placeholder: "Url",
|
|
45858
|
+
class: "border-1 border-solid border-gray-300 rounded-lg bg-white w-full"
|
|
45859
|
+
}, null, 8, _hoisted_10$e), [
|
|
45860
|
+
[vModelText, item.youtube_url]
|
|
45861
|
+
])
|
|
45862
|
+
]),
|
|
45863
|
+
_: 2
|
|
45864
|
+
}, 1032, ["value"]),
|
|
45865
|
+
_cache[1] || (_cache[1] = createElementVNode("p", null, "OR", -1)),
|
|
45866
|
+
createElementVNode("div", _hoisted_11$c, [
|
|
45867
|
+
createElementVNode("div", _hoisted_12$a, [
|
|
45846
45868
|
createVNode(unref(VFileUpload), {
|
|
45847
45869
|
name: "image",
|
|
45848
45870
|
type: "video",
|
|
@@ -46167,11 +46189,11 @@ const _hoisted_11$b = { class: "flex flex-col" };
|
|
|
46167
46189
|
const _hoisted_12$9 = { class: "text-sm font-medium text-gray-900" };
|
|
46168
46190
|
const _hoisted_13$9 = { class: "flex items-center justify-between gap-3 px-[10px]" };
|
|
46169
46191
|
const _hoisted_14$7 = { class: "flex h-full flex-1 flex-col mb-20" };
|
|
46170
|
-
const _hoisted_15$
|
|
46192
|
+
const _hoisted_15$6 = {
|
|
46171
46193
|
key: 0,
|
|
46172
46194
|
class: "mb-4 px-6 py-5 rounded-xl bg-gray-50"
|
|
46173
46195
|
};
|
|
46174
|
-
const _hoisted_16$
|
|
46196
|
+
const _hoisted_16$3 = { class: "flex flex-col gap-1 pt-6 text-gray-600" };
|
|
46175
46197
|
const _hoisted_17$1 = ["value"];
|
|
46176
46198
|
const _hoisted_18$1 = {
|
|
46177
46199
|
key: 1,
|
|
@@ -46312,9 +46334,9 @@ const _sfc_main$t = {
|
|
|
46312
46334
|
}), 256))
|
|
46313
46335
|
]),
|
|
46314
46336
|
createElementVNode("div", _hoisted_14$7, [
|
|
46315
|
-
!unref(selected) ? (openBlock(), createElementBlock("div", _hoisted_15$
|
|
46337
|
+
!unref(selected) ? (openBlock(), createElementBlock("div", _hoisted_15$6, [
|
|
46316
46338
|
_cache[3] || (_cache[3] = createElementVNode("div", { class: "text-lg pb-6 font-semibold text-gray-900 border-b border-gray-200" }, "Settings", -1)),
|
|
46317
|
-
createElementVNode("div", _hoisted_16$
|
|
46339
|
+
createElementVNode("div", _hoisted_16$3, [
|
|
46318
46340
|
createVNode(_sfc_main$P, {
|
|
46319
46341
|
field: "breadcrumb",
|
|
46320
46342
|
"label-text": "Breadcrumb section",
|
|
@@ -48455,11 +48477,11 @@ const _hoisted_11$9 = ["innerHTML"];
|
|
|
48455
48477
|
const _hoisted_12$7 = { class: "border-t border-gray-200 mt-4 pt-[17px] flex justify-between items-center" };
|
|
48456
48478
|
const _hoisted_13$7 = ["href"];
|
|
48457
48479
|
const _hoisted_14$6 = { class: "absolute max-sm:bottom-0 sm:top-[-65px] right-0 lg:right-4 flex gap-4" };
|
|
48458
|
-
const _hoisted_15$
|
|
48480
|
+
const _hoisted_15$5 = {
|
|
48459
48481
|
key: 0,
|
|
48460
48482
|
class: "flex sm:justify-center mb-6 lg:mb-10"
|
|
48461
48483
|
};
|
|
48462
|
-
const _hoisted_16$
|
|
48484
|
+
const _hoisted_16$2 = ["href", "target"];
|
|
48463
48485
|
const _sfc_main$j = {
|
|
48464
48486
|
__name: "CarouselPresenter",
|
|
48465
48487
|
props: {
|
|
@@ -48605,7 +48627,7 @@ const _sfc_main$j = {
|
|
|
48605
48627
|
createVNode(unref(ChevronRight), { class: "w-6 h-6" })
|
|
48606
48628
|
], 2)
|
|
48607
48629
|
]),
|
|
48608
|
-
((_a2 = __props.component) == null ? void 0 : _a2.button) ? (openBlock(), createElementBlock("div", _hoisted_15$
|
|
48630
|
+
((_a2 = __props.component) == null ? void 0 : _a2.button) ? (openBlock(), createElementBlock("div", _hoisted_15$5, [
|
|
48609
48631
|
createElementVNode("a", {
|
|
48610
48632
|
class: "border-brand-300 hover:border-brand-700 border text-brand-700 h-[44px] rounded-full px-[14px] py-[10px] inline-flex gap-1.5 items-center font-semibold text-base",
|
|
48611
48633
|
href: unref(formatUrl)(__props.component.button.url),
|
|
@@ -48613,7 +48635,7 @@ const _sfc_main$j = {
|
|
|
48613
48635
|
}, [
|
|
48614
48636
|
createTextVNode(toDisplayString(__props.component.button.title) + " ", 1),
|
|
48615
48637
|
createVNode(unref(ArrowUpRight), { class: "w-5 h-5" })
|
|
48616
|
-
], 8, _hoisted_16$
|
|
48638
|
+
], 8, _hoisted_16$2)
|
|
48617
48639
|
])) : createCommentVNode("", true)
|
|
48618
48640
|
]);
|
|
48619
48641
|
};
|
|
@@ -48680,31 +48702,36 @@ const PlayButton = { render: render$e };
|
|
|
48680
48702
|
const _hoisted_1$v = { class: "grid grid-cols-1 md:grid-cols-3 gap-6 w-full" };
|
|
48681
48703
|
const _hoisted_2$f = {
|
|
48682
48704
|
key: 0,
|
|
48683
|
-
class: "relative group"
|
|
48705
|
+
class: "relative group w-full object-cover rounded-lg md:rounded-2xl overflow-hidden"
|
|
48706
|
+
};
|
|
48707
|
+
const _hoisted_3$f = {
|
|
48708
|
+
key: 0,
|
|
48709
|
+
class: "w-full h-[281px] md:rounded-2xl"
|
|
48684
48710
|
};
|
|
48685
|
-
const _hoisted_3$f = ["onClick"];
|
|
48686
48711
|
const _hoisted_4$f = ["src"];
|
|
48687
|
-
const _hoisted_5$f = ["
|
|
48688
|
-
const _hoisted_6$f =
|
|
48712
|
+
const _hoisted_5$f = ["onClick"];
|
|
48713
|
+
const _hoisted_6$f = ["src"];
|
|
48714
|
+
const _hoisted_7$e = ["src"];
|
|
48715
|
+
const _hoisted_8$d = {
|
|
48689
48716
|
key: 2,
|
|
48690
48717
|
class: "w-full h-[281px] object-cover rounded-lg md:rounded-2xl mb-4",
|
|
48691
48718
|
alt: "No Available",
|
|
48692
48719
|
src: _imports_0
|
|
48693
48720
|
};
|
|
48694
|
-
const
|
|
48695
|
-
const
|
|
48721
|
+
const _hoisted_9$d = { class: "flex flex-col gap-2 items-start text-left w-full" };
|
|
48722
|
+
const _hoisted_10$9 = {
|
|
48696
48723
|
key: 0,
|
|
48697
48724
|
class: "flex gap-2"
|
|
48698
48725
|
};
|
|
48699
|
-
const
|
|
48700
|
-
const
|
|
48701
|
-
const
|
|
48702
|
-
const
|
|
48703
|
-
const
|
|
48726
|
+
const _hoisted_11$8 = ["href"];
|
|
48727
|
+
const _hoisted_12$6 = { class: "flex justify-between" };
|
|
48728
|
+
const _hoisted_13$6 = ["innerHTML"];
|
|
48729
|
+
const _hoisted_14$5 = { class: "text-gray-500 text-sm mb-4" };
|
|
48730
|
+
const _hoisted_15$4 = {
|
|
48704
48731
|
key: 0,
|
|
48705
48732
|
class: "flex justify-center"
|
|
48706
48733
|
};
|
|
48707
|
-
const
|
|
48734
|
+
const _hoisted_16$1 = ["href", "target"];
|
|
48708
48735
|
const _sfc_main$h = {
|
|
48709
48736
|
__name: "CollectionGridPresenter",
|
|
48710
48737
|
props: {
|
|
@@ -48741,6 +48768,13 @@ const _sfc_main$h = {
|
|
|
48741
48768
|
videoRefs.value[index] = el;
|
|
48742
48769
|
}
|
|
48743
48770
|
};
|
|
48771
|
+
const getEmbedUrl = (item) => {
|
|
48772
|
+
if (!item.youtube_url) return null;
|
|
48773
|
+
const m = item.youtube_url.match(/(?:youtube\.com\/(?:.*v=|v\/|embed\/)|youtu\.be\/)([A-Za-z0-9_-]{11})/);
|
|
48774
|
+
const id = m ? m[1] : null;
|
|
48775
|
+
if (!id) return null;
|
|
48776
|
+
return `https://www.youtube.com/embed/${id}`;
|
|
48777
|
+
};
|
|
48744
48778
|
return (_ctx, _cache) => {
|
|
48745
48779
|
var _a2, _b2;
|
|
48746
48780
|
return openBlock(), createElementBlock("div", {
|
|
@@ -48750,35 +48784,45 @@ const _sfc_main$h = {
|
|
|
48750
48784
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(items), (card, index) => {
|
|
48751
48785
|
return openBlock(), createElementBlock("div", {
|
|
48752
48786
|
key: index,
|
|
48753
|
-
class: "card bg-white sm:p-0 px-4"
|
|
48787
|
+
class: "card bg-white sm:p-0 px-4 w-full"
|
|
48754
48788
|
}, [
|
|
48755
48789
|
__props.component.type === "video_grid" ? (openBlock(), createElementBlock("div", _hoisted_2$f, [
|
|
48756
|
-
|
|
48757
|
-
|
|
48758
|
-
|
|
48759
|
-
|
|
48760
|
-
|
|
48761
|
-
|
|
48762
|
-
|
|
48763
|
-
preload: "metadata"
|
|
48764
|
-
}, [
|
|
48765
|
-
createElementVNode("source", {
|
|
48766
|
-
src: `${card.video}#t=2`
|
|
48790
|
+
(card == null ? void 0 : card.youtube_url) && getEmbedUrl(card) ? (openBlock(), createElementBlock("div", _hoisted_3$f, [
|
|
48791
|
+
createElementVNode("iframe", {
|
|
48792
|
+
src: getEmbedUrl(card),
|
|
48793
|
+
frameborder: "0",
|
|
48794
|
+
allow: "accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",
|
|
48795
|
+
allowfullscreen: "",
|
|
48796
|
+
class: "w-full h-full"
|
|
48767
48797
|
}, null, 8, _hoisted_4$f)
|
|
48768
|
-
],
|
|
48769
|
-
|
|
48770
|
-
|
|
48771
|
-
|
|
48772
|
-
|
|
48773
|
-
|
|
48798
|
+
])) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
48799
|
+
createElementVNode("video", {
|
|
48800
|
+
onClick: ($event) => togglePlayPause(index),
|
|
48801
|
+
ref_for: true,
|
|
48802
|
+
ref: (el) => setVideoRef(el, index),
|
|
48803
|
+
class: "w-full h-[281px] object-cover rounded-lg md:rounded-2xl",
|
|
48804
|
+
width: "640",
|
|
48805
|
+
height: "360",
|
|
48806
|
+
preload: "metadata"
|
|
48807
|
+
}, [
|
|
48808
|
+
createElementVNode("source", {
|
|
48809
|
+
src: `${card.video}#t=2`
|
|
48810
|
+
}, null, 8, _hoisted_6$f)
|
|
48811
|
+
], 8, _hoisted_5$f),
|
|
48812
|
+
!isPlaying.value[index] ? (openBlock(), createBlock(unref(PlayButton), {
|
|
48813
|
+
key: 0,
|
|
48814
|
+
class: "cursor-pointer absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2 group-hover:opacity-100 transition-opacity",
|
|
48815
|
+
onClick: ($event) => togglePlayPause(index)
|
|
48816
|
+
}, null, 8, ["onClick"])) : createCommentVNode("", true)
|
|
48817
|
+
], 64))
|
|
48774
48818
|
])) : card.image ? (openBlock(), createElementBlock("img", {
|
|
48775
48819
|
key: 1,
|
|
48776
48820
|
src: card.image,
|
|
48777
48821
|
alt: "Card Image",
|
|
48778
48822
|
class: "w-full h-[281px] object-cover rounded-lg md:rounded-2xl mb-4"
|
|
48779
|
-
}, null, 8,
|
|
48780
|
-
createElementVNode("div",
|
|
48781
|
-
card.categories && card.categories.length ? (openBlock(), createElementBlock("div",
|
|
48823
|
+
}, null, 8, _hoisted_7$e)) : (openBlock(), createElementBlock("img", _hoisted_8$d)),
|
|
48824
|
+
createElementVNode("div", _hoisted_9$d, [
|
|
48825
|
+
card.categories && card.categories.length ? (openBlock(), createElementBlock("div", _hoisted_10$9, [
|
|
48782
48826
|
(openBlock(true), createElementBlock(Fragment, null, renderList(card.categories, (tag) => {
|
|
48783
48827
|
return openBlock(), createElementBlock("span", {
|
|
48784
48828
|
key: tag,
|
|
@@ -48797,20 +48841,20 @@ const _sfc_main$h = {
|
|
|
48797
48841
|
target: "_blank",
|
|
48798
48842
|
rel: "noopener noreferrer"
|
|
48799
48843
|
}, [
|
|
48800
|
-
createElementVNode("div",
|
|
48844
|
+
createElementVNode("div", _hoisted_12$6, [
|
|
48801
48845
|
createElementVNode("span", {
|
|
48802
48846
|
class: "w-5/6 leading-[28px]",
|
|
48803
48847
|
innerHTML: card.title
|
|
48804
|
-
}, null, 8,
|
|
48848
|
+
}, null, 8, _hoisted_13$6),
|
|
48805
48849
|
createVNode(unref(ArrowUpRight), { class: "w-5 h-5 mt-1" })
|
|
48806
48850
|
])
|
|
48807
|
-
], 8,
|
|
48808
|
-
createElementVNode("p",
|
|
48851
|
+
], 8, _hoisted_11$8)) : createCommentVNode("", true),
|
|
48852
|
+
createElementVNode("p", _hoisted_14$5, toDisplayString(card.dateTime), 1)
|
|
48809
48853
|
])
|
|
48810
48854
|
]);
|
|
48811
48855
|
}), 128))
|
|
48812
48856
|
]),
|
|
48813
|
-
Object.keys(unref(button)).length && ((_b2 = unref(button)) == null ? void 0 : _b2.show) ? (openBlock(), createElementBlock("div",
|
|
48857
|
+
Object.keys(unref(button)).length && ((_b2 = unref(button)) == null ? void 0 : _b2.show) ? (openBlock(), createElementBlock("div", _hoisted_15$4, [
|
|
48814
48858
|
createElementVNode("a", {
|
|
48815
48859
|
class: "border-brand-300 hover:border-brand-700 border text-brand-700 h-[44px] rounded-full px-[14px] py-[10px] inline-flex gap-1.5 items-center font-semibold text-base",
|
|
48816
48860
|
href: unref(formatUrl)(unref(button).url),
|
|
@@ -48818,13 +48862,13 @@ const _sfc_main$h = {
|
|
|
48818
48862
|
}, [
|
|
48819
48863
|
createTextVNode(toDisplayString(unref(button).title) + " ", 1),
|
|
48820
48864
|
createVNode(unref(ArrowUpRight), { class: "w-5 h-5" })
|
|
48821
|
-
], 8,
|
|
48865
|
+
], 8, _hoisted_16$1)
|
|
48822
48866
|
])) : createCommentVNode("", true)
|
|
48823
48867
|
], 2);
|
|
48824
48868
|
};
|
|
48825
48869
|
}
|
|
48826
48870
|
};
|
|
48827
|
-
const CollectionGridPresenter = /* @__PURE__ */ _export_sfc(_sfc_main$h, [["__scopeId", "data-v-
|
|
48871
|
+
const CollectionGridPresenter = /* @__PURE__ */ _export_sfc(_sfc_main$h, [["__scopeId", "data-v-77dcb437"]]);
|
|
48828
48872
|
const _hoisted_1$u = { class: "overflow-hidden" };
|
|
48829
48873
|
const _sfc_main$g = {
|
|
48830
48874
|
__name: "CollectionGrid",
|
package/dist/page-builder.umd.js
CHANGED
|
@@ -451,11 +451,11 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
451
451
|
const _hoisted_9$n = { class: "font-semibold text-gray-900" };
|
|
452
452
|
const _hoisted_10$j = { class: "text-sm text-gray-600" };
|
|
453
453
|
const _hoisted_11$g = ["disabled"];
|
|
454
|
-
const _hoisted_12$
|
|
454
|
+
const _hoisted_12$e = { class: "flex flex-col gap-3" };
|
|
455
455
|
const _hoisted_13$b = ["onClick"];
|
|
456
456
|
const _hoisted_14$9 = ["onClick"];
|
|
457
|
-
const _hoisted_15$
|
|
458
|
-
const _hoisted_16$
|
|
457
|
+
const _hoisted_15$8 = { class: "text-xs text-gray-600" };
|
|
458
|
+
const _hoisted_16$5 = { class: "text-sm font-medium text-gray-900" };
|
|
459
459
|
const _sfc_main$Q = {
|
|
460
460
|
__name: "Items",
|
|
461
461
|
props: {
|
|
@@ -529,7 +529,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
529
529
|
], 10, _hoisted_11$g)
|
|
530
530
|
])
|
|
531
531
|
]),
|
|
532
|
-
vue.createElementVNode("div", _hoisted_12$
|
|
532
|
+
vue.createElementVNode("div", _hoisted_12$e, [
|
|
533
533
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(dataRef.value.data, (item, index) => {
|
|
534
534
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
535
535
|
class: vue.normalizeClass(["flex items-center gap-4 px-2 py-1 hover:bg-gray-100 rounded-lg", { "bg-gray-200 hover:bg-gray-200": openItemStates.value[index] }])
|
|
@@ -544,8 +544,8 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
544
544
|
class: "flex flex-1 flex-col cursor-pointer",
|
|
545
545
|
onClick: ($event) => edit(item, index)
|
|
546
546
|
}, [
|
|
547
|
-
vue.createElementVNode("div", _hoisted_15$
|
|
548
|
-
vue.createElementVNode("div", _hoisted_16$
|
|
547
|
+
vue.createElementVNode("div", _hoisted_15$8, vue.toDisplayString(vue.unref(singularize)(vue.unref(parseName)(vue.unref(type)))) + " #" + vue.toDisplayString(index + 1), 1),
|
|
548
|
+
vue.createElementVNode("div", _hoisted_16$5, vue.toDisplayString(item.title), 1)
|
|
549
549
|
], 8, _hoisted_14$9),
|
|
550
550
|
vue.createVNode(_sfc_main$S, {
|
|
551
551
|
onRemoveItem: ($event) => handleDeleteItem(index),
|
|
@@ -11704,7 +11704,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
11704
11704
|
const _hoisted_9$m = ["href"];
|
|
11705
11705
|
const _hoisted_10$i = { class: "file-upload-title" };
|
|
11706
11706
|
const _hoisted_11$f = { class: "file-upload-file-remove" };
|
|
11707
|
-
const _hoisted_12$
|
|
11707
|
+
const _hoisted_12$d = { class: "absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 p-4 rounded-lg flex flex-col justify-center items-center w-full" };
|
|
11708
11708
|
const _sfc_main$O = {
|
|
11709
11709
|
__name: "FileUpload",
|
|
11710
11710
|
props: {
|
|
@@ -11825,7 +11825,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
11825
11825
|
ref_key: "dropzone",
|
|
11826
11826
|
ref: dropzone2
|
|
11827
11827
|
}, null, 512),
|
|
11828
|
-
vue.createElementVNode("div", _hoisted_12$
|
|
11828
|
+
vue.createElementVNode("div", _hoisted_12$d, [
|
|
11829
11829
|
vue.createElementVNode("div", null, [
|
|
11830
11830
|
vue.createVNode(vue.unref(UploadCloud), { class: "w-6 h-6" })
|
|
11831
11831
|
]),
|
|
@@ -45227,17 +45227,17 @@ ${escapeText(this.code(index, length))}
|
|
|
45227
45227
|
const _hoisted_9$k = { class: "text-lg font-semibold text-gray-900" };
|
|
45228
45228
|
const _hoisted_10$g = { class: "relative flex items-end" };
|
|
45229
45229
|
const _hoisted_11$e = { class: "flex flex-col gap-6" };
|
|
45230
|
-
const _hoisted_12$
|
|
45230
|
+
const _hoisted_12$c = {
|
|
45231
45231
|
key: 0,
|
|
45232
45232
|
class: "flex gap-4"
|
|
45233
45233
|
};
|
|
45234
45234
|
const _hoisted_13$a = { class: "flex items-center gap-2 cursor-pointer" };
|
|
45235
45235
|
const _hoisted_14$8 = ["name", "value", "onUpdate:modelValue", "onChange"];
|
|
45236
|
-
const _hoisted_15$
|
|
45236
|
+
const _hoisted_15$7 = {
|
|
45237
45237
|
key: 1,
|
|
45238
45238
|
class: "flex flex-col gap-1.5"
|
|
45239
45239
|
};
|
|
45240
|
-
const _hoisted_16$
|
|
45240
|
+
const _hoisted_16$4 = ["onUpdate:modelValue", "maxlength"];
|
|
45241
45241
|
const _hoisted_17$2 = ["onUpdate:modelValue", "maxlength"];
|
|
45242
45242
|
const _hoisted_18$2 = { key: 2 };
|
|
45243
45243
|
const _sfc_main$C = {
|
|
@@ -45367,7 +45367,7 @@ ${escapeText(this.code(index, length))}
|
|
|
45367
45367
|
])
|
|
45368
45368
|
]),
|
|
45369
45369
|
vue.createElementVNode("div", _hoisted_11$e, [
|
|
45370
|
-
!((_a2 = componentData.value) == null ? void 0 : _a2.hasOwnProperty("has_type_switcher")) || ((_b = componentData.value) == null ? void 0 : _b.has_type_switcher) ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_12$
|
|
45370
|
+
!((_a2 = componentData.value) == null ? void 0 : _a2.hasOwnProperty("has_type_switcher")) || ((_b = componentData.value) == null ? void 0 : _b.has_type_switcher) ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_12$c, [
|
|
45371
45371
|
(vue.openBlock(), vue.createElementBlock(vue.Fragment, null, vue.renderList(options, (option) => {
|
|
45372
45372
|
return vue.createElementVNode("label", _hoisted_13$a, [
|
|
45373
45373
|
vue.withDirectives(vue.createElementVNode("input", {
|
|
@@ -45384,7 +45384,7 @@ ${escapeText(this.code(index, length))}
|
|
|
45384
45384
|
]);
|
|
45385
45385
|
}), 64))
|
|
45386
45386
|
])) : vue.createCommentVNode("", true),
|
|
45387
|
-
!item.hasOwnProperty("content_type") || item.content_type === "content" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_15$
|
|
45387
|
+
!item.hasOwnProperty("content_type") || item.content_type === "content" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_15$7, [
|
|
45388
45388
|
["feature_items", "faqs", "pricing"].includes(componentData.value.type) ? (vue.openBlock(), vue.createBlock(_sfc_main$D, {
|
|
45389
45389
|
key: 0,
|
|
45390
45390
|
data: item
|
|
@@ -45408,7 +45408,7 @@ ${escapeText(this.code(index, length))}
|
|
|
45408
45408
|
placeholder: "Title",
|
|
45409
45409
|
maxlength: ((_a3 = componentData.value) == null ? void 0 : _a3.max_title) ?? 200,
|
|
45410
45410
|
class: "border-1 border-solid border-gray-300 rounded-lg bg-white w-full"
|
|
45411
|
-
}, null, 8, _hoisted_16$
|
|
45411
|
+
}, null, 8, _hoisted_16$4)), [
|
|
45412
45412
|
[vue.vModelText, item.title]
|
|
45413
45413
|
]) : vue.createCommentVNode("", true),
|
|
45414
45414
|
isBulletPoint.value ? vue.withDirectives((vue.openBlock(), vue.createElementBlock("textarea", {
|
|
@@ -45482,7 +45482,7 @@ ${escapeText(this.code(index, length))}
|
|
|
45482
45482
|
const _hoisted_9$j = { class: "relative flex items-end" };
|
|
45483
45483
|
const _hoisted_10$f = { class: "flex flex-col gap-6" };
|
|
45484
45484
|
const _hoisted_11$d = { class: "flex flex-col gap-1.5" };
|
|
45485
|
-
const _hoisted_12$
|
|
45485
|
+
const _hoisted_12$b = ["onUpdate:modelValue"];
|
|
45486
45486
|
const _sfc_main$B = {
|
|
45487
45487
|
__name: "Logos",
|
|
45488
45488
|
props: {
|
|
@@ -45584,7 +45584,7 @@ ${escapeText(this.code(index, length))}
|
|
|
45584
45584
|
type: "text",
|
|
45585
45585
|
placeholder: "Enter your url",
|
|
45586
45586
|
class: "border-1 border-solid border-gray-300 rounded-lg bg-white w-full"
|
|
45587
|
-
}, null, 8, _hoisted_12$
|
|
45587
|
+
}, null, 8, _hoisted_12$b), [
|
|
45588
45588
|
[vue.vModelText, item.url]
|
|
45589
45589
|
])
|
|
45590
45590
|
]),
|
|
@@ -45768,8 +45768,9 @@ ${escapeText(this.code(index, length))}
|
|
|
45768
45768
|
const _hoisted_7$j = { class: "flex items-center justify-between" };
|
|
45769
45769
|
const _hoisted_8$i = { class: "text-lg font-semibold text-gray-900" };
|
|
45770
45770
|
const _hoisted_9$i = { class: "relative flex items-end" };
|
|
45771
|
-
const _hoisted_10$e =
|
|
45772
|
-
const _hoisted_11$c = { class: "flex flex-col gap-
|
|
45771
|
+
const _hoisted_10$e = ["onUpdate:modelValue"];
|
|
45772
|
+
const _hoisted_11$c = { class: "flex flex-col gap-6" };
|
|
45773
|
+
const _hoisted_12$a = { class: "flex flex-col gap-1.5" };
|
|
45773
45774
|
const _sfc_main$y = {
|
|
45774
45775
|
__name: "VideoGrid",
|
|
45775
45776
|
props: {
|
|
@@ -45844,8 +45845,29 @@ ${escapeText(this.code(index, length))}
|
|
|
45844
45845
|
}, null, 8, ["onRemoveItem"])
|
|
45845
45846
|
])
|
|
45846
45847
|
]),
|
|
45847
|
-
vue.
|
|
45848
|
-
|
|
45848
|
+
vue.createVNode(_sfc_main$P, {
|
|
45849
|
+
"is-vertical": "",
|
|
45850
|
+
field: "line.title",
|
|
45851
|
+
"label-text": "Youtube URL",
|
|
45852
|
+
class: "w-full",
|
|
45853
|
+
value: item.youtube_url
|
|
45854
|
+
}, {
|
|
45855
|
+
default: vue.withCtx(() => [
|
|
45856
|
+
vue.withDirectives(vue.createElementVNode("input", {
|
|
45857
|
+
"onUpdate:modelValue": ($event) => item.youtube_url = $event,
|
|
45858
|
+
name: "youtube_url.youtube_url",
|
|
45859
|
+
type: "text",
|
|
45860
|
+
placeholder: "Url",
|
|
45861
|
+
class: "border-1 border-solid border-gray-300 rounded-lg bg-white w-full"
|
|
45862
|
+
}, null, 8, _hoisted_10$e), [
|
|
45863
|
+
[vue.vModelText, item.youtube_url]
|
|
45864
|
+
])
|
|
45865
|
+
]),
|
|
45866
|
+
_: 2
|
|
45867
|
+
}, 1032, ["value"]),
|
|
45868
|
+
_cache[1] || (_cache[1] = vue.createElementVNode("p", null, "OR", -1)),
|
|
45869
|
+
vue.createElementVNode("div", _hoisted_11$c, [
|
|
45870
|
+
vue.createElementVNode("div", _hoisted_12$a, [
|
|
45849
45871
|
vue.createVNode(vue.unref(VFileUpload), {
|
|
45850
45872
|
name: "image",
|
|
45851
45873
|
type: "video",
|
|
@@ -46170,11 +46192,11 @@ ${escapeText(this.code(index, length))}
|
|
|
46170
46192
|
const _hoisted_12$9 = { class: "text-sm font-medium text-gray-900" };
|
|
46171
46193
|
const _hoisted_13$9 = { class: "flex items-center justify-between gap-3 px-[10px]" };
|
|
46172
46194
|
const _hoisted_14$7 = { class: "flex h-full flex-1 flex-col mb-20" };
|
|
46173
|
-
const _hoisted_15$
|
|
46195
|
+
const _hoisted_15$6 = {
|
|
46174
46196
|
key: 0,
|
|
46175
46197
|
class: "mb-4 px-6 py-5 rounded-xl bg-gray-50"
|
|
46176
46198
|
};
|
|
46177
|
-
const _hoisted_16$
|
|
46199
|
+
const _hoisted_16$3 = { class: "flex flex-col gap-1 pt-6 text-gray-600" };
|
|
46178
46200
|
const _hoisted_17$1 = ["value"];
|
|
46179
46201
|
const _hoisted_18$1 = {
|
|
46180
46202
|
key: 1,
|
|
@@ -46315,9 +46337,9 @@ ${escapeText(this.code(index, length))}
|
|
|
46315
46337
|
}), 256))
|
|
46316
46338
|
]),
|
|
46317
46339
|
vue.createElementVNode("div", _hoisted_14$7, [
|
|
46318
|
-
!vue.unref(selected) ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_15$
|
|
46340
|
+
!vue.unref(selected) ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_15$6, [
|
|
46319
46341
|
_cache[3] || (_cache[3] = vue.createElementVNode("div", { class: "text-lg pb-6 font-semibold text-gray-900 border-b border-gray-200" }, "Settings", -1)),
|
|
46320
|
-
vue.createElementVNode("div", _hoisted_16$
|
|
46342
|
+
vue.createElementVNode("div", _hoisted_16$3, [
|
|
46321
46343
|
vue.createVNode(_sfc_main$P, {
|
|
46322
46344
|
field: "breadcrumb",
|
|
46323
46345
|
"label-text": "Breadcrumb section",
|
|
@@ -48458,11 +48480,11 @@ ${escapeText(this.code(index, length))}
|
|
|
48458
48480
|
const _hoisted_12$7 = { class: "border-t border-gray-200 mt-4 pt-[17px] flex justify-between items-center" };
|
|
48459
48481
|
const _hoisted_13$7 = ["href"];
|
|
48460
48482
|
const _hoisted_14$6 = { class: "absolute max-sm:bottom-0 sm:top-[-65px] right-0 lg:right-4 flex gap-4" };
|
|
48461
|
-
const _hoisted_15$
|
|
48483
|
+
const _hoisted_15$5 = {
|
|
48462
48484
|
key: 0,
|
|
48463
48485
|
class: "flex sm:justify-center mb-6 lg:mb-10"
|
|
48464
48486
|
};
|
|
48465
|
-
const _hoisted_16$
|
|
48487
|
+
const _hoisted_16$2 = ["href", "target"];
|
|
48466
48488
|
const _sfc_main$j = {
|
|
48467
48489
|
__name: "CarouselPresenter",
|
|
48468
48490
|
props: {
|
|
@@ -48608,7 +48630,7 @@ ${escapeText(this.code(index, length))}
|
|
|
48608
48630
|
vue.createVNode(vue.unref(ChevronRight), { class: "w-6 h-6" })
|
|
48609
48631
|
], 2)
|
|
48610
48632
|
]),
|
|
48611
|
-
((_a2 = __props.component) == null ? void 0 : _a2.button) ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_15$
|
|
48633
|
+
((_a2 = __props.component) == null ? void 0 : _a2.button) ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_15$5, [
|
|
48612
48634
|
vue.createElementVNode("a", {
|
|
48613
48635
|
class: "border-brand-300 hover:border-brand-700 border text-brand-700 h-[44px] rounded-full px-[14px] py-[10px] inline-flex gap-1.5 items-center font-semibold text-base",
|
|
48614
48636
|
href: vue.unref(formatUrl)(__props.component.button.url),
|
|
@@ -48616,7 +48638,7 @@ ${escapeText(this.code(index, length))}
|
|
|
48616
48638
|
}, [
|
|
48617
48639
|
vue.createTextVNode(vue.toDisplayString(__props.component.button.title) + " ", 1),
|
|
48618
48640
|
vue.createVNode(vue.unref(ArrowUpRight), { class: "w-5 h-5" })
|
|
48619
|
-
], 8, _hoisted_16$
|
|
48641
|
+
], 8, _hoisted_16$2)
|
|
48620
48642
|
])) : vue.createCommentVNode("", true)
|
|
48621
48643
|
]);
|
|
48622
48644
|
};
|
|
@@ -48683,31 +48705,36 @@ ${escapeText(this.code(index, length))}
|
|
|
48683
48705
|
const _hoisted_1$v = { class: "grid grid-cols-1 md:grid-cols-3 gap-6 w-full" };
|
|
48684
48706
|
const _hoisted_2$f = {
|
|
48685
48707
|
key: 0,
|
|
48686
|
-
class: "relative group"
|
|
48708
|
+
class: "relative group w-full object-cover rounded-lg md:rounded-2xl overflow-hidden"
|
|
48709
|
+
};
|
|
48710
|
+
const _hoisted_3$f = {
|
|
48711
|
+
key: 0,
|
|
48712
|
+
class: "w-full h-[281px] md:rounded-2xl"
|
|
48687
48713
|
};
|
|
48688
|
-
const _hoisted_3$f = ["onClick"];
|
|
48689
48714
|
const _hoisted_4$f = ["src"];
|
|
48690
|
-
const _hoisted_5$f = ["
|
|
48691
|
-
const _hoisted_6$f =
|
|
48715
|
+
const _hoisted_5$f = ["onClick"];
|
|
48716
|
+
const _hoisted_6$f = ["src"];
|
|
48717
|
+
const _hoisted_7$e = ["src"];
|
|
48718
|
+
const _hoisted_8$d = {
|
|
48692
48719
|
key: 2,
|
|
48693
48720
|
class: "w-full h-[281px] object-cover rounded-lg md:rounded-2xl mb-4",
|
|
48694
48721
|
alt: "No Available",
|
|
48695
48722
|
src: _imports_0
|
|
48696
48723
|
};
|
|
48697
|
-
const
|
|
48698
|
-
const
|
|
48724
|
+
const _hoisted_9$d = { class: "flex flex-col gap-2 items-start text-left w-full" };
|
|
48725
|
+
const _hoisted_10$9 = {
|
|
48699
48726
|
key: 0,
|
|
48700
48727
|
class: "flex gap-2"
|
|
48701
48728
|
};
|
|
48702
|
-
const
|
|
48703
|
-
const
|
|
48704
|
-
const
|
|
48705
|
-
const
|
|
48706
|
-
const
|
|
48729
|
+
const _hoisted_11$8 = ["href"];
|
|
48730
|
+
const _hoisted_12$6 = { class: "flex justify-between" };
|
|
48731
|
+
const _hoisted_13$6 = ["innerHTML"];
|
|
48732
|
+
const _hoisted_14$5 = { class: "text-gray-500 text-sm mb-4" };
|
|
48733
|
+
const _hoisted_15$4 = {
|
|
48707
48734
|
key: 0,
|
|
48708
48735
|
class: "flex justify-center"
|
|
48709
48736
|
};
|
|
48710
|
-
const
|
|
48737
|
+
const _hoisted_16$1 = ["href", "target"];
|
|
48711
48738
|
const _sfc_main$h = {
|
|
48712
48739
|
__name: "CollectionGridPresenter",
|
|
48713
48740
|
props: {
|
|
@@ -48744,6 +48771,13 @@ ${escapeText(this.code(index, length))}
|
|
|
48744
48771
|
videoRefs.value[index] = el;
|
|
48745
48772
|
}
|
|
48746
48773
|
};
|
|
48774
|
+
const getEmbedUrl = (item) => {
|
|
48775
|
+
if (!item.youtube_url) return null;
|
|
48776
|
+
const m = item.youtube_url.match(/(?:youtube\.com\/(?:.*v=|v\/|embed\/)|youtu\.be\/)([A-Za-z0-9_-]{11})/);
|
|
48777
|
+
const id = m ? m[1] : null;
|
|
48778
|
+
if (!id) return null;
|
|
48779
|
+
return `https://www.youtube.com/embed/${id}`;
|
|
48780
|
+
};
|
|
48747
48781
|
return (_ctx, _cache) => {
|
|
48748
48782
|
var _a2, _b2;
|
|
48749
48783
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
@@ -48753,35 +48787,45 @@ ${escapeText(this.code(index, length))}
|
|
|
48753
48787
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(vue.unref(items), (card, index) => {
|
|
48754
48788
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
48755
48789
|
key: index,
|
|
48756
|
-
class: "card bg-white sm:p-0 px-4"
|
|
48790
|
+
class: "card bg-white sm:p-0 px-4 w-full"
|
|
48757
48791
|
}, [
|
|
48758
48792
|
__props.component.type === "video_grid" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$f, [
|
|
48759
|
-
vue.
|
|
48760
|
-
|
|
48761
|
-
|
|
48762
|
-
|
|
48763
|
-
|
|
48764
|
-
|
|
48765
|
-
|
|
48766
|
-
preload: "metadata"
|
|
48767
|
-
}, [
|
|
48768
|
-
vue.createElementVNode("source", {
|
|
48769
|
-
src: `${card.video}#t=2`
|
|
48793
|
+
(card == null ? void 0 : card.youtube_url) && getEmbedUrl(card) ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_3$f, [
|
|
48794
|
+
vue.createElementVNode("iframe", {
|
|
48795
|
+
src: getEmbedUrl(card),
|
|
48796
|
+
frameborder: "0",
|
|
48797
|
+
allow: "accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",
|
|
48798
|
+
allowfullscreen: "",
|
|
48799
|
+
class: "w-full h-full"
|
|
48770
48800
|
}, null, 8, _hoisted_4$f)
|
|
48771
|
-
],
|
|
48772
|
-
|
|
48773
|
-
|
|
48774
|
-
|
|
48775
|
-
|
|
48776
|
-
|
|
48801
|
+
])) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
|
|
48802
|
+
vue.createElementVNode("video", {
|
|
48803
|
+
onClick: ($event) => togglePlayPause(index),
|
|
48804
|
+
ref_for: true,
|
|
48805
|
+
ref: (el) => setVideoRef(el, index),
|
|
48806
|
+
class: "w-full h-[281px] object-cover rounded-lg md:rounded-2xl",
|
|
48807
|
+
width: "640",
|
|
48808
|
+
height: "360",
|
|
48809
|
+
preload: "metadata"
|
|
48810
|
+
}, [
|
|
48811
|
+
vue.createElementVNode("source", {
|
|
48812
|
+
src: `${card.video}#t=2`
|
|
48813
|
+
}, null, 8, _hoisted_6$f)
|
|
48814
|
+
], 8, _hoisted_5$f),
|
|
48815
|
+
!isPlaying.value[index] ? (vue.openBlock(), vue.createBlock(vue.unref(PlayButton), {
|
|
48816
|
+
key: 0,
|
|
48817
|
+
class: "cursor-pointer absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2 group-hover:opacity-100 transition-opacity",
|
|
48818
|
+
onClick: ($event) => togglePlayPause(index)
|
|
48819
|
+
}, null, 8, ["onClick"])) : vue.createCommentVNode("", true)
|
|
48820
|
+
], 64))
|
|
48777
48821
|
])) : card.image ? (vue.openBlock(), vue.createElementBlock("img", {
|
|
48778
48822
|
key: 1,
|
|
48779
48823
|
src: card.image,
|
|
48780
48824
|
alt: "Card Image",
|
|
48781
48825
|
class: "w-full h-[281px] object-cover rounded-lg md:rounded-2xl mb-4"
|
|
48782
|
-
}, null, 8,
|
|
48783
|
-
vue.createElementVNode("div",
|
|
48784
|
-
card.categories && card.categories.length ? (vue.openBlock(), vue.createElementBlock("div",
|
|
48826
|
+
}, null, 8, _hoisted_7$e)) : (vue.openBlock(), vue.createElementBlock("img", _hoisted_8$d)),
|
|
48827
|
+
vue.createElementVNode("div", _hoisted_9$d, [
|
|
48828
|
+
card.categories && card.categories.length ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_10$9, [
|
|
48785
48829
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(card.categories, (tag) => {
|
|
48786
48830
|
return vue.openBlock(), vue.createElementBlock("span", {
|
|
48787
48831
|
key: tag,
|
|
@@ -48800,20 +48844,20 @@ ${escapeText(this.code(index, length))}
|
|
|
48800
48844
|
target: "_blank",
|
|
48801
48845
|
rel: "noopener noreferrer"
|
|
48802
48846
|
}, [
|
|
48803
|
-
vue.createElementVNode("div",
|
|
48847
|
+
vue.createElementVNode("div", _hoisted_12$6, [
|
|
48804
48848
|
vue.createElementVNode("span", {
|
|
48805
48849
|
class: "w-5/6 leading-[28px]",
|
|
48806
48850
|
innerHTML: card.title
|
|
48807
|
-
}, null, 8,
|
|
48851
|
+
}, null, 8, _hoisted_13$6),
|
|
48808
48852
|
vue.createVNode(vue.unref(ArrowUpRight), { class: "w-5 h-5 mt-1" })
|
|
48809
48853
|
])
|
|
48810
|
-
], 8,
|
|
48811
|
-
vue.createElementVNode("p",
|
|
48854
|
+
], 8, _hoisted_11$8)) : vue.createCommentVNode("", true),
|
|
48855
|
+
vue.createElementVNode("p", _hoisted_14$5, vue.toDisplayString(card.dateTime), 1)
|
|
48812
48856
|
])
|
|
48813
48857
|
]);
|
|
48814
48858
|
}), 128))
|
|
48815
48859
|
]),
|
|
48816
|
-
Object.keys(vue.unref(button)).length && ((_b2 = vue.unref(button)) == null ? void 0 : _b2.show) ? (vue.openBlock(), vue.createElementBlock("div",
|
|
48860
|
+
Object.keys(vue.unref(button)).length && ((_b2 = vue.unref(button)) == null ? void 0 : _b2.show) ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_15$4, [
|
|
48817
48861
|
vue.createElementVNode("a", {
|
|
48818
48862
|
class: "border-brand-300 hover:border-brand-700 border text-brand-700 h-[44px] rounded-full px-[14px] py-[10px] inline-flex gap-1.5 items-center font-semibold text-base",
|
|
48819
48863
|
href: vue.unref(formatUrl)(vue.unref(button).url),
|
|
@@ -48821,13 +48865,13 @@ ${escapeText(this.code(index, length))}
|
|
|
48821
48865
|
}, [
|
|
48822
48866
|
vue.createTextVNode(vue.toDisplayString(vue.unref(button).title) + " ", 1),
|
|
48823
48867
|
vue.createVNode(vue.unref(ArrowUpRight), { class: "w-5 h-5" })
|
|
48824
|
-
], 8,
|
|
48868
|
+
], 8, _hoisted_16$1)
|
|
48825
48869
|
])) : vue.createCommentVNode("", true)
|
|
48826
48870
|
], 2);
|
|
48827
48871
|
};
|
|
48828
48872
|
}
|
|
48829
48873
|
};
|
|
48830
|
-
const CollectionGridPresenter = /* @__PURE__ */ _export_sfc(_sfc_main$h, [["__scopeId", "data-v-
|
|
48874
|
+
const CollectionGridPresenter = /* @__PURE__ */ _export_sfc(_sfc_main$h, [["__scopeId", "data-v-77dcb437"]]);
|
|
48831
48875
|
const _hoisted_1$u = { class: "overflow-hidden" };
|
|
48832
48876
|
const _sfc_main$g = {
|
|
48833
48877
|
__name: "CollectionGrid",
|
|
@@ -192,6 +192,7 @@ export const BestLife = {
|
|
|
192
192
|
data: [
|
|
193
193
|
{
|
|
194
194
|
video: "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ForBiggerFun.mp4",
|
|
195
|
+
youtube_url: "https://www.youtube.com/watch?v=cEpTYBuR7vY",
|
|
195
196
|
},
|
|
196
197
|
{
|
|
197
198
|
video: "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ElephantsDream.mp4",
|
package/package.json
CHANGED
|
@@ -37,6 +37,22 @@
|
|
|
37
37
|
<ActionMenu @removeItem="handleDeleteItem(index)"/>
|
|
38
38
|
</div>
|
|
39
39
|
</div>
|
|
40
|
+
<InputWrapper
|
|
41
|
+
is-vertical
|
|
42
|
+
field="line.title"
|
|
43
|
+
label-text="Youtube URL"
|
|
44
|
+
class="w-full"
|
|
45
|
+
:value="item.youtube_url"
|
|
46
|
+
>
|
|
47
|
+
<input
|
|
48
|
+
v-model="item.youtube_url"
|
|
49
|
+
name="youtube_url.youtube_url"
|
|
50
|
+
type="text"
|
|
51
|
+
placeholder="Url"
|
|
52
|
+
class="border-1 border-solid border-gray-300 rounded-lg bg-white w-full"
|
|
53
|
+
/>
|
|
54
|
+
</InputWrapper>
|
|
55
|
+
<p>OR</p>
|
|
40
56
|
<div class="flex flex-col gap-6">
|
|
41
57
|
<div class="flex flex-col gap-1.5">
|
|
42
58
|
<VFileUpload
|
|
@@ -59,6 +75,7 @@ import {defaultProps} from "@/components/helpers/defaultProps";
|
|
|
59
75
|
import ActionMenu from "@/components/common/ActionMenu.vue";
|
|
60
76
|
import VModal from "@/components/common/Modal.vue";
|
|
61
77
|
import DefaultFileUpload from "@/components/common/FileUpload.vue";
|
|
78
|
+
import InputWrapper from "@/components/common/InputWrapper.vue";
|
|
62
79
|
|
|
63
80
|
// Inject the FileUpload component or fallback to the default one
|
|
64
81
|
const VFileUpload = inject("VFileUpload", DefaultFileUpload);
|
|
@@ -1,24 +1,35 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="flex flex-col items-center gap-6 pb-[40px] pt-[24px]" :class="{'!pt-0': component.hasOwnProperty('padding_top') && !component?.padding_top}">
|
|
3
3
|
<div class="grid grid-cols-1 md:grid-cols-3 gap-6 w-full">
|
|
4
|
-
<div v-for="(card, index) in items" :key="index" class="card bg-white sm:p-0 px-4">
|
|
5
|
-
<div v-if="component.type === 'video_grid'" class="relative group">
|
|
6
|
-
<
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
4
|
+
<div v-for="(card, index) in items" :key="index" class="card bg-white sm:p-0 px-4 w-full">
|
|
5
|
+
<div v-if="component.type === 'video_grid'" class="relative group w-full object-cover rounded-lg md:rounded-2xl overflow-hidden">
|
|
6
|
+
<div v-if="card?.youtube_url && getEmbedUrl(card)" class="w-full h-[281px] md:rounded-2xl">
|
|
7
|
+
<iframe
|
|
8
|
+
:src="getEmbedUrl(card)"
|
|
9
|
+
frameborder="0"
|
|
10
|
+
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
|
|
11
|
+
allowfullscreen
|
|
12
|
+
class="w-full h-full"
|
|
13
|
+
></iframe>
|
|
14
|
+
</div>
|
|
15
|
+
<template v-else>
|
|
16
|
+
<video
|
|
17
|
+
@click="togglePlayPause(index)"
|
|
18
|
+
:ref="(el) => setVideoRef(el, index)"
|
|
19
|
+
class="w-full h-[281px] object-cover rounded-lg md:rounded-2xl"
|
|
20
|
+
width="640"
|
|
21
|
+
height="360"
|
|
22
|
+
preload="metadata"
|
|
23
|
+
>
|
|
24
|
+
<source :src="`${card.video}#t=2`" />
|
|
25
|
+
</video>
|
|
26
|
+
<PlayButton
|
|
27
|
+
v-if="!isPlaying[index]"
|
|
28
|
+
class="cursor-pointer absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2 group-hover:opacity-100 transition-opacity"
|
|
29
|
+
@click="togglePlayPause(index)">
|
|
20
30
|
|
|
21
|
-
|
|
31
|
+
</PlayButton>
|
|
32
|
+
</template>
|
|
22
33
|
</div>
|
|
23
34
|
<img
|
|
24
35
|
v-else-if="card.image"
|
|
@@ -114,6 +125,16 @@ const setVideoRef = (el, index) => {
|
|
|
114
125
|
videoRefs.value[index] = el;
|
|
115
126
|
}
|
|
116
127
|
};
|
|
128
|
+
|
|
129
|
+
const getEmbedUrl = (item) => {
|
|
130
|
+
if (!item.youtube_url) return null;
|
|
131
|
+
// match common YouTube URL formats and extract the 11-char id
|
|
132
|
+
const m = item.youtube_url.match(/(?:youtube\.com\/(?:.*v=|v\/|embed\/)|youtu\.be\/)([A-Za-z0-9_-]{11})/);
|
|
133
|
+
const id = m ? m[1] : null;
|
|
134
|
+
if (!id) return null;
|
|
135
|
+
return `https://www.youtube.com/embed/${id}`;
|
|
136
|
+
};
|
|
137
|
+
|
|
117
138
|
</script>
|
|
118
139
|
|
|
119
140
|
<style scoped>
|