From 520f9801be9f1dcfa463090b649845980e59deb9 Mon Sep 17 00:00:00 2001 From: triphora Date: Wed, 14 Dec 2022 19:36:28 -0500 Subject: [PATCH] Corresponding frontend PR to modrinth/labrinth#449 (#763) Co-authored-by: Prospector Fixes https://github.com/modrinth/knossos/issues/597 Fixes https://github.com/modrinth/knossos/issues/593 Fixes https://github.com/modrinth/knossos/issues/768 --- .eslintrc.js | 1 + .gitignore | 1 + assets/styles/components.scss | 14 +- components/ui/ModalCreation.vue | 4 +- nuxt.config.js | 3 - pages/_type/_id.vue | 72 +++++++- pages/_type/_id/edit.vue | 291 ++++++++++++++++++++++---------- pages/search.vue | 36 ++-- pages/settings/monetization.vue | 2 +- store/tag.js | 1 - 10 files changed, 298 insertions(+), 127 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index b445e14d2..0c004c46f 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -16,5 +16,6 @@ module.exports = { plugins: ['prettier'], rules: { 'no-console': 'off', + 'vue/no-v-html': 'off', }, } diff --git a/.gitignore b/.gitignore index c027f3d69..b5714fd85 100644 --- a/.gitignore +++ b/.gitignore @@ -95,3 +95,4 @@ sw.* # pnpm files pnpm-lock.yaml +/.npmrc diff --git a/assets/styles/components.scss b/assets/styles/components.scss index a9a85c634..39c7807fe 100644 --- a/assets/styles/components.scss +++ b/assets/styles/components.scss @@ -34,6 +34,7 @@ &:focus-visible, &:hover { color: var(--color-link-hover); + cursor: pointer; } &:active { @@ -1001,6 +1002,11 @@ h1 { .label__description { display: block; margin-block-end: var(--spacing-card-sm); + + .label__subdescription { + display: block; + margin-block-start: var(--spacing-card-md); + } } } } @@ -1061,8 +1067,12 @@ h1 { width: 15rem; } - input + *, .input-group + * { - margin-block-start: var(--spacing-card-md); + >, + .extend-styling> { + input + *, + .input-group + * { + margin-block-start: var(--spacing-card-md); + } } button, .button, .iconified-button { diff --git a/components/ui/ModalCreation.vue b/components/ui/ModalCreation.vue index 64fe9ef15..8531ae7c5 100644 --- a/components/ui/ModalCreation.vue +++ b/components/ui/ModalCreation.vue @@ -181,9 +181,7 @@ Questions? [Join the Modrinth Discord for support!](https://discord.gg/EUHuJHt)` categories: [], client_side: this.getClientSide(), server_side: this.getServerSide(), - license_id: this.$tag.licenses.map((it) => it.short).includes('arr') - ? 'arr' - : this.$tag.licenses[0].short, + license_id: 'LicenseRef-All-Rights-Reserved', is_draft: true, }) ) diff --git a/nuxt.config.js b/nuxt.config.js index c8bc06b62..6fb4ad13f 100644 --- a/nuxt.config.js +++ b/nuxt.config.js @@ -346,7 +346,6 @@ export default { categories, loaders, gameVersions, - licenses, donationPlatforms, reportTypes, ] = ( @@ -354,7 +353,6 @@ export default { axios.get(`${API_URL}tag/category`, headers), axios.get(`${API_URL}tag/loader`, headers), axios.get(`${API_URL}tag/game_version`, headers), - axios.get(`${API_URL}tag/license`, headers), axios.get(`${API_URL}tag/donation_platform`, headers), axios.get(`${API_URL}tag/report_type`, headers), ]) @@ -363,7 +361,6 @@ export default { state.categories = categories state.loaders = loaders state.gameVersions = gameVersions - state.licenses = licenses state.donationPlatforms = donationPlatforms state.reportTypes = reportTypes diff --git a/pages/_type/_id.vue b/pages/_type/_id.vue index a32923d6e..b63a5bb0d 100644 --- a/pages/_type/_id.vue +++ b/pages/_type/_id.vue @@ -1,5 +1,13 @@