Skip to content

Open source CapCut alternative.

TypeScript

fix(site): render the signed-in app surface on a white theme so outline buttons aren't beige

David Le5e607bbccefe
diff --git a/site/src/app/app/settings/_components/CreditsCard.tsx b/site/src/app/app/settings/_components/CreditsCard.tsx
index 4219b680..587e4dc6 100644
--- a/site/src/app/app/settings/_components/CreditsCard.tsx
+++ b/site/src/app/app/settings/_components/CreditsCard.tsx
@@ -70,7 +70,6 @@ export function CreditsCard() {
<div className="flex flex-wrap gap-2">
{creditTopUpPresetsDollars.map((amount) => (
<Button
- className={customAmount === String(amount) ? undefined : "bg-card"}
disabled={checkout.isPending}
key={amount}
onClick={() => setCustomAmount(String(amount))}
diff --git a/site/src/app/app/settings/_components/SuperuserCreditsCard.tsx b/site/src/app/app/settings/_components/SuperuserCreditsCard.tsx
index 60e0f0bd..f43122e0 100644
--- a/site/src/app/app/settings/_components/SuperuserCreditsCard.tsx
+++ b/site/src/app/app/settings/_components/SuperuserCreditsCard.tsx
@@ -117,7 +117,6 @@ export function SuperuserCreditsCard() {
{presetDollars.map((preset) => (
<Button
key={preset}
- className={amount === String(preset) ? undefined : "bg-card"}
onClick={() => setAmount(String(preset))}
type="button"
variant={amount === String(preset) ? "default" : "outline"}
diff --git a/site/src/app/app/settings/_components/UsageHistoryCard.tsx b/site/src/app/app/settings/_components/UsageHistoryCard.tsx
index 2b3d1889..19a85e81 100644
--- a/site/src/app/app/settings/_components/UsageHistoryCard.tsx
+++ b/site/src/app/app/settings/_components/UsageHistoryCard.tsx
@@ -312,7 +312,6 @@ export function UsageHistoryCard() {
(pageNumber) => (
<PaginationItem key={pageNumber}>
<PaginationLink
- className={pageNumber === currentPage ? "bg-card" : undefined}
isActive={pageNumber === currentPage}
onClick={() => goToPage(pageNumber)}
>
diff --git a/site/src/app/globals.css b/site/src/app/globals.css
index 8c1d3023..76ac6606 100644
--- a/site/src/app/globals.css
+++ b/site/src/app/globals.css
@@ -124,6 +124,17 @@
--sidebar-ring: oklch(0.556 0 0);
}
+/* App theme: the signed-in /app surface renders on white instead of the cream
+ landing background. Defined unlayered (like :root, the landing theme) so it
+ wins the cascade — an @layer base rule would lose to the unlayered :root no
+ matter its specificity. Repointing this one token flows everywhere keyed to
+ bg-background: the html/overscroll area, body, and every shadcn component
+ (e.g. the outline button variant). CSS variables inherit from html, so
+ portaled dialogs pick it up too. */
+html.app-surface {
+ --background: oklch(1 0 0);
+}
+
@layer base {
* {
@apply border-border outline-ring/50;
@@ -144,10 +155,4 @@
html {
@apply bg-background font-sans;
}
- /* The signed-in /app surface renders on white; override the cream landing
- background on html/body so it does not show through the overscroll area. */
- html.app-surface,
- html.app-surface body {
- @apply bg-white;
- }
}