@epic-web/workshop-app 4.12.2 → 4.12.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,2 +1,2 @@
1
- import{j as r,a as l,i as c}from"./index-Czg1ruVn.js";import{E as m}from"./index-D6ukHE4T.js";import{E as a}from"./epic-video-DJN9_SUj.js";import{M as d,E as p}from"./mdx-BENF-kTQ.js";import{P as x}from"./progress-BwanvUpB.js";import{g as u}from"./misc-S5ZD98sI.js";import{g as f}from"./seo-pBpFCWsy.js";import{u as b,L as h}from"./components-wgHiPsTg.js";import"./index-yEAxvbDV.js";import"./request-info-DHtGM4FI.js";import"./tooltip-BtzSIxlB.js";import"./client-hints-DLYDs4RF.js";import"./loading-B0uKxERz.js";import"./user-CdUDQ7a8.js";import"./clsx-B-dksMZM.js";import"./progress-bar-wMXWRGq0.js";const V=({data:e,matches:o})=>{var i;const s=e==null?void 0:e.exercise.exerciseNumber.toString().padStart(2,"0"),t=(i=o.find(n=>n.id==="root"))==null?void 0:i.data;return!e||!t?[{title:"🦉 | Error"}]:f({title:`📝 | ${s}. ${e.exercise.title} | ${t==null?void 0:t.workshopTitle}`,description:`Introduction for ${s}. ${e.exercise.title}`,ogTitle:e.exercise.title,ogDescription:`Introduction for exercise ${Number(s)}`,instructor:t.instructor,requestInfo:t.requestInfo})},j={h1:()=>null};function q(){var t;const e=b(),s=`${String(((t=e.firstStep)==null?void 0:t.stepNumber)??"01").padStart(2,"0")}/${e.firstType}`;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 flex w-full flex-1 flex-col gap-12 overflow-y-scroll px-3 py-4 pt-6 scrollbar-thin scrollbar-thumb-scrollbar md:px-10 md:py-12 md:pt-16",children:[r.jsx("div",{children:r.jsx("h1",{className:"text-[clamp(3rem,6vw,8.5rem)] font-extrabold leading-none",children:e.exercise.title})}),r.jsx("div",{children:e.exercise.instructionsCode?r.jsx(a,{epicVideoInfosPromise:e.epicVideoInfosPromise,children:r.jsx("div",{className:"prose dark:prose-invert sm:prose-lg",children:r.jsx(d,{code:e.exercise.instructionsCode,components:j})})}):"No instructions yet..."})]},e.articleId),r.jsx(m,{elementQuery:`#${e.articleId}`},`scroll-${e.articleId}`),r.jsx(x,{type:"instructions",exerciseNumber:e.exerciseNumber,className:"h-14 border-t px-6"}),r.jsxs("div",{className:"flex h-16 justify-between border-b-4 border-t lg:border-b-0",children:[r.jsx("div",{}),r.jsx(p,{file:e.exerciseReadme.file,relativePath:e.exerciseReadme.relativePath}),r.jsx(h,{to:s,prefetch:"intent",className:"flex h-full items-center justify-center bg-foreground px-7 text-background",children:"Start Learning"})]})]})}function B(){const e=l();return typeof document<"u"&&console.error(e),c(e)?e.status===404?r.jsx("p",{children:"Sorry, we couldn't find that step."}):r.jsxs("p",{children:[e.status," ",e.data]}):r.jsx("p",{children:u(e)})}export{B as ErrorBoundary,q as default,V as meta};
2
- //# sourceMappingURL=_exerciseNumber-DTITDRGx.js.map
1
+ import{j as r,a as l,i as c}from"./index-Czg1ruVn.js";import{E as m}from"./index-D6ukHE4T.js";import{E as a}from"./epic-video-DJN9_SUj.js";import{M as d,E as p}from"./mdx-BENF-kTQ.js";import{P as x}from"./progress-BwanvUpB.js";import{g as u}from"./misc-S5ZD98sI.js";import{g as f}from"./seo-pBpFCWsy.js";import{u as b,L as h}from"./components-wgHiPsTg.js";import"./index-yEAxvbDV.js";import"./request-info-DHtGM4FI.js";import"./tooltip-BtzSIxlB.js";import"./client-hints-DLYDs4RF.js";import"./loading-B0uKxERz.js";import"./user-CdUDQ7a8.js";import"./clsx-B-dksMZM.js";import"./progress-bar-wMXWRGq0.js";const V=({data:e,matches:o})=>{var i;const s=e==null?void 0:e.exercise.exerciseNumber.toString().padStart(2,"0"),t=(i=o.find(n=>n.id==="root"))==null?void 0:i.data;return!e||!t?[{title:"🦉 | Error"}]:f({title:`📝 | ${s}. ${e.exercise.title} | ${t==null?void 0:t.workshopTitle}`,description:`Introduction for ${s}. ${e.exercise.title}`,ogTitle:e.exercise.title,ogDescription:`Introduction for exercise ${Number(s)}`,instructor:t.instructor,requestInfo:t.requestInfo})},j={h1:()=>null};function q(){var t;const e=b(),s=`${String(((t=e.firstStep)==null?void 0:t.stepNumber)??"01").padStart(2,"0")}/${e.firstType}`;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 flex w-full flex-1 flex-col gap-12 overflow-y-scroll px-3 py-4 pt-6 scrollbar-thin scrollbar-thumb-scrollbar md:px-10 md:py-12 md:pt-16",children:[r.jsx("div",{children:r.jsx("h1",{className:"text-[clamp(3rem,6vw,7.5rem)] font-extrabold leading-none",children:e.exercise.title})}),r.jsx("div",{children:e.exercise.instructionsCode?r.jsx(a,{epicVideoInfosPromise:e.epicVideoInfosPromise,children:r.jsx("div",{className:"prose dark:prose-invert sm:prose-lg",children:r.jsx(d,{code:e.exercise.instructionsCode,components:j})})}):"No instructions yet..."})]},e.articleId),r.jsx(m,{elementQuery:`#${e.articleId}`},`scroll-${e.articleId}`),r.jsx(x,{type:"instructions",exerciseNumber:e.exerciseNumber,className:"h-14 border-t px-6"}),r.jsxs("div",{className:"flex h-16 justify-between border-b-4 border-t lg:border-b-0",children:[r.jsx("div",{}),r.jsx(p,{file:e.exerciseReadme.file,relativePath:e.exerciseReadme.relativePath}),r.jsx(h,{to:s,prefetch:"intent",className:"flex h-full items-center justify-center bg-foreground px-7 text-background",children:"Start Learning"})]})]})}function B(){const e=l();return typeof document<"u"&&console.error(e),c(e)?e.status===404?r.jsx("p",{children:"Sorry, we couldn't find that step."}):r.jsxs("p",{children:[e.status," ",e.data]}):r.jsx("p",{children:u(e)})}export{B as ErrorBoundary,q as default,V as meta};
2
+ //# sourceMappingURL=_exerciseNumber-Ccwr4LZw.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"_exerciseNumber-DTITDRGx.js","sources":["../../../app/routes/_app+/_exercises+/$exerciseNumber.tsx"],"sourcesContent":["import path from 'path'\nimport { invariantResponse } from '@epic-web/invariant'\nimport { ElementScrollRestoration } from '@epic-web/restore-scroll'\nimport {\n\tgetExercises,\n\tgetWorkshopRoot,\n\tgetWorkshopTitle,\n} from '@epic-web/workshop-utils/apps.server'\nimport {\n\tcombineServerTimings,\n\tgetServerTimeHeader,\n\tmakeTimings,\n\ttime,\n} from '@epic-web/workshop-utils/timing.server'\nimport {\n\tdefer,\n\ttype HeadersFunction,\n\ttype LoaderFunctionArgs,\n\ttype MetaFunction,\n} from '@remix-run/node'\nimport {\n\tLink,\n\tisRouteErrorResponse,\n\tuseLoaderData,\n\tuseRouteError,\n} from '@remix-run/react'\nimport slugify from '@sindresorhus/slugify'\nimport { EpicVideoInfoProvider } from '#app/components/epic-video.tsx'\nimport { type loader as rootLoader } from '#app/root.tsx'\nimport { EditFileOnGitHub } from '#app/routes/launch-editor.tsx'\nimport { ProgressToggle } from '#app/routes/progress.tsx'\nimport { getEpicVideoInfos } from '#app/utils/epic-api.ts'\nimport { Mdx } from '#app/utils/mdx.tsx'\nimport { getErrorMessage } from '#app/utils/misc.tsx'\nimport { getSeoMetaTags } from '#app/utils/seo.js'\n\nexport const meta: MetaFunction<typeof loader, { root: typeof rootLoader }> = ({\n\tdata,\n\tmatches,\n}) => {\n\tconst number = data?.exercise.exerciseNumber.toString().padStart(2, '0')\n\n\tconst rootData = matches.find((m) => m.id === 'root')?.data\n\tif (!data || !rootData) return [{ title: '🦉 | Error' }]\n\n\treturn getSeoMetaTags({\n\t\ttitle: `📝 | ${number}. ${data.exercise.title} | ${rootData?.workshopTitle}`,\n\t\tdescription: `Introduction for ${number}. ${data.exercise.title}`,\n\t\togTitle: data.exercise.title,\n\t\togDescription: `Introduction for exercise ${Number(number)}`,\n\t\tinstructor: rootData.instructor,\n\t\trequestInfo: rootData.requestInfo,\n\t})\n}\n\nexport async function loader({ request, params }: LoaderFunctionArgs) {\n\tconst timings = makeTimings('exerciseNumberLoader')\n\tinvariantResponse(params.exerciseNumber, 'exerciseNumber is required')\n\tconst [exercises, workshopTitle] = await Promise.all([\n\t\ttime(() => getExercises({ request, timings }), {\n\t\t\ttimings,\n\t\t\ttype: 'getExercises',\n\t\t\tdesc: 'getExercises in $exerciseNumber.tsx',\n\t\t}),\n\t\ttime(() => getWorkshopTitle(), {\n\t\t\ttimings,\n\t\t\ttype: 'getWorkshopTitle',\n\t\t\tdesc: 'getWorkshopTitle in $exerciseNumber.tsx',\n\t\t}),\n\t])\n\tconst exercise = exercises.find(\n\t\t(e) => e.exerciseNumber === Number(params.exerciseNumber),\n\t)\n\tif (!exercise) {\n\t\tthrow new Response('Not found', { status: 404 })\n\t}\n\n\tconst readmeFilepath = path.join(\n\t\tgetWorkshopRoot(),\n\t\t'exercises',\n\t\texercise.dirName,\n\t\t'README.mdx',\n\t)\n\n\tconst firstStep = exercise.steps.find(Boolean)\n\n\tconst articleId = `workshop-${slugify(workshopTitle)}-${\n\t\texercise.exerciseNumber\n\t}-instructions`\n\n\treturn defer(\n\t\t{\n\t\t\tarticleId,\n\t\t\texercise,\n\t\t\texerciseNumber: exercise.exerciseNumber,\n\t\t\texerciseReadme: {\n\t\t\t\tfile: readmeFilepath,\n\t\t\t\trelativePath: `exercises/${exercise.dirName}`,\n\t\t\t},\n\t\t\texerciseTitle: exercise.title,\n\t\t\tfirstStep,\n\t\t\tfirstType: firstStep?.problem ? 'problem' : 'solution',\n\t\t\ttitle: workshopTitle,\n\t\t\tepicVideoInfosPromise: getEpicVideoInfos(\n\t\t\t\texercise.instructionsEpicVideoEmbeds,\n\t\t\t\t{ request },\n\t\t\t),\n\t\t},\n\t\t{\n\t\t\theaders: {\n\t\t\t\t'Server-Timing': getServerTimeHeader(timings),\n\t\t\t},\n\t\t},\n\t)\n}\n\nexport const headers: HeadersFunction = ({ loaderHeaders, parentHeaders }) => {\n\tconst headers = {\n\t\t'Cache-Control': loaderHeaders.get('Cache-Control') ?? '',\n\t\t'Server-Timing': combineServerTimings(loaderHeaders, parentHeaders),\n\t}\n\treturn headers\n}\n\nconst mdxComponents = { h1: () => null }\nexport default function ExerciseNumberRoute() {\n\tconst data = useLoaderData<typeof loader>()\n\n\tconst firstStepNumber = String(data.firstStep?.stepNumber ?? '01')\n\tconst firstStepPath = `${firstStepNumber.padStart(2, '0')}/${data.firstType}`\n\treturn (\n\t\t<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\">\n\t\t\t<article\n\t\t\t\tid={data.articleId}\n\t\t\t\tkey={data.articleId}\n\t\t\t\tclassName=\"shadow-on-scrollbox flex w-full flex-1 flex-col gap-12 overflow-y-scroll px-3 py-4 pt-6 scrollbar-thin scrollbar-thumb-scrollbar md:px-10 md:py-12 md:pt-16\"\n\t\t\t>\n\t\t\t\t<div>\n\t\t\t\t\t<h1 className=\"text-[clamp(3rem,6vw,8.5rem)] font-extrabold leading-none\">\n\t\t\t\t\t\t{data.exercise.title}\n\t\t\t\t\t</h1>\n\t\t\t\t</div>\n\t\t\t\t<div>\n\t\t\t\t\t{data.exercise.instructionsCode ? (\n\t\t\t\t\t\t<EpicVideoInfoProvider\n\t\t\t\t\t\t\tepicVideoInfosPromise={data.epicVideoInfosPromise}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<div className=\"prose dark:prose-invert sm:prose-lg\">\n\t\t\t\t\t\t\t\t<Mdx\n\t\t\t\t\t\t\t\t\tcode={data.exercise.instructionsCode}\n\t\t\t\t\t\t\t\t\tcomponents={mdxComponents}\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</EpicVideoInfoProvider>\n\t\t\t\t\t) : (\n\t\t\t\t\t\t'No instructions yet...'\n\t\t\t\t\t)}\n\t\t\t\t</div>\n\t\t\t</article>\n\t\t\t<ElementScrollRestoration\n\t\t\t\telementQuery={`#${data.articleId}`}\n\t\t\t\tkey={`scroll-${data.articleId}`}\n\t\t\t/>\n\t\t\t<ProgressToggle\n\t\t\t\ttype=\"instructions\"\n\t\t\t\texerciseNumber={data.exerciseNumber}\n\t\t\t\tclassName=\"h-14 border-t px-6\"\n\t\t\t/>\n\t\t\t<div className=\"flex h-16 justify-between border-b-4 border-t lg:border-b-0\">\n\t\t\t\t<div />\n\t\t\t\t<EditFileOnGitHub\n\t\t\t\t\tfile={data.exerciseReadme.file}\n\t\t\t\t\trelativePath={data.exerciseReadme.relativePath}\n\t\t\t\t/>\n\t\t\t\t<Link\n\t\t\t\t\tto={firstStepPath}\n\t\t\t\t\tprefetch=\"intent\"\n\t\t\t\t\tclassName=\"flex h-full items-center justify-center bg-foreground px-7 text-background\"\n\t\t\t\t>\n\t\t\t\t\tStart Learning\n\t\t\t\t</Link>\n\t\t\t</div>\n\t\t</main>\n\t)\n}\n\nexport function ErrorBoundary() {\n\tconst error = useRouteError()\n\n\tif (typeof document !== 'undefined') {\n\t\tconsole.error(error)\n\t}\n\n\treturn isRouteErrorResponse(error) ? (\n\t\terror.status === 404 ? (\n\t\t\t<p>Sorry, we couldn't find that step.</p>\n\t\t) : (\n\t\t\t<p>\n\t\t\t\t{error.status} {error.data}\n\t\t\t</p>\n\t\t)\n\t) : (\n\t\t<p>{getErrorMessage(error)}</p>\n\t)\n}\n"],"names":["meta","data","matches","number","exercise","exerciseNumber","toString","padStart","rootData","find","m","id","title","getSeoMetaTags","workshopTitle","description","ogTitle","ogDescription","Number","instructor","requestInfo","mdxComponents","h1","ExerciseNumberRoute","useLoaderData","firstStepPath","String","firstStep","stepNumber","firstType","jsxs","className","children","articleId","jsx","instructionsCode","EpicVideoInfoProvider","epicVideoInfosPromise","Mdx","code","components","ElementScrollRestoration","elementQuery","ProgressToggle","type","EditFileOnGitHub","file","exerciseReadme","relativePath","Link","to","prefetch","ErrorBoundary","error","useRouteError","document","console","isRouteErrorResponse","status","getErrorMessage"],"mappings":"2lBAoCO,MAAMA,EAAiEA,CAAC,CAC9EC,KAAAA,EACAC,QAAAA,CACD,IAAM,OACC,MAAAC,EAASF,GAAAA,YAAAA,EAAMG,SAASC,eAAeC,WAAWC,SAAS,EAAG,KAE9DC,GAAWN,EAAAA,EAAQO,KAAMC,GAAMA,EAAEC,KAAO,MAAM,IAAnCT,YAAAA,EAAsCD,KACnD,MAAA,CAACA,GAAQ,CAACO,EAAiB,CAAC,CAAEI,MAAO,YAAa,CAAC,EAEhDC,EAAe,CACrBD,MAAO,QAAQT,CAAM,KAAKF,EAAKG,SAASQ,KAAK,MAAMJ,GAAAA,YAAAA,EAAUM,aAAa,GAC1EC,YAAa,oBAAoBZ,CAAM,KAAKF,EAAKG,SAASQ,KAAK,GAC/DI,QAASf,EAAKG,SAASQ,MACvBK,cAAe,6BAA6BC,OAAOf,CAAM,CAAC,GAC1DgB,WAAYX,EAASW,WACrBC,YAAaZ,EAASY,WACvB,CAAC,CACF,EAuEMC,EAAgB,CAAEC,GAAIA,IAAM,IAAK,EACvC,SAAwBC,GAAsB,OAC7C,MAAMtB,EAAOuB,IAGPC,EAAgB,GADEC,SAAOzB,EAAAA,EAAK0B,YAAL1B,YAAAA,EAAgB2B,aAAc,IAAI,EACxBrB,SAAS,EAAG,GAAG,CAAC,IAAIN,EAAK4B,SAAS,GAE1E,OAAAC,EAAAA,KAAC,OAAK,CAAAC,UAAU,4FACfC,SAAA,CAAAF,EAAA,KAAC,UAAA,CACAnB,GAAIV,EAAKgC,UAETF,UAAU,8JAEVC,SAAA,CAACE,EAAA,IAAA,MAAA,CACAF,eAAC,KAAG,CAAAD,UAAU,4DACZC,SAAK/B,EAAAG,SAASQ,MAChB,CACD,CAAA,EACCsB,EAAA,IAAA,MAAA,CACCF,SAAK/B,EAAAG,SAAS+B,iBACdD,EAAAA,IAACE,EAAA,CACAC,sBAAuBpC,EAAKoC,sBAE5BL,SAAAE,EAAA,IAAC,MAAI,CAAAH,UAAU,sCACdC,SAAAE,EAAA,IAACI,EAAA,CACAC,KAAMtC,EAAKG,SAAS+B,iBACpBK,WAAYnB,EACb,EACD,CACD,CAAA,EAEA,wBAEF,CAAA,CAAA,CAAA,EAvBKpB,EAAKgC,SAwBX,EACAC,EAAAA,IAACO,EAAA,CACAC,aAAc,IAAIzC,EAAKgC,SAAS,EAAA,EAC3B,UAAUhC,EAAKgC,SAAS,EAC9B,EACAC,EAAA,IAACS,EAAA,CACAC,KAAK,eACLvC,eAAgBJ,EAAKI,eACrB0B,UAAU,oBAAA,CACX,EACAD,EAAA,KAAC,MAAI,CAAAC,UAAU,8DACdC,SAAA,CAAAE,EAAAA,IAAC,MAAI,CAAA,CAAA,EACLA,EAAA,IAACW,EAAA,CACAC,KAAM7C,EAAK8C,eAAeD,KAC1BE,aAAc/C,EAAK8C,eAAeC,YAAA,CACnC,EACAd,EAAA,IAACe,EAAA,CACAC,GAAIzB,EACJ0B,SAAS,SACTpB,UAAU,6EACVC,SAAA,gBAAA,CAED,CAAA,CACD,CAAA,CAAA,CACD,CAAA,CAEF,CAEO,SAASoB,GAAgB,CAC/B,MAAMC,EAAQC,IAEV,OAAA,OAAOC,SAAa,KACvBC,QAAQH,MAAMA,CAAK,EAGbI,EAAqBJ,CAAK,EAChCA,EAAMK,SAAW,IAChBxB,EAAA,IAAC,IAAE,CAAAF,SAAA,oCAAA,CAAkC,EAErCF,EAAA,KAAC,IACC,CAAAE,SAAA,CAAMqB,EAAAK,OAAO,IAAEL,EAAMpD,IAAA,CAAA,CACvB,EAGDiC,EAAA,IAAC,IAAG,CAAAF,SAAA2B,EAAgBN,CAAK,CAAE,CAAA,CAE7B"}
1
+ {"version":3,"file":"_exerciseNumber-Ccwr4LZw.js","sources":["../../../app/routes/_app+/_exercises+/$exerciseNumber.tsx"],"sourcesContent":["import path from 'path'\nimport { invariantResponse } from '@epic-web/invariant'\nimport { ElementScrollRestoration } from '@epic-web/restore-scroll'\nimport {\n\tgetExercises,\n\tgetWorkshopRoot,\n\tgetWorkshopTitle,\n} from '@epic-web/workshop-utils/apps.server'\nimport {\n\tcombineServerTimings,\n\tgetServerTimeHeader,\n\tmakeTimings,\n\ttime,\n} from '@epic-web/workshop-utils/timing.server'\nimport {\n\tdefer,\n\ttype HeadersFunction,\n\ttype LoaderFunctionArgs,\n\ttype MetaFunction,\n} from '@remix-run/node'\nimport {\n\tLink,\n\tisRouteErrorResponse,\n\tuseLoaderData,\n\tuseRouteError,\n} from '@remix-run/react'\nimport slugify from '@sindresorhus/slugify'\nimport { EpicVideoInfoProvider } from '#app/components/epic-video.tsx'\nimport { type loader as rootLoader } from '#app/root.tsx'\nimport { EditFileOnGitHub } from '#app/routes/launch-editor.tsx'\nimport { ProgressToggle } from '#app/routes/progress.tsx'\nimport { getEpicVideoInfos } from '#app/utils/epic-api.ts'\nimport { Mdx } from '#app/utils/mdx.tsx'\nimport { getErrorMessage } from '#app/utils/misc.tsx'\nimport { getSeoMetaTags } from '#app/utils/seo.js'\n\nexport const meta: MetaFunction<typeof loader, { root: typeof rootLoader }> = ({\n\tdata,\n\tmatches,\n}) => {\n\tconst number = data?.exercise.exerciseNumber.toString().padStart(2, '0')\n\n\tconst rootData = matches.find((m) => m.id === 'root')?.data\n\tif (!data || !rootData) return [{ title: '🦉 | Error' }]\n\n\treturn getSeoMetaTags({\n\t\ttitle: `📝 | ${number}. ${data.exercise.title} | ${rootData?.workshopTitle}`,\n\t\tdescription: `Introduction for ${number}. ${data.exercise.title}`,\n\t\togTitle: data.exercise.title,\n\t\togDescription: `Introduction for exercise ${Number(number)}`,\n\t\tinstructor: rootData.instructor,\n\t\trequestInfo: rootData.requestInfo,\n\t})\n}\n\nexport async function loader({ request, params }: LoaderFunctionArgs) {\n\tconst timings = makeTimings('exerciseNumberLoader')\n\tinvariantResponse(params.exerciseNumber, 'exerciseNumber is required')\n\tconst [exercises, workshopTitle] = await Promise.all([\n\t\ttime(() => getExercises({ request, timings }), {\n\t\t\ttimings,\n\t\t\ttype: 'getExercises',\n\t\t\tdesc: 'getExercises in $exerciseNumber.tsx',\n\t\t}),\n\t\ttime(() => getWorkshopTitle(), {\n\t\t\ttimings,\n\t\t\ttype: 'getWorkshopTitle',\n\t\t\tdesc: 'getWorkshopTitle in $exerciseNumber.tsx',\n\t\t}),\n\t])\n\tconst exercise = exercises.find(\n\t\t(e) => e.exerciseNumber === Number(params.exerciseNumber),\n\t)\n\tif (!exercise) {\n\t\tthrow new Response('Not found', { status: 404 })\n\t}\n\n\tconst readmeFilepath = path.join(\n\t\tgetWorkshopRoot(),\n\t\t'exercises',\n\t\texercise.dirName,\n\t\t'README.mdx',\n\t)\n\n\tconst firstStep = exercise.steps.find(Boolean)\n\n\tconst articleId = `workshop-${slugify(workshopTitle)}-${\n\t\texercise.exerciseNumber\n\t}-instructions`\n\n\treturn defer(\n\t\t{\n\t\t\tarticleId,\n\t\t\texercise,\n\t\t\texerciseNumber: exercise.exerciseNumber,\n\t\t\texerciseReadme: {\n\t\t\t\tfile: readmeFilepath,\n\t\t\t\trelativePath: `exercises/${exercise.dirName}`,\n\t\t\t},\n\t\t\texerciseTitle: exercise.title,\n\t\t\tfirstStep,\n\t\t\tfirstType: firstStep?.problem ? 'problem' : 'solution',\n\t\t\ttitle: workshopTitle,\n\t\t\tepicVideoInfosPromise: getEpicVideoInfos(\n\t\t\t\texercise.instructionsEpicVideoEmbeds,\n\t\t\t\t{ request },\n\t\t\t),\n\t\t},\n\t\t{\n\t\t\theaders: {\n\t\t\t\t'Server-Timing': getServerTimeHeader(timings),\n\t\t\t},\n\t\t},\n\t)\n}\n\nexport const headers: HeadersFunction = ({ loaderHeaders, parentHeaders }) => {\n\tconst headers = {\n\t\t'Cache-Control': loaderHeaders.get('Cache-Control') ?? '',\n\t\t'Server-Timing': combineServerTimings(loaderHeaders, parentHeaders),\n\t}\n\treturn headers\n}\n\nconst mdxComponents = { h1: () => null }\nexport default function ExerciseNumberRoute() {\n\tconst data = useLoaderData<typeof loader>()\n\n\tconst firstStepNumber = String(data.firstStep?.stepNumber ?? '01')\n\tconst firstStepPath = `${firstStepNumber.padStart(2, '0')}/${data.firstType}`\n\treturn (\n\t\t<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\">\n\t\t\t<article\n\t\t\t\tid={data.articleId}\n\t\t\t\tkey={data.articleId}\n\t\t\t\tclassName=\"shadow-on-scrollbox flex w-full flex-1 flex-col gap-12 overflow-y-scroll px-3 py-4 pt-6 scrollbar-thin scrollbar-thumb-scrollbar md:px-10 md:py-12 md:pt-16\"\n\t\t\t>\n\t\t\t\t<div>\n\t\t\t\t\t<h1 className=\"text-[clamp(3rem,6vw,7.5rem)] font-extrabold leading-none\">\n\t\t\t\t\t\t{data.exercise.title}\n\t\t\t\t\t</h1>\n\t\t\t\t</div>\n\t\t\t\t<div>\n\t\t\t\t\t{data.exercise.instructionsCode ? (\n\t\t\t\t\t\t<EpicVideoInfoProvider\n\t\t\t\t\t\t\tepicVideoInfosPromise={data.epicVideoInfosPromise}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<div className=\"prose dark:prose-invert sm:prose-lg\">\n\t\t\t\t\t\t\t\t<Mdx\n\t\t\t\t\t\t\t\t\tcode={data.exercise.instructionsCode}\n\t\t\t\t\t\t\t\t\tcomponents={mdxComponents}\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</EpicVideoInfoProvider>\n\t\t\t\t\t) : (\n\t\t\t\t\t\t'No instructions yet...'\n\t\t\t\t\t)}\n\t\t\t\t</div>\n\t\t\t</article>\n\t\t\t<ElementScrollRestoration\n\t\t\t\telementQuery={`#${data.articleId}`}\n\t\t\t\tkey={`scroll-${data.articleId}`}\n\t\t\t/>\n\t\t\t<ProgressToggle\n\t\t\t\ttype=\"instructions\"\n\t\t\t\texerciseNumber={data.exerciseNumber}\n\t\t\t\tclassName=\"h-14 border-t px-6\"\n\t\t\t/>\n\t\t\t<div className=\"flex h-16 justify-between border-b-4 border-t lg:border-b-0\">\n\t\t\t\t<div />\n\t\t\t\t<EditFileOnGitHub\n\t\t\t\t\tfile={data.exerciseReadme.file}\n\t\t\t\t\trelativePath={data.exerciseReadme.relativePath}\n\t\t\t\t/>\n\t\t\t\t<Link\n\t\t\t\t\tto={firstStepPath}\n\t\t\t\t\tprefetch=\"intent\"\n\t\t\t\t\tclassName=\"flex h-full items-center justify-center bg-foreground px-7 text-background\"\n\t\t\t\t>\n\t\t\t\t\tStart Learning\n\t\t\t\t</Link>\n\t\t\t</div>\n\t\t</main>\n\t)\n}\n\nexport function ErrorBoundary() {\n\tconst error = useRouteError()\n\n\tif (typeof document !== 'undefined') {\n\t\tconsole.error(error)\n\t}\n\n\treturn isRouteErrorResponse(error) ? (\n\t\terror.status === 404 ? (\n\t\t\t<p>Sorry, we couldn't find that step.</p>\n\t\t) : (\n\t\t\t<p>\n\t\t\t\t{error.status} {error.data}\n\t\t\t</p>\n\t\t)\n\t) : (\n\t\t<p>{getErrorMessage(error)}</p>\n\t)\n}\n"],"names":["meta","data","matches","number","exercise","exerciseNumber","toString","padStart","rootData","find","m","id","title","getSeoMetaTags","workshopTitle","description","ogTitle","ogDescription","Number","instructor","requestInfo","mdxComponents","h1","ExerciseNumberRoute","useLoaderData","firstStepPath","String","firstStep","stepNumber","firstType","jsxs","className","children","articleId","jsx","instructionsCode","EpicVideoInfoProvider","epicVideoInfosPromise","Mdx","code","components","ElementScrollRestoration","elementQuery","ProgressToggle","type","EditFileOnGitHub","file","exerciseReadme","relativePath","Link","to","prefetch","ErrorBoundary","error","useRouteError","document","console","isRouteErrorResponse","status","getErrorMessage"],"mappings":"2lBAoCO,MAAMA,EAAiEA,CAAC,CAC9EC,KAAAA,EACAC,QAAAA,CACD,IAAM,OACC,MAAAC,EAASF,GAAAA,YAAAA,EAAMG,SAASC,eAAeC,WAAWC,SAAS,EAAG,KAE9DC,GAAWN,EAAAA,EAAQO,KAAMC,GAAMA,EAAEC,KAAO,MAAM,IAAnCT,YAAAA,EAAsCD,KACnD,MAAA,CAACA,GAAQ,CAACO,EAAiB,CAAC,CAAEI,MAAO,YAAa,CAAC,EAEhDC,EAAe,CACrBD,MAAO,QAAQT,CAAM,KAAKF,EAAKG,SAASQ,KAAK,MAAMJ,GAAAA,YAAAA,EAAUM,aAAa,GAC1EC,YAAa,oBAAoBZ,CAAM,KAAKF,EAAKG,SAASQ,KAAK,GAC/DI,QAASf,EAAKG,SAASQ,MACvBK,cAAe,6BAA6BC,OAAOf,CAAM,CAAC,GAC1DgB,WAAYX,EAASW,WACrBC,YAAaZ,EAASY,WACvB,CAAC,CACF,EAuEMC,EAAgB,CAAEC,GAAIA,IAAM,IAAK,EACvC,SAAwBC,GAAsB,OAC7C,MAAMtB,EAAOuB,IAGPC,EAAgB,GADEC,SAAOzB,EAAAA,EAAK0B,YAAL1B,YAAAA,EAAgB2B,aAAc,IAAI,EACxBrB,SAAS,EAAG,GAAG,CAAC,IAAIN,EAAK4B,SAAS,GAE1E,OAAAC,EAAAA,KAAC,OAAK,CAAAC,UAAU,4FACfC,SAAA,CAAAF,EAAA,KAAC,UAAA,CACAnB,GAAIV,EAAKgC,UAETF,UAAU,8JAEVC,SAAA,CAACE,EAAA,IAAA,MAAA,CACAF,eAAC,KAAG,CAAAD,UAAU,4DACZC,SAAK/B,EAAAG,SAASQ,MAChB,CACD,CAAA,EACCsB,EAAA,IAAA,MAAA,CACCF,SAAK/B,EAAAG,SAAS+B,iBACdD,EAAAA,IAACE,EAAA,CACAC,sBAAuBpC,EAAKoC,sBAE5BL,SAAAE,EAAA,IAAC,MAAI,CAAAH,UAAU,sCACdC,SAAAE,EAAA,IAACI,EAAA,CACAC,KAAMtC,EAAKG,SAAS+B,iBACpBK,WAAYnB,EACb,EACD,CACD,CAAA,EAEA,wBAEF,CAAA,CAAA,CAAA,EAvBKpB,EAAKgC,SAwBX,EACAC,EAAAA,IAACO,EAAA,CACAC,aAAc,IAAIzC,EAAKgC,SAAS,EAAA,EAC3B,UAAUhC,EAAKgC,SAAS,EAC9B,EACAC,EAAA,IAACS,EAAA,CACAC,KAAK,eACLvC,eAAgBJ,EAAKI,eACrB0B,UAAU,oBAAA,CACX,EACAD,EAAA,KAAC,MAAI,CAAAC,UAAU,8DACdC,SAAA,CAAAE,EAAAA,IAAC,MAAI,CAAA,CAAA,EACLA,EAAA,IAACW,EAAA,CACAC,KAAM7C,EAAK8C,eAAeD,KAC1BE,aAAc/C,EAAK8C,eAAeC,YAAA,CACnC,EACAd,EAAA,IAACe,EAAA,CACAC,GAAIzB,EACJ0B,SAAS,SACTpB,UAAU,6EACVC,SAAA,gBAAA,CAED,CAAA,CACD,CAAA,CAAA,CACD,CAAA,CAEF,CAEO,SAASoB,GAAgB,CAC/B,MAAMC,EAAQC,IAEV,OAAA,OAAOC,SAAa,KACvBC,QAAQH,MAAMA,CAAK,EAGbI,EAAqBJ,CAAK,EAChCA,EAAMK,SAAW,IAChBxB,EAAA,IAAC,IAAE,CAAAF,SAAA,oCAAA,CAAkC,EAErCF,EAAA,KAAC,IACC,CAAAE,SAAA,CAAMqB,EAAAK,OAAO,IAAEL,EAAMpD,IAAA,CAAA,CACvB,EAGDiC,EAAA,IAAC,IAAG,CAAAF,SAAA2B,EAAgBN,CAAK,CAAE,CAAA,CAE7B"}
@@ -0,0 +1,2 @@
1
+ import{j as e}from"./index-Czg1ruVn.js";import{B as a}from"./button-BA3iiLRs.js";import{I as i}from"./misc-S5ZD98sI.js";import{S as o}from"./tooltip-BtzSIxlB.js";import{u as m,a as u}from"./user-CdUDQ7a8.js";import{u as x}from"./presence-CW1_eiIo.js";import{u as h,a as p,L as r,F as c}from"./components-wgHiPsTg.js";import"./clsx-B-dksMZM.js";import"./request-info-DHtGM4FI.js";function O(){const l=h(),d=p(),t=m(),s=u(),n=x();return e.jsxs("main",{className:"container flex h-full w-full max-w-3xl flex-grow flex-col items-center justify-center gap-4",children:[e.jsx("img",{className:"h-36 w-36 rounded-full",alt:(s==null?void 0:s.displayName)??t.name??t.email,src:t.avatarUrl}),e.jsx("h1",{className:"mb-1 text-2xl",children:"Your Account"}),e.jsx("p",{className:"text-center text-gray-700 dark:text-gray-300",children:t.name?`Hi ${(s==null?void 0:s.displayName)??t.name}, your device is logged in with ${t.email}.`:`Your device is logged in with ${t.email}.`}),s?e.jsxs(e.Fragment,{children:[e.jsxs("p",{className:"text-center text-gray-700 dark:text-gray-300",children:["And you are connected to discord as ",s.displayName," (",s.id,")."]}),e.jsxs("div",{className:"flex justify-center gap-2",children:[e.jsx(d.Form,{method:"post",children:e.jsx(a,{varient:"mono",name:"intent",value:"disconnect-discord",children:"Disconnect Discord"})}),e.jsx(o,{content:"Your discord connection gives you access to the exclusive Discord channels for Epic Web",children:e.jsx(i,{name:"Question",tabIndex:0})})]})]}):e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs(r,{to:l.discordAuthUrl,className:"inline-flex items-center gap-2 underline",children:[e.jsx(i,{name:"Discord",size:"lg"}),"Connect Discord"]}),e.jsx(o,{content:"This will give you access to the exclusive Discord channels for Epic Web",children:e.jsx(i,{name:"Question",tabIndex:0})})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs(c,{method:"POST",children:[e.jsx("input",{name:"optOut",type:"hidden",value:n!=null&&n.optOut?"false":"true"}),e.jsxs(a,{varient:"mono",name:"intent",value:"presence-opt-out",children:[n!=null&&n.optOut?"Opt in to":"Opt out of"," presence"]})]}),e.jsx(o,{content:"This controls whether your name and avatar are displayed in the pile of faces in navigation",children:e.jsx(i,{name:"Question",tabIndex:0})})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(c,{method:"post",children:e.jsx(a,{varient:"mono",name:"intent",value:"logout",children:"Log device out"})}),e.jsx(o,{content:e.jsxs("div",{children:["Note: it is your ",e.jsx("i",{className:"italic",children:"device"})," that's logged in, not your browser.",e.jsx("br",{}),"So all browsers on this device will be logged in with the same account on this device."]}),children:e.jsx(i,{name:"Question",tabIndex:0})})]}),e.jsxs("p",{children:["Check"," ",e.jsx(r,{to:"/onboarding",className:"underline",children:"/onboarding"})," ","if you'd like to review onboarding again."]}),e.jsxs("p",{children:["Check"," ",e.jsx(r,{to:"/support",className:"underline",children:"/support"})," ","if you need support."]})]})}export{O as default};
2
+ //# sourceMappingURL=account-uvU1jIL2.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"account-uvU1jIL2.js","sources":["../../../app/routes/_app+/account.tsx"],"sourcesContent":["import { deleteCache } from '@epic-web/workshop-utils/cache.server'\nimport {\n\tdeleteDb,\n\tdeleteDiscordInfo,\n\trequireAuthInfo,\n\tsetPresencePreferences,\n} from '@epic-web/workshop-utils/db.server'\nimport { json, redirect, type LoaderFunctionArgs } from '@remix-run/node'\nimport { Form, Link, useFetcher, useLoaderData } from '@remix-run/react'\nimport { Button } from '#app/components/button.tsx'\nimport { Icon } from '#app/components/icons.tsx'\nimport { SimpleTooltip } from '#app/components/ui/tooltip.js'\nimport { useOptionalDiscordMember, useUser } from '#app/components/user.tsx'\nimport { ensureUndeployed } from '#app/utils/misc.tsx'\nimport { usePresencePreferences } from '#app/utils/presence.tsx'\nimport { redirectWithToast } from '#app/utils/toast.server.ts'\nimport { getDiscordAuthURL } from '../discord.callback.ts'\n\nexport async function loader({ request }: LoaderFunctionArgs) {\n\tensureUndeployed()\n\tawait requireAuthInfo({ request })\n\treturn json({ discordAuthUrl: getDiscordAuthURL() })\n}\n\nexport async function action({ request }: { request: Request }) {\n\tensureUndeployed()\n\tconst formData = await request.formData()\n\tconst intent = formData.get('intent')\n\tif (intent === 'disconnect-discord') {\n\t\tawait deleteDiscordInfo()\n\t\treturn redirectWithToast('/account', {\n\t\t\ttype: 'success',\n\t\t\ttitle: 'Disconnected',\n\t\t\tdescription: 'Local discord data has been deleted.',\n\t\t})\n\t} else if (intent === 'logout') {\n\t\tawait deleteDb()\n\t\tawait deleteCache()\n\t\treturn redirectWithToast('/login', {\n\t\t\ttype: 'success',\n\t\t\ttitle: 'Logged out',\n\t\t\tdescription: 'Goodbye! Come back soon!',\n\t\t})\n\t} else if (intent === 'presence-opt-out') {\n\t\tconst optOut = formData.get('optOut') === 'true'\n\t\tawait setPresencePreferences({ optOut })\n\t\treturn redirectWithToast('/account', {\n\t\t\ttitle: optOut ? 'Opted out' : 'Opted in',\n\t\t\tdescription: `You are now ${optOut ? 'invisible' : 'visible'}.`,\n\t\t\ttype: 'success',\n\t\t})\n\t}\n\n\treturn redirect('/account')\n}\n\nexport default function Account() {\n\tconst data = useLoaderData<typeof loader>()\n\tconst disconnectFetcher = useFetcher()\n\tconst user = useUser()\n\tconst discordMember = useOptionalDiscordMember()\n\tconst presencePreferences = usePresencePreferences()\n\treturn (\n\t\t<main className=\"container flex h-full w-full max-w-3xl flex-grow flex-col items-center justify-center gap-4\">\n\t\t\t<img\n\t\t\t\tclassName=\"h-36 w-36 rounded-full\"\n\t\t\t\talt={discordMember?.displayName ?? user.name ?? user.email}\n\t\t\t\tsrc={user.avatarUrl}\n\t\t\t/>\n\t\t\t<h1 className=\"mb-1 text-2xl\">Your Account</h1>\n\t\t\t<p className=\"text-center text-gray-700 dark:text-gray-300\">\n\t\t\t\t{user.name\n\t\t\t\t\t? `Hi ${\n\t\t\t\t\t\t\tdiscordMember?.displayName ?? user.name\n\t\t\t\t\t\t}, your device is logged in with ${user.email}.`\n\t\t\t\t\t: `Your device is logged in with ${user.email}.`}\n\t\t\t</p>\n\t\t\t{discordMember ? (\n\t\t\t\t<>\n\t\t\t\t\t<p className=\"text-center text-gray-700 dark:text-gray-300\">\n\t\t\t\t\t\tAnd you are connected to discord as {discordMember.displayName} (\n\t\t\t\t\t\t{discordMember.id}).\n\t\t\t\t\t</p>\n\t\t\t\t\t<div className=\"flex justify-center gap-2\">\n\t\t\t\t\t\t<disconnectFetcher.Form method=\"post\">\n\t\t\t\t\t\t\t<Button varient=\"mono\" name=\"intent\" value=\"disconnect-discord\">\n\t\t\t\t\t\t\t\tDisconnect Discord\n\t\t\t\t\t\t\t</Button>\n\t\t\t\t\t\t</disconnectFetcher.Form>\n\t\t\t\t\t\t<SimpleTooltip content=\"Your discord connection gives you access to the exclusive Discord channels for Epic Web\">\n\t\t\t\t\t\t\t<Icon name=\"Question\" tabIndex={0} />\n\t\t\t\t\t\t</SimpleTooltip>\n\t\t\t\t\t</div>\n\t\t\t\t</>\n\t\t\t) : (\n\t\t\t\t<div className=\"flex items-center gap-2\">\n\t\t\t\t\t<Link\n\t\t\t\t\t\tto={data.discordAuthUrl}\n\t\t\t\t\t\tclassName=\"inline-flex items-center gap-2 underline\"\n\t\t\t\t\t>\n\t\t\t\t\t\t<Icon name=\"Discord\" size=\"lg\" />\n\t\t\t\t\t\tConnect Discord\n\t\t\t\t\t</Link>\n\t\t\t\t\t<SimpleTooltip content=\"This will give you access to the exclusive Discord channels for Epic Web\">\n\t\t\t\t\t\t<Icon name=\"Question\" tabIndex={0} />\n\t\t\t\t\t</SimpleTooltip>\n\t\t\t\t</div>\n\t\t\t)}\n\t\t\t<div className=\"flex items-center gap-2\">\n\t\t\t\t<Form method=\"POST\">\n\t\t\t\t\t<input\n\t\t\t\t\t\tname=\"optOut\"\n\t\t\t\t\t\ttype=\"hidden\"\n\t\t\t\t\t\tvalue={presencePreferences?.optOut ? 'false' : 'true'}\n\t\t\t\t\t/>\n\t\t\t\t\t<Button varient=\"mono\" name=\"intent\" value=\"presence-opt-out\">\n\t\t\t\t\t\t{presencePreferences?.optOut ? 'Opt in to' : 'Opt out of'} presence\n\t\t\t\t\t</Button>\n\t\t\t\t</Form>\n\t\t\t\t<SimpleTooltip content=\"This controls whether your name and avatar are displayed in the pile of faces in navigation\">\n\t\t\t\t\t<Icon name=\"Question\" tabIndex={0} />\n\t\t\t\t</SimpleTooltip>\n\t\t\t</div>\n\t\t\t<div className=\"flex items-center gap-2\">\n\t\t\t\t<Form method=\"post\">\n\t\t\t\t\t<Button varient=\"mono\" name=\"intent\" value=\"logout\">\n\t\t\t\t\t\tLog device out\n\t\t\t\t\t</Button>\n\t\t\t\t</Form>\n\t\t\t\t<SimpleTooltip\n\t\t\t\t\tcontent={\n\t\t\t\t\t\t<div>\n\t\t\t\t\t\t\tNote: it is your <i className=\"italic\">device</i> that's logged\n\t\t\t\t\t\t\tin, not your browser.\n\t\t\t\t\t\t\t<br />\n\t\t\t\t\t\t\tSo all browsers on this device will be logged in with the same\n\t\t\t\t\t\t\taccount on this device.\n\t\t\t\t\t\t</div>\n\t\t\t\t\t}\n\t\t\t\t>\n\t\t\t\t\t<Icon name=\"Question\" tabIndex={0} />\n\t\t\t\t</SimpleTooltip>\n\t\t\t</div>\n\t\t\t<p>\n\t\t\t\tCheck{' '}\n\t\t\t\t<Link to=\"/onboarding\" className=\"underline\">\n\t\t\t\t\t/onboarding\n\t\t\t\t</Link>{' '}\n\t\t\t\tif you'd like to review onboarding again.\n\t\t\t</p>\n\t\t\t<p>\n\t\t\t\tCheck{' '}\n\t\t\t\t<Link to=\"/support\" className=\"underline\">\n\t\t\t\t\t/support\n\t\t\t\t</Link>{' '}\n\t\t\t\tif you need support.\n\t\t\t</p>\n\t\t</main>\n\t)\n}\n"],"names":["Account","data","useLoaderData","disconnectFetcher","useFetcher","user","useUser","discordMember","useOptionalDiscordMember","presencePreferences","usePresencePreferences","jsxs","className","children","jsx","alt","displayName","name","email","src","avatarUrl","Fragment","id","Form","method","Button","varient","value","SimpleTooltip","content","Icon","tabIndex","Link","to","discordAuthUrl","size","type","optOut"],"mappings":"2XAwDA,SAAwBA,GAAU,CACjC,MAAMC,EAAOC,IACPC,EAAoBC,IACpBC,EAAOC,IACPC,EAAgBC,IAChBC,EAAsBC,IAE3B,OAAAC,EAAAA,KAAC,OAAK,CAAAC,UAAU,8FACfC,SAAA,CAAAC,EAAA,IAAC,MAAA,CACAF,UAAU,yBACVG,KAAKR,GAAAA,YAAAA,EAAeS,cAAeX,EAAKY,MAAQZ,EAAKa,MACrDC,IAAKd,EAAKe,SAAA,CACX,EACCN,EAAA,IAAA,KAAA,CAAGF,UAAU,gBAAgBC,SAAY,cAAA,CAAA,QACzC,IAAE,CAAAD,UAAU,+CACXC,SAAKR,EAAAY,KACH,OACAV,GAAAA,YAAAA,EAAeS,cAAeX,EAAKY,IACpC,mCAAmCZ,EAAKa,KAAK,IAC5C,iCAAiCb,EAAKa,KAAK,IAC/C,EACCX,EAECI,EAAA,KAAAU,WAAA,CAAAR,SAAA,CAACF,EAAA,KAAA,IAAA,CAAEC,UAAU,+CAA+CC,SAAA,CAAA,uCACtBN,EAAcS,YAAY,KAC9DT,EAAce,GAAG,IAAA,CACnB,CAAA,EACAX,EAAA,KAAC,MAAI,CAAAC,UAAU,4BACdC,SAAA,CAAAC,EAAAA,IAACX,EAAkBoB,KAAlB,CAAuBC,OAAO,OAC9BX,SAACC,EAAA,IAAAW,EAAA,CAAOC,QAAQ,OAAOT,KAAK,SAASU,MAAM,qBAAqBd,8BAEhE,CACD,CAAA,EACAC,EAAA,IAACc,EAAc,CAAAC,QAAQ,0FACtBhB,SAAAC,EAAA,IAACgB,GAAKb,KAAK,WAAWc,SAAU,EAAG,CACpC,CAAA,CAAA,CACD,CAAA,CAAA,CAAA,CACD,EAEApB,EAAA,KAAC,MAAI,CAAAC,UAAU,0BACdC,SAAA,CAAAF,EAAA,KAACqB,EAAA,CACAC,GAAIhC,EAAKiC,eACTtB,UAAU,2CAEVC,SAAA,CAAAC,EAAA,IAACgB,EAAK,CAAAb,KAAK,UAAUkB,KAAK,IAAK,CAAA,EAAE,iBAAA,CAAA,CAElC,EACArB,EAAA,IAACc,EAAc,CAAAC,QAAQ,2EACtBhB,SAAAC,EAAA,IAACgB,GAAKb,KAAK,WAAWc,SAAU,EAAG,CACpC,CAAA,CAAA,CACD,CAAA,EAEDpB,EAAA,KAAC,MAAI,CAAAC,UAAU,0BACdC,SAAA,CAACF,EAAA,KAAAY,EAAA,CAAKC,OAAO,OACZX,SAAA,CAAAC,EAAA,IAAC,QAAA,CACAG,KAAK,SACLmB,KAAK,SACLT,MAAOlB,GAAAA,MAAAA,EAAqB4B,OAAS,QAAU,MAAA,CAChD,SACCZ,EAAO,CAAAC,QAAQ,OAAOT,KAAK,SAASU,MAAM,mBACzCd,SAAA,CAAAJ,GAAAA,MAAAA,EAAqB4B,OAAS,YAAc,aAAa,WAAA,CAC3D,CAAA,CAAA,CACD,CAAA,EACAvB,EAAA,IAACc,EAAc,CAAAC,QAAQ,8FACtBhB,SAAAC,EAAA,IAACgB,GAAKb,KAAK,WAAWc,SAAU,EAAG,CACpC,CAAA,CAAA,CACD,CAAA,EACApB,EAAA,KAAC,MAAI,CAAAC,UAAU,0BACdC,SAAA,CAAAC,EAAA,IAACS,EAAK,CAAAC,OAAO,OACZX,SAAAC,EAAA,IAACW,EAAO,CAAAC,QAAQ,OAAOT,KAAK,SAASU,MAAM,SAASd,SAAA,iBAEpD,CACD,CAAA,EACAC,EAAA,IAACc,EAAA,CACAC,eACE,MAAI,CAAAhB,SAAA,CAAA,oBACcC,EAAA,IAAA,IAAA,CAAEF,UAAU,SAASC,SAAM,QAAA,CAAA,EAAI,6CAEhD,KAAG,CAAA,CAAA,EAAE,wFAAA,CAGP,CAAA,EAGDA,SAACC,EAAA,IAAAgB,EAAA,CAAKb,KAAK,WAAWc,SAAU,EAAG,CAAA,CACpC,CAAA,CACD,CAAA,SACC,IAAE,CAAAlB,SAAA,CAAA,QACI,UACLmB,EAAK,CAAAC,GAAG,cAAcrB,UAAU,YAAYC,SAE7C,aAAA,CAAA,EAAQ,IAAI,2CAAA,CAEb,CAAA,SACC,IAAE,CAAAA,SAAA,CAAA,QACI,UACLmB,EAAK,CAAAC,GAAG,WAAWrB,UAAU,YAAYC,SAE1C,UAAA,CAAA,EAAQ,IAAI,sBAAA,CAEb,CAAA,CAAA,CACD,CAAA,CAEF"}
@@ -1,2 +1,2 @@
1
- import{j as e}from"./index-Czg1ruVn.js";import{E as t}from"./index-D6ukHE4T.js";import{E as a}from"./epic-video-DJN9_SUj.js";import{G as i}from"./error-boundary-BVTbN8PZ.js";import{M as l,E as m}from"./mdx-BENF-kTQ.js";import{c as n}from"./misc-S5ZD98sI.js";import{P as c,u as d}from"./progress-BwanvUpB.js";import{u as p,L as x}from"./components-wgHiPsTg.js";import"./index-yEAxvbDV.js";import"./request-info-DHtGM4FI.js";import"./tooltip-BtzSIxlB.js";import"./client-hints-DLYDs4RF.js";import"./loading-B0uKxERz.js";import"./user-CdUDQ7a8.js";import"./clsx-B-dksMZM.js";import"./progress-bar-wMXWRGq0.js";function h({exercise:r}){const s=d(r.exerciseNumber);return e.jsx("li",{children:e.jsxs(x,{className:n("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:bg-gray-50 hover:after:translate-x-0 hover:after:opacity-100 dark:hover:bg-white/5",s),to:`${r.exerciseNumber.toString().padStart(2,"0")}`,children:[e.jsx("span",{className:"text-xs font-normal tabular-nums opacity-50",children:r.exerciseNumber}),e.jsx("span",{children:r.title})]})},r.exerciseNumber)}const f={h1:()=>null};function S(){const r=p(),s=e.jsxs("ul",{className:"flex flex-col divide-y divide-border dark:divide-border/50",children:[e.jsx("strong",{className:"px-10 pb-3 font-mono text-xs uppercase",children:"Exercises"}),r.exercises.map(o=>e.jsx(h,{exercise:o},o.exerciseNumber))]});return e.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:[e.jsxs("article",{id:r.articleId,className:"shadow-on-scrollbox flex w-full flex-1 flex-col gap-12 overflow-y-scroll px-3 py-4 pt-6 scrollbar-thin scrollbar-thumb-scrollbar md:px-10 md:py-12 md:pt-16",children:[e.jsx("div",{children:e.jsx("h1",{className:"px-10 text-[clamp(3rem,6vw,8.5rem)] font-extrabold leading-none",children:r.title})}),e.jsxs("div",{className:"w-full max-w-none scroll-pt-6 border-t px-3 pt-3 md:px-10 md:pt-8",children:[e.jsx("h2",{className:"pb-5 font-mono text-xs font-semibold uppercase",children:"Intro"}),r.workshopReadme.compiled.status==="success"&&r.workshopReadme.compiled.code?e.jsx(a,{epicVideoInfosPromise:r.epicVideoInfosPromise,children:e.jsx("div",{className:"prose dark:prose-invert sm:prose-lg",children:e.jsx(l,{code:r.workshopReadme.compiled.code,components:f})})}):r.workshopReadme.compiled.status==="error"?e.jsxs("div",{className:"text-red-500",children:["There was an error:",e.jsx("pre",{children:r.workshopReadme.compiled.error})]}):"No instructions yet..."]}),e.jsx("div",{className:"pb-5 pt-10",children:r.workshopReadme.compiled.status==="success"&&r.workshopReadme.compiled.code&&r.workshopReadme.compiled.code.length>500?s:null})]}),e.jsx(t,{elementQuery:`#${r.articleId}`}),e.jsx(c,{type:"workshop-instructions",className:"h-14 border-t px-6"}),e.jsx("div",{className:"flex h-16 justify-center border-t",children:e.jsx(m,{file:r.workshopReadme.file,relativePath:r.workshopReadme.relativePath})})]})}function V(){return e.jsx(i,{})}export{V as ErrorBoundary,S as default};
2
- //# sourceMappingURL=index-6edM1tdB.js.map
1
+ import{j as e}from"./index-Czg1ruVn.js";import{E as t}from"./index-D6ukHE4T.js";import{E as a}from"./epic-video-DJN9_SUj.js";import{G as i}from"./error-boundary-BVTbN8PZ.js";import{M as l,E as m}from"./mdx-BENF-kTQ.js";import{c as n}from"./misc-S5ZD98sI.js";import{P as c,u as d}from"./progress-BwanvUpB.js";import{u as p,L as x}from"./components-wgHiPsTg.js";import"./index-yEAxvbDV.js";import"./request-info-DHtGM4FI.js";import"./tooltip-BtzSIxlB.js";import"./client-hints-DLYDs4RF.js";import"./loading-B0uKxERz.js";import"./user-CdUDQ7a8.js";import"./clsx-B-dksMZM.js";import"./progress-bar-wMXWRGq0.js";function h({exercise:r}){const s=d(r.exerciseNumber);return e.jsx("li",{children:e.jsxs(x,{className:n("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:bg-gray-50 hover:after:translate-x-0 hover:after:opacity-100 dark:hover:bg-white/5",s),to:`${r.exerciseNumber.toString().padStart(2,"0")}`,children:[e.jsx("span",{className:"text-xs font-normal tabular-nums opacity-50",children:r.exerciseNumber}),e.jsx("span",{children:r.title})]})},r.exerciseNumber)}const f={h1:()=>null};function S(){const r=p(),s=e.jsxs("ul",{className:"flex flex-col divide-y divide-border dark:divide-border/50",children:[e.jsx("strong",{className:"px-10 pb-3 font-mono text-xs uppercase",children:"Exercises"}),r.exercises.map(o=>e.jsx(h,{exercise:o},o.exerciseNumber))]});return e.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:[e.jsxs("article",{id:r.articleId,className:"shadow-on-scrollbox flex w-full flex-1 flex-col gap-12 overflow-y-scroll px-3 py-4 pt-6 scrollbar-thin scrollbar-thumb-scrollbar md:px-10 md:py-12 md:pt-16",children:[e.jsx("div",{children:e.jsx("h1",{className:"px-10 text-[clamp(3rem,6vw,7.5rem)] font-extrabold leading-none",children:r.title})}),e.jsxs("div",{className:"w-full max-w-none scroll-pt-6 border-t px-3 pt-3 md:px-10 md:pt-8",children:[e.jsx("h2",{className:"pb-5 font-mono text-xs font-semibold uppercase",children:"Intro"}),r.workshopReadme.compiled.status==="success"&&r.workshopReadme.compiled.code?e.jsx(a,{epicVideoInfosPromise:r.epicVideoInfosPromise,children:e.jsx("div",{className:"prose dark:prose-invert sm:prose-lg",children:e.jsx(l,{code:r.workshopReadme.compiled.code,components:f})})}):r.workshopReadme.compiled.status==="error"?e.jsxs("div",{className:"text-red-500",children:["There was an error:",e.jsx("pre",{children:r.workshopReadme.compiled.error})]}):"No instructions yet..."]}),e.jsx("div",{className:"pb-5 pt-10",children:r.workshopReadme.compiled.status==="success"&&r.workshopReadme.compiled.code&&r.workshopReadme.compiled.code.length>500?s:null})]}),e.jsx(t,{elementQuery:`#${r.articleId}`}),e.jsx(c,{type:"workshop-instructions",className:"h-14 border-t px-6"}),e.jsx("div",{className:"flex h-16 justify-center border-t",children:e.jsx(m,{file:r.workshopReadme.file,relativePath:r.workshopReadme.relativePath})})]})}function V(){return e.jsx(i,{})}export{V as ErrorBoundary,S as default};
2
+ //# sourceMappingURL=index-3HxjMIAS.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index-6edM1tdB.js","sources":["../../../app/routes/_app+/index.tsx"],"sourcesContent":["import { ElementScrollRestoration } from '@epic-web/restore-scroll'\nimport {\n\tgetExercises,\n\tgetWorkshopInstructions,\n\tgetWorkshopTitle,\n} from '@epic-web/workshop-utils/apps.server'\nimport {\n\tcombineServerTimings,\n\tgetServerTimeHeader,\n\tmakeTimings,\n\ttime,\n} from '@epic-web/workshop-utils/timing.server'\nimport {\n\tdefer,\n\ttype HeadersFunction,\n\ttype LoaderFunctionArgs,\n\ttype SerializeFrom,\n} from '@remix-run/node'\nimport { Link, useLoaderData } from '@remix-run/react'\nimport slugify from '@sindresorhus/slugify'\nimport { EpicVideoInfoProvider } from '#app/components/epic-video.tsx'\nimport { GeneralErrorBoundary } from '#app/components/error-boundary.tsx'\nimport { EditFileOnGitHub } from '#app/routes/launch-editor.tsx'\nimport { getEpicVideoInfos } from '#app/utils/epic-api.ts'\nimport { Mdx } from '#app/utils/mdx.tsx'\nimport { cn } from '#app/utils/misc.tsx'\nimport { ProgressToggle, useExerciseProgressClassName } from '../progress.tsx'\n\nexport async function loader({ request }: LoaderFunctionArgs) {\n\tconst timings = makeTimings('indexLoader')\n\tconst [title, exercises, workshopReadme] = await Promise.all([\n\t\ttime(() => getWorkshopTitle(), {\n\t\t\ttimings,\n\t\t\ttype: 'getWorkshopTitle',\n\t\t\tdesc: 'getWorkshopTitle in index',\n\t\t}),\n\t\ttime(() => getExercises({ request, timings }), {\n\t\t\ttimings,\n\t\t\ttype: 'getExercises',\n\t\t\tdesc: 'getExercises in index',\n\t\t}),\n\t\ttime(() => getWorkshopInstructions({ request }), {\n\t\t\ttimings,\n\t\t\ttype: 'compileMdx',\n\t\t\tdesc: 'compileMdx in index',\n\t\t}),\n\t])\n\n\treturn defer(\n\t\t{\n\t\t\tarticleId: `workshop-${slugify(title)}-instructions`,\n\t\t\ttitle:\n\t\t\t\tworkshopReadme.compiled.status === 'success'\n\t\t\t\t\t? workshopReadme.compiled.title\n\t\t\t\t\t: title,\n\t\t\texercises: exercises.map((e) => ({\n\t\t\t\texerciseNumber: e.exerciseNumber,\n\t\t\t\ttitle: e.title,\n\t\t\t})),\n\t\t\tworkshopReadme,\n\t\t\tepicVideoInfosPromise:\n\t\t\t\tworkshopReadme.compiled.status === 'success'\n\t\t\t\t\t? getEpicVideoInfos(workshopReadme.compiled.epicVideoEmbeds, {\n\t\t\t\t\t\t\trequest,\n\t\t\t\t\t\t})\n\t\t\t\t\t: null,\n\t\t},\n\t\t{\n\t\t\theaders: {\n\t\t\t\t'Server-Timing': getServerTimeHeader(timings),\n\t\t\t},\n\t\t},\n\t)\n}\n\nexport const headers: HeadersFunction = ({ loaderHeaders, parentHeaders }) => {\n\tconst headers = {\n\t\t'Cache-Control': loaderHeaders.get('Cache-Control') ?? '',\n\t\t'Server-Timing': combineServerTimings(loaderHeaders, parentHeaders),\n\t}\n\treturn headers\n}\n\nfunction ExerciseListItem({\n\texercise,\n}: {\n\texercise: SerializeFrom<typeof loader>['exercises'][number]\n}) {\n\tconst progressClassName = useExerciseProgressClassName(\n\t\texercise.exerciseNumber,\n\t)\n\treturn (\n\t\t<li key={exercise.exerciseNumber}>\n\t\t\t<Link\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"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:bg-gray-50 hover:after:translate-x-0 hover:after:opacity-100 dark:hover:bg-white/5\",\n\t\t\t\t\tprogressClassName,\n\t\t\t\t)}\n\t\t\t\tto={`${exercise.exerciseNumber.toString().padStart(2, '0')}`}\n\t\t\t>\n\t\t\t\t<span className=\"text-xs font-normal tabular-nums opacity-50\">\n\t\t\t\t\t{exercise.exerciseNumber}\n\t\t\t\t</span>\n\t\t\t\t<span>{exercise.title}</span>\n\t\t\t</Link>\n\t\t</li>\n\t)\n}\n\nconst mdxComponents = { h1: () => null }\n\nexport default function Index() {\n\tconst data = useLoaderData<typeof loader>()\n\n\tconst exerciseLinks = (\n\t\t<ul className=\"flex flex-col divide-y divide-border dark:divide-border/50\">\n\t\t\t<strong className=\"px-10 pb-3 font-mono text-xs uppercase\">\n\t\t\t\tExercises\n\t\t\t</strong>\n\t\t\t{data.exercises.map((exercise) => (\n\t\t\t\t<ExerciseListItem key={exercise.exerciseNumber} exercise={exercise} />\n\t\t\t))}\n\t\t</ul>\n\t)\n\treturn (\n\t\t<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\">\n\t\t\t<article\n\t\t\t\tid={data.articleId}\n\t\t\t\tclassName=\"shadow-on-scrollbox flex w-full flex-1 flex-col gap-12 overflow-y-scroll px-3 py-4 pt-6 scrollbar-thin scrollbar-thumb-scrollbar md:px-10 md:py-12 md:pt-16\"\n\t\t\t>\n\t\t\t\t<div>\n\t\t\t\t\t<h1 className=\"px-10 text-[clamp(3rem,6vw,8.5rem)] font-extrabold leading-none\">\n\t\t\t\t\t\t{data.title}\n\t\t\t\t\t</h1>\n\t\t\t\t</div>\n\t\t\t\t<div className=\"w-full max-w-none scroll-pt-6 border-t px-3 pt-3 md:px-10 md:pt-8\">\n\t\t\t\t\t<h2 className=\"pb-5 font-mono text-xs font-semibold uppercase\">\n\t\t\t\t\t\tIntro\n\t\t\t\t\t</h2>\n\t\t\t\t\t{data.workshopReadme.compiled.status === 'success' &&\n\t\t\t\t\tdata.workshopReadme.compiled.code ? (\n\t\t\t\t\t\t<EpicVideoInfoProvider\n\t\t\t\t\t\t\tepicVideoInfosPromise={data.epicVideoInfosPromise}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<div className=\"prose dark:prose-invert sm:prose-lg\">\n\t\t\t\t\t\t\t\t<Mdx\n\t\t\t\t\t\t\t\t\tcode={data.workshopReadme.compiled.code}\n\t\t\t\t\t\t\t\t\tcomponents={mdxComponents}\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</EpicVideoInfoProvider>\n\t\t\t\t\t) : data.workshopReadme.compiled.status === 'error' ? (\n\t\t\t\t\t\t<div className=\"text-red-500\">\n\t\t\t\t\t\t\tThere was an error:\n\t\t\t\t\t\t\t<pre>{data.workshopReadme.compiled.error}</pre>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t) : (\n\t\t\t\t\t\t'No instructions yet...'\n\t\t\t\t\t)}\n\t\t\t\t</div>\n\t\t\t\t<div className=\"pb-5 pt-10\">\n\t\t\t\t\t{data.workshopReadme.compiled.status === 'success' &&\n\t\t\t\t\tdata.workshopReadme.compiled.code &&\n\t\t\t\t\tdata.workshopReadme.compiled.code.length > 500\n\t\t\t\t\t\t? exerciseLinks\n\t\t\t\t\t\t: null}\n\t\t\t\t</div>\n\t\t\t</article>\n\t\t\t<ElementScrollRestoration elementQuery={`#${data.articleId}`} />\n\t\t\t<ProgressToggle\n\t\t\t\ttype=\"workshop-instructions\"\n\t\t\t\tclassName=\"h-14 border-t px-6\"\n\t\t\t/>\n\t\t\t<div className=\"flex h-16 justify-center border-t\">\n\t\t\t\t<EditFileOnGitHub\n\t\t\t\t\tfile={data.workshopReadme.file}\n\t\t\t\t\trelativePath={data.workshopReadme.relativePath}\n\t\t\t\t/>\n\t\t\t</div>\n\t\t</main>\n\t)\n}\n\nexport function ErrorBoundary() {\n\treturn <GeneralErrorBoundary />\n}\n"],"names":["ExerciseListItem","exercise","progressClassName","useExerciseProgressClassName","exerciseNumber","children","jsxs","Link","className","cn","to","toString","padStart","jsx","title","mdxComponents","h1","Index","data","useLoaderData","exerciseLinks","exercises","map","id","articleId","workshopReadme","compiled","status","code","EpicVideoInfoProvider","epicVideoInfosPromise","Mdx","components","error","length","ElementScrollRestoration","elementQuery","ProgressToggle","type","EditFileOnGitHub","file","relativePath","ErrorBoundary","GeneralErrorBoundary"],"mappings":"+lBAmFA,SAASA,EAAiB,CACzBC,SAAAA,CACD,EAEG,CACF,MAAMC,EAAoBC,EACzBF,EAASG,cACV,EACA,aACE,KACA,CAAAC,SAAAC,EAAA,KAACC,EAAA,CACAC,UAAWC,EACV,+QACAP,CACD,EACAQ,GAAI,GAAGT,EAASG,eAAeO,SAAW,EAAAC,SAAS,EAAG,GAAG,CAAC,GAE1DP,SAAA,CAAAQ,EAAA,IAAC,OAAK,CAAAL,UAAU,8CACdH,SAAAJ,EAASG,cACX,CAAA,EACAS,EAAA,IAAC,OAAM,CAAAR,SAAAJ,EAASa,KAAM,CAAA,CAAA,EACvB,CAAA,EAZQb,EAASG,cAalB,CAEF,CAEA,MAAMW,EAAgB,CAAEC,GAAIA,IAAM,IAAK,EAEvC,SAAwBC,GAAQ,CAC/B,MAAMC,EAAOC,IAEPC,EACLd,EAAA,KAAC,KAAG,CAAAE,UAAU,6DACbH,SAAA,CAACQ,EAAA,IAAA,SAAA,CAAOL,UAAU,yCAAyCH,SAE3D,WAAA,CAAA,EACCa,EAAKG,UAAUC,IAAKrB,SACnBD,EAA+C,CAAAC,SAAAA,CAAA,EAAzBA,EAASG,cAAoC,CACpE,CAAA,CACF,CAAA,EAGA,OAAAE,EAAAA,KAAC,OAAK,CAAAE,UAAU,4FACfH,SAAA,CAAAC,EAAA,KAAC,UAAA,CACAiB,GAAIL,EAAKM,UACThB,UAAU,8JAEVH,SAAA,CAAAQ,EAAA,IAAC,OACAR,SAACQ,EAAA,IAAA,KAAA,CAAGL,UAAU,kEACZH,SAAAa,EAAKJ,MACP,CACD,CAAA,EACAR,EAAA,KAAC,MAAI,CAAAE,UAAU,oEACdH,SAAA,CAACQ,EAAA,IAAA,KAAA,CAAGL,UAAU,iDAAiDH,SAE/D,OAAA,CAAA,EACCa,EAAKO,eAAeC,SAASC,SAAW,WACzCT,EAAKO,eAAeC,SAASE,KAC5Bf,EAAAA,IAACgB,EAAA,CACAC,sBAAuBZ,EAAKY,sBAE5BzB,SAAAQ,EAAA,IAAC,MAAI,CAAAL,UAAU,sCACdH,SAAAQ,EAAA,IAACkB,EAAA,CACAH,KAAMV,EAAKO,eAAeC,SAASE,KACnCI,WAAYjB,EACb,EACD,CAAA,CACD,EACGG,EAAKO,eAAeC,SAASC,SAAW,QAC3CrB,EAAA,KAAC,MAAI,CAAAE,UAAU,eAAeH,SAAA,CAAA,sBAE5BQ,EAAA,IAAA,MAAA,CAAKR,SAAKa,EAAAO,eAAeC,SAASO,KAAM,CAAA,CAAA,CAC1C,CAAA,EAEA,wBAAA,CAEF,CAAA,EACApB,EAAA,IAAC,OAAIL,UAAU,aACbH,WAAKoB,eAAeC,SAASC,SAAW,WACzCT,EAAKO,eAAeC,SAASE,MAC7BV,EAAKO,eAAeC,SAASE,KAAKM,OAAS,IACxCd,EACA,IACJ,CAAA,CAAA,CAAA,CACD,QACCe,EAAyB,CAAAC,aAAc,IAAIlB,EAAKM,SAAS,EAAI,CAAA,EAC9DX,EAAA,IAACwB,EAAA,CACAC,KAAK,wBACL9B,UAAU,oBAAA,CACX,EACAK,EAAA,IAAC,MAAI,CAAAL,UAAU,oCACdH,SAAAQ,EAAA,IAAC0B,EAAA,CACAC,KAAMtB,EAAKO,eAAee,KAC1BC,aAAcvB,EAAKO,eAAegB,aACnC,CACD,CAAA,CAAA,CACD,CAAA,CAEF,CAEO,SAASC,GAAgB,CAC/B,aAAQC,EAAqB,CAAA,CAAA,CAC9B"}
1
+ {"version":3,"file":"index-3HxjMIAS.js","sources":["../../../app/routes/_app+/index.tsx"],"sourcesContent":["import { ElementScrollRestoration } from '@epic-web/restore-scroll'\nimport {\n\tgetExercises,\n\tgetWorkshopInstructions,\n\tgetWorkshopTitle,\n} from '@epic-web/workshop-utils/apps.server'\nimport {\n\tcombineServerTimings,\n\tgetServerTimeHeader,\n\tmakeTimings,\n\ttime,\n} from '@epic-web/workshop-utils/timing.server'\nimport {\n\tdefer,\n\ttype HeadersFunction,\n\ttype LoaderFunctionArgs,\n\ttype SerializeFrom,\n} from '@remix-run/node'\nimport { Link, useLoaderData } from '@remix-run/react'\nimport slugify from '@sindresorhus/slugify'\nimport { EpicVideoInfoProvider } from '#app/components/epic-video.tsx'\nimport { GeneralErrorBoundary } from '#app/components/error-boundary.tsx'\nimport { EditFileOnGitHub } from '#app/routes/launch-editor.tsx'\nimport { getEpicVideoInfos } from '#app/utils/epic-api.ts'\nimport { Mdx } from '#app/utils/mdx.tsx'\nimport { cn } from '#app/utils/misc.tsx'\nimport { ProgressToggle, useExerciseProgressClassName } from '../progress.tsx'\n\nexport async function loader({ request }: LoaderFunctionArgs) {\n\tconst timings = makeTimings('indexLoader')\n\tconst [title, exercises, workshopReadme] = await Promise.all([\n\t\ttime(() => getWorkshopTitle(), {\n\t\t\ttimings,\n\t\t\ttype: 'getWorkshopTitle',\n\t\t\tdesc: 'getWorkshopTitle in index',\n\t\t}),\n\t\ttime(() => getExercises({ request, timings }), {\n\t\t\ttimings,\n\t\t\ttype: 'getExercises',\n\t\t\tdesc: 'getExercises in index',\n\t\t}),\n\t\ttime(() => getWorkshopInstructions({ request }), {\n\t\t\ttimings,\n\t\t\ttype: 'compileMdx',\n\t\t\tdesc: 'compileMdx in index',\n\t\t}),\n\t])\n\n\treturn defer(\n\t\t{\n\t\t\tarticleId: `workshop-${slugify(title)}-instructions`,\n\t\t\ttitle:\n\t\t\t\tworkshopReadme.compiled.status === 'success'\n\t\t\t\t\t? workshopReadme.compiled.title\n\t\t\t\t\t: title,\n\t\t\texercises: exercises.map((e) => ({\n\t\t\t\texerciseNumber: e.exerciseNumber,\n\t\t\t\ttitle: e.title,\n\t\t\t})),\n\t\t\tworkshopReadme,\n\t\t\tepicVideoInfosPromise:\n\t\t\t\tworkshopReadme.compiled.status === 'success'\n\t\t\t\t\t? getEpicVideoInfos(workshopReadme.compiled.epicVideoEmbeds, {\n\t\t\t\t\t\t\trequest,\n\t\t\t\t\t\t})\n\t\t\t\t\t: null,\n\t\t},\n\t\t{\n\t\t\theaders: {\n\t\t\t\t'Server-Timing': getServerTimeHeader(timings),\n\t\t\t},\n\t\t},\n\t)\n}\n\nexport const headers: HeadersFunction = ({ loaderHeaders, parentHeaders }) => {\n\tconst headers = {\n\t\t'Cache-Control': loaderHeaders.get('Cache-Control') ?? '',\n\t\t'Server-Timing': combineServerTimings(loaderHeaders, parentHeaders),\n\t}\n\treturn headers\n}\n\nfunction ExerciseListItem({\n\texercise,\n}: {\n\texercise: SerializeFrom<typeof loader>['exercises'][number]\n}) {\n\tconst progressClassName = useExerciseProgressClassName(\n\t\texercise.exerciseNumber,\n\t)\n\treturn (\n\t\t<li key={exercise.exerciseNumber}>\n\t\t\t<Link\n\t\t\t\tclassName={cn(\n\t\t\t\t\t\"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:bg-gray-50 hover:after:translate-x-0 hover:after:opacity-100 dark:hover:bg-white/5\",\n\t\t\t\t\tprogressClassName,\n\t\t\t\t)}\n\t\t\t\tto={`${exercise.exerciseNumber.toString().padStart(2, '0')}`}\n\t\t\t>\n\t\t\t\t<span className=\"text-xs font-normal tabular-nums opacity-50\">\n\t\t\t\t\t{exercise.exerciseNumber}\n\t\t\t\t</span>\n\t\t\t\t<span>{exercise.title}</span>\n\t\t\t</Link>\n\t\t</li>\n\t)\n}\n\nconst mdxComponents = { h1: () => null }\n\nexport default function Index() {\n\tconst data = useLoaderData<typeof loader>()\n\n\tconst exerciseLinks = (\n\t\t<ul className=\"flex flex-col divide-y divide-border dark:divide-border/50\">\n\t\t\t<strong className=\"px-10 pb-3 font-mono text-xs uppercase\">\n\t\t\t\tExercises\n\t\t\t</strong>\n\t\t\t{data.exercises.map((exercise) => (\n\t\t\t\t<ExerciseListItem key={exercise.exerciseNumber} exercise={exercise} />\n\t\t\t))}\n\t\t</ul>\n\t)\n\treturn (\n\t\t<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\">\n\t\t\t<article\n\t\t\t\tid={data.articleId}\n\t\t\t\tclassName=\"shadow-on-scrollbox flex w-full flex-1 flex-col gap-12 overflow-y-scroll px-3 py-4 pt-6 scrollbar-thin scrollbar-thumb-scrollbar md:px-10 md:py-12 md:pt-16\"\n\t\t\t>\n\t\t\t\t<div>\n\t\t\t\t\t<h1 className=\"px-10 text-[clamp(3rem,6vw,7.5rem)] font-extrabold leading-none\">\n\t\t\t\t\t\t{data.title}\n\t\t\t\t\t</h1>\n\t\t\t\t</div>\n\t\t\t\t<div className=\"w-full max-w-none scroll-pt-6 border-t px-3 pt-3 md:px-10 md:pt-8\">\n\t\t\t\t\t<h2 className=\"pb-5 font-mono text-xs font-semibold uppercase\">\n\t\t\t\t\t\tIntro\n\t\t\t\t\t</h2>\n\t\t\t\t\t{data.workshopReadme.compiled.status === 'success' &&\n\t\t\t\t\tdata.workshopReadme.compiled.code ? (\n\t\t\t\t\t\t<EpicVideoInfoProvider\n\t\t\t\t\t\t\tepicVideoInfosPromise={data.epicVideoInfosPromise}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<div className=\"prose dark:prose-invert sm:prose-lg\">\n\t\t\t\t\t\t\t\t<Mdx\n\t\t\t\t\t\t\t\t\tcode={data.workshopReadme.compiled.code}\n\t\t\t\t\t\t\t\t\tcomponents={mdxComponents}\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</EpicVideoInfoProvider>\n\t\t\t\t\t) : data.workshopReadme.compiled.status === 'error' ? (\n\t\t\t\t\t\t<div className=\"text-red-500\">\n\t\t\t\t\t\t\tThere was an error:\n\t\t\t\t\t\t\t<pre>{data.workshopReadme.compiled.error}</pre>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t) : (\n\t\t\t\t\t\t'No instructions yet...'\n\t\t\t\t\t)}\n\t\t\t\t</div>\n\t\t\t\t<div className=\"pb-5 pt-10\">\n\t\t\t\t\t{data.workshopReadme.compiled.status === 'success' &&\n\t\t\t\t\tdata.workshopReadme.compiled.code &&\n\t\t\t\t\tdata.workshopReadme.compiled.code.length > 500\n\t\t\t\t\t\t? exerciseLinks\n\t\t\t\t\t\t: null}\n\t\t\t\t</div>\n\t\t\t</article>\n\t\t\t<ElementScrollRestoration elementQuery={`#${data.articleId}`} />\n\t\t\t<ProgressToggle\n\t\t\t\ttype=\"workshop-instructions\"\n\t\t\t\tclassName=\"h-14 border-t px-6\"\n\t\t\t/>\n\t\t\t<div className=\"flex h-16 justify-center border-t\">\n\t\t\t\t<EditFileOnGitHub\n\t\t\t\t\tfile={data.workshopReadme.file}\n\t\t\t\t\trelativePath={data.workshopReadme.relativePath}\n\t\t\t\t/>\n\t\t\t</div>\n\t\t</main>\n\t)\n}\n\nexport function ErrorBoundary() {\n\treturn <GeneralErrorBoundary />\n}\n"],"names":["ExerciseListItem","exercise","progressClassName","useExerciseProgressClassName","exerciseNumber","children","jsxs","Link","className","cn","to","toString","padStart","jsx","title","mdxComponents","h1","Index","data","useLoaderData","exerciseLinks","exercises","map","id","articleId","workshopReadme","compiled","status","code","EpicVideoInfoProvider","epicVideoInfosPromise","Mdx","components","error","length","ElementScrollRestoration","elementQuery","ProgressToggle","type","EditFileOnGitHub","file","relativePath","ErrorBoundary","GeneralErrorBoundary"],"mappings":"+lBAmFA,SAASA,EAAiB,CACzBC,SAAAA,CACD,EAEG,CACF,MAAMC,EAAoBC,EACzBF,EAASG,cACV,EACA,aACE,KACA,CAAAC,SAAAC,EAAA,KAACC,EAAA,CACAC,UAAWC,EACV,+QACAP,CACD,EACAQ,GAAI,GAAGT,EAASG,eAAeO,SAAW,EAAAC,SAAS,EAAG,GAAG,CAAC,GAE1DP,SAAA,CAAAQ,EAAA,IAAC,OAAK,CAAAL,UAAU,8CACdH,SAAAJ,EAASG,cACX,CAAA,EACAS,EAAA,IAAC,OAAM,CAAAR,SAAAJ,EAASa,KAAM,CAAA,CAAA,EACvB,CAAA,EAZQb,EAASG,cAalB,CAEF,CAEA,MAAMW,EAAgB,CAAEC,GAAIA,IAAM,IAAK,EAEvC,SAAwBC,GAAQ,CAC/B,MAAMC,EAAOC,IAEPC,EACLd,EAAA,KAAC,KAAG,CAAAE,UAAU,6DACbH,SAAA,CAACQ,EAAA,IAAA,SAAA,CAAOL,UAAU,yCAAyCH,SAE3D,WAAA,CAAA,EACCa,EAAKG,UAAUC,IAAKrB,SACnBD,EAA+C,CAAAC,SAAAA,CAAA,EAAzBA,EAASG,cAAoC,CACpE,CAAA,CACF,CAAA,EAGA,OAAAE,EAAAA,KAAC,OAAK,CAAAE,UAAU,4FACfH,SAAA,CAAAC,EAAA,KAAC,UAAA,CACAiB,GAAIL,EAAKM,UACThB,UAAU,8JAEVH,SAAA,CAAAQ,EAAA,IAAC,OACAR,SAACQ,EAAA,IAAA,KAAA,CAAGL,UAAU,kEACZH,SAAAa,EAAKJ,MACP,CACD,CAAA,EACAR,EAAA,KAAC,MAAI,CAAAE,UAAU,oEACdH,SAAA,CAACQ,EAAA,IAAA,KAAA,CAAGL,UAAU,iDAAiDH,SAE/D,OAAA,CAAA,EACCa,EAAKO,eAAeC,SAASC,SAAW,WACzCT,EAAKO,eAAeC,SAASE,KAC5Bf,EAAAA,IAACgB,EAAA,CACAC,sBAAuBZ,EAAKY,sBAE5BzB,SAAAQ,EAAA,IAAC,MAAI,CAAAL,UAAU,sCACdH,SAAAQ,EAAA,IAACkB,EAAA,CACAH,KAAMV,EAAKO,eAAeC,SAASE,KACnCI,WAAYjB,EACb,EACD,CAAA,CACD,EACGG,EAAKO,eAAeC,SAASC,SAAW,QAC3CrB,EAAA,KAAC,MAAI,CAAAE,UAAU,eAAeH,SAAA,CAAA,sBAE5BQ,EAAA,IAAA,MAAA,CAAKR,SAAKa,EAAAO,eAAeC,SAASO,KAAM,CAAA,CAAA,CAC1C,CAAA,EAEA,wBAAA,CAEF,CAAA,EACApB,EAAA,IAAC,OAAIL,UAAU,aACbH,WAAKoB,eAAeC,SAASC,SAAW,WACzCT,EAAKO,eAAeC,SAASE,MAC7BV,EAAKO,eAAeC,SAASE,KAAKM,OAAS,IACxCd,EACA,IACJ,CAAA,CAAA,CAAA,CACD,QACCe,EAAyB,CAAAC,aAAc,IAAIlB,EAAKM,SAAS,EAAI,CAAA,EAC9DX,EAAA,IAACwB,EAAA,CACAC,KAAK,wBACL9B,UAAU,oBAAA,CACX,EACAK,EAAA,IAAC,MAAI,CAAAL,UAAU,oCACdH,SAAAQ,EAAA,IAAC0B,EAAA,CACAC,KAAMtB,EAAKO,eAAee,KAC1BC,aAAcvB,EAAKO,eAAegB,aACnC,CACD,CAAA,CAAA,CACD,CAAA,CAEF,CAEO,SAASC,GAAgB,CAC/B,aAAQC,EAAqB,CAAA,CAAA,CAC9B"}
@@ -0,0 +1 @@
1
+ window.__remixManifest={"entry":{"module":"/assets/entry.client-Cs8lBz8l.js","imports":["/assets/index-Czg1ruVn.js","/assets/components-wgHiPsTg.js"],"css":[]},"routes":{"root":{"id":"root","path":"","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":true,"module":"/assets/root-C9KM-7Ur.js","imports":["/assets/index-Czg1ruVn.js","/assets/components-wgHiPsTg.js","/assets/clsx-B-dksMZM.js","/assets/misc-S5ZD98sI.js","/assets/request-info-DHtGM4FI.js","/assets/tooltip-BtzSIxlB.js","/assets/client-hints-DLYDs4RF.js","/assets/error-boundary-BVTbN8PZ.js","/assets/progress-bar-wMXWRGq0.js","/assets/index-DjzedX4O.js","/assets/index-yEAxvbDV.js","/assets/presence-CW1_eiIo.js","/assets/seo-pBpFCWsy.js"],"css":[]},"routes/$":{"id":"routes/$","parentId":"root","path":"*","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":true,"module":"/assets/_-DYArYM0Z.js","imports":["/assets/index-Czg1ruVn.js","/assets/clsx-B-dksMZM.js","/assets/components-wgHiPsTg.js","/assets/misc-S5ZD98sI.js","/assets/error-boundary-BVTbN8PZ.js"],"css":[]},"routes/_app+/_layout":{"id":"routes/_app+/_layout","parentId":"root","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/_layout-dHX2Hcew.js","imports":["/assets/index-Czg1ruVn.js","/assets/clsx-B-dksMZM.js","/assets/components-wgHiPsTg.js","/assets/misc-S5ZD98sI.js","/assets/tooltip-BtzSIxlB.js","/assets/request-info-DHtGM4FI.js","/assets/client-hints-DLYDs4RF.js","/assets/index-C6ToujzV.js","/assets/user-CdUDQ7a8.js","/assets/presence-CW1_eiIo.js","/assets/progress-BwanvUpB.js","/assets/index-yEAxvbDV.js"],"css":[]},"routes/_app+/_exercises+/_layout":{"id":"routes/_app+/_exercises+/_layout","parentId":"routes/_app+/_layout","hasAction":false,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/_layout-DaZNLfOL.js","imports":["/assets/index-Czg1ruVn.js"],"css":[]},"routes/_app+/_exercises+/$exerciseNumber":{"id":"routes/_app+/_exercises+/$exerciseNumber","parentId":"routes/_app+/_exercises+/_layout","path":":exerciseNumber","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":true,"module":"/assets/_exerciseNumber-Ccwr4LZw.js","imports":["/assets/index-Czg1ruVn.js","/assets/components-wgHiPsTg.js","/assets/clsx-B-dksMZM.js","/assets/misc-S5ZD98sI.js","/assets/request-info-DHtGM4FI.js","/assets/tooltip-BtzSIxlB.js","/assets/client-hints-DLYDs4RF.js","/assets/index-yEAxvbDV.js","/assets/loading-B0uKxERz.js","/assets/user-CdUDQ7a8.js","/assets/epic-video-DJN9_SUj.js","/assets/progress-bar-wMXWRGq0.js","/assets/index-D6ukHE4T.js","/assets/mdx-BENF-kTQ.js","/assets/progress-BwanvUpB.js","/assets/seo-pBpFCWsy.js"],"css":["/assets/epic-video-DUnRvy1A.css"]},"routes/_app+/_exercises+/$exerciseNumber_.$stepNumber":{"id":"routes/_app+/_exercises+/$exerciseNumber_.$stepNumber","parentId":"routes/_app+/_exercises+/_layout","path":":exerciseNumber/:stepNumber","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":true,"module":"/assets/_exerciseNumber_._stepNumber-Ct5BCuA1.js","imports":["/assets/index-Czg1ruVn.js","/assets/clsx-B-dksMZM.js","/assets/components-wgHiPsTg.js","/assets/misc-S5ZD98sI.js"],"css":[]},"routes/_app+/_exercises+/$exerciseNumber_.$stepNumber.$type+/_layout":{"id":"routes/_app+/_exercises+/$exerciseNumber_.$stepNumber.$type+/_layout","parentId":"routes/_app+/_exercises+/$exerciseNumber_.$stepNumber","path":":type","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":true,"module":"/assets/_layout-Bn9QhWq9.js","imports":["/assets/index-Czg1ruVn.js","/assets/clsx-B-dksMZM.js","/assets/components-wgHiPsTg.js","/assets/misc-S5ZD98sI.js","/assets/tooltip-BtzSIxlB.js","/assets/request-info-DHtGM4FI.js","/assets/client-hints-DLYDs4RF.js","/assets/index-yEAxvbDV.js","/assets/loading-B0uKxERz.js","/assets/user-CdUDQ7a8.js","/assets/epic-video-DJN9_SUj.js","/assets/progress-bar-wMXWRGq0.js","/assets/index-C6ToujzV.js","/assets/mdx-BENF-kTQ.js","/assets/index-D6ukHE4T.js","/assets/diff-CpG96hGZ.js","/assets/error-boundary-BVTbN8PZ.js","/assets/nav-chevrons-DaXg0NPS.js","/assets/progress-BwanvUpB.js","/assets/seo-pBpFCWsy.js","/assets/discord-yZor-3t1.js","/assets/index-DjzedX4O.js","/assets/button-BA3iiLRs.js","/assets/use-event-source-ySol3hbz.js"],"css":["/assets/epic-video-DUnRvy1A.css"]},"routes/_app+/_exercises+/$exerciseNumber_.$stepNumber.index":{"id":"routes/_app+/_exercises+/$exerciseNumber_.$stepNumber.index","parentId":"routes/_app+/_exercises+/$exerciseNumber_.$stepNumber","index":true,"hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/_exerciseNumber_._stepNumber.index-l0sNRNKZ.js","imports":[],"css":[]},"routes/_app+/_exercises+/$exerciseNumber_.finished":{"id":"routes/_app+/_exercises+/$exerciseNumber_.finished","parentId":"routes/_app+/_exercises+/_layout","path":":exerciseNumber/finished","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/_exerciseNumber_.finished-gEWcHsfL.js","imports":["/assets/index-Czg1ruVn.js","/assets/components-wgHiPsTg.js","/assets/clsx-B-dksMZM.js","/assets/misc-S5ZD98sI.js","/assets/request-info-DHtGM4FI.js","/assets/tooltip-BtzSIxlB.js","/assets/client-hints-DLYDs4RF.js","/assets/index-yEAxvbDV.js","/assets/loading-B0uKxERz.js","/assets/user-CdUDQ7a8.js","/assets/epic-video-DJN9_SUj.js","/assets/progress-bar-wMXWRGq0.js","/assets/index-D6ukHE4T.js","/assets/nav-chevrons-DaXg0NPS.js","/assets/mdx-BENF-kTQ.js","/assets/progress-BwanvUpB.js","/assets/seo-pBpFCWsy.js"],"css":["/assets/epic-video-DUnRvy1A.css"]},"routes/_app+/account":{"id":"routes/_app+/account","parentId":"routes/_app+/_layout","path":"account","hasAction":true,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/account-uvU1jIL2.js","imports":["/assets/index-Czg1ruVn.js","/assets/clsx-B-dksMZM.js","/assets/components-wgHiPsTg.js","/assets/misc-S5ZD98sI.js","/assets/request-info-DHtGM4FI.js","/assets/button-BA3iiLRs.js","/assets/tooltip-BtzSIxlB.js","/assets/user-CdUDQ7a8.js","/assets/presence-CW1_eiIo.js"],"css":[]},"routes/_app+/app.$appName+/$":{"id":"routes/_app+/app.$appName+/$","parentId":"routes/_app+/_layout","path":"app/:appName/*","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/_-l0sNRNKZ.js","imports":[],"css":[]},"routes/_app+/app.$appName+/api.$":{"id":"routes/_app+/app.$appName+/api.$","parentId":"routes/_app+/_layout","path":"app/:appName/api/*","hasAction":true,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/api._-l0sNRNKZ.js","imports":[],"css":[]},"routes/_app+/app.$appName+/epic_ws[.js]":{"id":"routes/_app+/app.$appName+/epic_ws[.js]","parentId":"routes/_app+/_layout","path":"app/:appName/epic_ws.js","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/epic_ws_.js_-l0sNRNKZ.js","imports":[],"css":[]},"routes/_app+/app.$appName+/index":{"id":"routes/_app+/app.$appName+/index","parentId":"routes/_app+/_layout","path":"app/:appName/","index":true,"hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/index-l0sNRNKZ.js","imports":[],"css":[]},"routes/_app+/app.$appName+/test.$testName":{"id":"routes/_app+/app.$appName+/test.$testName","parentId":"routes/_app+/_layout","path":"app/:appName/test/:testName","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/test._testName-l0sNRNKZ.js","imports":[],"css":[]},"routes/_app+/discord":{"id":"routes/_app+/discord","parentId":"routes/_app+/_layout","path":"discord","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/discord-CgwNGD2p.js","imports":["/assets/index-Czg1ruVn.js","/assets/clsx-B-dksMZM.js","/assets/components-wgHiPsTg.js","/assets/misc-S5ZD98sI.js","/assets/user-CdUDQ7a8.js","/assets/discord-yZor-3t1.js"],"css":[]},"routes/_app+/finished":{"id":"routes/_app+/finished","parentId":"routes/_app+/_layout","path":"finished","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/finished-B9qjUR4B.js","imports":["/assets/index-Czg1ruVn.js","/assets/components-wgHiPsTg.js","/assets/clsx-B-dksMZM.js","/assets/misc-S5ZD98sI.js","/assets/request-info-DHtGM4FI.js","/assets/tooltip-BtzSIxlB.js","/assets/client-hints-DLYDs4RF.js","/assets/index-yEAxvbDV.js","/assets/loading-B0uKxERz.js","/assets/user-CdUDQ7a8.js","/assets/epic-video-DJN9_SUj.js","/assets/progress-bar-wMXWRGq0.js","/assets/index-D6ukHE4T.js","/assets/nav-chevrons-DaXg0NPS.js","/assets/mdx-BENF-kTQ.js","/assets/seo-pBpFCWsy.js","/assets/progress-BwanvUpB.js"],"css":["/assets/epic-video-DUnRvy1A.css"]},"routes/_app+/index":{"id":"routes/_app+/index","parentId":"routes/_app+/_layout","index":true,"hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":true,"module":"/assets/index-3HxjMIAS.js","imports":["/assets/index-Czg1ruVn.js","/assets/components-wgHiPsTg.js","/assets/clsx-B-dksMZM.js","/assets/misc-S5ZD98sI.js","/assets/request-info-DHtGM4FI.js","/assets/tooltip-BtzSIxlB.js","/assets/client-hints-DLYDs4RF.js","/assets/index-yEAxvbDV.js","/assets/loading-B0uKxERz.js","/assets/user-CdUDQ7a8.js","/assets/epic-video-DJN9_SUj.js","/assets/progress-bar-wMXWRGq0.js","/assets/index-D6ukHE4T.js","/assets/error-boundary-BVTbN8PZ.js","/assets/mdx-BENF-kTQ.js","/assets/progress-BwanvUpB.js"],"css":["/assets/epic-video-DUnRvy1A.css"]},"routes/_app+/login":{"id":"routes/_app+/login","parentId":"routes/_app+/_layout","path":"login","hasAction":true,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/login-CHE9W6po.js","imports":["/assets/index-Czg1ruVn.js","/assets/clsx-B-dksMZM.js","/assets/components-wgHiPsTg.js","/assets/request-info-DHtGM4FI.js","/assets/client-hints-DLYDs4RF.js","/assets/use-event-source-ySol3hbz.js","/assets/button-BA3iiLRs.js","/assets/loading-B0uKxERz.js"],"css":[]},"routes/_app+/support":{"id":"routes/_app+/support","parentId":"routes/_app+/_layout","path":"support","hasAction":false,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/support-D1ydJNdm.js","imports":["/assets/index-Czg1ruVn.js","/assets/components-wgHiPsTg.js"],"css":[]},"routes/admin+/_layout":{"id":"routes/admin+/_layout","parentId":"root","path":"admin","hasAction":true,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/_layout-B9Y-8OU6.js","imports":["/assets/index-Czg1ruVn.js","/assets/clsx-B-dksMZM.js","/assets/components-wgHiPsTg.js","/assets/misc-S5ZD98sI.js","/assets/tooltip-BtzSIxlB.js","/assets/progress-BwanvUpB.js"],"css":[]},"routes/admin+/apps":{"id":"routes/admin+/apps","parentId":"routes/admin+/_layout","path":"apps","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/apps-DP2rzg_V.js","imports":[],"css":[]},"routes/admin+/cache":{"id":"routes/admin+/cache","parentId":"routes/admin+/_layout","path":"cache","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/cache-l0sNRNKZ.js","imports":[],"css":[]},"routes/apps":{"id":"routes/apps","parentId":"root","path":"apps","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/apps-l0sNRNKZ.js","imports":[],"css":[]},"routes/diff":{"id":"routes/diff","parentId":"root","path":"diff","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/diff-Bd9WnUnR.js","imports":["/assets/index-Czg1ruVn.js","/assets/clsx-B-dksMZM.js","/assets/components-wgHiPsTg.js","/assets/misc-S5ZD98sI.js","/assets/tooltip-BtzSIxlB.js","/assets/request-info-DHtGM4FI.js","/assets/client-hints-DLYDs4RF.js","/assets/index-yEAxvbDV.js","/assets/loading-B0uKxERz.js","/assets/user-CdUDQ7a8.js","/assets/epic-video-DJN9_SUj.js","/assets/progress-bar-wMXWRGq0.js","/assets/index-C6ToujzV.js","/assets/mdx-BENF-kTQ.js","/assets/diff-CpG96hGZ.js","/assets/nav-chevrons-DaXg0NPS.js"],"css":["/assets/epic-video-DUnRvy1A.css"]},"routes/discord.callback":{"id":"routes/discord.callback","parentId":"root","path":"discord/callback","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/discord.callback-l0sNRNKZ.js","imports":[],"css":[]},"routes/exercises":{"id":"routes/exercises","parentId":"root","path":"exercises","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/exercises-l0sNRNKZ.js","imports":[],"css":[]},"routes/launch-editor":{"id":"routes/launch-editor","parentId":"root","path":"launch-editor","hasAction":true,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/launch-editor-l0sNRNKZ.js","imports":[],"css":[]},"routes/login-sse":{"id":"routes/login-sse","parentId":"root","path":"login-sse","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/login-sse-l0sNRNKZ.js","imports":[],"css":[]},"routes/og":{"id":"routes/og","parentId":"root","path":"og","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/og-l0sNRNKZ.js","imports":[],"css":[]},"routes/onboarding":{"id":"routes/onboarding","parentId":"root","path":"onboarding","hasAction":true,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/onboarding-FD1FkQuu.js","imports":["/assets/index-Czg1ruVn.js","/assets/clsx-B-dksMZM.js","/assets/components-wgHiPsTg.js","/assets/misc-S5ZD98sI.js","/assets/request-info-DHtGM4FI.js","/assets/tooltip-BtzSIxlB.js","/assets/client-hints-DLYDs4RF.js","/assets/index-yEAxvbDV.js","/assets/loading-B0uKxERz.js","/assets/user-CdUDQ7a8.js","/assets/button-BA3iiLRs.js","/assets/epic-video-DJN9_SUj.js"],"css":["/assets/epic-video-DUnRvy1A.css"]},"routes/processes":{"id":"routes/processes","parentId":"root","path":"processes","hasAction":false,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/processes-l0sNRNKZ.js","imports":[],"css":[]},"routes/progress":{"id":"routes/progress","parentId":"root","path":"progress","hasAction":true,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/progress-l0sNRNKZ.js","imports":[],"css":[]},"routes/set-playground":{"id":"routes/set-playground","parentId":"root","path":"set-playground","hasAction":true,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/set-playground-l0sNRNKZ.js","imports":[],"css":[]},"routes/start":{"id":"routes/start","parentId":"root","path":"start","hasAction":true,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/start-l0sNRNKZ.js","imports":[],"css":[]},"routes/test":{"id":"routes/test","parentId":"root","path":"test","hasAction":true,"hasLoader":true,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/test-l0sNRNKZ.js","imports":[],"css":[]},"routes/theme/index":{"id":"routes/theme/index","parentId":"root","path":"theme","hasAction":true,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/index-DP2rzg_V.js","imports":[],"css":[]},"routes/update-mdx-cache":{"id":"routes/update-mdx-cache","parentId":"root","path":"update-mdx-cache","hasAction":true,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/update-mdx-cache-l0sNRNKZ.js","imports":[],"css":[]},"routes/video-player/index":{"id":"routes/video-player/index","parentId":"root","path":"video-player","hasAction":true,"hasLoader":false,"hasClientAction":false,"hasClientLoader":false,"hasErrorBoundary":false,"module":"/assets/index-K6Dvbx-E.js","imports":[],"css":[]}},"url":"/assets/manifest-23a014f9.js","version":"23a014f9"};
@@ -1,4 +1,4 @@
1
- import{u as G,l as H,r as h,n as Y,R as m,j as c,c as Q,O as $,e as V}from"./index-Czg1ruVn.js";import{d as J,u as U,c as X}from"./misc-S5ZD98sI.js";import{G as z}from"./error-boundary-BVTbN8PZ.js";import{E as K}from"./progress-bar-wMXWRGq0.js";import{T as Z,J as ee}from"./index-DjzedX4O.js";import{T as te}from"./tooltip-BtzSIxlB.js";import{u as ne}from"./index-yEAxvbDV.js";import{C as ie}from"./client-hints-DLYDs4RF.js";import{P as re}from"./presence-CW1_eiIo.js";import{g as oe}from"./seo-pBpFCWsy.js";import{p as se,q as ae,_ as ce,u as T,M as ue,t as le,S as fe}from"./components-wgHiPsTg.js";import"./clsx-B-dksMZM.js";import"./request-info-DHtGM4FI.js";/**
1
+ import{u as q,l as G,r as h,n as Y,R as m,j as c,c as Q,O as V,e as $}from"./index-Czg1ruVn.js";import{d as J,u as U,c as X}from"./misc-S5ZD98sI.js";import{G as z}from"./error-boundary-BVTbN8PZ.js";import{E as K}from"./progress-bar-wMXWRGq0.js";import{T as Z,J as ee}from"./index-DjzedX4O.js";import{T as te}from"./tooltip-BtzSIxlB.js";import{u as ne}from"./index-yEAxvbDV.js";import{C as ie}from"./client-hints-DLYDs4RF.js";import{P as re}from"./presence-CW1_eiIo.js";import{g as oe}from"./seo-pBpFCWsy.js";import{p as se,q as ae,_ as ce,u as T,M as ue,t as le,S as fe}from"./components-wgHiPsTg.js";import"./clsx-B-dksMZM.js";import"./request-info-DHtGM4FI.js";/**
2
2
  * @remix-run/react v2.10.0
3
3
  *
4
4
  * Copyright (c) Remix Software Inc.
@@ -7,7 +7,7 @@ import{u as G,l as H,r as h,n as Y,R as m,j as c,c as Q,O as $,e as V}from"./ind
7
7
  * LICENSE.md file in the root directory of this source tree.
8
8
  *
9
9
  * @license MIT
10
- */let N="positions";function he({getKey:e,...n}){let{isSpaMode:r}=se(),t=G(),i=H();ae({getKey:e,storageKey:N});let o=h.useMemo(()=>{if(!e)return null;let a=e(t,i);return a!==t.key?a:null},[]);if(r)return null;let s=((a,l)=>{if(!window.history.state||!window.history.state.key){let u=Math.random().toString(32).slice(2);window.history.replaceState({key:u},"")}try{let x=JSON.parse(sessionStorage.getItem(a)||"{}")[l||window.history.state.key];typeof x=="number"&&window.scrollTo(0,x)}catch(u){console.error(u),sessionStorage.removeItem(a)}}).toString();return h.createElement("script",ce({},n,{suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:`(${s})(${JSON.stringify(N)}, ${JSON.stringify(o)})`}}))}var O={linear:function(e,n,r,t){var i=r-n;return i*e/t+n},easeInQuad:function(e,n,r,t){var i=r-n;return i*(e/=t)*e+n},easeOutQuad:function(e,n,r,t){var i=r-n;return-i*(e/=t)*(e-2)+n},easeInOutQuad:function(e,n,r,t){var i=r-n;return(e/=t/2)<1?i/2*e*e+n:-i/2*(--e*(e-2)-1)+n},easeInCubic:function(e,n,r,t){var i=r-n;return i*(e/=t)*e*e+n},easeOutCubic:function(e,n,r,t){var i=r-n;return i*((e=e/t-1)*e*e+1)+n},easeInOutCubic:function(e,n,r,t){var i=r-n;return(e/=t/2)<1?i/2*e*e*e+n:i/2*((e-=2)*e*e+2)+n},easeInQuart:function(e,n,r,t){var i=r-n;return i*(e/=t)*e*e*e+n},easeOutQuart:function(e,n,r,t){var i=r-n;return-i*((e=e/t-1)*e*e*e-1)+n},easeInOutQuart:function(e,n,r,t){var i=r-n;return(e/=t/2)<1?i/2*e*e*e*e+n:-i/2*((e-=2)*e*e*e-2)+n},easeInQuint:function(e,n,r,t){var i=r-n;return i*(e/=t)*e*e*e*e+n},easeOutQuint:function(e,n,r,t){var i=r-n;return i*((e=e/t-1)*e*e*e*e+1)+n},easeInOutQuint:function(e,n,r,t){var i=r-n;return(e/=t/2)<1?i/2*e*e*e*e*e+n:i/2*((e-=2)*e*e*e*e+2)+n},easeInSine:function(e,n,r,t){var i=r-n;return-i*Math.cos(e/t*(Math.PI/2))+i+n},easeOutSine:function(e,n,r,t){var i=r-n;return i*Math.sin(e/t*(Math.PI/2))+n},easeInOutSine:function(e,n,r,t){var i=r-n;return-i/2*(Math.cos(Math.PI*e/t)-1)+n},easeInExpo:function(e,n,r,t){var i=r-n;return e==0?n:i*Math.pow(2,10*(e/t-1))+n},easeOutExpo:function(e,n,r,t){var i=r-n;return e==t?n+i:i*(-Math.pow(2,-10*e/t)+1)+n},easeInOutExpo:function(e,n,r,t){var i=r-n;return e===0?n:e===t?n+i:(e/=t/2)<1?i/2*Math.pow(2,10*(e-1))+n:i/2*(-Math.pow(2,-10*--e)+2)+n},easeInCirc:function(e,n,r,t){var i=r-n;return-i*(Math.sqrt(1-(e/=t)*e)-1)+n},easeOutCirc:function(e,n,r,t){var i=r-n;return i*Math.sqrt(1-(e=e/t-1)*e)+n},easeInOutCirc:function(e,n,r,t){var i=r-n;return(e/=t/2)<1?-i/2*(Math.sqrt(1-e*e)-1)+n:i/2*(Math.sqrt(1-(e-=2)*e)+1)+n},easeInElastic:function(e,n,r,t){var i=r-n,o,s,a;return a=1.70158,s=0,o=i,e===0?n:(e/=t)===1?n+i:(s||(s=t*.3),o<Math.abs(i)?(o=i,a=s/4):a=s/(2*Math.PI)*Math.asin(i/o),-(o*Math.pow(2,10*(e-=1))*Math.sin((e*t-a)*(2*Math.PI)/s))+n)},easeOutElastic:function(e,n,r,t){var i=r-n,o,s,a;return a=1.70158,s=0,o=i,e===0?n:(e/=t)===1?n+i:(s||(s=t*.3),o<Math.abs(i)?(o=i,a=s/4):a=s/(2*Math.PI)*Math.asin(i/o),o*Math.pow(2,-10*e)*Math.sin((e*t-a)*(2*Math.PI)/s)+i+n)},easeInOutElastic:function(e,n,r,t){var i=r-n,o,s,a;return a=1.70158,s=0,o=i,e===0?n:(e/=t/2)===2?n+i:(s||(s=t*(.3*1.5)),o<Math.abs(i)?(o=i,a=s/4):a=s/(2*Math.PI)*Math.asin(i/o),e<1?-.5*(o*Math.pow(2,10*(e-=1))*Math.sin((e*t-a)*(2*Math.PI)/s))+n:o*Math.pow(2,-10*(e-=1))*Math.sin((e*t-a)*(2*Math.PI)/s)*.5+i+n)},easeInBack:function(e,n,r,t,i){var o=r-n;return i===void 0&&(i=1.70158),o*(e/=t)*e*((i+1)*e-i)+n},easeOutBack:function(e,n,r,t,i){var o=r-n;return i===void 0&&(i=1.70158),o*((e=e/t-1)*e*((i+1)*e+i)+1)+n},easeInOutBack:function(e,n,r,t,i){var o=r-n;return i===void 0&&(i=1.70158),(e/=t/2)<1?o/2*(e*e*(((i*=1.525)+1)*e-i))+n:o/2*((e-=2)*e*(((i*=1.525)+1)*e+i)+2)+n},easeInBounce:function(e,n,r,t){var i=r-n,o;return o=O.easeOutBounce(t-e,0,i,t),i-o+n},easeOutBounce:function(e,n,r,t){var i=r-n;return(e/=t)<1/2.75?i*(7.5625*e*e)+n:e<2/2.75?i*(7.5625*(e-=1.5/2.75)*e+.75)+n:e<2.5/2.75?i*(7.5625*(e-=2.25/2.75)*e+.9375)+n:i*(7.5625*(e-=2.625/2.75)*e+.984375)+n},easeInOutBounce:function(e,n,r,t){var i=r-n,o;return e<t/2?(o=O.easeInBounce(e*2,0,i,t),o*.5+n):(o=O.easeOutBounce(e*2-t,0,i,t),o*.5+i*.5+n)}},pe=O;const ve=Y(pe);function de(e,n){for(var r=0;r<n.length;r++){var t=n[r];t.enumerable=t.enumerable||!1,t.configurable=!0,"value"in t&&(t.writable=!0),Object.defineProperty(e,t.key,t)}}function ge(e,n,r){return n&&de(e.prototype,n),e}function y(){return y=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var r=arguments[n];for(var t in r)Object.prototype.hasOwnProperty.call(r,t)&&(e[t]=r[t])}return e},y.apply(this,arguments)}function we(e,n){e.prototype=Object.create(n.prototype),e.prototype.constructor=e,C(e,n)}function C(e,n){return C=Object.setPrototypeOf||function(t,i){return t.__proto__=i,t},C(e,n)}function me(e){return e*Math.PI/180}function f(e,n){return e+Math.random()*(n-e)}function ye(e,n){return Math.floor(e+Math.random()*(n-e+1))}var w;(function(e){e[e.Circle=0]="Circle",e[e.Square=1]="Square",e[e.Strip=2]="Strip"})(w||(w={}));var p;(function(e){e[e.Positive=1]="Positive",e[e.Negative=-1]="Negative"})(p||(p={}));var xe=function(){function e(r,t,i,o){this.getOptions=t;var s=this.getOptions(),a=s.colors,l=s.initialVelocityX,u=s.initialVelocityY;this.context=r,this.x=i,this.y=o,this.w=f(5,20),this.h=f(5,20),this.radius=f(5,10),this.vx=f(-l,l),this.vy=f(-u,0),this.shape=ye(0,2),this.angle=me(f(0,360)),this.angularSpin=f(-.2,.2),this.color=a[Math.floor(Math.random()*a.length)],this.rotateY=f(0,1),this.rotationDirection=f(0,1)?p.Positive:p.Negative}var n=e.prototype;return n.update=function(){var t=this.getOptions(),i=t.gravity,o=t.wind,s=t.friction,a=t.opacity,l=t.drawShape;this.x+=this.vx,this.y+=this.vy,this.vy+=i,this.vx+=o,this.vx*=s,this.vy*=s,this.rotateY>=1&&this.rotationDirection===p.Positive?this.rotationDirection=p.Negative:this.rotateY<=-1&&this.rotationDirection===p.Negative&&(this.rotationDirection=p.Positive);var u=.1*this.rotationDirection;if(this.rotateY+=u,this.angle+=this.angularSpin,this.context.save(),this.context.translate(this.x,this.y),this.context.rotate(this.angle),this.context.scale(1,this.rotateY),this.context.rotate(this.angle),this.context.beginPath(),this.context.fillStyle=this.color,this.context.strokeStyle=this.color,this.context.globalAlpha=a,this.context.lineCap="round",this.context.lineWidth=2,l&&typeof l=="function")l.call(this,this.context);else switch(this.shape){case w.Circle:{this.context.beginPath(),this.context.arc(0,0,this.radius,0,2*Math.PI),this.context.fill();break}case w.Square:{this.context.fillRect(-this.w/2,-this.h/2,this.w,this.h);break}case w.Strip:{this.context.fillRect(-this.w/6,-this.h/2,this.w/3,this.h);break}default:throw new Error("Unknown type in Particle.ts")}this.context.closePath(),this.context.restore()},e}(),Oe=function(n,r){var t=this;this.x=0,this.y=0,this.w=0,this.h=0,this.lastNumberOfPieces=0,this.tweenInitTime=Date.now(),this.particles=[],this.particlesGenerated=0,this.removeParticleAt=function(o){t.particles.splice(o,1)},this.getParticle=function(){var o=f(t.x,t.w+t.x),s=f(t.y,t.h+t.y);return new xe(t.context,t.getOptions,o,s)},this.animate=function(){var o=t.canvas,s=t.context,a=t.particlesGenerated,l=t.lastNumberOfPieces,u=t.getOptions(),x=u.run,E=u.recycle,v=u.numberOfPieces,W=u.debug,A=u.tweenFunction,P=u.tweenDuration;if(!x)return!1;var M=t.particles.length,d=E?M:a,I=Date.now();if(d<v){l!==v&&(t.tweenInitTime=I,t.lastNumberOfPieces=v);for(var F=t.tweenInitTime,L=I-F>P?P:Math.max(0,I-F),q=A(L,d,v,P),D=Math.round(q-d),k=0;k<D;k+=1)t.particles.push(t.getParticle());t.particlesGenerated+=D}return W&&(s.font="12px sans-serif",s.fillStyle="#333",s.textAlign="right",s.fillText("Particles: "+M,o.width-10,o.height-20)),t.particles.forEach(function(g,R){g.update(),(g.y>o.height||g.y<-100||g.x>o.width+100||g.x<-100)&&(E&&d<=v?t.particles[R]=t.getParticle():t.removeParticleAt(R))}),M>0||d<v},this.canvas=n;var i=this.canvas.getContext("2d");if(!i)throw new Error("Could not get canvas context");this.context=i,this.getOptions=r},j={width:typeof window<"u"?window.innerWidth:300,height:typeof window<"u"?window.innerHeight:200,numberOfPieces:200,friction:.99,wind:0,gravity:.1,initialVelocityX:4,initialVelocityY:10,colors:["#f44336","#e91e63","#9c27b0","#673ab7","#3f51b5","#2196f3","#03a9f4","#00bcd4","#009688","#4CAF50","#8BC34A","#CDDC39","#FFEB3B","#FFC107","#FF9800","#FF5722","#795548"],opacity:1,debug:!1,tweenFunction:ve.easeInOutQuad,tweenDuration:5e3,recycle:!0,run:!0},Pe=function(){function e(n,r){var t=this;this.setOptionsWithDefaults=function(o){var s={confettiSource:{x:0,y:0,w:t.canvas.width,h:0}};t._options=y({},s,j,o),Object.assign(t,o.confettiSource)},this.update=function(){var o=t.options,s=o.run,a=o.onConfettiComplete,l=t.canvas,u=t.context;s&&(u.fillStyle="white",u.clearRect(0,0,l.width,l.height)),t.generator.animate()?t.rafId=requestAnimationFrame(t.update):(a&&typeof a=="function"&&t.generator.particlesGenerated>0&&a.call(t,t),t._options.run=!1)},this.reset=function(){t.generator&&t.generator.particlesGenerated>0&&(t.generator.particlesGenerated=0,t.generator.particles=[],t.generator.lastNumberOfPieces=0)},this.stop=function(){t.options={run:!1},t.rafId&&(cancelAnimationFrame(t.rafId),t.rafId=void 0)},this.canvas=n;var i=this.canvas.getContext("2d");if(!i)throw new Error("Could not get canvas context");this.context=i,this.generator=new Oe(this.canvas,function(){return t.options}),this.options=r,this.update()}return ge(e,[{key:"options",get:function(){return this._options},set:function(r){var t=this._options&&this._options.run,i=this._options&&this._options.recycle;this.setOptionsWithDefaults(r),this.generator&&(Object.assign(this.generator,this.options.confettiSource),typeof r.recycle=="boolean"&&r.recycle&&i===!1&&(this.generator.lastNumberOfPieces=this.generator.particles.length)),typeof r.run=="boolean"&&r.run&&t===!1&&this.update()}}]),e}(),B=m.createRef();function S(e){var n={},r={},t={},i=[].concat(Object.keys(j),["confettiSource","drawShape","onConfettiComplete"]),o=["canvasRef"];return Object.keys(e).forEach(function(s){var a=e[s];i.includes(s)?n[s]=a:o.includes(s)?o[s]=a:t[s]=a}),[n,t,r]}var _=function(e){we(n,e);function n(t){for(var i,o=arguments.length,s=new Array(o>1?o-1:0),a=1;a<o;a++)s[a-1]=arguments[a];return i=e.call.apply(e,[this,t].concat(s))||this,i.canvas=m.createRef(),i.canvas=t.canvasRef||B,i}var r=n.prototype;return r.componentDidMount=function(){if(this.canvas.current){var i=S(this.props)[0];this.confetti=new Pe(this.canvas.current,i)}},r.componentDidUpdate=function(){var i=S(this.props)[0];this.confetti&&(this.confetti.options=i)},r.componentWillUnmount=function(){this.confetti&&this.confetti.stop(),this.confetti=void 0},r.render=function(){var i=S(this.props),o=i[0],s=i[1],a=y({zIndex:2,position:"absolute",pointerEvents:"none",top:0,left:0,bottom:0,right:0},s.style);return m.createElement("canvas",Object.assign({width:o.width,height:o.height,ref:this.canvas},s,{style:a}))},n}(h.Component);_.defaultProps=y({},j);_.displayName="ConfettiReact";var Me=m.forwardRef(function(e,n){return m.createElement(_,Object.assign({canvasRef:B},e))});function Ie(){return()=>{}}function Se(){return h.useSyncExternalStore(Ie,()=>!0,()=>!1)}function Ce({children:e,fallback:n=null}){return Se()?h.createElement(h.Fragment,null,e()):h.createElement(h.Fragment,null,n)}function je({id:e}){return e?c.jsx(Ce,{children:()=>c.jsx(Me,{run:!!e,recycle:!1,numberOfPieces:800,width:window.innerWidth,height:window.innerHeight},e)}):null}function _e({toast:e}){return c.jsxs(c.Fragment,{children:[c.jsx(Z,{closeButton:!0,position:"top-center"}),e?c.jsx(Ee,{toast:e}):null]})}function Ee({toast:e}){const{id:n,type:r,title:t,description:i}=e;return h.useEffect(()=>{setTimeout(()=>{ee[r](t,{id:n,description:i})},0)},[i,n,t,r]),null}const Fe="/assets/app-BKC4z3M_.css",De="/assets/tailwind-D2vjZZFL.css",Ve=()=>[{rel:"stylesheet",href:"/neogrotesk-font.css"},{rel:"stylesheet",href:"https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:ital,wght@0,200;0,300;0,400;0,500;0,600;1,700&display=swap"},{rel:"stylesheet",href:De},{rel:"stylesheet",href:Fe},{rel:"mask-icon",href:"/favicons/favicon.svg"},{rel:"alternate icon",type:"image/png",href:"/favicon.png"},{rel:"icon",type:"image/svg+xml",href:"/favicon.svg"}],Je=({data:e})=>e?oe({instructor:e.instructor,title:e.workshopTitle,description:e.workshopSubtitle,requestInfo:e.requestInfo}):[];function b({children:e,env:n={},className:r}){const t=V();return h.useEffect(()=>{window.__epicshop??(window.__epicshop={}),window.__epicshop.handleFileChange=t.revalidate},[t]),c.jsxs("html",{lang:"en",className:r,children:[c.jsxs("head",{children:[c.jsx(ie,{}),c.jsx(ue,{}),c.jsx("meta",{charSet:"utf-8"}),c.jsx("meta",{name:"viewport",content:"width=device-width,initial-scale=1"}),c.jsx(le,{}),c.jsx("script",{dangerouslySetInnerHTML:{__html:`window.ENV = ${JSON.stringify(n)}`}})]}),c.jsxs("body",{className:"bg-background text-foreground scrollbar-thin scrollbar-thumb-scrollbar h-screen-safe",children:[e,c.jsx(he,{}),c.jsx(fe,{}),ENV.EPICSHOP_DEPLOYED?null:c.jsx("script",{dangerouslySetInnerHTML:{__html:Re()}})]})]})}function ke(){const e=T(),n=Q(),r=J.useSpinDelay(n.state!=="idle",{delay:400,minDuration:200}),t=U(),i=ne();return c.jsxs(b,{className:X("antialiased h-screen-safe",i,{"cursor-progress":r},t?"alt-down":null),env:e.ENV,children:[c.jsx($,{}),c.jsx(je,{id:e.confettiId}),c.jsx(_e,{toast:e.toast}),c.jsx(K,{})]})}function Ue(){const{user:e}=T();return c.jsx(re,{user:e,children:c.jsx(te,{children:c.jsx(ke,{})})})}function Xe(){return c.jsx(b,{className:"h-screen-safe",children:c.jsx(z,{})})}function Re(){return`
10
+ */let N="positions";function he({getKey:e,...n}){let{isSpaMode:r}=se(),t=q(),i=G();ae({getKey:e,storageKey:N});let o=h.useMemo(()=>{if(!e)return null;let a=e(t,i);return a!==t.key?a:null},[]);if(r)return null;let s=((a,l)=>{if(!window.history.state||!window.history.state.key){let u=Math.random().toString(32).slice(2);window.history.replaceState({key:u},"")}try{let x=JSON.parse(sessionStorage.getItem(a)||"{}")[l||window.history.state.key];typeof x=="number"&&window.scrollTo(0,x)}catch(u){console.error(u),sessionStorage.removeItem(a)}}).toString();return h.createElement("script",ce({},n,{suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:`(${s})(${JSON.stringify(N)}, ${JSON.stringify(o)})`}}))}var O={linear:function(e,n,r,t){var i=r-n;return i*e/t+n},easeInQuad:function(e,n,r,t){var i=r-n;return i*(e/=t)*e+n},easeOutQuad:function(e,n,r,t){var i=r-n;return-i*(e/=t)*(e-2)+n},easeInOutQuad:function(e,n,r,t){var i=r-n;return(e/=t/2)<1?i/2*e*e+n:-i/2*(--e*(e-2)-1)+n},easeInCubic:function(e,n,r,t){var i=r-n;return i*(e/=t)*e*e+n},easeOutCubic:function(e,n,r,t){var i=r-n;return i*((e=e/t-1)*e*e+1)+n},easeInOutCubic:function(e,n,r,t){var i=r-n;return(e/=t/2)<1?i/2*e*e*e+n:i/2*((e-=2)*e*e+2)+n},easeInQuart:function(e,n,r,t){var i=r-n;return i*(e/=t)*e*e*e+n},easeOutQuart:function(e,n,r,t){var i=r-n;return-i*((e=e/t-1)*e*e*e-1)+n},easeInOutQuart:function(e,n,r,t){var i=r-n;return(e/=t/2)<1?i/2*e*e*e*e+n:-i/2*((e-=2)*e*e*e-2)+n},easeInQuint:function(e,n,r,t){var i=r-n;return i*(e/=t)*e*e*e*e+n},easeOutQuint:function(e,n,r,t){var i=r-n;return i*((e=e/t-1)*e*e*e*e+1)+n},easeInOutQuint:function(e,n,r,t){var i=r-n;return(e/=t/2)<1?i/2*e*e*e*e*e+n:i/2*((e-=2)*e*e*e*e+2)+n},easeInSine:function(e,n,r,t){var i=r-n;return-i*Math.cos(e/t*(Math.PI/2))+i+n},easeOutSine:function(e,n,r,t){var i=r-n;return i*Math.sin(e/t*(Math.PI/2))+n},easeInOutSine:function(e,n,r,t){var i=r-n;return-i/2*(Math.cos(Math.PI*e/t)-1)+n},easeInExpo:function(e,n,r,t){var i=r-n;return e==0?n:i*Math.pow(2,10*(e/t-1))+n},easeOutExpo:function(e,n,r,t){var i=r-n;return e==t?n+i:i*(-Math.pow(2,-10*e/t)+1)+n},easeInOutExpo:function(e,n,r,t){var i=r-n;return e===0?n:e===t?n+i:(e/=t/2)<1?i/2*Math.pow(2,10*(e-1))+n:i/2*(-Math.pow(2,-10*--e)+2)+n},easeInCirc:function(e,n,r,t){var i=r-n;return-i*(Math.sqrt(1-(e/=t)*e)-1)+n},easeOutCirc:function(e,n,r,t){var i=r-n;return i*Math.sqrt(1-(e=e/t-1)*e)+n},easeInOutCirc:function(e,n,r,t){var i=r-n;return(e/=t/2)<1?-i/2*(Math.sqrt(1-e*e)-1)+n:i/2*(Math.sqrt(1-(e-=2)*e)+1)+n},easeInElastic:function(e,n,r,t){var i=r-n,o,s,a;return a=1.70158,s=0,o=i,e===0?n:(e/=t)===1?n+i:(s||(s=t*.3),o<Math.abs(i)?(o=i,a=s/4):a=s/(2*Math.PI)*Math.asin(i/o),-(o*Math.pow(2,10*(e-=1))*Math.sin((e*t-a)*(2*Math.PI)/s))+n)},easeOutElastic:function(e,n,r,t){var i=r-n,o,s,a;return a=1.70158,s=0,o=i,e===0?n:(e/=t)===1?n+i:(s||(s=t*.3),o<Math.abs(i)?(o=i,a=s/4):a=s/(2*Math.PI)*Math.asin(i/o),o*Math.pow(2,-10*e)*Math.sin((e*t-a)*(2*Math.PI)/s)+i+n)},easeInOutElastic:function(e,n,r,t){var i=r-n,o,s,a;return a=1.70158,s=0,o=i,e===0?n:(e/=t/2)===2?n+i:(s||(s=t*(.3*1.5)),o<Math.abs(i)?(o=i,a=s/4):a=s/(2*Math.PI)*Math.asin(i/o),e<1?-.5*(o*Math.pow(2,10*(e-=1))*Math.sin((e*t-a)*(2*Math.PI)/s))+n:o*Math.pow(2,-10*(e-=1))*Math.sin((e*t-a)*(2*Math.PI)/s)*.5+i+n)},easeInBack:function(e,n,r,t,i){var o=r-n;return i===void 0&&(i=1.70158),o*(e/=t)*e*((i+1)*e-i)+n},easeOutBack:function(e,n,r,t,i){var o=r-n;return i===void 0&&(i=1.70158),o*((e=e/t-1)*e*((i+1)*e+i)+1)+n},easeInOutBack:function(e,n,r,t,i){var o=r-n;return i===void 0&&(i=1.70158),(e/=t/2)<1?o/2*(e*e*(((i*=1.525)+1)*e-i))+n:o/2*((e-=2)*e*(((i*=1.525)+1)*e+i)+2)+n},easeInBounce:function(e,n,r,t){var i=r-n,o;return o=O.easeOutBounce(t-e,0,i,t),i-o+n},easeOutBounce:function(e,n,r,t){var i=r-n;return(e/=t)<1/2.75?i*(7.5625*e*e)+n:e<2/2.75?i*(7.5625*(e-=1.5/2.75)*e+.75)+n:e<2.5/2.75?i*(7.5625*(e-=2.25/2.75)*e+.9375)+n:i*(7.5625*(e-=2.625/2.75)*e+.984375)+n},easeInOutBounce:function(e,n,r,t){var i=r-n,o;return e<t/2?(o=O.easeInBounce(e*2,0,i,t),o*.5+n):(o=O.easeOutBounce(e*2-t,0,i,t),o*.5+i*.5+n)}},pe=O;const ve=Y(pe);function de(e,n){for(var r=0;r<n.length;r++){var t=n[r];t.enumerable=t.enumerable||!1,t.configurable=!0,"value"in t&&(t.writable=!0),Object.defineProperty(e,t.key,t)}}function ge(e,n,r){return n&&de(e.prototype,n),e}function y(){return y=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var r=arguments[n];for(var t in r)Object.prototype.hasOwnProperty.call(r,t)&&(e[t]=r[t])}return e},y.apply(this,arguments)}function we(e,n){e.prototype=Object.create(n.prototype),e.prototype.constructor=e,C(e,n)}function C(e,n){return C=Object.setPrototypeOf||function(t,i){return t.__proto__=i,t},C(e,n)}function me(e){return e*Math.PI/180}function f(e,n){return e+Math.random()*(n-e)}function ye(e,n){return Math.floor(e+Math.random()*(n-e+1))}var w;(function(e){e[e.Circle=0]="Circle",e[e.Square=1]="Square",e[e.Strip=2]="Strip"})(w||(w={}));var p;(function(e){e[e.Positive=1]="Positive",e[e.Negative=-1]="Negative"})(p||(p={}));var xe=function(){function e(r,t,i,o){this.getOptions=t;var s=this.getOptions(),a=s.colors,l=s.initialVelocityX,u=s.initialVelocityY;this.context=r,this.x=i,this.y=o,this.w=f(5,20),this.h=f(5,20),this.radius=f(5,10),this.vx=f(-l,l),this.vy=f(-u,0),this.shape=ye(0,2),this.angle=me(f(0,360)),this.angularSpin=f(-.2,.2),this.color=a[Math.floor(Math.random()*a.length)],this.rotateY=f(0,1),this.rotationDirection=f(0,1)?p.Positive:p.Negative}var n=e.prototype;return n.update=function(){var t=this.getOptions(),i=t.gravity,o=t.wind,s=t.friction,a=t.opacity,l=t.drawShape;this.x+=this.vx,this.y+=this.vy,this.vy+=i,this.vx+=o,this.vx*=s,this.vy*=s,this.rotateY>=1&&this.rotationDirection===p.Positive?this.rotationDirection=p.Negative:this.rotateY<=-1&&this.rotationDirection===p.Negative&&(this.rotationDirection=p.Positive);var u=.1*this.rotationDirection;if(this.rotateY+=u,this.angle+=this.angularSpin,this.context.save(),this.context.translate(this.x,this.y),this.context.rotate(this.angle),this.context.scale(1,this.rotateY),this.context.rotate(this.angle),this.context.beginPath(),this.context.fillStyle=this.color,this.context.strokeStyle=this.color,this.context.globalAlpha=a,this.context.lineCap="round",this.context.lineWidth=2,l&&typeof l=="function")l.call(this,this.context);else switch(this.shape){case w.Circle:{this.context.beginPath(),this.context.arc(0,0,this.radius,0,2*Math.PI),this.context.fill();break}case w.Square:{this.context.fillRect(-this.w/2,-this.h/2,this.w,this.h);break}case w.Strip:{this.context.fillRect(-this.w/6,-this.h/2,this.w/3,this.h);break}default:throw new Error("Unknown type in Particle.ts")}this.context.closePath(),this.context.restore()},e}(),Oe=function(n,r){var t=this;this.x=0,this.y=0,this.w=0,this.h=0,this.lastNumberOfPieces=0,this.tweenInitTime=Date.now(),this.particles=[],this.particlesGenerated=0,this.removeParticleAt=function(o){t.particles.splice(o,1)},this.getParticle=function(){var o=f(t.x,t.w+t.x),s=f(t.y,t.h+t.y);return new xe(t.context,t.getOptions,o,s)},this.animate=function(){var o=t.canvas,s=t.context,a=t.particlesGenerated,l=t.lastNumberOfPieces,u=t.getOptions(),x=u.run,E=u.recycle,v=u.numberOfPieces,W=u.debug,A=u.tweenFunction,P=u.tweenDuration;if(!x)return!1;var M=t.particles.length,d=E?M:a,I=Date.now();if(d<v){l!==v&&(t.tweenInitTime=I,t.lastNumberOfPieces=v);for(var F=t.tweenInitTime,H=I-F>P?P:Math.max(0,I-F),L=A(H,d,v,P),D=Math.round(L-d),k=0;k<D;k+=1)t.particles.push(t.getParticle());t.particlesGenerated+=D}return W&&(s.font="12px sans-serif",s.fillStyle="#333",s.textAlign="right",s.fillText("Particles: "+M,o.width-10,o.height-20)),t.particles.forEach(function(g,R){g.update(),(g.y>o.height||g.y<-100||g.x>o.width+100||g.x<-100)&&(E&&d<=v?t.particles[R]=t.getParticle():t.removeParticleAt(R))}),M>0||d<v},this.canvas=n;var i=this.canvas.getContext("2d");if(!i)throw new Error("Could not get canvas context");this.context=i,this.getOptions=r},j={width:typeof window<"u"?window.innerWidth:300,height:typeof window<"u"?window.innerHeight:200,numberOfPieces:200,friction:.99,wind:0,gravity:.1,initialVelocityX:4,initialVelocityY:10,colors:["#f44336","#e91e63","#9c27b0","#673ab7","#3f51b5","#2196f3","#03a9f4","#00bcd4","#009688","#4CAF50","#8BC34A","#CDDC39","#FFEB3B","#FFC107","#FF9800","#FF5722","#795548"],opacity:1,debug:!1,tweenFunction:ve.easeInOutQuad,tweenDuration:5e3,recycle:!0,run:!0},Pe=function(){function e(n,r){var t=this;this.setOptionsWithDefaults=function(o){var s={confettiSource:{x:0,y:0,w:t.canvas.width,h:0}};t._options=y({},s,j,o),Object.assign(t,o.confettiSource)},this.update=function(){var o=t.options,s=o.run,a=o.onConfettiComplete,l=t.canvas,u=t.context;s&&(u.fillStyle="white",u.clearRect(0,0,l.width,l.height)),t.generator.animate()?t.rafId=requestAnimationFrame(t.update):(a&&typeof a=="function"&&t.generator.particlesGenerated>0&&a.call(t,t),t._options.run=!1)},this.reset=function(){t.generator&&t.generator.particlesGenerated>0&&(t.generator.particlesGenerated=0,t.generator.particles=[],t.generator.lastNumberOfPieces=0)},this.stop=function(){t.options={run:!1},t.rafId&&(cancelAnimationFrame(t.rafId),t.rafId=void 0)},this.canvas=n;var i=this.canvas.getContext("2d");if(!i)throw new Error("Could not get canvas context");this.context=i,this.generator=new Oe(this.canvas,function(){return t.options}),this.options=r,this.update()}return ge(e,[{key:"options",get:function(){return this._options},set:function(r){var t=this._options&&this._options.run,i=this._options&&this._options.recycle;this.setOptionsWithDefaults(r),this.generator&&(Object.assign(this.generator,this.options.confettiSource),typeof r.recycle=="boolean"&&r.recycle&&i===!1&&(this.generator.lastNumberOfPieces=this.generator.particles.length)),typeof r.run=="boolean"&&r.run&&t===!1&&this.update()}}]),e}(),B=m.createRef();function S(e){var n={},r={},t={},i=[].concat(Object.keys(j),["confettiSource","drawShape","onConfettiComplete"]),o=["canvasRef"];return Object.keys(e).forEach(function(s){var a=e[s];i.includes(s)?n[s]=a:o.includes(s)?o[s]=a:t[s]=a}),[n,t,r]}var _=function(e){we(n,e);function n(t){for(var i,o=arguments.length,s=new Array(o>1?o-1:0),a=1;a<o;a++)s[a-1]=arguments[a];return i=e.call.apply(e,[this,t].concat(s))||this,i.canvas=m.createRef(),i.canvas=t.canvasRef||B,i}var r=n.prototype;return r.componentDidMount=function(){if(this.canvas.current){var i=S(this.props)[0];this.confetti=new Pe(this.canvas.current,i)}},r.componentDidUpdate=function(){var i=S(this.props)[0];this.confetti&&(this.confetti.options=i)},r.componentWillUnmount=function(){this.confetti&&this.confetti.stop(),this.confetti=void 0},r.render=function(){var i=S(this.props),o=i[0],s=i[1],a=y({zIndex:2,position:"absolute",pointerEvents:"none",top:0,left:0,bottom:0,right:0},s.style);return m.createElement("canvas",Object.assign({width:o.width,height:o.height,ref:this.canvas},s,{style:a}))},n}(h.Component);_.defaultProps=y({},j);_.displayName="ConfettiReact";var Me=m.forwardRef(function(e,n){return m.createElement(_,Object.assign({canvasRef:B},e))});function Ie(){return()=>{}}function Se(){return h.useSyncExternalStore(Ie,()=>!0,()=>!1)}function Ce({children:e,fallback:n=null}){return Se()?h.createElement(h.Fragment,null,e()):h.createElement(h.Fragment,null,n)}function je({id:e}){return e?c.jsx(Ce,{children:()=>c.jsx(Me,{run:!!e,recycle:!1,numberOfPieces:800,width:window.innerWidth,height:window.innerHeight},e)}):null}function _e({toast:e}){return c.jsxs(c.Fragment,{children:[c.jsx(Z,{closeButton:!0,position:"top-center"}),e?c.jsx(Ee,{toast:e}):null]})}function Ee({toast:e}){const{id:n,type:r,title:t,description:i}=e;return h.useEffect(()=>{setTimeout(()=>{ee[r](t,{id:n,description:i})},0)},[i,n,t,r]),null}const Fe="/assets/app-BKC4z3M_.css",De="/assets/tailwind-B8W-1HVL.css",$e=()=>[{rel:"stylesheet",href:"/neogrotesk-font.css"},{rel:"stylesheet",href:"https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:ital,wght@0,200;0,300;0,400;0,500;0,600;1,700&display=swap"},{rel:"stylesheet",href:De},{rel:"stylesheet",href:Fe},{rel:"mask-icon",href:"/favicons/favicon.svg"},{rel:"alternate icon",type:"image/png",href:"/favicon.png"},{rel:"icon",type:"image/svg+xml",href:"/favicon.svg"}],Je=({data:e})=>e?oe({instructor:e.instructor,title:e.workshopTitle,description:e.workshopSubtitle,requestInfo:e.requestInfo}):[];function b({children:e,env:n={},className:r}){const t=$();return h.useEffect(()=>{window.__epicshop??(window.__epicshop={}),window.__epicshop.handleFileChange=t.revalidate},[t]),c.jsxs("html",{lang:"en",className:r,children:[c.jsxs("head",{children:[c.jsx(ie,{}),c.jsx(ue,{}),c.jsx("meta",{charSet:"utf-8"}),c.jsx("meta",{name:"viewport",content:"width=device-width,initial-scale=1"}),c.jsx(le,{}),c.jsx("script",{dangerouslySetInnerHTML:{__html:`window.ENV = ${JSON.stringify(n)}`}})]}),c.jsxs("body",{className:"bg-background text-foreground scrollbar-thin scrollbar-thumb-scrollbar h-screen-safe",children:[e,c.jsx(he,{}),c.jsx(fe,{}),ENV.EPICSHOP_DEPLOYED?null:c.jsx("script",{dangerouslySetInnerHTML:{__html:Re()}})]})]})}function ke(){const e=T(),n=Q(),r=J.useSpinDelay(n.state!=="idle",{delay:400,minDuration:200}),t=U(),i=ne();return c.jsxs(b,{className:X("antialiased h-screen-safe",i,{"cursor-progress":r},t?"alt-down":null),env:e.ENV,children:[c.jsx(V,{}),c.jsx(je,{id:e.confettiId}),c.jsx(_e,{toast:e.toast}),c.jsx(K,{})]})}function Ue(){const{user:e}=T();return c.jsx(re,{user:e,children:c.jsx(te,{children:c.jsx(ke,{})})})}function Xe(){return c.jsx(b,{className:"h-screen-safe",children:c.jsx(z,{})})}function Re(){return`
11
11
  function epicLiveReloadConnect(config) {
12
12
  const protocol = location.protocol === "https:" ? "wss:" : "ws:";
13
13
  const host = location.hostname;
@@ -64,5 +64,5 @@ import{u as G,l as H,r as h,n as Y,R as m,j as c,c as Q,O as $,e as V}from"./ind
64
64
  };
65
65
  }
66
66
  epicLiveReloadConnect();
67
- `}export{Xe as ErrorBoundary,Ue as default,Ve as links,Je as meta};
68
- //# sourceMappingURL=root-BvoAKOBJ.js.map
67
+ `}export{Xe as ErrorBoundary,Ue as default,$e as links,Je as meta};
68
+ //# sourceMappingURL=root-C9KM-7Ur.js.map