@gem-sdk/components 2.1.13-staging.1 → 2.1.13-staging.11
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/ArticleList.liquid.js +6 -2
- package/dist/cjs/banner/components/hero-banner/index.liquid.js +12 -10
- package/dist/cjs/builder.js +21 -1
- package/dist/cjs/collection/components/CollectionDescription.js +101 -7
- package/dist/cjs/collection/components/CollectionDescription.liquid.js +102 -9
- package/dist/cjs/collection/setting/CollectionDescription.js +128 -0
- package/dist/cjs/common/const.js +1 -1
- package/dist/cjs/image/components/AdaptiveImage.liquid.js +6 -5
- package/dist/cjs/image/components/Image.js +22 -3
- package/dist/cjs/image/components/Image.liquid.js +6 -5
- package/dist/cjs/image/components/NextImage.liquid.js +4 -3
- package/dist/cjs/image/components/NoDataImage.js +133 -0
- package/dist/cjs/image-comparison/components/CompareImage.liquid.js +7 -3
- package/dist/cjs/index.js +20 -0
- package/dist/cjs/index.liquid.js +22 -2
- package/dist/cjs/product/components/ProductImagesV2/liquid/ProductFeaturedImageCarousel.liquid.js +4 -4
- 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/tab/hooks/useTabInteraction.js +13 -9
- package/dist/cjs/text/components/Text.js +0 -1
- package/dist/cjs/third-party/components/AlsoBoughtCbb.js +32 -0
- package/dist/cjs/third-party/components/AlsoBoughtCbb.liquid.js +21 -0
- package/dist/cjs/third-party/components/BfSizeChartSizeGuide.js +32 -0
- package/dist/cjs/third-party/components/BfSizeChartSizeGuide.liquid.js +12 -0
- package/dist/cjs/third-party/components/EssentialAnnouncementBar.js +32 -0
- package/dist/cjs/third-party/components/EssentialAnnouncementBar.liquid.js +12 -0
- package/dist/cjs/third-party/components/EssentialCountdownTimerBar.js +32 -0
- package/dist/cjs/third-party/components/EssentialCountdownTimerBar.liquid.js +12 -0
- package/dist/cjs/third-party/components/EstimatedDeliveryDatePlus.js +32 -0
- package/dist/cjs/third-party/components/EstimatedDeliveryDatePlus.liquid.js +12 -0
- package/dist/cjs/third-party/components/GloColorSwatchvariantImage.js +32 -0
- package/dist/cjs/third-party/components/GloColorSwatchvariantImage.liquid.js +12 -0
- package/dist/cjs/third-party/components/HextomFreeShippingBar.js +32 -0
- package/dist/cjs/third-party/components/HextomFreeShippingBar.liquid.js +12 -0
- package/dist/cjs/third-party/components/OkendoReviewsLoyalty.js +32 -0
- package/dist/cjs/third-party/components/OkendoReviewsLoyalty.liquid.js +12 -0
- package/dist/cjs/third-party/components/StellarDeliveryDatePickup.js +32 -0
- package/dist/cjs/third-party/components/StellarDeliveryDatePickup.liquid.js +21 -0
- package/dist/cjs/third-party/components/TrustedsiteTrustBadges.js +32 -0
- package/dist/cjs/third-party/components/TrustedsiteTrustBadges.liquid.js +12 -0
- package/dist/cjs/third-party/configs/AlsoBoughtCbb.js +12 -0
- package/dist/cjs/third-party/configs/BfSizeChartSizeGuide.js +12 -0
- package/dist/cjs/third-party/configs/EssentialAnnouncementBar.js +12 -0
- package/dist/cjs/third-party/configs/EssentialCountdownTimerBar.js +12 -0
- package/dist/cjs/third-party/configs/EstimatedDeliveryDatePlus.js +12 -0
- package/dist/cjs/third-party/configs/GloColorSwatchvariantImage.js +12 -0
- package/dist/cjs/third-party/configs/HextomFreeShippingBar.js +12 -0
- package/dist/cjs/third-party/configs/OkendoReviewsLoyalty.js +12 -0
- package/dist/cjs/third-party/configs/StellarDeliveryDatePickup.js +12 -0
- package/dist/cjs/third-party/configs/TrustedsiteTrustBadges.js +12 -0
- package/dist/cjs/third-party/helpers/thirdParty.js +1 -1
- package/dist/cjs/third-party/next.js +51 -1
- package/dist/cjs/third-party/setting/AlsoBoughtCbb.js +127 -0
- package/dist/cjs/third-party/setting/BfSizeChartSizeGuide.js +131 -0
- package/dist/cjs/third-party/setting/EssentialAnnouncementBar.js +142 -0
- package/dist/cjs/third-party/setting/EssentialCountdownTimerBar.js +142 -0
- package/dist/cjs/third-party/setting/EstimatedDeliveryDatePlus.js +128 -0
- package/dist/cjs/third-party/setting/GloColorSwatchvariantImage.js +152 -0
- package/dist/cjs/third-party/setting/HextomFreeShippingBar.js +128 -0
- package/dist/cjs/third-party/setting/OkendoReviewsLoyalty.js +171 -0
- package/dist/cjs/third-party/setting/StellarDeliveryDatePickup.js +127 -0
- package/dist/cjs/third-party/setting/TrustedsiteTrustBadges.js +177 -0
- package/dist/cjs/third-party/setting/index.js +21 -1
- package/dist/cjs/video/components/HTML5Embed.js +2 -2
- package/dist/cjs/video/components/HTML5Embed.liquid.js +6 -3
- package/dist/cjs/video/components/LiteYouTubeEmbed.liquid.js +4 -2
- package/dist/esm/article/components/ArticleList.liquid.js +6 -2
- package/dist/esm/banner/components/hero-banner/index.liquid.js +12 -10
- package/dist/esm/builder.js +21 -1
- package/dist/esm/collection/components/CollectionDescription.js +103 -9
- package/dist/esm/collection/components/CollectionDescription.liquid.js +103 -10
- package/dist/esm/collection/setting/CollectionDescription.js +128 -0
- package/dist/esm/common/const.js +1 -1
- package/dist/esm/image/components/AdaptiveImage.liquid.js +6 -5
- package/dist/esm/image/components/Image.js +23 -4
- package/dist/esm/image/components/Image.liquid.js +6 -5
- package/dist/esm/image/components/NextImage.liquid.js +4 -3
- package/dist/esm/image/components/NoDataImage.js +129 -0
- package/dist/esm/image-comparison/components/CompareImage.liquid.js +7 -3
- package/dist/esm/index.js +10 -0
- package/dist/esm/index.liquid.js +11 -1
- package/dist/esm/product/components/ProductImagesV2/liquid/ProductFeaturedImageCarousel.liquid.js +4 -4
- 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/tab/hooks/useTabInteraction.js +14 -10
- package/dist/esm/text/components/Text.js +0 -1
- package/dist/esm/third-party/components/AlsoBoughtCbb.js +28 -0
- package/dist/esm/third-party/components/AlsoBoughtCbb.liquid.js +17 -0
- package/dist/esm/third-party/components/BfSizeChartSizeGuide.js +28 -0
- package/dist/esm/third-party/components/BfSizeChartSizeGuide.liquid.js +8 -0
- package/dist/esm/third-party/components/EssentialAnnouncementBar.js +28 -0
- package/dist/esm/third-party/components/EssentialAnnouncementBar.liquid.js +8 -0
- package/dist/esm/third-party/components/EssentialCountdownTimerBar.js +28 -0
- package/dist/esm/third-party/components/EssentialCountdownTimerBar.liquid.js +8 -0
- package/dist/esm/third-party/components/EstimatedDeliveryDatePlus.js +28 -0
- package/dist/esm/third-party/components/EstimatedDeliveryDatePlus.liquid.js +8 -0
- package/dist/esm/third-party/components/GloColorSwatchvariantImage.js +28 -0
- package/dist/esm/third-party/components/GloColorSwatchvariantImage.liquid.js +8 -0
- package/dist/esm/third-party/components/HextomFreeShippingBar.js +28 -0
- package/dist/esm/third-party/components/HextomFreeShippingBar.liquid.js +8 -0
- package/dist/esm/third-party/components/OkendoReviewsLoyalty.js +28 -0
- package/dist/esm/third-party/components/OkendoReviewsLoyalty.liquid.js +8 -0
- package/dist/esm/third-party/components/StellarDeliveryDatePickup.js +28 -0
- package/dist/esm/third-party/components/StellarDeliveryDatePickup.liquid.js +17 -0
- package/dist/esm/third-party/components/TrustedsiteTrustBadges.js +28 -0
- package/dist/esm/third-party/components/TrustedsiteTrustBadges.liquid.js +8 -0
- package/dist/esm/third-party/configs/AlsoBoughtCbb.js +8 -0
- package/dist/esm/third-party/configs/BfSizeChartSizeGuide.js +8 -0
- package/dist/esm/third-party/configs/EssentialAnnouncementBar.js +8 -0
- package/dist/esm/third-party/configs/EssentialCountdownTimerBar.js +8 -0
- package/dist/esm/third-party/configs/EstimatedDeliveryDatePlus.js +8 -0
- package/dist/esm/third-party/configs/GloColorSwatchvariantImage.js +8 -0
- package/dist/esm/third-party/configs/HextomFreeShippingBar.js +8 -0
- package/dist/esm/third-party/configs/OkendoReviewsLoyalty.js +8 -0
- package/dist/esm/third-party/configs/StellarDeliveryDatePickup.js +8 -0
- package/dist/esm/third-party/configs/TrustedsiteTrustBadges.js +8 -0
- package/dist/esm/third-party/helpers/thirdParty.js +1 -1
- package/dist/esm/third-party/next.js +51 -1
- package/dist/esm/third-party/setting/AlsoBoughtCbb.js +123 -0
- package/dist/esm/third-party/setting/BfSizeChartSizeGuide.js +127 -0
- package/dist/esm/third-party/setting/EssentialAnnouncementBar.js +138 -0
- package/dist/esm/third-party/setting/EssentialCountdownTimerBar.js +138 -0
- package/dist/esm/third-party/setting/EstimatedDeliveryDatePlus.js +124 -0
- package/dist/esm/third-party/setting/GloColorSwatchvariantImage.js +148 -0
- package/dist/esm/third-party/setting/HextomFreeShippingBar.js +124 -0
- package/dist/esm/third-party/setting/OkendoReviewsLoyalty.js +167 -0
- package/dist/esm/third-party/setting/StellarDeliveryDatePickup.js +123 -0
- package/dist/esm/third-party/setting/TrustedsiteTrustBadges.js +173 -0
- package/dist/esm/third-party/setting/index.js +224 -204
- package/dist/esm/video/components/HTML5Embed.js +2 -2
- package/dist/esm/video/components/HTML5Embed.liquid.js +6 -3
- package/dist/esm/video/components/LiteYouTubeEmbed.liquid.js +4 -2
- package/dist/types/index.d.ts +182 -8
- package/package.json +2 -2
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var TrustedsiteTrustBadges = require('../configs/TrustedsiteTrustBadges.js');
|
|
6
|
+
|
|
7
|
+
const config = {
|
|
8
|
+
tag: TrustedsiteTrustBadges.default.tag,
|
|
9
|
+
label: TrustedsiteTrustBadges.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/38fdc008d044b95511d73b59ae0cc83f/icon/CIX8yLf0lu8CEAE=.png">',
|
|
11
|
+
editorConfigs: {
|
|
12
|
+
component: {
|
|
13
|
+
isThirdParty: true
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
presets: [
|
|
17
|
+
{
|
|
18
|
+
id: TrustedsiteTrustBadges.default.id,
|
|
19
|
+
name: {
|
|
20
|
+
en: TrustedsiteTrustBadges.default.label
|
|
21
|
+
},
|
|
22
|
+
hideTextContent: true,
|
|
23
|
+
icon: {
|
|
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/38fdc008d044b95511d73b59ae0cc83f/icon/CIX8yLf0lu8CEAE=.png">
|
|
26
|
+
<span class="preset-item-title">TrustedSite ‑ Trust Badges</span>
|
|
27
|
+
</div>`
|
|
28
|
+
},
|
|
29
|
+
components: [
|
|
30
|
+
{
|
|
31
|
+
tag: TrustedsiteTrustBadges.default.tag
|
|
32
|
+
}
|
|
33
|
+
]
|
|
34
|
+
}
|
|
35
|
+
],
|
|
36
|
+
settings: [
|
|
37
|
+
{
|
|
38
|
+
id: 'setting',
|
|
39
|
+
controls: [
|
|
40
|
+
{
|
|
41
|
+
id: 'appBlockId',
|
|
42
|
+
type: 'input',
|
|
43
|
+
default: ''
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
id: 'widgetType',
|
|
47
|
+
label: 'Choose widget',
|
|
48
|
+
type: 'select',
|
|
49
|
+
options: [
|
|
50
|
+
{
|
|
51
|
+
label: 'Engagement',
|
|
52
|
+
value: 'engagement'
|
|
53
|
+
}
|
|
54
|
+
],
|
|
55
|
+
default: 'engagement'
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
id: 'trustId',
|
|
59
|
+
label: 'Trustmark Type',
|
|
60
|
+
type: 'select',
|
|
61
|
+
options: [
|
|
62
|
+
{
|
|
63
|
+
label: 'Certified Secure',
|
|
64
|
+
value: '202'
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
label: 'Secure Form',
|
|
68
|
+
value: '211'
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
label: 'Secure Checkout',
|
|
72
|
+
value: '212'
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
label: 'Secure Login',
|
|
76
|
+
value: '213'
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
label: 'Issue-Free Orders',
|
|
80
|
+
value: '214'
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
label: 'Spam-Free',
|
|
84
|
+
value: '216'
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
label: 'Banner',
|
|
88
|
+
value: '1001'
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
label: 'Testimonial',
|
|
92
|
+
value: '1002'
|
|
93
|
+
}
|
|
94
|
+
],
|
|
95
|
+
default: '202'
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
id: 'install',
|
|
99
|
+
type: 'open-link',
|
|
100
|
+
target: '_blank',
|
|
101
|
+
linkType: 'install',
|
|
102
|
+
href: 'https://apps.shopify.com/mcafee-secure?utm_source=gempages',
|
|
103
|
+
appName: TrustedsiteTrustBadges.default.label
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
id: 'openApp',
|
|
107
|
+
type: 'open-link',
|
|
108
|
+
target: '_blank',
|
|
109
|
+
linkType: 'openApp',
|
|
110
|
+
href: 'https://www.trustedsite.com/',
|
|
111
|
+
appName: TrustedsiteTrustBadges.default.label
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
id: 'align',
|
|
115
|
+
label: 'Alignment',
|
|
116
|
+
type: 'segment',
|
|
117
|
+
options: [
|
|
118
|
+
{
|
|
119
|
+
label: 'Left',
|
|
120
|
+
value: 'left',
|
|
121
|
+
type: 'align'
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
label: 'Center',
|
|
125
|
+
value: 'center',
|
|
126
|
+
type: 'align'
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
label: 'Right',
|
|
130
|
+
value: 'right',
|
|
131
|
+
type: 'align'
|
|
132
|
+
}
|
|
133
|
+
],
|
|
134
|
+
devices: {
|
|
135
|
+
desktop: {
|
|
136
|
+
default: 'left'
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
]
|
|
141
|
+
}
|
|
142
|
+
],
|
|
143
|
+
ui: [
|
|
144
|
+
{
|
|
145
|
+
type: 'control',
|
|
146
|
+
setting: {
|
|
147
|
+
id: 'install'
|
|
148
|
+
}
|
|
149
|
+
},
|
|
150
|
+
{
|
|
151
|
+
type: 'control',
|
|
152
|
+
setting: {
|
|
153
|
+
id: 'trustId'
|
|
154
|
+
},
|
|
155
|
+
label: {
|
|
156
|
+
en: 'Trustmark Type'
|
|
157
|
+
}
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
type: 'control',
|
|
161
|
+
setting: {
|
|
162
|
+
id: 'openApp'
|
|
163
|
+
}
|
|
164
|
+
},
|
|
165
|
+
{
|
|
166
|
+
type: 'control',
|
|
167
|
+
label: {
|
|
168
|
+
en: 'Align'
|
|
169
|
+
},
|
|
170
|
+
setting: {
|
|
171
|
+
id: 'align'
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
]
|
|
175
|
+
};
|
|
176
|
+
|
|
177
|
+
exports.default = config;
|
|
@@ -103,11 +103,26 @@ var TrustreviewsProductReviews = require('./TrustreviewsProductReviews.js');
|
|
|
103
103
|
var MyappgurusProductReviews = require('./MyappgurusProductReviews.js');
|
|
104
104
|
var HulkProductOptions = require('./HulkProductOptions.js');
|
|
105
105
|
var TrustshopProductReviews = require('./TrustshopProductReviews.js');
|
|
106
|
+
var StellarDeliveryDatePickup = require('./StellarDeliveryDatePickup.js');
|
|
107
|
+
var EssentialCountdownTimerBar = require('./EssentialCountdownTimerBar.js');
|
|
108
|
+
var EssentialAnnouncementBar = require('./EssentialAnnouncementBar.js');
|
|
109
|
+
var OkendoReviewsLoyalty = require('./OkendoReviewsLoyalty.js');
|
|
110
|
+
var EstimatedDeliveryDatePlus = require('./EstimatedDeliveryDatePlus.js');
|
|
106
111
|
var HextomCountdownTimerBar = require('./HextomCountdownTimerBar.js');
|
|
107
112
|
var TrustBadgesBear = require('./TrustBadgesBear.js');
|
|
113
|
+
var TrustedsiteTrustBadges = require('./TrustedsiteTrustBadges.js');
|
|
114
|
+
var GloColorSwatchvariantImage = require('./GloColorSwatchvariantImage.js');
|
|
115
|
+
var BfSizeChartSizeGuide = require('./BfSizeChartSizeGuide.js');
|
|
116
|
+
var AlsoBoughtCbb = require('./AlsoBoughtCbb.js');
|
|
117
|
+
var HextomFreeShippingBar = require('./HextomFreeShippingBar.js');
|
|
108
118
|
|
|
109
119
|
var index = {
|
|
110
120
|
HextomCountdownTimerBar: HextomCountdownTimerBar.default,
|
|
121
|
+
EstimatedDeliveryDatePlus: EstimatedDeliveryDatePlus.default,
|
|
122
|
+
OkendoReviewsLoyalty: OkendoReviewsLoyalty.default,
|
|
123
|
+
EssentialAnnouncementBar: EssentialAnnouncementBar.default,
|
|
124
|
+
EssentialCountdownTimerBar: EssentialCountdownTimerBar.default,
|
|
125
|
+
StellarDeliveryDatePickup: StellarDeliveryDatePickup.default,
|
|
111
126
|
TrustshopProductReviews: TrustshopProductReviews.default,
|
|
112
127
|
HulkProductOptions: HulkProductOptions.default,
|
|
113
128
|
TrustreviewsProductReviews: TrustreviewsProductReviews.default,
|
|
@@ -209,7 +224,12 @@ var index = {
|
|
|
209
224
|
RequestQuoteHidePrice: RequestQuoteHidePrice.default,
|
|
210
225
|
BirdChime: BirdChime.default,
|
|
211
226
|
FordeerProductLabels: FordeerProductLabels.default,
|
|
212
|
-
TrustBadgesBear: TrustBadgesBear.default
|
|
227
|
+
TrustBadgesBear: TrustBadgesBear.default,
|
|
228
|
+
TrustedsiteTrustBadges: TrustedsiteTrustBadges.default,
|
|
229
|
+
GloColorSwatchvariantImage: GloColorSwatchvariantImage.default,
|
|
230
|
+
BfSizeChartSizeGuide: BfSizeChartSizeGuide.default,
|
|
231
|
+
AlsoBoughtCbb: AlsoBoughtCbb.default,
|
|
232
|
+
HextomFreeShippingBar: HextomFreeShippingBar.default
|
|
213
233
|
};
|
|
214
234
|
|
|
215
235
|
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 gp-h-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-contain gp-thumbnail-video",
|
|
62
62
|
alt: "Video Thumbnail"
|
|
63
63
|
}),
|
|
64
64
|
/*#__PURE__*/ jsxRuntime.jsx("button", {
|
|
@@ -7,6 +7,7 @@ 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;
|
|
10
11
|
const videoId = `gp-video-${props.uid}`;
|
|
11
12
|
const preloadThumbnail = props.autoplay && props.thumbnail;
|
|
12
13
|
const offLazyVideo = !props.lazy && props.isVideoComponent;
|
|
@@ -23,7 +24,9 @@ const HTML5Embed = (props)=>{
|
|
|
23
24
|
'--op': 0,
|
|
24
25
|
'--z': -1,
|
|
25
26
|
display: 'none'
|
|
26
|
-
}
|
|
27
|
+
},
|
|
28
|
+
enableLazyLoadImage,
|
|
29
|
+
pageContext
|
|
27
30
|
})}
|
|
28
31
|
${core.RenderIf(props.autoplay, `<script>
|
|
29
32
|
document.addEventListener("DOMContentLoaded", (event) => {
|
|
@@ -72,14 +75,14 @@ const HTML5Embed = (props)=>{
|
|
|
72
75
|
</video>
|
|
73
76
|
<div
|
|
74
77
|
style="${props.style}"
|
|
75
|
-
class="${core.cls('gp-absolute gp-top-0 gp-left-0 gp-w-full gp-thumbnail-video', {
|
|
78
|
+
class="${core.cls('gp-absolute gp-top-0 gp-left-0 gp-w-full gp-h-full gp-thumbnail-video', {
|
|
76
79
|
'gp-hidden': !props.thumbnail || props.autoplay
|
|
77
80
|
})}"
|
|
78
81
|
>
|
|
79
82
|
<img
|
|
80
83
|
id="video-thumbnail"
|
|
81
84
|
src="${props.thumbnail ?? ''}"
|
|
82
|
-
class="gp-w-full gp-h-full gp-object-
|
|
85
|
+
class="gp-w-full gp-h-full gp-object-contain"
|
|
83
86
|
alt="Video Thumbnail"
|
|
84
87
|
></img>
|
|
85
88
|
<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 } = props;
|
|
10
|
+
const { style, lazy, preload, enableLazyLoadImage, pageContext } = props;
|
|
11
11
|
const videoUid = `gp-video-${props.uid}`;
|
|
12
12
|
const videoId = encodeURIComponent(props.id);
|
|
13
13
|
const videoTitle = props.title;
|
|
@@ -52,7 +52,9 @@ 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
|
|
55
|
+
isDisableAspectStyle: true,
|
|
56
|
+
enableLazyLoadImage,
|
|
57
|
+
pageContext
|
|
56
58
|
})}
|
|
57
59
|
<button
|
|
58
60
|
type="button"
|
|
@@ -52,8 +52,12 @@ const ArticleList = ({ setting, styles, className, children, advanced, builderPr
|
|
|
52
52
|
assign all_articles = all_articles | concat: articleByHandle
|
|
53
53
|
endfor
|
|
54
54
|
else
|
|
55
|
-
assign
|
|
56
|
-
|
|
55
|
+
assign current_blog_handle = blogs['${blogHandle}']
|
|
56
|
+
if gp_enable_custom_dynamic_blog == true
|
|
57
|
+
assign current_blog_handle = blogs[blog.handle]
|
|
58
|
+
endif
|
|
59
|
+
assign all_articles = current_blog_handle.articles | limit: limit | sort: "${articleOrderBy.replace('_REVERSE', '').toLowerCase()}" ${articleOrderBy.includes('_REVERSE') ? '| reverse' : ''}
|
|
60
|
+
assign blogTitle = current_blog_handle.title
|
|
57
61
|
endif
|
|
58
62
|
|
|
59
63
|
%}
|
|
@@ -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;
|
|
@@ -130,6 +130,7 @@ const HeroBanner = ({ builderAttrs, builderProps, setting, styles, style, childr
|
|
|
130
130
|
tablet: createBlurDataURL(srcSet?.tablet?.width ?? srcSet?.desktop?.width ?? 0, srcSet?.tablet?.height ?? srcSet?.desktop?.width ?? 0),
|
|
131
131
|
mobile: createBlurDataURL(srcSet?.mobile?.width ?? srcSet?.tablet?.width ?? srcSet?.desktop?.width ?? 0, srcSet?.mobile?.height ?? srcSet?.tablet?.height ?? srcSet?.desktop?.width ?? 0)
|
|
132
132
|
};
|
|
133
|
+
const enableLazyLoad = !setting?.preload && enableLazyLoadImage;
|
|
133
134
|
const renderInnerHeroBanner = ()=>{
|
|
134
135
|
return template /* liquid */ `
|
|
135
136
|
<div
|
|
@@ -179,7 +180,7 @@ const HeroBanner = ({ builderAttrs, builderProps, setting, styles, style, childr
|
|
|
179
180
|
alt,
|
|
180
181
|
title,
|
|
181
182
|
imagePlaceholder,
|
|
182
|
-
|
|
183
|
+
enableLazyLoadImage
|
|
183
184
|
})}
|
|
184
185
|
<div class="${cls('gp-absolute gp-w-full gp-h-full')}">
|
|
185
186
|
<div
|
|
@@ -193,9 +194,10 @@ const HeroBanner = ({ builderAttrs, builderProps, setting, styles, style, childr
|
|
|
193
194
|
'clip-path': getClipPath(borderBg?.width, cornerBg)
|
|
194
195
|
}}"
|
|
195
196
|
>
|
|
196
|
-
<div class="${cls('hero-banner-bg-parallax gp-hero-banner-image-background
|
|
197
|
+
<div class="${cls('hero-banner-bg-parallax gp-hero-banner-image-background', {
|
|
197
198
|
'gp-duration-[var(--duration)] group-hover/hero:gp-scale-[var(--scale)]': hoverEffect,
|
|
198
|
-
'gp-transition-transform': hoverEffect
|
|
199
|
+
'gp-transition-transform': hoverEffect,
|
|
200
|
+
gp_lazybg: enableLazyLoad
|
|
199
201
|
})}"
|
|
200
202
|
style="${{
|
|
201
203
|
...getStyleBackgroundByDevice(background, {
|
|
@@ -204,15 +206,16 @@ const HeroBanner = ({ builderAttrs, builderProps, setting, styles, style, childr
|
|
|
204
206
|
liquid: true
|
|
205
207
|
}),
|
|
206
208
|
...makeStyleResponsive('bgi', {
|
|
207
|
-
desktop: `url('${bgiEnableByDevice['desktop'] ?
|
|
208
|
-
tablet: `url('${bgiEnableByDevice['tablet'] ?
|
|
209
|
-
mobile: `url('${bgiEnableByDevice['mobile'] ?
|
|
209
|
+
desktop: `url('${bgiEnableByDevice['desktop'] ? !enableLazyLoad ? getImageSrc(getResponsiveValueByScreen(srcSet, 'desktop'), 'desktop') : imagePlaceholder['desktop'] : ''}')`,
|
|
210
|
+
tablet: `url('${bgiEnableByDevice['tablet'] ? !enableLazyLoad ? getImageSrc(getResponsiveValueByScreen(srcSet, 'tablet'), 'tablet') : imagePlaceholder['tablet'] : ''}')`,
|
|
211
|
+
mobile: `url('${bgiEnableByDevice['mobile'] ? !enableLazyLoad ? getImageSrc(getResponsiveValueByScreen(srcSet, 'mobile'), 'mobile') : imagePlaceholder['mobile'] : ''}')`
|
|
210
212
|
}),
|
|
211
213
|
'--duration': `${hoverEffectDuration ?? 0}s`,
|
|
212
214
|
'--scale': hoverEffectScale ?? 1,
|
|
213
215
|
...makeStyleResponsive('pos', getAttachmentDevice()),
|
|
214
216
|
...getStyleHeroBannerBg(backgroundResponsive || {}, enableParallax)
|
|
215
217
|
}}"
|
|
218
|
+
${embed()}
|
|
216
219
|
>
|
|
217
220
|
${!setting?.preload ? DEVICES.map((device)=>{
|
|
218
221
|
return RenderIf(getEnableBgImageByDevice(device), NextImage({
|
|
@@ -220,11 +223,10 @@ 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
|
-
</div>
|
|
227
|
-
${embed()} </div>
|
|
229
|
+
</div></div>
|
|
228
230
|
</div>
|
|
229
231
|
${RenderIf(overlayEnable, template`<div
|
|
230
232
|
aria-label="Overlay"
|
package/dist/esm/builder.js
CHANGED
|
@@ -107,8 +107,18 @@ import TrustreviewsProductReviews from './third-party/components/TrustreviewsPro
|
|
|
107
107
|
import MyappgurusProductReviews from './third-party/components/MyappgurusProductReviews.js';
|
|
108
108
|
import HulkProductOptions from './third-party/components/HulkProductOptions.js';
|
|
109
109
|
import TrustshopProductReviews from './third-party/components/TrustshopProductReviews.js';
|
|
110
|
+
import StellarDeliveryDatePickup from './third-party/components/StellarDeliveryDatePickup.js';
|
|
111
|
+
import EssentialCountdownTimerBar from './third-party/components/EssentialCountdownTimerBar.js';
|
|
112
|
+
import EssentialAnnouncementBar from './third-party/components/EssentialAnnouncementBar.js';
|
|
113
|
+
import OkendoReviewsLoyalty from './third-party/components/OkendoReviewsLoyalty.js';
|
|
114
|
+
import EstimatedDeliveryDatePlus from './third-party/components/EstimatedDeliveryDatePlus.js';
|
|
110
115
|
import HextomCountdownTimerBar from './third-party/components/HextomCountdownTimerBar.js';
|
|
111
116
|
import TrustBadgesBear from './third-party/components/TrustBadgesBear.js';
|
|
117
|
+
import TrustedsiteTrustBadges from './third-party/components/TrustedsiteTrustBadges.js';
|
|
118
|
+
import GloColorSwatchvariantImage from './third-party/components/GloColorSwatchvariantImage.js';
|
|
119
|
+
import BfSizeChartSizeGuide from './third-party/components/BfSizeChartSizeGuide.js';
|
|
120
|
+
import AlsoBoughtCbb from './third-party/components/AlsoBoughtCbb.js';
|
|
121
|
+
import HextomFreeShippingBar from './third-party/components/HextomFreeShippingBar.js';
|
|
112
122
|
import CartLineVariant from './cart/components/CartLineVariant.js';
|
|
113
123
|
import Cart from './cart/components/Cart.js';
|
|
114
124
|
import CartList from './cart/components/CartList.js';
|
|
@@ -243,6 +253,11 @@ import PostPurchaseCountdownTimer from './post-purchase/countdown-timer/componen
|
|
|
243
253
|
import Text$1 from './post-purchase/text/Text.js';
|
|
244
254
|
|
|
245
255
|
var builder = {
|
|
256
|
+
EstimatedDeliveryDatePlus,
|
|
257
|
+
OkendoReviewsLoyalty,
|
|
258
|
+
EssentialAnnouncementBar,
|
|
259
|
+
EssentialCountdownTimerBar,
|
|
260
|
+
StellarDeliveryDatePickup,
|
|
246
261
|
TrustshopProductReviews,
|
|
247
262
|
HulkProductOptions,
|
|
248
263
|
TrustreviewsProductReviews,
|
|
@@ -479,7 +494,12 @@ var builder = {
|
|
|
479
494
|
MarqueeItem,
|
|
480
495
|
ProductBadge,
|
|
481
496
|
HextomCountdownTimerBar,
|
|
482
|
-
TrustBadgesBear
|
|
497
|
+
TrustBadgesBear,
|
|
498
|
+
TrustedsiteTrustBadges,
|
|
499
|
+
GloColorSwatchvariantImage,
|
|
500
|
+
BfSizeChartSizeGuide,
|
|
501
|
+
AlsoBoughtCbb,
|
|
502
|
+
HextomFreeShippingBar
|
|
483
503
|
};
|
|
484
504
|
|
|
485
505
|
export { builder as default };
|
|
@@ -1,15 +1,109 @@
|
|
|
1
|
-
import { jsx } from 'react/jsx-runtime';
|
|
2
|
-
import { useCollection } from '@gem-sdk/core';
|
|
3
|
-
import
|
|
1
|
+
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { useCurrentDevice, useCollection, getResponsiveValueByScreen, composeTypographyClassName, composeTypographyStyle, isSafari, cls, getGlobalColorClass, getStyleShadow, makeStyleResponsive, makeStyle, getGlobalColorStyle } from '@gem-sdk/core';
|
|
3
|
+
import { useState, useRef, useEffect } from 'react';
|
|
4
4
|
|
|
5
|
-
const CollectionDescription = ({ setting })=>{
|
|
5
|
+
const CollectionDescription = ({ setting, builderProps })=>{
|
|
6
|
+
const [open, setOpen] = useState(false);
|
|
7
|
+
const [isShowViewMore, allowShowViewMore] = useState(false);
|
|
8
|
+
const ref = useRef(null);
|
|
9
|
+
const currentDevice = useCurrentDevice();
|
|
6
10
|
const collection = useCollection();
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
11
|
+
const hasLineClamp = getResponsiveValueByScreen(setting?.hasLineClamp, currentDevice);
|
|
12
|
+
const lineClamp = getResponsiveValueByScreen(setting?.lineClamp, currentDevice);
|
|
13
|
+
const appendTypoClass = composeTypographyClassName(setting?.typo, setting?.typography);
|
|
14
|
+
const appendTypoStyle = composeTypographyStyle(setting?.typo, setting?.typography);
|
|
15
|
+
useEffect(()=>{
|
|
16
|
+
const dom = ref.current;
|
|
17
|
+
setOpen(false);
|
|
18
|
+
if (dom && hasLineClamp && collection?.description) {
|
|
19
|
+
const value = lineClamp;
|
|
20
|
+
setTimeout(()=>{
|
|
21
|
+
const scrollHeight = dom?.scrollHeight ?? 0;
|
|
22
|
+
const clientHeight = dom?.clientHeight ?? 0;
|
|
23
|
+
const lineHeight = window.getComputedStyle(dom).getPropertyValue('line-height');
|
|
24
|
+
const lineText = Math.round((scrollHeight ?? 0) / parseInt(lineHeight));
|
|
25
|
+
const conditionCheckLine = isSafari() ? value && value < lineText : clientHeight < scrollHeight;
|
|
26
|
+
if (value && conditionCheckLine) {
|
|
27
|
+
allowShowViewMore(()=>true);
|
|
28
|
+
} else {
|
|
29
|
+
allowShowViewMore(()=>false);
|
|
30
|
+
}
|
|
31
|
+
}, 100);
|
|
12
32
|
}
|
|
33
|
+
}, [
|
|
34
|
+
hasLineClamp,
|
|
35
|
+
lineClamp,
|
|
36
|
+
collection?.description
|
|
37
|
+
]);
|
|
38
|
+
const css = `
|
|
39
|
+
.gp-p-description-text > *:not(ol):not(ul):not(table):not(div) {
|
|
40
|
+
display: inline !important;
|
|
41
|
+
}
|
|
42
|
+
.gp-p-description-text > *:not(ol):not(ul):not(table):not(div)::after {
|
|
43
|
+
content: "\\A";
|
|
44
|
+
white-space: pre;
|
|
45
|
+
}
|
|
46
|
+
.gp-p-description-text > table {
|
|
47
|
+
box-shadow: none;
|
|
48
|
+
}
|
|
49
|
+
`;
|
|
50
|
+
const hasDescription = collection?.description && collection.description?.trim() != '';
|
|
51
|
+
return /*#__PURE__*/ jsxs("div", {
|
|
52
|
+
"data-id": builderProps?.uid,
|
|
53
|
+
children: [
|
|
54
|
+
!isSafari() && /*#__PURE__*/ jsx("style", {
|
|
55
|
+
children: css
|
|
56
|
+
}),
|
|
57
|
+
/*#__PURE__*/ jsx("div", {
|
|
58
|
+
ref: ref,
|
|
59
|
+
"data-gp-text": true,
|
|
60
|
+
className: cls('gp-p-description-text gp-break-words safari:[&_p]:gp-inline safari:[&_p]:after:gp-whitespace-pre', appendTypoClass, !hasDescription ? 'gp-p-2 gp-text-center gp-text-sm gp-font-semibold gp-text-gray-500 gp-py-2 !gp-text-center' : '', getGlobalColorClass('text', setting?.color)),
|
|
61
|
+
style: {
|
|
62
|
+
...getStyleShadow({
|
|
63
|
+
styleAppliedFor: 'text-shadow'
|
|
64
|
+
}),
|
|
65
|
+
...makeStyleResponsive('ta', setting?.textAlign),
|
|
66
|
+
...hasLineClamp && !open ? makeStyleResponsive('line-clamp', setting?.lineClamp) : {},
|
|
67
|
+
...makeStyle({
|
|
68
|
+
tt: setting?.transform
|
|
69
|
+
}),
|
|
70
|
+
...appendTypoStyle
|
|
71
|
+
},
|
|
72
|
+
dangerouslySetInnerHTML: {
|
|
73
|
+
__html: collection?.descriptionHtml && hasDescription ? collection.descriptionHtml : ``
|
|
74
|
+
}
|
|
75
|
+
}),
|
|
76
|
+
hasLineClamp && isShowViewMore && /*#__PURE__*/ jsxs("button", {
|
|
77
|
+
className: cls(appendTypoClass, getGlobalColorClass('text', setting?.showMoreColor), 'gp-mt-4 gp-w-full gp-transition-all hover:gp-opacity-80'),
|
|
78
|
+
style: {
|
|
79
|
+
...makeStyleResponsive('ta', setting?.textAlign),
|
|
80
|
+
...makeStyle({
|
|
81
|
+
tt: setting?.transform
|
|
82
|
+
}),
|
|
83
|
+
...appendTypoStyle,
|
|
84
|
+
...getGlobalColorStyle(setting?.showMoreColor)
|
|
85
|
+
},
|
|
86
|
+
onClick: ()=>setOpen((prev)=>!prev),
|
|
87
|
+
children: [
|
|
88
|
+
!open ? setting?.viewMoreText : setting?.viewLessText,
|
|
89
|
+
setting?.enableViewMoreIcon && /*#__PURE__*/ jsx("svg", {
|
|
90
|
+
className: "gp-ml-1 gp-inline-block",
|
|
91
|
+
height: "1em",
|
|
92
|
+
width: "1em",
|
|
93
|
+
viewBox: "0 0 22 12",
|
|
94
|
+
fill: "none",
|
|
95
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
96
|
+
children: !open ? /*#__PURE__*/ jsx("path", {
|
|
97
|
+
d: "M1.70711 0.292893C1.31658 -0.0976311 0.683417 -0.0976311 0.292893 0.292893C-0.0976311 0.683417 -0.0976311 1.31658 0.292893 1.70711L1.70711 0.292893ZM11 11L10.2929 11.7071C10.6834 12.0976 11.3166 12.0976 11.7071 11.7071L11 11ZM21.7071 1.70711C22.0976 1.31658 22.0976 0.683417 21.7071 0.292893C21.3166 -0.0976311 20.6834 -0.0976311 20.2929 0.292893L21.7071 1.70711ZM0.292893 1.70711L10.2929 11.7071L11.7071 10.2929L1.70711 0.292893L0.292893 1.70711ZM11.7071 11.7071L21.7071 1.70711L20.2929 0.292893L10.2929 10.2929L11.7071 11.7071Z",
|
|
98
|
+
fill: "currentColor"
|
|
99
|
+
}) : /*#__PURE__*/ jsx("path", {
|
|
100
|
+
d: "M0.292893 10.2929C-0.0976311 10.6834 -0.0976311 11.3166 0.292893 11.7071C0.683417 12.0976 1.31658 12.0976 1.70711 11.7071L0.292893 10.2929ZM11 1L11.7071 0.292893C11.3166 -0.0976311 10.6834 -0.0976311 10.2929 0.292893L11 1ZM20.2929 11.7071C20.6834 12.0976 21.3166 12.0976 21.7071 11.7071C22.0976 11.3166 22.0976 10.6834 21.7071 10.2929L20.2929 11.7071ZM1.70711 11.7071L11.7071 1.70711L10.2929 0.292893L0.292893 10.2929L1.70711 11.7071ZM10.2929 1.70711L20.2929 11.7071L21.7071 10.2929L11.7071 0.292893L10.2929 1.70711Z",
|
|
101
|
+
fill: "currentColor"
|
|
102
|
+
})
|
|
103
|
+
})
|
|
104
|
+
]
|
|
105
|
+
})
|
|
106
|
+
]
|
|
13
107
|
});
|
|
14
108
|
};
|
|
15
109
|
|