diff options
author | Bob Zeleznik <zzzman@gmail.com> | 2019-04-29 21:11:32 -0400 |
---|---|---|
committer | Bob Zeleznik <zzzman@gmail.com> | 2019-04-29 21:11:32 -0400 |
commit | 041286093aef2e1f5a2b503959146124f292cc2b (patch) | |
tree | 1e43e19a8cb8294d5f7454b6204363b390a3405a /src | |
parent | 3da71792a339536118b7af7cfe0529201a45c64e (diff) |
fixed linking button
Diffstat (limited to 'src')
-rw-r--r-- | src/client/views/DocumentDecorations.scss | 2 | ||||
-rw-r--r-- | src/client/views/DocumentDecorations.tsx | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/src/client/views/DocumentDecorations.scss b/src/client/views/DocumentDecorations.scss index 27b94e6d2..0dfa6f0ff 100644 --- a/src/client/views/DocumentDecorations.scss +++ b/src/client/views/DocumentDecorations.scss @@ -135,7 +135,7 @@ grid-column: 1/4; } -.linkButton-empty { +.linkButton-empty, .linkButton-nonempty { height: 20px; width: 20px; border-radius: 50%; diff --git a/src/client/views/DocumentDecorations.tsx b/src/client/views/DocumentDecorations.tsx index 18449ed32..de17e1aef 100644 --- a/src/client/views/DocumentDecorations.tsx +++ b/src/client/views/DocumentDecorations.tsx @@ -496,7 +496,9 @@ export class DocumentDecorations extends React.Component<{}, { value: string }> anchorPoint={anchorPoints.RIGHT_TOP} content={<LinkMenu docView={selFirst} changeFlyout={this.changeFlyoutContent} />}> - <div className={"linkButton-" + (selFirst.props.Document.GetData(KeyStore.LinkedToDocs, ListField, []).length ? "nonempty" : "empty")} onPointerDown={this.onLinkButtonDown} >{linkCount}</div> + <div className={"linkButton-" + (selFirst.props.Document.GetData(KeyStore.LinkedToDocs, ListField, []).length || + selFirst.props.Document.GetData(KeyStore.LinkedFromDocs, ListField, []).length + ? "nonempty" : "empty")} onPointerDown={this.onLinkButtonDown} >{linkCount}</div> </Flyout>); } |