import{w as l,a as n,L as a}from"./chunk-JZWAC4HX-5kJHQiQ9.js";import{j as r}from"./jsx-runtime-C4_65a1U.js";import{E as d}from"./index-zkt0glVO.js";import{E as c}from"./epic-video-BZ1AWKL2.js";import{G as m}from"./error-boundary-BC83xzIm.js";import{E as p}from"./launch-editor-CwyOLU4S.js";import{M as f}from"./mdx-CNkHFdBV.js";import{c as x}from"./misc-DRDyxdMg.js";import{P as u,u as h}from"./progress-0t5gpm_A.js";import"./index-B9zr-vzA.js";import"./use-event-source-Dip1vrZy.js";import"./index-nErvdZSM.js";import"./index-BzPxupzT.js";import"./index-BYdxj4vr.js";import"./tooltip-mkBMB3mq.js";import"./root-loader-Cnwtpb_k.js";import"./pe-P58jSSsB.js";import"./schemas-RF4TJjJw.js";import"./online-CrGTaAx4.js";import"./loading-DDR0n-s7.js";import"./format-CKpZi3Um.js";import"./user-Pnhys2oT.js";import"./workshop-config-BVRT-ayZ.js";import"./preload-helper-DqNgO5-4.js";import"./progress-bar-BwLqNk15.js";(function(){try{var o=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};o.SENTRY_RELEASE={id:"8a6db0ac5fe78363b0c97fe458a96ce773bf357c"};var e=new o.Error().stack;e&&(o._sentryDebugIds=o._sentryDebugIds||{},o._sentryDebugIds[e]="73d2d81f-b3fc-4237-89f7-0de87dcb6440",o._sentryDebugIdIdentifier="sentry-dbid-73d2d81f-b3fc-4237-89f7-0de87dcb6440")}catch{}})();function b({index:o,exercise:e}){const s=h(e.exerciseNumber);return r.jsx("li",{children:r.jsxs(a,{className:x("hover:bg-muted/60 relative flex items-center gap-4 px-4 py-3 text-lg font-semibold transition after:absolute after:right-10 after:-translate-x-2 after:opacity-0 after:transition after:content-['→'] hover:after:translate-x-0 hover:after:opacity-100",s),to:`${e.exerciseNumber.toString().padStart(2,"0")}`,"data-keyboard-action":o===0?"g+n":void 0,children:[r.jsx("span",{className:"text-xs font-normal tabular-nums opacity-50",children:e.exerciseNumber}),r.jsx("span",{children:e.title})]})},e.exerciseNumber)}const w={h1:()=>null},Q=l(function({loaderData:e}){const s=r.jsxs("ul",{className:"divide-border dark:divide-border/50 flex flex-col divide-y",children:[r.jsx("strong",{className:"px-10 pb-3 font-mono text-xs uppercase",children:"Exercises"}),e.exercises.map((t,i)=>r.jsx(b,{index:i,exercise:t},t.exerciseNumber))]});return r.jsxs("main",{className:"relative flex h-full w-full max-w-5xl flex-col justify-between border-r md:w-3/4 xl:w-2/3",children:[r.jsxs("article",{id:e.articleId,className:"shadow-on-scrollbox scrollbar-thin scrollbar-thumb-scrollbar flex w-full flex-1 flex-col gap-12 overflow-y-scroll px-3 py-4 pt-6 md:px-10 md:py-12 md:pt-16",children:[r.jsx("div",{children:r.jsx("h1",{className:"px-10 text-[clamp(3rem,6vw,7.5rem)] leading-none font-extrabold",children:e.title})}),r.jsxs("div",{className:"w-full max-w-none scroll-pt-6 border-t px-3 pt-3 md:px-10 md:pt-8",children:[r.jsx("h2",{className:"pb-5 font-mono text-xs font-semibold uppercase",children:"Intro"}),e.workshopReadme.compiled.status==="success"&&e.workshopReadme.compiled.code?r.jsx(c,{epicVideoInfosPromise:e.epicVideoInfosPromise,children:r.jsx("div",{className:"prose dark:prose-invert sm:prose-lg",children:r.jsx(f,{code:e.workshopReadme.compiled.code,components:w})})}):e.workshopReadme.compiled.status==="error"?r.jsxs("div",{className:"text-foreground-destructive",children:["There was an error:",r.jsx("pre",{children:e.workshopReadme.compiled.error})]}):"No instructions yet..."]}),r.jsx("div",{className:"pt-10 pb-5",children:e.workshopReadme.compiled.status==="success"&&e.workshopReadme.compiled.code&&e.workshopReadme.compiled.code.length>500?s:null})]}),r.jsx(d,{elementQuery:`#${e.articleId}`}),r.jsx(u,{type:"workshop-instructions",className:"h-14 border-t px-6"}),r.jsx("div",{className:"@container flex h-16 justify-center border-t",children:r.jsx(p,{file:e.workshopReadme.file,relativePath:e.workshopReadme.relativePath})})]})}),Y=n(function(){return r.jsx(m,{})});export{Y as ErrorBoundary,Q as default};
//# sourceMappingURL=index-BI09UunU.js.map
