docs: add Tailwind CSS v4 & shadcn/ui guides with e2e tests#3099
docs: add Tailwind CSS v4 & shadcn/ui guides with e2e tests#3099
Conversation
Add an e2e test fixture verifying Tailwind CSS v4 integration with Rspress, and add dedicated Tailwind CSS documentation pages (en/zh) to the website. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Rsdoctor Bundle Diff AnalysisFound 3 projects in monorepo, 3 projects with changes. 📊 Quick Summary
📋 Detailed Reports (Click to expand)📁 nodePath:
📦 Download Diff Report: node Bundle Diff 📁 node_mdPath:
📦 Download Diff Report: node_md Bundle Diff 📁 webPath:
📦 Download Diff Report: web Bundle Diff Generated by Rsdoctor GitHub Action |
Deploying rspress-v2 with
|
| Latest commit: |
9aa7255
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://c5eb8a9c.rspress-v2.pages.dev |
| Branch Preview URL: | https://syt-vibe-kanban-0358-tailwin.rspress-v2.pages.dev |
There was a problem hiding this comment.
Pull request overview
This PR adds official Tailwind CSS v4 integration coverage to the repo, both in documentation and in automated e2e testing. It introduces a dedicated Tailwind v4 fixture, updates dependency locking for the new tooling, and wires Tailwind docs into the website navigation.
Changes:
- Add English and Chinese Tailwind CSS v4 setup guides, including PostCSS and
globalStylesconfiguration examples. - Introduce a new
e2e/fixtures/tailwind-v4project (config, CSS, MDX page, and Playwright test) to verify Tailwind utilities work correctly with Rspress. - Update dependency-related tooling: extend
check-dependency-versionignores and refreshpnpm-lock.yamlwith Tailwind v4 and its transitive dependencies.
Reviewed changes
Copilot reviewed 12 out of 13 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
website/docs/zh/guide/basic/tailwind-css.mdx |
New Chinese guide describing how to install, configure, and use Tailwind CSS v4 with Rspress, including example MDX usage. |
website/docs/zh/guide/basic/_meta.json |
Registers the new Tailwind CSS guide in the Chinese basic guide sidebar navigation. |
website/docs/en/guide/basic/tailwind-css.mdx |
New English Tailwind CSS v4 integration guide with PostCSS config, tailwind.css entry file, rspress.config.ts example, and usage snippet. |
website/docs/en/guide/basic/_meta.json |
Registers the new Tailwind CSS guide in the English basic guide sidebar navigation. |
pnpm-lock.yaml |
Locks in Tailwind CSS v4 (tailwindcss, @tailwindcss/postcss, @tailwindcss/node, @tailwindcss/oxide*) and associated lightningcss artifacts, and updates the resolved graph for rsbuild-plugin-publint and related tooling. |
package.json |
Extends the check-dependency-version script to ignore the new @rspress-fixture/tailwind-v4 fixture when enforcing dependency consistency. |
e2e/fixtures/tailwind-v4/tsconfig.json |
TypeScript config for the Tailwind v4 fixture, enabling MDX checking and targeting the doc content plus rspress.config.ts. |
e2e/fixtures/tailwind-v4/tailwind.css |
Minimal Tailwind CSS entry file using @import 'tailwindcss'; for v4. |
e2e/fixtures/tailwind-v4/rspress.config.ts |
Rspress configuration for the Tailwind v4 fixture, wiring root: doc and globalStyles: tailwind.css. |
e2e/fixtures/tailwind-v4/postcss.config.mjs |
PostCSS configuration that enables Tailwind v4 via the @tailwindcss/postcss plugin. |
e2e/fixtures/tailwind-v4/package.json |
Package definition for the Tailwind v4 fixture, including Rspress core dependency and Tailwind v4 devDependencies. |
e2e/fixtures/tailwind-v4/index.test.ts |
Playwright e2e test that boots the fixture with rspress dev and asserts Tailwind utility classes affect computed color, font-weight, and padding as expected. |
e2e/fixtures/tailwind-v4/doc/index.mdx |
Example MDX page in the fixture that uses Tailwind utility classes to produce distinct styles for the test to assert against. |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…e docs - Add shadcn/ui integration guide (en/zh) with setup steps and Button example - Remove outdated Tailwind CSS v3 section from custom page documentation Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Reference Rsbuild's Tailwind CSS v4 and v3 documentation since Rspress is built on Rsbuild with consistent configuration. Add warnings about Cascade Layers browser compatibility and CSS preprocessor limitations. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
…dd e2e tests - Rewrite Tailwind CSS and shadcn/ui docs using <Steps> component for both zh/en - Add components.json configuration guide for shadcn/ui - Add dark mode @custom-variant setup to Tailwind CSS guide - Add shadcn/ui button and dark mode e2e tests to tailwind-v4 fixture - Sync Tailwind CSS preEntry tip to English preview.mdx - Fix shadcn-ui prerequisite link to new /ui/tailwindcss path Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Summary
<Steps>component for both zh/encomponents.jsonconfiguration guide and dark mode@custom-variantsetup for shadcn/uiguide/basic/toui/directoryTest plan
<Steps>componentcomponents.jsonexample works withshadcnCLI🤖 Generated with Claude Code