Skip to content

style(attachments): refine dark mode card tokens and hover states#349

Open
SonyLeo wants to merge 2 commits into
opentiny:developfrom
SonyLeo:style/attachments-dark-mode
Open

style(attachments): refine dark mode card tokens and hover states#349
SonyLeo wants to merge 2 commits into
opentiny:developfrom
SonyLeo:style/attachments-dark-mode

Conversation

@SonyLeo
Copy link
Copy Markdown
Collaborator

@SonyLeo SonyLeo commented May 20, 2026

Attachments 暗色模式适配

文档预览👉

截图对比

修改前
image

修改后
image

变更内容

  • 为 attachments 补充亮色和暗色主题 token,统一管理卡片背景、边框、hover、标题、元信息、操作按钮、重试按钮、关闭按钮和状态遮罩层颜色。
  • FileCard 内部的硬编码颜色改为复用全局 CSS 变量,减少组件内主题分散定义。
  • 优化暗色模式下附件卡片的 hover 表现和信息层级,提升边框、文本和操作区可读性。
  • 移除 demo 中固定标题颜色,避免覆盖暗色主题样式。

影响文件

  • packages/components/src/styles/variables.css
  • packages/components/src/attachments/components/FileCard.vue
  • packages/components/src/attachments/index.vue
  • docs/demos/attachments/custom-file-type.vue

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 20, 2026

Warning

Rate limit exceeded

@SonyLeo has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 59 minutes and 40 seconds before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 504c5b55-10ac-4d67-933f-2d9bfa99e77f

📥 Commits

Reviewing files that changed from the base of the PR and between 6ab87ee and 58d4a73.

⛔ Files ignored due to path filters (1)
  • packages/svgs/src/assets/file-remove.svg is excluded by !**/*.svg
📒 Files selected for processing (4)
  • docs/demos/attachments/custom-file-type.vue
  • packages/components/src/attachments/components/FileCard.vue
  • packages/components/src/attachments/index.vue
  • packages/components/src/styles/variables.css
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@SonyLeo SonyLeo marked this pull request as ready for review May 21, 2026 08:30
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.

2 participants