From 60a44742624fe5ad57223f5facbde91e95998998 Mon Sep 17 00:00:00 2001 From: "Kent C. Dodds" Date: Fri, 20 Sep 2024 11:22:04 -0600 Subject: [PATCH] add location support for workshops --- app/root.tsx | 9 ++++++++- content/workshops/advanced-react-apis.yml | 1 + types/index.d.ts | 1 + 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/app/root.tsx b/app/root.tsx index 8f9a3eb6a..65beb1663 100644 --- a/app/root.tsx +++ b/app/root.tsx @@ -173,6 +173,7 @@ export async function loader({ request }: LoaderFunctionArgs) { title: workshop.title, slug: workshop.slug, promoName, + location: event.location, dismissTimeSeconds: Math.min( Math.max( // one quarter of the time until the promoEndTime (in seconds) @@ -241,6 +242,7 @@ export async function loader({ request }: LoaderFunctionArgs) { title: e.title, slug: workshop.slug, promoName, + location: e.location, dismissTimeSeconds: Math.min( Math.max( // one quarter of the time until the promoEndTime (in seconds) @@ -475,10 +477,15 @@ function App() {

- Join Kent for an interactive{' '} + Join Kent for a{' '} live workshop + {e.location + ? e.location === 'Remote' + ? null + : ` in ${e.location}` + : null}