const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["component-Captcha.DTFlGjdV.js","dist-vendor.C4_qYgK9.js","esm-ShopPayCaptcha.DWqfz8Pi.js","hooks-ButtonWithRegisterWebPixel.BS-QmNv3.js","approval-scopes-FullScreenBackground.BMvb4DkL.js","app.BF3dzpy1.js","assets/app.fH9d1Lew.css","assets/FullScreenBackground.-XSmsMDv.css","assets/ButtonWithRegisterWebPixel.DcDpJflp.css","assets/Captcha.CJQgLR0i.css"])))=>i.map(i=>d[i]);
import{_ as m}from"./app.BF3dzpy1.js";import{g as B,r as g,u as e,q as f,p as b,b as w,k as v}from"./dist-vendor.C4_qYgK9.js";import{T as h,lg as A,L as W,B as x,l as S,es as R,lh as T,ha as z,h9 as I,li as L,hd as M,M as N}from"./hooks-ButtonWithRegisterWebPixel.BS-QmNv3.js";import{a as C}from"./approval-scopes-FullScreenBackground.BMvb4DkL.js";const q=B({load:()=>g(()=>m(()=>import("./component-Captcha.DTFlGjdV.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9])))});function E({isForExpressCheckout:a=!1}){const{i18n:t,shop:{merchantPolicies:l}}=C(),n=a?"small":"generic",i=l.find(r=>r.handle==="subscription-policy"),o=e(h,{type:n,children:t.translate("payment.purchase_options_cancellation_policy_label")}),s=i?e(W,{overlay:e(A,{handle:"subscription-policy",title:t.translate("shop_policies.purchase_options_cancellation_policy")}),children:o}):o;return e(x,{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 V=({disabled:a,loading:t,defaultLabel:l,pixelId:n})=>{const{nextPage:i}=S(),o=R(),s=i.id==="review",r=T().value,_=z(),{setPayNowButtonElement:u}=I(),d=f(P=>{o(n)(P),u(P)},[o,u,n]),y=_&&!s,c=r&&!s,p=b(!1);return c&&!p.value&&(p.value=!0),e(v,{children:[e(w,{when:p,children:e(L,{disabled:a,loading:t,hidden:!c})}),y&&e(M,{disabled:a,loading:t,pixelId:n}),!c&&!y&&e(N,{variant:"primary",size:"large",type:"submit",inlineSize:"fill",loading:t,disabled:a,ref:d,children:l})]})};export{q as C,E as P,V as a};
