aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/PresBox.tsx
diff options
context:
space:
mode:
authorbob <bcz@cs.brown.edu>2019-10-05 13:56:31 -0400
committerbob <bcz@cs.brown.edu>2019-10-05 13:56:31 -0400
commit961cb1566e16edb353975ec436a4445c1cf3db0f (patch)
treef333e7b52dbc999ca11ae63e32ade5f80b846a27 /src/client/views/nodes/PresBox.tsx
parent54f2067dbadb66e22249c1572bdc5d6d097f41d1 (diff)
parentf9916faa215297d434aab2357b98d2c4b1fdcb92 (diff)
Merge branch 'master' of https://github.com/browngraphicslab/Dash-Web
Diffstat (limited to 'src/client/views/nodes/PresBox.tsx')
-rw-r--r--src/client/views/nodes/PresBox.tsx9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/client/views/nodes/PresBox.tsx b/src/client/views/nodes/PresBox.tsx
index 180ed9032..15fafb022 100644
--- a/src/client/views/nodes/PresBox.tsx
+++ b/src/client/views/nodes/PresBox.tsx
@@ -314,12 +314,11 @@ export class PresBox extends React.Component<FieldViewProps> {
}
toggleMinimize = undoBatch(action((e: React.PointerEvent) => {
- if (this.props.Document.minimizedView) {
- this.props.Document.minimizedView = false;
+ if (this.props.Document.inOverlay) {
Doc.RemoveDocFromList((CurrentUserUtils.UserDocument.overlays as Doc), this.props.fieldKey, this.props.Document);
CollectionDockingView.AddRightSplit(this.props.Document, this.props.DataDoc);
+ this.props.Document.inOverlay = false;
} else {
- this.props.Document.minimizedView = true;
this.props.Document.x = e.clientX + 25;
this.props.Document.y = e.clientY - 25;
this.props.addDocTab && this.props.addDocTab(this.props.Document, this.props.DataDoc, "close");
@@ -370,9 +369,9 @@ export class PresBox extends React.Component<FieldViewProps> {
<FontAwesomeIcon icon={this.props.Document.presStatus ? "stop" : "play"} />
</button>
<button className="presBox-button" title="Next" onClick={this.next}><FontAwesomeIcon icon={"arrow-right"} /></button>
- <button className="presBox-button" title={this.props.Document.minimizedView ? "Expand" : "Minimize"} onClick={this.toggleMinimize}><FontAwesomeIcon icon={"eye"} /></button>
+ <button className="presBox-button" title={this.props.Document.inOverlay ? "Expand" : "Minimize"} onClick={this.toggleMinimize}><FontAwesomeIcon icon={"eye"} /></button>
</div>
- {this.props.Document.minimizedView ? (null) :
+ {this.props.Document.inOverlay ? (null) :
<div className="presBox-listCont" >
<CollectionView {...this.props} focus={this.selectElement} ScreenToLocalTransform={this.getTransform} />
</div>