Commit Graph

12 Commits

Author SHA1 Message Date
287d2295b3 feat: screen share + bottom control bar (Google Meet style)
- Replace VideoConference with custom layout: GridLayout for cameras,
  FocusLayout when someone shares screen (carousel + focused view)
- Bottom control bar: mic, camera, screen share, chat, lobby,
  moderation, hand raise, leave/end — all as round icon buttons
- Top bar reduced to minimal room name + code badge
- MediaControls: synced with LiveKit track state via RoomEvents
- LeaveButton disconnects and redirects (host → dashboard, guest → home)
- Screen share auto-detected: switches to focus layout with carousel
2026-03-24 12:35:25 +03:00
87f0b5a21d fix: chat duplication, lobby scroll, ban self-protection
- Chat: fix race condition where SSE delivers message before POST
  response, causing duplicate — now checks if real msg already exists
- LobbyManager: add max-h-72 + overflow-y-auto for long participant lists
- ModerationPanel: hide kick/ban buttons for yourself (useLocalParticipant),
  add max-h-80 + overflow scroll, show API errors instead of silencing
- Moderate API: reject kick/ban when targetSessionId === host userId
2026-03-24 12:31:02 +03:00
f6d3f37a5f feat: dark design system + full UI redesign + HTTPS for local dev
- Design system: CSS custom properties (surface levels, accent, status colors, scrollbar, focus-visible)
- Landing: hero with gradient title, feature cards with SVG icons
- Auth pages: consistent card layout with design tokens
- Dashboard: sticky top bar, room grid with status dots, empty state
- Create room: toggle switches, form validation with spinners
- Join flow: room info card with status badge, monospace code input
- Room page: top bar with sidebar toggles (chat/lobby/moderation)
- Chat: bubble messages with optimistic UI, empty state
- Moderation: participant list with avatar initials, kick/ban
- Lobby: waiting animation with pulsing rings, approve/reject
- HTTPS: dev:https script, setup.sh auto-configures BETTER_AUTH_URL
- Auth: trustedOrigins now includes both http:// and https://
2026-03-24 12:14:49 +03:00
848540cfbf fix: auto-start room when host enters (WAITING → ACTIVE) 2026-03-24 07:29:38 +03:00
ca3c786a6b fix: Prisma 7 adapter-based connection (no url in schema)
- Use @prisma/adapter-pg for PrismaClient (Prisma 7 removed datasourceUrl/datasources)
- prisma.config.ts: migrate.url for CLI commands
- schema.prisma: no url in datasource (Prisma 7 requirement)
2026-03-24 06:43:47 +03:00
a6c744223b fix: prisma url in schema + first user becomes ADMIN
- Add url = env("DATABASE_URL") back to schema (required by Prisma 7.5)
- Simplify prisma.config.ts
- First registered user auto-promoted to ADMIN via databaseHooks
- Subsequent users get HOST role
2026-03-24 03:54:55 +03:00
59c0cdad5f fix: remove datasourceUrl from PrismaClient constructor (Prisma 7)
Prisma 7 no longer accepts datasourceUrl in constructor.
URL is resolved from DATABASE_URL env var automatically.
2026-03-24 03:44:44 +03:00
0e53fba726 fix: auto-detect all LAN IPs for dev auth and HMR
No more manual LAN_HOST or BETTER_AUTH_TRUSTED_ORIGINS for dev.
Uses os.networkInterfaces() to allow all machine IPs automatically.
2026-03-24 03:35:02 +03:00
f6f93c2ae9 feat: auto LAN auth + setup.sh dev command
- auth.ts: auto-allow localhost:3000-3010 + LAN_HOST for trustedOrigins
- setup.sh: new `dev` command (update + kill old processes + auto LAN IP + launch)
- next.config.ts: allowedDevOrigins for LAN HMR
2026-03-24 03:24:14 +03:00
cbdd2fb2e4 fix: auth not working when accessed from non-localhost
- Remove hardcoded baseURL from auth-client.ts — better-auth now uses
  current window.location.origin, works from any IP/domain
- Add trustedOrigins config to auth.ts — allows requests from LAN IPs
- Add BETTER_AUTH_TRUSTED_ORIGINS env var for configuring allowed origins
- Improve error logging in login/register forms (was silent catch)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-24 02:54:56 +03:00
a42ec96965 perf: Redis pub/sub, PgBouncer, optimistic UI for high concurrency
- Add Redis 7 for pub/sub (lobby + chat real-time), rate limiting, caching
- Replace SSE DB polling with Redis pub/sub (lobby: instant approval, chat: instant delivery)
- Add PgBouncer (transaction mode, 500 client → 25 pool connections)
- Chat SSE stream via Redis pub/sub instead of 3s polling
- Optimistic UI in ChatPanel (messages appear before server confirms)
- Redis-based rate limiter (works across multiple app replicas)
- Prisma query optimization (select only needed fields)
- Chat message cache in Redis (10s TTL)
- Docker Compose: add redis, pgbouncer services with healthchecks
- Production: resource limits, 2 app replicas behind Traefik
- Update CLAUDE.md, README.md, .env.example, setup.sh

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-22 14:17:25 +03:00
3846e3e00d feat: LiveServer-M1 v1 — educational video conferencing platform
Full MVP implementation:
- Next.js 16 + React 19 + TypeScript + Tailwind CSS v4
- LiveKit integration (rooms, tokens, webhooks, moderation)
- better-auth (email/password, sessions, roles)
- Prisma 7 + PostgreSQL (9 models, 3 enums)
- 15 API routes (auth, rooms, lobby, chat, files, moderation, hand-raise)
- 7 pages (landing, auth, dashboard, join, video room)
- SSE-based waiting room with host approval flow
- Security: PIN rate limiting, session fingerprint bans, chat/files auth
- Python AI Agent (Deepgram STT + OpenAI summarization)
- Docker Compose (local + production with Traefik + Let's Encrypt)
- Interactive setup script (setup.sh)
- Dev protection middleware (DEV_ACCESS_KEY, ALLOWED_IPS)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-22 13:57:53 +03:00