mirror of
https://github.com/weaveworks/scope.git
synced 2026-05-06 01:08:03 +00:00
Add label_minor to tooltips in connections table
Sometimes label is not enough to distinguish between rows.
This commit is contained in:
@@ -18,17 +18,20 @@ class NodeDetailsTableNodeLink extends React.Component {
|
||||
}
|
||||
|
||||
render() {
|
||||
if (this.props.linkable) {
|
||||
const { label, label_minor: labelMinor, linkable } = this.props;
|
||||
const title = !labelMinor ? label : `${label} (${labelMinor})`;
|
||||
|
||||
if (linkable) {
|
||||
return (
|
||||
<span className="node-details-table-node-link" title={this.props.label}
|
||||
<span className="node-details-table-node-link" title={title}
|
||||
onClick={this.handleClick}>
|
||||
{this.props.label}
|
||||
{label}
|
||||
</span>
|
||||
);
|
||||
}
|
||||
return (
|
||||
<span className="node-details-table-node" title={this.props.label}>
|
||||
{this.props.label}
|
||||
<span className="node-details-table-node" title={title}>
|
||||
{label}
|
||||
</span>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user