feat(canvas): 画布主题 - 与工作台外观隔离并提高连线对比

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
ddCatandCursor committed 2026-09-16 22:59:34 +08:00
1 parent da0531f6eb
commit cb405e9b6a
54 files changed
+207 -134

No files matched your search

@@ -6,7 +6,7 @@ import { Check, Maximize2, X } from "lucide-react";
import type { CanvasDrawingEditorHandle } from "@/components/canvas/canvas-drawing-editor-types";
import { drawingEngineForNode, drawingEngineLabel, isDrawingEngineAvailable } from "@/lib/canvas/canvas-drawing-engine";
import { loadCanvasDrawing, saveCanvasDrawing, type CanvasDrawingSnapshot } from "@/lib/canvas/canvas-drawing-storage";
import { useThemeStore } from "@/stores/use-theme-store";
import { useActiveTheme } from "@/stores/canvas/use-canvas-theme-store";
import { useUserStore } from "@/stores/use-user-store";
import type { CanvasNodeData } from "@/types/canvas";
@@ -23,7 +23,7 @@ type CanvasDrawingEditorModalProps = {
export function CanvasDrawingEditorModal({ open, projectId, node, onClose, onSaved }: CanvasDrawingEditorModalProps) {
const { message } = App.useApp();
const colorScheme = useThemeStore((state) => state.theme);
const colorScheme = useActiveTheme();
const tldrawLicenseKey = useUserStore((state) => state.drawingEngine.tldrawLicenseKey);
const engine = drawingEngineForNode(node);
const currentRef = useRef<CanvasDrawingSnapshot | null>(null);