1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["56bd1136.B2qTB_jK.js","2c1ab0fe.DYQSH7bT.js","164ad2e3.BcELPLd1.js","4c290a1e.CvCmFIo_.js","app.Bvc4uxd4.js","assets/app.BuSMBobh.css","assets/previous.BpuyvRSB.css","65f3d4da.CPQqj7Ry.js","60a453ce.BJZuodLH.js","0a7dffce.BF-zuF6E.js","bb728e1c.D4AahLMP.js","assets/stopwatch.Kyhz8KoT.css","3a819064.zwYHd_Yo.js","ac5a19ff.B7MskK0_.js","cb8fcd45.c_ESjgQZ.js","8536083a.Ds7iqcJA.js","assets/WalletSandbox.BoV0vp4z.css","4aab4b34.7Cs4eZrV.js","assets/amazonWalletLazy.D78LrA7v.css"])))=>i.map(i=>d[i]); 2import{e as E,A,T as k,E as I,q as O,h as M,u as d,f as V,d as B}from"./2c1ab0fe.DYQSH7bT.js";import{aT as w,aV as F,P as b,O as L,aW as T,aX as x,W as z,aY as W,a6 as D,_ as N}from"./4c290a1e.CvCmFIo_.js";import{e as H,as as R,at as U,au as G,L as K,c as Y,I as j,n as q}from"./164ad2e3.BcELPLd1.js";import{_ as J}from"./app.Bvc4uxd4.js";import{M as X}from"./74835653.CCeFHMk_.js";function se({onValid:e,onInvalid:n,children:i}){const{billing:l,contact:u,payment:p,shipping:y}=w(),a=E(new Map),h=A(new WeakMap),f=k(()=>I(()=>{const t=a.value;let o=!1,s=t.size>0;for(const[c,{validator:r,previousValue:m}]of t){const g=c.value;r(g)&&(s=!1),g!==m&&(o=!0)}return{valid:s,changed:o}}),[a]),v=O(t=>{const o={billing:l,contact:u,payment:p,shipping:y};t.valid?e?.(o):n?.(o);const s=new Map;for(const[c,r]of a.value)s.set(c,{...r,previousValue:c.value});a.value=s},[a,e,n,l,u,p,y]),P=A(!1);M(()=>f.subscribe(t=>{const o=!P.current;if(t.changed||o)return P.current=!0,v(t)}),[f,v]);const S=k(()=>({registerValidator:(t,o)=>{const s=new Map(a.peek()),c=h.current.get(t);return s.set(t,{validator:o,previousValue:c}),a.value=s,()=>{const r=a.peek().get(t);r?.previousValue!==void 0&&h.current.set(t,r.previousValue);const m=new Map(a.peek());m.delete(t),a.value=m}}}),[a]);return d(F.Provider,{value:S,children:i})}function re(){const{paymentMethods:e,buyerIdentity:n}=b(),{router:i,source:{type:l},mobileCheckoutSdk:u,embed:p,checkout:y,shop:a}=L(),h=i.currentUrl,f=y.proposal.proposed.paymentLines,v=a.hasFlagEnabled(T),P=x(),S=H(),t=l==="simulated",o=u.variant.isStandard()||!!p?.isCheckoutKit();return V(()=>{const s=e.value?.some(C=>C.type==="wallet"&&C.name==="SHOP_PAY"),c=n.value?.purchasingCompany,{currentDetour:r}=S.value,m=r!=null&&["stockProblems"].includes(r.type),g=z(h.value.searchParams),_=v&&!!W(f.value);return!!(!t&&s&&!g&&!P.value&&!o&&!m&&!c&&!_)})}function Q(e,{wallet:n}={}){const{sdkStatus:i,buttonStatus:l,buyWithPrimeButtonStatus:u}=D().inMemoryAmazonPayParts,p=n===N.BuyWithPrime?u:l;M(()=>{e&&(i.value={status:R.Error},p.value={status:"error"})},[e,i,p])}const Z=B({displayName:"AmazonPayButtonContent",load:()=>J(()=>import("./56bd1136.B2qTB_jK.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18])).then(e=>e.AmazonPayButtonContent),useError:Q});function ie({isSdkOnly:e=!1}){return d(Z,{isSdkOnly:e})}const $=["paymentMethods"];function le(){const e=b().paymentMethods,n=U($);return V(()=>n.value&&!e.value?.length)}function ue({showIcon:e=!1}){const{i18n:n,source:i}=L(),l=G(),u=i.type==="simulated";return d(X,{interactive:!u,children:d(K,{href:l.value,display:"block",accessibilityLabel:n.translate("contact.change_company_location_link_label"),textDecoration:e?"none":void 0,children:d(Y,{direction:"inline",alignItems:"center",gap:"small-100",children:[e&&d(j,{type:"location"}),d(q,{children:n.translate("contact.change_location_link_label")})]})})})}export{ie as A,ue as C,se as S,le as a,Q as b,re as u};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.