Skip to content

Commit

Permalink
feat: update demo plans modal (#8594)
Browse files Browse the repository at this point in the history
Update demo banner for PAYG plan
  • Loading branch information
Tymek authored Oct 31, 2024
1 parent 8d4e3ef commit f967cb9
Showing 1 changed file with 71 additions and 31 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { DemoDialog } from '../DemoDialog';
import GitHub from '@mui/icons-material/GitHub';
import Launch from '@mui/icons-material/Launch';
import { usePlausibleTracker } from 'hooks/usePlausibleTracker';
import { useUiFlag } from 'hooks/useUiFlag';

const StyledDemoDialog = styled(DemoDialog)(({ theme }) => ({
'& .MuiDialog-paper': {
Expand Down Expand Up @@ -82,6 +83,7 @@ interface IDemoDialogPlansProps {

export const DemoDialogPlans = ({ open, onClose }: IDemoDialogPlansProps) => {
const { trackEvent } = usePlausibleTracker();
const isEnterprisePaygEnabled = useUiFlag('enterprise-payg');

return (
<StyledDemoDialog open={open} onClose={onClose}>
Expand Down Expand Up @@ -117,39 +119,77 @@ export const DemoDialogPlans = ({ open, onClose }: IDemoDialogPlansProps) => {
View project on GitHub
</Button>
</StyledPlan>
<StyledPlan>
<Typography variant='h5' fontWeight='bold'>
Pro
</Typography>
<Typography variant='body2' color='textSecondary'>
Free your team to collaborate. We'll do the heavy
lifting.
</Typography>
<div>
<Typography variant='h6' fontWeight='normal'>
$80/month
{isEnterprisePaygEnabled ? (
<StyledPlan>
<Typography variant='h5' fontWeight='bold'>
Enterprise
<br />
Pay-as-You-Go
</Typography>
<Typography variant='body2'>
includes 5 seats
<Typography variant='body2' color='textSecondary'>
All the features of Enterprise with no long term
commitment.
</Typography>
</div>
<Button
variant='contained'
color='primary'
href='https://www.getunleash.io/plans/pro'
target='_blank'
rel='noreferrer'
onClick={() => {
trackEvent('demo-see-plan', {
props: {
plan: 'pro',
},
});
}}
>
Start 14-day free trial
</Button>
</StyledPlan>
<div>
<Typography variant='h6' fontWeight='normal'>
$75 per user/month
</Typography>
<Typography variant='body2'>
5 users minimum
</Typography>
</div>
<Button
variant='contained'
color='primary'
href='https://www.getunleash.io/plans/enterprise-payg'
target='_blank'
rel='noreferrer'
onClick={() => {
trackEvent('demo-see-plan', {
props: {
plan: 'enterprise-starter',
},
});
}}
>
Start 14-day free trial
</Button>
</StyledPlan>
) : (
<StyledPlan>
<Typography variant='h5' fontWeight='bold'>
Pro
</Typography>
<Typography variant='body2' color='textSecondary'>
Free your team to collaborate. We'll do the heavy
lifting.
</Typography>
<div>
<Typography variant='h6' fontWeight='normal'>
$80/month
</Typography>
<Typography variant='body2'>
includes 5 seats
</Typography>
</div>
<Button
variant='contained'
color='primary'
href='https://www.getunleash.io/plans/pro'
target='_blank'
rel='noreferrer'
onClick={() => {
trackEvent('demo-see-plan', {
props: {
plan: 'pro',
},
});
}}
>
Start 14-day free trial
</Button>
</StyledPlan>
)}
<StyledPlan>
<Typography variant='h5' fontWeight='bold'>
Enterprise
Expand Down

0 comments on commit f967cb9

Please sign in to comment.