@gem-sdk/components 2.0.0-staging.1009 → 2.0.0-staging.1011
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/grid/settings/configs/section/ui-v2.js +1 -1
- package/dist/cjs/icon-list-v2/common/styles.js +1 -1
- package/dist/cjs/icon-list-v2/components/IconList.js +1 -1
- package/dist/cjs/post-purchase/product/settings/product-quantity/configs/ui-v2.js +1 -1
- package/dist/cjs/product/components/product-quantity/ProductQuantity.js +1 -1
- package/dist/cjs/product/components/product-quantity/ProductQuantity.liquid.js +20 -20
- package/dist/cjs/product/components/product-quantity/common/attrs.js +1 -1
- package/dist/cjs/product/components/product-quantity/common/classes.js +1 -1
- package/dist/cjs/product/components/product-quantity/common/styles.js +1 -1
- package/dist/cjs/product/settings/product-quantity/configs/presets.js +11 -13
- package/dist/cjs/product/settings/product-quantity/configs/settings.js +2 -2
- package/dist/cjs/product/settings/product-quantity/configs/ui-v2.js +1 -1
- package/dist/cjs/sticky/settings/configs/presets.js +2 -2
- package/dist/esm/grid/settings/configs/section/ui-v2.js +1 -1
- package/dist/esm/icon-list-v2/common/styles.js +1 -1
- package/dist/esm/icon-list-v2/components/IconList.js +1 -1
- package/dist/esm/post-purchase/product/settings/product-quantity/configs/ui-v2.js +1 -1
- package/dist/esm/product/components/product-quantity/ProductQuantity.js +1 -1
- package/dist/esm/product/components/product-quantity/ProductQuantity.liquid.js +21 -21
- package/dist/esm/product/components/product-quantity/common/attrs.js +1 -1
- package/dist/esm/product/components/product-quantity/common/classes.js +1 -1
- package/dist/esm/product/components/product-quantity/common/styles.js +1 -1
- package/dist/esm/product/settings/product-quantity/configs/presets.js +11 -13
- package/dist/esm/product/settings/product-quantity/configs/settings.js +2 -2
- package/dist/esm/product/settings/product-quantity/configs/ui-v2.js +1 -1
- package/dist/esm/sticky/settings/configs/presets.js +2 -2
- package/dist/types/index.d.ts +6 -5
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const SettingUIV2=[{controls:[{setting:{id:"layout"},layout:"vertical"}]},{label:{en:"Column spacing"},conditionDisplay:"childrens > 1",controls:[{setting:{id:"verticalGutter"},label:{en:"Gap"},conditionDisplay:'layout.cols.length > 1 && pageType !== "POST_PURCHASE"',controlChangeTrigger:{settings:[{condition:"activeScreenId !== 'desktop'",action:{controlId:"verticalGutterMobile",groupType:"style",controlType:"style"}}],options:{noRecordHistory:!0}}},{setting:{id:"verticalGutterMobile"},label:{en:"Gap"},conditionDisplay:'layout.cols.length === 1 && pageType !== "POST_PURCHASE"',controlChangeTrigger:{settings:[{condition:"activeScreenId !== 'desktop'",action:{controlId:"verticalGutter",groupType:"style",controlType:"style"}}],options:{noRecordHistory:!0}}},{label:{en:"Column gap"},setting:{id:"columnGap"},conditionDisplay:'pageType == "POST_PURCHASE"',conditionEnable:"!!layout.cols && layout.cols.length > 1"}]},{label:{en:"Size"},controls:[{id:"Width",setting:{id:"width"},label:{en:"Width"},layout:"horizontal"},{label:{en:"Padding"},controlConfig:{id:"padding",type:"padding-v2",linkWithSetting:{name:"spacing-setting",field:"padding"},compoDefaultValue:{desktop:{default:{top:"var(--g-s-2xl)",bottom:"var(--g-s-2xl)"}},tablet:{default:{top:"var(--g-s-2xl)",bottom:"var(--g-s-2xl)",left:"var(--g-s-l)",right:"var(--g-s-l)",linked:!1}}}},conditionDisplay:'pageType !== "POST_PURCHASE"'},{setting:{id:"enablePagePadding"},label:{en:"Page padding"},help:{content:"Page padding controls the <br> space between the browser <br> edge and sections. Adjust it in <br> Global Style > Page Padding."},conditionDisplay:'pageType !== "POST_PURCHASE"'}]},{label:{en:"Background"},conditionDisplay:'pageType != "POST_PURCHASE"',controls:[{setting:{id:"background"},layout:"vertical",options:{updateFields:[{field:"preload",settingId:"preloadBgImage"}]},controlChangeTrigger:{settings:[{action:{controlId:"preloadBgImage",valueFromField:"preload",groupType:"style",controlType:"style",removeDevice:!0}}],options:{noRecordHistory:!0}}}]},{label:{en:"Shape"},conditionDisplay:'pageType != "POST_PURCHASE"',controls:[{label:{en:"Border"},controlConfig:{id:"border-advanced",type:"border-v2",linkWithSetting:{name:"border",field:"normal"},compoDefaultValue:{color:"line-3",border:"solid",width:"1px",borderWidth:"1px"}}},{label:{en:"Corner"},setting:{id:"rounded",state:"normal"}},{label:{en:"Shadow"},setting:{id:"boxShadow",state:"normal"},controlConfig:{id:"boxShadow",type:"shadow-v2"},options:{updateFields:[{field:"normal.enable",settingId:"hasBoxShadow",state:"normal"}]},controlChangeTrigger:{settings:[{condition:"boxShadow.normal.enable === true",source:["boxShadow","hasBoxShadow"],action:{controlId:"hasBoxShadow",groupType:"advanced",controlType:"advanced",state:"normal",newValue:!0}},{condition:"boxShadow.normal.enable === false",source:["boxShadow","hasBoxShadow"],action:{controlId:"hasBoxShadow",groupType:"advanced",controlType:"advanced",state:"normal",newValue:!1}}],options:{noRecordHistory:!0}}}]},{label:{en:"Align"},conditionDisplay:"pageType != \"POST_PURCHASE\" && (layout.display !== 'fill' || (!!layout.cols && layout.cols.length > 1))",controls:[{id:"verticalAlign",label:{en:"Vertical"},setting:{id:"verticalAlign"},conditionDisplay:"!!layout.cols && layout.cols.length > 1"},{id:"horizontalAlign",label:{en:"Horizontal"},setting:{id:"horizontalAlign"},conditionDisplay:"layout.display !== 'fill'",options:{disableMessage:'Horizontal Align is available when layout is "Fit to content"'}}]}];exports.SettingUIV2=SettingUIV2;
|
|
1
|
+
"use strict";const SettingUIV2=[{controls:[{setting:{id:"layout"},layout:"vertical"}]},{label:{en:"Column spacing"},conditionDisplay:"childrens > 1",controls:[{setting:{id:"verticalGutter"},label:{en:"Gap"},conditionDisplay:'layout.cols.length > 1 && pageType !== "POST_PURCHASE"',controlChangeTrigger:{settings:[{condition:"activeScreenId !== 'desktop'",action:{controlId:"verticalGutterMobile",groupType:"style",controlType:"style"}}],options:{noRecordHistory:!0}}},{setting:{id:"verticalGutterMobile"},label:{en:"Gap"},conditionDisplay:'layout.cols.length === 1 && pageType !== "POST_PURCHASE"',controlChangeTrigger:{settings:[{condition:"activeScreenId !== 'desktop'",action:{controlId:"verticalGutter",groupType:"style",controlType:"style"}}],options:{noRecordHistory:!0}}},{label:{en:"Column gap"},setting:{id:"columnGap"},conditionDisplay:'pageType == "POST_PURCHASE"',conditionEnable:"!!layout.cols && layout.cols.length > 1"}]},{label:{en:"Size"},controls:[{id:"Width",setting:{id:"width"},label:{en:"Width"},layout:"horizontal",conditionDisplay:'pageType !== "POST_PURCHASE"'},{label:{en:"Width"},layout:"horizontal",controlConfig:{id:"width-post-purchase",type:"dropdown:input",label:"Width",inputType:"number",units:["px","%"],hideUnit:!1,isRowWith:!0,linkWithSetting:{name:"width"},displayOptions:[{label:"Full",value:"100%",showValue:!0}]},conditionDisplay:'pageType === "POST_PURCHASE"'},{label:{en:"Padding"},controlConfig:{id:"padding",type:"padding-v2",linkWithSetting:{name:"spacing-setting",field:"padding"},compoDefaultValue:{desktop:{default:{top:"var(--g-s-2xl)",bottom:"var(--g-s-2xl)"}},tablet:{default:{top:"var(--g-s-2xl)",bottom:"var(--g-s-2xl)",left:"var(--g-s-l)",right:"var(--g-s-l)",linked:!1}}}},conditionDisplay:'pageType !== "POST_PURCHASE"'},{setting:{id:"enablePagePadding"},label:{en:"Page padding"},help:{content:"Page padding controls the <br> space between the browser <br> edge and sections. Adjust it in <br> Global Style > Page Padding."},conditionDisplay:'pageType !== "POST_PURCHASE"'}]},{label:{en:"Background"},conditionDisplay:'pageType != "POST_PURCHASE"',controls:[{setting:{id:"background"},layout:"vertical",options:{updateFields:[{field:"preload",settingId:"preloadBgImage"}]},controlChangeTrigger:{settings:[{action:{controlId:"preloadBgImage",valueFromField:"preload",groupType:"style",controlType:"style",removeDevice:!0}}],options:{noRecordHistory:!0}}}]},{label:{en:"Shape"},conditionDisplay:'pageType != "POST_PURCHASE"',controls:[{label:{en:"Border"},controlConfig:{id:"border-advanced",type:"border-v2",linkWithSetting:{name:"border",field:"normal"},compoDefaultValue:{color:"line-3",border:"solid",width:"1px",borderWidth:"1px"}}},{label:{en:"Corner"},setting:{id:"rounded",state:"normal"}},{label:{en:"Shadow"},setting:{id:"boxShadow",state:"normal"},controlConfig:{id:"boxShadow",type:"shadow-v2"},options:{updateFields:[{field:"normal.enable",settingId:"hasBoxShadow",state:"normal"}]},controlChangeTrigger:{settings:[{condition:"boxShadow.normal.enable === true",source:["boxShadow","hasBoxShadow"],action:{controlId:"hasBoxShadow",groupType:"advanced",controlType:"advanced",state:"normal",newValue:!0}},{condition:"boxShadow.normal.enable === false",source:["boxShadow","hasBoxShadow"],action:{controlId:"hasBoxShadow",groupType:"advanced",controlType:"advanced",state:"normal",newValue:!1}}],options:{noRecordHistory:!0}}}]},{label:{en:"Align"},conditionDisplay:"pageType != \"POST_PURCHASE\" && (layout.display !== 'fill' || (!!layout.cols && layout.cols.length > 1))",controls:[{id:"verticalAlign",label:{en:"Vertical"},setting:{id:"verticalAlign"},conditionDisplay:"!!layout.cols && layout.cols.length > 1"},{id:"horizontalAlign",label:{en:"Horizontal"},setting:{id:"horizontalAlign"},conditionDisplay:"layout.display !== 'fill'",options:{disableMessage:'Horizontal Align is available when layout is "Fit to content"'}}]}];exports.SettingUIV2=SettingUIV2;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var core=require("@gem-sdk/core");const filterStyles=e=>{let t=["--mb","--mb-mobile","--mb-tablet"];return t.forEach(t=>{delete e?.[t]}),e},getStyleContainerIconlistMain=({styles:e,style:t,type:o})=>{let{align:
|
|
1
|
+
"use strict";var core=require("@gem-sdk/core");const filterStyles=e=>{let t=["--mb","--mb-mobile","--mb-tablet"];return t.forEach(t=>{delete e?.[t]}),e},getStyleContainerIconlistMain=({styles:e,style:t,type:o,advanced:r})=>{let{align:l}=e??{};return{...t="react"===o?filterStyles(t):t,...core.makeStyleResponsive("jc",l),...core.makeStyleResponsive("d",{desktop:r?.d?.desktop?"flex":"none",tablet:r?.d?.tablet?"flex":"none",mobile:r?.d?.mobile?"flex":"none"})}},getStyleWraplistIcon=({styles:e})=>{let{panelAlign:t,contentBoxPadding:o,contentBoxWidth:r,background:l,contentBoxBorder:i,contentBoxRounded:s,contentBoxShadow:n}=e??{};return{...core.composeBorderResponsive(i),...core.getResponsiveStyleShadowWithoutState(n,"box-shadow",n),...core.composeRadiusResponsive(s),...core.getStyleBackgroundByDevice(l),...core.getResponsiveStylePadding(o),...core.makeStyleResponsive("w",r),...core.makeStyleResponsive("jc",t),...core.getGradientBgrStyleByDevice(l,{desktop:!0,tablet:!0,mobile:!0})}},getStyleColListIcon=({styles:e})=>{let{verticalSpacing:t}=e??{};return{...core.makeStyleResponsive("rg",t)}},getStyleWrapItemIcon=({styles:e})=>{let{horizontalSpacing:t,position:o}=e??{};return{...core.makeStyleResponsive("cg",t),...core.makeStyleResponsive("ai",o)}},getStyleWrapIcon=({styles:e,setting:t})=>{let{iconBorder:o,backgroundColor:r,iconRounded:l}=e??{},{globalSize:i}=t??{},s=core.makeGlobalSize(i);return{...s.padding,...core.makeStyle({bs:o?.border,bw:o?.width,bc:core.getSingleColorVariable(o?.color),bg:r,bblr:l?.bblr,bbrr:l?.bbrr,btlr:l?.btlr,btrr:l?.btrr}),...core.makeStyleResponsive("pos",{desktop:"relative",tablet:"relative",mobile:"relative"}),...core.makeStyleResponsive("top",{desktop:"inherit",tablet:"inherit",mobile:"inherit"})}},getStyleIcon=({styles:e,setting:t})=>{let{iconColor:o}=e||{},{iconWidth:r}=t??{};return{"--c":core.getSingleColorVariable(o),"--w":"100%","--h":"100%","--size-desktop":`${r?.desktop}px`,"--size-tablet":`${r?.tablet||r?.desktop}px`,"--size-mobile":`${r?.mobile||r?.tablet||r?.desktop}px`}},getStyleTypoText=({setting:e})=>({typo:e?.textTypo});exports.getStyleColListIcon=getStyleColListIcon,exports.getStyleContainerIconlistMain=getStyleContainerIconlistMain,exports.getStyleIcon=getStyleIcon,exports.getStyleTypoText=getStyleTypoText,exports.getStyleWrapIcon=getStyleWrapIcon,exports.getStyleWrapItemIcon=getStyleWrapItemIcon,exports.getStyleWraplistIcon=getStyleWraplistIcon;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var jsxRuntime=require("react/jsx-runtime"),useGetProductId=require("../../hooks/useGetProductId.js"),React=require("react"),Text=require("../../text/components/Text.js"),system=require("@gem-sdk/system"),classes=require("../common/classes.js"),styles=require("../common/styles.js"),helpers=require("../common/helpers.js");const IconListV2=e=>{let{builderProps:s,builderAttrs:t,style:l,setting:a,styles:r,pageContext:c}=e,
|
|
2
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var jsxRuntime=require("react/jsx-runtime"),useGetProductId=require("../../hooks/useGetProductId.js"),React=require("react"),Text=require("../../text/components/Text.js"),system=require("@gem-sdk/system"),classes=require("../common/classes.js"),styles=require("../common/styles.js"),helpers=require("../common/helpers.js");const IconListV2=e=>{let{builderProps:s,builderAttrs:t,style:l,setting:a,styles:r,pageContext:c,advanced:y}=e,n=system.createClass({[s?.uid??""]:!0}),i=system.createClass(classes.getClassWraplistIcon()),m=system.createClass(classes.getClassColListIcon()),o=system.createClass(classes.getClassWrapItemIcon({builderProps:s})),u=system.createClass(classes.getClassWrapIcon()),d=system.createClass(classes.getClassIcon()),x=system.createClass(classes.getClassTextItem({setting:a})),p=system.createStyle(styles.getStyleContainerIconlistMain({styles:r,style:l,type:"react",advanced:y})),I=system.createStyle(styles.getStyleWraplistIcon({styles:r})),j=system.createStyle(styles.getStyleColListIcon({styles:r})),g=system.createStyle(styles.getStyleWrapIcon({styles:r,setting:a})),C=system.createStyle(styles.getStyleWrapItemIcon({styles:r})),S=system.createStyle(styles.getStyleIcon({styles:r,setting:a})),h=styles.getStyleTypoText({setting:a}),R=system.createAttr({...t}),T=helpers.getTextIconNotFound("react"),v=helpers.getvalueMap({setting:a}),q=React.useRef(null),{refContainer:f,productID:N}=useGetProductId.useGetProductId();return jsxRuntime.jsx("div",{...R,...s,"data-id":s?.uid,style:p,className:n,ref:f,children:system.If(!v||!v.length,jsxRuntime.jsx("div",{children:T}),jsxRuntime.jsx("div",{className:i,style:I,children:jsxRuntime.jsx("div",{className:m,style:j,children:v?.map((e,t)=>{let l=helpers.getTextIconTranslations({setting:a,builderProps:s,pageContext:c,key:t,type:"react"});return jsxRuntime.jsxs("div",{"data-index":t,className:o,style:C,children:[jsxRuntime.jsx("div",{className:u,style:g,children:jsxRuntime.jsx("span",{style:S,className:d,dangerouslySetInnerHTML:{__html:e}})}),jsxRuntime.jsx(Text.default,{setting:{text:l?.toString(),htmlTag:"div",options:{useState:!0,uniqueId:`${s?.uid}-${t}-${N}`,productID:N,customClass:{wrapper:"gp-w-full"}}},styles:h,className:x,ref:q})]},t)})})}))})};exports.default=IconListV2;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const SettingUIV2=[{label:{en:"Size"},controls:[{type:"control",label:{en:"Width"},setting:{id:"inputWidth"},layout:"horizontal"}]},{label:{en:"Display"},controls:[{label:{en:"Default quantity"},setting:{id:"defaultQtyValue"},layout:"horizontal"},{type:"combo",label:{en:"Label title"},iconName:"polaris-text-block",getValueFromSettingID:"title",disableClearMessage:"This label title is needed for customers <br> to adjust the product's quantity",controls:[{label:{en:"Content"},setting:{id:"title"},layout:"vertical",options:{clearButton:!1}}]}]},{controls:[{type:"control",label:{en:"Align"},setting:{id:"align"},conditionEnable:'!(parseInt(inputWidth) >= 100 && inputWidth?.includes("%"))',options:{labelVariant:"primary",fullWidth:!0,disableMessage:"Horizontal alignment is disabled when the width is set to 100% or greater"},layout:"horizontal"}]}];exports.SettingUIV2=SettingUIV2;
|
|
1
|
+
"use strict";const SettingUIV2=[{label:{en:"Size"},controls:[{type:"control",label:{en:"Width"},setting:{id:"inputWidth"},layout:"horizontal"}]},{label:{en:"Display options"},controls:[{label:{en:"Default quantity"},setting:{id:"defaultQtyValue"},layout:"horizontal"},{type:"combo",label:{en:"Label title"},iconName:"polaris-text-block",getValueFromSettingID:"title",disableClearMessage:"This label title is needed for customers <br> to adjust the product's quantity",controls:[{label:{en:"Content"},setting:{id:"title"},layout:"vertical",options:{clearButton:!1}}]}]},{controls:[{type:"control",label:{en:"Align"},setting:{id:"align"},conditionEnable:'!(parseInt(inputWidth) >= 100 && inputWidth?.includes("%"))',options:{labelVariant:"primary",fullWidth:!0,disableMessage:"Horizontal alignment is disabled when the width is set to 100% or greater"},layout:"horizontal"}]}];exports.SettingUIV2=SettingUIV2;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var jsxRuntime=require("react/jsx-runtime"),core=require("@gem-sdk/core"),system=require("@gem-sdk/system"),useProductQuantity=require("./hooks/useProductQuantity.js"),attrs=require("./common/attrs.js"),classes=require("./common/classes.js"),styles=require("./common/styles.js"),helpers=require("./common/helpers.js");const ProductQuantity=e=>{let{setting:
|
|
2
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var jsxRuntime=require("react/jsx-runtime"),core=require("@gem-sdk/core"),system=require("@gem-sdk/system"),useProductQuantity=require("./hooks/useProductQuantity.js"),attrs=require("./common/attrs.js"),classes=require("./common/classes.js"),styles=require("./common/styles.js"),helpers=require("./common/helpers.js");const ProductQuantity=e=>{let{setting:s={},styles:t={},builderProps:r,advanced:a}=e,l=core.useCurrentVariant(),{quantity:n}=core.useQuantity(),{isInStock:u,ref:c,onClickIncrement:o,onClickDecrement:y,onChangeInput:i,onFocusInput:m}=useProductQuantity.useProductQuantity(e),{plusIcon:d,minusIcon:g}=s,j=s.defaultQtyValue||1,{inputHeight:p,buttonBackgroundColor:C,backgroundColor:h,iconColor:x,inputBackgroundColor:S,textColor:b,align:B,borderBtn:I,buttonWidth:f,iconSizeCustom:q,corner:v}=t,A=s?.hasButton,P=system.createAttr({...attrs.getContainerAttrs({isDisabled:!u,uid:r?.uid||""})}),Q=system.createClass({...classes.getContainerClasses(a?.cssClass)}),R=system.createStyle({...styles.getContainerStyles({align:B,inputHeight:p})}),N=system.createClass({...classes.getWrapperClasses()}),H=system.createStyle({...styles.getWrapperStyles({backgroundColor:h,styles:t,setting:s})}),_=system.createAttr({...attrs.getInputAttr({hasButton:A,quantity:n,currentVariant:l,defaultQty:j})}),k=system.createClass({...classes.getInputClasses({styles:t,borderBtn:I,inputBackgroundColor:S,textColor:b,isDisabled:!u})}),D=system.createStyle({...styles.getInputStyle(e)}),M=system.createClass({...classes.getButtonClass({borderBtn:I,buttonBackgroundColor:C,iconColor:x,buttonSide:"left",isDisabled:!u})}),W=system.createStyle({...styles.getButtonStyle({borderBtn:I,buttonWidth:f,buttonBackgroundColor:C,iconColor:x,corner:v,enableHoverButton:s?.enableHoverButton})}),L=system.createAttr({...attrs.getButtonAttrs({buttonSide:"left"})}),T=system.createClass({...classes.getButtonClass({borderBtn:I,buttonBackgroundColor:C,iconColor:x,buttonSide:"right",isDisabled:!u})}),V=system.createStyle({...styles.getButtonStyle({borderBtn:I,buttonWidth:f,buttonBackgroundColor:C,iconColor:x,corner:v,enableHoverButton:s?.enableHoverButton})}),F=system.createAttr({...attrs.getButtonAttrs({buttonSide:"right"})}),O=system.createClass({...classes.getIconWrapperClasses()}),w=system.createStyle({...helpers.getIconWidth(q)});return jsxRuntime.jsx("div",{ref:c,...P,className:Q,style:R,children:jsxRuntime.jsxs("div",{className:N,style:H,children:[system.If(A,jsxRuntime.jsx("button",{...L,onClick:y,className:M,style:W,children:jsxRuntime.jsx("span",{className:O,style:w,dangerouslySetInnerHTML:{__html:helpers.getMinusIcon(g)}})})),jsxRuntime.jsx("input",{..._,className:k,style:D,onChange:e=>i(e),onFocus:e=>m(e)}),system.If(A,jsxRuntime.jsx("button",{...F,onClick:o,className:T,style:V,children:jsxRuntime.jsx("span",{className:O,style:w,dangerouslySetInnerHTML:{__html:helpers.getPlusIcon(d)}})}))]})})};exports.default=ProductQuantity;
|
|
@@ -1,45 +1,45 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var core=require("@gem-sdk/core"),helpers$1=require("../../../helpers.js"),system=require("@gem-sdk/system"),attrs=require("./common/attrs.js"),classes=require("./common/classes.js"),styles=require("./common/styles.js"),helpers=require("./common/helpers.js");const ProductQuantity=({setting:e={},styles:t={},advanced:s,builderProps:a})=>{let{
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var core=require("@gem-sdk/core"),helpers$1=require("../../../helpers.js"),system=require("@gem-sdk/system"),attrs=require("./common/attrs.js"),classes=require("./common/classes.js"),styles=require("./common/styles.js"),helpers=require("./common/helpers.js");const ProductQuantity=({setting:e={},styles:t={},advanced:s,builderProps:a})=>{let{plusIcon:r,minusIcon:l,updatePrice:n}=e,i=e.defaultQtyValue??1,{inputHeight:c,buttonBackgroundColor:o,iconColor:u,inputBackgroundColor:y,textColor:d,align:p,borderBtn:g,buttonWidth:m,iconSizeCustom:$,corner:f,backgroundColor:b,dividerColor:S,dividerStroke:v}=t,C=e?.hasButton,h=system.createAttr({...attrs.getContainerAttrs({uid:a?.uid||"",isDisableByLiquid:!0})}),q=system.createClass({...classes.getContainerClasses(s?.cssClass)}),B=system.createStyle({...styles.getContainerStyles({align:p,inputHeight:c})}),A=system.createClass({...classes.getWrapperClasses()}),I=system.createStyle({...styles.getWrapperStyles({backgroundColor:b,styles:t,setting:e})}),_=system.createAttr({...attrs.getInputAttr({isLiquid:!0,hasButton:C,defaultQty:i})}),j=system.createClass({...classes.getInputClasses({styles:t,borderBtn:g,inputBackgroundColor:y,textColor:d})}),P=system.createStyle({...styles.getInputStyle({setting:e,styles:{...t,borderBtn:g,inputBackgroundColor:y,textColor:d,dividerColor:S,dividerStroke:v}})}),E=system.createClass({...classes.getButtonClass({borderBtn:g,buttonBackgroundColor:o,iconColor:u,buttonSide:"left"})}),R=system.createStyle({...styles.getButtonStyle({borderBtn:g,buttonWidth:m,buttonBackgroundColor:o,iconColor:u,corner:f,enableHoverButton:e?.enableHoverButton})}),k=system.createAttr({...attrs.getButtonAttrs({buttonSide:"left"})}),H=system.createClass({...classes.getButtonClass({borderBtn:g,buttonBackgroundColor:o,iconColor:u,buttonSide:"right"})}),L=system.createStyle({...styles.getButtonStyle({borderBtn:g,buttonWidth:m,buttonBackgroundColor:o,iconColor:u,corner:f,enableHoverButton:e?.enableHoverButton})}),M=system.createAttr({...attrs.getButtonAttrs({buttonSide:"right"})}),W=system.createClass({...classes.getIconWrapperClasses()}),D=helpers.getIconWidth($);return core.template`
|
|
2
2
|
{%- liquid
|
|
3
3
|
assign current_variant = product.selected_or_first_available_variant
|
|
4
4
|
assign available = current_variant.available | default: false
|
|
5
5
|
-%}
|
|
6
6
|
<gp-product-quantity
|
|
7
|
-
${{...
|
|
8
|
-
data-price="${
|
|
9
|
-
class="${
|
|
7
|
+
${{...h}}
|
|
8
|
+
data-price="${n}"
|
|
9
|
+
class="${q}"
|
|
10
10
|
style="${B}"
|
|
11
11
|
>
|
|
12
|
-
<div class="${
|
|
13
|
-
${core.RenderIf(
|
|
12
|
+
<div class="${A}" style="${I}">
|
|
13
|
+
${core.RenderIf(C,core.template`
|
|
14
14
|
<button
|
|
15
15
|
{% if available == false %} disabled {% endif %}
|
|
16
|
-
${{...
|
|
17
|
-
class="${
|
|
18
|
-
style="${
|
|
16
|
+
${{...k}}
|
|
17
|
+
class="${E}"
|
|
18
|
+
style="${R}"
|
|
19
19
|
>
|
|
20
|
-
<span class="${
|
|
20
|
+
<span class="${W}" style="${D}"
|
|
21
21
|
>
|
|
22
|
-
${helpers.getMinusIcon(
|
|
22
|
+
${helpers.getMinusIcon(l)}
|
|
23
23
|
</span>
|
|
24
24
|
</button>
|
|
25
25
|
`)}
|
|
26
26
|
<input
|
|
27
27
|
{% if available == false %} disabled {% endif %}
|
|
28
|
-
${{...
|
|
29
|
-
class="${
|
|
30
|
-
style="${
|
|
28
|
+
${{..._}}
|
|
29
|
+
class="${j}"
|
|
30
|
+
style="${P}"
|
|
31
31
|
inputMode="numeric"
|
|
32
32
|
/>
|
|
33
33
|
|
|
34
|
-
${core.RenderIf(
|
|
34
|
+
${core.RenderIf(C,core.template`
|
|
35
35
|
<button
|
|
36
36
|
{% if available == false %} disabled {% endif %}
|
|
37
|
-
${{...
|
|
38
|
-
class="${
|
|
39
|
-
style="${
|
|
37
|
+
${{...M}}
|
|
38
|
+
class="${H}"
|
|
39
|
+
style="${L}"
|
|
40
40
|
>
|
|
41
|
-
<span class="${
|
|
42
|
-
${helpers.getPlusIcon(
|
|
41
|
+
<span class="${W}" style="${D}">
|
|
42
|
+
${helpers.getPlusIcon(r)}
|
|
43
43
|
</span>
|
|
44
44
|
</button>
|
|
45
45
|
`)}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const getContainerAttrs=({uid:t,isDisabled:e=!0,isDisableByLiquid:n})=>({"data-id":t,"data-disabled":n?"{%- if available -%} false {%- else -%} true {%- endif -%}":e}),getButtonAttrs=({buttonSide:t})=>({title:"left"===t?"Decrement":"Increment","aria-label":"left"===t?"decrement":"increment",type:"button"}),getInputAttr=({isLiquid:t,
|
|
1
|
+
"use strict";const getContainerAttrs=({uid:t,isDisabled:e=!0,isDisableByLiquid:n})=>({"data-id":t,"data-disabled":n?"{%- if available -%} false {%- else -%} true {%- endif -%}":e}),getButtonAttrs=({buttonSide:t})=>({title:"left"===t?"Decrement":"Increment","aria-label":"left"===t?"decrement":"increment",type:"button"}),getInputAttr=({isLiquid:t,hasButton:e,quantity:n,currentVariant:r,defaultQty:a})=>{let i={};return r?.manageInventory&&(i.max=t?"{{ current_variant.quantity_rule.max }}":r?.inventoryQuantity??1),{type:e?"text":"number",name:"quantity",step:1,min:1,"aria-label":"quantity",inputMode:"numeric",quantity:t?"current_variant.quantity":n??0,autocomplete:"off",value:n??a??1,...i}};exports.getButtonAttrs=getButtonAttrs,exports.getContainerAttrs=getContainerAttrs,exports.getInputAttr=getInputAttr;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var core=require("@gem-sdk/core");const getInputClasses=({styles:e,borderBtn:s,inputBackgroundColor:t,textColor:o,isDisabled:l})=>{let r="gp-flex gp-w-full gp-px-1 gp-min-w-[45px] gp-shrink-[99999] gp-appearance-none gp-items-center gp-text-center gp-outline-none gp-transition-all gp-duration-150 hover:gp-text-black disabled:gp-cursor-not-allowed",p=core.composeTypographyClassName(e?.typo,e?.typography),a=core.handleConvertClassColor(s),g=core.getGlobalColorStateClass("bg",t),n=core.getGlobalColorStateClass("text",o);return a&&(r+=` ${a} `),p&&(r+=` ${p} `),g&&(r+=` ${g} `),n&&(r+=` ${n} `),l&&(r+="gp-cursor-not-allowed"),{...core.composeClasses(r)}},getButtonClass=({borderBtn:e,buttonBackgroundColor:s,iconColor:t,buttonSide:o,isDisabled:l})=>{let r=`gp-flex gp-aspect-square gp-h-full disabled:gp-cursor-not-allowed ${l?"gp-cursor-not-allowed":"gp-cursor-pointer"} gp-items-center gp-justify-center gp-outline-none ${"left"===o?"
|
|
1
|
+
"use strict";var core=require("@gem-sdk/core");const getInputClasses=({styles:e,borderBtn:s,inputBackgroundColor:t,textColor:o,isDisabled:l})=>{let r="gp-flex gp-w-full gp-px-1 gp-min-w-[45px] gp-shrink-[99999] gp-appearance-none gp-items-center gp-text-center gp-outline-none gp-transition-all gp-duration-150 hover:gp-text-black disabled:gp-cursor-not-allowed",p=core.composeTypographyClassName(e?.typo,e?.typography),a=core.handleConvertClassColor(s),g=core.getGlobalColorStateClass("bg",t),n=core.getGlobalColorStateClass("text",o);return a&&(r+=` ${a} `),p&&(r+=` ${p} `),g&&(r+=` ${g} `),n&&(r+=` ${n} `),l&&(r+="gp-cursor-not-allowed"),{...core.composeClasses(r)}},getButtonClass=({borderBtn:e,buttonBackgroundColor:s,iconColor:t,buttonSide:o,isDisabled:l})=>{let r=`gp-flex gp-aspect-square gp-h-full disabled:gp-cursor-not-allowed ${l?"gp-cursor-not-allowed":"gp-cursor-pointer"} gp-items-center gp-justify-center gp-outline-none ${"left"===o?"gp-minus":"gp-plus"} `,p=core.handleConvertClassColor(e),a=core.getGlobalColorStateClass("bg",s),g=core.getGlobalColorStateClass("text",t);return p&&(r+=` ${p} `),a&&(r+=` ${a} `),g&&(r+=` ${g} `),{...core.composeClasses(r)}},getContainerClasses=e=>({...core.composeClasses(`quantityClass gp-relative gp-inline-flex gp-h-12 gp-w-full gp-bg-transparent gp-transition-all gp-duration-150 data-[disabled=true]:gp-opacity-60 ${e??""}`)}),getWrapperClasses=()=>({...core.composeClasses("gp-inline-flex gp-w-full gp-overflow-hidden")}),getIconWrapperClasses=()=>({...core.composeClasses("gp-inline-flex gp-items-center gp-justify-center [&>*]:gp-h-full [&>*]:gp-w-full")});exports.getButtonClass=getButtonClass,exports.getContainerClasses=getContainerClasses,exports.getIconWrapperClasses=getIconWrapperClasses,exports.getInputClasses=getInputClasses,exports.getWrapperClasses=getWrapperClasses;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var core=require("@gem-sdk/core");const addPxToValues=e=>Object.fromEntries(Object.entries(e).map(([e,t])=>[e,`${t}px`])),getDividerWidth=(e,t)=>{if(!e)return{};let
|
|
1
|
+
"use strict";var core=require("@gem-sdk/core");const addPxToValues=e=>Object.fromEntries(Object.entries(e).map(([e,t])=>[e,`${t}px`])),getDividerWidth=(e,t)=>{if(!e||!t)return{};let o=addPxToValues(e),r={...core.makeStyleState("brw",o),...core.makeStyleState("blw",o)};return r},getDividerColorStyle=e=>{if(!e)return{};let t={...e,normal:e?.normal??"transparent"},o={...core.getGlobalColorStateStyle("brc",t),...core.getGlobalColorStateStyle("blc",t)},r=Object.fromEntries(Object.entries(o).filter(([e,t])=>void 0!==t));return r},getInputStyle=e=>{let{styles:t,setting:o}=e,{inputBackgroundColor:r,textColor:l,dividerColor:a,dividerStroke:s,inputBoxShadow:n}=t??{},{enableHoverInput:S,hasButton:d}=o??{},c=core.composeTypographyStyle(t?.typo,t?.typography),i=core.getStyleShadowState(n,"box-shadow",{normal:!!n?.normal,hover:!!n?.hover}),p={...getDividerWidth(s,a),...getDividerColorStyle(a)},y={...core.getGlobalColorStateStyle("bg",r),...i,...core.getGlobalColorStateStyle("c",{...l,hover:l?.hover??l?.normal}),...d?p:{}},h={...core.makeStyle({}),...c,...y,...core.getStyleShadow({value:t?.typo?.custom?.textShadow,styleAppliedFor:"text-shadow",isEnableShadow:t?.typo?.custom?.hasShadowText})};return S?h:core.filterHoverVariables(h)},getButtonStyle=({borderBtn:e,buttonWidth:t,buttonBackgroundColor:o,iconColor:r,corner:l,enableHoverButton:a})=>{let s={...core.makeStyleResponsive("w",t),...core.handleConvertBorderStyle(e),...core.handleConvertBorderWidth(e),...core.handleConvertBorderColor(e),...core.getGlobalColorStateStyle("bg",o),...core.getGlobalColorStateStyle("c",r),...core.composeRadius(l)};return a?s:core.filterHoverVariables(s)},getContainerStyles=({inputHeight:e,align:t})=>({...core.makeStyleResponsive("h",e),...core.makeStyleResponsive("jc",t)}),getWrapperStyles=({backgroundColor:e,styles:t,setting:o})=>{let{enableHoverInput:r,hasButton:l}=o??{},a=t?.shapeShadow,s=core.getResponsiveStyleShadowWithoutState(a,"box-shadow",{desktop:a?.desktop??{},tablet:a?.tablet??a?.desktop??{},mobile:a?.mobile??a?.tablet??a?.desktop??{}}),n=t?.inputBorder,S=r&&!l,d={...core.handleConvertBorderStyle(n),...core.handleConvertBorderWidth(n),...core.handleConvertBorderColor(n)};return{...S?d:{},...core.getGlobalColorStateStyle("bg",e),...core.makeStyleResponsive("maxw",t?.quantityWidth),...core.composeBorderResponsive(t?.shapeBorder),...core.composeRadiusResponsive(t?.shapeRounded),...s}};exports.getButtonStyle=getButtonStyle,exports.getContainerStyles=getContainerStyles,exports.getInputStyle=getInputStyle,exports.getWrapperStyles=getWrapperStyles;
|
|
@@ -1,21 +1,19 @@
|
|
|
1
1
|
"use strict";const ProductQuantityPresets=[{id:"product-quantity",name:{en:"Product Quantity"},icon:{desktop:`
|
|
2
|
-
<svg width="96" height="
|
|
3
|
-
<
|
|
4
|
-
<path
|
|
2
|
+
<svg width="96" height="36" viewBox="0 0 96 36" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
3
|
+
<rect x="0.5" y="0.5" width="95" height="35" rx="2.5" stroke="#424242"/>
|
|
4
|
+
<g clip-path="url(#clip0_23331_7683)">
|
|
5
|
+
<path d="M10 18C10 17.7239 10.2239 17.5 10.5 17.5H19.5C19.7761 17.5 20 17.7239 20 18C20 18.2761 19.7761 18.5 19.5 18.5H10.5C10.2239 18.5 10 18.2761 10 18Z" fill="#F9F9F9"/>
|
|
5
6
|
</g>
|
|
6
|
-
<
|
|
7
|
-
<path
|
|
8
|
-
<
|
|
9
|
-
<g clip-path="url(#clip1_1631_19448)">
|
|
10
|
-
<path d="M81.45 19.95C81.45 19.7015 81.2485 19.5 81 19.5C80.7515 19.5 80.55 19.7015 80.55 19.95V23.55H76.95C76.7015 23.55 76.5 23.7515 76.5 24C76.5 24.2485 76.7015 24.45 76.95 24.45H80.55V28.05C80.55 28.2985 80.7515 28.5 81 28.5C81.2485 28.5 81.45 28.2985 81.45 28.05V24.45H85.05C85.2985 24.45 85.5 24.2485 85.5 24C85.5 23.7515 85.2985 23.55 85.05 23.55H81.45V19.95Z" fill="#AAAAAA"/>
|
|
7
|
+
<path d="M49.1825 13.2727V22H48.1257V14.3807H48.0746L45.9439 15.7955V14.7216L48.1257 13.2727H49.1825Z" fill="#F9F9F9"/>
|
|
8
|
+
<g clip-path="url(#clip1_23331_7683)">
|
|
9
|
+
<path d="M81.45 13.95C81.45 13.7015 81.2485 13.5 81 13.5C80.7515 13.5 80.55 13.7015 80.55 13.95V17.55H76.95C76.7015 17.55 76.5 17.7515 76.5 18C76.5 18.2485 76.7015 18.45 76.95 18.45H80.55V22.05C80.55 22.2985 80.7515 22.5 81 22.5C81.2485 22.5 81.45 22.2985 81.45 22.05V18.45H85.05C85.2985 18.45 85.5 18.2485 85.5 18C85.5 17.7515 85.2985 17.55 85.05 17.55H81.45V13.95Z" fill="#F9F9F9"/>
|
|
11
10
|
</g>
|
|
12
|
-
<rect x="0.5" y="6.5" width="95" height="35" rx="2.5" stroke="#424242"/>
|
|
13
11
|
<defs>
|
|
14
|
-
<clipPath id="
|
|
15
|
-
<rect x="7" y="
|
|
12
|
+
<clipPath id="clip0_23331_7683">
|
|
13
|
+
<rect x="7" y="10" width="16" height="16" rx="3" fill="white"/>
|
|
16
14
|
</clipPath>
|
|
17
|
-
<clipPath id="
|
|
18
|
-
<rect x="73" y="
|
|
15
|
+
<clipPath id="clip1_23331_7683">
|
|
16
|
+
<rect x="73" y="10" width="16" height="16" rx="3" fill="white"/>
|
|
19
17
|
</clipPath>
|
|
20
18
|
</defs>
|
|
21
19
|
</svg>
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";const ProductQuantitySettings=[{id:"setting",controls:[{id:"updatePrice",label:"Update price",type:"toggle",default:!0},{id:"
|
|
1
|
+
"use strict";const ProductQuantitySettings=[{id:"setting",controls:[{id:"updatePrice",label:"Update price",type:"toggle",default:!0},{id:"hasButton",label:"Button",type:"toggle",default:!0},{id:"defaultQtyValue",label:"Text",type:"input:stepper",min:1,default:1},{id:"plusIcon",type:"icon",isHideClear:!0,customLabel:"Plus",info:"Choose from list or paste any SVG icon",default:`<svg height="20px" width="20px" data-name="plus-regular" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor" data-id="508817698760687976">
|
|
2
2
|
<path fill="currentColor" strokelinecap="round" strokelinejoin="round" d="M224,128a8,8,0,0,1-8,8H136v80a8,8,0,0,1-16,0V136H40a8,8,0,0,1,0-16h80V40a8,8,0,0,1,16,0v80h80A8,8,0,0,1,224,128Z"></path></svg>`},{id:"minusIcon",type:"icon",isHideClear:!0,customLabel:"Minus",info:"Choose from list or paste any SVG icon",default:`<svg height="20px" width="20px" data-name="minus-regular" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor" data-id="508817690725712232">
|
|
3
|
-
<path fill="currentColor" strokelinecap="round" strokelinejoin="round" d="M224,128a8,8,0,0,1-8,8H40a8,8,0,0,1,0-16H216A8,8,0,0,1,224,128Z"></path></svg>`},{id:"enableHoverInput",label:"Enable hover input",type:"toggle",default:!1},{id:"enableHoverButton",label:"Enable hover input",type:"toggle",default:!1}]},{id:"style",controls:[{id:"quantityLayout",label:"Style",type:"layout-selector",popoverLabel:{en:"Style"},iconViewBox:"0 0 80 48",enableItemBackground:!0,itemPerRow:2,itemSpacing:"large",options:[{label:"Square",value:"product-quantity-square",type:"p-quantity-layout",iconName:"gp-product-quantity-square"},{label:"Square with divider",value:"product-quantity-square-divider",type:"p-quantity-layout",iconName:"gp-product-quantity-square-divider"},{label:"Rounded",value:"product-quantity-rounded",type:"p-quantity-layout",iconName:"gp-product-quantity-rounded"},{label:"Rounded with divider",value:"product-quantity-rounded-divider",type:"p-quantity-layout",iconName:"gp-product-quantity-rounded-divider"},{label:"Square input only",value:"product-quantity-square-input-only",type:"p-quantity-layout",iconName:"gp-product-quantity-square-input-only"},{label:"Rounded input only",value:"product-quantity-rounded-input-only",type:"p-quantity-layout",iconName:"gp-product-quantity-rounded-input-only"}],default:"product-quantity-square"},{id:"dimensions",type:"group",label:"Dimensions",controls:[{id:"fullWidth",label:"Full Width",type:"toggle",devices:{desktop:{default:!1}}},{id:"quantityWidth",type:"dropdown:input",label:"Width",inputType:"number",units:["px","%"],hideUnit:!1,displayOptions:[{label:"Full",value:"100%",showValue:!0}],devices:{desktop:{default:"160px"}}},{id:"inputHeight",type:"dropdown:input",label:"Width",inputType:"number",units:["px","%"],hideUnit:!1,displayOptions:[{label:"Full",value:"100%",showValue:!0}],devices:{desktop:{default:"45px"}}},{id:"buttonWidth",type:"dropdown:input",label:"Button Width",inputType:"number",units:["px","%"],hideUnit:!1,displayOptions:[{label:"Full",value:"100%",showValue:!0}],devices:{desktop:{default:"45px"}}},{id:"iconSizeCustom",type:"input:stepper",includeUnit:"px",min:1,devices:{desktop:{default:"16px"}}}]},{id:"inputStyle",type:"group",label:"Input Style",controls:[{id:"typo",type:"typography-
|
|
3
|
+
<path fill="currentColor" strokelinecap="round" strokelinejoin="round" d="M224,128a8,8,0,0,1-8,8H40a8,8,0,0,1,0-16H216A8,8,0,0,1,224,128Z"></path></svg>`},{id:"enableHoverInput",label:"Enable hover input",type:"toggle",default:!1},{id:"enableHoverButton",label:"Enable hover input",type:"toggle",default:!1}]},{id:"style",controls:[{id:"quantityLayout",label:"Style",type:"layout-selector",popoverLabel:{en:"Style"},iconViewBox:"0 0 80 48",enableItemBackground:!0,itemPerRow:2,itemSpacing:"large",options:[{label:"Square",value:"product-quantity-square",type:"p-quantity-layout",iconName:"gp-product-quantity-square"},{label:"Square with divider",value:"product-quantity-square-divider",type:"p-quantity-layout",iconName:"gp-product-quantity-square-divider"},{label:"Rounded",value:"product-quantity-rounded",type:"p-quantity-layout",iconName:"gp-product-quantity-rounded"},{label:"Rounded with divider",value:"product-quantity-rounded-divider",type:"p-quantity-layout",iconName:"gp-product-quantity-rounded-divider"},{label:"Square input only",value:"product-quantity-square-input-only",type:"p-quantity-layout",iconName:"gp-product-quantity-square-input-only"},{label:"Rounded input only",value:"product-quantity-rounded-input-only",type:"p-quantity-layout",iconName:"gp-product-quantity-rounded-input-only"}],default:"product-quantity-square"},{id:"dimensions",type:"group",label:"Dimensions",controls:[{id:"fullWidth",label:"Full Width",type:"toggle",devices:{desktop:{default:!1}}},{id:"quantityWidth",type:"dropdown:input",label:"Width",inputType:"number",units:["px","%"],hideUnit:!1,displayOptions:[{label:"Full",value:"100%",showValue:!0}],devices:{desktop:{default:"160px"}}},{id:"inputHeight",type:"dropdown:input",label:"Width",inputType:"number",units:["px","%"],hideUnit:!1,displayOptions:[{label:"Full",value:"100%",showValue:!0}],devices:{desktop:{default:"45px"}}},{id:"buttonWidth",type:"dropdown:input",label:"Button Width",inputType:"number",units:["px","%"],hideUnit:!1,displayOptions:[{label:"Full",value:"100%",showValue:!0}],devices:{desktop:{default:"45px"}}},{id:"iconSizeCustom",type:"input:stepper",includeUnit:"px",min:1,devices:{desktop:{default:"16px"}}}]},{id:"inputStyle",type:"group",label:"Input Style",controls:[{id:"typo",type:"typography-combo",default:{type:"paragraph-1",attrs:{color:"#121212"},custom:{fontSize:{desktop:"16px",tablet:"16px",mobile:"14px"},lineHeight:{desktop:"120%",tablet:"180%",mobile:"180%"},fontWeight:"400",fontFamily:{value:"Assistant",type:"google"},hasShadowText:!1,textShadow:{enable:!1}}},ignoreReRender:!0,hiddenSetting:{transform:!0,textAlign:!0}},{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:"button-behavior-state",type:"behavior-state",label:"Button Style",hide:!0,controls:[{id:"textColor",type:"color-picker-v2",label:"Text Color",default:{normal:"text-2"},compoDefaultValue:{hover:"text-2"},state:{hover:!0,normal:!0},enableGradient:!0},{id:"inputBackgroundColor",type:"color-picker-v2",label:"Background Color",state:{hover:!0,normal:!0},compoDefaultValue:{normal:"highlight",hover:"highlight"},enableGradient:!0},{id:"buttonBackgroundColor",type:"color-picker-v2",label:"Button Background Color",state:{hover:!0,normal:!0},enableGradient:!0,compoDefaultValue:{normal:"brand",hover:"highlight"}},{id:"iconColor",type:"color-picker-v2",label:"Icon Color",default:{normal:"#121212"},compoDefaultValue:{hover:"text-2"},state:{hover:!0,normal:!0},enableGradient:!0}]},{id:"borderBtn",label:"Border",type:"border-v2",default:{normal:{}},compoDefaultValue:{normal:{border:"solid",color:"#212121",width:"1px",borderWidth:"1px"},hover:{border:"solid",color:"#212121",width:"1px",borderWidth:"1px"}},state:{hover:!0,normal:!0}},{id:"corner",label:"Corner",type:"corner-v2",default:{normal:{btrr:"0px",bblr:"0px",bbrr:"0px",btlr:"0px",radiusType:"none"}}},{id:"inputBoxShadow",type:"shadow-v2",default:{normal:{}},compoDefaultValue:{normal:{type:"shadow-1",distance:"4px",blur:"4px",spread:"0px",color:"#121212",angle:90}}},{id:"backgroundColor",type:"color-picker-v2",label:"Background Color",default:{normal:"#FFFFFF",hover:"#FFFFFF"},state:{hover:!0,normal:!0},enableGradient:!0},{id:"dividerColor",type:"color-picker-v2",label:"Divider Color",default:{normal:"line-3"},compoDefaultValue:{normal:"line-3"},state:{hover:!0,normal:!0},enableGradient:!0},{id:"dividerStroke",label:"Thickness",type:"input:stepper",min:1,default:{normal:1,hover:1},state:{hover:!0,normal:!0}},{id:"inputBorder",label:"Input Border",type:"border-v2",default:{hover:{border:"solid",color:"line-3",width:"1px",borderWidth:"1px"}},state:{hover:!0,normal:!1}},{id:"shapeBorder",type:"border-v2",devices:{desktop:{default:{border:"solid",color:"line-3",width:"1px",borderWidth:"1px"}}}},{id:"shapeRounded",type:"corner-v2",devices:{desktop:{default:{radiusType:"none"}}}},{id:"shapeShadow",type:"shadow-v2",devices:{desktop:{default:{}}},compoDefaultValue:{desktop:{default:{type:"shadow-1",distance:"4px",blur:"4px",spread:"0px",color:"rgba(18, 18, 18, 0.20)",angle:45,enable:!0}}}}]}];exports.ProductQuantitySettings=ProductQuantitySettings;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const SettingUIV2=[{label:{en:"
|
|
1
|
+
"use strict";const SettingUIV2=[{controls:[{label:{en:"Button"},setting:{id:"hasButton"},options:{labelVariant:"primary",toggleStyle:"switch"}},{label:{en:"Width"},setting:{id:"buttonWidth"},conditionDisplay:"hasButton === true"},{label:{en:"Background"},setting:{id:"buttonBackgroundColor",state:"normal"},conditionDisplay:"hasButton === true"},{label:{en:"Plus icon"},setting:{id:"plusIcon"},conditionDisplay:"hasButton === true"},{label:{en:"Minus icon"},setting:{id:"minusIcon"},conditionDisplay:"hasButton === true"},{label:{en:"Icon color"},setting:{id:"iconColor",state:"normal"},conditionDisplay:"hasButton === true"}],moreSettings:{type:"collapse",controls:[{label:{en:"Icon size"},setting:{id:"iconSizeCustom"},conditionDisplay:"hasButton === true"},{label:{en:"Border"},setting:{id:"borderBtn",state:"normal"},conditionDisplay:"hasButton === true"},{label:{en:"Corner"},setting:{id:"corner",state:"normal"},conditionDisplay:"hasButton === true"},{label:{en:"Hover"},type:"combo",iconName:"polaris-check-clicked",fixedValue:"Styled",setting:{id:"enableHoverButton"},popoverLabel:{en:"Hover effect"},state:"hover",conditionDisplay:"hasButton === true",controls:[{label:{en:"Background"},setting:{id:"buttonBackgroundColor",state:"hover"},compoDefaultValue:{default:"highlight"}},{label:{en:"Icon color"},setting:{id:"iconColor",state:"hover"}},{label:{en:"Border"},setting:{id:"borderBtn",state:"hover"}},{label:{en:"Corner"},setting:{id:"corner",state:"hover"}}]}]}},{label:{en:"Input"},controls:[{label:{en:"Background"},setting:{id:"inputBackgroundColor",state:"normal"}},{label:{en:"Text style"},setting:{id:"typo"},options:{updateFields:[{field:"attrs.color",settingId:"textColor",state:"normal"}]},controlChangeTrigger:{settings:[{action:{controlId:"textColor",valueFromField:"attrs.color",groupType:"style",controlType:"style",removeDevice:!0,state:"normal"}}],options:{noRecordHistory:!0}}},{label:{en:"Divider"},type:"combo",conditionDisplay:"hasButton === true",comboType:"color",getValueFromSettingID:"dividerColor.normal",compoDefaultValue:"line-3",controls:[{label:{en:"Color"},setting:{id:"dividerColor",state:"normal"}},{label:{en:"Thickness"},setting:{id:"dividerStroke",state:"normal"}}]},{label:{en:"Shadow"},setting:{id:"inputBoxShadow",state:"normal"}},{label:{en:"Hover"},type:"combo",iconName:"polaris-check-clicked",fixedValue:"Styled",popoverLabel:{en:"Hover effect"},setting:{id:"enableHoverInput"},state:"hover",controls:[{label:{en:"Background"},setting:{id:"inputBackgroundColor",state:"hover"}},{label:{en:"Text color"},setting:{id:"textColor",state:"hover"}},{id:"divider-hover",label:{en:"Divider"},type:"combo",iconName:"polaris-edit",getValueFromSettingID:"dividerColor.hover",comboType:"color",compoDefaultValue:"line-3",controls:[{label:{en:"Color"},setting:{id:"dividerColor",state:"hover"}},{label:{en:"Thickness"},setting:{id:"dividerStroke",state:"hover"}}],conditionDisplay:"hasButton === true"},{label:{en:"Border"},setting:{id:"inputBorder",state:"hover"},conditionDisplay:"hasButton === false"},{label:{en:"Shadow"},setting:{id:"inputBoxShadow",state:"hover"}}]}]},{label:{en:"Size"},controls:[{label:{en:"Width"},setting:{id:"quantityWidth"}},{label:{en:"Height"},setting:{id:"inputHeight"}}]},{label:{en:"Background"},controls:[{label:{en:"Color"},setting:{id:"backgroundColor",state:"normal"}}]},{label:{en:"Shape"},controls:[{label:{en:"Border"},setting:{id:"shapeBorder"}},{label:{en:"Corner"},setting:{id:"shapeRounded"}},{label:{en:"Shadow"},setting:{id:"shapeShadow"}}]},{label:{en:"Display condition"},controls:[{label:{en:"Default quantity"},setting:{id:"defaultQtyValue"}},{label:{en:"Update price"},setting:{id:"updatePrice"}}]},{controls:[{label:{en:"Align"},conditionEnable:'!(parseInt(quantityWidth) >= 100 && quantityWidth?.includes("%"))',setting:{id:"align"},options:{labelVariant:"primary",fullWidth:!0,disableMessage:"Align is not supported when width is 100%"}}]}];exports.SettingUIV2=SettingUIV2;
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
<circle cx="64.2674" cy="46.5138" r="1.15512" fill="white"/>
|
|
10
10
|
<circle cx="69.5565" cy="46.5138" r="1.15512" fill="white"/>
|
|
11
11
|
</svg>
|
|
12
|
-
`},components:[{tag:"Sticky",label:"Sticky",settings:{width:{desktop:"100%"}},advanced:{hasBoxShadow:{desktop:{normal:!0}},boxShadow:{desktop:{normal:{type:"shadow-2",distance:"12px",blur:"12px",spread:"0px",color:"rgba(18, 18, 18, 0.2)",angle:45}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Product",label:"Product",settings:{layout:{desktop:{cols:[4,8],display:"fill"},mobile:{cols:[12]}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"},isSyncProduct:!0},styles:{verticalGutter:{desktop:"8px"},verticalGutterMobile:{desktop:"0px"},fullWidth:{desktop:!1}},advanced:{"spacing-setting":{desktop:{margin:{},padding:{left:"4px",right:"4px",top:"4px",bottom:"4px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,6],display:"fit"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px",tablet:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1},border:{desktop:{normal:{borderType:"none",border:"solid",borderWidth:"0px",width:"0px",color:"#121212",isCustom:!0}}},rounded:{desktop:{normal:{btrr:"0px",bblr:"0px",bbrr:"0px",btlr:"0px",radiusType:"none"}}},hasBoxShadow:{desktop:{normal:!1}},boxShadow:{desktop:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}}},op:{desktop:"100%"}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductImagesV2",label:"Product Images",settings:{hoverEffect:"none"},styles:{position:{desktop:"only-feature",mobile:"only-feature"},ftShape:{desktop:{shape:"square",shapeValue:"1/1",width:"32px",height:void 0}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductTitle",label:"Product Title",settings:{htmlTag:"h1",linkProduct:!1},styles:{typo:{type:"subheading-3",custom:{fontSize:{desktop:"16px"},fontWeight:"400",lineHeight:"24px",letterSpacing:"0.6px",fontStyle:"normal"}},textAlign:{desktop:"left"},hasLineClamp:{desktop:!0},lineClamp:{desktop:1},color:{normal:"text-2"},hasTextShadow:{normal:!1,hover:!1},textShadow:{normal:{type:"shadow-1"}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}},{tag:"ProductPrice",label:"Product Price",settings:{priceType:"regular"},styles:{typo:{type:"subheading-2",default:{type:"subheading-2"},custom:{fontSize:{desktop:"14px"},fontWeight:"400",lineHeight:"20px",letterSpacing:"0.6px",fontStyle:"normal"}},lineThrough:!0,thickness:1,lineColor:"text-1",color:{normal:"text-2"},hasTextShadow:{normal:!1},textShadow:{normal:{type:"shadow-1"}},textAlign:{desktop:"left"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]}]}]},{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,3,3],display:"fill"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px",tablet:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductVariants",label:"Product Variants & Swatches",settings:{optionType:"groupOption",label:!0,optionAlign:{desktop:"left"},price:!0,showAsSwatches:!0,combineFullWidth:{desktop:!0},combineWidth:{desktop:"400px"},combineHeight:"40px",variantPresets:[{optionName:"base",optionType:"rectangle_list",presets:{color:{width:{desktop:"45px",tablet:"45px",mobile:"45px"},height:"45px",spacing:"16px"},rectangle_list:{width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px",spacing:"16px"},image:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},image_shopify:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},dropdown:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px"}}}],soldOutMark:!0,layout:{desktop:"vertical"},column:{desktop:1},hasPreSelected:!0,blankText:"Please select an option"},styles:{fullWidth:{desktop:!0},width:{desktop:"400px"},optionSpacing:"30px",labelGap:"8px",swatchAutoWidth:{desktop:!0},swatchWidth:{desktop:"80px"},swatchHeight:{desktop:"40px"},swatchSpacing:"var(--g-s-m)",marginBottom:{desktop:"var(--g-s-xl)",mobile:"var(--g-s-xl)"},align:{desktop:"left"},labelTypo:{type:"paragraph-2",attrs:{color:"text-1",bold:!0}},labelColor:"text-2",optionTypo:{type:"paragraph-2"},optionBgColor:{normal:"bg-3",hover:"bg-3",active:"bg-3"},optionTextColor:{normal:"text-2",hover:"text-2",active:"text-2"},optionBorder:{normal:{borderType:"style-2",border:"solid",color:"line-2",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"},active:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"2px 2px 2px 2px",borderWidth:"2px"},hover:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"}},optionRounded:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"custom"},hover:{radiusType:"none"},active:{radiusType:"none"}},optionHasShadow:{normal:!1},optionShadow:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},dropdownItemWidth:{desktop:"fill",mobile:"fill",tablet:"fill"},fixedDropdownWidth:{desktop:"240px"},swatchItemWidth:{desktop:"auto"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductQuantity",label:"Product Quantity",settings:{
|
|
12
|
+
`},components:[{tag:"Sticky",label:"Sticky",settings:{width:{desktop:"100%"}},advanced:{hasBoxShadow:{desktop:{normal:!0}},boxShadow:{desktop:{normal:{type:"shadow-2",distance:"12px",blur:"12px",spread:"0px",color:"rgba(18, 18, 18, 0.2)",angle:45}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Product",label:"Product",settings:{layout:{desktop:{cols:[4,8],display:"fill"},mobile:{cols:[12]}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"},isSyncProduct:!0},styles:{verticalGutter:{desktop:"8px"},verticalGutterMobile:{desktop:"0px"},fullWidth:{desktop:!1}},advanced:{"spacing-setting":{desktop:{margin:{},padding:{left:"4px",right:"4px",top:"4px",bottom:"4px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,6],display:"fit"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px",tablet:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1},border:{desktop:{normal:{borderType:"none",border:"solid",borderWidth:"0px",width:"0px",color:"#121212",isCustom:!0}}},rounded:{desktop:{normal:{btrr:"0px",bblr:"0px",bbrr:"0px",btlr:"0px",radiusType:"none"}}},hasBoxShadow:{desktop:{normal:!1}},boxShadow:{desktop:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}}},op:{desktop:"100%"}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductImagesV2",label:"Product Images",settings:{hoverEffect:"none"},styles:{position:{desktop:"only-feature",mobile:"only-feature"},ftShape:{desktop:{shape:"square",shapeValue:"1/1",width:"32px",height:void 0}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductTitle",label:"Product Title",settings:{htmlTag:"h1",linkProduct:!1},styles:{typo:{type:"subheading-3",custom:{fontSize:{desktop:"16px"},fontWeight:"400",lineHeight:"24px",letterSpacing:"0.6px",fontStyle:"normal"}},textAlign:{desktop:"left"},hasLineClamp:{desktop:!0},lineClamp:{desktop:1},color:{normal:"text-2"},hasTextShadow:{normal:!1,hover:!1},textShadow:{normal:{type:"shadow-1"}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}},{tag:"ProductPrice",label:"Product Price",settings:{priceType:"regular"},styles:{typo:{type:"subheading-2",default:{type:"subheading-2"},custom:{fontSize:{desktop:"14px"},fontWeight:"400",lineHeight:"20px",letterSpacing:"0.6px",fontStyle:"normal"}},lineThrough:!0,thickness:1,lineColor:"text-1",color:{normal:"text-2"},hasTextShadow:{normal:!1},textShadow:{normal:{type:"shadow-1"}},textAlign:{desktop:"left"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]}]}]},{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,3,3],display:"fill"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px",tablet:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductVariants",label:"Product Variants & Swatches",settings:{optionType:"groupOption",label:!0,optionAlign:{desktop:"left"},price:!0,showAsSwatches:!0,combineFullWidth:{desktop:!0},combineWidth:{desktop:"400px"},combineHeight:"40px",variantPresets:[{optionName:"base",optionType:"rectangle_list",presets:{color:{width:{desktop:"45px",tablet:"45px",mobile:"45px"},height:"45px",spacing:"16px"},rectangle_list:{width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px",spacing:"16px"},image:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},image_shopify:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},dropdown:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px"}}}],soldOutMark:!0,layout:{desktop:"vertical"},column:{desktop:1},hasPreSelected:!0,blankText:"Please select an option"},styles:{fullWidth:{desktop:!0},width:{desktop:"400px"},optionSpacing:"30px",labelGap:"8px",swatchAutoWidth:{desktop:!0},swatchWidth:{desktop:"80px"},swatchHeight:{desktop:"40px"},swatchSpacing:"var(--g-s-m)",marginBottom:{desktop:"var(--g-s-xl)",mobile:"var(--g-s-xl)"},align:{desktop:"left"},labelTypo:{type:"paragraph-2",attrs:{color:"text-1",bold:!0}},labelColor:"text-2",optionTypo:{type:"paragraph-2"},optionBgColor:{normal:"bg-3",hover:"bg-3",active:"bg-3"},optionTextColor:{normal:"text-2",hover:"text-2",active:"text-2"},optionBorder:{normal:{borderType:"style-2",border:"solid",color:"line-2",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"},active:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"2px 2px 2px 2px",borderWidth:"2px"},hover:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"}},optionRounded:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"custom"},hover:{radiusType:"none"},active:{radiusType:"none"}},optionHasShadow:{normal:!1},optionShadow:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},dropdownItemWidth:{desktop:"fill",mobile:"fill",tablet:"fill"},fixedDropdownWidth:{desktop:"240px"},swatchItemWidth:{desktop:"auto"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductQuantity",label:"Product Quantity",settings:{hasButton:!0,enableHoverButton:!0},styles:{inputHeight:{desktop:"40px"},buttonWidth:{desktop:"40px"},iconSizeCustom:{desktop:"20px"},typo:{type:"paragraph-2",attrs:{color:"text-1"}},align:{desktop:"left"},inputBackgroundColor:"bg-3",textColor:"text-2",buttonBackgroundColor:{normal:"bg-3"},iconColor:{normal:"text-2"},borderBtn:{normal:{},hover:{borderType:"style-3",border:"solid",width:"1px 1px 1px 1px",color:"line-3",isCustom:!1}},corner:{desktop:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"rounded"}}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductButton",label:"Product Cart Button",settings:{label:"Add to cart",outOfStockLabel:"Out of stock",actionEffect:"open-cart-drawer",customURL:{link:"/cart",target:"_self"},successMessage:"Add product to cart successfully",errorMessage:"Cannot add product to cart",buttonLayout:"cart-only",iconAlign:"left",errorType:"built-in"},styles:{backgroundColor:{normal:"brand",hover:"highlight"},textColor:{normal:"text-3"},borderBtn:{normal:{border:"solid",color:"#121212",isCustom:!0,position:"all",borderWidth:"0px",width:"0px 0px 0px 0px"},hover:{border:"solid",color:"#4D4D4D",isCustom:!0,position:"all",borderWidth:"0px",width:"0px 0px 0px 0px"}},hasBoxShadowBtn:{normal:!1,hover:!1},boxShadowBtn:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},roundedBtnV2:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"rounded"}},align:{desktop:"left"},typo:{type:"paragraph-1"},transform:"default",btnSpacing:{type:"medium"},fullWidth:{desktop:!0},iconSizeAuto:!0,size:{desktop:"1em"},iconDimension:{desktop:"24px"},spacing:"8px",successTypo:{type:"paragraph-2"},successColor:"success",errorTypo:{type:"paragraph-2"},errorColor:"error",isCustomOutOfStock:!1,oosBackground:"brand",oosTextColor:"text-3",oosBorder:{normal:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,borderWidth:"0px",width:"0px 0px 0px 0px"}},oosEnableShadow:!1,oosShadow:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90},oosRounded:{radiusType:"none"},globalSize:{desktop:{width:"100%"}},enableIcon:!1,enablePrice:!1,enableSeparator:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]}]}]}]}]}]}]},StickyPresetScrollToTop={id:"sticky-scroll-to-top",name:{en:"Sticky Back to top"},icon:{desktop:`
|
|
13
13
|
<svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
14
14
|
<rect width="40" height="40" rx="20" fill="#424242"/>
|
|
15
15
|
<path d="M13.6001 14C13.6001 13.5581 13.9583 13.2 14.4001 13.2H25.6001C26.0419 13.2 26.4001 13.5581 26.4001 14C26.4001 14.4418 26.0419 14.8 25.6001 14.8H14.4001C13.9583 14.8 13.6001 14.4418 13.6001 14Z" fill="#F9F9F9"/>
|
|
@@ -28,4 +28,4 @@
|
|
|
28
28
|
<circle cx="64.2674" cy="46.5138" r="1.15512" fill="white"/>
|
|
29
29
|
<circle cx="69.5565" cy="46.5138" r="1.15512" fill="white"/>
|
|
30
30
|
</svg>
|
|
31
|
-
`},components:[{tag:"Sticky",label:"Sticky",advanced:{hasBoxShadow:{desktop:{normal:!0}},boxShadow:{desktop:{normal:{type:"shadow-1",distance:"0px",blur:"10px",spread:"0px",color:"rgba(0, 0, 0, 0.1)",angle:90}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Product",label:"Product",settings:{productSetting:{productStatus:"dynamic"},layout:{desktop:{cols:[4,8],display:"fill"},mobile:{cols:[12]}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"},isSyncProduct:!0},styles:{verticalGutter:{desktop:"8px",tablet:"8px"},verticalGutterMobile:{desktop:"0px"},fullWidth:{desktop:!1}},advanced:{"spacing-setting":{desktop:{margin:{},padding:{left:"4px",right:"4px",top:"4px",bottom:"4px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,6],display:"fit"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px",tablet:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1},border:{desktop:{normal:{borderType:"none",border:"solid",borderWidth:"0px",width:"0px",color:"#121212",isCustom:!0}}},rounded:{desktop:{normal:{btrr:"0px",bblr:"0px",bbrr:"0px",btlr:"0px",radiusType:"none"}}},hasBoxShadow:{desktop:{normal:!1}},boxShadow:{desktop:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}}},op:{desktop:"100%"}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductImagesV2",label:"Product Images",settings:{hoverEffect:"none"},styles:{position:{desktop:"only-feature",mobile:"only-feature"},ftShape:{desktop:{shape:"square",shapeValue:"1/1",width:"32px",height:void 0}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductTitle",label:"Product Title",settings:{htmlTag:"h1",linkProduct:!1},styles:{typo:{type:"subheading-3",custom:{fontSize:{desktop:"18px",tablet:"18px",mobile:"18px"},fontWeight:"400",lineHeight:"24px",letterSpacing:"0.6px",fontStyle:"normal"}},textAlign:{desktop:"left"},hasLineClamp:{desktop:!0},lineClamp:{desktop:1},color:{normal:"text-2"},hasTextShadow:{normal:!1,hover:!1},textShadow:{normal:{type:"shadow-1"}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}},{tag:"ProductPrice",label:"Product Price",settings:{priceType:"regular"},styles:{typo:{type:"subheading-2",default:{type:"subheading-2"},custom:{fontSize:{desktop:"14px"},fontWeight:"400",lineHeight:"20px",letterSpacing:"0.6px",fontStyle:"normal"}},lineThrough:!0,thickness:1,lineColor:"text-1",color:{normal:"text-2"},hasTextShadow:{normal:!1},textShadow:{normal:{type:"shadow-1"}},textAlign:{desktop:"left"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]}]}]},{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,3,3],display:"fill"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductVariants",label:"Product Variants & Swatches",settings:{optionType:"groupOption",label:!0,optionAlign:{desktop:"left"},price:!0,showAsSwatches:!0,combineFullWidth:{desktop:!0},combineWidth:{desktop:"400px"},combineHeight:"40px",variantPresets:[{optionName:"base",optionType:"rectangle_list",presets:{color:{width:{desktop:"45px",tablet:"45px",mobile:"45px"},height:"45px",spacing:"16px"},rectangle_list:{width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px",spacing:"16px"},image:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},image_shopify:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},dropdown:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px"}}}],soldOutMark:!0,layout:{desktop:"vertical"},column:{desktop:1},hasPreSelected:!0,blankText:"Please select an option"},styles:{fullWidth:{desktop:!0},width:{desktop:"400px"},optionSpacing:"30px",labelGap:"8px",swatchAutoWidth:{desktop:!0},swatchWidth:{desktop:"80px"},swatchHeight:{desktop:"40px"},swatchSpacing:"var(--g-s-m)",marginBottom:{desktop:"var(--g-s-xl)",mobile:"var(--g-s-xl)"},align:{desktop:"left"},labelTypo:{type:"paragraph-2",attrs:{color:"text-1",bold:!0}},labelColor:"text-2",optionTypo:{type:"paragraph-2"},optionBgColor:{normal:"bg-3",hover:"bg-3",active:"bg-3"},optionTextColor:{normal:"text-2",hover:"text-2",active:"text-2"},optionBorder:{normal:{borderType:"style-2",border:"solid",color:"line-2",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"},active:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"2px 2px 2px 2px",borderWidth:"2px"},hover:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"}},optionRounded:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"custom"},hover:{radiusType:"none"},active:{radiusType:"none"}},optionHasShadow:{normal:!1},optionShadow:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},dropdownItemWidth:{desktop:"fill",mobile:"fill",tablet:"fill"},fixedDropdownWidth:{desktop:"240px"},swatchItemWidth:{desktop:"auto"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductQuantity",label:"Product Quantity",settings:{
|
|
31
|
+
`},components:[{tag:"Sticky",label:"Sticky",advanced:{hasBoxShadow:{desktop:{normal:!0}},boxShadow:{desktop:{normal:{type:"shadow-1",distance:"0px",blur:"10px",spread:"0px",color:"rgba(0, 0, 0, 0.1)",angle:90}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Product",label:"Product",settings:{productSetting:{productStatus:"dynamic"},layout:{desktop:{cols:[4,8],display:"fill"},mobile:{cols:[12]}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"},isSyncProduct:!0},styles:{verticalGutter:{desktop:"8px",tablet:"8px"},verticalGutterMobile:{desktop:"0px"},fullWidth:{desktop:!1}},advanced:{"spacing-setting":{desktop:{margin:{},padding:{left:"4px",right:"4px",top:"4px",bottom:"4px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,6],display:"fit"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px",tablet:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1},border:{desktop:{normal:{borderType:"none",border:"solid",borderWidth:"0px",width:"0px",color:"#121212",isCustom:!0}}},rounded:{desktop:{normal:{btrr:"0px",bblr:"0px",bbrr:"0px",btlr:"0px",radiusType:"none"}}},hasBoxShadow:{desktop:{normal:!1}},boxShadow:{desktop:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}}},op:{desktop:"100%"}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductImagesV2",label:"Product Images",settings:{hoverEffect:"none"},styles:{position:{desktop:"only-feature",mobile:"only-feature"},ftShape:{desktop:{shape:"square",shapeValue:"1/1",width:"32px",height:void 0}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductTitle",label:"Product Title",settings:{htmlTag:"h1",linkProduct:!1},styles:{typo:{type:"subheading-3",custom:{fontSize:{desktop:"18px",tablet:"18px",mobile:"18px"},fontWeight:"400",lineHeight:"24px",letterSpacing:"0.6px",fontStyle:"normal"}},textAlign:{desktop:"left"},hasLineClamp:{desktop:!0},lineClamp:{desktop:1},color:{normal:"text-2"},hasTextShadow:{normal:!1,hover:!1},textShadow:{normal:{type:"shadow-1"}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}},{tag:"ProductPrice",label:"Product Price",settings:{priceType:"regular"},styles:{typo:{type:"subheading-2",default:{type:"subheading-2"},custom:{fontSize:{desktop:"14px"},fontWeight:"400",lineHeight:"20px",letterSpacing:"0.6px",fontStyle:"normal"}},lineThrough:!0,thickness:1,lineColor:"text-1",color:{normal:"text-2"},hasTextShadow:{normal:!1},textShadow:{normal:{type:"shadow-1"}},textAlign:{desktop:"left"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]}]}]},{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,3,3],display:"fill"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductVariants",label:"Product Variants & Swatches",settings:{optionType:"groupOption",label:!0,optionAlign:{desktop:"left"},price:!0,showAsSwatches:!0,combineFullWidth:{desktop:!0},combineWidth:{desktop:"400px"},combineHeight:"40px",variantPresets:[{optionName:"base",optionType:"rectangle_list",presets:{color:{width:{desktop:"45px",tablet:"45px",mobile:"45px"},height:"45px",spacing:"16px"},rectangle_list:{width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px",spacing:"16px"},image:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},image_shopify:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},dropdown:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px"}}}],soldOutMark:!0,layout:{desktop:"vertical"},column:{desktop:1},hasPreSelected:!0,blankText:"Please select an option"},styles:{fullWidth:{desktop:!0},width:{desktop:"400px"},optionSpacing:"30px",labelGap:"8px",swatchAutoWidth:{desktop:!0},swatchWidth:{desktop:"80px"},swatchHeight:{desktop:"40px"},swatchSpacing:"var(--g-s-m)",marginBottom:{desktop:"var(--g-s-xl)",mobile:"var(--g-s-xl)"},align:{desktop:"left"},labelTypo:{type:"paragraph-2",attrs:{color:"text-1",bold:!0}},labelColor:"text-2",optionTypo:{type:"paragraph-2"},optionBgColor:{normal:"bg-3",hover:"bg-3",active:"bg-3"},optionTextColor:{normal:"text-2",hover:"text-2",active:"text-2"},optionBorder:{normal:{borderType:"style-2",border:"solid",color:"line-2",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"},active:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"2px 2px 2px 2px",borderWidth:"2px"},hover:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"}},optionRounded:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"custom"},hover:{radiusType:"none"},active:{radiusType:"none"}},optionHasShadow:{normal:!1},optionShadow:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},dropdownItemWidth:{desktop:"fill",mobile:"fill",tablet:"fill"},fixedDropdownWidth:{desktop:"240px"},swatchItemWidth:{desktop:"auto"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductQuantity",label:"Product Quantity",settings:{hasButton:!0,enableHoverButton:!0},styles:{inputHeight:{desktop:"40px"},buttonWidth:{desktop:"40px"},iconSizeCustom:{desktop:"20px"},typo:{type:"paragraph-2",attrs:{color:"text-1"}},align:{desktop:"left"},inputBackgroundColor:"bg-3",textColor:"text-2",buttonBackgroundColor:{normal:"bg-3"},iconColor:{normal:"text-2"},borderBtn:{normal:{},hover:{borderType:"style-3",border:"solid",width:"1px 1px 1px 1px",color:"line-3",isCustom:!1}},corner:{desktop:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"rounded"}}}},advanced:{rounded:{desktop:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"none"}}},"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductButton",label:"Product Cart Button",settings:{label:"Add to cart",outOfStockLabel:"Out of stock",actionEffect:"open-cart-drawer",customURL:{link:"/cart",target:"_self"},successMessage:"Add product to cart successfully",errorMessage:"Cannot add product to cart",buttonLayout:"cart-only",iconAlign:"left",errorType:"built-in"},styles:{backgroundColor:{normal:"brand",hover:"highlight"},backgroundColorV2:{normal:"brand",hover:"highlight"},textColor:{normal:"text-3"},borderBtn:{normal:{border:"solid",color:"#121212",isCustom:!0,position:"all",borderWidth:"0px",width:"0px 0px 0px 0px"},hover:{border:"solid",color:"#4D4D4D",isCustom:!0,position:"all",borderWidth:"0px",width:"0px 0px 0px 0px"}},hasBoxShadowBtn:{normal:!1,hover:!1},boxShadowBtn:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},roundedBtnV2:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"rounded"}},align:{desktop:"left"},typo:{type:"paragraph-1"},transform:"default",btnSpacing:{type:"medium"},fullWidth:{desktop:!0},iconSizeAuto:!0,size:{desktop:"1em"},iconDimension:{desktop:"24px"},spacing:"8px",successTypo:{type:"paragraph-2"},successColor:"success",errorTypo:{type:"paragraph-2"},errorColor:"error",isCustomOutOfStock:!1,oosBackground:"brand",oosTextColor:"text-3",oosBorder:{normal:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,borderWidth:"0px",width:"0px 0px 0px 0px"}},oosEnableShadow:!1,oosShadow:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90},oosRounded:{radiusType:"none"},globalSize:{desktop:{width:"100%"}},enableIcon:!1,enablePrice:!1,enableSeparator:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]}]}]}]}]}]}]};exports.StickyPreset=StickyPreset,exports.StickyPresetProduct=StickyPresetProduct,exports.StickyPresetScrollToTop=StickyPresetScrollToTop;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
let SettingUIV2=[{controls:[{setting:{id:"layout"},layout:"vertical"}]},{label:{en:"Column spacing"},conditionDisplay:"childrens > 1",controls:[{setting:{id:"verticalGutter"},label:{en:"Gap"},conditionDisplay:'layout.cols.length > 1 && pageType !== "POST_PURCHASE"',controlChangeTrigger:{settings:[{condition:"activeScreenId !== 'desktop'",action:{controlId:"verticalGutterMobile",groupType:"style",controlType:"style"}}],options:{noRecordHistory:!0}}},{setting:{id:"verticalGutterMobile"},label:{en:"Gap"},conditionDisplay:'layout.cols.length === 1 && pageType !== "POST_PURCHASE"',controlChangeTrigger:{settings:[{condition:"activeScreenId !== 'desktop'",action:{controlId:"verticalGutter",groupType:"style",controlType:"style"}}],options:{noRecordHistory:!0}}},{label:{en:"Column gap"},setting:{id:"columnGap"},conditionDisplay:'pageType == "POST_PURCHASE"',conditionEnable:"!!layout.cols && layout.cols.length > 1"}]},{label:{en:"Size"},controls:[{id:"Width",setting:{id:"width"},label:{en:"Width"},layout:"horizontal"},{label:{en:"Padding"},controlConfig:{id:"padding",type:"padding-v2",linkWithSetting:{name:"spacing-setting",field:"padding"},compoDefaultValue:{desktop:{default:{top:"var(--g-s-2xl)",bottom:"var(--g-s-2xl)"}},tablet:{default:{top:"var(--g-s-2xl)",bottom:"var(--g-s-2xl)",left:"var(--g-s-l)",right:"var(--g-s-l)",linked:!1}}}},conditionDisplay:'pageType !== "POST_PURCHASE"'},{setting:{id:"enablePagePadding"},label:{en:"Page padding"},help:{content:"Page padding controls the <br> space between the browser <br> edge and sections. Adjust it in <br> Global Style > Page Padding."},conditionDisplay:'pageType !== "POST_PURCHASE"'}]},{label:{en:"Background"},conditionDisplay:'pageType != "POST_PURCHASE"',controls:[{setting:{id:"background"},layout:"vertical",options:{updateFields:[{field:"preload",settingId:"preloadBgImage"}]},controlChangeTrigger:{settings:[{action:{controlId:"preloadBgImage",valueFromField:"preload",groupType:"style",controlType:"style",removeDevice:!0}}],options:{noRecordHistory:!0}}}]},{label:{en:"Shape"},conditionDisplay:'pageType != "POST_PURCHASE"',controls:[{label:{en:"Border"},controlConfig:{id:"border-advanced",type:"border-v2",linkWithSetting:{name:"border",field:"normal"},compoDefaultValue:{color:"line-3",border:"solid",width:"1px",borderWidth:"1px"}}},{label:{en:"Corner"},setting:{id:"rounded",state:"normal"}},{label:{en:"Shadow"},setting:{id:"boxShadow",state:"normal"},controlConfig:{id:"boxShadow",type:"shadow-v2"},options:{updateFields:[{field:"normal.enable",settingId:"hasBoxShadow",state:"normal"}]},controlChangeTrigger:{settings:[{condition:"boxShadow.normal.enable === true",source:["boxShadow","hasBoxShadow"],action:{controlId:"hasBoxShadow",groupType:"advanced",controlType:"advanced",state:"normal",newValue:!0}},{condition:"boxShadow.normal.enable === false",source:["boxShadow","hasBoxShadow"],action:{controlId:"hasBoxShadow",groupType:"advanced",controlType:"advanced",state:"normal",newValue:!1}}],options:{noRecordHistory:!0}}}]},{label:{en:"Align"},conditionDisplay:"pageType != \"POST_PURCHASE\" && (layout.display !== 'fill' || (!!layout.cols && layout.cols.length > 1))",controls:[{id:"verticalAlign",label:{en:"Vertical"},setting:{id:"verticalAlign"},conditionDisplay:"!!layout.cols && layout.cols.length > 1"},{id:"horizontalAlign",label:{en:"Horizontal"},setting:{id:"horizontalAlign"},conditionDisplay:"layout.display !== 'fill'",options:{disableMessage:'Horizontal Align is available when layout is "Fit to content"'}}]}];export{SettingUIV2};
|
|
1
|
+
let SettingUIV2=[{controls:[{setting:{id:"layout"},layout:"vertical"}]},{label:{en:"Column spacing"},conditionDisplay:"childrens > 1",controls:[{setting:{id:"verticalGutter"},label:{en:"Gap"},conditionDisplay:'layout.cols.length > 1 && pageType !== "POST_PURCHASE"',controlChangeTrigger:{settings:[{condition:"activeScreenId !== 'desktop'",action:{controlId:"verticalGutterMobile",groupType:"style",controlType:"style"}}],options:{noRecordHistory:!0}}},{setting:{id:"verticalGutterMobile"},label:{en:"Gap"},conditionDisplay:'layout.cols.length === 1 && pageType !== "POST_PURCHASE"',controlChangeTrigger:{settings:[{condition:"activeScreenId !== 'desktop'",action:{controlId:"verticalGutter",groupType:"style",controlType:"style"}}],options:{noRecordHistory:!0}}},{label:{en:"Column gap"},setting:{id:"columnGap"},conditionDisplay:'pageType == "POST_PURCHASE"',conditionEnable:"!!layout.cols && layout.cols.length > 1"}]},{label:{en:"Size"},controls:[{id:"Width",setting:{id:"width"},label:{en:"Width"},layout:"horizontal",conditionDisplay:'pageType !== "POST_PURCHASE"'},{label:{en:"Width"},layout:"horizontal",controlConfig:{id:"width-post-purchase",type:"dropdown:input",label:"Width",inputType:"number",units:["px","%"],hideUnit:!1,isRowWith:!0,linkWithSetting:{name:"width"},displayOptions:[{label:"Full",value:"100%",showValue:!0}]},conditionDisplay:'pageType === "POST_PURCHASE"'},{label:{en:"Padding"},controlConfig:{id:"padding",type:"padding-v2",linkWithSetting:{name:"spacing-setting",field:"padding"},compoDefaultValue:{desktop:{default:{top:"var(--g-s-2xl)",bottom:"var(--g-s-2xl)"}},tablet:{default:{top:"var(--g-s-2xl)",bottom:"var(--g-s-2xl)",left:"var(--g-s-l)",right:"var(--g-s-l)",linked:!1}}}},conditionDisplay:'pageType !== "POST_PURCHASE"'},{setting:{id:"enablePagePadding"},label:{en:"Page padding"},help:{content:"Page padding controls the <br> space between the browser <br> edge and sections. Adjust it in <br> Global Style > Page Padding."},conditionDisplay:'pageType !== "POST_PURCHASE"'}]},{label:{en:"Background"},conditionDisplay:'pageType != "POST_PURCHASE"',controls:[{setting:{id:"background"},layout:"vertical",options:{updateFields:[{field:"preload",settingId:"preloadBgImage"}]},controlChangeTrigger:{settings:[{action:{controlId:"preloadBgImage",valueFromField:"preload",groupType:"style",controlType:"style",removeDevice:!0}}],options:{noRecordHistory:!0}}}]},{label:{en:"Shape"},conditionDisplay:'pageType != "POST_PURCHASE"',controls:[{label:{en:"Border"},controlConfig:{id:"border-advanced",type:"border-v2",linkWithSetting:{name:"border",field:"normal"},compoDefaultValue:{color:"line-3",border:"solid",width:"1px",borderWidth:"1px"}}},{label:{en:"Corner"},setting:{id:"rounded",state:"normal"}},{label:{en:"Shadow"},setting:{id:"boxShadow",state:"normal"},controlConfig:{id:"boxShadow",type:"shadow-v2"},options:{updateFields:[{field:"normal.enable",settingId:"hasBoxShadow",state:"normal"}]},controlChangeTrigger:{settings:[{condition:"boxShadow.normal.enable === true",source:["boxShadow","hasBoxShadow"],action:{controlId:"hasBoxShadow",groupType:"advanced",controlType:"advanced",state:"normal",newValue:!0}},{condition:"boxShadow.normal.enable === false",source:["boxShadow","hasBoxShadow"],action:{controlId:"hasBoxShadow",groupType:"advanced",controlType:"advanced",state:"normal",newValue:!1}}],options:{noRecordHistory:!0}}}]},{label:{en:"Align"},conditionDisplay:"pageType != \"POST_PURCHASE\" && (layout.display !== 'fill' || (!!layout.cols && layout.cols.length > 1))",controls:[{id:"verticalAlign",label:{en:"Vertical"},setting:{id:"verticalAlign"},conditionDisplay:"!!layout.cols && layout.cols.length > 1"},{id:"horizontalAlign",label:{en:"Horizontal"},setting:{id:"horizontalAlign"},conditionDisplay:"layout.display !== 'fill'",options:{disableMessage:'Horizontal Align is available when layout is "Fit to content"'}}]}];export{SettingUIV2};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{makeStyleResponsive as
|
|
1
|
+
import{makeStyleResponsive as e,composeBorderResponsive as t,getResponsiveStyleShadowWithoutState as l,composeRadiusResponsive as o,getStyleBackgroundByDevice as r,getResponsiveStylePadding as b,getGradientBgrStyleByDevice as i,makeGlobalSize as n,makeStyle as a,getSingleColorVariable as p}from"@gem-sdk/core";let filterStyles=e=>{let t=["--mb","--mb-mobile","--mb-tablet"];return t.forEach(t=>{delete e?.[t]}),e},getStyleContainerIconlistMain=({styles:t,style:l,type:o,advanced:r})=>{let{align:b}=t??{};return{...l="react"===o?filterStyles(l):l,...e("jc",b),...e("d",{desktop:r?.d?.desktop?"flex":"none",tablet:r?.d?.tablet?"flex":"none",mobile:r?.d?.mobile?"flex":"none"})}},getStyleWraplistIcon=({styles:n})=>{let{panelAlign:a,contentBoxPadding:p,contentBoxWidth:s,background:c,contentBoxBorder:d,contentBoxRounded:y,contentBoxShadow:g}=n??{};return{...t(d),...l(g,"box-shadow",g),...o(y),...r(c),...b(p),...e("w",s),...e("jc",a),...i(c,{desktop:!0,tablet:!0,mobile:!0})}},getStyleColListIcon=({styles:t})=>{let{verticalSpacing:l}=t??{};return{...e("rg",l)}},getStyleWrapItemIcon=({styles:t})=>{let{horizontalSpacing:l,position:o}=t??{};return{...e("cg",l),...e("ai",o)}},getStyleWrapIcon=({styles:t,setting:l})=>{let{iconBorder:o,backgroundColor:r,iconRounded:b}=t??{},{globalSize:i}=l??{},s=n(i);return{...s.padding,...a({bs:o?.border,bw:o?.width,bc:p(o?.color),bg:r,bblr:b?.bblr,bbrr:b?.bbrr,btlr:b?.btlr,btrr:b?.btrr}),...e("pos",{desktop:"relative",tablet:"relative",mobile:"relative"}),...e("top",{desktop:"inherit",tablet:"inherit",mobile:"inherit"})}},getStyleIcon=({styles:e,setting:t})=>{let{iconColor:l}=e||{},{iconWidth:o}=t??{};return{"--c":p(l),"--w":"100%","--h":"100%","--size-desktop":`${o?.desktop}px`,"--size-tablet":`${o?.tablet||o?.desktop}px`,"--size-mobile":`${o?.mobile||o?.tablet||o?.desktop}px`}},getStyleTypoText=({setting:e})=>({typo:e?.textTypo});export{getStyleColListIcon,getStyleContainerIconlistMain,getStyleIcon,getStyleTypoText,getStyleWrapIcon,getStyleWrapItemIcon,getStyleWraplistIcon};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import{jsx as e,jsxs as t}from"react/jsx-runtime";import{useGetProductId as s}from"../../hooks/useGetProductId.js";import{useRef as r}from"react";import m from"../../text/components/Text.js";import{createClass as l,createStyle as o,createAttr as a,If as i}from"@gem-sdk/system";import{getClassWraplistIcon as c,getClassColListIcon as n,getClassWrapItemIcon as d,getClassWrapIcon as p,getClassIcon as u,getClassTextItem as f}from"../common/classes.js";import{getStyleContainerIconlistMain as y,getStyleWraplistIcon as h,getStyleColListIcon as g,getStyleWrapIcon as v,getStyleWrapItemIcon as N,getStyleIcon as j,getStyleTypoText as x}from"../common/styles.js";import{getvalueMap as I,getTextIconTranslations as L,getTextIconNotFound as S}from"../common/helpers.js";let IconListV2=T=>{let{builderProps:$,builderAttrs:k,style:w,setting:V,styles:_,pageContext:q}=T,
|
|
2
|
+
import{jsx as e,jsxs as t}from"react/jsx-runtime";import{useGetProductId as s}from"../../hooks/useGetProductId.js";import{useRef as r}from"react";import m from"../../text/components/Text.js";import{createClass as l,createStyle as o,createAttr as a,If as i}from"@gem-sdk/system";import{getClassWraplistIcon as c,getClassColListIcon as n,getClassWrapItemIcon as d,getClassWrapIcon as p,getClassIcon as u,getClassTextItem as f}from"../common/classes.js";import{getStyleContainerIconlistMain as y,getStyleWraplistIcon as h,getStyleColListIcon as g,getStyleWrapIcon as v,getStyleWrapItemIcon as N,getStyleIcon as j,getStyleTypoText as x}from"../common/styles.js";import{getvalueMap as I,getTextIconTranslations as L,getTextIconNotFound as S}from"../common/helpers.js";let IconListV2=T=>{let{builderProps:$,builderAttrs:k,style:w,setting:V,styles:_,pageContext:q,advanced:C}=T,G=l({[$?.uid??""]:!0}),H=l(c()),M=l(n()),P=l(d({builderProps:$})),b=l(p()),z=l(u()),A=l(f({setting:V})),B=o(y({styles:_,style:w,type:"react",advanced:C})),D=o(h({styles:_})),E=o(g({styles:_})),F=o(v({styles:_,setting:V})),J=o(N({styles:_})),K=o(j({styles:_,setting:V})),O=x({setting:V}),Q=a({...k}),R=S("react"),U=I({setting:V}),W=r(null),{refContainer:X,productID:Y}=s();return e("div",{...Q,...$,"data-id":$?.uid,style:B,className:G,ref:X,children:i(!U||!U.length,e("div",{children:R}),e("div",{className:H,style:D,children:e("div",{className:M,style:E,children:U?.map((s,r)=>{let l=L({setting:V,builderProps:$,pageContext:q,key:r,type:"react"});return t("div",{"data-index":r,className:P,style:J,children:[e("div",{className:b,style:F,children:e("span",{style:K,className:z,dangerouslySetInnerHTML:{__html:s}})}),e(m,{setting:{text:l?.toString(),htmlTag:"div",options:{useState:!0,uniqueId:`${$?.uid}-${r}-${Y}`,productID:Y,customClass:{wrapper:"gp-w-full"}}},styles:O,className:A,ref:W})]},r)})})}))})};export{IconListV2 as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
let SettingUIV2=[{label:{en:"Size"},controls:[{type:"control",label:{en:"Width"},setting:{id:"inputWidth"},layout:"horizontal"}]},{label:{en:"Display"},controls:[{label:{en:"Default quantity"},setting:{id:"defaultQtyValue"},layout:"horizontal"},{type:"combo",label:{en:"Label title"},iconName:"polaris-text-block",getValueFromSettingID:"title",disableClearMessage:"This label title is needed for customers <br> to adjust the product's quantity",controls:[{label:{en:"Content"},setting:{id:"title"},layout:"vertical",options:{clearButton:!1}}]}]},{controls:[{type:"control",label:{en:"Align"},setting:{id:"align"},conditionEnable:'!(parseInt(inputWidth) >= 100 && inputWidth?.includes("%"))',options:{labelVariant:"primary",fullWidth:!0,disableMessage:"Horizontal alignment is disabled when the width is set to 100% or greater"},layout:"horizontal"}]}];export{SettingUIV2};
|
|
1
|
+
let SettingUIV2=[{label:{en:"Size"},controls:[{type:"control",label:{en:"Width"},setting:{id:"inputWidth"},layout:"horizontal"}]},{label:{en:"Display options"},controls:[{label:{en:"Default quantity"},setting:{id:"defaultQtyValue"},layout:"horizontal"},{type:"combo",label:{en:"Label title"},iconName:"polaris-text-block",getValueFromSettingID:"title",disableClearMessage:"This label title is needed for customers <br> to adjust the product's quantity",controls:[{label:{en:"Content"},setting:{id:"title"},layout:"vertical",options:{clearButton:!1}}]}]},{controls:[{type:"control",label:{en:"Align"},setting:{id:"align"},conditionEnable:'!(parseInt(inputWidth) >= 100 && inputWidth?.includes("%"))',options:{labelVariant:"primary",fullWidth:!0,disableMessage:"Horizontal alignment is disabled when the width is set to 100% or greater"},layout:"horizontal"}]}];export{SettingUIV2};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import{jsx as t,jsxs as e}from"react/jsx-runtime";import{useCurrentVariant as s,useQuantity as o}from"@gem-sdk/core";import{createAttr as
|
|
2
|
+
import{jsx as t,jsxs as e}from"react/jsx-runtime";import{useCurrentVariant as s,useQuantity as o}from"@gem-sdk/core";import{createAttr as l,createClass as n,createStyle as r,If as a}from"@gem-sdk/system";import{useProductQuantity as i}from"./hooks/useProductQuantity.js";import{getContainerAttrs as m,getInputAttr as u,getButtonAttrs as c}from"./common/attrs.js";import{getContainerClasses as d,getWrapperClasses as y,getInputClasses as b,getButtonClass as f,getIconWrapperClasses as h}from"./common/classes.js";import{getContainerStyles as p,getWrapperStyles as g,getInputStyle as N,getButtonStyle as j}from"./common/styles.js";import{getIconWidth as v,getMinusIcon as B,getPlusIcon as H}from"./common/helpers.js";let ProductQuantity=S=>{let{setting:k={},styles:C={},builderProps:D,advanced:Q}=S,_=s(),{quantity:P}=o(),{isInStock:x,ref:I,onClickIncrement:L,onClickDecrement:M,onChangeInput:T,onFocusInput:F}=i(S),{plusIcon:V,minusIcon:q}=k,w=k.defaultQtyValue||1,{inputHeight:z,buttonBackgroundColor:A,backgroundColor:E,iconColor:G,inputBackgroundColor:J,textColor:K,align:O,borderBtn:R,buttonWidth:U,iconSizeCustom:W,corner:X}=C,Y=k?.hasButton,Z=l({...m({isDisabled:!x,uid:D?.uid||""})}),$=n({...d(Q?.cssClass)}),tt=r({...p({align:O,inputHeight:z})}),te=n({...y()}),ts=r({...g({backgroundColor:E,styles:C,setting:k})}),to=l({...u({hasButton:Y,quantity:P,currentVariant:_,defaultQty:w})}),tl=n({...b({styles:C,borderBtn:R,inputBackgroundColor:J,textColor:K,isDisabled:!x})}),tn=r({...N(S)}),tr=n({...f({borderBtn:R,buttonBackgroundColor:A,iconColor:G,buttonSide:"left",isDisabled:!x})}),ta=r({...j({borderBtn:R,buttonWidth:U,buttonBackgroundColor:A,iconColor:G,corner:X,enableHoverButton:k?.enableHoverButton})}),ti=l({...c({buttonSide:"left"})}),tm=n({...f({borderBtn:R,buttonBackgroundColor:A,iconColor:G,buttonSide:"right",isDisabled:!x})}),tu=r({...j({borderBtn:R,buttonWidth:U,buttonBackgroundColor:A,iconColor:G,corner:X,enableHoverButton:k?.enableHoverButton})}),tc=l({...c({buttonSide:"right"})}),td=n({...h()}),ty=r({...v(W)});return t("div",{ref:I,...Z,className:$,style:tt,children:e("div",{className:te,style:ts,children:[a(Y,t("button",{...ti,onClick:M,className:tr,style:ta,children:t("span",{className:td,style:ty,dangerouslySetInnerHTML:{__html:B(q)}})})),t("input",{...to,className:tl,style:tn,onChange:t=>T(t),onFocus:t=>F(t)}),a(Y,t("button",{...tc,onClick:L,className:tm,style:tu,children:t("span",{className:td,style:ty,dangerouslySetInnerHTML:{__html:H(V)}})}))]})})};export{ProductQuantity as default};
|
|
@@ -1,45 +1,45 @@
|
|
|
1
|
-
import{template as t,RenderIf as s,isLocalEnv as e,baseAssetURL as a}from"@gem-sdk/core";import{getSettingPreloadData as i}from"../../../helpers.js";import{createAttr as l,createClass as r,createStyle as o}from"@gem-sdk/system";import{getContainerAttrs as n,getInputAttr as
|
|
1
|
+
import{template as t,RenderIf as s,isLocalEnv as e,baseAssetURL as a}from"@gem-sdk/core";import{getSettingPreloadData as i}from"../../../helpers.js";import{createAttr as l,createClass as r,createStyle as o}from"@gem-sdk/system";import{getContainerAttrs as n,getInputAttr as u,getButtonAttrs as d}from"./common/attrs.js";import{getContainerClasses as c,getWrapperClasses as p,getInputClasses as f,getButtonClass as m,getIconWrapperClasses as $}from"./common/classes.js";import{getContainerStyles as b,getWrapperStyles as y,getInputStyle as v,getButtonStyle as g}from"./common/styles.js";import{getIconWidth as S,getMinusIcon as _,getPlusIcon as h}from"./common/helpers.js";let ProductQuantity=({setting:j={},styles:q={},advanced:B,builderProps:k})=>{let{plusIcon:E,minusIcon:H,updatePrice:P}=j,Q=j.defaultQtyValue??1,{inputHeight:A,buttonBackgroundColor:G,iconColor:L,inputBackgroundColor:M,textColor:V,align:x,borderBtn:C,buttonWidth:D,iconSizeCustom:I,corner:N,backgroundColor:O,dividerColor:R,dividerStroke:T}=q,w=j?.hasButton,z=l({...n({uid:k?.uid||"",isDisableByLiquid:!0})}),F=r({...c(B?.cssClass)}),J=o({...b({align:x,inputHeight:A})}),K=r({...p()}),U=o({...y({backgroundColor:O,styles:q,setting:j})}),W=l({...u({isLiquid:!0,hasButton:w,defaultQty:Q})}),X=r({...f({styles:q,borderBtn:C,inputBackgroundColor:M,textColor:V})}),Y=o({...v({setting:j,styles:{...q,borderBtn:C,inputBackgroundColor:M,textColor:V,dividerColor:R,dividerStroke:T}})}),Z=r({...m({borderBtn:C,buttonBackgroundColor:G,iconColor:L,buttonSide:"left"})}),tt=o({...g({borderBtn:C,buttonWidth:D,buttonBackgroundColor:G,iconColor:L,corner:N,enableHoverButton:j?.enableHoverButton})}),ts=l({...d({buttonSide:"left"})}),te=r({...m({borderBtn:C,buttonBackgroundColor:G,iconColor:L,buttonSide:"right"})}),ta=o({...g({borderBtn:C,buttonWidth:D,buttonBackgroundColor:G,iconColor:L,corner:N,enableHoverButton:j?.enableHoverButton})}),ti=l({...d({buttonSide:"right"})}),tl=r({...$()}),tr=S(I);return t`
|
|
2
2
|
{%- liquid
|
|
3
3
|
assign current_variant = product.selected_or_first_available_variant
|
|
4
4
|
assign available = current_variant.available | default: false
|
|
5
5
|
-%}
|
|
6
6
|
<gp-product-quantity
|
|
7
|
-
${{...
|
|
8
|
-
data-price="${
|
|
9
|
-
class="${
|
|
10
|
-
style="${
|
|
7
|
+
${{...z}}
|
|
8
|
+
data-price="${P}"
|
|
9
|
+
class="${F}"
|
|
10
|
+
style="${J}"
|
|
11
11
|
>
|
|
12
|
-
<div class="${
|
|
13
|
-
${s(
|
|
12
|
+
<div class="${K}" style="${U}">
|
|
13
|
+
${s(w,t`
|
|
14
14
|
<button
|
|
15
15
|
{% if available == false %} disabled {% endif %}
|
|
16
|
-
${{...
|
|
17
|
-
class="${
|
|
18
|
-
style="${
|
|
16
|
+
${{...ts}}
|
|
17
|
+
class="${Z}"
|
|
18
|
+
style="${tt}"
|
|
19
19
|
>
|
|
20
|
-
<span class="${
|
|
20
|
+
<span class="${tl}" style="${tr}"
|
|
21
21
|
>
|
|
22
|
-
${_(
|
|
22
|
+
${_(H)}
|
|
23
23
|
</span>
|
|
24
24
|
</button>
|
|
25
25
|
`)}
|
|
26
26
|
<input
|
|
27
27
|
{% if available == false %} disabled {% endif %}
|
|
28
|
-
${{...
|
|
29
|
-
class="${
|
|
30
|
-
style="${
|
|
28
|
+
${{...W}}
|
|
29
|
+
class="${X}"
|
|
30
|
+
style="${Y}"
|
|
31
31
|
inputMode="numeric"
|
|
32
32
|
/>
|
|
33
33
|
|
|
34
|
-
${s(
|
|
34
|
+
${s(w,t`
|
|
35
35
|
<button
|
|
36
36
|
{% if available == false %} disabled {% endif %}
|
|
37
|
-
${{...
|
|
38
|
-
class="${
|
|
39
|
-
style="${
|
|
37
|
+
${{...ti}}
|
|
38
|
+
class="${te}"
|
|
39
|
+
style="${ta}"
|
|
40
40
|
>
|
|
41
|
-
<span class="${
|
|
42
|
-
${
|
|
41
|
+
<span class="${tl}" style="${tr}">
|
|
42
|
+
${h(E)}
|
|
43
43
|
</span>
|
|
44
44
|
</button>
|
|
45
45
|
`)}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
let getContainerAttrs=({uid:t,isDisabled:e=!0,isDisableByLiquid:n})=>({"data-id":t,"data-disabled":n?"{%- if available -%} false {%- else -%} true {%- endif -%}":e}),getButtonAttrs=({buttonSide:t})=>({title:"left"===t?"Decrement":"Increment","aria-label":"left"===t?"decrement":"increment",type:"button"}),getInputAttr=({isLiquid:t,
|
|
1
|
+
let getContainerAttrs=({uid:t,isDisabled:e=!0,isDisableByLiquid:n})=>({"data-id":t,"data-disabled":n?"{%- if available -%} false {%- else -%} true {%- endif -%}":e}),getButtonAttrs=({buttonSide:t})=>({title:"left"===t?"Decrement":"Increment","aria-label":"left"===t?"decrement":"increment",type:"button"}),getInputAttr=({isLiquid:t,hasButton:e,quantity:n,currentVariant:a,defaultQty:r})=>{let i={};return a?.manageInventory&&(i.max=t?"{{ current_variant.quantity_rule.max }}":a?.inventoryQuantity??1),{type:e?"text":"number",name:"quantity",step:1,min:1,"aria-label":"quantity",inputMode:"numeric",quantity:t?"current_variant.quantity":n??0,autocomplete:"off",value:n??r??1,...i}};export{getButtonAttrs,getContainerAttrs,getInputAttr};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{composeTypographyClassName as e,handleConvertClassColor as t,getGlobalColorStateClass as p,composeClasses as g}from"@gem-sdk/core";let getInputClasses=({styles:l,borderBtn:
|
|
1
|
+
import{composeTypographyClassName as e,handleConvertClassColor as t,getGlobalColorStateClass as p,composeClasses as g}from"@gem-sdk/core";let getInputClasses=({styles:l,borderBtn:s,inputBackgroundColor:n,textColor:r,isDisabled:a})=>{let o="gp-flex gp-w-full gp-px-1 gp-min-w-[45px] gp-shrink-[99999] gp-appearance-none gp-items-center gp-text-center gp-outline-none gp-transition-all gp-duration-150 hover:gp-text-black disabled:gp-cursor-not-allowed",i=e(l?.typo,l?.typography),u=t(s),c=p("bg",n),d=p("text",r);return u&&(o+=` ${u} `),i&&(o+=` ${i} `),c&&(o+=` ${c} `),d&&(o+=` ${d} `),a&&(o+="gp-cursor-not-allowed"),{...g(o)}},getButtonClass=({borderBtn:e,buttonBackgroundColor:l,iconColor:s,buttonSide:n,isDisabled:r})=>{let a=`gp-flex gp-aspect-square gp-h-full disabled:gp-cursor-not-allowed ${r?"gp-cursor-not-allowed":"gp-cursor-pointer"} gp-items-center gp-justify-center gp-outline-none ${"left"===n?"gp-minus":"gp-plus"} `,o=t(e),i=p("bg",l),u=p("text",s);return o&&(a+=` ${o} `),i&&(a+=` ${i} `),u&&(a+=` ${u} `),{...g(a)}},getContainerClasses=e=>({...g(`quantityClass gp-relative gp-inline-flex gp-h-12 gp-w-full gp-bg-transparent gp-transition-all gp-duration-150 data-[disabled=true]:gp-opacity-60 ${e??""}`)}),getWrapperClasses=()=>({...g("gp-inline-flex gp-w-full gp-overflow-hidden")}),getIconWrapperClasses=()=>({...g("gp-inline-flex gp-items-center gp-justify-center [&>*]:gp-h-full [&>*]:gp-w-full")});export{getButtonClass,getContainerClasses,getIconWrapperClasses,getInputClasses,getWrapperClasses};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{composeTypographyStyle as e,getStyleShadowState as t,
|
|
1
|
+
import{composeTypographyStyle as e,getStyleShadowState as t,getGlobalColorStateStyle as r,makeStyle as o,getStyleShadow as l,filterHoverVariables as a,makeStyleResponsive as n,handleConvertBorderStyle as d,handleConvertBorderWidth as i,handleConvertBorderColor as s,composeRadius as p,getResponsiveStyleShadowWithoutState as h,composeBorderResponsive as b,composeRadiusResponsive as u,makeStyleState as g}from"@gem-sdk/core";let addPxToValues=e=>Object.fromEntries(Object.entries(e).map(([e,t])=>[e,`${t}px`])),getDividerWidth=(e,t)=>{if(!e||!t)return{};let r=addPxToValues(e),o={...g("brw",r),...g("blw",r)};return o},getDividerColorStyle=e=>{if(!e)return{};let t={...e,normal:e?.normal??"transparent"},o={...r("brc",t),...r("blc",t)},l=Object.fromEntries(Object.entries(o).filter(([e,t])=>void 0!==t));return l},getInputStyle=n=>{let{styles:d,setting:i}=n,{inputBackgroundColor:s,textColor:p,dividerColor:h,dividerStroke:b,inputBoxShadow:u}=d??{},{enableHoverInput:g,hasButton:y}=i??{},m=e(d?.typo,d?.typography),S=t(u,"box-shadow",{normal:!!u?.normal,hover:!!u?.hover}),c={...getDividerWidth(b,h),...getDividerColorStyle(h)},w={...r("bg",s),...S,...r("c",{...p,hover:p?.hover??p?.normal}),...y?c:{}},v={...o({}),...m,...w,...l({value:d?.typo?.custom?.textShadow,styleAppliedFor:"text-shadow",isEnableShadow:d?.typo?.custom?.hasShadowText})};return g?v:a(v)},getButtonStyle=({borderBtn:e,buttonWidth:t,buttonBackgroundColor:o,iconColor:l,corner:h,enableHoverButton:b})=>{let u={...n("w",t),...d(e),...i(e),...s(e),...r("bg",o),...r("c",l),...p(h)};return b?u:a(u)},getContainerStyles=({inputHeight:e,align:t})=>({...n("h",e),...n("jc",t)}),getWrapperStyles=({backgroundColor:e,styles:t,setting:o})=>{let{enableHoverInput:l,hasButton:a}=o??{},p=t?.shapeShadow,g=h(p,"box-shadow",{desktop:p?.desktop??{},tablet:p?.tablet??p?.desktop??{},mobile:p?.mobile??p?.tablet??p?.desktop??{}}),y=t?.inputBorder,m=l&&!a,S={...d(y),...i(y),...s(y)};return{...m?S:{},...r("bg",e),...n("maxw",t?.quantityWidth),...b(t?.shapeBorder),...u(t?.shapeRounded),...g}};export{getButtonStyle,getContainerStyles,getInputStyle,getWrapperStyles};
|
|
@@ -1,21 +1,19 @@
|
|
|
1
1
|
let ProductQuantityPresets=[{id:"product-quantity",name:{en:"Product Quantity"},icon:{desktop:`
|
|
2
|
-
<svg width="96" height="
|
|
3
|
-
<
|
|
4
|
-
<path
|
|
2
|
+
<svg width="96" height="36" viewBox="0 0 96 36" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
3
|
+
<rect x="0.5" y="0.5" width="95" height="35" rx="2.5" stroke="#424242"/>
|
|
4
|
+
<g clip-path="url(#clip0_23331_7683)">
|
|
5
|
+
<path d="M10 18C10 17.7239 10.2239 17.5 10.5 17.5H19.5C19.7761 17.5 20 17.7239 20 18C20 18.2761 19.7761 18.5 19.5 18.5H10.5C10.2239 18.5 10 18.2761 10 18Z" fill="#F9F9F9"/>
|
|
5
6
|
</g>
|
|
6
|
-
<
|
|
7
|
-
<path
|
|
8
|
-
<
|
|
9
|
-
<g clip-path="url(#clip1_1631_19448)">
|
|
10
|
-
<path d="M81.45 19.95C81.45 19.7015 81.2485 19.5 81 19.5C80.7515 19.5 80.55 19.7015 80.55 19.95V23.55H76.95C76.7015 23.55 76.5 23.7515 76.5 24C76.5 24.2485 76.7015 24.45 76.95 24.45H80.55V28.05C80.55 28.2985 80.7515 28.5 81 28.5C81.2485 28.5 81.45 28.2985 81.45 28.05V24.45H85.05C85.2985 24.45 85.5 24.2485 85.5 24C85.5 23.7515 85.2985 23.55 85.05 23.55H81.45V19.95Z" fill="#AAAAAA"/>
|
|
7
|
+
<path d="M49.1825 13.2727V22H48.1257V14.3807H48.0746L45.9439 15.7955V14.7216L48.1257 13.2727H49.1825Z" fill="#F9F9F9"/>
|
|
8
|
+
<g clip-path="url(#clip1_23331_7683)">
|
|
9
|
+
<path d="M81.45 13.95C81.45 13.7015 81.2485 13.5 81 13.5C80.7515 13.5 80.55 13.7015 80.55 13.95V17.55H76.95C76.7015 17.55 76.5 17.7515 76.5 18C76.5 18.2485 76.7015 18.45 76.95 18.45H80.55V22.05C80.55 22.2985 80.7515 22.5 81 22.5C81.2485 22.5 81.45 22.2985 81.45 22.05V18.45H85.05C85.2985 18.45 85.5 18.2485 85.5 18C85.5 17.7515 85.2985 17.55 85.05 17.55H81.45V13.95Z" fill="#F9F9F9"/>
|
|
11
10
|
</g>
|
|
12
|
-
<rect x="0.5" y="6.5" width="95" height="35" rx="2.5" stroke="#424242"/>
|
|
13
11
|
<defs>
|
|
14
|
-
<clipPath id="
|
|
15
|
-
<rect x="7" y="
|
|
12
|
+
<clipPath id="clip0_23331_7683">
|
|
13
|
+
<rect x="7" y="10" width="16" height="16" rx="3" fill="white"/>
|
|
16
14
|
</clipPath>
|
|
17
|
-
<clipPath id="
|
|
18
|
-
<rect x="73" y="
|
|
15
|
+
<clipPath id="clip1_23331_7683">
|
|
16
|
+
<rect x="73" y="10" width="16" height="16" rx="3" fill="white"/>
|
|
19
17
|
</clipPath>
|
|
20
18
|
</defs>
|
|
21
19
|
</svg>
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
let ProductQuantitySettings=[{id:"setting",controls:[{id:"updatePrice",label:"Update price",type:"toggle",default:!0},{id:"
|
|
1
|
+
let ProductQuantitySettings=[{id:"setting",controls:[{id:"updatePrice",label:"Update price",type:"toggle",default:!0},{id:"hasButton",label:"Button",type:"toggle",default:!0},{id:"defaultQtyValue",label:"Text",type:"input:stepper",min:1,default:1},{id:"plusIcon",type:"icon",isHideClear:!0,customLabel:"Plus",info:"Choose from list or paste any SVG icon",default:`<svg height="20px" width="20px" data-name="plus-regular" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor" data-id="508817698760687976">
|
|
2
2
|
<path fill="currentColor" strokelinecap="round" strokelinejoin="round" d="M224,128a8,8,0,0,1-8,8H136v80a8,8,0,0,1-16,0V136H40a8,8,0,0,1,0-16h80V40a8,8,0,0,1,16,0v80h80A8,8,0,0,1,224,128Z"></path></svg>`},{id:"minusIcon",type:"icon",isHideClear:!0,customLabel:"Minus",info:"Choose from list or paste any SVG icon",default:`<svg height="20px" width="20px" data-name="minus-regular" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor" data-id="508817690725712232">
|
|
3
|
-
<path fill="currentColor" strokelinecap="round" strokelinejoin="round" d="M224,128a8,8,0,0,1-8,8H40a8,8,0,0,1,0-16H216A8,8,0,0,1,224,128Z"></path></svg>`},{id:"enableHoverInput",label:"Enable hover input",type:"toggle",default:!1},{id:"enableHoverButton",label:"Enable hover input",type:"toggle",default:!1}]},{id:"style",controls:[{id:"quantityLayout",label:"Style",type:"layout-selector",popoverLabel:{en:"Style"},iconViewBox:"0 0 80 48",enableItemBackground:!0,itemPerRow:2,itemSpacing:"large",options:[{label:"Square",value:"product-quantity-square",type:"p-quantity-layout",iconName:"gp-product-quantity-square"},{label:"Square with divider",value:"product-quantity-square-divider",type:"p-quantity-layout",iconName:"gp-product-quantity-square-divider"},{label:"Rounded",value:"product-quantity-rounded",type:"p-quantity-layout",iconName:"gp-product-quantity-rounded"},{label:"Rounded with divider",value:"product-quantity-rounded-divider",type:"p-quantity-layout",iconName:"gp-product-quantity-rounded-divider"},{label:"Square input only",value:"product-quantity-square-input-only",type:"p-quantity-layout",iconName:"gp-product-quantity-square-input-only"},{label:"Rounded input only",value:"product-quantity-rounded-input-only",type:"p-quantity-layout",iconName:"gp-product-quantity-rounded-input-only"}],default:"product-quantity-square"},{id:"dimensions",type:"group",label:"Dimensions",controls:[{id:"fullWidth",label:"Full Width",type:"toggle",devices:{desktop:{default:!1}}},{id:"quantityWidth",type:"dropdown:input",label:"Width",inputType:"number",units:["px","%"],hideUnit:!1,displayOptions:[{label:"Full",value:"100%",showValue:!0}],devices:{desktop:{default:"160px"}}},{id:"inputHeight",type:"dropdown:input",label:"Width",inputType:"number",units:["px","%"],hideUnit:!1,displayOptions:[{label:"Full",value:"100%",showValue:!0}],devices:{desktop:{default:"45px"}}},{id:"buttonWidth",type:"dropdown:input",label:"Button Width",inputType:"number",units:["px","%"],hideUnit:!1,displayOptions:[{label:"Full",value:"100%",showValue:!0}],devices:{desktop:{default:"45px"}}},{id:"iconSizeCustom",type:"input:stepper",includeUnit:"px",min:1,devices:{desktop:{default:"16px"}}}]},{id:"inputStyle",type:"group",label:"Input Style",controls:[{id:"typo",type:"typography-
|
|
3
|
+
<path fill="currentColor" strokelinecap="round" strokelinejoin="round" d="M224,128a8,8,0,0,1-8,8H40a8,8,0,0,1,0-16H216A8,8,0,0,1,224,128Z"></path></svg>`},{id:"enableHoverInput",label:"Enable hover input",type:"toggle",default:!1},{id:"enableHoverButton",label:"Enable hover input",type:"toggle",default:!1}]},{id:"style",controls:[{id:"quantityLayout",label:"Style",type:"layout-selector",popoverLabel:{en:"Style"},iconViewBox:"0 0 80 48",enableItemBackground:!0,itemPerRow:2,itemSpacing:"large",options:[{label:"Square",value:"product-quantity-square",type:"p-quantity-layout",iconName:"gp-product-quantity-square"},{label:"Square with divider",value:"product-quantity-square-divider",type:"p-quantity-layout",iconName:"gp-product-quantity-square-divider"},{label:"Rounded",value:"product-quantity-rounded",type:"p-quantity-layout",iconName:"gp-product-quantity-rounded"},{label:"Rounded with divider",value:"product-quantity-rounded-divider",type:"p-quantity-layout",iconName:"gp-product-quantity-rounded-divider"},{label:"Square input only",value:"product-quantity-square-input-only",type:"p-quantity-layout",iconName:"gp-product-quantity-square-input-only"},{label:"Rounded input only",value:"product-quantity-rounded-input-only",type:"p-quantity-layout",iconName:"gp-product-quantity-rounded-input-only"}],default:"product-quantity-square"},{id:"dimensions",type:"group",label:"Dimensions",controls:[{id:"fullWidth",label:"Full Width",type:"toggle",devices:{desktop:{default:!1}}},{id:"quantityWidth",type:"dropdown:input",label:"Width",inputType:"number",units:["px","%"],hideUnit:!1,displayOptions:[{label:"Full",value:"100%",showValue:!0}],devices:{desktop:{default:"160px"}}},{id:"inputHeight",type:"dropdown:input",label:"Width",inputType:"number",units:["px","%"],hideUnit:!1,displayOptions:[{label:"Full",value:"100%",showValue:!0}],devices:{desktop:{default:"45px"}}},{id:"buttonWidth",type:"dropdown:input",label:"Button Width",inputType:"number",units:["px","%"],hideUnit:!1,displayOptions:[{label:"Full",value:"100%",showValue:!0}],devices:{desktop:{default:"45px"}}},{id:"iconSizeCustom",type:"input:stepper",includeUnit:"px",min:1,devices:{desktop:{default:"16px"}}}]},{id:"inputStyle",type:"group",label:"Input Style",controls:[{id:"typo",type:"typography-combo",default:{type:"paragraph-1",attrs:{color:"#121212"},custom:{fontSize:{desktop:"16px",tablet:"16px",mobile:"14px"},lineHeight:{desktop:"120%",tablet:"180%",mobile:"180%"},fontWeight:"400",fontFamily:{value:"Assistant",type:"google"},hasShadowText:!1,textShadow:{enable:!1}}},ignoreReRender:!0,hiddenSetting:{transform:!0,textAlign:!0}},{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:"button-behavior-state",type:"behavior-state",label:"Button Style",hide:!0,controls:[{id:"textColor",type:"color-picker-v2",label:"Text Color",default:{normal:"text-2"},compoDefaultValue:{hover:"text-2"},state:{hover:!0,normal:!0},enableGradient:!0},{id:"inputBackgroundColor",type:"color-picker-v2",label:"Background Color",state:{hover:!0,normal:!0},compoDefaultValue:{normal:"highlight",hover:"highlight"},enableGradient:!0},{id:"buttonBackgroundColor",type:"color-picker-v2",label:"Button Background Color",state:{hover:!0,normal:!0},enableGradient:!0,compoDefaultValue:{normal:"brand",hover:"highlight"}},{id:"iconColor",type:"color-picker-v2",label:"Icon Color",default:{normal:"#121212"},compoDefaultValue:{hover:"text-2"},state:{hover:!0,normal:!0},enableGradient:!0}]},{id:"borderBtn",label:"Border",type:"border-v2",default:{normal:{}},compoDefaultValue:{normal:{border:"solid",color:"#212121",width:"1px",borderWidth:"1px"},hover:{border:"solid",color:"#212121",width:"1px",borderWidth:"1px"}},state:{hover:!0,normal:!0}},{id:"corner",label:"Corner",type:"corner-v2",default:{normal:{btrr:"0px",bblr:"0px",bbrr:"0px",btlr:"0px",radiusType:"none"}}},{id:"inputBoxShadow",type:"shadow-v2",default:{normal:{}},compoDefaultValue:{normal:{type:"shadow-1",distance:"4px",blur:"4px",spread:"0px",color:"#121212",angle:90}}},{id:"backgroundColor",type:"color-picker-v2",label:"Background Color",default:{normal:"#FFFFFF",hover:"#FFFFFF"},state:{hover:!0,normal:!0},enableGradient:!0},{id:"dividerColor",type:"color-picker-v2",label:"Divider Color",default:{normal:"line-3"},compoDefaultValue:{normal:"line-3"},state:{hover:!0,normal:!0},enableGradient:!0},{id:"dividerStroke",label:"Thickness",type:"input:stepper",min:1,default:{normal:1,hover:1},state:{hover:!0,normal:!0}},{id:"inputBorder",label:"Input Border",type:"border-v2",default:{hover:{border:"solid",color:"line-3",width:"1px",borderWidth:"1px"}},state:{hover:!0,normal:!1}},{id:"shapeBorder",type:"border-v2",devices:{desktop:{default:{border:"solid",color:"line-3",width:"1px",borderWidth:"1px"}}}},{id:"shapeRounded",type:"corner-v2",devices:{desktop:{default:{radiusType:"none"}}}},{id:"shapeShadow",type:"shadow-v2",devices:{desktop:{default:{}}},compoDefaultValue:{desktop:{default:{type:"shadow-1",distance:"4px",blur:"4px",spread:"0px",color:"rgba(18, 18, 18, 0.20)",angle:45,enable:!0}}}}]}];export{ProductQuantitySettings};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
let SettingUIV2=[{label:{en:"
|
|
1
|
+
let SettingUIV2=[{controls:[{label:{en:"Button"},setting:{id:"hasButton"},options:{labelVariant:"primary",toggleStyle:"switch"}},{label:{en:"Width"},setting:{id:"buttonWidth"},conditionDisplay:"hasButton === true"},{label:{en:"Background"},setting:{id:"buttonBackgroundColor",state:"normal"},conditionDisplay:"hasButton === true"},{label:{en:"Plus icon"},setting:{id:"plusIcon"},conditionDisplay:"hasButton === true"},{label:{en:"Minus icon"},setting:{id:"minusIcon"},conditionDisplay:"hasButton === true"},{label:{en:"Icon color"},setting:{id:"iconColor",state:"normal"},conditionDisplay:"hasButton === true"}],moreSettings:{type:"collapse",controls:[{label:{en:"Icon size"},setting:{id:"iconSizeCustom"},conditionDisplay:"hasButton === true"},{label:{en:"Border"},setting:{id:"borderBtn",state:"normal"},conditionDisplay:"hasButton === true"},{label:{en:"Corner"},setting:{id:"corner",state:"normal"},conditionDisplay:"hasButton === true"},{label:{en:"Hover"},type:"combo",iconName:"polaris-check-clicked",fixedValue:"Styled",setting:{id:"enableHoverButton"},popoverLabel:{en:"Hover effect"},state:"hover",conditionDisplay:"hasButton === true",controls:[{label:{en:"Background"},setting:{id:"buttonBackgroundColor",state:"hover"},compoDefaultValue:{default:"highlight"}},{label:{en:"Icon color"},setting:{id:"iconColor",state:"hover"}},{label:{en:"Border"},setting:{id:"borderBtn",state:"hover"}},{label:{en:"Corner"},setting:{id:"corner",state:"hover"}}]}]}},{label:{en:"Input"},controls:[{label:{en:"Background"},setting:{id:"inputBackgroundColor",state:"normal"}},{label:{en:"Text style"},setting:{id:"typo"},options:{updateFields:[{field:"attrs.color",settingId:"textColor",state:"normal"}]},controlChangeTrigger:{settings:[{action:{controlId:"textColor",valueFromField:"attrs.color",groupType:"style",controlType:"style",removeDevice:!0,state:"normal"}}],options:{noRecordHistory:!0}}},{label:{en:"Divider"},type:"combo",conditionDisplay:"hasButton === true",comboType:"color",getValueFromSettingID:"dividerColor.normal",compoDefaultValue:"line-3",controls:[{label:{en:"Color"},setting:{id:"dividerColor",state:"normal"}},{label:{en:"Thickness"},setting:{id:"dividerStroke",state:"normal"}}]},{label:{en:"Shadow"},setting:{id:"inputBoxShadow",state:"normal"}},{label:{en:"Hover"},type:"combo",iconName:"polaris-check-clicked",fixedValue:"Styled",popoverLabel:{en:"Hover effect"},setting:{id:"enableHoverInput"},state:"hover",controls:[{label:{en:"Background"},setting:{id:"inputBackgroundColor",state:"hover"}},{label:{en:"Text color"},setting:{id:"textColor",state:"hover"}},{id:"divider-hover",label:{en:"Divider"},type:"combo",iconName:"polaris-edit",getValueFromSettingID:"dividerColor.hover",comboType:"color",compoDefaultValue:"line-3",controls:[{label:{en:"Color"},setting:{id:"dividerColor",state:"hover"}},{label:{en:"Thickness"},setting:{id:"dividerStroke",state:"hover"}}],conditionDisplay:"hasButton === true"},{label:{en:"Border"},setting:{id:"inputBorder",state:"hover"},conditionDisplay:"hasButton === false"},{label:{en:"Shadow"},setting:{id:"inputBoxShadow",state:"hover"}}]}]},{label:{en:"Size"},controls:[{label:{en:"Width"},setting:{id:"quantityWidth"}},{label:{en:"Height"},setting:{id:"inputHeight"}}]},{label:{en:"Background"},controls:[{label:{en:"Color"},setting:{id:"backgroundColor",state:"normal"}}]},{label:{en:"Shape"},controls:[{label:{en:"Border"},setting:{id:"shapeBorder"}},{label:{en:"Corner"},setting:{id:"shapeRounded"}},{label:{en:"Shadow"},setting:{id:"shapeShadow"}}]},{label:{en:"Display condition"},controls:[{label:{en:"Default quantity"},setting:{id:"defaultQtyValue"}},{label:{en:"Update price"},setting:{id:"updatePrice"}}]},{controls:[{label:{en:"Align"},conditionEnable:'!(parseInt(quantityWidth) >= 100 && quantityWidth?.includes("%"))',setting:{id:"align"},options:{labelVariant:"primary",fullWidth:!0,disableMessage:"Align is not supported when width is 100%"}}]}];export{SettingUIV2};
|
|
@@ -9,7 +9,7 @@ let StickyPreset={id:"sticky",name:{en:"Sticky Add to Cart"},icon:{desktop:`
|
|
|
9
9
|
<circle cx="64.2674" cy="46.5138" r="1.15512" fill="white"/>
|
|
10
10
|
<circle cx="69.5565" cy="46.5138" r="1.15512" fill="white"/>
|
|
11
11
|
</svg>
|
|
12
|
-
`},components:[{tag:"Sticky",label:"Sticky",settings:{width:{desktop:"100%"}},advanced:{hasBoxShadow:{desktop:{normal:!0}},boxShadow:{desktop:{normal:{type:"shadow-2",distance:"12px",blur:"12px",spread:"0px",color:"rgba(18, 18, 18, 0.2)",angle:45}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Product",label:"Product",settings:{layout:{desktop:{cols:[4,8],display:"fill"},mobile:{cols:[12]}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"},isSyncProduct:!0},styles:{verticalGutter:{desktop:"8px"},verticalGutterMobile:{desktop:"0px"},fullWidth:{desktop:!1}},advanced:{"spacing-setting":{desktop:{margin:{},padding:{left:"4px",right:"4px",top:"4px",bottom:"4px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,6],display:"fit"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px",tablet:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1},border:{desktop:{normal:{borderType:"none",border:"solid",borderWidth:"0px",width:"0px",color:"#121212",isCustom:!0}}},rounded:{desktop:{normal:{btrr:"0px",bblr:"0px",bbrr:"0px",btlr:"0px",radiusType:"none"}}},hasBoxShadow:{desktop:{normal:!1}},boxShadow:{desktop:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}}},op:{desktop:"100%"}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductImagesV2",label:"Product Images",settings:{hoverEffect:"none"},styles:{position:{desktop:"only-feature",mobile:"only-feature"},ftShape:{desktop:{shape:"square",shapeValue:"1/1",width:"32px",height:void 0}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductTitle",label:"Product Title",settings:{htmlTag:"h1",linkProduct:!1},styles:{typo:{type:"subheading-3",custom:{fontSize:{desktop:"16px"},fontWeight:"400",lineHeight:"24px",letterSpacing:"0.6px",fontStyle:"normal"}},textAlign:{desktop:"left"},hasLineClamp:{desktop:!0},lineClamp:{desktop:1},color:{normal:"text-2"},hasTextShadow:{normal:!1,hover:!1},textShadow:{normal:{type:"shadow-1"}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}},{tag:"ProductPrice",label:"Product Price",settings:{priceType:"regular"},styles:{typo:{type:"subheading-2",default:{type:"subheading-2"},custom:{fontSize:{desktop:"14px"},fontWeight:"400",lineHeight:"20px",letterSpacing:"0.6px",fontStyle:"normal"}},lineThrough:!0,thickness:1,lineColor:"text-1",color:{normal:"text-2"},hasTextShadow:{normal:!1},textShadow:{normal:{type:"shadow-1"}},textAlign:{desktop:"left"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]}]}]},{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,3,3],display:"fill"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px",tablet:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductVariants",label:"Product Variants & Swatches",settings:{optionType:"groupOption",label:!0,optionAlign:{desktop:"left"},price:!0,showAsSwatches:!0,combineFullWidth:{desktop:!0},combineWidth:{desktop:"400px"},combineHeight:"40px",variantPresets:[{optionName:"base",optionType:"rectangle_list",presets:{color:{width:{desktop:"45px",tablet:"45px",mobile:"45px"},height:"45px",spacing:"16px"},rectangle_list:{width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px",spacing:"16px"},image:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},image_shopify:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},dropdown:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px"}}}],soldOutMark:!0,layout:{desktop:"vertical"},column:{desktop:1},hasPreSelected:!0,blankText:"Please select an option"},styles:{fullWidth:{desktop:!0},width:{desktop:"400px"},optionSpacing:"30px",labelGap:"8px",swatchAutoWidth:{desktop:!0},swatchWidth:{desktop:"80px"},swatchHeight:{desktop:"40px"},swatchSpacing:"var(--g-s-m)",marginBottom:{desktop:"var(--g-s-xl)",mobile:"var(--g-s-xl)"},align:{desktop:"left"},labelTypo:{type:"paragraph-2",attrs:{color:"text-1",bold:!0}},labelColor:"text-2",optionTypo:{type:"paragraph-2"},optionBgColor:{normal:"bg-3",hover:"bg-3",active:"bg-3"},optionTextColor:{normal:"text-2",hover:"text-2",active:"text-2"},optionBorder:{normal:{borderType:"style-2",border:"solid",color:"line-2",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"},active:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"2px 2px 2px 2px",borderWidth:"2px"},hover:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"}},optionRounded:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"custom"},hover:{radiusType:"none"},active:{radiusType:"none"}},optionHasShadow:{normal:!1},optionShadow:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},dropdownItemWidth:{desktop:"fill",mobile:"fill",tablet:"fill"},fixedDropdownWidth:{desktop:"240px"},swatchItemWidth:{desktop:"auto"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductQuantity",label:"Product Quantity",settings:{
|
|
12
|
+
`},components:[{tag:"Sticky",label:"Sticky",settings:{width:{desktop:"100%"}},advanced:{hasBoxShadow:{desktop:{normal:!0}},boxShadow:{desktop:{normal:{type:"shadow-2",distance:"12px",blur:"12px",spread:"0px",color:"rgba(18, 18, 18, 0.2)",angle:45}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Product",label:"Product",settings:{layout:{desktop:{cols:[4,8],display:"fill"},mobile:{cols:[12]}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"},isSyncProduct:!0},styles:{verticalGutter:{desktop:"8px"},verticalGutterMobile:{desktop:"0px"},fullWidth:{desktop:!1}},advanced:{"spacing-setting":{desktop:{margin:{},padding:{left:"4px",right:"4px",top:"4px",bottom:"4px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,6],display:"fit"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px",tablet:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1},border:{desktop:{normal:{borderType:"none",border:"solid",borderWidth:"0px",width:"0px",color:"#121212",isCustom:!0}}},rounded:{desktop:{normal:{btrr:"0px",bblr:"0px",bbrr:"0px",btlr:"0px",radiusType:"none"}}},hasBoxShadow:{desktop:{normal:!1}},boxShadow:{desktop:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}}},op:{desktop:"100%"}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductImagesV2",label:"Product Images",settings:{hoverEffect:"none"},styles:{position:{desktop:"only-feature",mobile:"only-feature"},ftShape:{desktop:{shape:"square",shapeValue:"1/1",width:"32px",height:void 0}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductTitle",label:"Product Title",settings:{htmlTag:"h1",linkProduct:!1},styles:{typo:{type:"subheading-3",custom:{fontSize:{desktop:"16px"},fontWeight:"400",lineHeight:"24px",letterSpacing:"0.6px",fontStyle:"normal"}},textAlign:{desktop:"left"},hasLineClamp:{desktop:!0},lineClamp:{desktop:1},color:{normal:"text-2"},hasTextShadow:{normal:!1,hover:!1},textShadow:{normal:{type:"shadow-1"}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}},{tag:"ProductPrice",label:"Product Price",settings:{priceType:"regular"},styles:{typo:{type:"subheading-2",default:{type:"subheading-2"},custom:{fontSize:{desktop:"14px"},fontWeight:"400",lineHeight:"20px",letterSpacing:"0.6px",fontStyle:"normal"}},lineThrough:!0,thickness:1,lineColor:"text-1",color:{normal:"text-2"},hasTextShadow:{normal:!1},textShadow:{normal:{type:"shadow-1"}},textAlign:{desktop:"left"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]}]}]},{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,3,3],display:"fill"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px",tablet:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductVariants",label:"Product Variants & Swatches",settings:{optionType:"groupOption",label:!0,optionAlign:{desktop:"left"},price:!0,showAsSwatches:!0,combineFullWidth:{desktop:!0},combineWidth:{desktop:"400px"},combineHeight:"40px",variantPresets:[{optionName:"base",optionType:"rectangle_list",presets:{color:{width:{desktop:"45px",tablet:"45px",mobile:"45px"},height:"45px",spacing:"16px"},rectangle_list:{width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px",spacing:"16px"},image:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},image_shopify:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},dropdown:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px"}}}],soldOutMark:!0,layout:{desktop:"vertical"},column:{desktop:1},hasPreSelected:!0,blankText:"Please select an option"},styles:{fullWidth:{desktop:!0},width:{desktop:"400px"},optionSpacing:"30px",labelGap:"8px",swatchAutoWidth:{desktop:!0},swatchWidth:{desktop:"80px"},swatchHeight:{desktop:"40px"},swatchSpacing:"var(--g-s-m)",marginBottom:{desktop:"var(--g-s-xl)",mobile:"var(--g-s-xl)"},align:{desktop:"left"},labelTypo:{type:"paragraph-2",attrs:{color:"text-1",bold:!0}},labelColor:"text-2",optionTypo:{type:"paragraph-2"},optionBgColor:{normal:"bg-3",hover:"bg-3",active:"bg-3"},optionTextColor:{normal:"text-2",hover:"text-2",active:"text-2"},optionBorder:{normal:{borderType:"style-2",border:"solid",color:"line-2",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"},active:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"2px 2px 2px 2px",borderWidth:"2px"},hover:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"}},optionRounded:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"custom"},hover:{radiusType:"none"},active:{radiusType:"none"}},optionHasShadow:{normal:!1},optionShadow:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},dropdownItemWidth:{desktop:"fill",mobile:"fill",tablet:"fill"},fixedDropdownWidth:{desktop:"240px"},swatchItemWidth:{desktop:"auto"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductQuantity",label:"Product Quantity",settings:{hasButton:!0,enableHoverButton:!0},styles:{inputHeight:{desktop:"40px"},buttonWidth:{desktop:"40px"},iconSizeCustom:{desktop:"20px"},typo:{type:"paragraph-2",attrs:{color:"text-1"}},align:{desktop:"left"},inputBackgroundColor:"bg-3",textColor:"text-2",buttonBackgroundColor:{normal:"bg-3"},iconColor:{normal:"text-2"},borderBtn:{normal:{},hover:{borderType:"style-3",border:"solid",width:"1px 1px 1px 1px",color:"line-3",isCustom:!1}},corner:{desktop:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"rounded"}}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductButton",label:"Product Cart Button",settings:{label:"Add to cart",outOfStockLabel:"Out of stock",actionEffect:"open-cart-drawer",customURL:{link:"/cart",target:"_self"},successMessage:"Add product to cart successfully",errorMessage:"Cannot add product to cart",buttonLayout:"cart-only",iconAlign:"left",errorType:"built-in"},styles:{backgroundColor:{normal:"brand",hover:"highlight"},textColor:{normal:"text-3"},borderBtn:{normal:{border:"solid",color:"#121212",isCustom:!0,position:"all",borderWidth:"0px",width:"0px 0px 0px 0px"},hover:{border:"solid",color:"#4D4D4D",isCustom:!0,position:"all",borderWidth:"0px",width:"0px 0px 0px 0px"}},hasBoxShadowBtn:{normal:!1,hover:!1},boxShadowBtn:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},roundedBtnV2:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"rounded"}},align:{desktop:"left"},typo:{type:"paragraph-1"},transform:"default",btnSpacing:{type:"medium"},fullWidth:{desktop:!0},iconSizeAuto:!0,size:{desktop:"1em"},iconDimension:{desktop:"24px"},spacing:"8px",successTypo:{type:"paragraph-2"},successColor:"success",errorTypo:{type:"paragraph-2"},errorColor:"error",isCustomOutOfStock:!1,oosBackground:"brand",oosTextColor:"text-3",oosBorder:{normal:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,borderWidth:"0px",width:"0px 0px 0px 0px"}},oosEnableShadow:!1,oosShadow:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90},oosRounded:{radiusType:"none"},globalSize:{desktop:{width:"100%"}},enableIcon:!1,enablePrice:!1,enableSeparator:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]}]}]}]}]}]}]},StickyPresetScrollToTop={id:"sticky-scroll-to-top",name:{en:"Sticky Back to top"},icon:{desktop:`
|
|
13
13
|
<svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
14
14
|
<rect width="40" height="40" rx="20" fill="#424242"/>
|
|
15
15
|
<path d="M13.6001 14C13.6001 13.5581 13.9583 13.2 14.4001 13.2H25.6001C26.0419 13.2 26.4001 13.5581 26.4001 14C26.4001 14.4418 26.0419 14.8 25.6001 14.8H14.4001C13.9583 14.8 13.6001 14.4418 13.6001 14Z" fill="#F9F9F9"/>
|
|
@@ -28,4 +28,4 @@ let StickyPreset={id:"sticky",name:{en:"Sticky Add to Cart"},icon:{desktop:`
|
|
|
28
28
|
<circle cx="64.2674" cy="46.5138" r="1.15512" fill="white"/>
|
|
29
29
|
<circle cx="69.5565" cy="46.5138" r="1.15512" fill="white"/>
|
|
30
30
|
</svg>
|
|
31
|
-
`},components:[{tag:"Sticky",label:"Sticky",advanced:{hasBoxShadow:{desktop:{normal:!0}},boxShadow:{desktop:{normal:{type:"shadow-1",distance:"0px",blur:"10px",spread:"0px",color:"rgba(0, 0, 0, 0.1)",angle:90}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Product",label:"Product",settings:{productSetting:{productStatus:"dynamic"},layout:{desktop:{cols:[4,8],display:"fill"},mobile:{cols:[12]}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"},isSyncProduct:!0},styles:{verticalGutter:{desktop:"8px",tablet:"8px"},verticalGutterMobile:{desktop:"0px"},fullWidth:{desktop:!1}},advanced:{"spacing-setting":{desktop:{margin:{},padding:{left:"4px",right:"4px",top:"4px",bottom:"4px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,6],display:"fit"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px",tablet:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1},border:{desktop:{normal:{borderType:"none",border:"solid",borderWidth:"0px",width:"0px",color:"#121212",isCustom:!0}}},rounded:{desktop:{normal:{btrr:"0px",bblr:"0px",bbrr:"0px",btlr:"0px",radiusType:"none"}}},hasBoxShadow:{desktop:{normal:!1}},boxShadow:{desktop:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}}},op:{desktop:"100%"}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductImagesV2",label:"Product Images",settings:{hoverEffect:"none"},styles:{position:{desktop:"only-feature",mobile:"only-feature"},ftShape:{desktop:{shape:"square",shapeValue:"1/1",width:"32px",height:void 0}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductTitle",label:"Product Title",settings:{htmlTag:"h1",linkProduct:!1},styles:{typo:{type:"subheading-3",custom:{fontSize:{desktop:"18px",tablet:"18px",mobile:"18px"},fontWeight:"400",lineHeight:"24px",letterSpacing:"0.6px",fontStyle:"normal"}},textAlign:{desktop:"left"},hasLineClamp:{desktop:!0},lineClamp:{desktop:1},color:{normal:"text-2"},hasTextShadow:{normal:!1,hover:!1},textShadow:{normal:{type:"shadow-1"}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}},{tag:"ProductPrice",label:"Product Price",settings:{priceType:"regular"},styles:{typo:{type:"subheading-2",default:{type:"subheading-2"},custom:{fontSize:{desktop:"14px"},fontWeight:"400",lineHeight:"20px",letterSpacing:"0.6px",fontStyle:"normal"}},lineThrough:!0,thickness:1,lineColor:"text-1",color:{normal:"text-2"},hasTextShadow:{normal:!1},textShadow:{normal:{type:"shadow-1"}},textAlign:{desktop:"left"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]}]}]},{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,3,3],display:"fill"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductVariants",label:"Product Variants & Swatches",settings:{optionType:"groupOption",label:!0,optionAlign:{desktop:"left"},price:!0,showAsSwatches:!0,combineFullWidth:{desktop:!0},combineWidth:{desktop:"400px"},combineHeight:"40px",variantPresets:[{optionName:"base",optionType:"rectangle_list",presets:{color:{width:{desktop:"45px",tablet:"45px",mobile:"45px"},height:"45px",spacing:"16px"},rectangle_list:{width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px",spacing:"16px"},image:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},image_shopify:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},dropdown:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px"}}}],soldOutMark:!0,layout:{desktop:"vertical"},column:{desktop:1},hasPreSelected:!0,blankText:"Please select an option"},styles:{fullWidth:{desktop:!0},width:{desktop:"400px"},optionSpacing:"30px",labelGap:"8px",swatchAutoWidth:{desktop:!0},swatchWidth:{desktop:"80px"},swatchHeight:{desktop:"40px"},swatchSpacing:"var(--g-s-m)",marginBottom:{desktop:"var(--g-s-xl)",mobile:"var(--g-s-xl)"},align:{desktop:"left"},labelTypo:{type:"paragraph-2",attrs:{color:"text-1",bold:!0}},labelColor:"text-2",optionTypo:{type:"paragraph-2"},optionBgColor:{normal:"bg-3",hover:"bg-3",active:"bg-3"},optionTextColor:{normal:"text-2",hover:"text-2",active:"text-2"},optionBorder:{normal:{borderType:"style-2",border:"solid",color:"line-2",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"},active:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"2px 2px 2px 2px",borderWidth:"2px"},hover:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"}},optionRounded:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"custom"},hover:{radiusType:"none"},active:{radiusType:"none"}},optionHasShadow:{normal:!1},optionShadow:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},dropdownItemWidth:{desktop:"fill",mobile:"fill",tablet:"fill"},fixedDropdownWidth:{desktop:"240px"},swatchItemWidth:{desktop:"auto"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductQuantity",label:"Product Quantity",settings:{
|
|
31
|
+
`},components:[{tag:"Sticky",label:"Sticky",advanced:{hasBoxShadow:{desktop:{normal:!0}},boxShadow:{desktop:{normal:{type:"shadow-1",distance:"0px",blur:"10px",spread:"0px",color:"rgba(0, 0, 0, 0.1)",angle:90}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Product",label:"Product",settings:{productSetting:{productStatus:"dynamic"},layout:{desktop:{cols:[4,8],display:"fill"},mobile:{cols:[12]}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"},isSyncProduct:!0},styles:{verticalGutter:{desktop:"8px",tablet:"8px"},verticalGutterMobile:{desktop:"0px"},fullWidth:{desktop:!1}},advanced:{"spacing-setting":{desktop:{margin:{},padding:{left:"4px",right:"4px",top:"4px",bottom:"4px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,6],display:"fit"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px",tablet:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1},border:{desktop:{normal:{borderType:"none",border:"solid",borderWidth:"0px",width:"0px",color:"#121212",isCustom:!0}}},rounded:{desktop:{normal:{btrr:"0px",bblr:"0px",bbrr:"0px",btlr:"0px",radiusType:"none"}}},hasBoxShadow:{desktop:{normal:!1}},boxShadow:{desktop:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}}},op:{desktop:"100%"}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductImagesV2",label:"Product Images",settings:{hoverEffect:"none"},styles:{position:{desktop:"only-feature",mobile:"only-feature"},ftShape:{desktop:{shape:"square",shapeValue:"1/1",width:"32px",height:void 0}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductTitle",label:"Product Title",settings:{htmlTag:"h1",linkProduct:!1},styles:{typo:{type:"subheading-3",custom:{fontSize:{desktop:"18px",tablet:"18px",mobile:"18px"},fontWeight:"400",lineHeight:"24px",letterSpacing:"0.6px",fontStyle:"normal"}},textAlign:{desktop:"left"},hasLineClamp:{desktop:!0},lineClamp:{desktop:1},color:{normal:"text-2"},hasTextShadow:{normal:!1,hover:!1},textShadow:{normal:{type:"shadow-1"}}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}},{tag:"ProductPrice",label:"Product Price",settings:{priceType:"regular"},styles:{typo:{type:"subheading-2",default:{type:"subheading-2"},custom:{fontSize:{desktop:"14px"},fontWeight:"400",lineHeight:"20px",letterSpacing:"0.6px",fontStyle:"normal"}},lineThrough:!0,thickness:1,lineColor:"text-1",color:{normal:"text-2"},hasTextShadow:{normal:!1},textShadow:{normal:{type:"shadow-1"}},textAlign:{desktop:"left"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]}]}]},{tag:"Col",label:"Block",childrens:[{tag:"Row",label:"Row",settings:{layout:{desktop:{cols:[6,3,3],display:"fill"},mobile:{cols:[12],display:"fill"}},horizontalAlign:{desktop:"start"},verticalAlign:{desktop:"center"}},styles:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},verticalGutter:{desktop:"8px"},background:{desktop:{type:"color",color:"transparent",image:{src:"",width:0,height:0},size:"cover",position:{x:50,y:50},repeat:"no-repeat",attachment:"scroll"}},preloadBgImage:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}},childrens:[{tag:"Col",label:"Block",childrens:[{tag:"ProductVariants",label:"Product Variants & Swatches",settings:{optionType:"groupOption",label:!0,optionAlign:{desktop:"left"},price:!0,showAsSwatches:!0,combineFullWidth:{desktop:!0},combineWidth:{desktop:"400px"},combineHeight:"40px",variantPresets:[{optionName:"base",optionType:"rectangle_list",presets:{color:{width:{desktop:"45px",tablet:"45px",mobile:"45px"},height:"45px",spacing:"16px"},rectangle_list:{width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px",spacing:"16px"},image:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},image_shopify:{width:{desktop:"64px",tablet:"64px",mobile:"64px"},height:"64px",spacing:"16px"},dropdown:{fullWidth:{desktop:!0,tablet:!0,mobile:!0},width:{desktop:"auto",tablet:"auto",mobile:"auto"},height:"45px"}}}],soldOutMark:!0,layout:{desktop:"vertical"},column:{desktop:1},hasPreSelected:!0,blankText:"Please select an option"},styles:{fullWidth:{desktop:!0},width:{desktop:"400px"},optionSpacing:"30px",labelGap:"8px",swatchAutoWidth:{desktop:!0},swatchWidth:{desktop:"80px"},swatchHeight:{desktop:"40px"},swatchSpacing:"var(--g-s-m)",marginBottom:{desktop:"var(--g-s-xl)",mobile:"var(--g-s-xl)"},align:{desktop:"left"},labelTypo:{type:"paragraph-2",attrs:{color:"text-1",bold:!0}},labelColor:"text-2",optionTypo:{type:"paragraph-2"},optionBgColor:{normal:"bg-3",hover:"bg-3",active:"bg-3"},optionTextColor:{normal:"text-2",hover:"text-2",active:"text-2"},optionBorder:{normal:{borderType:"style-2",border:"solid",color:"line-2",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"},active:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"2px 2px 2px 2px",borderWidth:"2px"},hover:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,width:"1px 1px 1px 1px",borderWidth:"1px"}},optionRounded:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"custom"},hover:{radiusType:"none"},active:{radiusType:"none"}},optionHasShadow:{normal:!1},optionShadow:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},dropdownItemWidth:{desktop:"fill",mobile:"fill",tablet:"fill"},fixedDropdownWidth:{desktop:"240px"},swatchItemWidth:{desktop:"auto"}},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductQuantity",label:"Product Quantity",settings:{hasButton:!0,enableHoverButton:!0},styles:{inputHeight:{desktop:"40px"},buttonWidth:{desktop:"40px"},iconSizeCustom:{desktop:"20px"},typo:{type:"paragraph-2",attrs:{color:"text-1"}},align:{desktop:"left"},inputBackgroundColor:"bg-3",textColor:"text-2",buttonBackgroundColor:{normal:"bg-3"},iconColor:{normal:"text-2"},borderBtn:{normal:{},hover:{borderType:"style-3",border:"solid",width:"1px 1px 1px 1px",color:"line-3",isCustom:!1}},corner:{desktop:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"rounded"}}}},advanced:{rounded:{desktop:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"none"}}},"spacing-setting":{desktop:{margin:{bottom:"0px"}}},d:{desktop:!0,tablet:!0,mobile:!1}}}]},{tag:"Col",label:"Block",childrens:[{tag:"ProductButton",label:"Product Cart Button",settings:{label:"Add to cart",outOfStockLabel:"Out of stock",actionEffect:"open-cart-drawer",customURL:{link:"/cart",target:"_self"},successMessage:"Add product to cart successfully",errorMessage:"Cannot add product to cart",buttonLayout:"cart-only",iconAlign:"left",errorType:"built-in"},styles:{backgroundColor:{normal:"brand",hover:"highlight"},backgroundColorV2:{normal:"brand",hover:"highlight"},textColor:{normal:"text-3"},borderBtn:{normal:{border:"solid",color:"#121212",isCustom:!0,position:"all",borderWidth:"0px",width:"0px 0px 0px 0px"},hover:{border:"solid",color:"#4D4D4D",isCustom:!0,position:"all",borderWidth:"0px",width:"0px 0px 0px 0px"}},hasBoxShadowBtn:{normal:!1,hover:!1},boxShadowBtn:{normal:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90}},roundedBtnV2:{normal:{btrr:"4px",bblr:"4px",bbrr:"4px",btlr:"4px",radiusType:"rounded"}},align:{desktop:"left"},typo:{type:"paragraph-1"},transform:"default",btnSpacing:{type:"medium"},fullWidth:{desktop:!0},iconSizeAuto:!0,size:{desktop:"1em"},iconDimension:{desktop:"24px"},spacing:"8px",successTypo:{type:"paragraph-2"},successColor:"success",errorTypo:{type:"paragraph-2"},errorColor:"error",isCustomOutOfStock:!1,oosBackground:"brand",oosTextColor:"text-3",oosBorder:{normal:{borderType:"style-3",border:"solid",color:"line-3",isCustom:!1,borderWidth:"0px",width:"0px 0px 0px 0px"}},oosEnableShadow:!1,oosShadow:{type:"shadow-1",distance:"4px",blur:"12px",spread:"0px",color:"rgba(0, 0, 0, 0.20)",angle:90},oosRounded:{radiusType:"none"},globalSize:{desktop:{width:"100%"}},enableIcon:!1,enablePrice:!1,enableSeparator:!1},advanced:{"spacing-setting":{desktop:{margin:{bottom:"0px"}}}}}]}]}]}]}]}]}]};export{StickyPreset,StickyPresetProduct,StickyPresetScrollToTop};
|
package/dist/types/index.d.ts
CHANGED
|
@@ -3973,7 +3973,6 @@ type ProductBundleItemDiscountProps = {
|
|
|
3973
3973
|
|
|
3974
3974
|
type ProductQuantityLayout = 'product-quantity-square' | 'product-quantity-square-divider' | 'product-quantity-rounded' | 'product-quantity-rounded-divider' | 'product-quantity-square-input-only' | 'product-quantity-rounded-input-only';
|
|
3975
3975
|
type ProductQuantitySettingProps = {
|
|
3976
|
-
qtyStyle?: string;
|
|
3977
3976
|
defaultQtyValue?: number;
|
|
3978
3977
|
updatePrice?: boolean;
|
|
3979
3978
|
plusIcon?: string;
|
|
@@ -3995,15 +3994,17 @@ type ProductQuantityStyleProps = {
|
|
|
3995
3994
|
textColor?: StateProp<ColorValueType>;
|
|
3996
3995
|
buttonBackgroundColor?: StateProp<ColorValueType>;
|
|
3997
3996
|
iconColor?: StateProp<ColorValueType>;
|
|
3998
|
-
borderBtn?:
|
|
3997
|
+
borderBtn?: StateProp<Border>;
|
|
3999
3998
|
iconSizeCustom?: ObjectDevices<string>;
|
|
4000
|
-
corner?:
|
|
4001
|
-
shapeShadow?: ObjectDevices<StateProp<ShadowProps>>;
|
|
4002
|
-
buttonBoxShadow?: StateProp<ShadowProps>;
|
|
3999
|
+
corner?: StateProp<CornerRadius>;
|
|
4003
4000
|
inputBoxShadow?: StateProp<ShadowProps>;
|
|
4004
4001
|
backgroundColor?: StateProp<ColorValueType>;
|
|
4005
4002
|
dividerColor?: StateProp<ColorValueType>;
|
|
4006
4003
|
dividerStroke?: StateProp<number>;
|
|
4004
|
+
inputBorder?: StateProp<Border>;
|
|
4005
|
+
shapeBorder?: ObjectDevices<Border>;
|
|
4006
|
+
shapeRounded?: ObjectDevices<CornerRadius>;
|
|
4007
|
+
shapeShadow?: ObjectDevices<ShadowProps>;
|
|
4007
4008
|
};
|
|
4008
4009
|
type ProductQuantityProps = BaseProps<ProductQuantitySettingProps, ProductQuantityStyleProps>;
|
|
4009
4010
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gem-sdk/components",
|
|
3
|
-
"version": "2.0.0-staging.
|
|
3
|
+
"version": "2.0.0-staging.1011",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"main": "dist/cjs/index.js",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"scan-all-text": "rollup -c ./scripts/rollup.config.settings.mjs && node ./scripts/scan-all-text && node ./scripts/scan-all-text"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
|
-
"@gem-sdk/core": "2.0.0-staging.
|
|
28
|
+
"@gem-sdk/core": "2.0.0-staging.1010",
|
|
29
29
|
"@gem-sdk/styles": "2.0.0-staging.987",
|
|
30
30
|
"@gem-sdk/system": "2.0.0-staging.711",
|
|
31
31
|
"tsup": "^8.5.0",
|