feat: Payment invoice preview drawer

This commit is contained in:
Ahmed Bouhuolia
2024-09-19 12:45:06 +02:00
parent 809973730f
commit 16eaacd4bc
8 changed files with 93 additions and 18 deletions

View File

@@ -3,10 +3,17 @@ import clsx from 'classnames';
import { Box, Group, Stack } from '@/components';
import styles from './PaymentPortal.module.scss';
import { usePaymentPortalBoot } from './PaymentPortalBoot';
import { useDrawerActions } from '@/hooks/state';
import { DRAWERS } from '@/constants/drawers';
export function PaymentPortal() {
const { openDrawer } = useDrawerActions();
const { sharableLinkMeta } = usePaymentPortalBoot();
const handleInvoicePreviewBtnClick = () => {
openDrawer(DRAWERS.PAYMENT_INVOICE_PREVIEW);
};
return (
<Box className={styles.root}>
<Stack spacing={0} className={styles.body}>
@@ -85,6 +92,7 @@ export function PaymentPortal() {
Download Invoice
</Button>
<Button
onClick={handleInvoicePreviewBtnClick}
className={clsx(styles.footerButton, styles.viewInvoiceButton)}
>
View Invoice