فهرست منبع

e2e: should not enable whiteboard by default

Peng Xiao 3 سال پیش
والد
کامیت
81af8230e4
2فایلهای تغییر یافته به همراه3 افزوده شده و 1 حذف شده
  1. 1 1
      src/main/frontend/state.cljs
  2. 2 0
      tldraw/packages/core/src/lib/TLPage/TLPage.ts

+ 1 - 1
src/main/frontend/state.cljs

@@ -549,7 +549,7 @@ Similar to re-frame subscriptions"
    (and
     (util/electron?)
     ((resolve 'frontend.handler.user/alpha-user?)) ;; using resolve to avoid circular dependency
-    (not (false? (:feature/enable-whiteboards? (sub-config repo)))))))
+    (:feature/enable-whiteboards? (sub-config repo)))))
 
 (defn export-heading-to-list?
   []

+ 2 - 0
tldraw/packages/core/src/lib/TLPage/TLPage.ts

@@ -35,6 +35,8 @@ export class TLPage<S extends TLShape = TLShape, E extends TLEventMap = TLEventM
     this.addShapes(...shapes)
     makeObservable(this)
 
+    // Performance bottleneck!! Optimize me :/
+    // Instead of watch for every shape change, we should only watch for the changed ones
     reaction(
       () => ({
         id: this.id,