Skip to content

Commit 11d2db7

Browse files
committed
update get started button
1 parent 2463cb7 commit 11d2db7

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

app/routes/_marketing+/index.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
import { type MetaFunction } from '@remix-run/node'
22
import { Link } from '@remix-run/react'
33
import { Button } from '#app/components/ui/button.js'
4+
import { useOptionalUser } from '#app/utils/user.js'
45

56
export const meta: MetaFunction = () => [{ title: 'GratiText' }]
67

78
export default function Index() {
9+
const user = useOptionalUser()
810
return (
911
<main className="bg-gray-100 py-12">
1012
<section className="container mx-auto px-4">
@@ -115,7 +117,11 @@ export default function Index() {
115117
</div>
116118
<div className="mt-12 text-center">
117119
<Button asChild>
118-
<Link to="/login">Get Started</Link>
120+
{user ? (
121+
<Link to="/recipients">Your Recipients</Link>
122+
) : (
123+
<Link to="/login">Get Started</Link>
124+
)}
119125
</Button>
120126
</div>
121127
</section>

0 commit comments

Comments
 (0)