import{MARKDOC_PARTIALS_DATA_KEY as m}from"../../store.js";import{reporter as u}from"../../utils/reporter/reporter.js";async function g(r,e,n,i,l,o){const a=!!e?.props?.compilationErrors?.length,s=r?.serverPropsGetterIds;return s?.length?Promise.all(s.map(async t=>{const p=l[t];if(!p){if(a)return{...e.props};u.panicOnBuild(`Invalid server props getter id: "${t}" for route "${r.slug}"`)}return await(await p()).default(r,e,{variables:{...n,pageProps:i},partials:o.getGlobalConfig(m)},o.serverOutDir)})||[]):[]}export{g as getServerPropsFromSystemHandlers};
