summaryrefslogtreecommitdiff
path: root/src/components
diff options
context:
space:
mode:
authorKamran Ahmed <kamranahmed.se@gmail.com>2019-06-15 00:15:30 +0400
committerKamran Ahmed <kamranahmed.se@gmail.com>2019-06-15 00:15:30 +0400
commita6ef7592a201d59d0b7e21cde98e38339086f401 (patch)
tree54628283293064e20e3e6d88cd5acb7e62a66843 /src/components
parentFixed watchers parameter to subscribers_count (#32) (diff)
downloadgithunt-a6ef7592a201d59d0b7e21cde98e38339086f401.tar.gz
Update dependencies and add issue count
Diffstat (limited to 'src/components')
-rw-r--r--src/components/icons/issue.js9
-rw-r--r--src/components/repository-list/list-item/index.js14
2 files changed, 16 insertions, 7 deletions
diff --git a/src/components/icons/issue.js b/src/components/icons/issue.js
new file mode 100644
index 0000000..a22fc15
--- /dev/null
+++ b/src/components/icons/issue.js
@@ -0,0 +1,9 @@
+import React from 'react';
+
+const Issue = (props) => (
+ <svg className="octicon octicon-issue-opened" viewBox="0 0 14 16" version="1.1" width="14" height="16">
+ <path fillRule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path>
+ </svg>
+);
+
+export default Issue;
diff --git a/src/components/repository-list/list-item/index.js b/src/components/repository-list/list-item/index.js
index 54d3e47..8934c75 100644
--- a/src/components/repository-list/list-item/index.js
+++ b/src/components/repository-list/list-item/index.js
@@ -5,7 +5,7 @@ import './styles.css';
import moment from 'moment';
import Star from '../../icons/star';
import Fork from '../../icons/fork';
-import Watcher from '../../icons/watcher';
+import Issue from "../../icons/issue";
class ListItem extends React.Component {
render() {
@@ -39,22 +39,22 @@ class ListItem extends React.Component {
href={ `${this.props.repository.html_url}/stargazers` }
rel="noopener noreferrer"
target="_blank">
- <Star/>
+ <Star />
{ this.props.repository.stargazers_count.toLocaleString() }
</a>
<a className="muted-link d-inline-block mr-3"
href={ `${this.props.repository.html_url}/network/members` }
rel="noopener noreferrer"
target="_blank">
- <Fork/>
+ <Fork />
{ this.props.repository.forks.toLocaleString() }
</a>
<a className="muted-link d-inline-block mr-3"
- href={ `${this.props.repository.html_url}/watchers` }
+ href={ `${this.props.repository.html_url}/issues` }
rel="noopener noreferrer"
target="_blank">
- <Watcher/>
- { this.props.repository.subscribers_count.toLocaleString() }
+ <Issue />
+ { this.props.repository.open_issues.toLocaleString() }
</a>
</div>
</div>
@@ -68,7 +68,7 @@ class ListItem extends React.Component {
onError={ (e) => {
e.target.src = '/img/logo.svg';
} }
- alt={ this.props.repository.owner.login }/>
+ alt={ this.props.repository.owner.login } />
</a>
</div>
);