const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["component-Captcha.BmkvKYyl.js","vendor.BXe-L2nx.js","ShopPayCaptcha.ZPUFFHCN.js","app.aa9qjHTz.js","assets/app.CqTnsDJP.css","assets/Captcha.CJQgLR0i.css"])))=>i.map(i=>d[i]);
import{lx as m,b as B,T as h,uX as b,L as g,B as f,A as w,dd as A,uY as v,oB as W,p5 as x,uZ as S,p9 as L,ae as R}from"./app.aa9qjHTz.js";import{L as T,G as z,u as e,q as I,l as N,k as C}from"./vendor.BXe-L2nx.js";const O=T({load:()=>z(()=>m(()=>import("./component-Captcha.BmkvKYyl.js"),__vite__mapDeps([0,1,2,3,4,5])))});function j({isForExpressCheckout:a=!1}){const{i18n:t,shop:{merchantPolicies:l}}=B(),n=a?"small":"generic",i=l.find(c=>c.handle==="subscription-policy"),o=e(h,{type:n,children:t.translate("payment.purchase_options_cancellation_policy_label")}),s=i?e(g,{overlay:e(b,{handle:"subscription-policy",title:t.translate("shop_policies.purchase_options_cancellation_policy")}),children:o}):o;return e(f,{id:"purchase_options_agreement",padding:a?"small-100 none none none":"none",children:e(h,{color:"subdued",type:n,children:a?t.translate("payment.purchase_options_agreement_label_wallets"):t.translate("payment.purchase_options_agreement_label",{cancellation_policy_label:s})})})}const k=({disabled:a,loading:t,defaultLabel:l,pixelId:n})=>{const{nextPage:i}=w(),o=A(),s=i.id==="review",c=v(),_=W(),{setPayNowButtonElement:u}=x(),d=I(P=>{o(n)(P),u(P)},[o,u,n]),y=_&&!s,r=c&&!s,p=N(!1);return r&&!p.value&&(p.value=!0),e(C,{children:[p.value&&e(S,{disabled:a,loading:t,hidden:!r}),y&&e(L,{disabled:a,loading:t,pixelId:n}),!r&&!y&&e(R,{variant:"primary",size:"large",type:"submit",inlineSize:"fill",loading:t,disabled:a,ref:d,children:l})]})};export{O as C,j as P,k as a};
