npm run format

This commit is contained in:
2024-06-02 02:35:42 +02:00
parent 8329afe897
commit 86b80f8244
28 changed files with 572 additions and 562 deletions

View File

@ -1,10 +1,6 @@
<template>
<div class="notifications">
<Modal v-for="notification in notifications.getNotifications"
:key="notification.id"
:isModalOpen="true"
@modal:close="closeNotification(notification.id)"
>
<Modal v-for="notification in notifications.getNotifications" :key="notification.id" :isModalOpen="true" @modal:close="closeNotification(notification.id)">
<template #modal-body>
<p>{{ notification.message }}</p>
</template>
@ -30,7 +26,7 @@ function setupNotificationListener(connection: any) {
notifications.addNotification({
id: Math.random().toString(16),
message: data.message
});
})
})
}
@ -40,7 +36,9 @@ onMounted(() => {
setupNotificationListener(connection)
} else {
// Watch for changes in the socket connection
watch(() => socket.getConnection, (newConnection) => {
watch(
() => socket.getConnection,
(newConnection) => {
if (newConnection) setupNotificationListener(newConnection)
}
)
@ -53,4 +51,4 @@ onUnmounted(() => {
connection.off('notification')
}
})
</script>
</script>