fix: fix types, remove @nuxt/image because of broken types

This commit is contained in:
DecDuck
2025-04-05 14:21:37 +11:00
parent 82baeb909a
commit b22681c555
9 changed files with 30 additions and 48 deletions

View File

@ -1,5 +1,5 @@
<template>
<ModalTemplate v-model="!!open">
<ModalTemplate v-model="open">
<template #default>
<div>
<DialogTitle as="h3" class="text-lg font-medium leading-6 text-white">
@ -59,7 +59,7 @@ const emit = defineEmits<{
created: [collectionId: string];
}>();
const open = defineModel<boolean>();
const open: Ref<boolean> = defineModel<boolean>() as any;
const collectionName = ref("");
const createCollectionLoading = ref(false);

View File

@ -1,5 +1,5 @@
<template>
<TransitionRoot as="template" :show="!!open">
<TransitionRoot as="template" :show="open">
<Dialog class="relative z-50" @close="open = false">
<TransitionChild
as="template"
@ -71,9 +71,7 @@
type="button"
:loading="uploadLoading"
@click="() => uploadFile_wrapper()"
:class="[
'inline-flex w-full shadow-sm sm:ml-3 sm:w-auto',
]"
:class="['inline-flex w-full shadow-sm sm:ml-3 sm:w-auto']"
>
Upload
</LoadingButton>
@ -121,7 +119,7 @@ import {
import { ArrowUpTrayIcon } from "@heroicons/vue/20/solid";
import { XCircleIcon } from "@heroicons/vue/24/solid";
const open = defineModel<boolean>();
const open: Ref<boolean> = defineModel<boolean>() as any;
const file = ref<FileList | undefined>();
const currentFile = computed(() => file.value?.item(0));
@ -146,7 +144,10 @@ async function uploadFile() {
}
}
const result = await $dropFetch(props.endpoint, { method: "POST", body: form });
const result = await $dropFetch(props.endpoint, {
method: "POST",
body: form,
});
open.value = false;
file.value = undefined;
emit("upload", result);

View File

@ -101,16 +101,10 @@ if (import.meta.client) {
<div
class="hidden lg:relative lg:col-start-2 lg:row-start-1 lg:row-end-4 lg:block"
>
<NuxtImg
<img
src="/wallpapers/error-wallpaper.jpg"
class="absolute inset-0 h-full w-full object-cover"
alt=""
width="3000"
height="3000"
provider="ipx"
quality="80"
:placeholder="[700, 700, 75, 5]"
preload
/>
</div>
</div>

View File

@ -49,8 +49,6 @@ export default defineNuxtConfig({
tsConfig: {
compilerOptions: {
verbatimModuleSyntax: false,
skipDefaultLibCheck: true,
skipLibCheck: true,
},
},
},
@ -61,7 +59,7 @@ export default defineNuxtConfig({
modules: [
"vue3-carousel-nuxt",
"nuxt-security",
"@nuxt/image",
// "@nuxt/image",
"@nuxt/fonts",
],

View File

@ -9,14 +9,14 @@
"generate": "nuxt generate",
"preview": "nuxt preview",
"postinstall": "nuxt prepare",
"typecheck": "nuxi typecheck"
"typecheck": "nuxt typecheck"
},
"dependencies": {
"@drop-oss/droplet": "^0.7.2",
"@headlessui/vue": "^1.7.23",
"@heroicons/vue": "^2.1.5",
"@nuxt/fonts": "^0.11.0",
"@nuxt/image": "1.9.0",
"@nuxt/image": "^1.10.0",
"@nuxtjs/tailwindcss": "^6.12.2",
"@prisma/client": "^6.1.0",
"@tailwindcss/vite": "^4.0.6",

View File

@ -109,16 +109,10 @@
</div>
</div>
<div class="relative hidden w-0 flex-1 lg:block">
<NuxtImg
<img
src="/wallpapers/signin.jpg"
class="absolute inset-0 h-full w-full object-cover"
alt=""
width="3000"
height="3000"
provider="ipx"
quality="80"
:placeholder="[700, 700, 75, 5]"
preload
/>
</div>
</div>

View File

@ -18,16 +18,10 @@
</div>
</div>
<div class="relative hidden w-0 flex-1 lg:block">
<NuxtImg
<img
src="/wallpapers/signin.jpg"
class="absolute inset-0 h-full w-full object-cover"
alt=""
width="1000"
height="1000"
provider="ipx"
quality="80"
:placeholder="[700, 700, 75, 5]"
preload
/>
</div>
</div>

View File

@ -1054,19 +1054,20 @@
unplugin "^2.2.0"
unstorage "^1.15.0"
"@nuxt/image@1.9.0":
version "1.9.0"
resolved "https://registry.yarnpkg.com/@nuxt/image/-/image-1.9.0.tgz#3692cf6ab533e1b173a81bdefcdf5a9f5ceeda09"
integrity sha512-kuuePx/jtlmsuG/G8mTMELntw4p8MLD4tu9f4A064xor/ks29oEoBmFRzvfFwxqZ7cqfG2M4LZfTZFjQz5St+Q==
"@nuxt/image@^1.10.0":
version "1.10.0"
resolved "https://registry.yarnpkg.com/@nuxt/image/-/image-1.10.0.tgz#dda5fbc0420b9b6f64e2d67d4b74942c3d2c1323"
integrity sha512-/B58GeEmme7bkmQUrXzEw8P9sJb9BkMaYZqLDtq8ZdDLEddE3P4nVya8RQPB+p4b7EdqWajpPqdy1A2ZPLev/A==
dependencies:
"@nuxt/kit" "^3.15.1"
consola "^3.3.3"
"@nuxt/kit" "^3.16.0"
consola "^3.4.2"
defu "^6.1.4"
h3 "^1.13.0"
h3 "^1.15.1"
image-meta "^0.2.1"
ohash "^1.1.4"
pathe "^2.0.0"
std-env "^3.8.0"
knitwork "^1.2.0"
ohash "^2.0.11"
pathe "^2.0.3"
std-env "^3.8.1"
ufo "^1.5.4"
optionalDependencies:
ipx "^2.1.0"
@ -1097,7 +1098,7 @@
unimport "^4.0.0"
untyped "^1.5.2"
"@nuxt/kit@^3.11.2", "@nuxt/kit@^3.12.4", "@nuxt/kit@^3.13.2", "@nuxt/kit@^3.15.0", "@nuxt/kit@^3.15.1", "@nuxt/kit@^3.15.4", "@nuxt/kit@^3.16.0", "@nuxt/kit@^3.16.1":
"@nuxt/kit@^3.11.2", "@nuxt/kit@^3.12.4", "@nuxt/kit@^3.13.2", "@nuxt/kit@^3.15.0", "@nuxt/kit@^3.15.4", "@nuxt/kit@^3.16.0", "@nuxt/kit@^3.16.1":
version "3.16.1"
resolved "https://registry.yarnpkg.com/@nuxt/kit/-/kit-3.16.1.tgz#7acc5457b83fc2c7ecb25d728d83899eef4464d4"
integrity sha512-Perby8hJGUeCWad5oTVXb/Ibvp18ZCUC5PxHHu+acMDmVfnxSo48yqk7qNd09VkTF3LEzoEjNZpmW2ZWN0ry7A==
@ -2719,7 +2720,7 @@ confbox@^0.2.1:
resolved "https://registry.yarnpkg.com/confbox/-/confbox-0.2.1.tgz#ae39f2c99699afa451d00206479f15f9a1208a8b"
integrity sha512-hkT3yDPFbs95mNCy1+7qNKC6Pro+/ibzYxtM2iqEigpf0sVw+bg4Zh9/snjsBcf990vfIsg5+1U7VyiyBb3etg==
consola@^3.2.3, consola@^3.3.1, consola@^3.3.3, consola@^3.4.0, consola@^3.4.2:
consola@^3.2.3, consola@^3.3.1, consola@^3.4.0, consola@^3.4.2:
version "3.4.2"
resolved "https://registry.yarnpkg.com/consola/-/consola-3.4.2.tgz#5af110145397bb67afdab77013fdc34cae590ea7"
integrity sha512-5IKcdX0nnYavi6G7TtOhwkYzyjfJlatbjMjuLSfE2kYT5pMDOilZ4OvMhi637CcDICTmz3wARPoyhqyX1Y+XvA==
@ -5451,7 +5452,7 @@ pathe@^1.0.0, pathe@^1.1.1, pathe@^1.1.2:
resolved "https://registry.yarnpkg.com/pathe/-/pathe-1.1.2.tgz#6c4cb47a945692e48a1ddd6e4094d170516437ec"
integrity sha512-whLdWMYL2TwI08hn8/ZqAbrVemu0LNaNNJZX73O6qaIdCTfXutsLhMkjdENX0qhsQ9uIimo4/aQOmXkoon2nDQ==
pathe@^2.0.0, pathe@^2.0.1, pathe@^2.0.2, pathe@^2.0.3:
pathe@^2.0.1, pathe@^2.0.2, pathe@^2.0.3:
version "2.0.3"
resolved "https://registry.yarnpkg.com/pathe/-/pathe-2.0.3.tgz#3ecbec55421685b70a9da872b2cff3e1cbed1716"
integrity sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==