From 4db65993d543c9e615efe47029b14b0075e1d8c4 Mon Sep 17 00:00:00 2001 From: Dennis Landmann Date: Mon, 20 Apr 2026 00:26:19 +0200 Subject: [PATCH] feat: redesign + avatars + theme + call presence fixes (v0.6.0) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Visual: - Light/dark theme via ThemeContext + CSS vars - New design tokens (surface/fg/accent/line/etc.) across all pages - Reusable Avatar component (img + letter fallback) wired into UserBar, ConversationHeader, ChatsPage, FriendsPage, GroupInfoPanel, IncomingCallPanel Calls: - Split call UI: IncomingCallPanel, InCallPanel, CallControls, CallParticipantTile, ScreenShareViewer - Active speaker hook (useActiveSpeakers) - Fix: ActiveCallBanner stayed hidden after hangup while peers in room. - useCallPresence: bind presence callbacks only when we own subscribe (Supabase forbids .on() after .subscribe() on shared dedup'd channels) - useCallPresence: never removeChannel — channel is shared with CallContext so tearing it down on ConversationHeader unmount killed live tracking - ActiveCallBanner: lastCallConversationId fallback so banner shows instantly after hangup, auto-dismiss when room confirmed empty - Drop unused useAnyActiveCall Bump tauri version 0.5.0 -> 0.6.0 --- apps/desktop/index.html | 15 +- apps/desktop/src-tauri/tauri.conf.json | 2 +- apps/desktop/src/App.tsx | 3 + apps/desktop/src/components/AppShell.tsx | 8 +- apps/desktop/src/components/Avatar.tsx | 45 + apps/desktop/src/components/CallControls.tsx | 170 ++++ .../src/components/CallParticipantTile.tsx | 254 ++++++ apps/desktop/src/components/CallUI.tsx | 378 +++----- .../src/components/ConversationHeader.tsx | 158 +++- .../desktop/src/components/GroupInfoPanel.tsx | 31 +- apps/desktop/src/components/InCallPanel.tsx | 847 ++++++++++-------- .../src/components/IncomingCallPanel.tsx | 123 +++ apps/desktop/src/components/MessageBubble.tsx | 93 +- apps/desktop/src/components/Modal.tsx | 10 +- .../src/components/ScreenShareViewer.tsx | 182 ++++ apps/desktop/src/components/Sidebar.tsx | 159 +++- .../src/components/TypingIndicator.tsx | 8 +- apps/desktop/src/components/UpdateToast.tsx | 14 +- apps/desktop/src/components/UserBar.tsx | 35 +- apps/desktop/src/components/icons.tsx | 83 ++ apps/desktop/src/context/CallContext.tsx | 49 + apps/desktop/src/context/ThemeContext.tsx | 53 ++ apps/desktop/src/lib/theme.ts | 44 + apps/desktop/src/lib/useActiveSpeakers.ts | 35 + apps/desktop/src/lib/useAnyActiveCall.ts | 94 -- apps/desktop/src/lib/useCallPresence.ts | 53 +- apps/desktop/src/pages/AdminPage.tsx | 78 +- apps/desktop/src/pages/ChatsPage.tsx | 162 +++- apps/desktop/src/pages/ConversationPage.tsx | 59 +- apps/desktop/src/pages/FriendsPage.tsx | 85 +- apps/desktop/src/pages/SettingsPage.tsx | 127 ++- apps/desktop/src/styles/globals.css | 54 +- apps/desktop/tailwind.config.js | 42 + 33 files changed, 2459 insertions(+), 1094 deletions(-) create mode 100644 apps/desktop/src/components/Avatar.tsx create mode 100644 apps/desktop/src/components/CallControls.tsx create mode 100644 apps/desktop/src/components/CallParticipantTile.tsx create mode 100644 apps/desktop/src/components/IncomingCallPanel.tsx create mode 100644 apps/desktop/src/components/ScreenShareViewer.tsx create mode 100644 apps/desktop/src/context/ThemeContext.tsx create mode 100644 apps/desktop/src/lib/theme.ts create mode 100644 apps/desktop/src/lib/useActiveSpeakers.ts delete mode 100644 apps/desktop/src/lib/useAnyActiveCall.ts diff --git a/apps/desktop/index.html b/apps/desktop/index.html index 0270fe3..46c8e29 100644 --- a/apps/desktop/index.html +++ b/apps/desktop/index.html @@ -6,8 +6,21 @@ Netralax + - +
diff --git a/apps/desktop/src-tauri/tauri.conf.json b/apps/desktop/src-tauri/tauri.conf.json index 869de65..c62974f 100644 --- a/apps/desktop/src-tauri/tauri.conf.json +++ b/apps/desktop/src-tauri/tauri.conf.json @@ -1,7 +1,7 @@ { "$schema": "https://schema.tauri.app/config/2", "productName": "ChatApp", - "version": "0.5.0", + "version": "0.6.0", "identifier": "com.meinname.chatapp", "build": { "beforeDevCommand": "pnpm vite:dev", diff --git a/apps/desktop/src/App.tsx b/apps/desktop/src/App.tsx index 8f67e33..4c720ad 100644 --- a/apps/desktop/src/App.tsx +++ b/apps/desktop/src/App.tsx @@ -7,6 +7,7 @@ import { AuthProvider } from './context/AuthContext'; import { CallProvider } from './context/CallContext'; import { ConversationsProvider } from './context/ConversationsContext'; import { FriendshipsProvider } from './context/FriendshipsContext'; +import { ThemeProvider } from './context/ThemeContext'; import { AdminPage } from './pages/AdminPage'; import { AuthCallbackPage } from './pages/AuthCallbackPage'; import { AuthPage } from './pages/AuthPage'; @@ -18,6 +19,7 @@ import { SettingsPage } from './pages/SettingsPage'; export function App() { return ( + @@ -51,5 +53,6 @@ export function App() { + ); } diff --git a/apps/desktop/src/components/AppShell.tsx b/apps/desktop/src/components/AppShell.tsx index fa18e66..20c9122 100644 --- a/apps/desktop/src/components/AppShell.tsx +++ b/apps/desktop/src/components/AppShell.tsx @@ -21,7 +21,7 @@ export function AppShell() { }, [session?.user.id, device?.id]); return ( -
+
@@ -36,11 +36,11 @@ export function AppShell() { ); } -// Calmer than the auth-screen background — full-bleed grid + 2 large blobs. -// No animation here so message lists stay readable. +// Subtle ambient background — only renders in dark mode where the app's +// visual language expects depth. Light mode stays clean and flat. function ShellBackground() { return ( -