diff --git a/modules/customer-invoices/src/web/issued-invoices/list/ui/components/index.ts b/modules/customer-invoices/src/web/issued-invoices/list/ui/components/index.ts index 2cf1fb81..d9f7dce1 100644 --- a/modules/customer-invoices/src/web/issued-invoices/list/ui/components/index.ts +++ b/modules/customer-invoices/src/web/issued-invoices/list/ui/components/index.ts @@ -1 +1,2 @@ +export * from "./issued-invoices-grid-empty"; export * from "./verifactu-status-badge"; diff --git a/modules/customer-invoices/src/web/issued-invoices/list/ui/components/issued-invoices-grid-empty.tsx b/modules/customer-invoices/src/web/issued-invoices/list/ui/components/issued-invoices-grid-empty.tsx new file mode 100644 index 00000000..8d6d9f66 --- /dev/null +++ b/modules/customer-invoices/src/web/issued-invoices/list/ui/components/issued-invoices-grid-empty.tsx @@ -0,0 +1,17 @@ +import { Card, CardContent } from "@repo/shadcn-ui/components"; +import { cn } from "@repo/shadcn-ui/lib/utils"; +import { ChartNoAxesColumnIncreasingIcon } from "lucide-react"; + +export const IssuedInvoicesEmptyGrid = ({ className }: React.ComponentProps<"div">) => { + return ( + + +
+ +

No data to show

+

May take 15 minutes for data to load

+
+
+
+ ); +}; diff --git a/modules/customer-invoices/src/web/issued-invoices/list/ui/pages/list-issued-invoices-page.tsx b/modules/customer-invoices/src/web/issued-invoices/list/ui/pages/list-issued-invoices-page.tsx index afbe7149..cde08e4b 100644 --- a/modules/customer-invoices/src/web/issued-invoices/list/ui/pages/list-issued-invoices-page.tsx +++ b/modules/customer-invoices/src/web/issued-invoices/list/ui/pages/list-issued-invoices-page.tsx @@ -17,6 +17,7 @@ import { useNavigate } from "react-router-dom"; import { useTranslation } from "../../../../i18n"; import { useIssuedInvoiceListPageController } from "../../controllers"; import { IssuedInvoicesGrid, useIssuedInvoicesGridColumns } from "../blocks"; +import { IssuedInvoicesEmptyGrid } from "../components"; export const ListIssuedInvoicesPage = () => { const { t } = useTranslation(); @@ -88,63 +89,71 @@ export const ListIssuedInvoicesPage = () => { {/* Search and filters */} -
- + {listCtrl.data.totalItems === 0 && } - -
-
- navigate(`/issuedInvoices/${id}`)} - pageIndex={listCtrl.pageIndex} - pageSize={listCtrl.pageSize} - /> -
+ {listCtrl.data.totalItems !== 0 && ( + <> +
+ + + +
+
+ navigate(`/issuedInvoices/${id}`)} + pageIndex={listCtrl.pageIndex} + pageSize={listCtrl.pageSize} + /> +
+ + )} ); diff --git a/modules/customers/src/web/_archived/components/customer-modal-selector/customer-empty-card.tsx b/modules/customers/src/web/_archived/components/customer-modal-selector/customer-empty-card.tsx index 33929706..1accd7f4 100644 --- a/modules/customers/src/web/_archived/components/customer-modal-selector/customer-empty-card.tsx +++ b/modules/customers/src/web/_archived/components/customer-modal-selector/customer-empty-card.tsx @@ -3,21 +3,21 @@ import { UserSearchIcon } from "lucide-react"; export const CustomerEmptyCard = (props: React.ComponentProps<"button">) => { return (