mirror of
https://github.com/Drop-OSS/drop.git
synced 2025-11-22 12:41:10 +10:00
fix: lint
This commit is contained in:
@ -47,7 +47,9 @@ import { XMarkIcon } from "@heroicons/vue/24/solid";
|
||||
import type { SerializeObject } from "nitropack";
|
||||
import type { NotificationModel } from "~/prisma/client/models";
|
||||
|
||||
const props = defineProps<{ notification: SerializeObject<NotificationModel> }>();
|
||||
const props = defineProps<{
|
||||
notification: SerializeObject<NotificationModel>;
|
||||
}>();
|
||||
|
||||
async function deleteMe() {
|
||||
await $dropFetch(`/api/v1/notifications/:id`, {
|
||||
|
||||
@ -49,5 +49,7 @@
|
||||
import type { SerializeObject } from "nitropack";
|
||||
import type { NotificationModel } from "~/prisma/client/models";
|
||||
|
||||
const props = defineProps<{ notifications: Array<SerializeObject<NotificationModel>> }>();
|
||||
const props = defineProps<{
|
||||
notifications: Array<SerializeObject<NotificationModel>>;
|
||||
}>();
|
||||
</script>
|
||||
|
||||
@ -4,7 +4,10 @@ import type { NotificationModel } from "~/prisma/client/models";
|
||||
const ws = new WebSocketHandler("/api/v1/notifications/ws");
|
||||
|
||||
export const useNotifications = () =>
|
||||
useState<Array<SerializeObject<NotificationModel>>>("notifications", () => []);
|
||||
useState<Array<SerializeObject<NotificationModel>>>(
|
||||
"notifications",
|
||||
() => [],
|
||||
);
|
||||
|
||||
ws.listen((e) => {
|
||||
const notification = JSON.parse(e) as SerializeObject<NotificationModel>;
|
||||
|
||||
@ -26,7 +26,6 @@
|
||||
<TrashIcon class="size-4" />
|
||||
{{ $t("account.notifications.clear") }}
|
||||
</button>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<p
|
||||
|
||||
Reference in New Issue
Block a user