import{j as e,r as l}from"./index-ukWRVZhT.js";import{E as t}from"./index-gUr5Pw56.js";import{M as a,E as n}from"./mdx-D6tq6-eo.js";import{P as d}from"./progress-bflWy5AR.js";import{E as c}from"./epic-video-B_UyM5_A.js";import{L as m}from"./loading-D38hMiHp.js";import{N as p}from"./nav-chevrons-Brb7CoS8.js";import{c as f}from"./misc-Dj_mZhbv.js";import{u as h,L as x}from"./components-BgKv_YmS.js";import"./clsx-B-dksMZM.js";import"./progress-bar-CpMgJLQi.js";import"./tooltip-DGH2AGjl.js";import"./index-C7XNc9YK.js";import"./index-DDykkvu3.js";import"./client-hints-D8U-zfYg.js";const C=({matches:s})=>{var o;const r=(o=s.find(i=>i.id==="root"))==null?void 0:o.data;return[{title:`🎉 ${r==null?void 0:r.workshopTitle}`}]};function V(){const s=h();return e.jsx("div",{className:"flex h-full flex-grow flex-col",children:e.jsxs("main",{className:"grid h-full flex-grow grid-cols-1 grid-rows-2 lg:grid-cols-2 lg:grid-rows-1",children:[e.jsxs("div",{className:"relative col-span-1 row-span-1 flex h-full flex-col lg:border-r",children:[e.jsx("h1",{className:"h-14 border-b pl-10 pr-5 text-sm font-medium uppercase leading-none",children:e.jsx("div",{className:"flex h-14 flex-wrap items-center justify-between gap-x-2 py-2",children:e.jsxs("div",{className:"flex items-center justify-start gap-x-2",children:[e.jsx(x,{to:"/",className:"hover:underline",children:s.workshopTitle}),e.jsx("span",{children:"/"}),e.jsx("span",{children:"Elaboration"})]})})}),e.jsx("article",{className:"shadow-on-scrollbox h-full w-full max-w-none flex-1 scroll-pt-6 space-y-6 overflow-y-auto p-10 pt-8 scrollbar-thin scrollbar-thumb-scrollbar",id:s.articleId,children:s.finishedCode?e.jsx(c,{epicVideoInfosPromise:s.epicVideoInfosPromise,children:e.jsx("div",{className:"prose dark:prose-invert sm:prose-lg",children:e.jsx(a,{code:s.finishedCode,components:{h1:()=>null}})})}):"No finished instructions yet..."}),e.jsx(t,{elementQuery:`#${s.articleId}`}),e.jsx(d,{type:"workshop-finished",className:"h-14 border-t px-6"}),e.jsxs("div",{className:"flex h-16 justify-between border-b-4 border-t lg:border-b-0",children:[e.jsx("div",{}),s.workshopFinished.status==="success"?e.jsx(n,{file:s.workshopFinished.file,relativePath:s.workshopFinished.relativePath}):null,e.jsx(p,{prev:s.prevStepLink,next:{to:"/"}})]})]}),e.jsx(u,{workshopTitle:s.workshopTitle,workshopFormEmbedUrl:s.workshopFormEmbedUrl})]})})}function u({workshopTitle:s,workshopFormEmbedUrl:r}){const[o,i]=l.useState(!1);return e.jsxs("div",{className:"relative flex-shrink-0",children:[o?null:e.jsx("div",{className:"absolute inset-0 z-10 flex items-center justify-center",children:e.jsx(m,{children:e.jsxs("span",{children:["Loading ",s," Elaboration form"]})})}),e.jsx("iframe",{onLoad:()=>i(!0),title:"Elaboration",src:r,className:f("absolute inset-0 flex h-full w-full transition-opacity duration-300",o?"opacity-100":"opacity-0")})]})}export{V as default,C as meta};
//# sourceMappingURL=finished-CU6svdl5.js.map
