浏览代码

fix: global set color

Konstantinos Kaloutas 2 年之前
父节点
当前提交
0831115ae6
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      tldraw/packages/core/src/lib/TLApi/TLApi.ts

+ 1 - 1
tldraw/packages/core/src/lib/TLApi/TLApi.ts

@@ -176,7 +176,7 @@ export class TLApi<S extends TLShape = TLShape, K extends TLEventMap = TLEventMa
     settings.update({ color: color })
 
     this.app.selectedShapesArray.forEach(s => {
-      s.update({ fill: color, stroke: color })
+      if (!s.props.isLocked) s.update({ fill: color, stroke: color })
     })
     this.app.persist()