diff options
author | bob <bcz@cs.brown.edu> | 2019-07-31 10:03:15 -0400 |
---|---|---|
committer | bob <bcz@cs.brown.edu> | 2019-07-31 10:03:15 -0400 |
commit | f450ba6cea4fe0e9e2c83af68177e3a70aa9a499 (patch) | |
tree | 3745c6c1ac0e047698f043630147a58e1bb5da39 /src/client/views/nodes/ImageBox.tsx | |
parent | 548d23c3bf200579e5d179b7362599508ca67be2 (diff) |
fixes for templates and pivot viewer.
Diffstat (limited to 'src/client/views/nodes/ImageBox.tsx')
-rw-r--r-- | src/client/views/nodes/ImageBox.tsx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/client/views/nodes/ImageBox.tsx b/src/client/views/nodes/ImageBox.tsx index b60ef41fd..9a0615d68 100644 --- a/src/client/views/nodes/ImageBox.tsx +++ b/src/client/views/nodes/ImageBox.tsx @@ -68,7 +68,7 @@ export class ImageBox extends DocComponent<FieldViewProps, ImageDocument>(ImageD private dropDisposer?: DragManager.DragDropDisposer; - @computed get dataDoc() { return BoolCast(this.props.Document.isTemplate) && this.props.DataDoc ? this.props.DataDoc : this.props.Document; } + @computed get dataDoc() { return this.props.DataDoc && (BoolCast(this.props.Document.isTemplate) || BoolCast(this.props.DataDoc.isTemplate) || this.props.DataDoc.layout === this.props.Document) ? this.props.DataDoc : this.props.Document; } protected createDropTarget = (ele: HTMLDivElement) => { |