feat: implement frontend video platform configuration and abstraction

- Add NEXT_PUBLIC_VIDEO_PLATFORM environment variable support
- Create video platform abstraction layer with factory pattern
- Implement Whereby and Jitsi platform providers
- Update room meeting page to use platform-agnostic component
- Add platform display in room management (cards and table views)
- Support single platform per deployment configuration
- Maintain backward compatibility with existing Whereby integration

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-09-04 12:21:51 -06:00
parent 41224a424c
commit 293f7d4f1f
20 changed files with 1254 additions and 293 deletions

View File

@@ -10,10 +10,15 @@ import {
Text,
VStack,
HStack,
Badge,
} from "@chakra-ui/react";
import { LuLink } from "react-icons/lu";
import { RoomDetails } from "../../../api";
import { RoomActionsMenu } from "./RoomActionsMenu";
import {
getPlatformDisplayName,
getPlatformColor,
} from "../../../lib/videoPlatforms";
interface RoomCardsProps {
rooms: RoomDetails[];
@@ -93,6 +98,15 @@ export function RoomCards({
/>
</Flex>
<VStack align="start" fontSize="sm" gap={0}>
<HStack gap={2}>
<Text fontWeight="500">Platform:</Text>
<Badge
colorPalette={getPlatformColor(room.platform)}
size="sm"
>
{getPlatformDisplayName(room.platform)}
</Badge>
</HStack>
{room.zulip_auto_post && (
<HStack gap={2}>
<Text fontWeight="500">Zulip:</Text>

View File

@@ -7,10 +7,15 @@ import {
IconButton,
Text,
Spinner,
Badge,
} from "@chakra-ui/react";
import { LuLink } from "react-icons/lu";
import { RoomDetails } from "../../../api";
import { RoomActionsMenu } from "./RoomActionsMenu";
import {
getPlatformDisplayName,
getPlatformColor,
} from "../../../lib/videoPlatforms";
interface RoomTableProps {
rooms: RoomDetails[];
@@ -92,16 +97,19 @@ export function RoomTable({
<Table.Root>
<Table.Header>
<Table.Row>
<Table.ColumnHeader width="250px" fontWeight="600">
<Table.ColumnHeader width="200px" fontWeight="600">
Room Name
</Table.ColumnHeader>
<Table.ColumnHeader width="250px" fontWeight="600">
Zulip
</Table.ColumnHeader>
<Table.ColumnHeader width="150px" fontWeight="600">
Room Size
<Table.ColumnHeader width="120px" fontWeight="600">
Platform
</Table.ColumnHeader>
<Table.ColumnHeader width="200px" fontWeight="600">
Zulip
</Table.ColumnHeader>
<Table.ColumnHeader width="130px" fontWeight="600">
Room Size
</Table.ColumnHeader>
<Table.ColumnHeader width="180px" fontWeight="600">
Recording
</Table.ColumnHeader>
<Table.ColumnHeader
@@ -116,6 +124,14 @@ export function RoomTable({
<Table.Cell>
<Link href={`/${room.name}`}>{room.name}</Link>
</Table.Cell>
<Table.Cell>
<Badge
colorPalette={getPlatformColor(room.platform)}
size="sm"
>
{getPlatformDisplayName(room.platform)}
</Badge>
</Table.Cell>
<Table.Cell>
{getZulipDisplay(
room.zulip_auto_post,