aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/DocumentDecorations.tsx
diff options
context:
space:
mode:
authorbob <bcz@cs.brown.edu>2019-03-11 16:56:36 -0400
committerbob <bcz@cs.brown.edu>2019-03-11 16:56:36 -0400
commit618e66a5a070f1aac9224bd3f44b76a5ac314bfa (patch)
treea58c09879cd75c4b0b544f5c8d59de52a32043c7 /src/client/views/DocumentDecorations.tsx
parentfaf0cc17a47aacaef48b4fe18c2f52af0a360805 (diff)
fixed dragging of link button. made web views clips. added delete on marquee.
Diffstat (limited to 'src/client/views/DocumentDecorations.tsx')
-rw-r--r--src/client/views/DocumentDecorations.tsx6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/client/views/DocumentDecorations.tsx b/src/client/views/DocumentDecorations.tsx
index 8c3913232..dc62f97cf 100644
--- a/src/client/views/DocumentDecorations.tsx
+++ b/src/client/views/DocumentDecorations.tsx
@@ -8,6 +8,7 @@ import { NumberField } from "../../fields/NumberField";
import { props } from "bluebird";
import { DragManager } from "../util/DragManager";
import { LinkMenu } from "./nodes/LinkMenu";
+import { ListField } from "../../fields/ListField";
const higflyout = require("@hig/flyout");
const { anchorPoints } = higflyout;
const Flyout = higflyout.default;
@@ -204,13 +205,14 @@ export class DocumentDecorations extends React.Component {
let linkButton = null;
if (SelectionManager.SelectedDocuments().length > 0) {
+ let selFirst = SelectionManager.SelectedDocuments()[0];
linkButton = (<Flyout
anchorPoint={anchorPoints.RIGHT_TOP}
content={
- <LinkMenu docView={SelectionManager.SelectedDocuments()[0]} changeFlyout={this.changeFlyoutContent}>
+ <LinkMenu docView={selFirst} changeFlyout={this.changeFlyoutContent}>
</LinkMenu>
}>
- <div id="linkButton" onPointerDown={this.onLinkButtonDown} ref={this._linkButton}></div>
+ <div className={"linkButton-" + (selFirst.props.Document.GetData(KeyStore.LinkedToDocs, ListField, []).length ? "nonempty" : "empty")} onPointerDown={this.onLinkButtonDown} ref={this._linkButton} />
</Flyout>);
}
return (