Skip to content

Commit 3841a56

Browse files
committed
lint
1 parent 9a411cb commit 3841a56

File tree

2 files changed

+29
-32
lines changed

2 files changed

+29
-32
lines changed

src/components/Feed/SystemFeed.jsx

Lines changed: 28 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,7 @@ import moment from 'moment'
44
import ActionCard from '../ActionCard/ActionCard'
55
import Panel from '../Panel/Panel'
66
import UserTooltip from '../User/UserTooltip'
7-
import { NOTIFICATIONS } from '../../routes/notifications/constants/notifications'
87
import RemoveNotification from '../../assets/icons/x-mark-blue.svg'
9-
import { toggleNotificationRead } from '../../routes/notifications/actions'
108

119
class SystemFeed extends React.Component {
1210
constructor(props) {
@@ -22,40 +20,40 @@ class SystemFeed extends React.Component {
2220
authorName += ' ' + user.lastName
2321
}
2422
const renderMessages = (msg, i) => {
25-
return (
26-
<div className="project-notification" key={`${msg.id}-${i}`}>
27-
<ActionCard>
28-
<Panel.Body>
29-
<div className="portrait" id={`feed-${msg.id}`}>
30-
<UserTooltip usr={user} id={'CoderBot'} previewAvatar size={40} />
31-
</div>
32-
<div className="object topicBody">
33-
<div className="card-profile">
34-
<div className="card-author">
35-
{ authorName }
36-
</div>
37-
<div className="card-time">
38-
<span>{moment(msg.date).fromNow()}</span>
23+
return (
24+
<div className="project-notification" key={`${msg.id}-${i}`}>
25+
<ActionCard>
26+
<Panel.Body>
27+
<div className="portrait" id={`feed-${msg.id}`}>
28+
<UserTooltip usr={user} id={'CoderBot'} previewAvatar size={40} />
29+
</div>
30+
<div className="object topicBody">
31+
<div className="card-profile">
32+
<div className="card-author">
33+
{ authorName }
34+
</div>
35+
<div className="card-time">
36+
<span>{moment(msg.date).fromNow()}</span>
37+
</div>
38+
<div className="hide-project-notification">
39+
<i className="icon-remove-notification" onClick={() => onNotificationRead(msg)}><RemoveNotification /></i>
40+
</div>
3941
</div>
40-
<div className="hide-project-notification">
41-
<i className="icon-remove-notification" onClick={() => onNotificationRead(msg)}><RemoveNotification /></i>
42+
<div className="card-body">
43+
<span dangerouslySetInnerHTML={{__html: msg.text}} />
4244
</div>
4345
</div>
44-
<div className="card-body">
45-
<span dangerouslySetInnerHTML={{__html: msg.text}} />
46-
</div>
47-
</div>
48-
</Panel.Body>
49-
</ActionCard>
46+
</Panel.Body>
47+
</ActionCard>
48+
</div>
49+
)
50+
}
51+
return (
52+
<div className="project-feed">
53+
{ messages.map(renderMessages) }
5054
</div>
5155
)
5256
}
53-
return (
54-
<div className="project-feed">
55-
{ messages.map(renderMessages) }
56-
</div>
57-
)
58-
}
5957
}
6058

6159
SystemFeed.propTypes = {

src/projects/detail/containers/FeedContainer.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -446,8 +446,7 @@ class FeedView extends React.Component {
446446
messages={sortedUnreadProjectUpdates}
447447
user={SYSTEM_USER}
448448
onNotificationRead={this.onNotificationRead}
449-
>
450-
</SystemFeed>
449+
/>
451450
</div>
452451
}
453452
<NewPost

0 commit comments

Comments
 (0)