From 6282f6551958726d12c40042efc6a8b7257ecc35 Mon Sep 17 00:00:00 2001 From: Steve Ruiz Date: Wed, 17 Apr 2024 10:31:36 +0100 Subject: [PATCH] Stickies: fix sticky note clipping (#3503) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This PR restores masking for sticky notes that are the child of frames. ### Change Type - [x] `sdk` — Changes the tldraw SDK - [x] `bugfix` — Bug fix --- packages/editor/src/lib/editor/Editor.ts | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/packages/editor/src/lib/editor/Editor.ts b/packages/editor/src/lib/editor/Editor.ts index 93de351ff..435692885 100644 --- a/packages/editor/src/lib/editor/Editor.ts +++ b/packages/editor/src/lib/editor/Editor.ts @@ -3973,13 +3973,7 @@ export class Editor extends EventEmitter { /** @internal */ @computed private _getShapeMaskCache(): ComputedCache { return this.store.createComputedCache('pageMaskCache', (shape) => { - // todo: Consider adding a flag for this hardcoded behaviour - if ( - isPageId(shape.parentId) || - shape.type === 'note' || - this.findShapeAncestor(shape, (v) => v.type === 'note') - ) - return undefined + if (isPageId(shape.parentId)) return undefined const frameAncestors = this.getShapeAncestors(shape.id).filter((shape) => this.isShapeOfType(shape, 'frame')