1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1485],{81485:(e,t,n)=>{n.r(t),n.d(t,{DEFAULT_CONTAINER_ID:()=>l,DEFAULT_ONLOAD_NAME:()=>s,DEFAULT_SCRIPT_ID:()=>u,SCRIPT_URL:()=>a,Turnstile:()=>v});var r,o=n(98547),i=n(76947),c=(0,o.forwardRef)((e,t)=>{let{as:n="div",...r}=e;return(0,i.jsx)(n,{...r,ref:t})}),a="https://challenges.cloudflare.com/turnstile/v0/api.js",u="cf-turnstile-script",l="cf-turnstile",s="onloadTurnstileCallback",d=e=>!!document.getElementById(e),f={normal:{width:300,height:65},compact:{width:150,height:140},invisible:{width:0,height:0,overflow:"hidden"},flexible:{minWidth:300,width:"100%",height:65},interactionOnly:{width:"fit-content",height:"auto",display:"flex"}},p="unloaded",w=new Promise((e,t)=>{r={resolve:e,reject:t},"ready"===p&&e(void 0)}),h=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:s;return"unloaded"===p&&(p="loading",window[e]=()=>{r.resolve(),p="ready",delete window[e]}),w},v=(0,o.forwardRef)((e,t)=>{let{scriptOptions:n,options:r={},siteKey:w,onWidgetLoad:v,onSuccess:m,onExpire:b,onError:y,onBeforeInteractive:x,onAfterInteractive:g,onUnsupported:E,onTimeout:T,onLoadScript:k,id:N,style:R,as:I="div",injectScript:C=!0,...O}=e,L=r.size,_=(0,o.useCallback)(()=>typeof L>"u"?{}:"execute"===r.execution?f.invisible:"interaction-only"===r.appearance?f.interactionOnly:f[L],[r.execution,L,r.appearance]),[F,D]=(0,o.useState)(_()),S=(0,o.useRef)(null),[A,P]=(0,o.useState)(!1),j=(0,o.useRef)(),U=(0,o.useRef)(!1),B=N||l,M=(null==n?void 0:n.id)||u,z=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:u,[t,n]=(0,o.useState)(!1);return(0,o.useEffect)(()=>{let t=()=>{d(e)&&n(!0)},r=new MutationObserver(t);return r.observe(document,{childList:!0,subtree:!0}),t(),()=>{r.disconnect()}},[e]),t}(M),W=(null==n?void 0:n.onLoadCallbackName)||s,q=r.appearance||"always",H=(0,o.useMemo)(()=>({sitekey:w,action:r.action,cData:r.cData,callback:e=>{U.current=!0,null==m||m(e)},"error-callback":y,"expired-callback":b,"before-interactive-callback":x,"after-interactive-callback":g,"unsupported-callback":E,theme:r.theme||"auto",language:r.language||"auto",tabindex:r.tabIndex,"response-field":r.responseField,"response-field-name":r.responseFieldName,size:function(e){if("invisible"!==e&&"interactionOnly"!==e)return e}(L),retry:r.retry||"auto","retry-interval":r.retryInterval||8e3,"refresh-expired":r.refreshExpired||"auto","refresh-timeout":r.refreshTimeout||"auto",execution:r.execution||"render",appearance:r.appearance||"always","feedback-enabled":r.feedbackEnabled||!0,"timeout-callback":T}),[r.action,r.appearance,r.cData,r.execution,r.language,r.refreshExpired,r.responseField,r.responseFieldName,r.retry,r.retryInterval,r.tabIndex,r.theme,r.feedbackEnabled,r.refreshTimeout,w,L]),K=(0,o.useCallback)(()=>"u">typeof window&&!!window.turnstile,[]);return(0,o.useEffect)(function(){C&&!A&&(e=>{let{render:t="explicit",onLoadCallbackName:n=s,scriptOptions:{nonce:r="",defer:o=!0,async:i=!0,id:c="",appendTo:l,onError:f,crossOrigin:p=""}={}}=e,w=c||u;if(d(w))return;let h=document.createElement("script");h.id=w,h.src="".concat(a,"?onload=").concat(n,"&render=").concat(t),document.querySelector('script[src="'.concat(h.src,'"]'))||(h.defer=!!o,h.async=!!i,r&&(h.nonce=r),p&&(h.crossOrigin=p),f&&(h.onerror=f,delete window[n]),("body"===l?document.body:document.getElementsByTagName("head")[0]).appendChild(h))})({onLoadCallbackName:W,scriptOptions:{...n,id:M}})},[C,A,n,M]),(0,o.useEffect)(function(){"ready"!==p&&h(W).then(()=>P(!0)).catch(console.error)},[]),(0,o.useEffect)(function(){if(!S.current||!A)return;let e=!1;return(async()=>{!e&&S.current&&(j.current=window.turnstile.render(S.current,H),j.current&&(null==v||v(j.current)))})(),()=>{e=!0,j.current&&(window.turnstile.remove(j.current),U.current=!1)}},[B,A,H]),(0,o.useImperativeHandle)(t,()=>{let{turnstile:e}=window;return{getResponse:()=>(null==e?void 0:e.getResponse)&&j.current&&K()?e.getResponse(j.current):void console.warn("Turnstile has not been loaded"),async getResponsePromise(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:3e4,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:100;return new Promise((n,r)=>{let o,i=async()=>
1{if(U.current&&window.turnstile&&j.current)try{let e=window.turnstile.getResponse(j.current);return o&&clearTimeout(o),e?n(e):r(Error("No response received"))}catch(e){return o&&clearTimeout(o),console.warn("Failed to get response",e),r(Error("Failed to get response"))}o||(o=setTimeout(()=>{o&&clearTimeout(o),r(Error("Timeout"))},e)),await new Promise(e=>setTimeout(e,t)),await i()};i()})},reset(){if(!(null==e?void 0:e.reset)||!j.current||!K())return void console.warn("Turnstile has not been loaded");"execute"===r.execution&&D(f.invisible);try{U.current=!1,e.reset(j.current)}catch(e){console.warn("Failed to reset Turnstile widget ".concat(j),e)}},remove(){if(!(null==e?void 0:e.remove)||!j.current||!K())return void console.warn("Turnstile has not been loaded");D(f.invisible),U.current=!1,e.remove(j.current),j.current=null},render(){if(!(null==e?void 0:e.render)||!S.current||!K()||j.current)return void console.warn("Turnstile has not been loaded or container not found");let t=e.render(S.current,H);return j.current=t,j.current&&(null==v||v(j.current)),"execute"!==r.execution&&D(L?f[L]:{}),t},execute:()=>"execute"!==r.execution?void console.warn('Execution mode is not set to "execute"'):(null==e?void 0:e.execute)&&S.current&&j.current&&K()?void(e.execute(S.current,H),D(L?f[L]:{})):void console.warn("Turnstile has not been loaded or container not found"),isExpired:()=>(null==e?void 0:e.isExpired)&&j.current&&K()?e.isExpired(j.current):(console.warn("Turnstile has not been loaded"),!1)}},[j,r.execution,L,H,S,K,A,v]),(0,o.useEffect)(()=>{z&&!A&&window.turnstile&&P(!0)},[A,z]),(0,o.useEffect)(()=>{D(_())},[r.execution,L,q]),(0,o.useEffect)(()=>{z&&"function"==typeof k&&k()},[z]),(0,i.jsx)(c,{ref:S,as:I,id:B,style:{...F,...R},...O})});v.displayName="Turnstile"}}]);
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.