import * as React from 'react';
import { Link } from 'react-router-dom';
import Box from '@mui/material/Box';
import Button from '@mui/material/Button';
import Chip from '@mui/material/Chip';
import Card from '@mui/material/Card';
import CardActions from '@mui/material/CardActions';
import CardContent from '@mui/material/CardContent';
import Divider from '@mui/material/Divider';
import Grid from '@mui/material/Grid';
import Typography from '@mui/material/Typography';
import { TBillingCardAction } from '@automatisch/types';
import * as URLS from 'config/urls';
import useBillingAndUsageData from 'hooks/useBillingAndUsageData.ee';
import useFormatMessage from 'hooks/useFormatMessage';
const capitalize = (str: string) =>
str[0].toUpperCase() + str.slice(1, str.length);
type BillingCardProps = {
name: string;
title?: string;
action?: TBillingCardAction;
};
function BillingCard(props: BillingCardProps) {
const { name, title = '', action } = props;
return (
theme.palette.background.default,
}}
>
{name}
{title}
);
}
function Action(props: { action?: TBillingCardAction }) {
const { action } = props;
if (!action) return ;
const { text, type } = action;
if (type === 'link') {
if (action.src.startsWith('http')) {
return (
);
} else {
return (
);
}
}
if (type === 'text') {
return (
{text}
);
}
return ;
}
export default function Invoices() {
const formatMessage = useFormatMessage();
const billingAndUsageData = useBillingAndUsageData();
return (
Invoices
Date
Amount
Invoice
Mar 16, 2023
€20.00
Link
Mar 16, 2023
€20.00
Link
);
}