1
0
mirror of https://github.com/flarum/core.git synced 2025-10-12 07:24:27 +02:00
Files
php-flarum/js/forum/src/components/DiscussionRenamedNotification.js
dcsjapan 49d59089e4 Add third tier to key namespacing
- Changes all `app.trans` calls to `app.translator.trans` calls.
- Changes existing keys to [three-tier namespace structure](https://github.com/flarum/english/pull/12).
- Extracts additional strings for `lib:` namespace.
- Extracts two previously missed strings for EditGroupModal.js.
2015-10-20 13:04:43 +09:00

26 lines
680 B
JavaScript

import Notification from 'flarum/components/Notification';
/**
* The `DiscussionRenamedNotification` component displays a notification which
* indicates that a discussion has had its title changed.
*
* ### Props
*
* - All of the props for Notification
*/
export default class DiscussionRenamedNotification extends Notification {
icon() {
return 'pencil';
}
href() {
const notification = this.props.notification;
return app.route.discussion(notification.subject(), notification.content().postNumber);
}
content() {
return app.translator.trans('core.forum.notifications.discussion_renamed_text', {user: this.props.notification.sender()});
}
}