mirror of
https://github.com/flarum/framework.git
synced 2025-04-15 15:52:50 +08:00
Fix key names in Lock
- Fixes several key name errors in PR #17. - Sorry for the extra work!
This commit is contained in:
parent
eb398c9cbc
commit
751f3a3cb9
@ -7,7 +7,7 @@ export default function addLockBadge() {
|
||||
if (this.isLocked()) {
|
||||
badges.add('locked', Badge.component({
|
||||
type: 'locked',
|
||||
label: app.translator.trans('flarum-lock.forum.badge.locked'),
|
||||
label: app.translator.trans('flarum-lock.forum.badge.locked_discussion_tooltip'),
|
||||
icon: 'lock'
|
||||
}));
|
||||
}
|
||||
|
@ -7,7 +7,7 @@ export default function addLockControl() {
|
||||
extend(DiscussionControls, 'moderationControls', function(items, discussion) {
|
||||
if (discussion.canLock()) {
|
||||
items.add('lock', Button.component({
|
||||
children: app.translator.trans(discussion.isLocked() ? 'flarum-lock.forum.discussion_controls.unlock' : 'flarum-lock.forum.discussion_controls.lock'),
|
||||
children: app.translator.trans(discussion.isLocked() ? 'flarum-lock.forum.discussion_controls.unlock_button' : 'flarum-lock.forum.discussion_controls.lock_button'),
|
||||
icon: 'lock',
|
||||
onclick: this.lockAction.bind(discussion)
|
||||
}));
|
||||
|
@ -9,7 +9,7 @@ export default class DiscussionLockedPost extends EventPost {
|
||||
|
||||
descriptionKey() {
|
||||
return this.props.post.content().locked
|
||||
? 'flarum-lock.forum.post_stream.discussion_locked_post'
|
||||
: 'flarum-lock.forum.post_stream.discussion_unlocked_post';
|
||||
? 'flarum-lock.forum.post_stream.discussion_locked_text'
|
||||
: 'flarum-lock.forum.post_stream.discussion_unlocked_text';
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user