change note menu order

This commit is contained in:
naskya 2023-06-08 19:02:50 +09:00
parent bf78733da4
commit 91190244fb
No known key found for this signature in database
GPG key ID: 164DFF24E2D40139

View file

@ -262,13 +262,6 @@ export function getNoteMenu(props: {
null,
]
: []),
instance.features.postEditing && isAppearAuthor
? {
icon: "ph-pencil-line ph-bold ph-lg",
text: i18n.ts.edit,
action: edit,
}
: undefined,
{
icon: "ph-clipboard-text ph-bold ph-lg",
text: i18n.ts.copyContent,
@ -372,10 +365,9 @@ export function getNoteMenu(props: {
}]
: []
),*/
...(!isAppearAuthor
? [
null,
{
!isAppearAuthor
? {
icon: "ph-warning-circle ph-bold ph-lg",
text: i18n.ts.reportAbuse,
action: () => {
@ -395,10 +387,22 @@ export function getNoteMenu(props: {
"closed",
);
},
},
]
: []),
}
: undefined,
instance.features.postEditing && isAppearAuthor
? {
icon: "ph-pencil-line ph-bold ph-lg",
text: i18n.ts.edit,
action: edit,
}
: undefined,
isAppearAuthor
? {
icon: "ph-eraser ph-bold ph-lg",
text: i18n.ts.deleteAndEdit,
action: delEdit,
}
: undefined,
isAppearAuthor || isModerator
? {
icon: "ph-trash ph-bold ph-lg",
@ -407,14 +411,6 @@ export function getNoteMenu(props: {
action: del,
}
: undefined,
isAppearAuthor
? {
icon: "ph-eraser ph-bold ph-lg",
text: i18n.ts.deleteAndEdit,
action: delEdit,
}
: undefined,
].filter((x) => x !== undefined);
} else {
menu = [