diff options
| author | Tyler Schicke <tyler_schicke@brown.edu> | 2019-05-18 18:17:39 -0400 |
|---|---|---|
| committer | Tyler Schicke <tyler_schicke@brown.edu> | 2019-05-18 18:17:39 -0400 |
| commit | 130b5c55f954a011e91355c79ade4b9f91bd84e9 (patch) | |
| tree | 5633bab7fa5d1ef924649d84a0179a47f81b32f2 /src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx | |
| parent | 20a1c2a1e59c02b29bbe744c57df6022952e2741 (diff) | |
clamped scale and reverted safe mode
Diffstat (limited to 'src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx')
| -rw-r--r-- | src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx b/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx index 264c89d67..956a5668a 100644 --- a/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx +++ b/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx @@ -211,7 +211,7 @@ export class CollectionFreeFormView extends CollectionSubView(PanZoomDocument) { let [x, y] = this.getTransform().transformPoint(e.clientX, e.clientY); let localTransform = this.getLocalTransform().inverse().scaleAbout(deltaScale, x, y); - let safeScale = Math.abs(localTransform.Scale); + let safeScale = Math.max(0.002, localTransform.Scale); this.props.Document.scale = Math.abs(safeScale); this.setPan(-localTransform.TranslateX / safeScale, -localTransform.TranslateY / safeScale); e.stopPropagation(); |
