Account for new statuses (#853)
* Account for new statuses More work is going to be needed for scheduling projects, but this is a stopgap measure to fix #852 * Fix lint * Why, Prettier, why?
This commit is contained in:
parent
e45f0f0299
commit
6e5d1fb613
@ -3,6 +3,8 @@
|
||||
<template v-if="color">
|
||||
<span class="circle" /> {{ $capitalizeString(type) }}
|
||||
</template>
|
||||
|
||||
<!-- User roles -->
|
||||
<template v-else-if="type === 'admin'">
|
||||
<ModrinthIcon /> Modrinth Team
|
||||
</template>
|
||||
@ -10,8 +12,15 @@
|
||||
<ModeratorIcon /> Moderator
|
||||
</template>
|
||||
<template v-else-if="type === 'creator'"><CreatorIcon /> Creator</template>
|
||||
|
||||
<!-- Project statuses -->
|
||||
<template v-else-if="type === 'approved'"><ListIcon /> Listed</template>
|
||||
<template v-else-if="type === 'withheld'"><EyeOffIcon /> Withheld</template>
|
||||
<template v-else-if="type === 'unlisted'"><EyeOffIcon /> Unlisted</template>
|
||||
<template v-else-if="type === 'private'"><LockIcon /> Private</template>
|
||||
<template v-else-if="type === 'scheduled'">
|
||||
<CalendarIcon /> Scheduled
|
||||
</template>
|
||||
<template v-else-if="type === 'draft'"><DraftIcon /> Draft</template>
|
||||
<template v-else-if="type === 'archived'">
|
||||
<ArchiveIcon /> Archived
|
||||
@ -20,6 +29,8 @@
|
||||
<template v-else-if="type === 'processing'">
|
||||
<ProcessingIcon /> Under review
|
||||
</template>
|
||||
|
||||
<!-- Team members -->
|
||||
<template v-else-if="type === 'accepted'"><CheckIcon /> Accepted</template>
|
||||
<template v-else-if="type === 'pending'">
|
||||
<ProcessingIcon /> Pending
|
||||
@ -41,6 +52,8 @@ import CrossIcon from '~/assets/images/utils/x.svg?inline'
|
||||
import ArchiveIcon from '~/assets/images/utils/archive.svg?inline'
|
||||
import ProcessingIcon from '~/assets/images/utils/updated.svg?inline'
|
||||
import CheckIcon from '~/assets/images/utils/check.svg?inline'
|
||||
import LockIcon from '~/assets/images/utils/lock.svg?inline'
|
||||
import CalendarIcon from '~/assets/images/utils/calendar.svg?inline'
|
||||
|
||||
export default {
|
||||
name: 'Badge',
|
||||
@ -55,6 +68,8 @@ export default {
|
||||
ArchiveIcon,
|
||||
ProcessingIcon,
|
||||
CheckIcon,
|
||||
LockIcon,
|
||||
CalendarIcon,
|
||||
},
|
||||
props: {
|
||||
type: {
|
||||
@ -99,6 +114,7 @@ export default {
|
||||
&.type--pending,
|
||||
&.type--moderator,
|
||||
&.type--processing,
|
||||
&.type--scheduled,
|
||||
&.orange {
|
||||
--badge-color: var(--color-special-orange);
|
||||
}
|
||||
@ -115,11 +131,13 @@ export default {
|
||||
color: var(--color-special-blue);
|
||||
}
|
||||
|
||||
&.type--withheld,
|
||||
&.type--unlisted,
|
||||
&.purple {
|
||||
color: var(--color-special-purple);
|
||||
}
|
||||
|
||||
&.type--private,
|
||||
&.gray {
|
||||
--badge-color: var(--color-special-gray);
|
||||
}
|
||||
|
||||
@ -326,9 +326,7 @@
|
||||
<div class="buttons status-buttons">
|
||||
<button
|
||||
v-if="
|
||||
project.status === 'rejected' ||
|
||||
project.status === 'unlisted' ||
|
||||
project.status === 'abandoned'
|
||||
project.status === 'rejected' || project.status === 'withheld'
|
||||
"
|
||||
class="iconified-button brand-button"
|
||||
@click="submitForReview"
|
||||
@ -629,13 +627,12 @@
|
||||
:toggle-collapsed="toggleChecklistCollapse"
|
||||
/>
|
||||
<div
|
||||
v-if="project.status === 'unlisted'"
|
||||
v-if="project.status === 'withheld'"
|
||||
class="card warning"
|
||||
aria-label="Warning"
|
||||
>
|
||||
{{ project.title }} is not viewable in search — either because the
|
||||
author has marked it as such or because it has been found to be in
|
||||
violation of one of
|
||||
{{ project.title }} is not viewable in search because it has been
|
||||
found to be in violation of one of
|
||||
<nuxt-link to="/legal/rules">Modrinth's content rules</nuxt-link>.
|
||||
Modrinth makes no guarantees as to whether {{ project.title }} is safe
|
||||
for use in a multiplayer context.
|
||||
@ -649,15 +646,6 @@
|
||||
{{ project.title }} will not receive any further updates unless the
|
||||
author decides to unarchive the project.
|
||||
</div>
|
||||
<div
|
||||
v-if="project.status === 'abandoned'"
|
||||
class="card warning"
|
||||
aria-label="Warning"
|
||||
>
|
||||
{{ project.title }} has been marked as abandoned by Modrinth's
|
||||
moderators. {{ project.title }} will not receive any further updates
|
||||
unless the author decides to return.
|
||||
</div>
|
||||
<div
|
||||
v-if="project.project_type === 'modpack'"
|
||||
class="card warning"
|
||||
@ -692,7 +680,11 @@
|
||||
>.
|
||||
</div>
|
||||
<Advertisement
|
||||
v-if="project.status === 'approved' || project.status === 'unlisted'"
|
||||
v-if="
|
||||
['approved', 'unlisted', 'archived', 'private'].includes(
|
||||
project.status
|
||||
)
|
||||
"
|
||||
type="banner"
|
||||
small-screen="square"
|
||||
/>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user