import{r as e}from"./rolldown-runtime-DUnMT5BP.js";import{t}from"./framework~index~page~page~route~page~page~page~page~page~page~page~page~page~layout~route~r~ic3hypuo-Bx1kQmOd.js";var n=e(t(),1),r=Symbol.for(`vinext.serverInsertedHTMLContext`),i=Symbol.for(`vinext.navigation.fallback`);function a(e){return typeof n.createContext==`function`?n.createContext(e):null}function o(){let e=globalThis;return e[r]||(e[r]=a(null)),e[r]??null}o();var s=Symbol.for(`vinext.navigation.globalAccessors`);function c(){let e=globalThis;return e[i]??={serverContext:null,serverInsertedHTMLCallbacks:[]}}function l(){return globalThis[s]}var u=()=>l()?.getServerContext()??c().serverContext,d=e=>{let t=l();t?t.setServerContext(e):c().serverContext=e};function f(e){u=e.getServerContext,d=e.setServerContext,e.getInsertedHTMLCallbacks,e.clearInsertedHTMLCallbacks}function p(){return u()}function m(e){d(e)}var h=`NEXT_HTTP_ERROR_FALLBACK`;function g(e){if(!e||typeof e!=`object`||!(`digest`in e))return!1;let t=String(e.digest);return t===`NEXT_NOT_FOUND`||t.startsWith(`NEXT_HTTP_ERROR_FALLBACK;`)}var _=class extends Error{digest;constructor(e,t){super(e),this.digest=t}};function v(){throw new _(`NEXT_NOT_FOUND`,`${h};404`)}function y(e){return!!e&&typeof e==`object`&&`digest`in e&&typeof e.digest==`string`&&e.digest.startsWith(`NEXT_REDIRECT;`)}function b(e){return y(e)||g(e)}export{p as a,f as i,v as n,m as o,s as r,b as t};