From 378c10c84a1bd4502ea96e4924f007bd9e01f3d2 Mon Sep 17 00:00:00 2001 From: Dotta Date: Mon, 20 Apr 2026 10:50:35 -0500 Subject: [PATCH] fix(ui): fix Storybook style parity with main app MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The @tailwindcss/vite plugin only generates CSS for classes found in the Vite module graph. In the Storybook build, many component source files were not in the graph, producing only 70KB of CSS versus the main app's 263KB — missing data-state, data-slot, and hundreds of utility classes. Added a storybook-specific CSS entry with @source "../../src" so Tailwind v4 scans all component files, bringing the generated CSS to 283KB with full style parity. Co-Authored-By: Paperclip --- ui/storybook/.storybook/preview.tsx | 2 +- ui/storybook/.storybook/tailwind-entry.css | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 ui/storybook/.storybook/tailwind-entry.css diff --git a/ui/storybook/.storybook/preview.tsx b/ui/storybook/.storybook/preview.tsx index 92767f8c294..8334b14e52a 100644 --- a/ui/storybook/.storybook/preview.tsx +++ b/ui/storybook/.storybook/preview.tsx @@ -23,7 +23,7 @@ import { storybookSidebarBadges, } from "../fixtures/paperclipData"; import "@mdxeditor/editor/style.css"; -import "@/index.css"; +import "./tailwind-entry.css"; import "./styles.css"; function installStorybookApiFixtures() { diff --git a/ui/storybook/.storybook/tailwind-entry.css b/ui/storybook/.storybook/tailwind-entry.css new file mode 100644 index 00000000000..4d76eea8f70 --- /dev/null +++ b/ui/storybook/.storybook/tailwind-entry.css @@ -0,0 +1,2 @@ +@import "../../src/index.css"; +@source "../../src";