mirror of
https://github.com/flarum/core.git
synced 2025-10-15 00:44:40 +02:00
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.
This commit is contained in:
@@ -60,7 +60,7 @@ export default {
|
||||
if (!post.isHidden()) {
|
||||
items.add('edit', Button.component({
|
||||
icon: 'pencil',
|
||||
children: app.trans('core.forum.post_controls_edit_button'),
|
||||
children: app.translator.trans('core.forum.post_controls.edit_button'),
|
||||
onclick: this.editAction.bind(post)
|
||||
}));
|
||||
}
|
||||
@@ -85,7 +85,7 @@ export default {
|
||||
if (post.canEdit()) {
|
||||
items.add('hide', Button.component({
|
||||
icon: 'trash-o',
|
||||
children: app.trans('core.forum.post_controls_delete_button'),
|
||||
children: app.translator.trans('core.forum.post_controls.delete_button'),
|
||||
onclick: this.hideAction.bind(post)
|
||||
}));
|
||||
}
|
||||
@@ -93,14 +93,14 @@ export default {
|
||||
if (post.contentType() === 'comment' && post.canEdit()) {
|
||||
items.add('restore', Button.component({
|
||||
icon: 'reply',
|
||||
children: app.trans('core.forum.post_controls_restore_button'),
|
||||
children: app.translator.trans('core.forum.post_controls.restore_button'),
|
||||
onclick: this.restoreAction.bind(post)
|
||||
}));
|
||||
}
|
||||
if (post.canDelete() && post.number() !== 1) {
|
||||
items.add('delete', Button.component({
|
||||
icon: 'times',
|
||||
children: app.trans('core.forum.post_controls_delete_forever_button'),
|
||||
children: app.translator.trans('core.forum.post_controls.delete_forever_button'),
|
||||
onclick: this.deleteAction.bind(post)
|
||||
}));
|
||||
}
|
||||
|
Reference in New Issue
Block a user