@gem-sdk/components 2.0.0-staging.867 → 2.0.0-staging.869

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";Object.defineProperty(exports,"__esModule",{value:!0});const FormEmailSettings=[{id:"setting",controls:[{id:"placeholder",type:"input",label:"Placeholder",default:"Enter your email address"},{id:"placeholderColor",type:"color-picker-v2",label:"Color",default:"#A3A3A3"},{id:"translate",type:"input",default:"placeholder"},{id:"required",type:"toggle",label:"Placeholder",default:!0},{id:"hideOnClient",type:"toggle",label:"Hide on client",default:!1},{id:"defaultEmail",type:"input",label:"Default value",default:"default@gempages.help"},{id:"typo",label:"Text styles",type:"typography-v2",default:{type:"paragraph-1"},hiddenSetting:{color:!0,textAlign:!0,textShadow:!0},ignoreReRender:!0},{id:"size",label:"Field size",type:"size",default:{type:"medium"},ignoreReRender:!0},{id:"fullWidth",label:"Full Width",type:"toggle",devices:{desktop:{default:!0},tablet:{default:!0},mobile:{default:!0}}},{id:"width",type:"input:unit",label:"Width",placeholder:"Auto Width",min:0,units:["px","%"],hide:!0,devices:{desktop:{default:"100%"}}},{id:"background",type:"background-media",ignoreReRender:!0,hideImage:!0,devices:{desktop:{default:{type:"color",color:"#FFFFFF"}}},compoDefaultValue:{desktop:{default:{type:"color",color:"#FFFFFF"}}}},{id:"align",label:"Alignment",type:"option:value",options:[{label:"Left",value:"left",type:"align",tooltip:"Align left",iconName:"gp-align-left"},{label:"Center",value:"center",type:"align",tooltip:"Align center",iconName:"gp-align-center"},{label:"Right",value:"right",type:"align",tooltip:"Align right",iconName:"gp-align-right"}],devices:{desktop:{default:"left"}}}]},{id:"style",controls:[{id:"globalSize",type:"size-setting",devices:{desktop:{default:{width:"100%",height:"Auto",padding:{type:"medium",top:"12px",bottom:"12px",left:"12px",right:"12px"}}}},settingConfig:{width:{},height:{displayOptions:["auto","small","large","medium"],sizeConfig:{small:"28px",medium:"36px",large:"44px"}}},hiddenSettings:["shape","gap"]},{id:"wrapperBorder",type:"border-v2",label:"Border",default:{border:"solid",width:"1px 1px 1px 1px",position:"all",borderWidth:"1px",color:"#7D7D7D",isCustom:!0}},{id:"backgroundColorV2Hover",type:"color-picker-v2",enableGradient:!0},{id:"textColorHover",type:"color-picker-v2",label:"Text Color",state:{hover:!0}},{id:"borderEmailHover",type:"border",emptyOnClear:!0,state:{hover:!0}},{id:"roundedEmailHover",type:"radius-preset",default:{hover:{radiusType:"small"}},state:{hover:!0}},{id:"boxShadowEmailHover",type:"shadow-v2",label:"Button Shadow",hideOnState:{hover:!0},default:{hover:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},state:{hover:!0}},{id:"backgroundColorV2Active",type:"color-picker-v2",enableGradient:!0},{id:"textColorActive",type:"color-picker-v2",label:"Text Color",state:{active:!0}},{id:"borderEmailActive",type:"border",emptyOnClear:!0,state:{active:!0}},{id:"roundedEmailActive",type:"radius-preset",default:{active:{radiusType:"small"}},state:{active:!0}},{id:"boxShadowEmailActive",type:"shadow-v2",label:"Button Shadow",hideOnState:{active:!0},default:{active:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},state:{active:!0}}]}];exports.default=FormEmailSettings;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const FormEmailSettings=[{id:"setting",controls:[{id:"placeholder",type:"textarea",minHeight:56,label:"Placeholder",default:"Enter your email address"},{id:"placeholderColor",type:"color-picker-v2",label:"Color",default:"#A3A3A3"},{id:"translate",type:"input",default:"placeholder"},{id:"required",type:"toggle",label:"Placeholder",default:!0},{id:"hideOnClient",type:"toggle",label:"Hide on client",default:!1},{id:"defaultEmail",type:"input",label:"Default value",default:"default@gempages.help"},{id:"typo",label:"Text styles",type:"typography-v2",default:{type:"paragraph-1"},hiddenSetting:{color:!0,textAlign:!0,textShadow:!0},ignoreReRender:!0},{id:"size",label:"Field size",type:"size",default:{type:"medium"},ignoreReRender:!0},{id:"fullWidth",label:"Full Width",type:"toggle",devices:{desktop:{default:!0},tablet:{default:!0},mobile:{default:!0}}},{id:"width",type:"input:unit",label:"Width",placeholder:"Auto Width",min:0,units:["px","%"],hide:!0,devices:{desktop:{default:"100%"}}},{id:"background",type:"background-media",ignoreReRender:!0,hideImage:!0,devices:{desktop:{default:{type:"color",color:"#FFFFFF"}}},compoDefaultValue:{desktop:{default:{type:"color",color:"#FFFFFF"}}}},{id:"align",label:"Alignment",type:"option:value",options:[{label:"Left",value:"left",type:"align",tooltip:"Align left",iconName:"gp-align-left"},{label:"Center",value:"center",type:"align",tooltip:"Align center",iconName:"gp-align-center"},{label:"Right",value:"right",type:"align",tooltip:"Align right",iconName:"gp-align-right"}],devices:{desktop:{default:"left"}}}]},{id:"style",controls:[{id:"globalSize",type:"size-setting",devices:{desktop:{default:{width:"100%",height:"Auto",padding:{type:"medium",top:"12px",bottom:"12px",left:"12px",right:"12px"}}}},settingConfig:{width:{},height:{displayOptions:["auto","small","large","medium"],sizeConfig:{small:"28px",medium:"36px",large:"44px"}}},hiddenSettings:["shape","gap"]},{id:"wrapperBorder",type:"border-v2",label:"Border",default:{border:"solid",width:"1px 1px 1px 1px",position:"all",borderWidth:"1px",color:"#7D7D7D",isCustom:!0}},{id:"backgroundColorV2Hover",type:"color-picker-v2",enableGradient:!0},{id:"textColorHover",type:"color-picker-v2",label:"Text Color",state:{hover:!0}},{id:"borderEmailHover",type:"border",emptyOnClear:!0,state:{hover:!0}},{id:"roundedEmailHover",type:"radius-preset",default:{hover:{radiusType:"small"}},state:{hover:!0}},{id:"boxShadowEmailHover",type:"shadow-v2",label:"Button Shadow",hideOnState:{hover:!0},default:{hover:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},state:{hover:!0}},{id:"backgroundColorV2Active",type:"color-picker-v2",enableGradient:!0},{id:"textColorActive",type:"color-picker-v2",label:"Text Color",state:{active:!0}},{id:"borderEmailActive",type:"border",emptyOnClear:!0,state:{active:!0}},{id:"roundedEmailActive",type:"radius-preset",default:{active:{radiusType:"small"}},state:{active:!0}},{id:"boxShadowEmailActive",type:"shadow-v2",label:"Button Shadow",hideOnState:{active:!0},default:{active:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},state:{active:!0}}]}];exports.default=FormEmailSettings;
@@ -1,7 +1,7 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const config={tag:"Input",label:"Input",icon:`
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var settings=require("./configs/settings.js");const config={tag:"Input",label:"Input",icon:`
2
2
  <svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
3
3
  <path d="M38.1665 16.2397C38.4426 16.2397 38.6665 16.4636 38.6665 16.7397V30.3155C38.6665 30.5916 38.4426 30.8155 38.1665 30.8155H6.37109C6.09495 30.8155 5.87109 30.5916 5.87109 30.3155V22.813C5.87109 22.5368 6.09495 22.313 6.37109 22.313H7.80038C8.07653 22.313 8.30038 22.5368 8.30038 22.813V28.3862H36.2372V18.669H23.3761C23.1 18.669 22.8761 18.4452 22.8761 18.169V16.7397C22.8761 16.4636 23.1 16.2397 23.3761 16.2397H38.1665Z" fill="currentColor"/>
4
4
  <path d="M7.93505 16.9528H4.0383L3.51131 18.4447C3.44072 18.6446 3.2518 18.7782 3.03986 18.7782H1.69097C1.51719 18.7782 1.39642 18.6053 1.45626 18.4421L4.73106 9.51242C4.80328 9.31549 4.99074 9.18457 5.20049 9.18457H6.78688C6.99663 9.18457 7.18408 9.31549 7.2563 9.51242L10.5311 18.4421C10.5909 18.6053 10.4702 18.7782 10.2964 18.7782H8.93349C8.72155 18.7782 8.53263 18.6446 8.46204 18.4447L7.93505 16.9528ZM7.4024 15.4156L5.98667 11.408L4.57095 15.4156H7.4024Z" fill="currentColor"/>
5
5
  <path d="M11.4648 14.949C11.4648 14.1804 11.619 13.4987 11.9274 12.904C12.2451 12.3092 12.6703 11.8518 13.2029 11.5315C13.7449 11.2113 14.3477 11.0511 15.0111 11.0511C15.5905 11.0511 16.0951 11.1655 16.525 11.3943C16.9642 11.623 17.3146 11.9112 17.5763 12.2589V11.6747C17.5763 11.3985 17.8001 11.1747 18.0763 11.1747H19.0527C19.3288 11.1747 19.5527 11.3985 19.5527 11.6747V18.2782C19.5527 18.5543 19.3288 18.7782 19.0527 18.7782H18.0763C17.8001 18.7782 17.5763 18.5543 17.5763 18.2782V17.6665C17.324 18.0233 16.9735 18.3207 16.525 18.5586C16.0858 18.7874 15.5765 18.9017 14.9971 18.9017C14.343 18.9017 13.7449 18.737 13.2029 18.4076C12.6703 18.0782 12.2451 17.6162 11.9274 17.0214C11.619 16.4175 11.4648 15.7267 11.4648 14.949ZM17.5763 14.9764C17.5763 14.5098 17.4828 14.1118 17.2959 13.7824C17.109 13.4438 16.8567 13.1876 16.539 13.0138C16.2213 12.8308 15.8802 12.7393 15.5158 12.7393C15.1513 12.7393 14.8149 12.8262 14.5065 13.0001C14.1982 13.1739 13.9458 13.4301 13.7496 13.7687C13.5627 14.098 13.4693 14.4915 13.4693 14.949C13.4693 15.4065 13.5627 15.8091 13.7496 16.1568C13.9458 16.4953 14.1982 16.7561 14.5065 16.9391C14.8243 17.1221 15.1607 17.2136 15.5158 17.2136C15.8802 17.2136 16.2213 17.1267 16.539 16.9528C16.8567 16.7698 17.109 16.5136 17.2959 16.1842C17.4828 15.8457 17.5763 15.4431 17.5763 14.9764Z" fill="currentColor"/>
6
6
  </svg>
7
- `,settings:[{id:"setting",controls:[{id:"type",type:"select",label:"Select Type Input",options:[{label:"Text",value:"text"},{label:"Number",value:"number"},{label:"Password",value:"password"},{label:"Email",value:"email"},{label:"Hidden",value:"hidden"},{label:"Search",value:"search"},{label:"Tel",value:"tel"},{label:"Url",value:"url"}],default:"text"},{id:"defaultValue",type:"input",label:"Default Value",default:"",datalist:[{value:"suggest 1"},{value:"suggest 2"}]},{id:"placeholder",type:"input",label:"Placeholder",default:"Enter your text data"},{id:"disabled",type:"toggle",label:"Disabled",default:!1},{id:"prefix",type:"input",label:"prefix",info:"This is prefix icon",default:""},{id:"suffix",type:"input",label:"suffix",info:"This is suffix icon",default:""},{id:"allowClear",type:"toggle",label:"AllowClear",default:!1},{id:"passwordToggle",type:"toggle",label:"Password Toggle",default:!1},{id:"required",type:"toggle",label:"Required",default:!1}]},{id:"style",controls:[]}]};exports.default=config;
7
+ `,settings:settings.InputSettings};exports.default=config;
@@ -0,0 +1 @@
1
+ "use strict";const InputSettings=[{id:"setting",controls:[{id:"type",type:"select",label:"Select Type Input",options:[{label:"Text",value:"text"},{label:"Number",value:"number"},{label:"Password",value:"password"},{label:"Email",value:"email"},{label:"Hidden",value:"hidden"},{label:"Search",value:"search"},{label:"Tel",value:"tel"},{label:"Url",value:"url"}],default:"text"},{id:"defaultValue",type:"input",label:"Default Value",default:"",datalist:[{value:"suggest 1"},{value:"suggest 2"}]},{id:"placeholder",type:"input",label:"Placeholder",default:"Enter your text data"},{id:"disabled",type:"toggle",label:"Disabled",default:!1},{id:"prefix",type:"input",label:"prefix",info:"This is prefix icon",default:""},{id:"suffix",type:"input",label:"suffix",info:"This is suffix icon",default:""},{id:"allowClear",type:"toggle",label:"AllowClear",default:!1},{id:"passwordToggle",type:"toggle",label:"Password Toggle",default:!1},{id:"required",type:"toggle",label:"Required",default:!1}]},{id:"style",controls:[]}];exports.InputSettings=InputSettings;
@@ -1,2 +1,2 @@
1
- "use strict";var core=require("@gem-sdk/core");const getWrapperClass=e=>{let{typeOfOption:r,optionTypo:o,optionTypography:p,variantKey:t,soldOutMarkLine:s,available:l}=e,g="color"===r,a=`${core.composeTypographyClassName(o,p)}`,c=core.cls({...t&&{[t]:!0},[a]:!0,"gp-p-[4px]":g,"before:gp-absolute before:gp-top-[50%] before:gp-z-1 before:gp-block before:gp-w-full before:-gp-rotate-45 before:gp-border-t before:gp-border-[#A1A1A1] before:gp-bg-[#333]":s&&!l&&!g}),f=`gp-relative gp-flex gp-cursor-pointer gp-items-center gp-justify-center gp-text-center option-value-wrapper gp-overflow-hidden gp-w-full gp-h-full data-[disabled='disabled']:gp-pointer-events-none data-[disabled='disabled']:!gp-cursor-not-allowed
2
- data-[hidden='false']:gp-flex`,i=`${f} ${c}`.trim();return core.composeClasses(i)},getWrapperTextClass=e=>{let r=core.cls({"gp-flex gp-flex-col gp-justify-center gp-items-center gp-gap-[6px":e}),o=`option-value gp-overflow-hidden gp-relative ${r}`.trim();return core.composeClasses(o)},getTextClass=({optionTypo:e,optionTypography:r,isColorType:o,isUploadImageType:p})=>{let t=`${core.composeTypographyClassName(e,r)}`,s=core.cls({"gp-text-center":!0,[t]:!0,"gp-overflow-hidden gp-text-ellipsis gp-px-1":o||p}),l=`${s}`.trim();return core.composeClasses(l)},getColorClass=({soldOutMarkLine:e,available:r})=>{let o=core.cls({"before:gp-absolute before:gp-top-[50%] before:gp-block before:gp-w-full before:gp--rotate-45 before:gp-border":e&&!r}),p=`color gp-relative gp-h-full gp-w-full gp-overflow-hidden gp-min-w-fit gp-flex gp-color-circle ${o}`.trim();return core.composeClasses(p)};exports.getColorClass=getColorClass,exports.getTextClass=getTextClass,exports.getWrapperClass=getWrapperClass,exports.getWrapperTextClass=getWrapperTextClass;
1
+ "use strict";var core=require("@gem-sdk/core");const getWrapperClass=e=>{let{typeOfOption:r,optionTypo:p,optionTypography:o,variantKey:l,soldOutMarkLine:t,available:s}=e,g="color"===r,a=`${core.composeTypographyClassName(p,o)}`,c=core.cls({...l&&{[l]:!0},[a]:!0,"gp-p-[4px]":g,"before:gp-absolute before:gp-top-[50%] before:gp-z-1 before:gp-block before:gp-w-full before:-gp-rotate-45 before:gp-border-t before:gp-border-[#A1A1A1] before:gp-bg-[#333]":t&&!s&&!g}),f=`gp-relative gp-flex gp-cursor-pointer gp-items-center gp-justify-center gp-text-center option-value-wrapper gp-overflow-hidden gp-w-full gp-h-full data-[disabled='disabled']:gp-pointer-events-none data-[disabled='disabled']:!gp-cursor-not-allowed
2
+ data-[hidden='false']:gp-flex`,i=`${f} ${c}`.trim();return core.composeClasses(i)},getWrapperTextClass=(e,r)=>{let p=core.cls({"color gp-line-clamp-2 gp-flex gp-h-full gp-w-full gp-items-center gp-justify-center":r,"gp-flex gp-flex-col gp-justify-center gp-items-center gp-gap-[6px":e}),o=`option-value gp-overflow-hidden gp-relative ${p}`.trim();return core.composeClasses(o)},getTextClass=({optionTypo:e,optionTypography:r,isColorType:p,isUploadImageType:o})=>{let l=`${core.composeTypographyClassName(e,r)}`,t=core.cls({"gp-text-center":!0,[l]:!0,"gp-overflow-hidden gp-text-ellipsis gp-px-1":p||o}),s=`${t}`.trim();return core.composeClasses(s)},getColorClass=({soldOutMarkLine:e,available:r})=>{let p=core.cls({"before:gp-absolute before:gp-top-[50%] before:gp-block before:gp-w-full before:gp--rotate-45 before:gp-border":e&&!r}),o=`color gp-relative gp-h-full gp-w-full gp-overflow-hidden gp-min-w-fit gp-flex gp-color-circle ${p}`.trim();return core.composeClasses(o)};exports.getColorClass=getColorClass,exports.getTextClass=getTextClass,exports.getWrapperClass=getWrapperClass,exports.getWrapperTextClass=getWrapperTextClass;
@@ -1 +1 @@
1
- "use strict";var core=require("@gem-sdk/core"),helpers=require("../../../../../helpers.js");const getWrapperStyleActive=e=>{let{preset:t,optionTypography:o,optionTypo:r,typeOfOption:l}=e,a=t?.optionBgColor,p=t?.optionTextColor,i=t?.optionBorder,c=t?.optionHasShadow,d=t?.optionShadow,h=t?.optionRounded,n="color"===l,g="image"===l||"image_shopify"===l,s=core.composeTypographyStyle(r,o),y=e=>core.makeStyle({bg:e&&core.getSingleColorVariable(a?.active??a?.normal),bs:i?.active?.border,bw:i?.active?.width,bc:core.getSingleColorVariable(i?.active?.color)});return helpers.filterTruthyObject({...y(!n),...core.getRadiusStyleActiveState(h),...core.getStyleShadow({value:d?.active,state:"active",styleAppliedFor:"box-shadow",isEnableShadow:c?.active},!0),...s,...!n&&!g&&core.makeStyle({c:core.getSingleColorVariable(p?.active??p?.normal)}),...core.makeStyle({h:t?.height})})},getWrapperStyleNormalAndHover=e=>{let{preset:t,optionTransform:o,optionTypography:r,optionTypo:l,typeOfOption:a}=e,p=t?.optionBgColor,i=t?.optionTextColor,c=t?.optionBorder,d=t?.optionHasShadow,h=t?.optionShadow,n=t?.optionRounded,g="color"===a,s="image"===a||"image_shopify"===a,y=core.composeTypographyStyle(l,r),S=["normal","hover"].reduce((e,t)=>({...e,...core.getStyleShadow({value:h?.[t],state:t,styleAppliedFor:"box-shadow",isEnableShadow:d?.[t]})}),{});return helpers.filterTruthyObject({...core.composeRadius(n),...S,...!g&&core.getGlobalColorStateStyle("bg",p),...!g&&core.handleConvertBorderStyle(c),...!g&&core.handleConvertBorderWidth(c),...!g&&core.handleConvertBorderColor(c),...!g&&!s&&core.makeStyle({c:o}),...!g&&!s&&core.getGlobalColorStateStyle("c",i),...y,...core.makeStyle({h:t?.height})})},getWrapperTextStyle=e=>{let{preset:t,typeOfOption:o}=e,r="color"===o,l=()=>{let e="16px",o={"--pl":"0px","--pr":"0px","--pl-tablet":"0px","--pr-tablet":"0px","--pl-mobile":"0px","--pr-mobile":"0px","--pt":"0px","--pb":"0px"};return t?.width?.desktop?.toLowerCase()!=="auto"&&t?.width?.desktop||(o["--pl"]=e,o["--pr"]=e),t?.width?.tablet?.toLowerCase()!=="auto"&&t?.width?.tablet||(o["--pl-tablet"]=e,o["--pr-tablet"]=e),t?.width?.mobile?.toLowerCase()!=="auto"&&t?.width?.mobile||(o["--pl-mobile"]=e,o["--pr-mobile"]=e),(t?.height?.toLowerCase()==="auto"||t?.height)&&(o["--pt"]="8px",o["--pb"]="8px"),o};return helpers.filterTruthyObject({...r?{}:l()})},getColorStyle=({optionBorder:e,optionRounded:t,isActive:o,color:r})=>{let l=()=>r?r?.startsWith("linear-gradient")?{backgroundImage:r}:{backgroundColor:r}:{},a=o=>({"--d":"flex","--jc":"center"," --ai":"center","--w":"100%","--h":"100%","--of":"hidden","--bs":o?"none":"solid",...core.handleConvertBorderWidth(e),...core.handleConvertBorderColor(e),...core.composeRadius(t),...l()});return a(!!o)},getTextStyle=({optionTypo:e,optionTypography:t})=>{let o=core.composeTypographyStyle(e,t);return delete o["--c"],helpers.filterTruthyObject({...o})};exports.getColorStyle=getColorStyle,exports.getTextStyle=getTextStyle,exports.getWrapperStyleActive=getWrapperStyleActive,exports.getWrapperStyleNormalAndHover=getWrapperStyleNormalAndHover,exports.getWrapperTextStyle=getWrapperTextStyle;
1
+ "use strict";var core=require("@gem-sdk/core"),helpers=require("../../../../../helpers.js");const getWrapperStyleActive=e=>{let{preset:o,optionTypography:t,optionTypo:r,typeOfOption:l}=e,a=o?.optionBgColor,p=o?.optionTextColor,i=o?.optionBorder,c=o?.optionHasShadow,d=o?.optionShadow,n=o?.optionRounded,h="color"===l,s="image"===l||"image_shopify"===l,g=core.composeTypographyStyle(r,t),y=e=>core.makeStyle({bg:e&&core.getSingleColorVariable(a?.active??a?.normal),bs:i?.active?.border,bw:i?.active?.width,bc:core.getSingleColorVariable(i?.active?.color)});return helpers.filterTruthyObject({...y(!h),...core.getRadiusStyleActiveState(n),...core.getStyleShadow({value:d?.active,state:"active",styleAppliedFor:"box-shadow",isEnableShadow:c?.active},!0),...g,...!h&&!s&&core.makeStyle({c:core.getSingleColorVariable(p?.active??p?.normal)}),...core.makeStyle({h:o?.height})})},getWrapperStyleNormalAndHover=e=>{let{preset:o,optionTransform:t,optionTypography:r,optionTypo:l,typeOfOption:a}=e,p=o?.optionBgColor,i=o?.optionTextColor,c=o?.optionBorder,d=o?.optionHasShadow,n=o?.optionShadow,h=o?.optionRounded,s="color"===a,g="image"===a||"image_shopify"===a,y=core.composeTypographyStyle(l,r),S=["normal","hover"].reduce((e,o)=>({...e,...core.getStyleShadow({value:n?.[o],state:o,styleAppliedFor:"box-shadow",isEnableShadow:d?.[o]})}),{});return helpers.filterTruthyObject({...core.composeRadius(h),...S,...!s&&core.getGlobalColorStateStyle("bg",p),...!s&&core.handleConvertBorderStyle(c),...!s&&core.handleConvertBorderWidth(c),...!s&&core.handleConvertBorderColor(c),...!s&&!g&&core.makeStyle({c:t}),...!s&&!g&&core.getGlobalColorStateStyle("c",i),...y,...core.makeStyle({h:o?.height})})},getWrapperTextStyle=e=>{let{preset:o,typeOfOption:t,checked:r}=e,l=o?.optionBorder,a=o?.optionRounded,p="color"===t,i=()=>{let e="16px",t={"--pl":"0px","--pr":"0px","--pl-tablet":"0px","--pr-tablet":"0px","--pl-mobile":"0px","--pr-mobile":"0px","--pt":"0px","--pb":"0px"};return o?.width?.desktop?.toLowerCase()!=="auto"&&o?.width?.desktop||(t["--pl"]=e,t["--pr"]=e),o?.width?.tablet?.toLowerCase()!=="auto"&&o?.width?.tablet||(t["--pl-tablet"]=e,t["--pr-tablet"]=e),o?.width?.mobile?.toLowerCase()!=="auto"&&o?.width?.mobile||(t["--pl-mobile"]=e,t["--pr-mobile"]=e),(o?.height?.toLowerCase()==="auto"||o?.height)&&(t["--pt"]="8px",t["--pb"]="8px"),t},c={...a,active:{...a?.active||{},radiusType:"custom"}},d=r?core.getRadiusStyleActiveState(c):core.composeRadius(a),n=!r&&p?{...core.handleConvertBorderStyle(l),...core.handleConvertBorderWidth(l),...core.handleConvertBorderColor(l)}:{};return helpers.filterTruthyObject({...!p&&i(),...p&&d,...n})},getColorStyle=({optionBorder:e,optionRounded:o,isActive:t,color:r})=>{let l=()=>r?r?.startsWith("linear-gradient")?{backgroundImage:r}:{backgroundColor:r}:{},a=t=>({"--d":"flex","--jc":"center"," --ai":"center","--w":"100%","--h":"100%","--of":"hidden","--bs":t?"none":"solid",...core.handleConvertBorderWidth(e),...core.handleConvertBorderColor(e),...core.composeRadius(o),...l()});return a(!!t)},getTextStyle=({optionTypo:e,optionTypography:o})=>{let t=core.composeTypographyStyle(e,o);return delete t["--c"],helpers.filterTruthyObject({...t})};exports.getColorStyle=getColorStyle,exports.getTextStyle=getTextStyle,exports.getWrapperStyleActive=getWrapperStyleActive,exports.getWrapperStyleNormalAndHover=getWrapperStyleNormalAndHover,exports.getWrapperTextStyle=getWrapperTextStyle;
@@ -8,4 +8,4 @@
8
8
  .${n} .color:before {
9
9
  border-color: ${C(s)} !important;
10
10
  }
11
- `}),jsxRuntime.jsx("div",{className:h,style:a},e)]},e)})}),v=system.createClass(classes.getWrapperTextClass(p)),b=system.createStyle(styles.getWrapperTextStyle(e)),S=system.createClass(classes.getTextClass({optionTypo:a,optionTypography:r,isColorType:x,isUploadImageType:p})),w=system.createStyle(styles.getTextStyle({optionTypo:a,optionTypography:r})),D=()=>jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsxs("div",{className:v,style:b,children:[f(),system.If(p,jsxRuntime.jsxs("svg",{width:"15",height:"12",viewBox:"0 0 15 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsxRuntime.jsx("circle",{cx:"2",cy:"2",r:"2",fill:"#D6D6D6"}),jsxRuntime.jsx("path",{d:"M0.196854 10.6453L2.40968 8.05946C2.4846 7.97175 2.57719 7.9008 2.68141 7.85124C2.78562 7.80168 2.89913 7.77461 3.01452 7.77181C3.12991 7.76902 3.2446 7.79055 3.3511 7.835C3.45761 7.87945 3.55353 7.94583 3.63262 8.02981L4.66733 9.12714L8.71205 4.29464C8.79123 4.19995 8.89077 4.1243 9.00325 4.07333C9.11573 4.02236 9.23827 3.99737 9.36176 4.00022C9.48524 4.00307 9.6065 4.03369 9.71651 4.08979C9.82651 4.1459 9.92245 4.22605 9.99717 4.32429L14.8329 10.6772C14.9254 10.7989 14.982 10.9441 14.9964 11.0962C15.0107 11.2484 14.9823 11.4016 14.9144 11.5385C14.8464 11.6754 14.7415 11.7907 14.6115 11.8713C14.4815 11.952 14.3316 11.9948 14.1786 11.995L0.822048 12C0.664945 11.9999 0.511148 11.9549 0.378853 11.8703C0.246557 11.7857 0.141299 11.6649 0.0755311 11.5224C0.00976323 11.3799 -0.013762 11.2216 0.00773837 11.0661C0.0292388 10.9107 0.0948652 10.7646 0.196854 10.6453Z",fill:"#D6D6D6"})]})),jsxRuntime.jsx("span",{className:S,style:w,children:s?.label})]})}),q=()=>jsxRuntime.jsx("img",{className:"gp-h-full gp-w-full gp-object-cover",src:l,alt:""}),A=()=>{switch(i){case"color":return system.If(m&&m.length>0,R(),D());case"image":case"image_shopify":return system.If(!!l,q(),D());default:return D()}},W=system.createClass(classes.getWrapperClass(e)),N=system.createAttr(attrs.getWrapperAttr(e)),$=system.createStyle(styles.getWrapperStyleActive(e)),k=system.createStyle(styles.getWrapperStyleNormalAndHover(e)),B=t?$:k;return jsxRuntime.jsxs("div",{...N,className:W,style:B,children:[f(),A()]})};exports.default=BaseVariant;
11
+ `}),jsxRuntime.jsx("div",{className:h,style:a},e)]},e)})}),v=system.createClass(classes.getWrapperTextClass(p,x)),b=system.createStyle(styles.getWrapperTextStyle(e)),S=system.createClass(classes.getTextClass({optionTypo:a,optionTypography:r,isColorType:x,isUploadImageType:p})),w=system.createStyle(styles.getTextStyle({optionTypo:a,optionTypography:r})),D=()=>jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsxs("div",{className:v,style:b,children:[f(),system.If(p,jsxRuntime.jsxs("svg",{width:"15",height:"12",viewBox:"0 0 15 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsxRuntime.jsx("circle",{cx:"2",cy:"2",r:"2",fill:"#D6D6D6"}),jsxRuntime.jsx("path",{d:"M0.196854 10.6453L2.40968 8.05946C2.4846 7.97175 2.57719 7.9008 2.68141 7.85124C2.78562 7.80168 2.89913 7.77461 3.01452 7.77181C3.12991 7.76902 3.2446 7.79055 3.3511 7.835C3.45761 7.87945 3.55353 7.94583 3.63262 8.02981L4.66733 9.12714L8.71205 4.29464C8.79123 4.19995 8.89077 4.1243 9.00325 4.07333C9.11573 4.02236 9.23827 3.99737 9.36176 4.00022C9.48524 4.00307 9.6065 4.03369 9.71651 4.08979C9.82651 4.1459 9.92245 4.22605 9.99717 4.32429L14.8329 10.6772C14.9254 10.7989 14.982 10.9441 14.9964 11.0962C15.0107 11.2484 14.9823 11.4016 14.9144 11.5385C14.8464 11.6754 14.7415 11.7907 14.6115 11.8713C14.4815 11.952 14.3316 11.9948 14.1786 11.995L0.822048 12C0.664945 11.9999 0.511148 11.9549 0.378853 11.8703C0.246557 11.7857 0.141299 11.6649 0.0755311 11.5224C0.00976323 11.3799 -0.013762 11.2216 0.00773837 11.0661C0.0292388 10.9107 0.0948652 10.7646 0.196854 10.6453Z",fill:"#D6D6D6"})]})),jsxRuntime.jsx("span",{className:S,style:w,children:s?.label})]})}),q=()=>jsxRuntime.jsx("img",{className:"gp-h-full gp-w-full gp-object-cover",src:l,alt:""}),A=()=>{switch(i){case"color":return system.If(m&&m.length>0,R(),D());case"image":case"image_shopify":return system.If(!!l,q(),D());default:return D()}},W=system.createClass(classes.getWrapperClass(e)),N=system.createAttr(attrs.getWrapperAttr(e)),$=system.createStyle(styles.getWrapperStyleActive(e)),k=system.createStyle(styles.getWrapperStyleNormalAndHover(e)),B=t?$:k;return jsxRuntime.jsxs("div",{...N,className:W,style:B,children:[f(),A()]})};exports.default=BaseVariant;
@@ -7,7 +7,7 @@
7
7
  data-test="{{ backgroundType }}: {{ color }}"
8
8
  style="{{ backgroundType }}: {{ color }}; ${u()}"></div>
9
9
  `)}
10
- `,n=system.createStyle(styles.getColorStyle({optionBorder:t,optionRounded:l,isActive:!0})),m=system.createStyle(styles.getColorStyle({optionBorder:t,optionRounded:l,isActive:!1})),u=()=>system.LiquidIf("selectedValue == value",_function.getStyleOfObject(n),_function.getStyleOfObject(m)),g=system.createClass(classes.getWrapperTextClass(i)),d=system.createStyle({...styles.getWrapperTextStyle(e)}),p=system.createClass(classes.getTextClass({optionTypo:r,optionTypography:s,isColorType:c,isUploadImageType:i})),C=system.createStyle(styles.getTextStyle({optionTypo:r,optionTypography:s})),f=()=>core.template`
10
+ `,n=system.createStyle(styles.getColorStyle({optionBorder:t,optionRounded:l,isActive:!0})),m=system.createStyle(styles.getColorStyle({optionBorder:t,optionRounded:l,isActive:!1})),u=()=>system.LiquidIf("selectedValue == value",_function.getStyleOfObject(n),_function.getStyleOfObject(m)),g=system.createClass(classes.getWrapperTextClass(i,c)),d=system.createStyle({...styles.getWrapperTextStyle(e)}),p=system.createClass(classes.getTextClass({optionTypo:r,optionTypography:s,isColorType:c,isUploadImageType:i})),C=system.createStyle(styles.getTextStyle({optionTypo:r,optionTypography:s})),f=()=>core.template`
11
11
  <div
12
12
  class="${g}"
13
13
  style="${c?u():""} ${_function.getStyleOfObject(d)}">
@@ -1 +1 @@
1
- "use strict";var core=require("@gem-sdk/core");require("react/jsx-runtime"),require("react");var _const=require("../../common/const.js");const getCSSPosition=t=>"top"==t?"sticky":"fixed",getDisplayStyle=(t,e,l)=>{let o={[`--top${t}`]:"auto",[`--${l+t}`]:"0",[`--pos${t}`]:getCSSPosition(l)};return"after-first-cart-button"===e&&(o[`--d${t}`]="none"),o},displayConditionStyle=(t,e)=>({...getDisplayStyle("",t?.desktop,e?.desktop),...getDisplayStyle("-tablet",t?.tablet??t?.desktop,e?.tablet??e?.desktop),...getDisplayStyle("-mobile",t?.mobile??t?.tablet??t?.desktop,e?.mobile??e?.tablet??e?.desktop)}),getCSSAlignByDevice=(t,e)=>({[`--left${e}`]:"top"==t?"0":"50%",[`--t${e}`]:"top"==t?"unset":"translateX(-50%)"}),getCSSAlign=t=>({...getCSSAlignByDevice(t?.desktop,""),...getCSSAlignByDevice(t?.tablet??t?.desktop,"-tablet"),...getCSSAlignByDevice(t?.mobile??t?.tablet??t?.desktop,"-mobile")}),getContainerStyles=t=>{let{position:e,display:l,width:o}=t;return{margin:"0 auto",...core.makeStyleResponsive("w",o),...getCSSAlign(e),...displayConditionStyle(l,e),"z-index":_const.ELEMENT_Z_INDEX.STICKY}},getContentStyles=t=>{let{style:e,background:l}=t;return{...core.makeStyle({m:"0 auto"}),...getStylePadding(e),...filterStyles(e),...core.getStyleBackgroundByDevice(l),...core.getGradientBgrStyleByDevice(l)}},getStylePadding=t=>{let e=["--pt","--pb","--pr","--pl","--pt-mobile","--pb-mobile","--pr-mobile","--pl-mobile","--pt-tablet","--pb-tablet","--pr-tablet","--pl-tablet"],l={};return e.forEach(e=>{t?.[e]&&(l[e]=t[e])}),l},filterStyles=t=>{let e={...t},l=["--pt","--pb","--pr","--pl","--pt-mobile","--pb-mobile","--pr-mobile","--pl-mobile","--pt-tablet","--pb-tablet","--pr-tablet","--pl-tablet"];return l.forEach(t=>{delete e?.[t]}),e};exports.displayConditionStyle=displayConditionStyle,exports.filterStyles=filterStyles,exports.getContainerStyles=getContainerStyles,exports.getContentStyles=getContentStyles,exports.getDisplayStyle=getDisplayStyle,exports.getStylePadding=getStylePadding;
1
+ "use strict";var core=require("@gem-sdk/core");require("react/jsx-runtime"),require("react");var _const=require("../../common/const.js");const getCSSPosition=t=>"top"==t?"sticky":"fixed",getDisplayStyle=(t,e,l)=>{let i={[`--top${t}`]:"auto",[`--${l+t}`]:"0",[`--pos${t}`]:getCSSPosition(l)};return"after-first-cart-button"===e&&(i[`--d${t}`]="none"),i},displayConditionStyle=(t,e)=>({...getDisplayStyle("",t?.desktop,e?.desktop),...getDisplayStyle("-tablet",t?.tablet??t?.desktop,e?.tablet??e?.desktop),...getDisplayStyle("-mobile",t?.mobile??t?.tablet??t?.desktop,e?.mobile??e?.tablet??e?.desktop)}),getCSSAlignByDevice=(t,e)=>({[`--left${e}`]:"top"==t?"0":"50%",[`--t${e}`]:"top"==t?"unset":"translateX(-50%)"}),getCSSAlign=t=>({...getCSSAlignByDevice(t?.desktop,""),...getCSSAlignByDevice(t?.tablet??t?.desktop,"-tablet"),...getCSSAlignByDevice(t?.mobile??t?.tablet??t?.desktop,"-mobile")}),getContainerStyles=t=>{let{position:e,display:l}=t;return{margin:"0 auto",...getCSSAlign(e),...displayConditionStyle(l,e),"z-index":_const.ELEMENT_Z_INDEX.STICKY}},getContentStyles=t=>{let{style:e,background:l}=t;return{...core.makeStyle({m:"0 auto"}),...getStylePadding(e),...filterStyles(e),...core.getStyleBackgroundByDevice(l),...core.getGradientBgrStyleByDevice(l)}},getStylePadding=t=>{let e=["--pt","--pb","--pr","--pl","--pt-mobile","--pb-mobile","--pr-mobile","--pl-mobile","--pt-tablet","--pb-tablet","--pr-tablet","--pl-tablet"],l={};return e.forEach(e=>{t?.[e]&&(l[e]=t[e])}),l},filterStyles=t=>{let e={...t},l=["--pt","--pb","--pr","--pl","--pt-mobile","--pb-mobile","--pr-mobile","--pl-mobile","--pt-tablet","--pb-tablet","--pr-tablet","--pl-tablet"];return l.forEach(t=>{delete e?.[t]}),e};exports.displayConditionStyle=displayConditionStyle,exports.filterStyles=filterStyles,exports.getContainerStyles=getContainerStyles,exports.getContentStyles=getContentStyles,exports.getDisplayStyle=getDisplayStyle,exports.getStylePadding=getStylePadding;
@@ -1,18 +1,18 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var core=require("@gem-sdk/core"),helpers=require("../../helpers.js"),system=require("@gem-sdk/system"),styles=require("../common/styles.js"),classes=require("../common/classes.js");const Sticky=({children:e,builderAttrs:s,setting:t,style:r,builderProps:a,advanced:i})=>{let{width:l,position:d,display:c,preloadBgImage:o,background:n,isScrollToTop:p}=t??{},g=i?.d,m=system.createStyle({...styles.getContainerStyles({position:d,style:r,display:c,width:l})}),y=system.createStyle(styles.getContentStyles({width:l,style:r,background:n})),$=system.createClass(classes.getContainerClasses({uid:a?.uid,isScrollToTop:p,cssClass:i?.cssClass,isLiquid:!0})),k=system.createStateOrContext({uid:a?.uid,setting:{display:{desktop:c?.desktop,tablet:c?.tablet??c?.desktop,mobile:c?.mobile??c?.tablet??c?.desktop}},advanced:{d:g}}),u=`.drawer-page-content {
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var core=require("@gem-sdk/core"),helpers=require("../../helpers.js"),system=require("@gem-sdk/system"),styles=require("../common/styles.js"),classes=require("../common/classes.js");const Sticky=({children:e,builderAttrs:s,setting:t,style:r,builderProps:a,advanced:i})=>{let{width:l,position:d,display:o,preloadBgImage:c,background:n,isScrollToTop:p}=t??{},m=i?.d,g=system.createStyle({...styles.getContainerStyles({position:d,style:r,display:o})}),y=system.createStyle(styles.getContentStyles({width:l,style:r,background:n})),$=system.createClass(classes.getContainerClasses({uid:a?.uid,isScrollToTop:p,cssClass:i?.cssClass,isLiquid:!0})),k=system.createStateOrContext({uid:a?.uid,setting:{display:{desktop:o?.desktop,tablet:o?.tablet??o?.desktop,mobile:o?.mobile??o?.tablet??o?.desktop}},advanced:{d:m}}),u=`.drawer-page-content {
2
2
  transform: none !important;
3
3
  -webkit-transform: none !important;
4
4
  }`;return core.template`
5
- ${core.RenderIf(!!o,`${core.RenderIf(!!n?.desktop?.image?.src,`<link rel="preload" href="${n?.desktop?.image?.src}" as="image" />`)}${core.RenderIf(!!n?.tablet?.image?.src,`<link rel="preload" href="${n?.tablet?.image?.src}" as="image" />`)}${core.RenderIf(!!n?.mobile?.image?.src,`<link rel="preload" href="${n?.mobile?.image?.src}" as="image" />`)}`)}
5
+ ${core.RenderIf(!!c,`${core.RenderIf(!!n?.desktop?.image?.src,`<link rel="preload" href="${n?.desktop?.image?.src}" as="image" />`)}${core.RenderIf(!!n?.tablet?.image?.src,`<link rel="preload" href="${n?.tablet?.image?.src}" as="image" />`)}${core.RenderIf(!!n?.mobile?.image?.src,`<link rel="preload" href="${n?.mobile?.image?.src}" as="image" />`)}`)}
6
6
  <gp-sticky
7
7
  data-id="${a?.uid}"
8
8
  gp-data='${JSON.stringify(k)}'
9
9
  id="${a?.uid}"
10
10
  data-id="${a?.uid}"
11
11
  class="${$} ${helpers.getSettingPreloadData("gps-lazy")}"
12
- style="${m}"
12
+ style="${g}"
13
13
  >
14
14
  <style>${u}</style>
15
- <div ${{...s}} style="${{...y}}">
15
+ <div ${{...s}} style="${{...y,...core.makeStyleResponsive("w",l)}}">
16
16
  ${e}
17
17
  </div>
18
18
  </gp-sticky>
@@ -1 +1 @@
1
- let FormEmailSettings=[{id:"setting",controls:[{id:"placeholder",type:"input",label:"Placeholder",default:"Enter your email address"},{id:"placeholderColor",type:"color-picker-v2",label:"Color",default:"#A3A3A3"},{id:"translate",type:"input",default:"placeholder"},{id:"required",type:"toggle",label:"Placeholder",default:!0},{id:"hideOnClient",type:"toggle",label:"Hide on client",default:!1},{id:"defaultEmail",type:"input",label:"Default value",default:"default@gempages.help"},{id:"typo",label:"Text styles",type:"typography-v2",default:{type:"paragraph-1"},hiddenSetting:{color:!0,textAlign:!0,textShadow:!0},ignoreReRender:!0},{id:"size",label:"Field size",type:"size",default:{type:"medium"},ignoreReRender:!0},{id:"fullWidth",label:"Full Width",type:"toggle",devices:{desktop:{default:!0},tablet:{default:!0},mobile:{default:!0}}},{id:"width",type:"input:unit",label:"Width",placeholder:"Auto Width",min:0,units:["px","%"],hide:!0,devices:{desktop:{default:"100%"}}},{id:"background",type:"background-media",ignoreReRender:!0,hideImage:!0,devices:{desktop:{default:{type:"color",color:"#FFFFFF"}}},compoDefaultValue:{desktop:{default:{type:"color",color:"#FFFFFF"}}}},{id:"align",label:"Alignment",type:"option:value",options:[{label:"Left",value:"left",type:"align",tooltip:"Align left",iconName:"gp-align-left"},{label:"Center",value:"center",type:"align",tooltip:"Align center",iconName:"gp-align-center"},{label:"Right",value:"right",type:"align",tooltip:"Align right",iconName:"gp-align-right"}],devices:{desktop:{default:"left"}}}]},{id:"style",controls:[{id:"globalSize",type:"size-setting",devices:{desktop:{default:{width:"100%",height:"Auto",padding:{type:"medium",top:"12px",bottom:"12px",left:"12px",right:"12px"}}}},settingConfig:{width:{},height:{displayOptions:["auto","small","large","medium"],sizeConfig:{small:"28px",medium:"36px",large:"44px"}}},hiddenSettings:["shape","gap"]},{id:"wrapperBorder",type:"border-v2",label:"Border",default:{border:"solid",width:"1px 1px 1px 1px",position:"all",borderWidth:"1px",color:"#7D7D7D",isCustom:!0}},{id:"backgroundColorV2Hover",type:"color-picker-v2",enableGradient:!0},{id:"textColorHover",type:"color-picker-v2",label:"Text Color",state:{hover:!0}},{id:"borderEmailHover",type:"border",emptyOnClear:!0,state:{hover:!0}},{id:"roundedEmailHover",type:"radius-preset",default:{hover:{radiusType:"small"}},state:{hover:!0}},{id:"boxShadowEmailHover",type:"shadow-v2",label:"Button Shadow",hideOnState:{hover:!0},default:{hover:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},state:{hover:!0}},{id:"backgroundColorV2Active",type:"color-picker-v2",enableGradient:!0},{id:"textColorActive",type:"color-picker-v2",label:"Text Color",state:{active:!0}},{id:"borderEmailActive",type:"border",emptyOnClear:!0,state:{active:!0}},{id:"roundedEmailActive",type:"radius-preset",default:{active:{radiusType:"small"}},state:{active:!0}},{id:"boxShadowEmailActive",type:"shadow-v2",label:"Button Shadow",hideOnState:{active:!0},default:{active:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},state:{active:!0}}]}];export{FormEmailSettings as default};
1
+ let FormEmailSettings=[{id:"setting",controls:[{id:"placeholder",type:"textarea",minHeight:56,label:"Placeholder",default:"Enter your email address"},{id:"placeholderColor",type:"color-picker-v2",label:"Color",default:"#A3A3A3"},{id:"translate",type:"input",default:"placeholder"},{id:"required",type:"toggle",label:"Placeholder",default:!0},{id:"hideOnClient",type:"toggle",label:"Hide on client",default:!1},{id:"defaultEmail",type:"input",label:"Default value",default:"default@gempages.help"},{id:"typo",label:"Text styles",type:"typography-v2",default:{type:"paragraph-1"},hiddenSetting:{color:!0,textAlign:!0,textShadow:!0},ignoreReRender:!0},{id:"size",label:"Field size",type:"size",default:{type:"medium"},ignoreReRender:!0},{id:"fullWidth",label:"Full Width",type:"toggle",devices:{desktop:{default:!0},tablet:{default:!0},mobile:{default:!0}}},{id:"width",type:"input:unit",label:"Width",placeholder:"Auto Width",min:0,units:["px","%"],hide:!0,devices:{desktop:{default:"100%"}}},{id:"background",type:"background-media",ignoreReRender:!0,hideImage:!0,devices:{desktop:{default:{type:"color",color:"#FFFFFF"}}},compoDefaultValue:{desktop:{default:{type:"color",color:"#FFFFFF"}}}},{id:"align",label:"Alignment",type:"option:value",options:[{label:"Left",value:"left",type:"align",tooltip:"Align left",iconName:"gp-align-left"},{label:"Center",value:"center",type:"align",tooltip:"Align center",iconName:"gp-align-center"},{label:"Right",value:"right",type:"align",tooltip:"Align right",iconName:"gp-align-right"}],devices:{desktop:{default:"left"}}}]},{id:"style",controls:[{id:"globalSize",type:"size-setting",devices:{desktop:{default:{width:"100%",height:"Auto",padding:{type:"medium",top:"12px",bottom:"12px",left:"12px",right:"12px"}}}},settingConfig:{width:{},height:{displayOptions:["auto","small","large","medium"],sizeConfig:{small:"28px",medium:"36px",large:"44px"}}},hiddenSettings:["shape","gap"]},{id:"wrapperBorder",type:"border-v2",label:"Border",default:{border:"solid",width:"1px 1px 1px 1px",position:"all",borderWidth:"1px",color:"#7D7D7D",isCustom:!0}},{id:"backgroundColorV2Hover",type:"color-picker-v2",enableGradient:!0},{id:"textColorHover",type:"color-picker-v2",label:"Text Color",state:{hover:!0}},{id:"borderEmailHover",type:"border",emptyOnClear:!0,state:{hover:!0}},{id:"roundedEmailHover",type:"radius-preset",default:{hover:{radiusType:"small"}},state:{hover:!0}},{id:"boxShadowEmailHover",type:"shadow-v2",label:"Button Shadow",hideOnState:{hover:!0},default:{hover:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},state:{hover:!0}},{id:"backgroundColorV2Active",type:"color-picker-v2",enableGradient:!0},{id:"textColorActive",type:"color-picker-v2",label:"Text Color",state:{active:!0}},{id:"borderEmailActive",type:"border",emptyOnClear:!0,state:{active:!0}},{id:"roundedEmailActive",type:"radius-preset",default:{active:{radiusType:"small"}},state:{active:!0}},{id:"boxShadowEmailActive",type:"shadow-v2",label:"Button Shadow",hideOnState:{active:!0},default:{active:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},state:{active:!0}}]}];export{FormEmailSettings as default};
@@ -1,7 +1,7 @@
1
- let config={tag:"Input",label:"Input",icon:`
1
+ import{InputSettings as C}from"./configs/settings.js";let config={tag:"Input",label:"Input",icon:`
2
2
  <svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
3
3
  <path d="M38.1665 16.2397C38.4426 16.2397 38.6665 16.4636 38.6665 16.7397V30.3155C38.6665 30.5916 38.4426 30.8155 38.1665 30.8155H6.37109C6.09495 30.8155 5.87109 30.5916 5.87109 30.3155V22.813C5.87109 22.5368 6.09495 22.313 6.37109 22.313H7.80038C8.07653 22.313 8.30038 22.5368 8.30038 22.813V28.3862H36.2372V18.669H23.3761C23.1 18.669 22.8761 18.4452 22.8761 18.169V16.7397C22.8761 16.4636 23.1 16.2397 23.3761 16.2397H38.1665Z" fill="currentColor"/>
4
4
  <path d="M7.93505 16.9528H4.0383L3.51131 18.4447C3.44072 18.6446 3.2518 18.7782 3.03986 18.7782H1.69097C1.51719 18.7782 1.39642 18.6053 1.45626 18.4421L4.73106 9.51242C4.80328 9.31549 4.99074 9.18457 5.20049 9.18457H6.78688C6.99663 9.18457 7.18408 9.31549 7.2563 9.51242L10.5311 18.4421C10.5909 18.6053 10.4702 18.7782 10.2964 18.7782H8.93349C8.72155 18.7782 8.53263 18.6446 8.46204 18.4447L7.93505 16.9528ZM7.4024 15.4156L5.98667 11.408L4.57095 15.4156H7.4024Z" fill="currentColor"/>
5
5
  <path d="M11.4648 14.949C11.4648 14.1804 11.619 13.4987 11.9274 12.904C12.2451 12.3092 12.6703 11.8518 13.2029 11.5315C13.7449 11.2113 14.3477 11.0511 15.0111 11.0511C15.5905 11.0511 16.0951 11.1655 16.525 11.3943C16.9642 11.623 17.3146 11.9112 17.5763 12.2589V11.6747C17.5763 11.3985 17.8001 11.1747 18.0763 11.1747H19.0527C19.3288 11.1747 19.5527 11.3985 19.5527 11.6747V18.2782C19.5527 18.5543 19.3288 18.7782 19.0527 18.7782H18.0763C17.8001 18.7782 17.5763 18.5543 17.5763 18.2782V17.6665C17.324 18.0233 16.9735 18.3207 16.525 18.5586C16.0858 18.7874 15.5765 18.9017 14.9971 18.9017C14.343 18.9017 13.7449 18.737 13.2029 18.4076C12.6703 18.0782 12.2451 17.6162 11.9274 17.0214C11.619 16.4175 11.4648 15.7267 11.4648 14.949ZM17.5763 14.9764C17.5763 14.5098 17.4828 14.1118 17.2959 13.7824C17.109 13.4438 16.8567 13.1876 16.539 13.0138C16.2213 12.8308 15.8802 12.7393 15.5158 12.7393C15.1513 12.7393 14.8149 12.8262 14.5065 13.0001C14.1982 13.1739 13.9458 13.4301 13.7496 13.7687C13.5627 14.098 13.4693 14.4915 13.4693 14.949C13.4693 15.4065 13.5627 15.8091 13.7496 16.1568C13.9458 16.4953 14.1982 16.7561 14.5065 16.9391C14.8243 17.1221 15.1607 17.2136 15.5158 17.2136C15.8802 17.2136 16.2213 17.1267 16.539 16.9528C16.8567 16.7698 17.109 16.5136 17.2959 16.1842C17.4828 15.8457 17.5763 15.4431 17.5763 14.9764Z" fill="currentColor"/>
6
6
  </svg>
7
- `,settings:[{id:"setting",controls:[{id:"type",type:"select",label:"Select Type Input",options:[{label:"Text",value:"text"},{label:"Number",value:"number"},{label:"Password",value:"password"},{label:"Email",value:"email"},{label:"Hidden",value:"hidden"},{label:"Search",value:"search"},{label:"Tel",value:"tel"},{label:"Url",value:"url"}],default:"text"},{id:"defaultValue",type:"input",label:"Default Value",default:"",datalist:[{value:"suggest 1"},{value:"suggest 2"}]},{id:"placeholder",type:"input",label:"Placeholder",default:"Enter your text data"},{id:"disabled",type:"toggle",label:"Disabled",default:!1},{id:"prefix",type:"input",label:"prefix",info:"This is prefix icon",default:""},{id:"suffix",type:"input",label:"suffix",info:"This is suffix icon",default:""},{id:"allowClear",type:"toggle",label:"AllowClear",default:!1},{id:"passwordToggle",type:"toggle",label:"Password Toggle",default:!1},{id:"required",type:"toggle",label:"Required",default:!1}]},{id:"style",controls:[]}]};export{config as default};
7
+ `,settings:C};export{config as default};
@@ -0,0 +1 @@
1
+ let InputSettings=[{id:"setting",controls:[{id:"type",type:"select",label:"Select Type Input",options:[{label:"Text",value:"text"},{label:"Number",value:"number"},{label:"Password",value:"password"},{label:"Email",value:"email"},{label:"Hidden",value:"hidden"},{label:"Search",value:"search"},{label:"Tel",value:"tel"},{label:"Url",value:"url"}],default:"text"},{id:"defaultValue",type:"input",label:"Default Value",default:"",datalist:[{value:"suggest 1"},{value:"suggest 2"}]},{id:"placeholder",type:"input",label:"Placeholder",default:"Enter your text data"},{id:"disabled",type:"toggle",label:"Disabled",default:!1},{id:"prefix",type:"input",label:"prefix",info:"This is prefix icon",default:""},{id:"suffix",type:"input",label:"suffix",info:"This is suffix icon",default:""},{id:"allowClear",type:"toggle",label:"AllowClear",default:!1},{id:"passwordToggle",type:"toggle",label:"Password Toggle",default:!1},{id:"required",type:"toggle",label:"Required",default:!1}]},{id:"style",controls:[]}];export{InputSettings};
@@ -1,2 +1,2 @@
1
- import{composeTypographyClassName as e,cls as r,composeClasses as p}from"@gem-sdk/core";let getWrapperClass=t=>{let{typeOfOption:o,optionTypo:l,optionTypography:g,variantKey:a,soldOutMarkLine:f,available:s}=t,i="color"===o,b=`${e(l,g)}`,d=r({...a&&{[a]:!0},[b]:!0,"gp-p-[4px]":i,"before:gp-absolute before:gp-top-[50%] before:gp-z-1 before:gp-block before:gp-w-full before:-gp-rotate-45 before:gp-border-t before:gp-border-[#A1A1A1] before:gp-bg-[#333]":f&&!s&&!i}),n=`gp-relative gp-flex gp-cursor-pointer gp-items-center gp-justify-center gp-text-center option-value-wrapper gp-overflow-hidden gp-w-full gp-h-full data-[disabled='disabled']:gp-pointer-events-none data-[disabled='disabled']:!gp-cursor-not-allowed
2
- data-[hidden='false']:gp-flex`,u=`${n} ${d}`.trim();return p(u)},getWrapperTextClass=e=>{let t=r({"gp-flex gp-flex-col gp-justify-center gp-items-center gp-gap-[6px":e}),o=`option-value gp-overflow-hidden gp-relative ${t}`.trim();return p(o)},getTextClass=({optionTypo:t,optionTypography:o,isColorType:l,isUploadImageType:g})=>{let a=`${e(t,o)}`,f=r({"gp-text-center":!0,[a]:!0,"gp-overflow-hidden gp-text-ellipsis gp-px-1":l||g}),s=`${f}`.trim();return p(s)},getColorClass=({soldOutMarkLine:e,available:t})=>{let o=r({"before:gp-absolute before:gp-top-[50%] before:gp-block before:gp-w-full before:gp--rotate-45 before:gp-border":e&&!t}),l=`color gp-relative gp-h-full gp-w-full gp-overflow-hidden gp-min-w-fit gp-flex gp-color-circle ${o}`.trim();return p(l)};export{getColorClass,getTextClass,getWrapperClass,getWrapperTextClass};
1
+ import{composeTypographyClassName as e,cls as p,composeClasses as r}from"@gem-sdk/core";let getWrapperClass=t=>{let{typeOfOption:l,optionTypo:g,optionTypography:o,variantKey:f,soldOutMarkLine:a,available:s}=t,i="color"===l,b=`${e(g,o)}`,n=p({...f&&{[f]:!0},[b]:!0,"gp-p-[4px]":i,"before:gp-absolute before:gp-top-[50%] before:gp-z-1 before:gp-block before:gp-w-full before:-gp-rotate-45 before:gp-border-t before:gp-border-[#A1A1A1] before:gp-bg-[#333]":a&&!s&&!i}),d=`gp-relative gp-flex gp-cursor-pointer gp-items-center gp-justify-center gp-text-center option-value-wrapper gp-overflow-hidden gp-w-full gp-h-full data-[disabled='disabled']:gp-pointer-events-none data-[disabled='disabled']:!gp-cursor-not-allowed
2
+ data-[hidden='false']:gp-flex`,c=`${d} ${n}`.trim();return r(c)},getWrapperTextClass=(e,t)=>{let l=p({"color gp-line-clamp-2 gp-flex gp-h-full gp-w-full gp-items-center gp-justify-center":t,"gp-flex gp-flex-col gp-justify-center gp-items-center gp-gap-[6px":e}),g=`option-value gp-overflow-hidden gp-relative ${l}`.trim();return r(g)},getTextClass=({optionTypo:t,optionTypography:l,isColorType:g,isUploadImageType:o})=>{let f=`${e(t,l)}`,a=p({"gp-text-center":!0,[f]:!0,"gp-overflow-hidden gp-text-ellipsis gp-px-1":g||o}),s=`${a}`.trim();return r(s)},getColorClass=({soldOutMarkLine:e,available:t})=>{let l=p({"before:gp-absolute before:gp-top-[50%] before:gp-block before:gp-w-full before:gp--rotate-45 before:gp-border":e&&!t}),g=`color gp-relative gp-h-full gp-w-full gp-overflow-hidden gp-min-w-fit gp-flex gp-color-circle ${l}`.trim();return r(g)};export{getColorClass,getTextClass,getWrapperClass,getWrapperTextClass};
@@ -1 +1 @@
1
- import{composeTypographyStyle as e,getRadiusStyleActiveState as t,getStyleShadow as o,makeStyle as r,getSingleColorVariable as l,composeRadius as p,getGlobalColorStateStyle as a,handleConvertBorderStyle as i,handleConvertBorderWidth as d,handleConvertBorderColor as n}from"@gem-sdk/core";import{filterTruthyObject as h}from"../../../../../helpers.js";let getWrapperStyleActive=p=>{let{preset:a,optionTypography:i,optionTypo:d,typeOfOption:n}=p,b=a?.optionBgColor,g=a?.optionTextColor,c=a?.optionBorder,s=a?.optionHasShadow,m=a?.optionShadow,w=a?.optionRounded,x="color"===n,u="image"===n||"image_shopify"===n,S=e(d,i),v=e=>r({bg:e&&l(b?.active??b?.normal),bs:c?.active?.border,bw:c?.active?.width,bc:l(c?.active?.color)});return h({...v(!x),...t(w),...o({value:m?.active,state:"active",styleAppliedFor:"box-shadow",isEnableShadow:s?.active},!0),...S,...!x&&!u&&r({c:l(g?.active??g?.normal)}),...r({h:a?.height})})},getWrapperStyleNormalAndHover=t=>{let{preset:l,optionTransform:b,optionTypography:g,optionTypo:c,typeOfOption:s}=t,m=l?.optionBgColor,w=l?.optionTextColor,x=l?.optionBorder,u=l?.optionHasShadow,S=l?.optionShadow,v=l?.optionRounded,y="color"===s,C="image"===s||"image_shopify"===s,W=e(c,g),f=["normal","hover"].reduce((e,t)=>({...e,...o({value:S?.[t],state:t,styleAppliedFor:"box-shadow",isEnableShadow:u?.[t]})}),{});return h({...p(v),...f,...!y&&a("bg",m),...!y&&i(x),...!y&&d(x),...!y&&n(x),...!y&&!C&&r({c:b}),...!y&&!C&&a("c",w),...W,...r({h:l?.height})})},getWrapperTextStyle=e=>{let{preset:t,typeOfOption:o}=e,r="color"===o,l=()=>{let e="16px",o={"--pl":"0px","--pr":"0px","--pl-tablet":"0px","--pr-tablet":"0px","--pl-mobile":"0px","--pr-mobile":"0px","--pt":"0px","--pb":"0px"};return t?.width?.desktop?.toLowerCase()!=="auto"&&t?.width?.desktop||(o["--pl"]=e,o["--pr"]=e),t?.width?.tablet?.toLowerCase()!=="auto"&&t?.width?.tablet||(o["--pl-tablet"]=e,o["--pr-tablet"]=e),t?.width?.mobile?.toLowerCase()!=="auto"&&t?.width?.mobile||(o["--pl-mobile"]=e,o["--pr-mobile"]=e),(t?.height?.toLowerCase()==="auto"||t?.height)&&(o["--pt"]="8px",o["--pb"]="8px"),o};return h({...r?{}:l()})},getColorStyle=({optionBorder:e,optionRounded:t,isActive:o,color:r})=>{let l=()=>r?r?.startsWith("linear-gradient")?{backgroundImage:r}:{backgroundColor:r}:{},a=o=>({"--d":"flex","--jc":"center"," --ai":"center","--w":"100%","--h":"100%","--of":"hidden","--bs":o?"none":"solid",...d(e),...n(e),...p(t),...l()});return a(!!o)},getTextStyle=({optionTypo:t,optionTypography:o})=>{let r=e(t,o);return delete r["--c"],h({...r})};export{getColorStyle,getTextStyle,getWrapperStyleActive,getWrapperStyleNormalAndHover,getWrapperTextStyle};
1
+ import{composeTypographyStyle as e,getRadiusStyleActiveState as t,getStyleShadow as o,makeStyle as r,getSingleColorVariable as p,composeRadius as l,getGlobalColorStateStyle as a,handleConvertBorderStyle as i,handleConvertBorderWidth as d,handleConvertBorderColor as n}from"@gem-sdk/core";import{filterTruthyObject as h}from"../../../../../helpers.js";let getWrapperStyleActive=l=>{let{preset:a,optionTypography:i,optionTypo:d,typeOfOption:n}=l,c=a?.optionBgColor,b=a?.optionTextColor,g=a?.optionBorder,s=a?.optionHasShadow,m=a?.optionShadow,w=a?.optionRounded,x="color"===n,u="image"===n||"image_shopify"===n,v=e(d,i),S=e=>r({bg:e&&p(c?.active??c?.normal),bs:g?.active?.border,bw:g?.active?.width,bc:p(g?.active?.color)});return h({...S(!x),...t(w),...o({value:m?.active,state:"active",styleAppliedFor:"box-shadow",isEnableShadow:s?.active},!0),...v,...!x&&!u&&r({c:p(b?.active??b?.normal)}),...r({h:a?.height})})},getWrapperStyleNormalAndHover=t=>{let{preset:p,optionTransform:c,optionTypography:b,optionTypo:g,typeOfOption:s}=t,m=p?.optionBgColor,w=p?.optionTextColor,x=p?.optionBorder,u=p?.optionHasShadow,v=p?.optionShadow,S=p?.optionRounded,y="color"===s,C="image"===s||"image_shopify"===s,T=e(g,b),W=["normal","hover"].reduce((e,t)=>({...e,...o({value:v?.[t],state:t,styleAppliedFor:"box-shadow",isEnableShadow:u?.[t]})}),{});return h({...l(S),...W,...!y&&a("bg",m),...!y&&i(x),...!y&&d(x),...!y&&n(x),...!y&&!C&&r({c:c}),...!y&&!C&&a("c",w),...T,...r({h:p?.height})})},getWrapperTextStyle=e=>{let{preset:o,typeOfOption:r,checked:p}=e,a=o?.optionBorder,c=o?.optionRounded,b="color"===r,g=()=>{let e="16px",t={"--pl":"0px","--pr":"0px","--pl-tablet":"0px","--pr-tablet":"0px","--pl-mobile":"0px","--pr-mobile":"0px","--pt":"0px","--pb":"0px"};return o?.width?.desktop?.toLowerCase()!=="auto"&&o?.width?.desktop||(t["--pl"]=e,t["--pr"]=e),o?.width?.tablet?.toLowerCase()!=="auto"&&o?.width?.tablet||(t["--pl-tablet"]=e,t["--pr-tablet"]=e),o?.width?.mobile?.toLowerCase()!=="auto"&&o?.width?.mobile||(t["--pl-mobile"]=e,t["--pr-mobile"]=e),(o?.height?.toLowerCase()==="auto"||o?.height)&&(t["--pt"]="8px",t["--pb"]="8px"),t},s={...c,active:{...c?.active||{},radiusType:"custom"}},m=p?t(s):l(c),w=!p&&b?{...i(a),...d(a),...n(a)}:{};return h({...!b&&g(),...b&&m,...w})},getColorStyle=({optionBorder:e,optionRounded:t,isActive:o,color:r})=>{let p=()=>r?r?.startsWith("linear-gradient")?{backgroundImage:r}:{backgroundColor:r}:{},a=o=>({"--d":"flex","--jc":"center"," --ai":"center","--w":"100%","--h":"100%","--of":"hidden","--bs":o?"none":"solid",...d(e),...n(e),...l(t),...p()});return a(!!o)},getTextStyle=({optionTypo:t,optionTypography:o})=>{let r=e(t,o);return delete r["--c"],h({...r})};export{getColorStyle,getTextStyle,getWrapperStyleActive,getWrapperStyleNormalAndHover,getWrapperTextStyle};
@@ -8,4 +8,4 @@ import{jsxs as e,jsx as r,Fragment as t}from"react/jsx-runtime";import{useMemo a
8
8
  .${F} .color:before {
9
9
  border-color: ${q(o)} !important;
10
10
  }
11
- `}),r("div",{className:E,style:i},t)]},t)})}),H=i(f(W)),I=s(g(b)),J=i(d({optionTypo:D,optionTypography:j,isColorType:V,isUploadImageType:W})),K=s(C({optionTypo:D,optionTypography:j})),O=()=>r(t,{children:e("div",{className:H,style:I,children:[z(),m(W,e("svg",{width:"15",height:"12",viewBox:"0 0 15 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[r("circle",{cx:"2",cy:"2",r:"2",fill:"#D6D6D6"}),r("path",{d:"M0.196854 10.6453L2.40968 8.05946C2.4846 7.97175 2.57719 7.9008 2.68141 7.85124C2.78562 7.80168 2.89913 7.77461 3.01452 7.77181C3.12991 7.76902 3.2446 7.79055 3.3511 7.835C3.45761 7.87945 3.55353 7.94583 3.63262 8.02981L4.66733 9.12714L8.71205 4.29464C8.79123 4.19995 8.89077 4.1243 9.00325 4.07333C9.11573 4.02236 9.23827 3.99737 9.36176 4.00022C9.48524 4.00307 9.6065 4.03369 9.71651 4.08979C9.82651 4.1459 9.92245 4.22605 9.99717 4.32429L14.8329 10.6772C14.9254 10.7989 14.982 10.9441 14.9964 11.0962C15.0107 11.2484 14.9823 11.4016 14.9144 11.5385C14.8464 11.6754 14.7415 11.7907 14.6115 11.8713C14.4815 11.952 14.3316 11.9948 14.1786 11.995L0.822048 12C0.664945 11.9999 0.511148 11.9549 0.378853 11.8703C0.246557 11.7857 0.141299 11.6649 0.0755311 11.5224C0.00976323 11.3799 -0.013762 11.2216 0.00773837 11.0661C0.0292388 10.9107 0.0948652 10.7646 0.196854 10.6453Z",fill:"#D6D6D6"})]})),r("span",{className:J,style:K,children:w?.label})]})}),P=()=>r("img",{className:"gp-h-full gp-w-full gp-object-cover",src:$,alt:""}),Q=()=>{switch(N){case"color":return m(B&&B.length>0,G(),O());case"image":case"image_shopify":return m(!!$,P(),O());default:return O()}},S=i(h(b)),T=c(p(b)),U=s(u(b)),X=s(y(b)),Y=x?U:X;return e("div",{...T,className:S,style:Y,children:[z(),Q()]})};export{BaseVariant as default};
11
+ `}),r("div",{className:E,style:i},t)]},t)})}),H=i(f(W,V)),I=s(g(b)),J=i(d({optionTypo:D,optionTypography:j,isColorType:V,isUploadImageType:W})),K=s(C({optionTypo:D,optionTypography:j})),O=()=>r(t,{children:e("div",{className:H,style:I,children:[z(),m(W,e("svg",{width:"15",height:"12",viewBox:"0 0 15 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[r("circle",{cx:"2",cy:"2",r:"2",fill:"#D6D6D6"}),r("path",{d:"M0.196854 10.6453L2.40968 8.05946C2.4846 7.97175 2.57719 7.9008 2.68141 7.85124C2.78562 7.80168 2.89913 7.77461 3.01452 7.77181C3.12991 7.76902 3.2446 7.79055 3.3511 7.835C3.45761 7.87945 3.55353 7.94583 3.63262 8.02981L4.66733 9.12714L8.71205 4.29464C8.79123 4.19995 8.89077 4.1243 9.00325 4.07333C9.11573 4.02236 9.23827 3.99737 9.36176 4.00022C9.48524 4.00307 9.6065 4.03369 9.71651 4.08979C9.82651 4.1459 9.92245 4.22605 9.99717 4.32429L14.8329 10.6772C14.9254 10.7989 14.982 10.9441 14.9964 11.0962C15.0107 11.2484 14.9823 11.4016 14.9144 11.5385C14.8464 11.6754 14.7415 11.7907 14.6115 11.8713C14.4815 11.952 14.3316 11.9948 14.1786 11.995L0.822048 12C0.664945 11.9999 0.511148 11.9549 0.378853 11.8703C0.246557 11.7857 0.141299 11.6649 0.0755311 11.5224C0.00976323 11.3799 -0.013762 11.2216 0.00773837 11.0661C0.0292388 10.9107 0.0948652 10.7646 0.196854 10.6453Z",fill:"#D6D6D6"})]})),r("span",{className:J,style:K,children:w?.label})]})}),P=()=>r("img",{className:"gp-h-full gp-w-full gp-object-cover",src:$,alt:""}),Q=()=>{switch(N){case"color":return m(B&&B.length>0,G(),O());case"image":case"image_shopify":return m(!!$,P(),O());default:return O()}},S=i(h(b)),T=c(p(b)),U=s(u(b)),X=s(y(b)),Y=x?U:X;return e("div",{...T,className:S,style:Y,children:[z(),Q()]})};export{BaseVariant as default};
@@ -7,7 +7,7 @@ import{template as e}from"@gem-sdk/core";import{getStyleOfObject as s}from"../..
7
7
  data-test="{{ backgroundType }}: {{ color }}"
8
8
  style="{{ backgroundType }}: {{ color }}; ${U()}"></div>
9
9
  `)}
10
- `,V=t(u({optionBorder:b,optionRounded:k,isActive:!0})),B=t(u({optionBorder:b,optionRounded:k,isActive:!1})),U=()=>n("selectedValue == value",s(V),s(B)),A=i(o(L)),_=t({...v(y)}),q=i(l({optionTypo:w,optionTypography:h,isColorType:D,isUploadImageType:L})),z=t($({optionTypo:w,optionTypography:h})),M=()=>e`
10
+ `,V=t(u({optionBorder:b,optionRounded:k,isActive:!0})),B=t(u({optionBorder:b,optionRounded:k,isActive:!1})),U=()=>n("selectedValue == value",s(V),s(B)),A=i(o(L,D)),_=t({...v(y)}),q=i(l({optionTypo:w,optionTypography:h,isColorType:D,isUploadImageType:L})),z=t($({optionTypo:w,optionTypography:h})),M=()=>e`
11
11
  <div
12
12
  class="${A}"
13
13
  style="${D?U():""} ${s(_)}">
@@ -1 +1 @@
1
- import{makeStyleResponsive as t,makeStyle as e,getStyleBackgroundByDevice as l,getGradientBgrStyleByDevice as i}from"@gem-sdk/core";import"react/jsx-runtime";import"react";import{ELEMENT_Z_INDEX as o}from"../../common/const.js";let getCSSPosition=t=>"top"==t?"sticky":"fixed",getDisplayStyle=(t,e,l)=>{let i={[`--top${t}`]:"auto",[`--${l+t}`]:"0",[`--pos${t}`]:getCSSPosition(l)};return"after-first-cart-button"===e&&(i[`--d${t}`]="none"),i},displayConditionStyle=(t,e)=>({...getDisplayStyle("",t?.desktop,e?.desktop),...getDisplayStyle("-tablet",t?.tablet??t?.desktop,e?.tablet??e?.desktop),...getDisplayStyle("-mobile",t?.mobile??t?.tablet??t?.desktop,e?.mobile??e?.tablet??e?.desktop)}),getCSSAlignByDevice=(t,e)=>({[`--left${e}`]:"top"==t?"0":"50%",[`--t${e}`]:"top"==t?"unset":"translateX(-50%)"}),getCSSAlign=t=>({...getCSSAlignByDevice(t?.desktop,""),...getCSSAlignByDevice(t?.tablet??t?.desktop,"-tablet"),...getCSSAlignByDevice(t?.mobile??t?.tablet??t?.desktop,"-mobile")}),getContainerStyles=e=>{let{position:l,display:i,width:p}=e;return{margin:"0 auto",...t("w",p),...getCSSAlign(l),...displayConditionStyle(i,l),"z-index":o.STICKY}},getContentStyles=t=>{let{style:o,background:p}=t;return{...e({m:"0 auto"}),...getStylePadding(o),...filterStyles(o),...l(p),...i(p)}},getStylePadding=t=>{let e=["--pt","--pb","--pr","--pl","--pt-mobile","--pb-mobile","--pr-mobile","--pl-mobile","--pt-tablet","--pb-tablet","--pr-tablet","--pl-tablet"],l={};return e.forEach(e=>{t?.[e]&&(l[e]=t[e])}),l},filterStyles=t=>{let e={...t},l=["--pt","--pb","--pr","--pl","--pt-mobile","--pb-mobile","--pr-mobile","--pl-mobile","--pt-tablet","--pb-tablet","--pr-tablet","--pl-tablet"];return l.forEach(t=>{delete e?.[t]}),e};export{displayConditionStyle,filterStyles,getContainerStyles,getContentStyles,getDisplayStyle,getStylePadding};
1
+ import{makeStyle as t,getStyleBackgroundByDevice as e,getGradientBgrStyleByDevice as l}from"@gem-sdk/core";import"react/jsx-runtime";import"react";import{ELEMENT_Z_INDEX as i}from"../../common/const.js";let getCSSPosition=t=>"top"==t?"sticky":"fixed",getDisplayStyle=(t,e,l)=>{let i={[`--top${t}`]:"auto",[`--${l+t}`]:"0",[`--pos${t}`]:getCSSPosition(l)};return"after-first-cart-button"===e&&(i[`--d${t}`]="none"),i},displayConditionStyle=(t,e)=>({...getDisplayStyle("",t?.desktop,e?.desktop),...getDisplayStyle("-tablet",t?.tablet??t?.desktop,e?.tablet??e?.desktop),...getDisplayStyle("-mobile",t?.mobile??t?.tablet??t?.desktop,e?.mobile??e?.tablet??e?.desktop)}),getCSSAlignByDevice=(t,e)=>({[`--left${e}`]:"top"==t?"0":"50%",[`--t${e}`]:"top"==t?"unset":"translateX(-50%)"}),getCSSAlign=t=>({...getCSSAlignByDevice(t?.desktop,""),...getCSSAlignByDevice(t?.tablet??t?.desktop,"-tablet"),...getCSSAlignByDevice(t?.mobile??t?.tablet??t?.desktop,"-mobile")}),getContainerStyles=t=>{let{position:e,display:l}=t;return{margin:"0 auto",...getCSSAlign(e),...displayConditionStyle(l,e),"z-index":i.STICKY}},getContentStyles=i=>{let{style:o,background:p}=i;return{...t({m:"0 auto"}),...getStylePadding(o),...filterStyles(o),...e(p),...l(p)}},getStylePadding=t=>{let e=["--pt","--pb","--pr","--pl","--pt-mobile","--pb-mobile","--pr-mobile","--pl-mobile","--pt-tablet","--pb-tablet","--pr-tablet","--pl-tablet"],l={};return e.forEach(e=>{t?.[e]&&(l[e]=t[e])}),l},filterStyles=t=>{let e={...t},l=["--pt","--pb","--pr","--pl","--pt-mobile","--pb-mobile","--pr-mobile","--pl-mobile","--pt-tablet","--pb-tablet","--pr-tablet","--pl-tablet"];return l.forEach(t=>{delete e?.[t]}),e};export{displayConditionStyle,filterStyles,getContainerStyles,getContentStyles,getDisplayStyle,getStylePadding};
@@ -1,20 +1,20 @@
1
- import{template as s,RenderIf as e,isLocalEnv as t,baseAssetURL as i}from"@gem-sdk/core";import{getSettingPreloadData as r}from"../../helpers.js";import{createStyle as a,createClass as d,createStateOrContext as l}from"@gem-sdk/system";import{getContainerStyles as o,getContentStyles as m}from"../common/styles.js";import{getContainerClasses as p}from"../common/classes.js";let Sticky=({children:c,builderAttrs:g,setting:$,style:n,builderProps:k,advanced:f})=>{let{width:y,position:u,display:b,preloadBgImage:S,background:h,isScrollToTop:j}=$??{},v=f?.d,E=a({...o({position:u,style:n,display:b,width:y})}),w=a(m({width:y,style:n,background:h})),A=d(p({uid:k?.uid,isScrollToTop:j,cssClass:f?.cssClass,isLiquid:!0})),C=l({uid:k?.uid,setting:{display:{desktop:b?.desktop,tablet:b?.tablet??b?.desktop,mobile:b?.mobile??b?.tablet??b?.desktop}},advanced:{d:v}}),G=`.drawer-page-content {
1
+ import{template as s,RenderIf as e,makeStyleResponsive as t,isLocalEnv as i,baseAssetURL as r}from"@gem-sdk/core";import{getSettingPreloadData as a}from"../../helpers.js";import{createStyle as d,createClass as l,createStateOrContext as o}from"@gem-sdk/system";import{getContainerStyles as m,getContentStyles as p}from"../common/styles.js";import{getContainerClasses as c}from"../common/classes.js";let Sticky=({children:g,builderAttrs:$,setting:n,style:k,builderProps:f,advanced:y})=>{let{width:u,position:b,display:S,preloadBgImage:h,background:j,isScrollToTop:v}=n??{},E=y?.d,w=d({...m({position:b,style:k,display:S})}),A=d(p({width:u,style:k,background:j})),C=l(c({uid:f?.uid,isScrollToTop:v,cssClass:y?.cssClass,isLiquid:!0})),G=o({uid:f?.uid,setting:{display:{desktop:S?.desktop,tablet:S?.tablet??S?.desktop,mobile:S?.mobile??S?.tablet??S?.desktop}},advanced:{d:E}}),N=`.drawer-page-content {
2
2
  transform: none !important;
3
3
  -webkit-transform: none !important;
4
4
  }`;return s`
5
- ${e(!!S,`${e(!!h?.desktop?.image?.src,`<link rel="preload" href="${h?.desktop?.image?.src}" as="image" />`)}${e(!!h?.tablet?.image?.src,`<link rel="preload" href="${h?.tablet?.image?.src}" as="image" />`)}${e(!!h?.mobile?.image?.src,`<link rel="preload" href="${h?.mobile?.image?.src}" as="image" />`)}`)}
5
+ ${e(!!h,`${e(!!j?.desktop?.image?.src,`<link rel="preload" href="${j?.desktop?.image?.src}" as="image" />`)}${e(!!j?.tablet?.image?.src,`<link rel="preload" href="${j?.tablet?.image?.src}" as="image" />`)}${e(!!j?.mobile?.image?.src,`<link rel="preload" href="${j?.mobile?.image?.src}" as="image" />`)}`)}
6
6
  <gp-sticky
7
- data-id="${k?.uid}"
8
- gp-data='${JSON.stringify(C)}'
9
- id="${k?.uid}"
10
- data-id="${k?.uid}"
11
- class="${A} ${r("gps-lazy")}"
12
- style="${E}"
7
+ data-id="${f?.uid}"
8
+ gp-data='${JSON.stringify(G)}'
9
+ id="${f?.uid}"
10
+ data-id="${f?.uid}"
11
+ class="${C} ${a("gps-lazy")}"
12
+ style="${w}"
13
13
  >
14
- <style>${G}</style>
15
- <div ${{...g}} style="${{...w}}">
16
- ${c}
14
+ <style>${N}</style>
15
+ <div ${{...$}} style="${{...A,...t("w",u)}}">
16
+ ${g}
17
17
  </div>
18
18
  </gp-sticky>
19
- ${e(t,`<script ${r('class="gps-link" delay',"src")}="{{ 'gp-sticky.js' | asset_url }}" defer="defer"></script>`,`<script ${r('class="gps-link" delay',"src")}="${i}/assets-v2/gp-sticky.js?v={{ shop.metafields.GEMPAGES.ASSETS_VERSION }}" defer="defer"></script>`)}
19
+ ${e(i,`<script ${a('class="gps-link" delay',"src")}="{{ 'gp-sticky.js' | asset_url }}" defer="defer"></script>`,`<script ${a('class="gps-link" delay',"src")}="${r}/assets-v2/gp-sticky.js?v={{ shop.metafields.GEMPAGES.ASSETS_VERSION }}" defer="defer"></script>`)}
20
20
  `};export{Sticky as default};
@@ -1993,41 +1993,18 @@ declare const imageDetectionSetting: {
1993
1993
  ImageDetection: _gem_sdk_core.ComponentSetting<ImageDetectionProps>;
1994
1994
  };
1995
1995
 
1996
- type InputProps = BasePropsWrap<{
1997
- /**
1998
- Type of the Input
1999
- */
1996
+ type InputSettingProps = {
2000
1997
  type?: 'text' | 'number' | 'password' | 'email' | 'hidden' | 'search' | 'tel' | 'url';
2001
- /**
2002
- The initial input content
2003
- */
2004
1998
  defaultValue?: string;
2005
- /**
2006
- Placeholder of the input
2007
- */
2008
1999
  placeholder?: string;
2009
- /**
2010
- Whether the input is disabled
2011
- */
2012
2000
  disabled?: boolean;
2013
- /**
2014
- The prefix icon for the Input
2015
- */
2016
2001
  prefix?: string;
2017
- /**
2018
- The suffix icon for the Input
2019
- */
2020
2002
  suffix?: string;
2021
- /**
2022
- If allow to remove input content with clear icon
2023
- */
2024
2003
  allowClear?: boolean;
2025
- /**
2026
- Handle show/hide password
2027
- */
2028
2004
  passwordToggle?: boolean;
2029
2005
  required?: boolean;
2030
- }> & {
2006
+ };
2007
+ type InputProps = BasePropsWrap<InputSettingProps> & {
2031
2008
  className?: string;
2032
2009
  style?: React.CSSProperties;
2033
2010
  id?: string;
@@ -3884,7 +3861,7 @@ type ProductTagTrigger = {
3884
3861
  };
3885
3862
  type TDisplayTrigger = InventoryStatusTrigger | DiscountPriceTrigger | PriceRangeTrigger | ProductTagTrigger | CreationDateTrigger;
3886
3863
 
3887
- type Setting = {
3864
+ type FileUploadSettingProps = {
3888
3865
  textContent?: string;
3889
3866
  translate?: string;
3890
3867
  fileUploadLayout?: string;
@@ -3903,7 +3880,7 @@ type Setting = {
3903
3880
  contentWidth?: ObjectDevices<string>;
3904
3881
  paddingSize?: ObjectDevices<SizeSettingGlobal>;
3905
3882
  };
3906
- type Style = {
3883
+ type FileUploadStyleProps = {
3907
3884
  typo?: TypographySettingV2;
3908
3885
  borderBtn?: StateProp<Border>;
3909
3886
  hasBoxShadowBtn?: StateProp<boolean>;
@@ -3915,11 +3892,11 @@ type Style = {
3915
3892
  align?: ObjectDevices<string>;
3916
3893
  textAlign?: ObjectDevices<AlignProp>;
3917
3894
  };
3918
- type FileUploadProps = BasePropsWrap<Setting, Style> & {
3895
+ type FileUploadProps = BasePropsWrap<FileUploadSettingProps, FileUploadStyleProps> & {
3919
3896
  pageContext?: PageContext;
3920
3897
  };
3921
3898
 
3922
- type ProductBundleDiscountProps = BasePropsWrap<{
3899
+ type ProductBundleDiscountSettingProps = {
3923
3900
  enableDisplayCondition?: boolean;
3924
3901
  childItem?: string[];
3925
3902
  hideNoDiscountItem?: boolean;
@@ -3934,7 +3911,8 @@ type ProductBundleDiscountProps = BasePropsWrap<{
3934
3911
  bundleItems?: bundleItem[];
3935
3912
  useProductCompareAtPrice?: boolean;
3936
3913
  iconItemColor?: ColorValueType;
3937
- }, {
3914
+ };
3915
+ type ProductBundleDiscountStyleProps = {
3938
3916
  size?: ObjectDevices<SizeSettingGlobal>;
3939
3917
  backgroundColor?: StateProp<ColorValueType>;
3940
3918
  iconColor?: StateProp<ColorValueType>;
@@ -3943,7 +3921,8 @@ type ProductBundleDiscountProps = BasePropsWrap<{
3943
3921
  borderBundle?: StateProp<Border>;
3944
3922
  roundedBundle?: StateProp<CornerRadius>;
3945
3923
  align?: string;
3946
- }> & {
3924
+ };
3925
+ type ProductBundleDiscountProps = BasePropsWrap<ProductBundleDiscountSettingProps, ProductBundleDiscountStyleProps> & {
3947
3926
  children: React.ReactNode[];
3948
3927
  rawChildren?: any[];
3949
3928
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gem-sdk/components",
3
- "version": "2.0.0-staging.867",
3
+ "version": "2.0.0-staging.869",
4
4
  "license": "MIT",
5
5
  "sideEffects": false,
6
6
  "main": "dist/cjs/index.js",