aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/DocumentView.tsx
diff options
context:
space:
mode:
authorandrewdkim <adkim414@gmail.com>2019-06-20 16:33:20 -0400
committerandrewdkim <adkim414@gmail.com>2019-06-20 16:33:20 -0400
commit1fa8e6c102b41bf99b7af9d803b6060284afc8b7 (patch)
tree8cbe91a4f3ea866abc6f160d63a7a812446a66d1 /src/client/views/nodes/DocumentView.tsx
parent82f21b627c4823b1984cd1865aea6eb91f290eca (diff)
parenta5dc0e04add05f2f5bf1e17f1ac0a5e0aba1ea41 (diff)
Merge branch 'master' of https://github.com/browngraphicslab/Dash-Web into animationtimeline
Diffstat (limited to 'src/client/views/nodes/DocumentView.tsx')
-rw-r--r--src/client/views/nodes/DocumentView.tsx4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/client/views/nodes/DocumentView.tsx b/src/client/views/nodes/DocumentView.tsx
index acd5e4cf2..280804630 100644
--- a/src/client/views/nodes/DocumentView.tsx
+++ b/src/client/views/nodes/DocumentView.tsx
@@ -89,6 +89,7 @@ const schema = createSchema({
nativeWidth: "number",
nativeHeight: "number",
backgroundColor: "string",
+ hidden: "boolean"
});
export const positionSchema = createSchema({
@@ -538,6 +539,9 @@ export class DocumentView extends DocComponent<DocumentViewProps, Document>(Docu
}
render() {
+ if (this.Document.hidden) {
+ return null;
+ }
var scaling = this.props.ContentScaling();
var nativeWidth = this.nativeWidth > 0 ? `${this.nativeWidth}px` : "100%";
var nativeHeight = BoolCast(this.props.Document.ignoreAspect) ? this.props.PanelHeight() / this.props.ContentScaling() : this.nativeHeight > 0 ? `${this.nativeHeight}px` : "100%";