mirror of
https://github.com/modrinth/code.git
synced 2026-08-31 03:55:59 +00:00
feat: moderation additions for shared instances (#7285)
* feat: moderation additions for shared instances * fix: lint --------- Co-authored-by: Prospector <6166773+Prospector@users.noreply.github.com>
This commit is contained in:
@@ -89,6 +89,7 @@ import {
|
||||
AffiliateIcon,
|
||||
BadgeCheckIcon,
|
||||
BanIcon,
|
||||
BoxesIcon,
|
||||
BoxIcon,
|
||||
CalendarIcon,
|
||||
ChartIcon,
|
||||
@@ -140,6 +141,10 @@ const messages = defineMessages({
|
||||
id: 'profile.button.info',
|
||||
defaultMessage: 'View user details',
|
||||
},
|
||||
sharedInstancesButton: {
|
||||
id: 'profile.button.shared-instances',
|
||||
defaultMessage: 'View shared instances',
|
||||
},
|
||||
officialAccount: {
|
||||
id: 'profile.official-account',
|
||||
defaultMessage: 'Official Modrinth account',
|
||||
@@ -215,6 +220,7 @@ const emit = defineEmits<{
|
||||
openBilling: []
|
||||
toggleAffiliate: []
|
||||
openInfo: []
|
||||
openSharedInstances: []
|
||||
openAnalytics: []
|
||||
editUser: []
|
||||
}>()
|
||||
@@ -293,6 +299,14 @@ const moreActions = computed<OverflowMenuOption[]>(() => [
|
||||
tone: 'orange',
|
||||
shown: props.showStaffActions && props.isStaff,
|
||||
},
|
||||
{
|
||||
id: 'open-shared-instances',
|
||||
label: formatMessage(messages.sharedInstancesButton),
|
||||
icon: BoxesIcon,
|
||||
action: () => emit('openSharedInstances'),
|
||||
tone: 'orange',
|
||||
shown: props.showStaffActions && props.isStaff,
|
||||
},
|
||||
{
|
||||
id: 'open-analytics',
|
||||
label: formatMessage(messages.analyticsButton),
|
||||
|
||||
@@ -189,6 +189,7 @@
|
||||
@open-billing="openPath(`/admin/billing/${user.id}`)"
|
||||
@toggle-affiliate="toggleAffiliate"
|
||||
@open-info="openUserDetails"
|
||||
@open-shared-instances="openPath(`/admin/shared-instances/${user.id}`)"
|
||||
@open-analytics="
|
||||
openPath(`/dashboard/analytics?user=${encodeURIComponent(user.username)}`)
|
||||
"
|
||||
|
||||
@@ -3113,6 +3113,9 @@
|
||||
"profile.button.set-affiliate": {
|
||||
"defaultMessage": "Set as affiliate"
|
||||
},
|
||||
"profile.button.shared-instances": {
|
||||
"defaultMessage": "View shared instances"
|
||||
},
|
||||
"profile.button.unblock": {
|
||||
"defaultMessage": "Unblock"
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user