PageSourceSearch

https://park-place-liquor-and-deli.onrender.com/assets/TurnstileProvider-D0TbC3sy.js

js park-place-liquor-and-deli.onrender.com collected 2026-10-03 11:44:08 UTC 2,661 bytes, 1 lines download raw bytes

1import{r as e,j as C}from"./jsx-runtime-D2HyDbKh.js";import{u as k}from"./root-B7dITD1u.js";const A="cf-turnstile-response",v="https://challenges.cloudflare.com/turnstile/v0/api.js?render=explicit",P=4e3,L=6e3,S=()=>window.turnstile?Promise.resolve(window.turnstile):(window.__turnstileLoader||(window.__turnstileLoader=new Promise((i,c)=>{const n=document.createElement("script");n.src=v,n.async=!0,n.defer=!0,n.onload=()=>{window.turnstile?i(window.turnstile):c(new Error("Turnstile script loaded without an API"))},n.onerror=()=>{delete window.__turnstileLoader,c(new Error("Turnstile script failed to load"))},document.head.appendChild(n)})),window.__turnstileLoader),N=i=>new Promise(c=>setTimeout(c,i)),j={enabled:!1,getToken:async()=>null},x=e.createContext(j),K=()=>e.useContext(x),F=({children:i,className:c})=>{var b,y;const n=e.useContext(x),R=k(),_=(y=(b=R==null?void 0:R.ENV)==null?void 0:b.TURNSTILE_SITE_KEY)==null?void 0:y.trim(),l=!n.enabled&&!!_,h=e.useRef(null),a=e.useRef(null),E=e.useRef(null),o=e.useRef(null),s=e.useRef(!1),d=e.useRef([]),f=e.useCallback(()=>{const r=d.current.shift();return r&&clearTimeout(r.timer),r},[]),w=e.useCallback(()=>{for(let r=f();r;r=f())r.resolve(null)},[f]),m=e.useCallback(()=>{const r=window.turnstile,t=a.current;if(!(!r||!t||s.current)){s.current=!0;try{r.reset(t)}catch(u){s.current=!1,console.error("[turnstile] reset failed",u),w()}}},[w]);e.useEffect(()=>{if(!l)return;let r=!1;return E.current=S().then(t=>{if(r||!h.current)return!1;const u=t.render(h.current,{sitekey:_,execution:"render",appearance:"interaction-only","refresh-expired":"auto",retry:"auto","retry-interval":3e3,callback:p=>{s.current=!1;const T=f();T?(T.resolve(p),d.current.length>0&&m()):o.current=p},"error-callback":()=>{s.current=!1,o.current=null,w()},"expired-callback":()=>{o.current=null},"timeout-callback":()=>{s.current=!1}});return u?(a.current=u,s.current=!0,!0):!1}).catch(t=>(console.error("[turnstile] widget unavailable",t),!1)),()=>{r=!0,w(),o.current=null,s.current=!1;const t=a.current;if(a.current=null,t&&window.turnstile)try{window.turnstile.remove(t)}catch{}}},[l,_,m,f,w]);const I=e.useCallback(async()=>{if(!l||!await Promise.race([E.current??Promise.resolve(!1),N(L).then(()=>!1)])||!a.current)return null;const t=o.current;return t?(o.current=null,m(),t):new Promise(u=>{const p={resolve:u,timer:setTimeout(()=>{d.current=d.current.filter(T=>T!==p),u(null)},P)};d.current.push(p),m()})},[l,m]),g=e.useMemo(()=>n.enabled?n:{enabled:l,getToken:I},[n,l,I]);return C.jsxs(x.Provider,{value:g,children:[i,l&&C.jsx("div",{ref:h,className:c,"data-turnstile-container":!0})]})};export{F as T,A as a,K 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.