Skip to content

refactor(frontend): colocate owner-scoped CSS - #943

Merged
huyanxius merged 1 commit into
1024XEngineer:mainfrom
huyanxius:refactor/colocate-owner-css
Sep 18, 2026
Merged

huyanxius merged 1 commit into
1024XEngineer:mainfrom
huyanxius:refactor/colocate-owner-css

Conversation

@huyanxius

@huyanxius huyanxius commented Sep 18, 2026 •

Copy link
Copy Markdown
Collaborator

概要

  • 将 App Header、返回按钮、共享 Product Popover、Route Motion、Projects、Project Create 和 Playtest 的样式移动到各自明确的 owner 附近
  • 将 Project Preview 的暗色模式特例从全局主题文件移到 Projects 自己的样式文件
  • 保留 index.css 中真正的全局职责:Tailwind 入口、设计令牌,以及本次暂不处理的全局/待确认样式
  • 保持现有 class 名、动画参数、视觉表现和 reduced-motion 行为不变

本次范围

本次只做 CSS ownership 归位,不包含以下改动:

  • 不重命名 selector / class
  • 不把现有 CSS 批量改写为 Tailwind utilities
  • 不修改主题 token
  • 不顺手删除疑似 dead CSS,例如 action-reveal、projects-intro、projects-card-enter

验证

  • 已确认该开发分支基于同步后的 fork main,且仅领先 1 个 commit
  • 已确认 @theme 块与 upstream 保持逐字节一致
  • 已确认迁移后的 selector 不再残留在 index.css
  • 已确认每个 owner 都显式 import 自己的共置 CSS
  • frontend CI 将继续验证 lint、typecheck、test 和 build

Closes #942

@vercel

vercel Bot commented Sep 18, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
windup Ready Ready Preview Sep 18, 2026 6:56am UTC

@codecov

codecov Bot commented Sep 18, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #943   +/-   ##
=======================================
  Coverage   91.27%   91.27%           
=======================================
  Files         193      193           
  Lines       13204    13204           
=======================================
  Hits        12052    12052           
  Misses       1152     1152           
Flag Coverage Δ
backend 91.27% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@fennoai fennoai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

审阅结论

已审阅固定范围 40af76f…79ecdd7 的全部 16 个变更文件,并对照 #942 的纯 CSS ownership 迁移要求;未发现可确认的回归问题。各 owner 均显式导入共置样式,预览暗色覆盖与 reduced-motion 规则随对应模块保留,未发现具体的加载遗漏或覆盖顺序回归。

验证:按 selector、声明及 media/keyframe 上下文归一化比对,迁移前后 164 条 CSS 叶规则一致;@theme 内容逐字节一致;git diff --check 通过。当前工作区未安装 frontend 依赖,未运行 lint、typecheck、测试、构建或浏览器视觉验证,因此不将静态比对视为视觉验证通过。

View job run

@huyanxius

Copy link
Copy Markdown
Collaborator Author

@fennoai 没问题的话你能帮我 merge 一下不

@fennoai

fennoai Bot commented Sep 18, 2026 •

Copy link
Copy Markdown
Contributor

检查完成

  • PR refactor(frontend): colocate owner-scoped CSS #943 当前为 OPEN,不是 Draft,代码状态为 MERGEABLE。
  • Backend CI、Frontend CI、Version、Vercel 和 Codecov 检查均已通过。
  • 当前仍是 MERGE_STATE: BLOCKED,原因是 REVIEW_REQUIRED,需要至少一位符合规则的审阅者批准。
  • 我确认你对仓库拥有 admin 权限,但 FennoAI 不能代替仓库维护者执行合并操作,也不能自行批准 PR。

请让其他维护者完成审阅并批准后,你可以在 GitHub 上点击 Merge;届时 PR 应可合并。

@huyanxius
huyanxius merged commit 5b80256 into 1024XEngineer:main Sep 18, 2026
12 checks passed

This branch was successfully deployed

1 active deployment
Preview — 79ecdd7b Deployed Sep 18, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

refactor(frontend): colocate owner-scoped CSS outside index.css

2 participants