diff options
author | Cédric Bonhomme <cedric@cedricbonhomme.org> | 2016-02-04 07:47:03 +0100 |
---|---|---|
committer | Cédric Bonhomme <cedric@cedricbonhomme.org> | 2016-02-04 07:47:03 +0100 |
commit | 1eee1cc14cca3863e7da7368a659fb70fc3b4d0f (patch) | |
tree | fd3bd3ed9df08e87e08473529c7ca164d11526da /src/web/js | |
parent | Better if we don't leave JARR when clicking on this link. (diff) | |
download | newspipe-1eee1cc14cca3863e7da7368a659fb70fc3b4d0f.tar.gz newspipe-1eee1cc14cca3863e7da7368a659fb70fc3b4d0f.tar.bz2 newspipe-1eee1cc14cca3863e7da7368a659fb70fc3b4d0f.zip |
Add a link to open an article in a new tab. Should be improve (maybe without the a anchor).
Diffstat (limited to 'src/web/js')
-rw-r--r-- | src/web/js/components/MiddlePanel.react.js | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/web/js/components/MiddlePanel.react.js b/src/web/js/components/MiddlePanel.react.js index 92f04325..dad33acc 100644 --- a/src/web/js/components/MiddlePanel.react.js +++ b/src/web/js/components/MiddlePanel.react.js @@ -35,13 +35,18 @@ var TableLine = React.createClass({ icon = <Glyphicon glyph="ban-circle" />; } var title = (<a href={'/article/redirect/' + this.props.article_id} - onClick={this.openRedirectLink} target="_blank"> + onClick={this.openRedirectLink}> {icon} {this.props.feed_title} </a>); var read = (<Glyphicon glyph={this.state.read?"check":"unchecked"} onClick={this.toogleRead} />); var liked = (<Glyphicon glyph={this.state.liked?"star":"star-empty"} onClick={this.toogleLike} />); + icon = <Glyphicon glyph={"new-window"} />; + var newTab = (<a href={'/article/redirect/' + this.props.article_id} + onClick={this.openRedirectLink} target="_blank"> + {icon} + </a>); var clsses = "list-group-item"; if(this.props.selected) { clsses += " active"; @@ -52,7 +57,7 @@ var TableLine = React.createClass({ <h5><strong>{title}</strong></h5> <JarrTime text={this.props.date} stamp={this.props.timestamp} /> - <div>{read} {liked} {this.props.title}</div> + <div>{read} {liked} {newTab} {this.props.title}</div> </div> ); }, |