@gem-sdk/components 12.0.0-dev.79 → 12.0.0-dev.81

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var jsxRuntime=require("react/jsx-runtime"),React=require("react"),system=require("@gem-sdk/system"),styles=require("../common/styles.js"),classes=require("../common/classes.js"),helpers$1=require("../common/helpers.js"),core=require("@gem-sdk/core"),helpers=require("../../../helpers.js"),PostPurchaseCheckbox=require("./PostPurchaseCheckbox.js");const DEFAULT_PRE_CHECK_VALUE=!0,COMPONENT_ID_PREFIX="buyer-consent-product",BuyerConsent=({styles:e,builderProps:s,setting:t})=>{let r=core.useProduct(),c=core.usePageStore(e=>e.buyerConsentChecked),l=core.usePageStore(e=>e.setBuyerConsentChecked),{description:a,policyLabel:o,policyLink:n,align:u}=t??{},i=r?.id?`buyer-consent-product-${s?.uid}-${r.id}`:void 0,y=helpers$1.getComponentTag(n),m=system.createStyle(styles.getWrapperStyles({styles:e})),d=system.createClass(classes.getWrapperClassName({align:u,uid:s?.uid})),h=system.createStyle(styles.getContainerStyles({styles:e})),C=system.createClass(classes.getCheckboxContainerClassName()),x=system.createStyle(styles.getTextStyle({styles:e})),p=system.createClass(classes.getLinkComponentClassName()),j=system.createStyle(classes.getLinkComponentStyles()),g=React.useMemo(()=>helpers.extractProductID(r?.baseID??""),[r?.baseID]),b=React.useMemo(()=>{let e=`${g}`;return c?.[e]??!0},[c,g]),k=e=>{let s=`${g}`,t={...c,[s]:e.target.checked};l(t)};return jsxRuntime.jsx("div",{"data-id":s?.uid,style:m,className:d,children:jsxRuntime.jsxs("label",{htmlFor:i,dir:e?.direction??"ltr",style:h,className:C,children:[jsxRuntime.jsx(PostPurchaseCheckbox.default,{id:i,name:i,type:"checkbox",checked:b,onChange:k}),jsxRuntime.jsxs("bdo",{dir:e?.direction??"ltr",style:x,children:[a," ",jsxRuntime.jsx(y,{target:"_blank",rel:"noreferrer",href:n,className:p,style:j,children:o})]})]})})};exports.default=BuyerConsent;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var jsxRuntime=require("react/jsx-runtime"),React=require("react"),system=require("@gem-sdk/system"),styles=require("../common/styles.js"),classes=require("../common/classes.js"),helpers$1=require("../common/helpers.js"),core=require("@gem-sdk/core"),helpers=require("../../../helpers.js"),PostPurchaseCheckbox=require("./PostPurchaseCheckbox.js");const DEFAULT_PRE_CHECK_VALUE=!0,COMPONENT_ID_PREFIX="buyer-consent-product",BuyerConsent=({styles:e,builderProps:s,setting:t,builderAttrs:r,style:l})=>{let c=core.useProduct(),a=core.usePageStore(e=>e.buyerConsentChecked),o=core.usePageStore(e=>e.setBuyerConsentChecked),{description:n,policyLabel:u,policyLink:i,align:y}=t??{},m=c?.id?`buyer-consent-product-${s?.uid}-${c.id}`:void 0,d=helpers$1.getComponentTag(i),h=system.createStyle(styles.getWrapperStyles({styles:e})),C=system.createClass(classes.getWrapperClassName({align:y,uid:s?.uid})),x=system.createStyle(styles.getContainerStyles({styles:e})),j=system.createClass(classes.getCheckboxContainerClassName()),p=system.createStyle(styles.getTextStyle({styles:e})),g=system.createClass(classes.getLinkComponentClassName()),b=system.createStyle(classes.getLinkComponentStyles()),k=React.useMemo(()=>helpers.extractProductID(c?.baseID??""),[c?.baseID]),P=React.useMemo(()=>{let e=`${k}`;return a?.[e]??!0},[a,k]),R=e=>{let s=`${k}`,t={...a,[s]:e.target.checked};o(t)};return jsxRuntime.jsx("div",{...r,style:{...l},children:jsxRuntime.jsx("div",{"data-id":s?.uid,style:h,className:C,children:jsxRuntime.jsxs("label",{htmlFor:m,dir:e?.direction??"ltr",style:x,className:j,children:[jsxRuntime.jsx(PostPurchaseCheckbox.default,{id:m,name:m,type:"checkbox",checked:P,onChange:R}),jsxRuntime.jsxs("bdo",{dir:e?.direction??"ltr",style:p,children:[n," ",jsxRuntime.jsx(d,{target:"_blank",rel:"noreferrer",href:i,className:g,style:b,children:u})]})]})})})};exports.default=BuyerConsent;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var jsxRuntime=require("react/jsx-runtime"),core=require("@gem-sdk/core"),system=require("@gem-sdk/system"),React=require("react"),index=require("../../constants/index.js"),classes=require("./common/classes.js"),styles=require("./common/styles.js"),useSellingPlanChange=require("./hooks/useSellingPlanChange.js"),useSellingSubscription=require("./hooks/useSellingSubscription.js"),useSellingPlanOptions=require("./hooks/useSellingPlanOptions.js"),useSubscriptionVisibility=require("./hooks/useSubscriptionVisibility.js"),OneTimePurchaseTooltip=require("./components/OneTimePurchaseTooltip.js"),SellingPlanDropdown=require("./components/SellingPlanDropdown.js"),SellingPlanLabel=require("./components/SellingPlanLabel.js"),SellingPlanRadio=require("./components/SellingPlanRadio.js"),SubscriptionDetail=require("./components/SubscriptionDetail.js"),SubscriptionRadio=require("./components/SubscriptionRadio.js");const ProductSubscription=({styles:e,setting:s,builderProps:i,builderAttrs:n,style:l,children:t})=>{let r=core.useProduct(),{defaultValue:u,selectedSellingPlan:a,setSelectedSellingPlan:o}=useSellingSubscription.useSellingSubscription(s),c=useSellingPlanOptions.useSellingPlanOptions(s),{selectedValue:p,handleSellingPlanChange:S}=useSellingPlanChange.useSellingPlanChange({defaultValue:u,selectedSellingPlan:a,setSelectedSellingPlan:o,sellingPlanOptions:c}),d=React.useRef(null),m=React.useId(),{selectedType:g,shouldShowRadio:j,isOneTimeHidden:x,hasNoSellingPlanOptions:b,setSubscriptionSellingType:R}=useSubscriptionVisibility.useSubscriptionVisibility({setting:s}),P=system.createStyle(styles.getSubscriptionStyles(e)),y=system.createStyle(styles.getSubscriptionWrapperStyles(e?.align)),h=system.createClass(classes.getWrapperClasses()),T=system.createClass(classes.getContainerClasses()),O=system.createStyle({...l}),{isEditMode:C}=core.useRenderMode(),I=`product-subscription-${r?.baseID}`,q=r?.baseID,E=`subscription-type-selection-${m}`,N=s?.sellingType===index.SubscriptionEnum.ONE_TIME,v=s?.sellingType===index.SubscriptionEnum.SUBSCRIPTION;if(x||b)return C?jsxRuntime.jsxs("div",{...n,style:O,children:[jsxRuntime.jsx(OneTimePurchaseTooltip.OneTimePurchaseTooltip,{ref:d,setting:s}),core.filterToolbarPreview(t,!0)]}):null;let D=e=>jsxRuntime.jsxs("div",{...n,style:O,children:[jsxRuntime.jsx("div",{ref:d,"data-selling-type":s?.sellingType,id:I,className:h,style:y,children:e}),core.filterToolbarPreview(t,!0)]}),k=()=>jsxRuntime.jsx(jsxRuntime.Fragment,{children:s?.sellingStyle==="radio"?jsxRuntime.jsx(SellingPlanRadio.SellingPlanRadio,{setting:s,styles:e,builderProps:i,productId:q??"",sellingPlanOptions:c,selectedValue:p,onChange:S}):jsxRuntime.jsx(SellingPlanDropdown.SellingPlanDropdown,{setting:s,sellingPlanOptions:c,selectedValue:p,onChange:S})});return D(N&&j?jsxRuntime.jsx("div",{className:T,style:P,children:jsxRuntime.jsx(SubscriptionRadio.SubscriptionRadio,{id:`${q}-one-time-radio`,name:E,value:index.SubscriptionEnum.ONE_TIME,checked:g===index.SubscriptionEnum.ONE_TIME,className:"!gp-items-start",onChange:e=>{e.target.checked&&R(index.SubscriptionEnum.ONE_TIME)},children:jsxRuntime.jsx(SellingPlanLabel.SellingPlanLabel,{setting:s,styles:e})})}):v&&j?jsxRuntime.jsxs("div",{className:T,style:P,children:[jsxRuntime.jsx(SubscriptionRadio.SubscriptionRadio,{id:`${q}-subscription-radio`,name:E,value:index.SubscriptionEnum.SUBSCRIPTION,checked:g===index.SubscriptionEnum.SUBSCRIPTION,className:"!gp-items-start",onChange:e=>{e.target.checked&&R(index.SubscriptionEnum.SUBSCRIPTION)},children:jsxRuntime.jsx(SellingPlanLabel.SellingPlanLabel,{setting:s,styles:e})}),g===index.SubscriptionEnum.SUBSCRIPTION&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{className:"gp-pl-7",children:k()}),jsxRuntime.jsx("div",{className:"gp-pl-7",children:jsxRuntime.jsx(SubscriptionDetail.SubscriptionDetail,{setting:s,styles:e})})]})]}):jsxRuntime.jsxs("div",{className:T,style:P,children:[jsxRuntime.jsx(SellingPlanLabel.SellingPlanLabel,{setting:s,styles:e}),k(),jsxRuntime.jsx(SubscriptionDetail.SubscriptionDetail,{setting:s,styles:e})]}))};exports.default=ProductSubscription;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var jsxRuntime=require("react/jsx-runtime"),core=require("@gem-sdk/core"),system=require("@gem-sdk/system"),React=require("react"),index=require("../../constants/index.js"),classes=require("./common/classes.js"),styles=require("./common/styles.js"),useSellingPlanChange=require("./hooks/useSellingPlanChange.js"),useSellingSubscription=require("./hooks/useSellingSubscription.js"),useSellingPlanOptions=require("./hooks/useSellingPlanOptions.js"),useSubscriptionVisibility=require("./hooks/useSubscriptionVisibility.js"),OneTimePurchaseTooltip=require("./components/OneTimePurchaseTooltip.js"),SellingPlanDropdown=require("./components/SellingPlanDropdown.js"),SellingPlanLabel=require("./components/SellingPlanLabel.js"),SellingPlanRadio=require("./components/SellingPlanRadio.js"),SubscriptionDetail=require("./components/SubscriptionDetail.js"),SubscriptionRadio=require("./components/SubscriptionRadio.js"),useDynamicProduct=require("../../hooks/useDynamicProduct.js");const ProductSubscription=({styles:e,setting:s,builderProps:i,builderAttrs:n,style:l,children:t})=>{let r=core.useProduct(),{defaultValue:u,selectedSellingPlan:o,setSelectedSellingPlan:a}=useSellingSubscription.useSellingSubscription(s),c=useSellingPlanOptions.useSellingPlanOptions(s),{selectedValue:d,handleSellingPlanChange:p}=useSellingPlanChange.useSellingPlanChange({defaultValue:u,selectedSellingPlan:o,setSelectedSellingPlan:a,sellingPlanOptions:c}),S=React.useRef(null),m=React.useId(),{selectedType:g,shouldShowRadio:j,isOneTimeHidden:x,hasNoSellingPlanOptions:b,setSubscriptionSellingType:P}=useSubscriptionVisibility.useSubscriptionVisibility({setting:s}),y=system.createStyle(styles.getSubscriptionStyles(e)),R=system.createStyle(styles.getSubscriptionWrapperStyles(e?.align)),h=system.createClass(classes.getWrapperClasses()),T=system.createClass(classes.getContainerClasses()),O=system.createStyle({...l}),{isEditMode:q}=core.useRenderMode(),C=`product-subscription-${r?.baseID}`,I=r?.baseID,E=`subscription-type-selection-${m}`,N=s?.sellingType===index.SubscriptionEnum.ONE_TIME,D=s?.sellingType===index.SubscriptionEnum.SUBSCRIPTION,{isDynamicProduct:v}=useDynamicProduct.useDynamicProduct();if(x||b||v)return q?jsxRuntime.jsxs("div",{...n,style:O,children:[jsxRuntime.jsx(OneTimePurchaseTooltip.OneTimePurchaseTooltip,{ref:S,setting:s}),core.filterToolbarPreview(t,!0)]}):null;let k=e=>jsxRuntime.jsxs("div",{...n,style:O,children:[jsxRuntime.jsx("div",{ref:S,"data-selling-type":s?.sellingType,id:C,className:h,style:R,children:e}),core.filterToolbarPreview(t,!0)]}),f=()=>jsxRuntime.jsx(jsxRuntime.Fragment,{children:s?.sellingStyle==="radio"?jsxRuntime.jsx(SellingPlanRadio.SellingPlanRadio,{setting:s,styles:e,builderProps:i,productId:I??"",sellingPlanOptions:c,selectedValue:d,onChange:p}):jsxRuntime.jsx(SellingPlanDropdown.SellingPlanDropdown,{setting:s,sellingPlanOptions:c,selectedValue:d,onChange:p})});return k(N&&j?jsxRuntime.jsx("div",{className:T,style:y,children:jsxRuntime.jsx(SubscriptionRadio.SubscriptionRadio,{id:`${I}-one-time-radio`,name:E,value:index.SubscriptionEnum.ONE_TIME,checked:g===index.SubscriptionEnum.ONE_TIME,className:"!gp-items-start",onChange:e=>{e.target.checked&&P(index.SubscriptionEnum.ONE_TIME)},children:jsxRuntime.jsx(SellingPlanLabel.SellingPlanLabel,{setting:s,styles:e})})}):D&&j?jsxRuntime.jsxs("div",{className:T,style:y,children:[jsxRuntime.jsx(SubscriptionRadio.SubscriptionRadio,{id:`${I}-subscription-radio`,name:E,value:index.SubscriptionEnum.SUBSCRIPTION,checked:g===index.SubscriptionEnum.SUBSCRIPTION,className:"!gp-items-start",onChange:e=>{e.target.checked&&P(index.SubscriptionEnum.SUBSCRIPTION)},children:jsxRuntime.jsx(SellingPlanLabel.SellingPlanLabel,{setting:s,styles:e})}),g===index.SubscriptionEnum.SUBSCRIPTION&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{className:"gp-pl-7",children:f()}),jsxRuntime.jsx("div",{className:"gp-pl-7",children:jsxRuntime.jsx(SubscriptionDetail.SubscriptionDetail,{setting:s,styles:e})})]})]}):jsxRuntime.jsxs("div",{className:T,style:y,children:[jsxRuntime.jsx(SellingPlanLabel.SellingPlanLabel,{setting:s,styles:e}),f(),jsxRuntime.jsx(SubscriptionDetail.SubscriptionDetail,{setting:s,styles:e})]}))};exports.default=ProductSubscription;
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var styles=require("./common/styles.js"),helpers$1=require("./common/helpers.js"),core=require("@gem-sdk/core"),system=require("@gem-sdk/system"),helpers=require("../../../helpers.js"),getButtonDynamicSourceLocales=require("./helpers/getButtonDynamicSourceLocales.js"),SoldOutButton_liquid=require("./SoldOutButton.liquid.js"),AddToCartButton_liquid=require("./AddToCartButton.liquid.js");const ProductButton=t=>{let{setting:e,builderProps:s,style:r,styles:o,pageContext:a}=t,{wrapStyle:i,restStyle:l}=styles.getSplitStyle(r),{outOfStockButtonLabel:n,unavailableButtonLabel:u,variantSelectionRequiredMessage:c}=getButtonDynamicSourceLocales.getButtonDynamicSourceLocales({setting:e,pageContext:a,builderProps:s}),{urlData:d}=helpers.getInsertLinkData("",e?.actionEffect==="open-cart-drawer"?{link:"/cart",target:"_self"}:e?.customURL),p=system.createStateOrContext(helpers$1.getGPProductButtonState(o,e)),g=()=>AddToCartButton_liquid.AddToCartButton({...t,style:l}),y=()=>SoldOutButton_liquid.SoldOutButton({...t,style:l,label:n}),m=()=>system.If(core.isLocalEnv,`<script ${helpers.getSettingPreloadData('class="gps-link" delay',"src")}="{{ 'gp-product-button-v7-5.js' | asset_url }}" defer="defer"></script>`,`<script ${helpers.getSettingPreloadData('class="gps-link" delay',"src")}="${core.baseAssetURL}/assets-v2/gp-product-button-v7-5.js?v={{ shop.metafields.GEMPAGES.ASSETS_VERSION }}" defer="defer"></script>`);return core.template`
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var styles=require("./common/styles.js"),helpers$1=require("./common/helpers.js"),core=require("@gem-sdk/core"),system=require("@gem-sdk/system"),helpers=require("../../../helpers.js"),getButtonDynamicSourceLocales=require("./helpers/getButtonDynamicSourceLocales.js"),SoldOutButton_liquid=require("./SoldOutButton.liquid.js"),AddToCartButton_liquid=require("./AddToCartButton.liquid.js");const ProductButton=t=>{let{setting:e,builderProps:s,style:r,styles:o,pageContext:a}=t,{wrapStyle:i,restStyle:l}=styles.getSplitStyle(r),{outOfStockButtonLabel:n,unavailableButtonLabel:u,variantSelectionRequiredMessage:c,successMessage:d,errorMessage:p}=getButtonDynamicSourceLocales.getButtonDynamicSourceLocales({setting:e,pageContext:a,builderProps:s}),{urlData:g}=helpers.getInsertLinkData("",e?.actionEffect==="open-cart-drawer"?{link:"/cart",target:"_self"}:e?.customURL),y=system.createStateOrContext(helpers$1.getGPProductButtonState({styles:o,setting:e,successMessage:d,errorMessage:p})),m=()=>AddToCartButton_liquid.AddToCartButton({...t,style:l}),S=()=>SoldOutButton_liquid.SoldOutButton({...t,style:l,label:n}),q=()=>system.If(core.isLocalEnv,`<script ${helpers.getSettingPreloadData('class="gps-link" delay',"src")}="{{ 'gp-product-button-v7-5.js' | asset_url }}" defer="defer"></script>`,`<script ${helpers.getSettingPreloadData('class="gps-link" delay',"src")}="${core.baseAssetURL}/assets-v2/gp-product-button-v7-5.js?v={{ shop.metafields.GEMPAGES.ASSETS_VERSION }}" defer="defer"></script>`);return core.template`
2
2
  ${system.Liquid("{%- assign total_combinations = 1 -%}")}
3
3
  ${system.LiquidFor("option in product.options_with_values","{%- assign total_combinations = total_combinations | times: option.values.size -%}")}
4
4
  {%- liquid
@@ -8,16 +8,16 @@
8
8
  <gp-product-button
9
9
  style="${i}"
10
10
  gp-data-wrapper="true"
11
- gp-href="${d.href}"
11
+ gp-href="${g.href}"
12
12
  class="gp-product-button"
13
13
  gp-label-out-of-stock="${n}"
14
14
  gp-label-unavailable="${u}"
15
15
  data-variant-selection-required-message="${c}"
16
16
  gp-enable-third-partycart="{{shop.metafields.GEMPAGES.enableThirdPartyCart}}"
17
17
  >
18
- <script gp-data type="application/json">${JSON.stringify(p).replaceAll("'","&#039;")}</script>
19
- ${g()}
20
- ${y()}
18
+ <script gp-data type="application/json">${JSON.stringify(y).replaceAll("'","&#039;")}</script>
19
+ ${m()}
20
+ ${S()}
21
21
  </gp-product-button>
22
- ${m()}
22
+ ${q()}
23
23
  `};exports.default=ProductButton;
@@ -1 +1 @@
1
- "use strict";var constants=require("./constants.js");const checkIconVisibility=e=>e?.enableIcon===!0,getRenderRegularPriceSettings=e=>({lineThrough:!1,typo:removeColorFromTypo(e?.priceTypo)}),getRenderComparePriceSettings=e=>({lineThrough:!0,typo:removeColorFromTypo(e?.compareAtPriceTypo),opacityPrice:e?.opacityPrice}),getGPProductButtonState=(e,t)=>({styles:{errorTypo:e?.errorTypo,successTypo:e?.successTypo},setting:{errorType:t?.errorType,actionEffect:t?.actionEffect,enableMessage:t?.enableMessage,label:t?.label?.replaceAll("'","&#039;"),errorMessage:t?.errorMessage?.replaceAll("'","&#039;"),successMessage:t?.successMessage?.replaceAll("'","&#039;"),outOfStockLabel:t?.outOfStockLabel?.replaceAll("'","&#039;"),customURL:{link:t?.customURL?.link?.replaceAll("'","&#039;"),target:t?.customURL?.target}},variantID:"{{variant.id}}",disabled:"{{variant.available}}",totalVariant:"{{total_combinations}}"}),renderSeparator=e=>{let t=e??"horizontal-line";return({dot:constants.SEPARATOR.DOT,"vertical-line":constants.SEPARATOR.VERTICAL_LINE,"horizontal-line":constants.SEPARATOR.HORIZONTAL_LINE})[t]??constants.SEPARATOR.HORIZONTAL_LINE},removeColorFromTypo=e=>(e?.attrs&&e?.attrs.color&&delete e.attrs.color,e);exports.checkIconVisibility=checkIconVisibility,exports.getGPProductButtonState=getGPProductButtonState,exports.getRenderComparePriceSettings=getRenderComparePriceSettings,exports.getRenderRegularPriceSettings=getRenderRegularPriceSettings,exports.renderSeparator=renderSeparator;
1
+ "use strict";var constants=require("./constants.js");const checkIconVisibility=e=>e?.enableIcon===!0,getRenderRegularPriceSettings=e=>({lineThrough:!1,typo:removeColorFromTypo(e?.priceTypo)}),getRenderComparePriceSettings=e=>({lineThrough:!0,typo:removeColorFromTypo(e?.compareAtPriceTypo),opacityPrice:e?.opacityPrice}),getGPProductButtonState=({styles:e,setting:t,successMessage:r,errorMessage:o})=>({styles:{errorTypo:e?.errorTypo,successTypo:e?.successTypo},setting:{errorType:t?.errorType,actionEffect:t?.actionEffect,enableMessage:t?.enableMessage,label:t?.label?.replaceAll("'","&#039;"),errorMessage:o??t?.errorMessage?.replaceAll("'","&#039;"),successMessage:r??t?.successMessage?.replaceAll("'","&#039;"),outOfStockLabel:t?.outOfStockLabel?.replaceAll("'","&#039;"),customURL:{link:t?.customURL?.link?.replaceAll("'","&#039;"),target:t?.customURL?.target}},variantID:"{{variant.id}}",disabled:"{{variant.available}}",totalVariant:"{{total_combinations}}"}),renderSeparator=e=>{let t=e??"horizontal-line";return({dot:constants.SEPARATOR.DOT,"vertical-line":constants.SEPARATOR.VERTICAL_LINE,"horizontal-line":constants.SEPARATOR.HORIZONTAL_LINE})[t]??constants.SEPARATOR.HORIZONTAL_LINE},removeColorFromTypo=e=>(e?.attrs&&e?.attrs.color&&delete e.attrs.color,e);exports.checkIconVisibility=checkIconVisibility,exports.getGPProductButtonState=getGPProductButtonState,exports.getRenderComparePriceSettings=getRenderComparePriceSettings,exports.getRenderRegularPriceSettings=getRenderRegularPriceSettings,exports.renderSeparator=renderSeparator;
@@ -1 +1 @@
1
- "use strict";var helpers=require("../../../../helpers.js"),translate=require("../../../settings/product-button/configs/translate.js");const getButtonDynamicSourceLocales=({setting:e,builderProps:t,pageContext:a})=>{let r={pageContext:a,uid:t?.uid},n=(e,t)=>{let a=helpers.getDynamicSourceLocales({...r,settingId:helpers.createSettingId({id:translate.ProductButton[e]?.id}),val:t??""});return a};return{outOfStockButtonLabel:n("outOfStockLabel",e?.outOfStockLabel),unavailableButtonLabel:n("unavailableLabel","Unavailable"),variantSelectionRequiredMessage:n("variantSelectionRequiredMessage",e?.variantSelectionRequiredMessage)}};exports.getButtonDynamicSourceLocales=getButtonDynamicSourceLocales;
1
+ "use strict";var helpers=require("../../../../helpers.js"),translate=require("../../../settings/product-button/configs/translate.js");const getButtonDynamicSourceLocales=({setting:e,builderProps:t,pageContext:s})=>{let a={pageContext:s,uid:t?.uid},r=(e,t)=>{let s=helpers.getDynamicSourceLocales({...a,settingId:helpers.createSettingId({id:translate.ProductButton[e]?.id}),val:t??""});return s};return{outOfStockButtonLabel:r("outOfStockLabel",e?.outOfStockLabel),unavailableButtonLabel:r("unavailableLabel","Unavailable"),variantSelectionRequiredMessage:r("variantSelectionRequiredMessage",e?.variantSelectionRequiredMessage),successMessage:r("successMessage",e?.successMessage),errorMessage:r("errorMessage",e?.errorMessage)}};exports.getButtonDynamicSourceLocales=getButtonDynamicSourceLocales;
@@ -1 +1 @@
1
- "use strict";const ProductButton={label:{id:"label"},outOfStockLabel:{id:"outOfStockLabel"},unavailableLabel:{id:"unavailableLabel"},variantSelectionRequiredMessage:{id:"variantSelectionRequiredMessage"}};exports.ProductButton=ProductButton;
1
+ "use strict";const ProductButton={label:{id:"label"},outOfStockLabel:{id:"outOfStockLabel"},unavailableLabel:{id:"unavailableLabel"},variantSelectionRequiredMessage:{id:"variantSelectionRequiredMessage"},successMessage:{id:"successMessage"},errorMessage:{id:"errorMessage"}};exports.ProductButton=ProductButton;
@@ -1 +1 @@
1
- import{jsx as e,jsxs as r}from"react/jsx-runtime";import{useMemo as t}from"react";import{createStyle as o,createClass as s}from"@gem-sdk/system";import{getWrapperStyles as m,getContainerStyles as c,getTextStyle as i}from"../common/styles.js";import{getWrapperClassName as d,getCheckboxContainerClassName as n,getLinkComponentClassName as l,getLinkComponentStyles as a}from"../common/classes.js";import{getComponentTag as u}from"../common/helpers.js";import{useProduct as h,usePageStore as p}from"@gem-sdk/core";import{extractProductID as y}from"../../../helpers.js";import f from"./PostPurchaseCheckbox.js";let DEFAULT_PRE_CHECK_VALUE=!0,COMPONENT_ID_PREFIX="buyer-consent-product",BuyerConsent=({styles:C,builderProps:b,setting:k})=>{let j=h(),E=p(e=>e.buyerConsentChecked),_=p(e=>e.setBuyerConsentChecked),{description:g,policyLabel:N,policyLink:P,align:x}=k??{},D=j?.id?`buyer-consent-product-${b?.uid}-${j.id}`:void 0,I=u(P),$=o(m({styles:C})),B=s(d({align:x,uid:b?.uid})),F=o(c({styles:C})),v=s(n()),A=o(i({styles:C})),L=s(l()),O=o(a()),R=t(()=>y(j?.baseID??""),[j?.baseID]),T=t(()=>{let e=`${R}`;return E?.[e]??!0},[E,R]),U=e=>{let r=`${R}`,t={...E,[r]:e.target.checked};_(t)};return e("div",{"data-id":b?.uid,style:$,className:B,children:r("label",{htmlFor:D,dir:C?.direction??"ltr",style:F,className:v,children:[e(f,{id:D,name:D,type:"checkbox",checked:T,onChange:U}),r("bdo",{dir:C?.direction??"ltr",style:A,children:[g," ",e(I,{target:"_blank",rel:"noreferrer",href:P,className:L,style:O,children:N})]})]})})};export{BuyerConsent as default};
1
+ import{jsx as e,jsxs as r}from"react/jsx-runtime";import{useMemo as t}from"react";import{createStyle as o,createClass as s}from"@gem-sdk/system";import{getWrapperStyles as m,getContainerStyles as i,getTextStyle as c}from"../common/styles.js";import{getWrapperClassName as d,getCheckboxContainerClassName as n,getLinkComponentClassName as l,getLinkComponentStyles as a}from"../common/classes.js";import{getComponentTag as h}from"../common/helpers.js";import{useProduct as u,usePageStore as p}from"@gem-sdk/core";import{extractProductID as y}from"../../../helpers.js";import f from"./PostPurchaseCheckbox.js";let DEFAULT_PRE_CHECK_VALUE=!0,COMPONENT_ID_PREFIX="buyer-consent-product",BuyerConsent=({styles:C,builderProps:b,setting:k,builderAttrs:j,style:E})=>{let _=u(),g=p(e=>e.buyerConsentChecked),N=p(e=>e.setBuyerConsentChecked),{description:P,policyLabel:x,policyLink:D,align:I}=k??{},$=_?.id?`buyer-consent-product-${b?.uid}-${_.id}`:void 0,v=h(D),B=o(m({styles:C})),F=s(d({align:I,uid:b?.uid})),A=o(i({styles:C})),L=s(n()),O=o(c({styles:C})),R=s(l()),T=o(a()),U=t(()=>y(_?.baseID??""),[_?.baseID]),H=t(()=>{let e=`${U}`;return g?.[e]??!0},[g,U]),K=e=>{let r=`${U}`,t={...g,[r]:e.target.checked};N(t)};return e("div",{...j,style:{...E},children:e("div",{"data-id":b?.uid,style:B,className:F,children:r("label",{htmlFor:$,dir:C?.direction??"ltr",style:A,className:L,children:[e(f,{id:$,name:$,type:"checkbox",checked:H,onChange:K}),r("bdo",{dir:C?.direction??"ltr",style:O,children:[P," ",e(v,{target:"_blank",rel:"noreferrer",href:D,className:R,style:T,children:x})]})]})})})};export{BuyerConsent as default};
@@ -1 +1 @@
1
- import{jsxs as e,jsx as s,Fragment as i}from"react/jsx-runtime";import{useProduct as t,useRenderMode as o,filterToolbarPreview as l}from"@gem-sdk/core";import{createStyle as n,createClass as r}from"@gem-sdk/system";import{useRef as m,useId as c}from"react";import{SubscriptionEnum as a}from"../../constants/index.js";import{getWrapperClasses as p,getContainerClasses as d}from"./common/classes.js";import{getSubscriptionStyles as g,getSubscriptionWrapperStyles as u}from"./common/styles.js";import{useSellingPlanChange as h}from"./hooks/useSellingPlanChange.js";import{useSellingSubscription as S}from"./hooks/useSellingSubscription.js";import{useSellingPlanOptions as f}from"./hooks/useSellingPlanOptions.js";import{useSubscriptionVisibility as y}from"./hooks/useSubscriptionVisibility.js";import{OneTimePurchaseTooltip as I}from"./components/OneTimePurchaseTooltip.js";import{SellingPlanDropdown as N}from"./components/SellingPlanDropdown.js";import{SellingPlanLabel as P}from"./components/SellingPlanLabel.js";import{SellingPlanRadio as b}from"./components/SellingPlanRadio.js";import{SubscriptionDetail as j}from"./components/SubscriptionDetail.js";import{SubscriptionRadio as T}from"./components/SubscriptionRadio.js";let ProductSubscription=({styles:O,setting:k,builderProps:v,builderAttrs:C,style:E,children:R})=>{let B=t(),{defaultValue:U,selectedSellingPlan:D,setSelectedSellingPlan:M}=S(k),$=f(k),{selectedValue:_,handleSellingPlanChange:x}=h({defaultValue:U,selectedSellingPlan:D,setSelectedSellingPlan:M,sellingPlanOptions:$}),V=m(null),w=c(),{selectedType:L,shouldShowRadio:q,isOneTimeHidden:z,hasNoSellingPlanOptions:A,setSubscriptionSellingType:F}=y({setting:k}),G=n(g(O)),H=n(u(O?.align)),J=r(p()),K=r(d()),Q=n({...E}),{isEditMode:W}=o(),X=`product-subscription-${B?.baseID}`,Y=B?.baseID,Z=`subscription-type-selection-${w}`,ee=k?.sellingType===a.ONE_TIME,es=k?.sellingType===a.SUBSCRIPTION;if(z||A)return W?e("div",{...C,style:Q,children:[s(I,{ref:V,setting:k}),l(R,!0)]}):null;let ei=i=>e("div",{...C,style:Q,children:[s("div",{ref:V,"data-selling-type":k?.sellingType,id:X,className:J,style:H,children:i}),l(R,!0)]}),et=()=>s(i,{children:k?.sellingStyle==="radio"?s(b,{setting:k,styles:O,builderProps:v,productId:Y??"",sellingPlanOptions:$,selectedValue:_,onChange:x}):s(N,{setting:k,sellingPlanOptions:$,selectedValue:_,onChange:x})});return ei(ee&&q?s("div",{className:K,style:G,children:s(T,{id:`${Y}-one-time-radio`,name:Z,value:a.ONE_TIME,checked:L===a.ONE_TIME,className:"!gp-items-start",onChange:e=>{e.target.checked&&F(a.ONE_TIME)},children:s(P,{setting:k,styles:O})})}):es&&q?e("div",{className:K,style:G,children:[s(T,{id:`${Y}-subscription-radio`,name:Z,value:a.SUBSCRIPTION,checked:L===a.SUBSCRIPTION,className:"!gp-items-start",onChange:e=>{e.target.checked&&F(a.SUBSCRIPTION)},children:s(P,{setting:k,styles:O})}),L===a.SUBSCRIPTION&&e(i,{children:[s("div",{className:"gp-pl-7",children:et()}),s("div",{className:"gp-pl-7",children:s(j,{setting:k,styles:O})})]})]}):e("div",{className:K,style:G,children:[s(P,{setting:k,styles:O}),et(),s(j,{setting:k,styles:O})]}))};export{ProductSubscription as default};
1
+ import{jsxs as e,jsx as s,Fragment as i}from"react/jsx-runtime";import{useProduct as t,useRenderMode as o,filterToolbarPreview as l}from"@gem-sdk/core";import{createStyle as n,createClass as r}from"@gem-sdk/system";import{useRef as m,useId as c}from"react";import{SubscriptionEnum as a}from"../../constants/index.js";import{getWrapperClasses as p,getContainerClasses as d}from"./common/classes.js";import{getSubscriptionStyles as g,getSubscriptionWrapperStyles as u}from"./common/styles.js";import{useSellingPlanChange as h}from"./hooks/useSellingPlanChange.js";import{useSellingSubscription as S}from"./hooks/useSellingSubscription.js";import{useSellingPlanOptions as f}from"./hooks/useSellingPlanOptions.js";import{useSubscriptionVisibility as y}from"./hooks/useSubscriptionVisibility.js";import{OneTimePurchaseTooltip as I}from"./components/OneTimePurchaseTooltip.js";import{SellingPlanDropdown as N}from"./components/SellingPlanDropdown.js";import{SellingPlanLabel as P}from"./components/SellingPlanLabel.js";import{SellingPlanRadio as j}from"./components/SellingPlanRadio.js";import{SubscriptionDetail as b}from"./components/SubscriptionDetail.js";import{SubscriptionRadio as T}from"./components/SubscriptionRadio.js";import{useDynamicProduct as O}from"../../hooks/useDynamicProduct.js";let ProductSubscription=({styles:k,setting:v,builderProps:C,builderAttrs:E,style:R,children:B})=>{let D=t(),{defaultValue:U,selectedSellingPlan:M,setSelectedSellingPlan:$}=S(v),_=f(v),{selectedValue:x,handleSellingPlanChange:V}=h({defaultValue:U,selectedSellingPlan:M,setSelectedSellingPlan:$,sellingPlanOptions:_}),w=m(null),L=c(),{selectedType:q,shouldShowRadio:z,isOneTimeHidden:A,hasNoSellingPlanOptions:F,setSubscriptionSellingType:G}=y({setting:v}),H=n(g(k)),J=n(u(k?.align)),K=r(p()),Q=r(d()),W=n({...R}),{isEditMode:X}=o(),Y=`product-subscription-${D?.baseID}`,Z=D?.baseID,ee=`subscription-type-selection-${L}`,es=v?.sellingType===a.ONE_TIME,ei=v?.sellingType===a.SUBSCRIPTION,{isDynamicProduct:et}=O();if(A||F||et)return X?e("div",{...E,style:W,children:[s(I,{ref:w,setting:v}),l(B,!0)]}):null;let eo=i=>e("div",{...E,style:W,children:[s("div",{ref:w,"data-selling-type":v?.sellingType,id:Y,className:K,style:J,children:i}),l(B,!0)]}),el=()=>s(i,{children:v?.sellingStyle==="radio"?s(j,{setting:v,styles:k,builderProps:C,productId:Z??"",sellingPlanOptions:_,selectedValue:x,onChange:V}):s(N,{setting:v,sellingPlanOptions:_,selectedValue:x,onChange:V})});return eo(es&&z?s("div",{className:Q,style:H,children:s(T,{id:`${Z}-one-time-radio`,name:ee,value:a.ONE_TIME,checked:q===a.ONE_TIME,className:"!gp-items-start",onChange:e=>{e.target.checked&&G(a.ONE_TIME)},children:s(P,{setting:v,styles:k})})}):ei&&z?e("div",{className:Q,style:H,children:[s(T,{id:`${Z}-subscription-radio`,name:ee,value:a.SUBSCRIPTION,checked:q===a.SUBSCRIPTION,className:"!gp-items-start",onChange:e=>{e.target.checked&&G(a.SUBSCRIPTION)},children:s(P,{setting:v,styles:k})}),q===a.SUBSCRIPTION&&e(i,{children:[s("div",{className:"gp-pl-7",children:el()}),s("div",{className:"gp-pl-7",children:s(b,{setting:v,styles:k})})]})]}):e("div",{className:Q,style:H,children:[s(P,{setting:v,styles:k}),el(),s(b,{setting:v,styles:k})]}))};export{ProductSubscription as default};
@@ -1,4 +1,4 @@
1
- import{getSplitStyle as t}from"./common/styles.js";import{getGPProductButtonState as o}from"./common/helpers.js";import{template as s,isLocalEnv as e,baseAssetURL as r}from"@gem-sdk/core";import{createStateOrContext as a,Liquid as i,LiquidFor as l,If as n}from"@gem-sdk/system";import{getInsertLinkData as p,getSettingPreloadData as c}from"../../../helpers.js";import{getButtonDynamicSourceLocales as u}from"./helpers/getButtonDynamicSourceLocales.js";import{SoldOutButton as d}from"./SoldOutButton.liquid.js";import{AddToCartButton as m}from"./AddToCartButton.liquid.js";let ProductButton=f=>{let{setting:g,builderProps:y,style:b,styles:$,pageContext:v}=f,{wrapStyle:_,restStyle:h}=t(b),{outOfStockButtonLabel:j,unavailableButtonLabel:S,variantSelectionRequiredMessage:k}=u({setting:g,pageContext:v,builderProps:y}),{urlData:E}=p("",g?.actionEffect==="open-cart-drawer"?{link:"/cart",target:"_self"}:g?.customURL),q=a(o($,g)),A=()=>m({...f,style:h}),B=()=>d({...f,style:h,label:j}),P=()=>n(e,`<script ${c('class="gps-link" delay',"src")}="{{ 'gp-product-button-v7-5.js' | asset_url }}" defer="defer"></script>`,`<script ${c('class="gps-link" delay',"src")}="${r}/assets-v2/gp-product-button-v7-5.js?v={{ shop.metafields.GEMPAGES.ASSETS_VERSION }}" defer="defer"></script>`);return s`
1
+ import{getSplitStyle as t}from"./common/styles.js";import{getGPProductButtonState as o}from"./common/helpers.js";import{template as s,isLocalEnv as e,baseAssetURL as r}from"@gem-sdk/core";import{createStateOrContext as a,Liquid as i,LiquidFor as l,If as n}from"@gem-sdk/system";import{getInsertLinkData as p,getSettingPreloadData as c}from"../../../helpers.js";import{getButtonDynamicSourceLocales as u}from"./helpers/getButtonDynamicSourceLocales.js";import{SoldOutButton as d}from"./SoldOutButton.liquid.js";import{AddToCartButton as m}from"./AddToCartButton.liquid.js";let ProductButton=f=>{let{setting:g,builderProps:y,style:b,styles:$,pageContext:v}=f,{wrapStyle:_,restStyle:h}=t(b),{outOfStockButtonLabel:j,unavailableButtonLabel:S,variantSelectionRequiredMessage:k,successMessage:E,errorMessage:q}=u({setting:g,pageContext:v,builderProps:y}),{urlData:A}=p("",g?.actionEffect==="open-cart-drawer"?{link:"/cart",target:"_self"}:g?.customURL),B=a(o({styles:$,setting:g,successMessage:E,errorMessage:q})),P=()=>m({...f,style:h}),G=()=>d({...f,style:h,label:j}),w=()=>n(e,`<script ${c('class="gps-link" delay',"src")}="{{ 'gp-product-button-v7-5.js' | asset_url }}" defer="defer"></script>`,`<script ${c('class="gps-link" delay',"src")}="${r}/assets-v2/gp-product-button-v7-5.js?v={{ shop.metafields.GEMPAGES.ASSETS_VERSION }}" defer="defer"></script>`);return s`
2
2
  ${i("{%- assign total_combinations = 1 -%}")}
3
3
  ${l("option in product.options_with_values","{%- assign total_combinations = total_combinations | times: option.values.size -%}")}
4
4
  {%- liquid
@@ -8,16 +8,16 @@ import{getSplitStyle as t}from"./common/styles.js";import{getGPProductButtonStat
8
8
  <gp-product-button
9
9
  style="${_}"
10
10
  gp-data-wrapper="true"
11
- gp-href="${E.href}"
11
+ gp-href="${A.href}"
12
12
  class="gp-product-button"
13
13
  gp-label-out-of-stock="${j}"
14
14
  gp-label-unavailable="${S}"
15
15
  data-variant-selection-required-message="${k}"
16
16
  gp-enable-third-partycart="{{shop.metafields.GEMPAGES.enableThirdPartyCart}}"
17
17
  >
18
- <script gp-data type="application/json">${JSON.stringify(q).replaceAll("'","&#039;")}</script>
19
- ${A()}
20
- ${B()}
18
+ <script gp-data type="application/json">${JSON.stringify(B).replaceAll("'","&#039;")}</script>
19
+ ${P()}
20
+ ${G()}
21
21
  </gp-product-button>
22
- ${P()}
22
+ ${w()}
23
23
  `};export{ProductButton as default};
@@ -1 +1 @@
1
- import{SEPARATOR as e}from"./constants.js";let checkIconVisibility=e=>e?.enableIcon===!0,getRenderRegularPriceSettings=e=>({lineThrough:!1,typo:removeColorFromTypo(e?.priceTypo)}),getRenderComparePriceSettings=e=>({lineThrough:!0,typo:removeColorFromTypo(e?.compareAtPriceTypo),opacityPrice:e?.opacityPrice}),getGPProductButtonState=(e,r)=>({styles:{errorTypo:e?.errorTypo,successTypo:e?.successTypo},setting:{errorType:r?.errorType,actionEffect:r?.actionEffect,enableMessage:r?.enableMessage,label:r?.label?.replaceAll("'","&#039;"),errorMessage:r?.errorMessage?.replaceAll("'","&#039;"),successMessage:r?.successMessage?.replaceAll("'","&#039;"),outOfStockLabel:r?.outOfStockLabel?.replaceAll("'","&#039;"),customURL:{link:r?.customURL?.link?.replaceAll("'","&#039;"),target:r?.customURL?.target}},variantID:"{{variant.id}}",disabled:"{{variant.available}}",totalVariant:"{{total_combinations}}"}),renderSeparator=r=>{let t=r??"horizontal-line";return({dot:e.DOT,"vertical-line":e.VERTICAL_LINE,"horizontal-line":e.HORIZONTAL_LINE})[t]??e.HORIZONTAL_LINE},removeColorFromTypo=e=>(e?.attrs&&e?.attrs.color&&delete e.attrs.color,e);export{checkIconVisibility,getGPProductButtonState,getRenderComparePriceSettings,getRenderRegularPriceSettings,renderSeparator};
1
+ import{SEPARATOR as e}from"./constants.js";let checkIconVisibility=e=>e?.enableIcon===!0,getRenderRegularPriceSettings=e=>({lineThrough:!1,typo:removeColorFromTypo(e?.priceTypo)}),getRenderComparePriceSettings=e=>({lineThrough:!0,typo:removeColorFromTypo(e?.compareAtPriceTypo),opacityPrice:e?.opacityPrice}),getGPProductButtonState=({styles:e,setting:r,successMessage:t,errorMessage:o})=>({styles:{errorTypo:e?.errorTypo,successTypo:e?.successTypo},setting:{errorType:r?.errorType,actionEffect:r?.actionEffect,enableMessage:r?.enableMessage,label:r?.label?.replaceAll("'","&#039;"),errorMessage:o??r?.errorMessage?.replaceAll("'","&#039;"),successMessage:t??r?.successMessage?.replaceAll("'","&#039;"),outOfStockLabel:r?.outOfStockLabel?.replaceAll("'","&#039;"),customURL:{link:r?.customURL?.link?.replaceAll("'","&#039;"),target:r?.customURL?.target}},variantID:"{{variant.id}}",disabled:"{{variant.available}}",totalVariant:"{{total_combinations}}"}),renderSeparator=r=>{let t=r??"horizontal-line";return({dot:e.DOT,"vertical-line":e.VERTICAL_LINE,"horizontal-line":e.HORIZONTAL_LINE})[t]??e.HORIZONTAL_LINE},removeColorFromTypo=e=>(e?.attrs&&e?.attrs.color&&delete e.attrs.color,e);export{checkIconVisibility,getGPProductButtonState,getRenderComparePriceSettings,getRenderRegularPriceSettings,renderSeparator};
@@ -1 +1 @@
1
- import{getDynamicSourceLocales as e,createSettingId as t}from"../../../../helpers.js";import{ProductButton as a}from"../../../settings/product-button/configs/translate.js";let getButtonDynamicSourceLocales=({setting:o,builderProps:i,pageContext:l})=>{let n={pageContext:l,uid:i?.uid},r=(o,i)=>{let l=e({...n,settingId:t({id:a[o]?.id}),val:i??""});return l};return{outOfStockButtonLabel:r("outOfStockLabel",o?.outOfStockLabel),unavailableButtonLabel:r("unavailableLabel","Unavailable"),variantSelectionRequiredMessage:r("variantSelectionRequiredMessage",o?.variantSelectionRequiredMessage)}};export{getButtonDynamicSourceLocales};
1
+ import{getDynamicSourceLocales as e,createSettingId as t}from"../../../../helpers.js";import{ProductButton as s}from"../../../settings/product-button/configs/translate.js";let getButtonDynamicSourceLocales=({setting:a,builderProps:r,pageContext:o})=>{let i={pageContext:o,uid:r?.uid},u=(a,r)=>{let o=e({...i,settingId:t({id:s[a]?.id}),val:r??""});return o};return{outOfStockButtonLabel:u("outOfStockLabel",a?.outOfStockLabel),unavailableButtonLabel:u("unavailableLabel","Unavailable"),variantSelectionRequiredMessage:u("variantSelectionRequiredMessage",a?.variantSelectionRequiredMessage),successMessage:u("successMessage",a?.successMessage),errorMessage:u("errorMessage",a?.errorMessage)}};export{getButtonDynamicSourceLocales};
@@ -1 +1 @@
1
- let ProductButton={label:{id:"label"},outOfStockLabel:{id:"outOfStockLabel"},unavailableLabel:{id:"unavailableLabel"},variantSelectionRequiredMessage:{id:"variantSelectionRequiredMessage"}};export{ProductButton};
1
+ let ProductButton={label:{id:"label"},outOfStockLabel:{id:"outOfStockLabel"},unavailableLabel:{id:"unavailableLabel"},variantSelectionRequiredMessage:{id:"variantSelectionRequiredMessage"},successMessage:{id:"successMessage"},errorMessage:{id:"errorMessage"}};export{ProductButton};
@@ -5,7 +5,7 @@ import { Property } from 'csstype';
5
5
  import * as _gem_sdk_keen_slider from '@gem-sdk/keen-slider';
6
6
  import { KeenSliderInstance } from '@gem-sdk/keen-slider';
7
7
  import { Swiper } from '@gem-sdk/swiper';
8
- import React$1, { ReactNode, FC } from 'react';
8
+ import React$1, { ReactNode } from 'react';
9
9
  import * as _gem_sdk_swiper_types_swiper_class from '@gem-sdk/swiper/types/swiper-class';
10
10
 
11
11
  type AccordionSettingProps = {
@@ -3561,9 +3561,9 @@ type PostPurchaseBuyerConsentStyleProps = {
3561
3561
  textAlign?: AlignItemProp;
3562
3562
  typo?: PostPurchaseTypo;
3563
3563
  };
3564
- type PostPurchaseBuyerConsentProps = BaseProps<PostPurchaseBuyerConsentSettingProps, PostPurchaseBuyerConsentStyleProps>;
3564
+ type PostPurchaseBuyerConsentProps = BasePropsWrap<PostPurchaseBuyerConsentSettingProps, PostPurchaseBuyerConsentStyleProps>;
3565
3565
 
3566
- declare const BuyerConsent: FC<PostPurchaseBuyerConsentProps>;
3566
+ declare const BuyerConsent: React.FC<PostPurchaseBuyerConsentProps>;
3567
3567
 
3568
3568
  declare const postPurchaseBuyerConsentSetting: {
3569
3569
  PostPurchaseBuyerConsent: _gem_sdk_core.ComponentSetting<PostPurchaseBuyerConsentProps>;
@@ -3790,6 +3790,7 @@ type ProductButtonProps = BasePropsWrap<ProductButtonSettingProps, ProductButton
3790
3790
  style?: React.CSSProperties;
3791
3791
  children?: React.ReactNode;
3792
3792
  };
3793
+ type ProductButtonPropsTranslateKeys = keyof (ProductButtonSettingProps & ProductButtonStyleProps);
3793
3794
  type Separator = 'horizontal-line' | 'vertical-line' | 'dot';
3794
3795
  type ButtonLayout = 'cart-only' | 'cart-icon' | 'cart-price' | 'cart-price-icon' | 'cart-full' | 'icon-only';
3795
3796
 
@@ -8087,7 +8088,7 @@ declare const ProductTag: TranslateObject<keyof ProductTagSidebarSettingProps['s
8087
8088
 
8088
8089
  declare const ProductDescription: TranslateObject<'viewMoreText' | 'viewLessText'>;
8089
8090
 
8090
- declare const ProductButton: TranslateObject<'label' | 'outOfStockLabel' | 'unavailableLabel' | 'variantSelectionRequiredMessage'>;
8091
+ declare const ProductButton: TranslateObject<ProductButtonPropsTranslateKeys>;
8091
8092
 
8092
8093
  declare const ProductBadge: TranslateObject<'displayContent'>;
8093
8094
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gem-sdk/components",
3
- "version": "12.0.0-dev.79",
3
+ "version": "12.0.0-dev.81",
4
4
  "license": "MIT",
5
5
  "sideEffects": false,
6
6
  "main": "dist/cjs/index.js",
@@ -26,7 +26,7 @@
26
26
  "i18n:extract": "rollup -c ./scripts/rollup.config.settings.mjs && node ./scripts/translate/extract-texts-to-locales.js && node ./scripts/translate/en-keys-usage.js"
27
27
  },
28
28
  "devDependencies": {
29
- "@gem-sdk/core": "12.0.0-dev.79",
29
+ "@gem-sdk/core": "12.0.0-dev.81",
30
30
  "@gem-sdk/styles": "12.0.0-dev.71",
31
31
  "@gem-sdk/system": "12.0.0-dev.53",
32
32
  "@types/react-transition-group": "^4.4.12",