@gem-sdk/components 3.0.8 → 3.0.9

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.
@@ -1 +1 @@
1
- "use strict";var core=require("@gem-sdk/core"),system=require("@gem-sdk/system"),helpers=require("../../../../grid/components/row/common/helpers.js"),helpers$1=require("../../../../carousel/common/helpers.js");const getStyle=e=>{let{setting:t,styles:o,style:r}=e,{background:s}=t??{},[l,a]=core.splitStyle(["pos","top","left","bottom","right","z","mb","mt","mb","ml","d"],r),c=core.makeGlobalSize(o?.itemPadding),i=system.createStyle({...l}),n=system.createStyle({...core.makeStyleResponsive("jc",o?.align||{desktop:"center"})}),d=system.createStyle({...a,...core.makeStyleResponsive("w",helpers.createStyleObject(o?.width).content),...core.getBgByDevice({backgroundColor:o?.backgroundColor,backgroundImage:o?.backgroundImage})}),m=system.createStyle({...!t?.sameHeight&&core.makeStyleResponsive("rg",o?.horizontalGutter),...core.makeStyleResponsive("cg",o?.verticalGutter),...core.makeStyleResponsive("gtc",{desktop:`repeat(${core.getResponsiveValueByScreen(t?.slidesToShow,"desktop")}, minmax(0, 1fr))`,tablet:t?.slidesToShow?.tablet&&`repeat(${core.getResponsiveValueByScreen(t?.slidesToShow,"tablet")}, minmax(0, 1fr))`,mobile:t?.slidesToShow?.mobile&&`repeat(${core.getResponsiveValueByScreen(t?.slidesToShow,"mobile")}, minmax(0, 1fr))`})}),S=system.createStyle({...helpers$1.getInitialWidthForCarouselItem({spacing:o?.spacing,slidesToShow:t?.slidesToShow})}),y={...c&&c.padding,...core.makeStyle({bs:o?.borderContent?.border,bw:o?.borderContent?.width,bc:core.getSingleColorVariable(o?.borderContent?.color)}),...core.getRadiusStyleActiveState({...o?.roundedContent,active:{...o?.roundedContent||{},radiusType:"custom"}}),...core.getStyleShadow({value:o?.carouselShadow,styleAppliedFor:"box-shadow",isEnableShadow:o?.hasActiveShadow}),...core.getStyleBackgroundByDevice(s),...core.getGradientBgrStyleByDevice(s,{desktop:!0,tablet:!0,mobile:!0})},g=system.createStyle({...y});return{gridLayoutStyle:m,carouselItemStyle:S,productListWrapStyle:i,productListContentStyle:d,productListWrapAlignStyle:n,productItemStyle:g}};exports.getStyle=getStyle;
1
+ "use strict";var core=require("@gem-sdk/core"),system=require("@gem-sdk/system"),helpers=require("../../../../grid/components/row/common/helpers.js"),helpers$1=require("../../../../carousel/common/helpers.js");const getStyle=e=>{let{setting:t,styles:o,style:r}=e,{background:s}=t??{},[l,a]=core.splitStyle(["pos","top","left","bottom","right","z","mb","mt","mb","ml","mr","d"],r),c=core.makeGlobalSize(o?.itemPadding),i=system.createStyle({...l}),n=system.createStyle({...core.makeStyleResponsive("jc",o?.align||{desktop:"center"})}),d=system.createStyle({...a,...core.makeStyleResponsive("w",helpers.createStyleObject(o?.width).content),...core.getBgByDevice({backgroundColor:o?.backgroundColor,backgroundImage:o?.backgroundImage})}),m=system.createStyle({...!t?.sameHeight&&core.makeStyleResponsive("rg",o?.horizontalGutter),...core.makeStyleResponsive("cg",o?.verticalGutter),...core.makeStyleResponsive("gtc",{desktop:`repeat(${core.getResponsiveValueByScreen(t?.slidesToShow,"desktop")}, minmax(0, 1fr))`,tablet:t?.slidesToShow?.tablet&&`repeat(${core.getResponsiveValueByScreen(t?.slidesToShow,"tablet")}, minmax(0, 1fr))`,mobile:t?.slidesToShow?.mobile&&`repeat(${core.getResponsiveValueByScreen(t?.slidesToShow,"mobile")}, minmax(0, 1fr))`})}),S=system.createStyle({...helpers$1.getInitialWidthForCarouselItem({spacing:o?.spacing,slidesToShow:t?.slidesToShow})}),y={...c&&c.padding,...core.makeStyle({bs:o?.borderContent?.border,bw:o?.borderContent?.width,bc:core.getSingleColorVariable(o?.borderContent?.color)}),...core.getRadiusStyleActiveState({...o?.roundedContent,active:{...o?.roundedContent||{},radiusType:"custom"}}),...core.getStyleShadow({value:o?.carouselShadow,styleAppliedFor:"box-shadow",isEnableShadow:o?.hasActiveShadow}),...core.getStyleBackgroundByDevice(s),...core.getGradientBgrStyleByDevice(s,{desktop:!0,tablet:!0,mobile:!0})},g=system.createStyle({...y});return{gridLayoutStyle:m,carouselItemStyle:S,productListWrapStyle:i,productListContentStyle:d,productListWrapAlignStyle:n,productItemStyle:g}};exports.getStyle=getStyle;
@@ -1 +1 @@
1
- import{splitStyle as o,makeGlobalSize as e,makeStyleResponsive as t,getBgByDevice as r,getResponsiveValueByScreen as s,makeStyle as d,getSingleColorVariable as i,getRadiusStyleActiveState as m,getStyleShadow as a,getStyleBackgroundByDevice as l,getGradientBgrStyleByDevice as n}from"@gem-sdk/core";import{createStyle as b}from"@gem-sdk/system";import{createStyleObject as c}from"../../../../grid/components/row/common/helpers.js";import{getInitialWidthForCarouselItem as p}from"../../../../carousel/common/helpers.js";let getStyle=g=>{let{setting:h,styles:w,style:u}=g,{background:S}=h??{},[k,f]=o(["pos","top","left","bottom","right","z","mb","mt","mb","ml","d"],u),T=e(w?.itemPadding),C=b({...k}),x=b({...t("jc",w?.align||{desktop:"center"})}),y=b({...f,...t("w",c(w?.width).content),...r({backgroundColor:w?.backgroundColor,backgroundImage:w?.backgroundImage})}),v=b({...!h?.sameHeight&&t("rg",w?.horizontalGutter),...t("cg",w?.verticalGutter),...t("gtc",{desktop:`repeat(${s(h?.slidesToShow,"desktop")}, minmax(0, 1fr))`,tablet:h?.slidesToShow?.tablet&&`repeat(${s(h?.slidesToShow,"tablet")}, minmax(0, 1fr))`,mobile:h?.slidesToShow?.mobile&&`repeat(${s(h?.slidesToShow,"mobile")}, minmax(0, 1fr))`})}),j=b({...p({spacing:w?.spacing,slidesToShow:h?.slidesToShow})}),$={...T&&T.padding,...d({bs:w?.borderContent?.border,bw:w?.borderContent?.width,bc:i(w?.borderContent?.color)}),...m({...w?.roundedContent,active:{...w?.roundedContent||{},radiusType:"custom"}}),...a({value:w?.carouselShadow,styleAppliedFor:"box-shadow",isEnableShadow:w?.hasActiveShadow}),...l(S),...n(S,{desktop:!0,tablet:!0,mobile:!0})},z=b({...$});return{gridLayoutStyle:v,carouselItemStyle:j,productListWrapStyle:C,productListContentStyle:y,productListWrapAlignStyle:x,productItemStyle:z}};export{getStyle};
1
+ import{splitStyle as o,makeGlobalSize as e,makeStyleResponsive as t,getBgByDevice as r,getResponsiveValueByScreen as s,makeStyle as d,getSingleColorVariable as m,getRadiusStyleActiveState as i,getStyleShadow as a,getStyleBackgroundByDevice as l,getGradientBgrStyleByDevice as n}from"@gem-sdk/core";import{createStyle as b}from"@gem-sdk/system";import{createStyleObject as c}from"../../../../grid/components/row/common/helpers.js";import{getInitialWidthForCarouselItem as p}from"../../../../carousel/common/helpers.js";let getStyle=g=>{let{setting:h,styles:w,style:u}=g,{background:S}=h??{},[k,f]=o(["pos","top","left","bottom","right","z","mb","mt","mb","ml","mr","d"],u),T=e(w?.itemPadding),C=b({...k}),x=b({...t("jc",w?.align||{desktop:"center"})}),y=b({...f,...t("w",c(w?.width).content),...r({backgroundColor:w?.backgroundColor,backgroundImage:w?.backgroundImage})}),v=b({...!h?.sameHeight&&t("rg",w?.horizontalGutter),...t("cg",w?.verticalGutter),...t("gtc",{desktop:`repeat(${s(h?.slidesToShow,"desktop")}, minmax(0, 1fr))`,tablet:h?.slidesToShow?.tablet&&`repeat(${s(h?.slidesToShow,"tablet")}, minmax(0, 1fr))`,mobile:h?.slidesToShow?.mobile&&`repeat(${s(h?.slidesToShow,"mobile")}, minmax(0, 1fr))`})}),j=b({...p({spacing:w?.spacing,slidesToShow:h?.slidesToShow})}),$={...T&&T.padding,...d({bs:w?.borderContent?.border,bw:w?.borderContent?.width,bc:m(w?.borderContent?.color)}),...i({...w?.roundedContent,active:{...w?.roundedContent||{},radiusType:"custom"}}),...a({value:w?.carouselShadow,styleAppliedFor:"box-shadow",isEnableShadow:w?.hasActiveShadow}),...l(S),...n(S,{desktop:!0,tablet:!0,mobile:!0})},z=b({...$});return{gridLayoutStyle:v,carouselItemStyle:j,productListWrapStyle:C,productListContentStyle:y,productListWrapAlignStyle:x,productItemStyle:z}};export{getStyle};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gem-sdk/components",
3
- "version": "3.0.8",
3
+ "version": "3.0.9",
4
4
  "license": "MIT",
5
5
  "sideEffects": false,
6
6
  "main": "dist/cjs/index.js",