@@ -896,6 +892,8 @@ export default defineNuxtComponent({
oldFileTypes = version.files.map((x) => fileTypes.find((y) => y.value === x.file_type))
+ const order = ['required', 'optional', 'incompatible', 'embedded']
+
return {
fileTypes: ref(fileTypes),
oldFileTypes: ref(oldFileTypes),
@@ -919,6 +917,11 @@ export default defineNuxtComponent({
.$dayjs(version.date_published)
.format('MMM D, YYYY')}. ${version.downloads} downloads.`
),
+ deps: computed(() =>
+ version.dependencies.sort(
+ (a, b) => order.indexOf(a.dependency_type) - order.indexOf(b.dependency_type)
+ )
+ ),
}
},
data() {
@@ -1428,6 +1431,11 @@ export default defineNuxtComponent({
.dep-type {
text-transform: capitalize;
+ color: var(--color-text-secondary);
+
+ &.incompatible {
+ color: var(--color-red);
+ }
}
}
@@ -1529,6 +1537,7 @@ export default defineNuxtComponent({
h4 {
margin-bottom: 0.5rem;
}
+
label {
margin-top: 0.5rem;
}
diff --git a/pages/[type]/[id]/versions.vue b/pages/[type]/[id]/versions.vue
index f974b5d7a..f97d2987b 100644
--- a/pages/[type]/[id]/versions.vue
+++ b/pages/[type]/[id]/versions.vue
@@ -290,10 +290,6 @@ async function handleFiles(files) {
flex-direction: column;
gap: var(--spacing-card-xs);
}
-
- &:active:not(&:disabled) {
- transform: scale(0.99) !important;
- }
}
}
diff --git a/pages/dashboard.vue b/pages/dashboard.vue
index 910992830..f26f60baf 100644
--- a/pages/dashboard.vue
+++ b/pages/dashboard.vue
@@ -2,17 +2,25 @@
You have made
@@ -49,6 +36,22 @@
Enroll in the Creator Monetization Program
+
+
+
+ View transfer history
+
+
+ Monetization settings
+
+
Processing fees
diff --git a/pages/dashboard/revenue/transfers.vue b/pages/dashboard/revenue/transfers.vue
index fa7290a16..483ea7a8e 100644
--- a/pages/dashboard/revenue/transfers.vue
+++ b/pages/dashboard/revenue/transfers.vue
@@ -41,11 +41,9 @@ useHead({
const auth = await useAuth()
const app = useNuxtApp()
-const [raw] = await Promise.all([
- useBaseFetch(`user/${auth.value.user.id}/payouts`, app.$defaultHeaders()),
-])
-
-const payouts = ref(raw)
+const { data: payouts } = await useAsyncData(`user/${auth.value.user.id}/payouts`, () =>
+ useBaseFetch(`user/${auth.value.user.id}/payouts`, app.$defaultHeaders())
+)
+
diff --git a/pages/moderation/index.vue b/pages/moderation/index.vue
new file mode 100644
index 000000000..baff9a6c8
--- /dev/null
+++ b/pages/moderation/index.vue
@@ -0,0 +1,46 @@
+
+
+
+ Statistics
+
+
+
Projects
+
+ {{ formatNumber(stats.projects) }}
+
+
+
+
Versions
+
+ {{ formatNumber(stats.versions) }}
+
+
+
+
Files
+
+ {{ formatNumber(stats.files) }}
+
+
+
+
Authors
+
+ {{ formatNumber(stats.authors) }}
+
+
+
+
+
+
+
diff --git a/pages/moderation/messages.vue b/pages/moderation/messages.vue
new file mode 100644
index 000000000..10f590c56
--- /dev/null
+++ b/pages/moderation/messages.vue
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
diff --git a/pages/moderation/report/[id].vue b/pages/moderation/report/[id].vue
new file mode 100644
index 000000000..9032c539a
--- /dev/null
+++ b/pages/moderation/report/[id].vue
@@ -0,0 +1,15 @@
+
+
+
+
diff --git a/pages/moderation/reports.vue b/pages/moderation/reports.vue
new file mode 100644
index 000000000..248553ce6
--- /dev/null
+++ b/pages/moderation/reports.vue
@@ -0,0 +1,16 @@
+
+
+
+
+
+
+
diff --git a/pages/moderation/review.vue b/pages/moderation/review.vue
new file mode 100644
index 000000000..2c0d37d09
--- /dev/null
+++ b/pages/moderation/review.vue
@@ -0,0 +1,254 @@
+
+
+ Review projects
+
+
+
+
+
+
+ Showing {{ projectsFiltered.length }} {{ projectTypePlural }} of {{ projects.length }} total
+ projects in the queue.
+
+ There are {{ projects.length }} projects in the queue.
+
+ {{ projectsOver24Hours.length }} {{ projectTypePlural }}
+ have been in the queue for over 24 hours.
+
+
+ {{ projectsOver48Hours.length }} {{ projectTypePlural }}
+ have been in the queue for over 48 hours.
+
+
+
+
+
+
+
+ {{ project.title }}
+ {{ $formatProjectType(project.inferred_project_type) }}
+
+
+
+
+ by
+
+
+ {{ project.owner.username }}
+
+
+
+ is requesting to be
+
+
+
+
+ View project
+
+
+
+ Submitted
+ {{
+ fromNow(project.queued)
+ }}
+
+
Unknown queue date
+
+
+
+
+
diff --git a/pages/notifications.vue b/pages/notifications.vue
deleted file mode 100644
index 3baf5065a..000000000
--- a/pages/notifications.vue
+++ /dev/null
@@ -1,225 +0,0 @@
-
-
-
-
-
-
-
-
-
- You are up-to-date!
-
-
-
-
-
-
-
-
-
diff --git a/pages/notifications/[type].vue b/pages/notifications/[type].vue
deleted file mode 100644
index 355338565..000000000
--- a/pages/notifications/[type].vue
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/pages/settings.vue b/pages/settings.vue
index 24bbd6250..8fae51a20 100644
--- a/pages/settings.vue
+++ b/pages/settings.vue
@@ -12,9 +12,6 @@
-
-
-
@@ -33,7 +30,6 @@ import NavStackItem from '~/components/ui/NavStackItem.vue'
import PaintbrushIcon from '~/assets/images/utils/paintbrush.svg'
import UserIcon from '~/assets/images/utils/user.svg'
-import HeartIcon from '~/assets/images/utils/heart.svg'
import CurrencyIcon from '~/assets/images/utils/currency.svg'
const route = useRoute()
diff --git a/pages/user/[id].vue b/pages/user/[id].vue
index ea2f320e3..f16f0429e 100644
--- a/pages/user/[id].vue
+++ b/pages/user/[id].vue
@@ -118,7 +118,7 @@
Joined {{ fromNow(user.created) }}
diff --git a/plugins/shorthands.js b/plugins/shorthands.js
index 693e1907e..54ba23ada 100644
--- a/plugins/shorthands.js
+++ b/plugins/shorthands.js
@@ -1,3 +1,5 @@
+import { getProjectTypeForUrlShorthand } from '~/helpers/projects.js'
+
export default defineNuxtPlugin((nuxtApp) => {
const tagStore = nuxtApp.$tag
const authStore = nuxtApp.$auth
@@ -121,33 +123,9 @@ export default defineNuxtPlugin((nuxtApp) => {
return type
})
- nuxtApp.provide('getProjectTypeForUrl', (type, categories) => {
- if (type === 'mod') {
- const isMod = categories.some((category) => {
- return tagStore.loaderData.modLoaders.includes(category)
- })
-
- const isPlugin = categories.some((category) => {
- return tagStore.loaderData.allPluginLoaders.includes(category)
- })
-
- const isDataPack = categories.some((category) => {
- return tagStore.loaderData.dataPackLoaders.includes(category)
- })
-
- if (isDataPack) {
- return 'datapack'
- } else if (isPlugin) {
- return 'plugin'
- } else if (isMod) {
- return 'mod'
- } else {
- return 'mod'
- }
- } else {
- return type
- }
- })
+ nuxtApp.provide('getProjectTypeForUrl', (type, loaders) =>
+ getProjectTypeForUrlShorthand(nuxtApp, type, loaders)
+ )
nuxtApp.provide('cycleValue', cycleValue)
const sortedCategories = tagStore.categories.slice().sort((a, b) => {
const headerCompare = a.header.localeCompare(b.header)
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index ab9d42d37..070489a30 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -31,6 +31,9 @@ dependencies:
markdown-it:
specifier: ^13.0.1
version: 13.0.1(patch_hash=3vlxaukqep4gvqytxeznhg6wbq)
+ omorphia:
+ specifier: ^0.4.31
+ version: 0.4.31
vue-multiselect:
specifier: ^3.0.0-alpha.2
version: 3.0.0-alpha.2
@@ -2010,7 +2013,6 @@ packages:
/@vue/devtools-api@6.5.0:
resolution: {integrity: sha512-o9KfBeaBmCKl10usN4crU53fYtC1r7jJwdGKjPT24t348rHxgfpZ0xL3Xm/gLUYnc0oTp8LAmrxOeLyu6tbk2Q==}
- dev: true
/@vue/reactivity-transform@3.3.4:
resolution: {integrity: sha512-MXgwjako4nu5WFLAjpBnCj/ieqcjE2aJBINUNQzkZQfzIZA4xn+0fV1tIYBJvvva3N3OvKGofRLvQIwEQPpaXw==}
@@ -4155,6 +4157,11 @@ packages:
engines: {node: '>=12.0.0'}
dev: false
+ /highlight.js@11.8.0:
+ resolution: {integrity: sha512-MedQhoqVdr0U6SSnWPzfiadUcDHfN/Wzq25AkXiQv9oiOO/sG0S7XkvpFIqWBl9Yq1UYyYOOVORs5UW2XlPyzg==}
+ engines: {node: '>=12.0.0'}
+ dev: false
+
/hookable@5.5.3:
resolution: {integrity: sha512-Yc+BQe8SvoXH1643Qez1zqLRmbA5rCL+sSmk6TVos0LWVfNIB7PGncdlId77WzLGSIB5KaWgTaNTs2lNVEI6VQ==}
dev: true
@@ -5384,6 +5391,19 @@ packages:
resolution: {integrity: sha512-9CIOSq5945rI045GFtcO3uudyOkYVY1nyfFxVQp+9BRgslr8jPNiSSrsFGg/BNTUFOLqx0P5tng6G32brIPw0w==}
dev: true
+ /omorphia@0.4.31:
+ resolution: {integrity: sha512-xeb9bD42VFRDKCkKz678hBYCIS//Atd4/hx6/YmboJLMEIjIJfS2Ocf9G53G52XkfS4DWs9CIzKz71NDh86kxQ==}
+ dependencies:
+ dayjs: 1.11.7
+ floating-vue: 2.0.0-beta.20(vue@3.3.4)
+ highlight.js: 11.8.0
+ markdown-it: 13.0.1(patch_hash=3vlxaukqep4gvqytxeznhg6wbq)
+ vue: 3.3.4
+ vue-router: 4.2.2(vue@3.3.4)
+ vue-select: 4.0.0-beta.6(vue@3.3.4)
+ xss: 1.0.14
+ dev: false
+
/on-finished@2.4.1:
resolution: {integrity: sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg==}
engines: {node: '>= 0.8'}
@@ -7208,7 +7228,14 @@ packages:
dependencies:
'@vue/devtools-api': 6.5.0
vue: 3.3.4
- dev: true
+
+ /vue-select@4.0.0-beta.6(vue@3.3.4):
+ resolution: {integrity: sha512-K+zrNBSpwMPhAxYLTCl56gaMrWZGgayoWCLqe5rWwkB8aUbAUh7u6sXjIR7v4ckp2WKC7zEEUY27g6h1MRsIHw==}
+ peerDependencies:
+ vue: 3.x
+ dependencies:
+ vue: 3.3.4
+ dev: false
/vue-template-compiler@2.7.14:
resolution: {integrity: sha512-zyA5Y3ArvVG0NacJDkkzJuPQDF8RFeRlzV2vLeSnhSpieO6LK2OVbdLPi5MPPs09Ii+gMO8nY4S3iKQxBxDmWQ==}