diff options
author | Fire Demon <firedemon@creature.cafe> | 2020-09-20 21:10:14 -0500 |
---|---|---|
committer | Fire Demon <firedemon@creature.cafe> | 2020-09-20 22:53:42 -0500 |
commit | e3cb18ba7520997a0f605c7f90db258ccccd5e33 (patch) | |
tree | 77ad166f04c96b2bf97bf989eabc8ca1fa61948c /app/javascript/flavours/glitch/features/notifications/components/follow.js | |
parent | 8ede83b2179488e0a28101033e8ce9e6978ea849 (diff) | |
parent | 787d5d728923393f12421a480b3c7aee789a11fe (diff) |
Merge remote-tracking branch 'upstream/master' into merge-glitch
Diffstat (limited to 'app/javascript/flavours/glitch/features/notifications/components/follow.js')
-rw-r--r-- | app/javascript/flavours/glitch/features/notifications/components/follow.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/app/javascript/flavours/glitch/features/notifications/components/follow.js b/app/javascript/flavours/glitch/features/notifications/components/follow.js index 5f405e976..7b47f411b 100644 --- a/app/javascript/flavours/glitch/features/notifications/components/follow.js +++ b/app/javascript/flavours/glitch/features/notifications/components/follow.js @@ -5,6 +5,7 @@ import PropTypes from 'prop-types'; import { FormattedMessage } from 'react-intl'; import ImmutablePureComponent from 'react-immutable-pure-component'; import { HotKeys } from 'react-hotkeys'; +import classNames from 'classnames'; // Our imports. import Permalink from 'flavours/glitch/components/permalink'; @@ -19,6 +20,7 @@ export default class NotificationFollow extends ImmutablePureComponent { id: PropTypes.string.isRequired, account: ImmutablePropTypes.map.isRequired, notification: ImmutablePropTypes.map.isRequired, + unread: PropTypes.bool, }; handleMoveUp = () => { @@ -59,7 +61,7 @@ export default class NotificationFollow extends ImmutablePureComponent { } render () { - const { account, notification, hidden } = this.props; + const { account, notification, hidden, unread } = this.props; // Links to the display name. const displayName = account.get('display_name_html') || account.get('username'); @@ -76,7 +78,7 @@ export default class NotificationFollow extends ImmutablePureComponent { // Renders. return ( <HotKeys handlers={this.getHandlers()}> - <div className='notification notification-follow focusable' tabIndex='0'> + <div className={classNames('notification notification-follow focusable', { unread })} tabIndex='0'> <div className='notification__message'> <div className='notification__favourite-icon-wrapper'> <Icon fixedWidth id='user-plus' /> |