From 6a3c8e898296d7d71ed30a45a514e53eb35d2244 Mon Sep 17 00:00:00 2001 From: SauceyRed Date: Thu, 29 May 2025 22:16:42 +0200 Subject: [PATCH 1/5] feat: improve channel list appearance --- components/Channel.vue | 13 ++++++++----- pages/servers/[serverId]/channels/[channelId].vue | 15 ++++++++++----- 2 files changed, 18 insertions(+), 10 deletions(-) diff --git a/components/Channel.vue b/components/Channel.vue index a0cdc78..a41974a 100644 --- a/components/Channel.vue +++ b/components/Channel.vue @@ -1,19 +1,21 @@ @@ -30,6 +32,7 @@ const props = defineProps<{ name: string, href: string, current?: boolean }>(); display: flex; height: 4dvh; white-space: nowrap; + align-items: center; } .current-channel { diff --git a/pages/servers/[serverId]/channels/[channelId].vue b/pages/servers/[serverId]/channels/[channelId].vue index eb6ba46..2b5d225 100644 --- a/pages/servers/[serverId]/channels/[channelId].vue +++ b/pages/servers/[serverId]/channels/[channelId].vue @@ -18,9 +18,8 @@
- -
@@ -102,19 +101,19 @@ const members = [ ]; onMounted(async () => { - loading.value = true; console.log("channelid: set loading to true"); server.value = await fetchWithApi(`servers/${route.params.serverId}`); channels.value = await fetchWithApi( `servers/${route.params.serverId}/channels` ); + console.log("channels:", channels.value); channel.value = await fetchWithApi( route.path ); + console.log("channel:", channel.value); console.log("channelid: channel:", channel); - loading.value = false; console.log("channelid: set loading to false"); }); @@ -151,4 +150,10 @@ function toggleInvitePopup(e: Event) { border-left: 1px solid rgb(70, 70, 70); } +#channels-list { + display: flex; + flex-direction: column; + gap: 1dvh; +} + \ No newline at end of file From 53687a0ec3fc899672b3123e8d6079c23078ddd0 Mon Sep 17 00:00:00 2001 From: SauceyRed Date: Thu, 29 May 2025 22:19:31 +0200 Subject: [PATCH 2/5] feat: implement message grouping, improve styling --- app.vue | 5 ++ components/Message.vue | 78 ++++++++++++++++------ components/MessageArea.vue | 128 +++++++++++++++++++++++++------------ nuxt.config.ts | 3 +- 4 files changed, 155 insertions(+), 59 deletions(-) diff --git a/app.vue b/app.vue index 717f0fd..9e6e124 100644 --- a/app.vue +++ b/app.vue @@ -49,4 +49,9 @@ a { border-radius: .3rem; } + +.invisible { + visibility: hidden; +} + diff --git a/components/Message.vue b/components/Message.vue index e37d1e4..bf85a17 100644 --- a/components/Message.vue +++ b/components/Message.vue @@ -1,6 +1,6 @@ \ No newline at end of file diff --git a/nuxt.config.ts b/nuxt.config.ts index 560e664..63d9372 100644 --- a/nuxt.config.ts +++ b/nuxt.config.ts @@ -26,7 +26,8 @@ export default defineNuxtConfig({ }, runtimeConfig: { public: { - apiVersion: 1 + apiVersion: 1, + messageGroupingMaxDifference: 300000 } }, /* nitro: { From a92c74edc9e2de361c86b14b95ad272fb35c32e5 Mon Sep 17 00:00:00 2001 From: SauceyRed Date: Thu, 29 May 2025 22:22:48 +0200 Subject: [PATCH 3/5] feat: remove unused sendMessage function in client layout --- layouts/client.vue | 8 -------- 1 file changed, 8 deletions(-) diff --git a/layouts/client.vue b/layouts/client.vue index ae749e3..6c2a49b 100644 --- a/layouts/client.vue +++ b/layouts/client.vue @@ -80,14 +80,6 @@ const members = [ } ]; -function sendMessage(e: Event) { - e.preventDefault(); - const textInput = document.getElementById("message-box-input") as HTMLInputElement; - const text = textInput.value; - console.log("MESSAGE SENT!!!"); - console.log("text:", text); -} -