diff options
author | geireann <geireann.lindfield@gmail.com> | 2025-04-17 13:52:58 -0400 |
---|---|---|
committer | geireann <geireann.lindfield@gmail.com> | 2025-04-17 13:52:58 -0400 |
commit | 1f294ef4a171eec72a069a9503629eaf7975d983 (patch) | |
tree | b10c3a5cfdd28bea5bf428d7bffc13061e2ef4cc /src/client/views/DocumentDecorations.tsx | |
parent | 305778d0d100709cf2eff643ba78648c5d0b7efb (diff) |
fix for resizing docs with native width and modify native dim set (fixes dailyjournal resizing).
Diffstat (limited to 'src/client/views/DocumentDecorations.tsx')
-rw-r--r-- | src/client/views/DocumentDecorations.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/DocumentDecorations.tsx b/src/client/views/DocumentDecorations.tsx index 0756d3d9e..120467e8a 100644 --- a/src/client/views/DocumentDecorations.tsx +++ b/src/client/views/DocumentDecorations.tsx @@ -551,7 +551,7 @@ export class DocumentDecorations extends ObservableReactComponent<DocumentDecora scale.x === 1 ? (scale.x = scale.y) : (scale.y = scale.x); } - if (['right', 'left'].includes(opts.dragHdl) && modifyNativeDim && Doc.NativeWidth(doc)) { + if (['right', 'left', 'bottomRight'].includes(opts.dragHdl) && modifyNativeDim && Doc.NativeWidth(doc)) { const setData = Doc.NativeWidth(doc[DocData]) === doc.nativeWidth; doc.nativeWidth = scale.x * Doc.NativeWidth(doc); if (setData) Doc.SetNativeWidth(doc[DocData], NumCast(doc.nativeWidth)); @@ -559,7 +559,7 @@ export class DocumentDecorations extends ObservableReactComponent<DocumentDecora doc._nativeHeight = (initHeight / initWidth) * nwidth; // initializes the nativeHeight for a PDF } } - if (['bottom', 'top'].includes(opts.dragHdl) && modifyNativeDim && Doc.NativeHeight(doc)) { + if (['bottom', 'top', 'bottomRight'].includes(opts.dragHdl) && modifyNativeDim && Doc.NativeHeight(doc)) { const setData = Doc.NativeHeight(doc[DocData]) === doc.nativeHeight && (!doc.layout_reflowVertical || opts.ctrlKey); doc._nativeHeight = scale.y * Doc.NativeHeight(doc); if (setData) Doc.SetNativeHeight(doc[DocData], NumCast(doc._nativeHeight)); |