@gem-sdk/components 2.2.0-staging.31 → 2.2.0
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/cjs/article/components/ArticleImage.js +1 -2
- package/dist/cjs/banner/components/hero-banner/index.liquid.js +7 -4
- package/dist/cjs/builder.js +1 -1
- package/dist/cjs/button/components/Button.js +3 -3
- package/dist/cjs/button/components/Button.liquid.js +4 -4
- package/dist/cjs/carousel/components/Carousel.liquid.js +2 -3
- package/dist/cjs/carousel/components/plugins/AutoPlayPlugin.js +58 -17
- package/dist/cjs/common/const.js +1 -1
- package/dist/cjs/grid/setting/Section.js +7 -37
- package/dist/cjs/image/components/AdaptiveImage.liquid.js +5 -6
- package/dist/cjs/image/components/Image.js +1 -2
- package/dist/cjs/image/components/Image.liquid.js +4 -6
- package/dist/cjs/image/components/NextImage.liquid.js +3 -4
- package/dist/cjs/image-comparison/components/CompareImage.liquid.js +3 -7
- package/dist/cjs/index.js +2 -2
- package/dist/cjs/index.liquid.js +2 -2
- package/dist/cjs/marquee/components/Marquee.liquid.js +13 -10
- package/dist/cjs/post-purchase/product/components/variants/Dropdown.js +1 -1
- package/dist/cjs/product/components/ProductButton.js +1 -1
- package/dist/cjs/product/components/ProductButton.liquid.js +3 -21
- package/dist/cjs/product/components/ProductImagesV2/liquid/ProductFeaturedImageCarousel.liquid.js +5 -6
- package/dist/cjs/product/components/ProductImagesV2/liquid/ProductGalleryCarousel.liquid.js +2 -2
- package/dist/cjs/product/components/ProductImagesV2/liquid/ProductGalleryGrid.liquid.js +4 -4
- package/dist/cjs/product/components/ProductImagesV2/liquid/ProductImages.liquid.js +4 -4
- package/dist/cjs/product/components/ProductVariants/variants/combine/index.js +1 -1
- package/dist/cjs/product/setting/ProductList.js +1 -1
- package/dist/cjs/tab/hooks/useTabInteraction.js +9 -13
- package/dist/cjs/third-party/components/Bogos/BogosSampleContent.js +10 -9
- package/dist/cjs/third-party/components/RechargeSubscriptions.liquid.js +1 -1
- package/dist/cjs/third-party/components/Releasit.liquid.js +2 -4
- package/dist/cjs/third-party/configs/BoldProductOptions.js +2 -2
- package/dist/cjs/third-party/configs/EcoboostifyShoppableReelUgc.js +1 -1
- package/dist/cjs/third-party/next.js +3 -3
- package/dist/cjs/third-party/setting/EcoboostifyShoppableReelUgc.js +2 -2
- package/dist/cjs/third-party/setting/Releasit.js +2 -59
- package/dist/cjs/third-party/setting/index.js +3 -3
- package/dist/cjs/video/components/HTML5Embed.js +2 -2
- package/dist/cjs/video/components/HTML5Embed.liquid.js +3 -6
- package/dist/cjs/video/components/LiteYouTubeEmbed.liquid.js +3 -5
- package/dist/esm/article/components/ArticleImage.js +1 -2
- package/dist/esm/banner/components/hero-banner/index.liquid.js +7 -4
- package/dist/esm/builder.js +1 -1
- package/dist/esm/button/components/Button.js +3 -3
- package/dist/esm/button/components/Button.liquid.js +4 -4
- package/dist/esm/carousel/components/Carousel.liquid.js +2 -3
- package/dist/esm/carousel/components/plugins/AutoPlayPlugin.js +58 -17
- package/dist/esm/common/const.js +1 -1
- package/dist/esm/grid/setting/Section.js +7 -37
- package/dist/esm/image/components/AdaptiveImage.liquid.js +5 -6
- package/dist/esm/image/components/Image.js +2 -3
- package/dist/esm/image/components/Image.liquid.js +4 -6
- package/dist/esm/image/components/NextImage.liquid.js +3 -4
- package/dist/esm/image-comparison/components/CompareImage.liquid.js +3 -7
- package/dist/esm/index.js +1 -1
- package/dist/esm/index.liquid.js +1 -1
- package/dist/esm/marquee/components/Marquee.liquid.js +13 -10
- package/dist/esm/post-purchase/product/components/variants/Dropdown.js +1 -1
- package/dist/esm/product/components/ProductButton.js +1 -1
- package/dist/esm/product/components/ProductButton.liquid.js +3 -21
- package/dist/esm/product/components/ProductImagesV2/liquid/ProductFeaturedImageCarousel.liquid.js +5 -6
- package/dist/esm/product/components/ProductImagesV2/liquid/ProductGalleryCarousel.liquid.js +2 -2
- package/dist/esm/product/components/ProductImagesV2/liquid/ProductGalleryGrid.liquid.js +4 -4
- package/dist/esm/product/components/ProductImagesV2/liquid/ProductImages.liquid.js +4 -4
- package/dist/esm/product/components/ProductVariants/variants/combine/index.js +1 -1
- package/dist/esm/product/setting/ProductList.js +1 -1
- package/dist/esm/tab/hooks/useTabInteraction.js +10 -14
- package/dist/esm/third-party/components/Bogos/BogosSampleContent.js +11 -10
- package/dist/esm/third-party/components/RechargeSubscriptions.liquid.js +1 -1
- package/dist/esm/third-party/components/Releasit.liquid.js +2 -4
- package/dist/esm/third-party/configs/BoldProductOptions.js +2 -2
- package/dist/esm/third-party/configs/EcoboostifyShoppableReelUgc.js +1 -1
- package/dist/esm/third-party/next.js +3 -3
- package/dist/esm/third-party/setting/EcoboostifyShoppableReelUgc.js +2 -2
- package/dist/esm/third-party/setting/Releasit.js +2 -59
- package/dist/esm/third-party/setting/index.js +4 -4
- package/dist/esm/video/components/HTML5Embed.js +2 -2
- package/dist/esm/video/components/HTML5Embed.liquid.js +3 -6
- package/dist/esm/video/components/LiteYouTubeEmbed.liquid.js +3 -5
- package/dist/types/index.d.ts +15 -29
- package/package.json +3 -3
|
@@ -188,22 +188,6 @@ const ProductButton = ({ setting, builderProps, builderAttrs, style, styles, adv
|
|
|
188
188
|
pageContext,
|
|
189
189
|
translate: setting?.translate
|
|
190
190
|
});
|
|
191
|
-
const labelUnavailableTranslate = helpers.getDynamicSourceLocales({
|
|
192
|
-
val: 'Unavailable',
|
|
193
|
-
uid: builderProps?.uid,
|
|
194
|
-
settingId: 'unavailableLabel',
|
|
195
|
-
isLiquid: true,
|
|
196
|
-
pageContext,
|
|
197
|
-
translate: setting?.translate ? 'unavailableLabel' : undefined
|
|
198
|
-
});
|
|
199
|
-
const labelOutOfStockTranslate = helpers.getDynamicSourceLocales({
|
|
200
|
-
val: setting?.outOfStockLabel,
|
|
201
|
-
uid: builderProps?.uid,
|
|
202
|
-
settingId: 'outOfStockLabel',
|
|
203
|
-
isLiquid: true,
|
|
204
|
-
pageContext,
|
|
205
|
-
translate: setting?.translate ? 'outOfStockLabel' : undefined
|
|
206
|
-
});
|
|
207
191
|
return core.template /* liquid */ `
|
|
208
192
|
{%- liquid
|
|
209
193
|
assign inventory_quantity = variant.inventory_quantity | default: 0
|
|
@@ -211,8 +195,6 @@ const ProductButton = ({ setting, builderProps, builderAttrs, style, styles, adv
|
|
|
211
195
|
<gp-product-button
|
|
212
196
|
class="gp-product-button"
|
|
213
197
|
gp-data-wrapper="true"
|
|
214
|
-
label-out-of-Stock="${pageContext?.isPreviewing ? labelOutOfStockTranslate : `{{${labelOutOfStockTranslate}}}`}"
|
|
215
|
-
label-unavailable="${pageContext?.isPreviewing ? labelUnavailableTranslate : `{{${labelUnavailableTranslate}}}`}"
|
|
216
198
|
gp-data='${JSON.stringify({
|
|
217
199
|
setting: {
|
|
218
200
|
actionEffect: setting?.actionEffect,
|
|
@@ -290,7 +272,8 @@ const ProductButton = ({ setting, builderProps, builderAttrs, style, styles, adv
|
|
|
290
272
|
'gp-data-hidden': `{% if variant.available %}true{% endif %}`
|
|
291
273
|
},
|
|
292
274
|
setting: {
|
|
293
|
-
label:
|
|
275
|
+
label: setting?.outOfStockLabel,
|
|
276
|
+
translate: setting?.translate ? 'outOfStockLabel' : undefined,
|
|
294
277
|
htmlType: 'button',
|
|
295
278
|
iconAlign: iconAlign,
|
|
296
279
|
iconSvg: iconSvg,
|
|
@@ -309,8 +292,7 @@ const ProductButton = ({ setting, builderProps, builderAttrs, style, styles, adv
|
|
|
309
292
|
}
|
|
310
293
|
},
|
|
311
294
|
pageContext,
|
|
312
|
-
nodePrice: composeNodePrice()
|
|
313
|
-
isForceValue: true
|
|
295
|
+
nodePrice: composeNodePrice()
|
|
314
296
|
})}
|
|
315
297
|
</gp-product-button>
|
|
316
298
|
${core.RenderIf(core.isLocalEnv, `<script ${helpers.getSettingPreloadData('class="gps-link" delay', 'src')}="{{ 'gp-product-button.js' | asset_url }}" defer="defer"></script>`, `<script ${helpers.getSettingPreloadData('class="gps-link" delay', 'src')}="${core.baseAssetURL}/assets-v2/gp-product-button.js?v={{ shop.metafields.GEMPAGES.ASSETS_VERSION }}" defer="defer"></script>`)}
|
package/dist/cjs/product/components/ProductImagesV2/liquid/ProductFeaturedImageCarousel.liquid.js
CHANGED
|
@@ -13,7 +13,7 @@ var NextImage_liquid = require('../../../../image/components/NextImage.liquid.js
|
|
|
13
13
|
var Video_liquid = require('../../../../image/components/Video.liquid.js');
|
|
14
14
|
var _function = require('../../../helpers/function.js');
|
|
15
15
|
|
|
16
|
-
const ProductFeaturedImageCarousel = ({ builderPropUID, children,
|
|
16
|
+
const ProductFeaturedImageCarousel = ({ builderPropUID, children, enableLazyloadImage, ...setting })=>{
|
|
17
17
|
const ftAspectRatio = common.getAspectRatio(setting.ftShape);
|
|
18
18
|
const getStyleFeaturedImageDisplay = ()=>{
|
|
19
19
|
return common.getDisplayStyle((device)=>![
|
|
@@ -153,7 +153,7 @@ const ProductFeaturedImageCarousel = ({ builderPropUID, children, enableLazyLoad
|
|
|
153
153
|
},
|
|
154
154
|
priority: setting?.preload,
|
|
155
155
|
className: `gp-w-full gp-h-full gp-absolute gp-top-0 gp-left-0 featured-image-only gp-cursor-pointer !gp-rounded-none ${className}`,
|
|
156
|
-
|
|
156
|
+
enableLazyloadImage
|
|
157
157
|
})}`;
|
|
158
158
|
};
|
|
159
159
|
const renderNoImage = ()=>{
|
|
@@ -171,7 +171,7 @@ const ProductFeaturedImageCarousel = ({ builderPropUID, children, enableLazyLoad
|
|
|
171
171
|
},
|
|
172
172
|
priority: setting?.preload,
|
|
173
173
|
className: `gp-w-full gp-h-full gp-absolute gp-top-0 gp-left-0 featured-image-only gp-cursor-pointer !gp-rounded-none`,
|
|
174
|
-
|
|
174
|
+
enableLazyloadImage
|
|
175
175
|
})}`;
|
|
176
176
|
};
|
|
177
177
|
const getValueFromValueContainUnit = (value)=>{
|
|
@@ -398,11 +398,10 @@ const ProductFeaturedImageCarousel = ({ builderPropUID, children, enableLazyLoad
|
|
|
398
398
|
},
|
|
399
399
|
className: `gp-w-full featured-image-only !gp-rounded-none`,
|
|
400
400
|
customLazyload: true,
|
|
401
|
-
|
|
401
|
+
enableLazyloadImage
|
|
402
402
|
})}
|
|
403
403
|
{%- endif -%}
|
|
404
|
-
|
|
405
|
-
ftShapeProductImage: setting?.ftShape
|
|
404
|
+
`
|
|
406
405
|
})}
|
|
407
406
|
`;
|
|
408
407
|
};
|
|
@@ -10,7 +10,7 @@ var common = require('../common/common.js');
|
|
|
10
10
|
var productGallery = require('../common/productGallery.js');
|
|
11
11
|
var _function = require('../../../helpers/function.js');
|
|
12
12
|
|
|
13
|
-
const ProductGalleryCarousel = ({ builderPropUID, children,
|
|
13
|
+
const ProductGalleryCarousel = ({ builderPropUID, children, enableLazyloadImage, ...setting })=>{
|
|
14
14
|
const getCarouselDisplay = ()=>{
|
|
15
15
|
const isDisplayCarousel = (type, position, device)=>{
|
|
16
16
|
const layout = core.getResponsiveValueByScreen(position, device);
|
|
@@ -90,7 +90,7 @@ const ProductGalleryCarousel = ({ builderPropUID, children, enableLazyLoadImage,
|
|
|
90
90
|
customLazyload: true,
|
|
91
91
|
style: style,
|
|
92
92
|
className: '!gp-rounded-none gp-w-full gp-h-full gp-absolute gp-top-0 gp-left-0 gp-cursor-pointer',
|
|
93
|
-
|
|
93
|
+
enableLazyloadImage
|
|
94
94
|
})}`;
|
|
95
95
|
};
|
|
96
96
|
const aspectRatioToPaddingBottom = ()=>{
|
|
@@ -12,7 +12,7 @@ var Modal3d_liquid = require('../../../../image/components/Modal3d.liquid.js');
|
|
|
12
12
|
var Video_liquid = require('../../../../image/components/Video.liquid.js');
|
|
13
13
|
var HTML5Embed_liquid = require('../../../../video/components/HTML5Embed.liquid.js');
|
|
14
14
|
|
|
15
|
-
const ProductGalleryGrid = ({ builderPropUID, wrapperStyle, children,
|
|
15
|
+
const ProductGalleryGrid = ({ builderPropUID, wrapperStyle, children, enableLazyloadImage, ...setting })=>{
|
|
16
16
|
const getGridDisplay = ()=>{
|
|
17
17
|
const isDisplayGrid = (type, position, device)=>{
|
|
18
18
|
const layout = core.getResponsiveValueByScreen(position, device);
|
|
@@ -101,7 +101,7 @@ const ProductGalleryGrid = ({ builderPropUID, wrapperStyle, children, enableLazy
|
|
|
101
101
|
style: style,
|
|
102
102
|
className: '!gp-rounded-none',
|
|
103
103
|
customLazyload: false,
|
|
104
|
-
|
|
104
|
+
enableLazyloadImage
|
|
105
105
|
})}
|
|
106
106
|
${setting?.galleryHoverEffect !== 'none' ? `<div class="${core.cls('zoom-element !gp-max-w-none', productFeaturedImage.getZoomImageClass())}">
|
|
107
107
|
${NextImage_liquid.default({
|
|
@@ -115,7 +115,7 @@ const ProductGalleryGrid = ({ builderPropUID, wrapperStyle, children, enableLazy
|
|
|
115
115
|
style: style,
|
|
116
116
|
className: '!gp-rounded-none gp-w-full gp-h-full',
|
|
117
117
|
customLazyload: false,
|
|
118
|
-
|
|
118
|
+
enableLazyloadImage
|
|
119
119
|
})}
|
|
120
120
|
</div>` : ''}
|
|
121
121
|
${setting?.galleryHoverEffect == 'zoom' && setting?.galleryZoomType == 'glasses' ? `
|
|
@@ -298,7 +298,7 @@ const ProductGalleryGrid = ({ builderPropUID, wrapperStyle, children, enableLazy
|
|
|
298
298
|
},
|
|
299
299
|
className: '!gp-rounded-none',
|
|
300
300
|
customLazyload: false,
|
|
301
|
-
|
|
301
|
+
enableLazyloadImage
|
|
302
302
|
})}`;
|
|
303
303
|
};
|
|
304
304
|
return core.template`
|
|
@@ -11,7 +11,7 @@ var helpers = require('../../../../helpers.js');
|
|
|
11
11
|
var productGallery = require('../common/productGallery.js');
|
|
12
12
|
|
|
13
13
|
const ProductImages = (productImageProps)=>{
|
|
14
|
-
const { setting, styles, builderProps, style, advanced, rawChildren, pageContext,
|
|
14
|
+
const { setting, styles, builderProps, style, advanced, rawChildren, pageContext, enableLazyloadImage } = productImageProps;
|
|
15
15
|
const settings = {
|
|
16
16
|
...setting,
|
|
17
17
|
...styles
|
|
@@ -116,7 +116,7 @@ const ProductImages = (productImageProps)=>{
|
|
|
116
116
|
builderPropUID: `gp-carousel-${builderProps?.uid}`,
|
|
117
117
|
...settings,
|
|
118
118
|
children: renderProductBadge(),
|
|
119
|
-
|
|
119
|
+
enableLazyloadImage
|
|
120
120
|
})}
|
|
121
121
|
${common.shouldSkipLiquidRenderForSingleImage(settings?.position, core.template`
|
|
122
122
|
<div
|
|
@@ -132,7 +132,7 @@ const ProductImages = (productImageProps)=>{
|
|
|
132
132
|
${ProductGalleryCarousel_liquid.default({
|
|
133
133
|
builderPropUID: `gp-gallery-${builderProps?.uid}`,
|
|
134
134
|
...settings,
|
|
135
|
-
|
|
135
|
+
enableLazyloadImage
|
|
136
136
|
})}
|
|
137
137
|
</div>
|
|
138
138
|
${ProductGalleryGrid_liquid.default({
|
|
@@ -142,7 +142,7 @@ const ProductImages = (productImageProps)=>{
|
|
|
142
142
|
},
|
|
143
143
|
children: renderProductBadge(),
|
|
144
144
|
...settings,
|
|
145
|
-
|
|
145
|
+
enableLazyloadImage
|
|
146
146
|
})}
|
|
147
147
|
`)}
|
|
148
148
|
</div>
|
|
@@ -40,7 +40,7 @@ const renderCombineVariants = (isSoldOutMark, hasPreSelected, enablePrice)=>{
|
|
|
40
40
|
`}`;
|
|
41
41
|
};
|
|
42
42
|
const renderBlankOption = (hasPreSelected, blankText)=>{
|
|
43
|
-
return !hasPreSelected ? `<option value="blank" selected>${blankText
|
|
43
|
+
return !hasPreSelected ? `<option value="blank" selected>${blankText ?? helpers.getStaticLocale('ProductVariants', 'please_select')}</option>` : '';
|
|
44
44
|
};
|
|
45
45
|
|
|
46
46
|
exports.renderBlankOption = renderBlankOption;
|
|
@@ -818,7 +818,7 @@ const config = {
|
|
|
818
818
|
options: {
|
|
819
819
|
tooltip: {
|
|
820
820
|
icon: 'info-line-16',
|
|
821
|
-
content: 'Note: this might not work properly on Safari for iOS versions below
|
|
821
|
+
content: 'Note: this might not work properly on Safari for iOS versions below 17',
|
|
822
822
|
iconClass: 'text-[#757575] hover:text-[#F9F9F9]'
|
|
823
823
|
}
|
|
824
824
|
},
|
|
@@ -4,18 +4,19 @@ var core = require('@gem-sdk/core');
|
|
|
4
4
|
var React = require('react');
|
|
5
5
|
|
|
6
6
|
const useTabInteraction = ({ activeKey, setActiveKey, activeTab, refContainer, componentUid })=>{
|
|
7
|
-
const
|
|
7
|
+
const [previousTab, setPreviousTab] = React.useState(activeKey || 1);
|
|
8
|
+
const { trigger, onListener, interactionListenerLoaded } = core.useInteraction();
|
|
8
9
|
const mode = core.useEditorMode();
|
|
9
10
|
const changeOpenTabInteraction = (params)=>{
|
|
10
|
-
const { data, isRollback
|
|
11
|
-
if (data === undefined && isRollback) return;
|
|
12
|
-
const newData = Number(data) + 1;
|
|
11
|
+
const { data, isRollback } = params || {};
|
|
12
|
+
if (data === undefined && isRollback === undefined) return;
|
|
13
13
|
if (isRollback) {
|
|
14
|
-
setActiveKey(
|
|
14
|
+
setActiveKey(previousTab);
|
|
15
|
+
setPreviousTab(activeTab);
|
|
15
16
|
return;
|
|
16
17
|
}
|
|
17
|
-
|
|
18
|
-
setActiveKey(
|
|
18
|
+
setPreviousTab(activeTab);
|
|
19
|
+
setActiveKey(data + 1);
|
|
19
20
|
};
|
|
20
21
|
const dispatchEventTabActive = (index)=>{
|
|
21
22
|
trigger({
|
|
@@ -36,16 +37,11 @@ const useTabInteraction = ({ activeKey, setActiveKey, activeTab, refContainer, c
|
|
|
36
37
|
dispatchEventTabActive(activeTab - 1);
|
|
37
38
|
});
|
|
38
39
|
const selector = `[data-id="${componentUid}"]`;
|
|
39
|
-
const element = findElementIncludingSelf(document, selector);
|
|
40
40
|
const removeListener = onListener({
|
|
41
41
|
event: 'gp:change-open-tab',
|
|
42
42
|
selector
|
|
43
43
|
}, (params)=>{
|
|
44
|
-
changeOpenTabInteraction(
|
|
45
|
-
...params,
|
|
46
|
-
element,
|
|
47
|
-
key: params?.uniqueStorageKey
|
|
48
|
-
});
|
|
44
|
+
changeOpenTabInteraction(params);
|
|
49
45
|
});
|
|
50
46
|
return ()=>{
|
|
51
47
|
removeListener?.();
|
|
@@ -13,8 +13,7 @@ const mapWidgetLabel = {
|
|
|
13
13
|
slider: 'Gift slider',
|
|
14
14
|
message: 'Cart message',
|
|
15
15
|
['classic-bundle']: 'Classic bundle',
|
|
16
|
-
['quantity-break']: 'Quantity break'
|
|
17
|
-
['mix-match']: 'Mix and match'
|
|
16
|
+
['quantity-break']: 'Quantity break'
|
|
18
17
|
};
|
|
19
18
|
const BogosSampleContent = ({ setting })=>{
|
|
20
19
|
const widgetLabel = setting?.widgetType && mapWidgetLabel[setting.widgetType];
|
|
@@ -23,13 +22,15 @@ const BogosSampleContent = ({ setting })=>{
|
|
|
23
22
|
}, [
|
|
24
23
|
widgetLabel
|
|
25
24
|
]);
|
|
26
|
-
return /*#__PURE__*/ jsxRuntime.jsx(
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
25
|
+
return /*#__PURE__*/ jsxRuntime.jsx(jsxRuntime.Fragment, {
|
|
26
|
+
children: /*#__PURE__*/ jsxRuntime.jsx("div", {
|
|
27
|
+
className: "p-2",
|
|
28
|
+
children: /*#__PURE__*/ jsxRuntime.jsx(ThirdPartyPreview.default, {
|
|
29
|
+
setting: {
|
|
30
|
+
label,
|
|
31
|
+
iconSvg: `<img class="gp-w-[24px] border border-[#494949] rounded-[3px]" src="${Bogos.default.logoUrl}">`
|
|
32
|
+
}
|
|
33
|
+
})
|
|
33
34
|
})
|
|
34
35
|
});
|
|
35
36
|
};
|
|
@@ -6,7 +6,7 @@ var thirdParty = require('../helpers/thirdParty.js');
|
|
|
6
6
|
|
|
7
7
|
const RechargeSubscriptions = ({ setting, advanced })=>{
|
|
8
8
|
const { align, appBlockId } = setting ?? {};
|
|
9
|
-
return thirdParty.getLiquidForAppBlock(appBlockId, align, `${advanced?.cssClass ?? ''}
|
|
9
|
+
return thirdParty.getLiquidForAppBlock(appBlockId, align, `${advanced?.cssClass ?? ''}!gp-block`);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
exports.default = RechargeSubscriptions;
|
|
@@ -2,13 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var thirdParty = require('../helpers/thirdParty.js');
|
|
6
5
|
var core = require('@gem-sdk/core');
|
|
7
6
|
|
|
8
7
|
const Releasit = ({ setting, advanced })=>{
|
|
9
|
-
const { align
|
|
10
|
-
|
|
11
|
-
return version === 'v2' ? thirdParty.getLiquidForAppBlock(appBlockId, align, `${advanced?.cssClass ?? ''}!gp-block`) : core.template`
|
|
8
|
+
const { align } = setting ?? {};
|
|
9
|
+
return core.template`
|
|
12
10
|
<div
|
|
13
11
|
class="${advanced?.cssClass}"
|
|
14
12
|
style="${{
|
|
@@ -4,8 +4,8 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
var BoldProductOptionsConfig = {
|
|
6
6
|
id: 'bold-product-options',
|
|
7
|
-
label: '
|
|
8
|
-
logoUrl: 'https://
|
|
7
|
+
label: 'Bold Product Options',
|
|
8
|
+
logoUrl: 'https://ucarecdn.com/cae13b55-18b6-416a-a447-c18211d78cfe/-/format/auto/-/preview/3000x3000/-/quality/lighter/Bold%20Product%20Options.png',
|
|
9
9
|
tag: 'BoldProductOptions'
|
|
10
10
|
};
|
|
11
11
|
|
|
@@ -5,7 +5,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
var AppConfig = {
|
|
6
6
|
id: 'ecoboostify-shoppable-reel-ugc',
|
|
7
7
|
label: 'EcoBoostify Shoppable Reel UGC',
|
|
8
|
-
logoUrl: 'https://cdn.shopify.com/app-store/listing_images/cdbdfc53291cf8d2908e72deae77f94e/icon/
|
|
8
|
+
logoUrl: 'https://cdn.shopify.com/app-store/listing_images/cdbdfc53291cf8d2908e72deae77f94e/icon/COuT9MaKvosDEAE=.png',
|
|
9
9
|
tag: 'EcoboostifyShoppableReelUgc'
|
|
10
10
|
};
|
|
11
11
|
|
|
@@ -6,11 +6,11 @@ var dynamic = require('next/dynamic');
|
|
|
6
6
|
var Loading = require('../common/components/Loading.js');
|
|
7
7
|
require('react/jsx-runtime');
|
|
8
8
|
|
|
9
|
-
const
|
|
9
|
+
const AppstleBundlesDiscounts = dynamic(()=>Promise.resolve().then(function () { return require('./components/AppstleBundlesDiscounts.js'); }), {
|
|
10
10
|
ssr: false,
|
|
11
11
|
loading: Loading.default
|
|
12
12
|
});
|
|
13
|
-
const
|
|
13
|
+
const EcomsendBackInStockAlert = dynamic(()=>Promise.resolve().then(function () { return require('./components/EcomsendBackInStockAlert.js'); }), {
|
|
14
14
|
ssr: false,
|
|
15
15
|
loading: Loading.default
|
|
16
16
|
});
|
|
@@ -471,8 +471,8 @@ const EcoboostifyShoppableReelUgc = dynamic(()=>Promise.resolve().then(function
|
|
|
471
471
|
loading: Loading.default
|
|
472
472
|
});
|
|
473
473
|
var thirdParty = {
|
|
474
|
-
EcomsendBackInStockAlert,
|
|
475
474
|
AppstleBundlesDiscounts,
|
|
475
|
+
EcomsendBackInStockAlert,
|
|
476
476
|
EcoboostifyShoppableReelUgc,
|
|
477
477
|
EstimatedDeliveryDatePlus,
|
|
478
478
|
OkendoReviewsLoyalty,
|
|
@@ -7,7 +7,7 @@ var EcoboostifyShoppableReelUgc = require('../configs/EcoboostifyShoppableReelUg
|
|
|
7
7
|
const config = {
|
|
8
8
|
tag: EcoboostifyShoppableReelUgc.default.tag,
|
|
9
9
|
label: EcoboostifyShoppableReelUgc.default.label,
|
|
10
|
-
icon: '<img class="gp-w-6 gp-border gp-border-[#494949] gp-rounded-[3px]" src="https://cdn.shopify.com/app-store/listing_images/cdbdfc53291cf8d2908e72deae77f94e/icon/
|
|
10
|
+
icon: '<img class="gp-w-6 gp-border gp-border-[#494949] gp-rounded-[3px]" src="https://cdn.shopify.com/app-store/listing_images/cdbdfc53291cf8d2908e72deae77f94e/icon/COuT9MaKvosDEAE=.png">',
|
|
11
11
|
editorConfigs: {
|
|
12
12
|
component: {
|
|
13
13
|
isThirdParty: true
|
|
@@ -22,7 +22,7 @@ const config = {
|
|
|
22
22
|
hideTextContent: true,
|
|
23
23
|
icon: {
|
|
24
24
|
desktop: `<div class="w-full flex flex-col items-center">
|
|
25
|
-
<img class="w-24 border border-dark-200 rounded-medium" src="https://cdn.shopify.com/app-store/listing_images/cdbdfc53291cf8d2908e72deae77f94e/icon/
|
|
25
|
+
<img class="w-24 border border-dark-200 rounded-medium" src="https://cdn.shopify.com/app-store/listing_images/cdbdfc53291cf8d2908e72deae77f94e/icon/COuT9MaKvosDEAE=.png">
|
|
26
26
|
<span class="preset-item-title">EcoBoostify Shoppable Reel UGC</span>
|
|
27
27
|
</div>`
|
|
28
28
|
},
|
|
@@ -11,11 +11,6 @@ const config = {
|
|
|
11
11
|
editorConfigs: {
|
|
12
12
|
component: {
|
|
13
13
|
isThirdParty: true
|
|
14
|
-
},
|
|
15
|
-
placeholder: {
|
|
16
|
-
flowTag: [
|
|
17
|
-
'Product'
|
|
18
|
-
]
|
|
19
14
|
}
|
|
20
15
|
},
|
|
21
16
|
presets: [
|
|
@@ -44,16 +39,6 @@ const config = {
|
|
|
44
39
|
{
|
|
45
40
|
id: 'setting',
|
|
46
41
|
controls: [
|
|
47
|
-
{
|
|
48
|
-
id: 'appBlockId',
|
|
49
|
-
type: 'input',
|
|
50
|
-
default: ''
|
|
51
|
-
},
|
|
52
|
-
{
|
|
53
|
-
id: 'productHandle',
|
|
54
|
-
type: 'input',
|
|
55
|
-
default: ''
|
|
56
|
-
},
|
|
57
42
|
{
|
|
58
43
|
id: 'install',
|
|
59
44
|
type: 'open-link',
|
|
@@ -70,38 +55,6 @@ const config = {
|
|
|
70
55
|
href: 'https://admin.shopify.com/?redirect=/apps/releasit-cod-order-form',
|
|
71
56
|
appName: Releasit.default.label
|
|
72
57
|
},
|
|
73
|
-
{
|
|
74
|
-
id: 'version',
|
|
75
|
-
label: 'Choose version',
|
|
76
|
-
type: 'select',
|
|
77
|
-
default: 'v1',
|
|
78
|
-
options: [
|
|
79
|
-
{
|
|
80
|
-
label: 'V1',
|
|
81
|
-
value: 'v1'
|
|
82
|
-
},
|
|
83
|
-
{
|
|
84
|
-
label: 'V2',
|
|
85
|
-
value: 'v2'
|
|
86
|
-
}
|
|
87
|
-
]
|
|
88
|
-
},
|
|
89
|
-
{
|
|
90
|
-
id: 'widgetTypeV2',
|
|
91
|
-
label: 'Choose widget',
|
|
92
|
-
type: 'select',
|
|
93
|
-
default: 'button-app-block',
|
|
94
|
-
options: [
|
|
95
|
-
{
|
|
96
|
-
label: 'Releasit button',
|
|
97
|
-
value: 'button-app-block'
|
|
98
|
-
},
|
|
99
|
-
{
|
|
100
|
-
label: 'Releasit embedded form',
|
|
101
|
-
value: 'form-app-block'
|
|
102
|
-
}
|
|
103
|
-
]
|
|
104
|
-
},
|
|
105
58
|
{
|
|
106
59
|
id: 'align',
|
|
107
60
|
label: 'Alignment',
|
|
@@ -139,24 +92,14 @@ const config = {
|
|
|
139
92
|
id: 'install'
|
|
140
93
|
}
|
|
141
94
|
},
|
|
142
|
-
{
|
|
143
|
-
type: 'control',
|
|
144
|
-
label: {
|
|
145
|
-
en: 'Choose version'
|
|
146
|
-
},
|
|
147
|
-
setting: {
|
|
148
|
-
id: 'version'
|
|
149
|
-
}
|
|
150
|
-
},
|
|
151
95
|
{
|
|
152
96
|
type: 'control',
|
|
153
97
|
label: {
|
|
154
98
|
en: 'Choose widget'
|
|
155
99
|
},
|
|
156
100
|
setting: {
|
|
157
|
-
id: '
|
|
158
|
-
}
|
|
159
|
-
condition: 'version === "v2"'
|
|
101
|
+
id: 'widgetType'
|
|
102
|
+
}
|
|
160
103
|
},
|
|
161
104
|
{
|
|
162
105
|
type: 'control',
|
|
@@ -116,8 +116,8 @@ var BfSizeChartSizeGuide = require('./BfSizeChartSizeGuide.js');
|
|
|
116
116
|
var AlsoBoughtCbb = require('./AlsoBoughtCbb.js');
|
|
117
117
|
var HextomFreeShippingBar = require('./HextomFreeShippingBar.js');
|
|
118
118
|
var EcoboostifyShoppableReelUgc = require('./EcoboostifyShoppableReelUgc.js');
|
|
119
|
-
var EcomsendBackInStockAlert = require('./EcomsendBackInStockAlert.js');
|
|
120
119
|
var AppstleBundlesDiscounts = require('./AppstleBundlesDiscounts.js');
|
|
120
|
+
var EcomsendBackInStockAlert = require('./EcomsendBackInStockAlert.js');
|
|
121
121
|
|
|
122
122
|
var index = {
|
|
123
123
|
HextomCountdownTimerBar: HextomCountdownTimerBar.default,
|
|
@@ -234,8 +234,8 @@ var index = {
|
|
|
234
234
|
AlsoBoughtCbb: AlsoBoughtCbb.default,
|
|
235
235
|
HextomFreeShippingBar: HextomFreeShippingBar.default,
|
|
236
236
|
EcoboostifyShoppableReelUgc: EcoboostifyShoppableReelUgc.default,
|
|
237
|
-
|
|
238
|
-
|
|
237
|
+
AppstleBundlesDiscounts: AppstleBundlesDiscounts.default,
|
|
238
|
+
EcomsendBackInStockAlert: EcomsendBackInStockAlert.default
|
|
239
239
|
};
|
|
240
240
|
|
|
241
241
|
exports.default = index;
|
|
@@ -51,14 +51,14 @@ const HTML5Embed = (props)=>{
|
|
|
51
51
|
}),
|
|
52
52
|
props.thumbnail && showThumbnail && /*#__PURE__*/ jsxRuntime.jsxs("div", {
|
|
53
53
|
role: "presentation",
|
|
54
|
-
className: "gp-absolute gp-top-0 gp-left-0 gp-w-full
|
|
54
|
+
className: "gp-absolute gp-top-0 gp-left-0 gp-w-full",
|
|
55
55
|
onClick: playVideoAndTurnOffThumbnail,
|
|
56
56
|
style: props.style,
|
|
57
57
|
children: [
|
|
58
58
|
/*#__PURE__*/ jsxRuntime.jsx("img", {
|
|
59
59
|
id: "video-thumbnail",
|
|
60
60
|
src: props.thumbnail,
|
|
61
|
-
className: "gp-w-full gp-h-full gp-object-
|
|
61
|
+
className: "gp-w-full gp-h-full gp-object-cover gp-thumbnail-video",
|
|
62
62
|
alt: "Video Thumbnail"
|
|
63
63
|
}),
|
|
64
64
|
/*#__PURE__*/ jsxRuntime.jsx("button", {
|
|
@@ -7,7 +7,6 @@ var NextImage_liquid = require('../../image/components/NextImage.liquid.js');
|
|
|
7
7
|
var helpers = require('../../helpers.js');
|
|
8
8
|
|
|
9
9
|
const HTML5Embed = (props)=>{
|
|
10
|
-
const { enableLazyLoadImage, pageContext } = props;
|
|
11
10
|
const videoId = `gp-video-${props.uid}`;
|
|
12
11
|
const preloadThumbnail = props.autoplay && props.thumbnail;
|
|
13
12
|
const offLazyVideo = !props.lazy && props.isVideoComponent;
|
|
@@ -24,9 +23,7 @@ const HTML5Embed = (props)=>{
|
|
|
24
23
|
'--op': 0,
|
|
25
24
|
'--z': -1,
|
|
26
25
|
display: 'none'
|
|
27
|
-
}
|
|
28
|
-
enableLazyLoadImage,
|
|
29
|
-
pageContext
|
|
26
|
+
}
|
|
30
27
|
})}
|
|
31
28
|
${core.RenderIf(props.autoplay, `<script>
|
|
32
29
|
document.addEventListener("DOMContentLoaded", (event) => {
|
|
@@ -75,14 +72,14 @@ const HTML5Embed = (props)=>{
|
|
|
75
72
|
</video>
|
|
76
73
|
<div
|
|
77
74
|
style="${props.style}"
|
|
78
|
-
class="${core.cls('gp-absolute gp-top-0 gp-left-0 gp-w-full gp-
|
|
75
|
+
class="${core.cls('gp-absolute gp-top-0 gp-left-0 gp-w-full gp-thumbnail-video', {
|
|
79
76
|
'gp-hidden': !props.thumbnail || props.autoplay
|
|
80
77
|
})}"
|
|
81
78
|
>
|
|
82
79
|
<img
|
|
83
80
|
id="video-thumbnail"
|
|
84
81
|
src="${props.thumbnail ?? ''}"
|
|
85
|
-
class="gp-w-full gp-h-full gp-object-
|
|
82
|
+
class="gp-w-full gp-h-full gp-object-cover"
|
|
86
83
|
alt="Video Thumbnail"
|
|
87
84
|
></img>
|
|
88
85
|
<button
|
|
@@ -7,7 +7,7 @@ var NextImage_liquid = require('../../image/components/NextImage.liquid.js');
|
|
|
7
7
|
var helpers = require('../../helpers.js');
|
|
8
8
|
|
|
9
9
|
const LiteYouTubeEmbed = (props)=>{
|
|
10
|
-
const { style, lazy, preload
|
|
10
|
+
const { style, lazy, preload } = props;
|
|
11
11
|
const videoUid = `gp-video-${props.uid}`;
|
|
12
12
|
const videoId = encodeURIComponent(props.id);
|
|
13
13
|
const videoTitle = props.title;
|
|
@@ -42,7 +42,7 @@ const LiteYouTubeEmbed = (props)=>{
|
|
|
42
42
|
data-title="${videoTitle}"
|
|
43
43
|
style="${{
|
|
44
44
|
...core.makeStyleResponsive('bgi', {
|
|
45
|
-
desktop: preload
|
|
45
|
+
desktop: preload ? `url('${posterUrl}')` : `url('${imagePlaceholder}')`
|
|
46
46
|
}),
|
|
47
47
|
...style
|
|
48
48
|
}}"
|
|
@@ -52,9 +52,7 @@ const LiteYouTubeEmbed = (props)=>{
|
|
|
52
52
|
src: posterUrl,
|
|
53
53
|
alt: 'Poster',
|
|
54
54
|
className: `gp-invisible gp-w-full gp-h-full gp_lazyforbg`,
|
|
55
|
-
isDisableAspectStyle: true
|
|
56
|
-
enableLazyLoadImage,
|
|
57
|
-
pageContext
|
|
55
|
+
isDisableAspectStyle: true
|
|
58
56
|
})}
|
|
59
57
|
<button
|
|
60
58
|
type="button"
|
|
@@ -10,7 +10,7 @@ import NextImage from '../../../image/components/NextImage.liquid.js';
|
|
|
10
10
|
import { getImageSrc, DEVICES } from '../../../image/helpers/getSrcSet.js';
|
|
11
11
|
import { createBlurDataURL } from '../../../image/components/helpers.js';
|
|
12
12
|
|
|
13
|
-
const HeroBanner = ({ builderAttrs, builderProps, setting, styles, style, children, rawChildren, advanced,
|
|
13
|
+
const HeroBanner = ({ builderAttrs, builderProps, setting, styles, style, children, rawChildren, advanced, enableLazyloadImage = true })=>{
|
|
14
14
|
const { link, layout, verticalAlign, order, alignBanner, alt, title } = setting ?? {};
|
|
15
15
|
const { background, overlayEnable, overlayColor, overlayOpacity, verticalGutter, contentWidth, hoverEffect, hoverEffectDuration, hoverEffectScale, cornerBg, borderBg, hasActiveShadow, shadowBg, sizeSetting, contentPadding } = styles ?? {};
|
|
16
16
|
const enableParallax = setting?.enableParallax || false;
|
|
@@ -39,6 +39,9 @@ const HeroBanner = ({ builderAttrs, builderProps, setting, styles, style, childr
|
|
|
39
39
|
} else if (data.videoType === 'html5') {
|
|
40
40
|
delete data.video;
|
|
41
41
|
}
|
|
42
|
+
if (data.type !== 'image') {
|
|
43
|
+
delete data.image;
|
|
44
|
+
}
|
|
42
45
|
}
|
|
43
46
|
return background;
|
|
44
47
|
};
|
|
@@ -127,7 +130,7 @@ const HeroBanner = ({ builderAttrs, builderProps, setting, styles, style, childr
|
|
|
127
130
|
tablet: createBlurDataURL(srcSet?.tablet?.width ?? srcSet?.desktop?.width ?? 0, srcSet?.tablet?.height ?? srcSet?.desktop?.width ?? 0),
|
|
128
131
|
mobile: createBlurDataURL(srcSet?.mobile?.width ?? srcSet?.tablet?.width ?? srcSet?.desktop?.width ?? 0, srcSet?.mobile?.height ?? srcSet?.tablet?.height ?? srcSet?.desktop?.width ?? 0)
|
|
129
132
|
};
|
|
130
|
-
const enableLazyLoad = !setting?.preload &&
|
|
133
|
+
const enableLazyLoad = !setting?.preload && enableLazyloadImage;
|
|
131
134
|
const renderInnerHeroBanner = ()=>{
|
|
132
135
|
return template /* liquid */ `
|
|
133
136
|
<div
|
|
@@ -177,7 +180,7 @@ const HeroBanner = ({ builderAttrs, builderProps, setting, styles, style, childr
|
|
|
177
180
|
alt,
|
|
178
181
|
title,
|
|
179
182
|
imagePlaceholder,
|
|
180
|
-
|
|
183
|
+
enableLazyloadImage
|
|
181
184
|
})}
|
|
182
185
|
<div class="${cls('gp-absolute gp-w-full gp-h-full')}">
|
|
183
186
|
<div
|
|
@@ -220,7 +223,7 @@ const HeroBanner = ({ builderAttrs, builderProps, setting, styles, style, childr
|
|
|
220
223
|
alt: `lazy image ${device}`,
|
|
221
224
|
className: `gp-absolute gp-top-0 gp-invisible gp-w-full gp_lazyload gp-h-full gp_lazyforbg ${device === 'tablet' ? 'gp_lazybg_tl' : ''} ${device === 'mobile' ? 'gp_lazybg_mb' : ''}`,
|
|
222
225
|
isDisableAspectStyle: true,
|
|
223
|
-
|
|
226
|
+
enableLazyloadImage
|
|
224
227
|
}));
|
|
225
228
|
}).join('') : ''}
|
|
226
229
|
</div></div>
|
package/dist/esm/builder.js
CHANGED
|
@@ -120,8 +120,8 @@ import BfSizeChartSizeGuide from './third-party/components/BfSizeChartSizeGuide.
|
|
|
120
120
|
import AlsoBoughtCbb from './third-party/components/AlsoBoughtCbb.js';
|
|
121
121
|
import HextomFreeShippingBar from './third-party/components/HextomFreeShippingBar.js';
|
|
122
122
|
import EcoboostifyShoppableReelUgc from './third-party/components/EcoboostifyShoppableReelUgc.js';
|
|
123
|
-
import EcomsendBackInStockAlert from './third-party/components/EcomsendBackInStockAlert.js';
|
|
124
123
|
import AppstleBundlesDiscounts from './third-party/components/AppstleBundlesDiscounts.js';
|
|
124
|
+
import EcomsendBackInStockAlert from './third-party/components/EcomsendBackInStockAlert.js';
|
|
125
125
|
import CartLineVariant from './cart/components/CartLineVariant.js';
|
|
126
126
|
import Cart from './cart/components/Cart.js';
|
|
127
127
|
import CartList from './cart/components/CartList.js';
|