From ca730e0b3551d466a73104a4ddb1bb75e5389e36 Mon Sep 17 00:00:00 2001 From: Orion Reed Date: Fri, 29 Mar 2024 19:45:29 -0700 Subject: [PATCH] force light mode --- src/components/Canvas.tsx | 5 +++-- src/css/style.css | 4 ++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/components/Canvas.tsx b/src/components/Canvas.tsx index 98d591f..ce74f51 100644 --- a/src/components/Canvas.tsx +++ b/src/components/Canvas.tsx @@ -1,4 +1,4 @@ -import { Tldraw, TLShape, TLUiComponents } from "@tldraw/tldraw"; +import { Editor, Tldraw, TLShape, TLUiComponents } from "@tldraw/tldraw"; import { SimController } from "@/physics/PhysicsControls"; import { HTMLShapeUtil } from "@/shapes/HTMLShapeUtil"; @@ -22,8 +22,9 @@ export function Canvas({ shapes }: { shapes: TLShape[]; }) { { + onMount={(editor: Editor) => { window.dispatchEvent(new CustomEvent('editorDidMountEvent')); + editor.user.updateUserPreferences({ isDarkMode: false }) }} > diff --git a/src/css/style.css b/src/css/style.css index af71386..1147f76 100644 --- a/src/css/style.css +++ b/src/css/style.css @@ -117,6 +117,10 @@ ol { &:hover { opacity: 1; } + & img { + width: 40px; + height: 40px; + } } #toggle-canvas { top: 10px;