@gem-sdk/components 2.2.0-staging.32 → 2.2.0-staging.34
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/button/components/Button.liquid.js +1 -1
- package/dist/cjs/third-party/components/EcomsendBackInStockAlert.liquid.js +8 -8
- package/dist/cjs/third-party/setting/EcomsendBackInStockAlert.js +16 -0
- package/dist/esm/button/components/Button.liquid.js +1 -1
- package/dist/esm/third-party/components/EcomsendBackInStockAlert.liquid.js +8 -8
- package/dist/esm/third-party/setting/EcomsendBackInStockAlert.js +16 -0
- package/dist/types/index.d.ts +1 -0
- package/package.json +2 -2
|
@@ -127,7 +127,7 @@ const Button = ({ className, builderProps, customAttrs, pageContext, setting = {
|
|
|
127
127
|
}}"
|
|
128
128
|
>
|
|
129
129
|
${!disabledLoading ? ` <svg
|
|
130
|
-
class="gp-invisible gp-absolute gp-h-5 gp-w-5 group-data-[state=loading]:gp-animate-spin group-data-[state=loading]:gp-visible"
|
|
130
|
+
class="group-data-[state=idle]:gp-invisible gp-absolute gp-h-5 gp-w-5 group-data-[state=loading]:gp-animate-spin group-data-[state=loading]:gp-visible"
|
|
131
131
|
xmlns="http://www.w3.org/2000/svg"
|
|
132
132
|
fill="none"
|
|
133
133
|
viewBox="0 0 24 24"
|
|
@@ -5,17 +5,17 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
var core = require('@gem-sdk/core');
|
|
6
6
|
|
|
7
7
|
const EcomsendBackInStockAlert = ({ setting, advanced })=>{
|
|
8
|
-
const { align } = setting ?? {};
|
|
8
|
+
const { align, productId } = setting ?? {};
|
|
9
9
|
return core.template`
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
<div
|
|
11
|
+
class="${advanced?.cssClass}"
|
|
12
|
+
style="${{
|
|
13
13
|
...core.makeStyleResponsive('ta', align)
|
|
14
14
|
}}"
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
`;
|
|
15
|
+
>
|
|
16
|
+
${productId ? `<div style="display: block" class="ecomsend-bis-block" data-product-id="${productId}"></div>` : `<div id="sealapps-bis-widget"></div>`}
|
|
17
|
+
</div>
|
|
18
|
+
`;
|
|
19
19
|
};
|
|
20
20
|
|
|
21
21
|
exports.default = EcomsendBackInStockAlert;
|
|
@@ -54,6 +54,11 @@ const config = {
|
|
|
54
54
|
],
|
|
55
55
|
default: 'product-restore-email'
|
|
56
56
|
},
|
|
57
|
+
{
|
|
58
|
+
id: 'productId',
|
|
59
|
+
label: 'Product ID',
|
|
60
|
+
type: 'input'
|
|
61
|
+
},
|
|
57
62
|
{
|
|
58
63
|
id: 'install',
|
|
59
64
|
type: 'open-link',
|
|
@@ -121,6 +126,17 @@ const config = {
|
|
|
121
126
|
setting: {
|
|
122
127
|
id: 'align'
|
|
123
128
|
}
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
type: 'control',
|
|
132
|
+
setting: {
|
|
133
|
+
id: 'productId'
|
|
134
|
+
},
|
|
135
|
+
options: {
|
|
136
|
+
hideOnPages: [
|
|
137
|
+
'GP_PRODUCT'
|
|
138
|
+
]
|
|
139
|
+
}
|
|
124
140
|
}
|
|
125
141
|
]
|
|
126
142
|
};
|
|
@@ -123,7 +123,7 @@ const Button = ({ className, builderProps, customAttrs, pageContext, setting = {
|
|
|
123
123
|
}}"
|
|
124
124
|
>
|
|
125
125
|
${!disabledLoading ? ` <svg
|
|
126
|
-
class="gp-invisible gp-absolute gp-h-5 gp-w-5 group-data-[state=loading]:gp-animate-spin group-data-[state=loading]:gp-visible"
|
|
126
|
+
class="group-data-[state=idle]:gp-invisible gp-absolute gp-h-5 gp-w-5 group-data-[state=loading]:gp-animate-spin group-data-[state=loading]:gp-visible"
|
|
127
127
|
xmlns="http://www.w3.org/2000/svg"
|
|
128
128
|
fill="none"
|
|
129
129
|
viewBox="0 0 24 24"
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { template, makeStyleResponsive } from '@gem-sdk/core';
|
|
2
2
|
|
|
3
3
|
const EcomsendBackInStockAlert = ({ setting, advanced })=>{
|
|
4
|
-
const { align } = setting ?? {};
|
|
4
|
+
const { align, productId } = setting ?? {};
|
|
5
5
|
return template`
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
<div
|
|
7
|
+
class="${advanced?.cssClass}"
|
|
8
|
+
style="${{
|
|
9
9
|
...makeStyleResponsive('ta', align)
|
|
10
10
|
}}"
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
`;
|
|
11
|
+
>
|
|
12
|
+
${productId ? `<div style="display: block" class="ecomsend-bis-block" data-product-id="${productId}"></div>` : `<div id="sealapps-bis-widget"></div>`}
|
|
13
|
+
</div>
|
|
14
|
+
`;
|
|
15
15
|
};
|
|
16
16
|
|
|
17
17
|
export { EcomsendBackInStockAlert as default };
|
|
@@ -50,6 +50,11 @@ const config = {
|
|
|
50
50
|
],
|
|
51
51
|
default: 'product-restore-email'
|
|
52
52
|
},
|
|
53
|
+
{
|
|
54
|
+
id: 'productId',
|
|
55
|
+
label: 'Product ID',
|
|
56
|
+
type: 'input'
|
|
57
|
+
},
|
|
53
58
|
{
|
|
54
59
|
id: 'install',
|
|
55
60
|
type: 'open-link',
|
|
@@ -117,6 +122,17 @@ const config = {
|
|
|
117
122
|
setting: {
|
|
118
123
|
id: 'align'
|
|
119
124
|
}
|
|
125
|
+
},
|
|
126
|
+
{
|
|
127
|
+
type: 'control',
|
|
128
|
+
setting: {
|
|
129
|
+
id: 'productId'
|
|
130
|
+
},
|
|
131
|
+
options: {
|
|
132
|
+
hideOnPages: [
|
|
133
|
+
'GP_PRODUCT'
|
|
134
|
+
]
|
|
135
|
+
}
|
|
120
136
|
}
|
|
121
137
|
]
|
|
122
138
|
};
|
package/dist/types/index.d.ts
CHANGED
|
@@ -3530,6 +3530,7 @@ type EcomsendBackInStockAlertProps = BaseProps<{
|
|
|
3530
3530
|
openApp?: any;
|
|
3531
3531
|
install?: any;
|
|
3532
3532
|
appBlockId?: string;
|
|
3533
|
+
productId?: string;
|
|
3533
3534
|
widgetType?: string;
|
|
3534
3535
|
}>;
|
|
3535
3536
|
declare const EcomsendBackInStockAlert$1: React.FC<EcomsendBackInStockAlertProps>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gem-sdk/components",
|
|
3
|
-
"version": "2.2.0-staging.
|
|
3
|
+
"version": "2.2.0-staging.34",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"main": "dist/cjs/index.js",
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"format": "prettier --write \"./src/**/*.{ts,tsx}\""
|
|
22
22
|
},
|
|
23
23
|
"devDependencies": {
|
|
24
|
-
"@gem-sdk/core": "2.2.0-staging.
|
|
24
|
+
"@gem-sdk/core": "2.2.0-staging.33",
|
|
25
25
|
"@gem-sdk/styles": "2.1.27-staging.13",
|
|
26
26
|
"@types/react-transition-group": "^4.4.5"
|
|
27
27
|
},
|