aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/CollectionFreeFormDocumentView.tsx
diff options
context:
space:
mode:
authorbobzel <zzzman@gmail.com>2023-11-22 11:52:57 -0500
committerbobzel <zzzman@gmail.com>2023-11-22 11:52:57 -0500
commitcc75a03d89a4b553a53b55404464cd2ca93d9b48 (patch)
treed4c455549245a287656d7e03ff9e459231251829 /src/client/views/nodes/CollectionFreeFormDocumentView.tsx
parent52241c5a42c0fa2d92eca8110523081ce9f353af (diff)
fixed more issues with rotation. restrutured how MarqueeAnnotator works to be simpler and more correct.
Diffstat (limited to 'src/client/views/nodes/CollectionFreeFormDocumentView.tsx')
-rw-r--r--src/client/views/nodes/CollectionFreeFormDocumentView.tsx14
1 files changed, 2 insertions, 12 deletions
diff --git a/src/client/views/nodes/CollectionFreeFormDocumentView.tsx b/src/client/views/nodes/CollectionFreeFormDocumentView.tsx
index 465bbcf2f..421d431b3 100644
--- a/src/client/views/nodes/CollectionFreeFormDocumentView.tsx
+++ b/src/client/views/nodes/CollectionFreeFormDocumentView.tsx
@@ -131,9 +131,6 @@ export class CollectionFreeFormDocumentView extends DocComponent<CollectionFreeF
public static animStringFields = ['backgroundColor', 'color', 'fillColor']; // fields that are configured to be animatable using animation frames
public static animDataFields = (doc: Doc) => (Doc.LayoutFieldKey(doc) ? [Doc.LayoutFieldKey(doc)] : []); // fields that are configured to be animatable using animation frames
- @observable _animPos: number[] | undefined = undefined;
- @observable _contentView: DocumentView | undefined | null;
-
get CollectionFreeFormView() {
return this.props.CollectionFreeFormView;
}
@@ -231,7 +228,7 @@ export class CollectionFreeFormDocumentView extends DocComponent<CollectionFreeF
this.props
.ScreenToLocalTransform()
.translate(-this.props.w_X(), -this.props.w_Y())
- .rotateDeg(this.props.w_Rotation?.() || 0);
+ .rotateDeg(-(this.props.w_Rotation?.() || 0));
returnThis = () => this;
/// this indicates whether the doc view is activated because of its relationshop to a group
@@ -262,14 +259,7 @@ export class CollectionFreeFormDocumentView extends DocComponent<CollectionFreeF
{this.props.RenderCutoffProvider(this.props.Document) ? (
<div style={{ position: 'absolute', width: this.props.PanelWidth(), height: this.props.PanelHeight(), background: 'lightGreen' }} />
) : (
- <DocumentView
- ref={action((r: DocumentView | null) => (this._contentView = r))}
- {...passOnProps}
- CollectionFreeFormDocumentView={this.returnThis}
- styleProvider={this.styleProvider}
- ScreenToLocalTransform={this.screenToLocalTransform}
- isGroupActive={this.isGroupActive}
- />
+ <DocumentView {...passOnProps} CollectionFreeFormDocumentView={this.returnThis} styleProvider={this.styleProvider} ScreenToLocalTransform={this.screenToLocalTransform} isGroupActive={this.isGroupActive} />
)}
</div>
);