Skip to content

Commit

Permalink
put demo button behind feature flag
Browse files Browse the repository at this point in the history
  • Loading branch information
MarconLP committed Nov 20, 2024
1 parent 06c40d5 commit 99706ba
Showing 1 changed file with 13 additions and 10 deletions.
23 changes: 13 additions & 10 deletions src/pages/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ const Home: NextPage = () => {
const posthog = usePostHog();
const session = useSession();
const router = useRouter();
const showDemoButton = useFeatureFlagEnabled('show-demo-button')

useEffect(() => {
if (session.status === "authenticated" && !recordModalOpen) {
Expand Down Expand Up @@ -87,16 +88,18 @@ const Home: NextPage = () => {
<span className="text-xs">(no account required)</span>
</button>
<div className="flex flex-col gap-6 sm:flex-row">
<a
onClick={() =>
posthog?.capture("clicked watch recorded demo demo")
}
target="_blank"
href="https://snapify.it/share/clk3mpgnu0003mj0f042964wg"
className="text-sm font-semibold leading-6"
>
Watch recorded demo <span aria-hidden="true"></span>
</a>
{showDemoButton ? (
<a
onClick={() =>
posthog?.capture("clicked watch recorded demo demo")
}
target="_blank"
href="https://snapify.it/share/clk3mpgnu0003mj0f042964wg"
className="text-sm font-semibold leading-6"
>
Watch recorded demo <span aria-hidden="true"></span>
</a>
) : null}
<a
onClick={() => posthog?.capture("clicked schedule demo")}
target="_blank"
Expand Down

0 comments on commit 99706ba

Please sign in to comment.