@gem-sdk/components 2.0.0-dev.395 → 2.0.0-dev.396
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/banner/components/common/getStyle.js +3 -1
- package/dist/cjs/banner/setting/setting.js +12 -16
- package/dist/cjs/banner/setting/uiV2.js +0 -26
- package/dist/cjs/product/components/ProductBundle/common/styles.js +0 -5
- package/dist/cjs/product/components/ProductBundle/components/ProductBundleDiscountChildrenItem.js +0 -1
- package/dist/cjs/product/setting/product-badge/configs/settings.js +1 -1
- package/dist/cjs/product/setting/product-badge/configs/uiV2.js +2 -5
- package/dist/esm/banner/components/common/getStyle.js +4 -2
- package/dist/esm/banner/setting/setting.js +12 -16
- package/dist/esm/banner/setting/uiV2.js +0 -26
- package/dist/esm/product/components/ProductBundle/common/styles.js +1 -6
- package/dist/esm/product/components/ProductBundle/components/ProductBundleDiscountChildrenItem.js +0 -1
- package/dist/esm/product/setting/product-badge/configs/settings.js +1 -1
- package/dist/esm/product/setting/product-badge/configs/uiV2.js +2 -5
- package/dist/types/index.d.ts +1 -1
- package/package.json +2 -2
|
@@ -60,7 +60,9 @@ const getOverlayStyle = (styles)=>{
|
|
|
60
60
|
};
|
|
61
61
|
const getRowStyle = (styles)=>{
|
|
62
62
|
const { contentPadding } = styles ?? {};
|
|
63
|
-
const composeStyles =
|
|
63
|
+
const composeStyles = {
|
|
64
|
+
...core.getResponsiveStylePadding(contentPadding)
|
|
65
|
+
};
|
|
64
66
|
return filterTruthyStyles(composeStyles);
|
|
65
67
|
};
|
|
66
68
|
const getAdaptiveStyle = (styles)=>{
|
|
@@ -446,7 +446,7 @@ const SettingsV2 = [
|
|
|
446
446
|
type: 'image',
|
|
447
447
|
color: 'bg-2',
|
|
448
448
|
image: {
|
|
449
|
-
src: 'https://
|
|
449
|
+
src: 'https://ucarecdn.com/40daf457-10f5-4a0f-a7c4-d73d28ffd60c/willianjustendevasconcellosjOF2TFSNxQIunsplash11min.png',
|
|
450
450
|
width: 1920,
|
|
451
451
|
height: 900
|
|
452
452
|
},
|
|
@@ -457,7 +457,7 @@ const SettingsV2 = [
|
|
|
457
457
|
},
|
|
458
458
|
repeat: 'no-repeat',
|
|
459
459
|
attachment: 'scroll',
|
|
460
|
-
video: 'https://
|
|
460
|
+
video: 'https://youtu.be/KOxfzBp72uk',
|
|
461
461
|
videoHtml5: 'https://media.w3.org/2010/05/sintel/trailer.mp4',
|
|
462
462
|
videoType: 'youtube',
|
|
463
463
|
loop: true,
|
|
@@ -716,26 +716,22 @@ const SettingsV2 = [
|
|
|
716
716
|
devices: {
|
|
717
717
|
desktop: {
|
|
718
718
|
default: {
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
right: '0px'
|
|
725
|
-
}
|
|
719
|
+
top: '4px',
|
|
720
|
+
left: '16px',
|
|
721
|
+
bottom: '4px',
|
|
722
|
+
right: '16px',
|
|
723
|
+
linked: false
|
|
726
724
|
}
|
|
727
725
|
}
|
|
728
726
|
},
|
|
729
727
|
compoDefaultValue: {
|
|
730
728
|
desktop: {
|
|
731
729
|
default: {
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
right: '0px'
|
|
738
|
-
}
|
|
730
|
+
top: '4px',
|
|
731
|
+
left: '16px',
|
|
732
|
+
bottom: '4px',
|
|
733
|
+
right: '16px',
|
|
734
|
+
linked: false
|
|
739
735
|
}
|
|
740
736
|
}
|
|
741
737
|
}
|
|
@@ -115,32 +115,6 @@ const SettingUIV2 = [
|
|
|
115
115
|
},
|
|
116
116
|
setting: {
|
|
117
117
|
id: 'contentPadding'
|
|
118
|
-
},
|
|
119
|
-
controlConfig: {
|
|
120
|
-
id: 'contentPadding',
|
|
121
|
-
type: 'padding-v2',
|
|
122
|
-
compoDefaultValue: {
|
|
123
|
-
desktop: {
|
|
124
|
-
padding: {
|
|
125
|
-
top: '32px',
|
|
126
|
-
right: '0px',
|
|
127
|
-
bottom: '32px',
|
|
128
|
-
left: '0px',
|
|
129
|
-
linked: false
|
|
130
|
-
}
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
|
-
},
|
|
134
|
-
compoDefaultValue: {
|
|
135
|
-
desktop: {
|
|
136
|
-
padding: {
|
|
137
|
-
top: '32px',
|
|
138
|
-
right: '0px',
|
|
139
|
-
bottom: '32px',
|
|
140
|
-
left: '0px',
|
|
141
|
-
linked: false
|
|
142
|
-
}
|
|
143
|
-
}
|
|
144
118
|
}
|
|
145
119
|
},
|
|
146
120
|
{
|
|
@@ -4,11 +4,6 @@ var core = require('@gem-sdk/core');
|
|
|
4
4
|
|
|
5
5
|
const getSizeSettings = (styles)=>core.makeGlobalSize(styles?.size);
|
|
6
6
|
const getItemWrapStyles = (styles, isSelected)=>{
|
|
7
|
-
console.log('shadown', core.getStyleShadowState(styles?.boxShadowBundle, 'box-shadow', {
|
|
8
|
-
normal: true,
|
|
9
|
-
active: true,
|
|
10
|
-
hover: true
|
|
11
|
-
}));
|
|
12
7
|
return {
|
|
13
8
|
...getSizeSettings(styles).width,
|
|
14
9
|
...getSizeSettings(styles).padding,
|
package/dist/cjs/product/components/ProductBundle/components/ProductBundleDiscountChildrenItem.js
CHANGED
|
@@ -18,7 +18,6 @@ const ProductBundleDiscountChildrenItem = (props)=>{
|
|
|
18
18
|
const composeIconSectionClasses = system.createClass(classes.getIconSectionClasses);
|
|
19
19
|
const composeItemClasses = system.createClass(classes.getItemClasses);
|
|
20
20
|
const composeFlexChildren = system.createClass(styles.getFlexChildren);
|
|
21
|
-
console.log('composeItemWrapStyles', composeItemWrapStyles);
|
|
22
21
|
return /*#__PURE__*/ jsxRuntime.jsx("div", {
|
|
23
22
|
"aria-hidden": true,
|
|
24
23
|
onClick: ()=>setSelected?.(index),
|
|
@@ -105,9 +105,9 @@ const ProductBadgeSettings = [
|
|
|
105
105
|
default: 'Sale {percent_discount} off',
|
|
106
106
|
minHeight: 72,
|
|
107
107
|
inputClass: '!pr-36',
|
|
108
|
-
isFallback: true,
|
|
109
108
|
autoHeight: true,
|
|
110
109
|
showPlusBtn: true,
|
|
110
|
+
isFocusToBottom: true,
|
|
111
111
|
defaultRows: 1,
|
|
112
112
|
suggestContents: [
|
|
113
113
|
{
|
|
@@ -72,7 +72,7 @@ const SettingUIV2 = [
|
|
|
72
72
|
{
|
|
73
73
|
id: 'content-badge',
|
|
74
74
|
type: 'combo',
|
|
75
|
-
iconName: 'polaris-
|
|
75
|
+
iconName: 'polaris-plus',
|
|
76
76
|
isHideClear: true,
|
|
77
77
|
fixedValue: 'Add...',
|
|
78
78
|
popoverLabel: {
|
|
@@ -81,9 +81,6 @@ const SettingUIV2 = [
|
|
|
81
81
|
label: {
|
|
82
82
|
en: 'Content'
|
|
83
83
|
},
|
|
84
|
-
setting: {
|
|
85
|
-
id: 'displayContent'
|
|
86
|
-
},
|
|
87
84
|
layout: 'vertical',
|
|
88
85
|
conditionDisplay: 'contentType == "text"',
|
|
89
86
|
controls: [
|
|
@@ -104,7 +101,7 @@ const SettingUIV2 = [
|
|
|
104
101
|
setting: {
|
|
105
102
|
id: 'contentBanner'
|
|
106
103
|
},
|
|
107
|
-
conditionDisplay: 'displayContent
|
|
104
|
+
conditionDisplay: 'displayContent?.includes("{inventory_quantity}")'
|
|
108
105
|
}
|
|
109
106
|
]
|
|
110
107
|
},
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { makeStyleResponsive, getHeightByShapeGlobalSize, makeStyleWithDefault, getWidthByShapeGlobalSize, makeStyle, getSingleColorVariable, getRadiusStyleActiveState, getStyleShadow, getGlobalColorStateStyle, makeStyleState,
|
|
1
|
+
import { makeStyleResponsive, getHeightByShapeGlobalSize, makeStyleWithDefault, getWidthByShapeGlobalSize, makeStyle, getSingleColorVariable, getRadiusStyleActiveState, getStyleShadow, getGlobalColorStateStyle, makeStyleState, getResponsiveStylePadding, getStyleBackgroundByDevice, getGradientBgrStyleByDevice } from '@gem-sdk/core';
|
|
2
2
|
import { getVisibilityStyle, getStyleAspectRatioHeroBannerCustom, getAspectRatioSettings, getDisplayStyleByFitContent, getStyleHeroBannerBg, bgiEnableByDevice, getAttachmentDevice, getClipPath, getResponsiveSetting } from './common.js';
|
|
3
3
|
|
|
4
4
|
function filterTruthyStyles(styles) {
|
|
@@ -58,7 +58,9 @@ const getOverlayStyle = (styles)=>{
|
|
|
58
58
|
};
|
|
59
59
|
const getRowStyle = (styles)=>{
|
|
60
60
|
const { contentPadding } = styles ?? {};
|
|
61
|
-
const composeStyles =
|
|
61
|
+
const composeStyles = {
|
|
62
|
+
...getResponsiveStylePadding(contentPadding)
|
|
63
|
+
};
|
|
62
64
|
return filterTruthyStyles(composeStyles);
|
|
63
65
|
};
|
|
64
66
|
const getAdaptiveStyle = (styles)=>{
|
|
@@ -444,7 +444,7 @@ const SettingsV2 = [
|
|
|
444
444
|
type: 'image',
|
|
445
445
|
color: 'bg-2',
|
|
446
446
|
image: {
|
|
447
|
-
src: 'https://
|
|
447
|
+
src: 'https://ucarecdn.com/40daf457-10f5-4a0f-a7c4-d73d28ffd60c/willianjustendevasconcellosjOF2TFSNxQIunsplash11min.png',
|
|
448
448
|
width: 1920,
|
|
449
449
|
height: 900
|
|
450
450
|
},
|
|
@@ -455,7 +455,7 @@ const SettingsV2 = [
|
|
|
455
455
|
},
|
|
456
456
|
repeat: 'no-repeat',
|
|
457
457
|
attachment: 'scroll',
|
|
458
|
-
video: 'https://
|
|
458
|
+
video: 'https://youtu.be/KOxfzBp72uk',
|
|
459
459
|
videoHtml5: 'https://media.w3.org/2010/05/sintel/trailer.mp4',
|
|
460
460
|
videoType: 'youtube',
|
|
461
461
|
loop: true,
|
|
@@ -714,26 +714,22 @@ const SettingsV2 = [
|
|
|
714
714
|
devices: {
|
|
715
715
|
desktop: {
|
|
716
716
|
default: {
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
right: '0px'
|
|
723
|
-
}
|
|
717
|
+
top: '4px',
|
|
718
|
+
left: '16px',
|
|
719
|
+
bottom: '4px',
|
|
720
|
+
right: '16px',
|
|
721
|
+
linked: false
|
|
724
722
|
}
|
|
725
723
|
}
|
|
726
724
|
},
|
|
727
725
|
compoDefaultValue: {
|
|
728
726
|
desktop: {
|
|
729
727
|
default: {
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
right: '0px'
|
|
736
|
-
}
|
|
728
|
+
top: '4px',
|
|
729
|
+
left: '16px',
|
|
730
|
+
bottom: '4px',
|
|
731
|
+
right: '16px',
|
|
732
|
+
linked: false
|
|
737
733
|
}
|
|
738
734
|
}
|
|
739
735
|
}
|
|
@@ -113,32 +113,6 @@ const SettingUIV2 = [
|
|
|
113
113
|
},
|
|
114
114
|
setting: {
|
|
115
115
|
id: 'contentPadding'
|
|
116
|
-
},
|
|
117
|
-
controlConfig: {
|
|
118
|
-
id: 'contentPadding',
|
|
119
|
-
type: 'padding-v2',
|
|
120
|
-
compoDefaultValue: {
|
|
121
|
-
desktop: {
|
|
122
|
-
padding: {
|
|
123
|
-
top: '32px',
|
|
124
|
-
right: '0px',
|
|
125
|
-
bottom: '32px',
|
|
126
|
-
left: '0px',
|
|
127
|
-
linked: false
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
}
|
|
131
|
-
},
|
|
132
|
-
compoDefaultValue: {
|
|
133
|
-
desktop: {
|
|
134
|
-
padding: {
|
|
135
|
-
top: '32px',
|
|
136
|
-
right: '0px',
|
|
137
|
-
bottom: '32px',
|
|
138
|
-
left: '0px',
|
|
139
|
-
linked: false
|
|
140
|
-
}
|
|
141
|
-
}
|
|
142
116
|
}
|
|
143
117
|
},
|
|
144
118
|
{
|
|
@@ -1,12 +1,7 @@
|
|
|
1
|
-
import { composeClasses, makeGlobalSize, makeStyle,
|
|
1
|
+
import { composeClasses, makeGlobalSize, makeStyle, makeStyleState, composeRadius, getStyleShadowState, getStyleShadow, getBorderStyle, handleConvertBorderWidth, handleConvertBorderStyle, handleConvertBorderColor, getRadiusStyleActiveState, makeStyleResponsive, getGlobalColorStateStyle } from '@gem-sdk/core';
|
|
2
2
|
|
|
3
3
|
const getSizeSettings = (styles)=>makeGlobalSize(styles?.size);
|
|
4
4
|
const getItemWrapStyles = (styles, isSelected)=>{
|
|
5
|
-
console.log('shadown', getStyleShadowState(styles?.boxShadowBundle, 'box-shadow', {
|
|
6
|
-
normal: true,
|
|
7
|
-
active: true,
|
|
8
|
-
hover: true
|
|
9
|
-
}));
|
|
10
5
|
return {
|
|
11
6
|
...getSizeSettings(styles).width,
|
|
12
7
|
...getSizeSettings(styles).padding,
|
package/dist/esm/product/components/ProductBundle/components/ProductBundleDiscountChildrenItem.js
CHANGED
|
@@ -14,7 +14,6 @@ const ProductBundleDiscountChildrenItem = (props)=>{
|
|
|
14
14
|
const composeIconSectionClasses = createClass(getIconSectionClasses);
|
|
15
15
|
const composeItemClasses = createClass(getItemClasses);
|
|
16
16
|
const composeFlexChildren = createClass(getFlexChildren);
|
|
17
|
-
console.log('composeItemWrapStyles', composeItemWrapStyles);
|
|
18
17
|
return /*#__PURE__*/ jsx("div", {
|
|
19
18
|
"aria-hidden": true,
|
|
20
19
|
onClick: ()=>setSelected?.(index),
|
|
@@ -103,9 +103,9 @@ const ProductBadgeSettings = [
|
|
|
103
103
|
default: 'Sale {percent_discount} off',
|
|
104
104
|
minHeight: 72,
|
|
105
105
|
inputClass: '!pr-36',
|
|
106
|
-
isFallback: true,
|
|
107
106
|
autoHeight: true,
|
|
108
107
|
showPlusBtn: true,
|
|
108
|
+
isFocusToBottom: true,
|
|
109
109
|
defaultRows: 1,
|
|
110
110
|
suggestContents: [
|
|
111
111
|
{
|
|
@@ -70,7 +70,7 @@ const SettingUIV2 = [
|
|
|
70
70
|
{
|
|
71
71
|
id: 'content-badge',
|
|
72
72
|
type: 'combo',
|
|
73
|
-
iconName: 'polaris-
|
|
73
|
+
iconName: 'polaris-plus',
|
|
74
74
|
isHideClear: true,
|
|
75
75
|
fixedValue: 'Add...',
|
|
76
76
|
popoverLabel: {
|
|
@@ -79,9 +79,6 @@ const SettingUIV2 = [
|
|
|
79
79
|
label: {
|
|
80
80
|
en: 'Content'
|
|
81
81
|
},
|
|
82
|
-
setting: {
|
|
83
|
-
id: 'displayContent'
|
|
84
|
-
},
|
|
85
82
|
layout: 'vertical',
|
|
86
83
|
conditionDisplay: 'contentType == "text"',
|
|
87
84
|
controls: [
|
|
@@ -102,7 +99,7 @@ const SettingUIV2 = [
|
|
|
102
99
|
setting: {
|
|
103
100
|
id: 'contentBanner'
|
|
104
101
|
},
|
|
105
|
-
conditionDisplay: 'displayContent
|
|
102
|
+
conditionDisplay: 'displayContent?.includes("{inventory_quantity}")'
|
|
106
103
|
}
|
|
107
104
|
]
|
|
108
105
|
},
|
package/dist/types/index.d.ts
CHANGED
|
@@ -730,7 +730,7 @@ type Styles$2 = {
|
|
|
730
730
|
shadowBg?: ShadowProps$1;
|
|
731
731
|
sizeSetting?: ObjectDevices$1<SizeSettingGlobal>;
|
|
732
732
|
order?: ObjectDevices$1<number>;
|
|
733
|
-
contentPadding?: ObjectDevices$1<
|
|
733
|
+
contentPadding?: ObjectDevices$1<PaddingType$1>;
|
|
734
734
|
} & Pick<NonNullable<RowProps['styles']>, 'verticalGutter' | 'background'>;
|
|
735
735
|
type HeroBannerProps = BasePropsWrap<Setting$4, Styles$2> & {
|
|
736
736
|
children?: React.ReactNode;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gem-sdk/components",
|
|
3
|
-
"version": "2.0.0-dev.
|
|
3
|
+
"version": "2.0.0-dev.396",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"main": "dist/cjs/index.js",
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"relationship": "rollup -c ./scripts/rollup.config.settings.mjs && node ./scripts/get-control-relationship.js && node ./scripts/get-element-relationship.js"
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
|
-
"@gem-sdk/core": "2.0.0-dev.
|
|
25
|
+
"@gem-sdk/core": "2.0.0-dev.396",
|
|
26
26
|
"@gem-sdk/styles": "2.0.0-dev.381",
|
|
27
27
|
"@gem-sdk/system": "2.0.0-dev.371",
|
|
28
28
|
"@types/react-transition-group": "^4.4.5"
|