OpenPanel is an open-source web and product analytics platform, an open-source alternative to Mixpanel with optional self-hosting.
import { Link, Text } from '@react-email/components';
import { z } from 'zod';
import { Layout } from '../components/layout';
import { withUtm } from '../utm';
export const zOnboardingFeatureRequest = z.object({
firstName: z.string().optional(),
hasData: z.boolean().default(true),
});
export type Props = z.infer<typeof zOnboardingFeatureRequest>;
export default OnboardingFeatureRequest;
export function OnboardingFeatureRequest({
firstName,
hasData = true,
unsubscribeUrl,
}: Props & { unsubscribeUrl?: string }) {
return (
<Layout unsubscribeUrl={unsubscribeUrl}>
<Text>Hi{firstName ? ` ${firstName}` : ''},</Text>
<Text>
You're halfway through your trial, so a quick question: is there
anything you expected OpenPanel to do that it doesn't?
</Text>
<Text>
Just reply to this email. If you'd rather post publicly, the feedback
board is at{' '}
<Link
href={withUtm(
'https://feedback.openpanel.dev',
'onboarding-feature-request'
)}
>
feedback.openpanel.dev
</Link>
.
</Text>
{!hasData && (
<Text>
And if you never got around to installing the tracking, no hard
feelings, but I'd like to know what got in the way.
</Text>
)}
<Text>Carl</Text>
</Layout>
);
}
OnboardingFeatureRequest.PreviewProps = {
firstName: 'Alex',
hasData: true,
};