mirror of
https://github.com/weaveworks/scope.git
synced 2026-07-28 09:41:57 +00:00
* always set updated topology object when received * track whether route was set on initial load * removed connection count from status bar (was not deemed important) * fixed issue where topology option changes did not affect details pane * only show filtered nodes when count > 0 * clear nodes graph when empty topology is loaded * also prevent JS error if nodes are hovered over that should be gone * fixed options sync issue between graph and status bar * implemented topology options with immutable DS
23 lines
493 B
JavaScript
23 lines
493 B
JavaScript
const React = require('react');
|
|
|
|
const AppActions = require('../actions/app-actions');
|
|
|
|
const TopologyOptionAction = React.createClass({
|
|
|
|
onClick: function(ev) {
|
|
ev.preventDefault();
|
|
AppActions.changeTopologyOption(this.props.option, this.props.value, this.props.topologyId);
|
|
},
|
|
|
|
render: function() {
|
|
return (
|
|
<span className="sidebar-item-action" onClick={this.onClick}>
|
|
{this.props.value}
|
|
</span>
|
|
);
|
|
}
|
|
|
|
});
|
|
|
|
module.exports = TopologyOptionAction;
|