From fc8a674e917c737be6d2b90cc64b973a54372f44 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=BE=B7=E5=AE=87?= Date: Tue, 22 Sep 2026 13:23:24 +0800 Subject: [PATCH] =?UTF-8?q?3D=20=E6=A8=A1=E5=9E=8B=E8=A7=92=E6=A0=87?= =?UTF-8?q?=E6=94=B9=E7=94=A8=20Tailwind=20v4=20=E5=8F=AF=E7=94=A8?= =?UTF-8?q?=E7=9A=84=E7=B1=BB=E4=B8=8E=E4=B8=93=E7=94=A8=20CSS=20=E8=A7=84?= =?UTF-8?q?=E5=88=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - src/index.css:新增 .image-canvas-editor__kind-badge--model3d 规则,背景与阴影沿用原取值,与其它 asset kind 的写法一致 - src/components/image-editor/ImageCanvasWorldView.tsx:model3d 角标改成引用该规则;原写法用 Tailwind v3 的 `!` 前缀(v4 改后缀),实际不会生成工具类,角标退化成白字无底色的白药丸 验证:npx prettier --check src/index.css src/components/image-editor/ImageCanvasWorldView.tsx --- src/components/image-editor/ImageCanvasWorldView.tsx | 3 +-- src/index.css | 5 +++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/components/image-editor/ImageCanvasWorldView.tsx b/src/components/image-editor/ImageCanvasWorldView.tsx index a2283a39d..8b6fcf200 100644 --- a/src/components/image-editor/ImageCanvasWorldView.tsx +++ b/src/components/image-editor/ImageCanvasWorldView.tsx @@ -293,8 +293,7 @@ const CANVAS_ASSET_KIND_TAG_OPTIONS: Array<{ { value: 'model3d', label: '3D模型', - badgeClassName: - '!bg-[rgba(30,64,175,0.94)] !shadow-[0_8px_18px_rgba(30,64,175,0.26)]', + badgeClassName: 'image-canvas-editor__kind-badge--model3d', }, { value: 'sound-effect', diff --git a/src/index.css b/src/index.css index a2c320e8c..77d1f8d0b 100644 --- a/src/index.css +++ b/src/index.css @@ -5963,6 +5963,11 @@ html[data-mobile-keyboard-open='true'] .platform-mobile-bottom-dock { box-shadow: 0 8px 18px rgba(79, 70, 229, 0.24); } +.image-canvas-editor__kind-badge--model3d { + background: rgba(30, 64, 175, 0.94); + box-shadow: 0 8px 18px rgba(30, 64, 175, 0.26); +} + .image-canvas-editor__kind-menu-anchor { position: absolute; width: 0;