1
0
mirror of https://github.com/flarum/core.git synced 2025-07-30 21:20:24 +02:00

Add notification excerpts to help distinguish posts

This commit is contained in:
Toby Zerner
2015-08-21 09:54:41 +09:30
parent 4e8f69a18c
commit 52bf8b3c1c
2 changed files with 20 additions and 0 deletions

View File

@@ -26,6 +26,9 @@ export default class Notification extends Component {
{icon(this.icon(), {className: 'Notification-icon'})}
<span className="Notification-content">{this.content()}</span>
{humanTime(notification.time())}
<div className="Notification-excerpt">
{this.excerpt()}
</div>
</a>
</div>
);
@@ -58,6 +61,15 @@ export default class Notification extends Component {
content() {
}
/**
* Get the excerpt of the notification.
*
* @return {VirtualElement}
* @abstract
*/
excerpt() {
}
/**
* Mark the notification as read.
*/