$ account element-hq
Element Call is a decentralized video/voice calling application built on the Matrix protocol (MatrixRTC) with LiveKit as the media backend (SFU). It provides a full-featured web application (React 19 + TypeScript 5.8) for group calls, screen sharing, reactions, end-to-end encryption, and multiple layout modes (grid, spotlight, one-on-one, PiP). The system is designed for embedding: it can run as a standalone SPA, an iframe widget for Matrix clients (Element Web/Element X), a React component library, or a native mobile package (Android AAR, iOS Swift). The architecture separates a core SDK (`sdk/`) that handles MatrixRTC session management, media backend abstraction, and reactive state management from the UI layer (`src/`), which provides the call views, settings, analytics (PostHog), and error reporting (rageshake). Key entry points include `src/main.tsx` (app initialization), `component/index.tsx` (component API), and `sdk/index.ts` (SDK exports). External dependencies include a Matrix homeserver (Synapse), a LiveKit SFU, and an authorization service for token exchange. The codebase is heavily tested with Vitest unit tests, Playwright E2E tests, and Storybook component stories.