diff options
| author | Owen Jacobson <owen@grimoire.ca> | 2025-07-01 15:30:44 -0400 |
|---|---|---|
| committer | Owen Jacobson <owen@grimoire.ca> | 2025-07-03 22:43:44 -0400 |
| commit | 1cafeb5ec92c1dc4ad74fbed58b15a8ab2f3c0cf (patch) | |
| tree | 0ecca3ed4133210286e9d11b2d2027136f09113a /ui | |
| parent | 8d412732dc094ead3c5cf86c005d187f9624fc65 (diff) | |
Move the `/ch` channel view to `/c` (for conversation).
Diffstat (limited to 'ui')
| -rw-r--r-- | ui/lib/components/Channel.svelte | 2 | ||||
| -rw-r--r-- | ui/routes/(app)/+layout.svelte | 4 | ||||
| -rw-r--r-- | ui/routes/(app)/c/[conversation]/+page.svelte (renamed from ui/routes/(app)/ch/[channel]/+page.svelte) | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/ui/lib/components/Channel.svelte b/ui/lib/components/Channel.svelte index 4f908d2..9004e50 100644 --- a/ui/lib/components/Channel.svelte +++ b/ui/lib/components/Channel.svelte @@ -3,7 +3,7 @@ </script> <li class:active> - <a href="/ch/{id}"> + <a href="/c/{id}"> {#if hasUnreads} <span class="badge has-unreads">❦</span> {:else} diff --git a/ui/routes/(app)/+layout.svelte b/ui/routes/(app)/+layout.svelte index c7e1f22..e3272bc 100644 --- a/ui/routes/(app)/+layout.svelte +++ b/ui/routes/(app)/+layout.svelte @@ -20,7 +20,7 @@ onDestroy(session.end.bind(session)); let pageContext = getContext('page'); - let channel = $derived(page.params.channel); + let channel = $derived(page.params.conversation); let channels = $derived(session.channels); @@ -60,7 +60,7 @@ const lastActiveChannel = getLastActiveChannel(); const inRoot = page.url.pathname === '/'; if (inRoot && lastActiveChannel) { - goto(`/ch/${lastActiveChannel}`); + goto(`/c/${lastActiveChannel}`); } else if (channel) { setLastActiveChannel(channel || null); } diff --git a/ui/routes/(app)/ch/[channel]/+page.svelte b/ui/routes/(app)/c/[conversation]/+page.svelte index ef000fc..4d2cc86 100644 --- a/ui/routes/(app)/ch/[channel]/+page.svelte +++ b/ui/routes/(app)/c/[conversation]/+page.svelte @@ -10,7 +10,7 @@ const { session, outbox } = data; let activeChannel; - const channelId = $derived(page.params.channel); + const channelId = $derived(page.params.conversation); const channel = $derived(session.channels.find((channel) => channel.id === channelId)); const messages = $derived( session.messages.filter((message) => message.conversation === channelId), |
