diff options
author | bob <bcz@cs.brown.edu> | 2019-12-19 16:27:13 -0500 |
---|---|---|
committer | bob <bcz@cs.brown.edu> | 2019-12-19 16:27:13 -0500 |
commit | 306ea362cad253764bc632d6274ae71a45ecd85c (patch) | |
tree | dd1e01ffe5828be5a8b36b4e3dd4798a2cf5137d /src/client/views/collections/CollectionStackingView.tsx | |
parent | 8907ea70352d07c80233ff4c3e06c9c543c5be83 (diff) |
compiler fixes. fix for text box titles on templates
Diffstat (limited to 'src/client/views/collections/CollectionStackingView.tsx')
-rw-r--r-- | src/client/views/collections/CollectionStackingView.tsx | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/client/views/collections/CollectionStackingView.tsx b/src/client/views/collections/CollectionStackingView.tsx index 83ac81103..e71e11b48 100644 --- a/src/client/views/collections/CollectionStackingView.tsx +++ b/src/client/views/collections/CollectionStackingView.tsx @@ -166,7 +166,6 @@ export class CollectionStackingView extends CollectionSubView(doc => doc) { getDisplayDoc(doc: Doc, dataDoc: Doc | undefined, dxf: () => Transform, width: () => number) { const layoutDoc = Doc.Layout(doc); const height = () => this.getDocHeight(doc); - const finalDxf = () => dxf(); return <ContentFittingDocumentView Document={doc} DataDocument={dataDoc} @@ -178,7 +177,7 @@ export class CollectionStackingView extends CollectionSubView(doc => doc) { onClick={layoutDoc.isTemplateDoc ? this.onClickHandler : this.onChildClickHandler} PanelWidth={width} PanelHeight={height} - getTransform={finalDxf} + getTransform={dxf} focus={this.props.focus} CollectionDoc={this.props.CollectionView && this.props.CollectionView.props.Document} CollectionView={this.props.CollectionView} @@ -250,7 +249,7 @@ export class CollectionStackingView extends CollectionSubView(doc => doc) { const pos1 = cd.dxf().inverse().transformPoint(cd.width(), cd.height()); if (where[0] > pos[0] && where[0] < pos1[0] && where[1] > pos[1] && where[1] < pos1[1]) { targInd = i; - let axis = this.Document.viewType === CollectionViewType.Masonry ? 0 : 1; + const axis = this.Document.viewType === CollectionViewType.Masonry ? 0 : 1; plusOne = where[axis] > (pos[axis] + pos1[axis]) / 2 ? 1 : 0; } }); |