1
0
mirror of https://github.com/alice-lg/alice-lg.git synced 2024-05-11 05:55:03 +00:00
2017-05-16 13:34:00 +02:00

29 lines
670 B
JavaScript

import React from 'react'
import {connect} from 'react-redux'
/*
* Show current neighbour if selected
* This should help to create a breadcrumb style navigation
* in the header.
*/
class ProtocolName extends React.Component {
render() {
return (
<span className="status-protocol">
{this.props.protocol.description}
</span>
);
}
}
export default connect(
(state, props) => {
let rsProtocols = state.routeservers.protocols[props.routeserverId]||{};
let protocol = rsProtocols[props.protocolId]||{};
return {
protocol: protocol
};
}
)(ProtocolName);