Make hovering URL unclickable

This commit is contained in:
Yuya Ochiai
2016-11-30 20:27:29 +09:00
parent 9d3a80a295
commit b333ca580f
2 changed files with 25 additions and 19 deletions

View File

@@ -1,27 +1,9 @@
const React = require('react');
const style = {
color: 'gray',
backgroundColor: 'whitesmoke',
maxWidth: '95%',
whiteSpace: 'nowrap',
overflow: 'hidden',
textOverflow: 'ellipsis',
position: 'absolute',
bottom: 0,
paddingLeft: 4,
paddingRight: 16,
paddingTop: 2,
paddingBottom: 2,
borderTopRightRadius: 4,
borderTop: 'solid thin lightgray',
borderRight: 'solid thin lightgray'
};
class HoveringURL extends React.Component {
render() {
return (
<div style={style}>
<div style={this.props.style}>
{this.props.targetURL}
</div>
);
@@ -29,6 +11,7 @@ class HoveringURL extends React.Component {
}
HoveringURL.propTypes = {
style: React.PropTypes.object,
targetURL: React.PropTypes.string
};