Skip to content

Commit

Permalink
feat: Invoice Email Template
Browse files Browse the repository at this point in the history
  • Loading branch information
alialaba committed Jul 22, 2024
1 parent f6ae4b8 commit 85d66d8
Showing 1 changed file with 3 additions and 19 deletions.
22 changes: 3 additions & 19 deletions app/root.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,24 +6,18 @@ import {
Outlet,
Scripts,
ScrollRestoration,
useLocation,
} from "@remix-run/react";
import type { ReactNode } from "react";

import FooterLight from "./components/ui/footerLight";
import Header from "./components/ui/header";
import { AdminSideNavBar } from "./components/SuperAdminSideBar/SuperAdminSideNavBar";
import styles from "./styles/global.css?url";
import InvoiceEmail from "./email/templates/invoice-email-temp/InvoiceEmail";

export const links: LinksFunction = () => [
{ rel: "stylesheet", href: styles },
...(cssBundleHref ? [{ rel: "stylesheet", href: cssBundleHref }] : []),
];

export function Layout({ children }: { children: ReactNode }) {
const location = useLocation();
const pagesWithNoFooter = ["/dashboard/password-settings"];
const showFooter = !pagesWithNoFooter.includes(location.pathname);
return (
<html lang="en">
<head>
Expand All @@ -33,19 +27,9 @@ export function Layout({ children }: { children: ReactNode }) {
<Links />
</head>
<body>

<InvoiceEmail/>
<div className="flex">
<main className="flex-1">{children}</main>
,

<div>
<main>
<Header />
{children}
{showFooter && <FooterLight />}
</main>

<AdminSideNavBar />
<main className="flex-1">{children}</main>,
<ScrollRestoration />
<Scripts />
</div>
Expand Down

0 comments on commit 85d66d8

Please sign in to comment.