@gem-sdk/components 2.1.12 → 2.1.13-staging.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/cjs/builder.js +5 -1
- package/dist/cjs/index.js +4 -0
- package/dist/cjs/index.liquid.js +4 -0
- package/dist/cjs/post-purchase/product/components/ProductDiscountTag.js +5 -2
- package/dist/cjs/post-purchase/product/components/ProductOffer.js +16 -3
- package/dist/cjs/post-purchase/product/components/ProductPrice.js +3 -1
- package/dist/cjs/post-purchase/product/components/ProductPriceBreakdown.js +9 -21
- package/dist/cjs/post-purchase/product/constants/ProductOfferPlaceholder.js +127 -0
- package/dist/cjs/post-purchase/product/hooks/useDynamicProduct.js +28 -0
- package/dist/cjs/post-purchase/product/settings/ProductOffer.js +26 -0
- package/dist/cjs/third-party/components/HextomCountdownTimerBar.js +32 -0
- package/dist/cjs/third-party/components/HextomCountdownTimerBar.liquid.js +12 -0
- package/dist/cjs/third-party/components/TrustBadgesBear.js +32 -0
- package/dist/cjs/third-party/components/TrustBadgesBear.liquid.js +12 -0
- package/dist/cjs/third-party/configs/HextomCountdownTimerBar.js +12 -0
- package/dist/cjs/third-party/configs/TrustBadgesBear.js +12 -0
- package/dist/cjs/third-party/next.js +11 -1
- package/dist/cjs/third-party/setting/HextomCountdownTimerBar.js +128 -0
- package/dist/cjs/third-party/setting/TrustBadgesBear.js +128 -0
- package/dist/cjs/third-party/setting/index.js +5 -1
- package/dist/esm/builder.js +5 -1
- package/dist/esm/index.js +2 -0
- package/dist/esm/index.liquid.js +2 -0
- package/dist/esm/post-purchase/product/components/ProductDiscountTag.js +5 -2
- package/dist/esm/post-purchase/product/components/ProductOffer.js +16 -3
- package/dist/esm/post-purchase/product/components/ProductPrice.js +3 -1
- package/dist/esm/post-purchase/product/components/ProductPriceBreakdown.js +9 -21
- package/dist/esm/post-purchase/product/constants/ProductOfferPlaceholder.js +125 -0
- package/dist/esm/post-purchase/product/hooks/useDynamicProduct.js +26 -0
- package/dist/esm/post-purchase/product/settings/ProductOffer.js +26 -0
- package/dist/esm/third-party/components/HextomCountdownTimerBar.js +28 -0
- package/dist/esm/third-party/components/HextomCountdownTimerBar.liquid.js +8 -0
- package/dist/esm/third-party/components/TrustBadgesBear.js +28 -0
- package/dist/esm/third-party/components/TrustBadgesBear.liquid.js +8 -0
- package/dist/esm/third-party/configs/HextomCountdownTimerBar.js +8 -0
- package/dist/esm/third-party/configs/TrustBadgesBear.js +8 -0
- package/dist/esm/third-party/next.js +11 -1
- package/dist/esm/third-party/setting/HextomCountdownTimerBar.js +124 -0
- package/dist/esm/third-party/setting/TrustBadgesBear.js +124 -0
- package/dist/esm/third-party/setting/index.js +206 -202
- package/dist/types/index.d.ts +34 -1
- package/package.json +2 -2
|
@@ -180,6 +180,14 @@ const config = {
|
|
|
180
180
|
}
|
|
181
181
|
}
|
|
182
182
|
},
|
|
183
|
+
{
|
|
184
|
+
id: 'dynamicOfferQuantity',
|
|
185
|
+
type: 'dynamic-offer-quantity',
|
|
186
|
+
min: 1,
|
|
187
|
+
max: 4,
|
|
188
|
+
default: 2,
|
|
189
|
+
isOnlyAcceptInteger: true
|
|
190
|
+
},
|
|
183
191
|
{
|
|
184
192
|
id: 'discountAndShippingFee',
|
|
185
193
|
type: 'discount-and-shipping-fee-product-offer',
|
|
@@ -373,6 +381,24 @@ const config = {
|
|
|
373
381
|
},
|
|
374
382
|
layout: 'vertical'
|
|
375
383
|
},
|
|
384
|
+
{
|
|
385
|
+
type: 'group',
|
|
386
|
+
label: {
|
|
387
|
+
en: 'Product offers'
|
|
388
|
+
},
|
|
389
|
+
controls: [
|
|
390
|
+
{
|
|
391
|
+
type: 'control',
|
|
392
|
+
label: {
|
|
393
|
+
en: 'Quantity'
|
|
394
|
+
},
|
|
395
|
+
setting: {
|
|
396
|
+
id: 'dynamicOfferQuantity'
|
|
397
|
+
}
|
|
398
|
+
}
|
|
399
|
+
],
|
|
400
|
+
condition: 'false'
|
|
401
|
+
},
|
|
376
402
|
{
|
|
377
403
|
type: 'control',
|
|
378
404
|
label: {
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { jsx, Fragment } from 'react/jsx-runtime';
|
|
2
|
+
import { makeStyleResponsive } from '@gem-sdk/core';
|
|
3
|
+
import ThirdPartyPreview from './ThirdPartyPreview.js';
|
|
4
|
+
import AppConfig from '../configs/HextomCountdownTimerBar.js';
|
|
5
|
+
|
|
6
|
+
const HextomCountdownTimerBarContent = ()=>{
|
|
7
|
+
return /*#__PURE__*/ jsx(Fragment, {
|
|
8
|
+
children: /*#__PURE__*/ jsx("div", {
|
|
9
|
+
className: "gp-p-2",
|
|
10
|
+
children: /*#__PURE__*/ jsx(ThirdPartyPreview, {
|
|
11
|
+
setting: {
|
|
12
|
+
label: 'Hextom: Countdown Timer Bar',
|
|
13
|
+
iconSvg: `<img class="gp-w-6 gp-border gp-border-[#494949] gp-rounded-[3px]" src="${AppConfig.logoUrl}">`
|
|
14
|
+
}
|
|
15
|
+
})
|
|
16
|
+
})
|
|
17
|
+
});
|
|
18
|
+
};
|
|
19
|
+
const HextomCountdownTimerBar = ({ setting })=>{
|
|
20
|
+
return /*#__PURE__*/ jsx("div", {
|
|
21
|
+
style: {
|
|
22
|
+
...makeStyleResponsive('ta', setting?.align)
|
|
23
|
+
},
|
|
24
|
+
children: /*#__PURE__*/ jsx(HextomCountdownTimerBarContent, {})
|
|
25
|
+
});
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
export { HextomCountdownTimerBar as default };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { getLiquidForAppBlock } from '../helpers/thirdParty.js';
|
|
2
|
+
|
|
3
|
+
const HextomCountdownTimerBar = ({ setting, advanced })=>{
|
|
4
|
+
const { align, appBlockId } = setting ?? {};
|
|
5
|
+
return getLiquidForAppBlock(appBlockId, align, `${advanced?.cssClass ?? ''} !gp-block`);
|
|
6
|
+
};
|
|
7
|
+
|
|
8
|
+
export { HextomCountdownTimerBar as default };
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { jsx, Fragment } from 'react/jsx-runtime';
|
|
2
|
+
import { makeStyleResponsive } from '@gem-sdk/core';
|
|
3
|
+
import ThirdPartyPreview from './ThirdPartyPreview.js';
|
|
4
|
+
import AppConfig from '../configs/TrustBadgesBear.js';
|
|
5
|
+
|
|
6
|
+
const TrustBadgesBearContent = ()=>{
|
|
7
|
+
return /*#__PURE__*/ jsx(Fragment, {
|
|
8
|
+
children: /*#__PURE__*/ jsx("div", {
|
|
9
|
+
className: "gp-p-2",
|
|
10
|
+
children: /*#__PURE__*/ jsx(ThirdPartyPreview, {
|
|
11
|
+
setting: {
|
|
12
|
+
label: 'Trust Badges Bear',
|
|
13
|
+
iconSvg: `<img class="gp-w-6 gp-border gp-border-[#494949] gp-rounded-[3px]" src="${AppConfig.logoUrl}">`
|
|
14
|
+
}
|
|
15
|
+
})
|
|
16
|
+
})
|
|
17
|
+
});
|
|
18
|
+
};
|
|
19
|
+
const TrustBadgesBear = ({ setting })=>{
|
|
20
|
+
return /*#__PURE__*/ jsx("div", {
|
|
21
|
+
style: {
|
|
22
|
+
...makeStyleResponsive('ta', setting?.align)
|
|
23
|
+
},
|
|
24
|
+
children: /*#__PURE__*/ jsx(TrustBadgesBearContent, {})
|
|
25
|
+
});
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
export { TrustBadgesBear as default };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { getLiquidForAppBlock } from '../helpers/thirdParty.js';
|
|
2
|
+
|
|
3
|
+
const TrustBadgesBear = ({ setting, advanced })=>{
|
|
4
|
+
const { align, appBlockId } = setting ?? {};
|
|
5
|
+
return getLiquidForAppBlock(appBlockId, align, `${advanced?.cssClass ?? ''} !gp-block`);
|
|
6
|
+
};
|
|
7
|
+
|
|
8
|
+
export { TrustBadgesBear as default };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
var AppConfig = {
|
|
2
|
+
id: 'hextom-countdown-timer-bar',
|
|
3
|
+
label: 'Hextom: Countdown Timer Bar',
|
|
4
|
+
logoUrl: 'https://cdn.shopify.com/app-store/listing_images/904be13e4bba460880341eba1a5579e1/icon/CKCYtc2d5oYDEAE=.png',
|
|
5
|
+
tag: 'HextomCountdownTimerBar'
|
|
6
|
+
};
|
|
7
|
+
|
|
8
|
+
export { AppConfig as default };
|
|
@@ -406,6 +406,14 @@ const Selleasy = dynamic(()=>import('./components/Selleasy.js'), {
|
|
|
406
406
|
ssr: false,
|
|
407
407
|
loading: Loading
|
|
408
408
|
});
|
|
409
|
+
const HextomCountdownTimerBar = dynamic(()=>import('./components/HextomCountdownTimerBar.js'), {
|
|
410
|
+
ssr: false,
|
|
411
|
+
loading: Loading
|
|
412
|
+
});
|
|
413
|
+
const TrustBadgesBear = dynamic(()=>import('./components/TrustBadgesBear.js'), {
|
|
414
|
+
ssr: false,
|
|
415
|
+
loading: Loading
|
|
416
|
+
});
|
|
409
417
|
var thirdParty = {
|
|
410
418
|
TrustshopProductReviews,
|
|
411
419
|
HulkProductOptions,
|
|
@@ -507,7 +515,9 @@ var thirdParty = {
|
|
|
507
515
|
Releasit,
|
|
508
516
|
RequestQuoteHidePrice,
|
|
509
517
|
BirdChime,
|
|
510
|
-
FordeerProductLabels
|
|
518
|
+
FordeerProductLabels,
|
|
519
|
+
HextomCountdownTimerBar,
|
|
520
|
+
TrustBadgesBear
|
|
511
521
|
};
|
|
512
522
|
|
|
513
523
|
export { thirdParty as default };
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
import AppConfig from '../configs/HextomCountdownTimerBar.js';
|
|
2
|
+
|
|
3
|
+
const config = {
|
|
4
|
+
tag: AppConfig.tag,
|
|
5
|
+
label: AppConfig.label,
|
|
6
|
+
icon: '<img class="gp-w-6 gp-border gp-border-[#494949] gp-rounded-[3px]" src="https://cdn.shopify.com/app-store/listing_images/904be13e4bba460880341eba1a5579e1/icon/CKCYtc2d5oYDEAE=.png">',
|
|
7
|
+
editorConfigs: {
|
|
8
|
+
component: {
|
|
9
|
+
isThirdParty: true
|
|
10
|
+
}
|
|
11
|
+
},
|
|
12
|
+
presets: [
|
|
13
|
+
{
|
|
14
|
+
id: AppConfig.id,
|
|
15
|
+
name: {
|
|
16
|
+
en: AppConfig.label
|
|
17
|
+
},
|
|
18
|
+
hideTextContent: true,
|
|
19
|
+
icon: {
|
|
20
|
+
desktop: `<div class="w-full flex flex-col items-center">
|
|
21
|
+
<img class="w-24 border border-dark-200 rounded-medium" src="https://cdn.shopify.com/app-store/listing_images/904be13e4bba460880341eba1a5579e1/icon/CKCYtc2d5oYDEAE=.png">
|
|
22
|
+
<span class="preset-item-title">Hextom: Countdown Timer Bar</span>
|
|
23
|
+
</div>`
|
|
24
|
+
},
|
|
25
|
+
components: [
|
|
26
|
+
{
|
|
27
|
+
tag: AppConfig.tag
|
|
28
|
+
}
|
|
29
|
+
]
|
|
30
|
+
}
|
|
31
|
+
],
|
|
32
|
+
settings: [
|
|
33
|
+
{
|
|
34
|
+
id: 'setting',
|
|
35
|
+
controls: [
|
|
36
|
+
{
|
|
37
|
+
id: 'appBlockId',
|
|
38
|
+
type: 'input',
|
|
39
|
+
default: ''
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
id: 'widgetType',
|
|
43
|
+
label: 'Choose widget',
|
|
44
|
+
type: 'select',
|
|
45
|
+
options: [
|
|
46
|
+
{
|
|
47
|
+
label: 'Fsb Custom Placement',
|
|
48
|
+
value: 'fsb-custom-placement'
|
|
49
|
+
}
|
|
50
|
+
],
|
|
51
|
+
default: 'fsb-custom-placement'
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
id: 'install',
|
|
55
|
+
type: 'open-link',
|
|
56
|
+
target: '_blank',
|
|
57
|
+
linkType: 'install',
|
|
58
|
+
href: 'https://apps.shopify.com/event-promotion-bar?utm_source=gempages',
|
|
59
|
+
appName: AppConfig.label
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
id: 'openApp',
|
|
63
|
+
type: 'open-link',
|
|
64
|
+
target: '_blank',
|
|
65
|
+
linkType: 'openApp',
|
|
66
|
+
href: '',
|
|
67
|
+
appName: AppConfig.label
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
id: 'align',
|
|
71
|
+
label: 'Alignment',
|
|
72
|
+
type: 'segment',
|
|
73
|
+
options: [
|
|
74
|
+
{
|
|
75
|
+
label: 'Left',
|
|
76
|
+
value: 'left',
|
|
77
|
+
type: 'align'
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
label: 'Center',
|
|
81
|
+
value: 'center',
|
|
82
|
+
type: 'align'
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
label: 'Right',
|
|
86
|
+
value: 'right',
|
|
87
|
+
type: 'align'
|
|
88
|
+
}
|
|
89
|
+
],
|
|
90
|
+
devices: {
|
|
91
|
+
desktop: {
|
|
92
|
+
default: 'left'
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
]
|
|
97
|
+
}
|
|
98
|
+
],
|
|
99
|
+
ui: [
|
|
100
|
+
{
|
|
101
|
+
type: 'control',
|
|
102
|
+
setting: {
|
|
103
|
+
id: 'install'
|
|
104
|
+
}
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
type: 'control',
|
|
108
|
+
setting: {
|
|
109
|
+
id: 'openApp'
|
|
110
|
+
}
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
type: 'control',
|
|
114
|
+
label: {
|
|
115
|
+
en: 'Align'
|
|
116
|
+
},
|
|
117
|
+
setting: {
|
|
118
|
+
id: 'align'
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
]
|
|
122
|
+
};
|
|
123
|
+
|
|
124
|
+
export { config as default };
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
import AppConfig from '../configs/TrustBadgesBear.js';
|
|
2
|
+
|
|
3
|
+
const config = {
|
|
4
|
+
tag: AppConfig.tag,
|
|
5
|
+
label: AppConfig.label,
|
|
6
|
+
icon: '<img class="gp-w-6 gp-border gp-border-[#494949] gp-rounded-[3px]" src="https://cdn.shopify.com/app-store/listing_images/c9141bfba8db18a258f290a5a639986e/icon/CLDR_q6erfwCEAE=.png">',
|
|
7
|
+
editorConfigs: {
|
|
8
|
+
component: {
|
|
9
|
+
isThirdParty: true
|
|
10
|
+
}
|
|
11
|
+
},
|
|
12
|
+
presets: [
|
|
13
|
+
{
|
|
14
|
+
id: AppConfig.id,
|
|
15
|
+
name: {
|
|
16
|
+
en: AppConfig.label
|
|
17
|
+
},
|
|
18
|
+
hideTextContent: true,
|
|
19
|
+
icon: {
|
|
20
|
+
desktop: `<div class="w-full flex flex-col items-center">
|
|
21
|
+
<img class="w-24 border border-dark-200 rounded-medium" src="https://cdn.shopify.com/app-store/listing_images/c9141bfba8db18a258f290a5a639986e/icon/CLDR_q6erfwCEAE=.png">
|
|
22
|
+
<span class="preset-item-title">Trust Badges Bear</span>
|
|
23
|
+
</div>`
|
|
24
|
+
},
|
|
25
|
+
components: [
|
|
26
|
+
{
|
|
27
|
+
tag: AppConfig.tag
|
|
28
|
+
}
|
|
29
|
+
]
|
|
30
|
+
}
|
|
31
|
+
],
|
|
32
|
+
settings: [
|
|
33
|
+
{
|
|
34
|
+
id: 'setting',
|
|
35
|
+
controls: [
|
|
36
|
+
{
|
|
37
|
+
id: 'appBlockId',
|
|
38
|
+
type: 'input',
|
|
39
|
+
default: ''
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
id: 'widgetType',
|
|
43
|
+
label: 'Choose widget',
|
|
44
|
+
type: 'select',
|
|
45
|
+
options: [
|
|
46
|
+
{
|
|
47
|
+
label: 'Widget',
|
|
48
|
+
value: 'widget'
|
|
49
|
+
}
|
|
50
|
+
],
|
|
51
|
+
default: 'widget'
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
id: 'install',
|
|
55
|
+
type: 'open-link',
|
|
56
|
+
target: '_blank',
|
|
57
|
+
linkType: 'install',
|
|
58
|
+
href: 'https://apps.shopify.com/ultimate-trust-badges?utm_source=gempages',
|
|
59
|
+
appName: AppConfig.label
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
id: 'openApp',
|
|
63
|
+
type: 'open-link',
|
|
64
|
+
target: '_blank',
|
|
65
|
+
linkType: 'openApp',
|
|
66
|
+
href: 'https://admin.shopify.com/?redirect=/apps/ultimate-trust-badge',
|
|
67
|
+
appName: AppConfig.label
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
id: 'align',
|
|
71
|
+
label: 'Alignment',
|
|
72
|
+
type: 'segment',
|
|
73
|
+
options: [
|
|
74
|
+
{
|
|
75
|
+
label: 'Left',
|
|
76
|
+
value: 'left',
|
|
77
|
+
type: 'align'
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
label: 'Center',
|
|
81
|
+
value: 'center',
|
|
82
|
+
type: 'align'
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
label: 'Right',
|
|
86
|
+
value: 'right',
|
|
87
|
+
type: 'align'
|
|
88
|
+
}
|
|
89
|
+
],
|
|
90
|
+
devices: {
|
|
91
|
+
desktop: {
|
|
92
|
+
default: 'left'
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
]
|
|
97
|
+
}
|
|
98
|
+
],
|
|
99
|
+
ui: [
|
|
100
|
+
{
|
|
101
|
+
type: 'control',
|
|
102
|
+
setting: {
|
|
103
|
+
id: 'install'
|
|
104
|
+
}
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
type: 'control',
|
|
108
|
+
setting: {
|
|
109
|
+
id: 'openApp'
|
|
110
|
+
}
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
type: 'control',
|
|
114
|
+
label: {
|
|
115
|
+
en: 'Align'
|
|
116
|
+
},
|
|
117
|
+
setting: {
|
|
118
|
+
id: 'align'
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
]
|
|
122
|
+
};
|
|
123
|
+
|
|
124
|
+
export { config as default };
|