UX: Make flag dropdown actions more clear
This commit is contained in:
parent
77594ab107
commit
0e2b9d3c10
|
@ -12,8 +12,10 @@ export default DropdownSelectBox.extend({
|
||||||
|
|
||||||
@on("didReceiveAttrs")
|
@on("didReceiveAttrs")
|
||||||
_setAdminAgreeDropdownOptions() {
|
_setAdminAgreeDropdownOptions() {
|
||||||
this.set("headerComponentOptions.selectedName", `${I18n.t(this.get("headerText"))}...`);
|
this.get('headerComponentOptions').setProperties({
|
||||||
this.set("headerComponentOptions.icon", iconHTML("thumbs-o-up"));
|
selectedName: `${I18n.t(this.get("headerText"))} ...`,
|
||||||
|
icon: iconHTML("thumbs-o-up")
|
||||||
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
@computed("adminTools", "post.user")
|
@computed("adminTools", "post.user")
|
||||||
|
@ -27,30 +29,30 @@ export default DropdownSelectBox.extend({
|
||||||
content(post, canDeleteSpammer) {
|
content(post, canDeleteSpammer) {
|
||||||
const content = [];
|
const content = [];
|
||||||
|
|
||||||
if (post.user_deleted === true) {
|
if (post.user_deleted) {
|
||||||
content.push({
|
content.push({
|
||||||
title: I18n.t("admin.flags.agree_flag_restore_post_title"),
|
|
||||||
icon: "eye",
|
icon: "eye",
|
||||||
id: "confirm-agree-restore",
|
id: "confirm-agree-restore",
|
||||||
action: () => this.send("perform", "restore"),
|
action: () => this.send("perform", "restore"),
|
||||||
label: I18n.t("admin.flags.agree_flag_restore_post"),
|
label: I18n.t("admin.flags.agree_flag_restore_post"),
|
||||||
|
description: I18n.t("admin.flags.agree_flag_restore_post_title")
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
if (post.get("postHidden") !== true) {
|
if (!post.get("postHidden")) {
|
||||||
content.push({
|
content.push({
|
||||||
title: I18n.t("admin.flags.agree_flag_hide_post_title"),
|
|
||||||
icon: "eye-slash",
|
icon: "eye-slash",
|
||||||
action: () => this.send("perform", "hide"),
|
action: () => this.send("perform", "hide"),
|
||||||
id: "confirm-agree-hide",
|
id: "confirm-agree-hide",
|
||||||
label: I18n.t("admin.flags.agree_flag_hide_post"),
|
label: I18n.t("admin.flags.agree_flag_hide_post"),
|
||||||
|
description: I18n.t("admin.flags.agree_flag_hide_post_title")
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
content.push({
|
content.push({
|
||||||
title: I18n.t("admin.flags.agree_flag_title"),
|
|
||||||
icon: "thumbs-o-up",
|
icon: "thumbs-o-up",
|
||||||
id: "confirm-agree-keep",
|
id: "confirm-agree-keep",
|
||||||
|
description: I18n.t('admin.flags.agree_flag_title'),
|
||||||
action: () => this.send("perform", "keep"),
|
action: () => this.send("perform", "keep"),
|
||||||
label: I18n.t("admin.flags.agree_flag"),
|
label: I18n.t("admin.flags.agree_flag"),
|
||||||
});
|
});
|
||||||
|
|
|
@ -11,8 +11,10 @@ export default DropdownSelectBox.extend({
|
||||||
|
|
||||||
@on("didReceiveAttrs")
|
@on("didReceiveAttrs")
|
||||||
_setAdminDeleteDropdownOptions() {
|
_setAdminDeleteDropdownOptions() {
|
||||||
this.set("headerComponentOptions.selectedName", I18n.t(this.get("headerText")));
|
this.get('headerComponentOptions').setProperties({
|
||||||
this.set("headerComponentOptions.icon", iconHTML("trash-o"));
|
selectedName: `${I18n.t(this.get("headerText"))} ...`,
|
||||||
|
icon: iconHTML("trash-o")
|
||||||
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
@computed("adminTools", "post.user")
|
@computed("adminTools", "post.user")
|
||||||
|
@ -27,19 +29,19 @@ export default DropdownSelectBox.extend({
|
||||||
const content = [];
|
const content = [];
|
||||||
|
|
||||||
content.push({
|
content.push({
|
||||||
title: I18n.t("admin.flags.delete_post_defer_flag_title"),
|
|
||||||
icon: "external-link",
|
icon: "external-link",
|
||||||
id: "delete-defer",
|
id: "delete-defer",
|
||||||
action: () => this.send("deletePostDeferFlag"),
|
action: () => this.send("deletePostDeferFlag"),
|
||||||
label: I18n.t("admin.flags.delete_post_defer_flag")
|
label: I18n.t("admin.flags.delete_post_defer_flag"),
|
||||||
|
description: I18n.t("admin.flags.delete_post_defer_flag_title"),
|
||||||
});
|
});
|
||||||
|
|
||||||
content.push({
|
content.push({
|
||||||
title: I18n.t("admin.flags.delete_post_agree_flag_title"),
|
|
||||||
icon: "thumbs-o-up",
|
icon: "thumbs-o-up",
|
||||||
id: "delete-agree",
|
id: "delete-agree",
|
||||||
action: () => this.send("deletePostAgreeFlag"),
|
action: () => this.send("deletePostAgreeFlag"),
|
||||||
label: I18n.t("admin.flags.delete_post_agree_flag")
|
label: I18n.t("admin.flags.delete_post_agree_flag"),
|
||||||
|
description: I18n.t("admin.flags.delete_post_agree_flag_title"),
|
||||||
});
|
});
|
||||||
|
|
||||||
if (canDeleteSpammer) {
|
if (canDeleteSpammer) {
|
||||||
|
|
|
@ -14,4 +14,5 @@
|
||||||
{{selectedName}}
|
{{selectedName}}
|
||||||
</span>
|
</span>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
</button>
|
</button>
|
||||||
|
|
|
@ -1,6 +1,11 @@
|
||||||
.select-box-kit {
|
.select-box-kit {
|
||||||
&.dropdown-select-box {
|
&.dropdown-select-box {
|
||||||
|
|
||||||
&.admin-agree-flag-dropdown {
|
&.admin-agree-flag-dropdown {
|
||||||
|
.select-box-kit-body {
|
||||||
|
width: 485px;
|
||||||
|
max-width: 485px;
|
||||||
|
}
|
||||||
.select-box-kit-row[data-value="delete-spammer"] .texts .name,
|
.select-box-kit-row[data-value="delete-spammer"] .texts .name,
|
||||||
.select-box-kit-row[data-value="delete-spammer"] .icons .d-icon {
|
.select-box-kit-row[data-value="delete-spammer"] .icons .d-icon {
|
||||||
color: $danger;
|
color: $danger;
|
||||||
|
|
|
@ -2617,20 +2617,19 @@ en:
|
||||||
|
|
||||||
agree: "Agree"
|
agree: "Agree"
|
||||||
agree_title: "Confirm this flag as valid and correct"
|
agree_title: "Confirm this flag as valid and correct"
|
||||||
agree_flag_modal_title: "Agree and..."
|
agree_flag_hide_post: "Agree and Hide Post"
|
||||||
agree_flag_hide_post: "Agree (hide post + send PM)"
|
agree_flag_hide_post_title: "Hide this post and automatically send the user a message urging them to edit it."
|
||||||
agree_flag_hide_post_title: "Hide this post and automatically send the user a message urging them to edit it"
|
agree_flag_restore_post: "Agree and Restore Post"
|
||||||
agree_flag_restore_post: "Agree (restore post)"
|
agree_flag_restore_post_title: "Restore the post so that all users can see it."
|
||||||
agree_flag_restore_post_title: "Restore this post"
|
agree_flag: "Agree and Keep Post"
|
||||||
agree_flag: "Agree with flag"
|
agree_flag_title: "Agree with flag and keep the post unchanged."
|
||||||
agree_flag_title: "Agree with flag and keep the post unchanged"
|
|
||||||
defer_flag: "Ignore"
|
defer_flag: "Ignore"
|
||||||
defer_flag_title: "Remove this flag; it requires no action at this time."
|
defer_flag_title: "Remove this flag; it requires no action at this time."
|
||||||
delete: "Delete"
|
delete: "Delete"
|
||||||
delete_title: "Delete the post this flag refers to."
|
delete_title: "Delete the post this flag refers to."
|
||||||
delete_post_defer_flag: "Delete post and Ignore flag"
|
delete_post_defer_flag: "Delete Post and Ignore flag"
|
||||||
delete_post_defer_flag_title: "Delete post; if the first post, delete the topic"
|
delete_post_defer_flag_title: "Delete post; if the first post, delete the topic"
|
||||||
delete_post_agree_flag: "Delete post and Agree with flag"
|
delete_post_agree_flag: "Delete Post and Agree with flag"
|
||||||
delete_post_agree_flag_title: "Delete post; if the first post, delete the topic"
|
delete_post_agree_flag_title: "Delete post; if the first post, delete the topic"
|
||||||
delete_flag_modal_title: "Delete and..."
|
delete_flag_modal_title: "Delete and..."
|
||||||
delete_spammer: "Delete Spammer"
|
delete_spammer: "Delete Spammer"
|
||||||
|
|
Loading…
Reference in New Issue