1;!function(){try { var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof global?global:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&((e._debugIds|| (e._debugIds={}))[n]="2a7151a4-68a8-0698-f85b-0560eda40596")}catch(e){}}(); 2(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,38062,144796,579668,710017,651431,15541,e=>{"use strict";var t=e.i(843476),r=e.i(271645),n=e.i(618566),i=e.i(861745),o=e.i(912598),s=e.i(146523);e.i(90008);var a=e.i(375242),u=e.i(85609),l=e.i(420671);e.i(962663);var h=e.i(988890),c=e.i(32692),m=e.i(626634);e.i(536419),e.i(293491),e.i(616746);var p=e.i(706364);e.i(80194);var g=e.i(946466);let d=new Set(["UNAVAILABLE"]),f="vtvgo.mergeTicket.v1";function y(){try{let e=localStorage.getItem(f);if(!e)return null;let t=JSON.parse(e);if("string"!=typeof t.ticket||!t.ticket)return null;return t}catch(e){return null}}function E(e){try{localStorage.setItem(f,JSON.stringify(e))}catch(e){}v()}function b(){try{localStorage.removeItem(f)}catch(e){}v()}let T="vtvgo:merge-ticket";function v(){try{window.dispatchEvent(new Event(T))}catch(e){}}function S(e){switch(e){case c.GUEST_ORDER_STATUS.PENDING:return"pending";case c.GUEST_ORDER_STATUS.PAID:return"paid";case c.GUEST_ORDER_STATUS.GRANTED:case c.GUEST_ORDER_STATUS.FULFILLED:return"success";case c.GUEST_ORDER_STATUS.FAILED:case c.GUEST_ORDER_STATUS.CANCELLED:return"error";default:return null}}e.s(["MERGE_TICKET_EVENT",0,T,"MERGE_TICKET_STORAGE_KEY",0,f,"claimMergeAttempt",0,function(e){let t=y();return!(!t||t.ticket!==e||t.attemptedAt&&Date.now()-t.attemptedAt<3e4)&&(E({...t,attemptedAt:Date.now()}),!0)},"clearMergeTicket",0,b,"readMergeTicket",0,y,"releaseMergeAttempt",0,function(){let e=y();(null==e?void 0:e.attemptedAt)&&E({...e,attemptedAt:void 0})},"saveMergeTicket",0,E],144796),e.s(["useGuestPaymentStatus",0,function(e){let{orderID:t,deviceID:n,expireTime:i,enabled:o=!0}=e,[s,a]=(0,r.useState)("idle"),[u,l]=(0,r.useState)(null),h=(0,r.useRef)(i);return h.current=i,(0,r.useEffect)(()=>{if(!o||!t||!n){a("idle"),l(null);return}let e=!1,r=!1,i=!1;a("pending");let s=(e,o,s,a)=>{var u;if(!i&&!r&&"string"==typeof e&&e){if((null==(u=y())?void 0:u.ticket)===e){i=!0;return}i=!0,E({orderID:s||t,deviceID:n,userID:a,ticket:e,receivedAt:Date.now()}),p.logger.info("state","payment:guest:merge-ticket-received",{orderID:t,via:o})}},u=t=>{r||e||(("success"===t||"error"===t||"expired"===t)&&(e=!0),a(t))},c=function(e){let{orderID:t,deviceID:r,onStatus:n,onCredential:i,onFatalError:o}=e,s=`${r}-${t}`,a=null,u=!1,l=null,h=null,c=0;function m(){let e;if(!u){try{e=new WebSocket(`${(0,g.getServiceBaseUrl)("payment").replace(/^http/,"ws")}/ws/order-status`)}catch(e){p.logger.warn("http","payment:order-ws:open-fail",void 0,e),y();return}a=e,e.onopen=()=>{c=0,e.send(JSON.stringify({action:"subscribe",topic:s,deviceID:r})),l=setInterval(()=>{e.readyState===WebSocket.OPEN&&e.send(JSON.stringify({action:"ping"}))},3e4)},e.onmessage=e=>{var r,s;let a;try{a=JSON.parse(String(e.data))}catch(e){return}let l=a.type;if("pong"===l)return;if("error"===l){let e=String(null!=(r=a.code)?r:"");p.logger.warn("http","payment:order-ws:error-frame",{code:e}),d.has(e)||(u=!0,f(),null==o||o(e));return}if("credential"===l){let e=a.accessToken;"string"==typeof e&&e&&i({orderID:String(null!=(s=a.orderID)?s:t),userID:null!=a.userID?String(a.userID):void 0,accessToken:e,expiresIn:"number"==typeof a.expiresIn?a.expiresIn:void 0});return}let h=a.status;"string"==typeof h&&n(h)},e.onclose=()=>{f(),y()},e.onerror=()=>{}}}function f(){if(l&&(clearInterval(l),l=null),a){if(a.onopen=a.onmessage=a.onclose=a.onerror=null,a.readyState===WebSocket.OPEN||a.readyState===WebSocket.CONNECTING)try{a.close()}catch(e){}a=null}}function y(){if(u||h)return;let e=Math.min(1e3*2**c,15e3);c+=1,h=setTimeout(()=>{h=null,m()},e)}return m(),()=>{if(u=!0,h&&(clearTimeout(h),h=null),a&&a.readyState===WebSocket.OPEN)try{a.send(JSON.stringify({action:"unsubscribe",topic:s}))}catch(e){}f()}}({orderID:t,deviceID:n,onStatus:e=>{let t=S(e);t&&"idle"!==t&&u(t)},onCredential:e=>{s(e.accessToken,"ws",e.orderID,e.userID)},onFatalError:e=>{p.logger.warn("http","payment:guest:ws-fatal",{code:e,orderID:t})}}),f=setInterval(async()=>
2{if(!e&&!r)try{let e=await (0,m.checkGuestOrder)(t,n);s(e.accessToken,"poll",e.orderID,e.userID);let r=S(e.status);r&&"idle"!==r&&u(r)}catch(e){}},5e3),b=null,T=h.current;if(T&&T>0){let e=Date.now()+1e3*T;l(T),b=setInterval(()=>{let t=Math.max(0,Math.round((e-Date.now())/1e3));l(t),t<=0&&(b&&(clearInterval(b),b=null),u("expired"))},1e3)}return()=>{r=!0,c(),clearInterval(f),b&&clearInterval(b)}},[o,t,n]),{status:s,secondsLeft:u}}],579668);var I=e.i(130750),A=e.i(801750),H=e.i(847924);let w=e=>new Promise(t=>setTimeout(t,e));async function B(e,t){let r=!1;for(let n=0;!r;n++)try{await (0,A.mergeTempAccount)({accessToken:e,tempAccessToken:t.ticket}),r=!0}catch(e){if(e instanceof I.AuthV2Error&&"source_locked"===e.code)r=!0;else if(e instanceof I.AuthV2Error&&503===e.status&&n<3)await w(1e3);else throw e}await w(1e3);let n=await (0,H.refreshAuthV2Session)(e);return b(),p.logger.info("state","payment:guest:merge-done",{orderID:t.orderID}),n}function P(e){let t=null==e.userId?void 0:String(e.userId),r=y();r&&"temp-account"!==r.source?p.logger.warn("state","payment:temp-account:kept-guest-ticket",{userID:t,ticketUserID:r.userID}):(E({orderID:"",deviceID:function(){try{return(0,u.getCurrentAuthV2DeviceId)()}catch(e){return""}}(),userID:t,ticket:e.accessToken,receivedAt:Date.now(),source:"temp-account"}),p.logger.info("state","payment:temp-account:ticket-saved",{userID:t}))}e.s(["runAccountMerge",0,B],710017),e.s([],651431);var _=e.i(57581),N=e.i(984476),R=e.i(157773);let D=[R.LEGACY_TOKEN_COOKIE,R.LEGACY_DATA_STORE_COOKIE,"authTemporaryData","dataApiConfig","dataPartnerConfig","globalSession","webviewSession","authCode","paymentCode","storage","clientId"];function M(e){if("u"<typeof document)return;let t=document.cookie.match(RegExp(`(?:^|; )${e}=([^;]*)`));return t?decodeURIComponent(t[1]):void 0}function L(){if("u">typeof document){for(let e of D)document.cookie=`${e}=; path=/; max-age=0`;try{for(let e of Object.keys(localStorage))e.startsWith("vtvgo-banner_")&&localStorage.removeItem(e)}catch(e){}}}let O=null;var C=e.i(111483);let z="vtvgo.auth.loginProvider";function k(){try{localStorage.removeItem(z)}catch(e){}}e.s(["forgetLoginProvider",0,k,"readLoginProvider",0,function(){try{var e;return null!=(e=localStorage.getItem(z))?e:void 0}catch(e){return}},"rememberLoginProvider",0,function(e){try{localStorage.setItem(z,e)}catch(e){}}],15541);let F={setUser:()=>void 0,setFirebaseUserId:()=>void 0,trackLogin:()=>(0,C.track)("user_login",{}),trackLogout:()=>(0,C.track)("user_logout",{})};e.s(["AuthProvider",0,function(e){let{children:c}=e,m=(0,o.useQueryClient)(),g=(0,n.useRouter)(),d=(0,i.useLocale)(),f=(0,r.useRef)(null);f.current||(f.current=(0,a.createAuthStore)({queryClient:m,analytics:F,onServerLogout:async()=>{await fetch("/api/auth/logout",{method:"POST"})},onLoggedOut:()=>{k(),g.push("/")},onLeavingTempPurchaseSession:P,initialDataStore:{}}));let y=f.current;return(0,h.useIdentityBoot)(y,m),(0,r.useEffect)(()=>{let e=e=>{"authChange"===e.key&&y.getState().hydrateFromStorage()};return window.addEventListener("storage",e),()=>window.removeEventListener("storage",e)},[y]),(0,r.useEffect)(()=>{y.getState().hydrateFromStorage(),(async()=>{try{let e=await ("u"<typeof document?Promise.resolve(null):O||(O=(async()=>{let e;if(M(R.TOKEN_COOKIE))return null;let t=M(R.LEGACY_TOKEN_COOKIE),r=function(){let e=M(R.LEGACY_DATA_STORE_COOKIE);if(!e)return;let t=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"cI7FZ7BUkXz";try{let r=atob(e).match(/.{1,2}/g);if(!r)return"";let n=r.map((e,r)=>(parseInt(e,16)^t.charCodeAt(r%t.length)).toString(16).padStart(2,"0")).join("").match(/.{1,2}/g);return n?decodeURIComponent("%"+n.join("%")):""}catch(e){return""}}(e);if(t)try{return JSON.parse(t)}catch(e){return}}();if(!t&&!r)return null;if(!t||(null==r?void 0:r.userType)!=="normal")return p.logger.info("state","auth:legacy-migration:skip",{userType:null==r?void 0:r.userType}),L(),null;try{e=(0,u.getCurrentAuthV2DeviceId)()}catch(e){return p.logger.warn("state","auth:legacy-migration:no-device-id",void 0,e),null}try{p.logger.info("state","auth:legacy-migration:start");let r=await (0,N.exchangeLegacyToken)({legacyAccessToken:t,deviceId:e}),n=await (0,N.getAuthV2Profile)(r.access_token),i=(0,H.toSession)(r,n);return L(),p.logger.info("state","auth:legacy-migration:success",{userId:i.userInfo.id}),{accessToken:i.accessToken,refreshToken:i.refreshToken,expiresIn:i.expiresIn,userInfo:i.userInfo}}catch(e){if(e instanceof I.AuthV2Error&&0===e.status)return p.logger.warn("state","auth:legacy-migration:network-fail"),null;if(e instanceof I.AuthV2Error&&409===e.status){if(await new Promise(e=>setTimeout(e,2e3)),M(R.TOKEN_COOKIE))return p.logger.info("state","auth:legacy-migration:adopted-other-tab"),L(),null;return p.logger.warn("state","auth:legacy-migration:conflict-lost"),L(),null}return p.logger.warn("state","auth:legacy-migration:rejected",void 0,e),L(),null}})().finally(()=>{O=null})));if(e)return void y.getState().login(e);await y.getState().bootstrap()}finally{y.getState().markBootstrapped()}})()},[y]),(0,r.useEffect)(()=>{var e;let t=e=>
2(0,l.applySentryUserScope)(s,{deviceId:(0,u.getCurrentAuthV2DeviceId)(),userId:null!=e?String(e):void 0,language:d});return t(null==(e=y.getState().userInfo)?void 0:e.id),y.subscribe((e,r)=>{var n,i,o;(null==(n=e.userInfo)?void 0:n.id)!==(null==(i=r.userInfo)?void 0:i.id)&&t(null==(o=e.userInfo)?void 0:o.id)})},[y,d]),(0,t.jsx)(_.AuthStoreContext.Provider,{value:y,children:c})}],38062)},86073,51748,988890,87506,e=>{"use strict";let t;e.i(80194);var r=e.i(57581),n=e.i(750235);e.s(["useIdentity",0,function(){let e=(0,r.useAuthStore)(e=>e.hydrated),t=(0,r.useAuthStore)(e=>e.authenticated),i=(0,n.useGetMeQuery)(e&&t);if(!e)return{status:"pending",authenticated:!1,me:void 0,adFree:!1,isPaid:!1};if(!t)return{status:"guest",authenticated:!1,me:void 0,adFree:!1,isPaid:!1};if(i.isSuccess){var o,s;let e=(null!=(s=null==(o=i.data)?void 0:o.plans.length)?s:0)>0;return{status:"ready",authenticated:!0,me:i.data,adFree:e,isPaid:e}}return{status:i.isError?"error":"pending",authenticated:!0,me:void 0,adFree:!1,isPaid:!1}}],86073),e.s([],51748);var i=e.i(271645),o=e.i(408155),s=e.i(768834),a=e.i(950067),u=e.i(640411),l=e.i(614121),h=e.i(706364);e.i(90008);var c=e.i(847924),m=e.i(967730),p=e.i(641277),g=e.i(996268),d=e.i(317136);let f=(0,o.createStore)(()=>({done:!1,outcome:null})),y=!1;function E(){t&&clearTimeout(t),t=void 0,y=!1}function b(e){return e.fetchQuery({queryKey:p.accountKeys.me,queryFn:m.getMe,staleTime:a.ME_CACHE_TTL_MS,retry:!1})}function T(e){return{outcome:"ready",isPaid:e.plans.length>0,tempUserType:e.tempUserType,profile:{id:e.id,username:e.email||e.phone||void 0,displayName:e.displayName||e.fullName||void 0,phone:e.phone||void 0}}}async function v(e,t){var r;if(await ((r=e=>e.hydrated&&e.bootstrapped)(t.getState())?Promise.resolve():new Promise(e=>{let n=t.subscribe(t=>{r(t)&&(n(),e())})})),!t.getState().authenticated)return{outcome:"guest"};let n=(0,u.getAuthToken)();try{return T(await b(e))}catch(e){if(h.logger.warn("state","identity:me-failed",void 0,e),(0,u.getAuthToken)()!==n)return{outcome:"error"}}if(!t.getState().authenticated)return{outcome:"logged-out"};let i=(0,u.getAuthToken)();if(!i)return{outcome:"logged-out"};try{h.logger.info("state","identity:refresh-and-retry"),await (0,c.refreshAuthV2Session)(i)}catch(e){if((0,l.isSessionRefreshRejected)(e))return h.logger.warn("state","identity:session-over",void 0,e),t.getState().authenticated&&await t.getState().logout(),{outcome:"logged-out"};return h.logger.warn("state","identity:refresh-failed",void 0,e),{outcome:"error"}}if(void 0===(0,a.peekMeCached)())return{outcome:"error"};try{return T(await b(e))}catch(e){return h.logger.warn("state","identity:me-failed-after-refresh",void 0,e),{outcome:"error"}}}async function S(e){var r;let n,{queryClient:i,authStore:o}=e,s=null!=(r=e.timeoutMs)?r:3e3,a=e=>("ready"===e.outcome&&o.getState().syncEntitlement({isPaid:e.isPaid,tempUserType:e.tempUserType,profile:e.profile}),"error"===e.outcome&&function(e,r,n){if(y)return;y=!0;let i=async()=>{if(t=void 0,!r.getState().authenticated)return void E();try{let t=n(T(await b(e)));h.logger.info("state","identity:me-recovered"),f.setState({done:!0,outcome:t}),E()}catch(e){h.logger.warn("state","identity:me-retry-failed",void 0,e),y&&(t=setTimeout(i,3e3))}};t=setTimeout(i,3e3)}(i,o,a),e.outcome),u=v(i,o),l=new Promise(e=>{n=setTimeout(()=>e("timeout"),s)}),c=await Promise.race([u,l]);if("timeout"===c)return h.logger.warn("state","identity:timeout",{timeoutMs:s}),f.setState({done:!0,outcome:"timeout"}),u.then(a).catch(()=>void 0),"timeout";clearTimeout(n);let m=a(c);return h.logger.info("state","identity:settled",{outcome:m}),f.setState({done:!0,outcome:m}),m}e.s(["useIdentityBoot",0,function(e,t,r){let n=(0,i.useRef)(!1);(0,i.useEffect)(()=>{let r;return r=r=>{let{accessToken:n,profile:i}=r.detail;if((0,u.getAuthToken)()!==n||!e.getState().authenticated||(e.getState().hydrateFromStorage(),!i))return;let o=d.MeResponseSchema.safeParse(i);if(!o.success)return;let s=o.data;(0,u.persistSegmentId)(s.userType),t.setQueryData(p.accountKeys.me,s),e.getState().syncEntitlement({isPaid:s.plans.length>0})},window.addEventListener(g.AUTH_SESSION_UPDATED,r),e.getState().hydrateFromStorage(),(
2)=>window.removeEventListener(g.AUTH_SESSION_UPDATED,r)},[e,t]),(0,i.useEffect)(()=>{n.current||f.getState().done||(n.current=!0,S({queryClient:t,authStore:e,timeoutMs:r}))},[e,t,r])},"useIdentityBootDone",0,function(){return(0,s.useStore)(f,e=>e.done)}],988890),e.s(["invalidateMe",0,function(e){(0,a.invalidateMeCache)(),e.invalidateQueries({queryKey:p.accountKeys.me})}],87506)},750235,580588,317136,967730,641277,e=>{"use strict";var t=e.i(266027);e.i(80194);var r=e.i(950067),n=e.i(499146),i=e.i(705599),o=e.i(614121),s=e.i(640411),a=e.i(946466),u=e.i(681307),l=e.i(392664),h=e.i(863429);let c=new Intl.DateTimeFormat("vi-VN",{timeZone:h.VN_TIME_ZONE,hour:"2-digit",minute:"2-digit",day:"2-digit",month:"2-digit",year:"numeric",hour12:!1});function m(e){if("string"==typeof e)return e;if(!Number.isFinite(e)||e<=0)return"";let t=c.formatToParts(new Date(e)),r=e=>{var r,n;return null!=(r=null==(n=t.find(t=>t.type===e))?void 0:n.value)?r:""},n=`${r("hour")}:${r("minute")}`,i=`${r("day")}/${r("month")}/${r("year")}`;return`${n} ${i}`}e.s(["transactionTimeLabel",0,m],580588);let p=u.z.string().nullish().transform(e=>null!=e?e:""),g=u.z.union([u.z.boolean(),u.z.number()]).nullish().transform(e=>null!=e&&("number"==typeof e?0!==e:e)),d=u.z.preprocess(l.withTempUserType,u.z.object({id:u.z.union([u.z.string(),u.z.number()]),displayName:p,email:p,fullName:p,phone:p,isSubscription:g.optional(),isTempUser:g,tempUserType:l.tempUserTypeField,plans:u.z.array(u.z.string()).nullish().transform(e=>null!=e?e:[]),userType:u.z.string().nullish(),ip:u.z.string().nullish()})),f=u.z.object({auth_type:u.z.string().optional(),current:u.z.boolean().default(!1),device_id:u.z.string(),device_name:u.z.string().optional(),expires_at_unix:u.z.number().int().optional(),ip:u.z.string().optional(),last_seen_at_unix:u.z.number().int().optional(),platform:u.z.string().optional(),started_at_unix:u.z.number().int().optional()}).transform(e=>{var t,r,n,i,o,s;return{authType:null!=(t=e.auth_type)?t:null,current:e.current,deviceId:e.device_id,deviceName:null!=(r=e.device_name)?r:"",expiresAtUnix:null!=(n=e.expires_at_unix)?n:null,ip:null!=(i=e.ip)?i:null,lastAccessedAt:e.last_seen_at_unix?new Date(1e3*e.last_seen_at_unix).toISOString():null,platform:null!=(o=e.platform)?o:null,startedAtUnix:null!=(s=e.started_at_unix)?s:null}}),y=u.z.object({next_cursor:u.z.string().optional(),projected_through_unix:u.z.number().int().optional(),projection_status:u.z.enum(["FRESH","STALE"]).optional(),sessions:u.z.array(f).default([])}),E=u.z.object({result:u.z.string()}),b=u.z.object({createdAt:u.z.union([u.z.string(),u.z.number()]).default("").transform(m),createdAtMilis:u.z.number().int().optional(),index:u.z.number().int().optional(),isSuccess:u.z.number().int().optional(),note:u.z.string().default(""),paymentMethodName:u.z.string().default(""),planName:u.z.string().default(""),price:u.z.string().default(""),promotionInfo:u.z.array(u.z.string()).default([]),purchaseDuration:u.z.string().default(""),status:u.z.string().default(""),transID:u.z.string().default(""),image:u.z.string().optional()}),T=u.z.object({page:u.z.number().int().positive(),limit:u.z.number().int().positive(),total:u.z.number().int().nonnegative(),totalPages:u.z.number().int().nonnegative()}),v=u.z.object({items:u.z.array(b),meta:T}),S=u.z.object({planID:u.z.string(),planName:u.z.string().default(""),timePlanName:u.z.string().default(""),expiredAt:u.z.string().default(""),durationLabel:u.z.string().default(""),image:u.z.string().default(""),imageDetail:u.z.string().default(""),isAutoRenew:u.z.boolean().default(!1),isCancelled:u.z.boolean().default(!1),latestTransID:u.z.string().default("")}),I=u.z.object({active:u.z.array(S).default([]),expired:u.z.array(S).default([])});S.extend({descriptions:u.z.array(u.z.string()).default([]),maxDeviceLogin:u.z.number().int().default(0),maxDeviceStream:u.z.number().int().default(0),allowBuy:u.z.boolean().default(!1),btnAction:u.z.number().int().default(0),messageContent:u.z.string().default(""),externalPurchaseID:u.z.string().default("")}),e.s(["MeResponseSchema",0,d,"PurchasedPlansSchema",0,I,"SessionListSchema",0,y,"SessionRemovalSchema",0,E,"TransactionHistoryPageSchema",0,v],317136);let A=u.z.unknown();async function H(e){let t,r=e.query?`?${new URLSearchParams(e.query)}`:"";try{t=await (0,o.fetchWithSessionRefresh)(`${(0,a.getServiceBaseUrl)("user")}${e.path}${r}`,{method:e.method},{replayOn401:e.replayOn401})}catch(e){throw new n.ApiError(n.GENERIC_ERROR_MESSAGE,{status:0,co
2de:"NETWORK_ERROR"})}let i=await t.json().catch(()=>null);if(!t.ok){var s,u,l,h,c,m;let e=null!=i?i:{},r="object"==typeof e.error&&null!==e.error?e.error:void 0;throw new n.ApiError((null==r?void 0:r.message)||e.message||n.GENERIC_ERROR_MESSAGE,{status:t.status,code:null!=(s=null==r?void 0:r.code)?s:"string"==typeof e.error?e.error:void 0,traceId:null!=(u=null!=(l=null!=(h=null==r?void 0:r.traceID)?h:e.traceID)?l:null==(m=t.headers)||null==(c=m.get)?void 0:c.call(m,"x-request-id"))?u:void 0})}return e.schema.parse(i)}async function w(){let e=await (0,r.readMeCached)(async()=>{try{return await H({method:"GET",path:"/user/me",schema:A,replayOn401:!1})}catch(t){if(!(t instanceof n.ApiError)||401!==t.status)throw t;let e=(0,r.peekMeCached)();if(void 0===e)throw t;return A.parse(e)}}),t=d.parse(e);return(0,s.persistSegmentId)(t.userType),t}async function B(){let e,t=[],r=new Set;do{let n=await H({method:"GET",path:"/auth/sessions",query:{limit:"50",...e?{cursor:e}:{}},schema:y});if(t.push(...n.sessions),(e=n.next_cursor)&&r.has(e))break;e&&r.add(e)}while(e)return t}async function P(e){return H({method:"DELETE",path:"/auth/sessions",query:{device_id:e},schema:E})}async function _(){let e=(0,s.getAuthToken)(),t=await (0,i.request)({route:{service:"payment",path:"/payment-purchase/payment-histories-display",auth:"optional"},method:"get",params:{page:1,limit:100},...e?{token:e}:{}});if(!t.success)throw(0,n.apiError)(t);return v.parse({items:t.result,meta:t.meta})}async function N(){var e;let t=(0,s.getAuthToken)(),r=await (0,i.request)({route:{service:"payment",path:"/payment-purchase/purchased-plans",auth:"optional"},method:"get",params:{platform:(0,a.getPlatformName)()},...t?{token:t}:{}});if(!r.success)throw(0,n.apiError)(r);return I.parse(null!=(e=r.result)?e:{})}e.s(["getMe",0,w,"getPurchasedPlans",0,N,"getSessions",0,B,"getTransactionHistory",0,_,"removeSession",0,P],967730);let R={me:["account","me"],sessions:["account","sessions"],transactions:["account","transactions"],purchasedPlans:["account","purchased-plans"],purchasedPlanDetail:e=>["account","purchased-plans",e]};e.s(["accountKeys",0,R],641277),e.s(["useGetMeQuery",0,function(){let e=!(arguments.length>0)||void 0===arguments[0]||arguments[0];return(0,t.useQuery)({queryKey:R.me,queryFn:w,enabled:e,staleTime:r.ME_CACHE_TTL_MS,retry:!1})}],750235)},834239,711193,615224,817460,e=>{"use strict";var t=e.i(266027),r=e.i(967730),n=e.i(641277);e.s(["useSessionsQuery",0,function(){return(0,t.useQuery)({meta:{errorDialog:!0},queryKey:n.accountKeys.sessions,queryFn:r.getSessions,staleTime:6e4})}],834239);var i=e.i(954616),o=e.i(912598);e.s(["useRemoveSessionMutation",0,function(){let e=(0,o.useQueryClient)();return(0,i.useMutation)({mutationFn:e=>(0,r.removeSession)(e),onSuccess:async()=>{await new Promise(e=>setTimeout(e,1e3)),await e.invalidateQueries({queryKey:n.accountKeys.sessions,refetchType:"active"})}})}],711193),e.i(80194);var s=e.i(640411);e.i(90008);var a=e.i(130750),u=e.i(923452),l=e.i(57581);e.s(["useLogoutOtherDevicesMutation",0,function(){let e=(0,o.useQueryClient)(),{replaceAccessToken:t}=(0,l.useAuth)();return(0,i.useMutation)({mutationFn:async()=>{let e=(0,s.getAuthToken)();if(!e)throw Error("Phiên ÄÄng nháºp không hợp lá»");try{return await (0,u.logoutOtherDevices)(e)}catch(e){if(e instanceof a.AuthV2Error)throw Error((0,a.authV2ErrorMessage)(e));throw e}},onSuccess:async r=>{t(r.access_token,r.expires_in),await new Promise(e=>setTimeout(e,u.SESSION_PROJECTION_DELAY_MS)),await e.invalidateQueries({queryKey:n.accountKeys.sessions,refetchType:"active"})}})}],615224),e.s(["useLogoutAllDevicesMutation",0,function(){let{logout:e}=(0,l.useAuth)();return(0,i.useMutation)({mutationFn:async()=>{let t=(0,s.getAuthToken)();if(!t)throw Error("Phiên ÄÄng nháºp không hợp lá»");try{await (0,u.logoutAllDevices)(t)}catch(e){if(e instanceof a.AuthV2Error)throw Error((0,a.authV2ErrorMessage)(e));throw e}await e()}})}],817460)},962663,571964,175107,e=>{"use strict";e.i(580588),e.i(317136);var t=e.i(967730);e.i(750235),e.i(86073),e.i(51748),e.i(988890),e.i(87506),e.i(834239),e.i(711193),e.i(615224),e.i(817460);var r=e.i(266027),n=e.i(641277);e.s(["useTransactionHistoryQuery",0,function(){let e=!(arguments.length>0)||void 0===arguments[0]||arguments[0];return(0,r.useQuery)({meta:{errorDialog:!0},queryKey:n.accountKeys.transactions,queryFn:t.getTransactionHistory,staleTime:6e4,enabled:e})}],571964),e.s(["usePurchasedPlansQuery",0,function(){let e=!(arguments.length>0)||void 0===arguments[0]||arguments[0];return(0,r.useQuery)({meta:{errorDialog:!0},queryKey:n.accountKeys.purchasedPlans,queryFn:t.getPurchasedPlans,staleTime:6e4,enabled:e})}],175107),e.s([],962663)},536419,e=>{"use strict";var t=e.i(954616),r=e.i(912598);e.i(80194);var n=e.i(950067),i=e.i(626634);e.s(["useCreatePaymentMutation",0,function(){return(0,t.useMutation)({mutationFn:e=>(0,i.createPayment)(e)})},"useUnbindAutoRenewMutation",0,function(){let e=(0,r.useQueryClient)();return(0,t.useMutation)({mutationFn:e=>(0,i.unbindAutoRenew)(e),onSuccess:()=>
2{(0,n.invalidateMeCache)(),e.invalidateQueries({queryKey:["account"]})}})}])},293491,e=>{"use strict";var t=e.i(266027);e.i(80194);var r=e.i(499146),n=e.i(626634);let i=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return["payment","plans",e]};e.s(["usePaymentMethodsQuery",0,function(e,r){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return(0,t.useQuery)({meta:{errorDialog:!0},queryKey:["payment","methods",null!=e?e:"",null!=r?r:""],queryFn:()=>(0,n.getPaymentMethods)(e,r),enabled:!1!==i.enabled&&!!e&&!!r,staleTime:3e5})},"usePlanDetailQuery",0,function(e){let r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return(0,t.useQuery)({meta:{errorDialog:!0},queryKey:["payment","plan-detail",null!=e?e:""],queryFn:()=>(0,n.getPlanDetail)(e),enabled:!1!==r.enabled&&!!e,staleTime:3e5})},"usePlansQuery",0,function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return(0,t.useQuery)({meta:{errorDialog:!0},queryKey:i(e),queryFn:()=>(0,n.getPlans)(e),enabled:!1!==r.enabled,staleTime:3e5})},"useRequiredPlansQuery",0,function(e){let i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return(0,t.useQuery)({meta:{errorDialog:!0},queryKey:["payment","required-plans",null!=e?e:""],queryFn:()=>(0,n.getRequiredPlans)(e),enabled:!1!==i.enabled&&!!e,staleTime:3e5,refetchOnMount:e=>!(0,r.isDefinitiveApiError)(e.state.error),refetchOnReconnect:e=>!(0,r.isDefinitiveApiError)(e.state.error)})},"useTimePlansQuery",0,function(e){let r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return(0,t.useQuery)({meta:{errorDialog:!0},queryKey:["payment","time-plans",null!=e?e:""],queryFn:()=>(0,n.getTimePlans)(e),enabled:!1!==r.enabled&&!!e,staleTime:3e5})}],293491)},616746,e=>{"use strict";var t=e.i(271645);e.i(80194);var r=e.i(204831),n=e.i(640411);e.i(90008);var i=e.i(85609),o=e.i(626634),s=e.i(32692);e.s(["usePaymentStatus",0,function(e){let{transId:a,expireTime:u,enabled:l=!0}=e,[h,c]=(0,t.useState)("idle"),[m,p]=(0,t.useState)(null),g=(0,t.useRef)(u);g.current=u;let d=(0,t.useRef)(null);return(0,t.useEffect)(()=>{var e;if(!l||!a){c("idle"),p(null);return}let t=!1,u=!1,h=d.current;(null==h?void 0:h.transId)===a&&(clearTimeout(h.timer),d.current=null),c("pending");let m=e=>{t||u||(t=!0,c(e))},f=(0,r.connectNotificationSocket)({deviceId:(0,i.getCurrentAuthV2DeviceId)(),accessToken:null!=(e=(0,n.getAuthToken)())?e:void 0,onPayment:e=>{let{status:t,transId:r}=e;r&&a&&r!==a||(t===s.PAYMENT_SOCKET_STATUS.SUCCESS?m("success"):t===s.PAYMENT_SOCKET_STATUS.ERROR&&m("error"))}}),y=setInterval(async()=>{if(!t&&!u)try{let e=await (0,o.checkTransaction)(a);e.status===s.TXN_STATUS.SUCCESS?m("success"):e.status===s.TXN_STATUS.ERROR&&m("error")}catch(e){}},5e3),E=null,b=g.current;if(b&&b>0){let e=Date.now()+1e3*b;p(b),E=setInterval(()=>{let r=Math.max(0,Math.round((e-Date.now())/1e3));p(r),r<=0&&(E&&(clearInterval(E),E=null),t||((0,o.cancelPayment)(a),m("expired")))},1e3)}return()=>{if(u=!0,f(),clearInterval(y),E&&clearInterval(E),!t){let e=setTimeout(()=>{var t;(0,o.cancelPayment)(a),(null==(t=d.current)?void 0:t.timer)===e&&(d.current=null)},0);d.current={transId:a,timer:e}}}},[l,a]),{status:h,secondsLeft:m}}])},32692,626634,e=>{"use strict";var t=e.i(681307);e.i(80194);var r=e.i(946466);let n=()=>t.z.union([t.z.number(),t.z.boolean()]).transform(e=>"boolean"==typeof e?+!!e:e).optional(),i={SUCCESS:1,INIT:0,ERROR:-1},o=t.z.object({backgroundColor:t.z.string().optional(),textColor:t.z.string().optional(),value:t.z.string().optional()}),s=t.z.object({id:t.z.string(),contentIds:t.z.array(t.z.string()).optional(),name:t.z.string().optional(),textDescription:t.z.string().optional(),imageDescription:t.z.string().optional(),imageDisplay:t.z.string().optional(),purchaseBanner:t.z.string().nullish(),logo:t.z.string().optional(),oldPrice:t.z.number().optional(),price:t.z.number().optional(),oldPriceString:t.z.string().optional(),priceString:t.z.string().optional(),currencyType:t.z.string().optional(),currencySymbol:t.z.string().optional(),currencySymbolPosition:t.z.string().optional(),requirements:t.z.array(t.z.unknown()).optional(),timeUnit:t.z.string().optional(),descriptionMapping:t.z.record(t.z.string(),t.z.unknown()).optional(),label:o.nullish(),descriptions:t.z.array(t.z.string()).optional(),tagType:t.z.string().optional(),type:t.z.number(),externalPurchaseId:t.z.string().nullish(),timePlanShowPrice:t.z.string().nullish(),showPrice:t.z.boolean().optional()}),a=t.z.object({plans:t.z.array(s).default([]),descriptions:t.z.array(t.z.unknown()).optional(),extraDescription:t.z.string().optional()}),u=t.z.object({name:t.z.string(),textDescription:t.z.string().optional(),duration:t.z.number().optional(),durationType:t.z.string().optional(),oldPrice:t.z.number().optional(),price:t.z.number().optional(),oldPriceString:t.z.string().optional(),priceString:t.z.string().optional(),discount:t.z.number().optional(),discountString:t.z.string().optional(),currencyType:t.z.string().optional(),currencySymbol:t.z.string().optional(),currencySymbolPosition:t.z.string().optional(),currencySymbolSeparator:t.z.string().optional(),promotionInfo:t.z.string().optional()}),l=t.z.object({timePlans:t.z.array(u).default([])}),h=t.z.preprocess(e=>{if(!e||"object"!=typeof e)return e;let t={...e};(void 0===t.imageDisplay&&"string"==typeof t.logo&&(t.imageDisplay=(0,r.resolveAssetUrl)(t.logo)),void 0===t.viewType&&"number"==typeof t.type&&(t.viewType=t.type),"boolean"==typeof t.autoRenew)&&(null!=t.isAutoRenew||(t.isAutoRenew=0),null!=t.showCheckboxAutoRenew||(t.showCheckboxAutoRenew=+!!t.autoRenew));return t},t.z.object({id:t.z.string(),name:t.z.string().optional(),viewType:t.z.number().optional(),textDescription:t.z.string().optional(),imageDisplay:t.z.string().optional(),oldPrice:t.z.number().optional(),price:t.z.number().optional(),oldPriceString:t.z.string().optional(),priceString:t.z.string().optional(),currencyType:t.z.string().optional(),currencySymbol:t.z.string().optional(),currencySymbolPosition:t.z.string().optional(),promotionInfo:t.z.string().optional(),orderIndex:t.z.number().optional(),isAutoRenew:n(),showCheckboxAutoRenew:n(),showCheckboxSaveCard:n(),isExternalBrowser:n(),smsLink:t.z.string().nullish()})),c=t.z.array(h),m=t.z.preprocess(e=>{var t,r,n;if(!e||"object"!=typeof e)return e;let i={...e};return null!=i.transId||(i.transId=i.transID),null!=i.webview||(i.webview=null!=(t=null!=(r=null!=(n=i.webUrl)?n:i.webURL)?r:i.paymentURL)?t:i.qrCodeURL),null!=i.amount||(i.amount=i.price),"boolean"==typeof i.isExternalWebview&&(i.isExternalWebview=+!!i.isExternalWebview),i},t.z.object({transId:t.z.string(),partner:t.z.string().optional(),webview:t.z.string().nullish(),expireTime:t.z.number().optional(),amount:t.z.number().optional(),description:t.z.string().optional(),isExternalWebview:n(),deepLink:t.z.string().nullish(),templateMobile:t.z.string().nullish()})),p=t.z.preprocess(e=>{if(!e||"object"!=typeof e)return e;let t={...e},r="number"==typeof t.statusCode?t.statusCode:void 0;return void 0!==r&&(t.status=!0===t.processing?i.INIT:r>0?1:r<0?-1:0),null!=t.transId||(t.transId=t.transID),"string"==typeof e.status&&(null!=t.message||(t.message=e.status)),t},t.z.object({status:t.z.number(),transId:t.z.string().optional(),message:t.z.string().optional(),messageObject:t.z.record(t.z.string(),t.z.unknown()).nullish()})),g=t.z.looseObject({orderID:t.z.string().optional(),status:t.z.string(),settledTransID:t.z.string().optional(),userID:t.z.string().optional(),accessToken:t.z.string().optional()}),d=t.z.object({plans:t.z.array(s).default([]),descriptions:t.z.unknown().optional(),heading:t.z.string().optional()}),f=t.z.object({planID:t.z.string().min(1)}),y=t.z.object({planID:t.z.string().optional()});e.s(["CheckTransactionResponseSchema",0,p,"CreatePaymentResponseSchema",0,m,"GUEST_ORDER_STATUS",0,{PENDING:"PENDING",PAID:"PAID",GRANTED:"GRANTED",FULFILLED:"FULFILLED",FAILED:"FAILED",CANCELLED:"CANCELLED"},"GuestOrderStatusResponseSchema",0,g,"PAYMENT_SOCKET_STATUS",0,{SUCCESS:0,ERROR:1},"PLAN_TYPE",0,{NORMAL:1,COMBO:2,EXTERNAL:3,MESSAGE_ONLY:4},"PaymentMethodListSchema",0,c,"PlanListResponseSchema",0,a,"PlanSchema",0,s,"RequiredPlansResponseSchema",0,d,"TEMPLATE_MOBILE",0,{DEEPLINK:"deeplink",SDK:"sdk"},"TXN_STATUS",0,i,"TimePlanListResponseSchema",0,l,"UnbindAutoRenewRequestSchema",0,f,"UnbindAutoRenewResponseSchema",0,y],32692);var E=e.i(499146),b=e.i(705599),T=e.i(502260),v=e.i(640411);function S(){var e;return null!=(e=(0,v.getAuthToken)())?e:void 0}function I(e,t){if(!e.success)throw(0,E.apiError)(e);return t(e.result)}let A=e=>({service:"payment",path:e,auth:"optional"});async function H(){var e,t;let n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return I(await (0,b.request)({route:A("/payment-plan/plans"),method:"get",params:{platform:(0,r.getPlatformName)(),dtId:null!=(e=n.dtId)?e:T.appInfo.dtId,spId:null!=(t=n.spId)?t:T.appInfo.spId},...S()?{token:S()}:{}}),e=>a.parse(e))}async function w(e){return I(await (0,b.request)({route:A(`/payment-plan/plan-detail/${e}`),method:"get",params:{platform:(0,r.getPlatformName)()},...S()?{token:S()}:{}}),e=>s.parse(e))}async function B(e){return I(await (0,b.request)({route:A("/payment-plan/time-plans"),method:"get",params:{planID:e,platform:(0,r.getPlatformName)()},...S()?{token:S()}:{}}),e=>l.parse(e).timePlans)}async function P(e,t){return I(await (0,b.request)({route:A("/payment-purchase/payment-methods"),method:"get",params:{planId:e,timePlanName:t,platform:(0,r.getPlatformName)()},...S()?{token:S()}:{}}),e=>c.parse(e).map((e,t)=>({method:e,index:t})).sort((e,t)=>
2{var r,n;return(null!=(r=e.method.orderIndex)?r:Number.MAX_SAFE_INTEGER)-(null!=(n=t.method.orderIndex)?n:Number.MAX_SAFE_INTEGER)||e.index-t.index}).map(e=>e.method))}async function _(e){var t,n,i;let o=null!=(t=null==(i=globalThis.crypto)||null==(n=i.randomUUID)?void 0:n.call(i))?t:`${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`,s=()=>(0,b.request)({route:A("/payment-purchase/create-payment"),method:"post",headers:{"Idempotency-Key":o,...e.deviceID?{"X-Device-ID":e.deviceID}:{}},data:{planID:e.planId,price:e.price,paymentMethodID:e.paymentMethodId,timePlanName:e.timePlanName,isAutoRenew:1===e.isAutoRenew,...void 0!==e.isSaveCard?{isSaveCard:1===e.isSaveCard}:{},...e.orderID?{orderID:e.orderID}:{},...e.deviceID?{deviceID:e.deviceID}:{},platform:(0,r.getPlatformName)()},...S()?{token:S()}:{}}),a=await s();return a.success||502!==a.status&&503!==a.status&&600!==a.status||(a=await s()),I(a,e=>m.parse(e))}async function N(e){return I(await (0,b.request)({route:A("/payment-purchase/check-transaction"),method:"post",data:{transID:e},...S()?{token:S()}:{}}),e=>p.parse(e))}async function R(e,t){return I(await (0,b.request)({route:A("/payment-purchase/check-transaction"),method:"post",headers:{"X-Device-ID":t},data:{orderID:e,deviceID:t}}),e=>g.parse(e))}async function D(e){await (0,b.request)({route:A("/payment-purchase/cancel-payment"),method:"post",data:{transID:e},...S()?{token:S()}:{}})}async function M(e){return I(await (0,b.request)({route:A("/payment-plan/required-plans"),method:"get",params:{contentIds:e,platform:(0,r.getPlatformName)()},...S()?{token:S()}:{}}),e=>d.parse(e))}async function L(e){let t=f.parse({planID:e});return I(await (0,b.request)({route:A("/payment-purchase/unbind"),method:"post",data:t,...S()?{token:S()}:{}}),e=>y.parse(null!=e?e:{}))}e.s(["cancelPayment",0,D,"checkGuestOrder",0,R,"checkTransaction",0,N,"createPayment",0,_,"getPaymentMethods",0,P,"getPlanDetail",0,w,"getPlans",0,H,"getRequiredPlans",0,M,"getTimePlans",0,B,"unbindAutoRenew",0,L],626634)},861745,e=>{"use strict";var t,r,n,i=e.i(271645);function o(e,t){let r=t&&t.cache?t.cache:h,n=t&&t.serializer?t.serializer:u;return(t&&t.strategy?t.strategy:function(e,t){var r,n;let i=1===e.length?s:a;return r=t.cache.create(),n=t.serializer,i.bind(this,e,r,n)})(e,{cache:r,serializer:n})}function s(e,t,r,n){let i=null==n||"number"==typeof n||"boolean"==typeof n?n:r(n),o=t.get(i);return void 0===o&&(o=e.call(this,n),t.set(i,o)),o}function a(e,t,r){let n=Array.prototype.slice.call(arguments,3),i=r(n),o=t.get(i);return void 0===o&&(o=e.apply(this,n),t.set(i,o)),o}let u=function(){return JSON.stringify(arguments)};var l=class{get(e){return this.cache[e]}set(e,t){this.cache[e]=t}constructor(){this.cache=Object.create(null)}};let h={create:function(){return new l}},c={variadic:function(e,t){var r,n;return r=t.cache.create(),n=t.serializer,a.bind(this,e,r,n)},monadic:function(e,t){var r,n;return r=t.cache.create(),n=t.serializer,s.bind(this,e,r,n)}};class m extends Error{constructor(e,t){let r=e;t&&(r+=": "+t),super(r),this.code=e,t&&(this.originalMessage=t)}}var p=((t=p||{}).MISSING_MESSAGE="MISSING_MESSAGE",t.MISSING_FORMAT="MISSING_FORMAT",t.ENVIRONMENT_FALLBACK="ENVIRONMENT_FALLBACK",t.INSUFFICIENT_PATH="INSUFFICIENT_PATH",t.INVALID_MESSAGE="INVALID_MESSAGE",t.INVALID_KEY="INVALID_KEY",t.FORMATTING_ERROR="FORMATTING_ERROR",t);function g(){return{dateTime:{},number:{},message:{},relativeTime:{},pluralRules:{},list:{},displayNames:{}}}function d(e,t){return o(e,{cache:{create:()=>({get:e=>t[e],set(e,r){t[e]=r}})},strategy:c.variadic})}function f(e,t){return d(function(){for(var t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];return new e(...r)},t)}function y(e){return{getDateTimeFormat:f(Intl.DateTimeFormat,e.dateTime),getNumberFormat:f(Intl.NumberFormat,e.number),getPluralRules:f(Intl.PluralRules,e.pluralRules),getRelativeTimeFormat:f(Intl.RelativeTimeFormat,e.relativeTime),getListFormat:f(Intl.ListFormat,e.list),getDisplayNames:f(Intl.DisplayNames,e.displayNames)}}let E=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g,b=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i,T=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,v=/^(@+)?(\+|#+)?[rs]?$/g,S=/(\*)(0+)|(#+)(0+)|(0+)/g,I=/^(0+)$/;function A(e){let t={};return"r"===e[e.length-1]?t.roundingPriority="morePrecision":"s"===e[e.length-1]&&(t.roundingPriority="lessPrecision"),e.replace(v,function(e,r,n){return"string"!=typeof n?(t.minimumSignificantDigits=r.length,t.maximumSignificantDigits=r.length):"+"===n?t.minimumSignificantDigits=r.length:"#"===r[0]?t.maximumSignificantDigits=r.length:(t.minimumSignificantDigits=r.length,t.maximumSignificantDigits=r.length+("string"==typeof n?n.length:0)),""}),t}function H(e){switch(e){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function w(e){let t=H(e);return t||{}}let B=((r={})[r.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",r[r.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",r[r.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",r[r.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",r[r.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",r[r.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",r[r.INVALID_
2NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",r[r.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",r[r.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",r[r.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",r[r.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",r[r.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",r[r.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",r[r.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",r[r.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",r[r.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",r[r.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",r[r.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",r[r.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",r[r.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",r[r.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",r[r.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",r[r.INVALID_TAG=23]="INVALID_TAG",r[r.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",r[r.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",r[r.UNCLOSED_TAG=27]="UNCLOSED_TAG",r);function P(e){return!!(e&&"object"==typeof e&&0===e.type)}function _(e){return!!(e&&"object"==typeof e&&1===e.type)}let N=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,R={"001":["H","h"],419:["h","H","hB","hb"],AC:["H","h","hb","hB"],AD:["H","hB"],AE:["h","hB","hb","H"],AF:["H","hb","hB","h"],AG:["h","hb","H","hB"],AI:["H","h","hb","hB"],AL:["h","H","hB"],AM:["H","hB"],AO:["H","hB"],AR:["h","H","hB","hb"],AS:["h","H"],AT:["H","hB"],AU:["h","hb","H","hB"],AW:["H","hB"],AX:["H"],AZ:["H","hB","h"],BA:["H","hB","h"],BB:["h","hb","H","hB"],BD:["h","hB","H"],BE:["H","hB"],BF:["H","hB"],BG:["H","hB","h"],BH:["h","hB","hb","H"],BI:["H","h"],BJ:["H","hB"],BL:["H","hB"],BM:["h","hb","H","hB"],BN:["hb","hB","h","H"],BO:["h","H","hB","hb"],BQ:["H"],BR:["H","hB"],BS:["h","hb","H","hB"],BT:["h","H"],BW:["H","h","hb","hB"],BY:["H","h"],BZ:["H","h","hb","hB"],CA:["h","hb","H","hB"],CC:["H","h","hb","hB"],CD:["hB","H"],CF:["H","h","hB"],CG:["H","hB"],CH:["H","hB","h"],CI:["H","hB"],CK:["H","h","hb","hB"],CL:["h","H","hB","hb"],CM:["H","h","hB"],CN:["H","hB","hb","h"],CO:["h","H","hB","hb"],CP:["H"],CR:["h","H","hB","hb"],CU:["h","H","hB","hb"],CV:["H","hB"],CW:["H","hB"],CX:["H","h","hb","hB"],CY:["h","H","hb","hB"],CZ:["H"],DE:["H","hB"],DG:["H","h","hb","hB"],DJ:["h","H"],DK:["H"],DM:["h","hb","H","hB"],DO:["h","H","hB","hb"],DZ:["h","hB","hb","H"],EA:["H","h","hB","hb"],EC:["h","H","hB","hb"],EE:["H","hB"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],ER:["h","H"],ES:["H","hB","h","hb"],ET:["hB","hb","h","H"],FI:["H"],FJ:["h","hb","H","hB"],FK:["H","h","hb","hB"],FM:["h","hb","H","hB"],FO:["H","h"],FR:["H","hB"],GA:["H","hB"],GB:["H","h","hb","hB"],GD:["h","hb","H","hB"],GE:["H","hB","h"],GF:["H","hB"],GG:["H","h","hb","hB"],GH:["h","H"],GI:["H","h","hb","hB"],GL:["H","h"],GM:["h","hb","H","hB"],GN:["H","hB"],GP:["H","hB"],GQ:["H","hB","h","hb"],GR:["h","H","hb","hB"],GS:["H","h","hb","hB"],GT:["h","H","hB","hb"],GU:["h","hb","H","hB"],GW:["H","hB"],GY:["h","hb","H","hB"],HK:["h","hB","hb","H"],HN:["h","H","hB","hb"],HR:["H","hB"],HU:["H","h"],IC:["H","h","hB","hb"],ID:["H"],IE:["H","h","hb","hB"],IL:["H","hB"],IM:["H","h","hb","hB"],IN:["h","H"],IO:["H","h","hb","hB"],IQ:["h","hB","hb","H"],IR:["hB","H"],IS:["H"],IT:["H","hB"],JE:["H","h","hb","hB"],JM:["h","hb","H","hB"],JO:["h","hB","hb","H"],JP:["H","K","h"],KE:["hB","hb","H","h"],KG:["H","h","hB","hb"],KH:["hB","h","H","hb"],KI:["h","hb","H","hB"],KM:["H","h","hB","hb"],KN:["h","hb","H","hB"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],KW:["h","hB","hb","H"],KY:["h","hb","H","hB"],KZ:["H","hB"],LA:["H","hb","hB","h"],LB:["h","hB","hb","H"],LC:["h","hb","H","hB"],LI:["H","hB","h"],LK:["H","h","hB","hb"],LR:["h","hb","H","hB"],LS:["h","H"],LT:["H","h","hb","hB"],LU:["H","h","hB"],LV:["H","hB","hb","h"],LY:["h","hB","hb","H"],MA
2:["H","h","hB","hb"],MC:["H","hB"],MD:["H","hB"],ME:["H","hB","h"],MF:["H","hB"],MG:["H","h"],MH:["h","hb","H","hB"],MK:["H","h","hb","hB"],ML:["H"],MM:["hB","hb","H","h"],MN:["H","h","hb","hB"],MO:["h","hB","hb","H"],MP:["h","hb","H","hB"],MQ:["H","hB"],MR:["h","hB","hb","H"],MS:["H","h","hb","hB"],MT:["H","h"],MU:["H","h"],MV:["H","h"],MW:["h","hb","H","hB"],MX:["h","H","hB","hb"],MY:["hb","hB","h","H"],MZ:["H","hB"],NA:["h","H","hB","hb"],NC:["H","hB"],NE:["H"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NI:["h","H","hB","hb"],NL:["H","hB"],NO:["H","h"],NP:["H","h","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],NZ:["h","hb","H","hB"],OM:["h","hB","hb","H"],PA:["h","H","hB","hb"],PE:["h","H","hB","hb"],PF:["H","h","hB"],PG:["h","H"],PH:["h","hB","hb","H"],PK:["h","hB","H"],PL:["H","h"],PM:["H","hB"],PN:["H","h","hb","hB"],PR:["h","H","hB","hb"],PS:["h","hB","hb","H"],PT:["H","hB"],PW:["h","H"],PY:["h","H","hB","hb"],QA:["h","hB","hb","H"],RE:["H","hB"],RO:["H","hB"],RS:["H","hB","h"],RU:["H"],RW:["H","h"],SA:["h","hB","hb","H"],SB:["h","hb","H","hB"],SC:["H","h","hB"],SD:["h","hB","hb","H"],SE:["H"],SG:["h","hb","H","hB"],SH:["H","h","hb","hB"],SI:["H","hB"],SJ:["H"],SK:["H"],SL:["h","hb","H","hB"],SM:["H","h","hB"],SN:["H","h","hB"],SO:["h","H"],SR:["H","hB"],SS:["h","hb","H","hB"],ST:["H","hB"],SV:["h","H","hB","hb"],SX:["H","h","hb","hB"],SY:["h","hB","hb","H"],SZ:["h","hb","H","hB"],TA:["H","h","hb","hB"],TC:["h","hb","H","hB"],TD:["h","H","hB"],TF:["H","h","hB"],TG:["H","hB"],TH:["H","h"],TJ:["H","h"],TL:["H","hB","hb","h"],TM:["H","h"],TN:["h","hB","hb","H"],TO:["h","H"],TR:["H","hB"],TT:["h","hb","H","hB"],TW:["hB","hb","h","H"],TZ:["hB","hb","H","h"],UA:["H","hB","h"],UG:["hB","hb","H","h"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],UY:["h","H","hB","hb"],UZ:["H","hB","h"],VA:["H","h","hB"],VC:["h","hb","H","hB"],VE:["h","H","hB","hb"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],VN:["H","h"],VU:["h","H"],WF:["H","hB"],WS:["h","H"],XK:["H","hB","h"],YE:["h","hB","hb","H"],YT:["H","hB"],ZA:["H","h","hb","hB"],ZM:["h","hb","H","hB"],ZW:["H","h"],"af-ZA":["H","h","hB","hb"],"ar-001":["h","hB","hb","H"],"ca-ES":["H","h","hB"],"en-001":["h","hb","H","hB"],"en-HK":["h","hb","H","hB"],"en-IL":["H","h","hb","hB"],"en-MY":["h","hb","H","hB"],"es-BR":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"gu-IN":["hB","hb","h","H"],"hi-IN":["hB","h","H"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],"kn-IN":["hB","h","H"],"ku-SY":["H","hB"],"ml-IN":["hB","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],"ta-IN":["hB","h","hb","H"],"te-IN":["hB","h","H"],"zu-ZA":["H","hB","hb","h"]},D=RegExp(`^${N.source}*`),M=RegExp(`${N.source}*$`);function L(e,t){return{start:e,end:t}}let O=!!Object.fromEntries,C=!!String.prototype.trimStart,z=!!String.prototype.trimEnd,k=O?Object.fromEntries:function(e){let t={};for(let[r,n]of e)t[r]=n;return t},F=C?function(e){return e.trimStart()}:function(e){return e.replace(D,"")},U=z?function(e){return e.trimEnd()}:function(e){return e.replace(M,"")},G=RegExp("([^\\u0009-\\u000D\\u0020\\u0085\\u00A0\\u1680\\u2000-\\u200A\\u2028-\\u2029\\u202F\\u205F\\u3000\\u0021-\\u002F\\u003A-\\u0040\\u005B-\\u005E\\u0060\\u007B-\\u007E\\u00A1-\\u00A7\\u00A9\\u00AB-\\u00AC\\u00AE\\u00B0-\\u00B1\\u00B6\\u00BB\\u00BF\\u00D7\\u00F7\\u2010-\\u2027\\u2030-\\u203E\\u2041-\\u2053\\u2055-\\u205E\\u2190-\\u245F\\u2500-\\u2775\\u2794-\\u2BFF\\u2E00-\\u2E7F\\u3001-\\u3003\\u3008-\\u3020\\u3030\\uFD3E-\\uFD3F\\uFE45-\\uFE46]*)","yu");var x=class{parse(){if(0!==this.offset())throw Error("parser can only be used once");return this.parseMessage(0,"",!1)}parseMessage(e,t,r){let n=[];for(;!this.isEOF();){let i=this.char();if(123===i){let t=this.parseArgument(e,r);if(t.err)return t;n.push(t.val)}else if(125===i&&e>0)break;else if(35===i&&("plural"===t||"selectordinal"===t)){let e=this.clonePosition();this.bump(),n.push({type:7,location:L(e,this.clonePosition())})}else if(60!==i||this.ignoreTag||47!==this.peek())if(60===i&&!this.ignoreTag&&K(this.peek()||0)){let r=this.parseTag(e,t);if(r.err)return r;n.push(r.val)}else{let r=this.parseLiteral(e,t);if(r.err)return r;n.push(r.val)}else if(!r)return this.error(26,L(this.clonePosition(),this.clonePosition()));else break}return{val:n,err:null}}parseTag(e,t){let r=this.clonePosition();this.bump();let n=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:0,value:`<${n}/>`,location:L(r,this.clonePosition())},err:null};if(!this.bumpIf(">"))return this.error(23,L(r,this.clonePosition()));{let i=this.parseMessage(e+1,t,!0);if(i.err)return i;let o=i.val,s=this.clonePosition();if(!this.bumpIf("</"))return this.error(27,L(r,this.clonePosition()));{if(this.isEOF()||!K(this.char()))return this.error(23,L(s,this.clonePosition()));let e=this.clonePosition();return n!==this.parseTagName()?this.error(26,L(e,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">"))?{val:{type:8,value:n,children:o,location:L(r,this.clonePosition())},err:null}:this.error(23,L(s,this.clonePosition()))}}}parseTagName(){var e;let t=this.offset();for(this.bump();!this.isEOF()&&(45===(e=this.char())||46===e||e>=48&&e<=57||95===e||e>=97&&e<=122||e>=65&&e<=90||183==e||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=893||e>=895&&e<=8191||e>=8204&&e<=8205||e>=8255&&e<=8256||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=63744&&e<=64975||e>=65008&&e<=65533||e>=65536&&e<=983039);)this.bump();return this.message.slice(t,this.offset())}parseLiteral(e,t){let r=this.clonePosition(),n="";for(;;){let r=this.tryParseQuote(t);if(r){n+=r;
2continue}let i=this.tryParseUnquoted(e,t);if(i){n+=i;continue}let o=this.tryParseLeftAngleBracket();if(o){n+=o;continue}break}return{val:{type:0,value:n,location:L(r,this.clonePosition())},err:null}}tryParseLeftAngleBracket(){var e;return this.isEOF()||60!==this.char()||!this.ignoreTag&&(K(e=this.peek()||0)||47===e)?null:(this.bump(),"<")}tryParseQuote(e){if(this.isEOF()||39!==this.char())return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if("plural"===e||"selectordinal"===e)break;return null;default:return null}this.bump();let t=[this.char()];for(this.bump();!this.isEOF();){let e=this.char();if(39===e)if(39===this.peek())t.push(39),this.bump();else{this.bump();break}else t.push(e);this.bump()}return String.fromCodePoint(...t)}tryParseUnquoted(e,t){if(this.isEOF())return null;let r=this.char();return 60===r||123===r||35===r&&("plural"===t||"selectordinal"===t)||125===r&&e>0?null:(this.bump(),String.fromCodePoint(r))}parseArgument(e,t){let r=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(1,L(r,this.clonePosition()));if(125===this.char())return this.bump(),this.error(2,L(r,this.clonePosition()));let n=this.parseIdentifierIfPossible().value;if(!n)return this.error(3,L(r,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(1,L(r,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:1,value:n,location:L(r,this.clonePosition())},err:null};case 44:if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(1,L(r,this.clonePosition()));return this.parseArgumentOptions(e,t,n,r);default:return this.error(3,L(r,this.clonePosition()))}}parseIdentifierIfPossible(){var e,t;let r=this.clonePosition(),n=this.offset(),i=(e=this.message,G.lastIndex=n,null!=(t=G.exec(e)[1])?t:""),o=n+i.length;return this.bumpTo(o),{value:i,location:L(r,this.clonePosition())}}parseArgumentOptions(e,t,r,n){let i=this.clonePosition(),o=this.parseIdentifierIfPossible().value,s=this.clonePosition();switch(o){case"":return this.error(4,L(i,s));case"number":case"date":case"time":{var a;this.bumpSpace();let e=null;if(this.bumpIf(",")){this.bumpSpace();let t=this.clonePosition(),r=this.parseSimpleArgStyleIfPossible();if(r.err)return r;let n=U(r.val);if(0===n.length)return this.error(6,L(this.clonePosition(),this.clonePosition()));e={style:n,styleLocation:L(t,this.clonePosition())}}let t=this.tryParseArgumentClose(n);if(t.err)return t;let i=L(n,this.clonePosition());if(e&&e.style.startsWith("::")){let t=F(e.style.slice(2));if("number"===o){let n=this.parseNumberSkeletonFromString(t,e.styleLocation);if(n.err)return n;return{val:{type:2,value:r,location:i,style:n.val},err:null}}{let n;if(0===t.length)return this.error(10,i);let s=t;return this.locale&&(s=function(e,t){let r="";for(let n=0;n<e.length;n++){let i=e.charAt(n);if("j"===i){let o=0;for(;n+1<e.length&&e.charAt(n+1)===i;)o++,n++;let s=1+(1&o),a=o<2?1:3+(o>>1),u=function(e){let t,r=e.hourCycle;if(void 0===r&&e.hourCycles&&e.hourCycles.length&&(r=e.hourCycles[0]),r)switch(r){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw Error("Invalid hourCycle")}let n=e.language;return"root"!==n&&(t=e.maximize().region),(R[t||""]||R[n||""]||R[`${n}-001`]||R["001"])[0]}(t);for(("H"==u||"k"==u)&&(a=0);a-- >0;)r+="a";for(;s-- >0;)r=u+r}else"J"===i?r+="H":r+=i}return r}(t,this.locale)),{val:{type:"date"===o?3:4,value:r,location:i,style:{type:1,pattern:s,location:e.styleLocation,parsedOptions:this.shouldParseSkeletons?(n={},s.replace(E,e=>{let t=e.length;switch(e[0]){case"G":n.era=4===t?"long":5===t?"narrow":"short";break;case"y":n.year=2===t?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":n.month=["numeric","2-digit","short","long","narrow"][t-1];break;case"w":case"W":throw RangeError("`w/W` (week) patterns are not supported");case"d":n.day=["numeric","2-digit"][t-1];break;case"D":case"F":case"g":throw RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":n.weekday=4===t?"long":5===t?"narrow":"short";break;case"e":if(t<4)throw RangeError("`e..eee` (weekday) patterns are not supported");n.weekday=["short","long","narrow","short"][t-4];break;case"c":if(t<4)throw RangeError("`c..ccc` (weekday) patterns are not supported");n.weekday=["short","long","narrow","short"][t-4];break;case"a":n.hour12=!0;break;case"b":case"B":throw RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":n.hourCycle="h12",n.hour=["numeric","2-digit"][t-1];break;case"H":n.hourCycle="h23",n.hour=["numeric","2-digit"][t-1];break;case"K":n.hourCycle="h11",n.hour=["numeric","2-digit"][t-1];break;case"k":n.hourCycle="h24",n.hour=["numeric","2-digit"][t-1];break;case"j":case"J":case"C":throw RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":n.minute=["numeric","2-digit"][t-1];break;case"s":n.second=["numeric","2-digit"][t-1];break;case"S":case"A":throw RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":n.timeZoneName=t<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""}),n):{}}},err:null}}}return{val:{type:"number"===o?2:"date"===o?3:4,value:r,location:i,style:null!=(a=null==e?void 0:e.style)?a:null},err:null}}
2case"plural":case"selectordinal":case"select":{let i=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(12,L(i,{...i}));this.bumpSpace();let s=this.parseIdentifierIfPossible(),a=0;if("select"!==o&&"offset"===s.value){if(!this.bumpIf(":"))return this.error(13,L(this.clonePosition(),this.clonePosition()));this.bumpSpace();let e=this.tryParseDecimalInteger(13,14);if(e.err)return e;this.bumpSpace(),s=this.parseIdentifierIfPossible(),a=e.val}let u=this.tryParsePluralOrSelectOptions(e,o,t,s);if(u.err)return u;let l=this.tryParseArgumentClose(n);if(l.err)return l;let h=L(n,this.clonePosition());if("select"===o)return{val:{type:5,value:r,options:k(u.val),location:h},err:null};return{val:{type:6,value:r,options:k(u.val),offset:a,pluralType:"plural"===o?"cardinal":"ordinal",location:h},err:null}}default:return this.error(5,L(i,s))}}tryParseArgumentClose(e){return this.isEOF()||125!==this.char()?this.error(1,L(e,this.clonePosition())):(this.bump(),{val:!0,err:null})}parseSimpleArgStyleIfPossible(){let e=0,t=this.clonePosition();for(;!this.isEOF();)switch(this.char()){case 39:{this.bump();let e=this.clonePosition();if(!this.bumpUntil("'"))return this.error(11,L(e,this.clonePosition()));this.bump();break}case 123:e+=1,this.bump();break;case 125:if(!(e>0))return{val:this.message.slice(t.offset,this.offset()),err:null};e-=1;break;default:this.bump()}return{val:this.message.slice(t.offset,this.offset()),err:null}}parseNumberSkeletonFromString(e,t){let r=[];try{r=function(e){if(0===e.length)throw Error("Number skeleton cannot be empty");let t=e.split(b).filter(e=>e.length>0),r=[];for(let e of t){let t=e.split("/");if(0===t.length)throw Error("Invalid number skeleton");let[n,...i]=t;for(let e of i)if(0===e.length)throw Error("Invalid number skeleton");r.push({stem:n,options:i})}return r}(e)}catch(e){return this.error(7,t)}return{val:{type:0,tokens:r,location:t,parsedOptions:this.shouldParseSkeletons?function(e){let t={};for(let r of e){switch(r.stem){case"percent":case"%":t.style="percent";continue;case"%x100":t.style="percent",t.scale=100;continue;case"currency":t.style="currency",t.currency=r.options[0];continue;case"group-off":case",_":t.useGrouping=!1;continue;case"precision-integer":case".":t.maximumFractionDigits=0;continue;case"measure-unit":case"unit":t.style="unit",t.unit=r.options[0].replace(/^(.*?)-/,"");continue;case"compact-short":case"K":t.notation="compact",t.compactDisplay="short";continue;case"compact-long":case"KK":t.notation="compact",t.compactDisplay="long";continue;case"scientific":t={...t,notation:"scientific",...r.options.reduce((e,t)=>({...e,...w(t)}),{})};continue;case"engineering":t={...t,notation:"engineering",...r.options.reduce((e,t)=>({...e,...w(t)}),{})};continue;case"notation-simple":t.notation="standard";continue;case"unit-width-narrow":t.currencyDisplay="narrowSymbol",t.unitDisplay="narrow";continue;case"unit-width-short":t.currencyDisplay="code",t.unitDisplay="short";continue;case"unit-width-full-name":t.currencyDisplay="name",t.unitDisplay="long";continue;case"unit-width-iso-code":t.currencyDisplay="symbol";continue;case"scale":t.scale=parseFloat(r.options[0]);continue;case"rounding-mode-floor":t.roundingMode="floor";continue;case"rounding-mode-ceiling":t.roundingMode="ceil";continue;case"rounding-mode-down":t.roundingMode="trunc";continue;case"rounding-mode-up":t.roundingMode="expand";continue;case"rounding-mode-half-even":t.roundingMode="halfEven";continue;case"rounding-mode-half-down":t.roundingMode="halfTrunc";continue;case"rounding-mode-half-up":t.roundingMode="halfExpand";continue;case"integer-width":if(r.options.length>1)throw RangeError("integer-width stems only accept a single optional option");r.options[0].replace(S,function(e,r,n,i,o,s){if(r)t.minimumIntegerDigits=n.length;else if(i&&o)throw Error("We currently do not support maximum integer digits");else if(s)throw Error("We currently do not support exact integer digits");return""});continue}if(I.test(r.stem)){t.minimumIntegerDigits=r.stem.length;continue}if(T.test(r.stem)){if(r.options.length>1)throw RangeError("Fraction-precision stems only accept a single optional option");r.stem.replace(T,function(e,r,n,i,o,s){return"*"===n?t.minimumFractionDigits=r.length:i&&"#"===i[0]?t.maximumFractionDigits=i.length:o&&s?(t.minimumFractionDigits=o.length,t.maximumFractionDigits=o.length+s.length):(t.minimumFractionDigits=r.length,t.maximumFractionDigits=r.length),""});let e=r.options[0];
2"w"===e?t={...t,trailingZeroDisplay:"stripIfInteger"}:e&&(t={...t,...A(e)});continue}if(v.test(r.stem)){t={...t,...A(r.stem)};continue}let e=H(r.stem);e&&(t={...t,...e});let n=function(e){let t;if("E"===e[0]&&"E"===e[1]?(t={notation:"engineering"},e=e.slice(2)):"E"===e[0]&&(t={notation:"scientific"},e=e.slice(1)),t){let r=e.slice(0,2);if("+!"===r?(t.signDisplay="always",e=e.slice(2)):"+?"===r&&(t.signDisplay="exceptZero",e=e.slice(2)),!I.test(e))throw Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}(r.stem);n&&(t={...t,...n})}return t}(r):{}},err:null}}tryParsePluralOrSelectOptions(e,t,r,n){let i=!1,o=[],s=new Set,{value:a,location:u}=n;for(;;){if(0===a.length){let e=this.clonePosition();if("select"!==t&&this.bumpIf("=")){let t=this.tryParseDecimalInteger(16,19);if(t.err)return t;u=L(e,this.clonePosition()),a=this.message.slice(e.offset,this.offset())}else break}if(s.has(a))return this.error("select"===t?21:20,u);"other"===a&&(i=!0),this.bumpSpace();let n=this.clonePosition();if(!this.bumpIf("{"))return this.error("select"===t?17:18,L(this.clonePosition(),this.clonePosition()));let l=this.parseMessage(e+1,t,r);if(l.err)return l;let h=this.tryParseArgumentClose(n);if(h.err)return h;o.push([a,{value:l.val,location:L(n,this.clonePosition())}]),s.add(a),this.bumpSpace(),{value:a,location:u}=this.parseIdentifierIfPossible()}return 0===o.length?this.error("select"===t?15:16,L(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!i?this.error(22,L(this.clonePosition(),this.clonePosition())):{val:o,err:null}}tryParseDecimalInteger(e,t){let r=1,n=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(r=-1);let i=!1,o=0;for(;!this.isEOF();){let e=this.char();if(e>=48&&e<=57)i=!0,o=10*o+(e-48),this.bump();else break}let s=L(n,this.clonePosition());return i?Number.isSafeInteger(o*=r)?{val:o,err:null}:this.error(t,s):this.error(e,s)}offset(){return this.position.offset}isEOF(){return this.offset()===this.message.length}clonePosition(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}}char(){let e=this.position.offset;if(e>=this.message.length)throw Error("out of bound");let t=this.message.codePointAt(e);if(void 0===t)throw Error(`Offset ${e} is at invalid UTF-16 code unit boundary`);return t}error(e,t){return{val:null,err:{kind:e,message:this.message,location:t}}}bump(){if(this.isEOF())return;let e=this.char();10===e?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=e<65536?1:2)}bumpIf(e){if(this.message.startsWith(e,this.offset())){for(let t=0;t<e.length;t++)this.bump();return!0}return!1}bumpUntil(e){let t=this.offset(),r=this.message.indexOf(e,t);return r>=0?(this.bumpTo(r),!0):(this.bumpTo(this.message.length),!1)}bumpTo(e){if(this.offset()>e)throw Error(`targetOffset ${e} must be greater than or equal to the current offset ${this.offset()}`);for(e=Math.min(e,this.message.length);;){let t=this.offset();if(t===e)break;if(t>e)throw Error(`targetOffset ${e} is at invalid UTF-16 code unit boundary`);if(this.bump(),this.isEOF())break}}bumpSpace(){for(var e;!this.isEOF()&&((e=this.char())>=9&&e<=13||32===e||133===e||e>=8206&&e<=8207||8232===e||8233===e);)this.bump()}peek(){var e;if(this.isEOF())return null;let t=this.char(),r=this.offset();return null!=(e=this.message.charCodeAt(r+(t>=65536?2:1)))?e:null}constructor(e,t={}){this.message=e,this.position={offset:0,line:1,column:1},this.ignoreTag=!!t.ignoreTag,this.locale=t.locale,this.requiresOtherClause=!!t.requiresOtherClause,this.shouldParseSkeletons=!!t.shouldParseSkeletons}};function K(e){return e>=97&&e<=122||e>=65&&e<=90}var V=class extends Error{toString(){return`[formatjs Error: ${this.code}] ${this.message}`}constructor(e,t,r){super(e),this.code=t,this.originalMessage=r}},j=class extends V{constructor(e,t,r,n){super(`Invalid values for "${e}": "${t}". Options are "${Object.keys(r).join('", "')}"`,"INVALID_VALUE",n)}},q=class extends V{constructor(e,t,r){super(`Value for "${e}" must be of type ${t}`,"INVALID_VALUE",r)}}
2,Z=class extends V{constructor(e,t){super(`The intl string context variable "${e}" was not provided to the string "${t}"`,"MISSING_VALUE",t)}};function $(e){return{create:()=>({get:t=>e[t],set(t,r){e[t]=r}})}}var Q=((n=class e{static get defaultLocale(){return e.memoizedDefaultLocale||(e.memoizedDefaultLocale=new Intl.NumberFormat().resolvedOptions().locale),e.memoizedDefaultLocale}constructor(t,r=e.defaultLocale,n,i){if(this.formatterCache={number:{},dateTime:{},pluralRules:{}},this.format=e=>{let t=this.formatToParts(e);if(1===t.length)return t[0].value;let r=t.reduce((e,t)=>(e.length&&0===t.type&&"string"==typeof e[e.length-1]?e[e.length-1]+=t.value:e.push(t.value),e),[]);return r.length<=1?r[0]||"":r},this.formatToParts=e=>(function e(t,r,n,i,o,s,a){if(1===t.length&&0===t[0].type)return[{type:0,value:t[0].value}];let u=[];for(let l of t){if(0===l.type){u.push({type:0,value:l.value});continue}if(7===l.type){"number"==typeof s&&u.push({type:0,value:n.getNumberFormat(r).format(s)});continue}let{value:t}=l;if(!(o&&t in o))throw new Z(t,a);let h=o[t];if(1===l.type){h&&"string"!=typeof h&&"number"!=typeof h&&"bigint"!=typeof h||(h="string"==typeof h||"number"==typeof h||"bigint"==typeof h?String(h):""),u.push({type:+("string"!=typeof h),value:h});continue}if(3===l.type){let e="string"==typeof l.style?i.date[l.style]:_(l.style)?l.style.parsedOptions:void 0;u.push({type:0,value:n.getDateTimeFormat(r,e).format(h)});continue}if(4===l.type){let e="string"==typeof l.style?i.time[l.style]:_(l.style)?l.style.parsedOptions:i.time.medium;u.push({type:0,value:n.getDateTimeFormat(r,e).format(h)});continue}if(2===l.type){let e="string"==typeof l.style?i.number[l.style]:P(l.style)?l.style.parsedOptions:void 0;if(e&&e.scale){let t=e.scale||1;if("bigint"==typeof h){if(!Number.isInteger(t))throw TypeError(`Cannot apply fractional scale ${t} to bigint value. Scale must be an integer when formatting bigint.`);h*=BigInt(t)}else h*=t}u.push({type:0,value:n.getNumberFormat(r,e).format(h)});continue}if(8===l.type){let{children:t,value:h}=l,c=o[h];if("function"!=typeof c)throw new q(h,"function",a);let m=c(e(t,r,n,i,o,s).map(e=>e.value));Array.isArray(m)||(m=[m]),u.push(...m.map(e=>({type:+("string"!=typeof e),value:e})))}if(5===l.type){let t=h,s=(Object.prototype.hasOwnProperty.call(l.options,t)?l.options[t]:void 0)||l.options.other;if(!s)throw new j(l.value,h,Object.keys(l.options),a);u.push(...e(s.value,r,n,i,o));continue}if(6===l.type){let t=`=${h}`,s=Object.prototype.hasOwnProperty.call(l.options,t)?l.options[t]:void 0;if(!s){if(!Intl.PluralRules)throw new V(`Intl.PluralRules is not available in this environment. 3Try polyfilling it using "@formatjs/intl-pluralrules" 4`,"MISSING_INTL_API",a);let e="bigint"==typeof h?Number(h):h,t=n.getPluralRules(r,{type:l.pluralType}).select(e-(l.offset||0));s=(Object.prototype.hasOwnProperty.call(l.options,t)?l.options[t]:void 0)||l.options.other}if(!s)throw new j(l.value,h,Object.keys(l.options),a);let c="bigint"==typeof h?Number(h):h;u.push(...e(s.value,r,n,i,o,c-(l.offset||0)));continue}}return u.length<2?u:u.reduce((e,t)=>{let r=e[e.length-1];return r&&0===r.type&&0===t.type?r.value+=t.value:e.push(t),e},[])})(this.ast,this.locales,this.formatters,this.formats,e,void 0,this.message),this.resolvedOptions=()=>{var e;return{locale:(null==(e=this.resolvedLocale)?void 0:e.toString())||Intl.NumberFormat.supportedLocalesOf(this.locales)[0]}},this.getAst=()=>this.ast,this.locales=r,this.resolvedLocale=e.resolveLocale(r),"string"==typeof t){if(this.message=t,!e.__parse)throw TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");const{...r}=i||{};this.ast=e.__parse(t,{...r,locale:this.resolvedLocale})}else this.ast=t;if(!Array.isArray(this.ast))throw TypeError("A message must be provided as a String or AST.");this.formats=function(e,t){return t?Object.keys(e).reduce((r,n)=>{var i,o;return r[n]=(i=e[n],(o=t[n])?{...i,...o,...Object.keys(i).reduce((e,t)=>(e[t]={...i[t],...o[t]},e),{})}:i),r},{...e}):e}(e.formats,n),this.formatters=i&&i.formatters||function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{number:{},dateTime:{},pluralRules:{}};return{getNumberFormat:o(function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return new Intl.NumberFormat(...t)}
4,{cache:$(e.number),strategy:c.variadic}),getDateTimeFormat:o(function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return new Intl.DateTimeFormat(...t)},{cache:$(e.dateTime),strategy:c.variadic}),getPluralRules:o(function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return new Intl.PluralRules(...t)},{cache:$(e.pluralRules),strategy:c.variadic})}}(this.formatterCache)}}).memoizedDefaultLocale=null,n.resolveLocale=e=>{if(void 0===Intl.Locale)return;let t=Intl.NumberFormat.supportedLocalesOf(e);return new Intl.Locale(t.length>0?t[0]:"string"==typeof e?e:e[0])},n.__parse=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=new x(e,t={shouldParseSkeletons:!0,requiresOtherClause:!0,...t}).parse();if(r.err){let e=SyntaxError(B[r.err.kind]);throw e.location=r.err.location,e.originalMessage=r.err.message,e}return(null==t?void 0:t.captureLocation)||function e(t){t.forEach(t=>{if(delete t.location,5===t.type||6===t.type)for(let r in t.options)delete t.options[r].location,e(t.options[r].value);else 2===t.type&&P(t.style)||(3===t.type||4===t.type)&&_(t.style)?delete t.style.location:8===t.type&&e(t.children)})}(r.val),r.val},n.formats={number:{integer:{maximumFractionDigits:0},currency:{style:"currency"},percent:{style:"percent"}},date:{short:{month:"numeric",day:"numeric",year:"2-digit"},medium:{month:"short",day:"numeric",year:"numeric"},long:{month:"long",day:"numeric",year:"numeric"},full:{weekday:"long",month:"long",day:"numeric",year:"numeric"}},time:{short:{hour:"numeric",minute:"numeric"},medium:{hour:"numeric",minute:"numeric",second:"numeric"},long:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"},full:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"}}},n);function X(){let e;for(var t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];let[o,s,a,u]=r;if(Array.isArray(s))throw new m(p.INVALID_MESSAGE,void 0);if("object"==typeof s)throw new m(p.INSUFFICIENT_PATH,void 0);if("string"==typeof s){let e=a||/'[{}]/.test(s)?void 0:s;if(e)return e}let{cache:l,formats:h,formatters:c,globalFormats:g,locale:f,timeZone:y}=u;c.getMessageFormat||(c.getMessageFormat=d(function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return new Q(t[0],t[1],t[2],{formatters:c,...t[3]})},l.message));try{let t,r,n,i;e=c.getMessageFormat(s,f,(t=Q.formats.date,r=Q.formats.time,n={...null==g?void 0:g.dateTime,...null==h?void 0:h.dateTime},i={date:{...t,...n},time:{...r,...n},number:{...null==g?void 0:g.number,...null==h?void 0:h.number}},y&&["date","time"].forEach(e=>{let t=i[e];for(let[e,r]of Object.entries(t))t[e]={timeZone:y,...r}}),i),{formatters:{...c,getDateTimeFormat:(e,t)=>{var r;return c.getDateTimeFormat(e,{...t,timeZone:null!=(r=null==t?void 0:t.timeZone)?r:y})}}})}catch(e){throw new m(p.INVALID_MESSAGE,void 0)}let E=e.format(a);return(0,i.isValidElement)(E)||Array.isArray(E)||"string"==typeof E?E:String(E)}function Y(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return t.filter(Boolean).join(".")}function W(e){return Y(e.namespace,e.key)}function J(e){console.error(e)}function ee(e,t,r,n){let i=Y(n,r);if(!t)throw Error(i);let o=t;return r.split(".").forEach(t=>{let r=o[t];if(null==t||null==r)throw Error(i+` (${e})`);o=r}),o}X.raw=!0;let et={second:1,seconds:1,minute:60,minutes:60,hour:3600,hours:3600,day:86400,days:86400,week:604800,weeks:604800,month:2628e3,months:2628e3,quarter:7884e3,quarters:7884e3,year:31536e3,years:31536e3};var er=e.i(843476);let en=(0,i.createContext)(void 0);function ei(){let e=(0,i.useContext)(en);if(!e)throw Error(void 0);return e}let eo=!1,es="u"<typeof window;e.s(["IntlProvider",0,function(e){let{children:t,formats:r,getMessageFallback:n,locale:o,messages:s,now:a,onError:u,timeZone:l}=e,h=(0,i.useContext)(en),c=(0,i.useMemo)(()=>(null==h?void 0:h.cache)||g(),[o,null==h?void 0:h.cache]),m=(0,i.useMemo)(()=>(null==h?void 0:h.formatters)||y(c),[c,null==h?void 0:h.formatters]),p=(0,i.useMemo)(()=>({...function(e){let{formats:t,getMessageFallback:r,messages:n,onError:i,...o}=e;return{...o,formats:t||void 0,messages:n||void 0,onError:i||J,getMessageFallback:r||W}}
4({locale:o,formats:void 0===r?null==h?void 0:h.formats:r,getMessageFallback:n||(null==h?void 0:h.getMessageFallback),messages:void 0===s?null==h?void 0:h.messages:s,now:a||(null==h?void 0:h.now),onError:u||(null==h?void 0:h.onError),timeZone:l||(null==h?void 0:h.timeZone)}),formatters:m,cache:c}),[c,r,m,n,o,s,a,u,h,l]);return(0,er.jsx)(en.Provider,{value:p,children:t})},"useFormatter",0,function(){let{formats:e,formatters:t,locale:r,now:n,onError:o,timeZone:s}=ei();return(0,i.useMemo)(()=>(function(e){let{_cache:t=g(),_formatters:r=y(t),formats:n,locale:i,onError:o=J,timeZone:s}=e;function a(e){return(null==e?void 0:e.timeZone)||(s?e={...e,timeZone:s}:o(new m(p.ENVIRONMENT_FALLBACK,void 0))),e}function u(e,t,r,n,i){let s;try{s=function(e,t,r){let n;if("string"==typeof t){if(!(n=null==e?void 0:e[t])){let e=new m(p.MISSING_FORMAT,void 0);throw o(e),e}}else n=t;return r&&(n={...n,...r}),n}(r,e,t)}catch(e){return i()}try{return n(s)}catch(e){return o(new m(p.FORMATTING_ERROR,e.message)),i()}}function l(e,t,o){return u(t,o,null==n?void 0:n.dateTime,t=>(t=a(t),r.getDateTimeFormat(i,t).format(e)),()=>String(e))}function h(){return e.now?e.now:(o(new m(p.ENVIRONMENT_FALLBACK,void 0)),new Date)}return{dateTime:l,number:function(e,t,o){return u(t,o,null==n?void 0:n.number,t=>r.getNumberFormat(i,t).format(e),()=>String(e))},relativeTime:function(e,t){try{var n;let o,s,a,u={};t instanceof Date||"number"==typeof t?o=new Date(t):t&&(o=null!=t.now?new Date(t.now):h(),s=t.unit,u.style=t.style,u.numberingSystem=t.numberingSystem),o||(o=h());let l=(new Date(e).getTime()-o.getTime())/1e3;s||(s=(a=Math.abs(l))<60?"second":a<3600?"minute":a<86400?"hour":a<604800?"day":a<2628e3?"week":a<31536e3?"month":"year"),u.numeric="second"===s?"auto":"always";let c=(n=s,Math.round(l/et[n]));return r.getRelativeTimeFormat(i,u).format(c,s)}catch(t){return o(new m(p.FORMATTING_ERROR,t.message)),String(e)}},list:function(e,t,o){let s=[],a=new Map,l=0;for(let t of e){let e;"object"==typeof t?(e=String(l),a.set(e,t)):e=String(t),s.push(e),l++}return u(t,o,null==n?void 0:n.list,e=>{let t=r.getListFormat(i,e).formatToParts(s).map(e=>"literal"===e.type?e.value:a.get(e.value)||e.value);return a.size>0?t:t.join("")},()=>String(e))},dateTimeRange:function(e,t,o,s){return u(o,s,null==n?void 0:n.dateTime,n=>(n=a(n),r.getDateTimeFormat(i,n).formatRange(e,t)),()=>[l(e),l(t)].join("âââ"))},displayName:function(e,t,o){return u(t,o,null==n?void 0:n.displayName,t=>r.getDisplayNames(i,t).of(e),()=>e)}}})({formats:e,locale:r,now:n,onError:o,timeZone:s,_formatters:t}),[e,t,n,r,o,s])},"useLocale",0,function(){return ei().locale},"useTranslations",0,function(e){return function(e,t){let{cache:r,formats:n,formatters:o,getMessageFallback:s,locale:a,onError:u,timeZone:l}=ei(),h=e["!"],c="!"===t?void 0:t.slice(2);return l||eo||!es||(eo=!0,u(new m(p.ENVIRONMENT_FALLBACK,void 0))),(0,i.useMemo)(()=>{var e;let t;return t=function(e,t,r){try{if(!t)throw Error(void 0);let n=r?ee(e,t,r):t;if(!n)throw Error(r);return n}catch(e){return new m(p.MISSING_MESSAGE,e.message)}}((e={cache:r,formatters:o,getMessageFallback:s,messages:h,namespace:c,onError:u,formats:n,locale:a,timeZone:l}).locale,e.messages,e.namespace),function(e){let{cache:t,formats:r,formatters:n,getMessageFallback:o=W,locale:s,messagesOrError:a,namespace:u,onError:l,timeZone:h}=e,c=a instanceof m;function g(e,t,r,n){let i=new m(t,r);return l(i),null!=n?n:o({error:i,key:e,namespace:u})}function d(e,d,f,y){let E;if(c){if(!y)return l(a),o({error:a,key:e,namespace:u});E=y}else try{E=ee(s,a,e,u)}catch(t){if(!y)return g(e,p.MISSING_MESSAGE,t.message,y);E=y}try{let o,a=Y(u,e);return X(a,E,d?(o={},Object.keys(d).forEach(e=>{let t,r=0,n=d[e];t="function"==typeof n?t=>{let o=n(t);return(0,i.isValidElement)(o)?(0,i.cloneElement)(o,{key:e+r++}):o}:n,o[e]=t}),o):d,{cache:t,formatters:n,globalFormats:r,formats:f,locale:s,timeZone:h})}catch(n){let t,r;return n instanceof m?(t=n.code,r=n.originalMessage):(t=p.FORMATTING_ERROR,r=n.message),g(e,t,r,y)}}function f(e,t,r,n){let i=d(e,t,r,n);return"string"!=typeof i?g(e,p.INVALID_MESSAGE,void 0):i}return f.rich=d,f.markup=(e,t,r,n)=>d(e,t,r,n),f.raw=e=>{if(c)return l(a),o({error:a,key:e,namespace:u});try{return ee(s,a,e,u)}catch(t){return g(e,p.MISSING_MESSAGE,t.message)}},f.has=e=>{if(c)return!1;try{return ee(s,a,e,u),!0}catch(e){return!1}},f}({...e,messagesOrError:t})},[r,o,s,h,c,u,n,a,l])}({"!":ei().messages},e?`!.${e}`:"!")}],861745)}]); 5 6//# debugId=2a7151a4-68a8-0698-f85b-0560eda40596
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.