From 9be9991af21ece97c7582738842041fb19b39acb Mon Sep 17 00:00:00 2001 From: Alper Gundogdu Date: Mon, 11 May 2026 16:20:06 +0100 Subject: [PATCH] chore(theme): migrate inline var() to Tailwind utilities (close #4) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Swap remaining `text-[var(--paper)]` arbitrary-value classes and `style={{ color: "var(--whisper)" }}` inline styles for the auto-generated Tailwind v4 utilities (`text-paper`, `text-whisper`, `bg-paper`, `bg-ink`, `border-current`, `pb-[2px]`). `app/globals.css` already exposes the tokens via `@theme inline`, so each utility resolves to the same CSS variable used today — no visual change, just style consistency across `Frame.tsx`, `Chrome.tsx`, `Hero.tsx`, `Comparison.tsx`, `Close.tsx`, and `FaqItem.tsx`. Co-Authored-By: Claude Opus 4.7 (1M context) --- components/site/Chrome.tsx | 8 +++----- components/site/Close.tsx | 2 +- components/site/Comparison.tsx | 7 +++---- components/site/Hero.tsx | 11 +++++------ components/ui/FaqItem.tsx | 2 +- components/ui/Frame.tsx | 4 ++-- 6 files changed, 15 insertions(+), 19 deletions(-) diff --git a/components/site/Chrome.tsx b/components/site/Chrome.tsx index 379621a..b9b02d5 100644 --- a/components/site/Chrome.tsx +++ b/components/site/Chrome.tsx @@ -118,7 +118,7 @@ export function Chrome() { data-scrolled={scrolled ? "true" : undefined} data-tone={onDark ? "ink" : "paper"} className={`chrome-nav fixed inset-x-0 top-0 z-50 py-5 ${ - onDark ? "text-[var(--paper)]" : "text-[var(--ink)]" + onDark ? "text-paper" : "text-ink" }`} style={{ paddingInline: "var(--frame-gutter)" }} > @@ -173,16 +173,14 @@ export function Chrome() {
Docs → Blog → diff --git a/components/site/Close.tsx b/components/site/Close.tsx index 11e4b38..efbdc82 100644 --- a/components/site/Close.tsx +++ b/components/site/Close.tsx @@ -44,7 +44,7 @@ export function Close() { }} className="max-w-[64ch] leading-[1.7]" > - deCDN{" "}is a peer-to-peer delivery layer for large files — software releases, datasets, media libraries, ai models, anything meant to be pulled a million times and that shouldn't depend on one bucket. the code is open. the network is open. the price is posted. + deCDN{" "}is a peer-to-peer delivery layer for large files — software releases, datasets, media libraries, ai models, anything meant to be pulled a million times and that shouldn't depend on one bucket. the code is open. the network is open. the price is posted.

the pattern repeats whenever something big ships: mirrors fork, cdns rate-limit, small teams burn tens of thousands hosting bytes they - don't own. deCDN{" "} - inverts every axis — supply forms around demand, not allocated to it. + don't own. deCDN inverts + every axis — supply forms around demand, not allocated to it.

@@ -77,8 +77,7 @@ export function Comparison() {
diff --git a/components/site/Hero.tsx b/components/site/Hero.tsx index a5f4230..83773cd 100644 --- a/components/site/Hero.tsx +++ b/components/site/Hero.tsx @@ -22,7 +22,7 @@ export function Hero() { the delivery layer anyone can serve - + . @@ -40,11 +40,10 @@ export function Hero() { verifies every chunk with blake3, and pays per megabyte in usdc — whether the payload is a linux iso, a dataset, a game patch, a media library, or an ai model.{" "} - deCDN is - demand-shaped, locality-optimised delivery for large files at - scale: supply forms around demand, cost collapses as regional - traffic concentrates. the code is open. the network is open. the - price is posted. + deCDN is demand-shaped, + locality-optimised delivery for large files at scale: supply forms + around demand, cost collapses as regional traffic concentrates. + the code is open. the network is open. the price is posted.

diff --git a/components/ui/FaqItem.tsx b/components/ui/FaqItem.tsx index 4380e2d..3322a8a 100644 --- a/components/ui/FaqItem.tsx +++ b/components/ui/FaqItem.tsx @@ -3,7 +3,7 @@ import type { ReactNode } from "react"; function highlightBrand(s: string): ReactNode[] { return s.split(/(decdn)/gi).map((part, i) => part.toLowerCase() === "decdn" ? ( - + deCDN ) : ( diff --git a/components/ui/Frame.tsx b/components/ui/Frame.tsx index 2369cd0..5e67901 100644 --- a/components/ui/Frame.tsx +++ b/components/ui/Frame.tsx @@ -11,8 +11,8 @@ type FrameProps = { }; const TONE_CLASS: Record = { - ink: "bg-[var(--ink)] text-[var(--paper)]", - paper: "bg-[var(--paper)] text-[var(--ink)]", + ink: "bg-ink text-paper", + paper: "bg-paper text-ink", }; export function Frame({ id, tone, className = "", children }: FrameProps) {