Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions app/(blobs)/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import BackgroundBlobs from '~/components/BackgroundBlobs/BackgroundBlobs';
import Image from 'next/image';
import type { PropsWithChildren } from 'react';
import Link from 'next/link';
import type { PropsWithChildren } from 'react';
import BackgroundBlobs from '~/components/BackgroundBlobs/BackgroundBlobs';
import NetlifyBadge from '~/components/NetlifyBadge';

export default function Layout({ children }: PropsWithChildren) {
return (
<>
<div className="relative z-10 flex h-[90dvh] w-[100dvw] flex-col">
<div className="relative z-10 flex min-h-dvh w-dvw flex-col">
<div className="p-6">
<Link href="/">
<Image
Expand All @@ -22,8 +23,9 @@ export default function Layout({ children }: PropsWithChildren) {
<main className="flex grow items-center justify-center">
{children}
</main>
<NetlifyBadge />
</div>
<div className="text-background-primary fixed left-0 top-0 h-[100dvh] w-[100dvw] bg-navy-taupe">
<div className="text-background-primary bg-navy-taupe fixed top-0 left-0 h-[100dvh] w-[100dvw]">
<BackgroundBlobs large={0} medium={3} small={4} />
</div>
</>
Expand Down
2 changes: 2 additions & 0 deletions app/dashboard/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import NetlifyBadge from '~/components/NetlifyBadge';
import { getAppSetting, requireAppNotExpired } from '~/queries/appSettings';
import { requirePageAuth } from '~/utils/auth';
import { NavigationBar } from './_components/NavigationBar';
Expand All @@ -22,6 +23,7 @@ const Layout = async ({ children }: { children: React.ReactNode }) => {
{!uploadThingToken && <UploadThingModal />}

{children}
<NetlifyBadge />
</>
);
};
Expand Down
14 changes: 0 additions & 14 deletions app/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
import { Quicksand } from 'next/font/google';
import ResponsiveContainer from '~/components/ResponsiveContainer';
import { Toaster } from '~/components/ui/toaster';
import { env } from '~/env';
import '~/styles/globals.css';

export const metadata = {
Expand All @@ -21,18 +19,6 @@ function RootLayout({ children }: { children: React.ReactNode }) {
<body className={`${quicksand.className} antialiased`}>
{children}
<Toaster />
{env.SANDBOX_MODE && (
<ResponsiveContainer>
<footer className="z-1 flex justify-center py-4">
<a href="https://www.netlify.com">
<img
src="https://www.netlify.com/assets/badges/netlify-badge-color-accent.svg"
alt="Deploys by Netlify"
/>
</a>
</footer>
</ResponsiveContainer>
)}
</body>
</html>
);
Expand Down
18 changes: 18 additions & 0 deletions components/NetlifyBadge.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
import { env } from '~/env';

export default function NetlifyBadge() {
if (!env.SANDBOX_MODE) {
return null;
}

return (
<footer className="flex justify-center py-4">
<a href="https://www.netlify.com">
<img
src="https://www.netlify.com/assets/badges/netlify-badge-color-accent.svg"
alt="Deploys by Netlify"
/>
</a>
</footer>
);
}
Loading