mirror of
https://github.com/hanzo-docs/docs.git
synced 2026-10-24 20:09:02 +00:00
Make the docs CTA "Try Hanzo", to hanzo.ai/login
Every conversion CTA reads "Try Hanzo" and goes to sign-in; payment comes after it. The landing's close now does that in place of "Choose plan". It no longer fires plan_clicked: it is not a plan choice, and the page view and the $click that <Hanzo> autocaptures already record it. That leaves the EVENTS re-export in @hanzo/docs-analytics with no caller, so it goes too.
This commit is contained in:
@@ -142,14 +142,16 @@ app.
|
||||
- **No page sends a visitor to hanzo.id.** Sign-in is `https://hanzo.ai/login`
|
||||
(`components/account.tsx`; `/login` is a rule in `public/_redirects`).
|
||||
Sign-out clears the session in this browser and navigates nowhere.
|
||||
- **The conversion CTA reads "Choose plan"** and opens `https://hanzo.ai/pricing`,
|
||||
firing `plan_clicked` `{ source: 'docs' }` (`components/landing.tsx`).
|
||||
- **Events are catalog names only** — `EVENTS` from @hanzo/events, re-exported
|
||||
by `@hanzo/docs-analytics`. That package sends page views (first load and each
|
||||
route change) to `api.hanzo.ai/v1/event` with the key `@hanzo/event`'s keyring
|
||||
- **The conversion CTA reads "Try Hanzo"** and opens `https://hanzo.ai/login`;
|
||||
payment comes after sign-in (`components/landing.tsx`). It sends no event of
|
||||
its own: it is not a plan choice, and the page view and click cover it.
|
||||
- **Tracking is `@hanzo/docs-analytics`**: page views (first load and each route
|
||||
change) to `api.hanzo.ai/v1/event`, and `<Hanzo>` (@hanzo/ui) autocaptures
|
||||
`$click` onto the same client. The key is the one `@hanzo/event`'s keyring
|
||||
resolves from the page's host: `docs.hanzo.ai` is the hanzo org's, `localhost`
|
||||
resolves none. The cold image lane's `PUBLISHABLE_KEY` build arg is no longer
|
||||
read by any app.
|
||||
resolves none. An event this site names itself comes from the @hanzo/events
|
||||
catalog. The cold image lane's `PUBLISHABLE_KEY` build arg is no longer read
|
||||
by any app.
|
||||
|
||||
## Build guards, and why prose needs them
|
||||
|
||||
|
||||
@@ -20,7 +20,6 @@ import {
|
||||
Workflow,
|
||||
} from '@hanzogui/lucide-icons-2';
|
||||
import { Grid } from '@hanzo/ui/grid';
|
||||
import { EVENTS, useAnalytics } from '@hanzo/docs-analytics';
|
||||
import { Action } from '@/components/action';
|
||||
import { Agent } from '@/components/agent';
|
||||
import { HeroField } from '@/components/hero-field';
|
||||
@@ -144,7 +143,6 @@ function Tile({ name, spec, mono = false }: { name: string; spec: string; mono?:
|
||||
}
|
||||
|
||||
export function Landing({ install, use }: { install: ReactNode; use: ReactNode }) {
|
||||
const analytics = useAnalytics();
|
||||
return (
|
||||
<YStack render="main" minW={0} pb={48}>
|
||||
{/* The hero, centred over its halftone. */}
|
||||
@@ -411,16 +409,8 @@ export function Landing({ install, use }: { install: ReactNode; use: ReactNode }
|
||||
curl hanzo.sh | sh
|
||||
</Text>
|
||||
<XStack flexWrap="wrap" gap={12} justify="center">
|
||||
<Action
|
||||
tone="loud"
|
||||
render="a"
|
||||
href="https://hanzo.ai/pricing"
|
||||
onPress={() => analytics.capture(EVENTS.PLAN_CLICKED, { source: 'docs' })}
|
||||
height={44}
|
||||
px={28}
|
||||
rounded={999}
|
||||
>
|
||||
Choose plan
|
||||
<Action tone="loud" render="a" href="https://hanzo.ai/login" height={44} px={28} rounded={999}>
|
||||
Try Hanzo
|
||||
</Action>
|
||||
<Action tone="line" render={<Link href="/docs" prefetch={false} />} height={44} px={28} rounded={999}>
|
||||
Browse documentation
|
||||
|
||||
@@ -3,10 +3,8 @@
|
||||
import { keyForPage } from '@hanzo/event';
|
||||
import { AnalyticsProvider, usePageview } from '@hanzo/event/react';
|
||||
|
||||
/** The client, for a page that sends an event of its own, and the catalog
|
||||
* (@hanzo/events) it takes the event's name from. */
|
||||
/** The client, for a page that sends an event of its own. */
|
||||
export { useAnalytics } from '@hanzo/event/react';
|
||||
export { EVENTS } from '@hanzo/event';
|
||||
import { usePathname } from 'next/navigation';
|
||||
import type { ReactNode } from 'react';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user