@gem-sdk/components 2.0.0-dev.478 → 2.0.0-dev.479
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/product/components/ProductSKU/Sku.liquid.js +2 -1
- package/dist/cjs/product/components/ProductVariants/common/base/styles.js +13 -1
- package/dist/cjs/product/setting/product-variant/configs/settings.js +1 -1
- package/dist/esm/product/components/ProductSKU/Sku.liquid.js +2 -1
- package/dist/esm/product/components/ProductVariants/common/base/styles.js +14 -2
- package/dist/esm/product/setting/product-variant/configs/settings.js +1 -1
- package/package.json +2 -2
|
@@ -25,7 +25,8 @@ const ProductSku = ({ setting, styles, advanced, builderProps })=>{
|
|
|
25
25
|
setting: {
|
|
26
26
|
...setting,
|
|
27
27
|
text: `{% if currentVariant.sku.size > 0 %} ${labelContent} {{ currentVariant.sku }} {% endif %}`,
|
|
28
|
-
excludeFlex: true
|
|
28
|
+
excludeFlex: true,
|
|
29
|
+
isForceValue: true
|
|
29
30
|
},
|
|
30
31
|
advanced: advanced,
|
|
31
32
|
builderProps,
|
|
@@ -54,9 +54,21 @@ const getWrapperStyleNormalAndHover = (props)=>{
|
|
|
54
54
|
const isColorType = typeOfOption === 'color';
|
|
55
55
|
const isUploadImageType = typeOfOption === 'image' || typeOfOption === 'image_shopify';
|
|
56
56
|
const appendTypoStyle = core.composeTypographyStyle(optionTypo, optionTypography);
|
|
57
|
+
const composeShadow = [
|
|
58
|
+
'normal',
|
|
59
|
+
'hover'
|
|
60
|
+
].reduce((acc, state)=>({
|
|
61
|
+
...acc,
|
|
62
|
+
...core.getStyleShadow({
|
|
63
|
+
value: optionShadow?.[state],
|
|
64
|
+
state,
|
|
65
|
+
styleAppliedFor: 'box-shadow',
|
|
66
|
+
isEnableShadow: optionHasShadow?.[state]
|
|
67
|
+
})
|
|
68
|
+
}), {});
|
|
57
69
|
return helpers.filterTruthyObject({
|
|
58
70
|
...core.composeRadius(optionRounded),
|
|
59
|
-
...
|
|
71
|
+
...composeShadow,
|
|
60
72
|
...!isColorType && core.getGlobalColorStateStyle('bg', optionBgColor),
|
|
61
73
|
...!isColorType && core.handleConvertBorderStyle(optionBorder),
|
|
62
74
|
...!isColorType && core.handleConvertBorderWidth(optionBorder),
|
|
@@ -21,7 +21,8 @@ const ProductSku = ({ setting, styles, advanced, builderProps })=>{
|
|
|
21
21
|
setting: {
|
|
22
22
|
...setting,
|
|
23
23
|
text: `{% if currentVariant.sku.size > 0 %} ${labelContent} {{ currentVariant.sku }} {% endif %}`,
|
|
24
|
-
excludeFlex: true
|
|
24
|
+
excludeFlex: true,
|
|
25
|
+
isForceValue: true
|
|
25
26
|
},
|
|
26
27
|
advanced: advanced,
|
|
27
28
|
builderProps,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { composeTypographyStyle, getRadiusStyleActiveState, getStyleShadow, makeStyle, getSingleColorVariable, composeRadius,
|
|
1
|
+
import { composeTypographyStyle, getRadiusStyleActiveState, getStyleShadow, makeStyle, getSingleColorVariable, composeRadius, getGlobalColorStateStyle, handleConvertBorderStyle, handleConvertBorderWidth, handleConvertBorderColor } from '@gem-sdk/core';
|
|
2
2
|
import { filterTruthyObject } from '../../../../../helpers.js';
|
|
3
3
|
|
|
4
4
|
const getWrapperStyleActive = (props)=>{
|
|
@@ -52,9 +52,21 @@ const getWrapperStyleNormalAndHover = (props)=>{
|
|
|
52
52
|
const isColorType = typeOfOption === 'color';
|
|
53
53
|
const isUploadImageType = typeOfOption === 'image' || typeOfOption === 'image_shopify';
|
|
54
54
|
const appendTypoStyle = composeTypographyStyle(optionTypo, optionTypography);
|
|
55
|
+
const composeShadow = [
|
|
56
|
+
'normal',
|
|
57
|
+
'hover'
|
|
58
|
+
].reduce((acc, state)=>({
|
|
59
|
+
...acc,
|
|
60
|
+
...getStyleShadow({
|
|
61
|
+
value: optionShadow?.[state],
|
|
62
|
+
state,
|
|
63
|
+
styleAppliedFor: 'box-shadow',
|
|
64
|
+
isEnableShadow: optionHasShadow?.[state]
|
|
65
|
+
})
|
|
66
|
+
}), {});
|
|
55
67
|
return filterTruthyObject({
|
|
56
68
|
...composeRadius(optionRounded),
|
|
57
|
-
...
|
|
69
|
+
...composeShadow,
|
|
58
70
|
...!isColorType && getGlobalColorStateStyle('bg', optionBgColor),
|
|
59
71
|
...!isColorType && handleConvertBorderStyle(optionBorder),
|
|
60
72
|
...!isColorType && handleConvertBorderWidth(optionBorder),
|
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.479",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"main": "dist/cjs/index.js",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"update-img-src-3rd": "node ./scripts/update-img-src-3rd.js"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@gem-sdk/core": "2.0.0-dev.
|
|
26
|
+
"@gem-sdk/core": "2.0.0-dev.479",
|
|
27
27
|
"@gem-sdk/styles": "2.0.0-dev.464",
|
|
28
28
|
"@gem-sdk/system": "2.0.0-dev.464",
|
|
29
29
|
"@types/react-transition-group": "^4.4.5"
|