1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6121,9235],{4140:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},4388:(e,t)=>{"use strict";t.Headers=self.Headers,t.Request=self.Request,t.Response=self.Response,t.fetch=self.fetch},47333:(e,t,a)=>{a(4388),e.exports=self.fetch.bind(self)},56121:(e,t,a)=>{e.exports=a(61847)()},61847:(e,t,a)=>{"use strict";var l=a(4140);function n(){}function r(){}r.resetWarningCache=n,e.exports=function(){function e(e,t,a,n,r,s){if(s!==l){var i=Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw i.name="Invariant Violation",i}}function t(){return e}e.isRequired=e;var a={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:r,resetWarningCache:n};return a.PropTypes=a,a}},99327:(e,t,a)=>{"use strict";a.r(t),a.d(t,{AppConfigProvider:()=>h,getCachedSubicha:()=>b,getGlobalConfig:()=>g,useAppConfig:()=>v});var l=a(6029),n=a(55729),r=a(56121),s=a.n(r),i=a(42730),o=a(37738);let u=(0,n.createContext)(),c={versionCaptcha:3,isLoading:!0,isSuccess:!1,openResale:!1,isInitialized:!1,error:null,lastFetched:null,enableYearEndRecap:!0},d=new Map,p=new Set,f=e=>{c={...c,...e},p.forEach(e=>e(c))},h=e=>{let{children:t}=e,a=(0,o.d4)(e=>e.user||{}),[r,s]=(0,n.useState)(c);(0,n.useEffect)(()=>(p.add(s),()=>{p.delete(s)}),[]);let h=(0,n.useCallback)(async function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=Date.now();if(!(!c.isInitialized||e||c.lastFetched&&t-c.lastFetched>3e5))return s(c),Promise.resolve(c);try{var a,l,n,r,o,u,p,h,v,g;f({isLoading:!0,error:null});let e=await (0,i.Fe)("/event/api/v1/applications/initialize",{platform:"web"},{"x-tb-skip-auth":!0},"https://api-v2.ticketbox.vn",0,null,null),s={...(null==e||null==(a=e.data)?void 0:a.result)||{},versionCaptcha:(null==e?void 0:e.status)===1&&(null==e||null==(n=e.data)||null==(l=n.result)?void 0:l.version)?e.data.result.version:3,isLoading:!1,isSuccess:(null==e?void 0:e.status)===1,openResale:!!(null==e||null==(o=e.data)||null==(r=o.result)?void 0:r.resaleFlag),isInitialized:!0,error:null,lastFetched:t,enableYearEndRecap:!!(null==e||null==(h=e.data)||null==(p=h.result)||null==(u=p.yearEndRecap)?void 0:u.enabled)};if(f(s),(null==e?void 0:e.status)===1&&(null==e||null==(g=e.data)||null==(v=g.result)?void 0:v.subicha)){let a=e.data.result.subicha;d.clear(),a.forEach(e=>{d.set(e.id,{gif:e.gif,gif2:e.gif2,cachedAt:t})})}return c}catch(e){return f({isLoading:!1,isSuccess:!1,error:e.message||"Failed to fetch app configuration",isInitialized:!0,lastFetched:t,enableYearEndRecap:!1}),c}},[]);(0,n.useEffect)(()=>{if(a.checking)return;let e=setTimeout(()=>{h()},0);return()=>clearTimeout(e)},[h,a.checking]);let v=(0,n.useMemo)(()=>({...r,refetch:h,clearCache(){d.clear(),f({isInitialized:!1,lastFetched:null})}}),[r,h]);return(0,l.jsx)(u.Provider,{value:v,children:t})},v=()=>{let e=(0,n.useContext)(u);if(!e)throw Error("useAppConfig must be used within an AppConfigProvider");return e},g=()=>c,b=()=>d;h.propTypes={children:s().node.isRequired}}}]);
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.