Skip to content

Commit a03c588

Browse files
committed
Adds DevPresenceBanner to the Run list page
1 parent 10ebe69 commit a03c588

File tree

1 file changed

+16
-0
lines changed
  • apps/webapp/app/routes/_app.orgs.$organizationSlug.projects.$projectParam.env.$envParam.runs._index

1 file changed

+16
-0
lines changed

apps/webapp/app/routes/_app.orgs.$organizationSlug.projects.$projectParam.env.$envParam.runs._index/route.tsx

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import { ListChecks, ListX } from "lucide-react";
88
import { Suspense, useState } from "react";
99
import { TypedAwait, typeddefer, useTypedLoaderData } from "remix-typedjson";
1010
import { TaskIcon } from "~/assets/icons/TaskIcon";
11+
import { DevPresenceBanner, useDevPresence } from "~/components/DevPresence";
1112
import { StepContentContainer } from "~/components/StepContentContainer";
1213
import { MainCenteredContainer, PageBody } from "~/components/layout/AppLayout";
1314
import { Button, LinkButton } from "~/components/primitives/Buttons";
@@ -161,11 +162,26 @@ export default function Page() {
161162
const { data, rootOnlyDefault } = useTypedLoaderData<typeof loader>();
162163
const navigation = useNavigation();
163164
const isLoading = navigation.state !== "idle";
165+
const { isConnected } = useDevPresence();
166+
const environment = useEnvironment();
164167

165168
return (
166169
<>
167170
<NavBar>
168171
<PageTitle title="Runs" />
172+
<AnimatePresence>
173+
{environment.type === "DEVELOPMENT" && !isConnected && (
174+
<motion.div
175+
initial={{ opacity: 0 }}
176+
animate={{ opacity: 1 }}
177+
exit={{ opacity: 0 }}
178+
transition={{ duration: 0.3 }}
179+
className="flex"
180+
>
181+
<DevPresenceBanner />
182+
</motion.div>
183+
)}
184+
</AnimatePresence>
169185
<PageAccessories>
170186
<LinkButton
171187
variant={"docs/small"}

0 commit comments

Comments
 (0)