From 1fbe63454f33405c8b084e18ee6b7ac3d98ee5d5 Mon Sep 17 00:00:00 2001 From: Sam Becker Date: Sun, 11 Aug 2024 12:29:44 -0400 Subject: [PATCH] Document explicit specs to --- src/app/layout.tsx | 3 --- src/components/Badge.tsx | 4 +--- src/components/SiteGrid.tsx | 24 ++++++++++-------------- src/site/config.ts | 2 -- 4 files changed, 11 insertions(+), 22 deletions(-) diff --git a/src/app/layout.tsx b/src/app/layout.tsx index 7fff3211..59aaec56 100644 --- a/src/app/layout.tsx +++ b/src/app/layout.tsx @@ -4,7 +4,6 @@ import { clsx } from 'clsx/lite'; import { IBM_Plex_Mono } from 'next/font/google'; import { BASE_URL, - CENTERED_LARGE_SCREENS, DEFAULT_THEME, SITE_DESCRIPTION, SITE_DOMAIN_OR_TITLE, @@ -28,8 +27,6 @@ const ibmPlexMono = IBM_Plex_Mono({ subsets: ['latin'], weight: ['400', '500', '700'], variable: '--font-ibm-plex-mono', - display: 'swap', // font wouldn't load in vercel dev environment, solution from link below - // https://stackoverflow.com/a/76484168 }); export const metadata: Metadata = { diff --git a/src/components/Badge.tsx b/src/components/Badge.tsx index 380b1dba..47505733 100644 --- a/src/components/Badge.tsx +++ b/src/components/Badge.tsx @@ -28,9 +28,7 @@ export default function Badge({ case 'small': return clsx( 'h-max-baseline', - // 'px-[5px] py-[2.75px]', //original padding - 'block', // added to keep gray background around text when overflowed - 'px-[6px] py-[5px]', // increased padding for block and to stop content shift + 'px-[5px] py-[2.75px]', 'text-[0.7rem] font-medium rounded-[0.25rem]', highContrast ? 'text-invert bg-invert' diff --git a/src/components/SiteGrid.tsx b/src/components/SiteGrid.tsx index b119e196..6c8e38d8 100644 --- a/src/components/SiteGrid.tsx +++ b/src/components/SiteGrid.tsx @@ -1,6 +1,13 @@ import { clsx } from 'clsx/lite'; import { RefObject } from 'react'; -import { CENTERED_LARGE_SCREENS } from '@/site/config'; + +/* + Max widths (lg and up) + Main: 954px + + Sidebar: 302px + + Gap: 24px = + Total: 1280px +*/ export default function SiteGrid({ containerRef, @@ -26,29 +33,18 @@ export default function SiteGrid({ 'gap-x-4 lg:gap-x-6', 'gap-y-4', 'max-w-7xl', - CENTERED_LARGE_SCREENS && 'mx-auto', className, )} >
{contentMain}
{contentSide &&
diff --git a/src/site/config.ts b/src/site/config.ts index ad01fbd8..a7097cc6 100644 --- a/src/site/config.ts +++ b/src/site/config.ts @@ -155,8 +155,6 @@ export const SHOW_FILM_SIMULATIONS = process.env.NEXT_PUBLIC_HIDE_FILM_SIMULATIONS !== '1'; export const SHOW_EXIF_DATA = process.env.NEXT_PUBLIC_HIDE_EXIF_DATA !== '1'; -export const CENTERED_LARGE_SCREENS = - process.env.NEXT_PUBLIC_CENTERED_ON_LARGE_SCREENS === '1'; export const GRID_ASPECT_RATIO = process.env.NEXT_PUBLIC_GRID_ASPECT_RATIO ? parseFloat(process.env.NEXT_PUBLIC_GRID_ASPECT_RATIO)