import{getNodeAttribute as c,setNodeAttributeValue as l}from"../../../../shared/markdoc.js";import{readFileContent as w}from"../read-file-content.js";import{resolvePathInMarkdown as m}from"../resolve-path-in-markdown.js";import{MdResolveError as d}from"./md-resolve-error.js";async function C(o,e,i,{context:n,actions:s}){const r=c(o,e),a=s.contentDir;if(r){const t=m(r,i,a);if(!await n.fs.exists(t))throw new d(`File ${t} does not exist`,{rawLink:t});const f=await w(t,n.fs);l(o,e+"RawContent",f)}}export{C as resolveRawContent};
