From 174c86efd17f40b3bca402b253eb8026848dfe0b Mon Sep 17 00:00:00 2001 From: bobzel Date: Tue, 19 Sep 2023 15:39:56 -0400 Subject: fixed pinning ink strokes to honor save layout/content. --- src/client/views/InkingStroke.tsx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/client/views/InkingStroke.tsx b/src/client/views/InkingStroke.tsx index f5ffff639..3b9edbc56 100644 --- a/src/client/views/InkingStroke.tsx +++ b/src/client/views/InkingStroke.tsx @@ -82,9 +82,8 @@ export class InkingStroke extends ViewBoxBaseComponent() { screenToLocal = () => this.props.ScreenToLocalTransform().scale(this.props.NativeDimScaling?.() || 1); getAnchor = (addAsAnnotation: boolean, pinProps?: PinProps) => { - if (this._subContentView) { - return this._subContentView.getAnchor?.(addAsAnnotation) || this.rootDoc; - } + const subAnchor = this._subContentView?.getAnchor?.(addAsAnnotation); + if (subAnchor !== this.rootDoc) return subAnchor; if (!addAsAnnotation && !pinProps) return this.rootDoc; -- cgit v1.2.3-70-g09d2