Examples and guides for using the OpenAI API
Add realtime translation cookbook guide (#2667)
erikakettleson-openai8ef2841809e1
diff --git a/.gitignore b/.gitignoreindex ba26b18d..93d3a30d 100644--- a/.gitignore+++ b/.gitignore@@ -15,6 +15,8 @@ downloads/eggs/.eggs/lib/+!examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/lib/+!examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/lib/**lib64parts/sdist/@@ -103,6 +105,8 @@ celerybeat.pid# Environments.env+.env.*+!.env.example.venvenv/venv/diff --git a/examples/voice_solutions/realtime_translation_guide.mdx b/examples/voice_solutions/realtime_translation_guide.mdxnew file mode 100644index 00000000..abf036fd--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide.mdx@@ -0,0 +1,562 @@+# Build Live Translation Apps with gpt-realtime-translate++`gpt-realtime-translate` is a live speech-to-speech translation model for building multilingual audio experiences across broadcasts, streams, calls, and video conversations. It accepts spoken input, automatically detects the source language, and returns translated speech plus text transcripts. Developers only need to specify the target output language.++This model has two new features that make it uniquely capable:++1. Unlike general-purpose voice models, `gpt-realtime-translate` is **optimized for interpretation**. It was trained on thousands of hours of professional interpreter audio, which helps it remain translation-only and wait for enough context before producing speech. This is especially important across languages with different sentence structures.+2. It can **process input audio while simultaneously streaming translated audio back**. This allows for truly low latency over continuous speech.++We built `gpt-realtime-translate` because live interpretation has different requirements than existing AI voice interactions. General-purpose models can be prompted to translate, but they may still answer questions or follow instructions rather than translate them. They also rely on turn-based interaction, requiring speakers to pause while the model generates the translated audio, which does not work well for fluent interpretation.++These have been the main blockers to the high accuracy and low latency required for natural live interpretation, and what we're solving for with `gpt-realtime-translate`.++## How to build with Realtime Translation++This model is unique in that it is primarily about **empowering humans to be multilingual as opposed to building AI voice agents**. If you're building voice agents, use the new `gpt-realtime-2` model.++We see two main patterns for `gpt-realtime-translate`. The first is **broadcast-style translation**: livestreams, webinars, lectures, earnings calls, conference keynotes, and other cases where many listeners need translated audio from one primary source to another. The second is **conversational translation**, where two or more participants speak with each other across languages: call centers, video chat, or other phone-based workflows.++This cookbook focuses on these patterns: We'll start by covering the basics, then build a web app for **one-way live translation** from any browser tab audio, use Twilio to build translation into **phone calls**, and create a **multilingual group video chat** room with LiveKit. Lastly, we'll cover production best practices, model limitations, and evals.++## What you will build++You will build three ways to add live translation to existing audio paths:++1. **Browser tab translation:** Capture tab audio with `getDisplayMedia()`, send it to Realtime Translation over WebRTC, and play translated speech plus captions in the browser.+2. **Phone-call translation:** Use Twilio Media Streams to receive phone audio over WebSockets, bridge it into Realtime Translation, and send translated audio back to the other caller.+3. **Video-call translation:** Subscribe to remote LiveKit microphone tracks, translate each remote speaker for the listener, and render translated audio and captions locally.++The complete demo apps live in the accompanying folders:++- [Browser tab translation](https://github.com/openai/openai-cookbook/tree/main/examples/voice_solutions/realtime_translation_guide/browser-translation-demo)+- [Twilio phone translation](https://github.com/openai/openai-cookbook/tree/main/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo)+- [LiveKit video translation](https://github.com/openai/openai-cookbook/tree/main/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo)++## Prerequisites++You need:++- An OpenAI API key.+- Node.js for the browser and Twilio demos.+- A Twilio phone number if you want to run the phone-call demo.+- A LiveKit project or self-hosted LiveKit server if you want to run the video-room demo.++Keep your OpenAI API key on a server. Browser examples should use short-lived client secrets rather than exposing the API key to client code.++## API & Session Basics++See our [Live Translation docs](https://developers.openai.com/api/docs/guides/realtime-translation) for full details on setting up WebRTC and WebSocket sessions, client and server events, and configuration options.++### Key differences++Realtime Translation sessions are configured around the target output language. Set the target language with `session.audio.output.language`. The model currently supports over 70 input languages and 13 output languages. This model does not currently support custom prompting or voice selection parameters.++If you want source-language transcripts alongside translated audio, configure input transcription with `gpt-realtime-whisper`.++Realtime Translation uses **dynamic voice adaptation**. Instead of selecting a fixed output voice, translated speech follows the source speaker's general tone, pitch, and speaking style. In a multi-speaker session, the translated voice will change as new speaker audio comes in.++### Session lifecycle++The session lifecycle is also different from a standard Realtime voice session:++- **Dedicated endpoint:** Connect to `/v1/realtime/translations`.+- **Continuous audio in**: Stream 24 kHz PCM16 audio with `session.input_audio_buffer.append`, including silence between phrases.+- **Continuous translation out**: The model emits translated audio in 200 ms PCM16 chunks, plus target-language transcript deltas.+- **No turn lifecycle**: Translation starts from the incoming audio stream itself. There is no `response.create`, assistant turn, tool call, or conversation state to manage.++### Protocols++For browser-based apps, use WebRTC. The browser sends microphone, tab, or remote participant audio as a media track and receives translated speech as a remote audio track. Use the `oai-events` data channel for session updates, transcript deltas, and errors. See the Browser Tab Translation or LiveKit sections for implementation examples.++For backend media pipelines, use WebSockets. This is the right fit when your server already receives raw audio, such as Twilio Media Streams, SIP, broadcast ingest, or a media worker. Send base64 24 kHz PCM16 audio with `session.input_audio_buffer.append`, including silence between spoken phrases. See the Phone Calls with Twilio section for an example.++## Browser tab translation++Let's start with a small browser app for one-way live translation. The app captures audio from a browser tab, starts a Realtime Translation session over WebRTC, and plays translated speech with subtitles as the model emits them.++This pattern is useful when the original experience is already happening in the browser: a public meeting, livestream, conference talk, online class, or video without built-in live dubbing. Instead of rebuilding the player or publishing separate language feeds, the app sits alongside the page and gives listeners translated audio and subtitles in real time.++++### How it works++1. Your server creates a short-lived translation client secret.+2. The browser captures tab audio with `getDisplayMedia()`.+3. The browser creates an `RTCPeerConnection`, adds the captured audio track, and opens an `oai-events` data channel.+4. The browser posts its SDP offer to the Realtime Translation call endpoint with the client secret.+5. The model returns translated audio on the remote WebRTC audio track and sends transcript deltas on the data channel.++### Create the translation client secret++Create the client secret on your server so your standard OpenAI API key never reaches the browser. The model and output language live in the client-secret request.++```ts+const TRANSLATION_CLIENT_SECRET_URL =+ "https://api.openai.com/v1/realtime/translations/client_secrets";++app.post("/session", async (req, res) => {+ const language = req.body.targetLanguage ?? "es";++ const response = await fetch(TRANSLATION_CLIENT_SECRET_URL, {+ method: "POST",+ headers: {+ Authorization: `Bearer ${process.env.OPENAI_API_KEY}`,+ "Content-Type": "application/json",+ },+ body: JSON.stringify({+ session: {+ model: "gpt-realtime-translate",+ audio: {+ input: {+ transcription: { model: "gpt-realtime-whisper" },+ noise_reduction: { type: "near_field" },+ },+ output: { language },+ },+ },+ }),+ });++ res.status(response.status).json(await response.json());+});+```++The complete browser demo validates target language codes before making the OpenAI request and returns only the short-lived client secret to the browser.++### Capture tab audio++Use `getDisplayMedia()` so the user explicitly picks the source tab. When supported, request `suppressLocalAudioPlayback` so the listener does not hear the original and translated audio at the same time.++```ts+async function captureTabAudio() {+ const audio = {+ echoCancellation: false,+ noiseSuppression: false,+ autoGainControl: false,+ };++ if (navigator.mediaDevices.getSupportedConstraints?.().suppressLocalAudioPlayback) {+ audio.suppressLocalAudioPlayback = true;+ }++ const stream = await navigator.mediaDevices.getDisplayMedia({+ video: true,+ audio,+ });++ if (!stream.getAudioTracks().length) {+ stream.getTracks().forEach((track) => track.stop());+ throw new Error("Choose a browser tab and enable tab audio.");+ }++ return stream;+}+```++### Open the WebRTC translation session++Use the short-lived client secret to post the browser's SDP offer to the Realtime Translation call endpoint. Audio output arrives as a remote track. Translation and input transcript deltas arrive on the data channel.++```ts+const sessionResponse = await fetch("/session", {+ method: "POST",+ headers: { "Content-Type": "application/json" },+ body: JSON.stringify({ targetLanguage }),+});++const session = await sessionResponse.json();++const pc = new RTCPeerConnection();+const events = pc.createDataChannel("oai-events");++for (const track of sourceStream.getAudioTracks()) {+ pc.addTrack(track, sourceStream);+}++pc.ontrack = ({ streams }) => {+ translatedAudio.srcObject = streams[0];+};++events.onmessage = ({ data }) => {+ const event = JSON.parse(data);++ if (event.type === "session.output_transcript.delta") {+ translatedSubtitles.textContent += event.delta;+ }++ if (event.type === "session.input_transcript.delta") {+ sourceTranscript.textContent += event.delta;+ }+};++const offer = await pc.createOffer();+await pc.setLocalDescription(offer);++const sdpResponse = await fetch(+ "https://api.openai.com/v1/realtime/translations/calls",+ {+ method: "POST",+ headers: {+ Authorization: `Bearer ${session.client_secret}`,+ "Content-Type": "application/sdp",+ },+ body: offer.sdp,+ }+);++await pc.setRemoteDescription({+ type: "answer",+ sdp: await sdpResponse.text(),+});+```++Run the complete demo:++```bash+cd examples/voice_solutions/realtime_translation_guide/browser-translation-demo+npm install+npm run dev+```++Then open the local URL, choose a tab with audio, pick the target language, and start translation.++## Phone calls with Twilio++Next, let's put `gpt-realtime-translate` into a Twilio call path. Conversational translation works best when each participant has a distinct audio stream. Twilio Media Streams gives your backend a server-side WebSocket for phone audio, and your server handles the format boundary: receiving caller audio, converting it for Realtime Translation, then converting translated audio back into Twilio media messages.++++### How it works++1. A caller joins and says their preferred output language.+2. Twilio streams that caller's audio to your backend.+3. Your backend converts Twilio audio into the audio format expected by Realtime Translation.+4. For each translation direction, your backend opens a Realtime Translation session with the listener's target language.+5. As translated audio comes back from OpenAI, your backend converts it back into Twilio media messages.+6. Twilio plays the translated audio to the other participant.++For a two-person call, this usually means two translation sessions: A-to-B and B-to-A. For larger calls, create translation sessions based on who needs to hear which source speaker in which language rather than mixing all participants into one shared stream.++> **Production note:** `gpt-realtime-translate` may not translate audio that is already in the listener's selected output language. Because this demo does not pass original Twilio audio through to the other participant, same-language speech may lead to silence. Production phone bridges should add original-audio passthrough or mixing. This demo pairs callers one-to-one; additional callers wait for another caller and form a separate pair.++### Configure the Twilio webhook++Create a public endpoint for your server, then set the Twilio phone number's [Voice webhook](https://www.twilio.com/docs/usage/webhooks/voice-webhooks) to route inbound calls to your application. For local development, expose the server with a tunnel or deploy it somewhere Twilio can reach over port 443. The same host must serve the HTTP webhook routes and the WebSocket Media Stream route.++### Ask the caller for a target language++When a caller dials in, return [TwiML](https://www.twilio.com/docs/voice/twiml) that asks which language they want for the translation.++```xml+<Response>+ <Gather input="speech" timeout="10" speechTimeout="auto" action="/choose-language" method="POST">+ <Say>What language do you want to hear?</Say>+ </Gather>+ <Redirect method="POST">/choose-language</Redirect>+</Response>+```++### Start the Twilio Media Stream++After the caller chooses a supported language, return a bidirectional Media Stream. Pass the selected language as a custom parameter so the WebSocket handler can register the caller with their preferred output language.++```xml+<Response>+ <Say>You chose Spanish. Wait for the other caller, then begin speaking.</Say>+ <Connect>+ <Stream url="wss://YOUR_PUBLIC_HOST/media-stream">+ <Parameter name="callSid" value="CALL_SID" />+ <Parameter name="language" value="es" />+ <Parameter name="languageLabel" value="Spanish" />+ </Stream>+ </Connect>+</Response>+```++### Open a server-side translation session++Because this integration runs on your backend, you do not need browser client secrets. Open the Translation WebSocket directly from the server with your OpenAI API key and select the model in the URL.++```ts+import WebSocket from "ws";++function openTranslationSession({ targetLanguage }) {+ const ws = new WebSocket(+ "wss://api.openai.com/v1/realtime/translations?model=gpt-realtime-translate",+ {+ headers: {+ Authorization: `Bearer ${process.env.OPENAI_API_KEY}`,+ },+ }+ );++ ws.on("open", () => {+ ws.send(JSON.stringify({+ type: "session.update",+ session: {+ audio: {+ input: {+ transcription: { model: "gpt-realtime-whisper" },+ noise_reduction: { type: "near_field" },+ },+ output: { language: targetLanguage },+ },+ },+ }));+ });++ return ws;+}+```++### Bridge Twilio audio into Realtime Translation++Twilio sends base64 `audio/x-mulaw` at 8 kHz. Realtime Translation expects base64 little-endian PCM16 at 24 kHz, so the bridge decodes u-law, resamples to 24 kHz, and appends the audio buffer. Keep sending audio continuously, including silence, since translation sessions are not turn-based and do not wait for `response.create`.++```ts+function sendTwilioAudioToTranslation(realtimeWs, twilioMessage) {+ if (twilioMessage.event !== "media") return;++ const realtimeAudio = twilioMediaToRealtimeAudio(+ twilioMessage.media.payload+ );++ realtimeWs.send(JSON.stringify({+ type: "session.input_audio_buffer.append",+ audio: realtimeAudio,+ }));+}+```++### Bridge translated audio back to Twilio++Realtime Translation emits translated audio as base64 24 kHz PCM16 in `session.output_audio.delta`. Before sending it to Twilio, convert it back to 8 kHz u-law and wrap it in a Twilio media message.++```ts+function sendTranslationToTwilio(twilioWs, streamSid, realtimeEvent) {+ if (realtimeEvent.type !== "session.output_audio.delta") return;++ const twilioPayload = realtimeAudioToTwilioMedia(realtimeEvent.delta);++ twilioWs.send(JSON.stringify({+ event: "media",+ streamSid,+ media: {+ payload: twilioPayload,+ },+ }));+}+```++### Pair callers and create one session per direction++Once two callers are waiting, pair them and open two Realtime Translation sessions. Each session's output language is the language selected by the listener, not the speaker.++```ts+function pairCallers(a, b) {+ const aToB = openTranslationSession({ targetLanguage: b.language });+ const bToA = openTranslationSession({ targetLanguage: a.language });++ a.onAudio = (message) => sendTwilioAudioToTranslation(aToB, message);+ b.onAudio = (message) => sendTwilioAudioToTranslation(bToA, message);++ aToB.on("message", (data) => {+ sendTranslationToTwilio(b.ws, b.streamSid, JSON.parse(data));+ });++ bToA.on("message", (data) => {+ sendTranslationToTwilio(a.ws, a.streamSid, JSON.parse(data));+ });+}+```++Run the complete demo:++```bash+cd examples/voice_solutions/realtime_translation_guide/twilio-translation-demo+npm install+npm run dev+```++Configure your Twilio phone number's Voice webhook to call `POST https://YOUR_PUBLIC_HOST/incoming-call`.++## Video chat with LiveKit++Finally, let's integrate `gpt-realtime-translate` into a group video conference. Use this pattern when you already have a video room and want to add live interpretation to the conversation. [LiveKit](https://docs.livekit.io/) handles rooms, participants, microphone tracks, camera tracks, device selection, and reconnect behavior. Realtime Translation acts as an interpreter layer attached to the audio tracks that each listener receives.++++### How it works++1. A participant publishes microphone and camera tracks into the LiveKit room.+2. A listener subscribes to the remote participant's microphone track through LiveKit.+3. The listener's browser passes that remote `MediaStreamTrack` into a Realtime Translation sidecar.+4. The sidecar opens a WebRTC Realtime Translation session for the listener's selected output language.+5. Realtime Translation returns translated audio as a remote audio track and transcript deltas over the `oai-events` data channel.+6. The listener's browser plays the translated audio, renders captions, and ducks or mixes the original LiveKit audio locally.++In this demo, translated audio stays local to the listener's browser; it is not published back into the LiveKit room.++### Attach translation to a remote participant track++Once the listener joins a LiveKit room, find each remote participant's microphone track and pass the underlying `MediaStreamTrack` into a translation helper.++```ts+function getParticipantAudioMediaStreamTrack(participant: Participant) {+ const publication = participant.getTrackPublication(Track.Source.Microphone);+ return publication?.audioTrack?.mediaStreamTrack ?? null;+}+```++### Create one translation sidecar per remote speaker++A translated participant tile can keep the original LiveKit media path intact while adding translation output beside it. The tile still renders the participant's video and original audio, but it also starts a Realtime Translation sidecar for the participant's microphone track when translation is enabled.++```tsx+function TranslatedParticipantTile({+ participant,+ language,+ translationEnabled,+}: {+ participant: Participant;+ language: string;+ translationEnabled: boolean;+}) {+ const sourceTrack = getParticipantAudioMediaStreamTrack(participant);++ const translation = useRemoteTranslation({+ enabled: translationEnabled && Boolean(sourceTrack),+ sourceTrack,+ language,+ });++ return (+ <MeetingTile+ participant={participant}+ sourceVolume={translation.hasOutputAudio ? 0.15 : 1}+ translatedSubtitle={translation.translatedSubtitle}+ sourceSubtitle={translation.sourceSubtitle}+ />+ );+}+```++### Open the translation sidecar++The helper creates a short-lived Realtime Translation client secret on your server, opens a WebRTC sidecar from the browser, attaches the remote LiveKit microphone `MediaStreamTrack` to an `RTCPeerConnection`, and plays translated audio from the returned remote track.++```ts+async function startTranslationSidecar({ sourceTrack, clientSecret }) {+ const pc = new RTCPeerConnection();+ pc.addTrack(sourceTrack, new MediaStream([sourceTrack]));++ const translatedAudio = new Audio();+ translatedAudio.autoplay = true;+ pc.ontrack = ({ streams }) => {+ translatedAudio.srcObject = streams[0];+ };++ const events = pc.createDataChannel("oai-events");+ events.onmessage = ({ data }) => {+ const event = JSON.parse(data);+ if (event.type === "session.output_transcript.delta") {+ subtitles.textContent += event.delta;+ }+ };++ const offer = await pc.createOffer();+ await pc.setLocalDescription(offer);++ const response = await fetch(+ "https://api.openai.com/v1/realtime/translations/calls",+ {+ method: "POST",+ headers: {+ Authorization: `Bearer ${clientSecret}`,+ "Content-Type": "application/sdp",+ },+ body: offer.sdp,+ }+ );++ await pc.setRemoteDescription({+ type: "answer",+ sdp: await response.text(),+ });++ return pc;+}+```++### Plan session fanout by listener language++For a two-person room, each participant translates the other participant's microphone track into their own preferred language. For a group room, the number of active translation sessions depends on the number of active remote speakers and the number of distinct target languages listeners need.++Browser-side translation is the simplest architecture: each listener creates translation sidecars for the remote speakers they want translated. For larger rooms in production, move the work into a LiveKit worker or server-side participant that subscribes to room audio, translates each source speaker once per target language, and republishes translated tracks back into the room.++Run the complete demo:++```bash+cd examples/voice_solutions/realtime_translation_guide/livekit-translation-demo+pnpm install+pnpm dev+```++Use the same meeting code in two browser windows to join the same LiveKit room. Enable translation in one window, choose the language that listener wants to hear, and speak from the other window.++## Production readiness++Before launching Realtime Translation, test the full experience with the same audio, languages, network conditions, and user flows you expect in production. Translation quality is only one part of the experience: latency, speaker routing, captions, reconnect behavior, and audio controls all impact production readiness.++### Choose the architecture based on the media path++Use browser WebRTC for client-side media like microphones, tab audio, or LiveKit participant tracks. Use server-side WebSockets for telephony, broadcast ingest, or backend media pipelines.++For multi-party calls, route translation by source speaker and target language. Keep speaker tracks separate when possible, then fan out the translated output to listeners who share the same target language. Mixing all speakers into one stream makes captions, speaker identity, and overlapping speech harder to handle.++### Test terminology and names directly++The model does not currently support custom prompts, glossaries, or pronunciation guides. If your use case depends on specific vocabulary, names, legal or medical terms, or other domain language, test those terms directly. The model can sometimes substitute incorrect names or entities while translating, so include these cases in your launch evaluation set.++### Account for mixed-language speech++Realtime Translation tries not to translate speech that is already in the selected output language. For example, if the output language is Spanish and the speaker switches into Spanish, the model may not produce translated audio for that segment.++This matters for mixed-language speech. Spanglish to German should work as expected because both the English and Spanish parts need to be translated into German. Spanglish to English can feel choppier because the model may translate the Spanish parts but stay quiet during the English parts.++This behavior is usually helpful, but it can be confusing if your app fully mutes the original audio. If you expect speakers to mix languages, keep the original audio available. A good pattern is to duck the original audio while translated audio is playing rather than fully muting it. You can also offer source-language captions or an original/translated audio mix control.++### Supported languages++Realtime Translation currently supports 13 target output languages: Spanish, Portuguese, French, Japanese, Russian, Chinese, German, Korean, Hindi, Indonesian, Vietnamese, Italian, and English.++The model currently supports over 70 input languages. It can dynamically detect and translate from Arabic, Afrikaans, Azerbaijani, Belarusian, Bengali, Bosnian, Bulgarian, Catalan, Chinese, Croatian, Czech, Danish, Dutch, Dzongkha, English, Esperanto, Estonian, Basque, Persian / Farsi, Finnish, Filipino, French, Galician, German, Greek, Gujarati, Haitian Creole, Hawaiian, Hebrew, Hindi, Hungarian, Armenian, Indonesian, Italian, Japanese, Javanese, Georgian, Kazakh, Korean, Kurdish, Latin, Latvian, Lithuanian, Macedonian, Malay, Malayalam, Maori, Mongolian, Burmese / Myanmar, Nepali, Norwegian, Nynorsk, Polish, Portuguese, Punjabi, Romanian, Russian, Serbian, Shona, Slovak, Slovenian, Albanian, Spanish, Swahili, Swedish, Tagalog, Telugu, Thai, Turkish, Ukrainian, Uzbek, Vietnamese, Welsh, and Yoruba.++### Evaluate meaning and latency separately++For evaluations, keep the source audio, generated translated audio, generated transcript, and reference text together for each run. You want to be able to answer three questions later:++- What did the model hear?+- What did it say?+- What should it have said?++Use the best human reference you can get, such as human-edited subtitles, a professional interpreter transcript, a call transcript reviewed by a bilingual speaker, or a human dub of the source material. Automatic captions and transcripts are useful for quick smoke tests, but they are weaker as the source of truth.++If your reference has timestamps, use them. Time-aligned subtitles or transcripts let you evaluate not just translation quality, but also when the translated audio and captions arrived.++Score translations by meaning, not exact wording. A good translation may use different words, so evaluate whether the important facts, nuance, entities, numbers, and tone are preserved. Track the full distribution of misses, not just the average score, because a few bad errors can matter a lot in live translation.++Traditional text metrics like BLEU can help with quick comparisons, but they are a weak proxy for speech-to-speech quality because they miss semantic similarity.++Measure latency separately from quality. Track source speech to translated audio and source speech to displayed captions. Only use segments where the translation is meaningfully aligned when calculating delay; otherwise, bad matches can make timing data misleading.++Finally, review low-scoring examples manually. Listen to the original source, the generated translation, and the reference segment side by side. This is where you catch the issues aggregate scores miss, especially names, numbers, partial translations, tone, and cases where the model skipped or delayed content.++For a deeper treatment of Realtime evaluation, see the [Realtime eval guide](https://developers.openai.com/cookbook/examples/realtime_eval_guide).++## Conclusion++Realtime Translation changes what it means to build applications for multilingual users. It turns live interpretation into a native part of the product experience, so multilingual conversations can feel less like using a translation tool and more like simply understanding each other in real time. With a dedicated translation session, audio can move through browsers, phone calls, and video rooms as part of the experience itself.++By making language a smaller barrier, these applications can help more people participate, collaborate, and connect.diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/.dockerignore b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/.dockerignorenew file mode 100644index 00000000..02970e6d--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/.dockerignore@@ -0,0 +1,6 @@+.env+.env.*+!.env.example+.git+node_modules+npm-debug.log*diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/.env.example b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/.env.examplenew file mode 100644index 00000000..0ea04335--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/.env.example@@ -0,0 +1,4 @@+OPENAI_API_KEY=+OPENAI_TRANSLATION_MODEL=gpt-realtime-translate+OPENAI_INPUT_TRANSCRIPTION_MODEL=gpt-realtime-whisper+PORT=5173diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/.gitignore b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/.gitignorenew file mode 100644index 00000000..49be0688--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/.gitignore@@ -0,0 +1,4 @@+.env+.env.*+!.env.example+node_modules/diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/Dockerfile b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/Dockerfilenew file mode 100644index 00000000..8c654853--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/Dockerfile@@ -0,0 +1,11 @@+FROM node:20-slim++WORKDIR /app+ENV NODE_ENV=production++COPY --chown=node:node package.json ./+COPY --chown=node:node src ./src++USER node+EXPOSE 5173+CMD ["node", "src/server.js"]diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/README.md b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/README.mdnew file mode 100644index 00000000..1615ac39--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/README.md@@ -0,0 +1,74 @@+# Browser Realtime Translation Demo++This is a small browser demo for one-way live translation from tab audio. The+server creates a short-lived OpenAI Realtime Translation client secret, and the+browser uses WebRTC to send captured tab audio and play translated speech with+captions.++## Setup++Create a local `.env` file in this demo folder using `.env.example` as the list+of required variables.++Required:++```bash+OPENAI_API_KEY=your-openai-api-key+```++Optional:++```bash+OPENAI_TRANSLATION_MODEL=gpt-realtime-translate+OPENAI_INPUT_TRANSCRIPTION_MODEL=gpt-realtime-whisper+PORT=5173+HOST=127.0.0.1+```++## Run++From the cookbook repo root:++```bash+cd examples/voice_solutions/realtime_translation_guide/browser-translation-demo+npm install+npm run dev+```++Open the local URL printed by the server. Choose a browser tab with audio, pick+the language you want to hear, and start translation.++## Audio mix++The app includes an Audio mix slider for balancing translated speech with the+original tab audio. By default, it plays 85% translated audio and 15% original+audio, matching the LiveKit demo.++When the selected source is a browser tab, the demo still requests+`suppressLocalAudioPlayback` in the `getDisplayMedia()` audio constraints.+If the browser honors that setting, the slider controls both the translated+audio and the original audio playback from this app. If the browser does not+support local playback suppression, the source tab may continue playing outside+the slider, so lower or mute the source tab if you hear too much original audio.++## Validation++From the cookbook repo root:++```bash+cd examples/voice_solutions/realtime_translation_guide/browser-translation-demo+npm test+```++To run a live API smoke test:++```bash+npm run smoke+```++## Notes++- The browser uses `getDisplayMedia()` so the user explicitly chooses the source+ tab.+- WebRTC handles browser audio transport, so the browser does not need to+ resample tab audio or manually send PCM chunks.diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/package.json b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/package.jsonnew file mode 100644index 00000000..51a653f5--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/package.json@@ -0,0 +1,15 @@+{+ "name": "browser-realtime-translation-demo",+ "version": "0.1.0",+ "private": true,+ "type": "module",+ "engines": {+ "node": ">=20"+ },+ "scripts": {+ "start": "node src/server.js",+ "dev": "node --watch src/server.js",+ "test": "node --test test/*.test.js",+ "smoke": "node scripts/smoke-realtime.mjs"+ }+}diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/scripts/smoke-realtime.mjs b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/scripts/smoke-realtime.mjsnew file mode 100644index 00000000..d63642a7--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/scripts/smoke-realtime.mjs@@ -0,0 +1,267 @@+import { spawnSync } from "node:child_process";+import { existsSync, mkdtempSync, readFileSync, rmSync } from "node:fs";+import { tmpdir } from "node:os";+import path from "node:path";++import {+ DEFAULT_TRANSLATION_MODEL,+ createClientSecret,+} from "../src/session.js";+import { loadEnvFiles } from "../src/server.js";+import { PCM16_200MS_CHUNK_BYTES } from "../src/public/audio-chunks.js";++const TRANSLATION_WS_URL = "wss://api.openai.com/v1/realtime/translations";+const TARGET_LANGUAGE = process.env.SMOKE_TARGET_LANGUAGE ?? "es";+const PHRASE =+ process.env.SMOKE_PHRASE ??+ "Hello, this is a browser tab audio translation test.";++loadEnvFiles(process.env, process.cwd());++if (!process.env.OPENAI_API_KEY) {+ throw new Error("OPENAI_API_KEY is not configured.");+}++const session = await createClientSecret({+ apiKey: process.env.OPENAI_API_KEY,+ targetLanguage: TARGET_LANGUAGE,+ model: process.env.OPENAI_TRANSLATION_MODEL ?? DEFAULT_TRANSLATION_MODEL,+});++const audio = createSpeechPcm16(PHRASE) ?? Buffer.alloc(24_000 * 2);+const usedSpeech = audio.some((byte) => byte !== 0);+const result = await runWebSocketSmoke({ session, audio, requireOutput: usedSpeech });++console.log(+ JSON.stringify(+ {+ ok: true,+ mode: usedSpeech ? "speech" : "silence",+ targetLanguage: session.targetLanguage,+ sessionCreated: result.sessionCreated,+ outputAudioDeltas: result.outputAudioDeltas,+ outputTranscriptPreview: result.outputTranscript.slice(0, 160),+ },+ null,+ 2,+ ),+);++async function runWebSocketSmoke({ session, audio, requireOutput }) {+ return new Promise((resolve, reject) => {+ const url = new URL(TRANSLATION_WS_URL);+ url.searchParams.set("model", session.model);++ const ws = new WebSocket(url, [+ `openai-insecure-api-key.${session.client_secret}`,+ "realtime",+ ]);++ const state = {+ sessionCreated: false,+ sessionUpdateSent: false,+ sessionUpdated: false,+ outputAudioDeltas: 0,+ outputTranscript: "",+ sending: false,+ sent: false,+ };+ let settled = false;++ const finish = (error) => {+ if (settled) {+ return;+ }+ settled = true;+ clearTimeout(timeout);+ ws.close();+ if (error) {+ reject(error);+ return;+ }+ resolve(state);+ };++ const timeout = setTimeout(() => {+ if (!state.sessionCreated) {+ finish(new Error("Realtime session was not created before timeout."));+ return;+ }+ if (requireOutput && state.outputAudioDeltas === 0 && !state.outputTranscript) {+ finish(new Error("Realtime session produced no translated output before timeout."));+ return;+ }+ finish();+ }, requireOutput ? 25_000 : 5_000);++ ws.addEventListener("error", () => {+ finish(new Error("Realtime WebSocket error."));+ });++ ws.addEventListener("open", () => {+ if (session.session_update) {+ ws.send(JSON.stringify(session.session_update));+ state.sessionUpdateSent = true;+ }+ });++ ws.addEventListener("message", async (message) => {+ let event;+ try {+ event = JSON.parse(await messageToText(message.data));+ } catch (error) {+ finish(error);+ return;+ }++ if (event.type === "error") {+ finish(new Error(JSON.stringify(event.error ?? event)));+ return;+ }++ if (event.type === "session.created") {+ state.sessionCreated = true;+ if (!session.session_update) {+ void sendAudioAndMaybeFinish(ws, audio, state, requireOutput, finish);+ }+ }++ if (event.type === "session.updated") {+ state.sessionUpdated = true;+ void sendAudioAndMaybeFinish(ws, audio, state, requireOutput, finish);+ }++ if (+ (event.type === "session.output_audio.delta" ||+ event.type === "response.output_audio.delta") &&+ typeof event.delta === "string"+ ) {+ state.outputAudioDeltas += 1;+ }++ if (+ (event.type === "session.output_transcript.delta" ||+ event.type === "response.output_audio_transcript.delta") &&+ typeof event.delta === "string"+ ) {+ state.outputTranscript += event.delta;+ }++ if (+ state.sessionCreated &&+ state.sent &&+ (!requireOutput || state.outputAudioDeltas > 0 || state.outputTranscript)+ ) {+ finish();+ }+ });+ });+}++async function sendAudioAndMaybeFinish(ws, audio, state, requireOutput, finish) {+ if (state.sending || state.sent) {+ return;+ }+ state.sending = true;+ try {+ await sendAudio(ws, audio);+ state.sent = true;+ if (!requireOutput || state.outputAudioDeltas > 0 || state.outputTranscript) {+ finish();+ }+ } catch (error) {+ finish(error);+ }+}++async function sendAudio(ws, audio) {+ const chunkBytes = PCM16_200MS_CHUNK_BYTES;+ for (let offset = 0; offset < audio.length; offset += chunkBytes) {+ const chunk = audio.subarray(offset, offset + chunkBytes);+ ws.send(+ JSON.stringify({+ type: "session.input_audio_buffer.append",+ audio: chunk.toString("base64"),+ }),+ );+ await delay(100);+ }++ const silence = Buffer.alloc(chunkBytes);+ for (let i = 0; i < 12; i += 1) {+ ws.send(+ JSON.stringify({+ type: "session.input_audio_buffer.append",+ audio: silence.toString("base64"),+ }),+ );+ await delay(100);+ }+}++function createSpeechPcm16(phrase) {+ if (!existsSync("/usr/bin/say") || !existsSync("/usr/bin/afconvert")) {+ return null;+ }++ const dir = mkdtempSync(path.join(tmpdir(), "browser-translation-smoke-"));+ const aiffPath = path.join(dir, "speech.aiff");+ const wavPath = path.join(dir, "speech.wav");++ try {+ const say = spawnSync("/usr/bin/say", ["-v", "Samantha", "-o", aiffPath, phrase], {+ stdio: "ignore",+ });+ if (say.status !== 0) {+ return null;+ }++ const convert = spawnSync(+ "/usr/bin/afconvert",+ ["-f", "WAVE", "-d", "LEI16@24000", aiffPath, wavPath],+ { stdio: "ignore" },+ );+ if (convert.status !== 0) {+ return null;+ }++ return extractWavData(readFileSync(wavPath));+ } finally {+ rmSync(dir, { force: true, recursive: true });+ }+}++function extractWavData(wav) {+ let offset = 12;+ while (offset + 8 <= wav.length) {+ const chunkId = wav.toString("ascii", offset, offset + 4);+ const chunkSize = wav.readUInt32LE(offset + 4);+ const dataStart = offset + 8;+ const dataEnd = dataStart + chunkSize;+ if (chunkId === "data") {+ return wav.subarray(dataStart, dataEnd);+ }+ offset = dataEnd + (chunkSize % 2);+ }+ throw new Error("Generated WAV did not contain a data chunk.");+}++async function messageToText(data) {+ if (typeof data === "string") {+ return data;+ }+ if (data instanceof ArrayBuffer) {+ return Buffer.from(data).toString("utf8");+ }+ if (ArrayBuffer.isView(data)) {+ return Buffer.from(data.buffer, data.byteOffset, data.byteLength).toString("utf8");+ }+ if (typeof data?.text === "function") {+ return data.text();+ }+ return String(data);+}++function delay(ms) {+ return new Promise((resolve) => setTimeout(resolve, ms));+}diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/app.js b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/app.jsnew file mode 100644index 00000000..eddc2c3a--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/app.js@@ -0,0 +1,405 @@+import { buildAudioMixState } from "/audio-mix.js";+import { buildDisplayMediaOptions } from "/capture-options.js";++const TRANSLATION_CALL_URL =+ "https://api.openai.com/v1/realtime/translations/calls";++const OUTPUT_TRANSCRIPT_EVENTS = new Set(["session.output_transcript.delta"]);+const INPUT_TRANSCRIPT_EVENTS = new Set(["session.input_transcript.delta"]);++const targetLanguage = document.querySelector("#targetLanguage");+const startButton = document.querySelector("#startButton");+const stopButton = document.querySelector("#stopButton");+const audioMix = document.querySelector("#audioMix");+const mixValue = document.querySelector("#mixValue");+const originalMixLabel = document.querySelector("#originalMixLabel");+const translatedMixLabel = document.querySelector("#translatedMixLabel");+const statusDot = document.querySelector("#statusDot");+const statusText = document.querySelector("#statusText");+const inputMeter = document.querySelector("#inputMeter");+const queueProgress = document.querySelector("#queueProgress");+const translatedTranscript = document.querySelector("#translatedTranscript");+const eventLog = document.querySelector("#eventLog");+const captureState = document.querySelector("#captureState");+const chunksSent = document.querySelector("#chunksSent");+const activeInputFrames = document.querySelector("#activeInputFrames");+const peakInputLevel = document.querySelector("#peakInputLevel");+const outputAudioDeltas = document.querySelector("#outputAudioDeltas");+const transcriptDeltas = document.querySelector("#transcriptDeltas");+const lastEventType = document.querySelector("#lastEventType");++let peerConnection = null;+let dataChannel = null;+let captureStream = null;+let meterContext = null;+let meterSource = null;+let meterAnalyser = null;+let meterTimer = null;+let sourceAudio = null;+let translatedAudio = null;+let diagnostics = createEmptyDiagnostics();++applyAudioMix();++audioMix.addEventListener("input", () => {+ applyAudioMix();+});++startButton.addEventListener("click", async () => {+ clearTranscript();+ resetDiagnostics();+ setControls({ running: true });+ setStatus("Pick a browser tab with audio", "idle");++ try {+ captureStream = await captureTabAudio();+ startSourceAudio(captureStream);+ startInputMeter(captureStream);++ setStatus("Creating Realtime Translation session", "idle");+ const session = await createSession(targetLanguage.value);++ setStatus("Connecting WebRTC", "idle");+ await connectRealtimeTranslation(session, captureStream);++ setStatus("Translating tab audio", "live");+ } catch (error) {+ logEvent("error", error instanceof Error ? error.message : String(error));+ await stop("Stopped after startup error", "error");+ }+});++stopButton.addEventListener("click", async () => {+ await stop("Stopped", "idle");+});++async function createSession(language) {+ const response = await fetch("/session", {+ method: "POST",+ headers: { "Content-Type": "application/json" },+ body: JSON.stringify({ targetLanguage: language }),+ });++ const body = await response.json();+ if (!response.ok) {+ throw new Error(body.error ?? "Failed to create session.");+ }++ return body;+}++async function connectRealtimeTranslation(session, stream) {+ peerConnection = new RTCPeerConnection();+ dataChannel = peerConnection.createDataChannel("oai-events");++ translatedAudio = new Audio();+ translatedAudio.autoplay = true;+ translatedAudio.playsInline = true;+ applyAudioMix();++ peerConnection.onconnectionstatechange = () => {+ diagnostics.connectionState = peerConnection?.connectionState ?? "closed";+ chunksSent.textContent = diagnostics.connectionState;+ logEvent("webrtc.connection", diagnostics.connectionState);+ updateDiagnostics();+ };++ peerConnection.oniceconnectionstatechange = () => {+ diagnostics.iceConnectionState =+ peerConnection?.iceConnectionState ?? "closed";+ queueProgress.value =+ diagnostics.iceConnectionState === "connected" ||+ diagnostics.iceConnectionState === "completed"+ ? 1+ : 0;+ updateDiagnostics();+ };++ peerConnection.ontrack = ({ streams }) => {+ diagnostics.remoteAudioTracks += 1;+ outputAudioDeltas.textContent = String(diagnostics.remoteAudioTracks);+ translatedAudio.srcObject = streams[0];+ applyAudioMix();+ void translatedAudio.play().catch((error) => {+ logEvent("audio.play", error.message);+ });+ logEvent("remote.audio", "track received");+ updateDiagnostics();+ };++ dataChannel.onopen = () => {+ diagnostics.dataChannelState = dataChannel?.readyState ?? "open";+ activeInputFrames.textContent = diagnostics.dataChannelState;+ logEvent("datachannel.open", "ok");+ updateDiagnostics();+ };+ dataChannel.onclose = () => {+ diagnostics.dataChannelState = "closed";+ activeInputFrames.textContent = "closed";+ logEvent("datachannel.close", "closed");+ updateDiagnostics();+ };+ dataChannel.onerror = () => {+ logEvent("datachannel.error", "error");+ };+ dataChannel.onmessage = handleRealtimeEvent;++ for (const track of stream.getAudioTracks()) {+ peerConnection.addTrack(track, stream);+ }++ const offer = await peerConnection.createOffer();+ await peerConnection.setLocalDescription(offer);++ const sdpResponse = await fetch(TRANSLATION_CALL_URL, {+ method: "POST",+ headers: {+ Authorization: `Bearer ${session.client_secret}`,+ "Content-Type": "application/sdp",+ },+ body: offer.sdp,+ });++ const answerSdp = await sdpResponse.text();+ if (!sdpResponse.ok) {+ throw new Error(answerSdp);+ }++ await peerConnection.setRemoteDescription({+ type: "answer",+ sdp: answerSdp,+ });++ logEvent("webrtc.offer", `connected for ${session.targetLanguage}`);+}++async function captureTabAudio() {+ if (!navigator.mediaDevices?.getDisplayMedia) {+ throw new Error("This browser does not support tab audio capture.");+ }++ const supportedConstraints =+ navigator.mediaDevices.getSupportedConstraints?.() ?? {};+ const stream = await navigator.mediaDevices.getDisplayMedia(+ buildDisplayMediaOptions(supportedConstraints),+ );++ const audioTracks = stream.getAudioTracks();+ const videoTracks = stream.getVideoTracks();++ if (audioTracks.length === 0) {+ stream.getTracks().forEach((track) => track.stop());+ throw new Error("No tab audio was shared. Pick a Chrome tab and enable tab audio.");+ }++ audioTracks[0].addEventListener(+ "ended",+ () => {+ void stop("Tab audio sharing ended", "idle");+ },+ { once: true },+ );++ const audioSettings = audioTracks[0].getSettings?.() ?? {};+ const suppressed =+ typeof audioSettings.suppressLocalAudioPlayback === "boolean"+ ? String(audioSettings.suppressLocalAudioPlayback)+ : "unknown";+ captureState.textContent = `audio=${audioTracks[0].readyState}, video=${videoTracks.length}, suppressed=${suppressed}`;+ logEvent(+ "capture.started",+ `audio tracks=${audioTracks.length}, video tracks=${videoTracks.length}, suppressed=${suppressed}`,+ );++ return stream;+}++function startInputMeter(stream) {+ meterContext = new AudioContext();+ meterSource = meterContext.createMediaStreamSource(stream);+ meterAnalyser = meterContext.createAnalyser();+ meterAnalyser.fftSize = 2048;+ meterSource.connect(meterAnalyser);++ const samples = new Float32Array(meterAnalyser.fftSize);+ meterTimer = window.setInterval(() => {+ meterAnalyser.getFloatTimeDomainData(samples);+ let sum = 0;+ for (const sample of samples) {+ sum += sample * sample;+ }+ const rms = Math.sqrt(sum / samples.length);+ inputMeter.value = Math.min(1, rms * 12);+ diagnostics.peakInputLevel = Math.max(diagnostics.peakInputLevel, rms);+ peakInputLevel.textContent = diagnostics.peakInputLevel.toFixed(3);+ }, 100);+}++function startSourceAudio(stream) {+ sourceAudio = new Audio();+ sourceAudio.autoplay = true;+ sourceAudio.playsInline = true;+ sourceAudio.srcObject = stream;+ applyAudioMix();++ void sourceAudio.play().catch((error) => {+ logEvent("source.audio.play", error.message);+ });+}++function applyAudioMix() {+ const mix = buildAudioMixState(audioMix.value);++ audioMix.value = String(mix.translatedPercent);+ mixValue.textContent = mix.valueLabel;+ originalMixLabel.textContent = mix.originalLabel;+ translatedMixLabel.textContent = mix.translatedLabel;++ if (sourceAudio) {+ sourceAudio.volume = mix.originalVolume;+ }+ if (translatedAudio) {+ translatedAudio.volume = mix.translatedVolume;+ }+}++function handleRealtimeEvent(message) {+ let event;+ try {+ event = JSON.parse(message.data);+ } catch {+ logEvent("message", "Received non-JSON data channel message.");+ return;+ }++ diagnostics.lastEventType = event.type;+ lastEventType.textContent = event.type;++ if (event.type === "error") {+ logEvent("error", JSON.stringify(event.error ?? event));+ return;+ }++ if (OUTPUT_TRANSCRIPT_EVENTS.has(event.type) && typeof event.delta === "string") {+ diagnostics.transcriptDeltas += 1;+ appendTranslatedText(event.delta);+ updateDiagnostics();+ return;+ }++ if (INPUT_TRANSCRIPT_EVENTS.has(event.type) && typeof event.delta === "string") {+ logEvent("input", event.delta);+ return;+ }++ if (+ event.type === "session.created" ||+ event.type === "session.updated" ||+ event.type === "output_audio_buffer.started"+ ) {+ logEvent(event.type, "ok");+ }++ updateDiagnostics();+}++async function stop(message, state = "idle") {+ if (meterTimer) {+ window.clearInterval(meterTimer);+ meterTimer = null;+ }++ meterSource?.disconnect();+ meterAnalyser?.disconnect();+ meterSource = null;+ meterAnalyser = null;++ if (meterContext?.state !== "closed") {+ await meterContext?.close();+ }+ meterContext = null;++ dataChannel?.close();+ dataChannel = null;++ peerConnection?.close();+ peerConnection = null;++ if (sourceAudio) {+ sourceAudio.pause();+ sourceAudio.srcObject = null;+ }+ sourceAudio = null;++ captureStream?.getTracks().forEach((track) => track.stop());+ captureStream = null;++ if (translatedAudio) {+ translatedAudio.pause();+ translatedAudio.srcObject = null;+ }+ translatedAudio = null;++ inputMeter.value = 0;+ queueProgress.value = 0;+ setControls({ running: false });+ setStatus(message, state);+}++function setControls({ running }) {+ startButton.disabled = running;+ stopButton.disabled = !running;+ targetLanguage.disabled = running;+}++function setStatus(message, state) {+ statusText.textContent = message;+ statusDot.className = `status-dot ${state === "live" ? "live" : ""} ${+ state === "error" ? "error" : ""+ }`;+}++function appendTranslatedText(text) {+ translatedTranscript.textContent += text;+ translatedTranscript.scrollTop = translatedTranscript.scrollHeight;+}++function clearTranscript() {+ translatedTranscript.textContent = "";+}++function createEmptyDiagnostics() {+ return {+ connectionState: "new",+ dataChannelState: "connecting",+ iceConnectionState: "new",+ lastEventType: "none",+ peakInputLevel: 0,+ remoteAudioTracks: 0,+ transcriptDeltas: 0,+ };+}++function resetDiagnostics() {+ diagnostics = createEmptyDiagnostics();+ captureState.textContent = "Starting";+ eventLog.textContent = "";+ updateDiagnostics();+}++function updateDiagnostics() {+ chunksSent.textContent = diagnostics.connectionState;+ activeInputFrames.textContent = diagnostics.dataChannelState;+ peakInputLevel.textContent = diagnostics.peakInputLevel.toFixed(3);+ outputAudioDeltas.textContent = String(diagnostics.remoteAudioTracks);+ transcriptDeltas.textContent = String(diagnostics.transcriptDeltas);+ lastEventType.textContent = diagnostics.lastEventType;+}++function logEvent(type, detail) {+ const entry = document.createElement("div");+ entry.className = "log-entry";+ entry.textContent = `[${new Date().toLocaleTimeString()}] ${type}: ${detail}`;+ eventLog.append(entry);+ eventLog.scrollTop = eventLog.scrollHeight;+}diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/audio-chunks.js b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/audio-chunks.jsnew file mode 100644index 00000000..658aa98d--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/audio-chunks.js@@ -0,0 +1,45 @@+export const PCM16_200MS_CHUNK_BYTES = 4_800 * 2;++export class Pcm16Chunker {+ constructor(chunkBytes) {+ if (!Number.isInteger(chunkBytes) || chunkBytes <= 0) {+ throw new Error("chunkBytes must be a positive integer.");+ }+ this.chunkBytes = chunkBytes;+ this.pending = new Uint8Array(0);+ }++ get pendingBytes() {+ return this.pending.length;+ }++ push(buffer) {+ const bytes = buffer instanceof Uint8Array ? buffer : new Uint8Array(buffer);+ const combined = new Uint8Array(this.pending.length + bytes.length);+ combined.set(this.pending, 0);+ combined.set(bytes, this.pending.length);++ const chunks = [];+ let offset = 0;+ while (offset + this.chunkBytes <= combined.length) {+ chunks.push(combined.slice(offset, offset + this.chunkBytes));+ offset += this.chunkBytes;+ }++ this.pending = combined.slice(offset);+ return chunks;+ }++ flush() {+ if (this.pending.length === 0) {+ return null;+ }+ const flushed = this.pending;+ this.pending = new Uint8Array(0);+ return flushed;+ }++ reset() {+ this.pending = new Uint8Array(0);+ }+}diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/audio-mix.js b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/audio-mix.jsnew file mode 100644index 00000000..82083b17--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/audio-mix.js@@ -0,0 +1,24 @@+export const DEFAULT_TRANSLATED_MIX = 85;++export function clampTranslatedMix(value) {+ const parsed = Number.parseInt(String(value), 10);+ if (!Number.isFinite(parsed)) {+ return DEFAULT_TRANSLATED_MIX;+ }+ return Math.min(100, Math.max(0, parsed));+}++export function buildAudioMixState(value) {+ const translatedPercent = clampTranslatedMix(value);+ const originalPercent = 100 - translatedPercent;++ return {+ translatedPercent,+ originalPercent,+ translatedVolume: translatedPercent / 100,+ originalVolume: originalPercent / 100,+ valueLabel: `${translatedPercent}% translated`,+ translatedLabel: `Translated ${translatedPercent}%`,+ originalLabel: `Original ${originalPercent}%`,+ };+}diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/capture-options.js b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/capture-options.jsnew file mode 100644index 00000000..5b91d893--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/capture-options.js@@ -0,0 +1,22 @@+export function buildDisplayMediaOptions(supportedConstraints = {}) {+ const audio = {+ echoCancellation: false,+ noiseSuppression: false,+ autoGainControl: false,+ };++ if (supportedConstraints.suppressLocalAudioPlayback) {+ audio.suppressLocalAudioPlayback = true;+ }++ return {+ preferCurrentTab: false,+ selfBrowserSurface: "exclude",+ surfaceSwitching: "include",+ systemAudio: "include",+ video: {+ displaySurface: "browser",+ },+ audio,+ };+}diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/index.html b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/index.htmlnew file mode 100644index 00000000..ddcbe70c--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/index.html@@ -0,0 +1,143 @@+<!doctype html>+<html lang="en">+ <head>+ <meta charset="utf-8" />+ <meta name="viewport" content="width=device-width, initial-scale=1" />+ <title>In-browser Realtime Translation</title>+ <link rel="stylesheet" href="/styles.css" />+ </head>+ <body>+ <main class="shell">+ <section class="hero">+ <div>+ <p class="eyebrow">Browser demo</p>+ <h1>In-browser Realtime Translation</h1>+ <p class="summary">+ Capture audio from a browser tab, send it to Realtime Translation+ over WebRTC, and play translated speech back locally.+ </p>+ </div>+ <div class="status-card" aria-live="polite">+ <p class="panel-label">Session status</p>+ <div class="status-panel">+ <span class="status-dot" id="statusDot"></span>+ <span id="statusText">Stopped</span>+ </div>+ </div>+ </section>++ <section class="control-dock" aria-label="Translation controls">+ <div class="dock-section field">+ <label for="targetLanguage">Target language</label>+ <select id="targetLanguage">+ <option value="es">Spanish</option>+ <option value="pt">Portuguese</option>+ <option value="fr">French</option>+ <option value="ja">Japanese</option>+ <option value="ru">Russian</option>+ <option value="zh">Chinese</option>+ <option value="de">German</option>+ <option value="ko">Korean</option>+ <option value="hi">Hindi</option>+ <option value="id">Indonesian</option>+ <option value="vi">Vietnamese</option>+ <option value="it">Italian</option>+ <option value="en">English</option>+ </select>+ </div>++ <div class="dock-section mix-control">+ <div class="mix-heading">+ <label class="range-label" for="audioMix">Audio mix</label>+ <span id="mixValue">85% translated</span>+ </div>+ <input+ id="audioMix"+ type="range"+ min="0"+ max="100"+ step="1"+ value="85"+ />+ <div class="mix-scale" aria-hidden="true">+ <span id="originalMixLabel">Original 15%</span>+ <span id="translatedMixLabel">Translated 85%</span>+ </div>+ </div>++ <div class="dock-section button-row">+ <button id="startButton" type="button">+ Choose tab to start translating+ </button>+ <button id="stopButton" type="button" class="secondary" disabled>+ Stop+ </button>+ </div>+ </section>++ <section class="meters" aria-label="Audio status">+ <div class="meter-card">+ <span>Captured tab audio</span>+ <meter id="inputMeter" min="0" max="1" value="0"></meter>+ </div>+ <div class="meter-card">+ <span>WebRTC connection</span>+ <progress id="queueProgress" max="1" value="0"></progress>+ </div>+ </section>++ <section class="workspace">+ <article class="guide-card">+ <h2>How to test</h2>+ <ol>+ <li>Open any browser tab that is playing audio.</li>+ <li>Return here and choose that tab from the browser picker.</li>+ <li>Enable tab audio in the picker, then listen for translation.</li>+ </ol>+ <dl class="diagnostics">+ <div>+ <dt>Capture</dt>+ <dd id="captureState">Not started</dd>+ </div>+ <div>+ <dt>WebRTC state</dt>+ <dd id="chunksSent">new</dd>+ </div>+ <div>+ <dt>Data channel</dt>+ <dd id="activeInputFrames">connecting</dd>+ </div>+ <div>+ <dt>Peak level</dt>+ <dd id="peakInputLevel">0.000</dd>+ </div>+ <div>+ <dt>Remote audio</dt>+ <dd><span id="outputAudioDeltas">0</span> tracks</dd>+ </div>+ <div>+ <dt>Transcript</dt>+ <dd><span id="transcriptDeltas">0</span> deltas</dd>+ </div>+ <div>+ <dt>Last event</dt>+ <dd id="lastEventType">none</dd>+ </div>+ </dl>+ </article>++ <article class="transcript-card">+ <h2>Translated transcript</h2>+ <div id="translatedTranscript" class="transcript" aria-live="polite"></div>+ </article>++ <article class="log-card">+ <h2>Event log</h2>+ <div id="eventLog" class="log" aria-live="polite"></div>+ </article>+ </section>+ </main>++ <script src="/app.js" type="module"></script>+ </body>+</html>diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/pcm16-capture.worklet.js b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/pcm16-capture.worklet.jsnew file mode 100644index 00000000..eceb3917--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/pcm16-capture.worklet.js@@ -0,0 +1,64 @@+class Pcm16CaptureProcessor extends AudioWorkletProcessor {+ constructor(options) {+ super();+ this.targetSampleRate = options.processorOptions?.targetSampleRate ?? 24000;+ }++ process(inputs) {+ const input = inputs[0]?.[0];+ if (!input || input.length === 0) {+ return true;+ }++ const resampled =+ sampleRate === this.targetSampleRate+ ? input+ : resampleLinear(input, sampleRate, this.targetSampleRate);+ const pcm = floatToPcm16(resampled);+ this.port.postMessage(+ {+ type: "pcm16",+ buffer: pcm.buffer,+ rms: rms(input),+ },+ [pcm.buffer],+ );++ return true;+ }+}++function resampleLinear(input, sourceRate, targetRate) {+ const ratio = sourceRate / targetRate;+ const outputLength = Math.max(1, Math.round(input.length / ratio));+ const output = new Float32Array(outputLength);++ for (let i = 0; i < outputLength; i += 1) {+ const sourceIndex = i * ratio;+ const leftIndex = Math.floor(sourceIndex);+ const rightIndex = Math.min(leftIndex + 1, input.length - 1);+ const weight = sourceIndex - leftIndex;+ output[i] = input[leftIndex] * (1 - weight) + input[rightIndex] * weight;+ }++ return output;+}++function floatToPcm16(input) {+ const output = new Int16Array(input.length);+ for (let i = 0; i < input.length; i += 1) {+ const sample = Math.max(-1, Math.min(1, input[i]));+ output[i] = sample < 0 ? sample * 0x8000 : sample * 0x7fff;+ }+ return output;+}++function rms(input) {+ let sum = 0;+ for (let i = 0; i < input.length; i += 1) {+ sum += input[i] * input[i];+ }+ return Math.sqrt(sum / input.length);+}++registerProcessor("pcm16-capture", Pcm16CaptureProcessor);diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/source-speech.wav b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/source-speech.wavnew file mode 100644index 00000000..52c8f010Binary files /dev/null and b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/source-speech.wav differdiff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/source.html b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/source.htmlnew file mode 100644index 00000000..7d8223f2--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/source.html@@ -0,0 +1,75 @@+<!doctype html>+<html lang="en">+ <head>+ <meta charset="utf-8" />+ <meta name="viewport" content="width=device-width, initial-scale=1" />+ <title>Translation Source Audio</title>+ <link rel="stylesheet" href="/styles.css" />+ <style>+ .source-shell {+ width: min(760px, calc(100vw - 32px));+ margin: 0 auto;+ padding: 48px 0;+ }++ .source-card {+ padding: 20px;+ border: 1px solid var(--line);+ border-radius: 8px;+ background: var(--panel);+ }++ .source-actions {+ display: flex;+ gap: 12px;+ flex-wrap: wrap;+ }++ audio {+ width: 100%;+ margin: 18px 0 8px;+ }+ </style>+ </head>+ <body>+ <main class="source-shell">+ <section class="source-card">+ <p class="eyebrow">Test source tab</p>+ <h1>English source audio</h1>+ <p class="summary">+ Press Play, leave this tab speaking, then share this Chrome tab from+ the translation app with tab audio enabled. This page uses a real+ audio element so Chrome tab capture receives media audio.+ </p>+ <audio id="sourceAudio" src="/source-speech.wav" controls loop preload="auto"></audio>+ <div class="source-actions">+ <button id="playButton" type="button">Play looping audio file</button>+ <button id="stopSourceButton" type="button" class="secondary">Stop</button>+ </div>+ <p id="lineText" class="note" aria-live="polite"></p>+ </section>+ </main>++ <script>+ const sourceAudio = document.querySelector("#sourceAudio");+ const playButton = document.querySelector("#playButton");+ const stopSourceButton = document.querySelector("#stopSourceButton");+ const lineText = document.querySelector("#lineText");++ playButton.addEventListener("click", async () => {+ await sourceAudio.play();+ lineText.textContent = "Playing the looping source audio file.";+ });++ stopSourceButton.addEventListener("click", () => {+ sourceAudio.pause();+ sourceAudio.currentTime = 0;+ lineText.textContent = "Stopped.";+ });++ sourceAudio.addEventListener("play", () => {+ lineText.textContent = "Playing. Share this tab and enable tab audio.";+ });+ </script>+ </body>+</html>diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/styles.css b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/styles.cssnew file mode 100644index 00000000..86a3ec19--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/public/styles.css@@ -0,0 +1,444 @@+:root {+ color-scheme: light;+ --bg: #ffffff;+ --panel: #ffffff;+ --panel-soft: #f7f7f5;+ --ink: #0d0d0d;+ --muted: #6f6f6a;+ --soft: #9a9a95;+ --line: #e7e7e4;+ --line-strong: #d7d7d2;+ --accent: #c45f26;+ --accent-strong: #9e4717;+ --success: #16824a;+ --danger: #b43224;+ --shadow: 0 24px 70px rgb(0 0 0 / 6%);+}++* {+ box-sizing: border-box;+}++html {+ background: var(--bg);+}++body {+ margin: 0;+ min-height: 100vh;+ background:+ linear-gradient(180deg, rgb(247 247 245 / 85%) 0, #fff 220px),+ var(--bg);+ color: var(--ink);+ font-family:+ ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",+ sans-serif;+}++button,+input,+select {+ font: inherit;+}++.shell {+ width: min(1000px, calc(100vw - 40px));+ margin: 0 auto;+ padding: 22px 0 44px;+}++.hero {+ display: grid;+ grid-template-columns: minmax(0, 1fr) auto;+ align-items: end;+ gap: 24px;+ margin-bottom: 18px;+}++.eyebrow,+.panel-label {+ margin: 0 0 12px;+ color: var(--muted);+ font-size: 0.72rem;+ font-weight: 750;+ letter-spacing: 0.08em;+ text-transform: uppercase;+}++h1,+h2,+p {+ margin-top: 0;+}++h1 {+ max-width: 920px;+ margin-bottom: 12px;+ color: var(--ink);+ font-size: clamp(1.9rem, 4vw, 3.35rem);+ line-height: 0.98;+}++h2 {+ margin-bottom: 10px;+ font-size: 0.98rem;+ line-height: 1.2;+}++.summary {+ max-width: 760px;+ margin-bottom: 0;+ color: #3f3f3a;+ font-size: clamp(0.98rem, 1.4vw, 1.08rem);+ line-height: 1.5;+}++.status-card,+.callout,+.control-dock,+.dock-section,+.meter-card,+article {+ border: 1px solid var(--line);+ border-radius: 10px;+ background: var(--panel);+}++.status-card {+ min-width: 180px;+ padding: 16px 18px;+ box-shadow: var(--shadow);+}++.status-panel {+ display: inline-flex;+ align-items: center;+ gap: 10px;+ min-width: 0;+ color: var(--ink);+ font-size: 0.95rem;+ font-weight: 750;+}++.status-dot {+ width: 10px;+ height: 10px;+ border-radius: 999px;+ background: var(--soft);+}++.status-dot.live {+ background: var(--success);+}++.status-dot.error {+ background: var(--danger);+}++.status-note {+ margin: 14px 0 0;+ color: var(--muted);+ font-size: 0.9rem;+ line-height: 1.45;+}++.callout {+ display: grid;+ grid-template-columns: auto 1fr;+ gap: 18px;+ align-items: center;+ margin-bottom: 22px;+ padding: 18px 20px;+ background: #fbfbfa;+}++.callout h2,+.callout p {+ margin-bottom: 0;+}++.callout p {+ color: #464641;+ line-height: 1.5;+}++.callout-rule {+ width: 5px;+ height: 64px;+ border-radius: 999px;+ background: var(--accent);+}++.control-dock {+ display: grid;+ grid-template-columns: minmax(190px, 0.8fr) minmax(280px, 1fr) minmax(300px, 0.9fr);+ gap: 12px;+ align-items: stretch;+ width: 100%;+ margin-bottom: 14px;+ padding: 12px;+ background: #fbfbfa;+}++.dock-section {+ min-width: 0;+ padding: 16px;+}++.field {+ display: grid;+ align-content: center;+ gap: 18px;+}++label {+ color: var(--muted);+ font-size: 0.74rem;+ font-weight: 750;+ letter-spacing: 0.08em;+ text-transform: uppercase;+}++select {+ width: 100%;+ min-width: 0;+ height: 52px;+ padding: 0 12px;+ border: 1px solid var(--line-strong);+ border-radius: 8px;+ background: var(--panel);+ color: var(--ink);+ font-size: 0.95rem;+ font-weight: 750;+ outline: none;+}++input[type="range"]:focus-visible,+select:focus-visible,+button:focus-visible {+ outline: 3px solid rgb(196 95 38 / 24%);+ outline-offset: 2px;+}++.mix-control {+ display: grid;+ align-content: center;+ gap: 12px;+ min-width: 0;+}++.mix-heading,+.mix-scale {+ display: flex;+ align-items: center;+ justify-content: space-between;+ gap: 12px;+}++.range-label {+ display: inline;+}++#mixValue {+ color: var(--ink);+ font-size: 1rem;+ font-weight: 750;+}++input[type="range"] {+ width: 100%;+ accent-color: var(--accent);+}++.mix-scale {+ color: var(--muted);+ font-size: 0.78rem;+ font-weight: 750;+}++.button-row {+ display: grid;+ align-content: center;+ gap: 12px;+}++button {+ min-height: 52px;+ padding: 0 16px;+ border: 1px solid var(--ink);+ border-radius: 8px;+ background: var(--ink);+ color: #ffffff;+ cursor: pointer;+ font-weight: 750;+ white-space: nowrap;+}++#startButton {+ width: 100%;+ min-width: 0;+}++button.secondary {+ border-color: var(--line-strong);+ background: var(--panel);+ color: var(--ink);+}++button:disabled {+ border-color: var(--line);+ background: #ededeb;+ color: var(--soft);+ cursor: not-allowed;+}++.button-row button {+ width: 100%;+}++.meters {+ display: grid;+ grid-template-columns: repeat(2, minmax(0, 1fr));+ gap: 12px;+ margin-bottom: 14px;+}++.meter-card {+ display: grid;+ gap: 8px;+ padding: 12px 14px;+ background: #fbfbfa;+}++.meter-card span {+ color: var(--muted);+ font-size: 0.8rem;+ font-weight: 700;+}++meter,+progress {+ width: 100%;+ height: 12px;+}++.workspace {+ display: grid;+ grid-template-columns: minmax(273px, 0.98fr) minmax(320px, 1.06fr) minmax(280px, 0.96fr);+ gap: 14px;+}++article {+ min-width: 0;+ min-height: 260px;+ padding: 16px;+}++.guide-card {+ background: #fbfbfa;+}++ol {+ margin: 0;+ padding-left: 22px;+ color: #3f3f3a;+ line-height: 1.48;+}++.diagnostics {+ display: grid;+ gap: 0;+ margin: 18px 0 0;+ border-top: 1px solid var(--line);+}++.diagnostics div {+ display: flex;+ justify-content: space-between;+ gap: 14px;+ padding: 9px 0;+ border-bottom: 1px solid var(--line);+}++.diagnostics dt {+ color: var(--muted);+ font-weight: 700;+}++.diagnostics dd {+ margin: 0;+ color: var(--ink);+ text-align: right;+}++.transcript,+.log {+ overflow: auto;+ border-radius: 8px;+ background: var(--panel-soft);+ line-height: 1.55;+}++.transcript {+ min-height: 210px;+ max-height: 360px;+ padding: 14px;+ color: #2f2f2a;+ font-size: 0.96rem;+}++.log {+ min-height: 210px;+ max-height: 360px;+ padding: 12px;+ color: #3d3d38;+ font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;+ font-size: 0.8rem;+ white-space: pre-wrap;+}++.log-entry {+ padding-bottom: 7px;+}++@media (max-width: 980px) {+ .hero,+ .control-dock,+ .workspace {+ grid-template-columns: 1fr;+ }++ .control-dock {+ align-items: stretch;+ }++ .status-card {+ min-width: 0;+ }+}++@media (max-width: 700px) {+ .shell {+ width: min(100% - 28px, 1000px);+ padding: 24px 0 36px;+ }++ h1 {+ font-size: clamp(2rem, 10vw, 2.8rem);+ }++ .button-row {+ align-items: stretch;+ }++ #startButton,+ select,+ .mix-control,+ button {+ width: 100%;+ }++ .meters {+ grid-template-columns: 1fr;+ }+}diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/server.js b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/server.jsnew file mode 100644index 00000000..b0f57eb4--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/server.js@@ -0,0 +1,257 @@+import { createServer } from "node:http";+import { createReadStream, existsSync, readFileSync } from "node:fs";+import path from "node:path";+import { fileURLToPath } from "node:url";++import { createClientSecret, normalizeTargetLanguage } from "./session.js";++const __filename = fileURLToPath(import.meta.url);+const __dirname = path.dirname(__filename);+const DEFAULT_PUBLIC_ROOT = path.join(__dirname, "public");+const MAX_JSON_BYTES = 1_000_000;++const CONTENT_TYPES = {+ ".css": "text/css; charset=utf-8",+ ".html": "text/html; charset=utf-8",+ ".js": "text/javascript; charset=utf-8",+ ".json": "application/json; charset=utf-8",+ ".mjs": "text/javascript; charset=utf-8",+ ".txt": "text/plain; charset=utf-8",+ ".wav": "audio/wav",+};++export function buildServer({+ env = process.env,+ fetchImpl = fetch,+ publicRoot = DEFAULT_PUBLIC_ROOT,+} = {}) {+ return createServer(async (request, response) => {+ try {+ const url = new URL(request.url ?? "/", "http://localhost");++ if (request.method === "POST" && url.pathname === "/session") {+ await handleSessionRequest(request, response, { env, fetchImpl });+ return;+ }++ if (request.method === "GET" || request.method === "HEAD") {+ await serveStatic(url.pathname, response, { method: request.method, publicRoot });+ return;+ }++ sendJson(response, 405, { error: "Method not allowed." });+ } catch (error) {+ const message =+ error instanceof Error ? error.message : "Unexpected server error.";+ sendJson(response, 500, { error: message });+ }+ });+}++export function loadEnvFiles(env = process.env, cwd = process.cwd()) {+ const candidates = [+ path.join(cwd, ".env"),+ path.join(cwd, "..", ".env"),+ ];++ for (const candidate of candidates) {+ if (existsSync(candidate)) {+ loadEnvFile(candidate, env);+ }+ }+}++async function handleSessionRequest(request, response, { env, fetchImpl }) {+ let body;+ try {+ body = await readJson(request);+ } catch (error) {+ sendJson(response, 400, {+ error: error instanceof Error ? error.message : "Invalid JSON body.",+ });+ return;+ }++ let targetLanguage;+ try {+ targetLanguage = normalizeTargetLanguage(body.targetLanguage);+ } catch (error) {+ sendJson(response, 400, {+ error: error instanceof Error ? error.message : "Invalid target language.",+ });+ return;+ }++ if (!env.OPENAI_API_KEY) {+ sendJson(response, 500, { error: "OPENAI_API_KEY is not configured." });+ return;+ }++ try {+ const result = await createClientSecret({+ apiKey: env.OPENAI_API_KEY,+ targetLanguage,+ model: env.OPENAI_TRANSLATION_MODEL,+ inputTranscriptionModel: env.OPENAI_INPUT_TRANSCRIPTION_MODEL,+ fetchImpl,+ });+ sendJson(response, 200, result);+ } catch (error) {+ if (error?.name === "OpenAIRequestError") {+ sendJson(response, 502, {+ error: error.message,+ status: error.status,+ details: parseJsonOrText(error.body),+ });+ return;+ }+ throw error;+ }+}++async function serveStatic(urlPath, response, { method, publicRoot }) {+ const filePath = resolvePublicPath(urlPath, publicRoot);+ if (!filePath) {+ sendText(response, 404, "Not found.");+ return;+ }++ response.writeHead(200, {+ "Cache-Control": "no-store",+ "Content-Type": contentTypeFor(filePath),+ });++ if (method === "HEAD") {+ response.end();+ return;+ }++ createReadStream(filePath).pipe(response);+}++function resolvePublicPath(urlPath, publicRoot) {+ let pathname;+ try {+ pathname = decodeURIComponent(urlPath);+ } catch {+ return null;+ }++ const relativePath = pathname === "/" ? "index.html" : pathname.replace(/^\/+/, "");+ const absolutePath = path.resolve(publicRoot, relativePath);+ const rootWithSeparator = `${path.resolve(publicRoot)}${path.sep}`;++ if (+ absolutePath !== path.resolve(publicRoot) &&+ !absolutePath.startsWith(rootWithSeparator)+ ) {+ return null;+ }++ if (!existsSync(absolutePath)) {+ return null;+ }++ return absolutePath;+}++async function readJson(request) {+ const chunks = [];+ let totalBytes = 0;++ for await (const chunk of request) {+ totalBytes += chunk.length;+ if (totalBytes > MAX_JSON_BYTES) {+ throw new Error("JSON body is too large.");+ }+ chunks.push(chunk);+ }++ const rawBody = Buffer.concat(chunks).toString("utf8").trim();+ if (!rawBody) {+ return {};+ }++ try {+ return JSON.parse(rawBody);+ } catch {+ throw new Error("Invalid JSON body.");+ }+}++function loadEnvFile(filePath, env) {+ const contents = readFileSync(filePath, "utf8");+ for (const line of contents.split(/\r?\n/)) {+ const trimmed = line.trim();+ if (!trimmed || trimmed.startsWith("#")) {+ continue;+ }++ const equalsIndex = trimmed.indexOf("=");+ if (equalsIndex === -1) {+ continue;+ }++ const key = trimmed.slice(0, equalsIndex).trim();+ const value = unquoteEnvValue(trimmed.slice(equalsIndex + 1).trim());+ if (key && env[key] === undefined) {+ env[key] = value;+ }+ }+}++function unquoteEnvValue(value) {+ if (+ (value.startsWith('"') && value.endsWith('"')) ||+ (value.startsWith("'") && value.endsWith("'"))+ ) {+ return value.slice(1, -1);+ }+ return value;+}++function sendJson(response, status, body) {+ response.writeHead(status, {+ "Cache-Control": "no-store",+ "Content-Type": "application/json; charset=utf-8",+ });+ response.end(JSON.stringify(body));+}++function sendText(response, status, body) {+ response.writeHead(status, {+ "Cache-Control": "no-store",+ "Content-Type": "text/plain; charset=utf-8",+ });+ response.end(body);+}++function contentTypeFor(filePath) {+ return CONTENT_TYPES[path.extname(filePath)] ?? "application/octet-stream";+}++function parseJsonOrText(value) {+ if (!value) {+ return "";+ }+ try {+ return JSON.parse(value);+ } catch {+ return value;+ }+}++export function getListenHost(env = process.env) {+ return env.HOST || "127.0.0.1";+}++if (process.argv[1] === __filename) {+ loadEnvFiles();+ const port = Number.parseInt(process.env.PORT ?? "5173", 10);+ const host = getListenHost(process.env);+ const server = buildServer();++ server.listen(port, host, () => {+ console.log(`Browser Realtime Translation demo listening at http://${host}:${port}`);+ });+}diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/session.js b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/session.jsnew file mode 100644index 00000000..dfec58a6--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/src/session.js@@ -0,0 +1,158 @@+export const DEFAULT_TRANSLATION_MODEL = "gpt-realtime-translate";+export const DEFAULT_INPUT_TRANSCRIPTION_MODEL = "gpt-realtime-whisper";+export const TRANSLATION_CLIENT_SECRET_URL =+ "https://api.openai.com/v1/realtime/translations/client_secrets";++const LANGUAGE_TAG_PATTERN = /^[a-z]{2,3}(?:-[a-z0-9]{2,8}){0,2}$/;+const SUPPORTED_TRANSLATION_LANGUAGES = new Set([+ "es",+ "pt",+ "fr",+ "ja",+ "ru",+ "zh",+ "de",+ "ko",+ "hi",+ "id",+ "vi",+ "it",+ "en",+]);++export function normalizeTargetLanguage(targetLanguage) {+ if (typeof targetLanguage !== "string" || !targetLanguage.trim()) {+ throw new Error("A target language code is required.");+ }++ const normalized = targetLanguage.trim().toLowerCase();+ if (!LANGUAGE_TAG_PATTERN.test(normalized)) {+ throw new Error("Use a compact supported target language code such as es, fr, pt, or zh.");+ }+ if (!SUPPORTED_TRANSLATION_LANGUAGES.has(normalized)) {+ throw new Error(+ "Use a supported target language code: es, pt, fr, ja, ru, zh, de, ko, hi, id, vi, it, or en.",+ );+ }++ return normalized;+}++export function buildClientSecretRequest({+ apiKey,+ targetLanguage,+ model = DEFAULT_TRANSLATION_MODEL,+ inputTranscriptionModel = DEFAULT_INPUT_TRANSCRIPTION_MODEL,+ noiseReduction = null,+}) {+ if (!apiKey) {+ throw new Error("OPENAI_API_KEY is required.");+ }++ const language = normalizeTargetLanguage(targetLanguage);+ const body = {+ session: {+ model,+ audio: {+ input: {+ transcription: { model: inputTranscriptionModel },+ noise_reduction: noiseReduction,+ },+ output: { language },+ },+ },+ };++ return {+ url: TRANSLATION_CLIENT_SECRET_URL,+ init: {+ method: "POST",+ headers: {+ Authorization: `Bearer ${apiKey}`,+ "Content-Type": "application/json",+ },+ body: JSON.stringify(body),+ },+ language,+ model,+ };+}++export function buildSessionUpdate({+ targetLanguage,+ inputTranscriptionModel = DEFAULT_INPUT_TRANSCRIPTION_MODEL,+ noiseReduction = null,+}) {+ return {+ type: "session.update",+ session: {+ audio: {+ input: {+ transcription: { model: inputTranscriptionModel },+ noise_reduction: noiseReduction,+ },+ output: { language: normalizeTargetLanguage(targetLanguage) },+ },+ },+ };+}++export async function createClientSecret({+ apiKey,+ targetLanguage,+ model,+ inputTranscriptionModel,+ noiseReduction,+ fetchImpl = fetch,+}) {+ const request = buildClientSecretRequest({+ apiKey,+ targetLanguage,+ model,+ inputTranscriptionModel,+ noiseReduction,+ });++ const response = await fetchImpl(request.url, request.init);+ if (!response.ok) {+ throw new OpenAIRequestError(+ response.status,+ await readResponseBodySafely(response),+ );+ }++ const data = await response.json();+ if (!data || typeof data.value !== "string") {+ throw new Error("OpenAI did not return a client secret value.");+ }++ return {+ client_secret: data.value,+ expires_at: data.expires_at ?? null,+ model: request.model,+ session: data.session ?? null,+ session_update: buildSessionUpdate({+ targetLanguage: request.language,+ inputTranscriptionModel,+ noiseReduction,+ }),+ targetLanguage: request.language,+ };+}++export class OpenAIRequestError extends Error {+ constructor(status, body) {+ super(`OpenAI request failed with status ${status}.`);+ this.name = "OpenAIRequestError";+ this.status = status;+ this.body = body;+ }+}++async function readResponseBodySafely(response) {+ try {+ return await response.text();+ } catch {+ return "";+ }+}diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/audio-chunks.test.js b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/audio-chunks.test.jsnew file mode 100644index 00000000..31004b8d--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/audio-chunks.test.js@@ -0,0 +1,36 @@+import assert from "node:assert/strict";+import test from "node:test";++import { PCM16_200MS_CHUNK_BYTES, Pcm16Chunker } from "../src/public/audio-chunks.js";++test("PCM16_200MS_CHUNK_BYTES is 4,800 16-bit samples", () => {+ assert.equal(PCM16_200MS_CHUNK_BYTES, 4_800 * 2);+});++test("Pcm16Chunker batches small buffers into fixed-size chunks", () => {+ const chunker = new Pcm16Chunker(6);++ assert.deepEqual(chunker.push(Uint8Array.from([1, 2, 3, 4]).buffer), []);+ assert.equal(chunker.pendingBytes, 4);++ const first = chunker.push(Uint8Array.from([5, 6, 7, 8]).buffer);+ assert.equal(first.length, 1);+ assert.deepEqual([...first[0]], [1, 2, 3, 4, 5, 6]);+ assert.equal(chunker.pendingBytes, 2);++ const second = chunker.push(Uint8Array.from([9, 10, 11, 12, 13, 14]).buffer);+ assert.equal(second.length, 1);+ assert.deepEqual([...second[0]], [7, 8, 9, 10, 11, 12]);+ assert.equal(chunker.pendingBytes, 2);+});++test("Pcm16Chunker flushes leftover bytes and resets state", () => {+ const chunker = new Pcm16Chunker(6);+ chunker.push(Uint8Array.from([1, 2, 3]).buffer);++ const flushed = chunker.flush();++ assert.deepEqual([...flushed], [1, 2, 3]);+ assert.equal(chunker.pendingBytes, 0);+ assert.equal(chunker.flush(), null);+});diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/audio-mix.test.js b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/audio-mix.test.jsnew file mode 100644index 00000000..2f820e6d--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/audio-mix.test.js@@ -0,0 +1,35 @@+import assert from "node:assert/strict";+import test from "node:test";++async function importAudioMix() {+ try {+ return await import("../src/public/audio-mix.js");+ } catch (error) {+ assert.fail(+ `audio-mix.js should export browser audio mix helpers: ${error.message}`,+ );+ }+}++test("audio mix defaults to mostly translated audio with some original audio", async () => {+ const { DEFAULT_TRANSLATED_MIX, buildAudioMixState } = await importAudioMix();++ assert.equal(DEFAULT_TRANSLATED_MIX, 85);+ assert.deepEqual(buildAudioMixState(DEFAULT_TRANSLATED_MIX), {+ translatedPercent: 85,+ originalPercent: 15,+ translatedVolume: 0.85,+ originalVolume: 0.15,+ valueLabel: "85% translated",+ translatedLabel: "Translated 85%",+ originalLabel: "Original 15%",+ });+});++test("audio mix clamps slider values into valid volume percentages", async () => {+ const { buildAudioMixState } = await importAudioMix();++ assert.equal(buildAudioMixState("-1").translatedPercent, 0);+ assert.equal(buildAudioMixState("101").translatedPercent, 100);+ assert.equal(buildAudioMixState("not a number").translatedPercent, 85);+});diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/capture-options.test.js b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/capture-options.test.jsnew file mode 100644index 00000000..b0fdcf67--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/capture-options.test.js@@ -0,0 +1,18 @@+import assert from "node:assert/strict";+import test from "node:test";++import { buildDisplayMediaOptions } from "../src/public/capture-options.js";++test("buildDisplayMediaOptions requests local playback suppression when supported", () => {+ const options = buildDisplayMediaOptions({ suppressLocalAudioPlayback: true });++ assert.equal(options.audio.suppressLocalAudioPlayback, true);+ assert.equal(options.audio.echoCancellation, false);+ assert.equal(options.video.displaySurface, "browser");+});++test("buildDisplayMediaOptions omits local playback suppression when unsupported", () => {+ const options = buildDisplayMediaOptions({});++ assert.equal(Object.hasOwn(options.audio, "suppressLocalAudioPlayback"), false);+});diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/server.test.js b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/server.test.jsnew file mode 100644index 00000000..439852ab--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/server.test.js@@ -0,0 +1,140 @@+import assert from "node:assert/strict";+import { once } from "node:events";+import test from "node:test";++import { buildServer, getListenHost } from "../src/server.js";++async function withServer(options, run) {+ const server = buildServer(options);+ server.listen(0, "127.0.0.1");+ await once(server, "listening");+ const { port } = server.address();+ try {+ await run(`http://127.0.0.1:${port}`);+ } finally {+ server.closeAllConnections?.();+ server.close();+ await once(server, "close");+ }+}++test("serves the browser app from the root route", async () => {+ await withServer({ env: { OPENAI_API_KEY: "sk-test" } }, async (baseUrl) => {+ const response = await fetch(`${baseUrl}/`);+ const body = await response.text();++ assert.equal(response.status, 200);+ assert.match(response.headers.get("content-type") ?? "", /text\/html/);+ assert.match(body, /In-browser Realtime Translation/);+ assert.match(body, /Choose tab to start translating/);+ assert.doesNotMatch(body, /Start translating</);+ assert.doesNotMatch(body, /OpenAI Developers/);+ assert.doesNotMatch(body, /class="topbar"/);+ assert.doesNotMatch(body, /Open a tab that is already playing audio/);+ });+});++test("uses localhost by default and allows the listen host to be configured", () => {+ assert.equal(getListenHost({}), "127.0.0.1");+ assert.equal(getListenHost({ HOST: "0.0.0.0" }), "0.0.0.0");+});++test("serves the source speech WAV as audio", async () => {+ await withServer({ env: { OPENAI_API_KEY: "sk-test" } }, async (baseUrl) => {+ const response = await fetch(`${baseUrl}/source-speech.wav`, { method: "HEAD" });++ assert.equal(response.status, 200);+ assert.match(response.headers.get("content-type") ?? "", /audio\/wav/);+ });+});++test("serves browser app code that connects to translation over WebRTC", async () => {+ await withServer({ env: { OPENAI_API_KEY: "sk-test" } }, async (baseUrl) => {+ const response = await fetch(`${baseUrl}/app.js`);+ const body = await response.text();++ assert.equal(response.status, 200);+ assert.match(body, /RTCPeerConnection/);+ assert.match(body, /realtime\/translations\/calls/);+ assert.doesNotMatch(body, /new WebSocket/);+ });+});++test("POST /session validates target language before calling OpenAI", async () => {+ let calls = 0;+ await withServer(+ {+ env: { OPENAI_API_KEY: "sk-test" },+ fetchImpl: async () => {+ calls += 1;+ throw new Error("fetch should not be called");+ },+ },+ async (baseUrl) => {+ const response = await fetch(`${baseUrl}/session`, {+ method: "POST",+ headers: { "Content-Type": "application/json" },+ body: JSON.stringify({ targetLanguage: "english" }),+ });+ const body = await response.json();++ assert.equal(response.status, 400);+ assert.match(body.error, /language code/i);+ assert.equal(calls, 0);+ },+ );+});++test("POST /session returns a browser-safe client secret response", async () => {+ const requests = [];+ await withServer(+ {+ env: { OPENAI_API_KEY: "sk-test" },+ fetchImpl: async (url, init) => {+ requests.push({ url, init });+ return Response.json({+ value: "ek_test",+ expires_at: 123,+ session: { id: "sess_test" },+ });+ },+ },+ async (baseUrl) => {+ const response = await fetch(`${baseUrl}/session`, {+ method: "POST",+ headers: { "Content-Type": "application/json" },+ body: JSON.stringify({ targetLanguage: "es" }),+ });+ const body = await response.json();++ assert.equal(response.status, 200);+ assert.deepEqual(body, {+ client_secret: "ek_test",+ expires_at: 123,+ model: "gpt-realtime-translate",+ session: { id: "sess_test" },+ session_update: {+ type: "session.update",+ session: {+ audio: {+ input: {+ transcription: { model: "gpt-realtime-whisper" },+ noise_reduction: null,+ },+ output: { language: "es" },+ },+ },+ },+ targetLanguage: "es",+ });+ assert.equal(requests.length, 1);+ const requestBody = JSON.parse(requests[0].init.body);+ assert.equal(requestBody.session.model, "gpt-realtime-translate");+ assert.equal(requestBody.session.audio.output.language, "es");+ assert.deepEqual(requestBody.session.audio.input, {+ transcription: { model: "gpt-realtime-whisper" },+ noise_reduction: null,+ });+ },+ );+});diff --git a/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/session.test.js b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/session.test.jsnew file mode 100644index 00000000..774b9b81--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/browser-translation-demo/test/session.test.js@@ -0,0 +1,61 @@+import assert from "node:assert/strict";+import test from "node:test";++import {+ DEFAULT_INPUT_TRANSCRIPTION_MODEL,+ DEFAULT_TRANSLATION_MODEL,+ TRANSLATION_CLIENT_SECRET_URL,+ buildClientSecretRequest,+ buildSessionUpdate,+ normalizeTargetLanguage,+} from "../src/session.js";++test("normalizeTargetLanguage accepts compact BCP-47 style tags", () => {+ assert.equal(normalizeTargetLanguage(" ES "), "es");+ assert.equal(normalizeTargetLanguage("PT"), "pt");+ assert.equal(normalizeTargetLanguage("zh"), "zh");+});++test("normalizeTargetLanguage rejects missing or unsafe values", () => {+ assert.throws(() => normalizeTargetLanguage(""), /target language/i);+ assert.throws(() => normalizeTargetLanguage("english"), /language code/i);+ assert.throws(() => normalizeTargetLanguage("pt-br"), /supported target language/i);+ assert.throws(() => normalizeTargetLanguage("zh-hans"), /supported target language/i);+ assert.throws(() => normalizeTargetLanguage("../es"), /language code/i);+});++test("buildClientSecretRequest builds the current translation payload", () => {+ const request = buildClientSecretRequest({+ apiKey: "sk-test",+ targetLanguage: " ES ",+ });++ assert.equal(request.url, TRANSLATION_CLIENT_SECRET_URL);+ assert.equal(request.init.method, "POST");+ assert.equal(request.init.headers.Authorization, "Bearer sk-test");+ assert.equal(request.init.headers["Content-Type"], "application/json");++ const body = JSON.parse(request.init.body);+ assert.equal(body.session.model, DEFAULT_TRANSLATION_MODEL);+ assert.equal(body.session.audio.input.transcription.model, DEFAULT_INPUT_TRANSCRIPTION_MODEL);+ assert.equal(body.session.audio.input.noise_reduction, null);+ assert.equal(body.session.audio.output.language, "es");+ assert.equal(Object.hasOwn(body, "model"), false);+ assert.equal(Object.hasOwn(body, "max_output_tokens"), false);+ assert.equal(Object.hasOwn(body.session, "max_output_tokens"), false);+});++test("buildSessionUpdate applies input transcription after session.created", () => {+ assert.deepEqual(buildSessionUpdate({ targetLanguage: " ES " }), {+ type: "session.update",+ session: {+ audio: {+ input: {+ transcription: { model: DEFAULT_INPUT_TRANSCRIPTION_MODEL },+ noise_reduction: null,+ },+ output: { language: "es" },+ },+ },+ });+});diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/.env.example b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/.env.examplenew file mode 100644index 00000000..5363a3c7--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/.env.example@@ -0,0 +1,5 @@+LIVEKIT_API_KEY=+LIVEKIT_API_SECRET=+LIVEKIT_URL=+OPENAI_API_KEY=+OPENAI_TRANSLATION_MODEL=gpt-realtime-translatediff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/.gitignore b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/.gitignorenew file mode 100644index 00000000..06a53fad--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/.gitignore@@ -0,0 +1,7 @@+.env+.env.*+!.env.example+.next/+node_modules/+tsconfig.tsbuildinfo+*.tsbuildinfodiff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/.prettierignore b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/.prettierignorenew file mode 100644index 00000000..461b0084--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/.prettierignore@@ -0,0 +1,7 @@+dist/+node_modules/+.next/+.turbo/+coverage/+pnpm-lock.yaml+.pnpm-store/\ No newline at end of filediff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/.prettierrc b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/.prettierrcnew file mode 100644index 00000000..a8a2054a--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/.prettierrc@@ -0,0 +1,11 @@+{+ "endOfLine": "lf",+ "semi": false,+ "singleQuote": false,+ "tabWidth": 2,+ "trailingComma": "es5",+ "printWidth": 80,+ "plugins": ["prettier-plugin-tailwindcss"],+ "tailwindStylesheet": "app/globals.css",+ "tailwindFunctions": ["cn", "cva"]+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/README.md b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/README.mdnew file mode 100644index 00000000..82c45e47--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/README.md@@ -0,0 +1,50 @@+# LiveKit Realtime Translation Demo++Local Next.js 16 demo for a LiveKit video room with per-listener OpenAI+Realtime Translation. LiveKit carries browser-to-browser camera and microphone+media. Each browser translates subscribed remote microphone tracks through an+OpenAI WebRTC connection and keeps captions/transcripts in local React state.++## Setup++Create `.env` in this demo folder:++```bash+LIVEKIT_API_KEY=+LIVEKIT_API_SECRET=+LIVEKIT_URL=+OPENAI_API_KEY=+OPENAI_TRANSLATION_MODEL=gpt-realtime-translate+```++`OPENAI_TRANSLATION_MODEL` is optional and defaults to+`gpt-realtime-translate`.++## Run++From the cookbook repo root:++```bash+cd examples/voice_solutions/realtime_translation_guide/livekit-translation-demo+pnpm install+pnpm dev+```++Open the local URL printed by Next.js. Use the same meeting code in two browser+windows to join the same LiveKit room.++## Validation++From the cookbook repo root:++```bash+cd examples/voice_solutions/realtime_translation_guide/livekit-translation-demo+pnpm test+pnpm lint+pnpm typecheck+pnpm build+```++The OpenAI translation payload tests cover the translation client secret request,+the translation WebRTC call endpoint, `session.audio.output.language`, optional+input transcription, and optional near-field noise reduction.diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/[roomName]/page.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/[roomName]/page.tsxnew file mode 100644index 00000000..48d3fce0--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/[roomName]/page.tsx@@ -0,0 +1,11 @@+import { LiveKitVideoConference } from "@/components/conference/livekit-video-conference"++export default async function RoomPage({+ params,+}: {+ params: Promise<{ roomName: string }>+}) {+ const { roomName } = await params++ return <LiveKitVideoConference initialRoomName={roomName} />+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/api/livekit/livekit-env.ts b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/api/livekit/livekit-env.tsnew file mode 100644index 00000000..8adaf042--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/api/livekit/livekit-env.ts@@ -0,0 +1,25 @@+import { loadEnvConfig } from "@next/env"++type LiveKitEnv = {+ apiKey: string+ apiSecret: string+ serverUrl: string+}++loadEnvConfig(process.cwd())++export function getLiveKitEnv(): LiveKitEnv | null {+ const apiKey = process.env.LIVEKIT_API_KEY+ const apiSecret = process.env.LIVEKIT_API_SECRET+ const serverUrl = process.env.LIVEKIT_URL++ if (!apiKey || !apiSecret || !serverUrl) {+ return null+ }++ return { apiKey, apiSecret, serverUrl }+}++export function normalizeLiveKitSegment(value: string | null) {+ return value?.trim().slice(0, 80) ?? ""+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/api/livekit/participants/route.ts b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/api/livekit/participants/route.tsnew file mode 100644index 00000000..e87ff3a2--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/api/livekit/participants/route.ts@@ -0,0 +1,62 @@+import { RoomServiceClient, TwirpError } from "livekit-server-sdk"+import { NextResponse } from "next/server"++import { getLiveKitEnv, normalizeLiveKitSegment } from "../livekit-env"++type ParticipantPresence = {+ identity: string+ name: string+}++type ParticipantsResponse = {+ participants: ParticipantPresence[]+}++export async function GET(request: Request) {+ const liveKitEnv = getLiveKitEnv()++ if (!liveKitEnv) {+ return new NextResponse(+ "Missing LIVEKIT_API_KEY, LIVEKIT_API_SECRET, or LIVEKIT_URL",+ { status: 500 }+ )+ }++ const url = new URL(request.url)+ const roomName = normalizeLiveKitSegment(url.searchParams.get("roomName"))++ if (!roomName) {+ return new NextResponse("Missing required query parameter: roomName", {+ status: 400,+ })+ }++ const roomService = new RoomServiceClient(+ liveKitEnv.serverUrl,+ liveKitEnv.apiKey,+ liveKitEnv.apiSecret+ )++ try {+ const participants = await roomService.listParticipants(roomName)+ const response: ParticipantsResponse = {+ participants: participants.map((participant) => ({+ identity: participant.identity,+ name: participant.name || participant.identity,+ })),+ }++ return NextResponse.json(response)+ } catch (error) {+ if (error instanceof TwirpError && error.code === "not_found") {+ return NextResponse.json({+ participants: [],+ } satisfies ParticipantsResponse)+ }++ const message =+ error instanceof Error ? error.message : "Unable to list participants"++ return new NextResponse(message, { status: 500 })+ }+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/api/livekit/token/route.ts b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/api/livekit/token/route.tsnew file mode 100644index 00000000..9a306f35--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/api/livekit/token/route.ts@@ -0,0 +1,105 @@+import {+ AccessToken,+ type AccessTokenOptions,+ type VideoGrant,+} from "livekit-server-sdk"+import { NextResponse } from "next/server"++import { getLiveKitEnv, normalizeLiveKitSegment } from "../livekit-env"++type TokenResponse = {+ serverUrl: string+ roomName: string+ participantName: string+ participantToken: string+}++export async function GET(request: Request) {+ try {+ const liveKitEnv = getLiveKitEnv()++ if (!liveKitEnv) {+ return new NextResponse(+ "Missing LIVEKIT_API_KEY, LIVEKIT_API_SECRET, or LIVEKIT_URL",+ { status: 500 }+ )+ }++ const url = new URL(request.url)+ const roomName = normalizeLiveKitSegment(url.searchParams.get("roomName"))+ const participantName = normalizeLiveKitSegment(+ url.searchParams.get("participantName")+ )++ if (!roomName) {+ return new NextResponse("Missing required query parameter: roomName", {+ status: 400,+ })+ }++ if (!participantName) {+ return new NextResponse(+ "Missing required query parameter: participantName",+ {+ status: 400,+ }+ )+ }++ const participantToken = await createParticipantToken(+ {+ identity: `${slugify(participantName)}-${crypto.randomUUID().slice(0, 8)}`,+ name: participantName,+ },+ roomName,+ liveKitEnv+ )++ const response: TokenResponse = {+ serverUrl: liveKitEnv.serverUrl,+ roomName,+ participantName,+ participantToken,+ }++ return NextResponse.json(response)+ } catch (error) {+ const message =+ error instanceof Error ? error.message : "Unable to create LiveKit token"++ return new NextResponse(message, { status: 500 })+ }+}++function createParticipantToken(+ userInfo: AccessTokenOptions,+ roomName: string,+ liveKitEnv: NonNullable<ReturnType<typeof getLiveKitEnv>>+) {+ const accessToken = new AccessToken(+ liveKitEnv.apiKey,+ liveKitEnv.apiSecret,+ userInfo+ )+ accessToken.ttl = "30m"++ const grant: VideoGrant = {+ room: roomName,+ roomJoin: true,+ canPublish: true,+ canPublishData: true,+ canSubscribe: true,+ }++ accessToken.addGrant(grant)++ return accessToken.toJwt()+}++function slugify(value: string) {+ return value+ .toLowerCase()+ .replace(/[^a-z0-9]+/g, "-")+ .replace(/(^-|-$)/g, "")+ .slice(0, 48)+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/api/realtime/translation-token/route.ts b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/api/realtime/translation-token/route.tsnew file mode 100644index 00000000..e2dc6728--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/api/realtime/translation-token/route.ts@@ -0,0 +1,77 @@+import { NextResponse } from "next/server"++import {+ buildTranslationClientSecretRequest,+ normalizeTranslationLanguage,+} from "@/lib/realtime-translation-config"++type TranslationTokenRequest = {+ language?: string+ inputTranscriptionEnabled?: boolean+ noiseReductionEnabled?: boolean+}++type ClientSecretResponse = {+ value?: string+ expires_at?: number+ client_secret?: {+ value?: string+ expires_at?: number+ }+}++export async function POST(request: Request) {+ const apiKey = process.env.OPENAI_API_KEY++ if (!apiKey) {+ return new NextResponse("Missing OPENAI_API_KEY", { status: 500 })+ }++ let payload: TranslationTokenRequest+ try {+ payload = (await request.json()) as TranslationTokenRequest+ } catch {+ return new NextResponse("Invalid JSON body", { status: 400 })+ }++ let language: string+ try {+ language = normalizeTranslationLanguage(payload.language || "es")+ } catch (error) {+ return new NextResponse(+ error instanceof Error ? error.message : "Unsupported translation language",+ { status: 400 }+ )+ }++ const translationRequest = buildTranslationClientSecretRequest({+ apiKey,+ language,+ inputTranscriptionEnabled: !!payload.inputTranscriptionEnabled,+ noiseReductionEnabled: !!payload.noiseReductionEnabled,+ model: process.env.OPENAI_TRANSLATION_MODEL,+ })++ const response = await fetch(translationRequest.url, translationRequest.init)++ if (!response.ok) {+ return new NextResponse(await response.text(), {+ status: response.status,+ })+ }++ const data = (await response.json()) as ClientSecretResponse+ const clientSecret = data.value ?? data.client_secret?.value++ if (!clientSecret) {+ return new NextResponse(+ "Realtime translation client secret response was missing value",+ { status: 502 }+ )+ }++ return NextResponse.json({+ clientSecret,+ expiresAt: data.expires_at ?? data.client_secret?.expires_at ?? null,+ })+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/favicon.ico b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/favicon.iconew file mode 100644index 00000000..718d6feaBinary files /dev/null and b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/favicon.ico differdiff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/globals.css b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/globals.cssnew file mode 100644index 00000000..1642ecf3--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/globals.css@@ -0,0 +1,174 @@+@import "tailwindcss";+@import "tw-animate-css";++@custom-variant dark (&:is(.dark *));+@custom-variant data-open {+ &:where([data-state="open"]),+ &:where([data-open]:not([data-open="false"])) {+ @slot;+ }+}+@custom-variant data-closed {+ &:where([data-state="closed"]),+ &:where([data-closed]:not([data-closed="false"])) {+ @slot;+ }+}+@custom-variant data-checked {+ &:where([data-state="checked"]),+ &:where([data-checked]:not([data-checked="false"])) {+ @slot;+ }+}+@custom-variant data-unchecked {+ &:where([data-state="unchecked"]),+ &:where([data-unchecked]:not([data-unchecked="false"])) {+ @slot;+ }+}+@custom-variant data-disabled {+ &:where([data-disabled="true"]),+ &:where([data-disabled]:not([data-disabled="false"])) {+ @slot;+ }+}+@custom-variant data-horizontal {+ &:where([data-orientation="horizontal"]) {+ @slot;+ }+}+@custom-variant data-vertical {+ &:where([data-orientation="vertical"]) {+ @slot;+ }+}+@source "../**/*.{ts,tsx}";++@theme inline {+ --font-heading: var(--font-openai-sans);+ --color-sidebar-ring: var(--sidebar-ring);+ --color-sidebar-border: var(--sidebar-border);+ --color-sidebar-accent-foreground: var(--sidebar-accent-foreground);+ --color-sidebar-accent: var(--sidebar-accent);+ --color-sidebar-primary-foreground: var(--sidebar-primary-foreground);+ --color-sidebar-primary: var(--sidebar-primary);+ --color-sidebar-foreground: var(--sidebar-foreground);+ --color-sidebar: var(--sidebar);+ --color-chart-5: var(--chart-5);+ --color-chart-4: var(--chart-4);+ --color-chart-3: var(--chart-3);+ --color-chart-2: var(--chart-2);+ --color-chart-1: var(--chart-1);+ --color-ring: var(--ring);+ --color-input: var(--input);+ --color-border: var(--border);+ --color-destructive: var(--destructive);+ --color-accent-foreground: var(--accent-foreground);+ --color-accent: var(--accent);+ --color-muted-foreground: var(--muted-foreground);+ --color-muted: var(--muted);+ --color-secondary-foreground: var(--secondary-foreground);+ --color-secondary: var(--secondary);+ --color-primary-foreground: var(--primary-foreground);+ --color-primary: var(--primary);+ --color-popover-foreground: var(--popover-foreground);+ --color-popover: var(--popover);+ --color-card-foreground: var(--card-foreground);+ --color-card: var(--card);+ --color-foreground: var(--foreground);+ --color-background: var(--background);+ --radius-sm: calc(var(--radius) * 0.6);+ --radius-md: calc(var(--radius) * 0.8);+ --radius-lg: var(--radius);+ --radius-xl: calc(var(--radius) * 1.4);+ --radius-2xl: calc(var(--radius) * 1.8);+ --radius-3xl: calc(var(--radius) * 2.2);+ --radius-4xl: calc(var(--radius) * 2.6);+ --font-sans: var(--font-openai-sans);+}++:root {+ --background: oklch(1 0 0);+ --foreground: oklch(0.153 0.006 107.1);+ --card: oklch(1 0 0);+ --card-foreground: oklch(0.153 0.006 107.1);+ --popover: oklch(1 0 0);+ --popover-foreground: oklch(0.153 0.006 107.1);+ --primary: #1a73e8;+ --primary-foreground: #ffffff;+ --secondary: oklch(0.967 0.001 286.375);+ --secondary-foreground: oklch(0.21 0.006 285.885);+ --muted: oklch(0.966 0.005 106.5);+ --muted-foreground: oklch(0.58 0.031 107.3);+ --accent: oklch(0.966 0.005 106.5);+ --accent-foreground: oklch(0.228 0.013 107.4);+ --destructive: oklch(0.577 0.245 27.325);+ --border: oklch(0.93 0.007 106.5);+ --input: oklch(0.93 0.007 106.5);+ --ring: oklch(0.737 0.021 106.9);+ --chart-1: #fbbc04;+ --chart-2: #34a853;+ --chart-3: #ea4335;+ --chart-4: #4285f4;+ --chart-5: #5f6368;+ --radius: 0.625rem;+ --sidebar: oklch(0.988 0.003 106.5);+ --sidebar-foreground: oklch(0.153 0.006 107.1);+ --sidebar-primary: #1a73e8;+ --sidebar-primary-foreground: #ffffff;+ --sidebar-accent: oklch(0.966 0.005 106.5);+ --sidebar-accent-foreground: oklch(0.228 0.013 107.4);+ --sidebar-border: oklch(0.93 0.007 106.5);+ --sidebar-ring: oklch(0.737 0.021 106.9);+}++.dark {+ --background: oklch(0.153 0.006 107.1);+ --foreground: oklch(0.988 0.003 106.5);+ --card: oklch(0.228 0.013 107.4);+ --card-foreground: oklch(0.988 0.003 106.5);+ --popover: oklch(0.228 0.013 107.4);+ --popover-foreground: oklch(0.988 0.003 106.5);+ --primary: #8ab4f8;+ --primary-foreground: #10233f;+ --secondary: oklch(0.274 0.006 286.033);+ --secondary-foreground: oklch(0.985 0 0);+ --muted: oklch(0.286 0.016 107.4);+ --muted-foreground: oklch(0.737 0.021 106.9);+ --accent: oklch(0.286 0.016 107.4);+ --accent-foreground: oklch(0.988 0.003 106.5);+ --destructive: oklch(0.704 0.191 22.216);+ --border: oklch(1 0 0 / 10%);+ --input: oklch(1 0 0 / 15%);+ --ring: oklch(0.58 0.031 107.3);+ --chart-1: oklch(0.88 0.011 106.6);+ --chart-2: oklch(0.58 0.031 107.3);+ --chart-3: oklch(0.466 0.025 107.3);+ --chart-4: oklch(0.394 0.023 107.4);+ --chart-5: oklch(0.286 0.016 107.4);+ --sidebar: oklch(0.228 0.013 107.4);+ --sidebar-foreground: oklch(0.988 0.003 106.5);+ --sidebar-primary: #8ab4f8;+ --sidebar-primary-foreground: #10233f;+ --sidebar-accent: oklch(0.286 0.016 107.4);+ --sidebar-accent-foreground: oklch(0.988 0.003 106.5);+ --sidebar-border: oklch(1 0 0 / 10%);+ --sidebar-ring: oklch(0.58 0.031 107.3);+}++@layer base {+ * {+ @apply border-border outline-ring/50;+ }+ body {+ @apply bg-background text-foreground;+ }+ button,+ input,+ select,+ textarea,+ [role="combobox"] {+ font-family: inherit;+ letter-spacing: normal;+ }+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/layout.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/layout.tsxnew file mode 100644index 00000000..82586f58--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/layout.tsx@@ -0,0 +1,43 @@+import { Geist_Mono } from "next/font/google"+import localFont from "next/font/local"++import "./globals.css"+import { AppHeader } from "@/components/app-header"+import { ThemeProvider } from "@/components/theme-provider"+import { cn } from "@/lib/utils"++const openAISans = localFont({+ src: "../public/fonts/OpenAISansVariable.woff2",+ variable: "--font-openai-sans",+ display: "swap",+})++const fontMono = Geist_Mono({+ subsets: ["latin"],+ variable: "--font-mono",+})++export default function RootLayout({+ children,+}: Readonly<{+ children: React.ReactNode+}>) {+ return (+ <html+ lang="en"+ suppressHydrationWarning+ className={cn(+ "font-sans antialiased",+ fontMono.variable,+ openAISans.variable+ )}+ >+ <body className="font-sans antialiased">+ <ThemeProvider>+ <AppHeader />+ {children}+ </ThemeProvider>+ </body>+ </html>+ )+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/page.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/page.tsxnew file mode 100644index 00000000..f57ae14a--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/app/page.tsx@@ -0,0 +1,5 @@+import { LiveKitVideoConference } from "@/components/conference/livekit-video-conference"++export default function Page() {+ return <LiveKitVideoConference />+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/app-header.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/app-header.tsxnew file mode 100644index 00000000..2d13217c--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/app-header.tsx@@ -0,0 +1,143 @@+"use client"++import * as React from "react"+import Image from "next/image"+import Link from "next/link"+import { MonitorIcon, MoonIcon, SunIcon } from "lucide-react"+import { useTheme } from "next-themes"++import { Button } from "@/components/ui/button"+import { useMounted } from "@/hooks/use-mounted"+import { cn } from "@/lib/utils"++function subscribeMeetingState(onStoreChange: () => void) {+ window.addEventListener("realtime-translation:meeting-state", onStoreChange)++ return () => {+ window.removeEventListener(+ "realtime-translation:meeting-state",+ onStoreChange+ )+ }+}++function getMeetingStateSnapshot() {+ return document.body.dataset.meetingState === "connected"+}++function getServerMeetingStateSnapshot() {+ return false+}++function AppHeader() {+ const meetingConnected = React.useSyncExternalStore(+ subscribeMeetingState,+ getMeetingStateSnapshot,+ getServerMeetingStateSnapshot+ )++ return (+ <header+ className={cn(+ "flex h-16 shrink-0 items-center bg-background px-6 text-foreground lg:px-8",+ meetingConnected && "border-b border-border"+ )}+ >+ <RealtimeTranslationLogo />+ <ThemeToggle />+ </header>+ )+}++function RealtimeTranslationLogo() {+ return (+ <Link href="/" className="flex items-center gap-1">+ <Image+ src="/brand/chatgpt-blossom-black.svg"+ alt=""+ width={40}+ height={40}+ className="size-14 dark:hidden"+ />+ <Image+ src="/brand/chatgpt-blossom-white.svg"+ alt=""+ width={40}+ height={40}+ className="hidden size-14 dark:block"+ />+ <span className="self-center text-2xl leading-none font-bold tracking-tight">+ Realtime Translation+ </span>+ </Link>+ )+}++function ThemeToggle() {+ const { theme = "system", setTheme } = useTheme()+ const mounted = useMounted()+ const activeTheme = mounted ? theme : "system"++ return (+ <div+ className="ms-auto flex items-center gap-1 rounded-full border border-border bg-background p-1"+ role="group"+ aria-label="Theme"+ >+ <ThemeModeButton+ active={activeTheme === "light"}+ ariaLabel="Use light mode"+ onClick={() => setTheme("light")}+ >+ <SunIcon />+ </ThemeModeButton>+ <ThemeModeButton+ active={activeTheme === "dark"}+ ariaLabel="Use dark mode"+ onClick={() => setTheme("dark")}+ >+ <MoonIcon />+ </ThemeModeButton>+ <ThemeModeButton+ active={activeTheme === "system"}+ ariaLabel="Use system mode"+ onClick={() => setTheme("system")}+ >+ <MonitorIcon />+ </ThemeModeButton>+ </div>+ )+}++function ThemeModeButton({+ active,+ ariaLabel,+ children,+ onClick,+}: {+ active: boolean+ ariaLabel: string+ children: React.ReactNode+ onClick: () => void+}) {+ return (+ <Button+ type="button"+ variant="ghost"+ size="icon"+ className={cn(+ "size-8 rounded-full",+ active+ ? "bg-foreground text-background hover:bg-foreground/90 hover:text-background"+ : "text-muted-foreground hover:text-foreground"+ )}+ aria-label={ariaLabel}+ aria-pressed={active}+ onClick={onClick}+ >+ {children}+ </Button>+ )+}++export { AppHeader }diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/conference/livekit-video-conference.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/conference/livekit-video-conference.tsxnew file mode 100644index 00000000..c2f2f08d--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/conference/livekit-video-conference.tsx@@ -0,0 +1,2279 @@+"use client"++import * as React from "react"+import Image from "next/image"+import {+ Room,+ RoomEvent,+ Track,+ VideoPresets,+ type Participant,+ type RoomConnectOptions,+} from "livekit-client"+import {+ AlertCircleIcon,+ CheckIcon,+ ChevronDownIcon,+ CopyIcon,+ LanguagesIcon,+ PhoneOffIcon,+ VideoOffIcon,+} from "lucide-react"++import { Alert, AlertDescription, AlertTitle } from "@/components/ui/alert"+import { Badge } from "@/components/ui/badge"+import { Button } from "@/components/ui/button"+import { Input } from "@/components/ui/input"+import {+ Popover,+ PopoverContent,+ PopoverTrigger,+} from "@/components/ui/popover"+import { Separator } from "@/components/ui/separator"+import {+ Select,+ SelectContent,+ SelectGroup,+ SelectItem,+ SelectTrigger,+ SelectValue,+} from "@/components/ui/select"+import { Slider } from "@/components/ui/slider"+import { Spinner } from "@/components/ui/spinner"+import { Switch } from "@/components/ui/switch"+import { useMounted } from "@/hooks/use-mounted"+import { cn } from "@/lib/utils"+import {+ TRANSLATION_LANGUAGES,+ useRemoteTranslation,+ type TranslationStatus,+ type UseRemoteTranslationResult,+} from "@/lib/realtime-translation"++type ConnectionDetails = {+ serverUrl: string+ roomName: string+ participantName: string+ participantToken: string+}++type JoinState = "setup" | "connecting" | "connected"+type MediaPermissionName = "camera" | "microphone"+type MeetingTileModel = {+ participant: Participant+ label: string+ isLocal: boolean+ highlighted: boolean+ visualIndex: number+}+type ParticipantPresence = {+ identity: string+ name: string+}+type ParticipantsResponse = {+ participants: ParticipantPresence[]+}+type DeviceMenuKind = "audio" | "video"+type DeviceMenuOption = {+ id: string+ label: string+ selected: boolean+ disabled?: boolean+ onSelect: () => void+}+type DeviceMenuSection = {+ label: string+ emptyLabel: string+ options: DeviceMenuOption[]+}+type ParticipantTranslationSnapshot = UseRemoteTranslationResult & {+ participantId: string+ participantName: string+ hasSourceTrack: boolean+}++const DEFAULT_ROOM_NAME = "test-demo"+const DEFAULT_PARTICIPANT_NAME = "Blossom"+const MAX_VISIBLE_PARTICIPANTS = 6+const SPEAKING_LEVEL_FLOOR = 0.08+const LANDSCAPE_VIDEO = VideoPresets.h1080+const LANDSCAPE_VIDEO_CONSTRAINTS = {+ aspectRatio: { ideal: 16 / 9 },+ frameRate: { ideal: 30, max: 30 },+ height: { ideal: LANDSCAPE_VIDEO.height },+ width: { ideal: LANDSCAPE_VIDEO.width },+} satisfies MediaTrackConstraints++const CONNECT_OPTIONS: RoomConnectOptions = {+ autoSubscribe: true,+}++function getDeviceLabel(+ device: MediaDeviceInfo,+ fallbackPrefix: "Camera" | "Microphone" | "Speaker",+ index: number+) {+ const label = device.label.trim() || `${fallbackPrefix} ${index + 1}`+ return label.replace(/\s+\([0-9a-f]{4}:[0-9a-f]{4}\)$/i, "")+}++export function LiveKitVideoConference({+ initialRoomName,+}: {+ initialRoomName?: string+}) {+ const [participantName, setParticipantName] = React.useState(+ DEFAULT_PARTICIPANT_NAME+ )+ const [roomName, setRoomName] = React.useState(+ initialRoomName?.trim() || DEFAULT_ROOM_NAME+ )+ const [translationLanguage, setTranslationLanguage] = React.useState("es")+ const [audioInputs, setAudioInputs] = React.useState<MediaDeviceInfo[]>([])+ const [audioOutputs, setAudioOutputs] = React.useState<MediaDeviceInfo[]>([])+ const [videoInputs, setVideoInputs] = React.useState<MediaDeviceInfo[]>([])+ const [audioDeviceId, setAudioDeviceId] = React.useState("")+ const [audioOutputDeviceId, setAudioOutputDeviceId] = React.useState("")+ const [videoDeviceId, setVideoDeviceId] = React.useState("")+ const [micEnabled, setMicEnabled] = React.useState(true)+ const [cameraEnabled, setCameraEnabled] = React.useState(true)+ const [previewStream, setPreviewStream] = React.useState<MediaStream | null>(+ null+ )+ const [joinState, setJoinState] = React.useState<JoinState>("setup")+ const [room, setRoom] = React.useState<Room | null>(null)+ const [errorMessage, setErrorMessage] = React.useState<string | null>(null)+ const [previewErrorMessage, setPreviewErrorMessage] = React.useState<+ string | null+ >(null)+ const [previewRequestKey, setPreviewRequestKey] = React.useState(0)+ const [permissionRevision, setPermissionRevision] = React.useState(0)+ const [, setRevision] = React.useState(0)+ const [lobbyParticipants, setLobbyParticipants] = React.useState<+ ParticipantPresence[]+ >([])+ const hasMounted = useMounted()++ const previewVideoRef = React.useRef<HTMLVideoElement | null>(null)++ React.useEffect(() => {+ let cancelled = false+ const statuses: PermissionStatus[] = []++ async function watchMediaPermissions() {+ const nextStatuses = await Promise.all([+ queryMediaPermission("camera"),+ queryMediaPermission("microphone"),+ ])++ if (cancelled) {+ return+ }++ nextStatuses.forEach((status) => {+ if (!status) {+ return+ }++ statuses.push(status)+ status.onchange = () => {+ setPermissionRevision((current) => current + 1)+ }+ })+ }++ watchMediaPermissions()++ return () => {+ cancelled = true+ statuses.forEach((status) => {+ status.onchange = null+ })+ }+ }, [])++ React.useEffect(() => {+ if (joinState !== "setup") {+ return+ }++ const normalizedRoomName = roomName.trim() || DEFAULT_ROOM_NAME+ let cancelled = false+ let activeController: AbortController | null = null++ async function refreshParticipants() {+ activeController?.abort()+ const controller = new AbortController()+ activeController = controller++ try {+ const participantsUrl = new URL(+ "/api/livekit/participants",+ window.location.origin+ )+ participantsUrl.searchParams.set("roomName", normalizedRoomName)++ const response = await fetch(participantsUrl.toString(), {+ signal: controller.signal,+ })++ if (!response.ok) {+ throw new Error(await response.text())+ }++ const data = (await response.json()) as ParticipantsResponse++ if (!cancelled) {+ setLobbyParticipants(data.participants)+ }+ } catch {+ if (!cancelled && !controller.signal.aborted) {+ setLobbyParticipants([])+ }+ }+ }++ void refreshParticipants()+ const interval = window.setInterval(() => {+ void refreshParticipants()+ }, 3000)++ return () => {+ cancelled = true+ activeController?.abort()+ window.clearInterval(interval)+ }+ }, [joinState, roomName])++ const applyDevices = React.useCallback((devices: MediaDeviceInfo[]) => {+ const nextAudioInputs = devices.filter(+ (device) => device.kind === "audioinput" && device.deviceId+ )+ const nextAudioOutputs = devices.filter(+ (device) => device.kind === "audiooutput" && device.deviceId+ )+ const nextVideoInputs = devices.filter(+ (device) => device.kind === "videoinput" && device.deviceId+ )++ setAudioInputs(nextAudioInputs)+ setAudioOutputs(nextAudioOutputs)+ setVideoInputs(nextVideoInputs)+ setAudioDeviceId((current) =>+ nextAudioInputs.some((device) => device.deviceId === current)+ ? current+ : nextAudioInputs[0]?.deviceId || ""+ )+ setAudioOutputDeviceId((current) =>+ nextAudioOutputs.some((device) => device.deviceId === current)+ ? current+ : nextAudioOutputs.find((device) => device.deviceId === "default")+ ?.deviceId ||+ nextAudioOutputs[0]?.deviceId ||+ ""+ )+ setVideoDeviceId((current) =>+ nextVideoInputs.some((device) => device.deviceId === current)+ ? current+ : nextVideoInputs[0]?.deviceId || ""+ )+ }, [])++ const refreshDevices = React.useCallback(async () => {+ if (!navigator.mediaDevices?.enumerateDevices) {+ return+ }++ applyDevices(await navigator.mediaDevices.enumerateDevices())+ }, [applyDevices])++ React.useEffect(() => {+ if (!navigator.mediaDevices?.enumerateDevices) {+ return+ }++ let cancelled = false++ function loadDevices() {+ navigator.mediaDevices+ .enumerateDevices()+ .then((devices) => {+ if (!cancelled) {+ applyDevices(devices)+ }+ })+ .catch((error) => {+ console.error(error)+ })+ }++ loadDevices()+ navigator.mediaDevices.addEventListener("devicechange", loadDevices)++ return () => {+ cancelled = true+ navigator.mediaDevices.removeEventListener("devicechange", loadDevices)+ }+ }, [applyDevices])++ React.useEffect(() => {+ if (joinState !== "setup") {+ return+ }++ if (!cameraEnabled && !micEnabled) {+ return+ }++ let cancelled = false+ let stream: MediaStream | null = null++ async function startPreview() {+ try {+ const [cameraPermission, microphonePermission] = await Promise.all([+ cameraEnabled ? queryMediaPermission("camera") : null,+ micEnabled ? queryMediaPermission("microphone") : null,+ ])++ if (cancelled) {+ return+ }++ if (+ cameraPermission?.state === "denied" ||+ microphonePermission?.state === "denied"+ ) {+ setPreviewStream((current) => {+ stopMediaStream(current)+ return null+ })+ setPreviewErrorMessage("Camera blocked")+ return+ }++ stream = await navigator.mediaDevices.getUserMedia({+ video: cameraEnabled+ ? {+ deviceId: videoDeviceId ? { exact: videoDeviceId } : undefined,+ ...LANDSCAPE_VIDEO_CONSTRAINTS,+ }+ : false,+ audio: micEnabled+ ? { deviceId: audioDeviceId ? { exact: audioDeviceId } : undefined }+ : false,+ })++ if (cancelled) {+ stopMediaStream(stream)+ return+ }++ setPreviewStream((current) => {+ stopMediaStream(current)+ return stream+ })++ await refreshDevices()+ setPreviewErrorMessage(null)+ } catch (error) {+ const message =+ error instanceof Error+ ? error.message+ : "Unable to open the selected camera or microphone."+ setPreviewErrorMessage(message)+ }+ }++ startPreview()++ return () => {+ cancelled = true+ stopMediaStream(stream)+ }+ }, [+ audioDeviceId,+ cameraEnabled,+ joinState,+ micEnabled,+ permissionRevision,+ previewRequestKey,+ refreshDevices,+ videoDeviceId,+ ])++ React.useEffect(() => {+ const previewVideo = previewVideoRef.current++ if (!previewVideo) {+ return+ }++ previewVideo.srcObject = previewStream++ return () => {+ previewVideo.srcObject = null+ }+ }, [previewStream])++ React.useEffect(() => {+ return () => {+ room?.disconnect()+ stopMediaStream(previewStream)+ }+ }, [previewStream, room])++ const roomUrl = React.useMemo(() => {+ if (typeof window === "undefined") {+ return ""+ }++ const url = new URL(window.location.href)+ url.pathname = `/${encodeURIComponent(roomName.trim() || DEFAULT_ROOM_NAME)}`+ url.search = ""+ url.hash = ""+ return url.toString()+ }, [roomName])++ const participants = room+ ? [room.localParticipant, ...Array.from(room.remoteParticipants.values())]+ : []+ const isConnected = joinState === "connected" && room++ React.useEffect(() => {+ document.body.dataset.meetingState = isConnected ? "connected" : "lobby"+ window.dispatchEvent(+ new CustomEvent("realtime-translation:meeting-state")+ )++ return () => {+ document.body.dataset.meetingState = "lobby"+ window.dispatchEvent(+ new CustomEvent("realtime-translation:meeting-state")+ )+ }+ }, [isConnected])++ async function joinRoom(event: React.FormEvent<HTMLFormElement>) {+ event.preventDefault()++ const normalizedRoomName = roomName.trim() || DEFAULT_ROOM_NAME+ const normalizedParticipantName =+ participantName.trim() || DEFAULT_PARTICIPANT_NAME+ let nextRoom: Room | null = null++ window.history.replaceState(+ null,+ "",+ `/${encodeURIComponent(normalizedRoomName)}`+ )+ setJoinState("connecting")+ setErrorMessage(null)++ try {+ const tokenUrl = new URL("/api/livekit/token", window.location.origin)+ tokenUrl.searchParams.set("roomName", normalizedRoomName)+ tokenUrl.searchParams.set("participantName", normalizedParticipantName)++ const response = await fetch(tokenUrl.toString())+ if (!response.ok) {+ throw new Error(await response.text())+ }++ const details = (await response.json()) as ConnectionDetails+ nextRoom = new Room({+ adaptiveStream: true,+ dynacast: true,+ videoCaptureDefaults: {+ deviceId: videoDeviceId || undefined,+ frameRate: 30,+ resolution: LANDSCAPE_VIDEO,+ },+ audioCaptureDefaults: {+ deviceId: audioDeviceId || undefined,+ },+ publishDefaults: {+ red: true,+ simulcast: false,+ videoEncoding: LANDSCAPE_VIDEO.encoding,+ },+ })++ const bumpRevision = () => setRevision((current) => current + 1)+ nextRoom+ .on(RoomEvent.Connected, bumpRevision)+ .on(RoomEvent.ConnectionStateChanged, bumpRevision)+ .on(RoomEvent.ParticipantConnected, bumpRevision)+ .on(RoomEvent.ParticipantDisconnected, bumpRevision)+ .on(RoomEvent.TrackSubscribed, bumpRevision)+ .on(RoomEvent.TrackUnsubscribed, bumpRevision)+ .on(RoomEvent.TrackPublished, bumpRevision)+ .on(RoomEvent.TrackUnpublished, bumpRevision)+ .on(RoomEvent.TrackMuted, bumpRevision)+ .on(RoomEvent.TrackUnmuted, bumpRevision)+ .on(RoomEvent.LocalTrackPublished, bumpRevision)+ .on(RoomEvent.LocalTrackUnpublished, bumpRevision)+ .on(RoomEvent.Disconnected, bumpRevision)++ setPreviewStream((current) => {+ stopMediaStream(current)+ return null+ })+ setRoom(nextRoom)++ await nextRoom.connect(+ details.serverUrl,+ details.participantToken,+ CONNECT_OPTIONS+ )++ if (cameraEnabled) {+ await nextRoom.localParticipant.setCameraEnabled(true, {+ deviceId: videoDeviceId || undefined,+ frameRate: 30,+ resolution: LANDSCAPE_VIDEO,+ })+ }++ if (micEnabled) {+ await nextRoom.localParticipant.setMicrophoneEnabled(true, {+ deviceId: audioDeviceId || undefined,+ })+ }++ setJoinState("connected")+ bumpRevision()+ } catch (error) {+ nextRoom?.disconnect()+ room?.disconnect()+ const message =+ error instanceof Error ? error.message : "Unable to join the room."+ setErrorMessage(message)+ setJoinState("setup")+ setRoom(null)+ }+ }++ async function leaveRoom() {+ room?.disconnect()+ setRoom(null)+ setJoinState("setup")+ setRevision((current) => current + 1)+ await refreshDevices()+ }++ async function copyRoomUrl() {+ await copyTextToClipboard(roomUrl)+ }++ async function toggleMicrophone() {+ const nextEnabled = !micEnabled+ setMicEnabled(nextEnabled)+ if (!nextEnabled && !cameraEnabled) {+ setPreviewStream((current) => {+ stopMediaStream(current)+ return null+ })+ }++ if (room) {+ await room.localParticipant.setMicrophoneEnabled(nextEnabled, {+ deviceId: audioDeviceId || undefined,+ })+ }+ }++ async function toggleCamera() {+ const nextEnabled = !cameraEnabled+ setCameraEnabled(nextEnabled)+ if (!nextEnabled && !micEnabled) {+ setPreviewStream((current) => {+ stopMediaStream(current)+ return null+ })+ }++ if (room) {+ await room.localParticipant.setCameraEnabled(nextEnabled, {+ deviceId: videoDeviceId || undefined,+ frameRate: 30,+ resolution: LANDSCAPE_VIDEO,+ })+ }+ }++ async function selectAudioDevice(deviceId: string) {+ setAudioDeviceId(deviceId)++ if (room && micEnabled) {+ await room.localParticipant.setMicrophoneEnabled(true, {+ deviceId,+ })+ setRevision((current) => current + 1)+ }+ }++ function selectAudioOutputDevice(deviceId: string) {+ setAudioOutputDeviceId(deviceId)+ }++ async function selectVideoDevice(deviceId: string) {+ setVideoDeviceId(deviceId)++ if (room && cameraEnabled) {+ await room.localParticipant.setCameraEnabled(true, {+ deviceId,+ frameRate: 30,+ resolution: LANDSCAPE_VIDEO,+ })+ setRevision((current) => current + 1)+ }+ }++ function retryPreview() {+ setMicEnabled(true)+ setCameraEnabled(true)+ setPreviewErrorMessage(null)+ setPreviewRequestKey((current) => current + 1)+ }++ return (+ <main className="min-h-[calc(100svh-4rem)] bg-background text-foreground">+ <div className="flex min-h-[calc(100svh-4rem)] flex-col">+ <div+ className={cn(+ "flex w-full flex-1 flex-col",+ isConnected+ ? "gap-0 px-0 pb-0"+ : "mx-auto max-w-6xl gap-6 px-6 pb-12"+ )}+ >+ {errorMessage ? (+ <Alert variant="destructive" className="mx-auto w-full max-w-3xl">+ <AlertCircleIcon />+ <AlertTitle>Connection needs attention</AlertTitle>+ <AlertDescription>{errorMessage}</AlertDescription>+ </Alert>+ ) : null}++ {isConnected ? (+ <ConnectedMeeting+ room={room}+ participants={participants}+ participantName={participantName}+ translationLanguage={translationLanguage}+ micEnabled={micEnabled}+ cameraEnabled={cameraEnabled}+ audioInputs={audioInputs}+ audioOutputs={audioOutputs}+ videoInputs={videoInputs}+ audioDeviceId={audioDeviceId}+ audioOutputDeviceId={audioOutputDeviceId}+ videoDeviceId={videoDeviceId}+ onCopyRoomUrl={copyRoomUrl}+ onLeaveRoom={leaveRoom}+ onTranslationLanguageChange={setTranslationLanguage}+ onAudioDeviceChange={(deviceId) => {+ void selectAudioDevice(deviceId)+ }}+ onAudioOutputDeviceChange={selectAudioOutputDevice}+ onToggleCamera={() => {+ void toggleCamera()+ }}+ onToggleMicrophone={() => {+ void toggleMicrophone()+ }}+ onVideoDeviceChange={(deviceId) => {+ void selectVideoDevice(deviceId)+ }}+ />+ ) : (+ <form+ onSubmit={joinRoom}+ className="grid flex-1 content-center items-start gap-12 py-8 md:grid-cols-[minmax(0,1fr)_18rem] lg:grid-cols-[minmax(0,44rem)_22rem]"+ >+ <section className="flex flex-col items-center gap-4">+ <div className="relative grid aspect-video w-full max-w-[43rem] place-items-center overflow-hidden rounded-xl bg-foreground text-background shadow-lg">+ <Badge+ variant="secondary"+ className="absolute end-4 top-4 z-10"+ >+ HD+ </Badge>++ {previewStream && cameraEnabled ? (+ <video+ ref={previewVideoRef}+ autoPlay+ muted+ playsInline+ className="size-full scale-x-[-1] object-contain"+ />+ ) : previewErrorMessage ? (+ <div className="flex flex-col items-center gap-5 px-6 text-center text-background">+ <p className="text-xl font-medium">Camera blocked</p>+ <Button type="button" onClick={retryPreview}>+ Retry+ </Button>+ </div>+ ) : (+ <div className="flex flex-col items-center gap-3 text-center text-background/70">+ <VideoOffIcon className="size-10" />+ </div>+ )}++ <div className="absolute inset-x-0 bottom-5 flex items-center justify-center gap-3">+ <Button+ type="button"+ variant="secondary"+ size="icon"+ className="rounded-full"+ >+ <BrandIcon src="/icons/ellipsis.svg" alt="" />+ </Button>+ <Button+ type="button"+ variant={micEnabled ? "secondary" : "destructive"}+ size="icon"+ className="rounded-full"+ onClick={() => {+ void toggleMicrophone()+ }}+ >+ <BrandIcon+ src={+ micEnabled+ ? "/icons/microphone.svg"+ : "/icons/microphone-slash.svg"+ }+ alt=""+ />+ </Button>+ <Button+ type="button"+ variant={cameraEnabled ? "secondary" : "destructive"}+ size="icon"+ className="rounded-full"+ onClick={() => {+ void toggleCamera()+ }}+ >+ <BrandIcon+ src={+ cameraEnabled+ ? "/icons/camera.svg"+ : "/icons/video-slash.svg"+ }+ alt=""+ />+ </Button>+ <Button+ type="button"+ variant="secondary"+ size="icon"+ className="rounded-full"+ >+ <BrandIcon src="/icons/settings.svg" alt="" />+ </Button>+ </div>+ </div>++ <div className="flex w-full max-w-[43rem] flex-wrap justify-center gap-2">+ {hasMounted ? (+ <>+ <DeviceSelect+ value={audioDeviceId}+ onValueChange={setAudioDeviceId}+ placeholder="Microphone"+ iconSrc="/icons/microphone.svg"+ >+ {audioInputs.map((device, index) => (+ <SelectItem+ key={device.deviceId}+ value={device.deviceId}+ >+ {getDeviceLabel(device, "Microphone", index)}+ </SelectItem>+ ))}+ </DeviceSelect>+ <DeviceSelect+ value={videoDeviceId}+ onValueChange={setVideoDeviceId}+ placeholder="Camera"+ iconSrc="/icons/camera.svg"+ >+ {videoInputs.map((device, index) => (+ <SelectItem+ key={device.deviceId}+ value={device.deviceId}+ >+ {getDeviceLabel(device, "Camera", index)}+ </SelectItem>+ ))}+ </DeviceSelect>+ </>+ ) : (+ <>+ <DeviceSelectShell+ placeholder="Microphone"+ iconSrc="/icons/microphone.svg"+ />+ <DeviceSelectShell+ placeholder="Camera"+ iconSrc="/icons/camera.svg"+ />+ </>+ )}+ </div>+ </section>++ <section className="mx-auto flex w-full max-w-sm flex-col items-stretch text-left">+ <div className="flex flex-col gap-4">+ <label className="flex flex-col gap-2 font-sans text-base font-medium tracking-normal text-foreground">+ <span>Meeting code</span>+ <Input+ aria-label="Meeting code"+ autoComplete="off"+ className="h-12 w-full rounded-full border border-foreground/25 bg-background px-4 font-sans text-base tracking-normal text-foreground placeholder:text-muted-foreground focus-visible:border-foreground focus-visible:ring-foreground/20 md:text-base"+ maxLength={120}+ placeholder="room-123"+ value={roomName}+ onChange={(event) => setRoomName(event.target.value)}+ />+ </label>+ <label className="flex flex-col gap-2 font-sans text-base font-medium tracking-normal text-foreground">+ <span>Name</span>+ <Input+ aria-label="Your name"+ autoComplete="name"+ className="h-12 w-full rounded-full border border-foreground/25 bg-background px-4 font-sans text-base tracking-normal text-foreground placeholder:text-muted-foreground focus-visible:border-foreground focus-visible:ring-foreground/20 md:text-base"+ maxLength={80}+ placeholder="Blossom"+ value={participantName}+ onChange={(event) =>+ setParticipantName(event.target.value)+ }+ />+ </label>+ </div>+ <LobbyPresence participants={lobbyParticipants} />+ <Button+ type="submit"+ size="lg"+ className="mt-8 h-12 w-full rounded-full bg-foreground font-sans text-base font-medium tracking-normal text-background hover:bg-foreground/90"+ disabled={joinState === "connecting"}+ >+ {joinState === "connecting" ? (+ <Spinner data-icon="inline-start" />+ ) : null}+ Join now+ </Button>+ </section>+ </form>+ )}+ </div>+ </div>+ </main>+ )+}++function LobbyPresence({+ participants,+}: {+ participants: ParticipantPresence[]+}) {+ if (participants.length === 0) {+ return (+ <p className="mt-5 font-sans text-base font-medium tracking-normal text-muted-foreground">+ No one else is here+ </p>+ )+ }++ return (+ <div className="mt-5 flex flex-wrap gap-2">+ {participants.map((participant) => (+ <Badge key={participant.identity} variant="secondary">+ {participant.name}+ </Badge>+ ))}+ </div>+ )+}++function BrandIcon({+ src,+ alt,+ className,+}: {+ src: string+ alt: string+ className?: string+}) {+ return (+ <Image+ src={src}+ alt={alt}+ width={20}+ height={20}+ className={cn("size-5 dark:invert", className)}+ />+ )+}++function DeviceSelect({+ value,+ onValueChange,+ placeholder,+ iconSrc,+ disabled,+ children,+}: {+ value: string+ onValueChange: (value: string) => void+ placeholder: string+ iconSrc: string+ disabled?: boolean+ children: React.ReactNode+}) {+ return (+ <Select value={value} onValueChange={onValueChange} disabled={disabled}>+ <SelectTrigger className="h-9 w-72 max-w-[calc(100vw-3rem)] rounded-full border bg-background">+ <BrandIcon src={iconSrc} alt="" />+ <SelectValue placeholder={placeholder} />+ </SelectTrigger>+ <SelectContent>+ <SelectGroup>{children}</SelectGroup>+ </SelectContent>+ </Select>+ )+}++function DeviceSelectShell({+ placeholder,+ iconSrc,+}: {+ placeholder: string+ iconSrc: string+}) {+ return (+ <button+ type="button"+ tabIndex={-1}+ className="flex h-9 max-w-52 items-center justify-between gap-1.5 rounded-full border bg-background px-3 py-2 text-sm text-muted-foreground"+ aria-hidden="true"+ >+ <BrandIcon src={iconSrc} alt="" />+ <span>{placeholder}</span>+ </button>+ )+}++function ConnectedMeeting({+ room,+ participants,+ participantName,+ translationLanguage,+ micEnabled,+ cameraEnabled,+ audioInputs,+ audioOutputs,+ videoInputs,+ audioDeviceId,+ audioOutputDeviceId,+ videoDeviceId,+ onCopyRoomUrl,+ onLeaveRoom,+ onTranslationLanguageChange,+ onAudioDeviceChange,+ onAudioOutputDeviceChange,+ onToggleCamera,+ onToggleMicrophone,+ onVideoDeviceChange,+}: {+ room: Room+ participants: Participant[]+ participantName: string+ translationLanguage: string+ micEnabled: boolean+ cameraEnabled: boolean+ audioInputs: MediaDeviceInfo[]+ audioOutputs: MediaDeviceInfo[]+ videoInputs: MediaDeviceInfo[]+ audioDeviceId: string+ audioOutputDeviceId: string+ videoDeviceId: string+ onCopyRoomUrl: () => void+ onLeaveRoom: () => void+ onTranslationLanguageChange: (language: string) => void+ onAudioDeviceChange: (deviceId: string) => void+ onAudioOutputDeviceChange: (deviceId: string) => void+ onToggleCamera: () => void+ onToggleMicrophone: () => void+ onVideoDeviceChange: (deviceId: string) => void+}) {+ const localParticipant = room.localParticipant+ const remoteParticipants = participants.filter(+ (participant) => participant !== localParticipant+ )+ const localName =+ localParticipant.name || participantName.trim() || DEFAULT_PARTICIPANT_NAME+ const visibleRemoteParticipants = remoteParticipants.slice(+ 0,+ MAX_VISIBLE_PARTICIPANTS - 1+ )+ const meetingParticipants: MeetingTileModel[] = [+ {+ participant: localParticipant,+ label: localName,+ isLocal: true,+ highlighted: true,+ visualIndex: visibleRemoteParticipants.length,+ },+ ...visibleRemoteParticipants.map((participant, index) => ({+ participant,+ label: getParticipantLabel(participant, index + 1),+ isLocal: false,+ highlighted: false,+ visualIndex: index,+ })),+ ]+ const [openDeviceMenu, setOpenDeviceMenu] =+ React.useState<DeviceMenuKind | null>(null)+ const [quickTranslationMenuOpen, setQuickTranslationMenuOpen] =+ React.useState(false)+ const [translationSettingsOpen, setTranslationSettingsOpen] =+ React.useState(false)+ const translationPanelRef = React.useRef<HTMLDivElement | null>(null)+ const translationTriggerRef = React.useRef<HTMLDivElement | null>(null)+ const [translationEnabled, setTranslationEnabled] = React.useState(false)+ const [captionsEnabled, setCaptionsEnabled] = React.useState(true)+ const [sourceTranscriptionEnabled, setSourceTranscriptionEnabled] =+ React.useState(false)+ const [translationMix, setTranslationMix] = React.useState(85)+ const [participantTranslations, setParticipantTranslations] = React.useState<+ Record<string, ParticipantTranslationSnapshot>+ >({})+ const localAudioLevel = useParticipantAudioLevel(localParticipant, micEnabled)+ const hasRemoteAudioTrack = visibleRemoteParticipants.some((participant) =>+ Boolean(getParticipantAudioMediaStreamTrack(participant))+ )+ const translatedVolume = translationEnabled ? translationMix / 100 : 0+ const sourceVolume = translationEnabled ? (100 - translationMix) / 100 : 1+ const translationStatus = getAggregateTranslationStatus(+ visibleRemoteParticipants.map(+ (participant) => participantTranslations[participant.identity]+ )+ )+ const translationError =+ visibleRemoteParticipants+ .map(+ (participant) => participantTranslations[participant.identity]?.error+ )+ .find(Boolean) ?? null++ const updateParticipantTranslation = React.useCallback(+ (nextTranslation: ParticipantTranslationSnapshot) => {+ setParticipantTranslations((current) => {+ const previous = current[nextTranslation.participantId]++ if (areParticipantTranslationsEqual(previous, nextTranslation)) {+ return current+ }++ return {+ ...current,+ [nextTranslation.participantId]: nextTranslation,+ }+ })+ },+ []+ )++ const removeParticipantTranslation = React.useCallback(+ (participantId: string) => {+ setParticipantTranslations((current) => {+ if (!current[participantId]) {+ return current+ }++ const nextTranslations = { ...current }+ delete nextTranslations[participantId]+ return nextTranslations+ })+ },+ []+ )++ function setDeviceMenuOpen(menu: DeviceMenuKind, open: boolean) {+ if (open) {+ setQuickTranslationMenuOpen(false)+ setTranslationSettingsOpen(false)+ }++ setOpenDeviceMenu((current) =>+ open ? menu : current === menu ? null : current+ )+ }++ React.useEffect(() => {+ if (!translationSettingsOpen) {+ return+ }++ function targetIsWithinTranslationControls(target: EventTarget | null) {+ if (!(target instanceof Node)) {+ return false+ }++ if (+ translationPanelRef.current?.contains(target) ||+ translationTriggerRef.current?.contains(target)+ ) {+ return true+ }++ return (+ target instanceof Element &&+ target.closest('[data-slot="select-content"]') !== null+ )+ }++ function handlePointerDown(event: PointerEvent) {+ if (!targetIsWithinTranslationControls(event.target)) {+ setTranslationSettingsOpen(false)+ }+ }++ function handleFocusIn(event: FocusEvent) {+ if (!targetIsWithinTranslationControls(event.target)) {+ setTranslationSettingsOpen(false)+ }+ }++ function handleKeyDown(event: KeyboardEvent) {+ if (event.key === "Escape") {+ setTranslationSettingsOpen(false)+ }+ }++ document.addEventListener("pointerdown", handlePointerDown, true)+ document.addEventListener("focusin", handleFocusIn, true)+ document.addEventListener("keydown", handleKeyDown)++ return () => {+ document.removeEventListener("pointerdown", handlePointerDown, true)+ document.removeEventListener("focusin", handleFocusIn, true)+ document.removeEventListener("keydown", handleKeyDown)+ }+ }, [translationSettingsOpen])++ return (+ <section className="relative mx-[calc(50%-50vw)] flex h-[calc(100svh-4rem)] min-h-0 w-screen overflow-hidden bg-background text-foreground dark:bg-black dark:text-white">+ <div className="flex min-h-0 min-w-0 flex-1 flex-col">+ <div+ className={cn(+ "grid min-h-0 flex-1 auto-rows-fr gap-3 p-4",+ getMeetingGridClassName(meetingParticipants.length)+ )}+ >+ {meetingParticipants.map((tile) => {+ const tileClassName = cn(+ "bg-zinc-900 dark:bg-black",+ getMeetingTileOrderClassName(tile.visualIndex),+ getMeetingTileClassName(+ tile.visualIndex,+ meetingParticipants.length+ )+ )++ if (tile.isLocal) {+ return (+ <MeetingTile+ key={tile.participant.identity}+ participant={tile.participant}+ label={tile.label}+ isLocal={tile.isLocal}+ highlighted={tile.highlighted}+ audioOutputDeviceId={audioOutputDeviceId}+ tileClassName={tileClassName}+ />+ )+ }++ return (+ <TranslatedMeetingTile+ key={tile.participant.identity}+ tile={tile}+ audioOutputDeviceId={audioOutputDeviceId}+ captionsEnabled={captionsEnabled}+ language={translationLanguage}+ sourceTranscriptionEnabled={sourceTranscriptionEnabled}+ sourceTranscriptionVisible={sourceTranscriptionEnabled}+ sourceVolume={sourceVolume}+ tileClassName={tileClassName}+ translatedVolume={translatedVolume}+ translationEnabled={translationEnabled}+ onTranslationChange={updateParticipantTranslation}+ onTranslationRemove={removeParticipantTranslation}+ />+ )+ })}+ </div>++ <div className="shrink-0 px-6 pb-5">+ <div className="grid items-center gap-4 md:grid-cols-[1fr_auto_1fr]">+ <div className="flex justify-center md:col-start-1 md:justify-start">+ <QuickTranslationPicker+ open={quickTranslationMenuOpen}+ enabled={translationEnabled}+ language={translationLanguage}+ onOpenChange={(open) => {+ setQuickTranslationMenuOpen(open)+ if (open) {+ setOpenDeviceMenu(null)+ setTranslationSettingsOpen(false)+ }+ }}+ onSelectLanguage={(language) => {+ onTranslationLanguageChange(language)+ setTranslationEnabled(true)+ setQuickTranslationMenuOpen(false)+ }}+ onSelectOff={() => {+ setTranslationEnabled(false)+ setQuickTranslationMenuOpen(false)+ }}+ />+ </div>++ <div className="flex items-center justify-center gap-2 md:col-start-2">+ <div ref={translationTriggerRef}>+ <InCallIconButton+ ariaLabel={+ translationSettingsOpen+ ? "Close translation"+ : "Open translation"+ }+ selected={translationSettingsOpen || translationEnabled}+ onClick={() => {+ setOpenDeviceMenu(null)+ setTranslationSettingsOpen((current) => !current)+ }}+ >+ <BrandIcon src="/icons/ellipsis.svg" alt="" />+ </InCallIconButton>+ </div>+ <InCallDeviceControl+ active={micEnabled}+ icon={+ <BrandIcon+ src={+ micEnabled+ ? "/icons/microphone.svg"+ : "/icons/microphone-slash.svg"+ }+ alt=""+ className={cn(!micEnabled && "invert")}+ />+ }+ audioLevel={localAudioLevel}+ menuOpen={openDeviceMenu === "audio"}+ menuLabel="Audio devices"+ toggleLabel={+ micEnabled ? "Mute microphone" : "Unmute microphone"+ }+ onMenuOpenChange={(open) => setDeviceMenuOpen("audio", open)}+ onToggle={() => {+ setOpenDeviceMenu(null)+ onToggleMicrophone()+ }}+ menu={+ <DeviceMenu+ sections={[+ {+ label: "Microphone",+ emptyLabel: "No microphones",+ options: audioInputs.map((device, index) => ({+ id: device.deviceId,+ label: getDeviceLabel(device, "Microphone", index),+ selected: device.deviceId === audioDeviceId,+ onSelect: () => onAudioDeviceChange(device.deviceId),+ })),+ },+ {+ label: "Speakers",+ emptyLabel: "Default speaker",+ options:+ audioOutputs.length > 0+ ? audioOutputs.map((device, index) => ({+ id: device.deviceId,+ label: getDeviceLabel(device, "Speaker", index),+ selected:+ device.deviceId === audioOutputDeviceId,+ onSelect: () =>+ onAudioOutputDeviceChange(device.deviceId),+ }))+ : [+ {+ id: "default",+ label: "Default speaker",+ selected: !audioOutputDeviceId,+ onSelect: () => onAudioOutputDeviceChange(""),+ },+ ],+ },+ ]}+ />+ }+ />+ <InCallDeviceControl+ active={cameraEnabled}+ icon={+ <BrandIcon+ src={+ cameraEnabled+ ? "/icons/camera.svg"+ : "/icons/video-slash.svg"+ }+ alt=""+ className={cn(!cameraEnabled && "invert")}+ />+ }+ menuOpen={openDeviceMenu === "video"}+ menuLabel="Camera devices"+ toggleLabel={+ cameraEnabled ? "Turn camera off" : "Turn camera on"+ }+ onMenuOpenChange={(open) => setDeviceMenuOpen("video", open)}+ onToggle={() => {+ setOpenDeviceMenu(null)+ onToggleCamera()+ }}+ menu={+ <DeviceMenu+ sections={[+ {+ label: "Camera",+ emptyLabel: "No cameras",+ options: videoInputs.map((device, index) => ({+ id: device.deviceId,+ label: getDeviceLabel(device, "Camera", index),+ selected: device.deviceId === videoDeviceId,+ onSelect: () => onVideoDeviceChange(device.deviceId),+ })),+ },+ ]}+ />+ }+ />+ <button+ type="button"+ aria-label="Leave"+ className="grid h-11 w-16 cursor-pointer place-items-center rounded-full bg-[#d84a38] text-white transition hover:bg-[#c23b2b]"+ onClick={onLeaveRoom}+ >+ <PhoneOffIcon className="size-5" />+ </button>+ </div>++ <div className="flex justify-center gap-2 md:col-start-3 md:justify-end">+ <InCallIconButton+ ariaLabel="Copy room link"+ onClick={onCopyRoomUrl}+ >+ <CopyIcon className="size-5" />+ </InCallIconButton>+ </div>+ </div>++ {translationSettingsOpen ? (+ <TranslationPanel+ rootRef={translationPanelRef}+ enabled={translationEnabled}+ language={translationLanguage}+ captionsEnabled={captionsEnabled}+ sourceTranscriptionEnabled={sourceTranscriptionEnabled}+ mix={translationMix}+ status={translationStatus}+ error={translationError}+ disabled={!hasRemoteAudioTrack}+ onCaptionsEnabledChange={setCaptionsEnabled}+ onEnabledChange={setTranslationEnabled}+ onLanguageChange={onTranslationLanguageChange}+ onMixChange={setTranslationMix}+ onSourceTranscriptionEnabledChange={setSourceTranscriptionEnabled}+ />+ ) : null}+ </div>+ </div>++ </section>+ )+}++function getParticipantLabel(participant: Participant, position: number) {+ return participant.name || participant.identity || `Participant ${position}`+}++function useParticipantAudioLevel(participant: Participant, enabled: boolean) {+ const [level, setLevel] = React.useState(0)++ React.useEffect(() => {+ if (!enabled) {+ return+ }++ let frame = 0+ let displayedLevel = 0++ function updateLevel() {+ const liveLevel = enabled ? participant.audioLevel : 0+ const amplifiedLevel =+ liveLevel > SPEAKING_LEVEL_FLOOR+ ? Math.min(1, liveLevel * 1.8 + 0.08)+ : 0+ const nextLevel =+ amplifiedLevel > displayedLevel+ ? amplifiedLevel+ : Math.max(0, displayedLevel * 0.82)++ if (Math.abs(nextLevel - displayedLevel) > 0.01) {+ displayedLevel = nextLevel+ setLevel(nextLevel)+ } else if (displayedLevel !== 0 && nextLevel < 0.02) {+ displayedLevel = 0+ setLevel(0)+ }++ frame = window.requestAnimationFrame(updateLevel)+ }++ updateLevel()++ return () => {+ window.cancelAnimationFrame(frame)+ }+ }, [enabled, participant])++ return enabled ? level : 0+}++function getMeetingGridClassName(participantCount: number) {+ if (participantCount <= 1) {+ return "grid-cols-1"+ }++ if (participantCount <= 4) {+ return "grid-cols-1 md:grid-cols-2"+ }++ return "grid-cols-1 sm:grid-cols-2 xl:grid-cols-6"+}++function getMeetingTileClassName(index: number, participantCount: number) {+ if (participantCount === 3 && index === 2) {+ return "md:col-span-2 md:mx-auto md:w-1/2"+ }++ if (participantCount >= 5) {+ return cn(+ "xl:col-span-2",+ participantCount === 5 && index === 3 && "xl:col-start-2"+ )+ }++ return undefined+}++function getMeetingTileOrderClassName(index: number) {+ switch (index) {+ case 0:+ return "order-1"+ case 1:+ return "order-2"+ case 2:+ return "order-3"+ case 3:+ return "order-4"+ case 4:+ return "order-5"+ default:+ return "order-6"+ }+}++function TranslatedMeetingTile({+ tile,+ audioOutputDeviceId,+ captionsEnabled,+ language,+ sourceTranscriptionEnabled,+ sourceTranscriptionVisible,+ sourceVolume,+ tileClassName,+ translatedVolume,+ translationEnabled,+ onTranslationChange,+ onTranslationRemove,+}: {+ tile: MeetingTileModel+ audioOutputDeviceId?: string+ captionsEnabled: boolean+ language: string+ sourceTranscriptionEnabled: boolean+ sourceTranscriptionVisible: boolean+ sourceVolume: number+ tileClassName?: string+ translatedVolume: number+ translationEnabled: boolean+ onTranslationChange: (translation: ParticipantTranslationSnapshot) => void+ onTranslationRemove: (participantId: string) => void+}) {+ const sourceTrack = getParticipantAudioMediaStreamTrack(tile.participant)+ const translationActive = Boolean(+ sourceTrack && (translationEnabled || sourceTranscriptionEnabled)+ )+ const translation = useRemoteTranslation({+ enabled: translationActive,+ sourceTrack,+ language,+ sourceTranscriptionEnabled,+ noiseReductionEnabled: false,+ translatedVolume,+ })+ const participantId = tile.participant.identity++ React.useEffect(() => {+ onTranslationChange({+ participantId,+ participantName: tile.label,+ hasSourceTrack: Boolean(sourceTrack),+ status: sourceTrack ? translation.status : "idle",+ error: sourceTrack ? translation.error : null,+ sourceTranscript: sourceTrack ? translation.sourceTranscript : "",+ translatedTranscript: sourceTrack ? translation.translatedTranscript : "",+ sourceSubtitle: sourceTrack ? translation.sourceSubtitle : "",+ translatedSubtitle: sourceTrack ? translation.translatedSubtitle : "",+ hasOutputAudio: sourceTrack ? translation.hasOutputAudio : false,+ })+ }, [+ onTranslationChange,+ participantId,+ sourceTrack,+ tile.label,+ translation.error,+ translation.hasOutputAudio,+ translation.sourceSubtitle,+ translation.sourceTranscript,+ translation.status,+ translation.translatedSubtitle,+ translation.translatedTranscript,+ ])++ React.useEffect(() => {+ return () => {+ onTranslationRemove(participantId)+ }+ }, [onTranslationRemove, participantId])++ return (+ <MeetingTile+ participant={tile.participant}+ label={tile.label}+ isLocal={tile.isLocal}+ highlighted={tile.highlighted}+ audioOutputDeviceId={audioOutputDeviceId}+ sourceVolume={+ translationEnabled && sourceTrack && translation.hasOutputAudio+ ? sourceVolume+ : 1+ }+ sourceSubtitle={+ captionsEnabled && sourceTranscriptionVisible+ ? translation.sourceSubtitle+ : ""+ }+ translatedSubtitle={+ translationEnabled && captionsEnabled+ ? translation.translatedSubtitle+ : ""+ }+ tileClassName={tileClassName}+ />+ )+}++function MeetingTile({+ participant,+ label,+ isLocal,+ highlighted,+ audioOutputDeviceId,+ sourceVolume = 1,+ sourceSubtitle,+ translatedSubtitle,+ tileClassName,+}: {+ participant: Participant+ label: string+ isLocal?: boolean+ highlighted?: boolean+ audioOutputDeviceId?: string+ sourceVolume?: number+ sourceSubtitle?: string+ translatedSubtitle?: string+ tileClassName?: string+}) {+ const videoRef = React.useRef<HTMLVideoElement | null>(null)+ const audioRef = React.useRef<HTMLAudioElement | null>(null)++ const videoPublication = participant.getTrackPublication(Track.Source.Camera)+ const audioPublication = participant.getTrackPublication(+ Track.Source.Microphone+ )+ const videoTrack = videoPublication?.videoTrack+ const audioTrack = audioPublication?.audioTrack++ React.useEffect(() => {+ const element = videoRef.current+ if (!element || !videoTrack) {+ return+ }++ videoTrack.attach(element)++ return () => {+ videoTrack.detach(element)+ }+ }, [videoTrack])++ React.useEffect(() => {+ const element = audioRef.current+ if (!element || !audioTrack || isLocal) {+ return+ }++ audioTrack.attach(element)+ element.volume = sourceVolume++ return () => {+ audioTrack.detach(element)+ }+ }, [audioTrack, isLocal, sourceVolume])++ React.useEffect(() => {+ if (audioRef.current) {+ audioRef.current.volume = sourceVolume+ }+ }, [sourceVolume])++ React.useEffect(() => {+ const element = audioRef.current as+ | (HTMLAudioElement & { setSinkId?: (sinkId: string) => Promise<void> })+ | null++ if (!element?.setSinkId) {+ return+ }++ element.setSinkId(audioOutputDeviceId || "").catch(() => {})+ }, [audioOutputDeviceId])++ return (+ <div+ className={cn(+ "relative grid min-h-0 overflow-hidden rounded-2xl ring-1 ring-border",+ "shadow-[0_1px_0_rgba(255,255,255,0.5)_inset] dark:shadow-[0_1px_0_rgba(255,255,255,0.08)_inset] dark:ring-white/10",+ highlighted && "ring-2 ring-[#8ab4f8]",+ tileClassName+ )}+ >+ {videoTrack ? (+ <video+ ref={videoRef}+ autoPlay+ muted={isLocal}+ playsInline+ className={cn("size-full object-contain", isLocal && "scale-x-[-1]")}+ />+ ) : (+ <div className="grid size-full place-items-center">+ <div className="grid size-16 place-items-center rounded-full bg-white/20 text-2xl font-medium">+ {getInitial(label)}+ </div>+ </div>+ )}+ {!isLocal ? <audio ref={audioRef} autoPlay /> : null}+ {translatedSubtitle || sourceSubtitle ? (+ <div className="pointer-events-none absolute inset-x-5 bottom-14 flex flex-col items-center gap-1 text-center">+ {translatedSubtitle ? (+ <p className="max-w-3xl rounded-xl bg-black/70 px-3 py-2 text-base leading-snug font-medium text-white shadow-lg">+ {translatedSubtitle}+ </p>+ ) : null}+ {sourceSubtitle ? (+ <p className="max-w-2xl rounded-lg bg-black/45 px-2.5 py-1.5 text-xs leading-snug font-medium text-white/85">+ {sourceSubtitle}+ </p>+ ) : null}+ </div>+ ) : null}+ <div className="absolute start-4 bottom-4 flex items-center gap-2 text-sm font-medium text-white">+ {audioPublication?.isMuted ? <VideoOffIcon className="size-4" /> : null}+ <span className="drop-shadow">{label}</span>+ </div>+ </div>+ )+}++function TranslationPanel({+ rootRef,+ enabled,+ language,+ captionsEnabled,+ sourceTranscriptionEnabled,+ mix,+ status,+ error,+ disabled,+ onCaptionsEnabledChange,+ onEnabledChange,+ onLanguageChange,+ onMixChange,+ onSourceTranscriptionEnabledChange,+}: {+ rootRef?: React.Ref<HTMLDivElement>+ enabled: boolean+ language: string+ captionsEnabled: boolean+ sourceTranscriptionEnabled: boolean+ mix: number+ status: "idle" | "connecting" | "connected" | "error"+ error: string | null+ disabled: boolean+ onCaptionsEnabledChange: (enabled: boolean) => void+ onEnabledChange: (enabled: boolean) => void+ onLanguageChange: (language: string) => void+ onMixChange: (mix: number) => void+ onSourceTranscriptionEnabledChange: (enabled: boolean) => void+}) {+ return (+ <div+ ref={rootRef}+ className="absolute bottom-20 left-1/2 z-20 flex w-[min(28rem,calc(100vw-2rem))] -translate-x-1/2 flex-col gap-4 rounded-2xl border border-border bg-background p-4 shadow-xl dark:border-white/15 dark:bg-black"+ >+ <div className="flex items-center justify-between gap-4">+ <span className="text-sm font-medium">Translation</span>+ <Switch+ checked={enabled}+ disabled={disabled}+ aria-label="Translation"+ onCheckedChange={onEnabledChange}+ />+ </div>++ <label className="flex items-center justify-between gap-4 text-sm font-medium">+ <span>Preferred Output language</span>+ <OutputLanguageSelect+ value={language}+ disabled={enabled && status === "connecting"}+ triggerClassName="h-9 w-44 rounded-full border bg-background"+ onValueChange={onLanguageChange}+ />+ </label>++ <div className="flex flex-col gap-2">+ <div className="flex items-center justify-between text-sm font-medium">+ <span>Audio mix</span>+ <span className="text-muted-foreground dark:text-white/60">+ {mix}%+ </span>+ </div>+ <Slider+ value={[mix]}+ min={0}+ max={100}+ step={5}+ aria-label="Translated audio mix"+ onValueChange={(value) => onMixChange(value[0] ?? mix)}+ />+ <div className="flex items-center justify-between text-xs font-medium text-muted-foreground dark:text-white/60">+ <span>Original {100 - mix}%</span>+ <span>Translated {mix}%</span>+ </div>+ </div>++ <div className="grid gap-3 sm:grid-cols-2">+ <TranslationSwitch+ checked={captionsEnabled}+ label="Captions"+ onCheckedChange={onCaptionsEnabledChange}+ />+ <TranslationSwitch+ checked={sourceTranscriptionEnabled}+ label="Source text"+ onCheckedChange={onSourceTranscriptionEnabledChange}+ />+ </div>++ {status === "connecting" ? (+ <div className="flex items-center gap-2 text-sm text-muted-foreground dark:text-white/70">+ <Spinner data-icon="inline-start" />+ <span>Connecting</span>+ </div>+ ) : null}++ {error ? (+ <p className="text-sm font-medium text-destructive">{error}</p>+ ) : null}+ </div>+ )+}++function OutputLanguageSelect({+ value,+ disabled,+ triggerClassName,+ onValueChange,+}: {+ value: string+ disabled?: boolean+ triggerClassName?: string+ onValueChange: (language: string) => void+}) {+ const hasMounted = useMounted()+ const selectedLabel = getTranslationLanguageLabel(value)++ if (!hasMounted) {+ return (+ <button+ type="button"+ aria-disabled="true"+ aria-label="Preferred Output language"+ className={cn(+ "flex items-center justify-between gap-1.5 whitespace-nowrap",+ triggerClassName+ )}+ >+ <span className="truncate">{selectedLabel}</span>+ <ChevronDownIcon className="pointer-events-none size-4 shrink-0 text-muted-foreground" />+ </button>+ )+ }++ return (+ <Select value={value} disabled={disabled} onValueChange={onValueChange}>+ <SelectTrigger+ aria-label="Preferred Output language"+ className={triggerClassName}+ >+ <SelectValue />+ </SelectTrigger>+ <SelectContent>+ <SelectGroup>+ {TRANSLATION_LANGUAGES.map((option) => (+ <SelectItem key={option.value} value={option.value}>+ {option.label}+ </SelectItem>+ ))}+ </SelectGroup>+ </SelectContent>+ </Select>+ )+}++function getTranslationLanguageLabel(value: string) {+ return (+ TRANSLATION_LANGUAGES.find((option) => option.value === value)?.label ||+ value+ )+}++async function copyTextToClipboard(text: string) {+ try {+ if (navigator.clipboard?.writeText) {+ await navigator.clipboard.writeText(text)+ return+ }+ } catch {+ // Fall back below for browser surfaces that block Clipboard API writes.+ }++ const textarea = document.createElement("textarea")+ textarea.value = text+ textarea.setAttribute("readonly", "")+ textarea.style.position = "fixed"+ textarea.style.opacity = "0"+ textarea.style.pointerEvents = "none"+ document.body.appendChild(textarea)+ textarea.select()++ try {+ document.execCommand("copy")+ } catch {+ return+ } finally {+ textarea.remove()+ }+}++function TranslationSwitch({+ checked,+ label,+ onCheckedChange,+}: {+ checked: boolean+ label: string+ onCheckedChange: (checked: boolean) => void+}) {+ return (+ <label className="flex items-center justify-between gap-2 rounded-xl bg-muted px-3 py-2 text-sm font-medium dark:bg-white/10">+ <span>{label}</span>+ <Switch+ size="sm"+ checked={checked}+ aria-label={label}+ onCheckedChange={onCheckedChange}+ />+ </label>+ )+}++function QuickTranslationPicker({+ open,+ enabled,+ language,+ onOpenChange,+ onSelectLanguage,+ onSelectOff,+}: {+ open: boolean+ enabled: boolean+ language: string+ onOpenChange: (open: boolean) => void+ onSelectLanguage: (language: string) => void+ onSelectOff: () => void+}) {+ const selectedLabel = enabled ? getTranslationLanguageLabel(language) : "Off"++ return (+ <Popover open={open} onOpenChange={onOpenChange}>+ <PopoverTrigger asChild>+ <button+ type="button"+ aria-label="Translation language"+ aria-expanded={open}+ className={cn(+ "flex h-11 max-w-[13rem] cursor-pointer items-center gap-2 rounded-full px-3 text-sm font-medium transition",+ enabled+ ? "bg-[#d2e3fc] text-[#174ea6] hover:bg-[#c2d7f8] dark:bg-[#8ab4f8] dark:text-[#111213] dark:hover:bg-[#a8c7fa]"+ : "bg-muted text-foreground hover:bg-muted/80 dark:bg-black dark:text-white dark:ring-1 dark:ring-white/15 dark:hover:bg-black"+ )}+ >+ <LanguagesIcon className="size-4 shrink-0" />+ <span className="truncate">{selectedLabel}</span>+ <ChevronDownIcon+ className={cn(+ "size-4 shrink-0 transition-transform duration-200",+ open && "rotate-180"+ )}+ />+ </button>+ </PopoverTrigger>+ <PopoverContent+ side="top"+ align="start"+ sideOffset={10}+ className="max-h-[min(28rem,calc(100svh-7rem))] w-56 overflow-y-auto rounded-2xl bg-[#151515] p-1.5 text-white shadow-2xl ring-1 ring-white/10"+ >+ <DeviceMenu+ sections={[+ {+ label: "Translation",+ emptyLabel: "No languages",+ options: [+ ...TRANSLATION_LANGUAGES.map((option) => ({+ id: option.value,+ label: option.label,+ selected: enabled && option.value === language,+ onSelect: () => onSelectLanguage(option.value),+ })),+ {+ id: "off",+ label: "Off",+ selected: !enabled,+ onSelect: onSelectOff,+ },+ ],+ },+ ]}+ />+ </PopoverContent>+ </Popover>+ )+}++function InCallDeviceControl({+ active,+ audioLevel = 0,+ icon,+ menu,+ menuLabel,+ menuOpen,+ toggleLabel,+ onMenuOpenChange,+ onToggle,+}: {+ active: boolean+ audioLevel?: number+ icon: React.ReactNode+ menu: React.ReactNode+ menuLabel: string+ menuOpen: boolean+ toggleLabel: string+ onMenuOpenChange: (open: boolean) => void+ onToggle: () => void+}) {+ return (+ <Popover open={menuOpen} onOpenChange={onMenuOpenChange}>+ <div+ className={cn(+ "flex h-11 overflow-hidden rounded-full transition",+ active+ ? "bg-muted text-foreground dark:bg-black dark:text-white dark:ring-1 dark:ring-white/15"+ : "bg-[#d84a38] text-white"+ )}+ >+ <button+ type="button"+ aria-label={toggleLabel}+ data-audio-active={audioLevel > 0}+ className={cn(+ "relative grid size-11 cursor-pointer place-items-center overflow-hidden transition",+ active+ ? "hover:bg-muted/80 dark:hover:bg-white/10"+ : "hover:bg-[#c23b2b]"+ )}+ onClick={onToggle}+ >+ {active ? (+ <span+ aria-hidden="true"+ className="pointer-events-none absolute inset-x-0 bottom-0 bg-[#8ab4f8]/35 transition-transform duration-75 ease-out dark:bg-[#8ab4f8]/45"+ style={{+ height: "100%",+ transform: `scaleY(${audioLevel})`,+ transformOrigin: "bottom",+ }}+ />+ ) : null}+ <span className="relative z-10 grid place-items-center">{icon}</span>+ </button>+ <PopoverTrigger asChild>+ <button+ type="button"+ aria-label={menuLabel}+ aria-expanded={menuOpen}+ className={cn(+ "grid h-11 w-9 cursor-pointer place-items-center border-s transition",+ active+ ? "border-foreground/10 hover:bg-muted/80 dark:border-white/10 dark:hover:bg-white/10"+ : "border-white/15 hover:bg-[#c23b2b]"+ )}+ >+ <ChevronDownIcon+ className={cn(+ "size-4 transition-transform duration-200",+ menuOpen && "rotate-180"+ )}+ />+ </button>+ </PopoverTrigger>+ </div>+ <PopoverContent+ side="top"+ align="center"+ sideOffset={10}+ className="max-h-[min(24rem,calc(100svh-7rem))] w-64 overflow-y-auto rounded-2xl bg-[#151515] p-1.5 text-white shadow-2xl ring-1 ring-white/10"+ >+ {menu}+ </PopoverContent>+ </Popover>+ )+}++function DeviceMenu({ sections }: { sections: DeviceMenuSection[] }) {+ return (+ <div role="menu" className="flex flex-col gap-1">+ {sections.map((section, sectionIndex) => (+ <React.Fragment key={section.label}>+ <div className="flex flex-col gap-1">+ <div className="px-2.5 pt-1.5 pb-1 text-[11px] font-semibold text-white/45 uppercase">+ {section.label}+ </div>+ {section.options.length > 0 ? (+ section.options.map((option) => (+ <button+ key={option.id}+ type="button"+ role="menuitemradio"+ aria-checked={option.selected}+ disabled={option.disabled}+ className={cn(+ "flex h-10 w-full cursor-pointer items-center justify-between gap-3 rounded-xl px-3 text-left text-sm font-medium text-white/90 transition disabled:cursor-default disabled:opacity-50",+ option.selected+ ? "bg-white/10 text-white"+ : "hover:bg-white/10"+ )}+ onClick={option.onSelect}+ >+ <span className="truncate">{option.label}</span>+ {option.selected ? (+ <CheckIcon className="size-4 shrink-0 text-white/60" />+ ) : null}+ </button>+ ))+ ) : (+ <div className="flex h-10 items-center rounded-xl px-3 text-sm font-medium text-white/45">+ {section.emptyLabel}+ </div>+ )}+ </div>+ {sectionIndex < sections.length - 1 ? (+ <Separator className="my-1 bg-white/10" />+ ) : null}+ </React.Fragment>+ ))}+ </div>+ )+}++function InCallIconButton({+ ariaLabel,+ active = true,+ selected = false,+ unreadCount = 0,+ onClick,+ children,+}: {+ ariaLabel: string+ active?: boolean+ selected?: boolean+ unreadCount?: number+ onClick?: () => void+ children: React.ReactNode+}) {+ const unreadLabel = unreadCount > 99 ? "99+" : `${unreadCount}`++ return (+ <button+ type="button"+ aria-label={ariaLabel}+ className={cn(+ "relative grid size-11 cursor-pointer place-items-center rounded-full transition",+ selected+ ? "bg-[#d2e3fc] text-[#174ea6] hover:bg-[#c2d7f8] dark:bg-[#8ab4f8] dark:text-[#111213] dark:hover:bg-[#a8c7fa]"+ : active+ ? "bg-muted text-foreground hover:bg-muted/80 dark:bg-black dark:text-white dark:ring-1 dark:ring-white/15 dark:hover:bg-black"+ : "bg-[#d84a38] text-white hover:bg-[#c23b2b]"+ )}+ onClick={onClick}+ >+ {children}+ {unreadCount > 0 ? (+ <span className="absolute -top-1 -right-1 grid min-w-5 place-items-center rounded-full bg-[#d84a38] px-1.5 text-[11px] leading-5 font-semibold text-white ring-2 ring-background dark:ring-black">+ {unreadLabel}+ </span>+ ) : null}+ </button>+ )+}++function getInitial(label: string) {+ return label.trim().charAt(0).toUpperCase() || "F"+}++function getParticipantAudioMediaStreamTrack(participant: Participant) {+ const audioTrack =+ participant.getTrackPublication(Track.Source.Microphone)?.audioTrack ?? null++ return getAudioMediaStreamTrack(audioTrack)+}++function getAggregateTranslationStatus(+ translations: Array<ParticipantTranslationSnapshot | undefined>+): TranslationStatus {+ const activeTranslations = translations.filter(+ (translation): translation is ParticipantTranslationSnapshot =>+ Boolean(translation?.hasSourceTrack)+ )++ if (+ activeTranslations.some((translation) => translation.status === "error")+ ) {+ return "error"+ }++ if (+ activeTranslations.some(+ (translation) => translation.status === "connecting"+ )+ ) {+ return "connecting"+ }++ if (+ activeTranslations.some((translation) => translation.status === "connected")+ ) {+ return "connected"+ }++ return "idle"+}++function areParticipantTranslationsEqual(+ previous: ParticipantTranslationSnapshot | undefined,+ next: ParticipantTranslationSnapshot+) {+ return (+ previous?.participantId === next.participantId &&+ previous.participantName === next.participantName &&+ previous.hasSourceTrack === next.hasSourceTrack &&+ previous.status === next.status &&+ previous.error === next.error &&+ previous.sourceTranscript === next.sourceTranscript &&+ previous.translatedTranscript === next.translatedTranscript &&+ previous.sourceSubtitle === next.sourceSubtitle &&+ previous.translatedSubtitle === next.translatedSubtitle &&+ previous.hasOutputAudio === next.hasOutputAudio+ )+}++function getAudioMediaStreamTrack(audioTrack: unknown) {+ if (!audioTrack || typeof audioTrack !== "object") {+ return null+ }++ const mediaStreamTrack = (audioTrack as { mediaStreamTrack?: unknown })+ .mediaStreamTrack++ return mediaStreamTrack instanceof MediaStreamTrack ? mediaStreamTrack : null+}++async function queryMediaPermission(name: MediaPermissionName) {+ if (!navigator.permissions?.query) {+ return null+ }++ try {+ return await navigator.permissions.query({+ name: name as PermissionName,+ })+ } catch {+ return null+ }+}++function stopMediaStream(stream: MediaStream | null) {+ stream?.getTracks().forEach((track) => track.stop())+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/theme-provider.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/theme-provider.tsxnew file mode 100644index 00000000..3d44f481--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/theme-provider.tsx@@ -0,0 +1,71 @@+"use client"++import * as React from "react"+import { ThemeProvider as NextThemesProvider, useTheme } from "next-themes"++function ThemeProvider({+ children,+ ...props+}: React.ComponentProps<typeof NextThemesProvider>) {+ return (+ <NextThemesProvider+ attribute="class"+ defaultTheme="system"+ enableSystem+ disableTransitionOnChange+ {...props}+ >+ <ThemeHotkey />+ {children}+ </NextThemesProvider>+ )+}++function isTypingTarget(target: EventTarget | null) {+ if (!(target instanceof HTMLElement)) {+ return false+ }++ return (+ target.isContentEditable ||+ target.tagName === "INPUT" ||+ target.tagName === "TEXTAREA" ||+ target.tagName === "SELECT"+ )+}++function ThemeHotkey() {+ const { resolvedTheme, setTheme } = useTheme()++ React.useEffect(() => {+ function onKeyDown(event: KeyboardEvent) {+ if (event.defaultPrevented || event.repeat) {+ return+ }++ if (event.metaKey || event.ctrlKey || event.altKey) {+ return+ }++ if (event.key.toLowerCase() !== "d") {+ return+ }++ if (isTypingTarget(event.target)) {+ return+ }++ setTheme(resolvedTheme === "dark" ? "light" : "dark")+ }++ window.addEventListener("keydown", onKeyDown)++ return () => {+ window.removeEventListener("keydown", onKeyDown)+ }+ }, [resolvedTheme, setTheme])++ return null+}++export { ThemeProvider }diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/alert.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/alert.tsxnew file mode 100644index 00000000..a60f6989--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/alert.tsx@@ -0,0 +1,76 @@+import * as React from "react"+import { cva, type VariantProps } from "class-variance-authority"++import { cn } from "@/lib/utils"++const alertVariants = cva(+ "group/alert relative grid w-full gap-0.5 rounded-2xl border px-4 py-3 text-start text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pe-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2.5 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4",+ {+ variants: {+ variant: {+ default: "bg-card text-card-foreground",+ destructive:+ "bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current",+ },+ },+ defaultVariants: {+ variant: "default",+ },+ }+)++function Alert({+ className,+ variant,+ ...props+}: React.ComponentProps<"div"> & VariantProps<typeof alertVariants>) {+ return (+ <div+ data-slot="alert"+ role="alert"+ className={cn(alertVariants({ variant }), className)}+ {...props}+ />+ )+}++function AlertTitle({ className, ...props }: React.ComponentProps<"div">) {+ return (+ <div+ data-slot="alert-title"+ className={cn(+ "font-medium group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground",+ className+ )}+ {...props}+ />+ )+}++function AlertDescription({+ className,+ ...props+}: React.ComponentProps<"div">) {+ return (+ <div+ data-slot="alert-description"+ className={cn(+ "text-sm text-balance text-muted-foreground md:text-pretty [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4",+ className+ )}+ {...props}+ />+ )+}++function AlertAction({ className, ...props }: React.ComponentProps<"div">) {+ return (+ <div+ data-slot="alert-action"+ className={cn("absolute end-3 top-2.5", className)}+ {...props}+ />+ )+}++export { Alert, AlertTitle, AlertDescription, AlertAction }diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/badge.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/badge.tsxnew file mode 100644index 00000000..087adc48--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/badge.tsx@@ -0,0 +1,49 @@+import * as React from "react"+import { cva, type VariantProps } from "class-variance-authority"+import { Slot } from "radix-ui"++import { cn } from "@/lib/utils"++const badgeVariants = cva(+ "group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-3xl border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pe-1.5 has-data-[icon=inline-start]:ps-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!",+ {+ variants: {+ variant: {+ default: "bg-primary text-primary-foreground [a]:hover:bg-primary/80",+ secondary:+ "bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",+ destructive:+ "bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20",+ outline:+ "border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground",+ ghost:+ "hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50",+ link: "text-primary underline-offset-4 hover:underline",+ },+ },+ defaultVariants: {+ variant: "default",+ },+ }+)++function Badge({+ className,+ variant = "default",+ asChild = false,+ ...props+}: React.ComponentProps<"span"> &+ VariantProps<typeof badgeVariants> & { asChild?: boolean }) {+ const Comp = asChild ? Slot.Root : "span"++ return (+ <Comp+ data-slot="badge"+ data-variant={variant}+ className={cn(badgeVariants({ variant }), className)}+ {...props}+ />+ )+}++export { Badge, badgeVariants }diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/button.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/button.tsxnew file mode 100644index 00000000..e7f87e5b--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/button.tsx@@ -0,0 +1,65 @@+import * as React from "react"+import { cva, type VariantProps } from "class-variance-authority"+import { Slot } from "radix-ui"++import { cn } from "@/lib/utils"++const buttonVariants = cva(+ "group/button inline-flex shrink-0 items-center justify-center rounded-4xl border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/30 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",+ {+ variants: {+ variant: {+ default: "bg-primary text-primary-foreground hover:bg-primary/80",+ outline:+ "border-border bg-background hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:bg-transparent dark:hover:bg-input/30",+ secondary:+ "bg-secondary text-secondary-foreground hover:bg-secondary/80 aria-expanded:bg-secondary aria-expanded:text-secondary-foreground",+ ghost:+ "hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50",+ destructive:+ "bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40",+ link: "text-primary underline-offset-4 hover:underline",+ },+ size: {+ default:+ "h-9 gap-1.5 px-3 has-data-[icon=inline-end]:pe-2.5 has-data-[icon=inline-start]:ps-2.5",+ xs: "h-6 gap-1 px-2.5 text-xs has-data-[icon=inline-end]:pe-2 has-data-[icon=inline-start]:ps-2 [&_svg:not([class*='size-'])]:size-3",+ sm: "h-8 gap-1 px-3 has-data-[icon=inline-end]:pe-2 has-data-[icon=inline-start]:ps-2",+ lg: "h-10 gap-1.5 px-4 has-data-[icon=inline-end]:pe-3 has-data-[icon=inline-start]:ps-3",+ icon: "size-9",+ "icon-xs": "size-6 [&_svg:not([class*='size-'])]:size-3",+ "icon-sm": "size-8",+ "icon-lg": "size-10",+ },+ },+ defaultVariants: {+ variant: "default",+ size: "default",+ },+ }+)++function Button({+ className,+ variant = "default",+ size = "default",+ asChild = false,+ ...props+}: React.ComponentProps<"button"> &+ VariantProps<typeof buttonVariants> & {+ asChild?: boolean+ }) {+ const Comp = asChild ? Slot.Root : "button"++ return (+ <Comp+ data-slot="button"+ data-variant={variant}+ data-size={size}+ className={cn(buttonVariants({ variant, size, className }))}+ {...props}+ />+ )+}++export { Button, buttonVariants }diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/input.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/input.tsxnew file mode 100644index 00000000..4143a0bc--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/input.tsx@@ -0,0 +1,19 @@+import * as React from "react"++import { cn } from "@/lib/utils"++function Input({ className, type, ...props }: React.ComponentProps<"input">) {+ return (+ <input+ type={type}+ data-slot="input"+ className={cn(+ "h-9 w-full min-w-0 rounded-3xl border border-transparent bg-input/50 px-3 py-1 text-base transition-[color,box-shadow,background-color] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/30 disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",+ className+ )}+ {...props}+ />+ )+}++export { Input }diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/popover.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/popover.tsxnew file mode 100644index 00000000..7f63b489--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/popover.tsx@@ -0,0 +1,89 @@+"use client"++import * as React from "react"+import { Popover as PopoverPrimitive } from "radix-ui"++import { cn } from "@/lib/utils"++function Popover({+ ...props+}: React.ComponentProps<typeof PopoverPrimitive.Root>) {+ return <PopoverPrimitive.Root data-slot="popover" {...props} />+}++function PopoverTrigger({+ ...props+}: React.ComponentProps<typeof PopoverPrimitive.Trigger>) {+ return <PopoverPrimitive.Trigger data-slot="popover-trigger" {...props} />+}++function PopoverContent({+ className,+ align = "center",+ sideOffset = 4,+ ...props+}: React.ComponentProps<typeof PopoverPrimitive.Content>) {+ return (+ <PopoverPrimitive.Portal>+ <PopoverPrimitive.Content+ data-slot="popover-content"+ align={align}+ sideOffset={sideOffset}+ className={cn(+ "z-50 flex w-72 origin-(--radix-popover-content-transform-origin) flex-col gap-4 rounded-3xl bg-popover p-4 text-sm text-popover-foreground shadow-lg ring-1 ring-foreground/5 outline-hidden duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 dark:ring-foreground/10 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",+ className+ )}+ {...props}+ />+ </PopoverPrimitive.Portal>+ )+}++function PopoverAnchor({+ ...props+}: React.ComponentProps<typeof PopoverPrimitive.Anchor>) {+ return <PopoverPrimitive.Anchor data-slot="popover-anchor" {...props} />+}++function PopoverHeader({ className, ...props }: React.ComponentProps<"div">) {+ return (+ <div+ data-slot="popover-header"+ className={cn("flex flex-col gap-1 text-sm", className)}+ {...props}+ />+ )+}++function PopoverTitle({ className, ...props }: React.ComponentProps<"h2">) {+ return (+ <div+ data-slot="popover-title"+ className={cn("text-base font-medium", className)}+ {...props}+ />+ )+}++function PopoverDescription({+ className,+ ...props+}: React.ComponentProps<"p">) {+ return (+ <p+ data-slot="popover-description"+ className={cn("text-muted-foreground", className)}+ {...props}+ />+ )+}++export {+ Popover,+ PopoverAnchor,+ PopoverContent,+ PopoverDescription,+ PopoverHeader,+ PopoverTitle,+ PopoverTrigger,+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/select.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/select.tsxnew file mode 100644index 00000000..f1e67651--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/select.tsx@@ -0,0 +1,198 @@+"use client"++import * as React from "react"+import { Select as SelectPrimitive } from "radix-ui"++import { cn } from "@/lib/utils"+import { ChevronDownIcon, CheckIcon, ChevronUpIcon } from "lucide-react"++function Select({+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Root>) {+ return <SelectPrimitive.Root data-slot="select" {...props} />+}++function SelectGroup({+ className,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Group>) {+ return (+ <SelectPrimitive.Group+ data-slot="select-group"+ className={cn("scroll-my-1.5 p-1.5", className)}+ {...props}+ />+ )+}++function SelectValue({+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Value>) {+ return <SelectPrimitive.Value data-slot="select-value" {...props} />+}++function SelectTrigger({+ className,+ size = "default",+ children,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Trigger> & {+ size?: "sm" | "default"+}) {+ return (+ <SelectPrimitive.Trigger+ data-slot="select-trigger"+ data-size={size}+ className={cn(+ "flex w-fit items-center justify-between gap-1.5 rounded-3xl border border-transparent bg-input/50 px-3 py-2 text-sm whitespace-nowrap transition-[color,box-shadow,background-color] outline-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/30 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-placeholder:text-muted-foreground data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-1.5 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",+ className+ )}+ {...props}+ >+ {children}+ <SelectPrimitive.Icon asChild>+ <ChevronDownIcon className="pointer-events-none size-4 text-muted-foreground" />+ </SelectPrimitive.Icon>+ </SelectPrimitive.Trigger>+ )+}++function SelectContent({+ className,+ children,+ position = "item-aligned",+ align = "center",+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Content>) {+ return (+ <SelectPrimitive.Portal>+ <SelectPrimitive.Content+ data-slot="select-content"+ data-align-trigger={position === "item-aligned"}+ className={cn(+ "relative z-50 max-h-(--radix-select-content-available-height) min-w-36 origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-3xl bg-popover text-popover-foreground shadow-lg ring-1 ring-foreground/5 duration-100 data-[align-trigger=true]:animate-none data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 dark:ring-foreground/10 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",+ position === "popper" &&+ "data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1 rtl:data-[side=left]:translate-x-1 rtl:data-[side=right]:-translate-x-1",+ className+ )}+ position={position}+ align={align}+ {...props}+ >+ <SelectScrollUpButton />+ <SelectPrimitive.Viewport+ data-position={position}+ className={cn(+ "data-[position=popper]:h-(--radix-select-trigger-height) data-[position=popper]:w-full data-[position=popper]:min-w-(--radix-select-trigger-width)",+ position === "popper" && ""+ )}+ >+ {children}+ </SelectPrimitive.Viewport>+ <SelectScrollDownButton />+ </SelectPrimitive.Content>+ </SelectPrimitive.Portal>+ )+}++function SelectLabel({+ className,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Label>) {+ return (+ <SelectPrimitive.Label+ data-slot="select-label"+ className={cn("px-3 py-2.5 text-xs text-muted-foreground", className)}+ {...props}+ />+ )+}++function SelectItem({+ className,+ children,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Item>) {+ return (+ <SelectPrimitive.Item+ data-slot="select-item"+ className={cn(+ "relative flex w-full cursor-default items-center gap-2.5 rounded-2xl py-2 ps-3 pe-8 text-sm font-medium outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",+ className+ )}+ {...props}+ >+ <span className="pointer-events-none absolute end-2 flex size-4 items-center justify-center">+ <SelectPrimitive.ItemIndicator>+ <CheckIcon className="pointer-events-none" />+ </SelectPrimitive.ItemIndicator>+ </span>+ <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>+ </SelectPrimitive.Item>+ )+}++function SelectSeparator({+ className,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Separator>) {+ return (+ <SelectPrimitive.Separator+ data-slot="select-separator"+ className={cn(+ "pointer-events-none -mx-1.5 my-1.5 h-px bg-border",+ className+ )}+ {...props}+ />+ )+}++function SelectScrollUpButton({+ className,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.ScrollUpButton>) {+ return (+ <SelectPrimitive.ScrollUpButton+ data-slot="select-scroll-up-button"+ className={cn(+ "z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4",+ className+ )}+ {...props}+ >+ <ChevronUpIcon />+ </SelectPrimitive.ScrollUpButton>+ )+}++function SelectScrollDownButton({+ className,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.ScrollDownButton>) {+ return (+ <SelectPrimitive.ScrollDownButton+ data-slot="select-scroll-down-button"+ className={cn(+ "z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4",+ className+ )}+ {...props}+ >+ <ChevronDownIcon />+ </SelectPrimitive.ScrollDownButton>+ )+}++export {+ Select,+ SelectContent,+ SelectGroup,+ SelectItem,+ SelectLabel,+ SelectScrollDownButton,+ SelectScrollUpButton,+ SelectSeparator,+ SelectTrigger,+ SelectValue,+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/separator.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/separator.tsxnew file mode 100644index 00000000..d4570908--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/separator.tsx@@ -0,0 +1,28 @@+"use client"++import * as React from "react"+import { Separator as SeparatorPrimitive } from "radix-ui"++import { cn } from "@/lib/utils"++function Separator({+ className,+ orientation = "horizontal",+ decorative = true,+ ...props+}: React.ComponentProps<typeof SeparatorPrimitive.Root>) {+ return (+ <SeparatorPrimitive.Root+ data-slot="separator"+ decorative={decorative}+ orientation={orientation}+ className={cn(+ "shrink-0 bg-border data-horizontal:h-px data-horizontal:w-full data-vertical:w-px data-vertical:self-stretch",+ className+ )}+ {...props}+ />+ )+}++export { Separator }diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/slider.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/slider.tsxnew file mode 100644index 00000000..2ce952e5--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/slider.tsx@@ -0,0 +1,59 @@+"use client"++import * as React from "react"+import { Slider as SliderPrimitive } from "radix-ui"++import { cn } from "@/lib/utils"++function Slider({+ className,+ defaultValue,+ value,+ min = 0,+ max = 100,+ ...props+}: React.ComponentProps<typeof SliderPrimitive.Root>) {+ const _values = React.useMemo(+ () =>+ Array.isArray(value)+ ? value+ : Array.isArray(defaultValue)+ ? defaultValue+ : [min, max],+ [value, defaultValue, min, max]+ )++ return (+ <SliderPrimitive.Root+ data-slot="slider"+ defaultValue={defaultValue}+ value={value}+ min={min}+ max={max}+ className={cn(+ "relative flex w-full touch-none items-center select-none data-disabled:opacity-50 data-vertical:h-full data-vertical:min-h-40 data-vertical:w-auto data-vertical:flex-col",+ className+ )}+ {...props}+ >+ <SliderPrimitive.Track+ data-slot="slider-track"+ className="relative grow overflow-hidden rounded-full bg-input/90 data-horizontal:h-2 data-horizontal:w-full data-vertical:h-full data-vertical:w-2"+ >+ <SliderPrimitive.Range+ data-slot="slider-range"+ className="absolute bg-primary select-none data-horizontal:h-full data-vertical:w-full"+ />+ </SliderPrimitive.Track>+ {Array.from({ length: _values.length }, (_, index) => (+ <SliderPrimitive.Thumb+ data-slot="slider-thumb"+ key={index}+ className="block h-4 w-6 shrink-0 rounded-full bg-white shadow-md ring-1 ring-black/10 transition-[color,box-shadow,background-color] select-none not-dark:bg-clip-padding hover:ring-4 hover:ring-ring/30 focus-visible:ring-4 focus-visible:ring-ring/30 focus-visible:outline-hidden disabled:pointer-events-none disabled:opacity-50 data-vertical:h-6 data-vertical:w-4"+ />+ ))}+ </SliderPrimitive.Root>+ )+}++export { Slider }diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/spinner.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/spinner.tsxnew file mode 100644index 00000000..9b2c9825--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/spinner.tsx@@ -0,0 +1,15 @@+import { cn } from "@/lib/utils"+import { Loader2Icon } from "lucide-react"++function Spinner({ className, ...props }: React.ComponentProps<"svg">) {+ return (+ <Loader2Icon+ role="status"+ aria-label="Loading"+ className={cn("size-4 animate-spin", className)}+ {...props}+ />+ )+}++export { Spinner }diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/switch.tsx b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/switch.tsxnew file mode 100644index 00000000..2fed1adf--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/components/ui/switch.tsx@@ -0,0 +1,33 @@+"use client"++import * as React from "react"+import { Switch as SwitchPrimitive } from "radix-ui"++import { cn } from "@/lib/utils"++function Switch({+ className,+ size = "default",+ ...props+}: React.ComponentProps<typeof SwitchPrimitive.Root> & {+ size?: "sm" | "default"+}) {+ return (+ <SwitchPrimitive.Root+ data-slot="switch"+ data-size={size}+ className={cn(+ "peer group/switch relative inline-flex shrink-0 items-center rounded-full border-2 transition-all outline-none after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/30 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-[size=default]:h-5 data-[size=default]:w-11 data-[size=sm]:h-4 data-[size=sm]:w-7 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-unchecked:border-transparent data-unchecked:bg-input/90 data-disabled:cursor-not-allowed data-disabled:opacity-50",+ className+ )}+ {...props}+ >+ <SwitchPrimitive.Thumb+ data-slot="switch-thumb"+ className="pointer-events-none block rounded-full bg-background shadow-sm ring-0 transition-transform not-dark:bg-clip-padding group-data-[size=default]/switch:h-4 group-data-[size=default]/switch:w-6 group-data-[size=sm]/switch:h-3 group-data-[size=sm]/switch:w-4 data-checked:translate-x-[calc(100%-8px)] rtl:data-checked:-translate-x-[calc(100%-8px)] dark:data-checked:bg-primary-foreground data-unchecked:translate-x-0 rtl:data-unchecked:-translate-x-0 dark:data-unchecked:bg-foreground"+ />+ </SwitchPrimitive.Root>+ )+}++export { Switch }diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/eslint.config.js b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/eslint.config.jsnew file mode 100644index 00000000..071d85c8--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/eslint.config.js@@ -0,0 +1,46 @@+import js from "@eslint/js"+import pluginNext from "@next/eslint-plugin-next"+import eslintConfigPrettier from "eslint-config-prettier"+import pluginReactHooks from "eslint-plugin-react-hooks"+import globals from "globals"+import tseslint from "typescript-eslint"++/** @type {import("eslint").Linter.Config} */+export default [+ {+ ignores: [+ ".next/**",+ "coverage/**",+ "next-env.d.ts",+ "node_modules/**",+ ],+ },+ js.configs.recommended,+ eslintConfigPrettier,+ ...tseslint.configs.recommended,+ {+ languageOptions: {+ globals: {+ ...globals.browser,+ ...globals.serviceworker,+ },+ },+ },+ {+ plugins: {+ "@next/next": pluginNext,+ },+ rules: {+ ...pluginNext.configs.recommended.rules,+ ...pluginNext.configs["core-web-vitals"].rules,+ },+ },+ {+ plugins: {+ "react-hooks": pluginReactHooks,+ },+ rules: {+ ...pluginReactHooks.configs.recommended.rules,+ },+ },+]diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/hooks/use-mounted.ts b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/hooks/use-mounted.tsnew file mode 100644index 00000000..a266027d--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/hooks/use-mounted.ts@@ -0,0 +1,21 @@+import * as React from "react"++function subscribeMounted() {+ return () => {}+}++function getMountedSnapshot() {+ return true+}++function getServerMountedSnapshot() {+ return false+}++export function useMounted() {+ return React.useSyncExternalStore(+ subscribeMounted,+ getMountedSnapshot,+ getServerMountedSnapshot+ )+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/lib/realtime-translation-config.js b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/lib/realtime-translation-config.jsnew file mode 100644index 00000000..192f58d4--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/lib/realtime-translation-config.js@@ -0,0 +1,128 @@+export const DEFAULT_TRANSLATION_MODEL = "gpt-realtime-translate"+export const DEFAULT_INPUT_TRANSCRIPTION_MODEL = "gpt-realtime-whisper"+export const REALTIME_TRANSLATION_CLIENT_SECRET_URL =+ "https://api.openai.com/v1/realtime/translations/client_secrets"+export const REALTIME_TRANSLATION_CALL_URL =+ "https://api.openai.com/v1/realtime/translations/calls"++export const TRANSLATION_LANGUAGES = [+ { value: "es", label: "Spanish" },+ { value: "pt", label: "Portuguese" },+ { value: "fr", label: "French" },+ { value: "ja", label: "Japanese" },+ { value: "ru", label: "Russian" },+ { value: "zh", label: "Chinese" },+ { value: "de", label: "German" },+ { value: "ko", label: "Korean" },+ { value: "hi", label: "Hindi" },+ { value: "id", label: "Indonesian" },+ { value: "vi", label: "Vietnamese" },+ { value: "it", label: "Italian" },+ { value: "en", label: "English" },+]++const SUPPORTED_LANGUAGES = new Set(+ TRANSLATION_LANGUAGES.map((language) => language.value)+)+const LANGUAGE_PATTERN = /^[a-z]{2,3}(?:-[a-z0-9]{2,8}){0,2}$/++export function normalizeTranslationLanguage(language) {+ if (typeof language !== "string" || !language.trim()) {+ throw new Error("A translation language is required")+ }++ const normalized = language.trim().toLowerCase()+ if (!LANGUAGE_PATTERN.test(normalized)) {+ throw new Error("Invalid translation language")+ }+ if (!SUPPORTED_LANGUAGES.has(normalized)) {+ throw new Error("Unsupported translation language")+ }++ return normalized+}++export function buildTranslationSessionConfig({+ language,+ inputTranscriptionEnabled,+ noiseReductionEnabled,+ model = DEFAULT_TRANSLATION_MODEL,+}) {+ return {+ model,+ audio: {+ input: buildAudioInputConfig({+ inputTranscriptionEnabled,+ noiseReductionEnabled,+ }),+ output: {+ language: normalizeTranslationLanguage(language),+ },+ },+ }+}++export function buildSessionUpdate({+ language,+ inputTranscriptionEnabled,+ noiseReductionEnabled,+}) {+ const session = buildTranslationSessionConfig({+ language,+ inputTranscriptionEnabled,+ noiseReductionEnabled,+ })+ delete session.model++ return {+ type: "session.update",+ session,+ }+}++export function buildTranslationClientSecretRequest({+ apiKey,+ language,+ inputTranscriptionEnabled,+ noiseReductionEnabled,+ model = DEFAULT_TRANSLATION_MODEL,+}) {+ if (!apiKey) {+ throw new Error("OPENAI_API_KEY is required")+ }++ return {+ url: REALTIME_TRANSLATION_CLIENT_SECRET_URL,+ init: {+ method: "POST",+ headers: {+ Authorization: `Bearer ${apiKey}`,+ "Content-Type": "application/json",+ },+ body: JSON.stringify({+ session: buildTranslationSessionConfig({+ language,+ inputTranscriptionEnabled,+ noiseReductionEnabled,+ model,+ }),+ }),+ },+ }+}++function buildAudioInputConfig({+ inputTranscriptionEnabled,+ noiseReductionEnabled,+}) {+ return {+ ...(inputTranscriptionEnabled+ ? {+ transcription: {+ model: DEFAULT_INPUT_TRANSCRIPTION_MODEL,+ },+ }+ : {}),+ noise_reduction: noiseReductionEnabled ? { type: "near_field" } : null,+ }+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/lib/realtime-translation.ts b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/lib/realtime-translation.tsnew file mode 100644index 00000000..48503ba7--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/lib/realtime-translation.ts@@ -0,0 +1,411 @@+"use client"++import * as React from "react"++import {+ REALTIME_TRANSLATION_CALL_URL,+ TRANSLATION_LANGUAGES,+ buildSessionUpdate,+} from "@/lib/realtime-translation-config"++export type TranslationLanguage = {+ value: string+ label: string+}++export { TRANSLATION_LANGUAGES }++export type TranslationStatus = "idle" | "connecting" | "connected" | "error"++type TranslationTokenResponse = {+ clientSecret: string+ expiresAt: number | null+}++type UseRemoteTranslationOptions = {+ enabled: boolean+ sourceTrack: MediaStreamTrack | null+ language: string+ sourceTranscriptionEnabled: boolean+ noiseReductionEnabled: boolean+ translatedVolume: number+}++export type UseRemoteTranslationResult = {+ status: TranslationStatus+ error: string | null+ sourceTranscript: string+ translatedTranscript: string+ sourceSubtitle: string+ translatedSubtitle: string+ hasOutputAudio: boolean+}++type TranslationSessionConfig = {+ language: string+ sourceTranscriptionEnabled: boolean+ noiseReductionEnabled: boolean+}++type RealtimeEvent = {+ type?: unknown+ delta?: unknown+ error?: unknown+}++export function useRemoteTranslation({+ enabled,+ sourceTrack,+ language,+ sourceTranscriptionEnabled,+ noiseReductionEnabled,+ translatedVolume,+}: UseRemoteTranslationOptions): UseRemoteTranslationResult {+ const [status, setStatus] = React.useState<TranslationStatus>("idle")+ const [error, setError] = React.useState<string | null>(null)+ const [sourceTranscript, setSourceTranscript] = React.useState("")+ const [translatedTranscript, setTranslatedTranscript] = React.useState("")+ const [hasOutputAudio, setHasOutputAudio] = React.useState(false)+ const peerConnectionRef = React.useRef<RTCPeerConnection | null>(null)+ const dataChannelRef = React.useRef<RTCDataChannel | null>(null)+ const translatedAudioRef = React.useRef<HTMLAudioElement | null>(null)+ const translatedVolumeRef = React.useRef(translatedVolume)+ const sessionConfigRef = React.useRef<TranslationSessionConfig>({+ language,+ sourceTranscriptionEnabled,+ noiseReductionEnabled,+ })+ const active = enabled && !!sourceTrack++ React.useEffect(() => {+ translatedVolumeRef.current = translatedVolume+ if (translatedAudioRef.current) {+ translatedAudioRef.current.volume = translatedVolume+ }+ }, [translatedVolume])++ React.useEffect(() => {+ const nextConfig = {+ language,+ sourceTranscriptionEnabled,+ noiseReductionEnabled,+ }+ sessionConfigRef.current = nextConfig++ const dataChannel = dataChannelRef.current+ if (!active || !dataChannel || dataChannel.readyState !== "open") {+ return+ }++ dataChannel.send(JSON.stringify(buildTranslationSessionUpdate(nextConfig)))+ }, [active, language, noiseReductionEnabled, sourceTranscriptionEnabled])++ React.useEffect(() => {+ if (!active || !sourceTrack) {+ return+ }++ const activeSourceTrack = sourceTrack+ let cancelled = false+ let peerConnection: RTCPeerConnection | null = null+ let dataChannel: RTCDataChannel | null = null+ let translatedAudio: HTMLAudioElement | null = null++ async function connect() {+ const initialSessionConfig = sessionConfigRef.current+ setStatus("connecting")+ setError(null)+ setSourceTranscript("")+ setTranslatedTranscript("")+ setHasOutputAudio(false)++ try {+ const tokenResponse = await fetch("/api/realtime/translation-token", {+ method: "POST",+ headers: {+ "Content-Type": "application/json",+ },+ body: JSON.stringify({+ language: initialSessionConfig.language,+ inputTranscriptionEnabled:+ initialSessionConfig.sourceTranscriptionEnabled,+ noiseReductionEnabled: initialSessionConfig.noiseReductionEnabled,+ }),+ })++ if (!tokenResponse.ok) {+ throw new Error(await tokenResponse.text())+ }++ const token = (await tokenResponse.json()) as TranslationTokenResponse++ if (cancelled) {+ return+ }++ peerConnection = new RTCPeerConnection()+ dataChannel = peerConnection.createDataChannel("oai-events")+ translatedAudio = new Audio()+ translatedAudio.autoplay = true+ translatedAudio.setAttribute("playsinline", "")+ translatedAudio.volume = translatedVolumeRef.current++ peerConnectionRef.current = peerConnection+ dataChannelRef.current = dataChannel+ translatedAudioRef.current = translatedAudio++ peerConnection.ontrack = ({ streams, track }) => {+ if (!translatedAudio) {+ return+ }++ translatedAudio.srcObject = streams[0] ?? new MediaStream([track])+ setHasOutputAudio(true)+ void translatedAudio.play().catch((audioError) => {+ setError(getErrorMessage(audioError))+ })+ }++ peerConnection.onconnectionstatechange = () => {+ if (!peerConnection || cancelled) {+ return+ }++ if (peerConnection.connectionState === "failed") {+ setError("Translation WebRTC connection failed")+ setStatus("error")+ }++ if (peerConnection.connectionState === "connected") {+ setStatus("connected")+ }+ }++ dataChannel.onopen = () => {+ if (!dataChannel || cancelled) {+ return+ }++ dataChannel.send(+ JSON.stringify(+ buildTranslationSessionUpdate(sessionConfigRef.current)+ )+ )+ }+ dataChannel.onmessage = (event) => {+ if (!cancelled) {+ void handleRealtimeEvent(event.data, {+ onSessionReady: () => setStatus("connected"),+ onInputTranscript: (delta) => {+ setSourceTranscript((current) =>+ appendTranscriptDelta(current, delta)+ )+ },+ onOutputAudio: () => setHasOutputAudio(true),+ onOutputTranscript: (delta) => {+ setTranslatedTranscript((current) =>+ appendTranscriptDelta(current, delta)+ )+ },+ onError: (message) => {+ setError(message)+ setStatus("error")+ },+ })+ }+ }+ dataChannel.onerror = () => {+ if (!cancelled) {+ setError("Translation data channel failed")+ setStatus("error")+ }+ }++ peerConnection.addTrack(+ activeSourceTrack,+ new MediaStream([activeSourceTrack])+ )++ const offer = await peerConnection.createOffer()+ await peerConnection.setLocalDescription(offer)++ const sdpResponse = await fetch(REALTIME_TRANSLATION_CALL_URL, {+ method: "POST",+ headers: {+ Authorization: `Bearer ${token.clientSecret}`,+ "Content-Type": "application/sdp",+ },+ body: offer.sdp,+ })++ const answerSdp = await sdpResponse.text()+ if (!sdpResponse.ok) {+ throw new Error(answerSdp)+ }++ await peerConnection.setRemoteDescription({+ type: "answer",+ sdp: answerSdp,+ })++ if (!cancelled) {+ setStatus("connected")+ }+ } catch (connectError) {+ if (!cancelled) {+ setError(getErrorMessage(connectError))+ setStatus("error")+ }+ }+ }++ void connect()++ return () => {+ cancelled = true+ dataChannel?.close()+ peerConnection?.close()++ if (translatedAudio) {+ translatedAudio.pause()+ translatedAudio.srcObject = null+ }++ if (dataChannelRef.current === dataChannel) {+ dataChannelRef.current = null+ }+ if (peerConnectionRef.current === peerConnection) {+ peerConnectionRef.current = null+ }+ if (translatedAudioRef.current === translatedAudio) {+ translatedAudioRef.current = null+ }+ }+ }, [active, sourceTrack])++ return {+ status: active ? status : "idle",+ error: active ? error : null,+ sourceTranscript,+ translatedTranscript,+ sourceSubtitle: getSubtitle(sourceTranscript),+ translatedSubtitle: getSubtitle(translatedTranscript),+ hasOutputAudio: active ? hasOutputAudio : false,+ }+}++async function handleRealtimeEvent(+ payload: unknown,+ handlers: {+ onSessionReady: () => void+ onInputTranscript: (delta: string) => void+ onOutputAudio: () => void+ onOutputTranscript: (delta: string) => void+ onError: (message: string) => void+ }+) {+ const text =+ typeof payload === "string"+ ? payload+ : payload instanceof Blob+ ? await payload.text()+ : null++ if (!text) {+ return+ }++ let event: RealtimeEvent+ try {+ event = JSON.parse(text) as RealtimeEvent+ } catch {+ return+ }++ if (event.type === "session.updated") {+ handlers.onSessionReady()+ return+ }++ if (event.type === "session.input_transcript.delta") {+ if (typeof event.delta === "string") {+ handlers.onInputTranscript(event.delta)+ }+ return+ }++ if (event.type === "session.output_audio.delta") {+ handlers.onOutputAudio()+ return+ }++ if (event.type === "session.output_transcript.delta") {+ if (typeof event.delta === "string") {+ handlers.onOutputTranscript(event.delta)+ }+ return+ }++ if (event.type === "error") {+ const error = event.error+ if (error && typeof error === "object" && !Array.isArray(error)) {+ const message = (error as Record<string, unknown>).message+ handlers.onError(+ typeof message === "string" ? message : "Translation error"+ )+ return+ }++ handlers.onError("Translation error")+ }+}++function appendTranscriptDelta(current: string, delta: string) {+ if (!delta) {+ return current+ }++ if (!current) {+ return delta.replace(/^\s+/, "")+ }++ if (+ /\s$/.test(current) ||+ /^\s/.test(delta) ||+ /^[,.;:!?%)}\]]/.test(delta)+ ) {+ return `${current}${delta}`+ }++ return `${current} ${delta}`+}++function buildTranslationSessionUpdate(config: TranslationSessionConfig) {+ return buildSessionUpdate({+ language: config.language,+ inputTranscriptionEnabled: config.sourceTranscriptionEnabled,+ noiseReductionEnabled: config.noiseReductionEnabled,+ })+}++function getSubtitle(transcript: string) {+ const normalized = transcript.replace(/\s+/g, " ").trim()++ if (!normalized) {+ return ""+ }++ const sentenceStart = Math.max(+ normalized.lastIndexOf(". "),+ normalized.lastIndexOf("? "),+ normalized.lastIndexOf("! ")+ )+ const latest =+ sentenceStart >= 0 ? normalized.slice(sentenceStart + 2) : normalized++ return latest.length > 180 ? latest.slice(latest.length - 180) : latest+}++function getErrorMessage(error: unknown) {+ return error instanceof Error ? error.message : "Translation failed"+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/lib/utils.ts b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/lib/utils.tsnew file mode 100644index 00000000..bd0c391d--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/lib/utils.ts@@ -0,0 +1,6 @@+import { clsx, type ClassValue } from "clsx"+import { twMerge } from "tailwind-merge"++export function cn(...inputs: ClassValue[]) {+ return twMerge(clsx(inputs))+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/next-env.d.ts b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/next-env.d.tsnew file mode 100644index 00000000..9edff1c7--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/next-env.d.ts@@ -0,0 +1,6 @@+/// <reference types="next" />+/// <reference types="next/image-types/global" />+import "./.next/types/routes.d.ts";++// NOTE: This file should not be edited+// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/next.config.mjs b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/next.config.mjsnew file mode 100644index 00000000..77dce8f3--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/next.config.mjs@@ -0,0 +1,13 @@+import path from "node:path"+import { fileURLToPath } from "node:url"++const __dirname = path.dirname(fileURLToPath(import.meta.url))++/** @type {import('next').NextConfig} */+const nextConfig = {+ turbopack: {+ root: __dirname,+ },+}++export default nextConfigdiff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/package.json b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/package.jsonnew file mode 100644index 00000000..c18cc128--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/package.json@@ -0,0 +1,57 @@+{+ "name": "livekit-translation-demo",+ "version": "0.1.0",+ "type": "module",+ "private": true,+ "scripts": {+ "build": "next build",+ "dev": "next dev --turbopack",+ "lint": "eslint --cache --cache-location .next/cache/eslint .",+ "format": "prettier --write \"**/*.{ts,tsx}\"",+ "start": "next start",+ "test": "node --test test/*.test.mjs",+ "typecheck": "next typegen && tsc --noEmit",+ "verify": "pnpm test && pnpm lint && pnpm typecheck"+ },+ "dependencies": {+ "@next/env": "16.1.6",+ "class-variance-authority": "^0.7.1",+ "clsx": "^2.1.1",+ "livekit-client": "2.17.3",+ "livekit-server-sdk": "2.15.0",+ "lucide-react": "^1.8.0",+ "next": "16.1.6",+ "next-themes": "^0.4.6",+ "radix-ui": "^1.4.3",+ "react": "^19.2.4",+ "react-dom": "^19.2.4",+ "tailwind-merge": "^3.5.0",+ "tw-animate-css": "^1.4.0"+ },+ "devDependencies": {+ "@eslint/js": "^9.39.2",+ "@next/eslint-plugin-next": "16.1.6",+ "@tailwindcss/postcss": "^4.1.18",+ "@types/node": "^25.1.0",+ "@types/react": "^19.2.10",+ "@types/react-dom": "^19.2.3",+ "eslint": "^9.39.2",+ "eslint-config-prettier": "^10.1.8",+ "eslint-plugin-react-hooks": "^7.0.1",+ "globals": "^16.5.0",+ "prettier": "^3.8.1",+ "prettier-plugin-tailwindcss": "^0.7.2",+ "tailwindcss": "^4.1.18",+ "typescript": "5.9.3",+ "typescript-eslint": "^8.50.0"+ },+ "packageManager": "[email protected]",+ "pnpm": {+ "ignoredBuiltDependencies": [+ "msw"+ ],+ "onlyBuiltDependencies": [+ "sharp"+ ]+ }+}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/pnpm-lock.yaml b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/pnpm-lock.yamlnew file mode 100644index 00000000..7a7178d4--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/pnpm-lock.yaml@@ -0,0 +1,4286 @@+lockfileVersion: '9.0'++settings:+ autoInstallPeers: true+ excludeLinksFromLockfile: false++importers:++ .:+ dependencies:+ '@next/env':+ specifier: 16.1.6+ version: 16.1.6+ class-variance-authority:+ specifier: ^0.7.1+ version: 0.7.1+ clsx:+ specifier: ^2.1.1+ version: 2.1.1+ livekit-client:+ specifier: 2.17.3+ version: 2.17.3(@types/[email protected])+ livekit-server-sdk:+ specifier: 2.15.0+ version: 2.15.0+ lucide-react:+ specifier: ^1.8.0+ version: 1.14.0([email protected])+ next:+ specifier: 16.1.6+ version: 16.1.6(@babel/[email protected])([email protected]([email protected]))([email protected])+ next-themes:+ specifier: ^0.4.6+ radix-ui:+ specifier: ^1.4.3+ version: 1.4.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react:+ specifier: ^19.2.4+ version: 19.2.5+ react-dom:+ specifier: ^19.2.4+ version: 19.2.5([email protected])+ tailwind-merge:+ specifier: ^3.5.0+ version: 3.5.0+ tw-animate-css:+ specifier: ^1.4.0+ version: 1.4.0+ devDependencies:+ '@eslint/js':+ specifier: ^9.39.2+ version: 9.39.4+ '@next/eslint-plugin-next':+ specifier: 16.1.6+ version: 16.1.6+ '@tailwindcss/postcss':+ specifier: ^4.1.18+ version: 4.2.4+ '@types/node':+ specifier: ^25.1.0+ version: 25.6.0+ '@types/react':+ specifier: ^19.2.10+ version: 19.2.14+ '@types/react-dom':+ specifier: ^19.2.3+ version: 19.2.3(@types/[email protected])+ eslint:+ specifier: ^9.39.2+ version: 9.39.4([email protected])+ eslint-config-prettier:+ specifier: ^10.1.8+ version: 10.1.8([email protected]([email protected]))+ eslint-plugin-react-hooks:+ specifier: ^7.0.1+ version: 7.1.1([email protected]([email protected]))+ globals:+ specifier: ^16.5.0+ version: 16.5.0+ prettier:+ specifier: ^3.8.1+ version: 3.8.3+ prettier-plugin-tailwindcss:+ specifier: ^0.7.2+ version: 0.7.4([email protected])+ tailwindcss:+ specifier: ^4.1.18+ version: 4.2.4+ typescript:+ specifier: 5.9.3+ version: 5.9.3+ typescript-eslint:+ specifier: ^8.50.0++packages:++ '@alloc/[email protected]':+ resolution: {integrity: sha512-UrcABB+4bUrFABwbluTIBErXwvbsU/V7TZWfmbgJfbkwiBuziS9gxdODUyuiecfdGQ85jglMW6juS3+z5TsKLw==}+ engines: {node: '>=10'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-9NhCeYjq9+3uxgdtp20LSiJXJvN0FeCtNGpJxuMFZ1Kv3cWUNb6DOhJwUvcVCzKGR66cw4njwM6hrJLqgOwbcw==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-LIVqM46zQWZhj17qA8wb4nW/ixr2y1Nw+r1etiAWgRM6U1IqP+LNhL1yg440jYZR72jCWcWbLWzIosH+uP1fqg==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-CGOfOJqWjg2qW/Mb6zNsDm+u5vFQ8DxXfbM09z69p5Z6+mE1ikP2jUXw+j42Pf1XTYED2Rni5f95npYeuwMDQA==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-qsaF+9Qcm2Qv8SRIMMscAvG4O3lJ0F1GuMo5HR/Bp02LopNgnZBC/EkbevHFeGs4ls/oPz9v+Bsmzbkbe+0dUw==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-JYtls3hqi15fcx5GaSNL7SCTJ2MNmjrkHXg4FSpOA/grxK8KwyZ5bubHsCq8FXCkua6xhuaaBit+3b7+VZRfcA==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-+W6cISkXFa1jXsDEdYA8HeevQT/FULhxzR99pxphltZcVaugps53THCeiWA8SguxxpSp3gKPiuYfSWopkLQ4hw==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-l5XkZK7r7wa9LucGw9LwZyyCUscb4x37JWTPz7swwFE/0FMQAGpiWUZn8u9DzkSBWEcK25jmvubfpw2dnAMdbw==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-67oXFAYr2cDLDVGLXTEABjdBJZ6drElUSI7WKp70NrpyISso3plG9SAGEF6y7zbha/wOzUByWWTJvEDVNIUGcA==}+ engines: {node: '>=6.9.0'}+ peerDependencies:+ '@babel/core': ^7.0.0++ '@babel/[email protected]':+ resolution: {integrity: sha512-qMlSxKbpRlAridDExk92nSobyDdpPijUq2DW6oDnUqd0iOGxmQjyqhMIihI9+zv4LPyZdRje2cavWPbCbWm3eA==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-YvjJow9FxbhFFKDSuFnVCe2WxXk1zWc22fFePVNEaWJEu8IrZVlda6N0uHwzZrUM1il7NC9Mlp4MaJYbYd9JSg==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-HoGuUs4sCZNezVEKdVcwqmZN8GoHirLUcLaYVNBK2J0DadGtdcqgr3BCbvH8+XUo4NGjNl3VOtSjEKNzqfFgKw==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-b3ctpQwp+PROvU/cttc4OYl4MzfJUWy6FZg+PMXfzmt/+39iHVF0sDfqay8TQM3JA2EUOyKcFZt75jWriQijsA==}+ engines: {node: '>=6.0.0'}+ hasBin: true++ '@babel/[email protected]':+ resolution: {integrity: sha512-YA6Ma2KsCdGb+WC6UpBVFJGXL58MDA6oyONbjyF/+5sBgxY/dwkhLogbMT2GXXyU84/IhRw/2D1Os1B/giz+BQ==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-4HPiQr0X7+waHfyXPZpWPfWL/J7dcN1mx9gL6WdQVMbPnF3+ZhSMs8tCxN7oHddJE9fhNE7+lxdnlyemKfJRuA==}+ engines: {node: '>=6.9.0'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-LwdZHpScM4Qz8Xw2iKSzS+cfglZzJGvofQICy7W7v4caru4EaAmyUuO6BGrbyQ2mYV11W0U8j5mBhd14dd3B0A==}+ engines: {node: '>=6.9.0'}++ '@bufbuild/[email protected]':+ resolution: {integrity: sha512-wJ8ReQbHxsAfXhrf9ixl0aYbZorRuOWpBNzm8pL8ftmSxQx/wnJD5Eg861NwJU/czy2VXFIebCeZnZrI9rktIQ==}++ '@emnapi/[email protected]':+ resolution: {integrity: sha512-ewvYlk86xUoGI0zQRNq/mC+16R1QeDlKQy21Ki3oSYXNgLb45GV1P6A0M+/s6nyCuNDqe5VpaY84BzXGwVbwFA==}++ '@eslint-community/[email protected]':+ resolution: {integrity: sha512-phrYmNiYppR7znFEdqgfWHXR6NCkZEK7hwWDHZUjit/2/U0r6XvkDl0SYnoM51Hq7FhCGdLDT6zxCCOY1hexsQ==}+ engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0}+ peerDependencies:+ eslint: ^6.0.0 || ^7.0.0 || >=8.0.0++ '@eslint-community/[email protected]':+ resolution: {integrity: sha512-EriSTlt5OC9/7SXkRSCAhfSxxoSUgBm33OH+IkwbdpgoqsSsUg7y3uh+IICI/Qg4BBWr3U2i39RpmycbxMq4ew==}+ engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-nJl2KGTlrf9GjLimgIru+V/mzgSK0ABCDQRvxw5BjURL7WfH5uoWmizbH7QB6MmnMBd8cIC9uceWnezL1VZWWw==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-gBrxN88gOIf3R7ja5K9slwNayVcZgK6SOUORm2uBzTeIEfeVaIhOpCtTox3P6R7o2jLFwLFTLnC7kU/RGcYEgw==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-yL/sLrpmtDaFEiUj1osRP4TI2MDz1AddJL+jZ7KSqvBuliN4xqYY54IfdN8qD8Toa6g1iloph1fxQNkjOxrrpQ==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-4IlJx0X0qftVsN5E+/vGujTRIFtwuLbNsVUe7TO6zYPDR1O6nFwvwhIKEKSrl6dZchmYBITazxKoUYOjdtjlRg==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-nE7DEIchvtiFTwBw4Lfbu59PG+kCofhjsKaCWzxTpt4lfRjRMqG6uMBzKXuEcyXhOHoUp9riAm7/aWYGhXZ9cw==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-VtAOaymWVfZcmZbp6E2mympDIHvyjXs/12LqWYjVw6qjrfF+VK+fyG33kChz3nnK+SU5/NeHOqrTEHS8sXO3OA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-43/qtrDUokr7LJqoF2c3+RInu/t4zfrpYdoSDfYyhg52rwLV6TnOvdG4fXm7IkSB3wErkcmJS9iEhjVtOSEjjA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@floating-ui/[email protected]':+ resolution: {integrity: sha512-1Ih4WTWyw0+lKyFMcBHGbb5U5FtuHJuujoyyr5zTaWS5EYMeT6Jb2AuDeftsCsEuchO+mM2ij5+q9crhydzLhQ==}++ '@floating-ui/[email protected]':+ resolution: {integrity: sha512-9gZSAI5XM36880PPMm//9dfiEngYoC6Am2izES1FF406YFsjvyBMmeJ2g4SAju3xWwtuynNRFL2s9hgxpLI5SQ==}++ '@floating-ui/[email protected]':+ resolution: {integrity: sha512-cC52bHwM/n/CxS87FH0yWdngEZrjdtLW/qVruo68qg+prK7ZQ4YGdut2GyDVpoGeAYe/h899rVeOVm6Oi40k2A==}+ peerDependencies:+ react: '>=16.8.0'+ react-dom: '>=16.8.0'++ '@floating-ui/[email protected]':+ resolution: {integrity: sha512-RiB/yIh78pcIxl6lLMG0CgBXAZ2Y0eVHqMPYugu+9U0AeT6YBeiJpf7lbdJNIugFP5SIjwNRgo4DhR1Qxi26Gg==}++ '@humanfs/[email protected]':+ resolution: {integrity: sha512-UhXNm+CFMWcbChXywFwkmhqjs3PRCmcSa/hfBgLIb7oQ5HNb1wS0icWsGtSAUNgefHeI+eBrA8I1fxmbHsGdvA==}+ engines: {node: '>=18.18.0'}++ '@humanfs/[email protected]':+ resolution: {integrity: sha512-gE1eQNZ3R++kTzFUpdGlpmy8kDZD/MLyHqDwqjkVQI0JMdI1D51sy1H958PNXYkM2rAac7e5/CnIKZrHtPh3BQ==}+ engines: {node: '>=18.18.0'}++ '@humanfs/[email protected]':+ resolution: {integrity: sha512-ZZ1w0aoQkwuUuC7Yf+7sdeaNfqQiiLcSRbfI08oAxqLtpXQr9AIVX7Ay7HLDuiLYAaFPu8oBYNq/QIi9URHJ3Q==}+ engines: {node: '>=18.18.0'}++ '@humanwhocodes/[email protected]':+ resolution: {integrity: sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==}+ engines: {node: '>=12.22'}++ '@humanwhocodes/[email protected]':+ resolution: {integrity: sha512-bV0Tgo9K4hfPCek+aMAn81RppFKv2ySDQeMoSZuvTASywNTnVJCArCZE2FWqpvIatKu7VMRLWlR1EazvVhDyhQ==}+ engines: {node: '>=18.18'}++ '@img/[email protected]':+ resolution: {integrity: sha512-Td76q7j57o/tLVdgS746cYARfSyxk8iEfRxewL9h4OMzYhbW4TAcppl0mT4eyqXddh6L/jwoM75mo7ixa/pCeQ==}+ engines: {node: '>=18'}++ '@img/[email protected]':+ resolution: {integrity: sha512-imtQ3WMJXbMY4fxb/Ndp6HBTNVtWCUI0WdobyheGf5+ad6xX8VIDO8u2xE4qc/fr08CKG/7dDseFtn6M6g/r3w==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [arm64]+ os: [darwin]++ '@img/[email protected]':+ resolution: {integrity: sha512-YNEFAF/4KQ/PeW0N+r+aVVsoIY0/qxxikF2SWdp+NRkmMB7y9LBZAVqQ4yhGCm/H3H270OSykqmQMKLBhBJDEw==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [x64]+ os: [darwin]++ '@img/[email protected]':+ resolution: {integrity: sha512-zqjjo7RatFfFoP0MkQ51jfuFZBnVE2pRiaydKJ1G/rHZvnsrHAOcQALIi9sA5co5xenQdTugCvtb1cuf78Vf4g==}+ cpu: [arm64]+ os: [darwin]++ '@img/[email protected]':+ resolution: {integrity: sha512-1IOd5xfVhlGwX+zXv2N93k0yMONvUlANylbJw1eTah8K/Jtpi15KC+WSiaX/nBmbm2HxRM1gZ0nSdjSsrZbGKg==}+ cpu: [x64]+ os: [darwin]++ '@img/[email protected]':+ resolution: {integrity: sha512-excjX8DfsIcJ10x1Kzr4RcWe1edC9PquDRRPx3YVCvQv+U5p7Yin2s32ftzikXojb1PIFc/9Mt28/y+iRklkrw==}+ cpu: [arm64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-bFI7xcKFELdiNCVov8e44Ia4u2byA+l3XtsAj+Q8tfCwO6BQ8iDojYdvoPMqsKDkuoOo+X6HZA0s0q11ANMQ8A==}+ cpu: [arm]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-FMuvGijLDYG6lW+b/UvyilUWu5Ayu+3r2d1S8notiGCIyYU/76eig1UfMmkZ7vwgOrzKzlQbFSuQfgm7GYUPpA==}+ cpu: [ppc64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-oVDbcR4zUC0ce82teubSm+x6ETixtKZBh/qbREIOcI3cULzDyb18Sr/Wcyx7NRQeQzOiHTNbZFF1UwPS2scyGA==}+ cpu: [riscv64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-qmp9VrzgPgMoGZyPvrQHqk02uyjA0/QrTO26Tqk6l4ZV0MPWIW6LTkqOIov+J1yEu7MbFQaDpwdwJKhbJvuRxQ==}+ cpu: [s390x]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-tJxiiLsmHc9Ax1bz3oaOYBURTXGIRDODBqhveVHonrHJ9/+k89qbLl0bcJns+e4t4rvaNBxaEZsFtSfAdquPrw==}+ cpu: [x64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-FVQHuwx1IIuNow9QAbYUzJ+En8KcVm9Lk5+uGUQJHaZmMECZmOlix9HnH7n1TRkXMS0pGxIJokIVB9SuqZGGXw==}+ cpu: [arm64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-+LpyBk7L44ZIXwz/VYfglaX/okxezESc6UxDSoyo2Ks6Jxc4Y7sGjpgU9s4PMgqgjj1gZCylTieNamqA1MF7Dg==}+ cpu: [x64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-bKQzaJRY/bkPOXyKx5EVup7qkaojECG6NLYswgktOZjaXecSAeCWiZwwiFf3/Y+O1HrauiE3FVsGxFg8c24rZg==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [arm64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-9dLqsvwtg1uuXBGZKsxem9595+ujv0sJ6Vi8wcTANSFpwV/GONat5eCkzQo/1O6zRIkh0m/8+5BjrRr7jDUSZw==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [arm]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-7zznwNaqW6YtsfrGGDA6BRkISKAAE1Jo0QdpNYXNMHu2+0dTrPflTLNkpc8l7MUP5M16ZJcUvysVWWrMefZquA==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [ppc64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-51gJuLPTKa7piYPaVs8GmByo7/U7/7TZOq+cnXJIHZKavIRHAP77e3N2HEl3dgiqdD/w0yUfiJnII77PuDDFdw==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [riscv64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-nQtCk0PdKfho3eC5MrbQoigJ2gd1CgddUMkabUj+rBevs8tZ2cULOx46E7oyX+04WGfABgIwmMC0VqieTiR4jg==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [s390x]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-MEzd8HPKxVxVenwAa+JRPwEC7QFjoPWuS5NZnBt6B3pu7EG2Ge0id1oLHZpPJdn3OQK+BQDiw9zStiHBTJQQQQ==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [x64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-fprJR6GtRsMt6Kyfq44IsChVZeGN97gTD331weR1ex1c1rypDEABN6Tm2xa1wE6lYb5DdEnk03NZPqA7Id21yg==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [arm64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-Jg8wNT1MUzIvhBFxViqrEhWDGzqymo3sV7z7ZsaWbZNDLXRJZoRGrjulp60YYtV4wfY8VIKcWidjojlLcWrd8Q==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [x64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-OdWTEiVkY2PHwqkbBI8frFxQQFekHaSSkUIJkwzclWZe64O1X4UlUjqqqLaPbUpMOQk6FBu/HtlGXNblIs0huw==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [wasm32]++ '@img/[email protected]':+ resolution: {integrity: sha512-WQ3AgWCWYSb2yt+IG8mnC6Jdk9Whs7O0gxphblsLvdhSpSTtmu69ZG1Gkb6NuvxsNACwiPV6cNSZNzt0KPsw7g==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [arm64]+ os: [win32]++ '@img/[email protected]':+ resolution: {integrity: sha512-FV9m/7NmeCmSHDD5j4+4pNI8Cp3aW+JvLoXcTUo0IqyjSfAZJ8dIUmijx1qaJsIiU+Hosw6xM5KijAWRJCSgNg==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [ia32]+ os: [win32]++ '@img/[email protected]':+ resolution: {integrity: sha512-+29YMsqY2/9eFEiW93eqWnuLcWcufowXewwSNIT6UwZdUUCrM3oFjMWH/Z6/TMmb4hlFenmfAVbpWeup2jryCw==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [x64]+ os: [win32]++ '@jridgewell/[email protected]':+ resolution: {integrity: sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA==}++ '@jridgewell/[email protected]':+ resolution: {integrity: sha512-LI9u/+laYG4Ds1TDKSJW2YPrIlcVYOwi2fUC6xB43lueCjgxV4lffOCZCtYFiH6TNOX+tQKXx97T4IKHbhyHEQ==}++ '@jridgewell/[email protected]':+ resolution: {integrity: sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==}+ engines: {node: '>=6.0.0'}++ '@jridgewell/[email protected]':+ resolution: {integrity: sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==}++ '@jridgewell/[email protected]':+ resolution: {integrity: sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==}++ '@livekit/[email protected]':+ resolution: {integrity: sha512-EsshAucklmpuUAfkABPxJNhzj9v2sG7JuzFDL4ML1oJQSV14sqrpTYnsaOudMAw9yOaW53NU3QQTlUQoRs4czw==}++ '@livekit/[email protected]':+ resolution: {integrity: sha512-/vfhDUGcUKO8Q43r6i+5FrDhl5oZjm/X3U4x2Iciqvgn5C8qbj+57YPcWSJ1kyIZm5Cm6AV2nAPjMm3ETD/iyg==}++ '@livekit/[email protected]':+ resolution: {integrity: sha512-YPDmrUiVe1EY/q/2bD+Fp+69DWq6LZgeH+G/KEbz07OIVf8hgAYzfb1FgiOdWLRpSj06+SuTmrOY604fWNuD3w==}++ '@next/[email protected]':+ resolution: {integrity: sha512-N1ySLuZjnAtN3kFnwhAwPvZah8RJxKasD7x1f8shFqhncnWZn4JMfg37diLNuoHsLAlrDfM3g4mawVdtAG8XLQ==}++ '@next/[email protected]':+ resolution: {integrity: sha512-/Qq3PTagA6+nYVfryAtQ7/9FEr/6YVyvOtl6rZnGsbReGLf0jZU6gkpr1FuChAQpvV46a78p4cmHOVP8mbfSMQ==}++ '@next/[email protected]':+ resolution: {integrity: sha512-wTzYulosJr/6nFnqGW7FrG3jfUUlEf8UjGA0/pyypJl42ExdVgC6xJgcXQ+V8QFn6niSG2Pb8+MIG1mZr2vczw==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [darwin]++ '@next/[email protected]':+ resolution: {integrity: sha512-BLFPYPDO+MNJsiDWbeVzqvYd4NyuRrEYVB5k2N3JfWncuHAy2IVwMAOlVQDFjj+krkWzhY2apvmekMkfQR0CUQ==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [darwin]++ '@next/[email protected]':+ resolution: {integrity: sha512-OJYkCd5pj/QloBvoEcJ2XiMnlJkRv9idWA/j0ugSuA34gMT6f5b7vOiCQHVRpvStoZUknhl6/UxOXL4OwtdaBw==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [linux]++ '@next/[email protected]':+ resolution: {integrity: sha512-S4J2v+8tT3NIO9u2q+S0G5KdvNDjXfAv06OhfOzNDaBn5rw84DGXWndOEB7d5/x852A20sW1M56vhC/tRVbccQ==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [linux]++ '@next/[email protected]':+ resolution: {integrity: sha512-2eEBDkFlMMNQnkTyPBhQOAyn2qMxyG2eE7GPH2WIDGEpEILcBPI/jdSv4t6xupSP+ot/jkfrCShLAa7+ZUPcJQ==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [linux]++ '@next/[email protected]':+ resolution: {integrity: sha512-oicJwRlyOoZXVlxmIMaTq7f8pN9QNbdes0q2FXfRsPhfCi8n8JmOZJm5oo1pwDaFbnnD421rVU409M3evFbIqg==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [linux]++ '@next/[email protected]':+ resolution: {integrity: sha512-gQmm8izDTPgs+DCWH22kcDmuUp7NyiJgEl18bcr8irXA5N2m2O+JQIr6f3ct42GOs9c0h8QF3L5SzIxcYAAXXw==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [win32]++ '@next/[email protected]':+ resolution: {integrity: sha512-NRfO39AIrzBnixKbjuo2YiYhB6o9d8v/ymU9m/Xk8cyVk+k7XylniXkHwjs4s70wedVffc6bQNbufk5v0xEm0A==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [win32]++ '@nodelib/[email protected]':+ resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==}+ engines: {node: '>= 8'}++ '@nodelib/[email protected]':+ resolution: {integrity: sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==}+ engines: {node: '>= 8'}++ '@nodelib/[email protected]':+ resolution: {integrity: sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==}+ engines: {node: '>= 8'}++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-MkKCwxlXTgz6CFoJx3pCwn07GKp36+aZyu/u2Ln2VrA5DcdyCZkASEDBTd8x5whTQQL5CiYf4prXKLcgQdv29g==}++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-JTF99U/6XIjCBo0wqkU5sK10glYe27MRRsfwoiq5zzOEZLHU3A3KCMa5X/azekYRCJ0HlwI0crAXS/5dEHTzDg==}++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-XM+E4WXl0OqUJFovy6GjmxxFyx9opfCAIUku4dlKRd5YEPqt4kALOkQOp0Of6reHuUkJuiPBEc5k0o4z4lTC8A==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-T4nygeh9YE9dLRPhAHSeOZi7HBXo+0kYIPJXayZfvWOWA0+n3dESrZbjfDPUABkUNym6Hd+f2IR113To8D2GPA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-oTVLkEw5GpdRe29BqJ0LSDFWI3qu0vR1M0mUkOQWDIUnY/QIkLpgDMWuKxP94c2NAC2LGcgVhG1ImF3jkZ5wXw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-F+M1tLhO+mlQaOWspE8Wstg+z6PwxwRd8oQ8IXceWz92kfAmalTRf0EjrouQeo7QssEPfCn05B4Ihs1K9WQ/7w==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Yq6lvO9HQyPwev1onK1daHCHqXVLzPhSVjmsNjCa2Zcxy2f7uJD2itDtxknv6FzAKCwD1qQkeVDmX/cev13n/g==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-V8piFfWapM5OmNCXTzVQY+E1rDa53zY+MQ4Y7356v4fFz6vqCyUtIz2rUD44ZEdwg78/jKmMJHj07+C/Z/rcog==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-wBbpv+NQftHDdG86Qc0pIyXk5IR3tM8Vd0nWLKDcX8nNn4nXFOFwsKuqw2okA/1D/mpaAkmuyndrPJTYDNZtFw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Uu+mSh4agx2ib1uIGPP4/CKNULyajb3p92LsVXmH2EHVMTfZWpll88XJ0j4W0z3f8NK1eYl1+Mf/szHPmcHzyA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Fh9rGN0MoI4ZFUNyfFVNU4y9LUz93u9/0K+yLgA2bwRojxM8JU1DyvvMBabnZPBgMWREAJvU2jjVzq+LrFUglw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-z4eqJvfiNnFMHIIvXP3CY57y2WJs5g2v3X0zm9mEJkrkNv4rDxu+sg9Jh8EkXyeqBkB7SOcboo9dMVqhyrACIg==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-O8morBEW+HsVG28gYDZPTrT9UUovQUlJue5YO836tiTJhuIWBm/zQHc7j388sHWtdH/xUZurK9olD2+pcqx5ww==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-TCglVRtzlffRNxRMEyR36DGBLJpeusFcgMVD9PZEzAKnUs1lKCgX5u9BmC2Yg+LL9MgZDugFFs1Vl+Jp4t/PGw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-1UEWRX6jnOA2y4H5WczZ44gOOjTEmlqv1uNW4GAJEO5+bauCBhv8snY65Iw5/VOS/ghKN9gr2KjnLKxrsvoMVw==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Nqcp+t5cTB8BinFkZgXiMJniQH0PsUt2k51FUhbdfeKvc4ACcG2uQniY/8+h1Yv6Kza4Q7lD7PQV0z0oicE0Mg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-1PLGQEynI/3OX/ftV54COn+3Sud/Mn8vALg2rWnBLnRaGtJDduNW/22XjlGgPdpcIbiQxjKtb7BkcjP00nqfJw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-0rFg/Rj2Q62NCm62jZw0QX7a3sz6QCQU0LpZdNrJX8byRGaGVTqbrW9jAoIAHyMQqsNpeZ81YgSizOt5WXq0Pw==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-t2ODlkXBQyn7jkl6TNaw/MtVEVvIGelJDCG41Okq/KwUsJBwQ4XVZsHAVUkK4mBv3ewiAS3PGuUWuY2BoK4ZUw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-QM70k4Zwjttifr5a4sZFts9fn8FzHYvQ5PiB19O2HsYibaHSVt9fH9rzB0XZo/YcM+b7t/p7lYCT/F5eOeF5yQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-qgTkjNT1CfKMoP0rcasmlH2r1DAiYicWsDsufxl940sT2wHNEWWv6FMWIQXWhVdmC1d/HYfbhQx60KYyAtKxjg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-kGkGegYIdQsOb4XjsfM97rXsiHaBwco+hFI66oO4s9LU+PLAC5oJ7khdOVFxkhsmlbpUqDAvXw11CluXP+jkHg==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-YT1GqPSL8kJn20djelMX7/cTRp/Y9w5IZHvfxQTVHrOqa2yMl7i/UfMqKRU5V7mEyKTrUVgJXhNQPVCG8PBLoQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-72F2T+PLlphrqLcAotYPp0uJMr5SjP5SL01wfEspJbru5Zs5vQaSHb4VB3ZMJPimgHHCHG7gMOeOB9H3Hdmtxg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-EB1FktTz5xRRi2Er974AUQZWg2yVBb1yjip38/lgwtCVRd3a+maUoGHN/xs9Yv8SY8QwbSEb+YrxGadVWbEutA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-YB9mTFQvCOAQMHU+C/jVl96WmuWeltyUEpRJJky51huhds5W2FQr1J8D/16sQlf0ozxkPK8uF3niQMdUwZPv5w==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-ycS4rbwURavDPVjCb5iS3aG4lURFDILi6sKI/WITUMZ13gMmn/xGjpLoqBAalhJaDk8I3UbCM5GzKHrnzwHbvg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-/UuCrDBWravcaMix4TdT+qlNdVwOM1Nck9kWx/vafXsdfj1ChfhOdfi3cy9SGBpWgTXwYCuboT/oYpJy3clqfw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-kr0X2+6Yy/vJzLYJUPCZEc8SfQcf+1COFoAqauJm74umQhta9M7lNJHP7QQS3vkvcGLQUbWpMzwrXYwrYztHKA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-0NJQ4LFFUuWkE7Oxf0htBKS6zLkkjBH+hM1uk7Ng705ReR8m/uelduy1DBo0PyBXPKVnBA6YBlU94MBGXrSBCw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-bpIxvq03if6UNwXZ+HTK71JLh4APvnXntDc6XOX8UVq4XQOVl7lwok0AvIl+b8zgCw3fSaVTZMpAPPagXbKmHQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-/jfEwNDdQVBCNvjkGit4h6pMOzq8bHkopq458dPt2lMjx+eBQUohZNG9A7DtO/O5ukSbxuaNGXMjHicgwy6rQQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-vPdg/tF6YC/ynuBIJlk1mm7Le0VgW6ub6J2UWnTQ7/D23KXcPI1qy+0vBkgKgd38RCMJavBXpB83HPNFMTb0Fg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-VBKYIYImA5zsxACdisNQ3BjCBfmbGH3kQlnFVqlWU4tXwjy7cGX8ta80BcrO+WJXIn5iBylEH3K6ZTlee//lgQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-7A6S9jSgm/S+7MdtNDSb+IU859vQqJ/QAtcYQcfFC6W8RS4IxIZDldLR0xqCFZ6DCyrQLjLPsxtTNch5jVA4lA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-tAXIa1g3sM5CGpVT0uIbUx/U3Gs5N8T52IICuCtObaos1S8fzsrPXG5WObkQN3S6NVl6wKgPhAIiBGbWnvc97A==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-I30RydO+bnn2PQztvo25tswPH+wFBjehVGtmagkU78yMdwTwVf12wnAOF+AeP8S2N8xD+5UPbGhkUfPyvT+mwQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-0HEb8R9E8A+jZjvmFCy/J4xhbXy3TV+9XSnGJ3KvTtjlIUy/YQ/p6UYZvi7YbeoeXdyU9+Y3scizK6hkY37baA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-JPYb1GuM1bxfjMRlNLE+BcmBC8onfCi60Blk7OBqi2MLTFdS+8401U4uFjnwkOr49BLmXxLC6JHkvAsx5OJvHw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-bByzr1+ep1zk4VubeEVViV592vu2lHE2BZY5OnzehZqOOgogN80+mNtCqPkhn2gklJqOpxWgPoYTSnhBCqpOXQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-7xdcatg7/U+7+Udyoj2zodtI9H/IIopqo+YOIcZOq1nJwXWBZ9p8xiu5llXlekDbZkca79a/fozEYQXIA4sW6A==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-3OSz3TacUWy4WtOXV38DggwxoqJK4+eDkNMl5Z/MJZaoUPaP4/9lf81xXMe1I2ReTAptverZUpbPY4wWwWyL5g==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-5umnS0T8JQzQT6HbPyO7Hh9dgd82NmS36DQr+X/YJ9ctFNCiiQd6IJAYYZ33LUwm8M+taCz5t2ui29fHZc4Y6Q==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-lS1odchhFTeZv3xwHH31YPObmJn8gOg7Lq12inrr0+BH/l3Tsq32VfjqH1oh80ARM3mlkfMic15n0kg4sD1poQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-4ol06/1bLoFu1nwUqzdD4Y5RZ9oDdKeiHIsntug54Hcr1pgaHiPqHFEaXI1IFP/EsOfROQZ8Mig9VTIRza6Tjg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-tY7sVt1yL9ozIxvmbtN5qtmH2krXcBCfjEiCgKGLqunJHvgvZG2Pcl2oQ3kbcZARb1BGEHdkLzcYGO8ynVlieg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-FkBMwD+qbGQeMu1cOHnuGB6x4yzPjho8ap5WtbEJ26umhgqVXbhekKUQO+hZEL1vU92a3wHwdp0HAcqAUF5iDg==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-BjasUjixPFdS+NKkypcyyN5Pmg83Olst0+c6vGov0diwTEo6mgdqVR6hxcEgFuh4QrAs7Rc+9KuGJ9TVCj0Zzg==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Qp8WbZOBe+blgpuUT+lw2xheLP8q0oatc9UpmiemEICxGvFLYmHm9QowVZGHtJlGbS6A6yJ3iViad/2cVjnOiA==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Il0+boE7w/XebUHyBjroE+DbByORGR9KKmITzbR7MyQ4akpORYP/ZmbhAr0DG7RmmBqoOnZdy2QlvajJ2QA59g==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-U+UORVEq+cTnRIaostJv9AGdV3G6Y+zbVd+12e18jQ5A3c0xL03IhnHuiU4UV69wolOQp5GfR58NW/EgdQhwOA==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-RbJRS4UWQFkzHTTwVymMTUv8EqYhOp8dOOviLj2ugtTiXRaRQS7GLGxZTLL1jWhMeoSCf5zmcZkqTl9IiYfXcQ==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-2dHfToCj/pzca2Ck724OZ5L0EVrr3eHRNsG/b3xQJLA2hZpVCS99bLAX+hm1IHXDEnzU6by5z/5MIY794/a8NQ==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-QTYuDesS0VtuHNNvMh+CjlKJ4LJickCMUAqjlE3+j8w+RlRpwyX3apEQKGFzbZGdo7XNG1tXa+bQqIE7HIXT2w==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-ewrXRDTAqAXlkl6t/fkXWNAhFX9I+CkKlw6zjEwk86RSPKwZr3xpBRso655aqYafwtnbpHLj6toFzmd6xdVptQ==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-pzJq12tEaaIhqjbzpCuv/OypJY/BPavOofm+dbab+MHLajy277+1lLm6JFcGgF5eskJ6mquGirhXY2GD/8u8Ug==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-HPwpGIzkl28mWyZqG52jiqDJ12waP11Pa1lGoiyUkIEuMLBP0oeK/C89esbXrxsky5we7dfd8U58nm0SgAWpVw==}++ '@swc/[email protected]':+ resolution: {integrity: sha512-JQ5TuMi45Owi4/BIMAJBoSQoOJu12oOk/gADqlcUL9JEdHB8vyjUSsxqeNXnmXHjYKMi2WcYtezGEEhqUI/E2g==}++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-Ai7+yQPxz3ddrDQzFfBKdHEVBg0w3Zl83jnjuwxnZOsnH9pGn93QHQtpU0p/8rYWxvbFZHneni6p1BSLK4DkGA==}++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-e7MOr1SAn9U8KlZzPi1ZXGZHeC5anY36qjNwmZv9pOJ8E4Q6jmD1vyEHkQFmNOIN7twGPEMXRHmitN4zCMN03g==}+ engines: {node: '>= 20'}+ cpu: [arm64]+ os: [android]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-tSC/Kbqpz/5/o/C2sG7QvOxAKqyd10bq+ypZNf+9Fi2TvbVbv1zNpcEptcsU7DPROaSbVgUXmrzKhurFvo5eDg==}+ engines: {node: '>= 20'}+ cpu: [arm64]+ os: [darwin]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-yPyUXn3yO/ufR6+Kzv0t4fCg2qNr90jxXc5QqBpjlPNd0NqyDXcmQb/6weunH/MEDXW5dhyEi+agTDiqa3WsGg==}+ engines: {node: '>= 20'}+ cpu: [x64]+ os: [darwin]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-BoMIB4vMQtZsXdGLVc2z+P9DbETkiopogfWZKbWwM8b/1Vinbs4YcUwo+kM/KeLkX3Ygrf4/PsRndKaYhS8Eiw==}+ engines: {node: '>= 20'}+ cpu: [x64]+ os: [freebsd]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-7pIHBLTHYRAlS7V22JNuTh33yLH4VElwKtB3bwchK/UaKUPpQ0lPQiOWcbm4V3WP2I6fNIJ23vABIvoy2izdwA==}+ engines: {node: '>= 20'}+ cpu: [arm]+ os: [linux]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-+E4wxJ0ZGOzSH325reXTWB48l42i93kQqMvDyz5gqfRzRZ7faNhnmvlV4EPGJU3QJM/3Ab5jhJ5pCRUsKn6OQw==}+ engines: {node: '>= 20'}+ cpu: [arm64]+ os: [linux]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-bBADEGAbo4ASnppIziaQJelekCxdMaxisrk+fB7Thit72IBnALp9K6ffA2G4ruj90G9XRS2VQ6q2bCKbfFV82g==}+ engines: {node: '>= 20'}+ cpu: [arm64]+ os: [linux]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-7Mx25E4WTfnht0TVRTyC00j3i0M+EeFe7wguMDTlX4mRxafznw0CA8WJkFjWYH5BlgELd1kSjuU2JiPnNZbJDA==}+ engines: {node: '>= 20'}+ cpu: [x64]+ os: [linux]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-2wwJRF7nyhOR0hhHoChc04xngV3iS+akccHTGtz965FwF0up4b2lOdo6kI1EbDaEXKgvcrFBYcYQQ/rrnWFVfA==}+ engines: {node: '>= 20'}+ cpu: [x64]+ os: [linux]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-FQsqApeor8Fo6gUEklzmaa9994orJZZDBAlQpK2Mq+DslRKFJeD6AjHpBQ0kZFQohVr8o85PPh8eOy86VlSCmw==}+ engines: {node: '>=14.0.0'}+ cpu: [wasm32]+ bundledDependencies:+ - '@napi-rs/wasm-runtime'+ - '@emnapi/core'+ - '@emnapi/runtime'+ - '@tybys/wasm-util'+ - '@emnapi/wasi-threads'+ - tslib++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-L9BXqxC4ToVgwMFqj3pmZRqyHEztulpUJzCxUtLjobMCzTPsGt1Fa9enKbOpY2iIyVtaHNeNvAK8ERP/64sqGQ==}+ engines: {node: '>= 20'}+ cpu: [arm64]+ os: [win32]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-ESlKG0EpVJQwRjXDDa9rLvhEAh0mhP1sF7sap9dNZT0yyl9SAG6T7gdP09EH0vIv0UNTlo6jPWyujD6559fZvw==}+ engines: {node: '>= 20'}+ cpu: [x64]+ os: [win32]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-9El/iI069DKDSXwTvB9J4BwdO5JhRrOweGaK25taBAvBXyXqJAX+Jqdvs8r8gKpsI/1m0LeJLyQYTf/WLrBT1Q==}+ engines: {node: '>= 20'}++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-wgAVj6nUWAolAu8YFvzT2cTBIElWHkjZwFYovF+xsqKsW2ADxM/X2opxj5NsF/qVccAOjRNe8X2IdPzMsWyHTg==}++ '@types/[email protected]':+ resolution: {integrity: sha512-mUMZLK3NvwRLcAAT9qmcK+9p7tpU2FHdDsntR3YI4+GY88XrgG4XiE7u1Q2LAN2/FZOz/tdMDC3GQCR4T8nFuw==}++ '@types/[email protected]':+ resolution: {integrity: sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==}++ '@types/[email protected]':+ resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==}++ '@types/[email protected]':+ resolution: {integrity: sha512-+qIYRKdNYJwY3vRCZMdJbPLJAtGjQBudzZzdzwQYkEPQd+PJGixUL5QfvCLDaULoLv+RhT3LDkwEfKaAkgSmNQ==}++ '@types/[email protected]':+ resolution: {integrity: sha512-jp2L/eY6fn+KgVVQAOqYItbF0VY/YApe5Mz2F0aykSO8gx31bYCZyvSeYxCHKvzHG5eZjc+zyaS5BrBWya2+kQ==}+ peerDependencies:+ '@types/react': ^19.2.0++ '@types/[email protected]':+ resolution: {integrity: sha512-ilcTH/UniCkMdtexkoCN0bI7pMcJDvmQFPvuPvmEaYA/NSfFTAgdUSLAoVjaRJm7+6PvcM+q1zYOwS4wTYMF9w==}++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-BOziFIfE+6osHO9FoJG4zjoHUcvI7fTNBSpdAwrNH0/TLvzjsk2oo8XSSOT2HhqUyhZPfHv4UOffoJ9oEEQ7Ag==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ '@typescript-eslint/parser': ^8.59.1+ eslint: ^8.57.0 || ^9.0.0 || ^10.0.0+ typescript: '>=4.8.4 <6.1.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-HDQH9O/47Dxi1ceDhBXdaldtf/WV9yRYMjbjCuNk3qnaTD564qwv61Y7+gTxwxRKzSrgO5uhtw584igXVuuZkA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ eslint: ^8.57.0 || ^9.0.0 || ^10.0.0+ typescript: '>=4.8.4 <6.1.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-+MuHQlHiEr00Of/IQbE/MmEoi44znZHbR/Pz7Opq4HryUOlRi+/44dro9Ycy8Fyo+/024IWtw8m4JUMCGTYxDg==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ typescript: '>=4.8.4 <6.1.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-LwuHQI4pDOYVKvmH2dkaJo6YZCSgouVgnS/z7yBPKBMvgtBvyLqiLy9Z6b7+m/TRcX1NFYUqZetI5Y+aT4GEfg==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-/0nEyPbX7gRsk0Uwfe4ALwwgxuA66d/l2mhRDNlAvaj4U3juhUtJNq0DsY8M2AYwwb9rEq2hrC3IcIcEt++iJA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ typescript: '>=4.8.4 <6.1.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-klWPBR2ciQHS3f++ug/mVnWKPjBUo7icEL3FAO1lhAR1Z1i5NQYZ1EannMSRYcq5qCv5wNALlXr6fksRHyYl7w==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ eslint: ^8.57.0 || ^9.0.0 || ^10.0.0+ typescript: '>=4.8.4 <6.1.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-ZDCjgccSdYPw5Bxh+my4Z0lJU96ZDN7jbBzvmEn0FZx3RtU1C7VWl6NbDx94bwY3V5YsgwRzJPOgeY2Q/nLG8A==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-OUd+vJS05sSkOip+BkZ/2NS8RMxrAAJemsC6vU3kmfLyeaJT0TftHkV9mcx2107MmsBVXXexhVu4F0TZXyMl4g==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ typescript: '>=4.8.4 <6.1.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-3pIeoXhCeYH9FSCBI8P3iNwJlGuzPlYKkTlen2O9T1DSeeg8UG8jstq6BLk+Mda0qup7mgk4z4XL4OzRaxZ8LA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ eslint: ^8.57.0 || ^9.0.0 || ^10.0.0+ typescript: '>=4.8.4 <6.1.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-LdDNl6C5iJExcM0Yh0PwAIBb9PrSiCsWamF/JyEZawm3kFDnRoaq3LGE4bpyRao/fWeGKKyw7icx0YxrLFC5Cg==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==}+ peerDependencies:+ acorn: ^6.0.0 || ^7.0.0 || ^8.0.0++ resolution: {integrity: sha512-UVJyE9MttOsBQIDKw1skb9nAwQuR5wuGD3+82K6JgJlm/Y+KI92oNsMNGZCYdDsVtRHSak0pcV5Dno5+4jh9sw==}+ engines: {node: '>=0.4.0'}+ hasBin: true++ resolution: {integrity: sha512-fgFx7Hfoq60ytK2c7DhnF8jIvzYgOMxfugjLOSMHjLIPgenqa7S7oaagATUq99mV6IYvN2tRmC0wnTYX6iPbMw==}++ resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==}++ resolution: {integrity: sha512-ik3ZgC9dY/lYVVM++OISsaYDeg1tb0VtP5uL3ouh1koGOaUMDPpbFIei4JkFimWUFPn90sbMNMXQAIVOlnYKJA==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==}++ resolution: {integrity: sha512-BLrgEcRTwX2o6gGxGOCNyMvGSp35YofuYzw9h1IMTRmKqttAZZVU67bdb9Pr2vUHA8+j3i2tJfjO6C6+4myGTA==}+ engines: {node: 18 || 20 || >=22}++ resolution: {integrity: sha512-zEs/ufmZoUd7WftKpKyXaT6RFxpQ5Qm9xytKRHvJfxFV9DFJkZph9RvJ1LcOUi0Z1ZVijMte65JbILeV+8QQEA==}+ engines: {node: '>=6.0.0'}+ hasBin: true++ resolution: {integrity: sha512-MWPGfDxnyzKU7rNOW9SP/c50vi3xrmrua/+6hfPbCS2ABNWfx24vPidzvC7krjU/RTo235sV776ymlsMtGKj8g==}++ resolution: {integrity: sha512-VZznLgtwhn+Mact9tfiwx64fA9erHH/MCXEUfB/0bX/6Fz6ny5EGTXYltMocqg4xFAQZtnO3DHWWXi8RiuN7cQ==}+ engines: {node: 18 || 20 || >=22}++ resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-48xSriZYYg+8qXna9kwqjIVzuQxi+KYWp2+5nCYnYKPTr0LvD89Jqk2Or5ogxz0NUMfIjhh2lIUX/LyX9B4oIg==}+ engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7}+ hasBin: true++ resolution: {integrity: sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-Rircqi9ch8AnZscQcsA1C47NFdaO3wukpmIRzYcDOrmvgt78hM/sj5pZhZNec2NM12uk5vTwRHZ4anGcrC4ZTg==}+ engines: {node: '>=16'}++ resolution: {integrity: sha512-8WB3Jcas3swSvjIeA2yvCJ+Miyz5l1ZmB6HFb9R1317dt9LCQoswg/BGrmAmkWVEszSrrg4RwmO46qIm2OEnSA==}+ engines: {node: '>=16'}++ resolution: {integrity: sha512-yk0l/YSrOnFZk3UROpDLQD9+kC1l4meK/wed583AXrzoarMGJcbRi2Q4RaUYbKxYAsZ8sWmaSa/DsLmdBeI1vQ==}++ resolution: {integrity: sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-Ka+9Trutv7G8M6WT6SeiRWz792K5qEqIGEGzXKhAE6xOWAY6pPH8U+9IY3oCMv6kqTmLsv7Xh/2w2RigkePMsg==}++ resolution: {integrity: sha512-IV3Ou0jSMzZrd3pZ48nLkT9DA7Ag1pnPzaiQhpW7c3RbcqqzvzzVu+L8gfqMp/8IM2MQtSiqaCxrrcfu8I8rMA==}++ resolution: {integrity: sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==}+ engines: {node: '>=7.0.0'}++ resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==}++ resolution: {integrity: sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==}++ resolution: {integrity: sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==}++ resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==}+ engines: {node: '>= 8'}++ resolution: {integrity: sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==}++ resolution: {integrity: sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==}+ engines: {node: '>=6.0'}+ peerDependencies:+ supports-color: '*'+ peerDependenciesMeta:+ supports-color:+ optional: true++ resolution: {integrity: sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==}++ resolution: {integrity: sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-ypdmJU/TbBby2Dxibuv7ZLW3Bs1QEmM7nHjEANfohJLvE0XVujisn1qPJcZxg+qDucsr+bP6fLD1rPS3AhJ7EQ==}++ resolution: {integrity: sha512-QsWVGyRuY07Aqb234QytTfwd5d9AJlfNIQ5wIOl1L+PZDzI9d9+Fn0FRale/QYlFxt/bUnB0/nLd1jFPGxGK1A==}++ resolution: {integrity: sha512-otxSQPw4lkOZWkHpB3zaEQs6gWYEsmX4xQF68ElXC/TWvGxGMSGOvoNbaLXm6/cS/fSfHtsEdw90y20PCd+sCA==}+ engines: {node: '>=10.13.0'}++ resolution: {integrity: sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-82GZUjRS0p/jganf6q1rEO25VSoHH0hKPCTrgillPjdI/3bgBhAE1QzHrHTizjpRvy6pGAvKjDJtk2pF9NDq8w==}+ hasBin: true+ peerDependencies:+ eslint: '>=7.0.0'++ resolution: {integrity: sha512-f2I7Gw6JbvCexzIInuSbZpfdQ44D7iqdWX01FKLvrPgqxoE7oMj8clOfto8U6vYiz4yd5oKu39rRSVOe1zRu0g==}+ engines: {node: '>=18'}+ peerDependencies:+ eslint: ^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0 || ^9.0.0 || ^10.0.0++ resolution: {integrity: sha512-sNXOfKCn74rt8RICKMvJS7XKV/Xk9kA7DyJr8mJik3S7Cwgy3qlkkmyS2uQB3jiJg6VNdZd/pDBJu0nvG2NlTg==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ resolution: {integrity: sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==}+ engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0}++ resolution: {integrity: sha512-Uhdk5sfqcee/9H/rCOJikYz67o0a2Tw2hGRPOG2Y1R2dg7brRe1uG0yaNQDHu+TO/uQPF/5eCapvYSmHUjt7JQ==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ resolution: {integrity: sha512-tD40eHxA35h0PEIZNeIjkHoDR4YjjJp34biM0mDvplBe//mB+IHCqHDGV7pxF+7MklTvighcCPPZC7ynWyjdTA==}+ engines: {node: ^20.19.0 || ^22.13.0 || >=24}++ resolution: {integrity: sha512-XoMjdBOwe/esVgEvLmNsD3IRHkm7fbKIUGvrleloJXUZgDHig2IPWNniv+GwjyJXzuNqVjlr5+4yVUZjycJwfQ==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ hasBin: true+ peerDependencies:+ jiti: '*'+ peerDependenciesMeta:+ jiti:+ optional: true++ resolution: {integrity: sha512-j6PAQ2uUr79PZhBjP5C5fhl8e39FmRnOjsD5lGnWrFU8i2G776tBK7+nP8KuQUTTyAZUwfQqXAgrVH5MbH9CYQ==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ resolution: {integrity: sha512-Ap6G0WQwcU/LHsvLwON1fAQX9Zp0A2Y6Y/cJBl9r/JbW90Zyg4/zbG6zzKa2OTALELarYHmKu0GhpM5EO+7T0g==}+ engines: {node: '>=0.10'}++ resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==}+ engines: {node: '>=4.0'}++ resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==}+ engines: {node: '>=4.0'}++ resolution: {integrity: sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==}+ engines: {node: '>=0.8.x'}++ resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==}++ resolution: {integrity: sha512-kNFPyjhh5cKjrUltxs+wFx+ZkbRaxxmZ+X0ZU31SOsxCEtP9VPgtq2teZw1DebupL5GmDaNQ6yKMMVcM41iqDg==}+ engines: {node: '>=8.6.0'}++ resolution: {integrity: sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==}++ resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==}++ resolution: {integrity: sha512-GGToxJ/w1x32s/D2EKND7kTil4n8OVk/9mycTc4VDza13lOvpUZTGX3mFSCtV9ksdGBVzvsyAVLM6mHFThxXxw==}++ resolution: {integrity: sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==}+ engines: {node: '>=12.0.0'}+ peerDependencies:+ picomatch: ^3 || ^4+ peerDependenciesMeta:+ picomatch:+ optional: true++ resolution: {integrity: sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ==}+ engines: {node: '>=16.0.0'}++ resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw==}+ engines: {node: '>=16'}++ resolution: {integrity: sha512-PjDse7RzhcPkIJwy5t7KPWQSZ9cAbzQXcafsetQoD7sOJRQlGikNbx7yZp2OotDnJyrDcbyRq3Ttb18iYOqkxA==}++ resolution: {integrity: sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==}+ engines: {node: '>=6.9.0'}++ resolution: {integrity: sha512-FJhYRoDaiatfEkUK8HKlicmu/3SGFD51q3itKDGoSTysQJBnfOcxU5GxnhE1E6soB76MbT0MBtnKJuXyAx+96Q==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==}+ engines: {node: '>= 6'}++ resolution: {integrity: sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==}+ engines: {node: '>=10.13.0'}++ resolution: {integrity: sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==}+ engines: {node: '>=18'}++ resolution: {integrity: sha512-c/c15i26VrJ4IRt5Z89DnIzCGDn9EcebibhAOjw5ibqEHsE1wLUgkPn9RDmNcUKyU87GeaL633nyJ+pplFR2ZQ==}+ engines: {node: '>=18'}++ resolution: {integrity: sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==}++ resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-0wUoCcLp+5Ev5pDW2OriHC2MJCbwLwuRx+gAqMTOkGKJJiBCLjtrvy4PWUGn6MIVefecRpzoOZ/UV6iGdOr+Cw==}++ resolution: {integrity: sha512-6pEjquH3rqaI6cYAXYPcz9MS4rY6R4ngRgrgfDshRptUZIc3lw0MCIJIGDj9++mfySOuPTHB4nrSW99BCvOPIA==}++ resolution: {integrity: sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==}+ engines: {node: '>= 4'}++ resolution: {integrity: sha512-Hs59xBNfUIunMFgWAbGX5cq6893IbWg4KnrjbYwX3tx0ztorVgTDA6B2sxf8ejHJ4wz8BqGUMYlnzNBer5NvGg==}+ engines: {node: '>= 4'}++ resolution: {integrity: sha512-TR3KfrTZTYLPB6jUjfx6MF9WcWrHL9su5TObK4ZkYgBdWKPOFoSoQIdEuTuR82pmtxH2spWG9h6etwfr1pLBqQ==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==}+ engines: {node: '>=0.8.19'}++ resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==}+ engines: {node: '>=0.12.0'}++ resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==}++ resolution: {integrity: sha512-ekilCSN1jwRvIbgeg/57YFh8qQDNbwDb9xT/qu2DAHbFFZUicIl4ygVaAvzveMhMVr3LnpSKTNnwt8PoOfmKhQ==}+ hasBin: true++ resolution: {integrity: sha512-s+3Al/p9g32Iq+oqXxkW//7jk2Vig6FF1CFqzVXoTUXt2qz89YWbL+OwS17NFYEvxC35n0FKeGO2LGYSxeM2Gg==}++ resolution: {integrity: sha512-YYVDInQKFJfR/xa3ojUTl8c2KoTwiL1R5Wg9YCydwH0x0B9grbzlg5HC7mMjCtUJjbQ/YnGEZIhI5tCgfTb4Hw==}++ resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==}++ resolution: {integrity: sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==}+ hasBin: true++ resolution: {integrity: sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA==}+ engines: {node: '>=6'}+ hasBin: true++ resolution: {integrity: sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==}++ resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==}++ resolution: {integrity: sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==}++ resolution: {integrity: sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==}+ engines: {node: '>=6'}+ hasBin: true++ resolution: {integrity: sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==}++ resolution: {integrity: sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==}+ engines: {node: '>= 0.8.0'}++ resolution: {integrity: sha512-YK7/ClTt4kAK0vo6w3X+Pnm0D2cf2vPHbhOXdoNti1Ga0al1P4TBZhwjATvjNwLEBCnKvjJc2jQgHXH0NEwlAg==}+ engines: {node: '>= 12.0.0'}+ cpu: [arm64]+ os: [android]++ resolution: {integrity: sha512-RzeG9Ju5bag2Bv1/lwlVJvBE3q6TtXskdZLLCyfg5pt+HLz9BqlICO7LZM7VHNTTn/5PRhHFBSjk5lc4cmscPQ==}+ engines: {node: '>= 12.0.0'}+ cpu: [arm64]+ os: [darwin]++ resolution: {integrity: sha512-U+QsBp2m/s2wqpUYT/6wnlagdZbtZdndSmut/NJqlCcMLTWp5muCrID+K5UJ6jqD2BFshejCYXniPDbNh73V8w==}+ engines: {node: '>= 12.0.0'}+ cpu: [x64]+ os: [darwin]++ resolution: {integrity: sha512-JCTigedEksZk3tHTTthnMdVfGf61Fky8Ji2E4YjUTEQX14xiy/lTzXnu1vwiZe3bYe0q+SpsSH/CTeDXK6WHig==}+ engines: {node: '>= 12.0.0'}+ cpu: [x64]+ os: [freebsd]++ resolution: {integrity: sha512-x6rnnpRa2GL0zQOkt6rts3YDPzduLpWvwAF6EMhXFVZXD4tPrBkEFqzGowzCsIWsPjqSK+tyNEODUBXeeVHSkw==}+ engines: {node: '>= 12.0.0'}+ cpu: [arm]+ os: [linux]++ resolution: {integrity: sha512-0nnMyoyOLRJXfbMOilaSRcLH3Jw5z9HDNGfT/gwCPgaDjnx0i8w7vBzFLFR1f6CMLKF8gVbebmkUN3fa/kQJpQ==}+ engines: {node: '>= 12.0.0'}+ cpu: [arm64]+ os: [linux]++ resolution: {integrity: sha512-UpQkoenr4UJEzgVIYpI80lDFvRmPVg6oqboNHfoH4CQIfNA+HOrZ7Mo7KZP02dC6LjghPQJeBsvXhJod/wnIBg==}+ engines: {node: '>= 12.0.0'}+ cpu: [arm64]+ os: [linux]++ resolution: {integrity: sha512-V7Qr52IhZmdKPVr+Vtw8o+WLsQJYCTd8loIfpDaMRWGUZfBOYEJeyJIkqGIDMZPwPx24pUMfwSxxI8phr/MbOA==}+ engines: {node: '>= 12.0.0'}+ cpu: [x64]+ os: [linux]++ resolution: {integrity: sha512-bYcLp+Vb0awsiXg/80uCRezCYHNg1/l3mt0gzHnWV9XP1W5sKa5/TCdGWaR/zBM2PeF/HbsQv/j2URNOiVuxWg==}+ engines: {node: '>= 12.0.0'}+ cpu: [x64]+ os: [linux]++ resolution: {integrity: sha512-8SbC8BR40pS6baCM8sbtYDSwEVQd4JlFTOlaD3gWGHfThTcABnNDBda6eTZeqbofalIJhFx0qKzgHJmcPTnGdw==}+ engines: {node: '>= 12.0.0'}+ cpu: [arm64]+ os: [win32]++ resolution: {integrity: sha512-Amq9B/SoZYdDi1kFrojnoqPLxYhQ4Wo5XiL8EVJrVsB8ARoC1PWW6VGtT0WKCemjy8aC+louJnjS7U18x3b06Q==}+ engines: {node: '>= 12.0.0'}+ cpu: [x64]+ os: [win32]++ resolution: {integrity: sha512-NXYBzinNrblfraPGyrbPoD19C1h9lfI/1mzgWYvXUTe414Gz/X1FD2XBZSZM7rRTrMA8JL3OtAaGifrIKhQ5yQ==}+ engines: {node: '>= 12.0.0'}++ resolution: {integrity: sha512-htwsAL/BMylY/zwdcT/z00U789csbi9DldSW7DO+5tz7Q15pwu++E1X+ZdtZDfkmlysfQLLibdcqlyg9FY7veQ==}+ peerDependencies:+ '@types/dom-mediacapture-record': ^1++ resolution: {integrity: sha512-HmzjWnwEwwShu8yUf7VGFXdc+BuMJR5pnIY4qsdlhqI9d9wDgq+4cdTEHg0NEBaiGnc6PCOBiaTYgmIyVJ0S9w==}+ engines: {node: '>=18'}++ resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==}++ resolution: {integrity: sha512-HgMmCqIJSAKqo68l0rS2AanEWfkxaZ5wNiEFb5ggm08lDs9Xl2KxBlX3PTcaD2chBM1gXAYf491/M2Rv8Jwayg==}+ engines: {node: '>= 0.6.0'}++ resolution: {integrity: sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==}++ resolution: {integrity: sha512-+1mdWcfSJVUsaTIjN9zoezmUhfXo5l0vP7ekBMPo3jcS/aIkxHnXqAPsByszMZx/Y8oQBRJxJx5xg+RH3urzxA==}+ peerDependencies:+ react: ^16.5.1 || ^17.0.0 || ^18.0.0 || ^19.0.0++ resolution: {integrity: sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ==}++ resolution: {integrity: sha512-2L3MIgJynYrZ3TYMriLDLWocz15okFakV6J12HXvMXDHui2x/zgChzg1u9mFFGbbGWE+GsLpQByt4POb9Or+uA==}+ engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0}++ resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==}+ engines: {node: '>= 8'}++ resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==}+ engines: {node: '>=8.6'}++ resolution: {integrity: sha512-MULkVLfKGYDFYejP07QOurDLLQpcjk7Fw+7jXS2R2czRQzR56yHRveU5NDJEOviH+hETZKSkIk5c+T23GjFUMg==}+ engines: {node: 18 || 20 || >=22}++ resolution: {integrity: sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w==}++ resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==}++ resolution: {integrity: sha512-ZB9RH/39qpq5Vu6Y+NmUaFhQR6pp+M2Xt76XBnEwDaGcVAqhlvxrl3B2bKS5D3NH3QR76v3aSrKaF/Kiy7lEtQ==}+ engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1}+ hasBin: true++ resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==}++ resolution: {integrity: sha512-pZvgD5L0IEvX5/9GWyHMf3m8BKiVQwsCMHfoFosXtXBMnaS0ZnIJ9ST4b4NqLVKDEm8QBxoNNGNaBv2JNF6XNA==}+ peerDependencies:+ react: ^16.8 || ^17 || ^18 || ^19 || ^19.0.0-rc+ react-dom: ^16.8 || ^17 || ^18 || ^19 || ^19.0.0-rc++ resolution: {integrity: sha512-hkyRkcu5x/41KoqnROkfTm2pZVbKxvbZRuNvKXLRXxs3VfyO0WhY50TQS40EuKO9SW3rBj/sF3WbVwDACeMZyw==}+ engines: {node: '>=20.9.0'}+ hasBin: true+ peerDependencies:+ '@opentelemetry/api': ^1.1.0+ '@playwright/test': ^1.51.1+ babel-plugin-react-compiler: '*'+ react: ^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0+ react-dom: ^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0+ sass: ^1.3.0+ peerDependenciesMeta:+ '@opentelemetry/api':+ optional: true+ '@playwright/test':+ optional: true+ babel-plugin-react-compiler:+ optional: true+ sass:+ optional: true++ resolution: {integrity: sha512-3qT/88Y3FbH/Kx4szpQQ4HzUbVrHPKTLVpVocKiLfoYvw9XSGOX2FmD2d6DrXbVYyAQTF2HeF6My8jmzx7/CRw==}++ resolution: {integrity: sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==}+ engines: {node: '>= 0.8.0'}++ resolution: {integrity: sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==}++ resolution: {integrity: sha512-V7+vQEJ06Z+c5tSye8S+nHUfI51xoXIXjHQ99cQtKUkQqqO1kO/KCJUfZXuB47h/YBlDhah2H3hdUGXn8ie0oA==}+ engines: {node: '>=8.6'}++ resolution: {integrity: sha512-QP88BAKvMam/3NxH6vj2o21R6MjxZUAd6nlwAS/pnGvN9IVLocLHxGYIzFhg6fUQ+5th6P4dv4eW9jX3DSIj7A==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-PS08Iboia9mts/2ygV3eLpY5ghnUcfLV/EXTOW1E2qYxJKGGBUtNjN76FYHnMs36RmARn41bC0AZmn+rR0OVpQ==}+ engines: {node: ^10 || ^12 || >=14}++ resolution: {integrity: sha512-qif0+jGGZoLWdHey3UFHHWP0H7Gbmsk8T5VEqyYFbWqPr1XqvLGBbk/sl8V5exGmcYJklJOhOQq1pV9IcsiFag==}+ engines: {node: ^10 || ^12 || >=14}++ resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==}+ engines: {node: '>= 0.8.0'}++ resolution: {integrity: sha512-UKii4RjY05SNt/WQi6/NcOn/LsT0/ILLXsxygjbRg5/YZelsSu5jTqorYHPDGq4nZy5q5hpCu+XdGZ1xaJEQgw==}+ engines: {node: '>=20.19'}+ peerDependencies:+ '@ianvs/prettier-plugin-sort-imports': '*'+ '@prettier/plugin-hermes': '*'+ '@prettier/plugin-oxc': '*'+ '@prettier/plugin-pug': '*'+ '@shopify/prettier-plugin-liquid': '*'+ '@trivago/prettier-plugin-sort-imports': '*'+ '@zackad/prettier-plugin-twig': '*'+ prettier: ^3.0+ prettier-plugin-astro: '*'+ prettier-plugin-css-order: '*'+ prettier-plugin-jsdoc: '*'+ prettier-plugin-marko: '*'+ prettier-plugin-multiline-arrays: '*'+ prettier-plugin-organize-attributes: '*'+ prettier-plugin-organize-imports: '*'+ prettier-plugin-sort-imports: '*'+ prettier-plugin-svelte: '*'+ peerDependenciesMeta:+ '@ianvs/prettier-plugin-sort-imports':+ optional: true+ '@prettier/plugin-hermes':+ optional: true+ '@prettier/plugin-oxc':+ optional: true+ '@prettier/plugin-pug':+ optional: true+ '@shopify/prettier-plugin-liquid':+ optional: true+ '@trivago/prettier-plugin-sort-imports':+ optional: true+ '@zackad/prettier-plugin-twig':+ optional: true+ prettier-plugin-astro:+ optional: true+ prettier-plugin-css-order:+ optional: true+ prettier-plugin-jsdoc:+ optional: true+ prettier-plugin-marko:+ optional: true+ prettier-plugin-multiline-arrays:+ optional: true+ prettier-plugin-organize-attributes:+ optional: true+ prettier-plugin-organize-imports:+ optional: true+ prettier-plugin-sort-imports:+ optional: true+ prettier-plugin-svelte:+ optional: true++ resolution: {integrity: sha512-7igPTM53cGHMW8xWuVTydi2KO233VFiTNyF5hLJqpilHfmn8C8gPf+PS7dUT64YcXFbiMGZxS9pCSxL/Dxm/Jw==}+ engines: {node: '>=14'}+ hasBin: true++ resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==}++ resolution: {integrity: sha512-AAFUA5O1d83pIHEhJwWCq/RQcRukCkn/NSm2QsTEMle5f2hP0ChI2+3Xb051PZCkLryI/Ir1MVKviT2FIloaTQ==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-aWizCQiyeAenIdUbqEpXgRA1ya65P13NKn/W8rWkcN0OPkRDxdBVLWnIEDsS2RpwCK2nobI7oMUSmexzTDyAmA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ resolution: {integrity: sha512-J5bAZz+DXMMwW/wV3xzKke59Af6CHY7G4uYLN1OvBcKEsWOs4pQExj86BBKamxl/Ik5bx9whOrvBlSDfWzgSag==}+ peerDependencies:+ react: ^19.2.5++ resolution: {integrity: sha512-9r+yi9+mgU33AKcj6IbT9oRCO78WriSj6t/cF8DWBZJ9aOGPOTEDvdUDz1FwKim7QXWwmHqtdHnRJfhAxEG46Q==}+ engines: {node: '>=10'}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0+ peerDependenciesMeta:+ '@types/react':+ optional: true++ resolution: {integrity: sha512-Iqb9NjCCTt6Hf+vOdNIZGdTiH1QSqr27H/Ek9sv/a97gfueI/5h1s3yRi1nngzMUaOOToin5dI1dXKdXiF+u0Q==}+ engines: {node: '>=10'}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ resolution: {integrity: sha512-b6jSvxvVnyptAiLjbkWLE/lOnR4lfTtDAl+eUC7RZy+QQWc6wRzIV2CE6xBuMmDxc2qIihtDCZD5NPOFl7fRBQ==}+ engines: {node: '>=10'}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ resolution: {integrity: sha512-llUJLzz1zTUBrskt2pwZgLq59AemifIftw4aB7JxOqf1HY2FDaGDxgwpAPVzHU1kdWabH7FauP4i1oEeer2WCA==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==}+ engines: {node: '>=4'}++ resolution: {integrity: sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==}+ engines: {iojs: '>=1.0.0', node: '>=0.10.0'}++ resolution: {integrity: sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==}++ resolution: {integrity: sha512-dhKf903U/PQZY6boNNtAGdWbG85WAbjT/1xYoZIC7FAY0yWapOBQVsVrDl58W86//e1VpMNBtRV4MaXfdMySFA==}++ resolution: {integrity: sha512-eNv+WrVbKu1f3vbYJT/xtiF5syA5HPIMtf9IgY/nKg0sWqzAUEvqY/xm7OcZc/qafLx/iO9FgOmeSAp4v5ti/Q==}++ resolution: {integrity: sha512-KrOH82c/W+GYQ0LHqtr3caRpM3ITglq3ljGUIb8LTki7ByacJZ9z+piSGiwZDsRyhQbYBOBJgr2k6X4BZXi3Kw==}+ hasBin: true++ resolution: {integrity: sha512-xZocWwfyp4hkbN4hLWxMjmv2Q8aNa9MhmOZ7L9aCZPT+dZsgRr6wZRrSYE3HTdyk/2pZKPSgqI7ns7Een1xMSA==}++ resolution: {integrity: sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==}+ hasBin: true++ resolution: {integrity: sha512-vFKC2IEtQnVhpT78h1Yp8wzwrf8CM+MzKMHGJZfBtzhZNycRFnXsHk6E5TxIkkMsgNS7mdX3AGB7x2QM2di4lA==}+ engines: {node: '>=10'}+ hasBin: true++ resolution: {integrity: sha512-Ou9I5Ft9WNcCbXrU9cMgPBcCK8LiwLqcbywW3t4oDV37n1pzpuNLsYiAV8eODnjbtQlSDwZ2cUEeQz4E54Hltg==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}++ resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-qSVyDTeMotdvQYoHWLNGwRFJHC+i+ZvdBRYosOFgC+Wg1vx4frN2/RG/NA7SYqqvKNLf39P2LSRA2pu6n0XYZA==}+ engines: {node: '>= 12.0.0'}+ peerDependencies:+ '@babel/core': '*'+ babel-plugin-macros: '*'+ react: '>= 16.8.0 || 17.x.x || ^18.0.0-0 || ^19.0.0-0'+ peerDependenciesMeta:+ '@babel/core':+ optional: true+ babel-plugin-macros:+ optional: true++ resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-I8K9wewnVDkL1NTGoqWmVEIlUcB9gFriAEkXkfCjX5ib8ezGxtR3xD7iZIxrfArjEsH7F1CHD4RFUtxefdqV/A==}++ resolution: {integrity: sha512-HhKppgO81FQof5m6TEnuBWCZGgfRAWbaeOaGT00KOy/Pf/j6oUihdvBpA7ltCeAvZpFhW3j0PTclkxsd4IXYDA==}++ resolution: {integrity: sha512-uxc/zpqFg6x7C8vOE7lh6Lbda8eEL9zmVm/PLeTPBRhh1xCgdWaQ+J1CUieGpIfm2HdtsUpRv+HshiasBMcc6A==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-pn99VhoACYR8nFHhxqix+uvsbXineAasWm5ojXoN8xEwK5Kd3/TrhNn1wByuD52UxWRLy8pu+kRMniEi6Eq9Zg==}+ engines: {node: '>=12.0.0'}++ resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==}+ engines: {node: '>=8.0'}++ resolution: {integrity: sha512-OJ/ibxhPlqrMM0UiNHJ/0CKQkoKF243/AEmplt3qpRgkW8VG7IfOS41h7V8TjITqdByHzrjcS/2si+y4lIh8NA==}+ engines: {node: '>=18.12'}+ peerDependencies:+ typescript: '>=4.8.4'++ resolution: {integrity: sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==}++ resolution: {integrity: sha512-7bziOlRqH0hJx80h/3mbicLW7o8qLsH5+RaLR2t+OHM3D0JlWGODQKQ4cxbK7WlvmUxpcj6Kgu6EKqjrGFe3QQ==}++ resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==}+ engines: {node: '>= 0.8.0'}++ resolution: {integrity: sha512-TeTSQ6H5YHvpqVwBRcnLDCBnDOHWYu7IvGbHT6N8AOymcr9PJGjc1GTtiWZTYg0NCgYwvnYWEkVChQAr9bjfwA==}+ engines: {node: '>=16'}++ resolution: {integrity: sha512-g/KzbYKbH5C2vPkaXGu8DJlHrGKHLsM25Zg9WuC9pMGfuvT+X25tZQWo5fK1BjBm8+UrVE9LDCvaY0CQk+fXDA==}++ resolution: {integrity: sha512-xqDcFVBmlrltH64lklOVp1wYxgJr6LVdg3NamBgH2OOQDLFdTKfIZXF5PfghrnXQKXZGTQs8tr1vL7fJvq8CTQ==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ eslint: ^8.57.0 || ^9.0.0 || ^10.0.0+ typescript: '>=4.8.4 <6.1.0'++ resolution: {integrity: sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==}+ engines: {node: '>=14.17'}+ hasBin: true++ resolution: {integrity: sha512-qYVnV5OEm2AW8cJMCpdV20CDyaN3g0AjDlOGf1OW4iaDEx8MwdtChUp4zu4H0VP3nDRF/8RKWH+IPp9uW0YGZg==}++ resolution: {integrity: sha512-Js0m9cx+qOgDxo0eMiFGEueWztz+d4+M3rGlmKPT+T4IS/jP4ylw3Nwpu6cpTTP8R1MAC1kF4VbdLt3ARf209w==}+ hasBin: true+ peerDependencies:+ browserslist: '>= 4.21.0'++ resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==}++ resolution: {integrity: sha512-jQL3lRnocaFtu3V00JToYz/4QkNWswxijDaCVNZRiRTO3HQDLsdu1ZtmIUvV4yPp+rvWm5j0y0TG/S61cuijTg==}+ engines: {node: '>=10'}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ resolution: {integrity: sha512-Fedw0aZvkhynoPYlA5WXrMCAMm+nSWdZt6lzJQ7Ok8S6Q+VsHmHpRWndVRJ8Be0ZbkfPc5LRYH+5XrzXcEeLRQ==}+ engines: {node: '>=10'}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ resolution: {integrity: sha512-Pp6GSwGP/NrPIrxVFAIkOQeyw8lFenOHijQWkUTrDvrF4ALqylP2C/KCkeS9dpUM3KvYRQhna5vt7IL95+ZQ9w==}+ peerDependencies:+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0++ resolution: {integrity: sha512-U9vjByy/sK2OMXu5mmfuZFKTMIUQe34c0JXRO+oDrxJTsntdYT2iIFwYMOV7HhMTuktcZLGf2W1N/OcSf9ssWg==}+ engines: {node: '>=6.0.0', npm: '>=3.10.0'}++ resolution: {integrity: sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==}+ engines: {node: '>= 8'}+ hasBin: true++ resolution: {integrity: sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==}++ resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-Q6/nZLe6jxuU80qb/4uJ4t5v2VEZ44lzQjPDhYJNztRQ4wyWc6VF3D3Kb/fAuPetZQnhS3hnajCf9CsWesghLQ==}+ engines: {node: '>=18.0.0'}+ peerDependencies:+ zod: ^3.25.0 || ^4.0.0++ resolution: {integrity: sha512-gzUt/qt81nXsFGKIFcC3YnfEAx5NkunCfnDlvuBSSFS02bcXu4Lmea0AFIUwbLWxWPx3d9p8S5QoaujKcNQxcQ==}++snapshots:++ '@alloc/[email protected]': {}++ '@babel/[email protected]':+ dependencies:+ '@babel/helper-validator-identifier': 7.28.5+ js-tokens: 4.0.0+ picocolors: 1.1.1++ '@babel/[email protected]': {}++ '@babel/[email protected]':+ dependencies:+ '@babel/code-frame': 7.29.0+ '@babel/generator': 7.29.1+ '@babel/helper-compilation-targets': 7.28.6+ '@babel/helper-module-transforms': 7.28.6(@babel/[email protected])+ '@babel/helpers': 7.29.2+ '@babel/parser': 7.29.3+ '@babel/template': 7.28.6+ '@babel/traverse': 7.29.0+ '@babel/types': 7.29.0+ '@jridgewell/remapping': 2.3.5+ convert-source-map: 2.0.0+ debug: 4.4.3+ gensync: 1.0.0-beta.2+ json5: 2.2.3+ semver: 6.3.1+ transitivePeerDependencies:+ - supports-color++ '@babel/[email protected]':+ dependencies:+ '@babel/parser': 7.29.3+ '@babel/types': 7.29.0+ '@jridgewell/gen-mapping': 0.3.13+ '@jridgewell/trace-mapping': 0.3.31+ jsesc: 3.1.0++ '@babel/[email protected]':+ dependencies:+ '@babel/compat-data': 7.29.3+ '@babel/helper-validator-option': 7.27.1+ browserslist: 4.28.2+ lru-cache: 5.1.1+ semver: 6.3.1++ '@babel/[email protected]': {}++ '@babel/[email protected]':+ dependencies:+ '@babel/traverse': 7.29.0+ '@babel/types': 7.29.0+ transitivePeerDependencies:+ - supports-color++ '@babel/[email protected](@babel/[email protected])':+ dependencies:+ '@babel/core': 7.29.0+ '@babel/helper-module-imports': 7.28.6+ '@babel/helper-validator-identifier': 7.28.5+ '@babel/traverse': 7.29.0+ transitivePeerDependencies:+ - supports-color++ '@babel/[email protected]': {}++ '@babel/[email protected]': {}++ '@babel/[email protected]': {}++ '@babel/[email protected]':+ dependencies:+ '@babel/template': 7.28.6+ '@babel/types': 7.29.0++ '@babel/[email protected]':+ dependencies:+ '@babel/types': 7.29.0++ '@babel/[email protected]':+ dependencies:+ '@babel/code-frame': 7.29.0+ '@babel/parser': 7.29.3+ '@babel/types': 7.29.0++ '@babel/[email protected]':+ dependencies:+ '@babel/code-frame': 7.29.0+ '@babel/generator': 7.29.1+ '@babel/helper-globals': 7.28.0+ '@babel/parser': 7.29.3+ '@babel/template': 7.28.6+ '@babel/types': 7.29.0+ debug: 4.4.3+ transitivePeerDependencies:+ - supports-color++ '@babel/[email protected]':+ dependencies:+ '@babel/helper-string-parser': 7.27.1+ '@babel/helper-validator-identifier': 7.28.5++ '@bufbuild/[email protected]': {}++ '@emnapi/[email protected]':+ dependencies:+ tslib: 2.8.1+ optional: true++ dependencies:+ eslint: 9.39.4([email protected])+ eslint-visitor-keys: 3.4.3++ '@eslint-community/[email protected]': {}++ '@eslint/[email protected]':+ dependencies:+ '@eslint/object-schema': 2.1.7+ debug: 4.4.3+ minimatch: 3.1.5+ transitivePeerDependencies:+ - supports-color++ '@eslint/[email protected]':+ dependencies:+ '@eslint/core': 0.17.0++ '@eslint/[email protected]':+ dependencies:+ '@types/json-schema': 7.0.15++ '@eslint/[email protected]':+ dependencies:+ ajv: 6.15.0+ debug: 4.4.3+ espree: 10.4.0+ globals: 14.0.0+ ignore: 5.3.2+ import-fresh: 3.3.1+ js-yaml: 4.1.1+ minimatch: 3.1.5+ strip-json-comments: 3.1.1+ transitivePeerDependencies:+ - supports-color++ '@eslint/[email protected]': {}++ '@eslint/[email protected]': {}++ '@eslint/[email protected]':+ dependencies:+ '@eslint/core': 0.17.0+ levn: 0.4.1++ '@floating-ui/[email protected]':+ dependencies:+ '@floating-ui/utils': 0.2.11++ '@floating-ui/[email protected]':+ dependencies:+ '@floating-ui/core': 1.7.5+ '@floating-ui/utils': 0.2.11++ dependencies:+ '@floating-ui/dom': 1.7.6+ react: 19.2.5+ react-dom: 19.2.5([email protected])++ '@floating-ui/[email protected]': {}++ '@humanfs/[email protected]':+ dependencies:+ '@humanfs/types': 0.15.0++ '@humanfs/[email protected]':+ dependencies:+ '@humanfs/core': 0.19.2+ '@humanfs/types': 0.15.0+ '@humanwhocodes/retry': 0.4.3++ '@humanfs/[email protected]': {}++ '@humanwhocodes/[email protected]': {}++ '@humanwhocodes/[email protected]': {}++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-darwin-arm64': 1.2.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-darwin-x64': 1.2.4+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linux-arm64': 1.2.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linux-arm': 1.2.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linux-ppc64': 1.2.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linux-riscv64': 1.2.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linux-s390x': 1.2.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linux-x64': 1.2.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linuxmusl-arm64': 1.2.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linuxmusl-x64': 1.2.4+ optional: true++ '@img/[email protected]':+ dependencies:+ '@emnapi/runtime': 1.10.0+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@jridgewell/[email protected]':+ dependencies:+ '@jridgewell/sourcemap-codec': 1.5.5+ '@jridgewell/trace-mapping': 0.3.31++ '@jridgewell/[email protected]':+ dependencies:+ '@jridgewell/gen-mapping': 0.3.13+ '@jridgewell/trace-mapping': 0.3.31++ '@jridgewell/[email protected]': {}++ '@jridgewell/[email protected]': {}++ '@jridgewell/[email protected]':+ dependencies:+ '@jridgewell/resolve-uri': 3.1.2+ '@jridgewell/sourcemap-codec': 1.5.5++ '@livekit/[email protected]': {}++ '@livekit/[email protected]':+ dependencies:+ '@bufbuild/protobuf': 1.10.1++ '@livekit/[email protected]':+ dependencies:+ '@bufbuild/protobuf': 1.10.1++ '@next/[email protected]': {}++ '@next/[email protected]':+ dependencies:+ fast-glob: 3.3.1++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@nodelib/[email protected]':+ dependencies:+ '@nodelib/fs.stat': 2.0.5+ run-parallel: 1.2.0++ '@nodelib/[email protected]': {}++ '@nodelib/[email protected]':+ dependencies:+ '@nodelib/fs.scandir': 2.1.5+ fastq: 1.20.1++ '@radix-ui/[email protected]': {}++ '@radix-ui/[email protected]': {}++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-visually-hidden': 1.2.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collapsible': 1.1.12(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-dialog': 1.1.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-is-hydrated': 0.1.0(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-previous': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-size': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-menu': 2.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-focus-guards': 1.1.3(@types/[email protected])([email protected])+ '@radix-ui/react-focus-scope': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ aria-hidden: 1.2.6+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ react-remove-scroll: 2.7.2(@types/[email protected])([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-escape-keydown': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-menu': 2.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-label': 2.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-popper': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-focus-guards': 1.1.3(@types/[email protected])([email protected])+ '@radix-ui/react-focus-scope': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-popper': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ aria-hidden: 1.2.6+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ react-remove-scroll: 2.7.2(@types/[email protected])([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-menu': 2.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-previous': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-visually-hidden': 1.2.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/number': 1.1.1+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-effect-event': 0.0.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-is-hydrated': 0.1.0(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-effect-event': 0.0.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-is-hydrated': 0.1.0(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-focus-guards': 1.1.3(@types/[email protected])([email protected])+ '@radix-ui/react-focus-scope': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-popper': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ aria-hidden: 1.2.6+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ react-remove-scroll: 2.7.2(@types/[email protected])([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-arrow': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-rect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-size': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/rect': 1.1.1+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-previous': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-size': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/number': 1.1.1+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/number': 1.1.1+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-focus-guards': 1.1.3(@types/[email protected])([email protected])+ '@radix-ui/react-focus-scope': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-popper': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-previous': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-visually-hidden': 1.2.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ aria-hidden: 1.2.6+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ react-remove-scroll: 2.7.2(@types/[email protected])([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/number': 1.1.1+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-previous': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-size': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-previous': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-size': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-visually-hidden': 1.2.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-toggle': 1.1.10(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-separator': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-toggle-group': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-popper': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-visually-hidden': 1.2.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ dependencies:+ '@radix-ui/react-use-effect-event': 0.0.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ dependencies:+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ dependencies:+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ dependencies:+ react: 19.2.5+ use-sync-external-store: 1.6.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.14++ dependencies:+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ dependencies:+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ dependencies:+ '@radix-ui/rect': 1.1.1+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ dependencies:+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.2.5+ optionalDependencies:+ '@types/react': 19.2.14++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected]': {}++ '@swc/[email protected]':+ dependencies:+ tslib: 2.8.1++ '@tailwindcss/[email protected]':+ dependencies:+ '@jridgewell/remapping': 2.3.5+ enhanced-resolve: 5.21.0+ jiti: 2.6.1+ lightningcss: 1.32.0+ magic-string: 0.30.21+ source-map-js: 1.2.1+ tailwindcss: 4.2.4++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optionalDependencies:+ '@tailwindcss/oxide-android-arm64': 4.2.4+ '@tailwindcss/oxide-darwin-arm64': 4.2.4+ '@tailwindcss/oxide-darwin-x64': 4.2.4+ '@tailwindcss/oxide-freebsd-x64': 4.2.4+ '@tailwindcss/oxide-linux-arm-gnueabihf': 4.2.4+ '@tailwindcss/oxide-linux-arm64-gnu': 4.2.4+ '@tailwindcss/oxide-linux-arm64-musl': 4.2.4+ '@tailwindcss/oxide-linux-x64-gnu': 4.2.4+ '@tailwindcss/oxide-linux-x64-musl': 4.2.4+ '@tailwindcss/oxide-wasm32-wasi': 4.2.4+ '@tailwindcss/oxide-win32-arm64-msvc': 4.2.4+ '@tailwindcss/oxide-win32-x64-msvc': 4.2.4++ '@tailwindcss/[email protected]':+ dependencies:+ '@alloc/quick-lru': 5.2.0+ '@tailwindcss/node': 4.2.4+ '@tailwindcss/oxide': 4.2.4+ postcss: 8.5.13+ tailwindcss: 4.2.4++ '@types/[email protected]': {}++ '@types/[email protected]': {}++ '@types/[email protected]': {}++ '@types/[email protected]':+ dependencies:+ undici-types: 7.19.2++ '@types/[email protected](@types/[email protected])':+ dependencies:+ '@types/react': 19.2.14++ '@types/[email protected]':+ dependencies:+ csstype: 3.2.3++ '@typescript-eslint/[email protected](@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected]([email protected]))([email protected])':+ dependencies:+ '@eslint-community/regexpp': 4.12.2+ '@typescript-eslint/scope-manager': 8.59.1+ '@typescript-eslint/visitor-keys': 8.59.1+ eslint: 9.39.4([email protected])+ ignore: 7.0.5+ natural-compare: 1.4.0+ ts-api-utils: 2.5.0([email protected])+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ dependencies:+ '@typescript-eslint/scope-manager': 8.59.1+ '@typescript-eslint/types': 8.59.1+ '@typescript-eslint/typescript-estree': 8.59.1([email protected])+ '@typescript-eslint/visitor-keys': 8.59.1+ debug: 4.4.3+ eslint: 9.39.4([email protected])+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ '@typescript-eslint/[email protected]([email protected])':+ dependencies:+ '@typescript-eslint/tsconfig-utils': 8.59.1([email protected])+ '@typescript-eslint/types': 8.59.1+ debug: 4.4.3+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ '@typescript-eslint/[email protected]':+ dependencies:+ '@typescript-eslint/types': 8.59.1+ '@typescript-eslint/visitor-keys': 8.59.1++ '@typescript-eslint/[email protected]([email protected])':+ dependencies:+ typescript: 5.9.3++ dependencies:+ '@typescript-eslint/types': 8.59.1+ '@typescript-eslint/typescript-estree': 8.59.1([email protected])+ debug: 4.4.3+ eslint: 9.39.4([email protected])+ ts-api-utils: 2.5.0([email protected])+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ '@typescript-eslint/[email protected]': {}++ '@typescript-eslint/[email protected]([email protected])':+ dependencies:+ '@typescript-eslint/project-service': 8.59.1([email protected])+ '@typescript-eslint/tsconfig-utils': 8.59.1([email protected])+ '@typescript-eslint/types': 8.59.1+ '@typescript-eslint/visitor-keys': 8.59.1+ debug: 4.4.3+ minimatch: 10.2.5+ semver: 7.7.4+ tinyglobby: 0.2.16+ ts-api-utils: 2.5.0([email protected])+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ dependencies:+ '@eslint-community/eslint-utils': 4.9.1([email protected]([email protected]))+ '@typescript-eslint/scope-manager': 8.59.1+ '@typescript-eslint/types': 8.59.1+ '@typescript-eslint/typescript-estree': 8.59.1([email protected])+ eslint: 9.39.4([email protected])+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ '@typescript-eslint/[email protected]':+ dependencies:+ '@typescript-eslint/types': 8.59.1+ eslint-visitor-keys: 5.0.1++ dependencies:+ acorn: 8.16.0++ [email protected]: {}++ dependencies:+ fast-deep-equal: 3.1.3+ fast-json-stable-stringify: 2.1.0+ json-schema-traverse: 0.4.1+ uri-js: 4.4.1++ dependencies:+ color-convert: 2.0.1++ [email protected]: {}++ dependencies:+ tslib: 2.8.1++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ balanced-match: 1.0.2+ concat-map: 0.0.1++ dependencies:+ balanced-match: 4.0.4++ dependencies:+ fill-range: 7.1.1++ dependencies:+ baseline-browser-mapping: 2.10.27+ caniuse-lite: 1.0.30001791+ electron-to-chromium: 1.5.349+ node-releases: 2.0.38+ update-browserslist-db: 1.2.3([email protected])++ [email protected]: {}++ dependencies:+ camelcase: 8.0.0+ map-obj: 5.0.0+ quick-lru: 6.1.2+ type-fest: 4.41.0++ [email protected]: {}++ [email protected]: {}++ dependencies:+ ansi-styles: 4.3.0+ supports-color: 7.2.0++ dependencies:+ clsx: 2.1.1++ [email protected]: {}++ [email protected]: {}++ dependencies:+ color-name: 1.1.4++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ path-key: 3.1.1+ shebang-command: 2.0.0+ which: 2.0.2++ [email protected]: {}++ dependencies:+ ms: 2.1.3++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ graceful-fs: 4.2.11+ tapable: 2.3.3++ [email protected]: {}++ [email protected]: {}++ dependencies:+ eslint: 9.39.4([email protected])++ dependencies:+ '@babel/core': 7.29.0+ '@babel/parser': 7.29.3+ eslint: 9.39.4([email protected])+ hermes-parser: 0.25.1+ zod: 3.25.76+ zod-validation-error: 4.0.2([email protected])+ transitivePeerDependencies:+ - supports-color++ dependencies:+ esrecurse: 4.3.0+ estraverse: 5.3.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ '@eslint-community/eslint-utils': 4.9.1([email protected]([email protected]))+ '@eslint-community/regexpp': 4.12.2+ '@eslint/config-array': 0.21.2+ '@eslint/config-helpers': 0.4.2+ '@eslint/core': 0.17.0+ '@eslint/eslintrc': 3.3.5+ '@eslint/js': 9.39.4+ '@eslint/plugin-kit': 0.4.1+ '@humanfs/node': 0.16.8+ '@humanwhocodes/module-importer': 1.0.1+ '@humanwhocodes/retry': 0.4.3+ '@types/estree': 1.0.8+ ajv: 6.15.0+ chalk: 4.1.2+ cross-spawn: 7.0.6+ debug: 4.4.3+ escape-string-regexp: 4.0.0+ eslint-scope: 8.4.0+ eslint-visitor-keys: 4.2.1+ espree: 10.4.0+ esquery: 1.7.0+ esutils: 2.0.3+ fast-deep-equal: 3.1.3+ file-entry-cache: 8.0.0+ find-up: 5.0.0+ glob-parent: 6.0.2+ ignore: 5.3.2+ imurmurhash: 0.1.4+ is-glob: 4.0.3+ json-stable-stringify-without-jsonify: 1.0.1+ lodash.merge: 4.6.2+ minimatch: 3.1.5+ natural-compare: 1.4.0+ optionator: 0.9.4+ optionalDependencies:+ jiti: 2.6.1+ transitivePeerDependencies:+ - supports-color++ dependencies:+ acorn: 8.16.0+ acorn-jsx: 5.3.2([email protected])+ eslint-visitor-keys: 4.2.1++ dependencies:+ estraverse: 5.3.0++ dependencies:+ estraverse: 5.3.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ '@nodelib/fs.stat': 2.0.5+ '@nodelib/fs.walk': 1.2.8+ glob-parent: 5.1.2+ merge2: 1.4.1+ micromatch: 4.0.8++ [email protected]: {}++ [email protected]: {}++ dependencies:+ reusify: 1.1.0++ optionalDependencies:+ picomatch: 4.0.4++ dependencies:+ flat-cache: 4.0.1++ dependencies:+ to-regex-range: 5.0.1++ dependencies:+ locate-path: 6.0.0+ path-exists: 4.0.0++ dependencies:+ flatted: 3.4.2+ keyv: 4.5.4++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ is-glob: 4.0.3++ dependencies:+ is-glob: 4.0.3++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ hermes-estree: 0.25.1++ [email protected]: {}++ [email protected]: {}++ dependencies:+ parent-module: 1.0.1+ resolve-from: 4.0.0++ [email protected]: {}++ [email protected]: {}++ dependencies:+ is-extglob: 2.1.1++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ argparse: 2.0.1++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ json-buffer: 3.0.1++ dependencies:+ prelude-ls: 1.2.1+ type-check: 0.4.0++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ dependencies:+ detect-libc: 2.1.2+ optionalDependencies:+ lightningcss-android-arm64: 1.32.0+ lightningcss-darwin-arm64: 1.32.0+ lightningcss-darwin-x64: 1.32.0+ lightningcss-freebsd-x64: 1.32.0+ lightningcss-linux-arm-gnueabihf: 1.32.0+ lightningcss-linux-arm64-gnu: 1.32.0+ lightningcss-linux-arm64-musl: 1.32.0+ lightningcss-linux-x64-gnu: 1.32.0+ lightningcss-linux-x64-musl: 1.32.0+ lightningcss-win32-arm64-msvc: 1.32.0+ lightningcss-win32-x64-msvc: 1.32.0++ [email protected](@types/[email protected]):+ dependencies:+ '@livekit/mutex': 1.1.1+ '@livekit/protocol': 1.44.0+ '@types/dom-mediacapture-record': 1.0.22+ events: 3.3.0+ jose: 6.2.3+ loglevel: 1.9.2+ sdp-transform: 2.15.0+ tslib: 2.8.1+ typed-emitter: 2.1.0+ webrtc-adapter: 9.0.5++ dependencies:+ '@bufbuild/protobuf': 1.10.1+ '@livekit/protocol': 1.45.6+ camelcase-keys: 9.1.3+ jose: 5.10.0++ dependencies:+ p-locate: 5.0.0++ [email protected]: {}++ [email protected]: {}++ dependencies:+ yallist: 3.1.1++ dependencies:+ react: 19.2.5++ dependencies:+ '@jridgewell/sourcemap-codec': 1.5.5++ [email protected]: {}++ [email protected]: {}++ dependencies:+ braces: 3.0.3+ picomatch: 2.3.2++ dependencies:+ brace-expansion: 5.0.5++ dependencies:+ brace-expansion: 1.1.14++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ react: 19.2.5+ react-dom: 19.2.5([email protected])++ [email protected](@babel/[email protected])([email protected]([email protected]))([email protected]):+ dependencies:+ '@next/env': 16.1.6+ '@swc/helpers': 0.5.15+ baseline-browser-mapping: 2.10.27+ caniuse-lite: 1.0.30001791+ postcss: 8.4.31+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ styled-jsx: 5.1.6(@babel/[email protected])([email protected])+ optionalDependencies:+ '@next/swc-darwin-arm64': 16.1.6+ '@next/swc-darwin-x64': 16.1.6+ '@next/swc-linux-arm64-gnu': 16.1.6+ '@next/swc-linux-arm64-musl': 16.1.6+ '@next/swc-linux-x64-gnu': 16.1.6+ '@next/swc-linux-x64-musl': 16.1.6+ '@next/swc-win32-arm64-msvc': 16.1.6+ '@next/swc-win32-x64-msvc': 16.1.6+ sharp: 0.34.5+ transitivePeerDependencies:+ - '@babel/core'+ - babel-plugin-macros++ [email protected]: {}++ dependencies:+ deep-is: 0.1.4+ fast-levenshtein: 2.0.6+ levn: 0.4.1+ prelude-ls: 1.2.1+ type-check: 0.4.0+ word-wrap: 1.2.5++ dependencies:+ yocto-queue: 0.1.0++ dependencies:+ p-limit: 3.1.0++ dependencies:+ callsites: 3.1.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ nanoid: 3.3.12+ picocolors: 1.1.1+ source-map-js: 1.2.1++ dependencies:+ nanoid: 3.3.12+ picocolors: 1.1.1+ source-map-js: 1.2.1++ [email protected]: {}++ dependencies:+ prettier: 3.8.3++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected]):+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-accessible-icon': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-accordion': 1.2.12(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-alert-dialog': 1.1.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-arrow': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-aspect-ratio': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-avatar': 1.1.10(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-checkbox': 1.3.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-collapsible': 1.1.12(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context-menu': 2.2.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-dialog': 1.1.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-dropdown-menu': 2.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-focus-guards': 1.1.3(@types/[email protected])([email protected])+ '@radix-ui/react-focus-scope': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-form': 0.1.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-hover-card': 1.1.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-label': 2.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-menu': 2.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-menubar': 1.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-navigation-menu': 1.2.14(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-one-time-password-field': 0.1.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-password-toggle-field': 0.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-popover': 1.1.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-popper': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-progress': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-radio-group': 1.3.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-scroll-area': 1.2.10(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-select': 2.2.6(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-separator': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slider': 1.3.6(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ '@radix-ui/react-switch': 1.2.6(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-tabs': 1.1.13(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-toast': 1.2.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-toggle': 1.1.10(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-toggle-group': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-toolbar': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-tooltip': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-effect-event': 0.0.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-escape-keydown': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-is-hydrated': 0.1.0(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-size': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-visually-hidden': 1.2.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.2.5+ react-dom: 19.2.5([email protected])+ optionalDependencies:+ '@types/react': 19.2.14+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ react: 19.2.5+ scheduler: 0.27.0++ dependencies:+ react: 19.2.5+ react-style-singleton: 2.2.3(@types/[email protected])([email protected])+ tslib: 2.8.1+ optionalDependencies:+ '@types/react': 19.2.14++ dependencies:+ react: 19.2.5+ react-remove-scroll-bar: 2.3.8(@types/[email protected])([email protected])+ react-style-singleton: 2.2.3(@types/[email protected])([email protected])+ tslib: 2.8.1+ use-callback-ref: 1.3.3(@types/[email protected])([email protected])+ use-sidecar: 1.1.3(@types/[email protected])([email protected])+ optionalDependencies:+ '@types/react': 19.2.14++ dependencies:+ get-nonce: 1.0.1+ react: 19.2.5+ tslib: 2.8.1+ optionalDependencies:+ '@types/react': 19.2.14++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ queue-microtask: 1.2.3++ dependencies:+ tslib: 2.8.1+ optional: true++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ '@img/colour': 1.1.0+ detect-libc: 2.1.2+ semver: 7.7.4+ optionalDependencies:+ '@img/sharp-darwin-arm64': 0.34.5+ '@img/sharp-darwin-x64': 0.34.5+ '@img/sharp-libvips-darwin-arm64': 1.2.4+ '@img/sharp-libvips-darwin-x64': 1.2.4+ '@img/sharp-libvips-linux-arm': 1.2.4+ '@img/sharp-libvips-linux-arm64': 1.2.4+ '@img/sharp-libvips-linux-ppc64': 1.2.4+ '@img/sharp-libvips-linux-riscv64': 1.2.4+ '@img/sharp-libvips-linux-s390x': 1.2.4+ '@img/sharp-libvips-linux-x64': 1.2.4+ '@img/sharp-libvips-linuxmusl-arm64': 1.2.4+ '@img/sharp-libvips-linuxmusl-x64': 1.2.4+ '@img/sharp-linux-arm': 0.34.5+ '@img/sharp-linux-arm64': 0.34.5+ '@img/sharp-linux-ppc64': 0.34.5+ '@img/sharp-linux-riscv64': 0.34.5+ '@img/sharp-linux-s390x': 0.34.5+ '@img/sharp-linux-x64': 0.34.5+ '@img/sharp-linuxmusl-arm64': 0.34.5+ '@img/sharp-linuxmusl-x64': 0.34.5+ '@img/sharp-wasm32': 0.34.5+ '@img/sharp-win32-arm64': 0.34.5+ '@img/sharp-win32-ia32': 0.34.5+ '@img/sharp-win32-x64': 0.34.5+ optional: true++ dependencies:+ shebang-regex: 3.0.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ client-only: 0.0.1+ react: 19.2.5+ optionalDependencies:+ '@babel/core': 7.29.0++ dependencies:+ has-flag: 4.0.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ fdir: 6.5.0([email protected])+ picomatch: 4.0.4++ dependencies:+ is-number: 7.0.0++ dependencies:+ typescript: 5.9.3++ [email protected]: {}++ [email protected]: {}++ dependencies:+ prelude-ls: 1.2.1++ [email protected]: {}++ optionalDependencies:+ rxjs: 7.8.2++ dependencies:+ '@typescript-eslint/eslint-plugin': 8.59.1(@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected]([email protected]))([email protected])+ '@typescript-eslint/typescript-estree': 8.59.1([email protected])+ eslint: 9.39.4([email protected])+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ [email protected]: {}++ [email protected]: {}++ dependencies:+ browserslist: 4.28.2+ escalade: 3.2.0+ picocolors: 1.1.1++ dependencies:+ punycode: 2.3.1++ dependencies:+ react: 19.2.5+ tslib: 2.8.1+ optionalDependencies:+ '@types/react': 19.2.14++ dependencies:+ detect-node-es: 1.1.0+ react: 19.2.5+ tslib: 2.8.1+ optionalDependencies:+ '@types/react': 19.2.14++ dependencies:+ react: 19.2.5++ dependencies:+ sdp: 3.2.2++ dependencies:+ isexe: 2.0.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ zod: 3.25.76++ [email protected]: {}diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/postcss.config.mjs b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/postcss.config.mjsnew file mode 100644index 00000000..2f8795a9--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/postcss.config.mjs@@ -0,0 +1,7 @@+const config = {+ plugins: {+ "@tailwindcss/postcss": {},+ },+}++export default configdiff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/brand/chatgpt-blossom-black.svg b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/brand/chatgpt-blossom-black.svgnew file mode 100644index 00000000..7c119340--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/brand/chatgpt-blossom-black.svg@@ -0,0 +1,3 @@+<svg width="716" height="716" viewBox="0 0 716 716" fill="none" xmlns="http://www.w3.org/2000/svg">+<path d="M508.749 317.399C516.777 287.314 508.991 253.884 485.389 230.282C461.788 206.681 428.36 198.895 398.273 206.923C376.231 184.928 343.39 174.956 311.148 183.596C278.906 192.234 255.45 217.292 247.36 247.361C217.291 255.451 192.233 278.91 183.595 311.149C174.957 343.391 184.927 376.232 206.924 398.274C198.896 428.359 206.683 461.789 230.284 485.391C253.885 508.992 287.313 516.779 317.401 508.75C339.442 530.745 372.286 540.717 404.525 532.079C436.767 523.441 460.223 498.384 468.313 468.315C498.383 460.224 523.44 436.766 532.078 404.526C540.716 372.285 530.747 339.443 508.749 317.402V317.399ZM470.899 244.776C486.892 260.77 493.488 282.601 490.687 303.412L415.577 260.046C412.411 258.218 408.509 258.218 405.345 260.046L317.401 310.82V277.526C317.401 275.191 318.652 273.005 320.676 271.837L387.644 233.174C414.178 218.353 448.346 222.223 470.901 244.776H470.899ZM357.837 311.144L398.275 334.491V381.185L357.837 404.532L317.398 381.185V334.491L357.837 311.144ZM264.776 269.693C265.207 239.305 285.644 211.649 316.453 203.393C338.3 197.54 360.505 202.744 377.127 215.573L302.014 258.937C298.848 260.764 296.898 264.144 296.898 267.798V369.346L268.065 352.699C266.043 351.531 264.776 349.353 264.776 347.017V269.691V269.693ZM203.391 316.454C209.244 294.608 224.854 277.978 244.276 269.999V356.73C244.276 360.384 246.226 363.763 249.392 365.591L337.337 416.365L308.503 433.013C306.481 434.181 303.961 434.188 301.939 433.02L234.971 394.357C208.868 378.789 195.138 347.261 203.391 316.454ZM244.775 470.9C228.781 454.906 222.186 433.075 224.986 412.264L300.096 455.63C303.263 457.457 307.164 457.457 310.328 455.63L398.273 404.856V438.149C398.273 440.485 397.022 442.671 394.997 443.839L328.029 482.502C301.495 497.322 267.327 493.452 244.772 470.9H244.775ZM450.897 445.982C450.466 476.371 430.029 504.027 399.22 512.283C377.373 518.136 355.168 512.932 338.547 500.102L413.659 456.738C416.826 454.911 418.775 451.532 418.775 447.877V346.329L447.609 362.977C449.631 364.145 450.897 366.323 450.897 368.659V445.985V445.982ZM512.282 399.221C506.429 421.068 490.819 437.697 471.397 445.676V358.946C471.397 355.292 469.448 351.912 466.281 350.085L378.336 299.311L407.17 282.663C409.192 281.495 411.712 281.487 413.734 282.655L480.702 321.318C506.805 336.887 520.536 368.415 512.282 399.221Z" fill="black"/>+</svg>diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/brand/chatgpt-blossom-white.svg b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/brand/chatgpt-blossom-white.svgnew file mode 100644index 00000000..6341b6fa--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/brand/chatgpt-blossom-white.svg@@ -0,0 +1,3 @@+<svg width="716" height="716" viewBox="0 0 716 716" fill="none" xmlns="http://www.w3.org/2000/svg">+<path d="M508.749 317.399C516.777 287.314 508.991 253.884 485.389 230.282C461.788 206.681 428.36 198.895 398.273 206.923C376.231 184.928 343.39 174.956 311.148 183.596C278.906 192.234 255.45 217.292 247.36 247.361C217.291 255.451 192.233 278.91 183.595 311.149C174.957 343.391 184.927 376.232 206.924 398.274C198.896 428.359 206.683 461.789 230.284 485.391C253.885 508.992 287.313 516.779 317.401 508.75C339.442 530.745 372.286 540.717 404.525 532.079C436.767 523.441 460.223 498.384 468.313 468.315C498.383 460.224 523.44 436.766 532.078 404.526C540.716 372.285 530.747 339.443 508.749 317.402V317.399ZM470.899 244.776C486.892 260.77 493.488 282.601 490.687 303.412L415.577 260.046C412.411 258.218 408.509 258.218 405.345 260.046L317.401 310.82V277.526C317.401 275.191 318.652 273.005 320.676 271.837L387.644 233.174C414.178 218.353 448.346 222.223 470.901 244.776H470.899ZM357.837 311.144L398.275 334.491V381.185L357.837 404.532L317.398 381.185V334.491L357.837 311.144ZM264.776 269.693C265.207 239.305 285.644 211.649 316.453 203.393C338.3 197.54 360.505 202.744 377.127 215.573L302.014 258.937C298.848 260.764 296.898 264.144 296.898 267.798V369.346L268.065 352.699C266.043 351.531 264.776 349.353 264.776 347.017V269.691V269.693ZM203.391 316.454C209.244 294.608 224.854 277.978 244.276 269.999V356.73C244.276 360.384 246.226 363.763 249.392 365.591L337.337 416.365L308.503 433.013C306.481 434.181 303.961 434.188 301.939 433.02L234.971 394.357C208.868 378.789 195.138 347.261 203.391 316.454ZM244.775 470.9C228.781 454.906 222.186 433.075 224.986 412.264L300.096 455.63C303.263 457.457 307.164 457.457 310.328 455.63L398.273 404.856V438.149C398.273 440.485 397.022 442.671 394.997 443.839L328.029 482.502C301.495 497.322 267.327 493.452 244.772 470.9H244.775ZM450.897 445.982C450.466 476.371 430.029 504.027 399.22 512.283C377.373 518.136 355.168 512.932 338.547 500.102L413.659 456.738C416.826 454.911 418.775 451.532 418.775 447.877V346.329L447.609 362.977C449.631 364.145 450.897 366.323 450.897 368.659V445.985V445.982ZM512.282 399.221C506.429 421.068 490.819 437.697 471.397 445.676V358.946C471.397 355.292 469.448 351.912 466.281 350.085L378.336 299.311L407.17 282.663C409.192 281.495 411.712 281.487 413.734 282.655L480.702 321.318C506.805 336.887 520.536 368.415 512.282 399.221Z" fill="white"/>+</svg>diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/fonts/OpenAISansVariable.woff2 b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/fonts/OpenAISansVariable.woff2new file mode 100644index 00000000..630a3b54Binary files /dev/null and b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/fonts/OpenAISansVariable.woff2 differdiff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/camera.svg b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/camera.svgnew file mode 100644index 00000000..05e67ee8--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/camera.svg@@ -0,0 +1 @@+<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 25"><path fill="#000" d="M12 3c1.71 0 3.116.857 3.972 2H18a4 4 0 0 1 4 4v9a4 4 0 0 1-4 4H6a4 4 0 0 1-4-4V9a4 4 0 0 1 4-4h2.027C8.911 3.823 10.305 3 12 3m0 2c-1.098 0-1.989.571-2.521 1.413A1.26 1.26 0 0 1 8.415 7H6a2 2 0 0 0-2 2v9a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-2.418a1.26 1.26 0 0 1-1.067-.596A2.96 2.96 0 0 0 12 5m0 4a4.25 4.25 0 1 1 0 8.5A4.25 4.25 0 0 1 12 9m0 2a2.25 2.25 0 1 0 0 4.5 2.25 2.25 0 0 0 0-4.5"/></svg>\ No newline at end of filediff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/ellipsis.svg b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/ellipsis.svgnew file mode 100644index 00000000..906a5048--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/ellipsis.svg@@ -0,0 +1 @@+<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"><path fill="#000" d="M5 10a2 2 0 1 1 0 4 2 2 0 0 1 0-4m7 0a2 2 0 1 1 0 4 2 2 0 0 1 0-4m7 0a2 2 0 1 1 0 4 2 2 0 0 1 0-4"/></svg>\ No newline at end of filediff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/microphone-slash.svg b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/microphone-slash.svgnew file mode 100644index 00000000..bbd87aea--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/microphone-slash.svg@@ -0,0 +1 @@+<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 23 25"><path stroke="#000" stroke-linecap="round" stroke-width="2" d="M8.5 22h6"/><path stroke="#000" stroke-width="2" d="M11.5 19v3"/><path stroke="#000" stroke-linecap="round" stroke-width="2" d="M4 12.5C4 16 7.5 19 11.5 19a8.1 8.1 0 0 0 4.84-1.608M8.694 4.15A4 4 0 0 1 15.5 7v4m3.218 3.21A5.4 5.4 0 0 0 19 12.5M3 4l17 17"/></svg>\ No newline at end of filediff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/microphone.svg b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/microphone.svgnew file mode 100644index 00000000..46fedf28--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/microphone.svg@@ -0,0 +1 @@+<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 25 25"><path stroke="#000" stroke-linecap="round" stroke-width="2" d="M9.5 22h6"/><path stroke="#000" stroke-width="2" d="M12.5 19v3"/><path stroke="#000" stroke-linecap="round" stroke-width="2" d="M5 12.5C5 16 8.5 19 12.5 19s7.5-3 7.5-6.5"/><path stroke="#000" stroke-width="2" d="M12.5 3a4 4 0 0 1 4 4v4a4 4 0 0 1-8 0V7a4 4 0 0 1 4-4Z"/></svg>\ No newline at end of filediff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/settings.svg b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/settings.svgnew file mode 100644index 00000000..0166c60c--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/settings.svg@@ -0,0 +1 @@+<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 25"><path fill="#000" fill-rule="evenodd" d="M12.533 2.052c.917 0 1.764.49 2.222 1.284l1.169 2.028 2.343.001c.916 0 1.763.49 2.22 1.282l.728 1.26c.458.792.458 1.77 0 2.563l-1.172 2.028 1.174 2.029c.46.793.46 1.773.002 2.567l-.727 1.259a2.57 2.57 0 0 1-2.22 1.282h-2.343l-1.17 2.029a2.57 2.57 0 0 1-2.222 1.285l-1.455-.001c-.914 0-1.76-.487-2.218-1.278l-1.18-2.035H5.342a2.57 2.57 0 0 1-2.22-1.282l-.726-1.26a2.56 2.56 0 0 1 0-2.564l1.174-2.03L2.4 10.47a2.57 2.57 0 0 1 0-2.564l.727-1.26a2.57 2.57 0 0 1 2.22-1.282l2.34-.002L8.86 3.333a2.57 2.57 0 0 1 2.22-1.282zm-1.453 2.05a.51.51 0 0 0-.444.257l-1.32 2.285a1.54 1.54 0 0 1-1.332.77l-2.638.002a.51.51 0 0 0-.444.256l-.728 1.26a.51.51 0 0 0 .001.513l1.32 2.285a1.54 1.54 0 0 1-.002 1.54L4.17 15.555a.51.51 0 0 0 .001.513l.726 1.259a.51.51 0 0 0 .444.256h2.64a1.54 1.54 0 0 1 1.331.768l1.327 2.29a.52.52 0 0 0 .444.257l1.454-.001a.52.52 0 0 0 .446-.257l1.316-2.286c.275-.477.783-.77 1.333-.77h2.64a.51.51 0 0 0 .443-.257l.727-1.259a.51.51 0 0 0 0-.513l-1.322-2.284a1.54 1.54 0 0 1-.092-1.357l.091-.184 1.32-2.285a.51.51 0 0 0 0-.513l-.728-1.259a.51.51 0 0 0-.444-.256l-2.639-.001-.204-.012a1.54 1.54 0 0 1-1.016-.588l-.113-.17-1.318-2.286a.51.51 0 0 0-.444-.258zm.725 4.81a3.59 3.59 0 1 1 0 7.18 3.59 3.59 0 0 1 0-7.18m0 2.052a1.539 1.539 0 1 0 0 3.077 1.539 1.539 0 0 0 0-3.077" clip-rule="evenodd"/></svg>\ No newline at end of filediff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/video-slash.svg b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/video-slash.svgnew file mode 100644index 00000000..44c6ec3e--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/public/icons/video-slash.svg@@ -0,0 +1 @@+<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 23"><path stroke="#000" stroke-width="2" d="M15.697 16.823c-1.35.961-1.735.961-3.01.961H6.22a3.016 3.016 0 0 1-3.016-3.016v-6.45c0-1.146.075-1.747.898-2.966"/><path stroke="#000" stroke-linecap="round" stroke-width="2" d="M8.64 4.713h4.62a3.016 3.016 0 0 1 3.016 3.017v4.481m.037-2.471 4.213-3.085a.804.804 0 0 1 1.28.65v7.77a.804.804 0 0 1-1.316.62l-4.177-3.44M2.01 3.016l16.968 16.968"/></svg>\ No newline at end of filediff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/test/realtime-translation-config.test.mjs b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/test/realtime-translation-config.test.mjsnew file mode 100644index 00000000..b8371ba0--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/test/realtime-translation-config.test.mjs@@ -0,0 +1,110 @@+import assert from "node:assert/strict"+import { describe, it } from "node:test"++import {+ DEFAULT_INPUT_TRANSCRIPTION_MODEL,+ DEFAULT_TRANSLATION_MODEL,+ REALTIME_TRANSLATION_CLIENT_SECRET_URL,+ REALTIME_TRANSLATION_CALL_URL,+ buildSessionUpdate,+ buildTranslationClientSecretRequest,+ normalizeTranslationLanguage,+} from "../lib/realtime-translation-config.js"++describe("Realtime Translation config", () => {+ it("builds the client secret request shape", () => {+ const request = buildTranslationClientSecretRequest({+ apiKey: "sk-test",+ language: " ES ",+ inputTranscriptionEnabled: true,+ noiseReductionEnabled: true,+ })++ assert.equal(+ request.url,+ "https://api.openai.com/v1/realtime/translations/client_secrets"+ )+ assert.equal(request.init.method, "POST")+ assert.deepEqual(request.init.headers, {+ Authorization: "Bearer sk-test",+ "Content-Type": "application/json",+ })++ const body = JSON.parse(request.init.body)+ assert.deepEqual(body, {+ session: {+ model: DEFAULT_TRANSLATION_MODEL,+ audio: {+ input: {+ transcription: {+ model: DEFAULT_INPUT_TRANSCRIPTION_MODEL,+ },+ noise_reduction: { type: "near_field" },+ },+ output: {+ language: "es",+ },+ },+ },+ })+ assert.equal("type" in body.session, false)+ assert.equal("format" in body.session.audio.input, false)+ assert.equal("max_output_tokens" in body.session, false)+ })++ it("uses null noise reduction and omits transcription when disabled", () => {+ const request = buildTranslationClientSecretRequest({+ apiKey: "sk-test",+ language: "fr",+ inputTranscriptionEnabled: false,+ noiseReductionEnabled: false,+ })++ const body = JSON.parse(request.init.body)+ assert.deepEqual(body.session.audio.input, {+ noise_reduction: null,+ })+ })++ it("builds session.update without session.type", () => {+ const update = buildSessionUpdate({+ language: "vi",+ inputTranscriptionEnabled: true,+ noiseReductionEnabled: false,+ })++ assert.deepEqual(update, {+ type: "session.update",+ session: {+ audio: {+ input: {+ transcription: {+ model: DEFAULT_INPUT_TRANSCRIPTION_MODEL,+ },+ noise_reduction: null,+ },+ output: {+ language: "vi",+ },+ },+ },+ })+ })++ it("normalizes supported language codes", () => {+ assert.equal(normalizeTranslationLanguage("JA"), "ja")+ assert.throws(() => normalizeTranslationLanguage("pt-br"), /Unsupported/)+ assert.throws(() => normalizeTranslationLanguage("<script>"), /Invalid/)+ })++ it("exposes the translation WebRTC calls endpoint", () => {+ assert.equal(+ REALTIME_TRANSLATION_CALL_URL,+ "https://api.openai.com/v1/realtime/translations/calls"+ )+ assert.equal(+ REALTIME_TRANSLATION_CLIENT_SECRET_URL,+ "https://api.openai.com/v1/realtime/translations/client_secrets"+ )+ })+})diff --git a/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/tsconfig.json b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/tsconfig.jsonnew file mode 100644index 00000000..50c5a0e6--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/livekit-translation-demo/tsconfig.json@@ -0,0 +1,44 @@+{+ "compilerOptions": {+ "target": "ES2022",+ "lib": [+ "dom",+ "dom.iterable",+ "es2022"+ ],+ "allowJs": true,+ "skipLibCheck": true,+ "strict": true,+ "noEmit": true,+ "esModuleInterop": true,+ "module": "esnext",+ "moduleResolution": "bundler",+ "resolveJsonModule": true,+ "isolatedModules": true,+ "jsx": "react-jsx",+ "incremental": true,+ "noUncheckedIndexedAccess": true,+ "baseUrl": ".",+ "paths": {+ "@/*": [+ "./*"+ ]+ },+ "plugins": [+ {+ "name": "next"+ }+ ]+ },+ "include": [+ "next-env.d.ts",+ "next.config.ts",+ "**/*.ts",+ "**/*.tsx",+ ".next/types/**/*.ts",+ ".next/dev/types/**/*.ts"+ ],+ "exclude": [+ "node_modules"+ ]+}diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/.env.example b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/.env.examplenew file mode 100644index 00000000..ff45e83c--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/.env.example@@ -0,0 +1,7 @@+OPENAI_API_KEY=+PUBLIC_URL=https://your-public-host.example.com+PORT=5050+OPENAI_TRANSLATION_MODEL=gpt-realtime-translate+TWILIO_AUTH_TOKEN=+ALLOWED_CALLER_NUMBERS=+MAX_ACTIVE_CALLERS=4diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/.gitignore b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/.gitignorenew file mode 100644index 00000000..7cadffcc--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/.gitignore@@ -0,0 +1,5 @@+.env+.env.*+!.env.example+node_modules/+coverage/diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/README.md b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/README.mdnew file mode 100644index 00000000..f60dac38--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/README.md@@ -0,0 +1,93 @@+# Twilio Realtime Translation Demo++This is a server-side demo for two-person phone translation with Twilio Media Streams and `gpt-realtime-translate`.++Each caller dials the same Twilio number, says the language they want to hear, and waits for a second caller. The server pairs the calls and opens two Realtime Translation sessions:++```txt+Caller A audio -> Realtime Translation -> Caller B hears B's selected language+Caller B audio -> Realtime Translation -> Caller A hears A's selected language+```++## Why WebSocket here++Twilio Media Streams are already server-side WebSocket connections. The server receives `audio/x-mulaw` 8 kHz audio from Twilio, converts it to 24 kHz PCM16 for Realtime Translation, converts translated 24 kHz PCM16 output back to 8 kHz mulaw, and sends it back to Twilio as `media` messages.++## Setup++From the cookbook repo root:++```bash+cd examples/voice_solutions/realtime_translation_guide/twilio-translation-demo+npm install+cp .env.example .env+```++Set:++```bash+OPENAI_API_KEY=your-openai-api-key+PUBLIC_URL=https://your-public-host.example.com+PORT=5050+OPENAI_TRANSLATION_MODEL=gpt-realtime-translate+TWILIO_AUTH_TOKEN=your-twilio-auth-token+ALLOWED_CALLER_NUMBERS=+15551234567,+15557654321+MAX_ACTIVE_CALLERS=4+```++Run:++```bash+npm run dev+```++Configure your Twilio phone number Voice webhook to:++```txt+POST https://your-public-host.example.com/incoming-call+```++For local testing, expose port `5050` through a public HTTPS/WSS tunnel or deploy this server somewhere Twilio can reach over port 443.++## Public deployment notes++Twilio must be able to reach the same public HTTPS/WSS origin for `/incoming-call`, `/choose-language`, and `/media-stream`. Use a stable public deployment for repeatable demos.++Set `OPENAI_API_KEY` and `TWILIO_AUTH_TOKEN` as deployment secrets. Set `PUBLIC_URL` to the deployed origin so Twilio signature validation uses the same public URL that Twilio requested.++Use `ALLOWED_CALLER_NUMBERS` when you want the phone number to be callable only from known test phones. Leave it empty for an open demo. Use `MAX_ACTIVE_CALLERS` to cap concurrent callers and prevent runaway Twilio/OpenAI spend.++## Known limitation++This demo only sends audio back to a caller when the Realtime Translation session emits translated audio. It does not pass the speaker's original Twilio audio through as a fallback. If the speaker is already using the listener's selected language, or if no translated audio is emitted for a short stretch, the listener may hear silence rather than the original speech.++Adding original-audio fallback requires a server-side playout/mixing layer that buffers Twilio media frames, decides when translated audio should take priority, and optionally mixes original audio under translated output. That is intentionally out of scope for this demo.++## Call Flow++1. Caller dials your Twilio number.+2. Twilio requests `/incoming-call`.+3. The server returns TwiML with `<Gather input="speech">` so the caller can say an output language.+4. Twilio posts the recognized speech to `/choose-language`. If the speech is missing, unclear, or names an unsupported language, the server reprompts instead of defaulting to a language.+5. The server returns `<Connect><Stream>` with custom parameters for the call SID and selected output language.+6. Twilio opens `/media-stream`.+7. The server pairs the caller with the next waiting caller.+8. The server streams each caller's audio through a separate Realtime Translation session and plays translated audio to the other caller.++## Notes++- This demo intentionally uses direct server-side Realtime Translation WebSockets, not browser client secrets.+- Direct server-side WebSockets select the translation model with the `model` query parameter, then configure the target language with `session.audio.output.language`.+- Input and output transcripts are emitted as JSON log lines prefixed with `[translation-transcript]`. Each line includes `callSid`, `direction`, `targetLanguage`, `phase`, `eventType`, and `text` so eval tooling can compare input speech against translated output.+- Twilio two-way Media Streams receive only the inbound track and allow the server to send audio back to the call.+- The demo keeps call state in memory. Use durable state if you deploy beyond local demos.+- Twilio request signature validation is enabled when `TWILIO_AUTH_TOKEN` is set. Leave `SKIP_TWILIO_SIGNATURE_VALIDATION=true` only for local debugging.++## Test++From the cookbook repo root:++```bash+cd examples/voice_solutions/realtime_translation_guide/twilio-translation-demo+npm test+```diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/package-lock.json b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/package-lock.jsonnew file mode 100644index 00000000..a8b644af--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/package-lock.json@@ -0,0 +1,2098 @@+{+ "name": "twilio-realtime-translation-demo",+ "version": "0.1.0",+ "lockfileVersion": 3,+ "requires": true,+ "packages": {+ "": {+ "name": "twilio-realtime-translation-demo",+ "version": "0.1.0",+ "dependencies": {+ "@fastify/formbody": "^8.0.2",+ "@fastify/websocket": "^11.0.2",+ "dotenv": "^16.4.7",+ "fastify": "^5.2.1",+ "ws": "^8.18.0"+ },+ "devDependencies": {+ "vitest": "^4.1.5"+ },+ "engines": {+ "node": ">=20"+ }+ },+ "node_modules/@emnapi/core": {+ "version": "1.10.0",+ "resolved": "https://registry.npmjs.org/@emnapi/core/-/core-1.10.0.tgz",+ "integrity": "sha512-yq6OkJ4p82CAfPl0u9mQebQHKPJkY7WrIuk205cTYnYe+k2Z8YBh11FrbRG/H6ihirqcacOgl2BIO8oyMQLeXw==",+ "dev": true,+ "license": "MIT",+ "optional": true,+ "dependencies": {+ "@emnapi/wasi-threads": "1.2.1",+ "tslib": "^2.4.0"+ }+ },+ "node_modules/@emnapi/runtime": {+ "version": "1.10.0",+ "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.10.0.tgz",+ "integrity": "sha512-ewvYlk86xUoGI0zQRNq/mC+16R1QeDlKQy21Ki3oSYXNgLb45GV1P6A0M+/s6nyCuNDqe5VpaY84BzXGwVbwFA==",+ "dev": true,+ "license": "MIT",+ "optional": true,+ "dependencies": {+ "tslib": "^2.4.0"+ }+ },+ "node_modules/@emnapi/wasi-threads": {+ "version": "1.2.1",+ "resolved": "https://registry.npmjs.org/@emnapi/wasi-threads/-/wasi-threads-1.2.1.tgz",+ "integrity": "sha512-uTII7OYF+/Mes/MrcIOYp5yOtSMLBWSIoLPpcgwipoiKbli6k322tcoFsxoIIxPDqW01SQGAgko4EzZi2BNv2w==",+ "dev": true,+ "license": "MIT",+ "optional": true,+ "dependencies": {+ "tslib": "^2.4.0"+ }+ },+ "node_modules/@fastify/ajv-compiler": {+ "version": "4.0.5",+ "resolved": "https://registry.npmjs.org/@fastify/ajv-compiler/-/ajv-compiler-4.0.5.tgz",+ "integrity": "sha512-KoWKW+MhvfTRWL4qrhUwAAZoaChluo0m0vbiJlGMt2GXvL4LVPQEjt8kSpHI3IBq5Rez8fg+XeH3cneztq+C7A==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT",+ "dependencies": {+ "ajv": "^8.12.0",+ "ajv-formats": "^3.0.1",+ "fast-uri": "^3.0.0"+ }+ },+ "node_modules/@fastify/error": {+ "version": "4.2.0",+ "resolved": "https://registry.npmjs.org/@fastify/error/-/error-4.2.0.tgz",+ "integrity": "sha512-RSo3sVDXfHskiBZKBPRgnQTtIqpi/7zhJOEmAxCiBcM7d0uwdGdxLlsCaLzGs8v8NnxIRlfG0N51p5yFaOentQ==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT"+ },+ "node_modules/@fastify/fast-json-stringify-compiler": {+ "version": "5.0.3",+ "resolved": "https://registry.npmjs.org/@fastify/fast-json-stringify-compiler/-/fast-json-stringify-compiler-5.0.3.tgz",+ "integrity": "sha512-uik7yYHkLr6fxd8hJSZ8c+xF4WafPK+XzneQDPU+D10r5X19GW8lJcom2YijX2+qtFF1ENJlHXKFM9ouXNJYgQ==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT",+ "dependencies": {+ "fast-json-stringify": "^6.0.0"+ }+ },+ "node_modules/@fastify/formbody": {+ "version": "8.0.2",+ "resolved": "https://registry.npmjs.org/@fastify/formbody/-/formbody-8.0.2.tgz",+ "integrity": "sha512-84v5J2KrkXzjgBpYnaNRPqwgMsmY7ZDjuj0YVuMR3NXCJRCgKEZy/taSP1wUYGn0onfxJpLyRGDLa+NMaDJtnA==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT",+ "dependencies": {+ "fast-querystring": "^1.1.2",+ "fastify-plugin": "^5.0.0"+ }+ },+ "node_modules/@fastify/forwarded": {+ "version": "3.0.1",+ "resolved": "https://registry.npmjs.org/@fastify/forwarded/-/forwarded-3.0.1.tgz",+ "integrity": "sha512-JqDochHFqXs3C3Ml3gOY58zM7OqO9ENqPo0UqAjAjH8L01fRZqwX9iLeX34//kiJubF7r2ZQHtBRU36vONbLlw==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT"+ },+ "node_modules/@fastify/merge-json-schemas": {+ "version": "0.2.1",+ "resolved": "https://registry.npmjs.org/@fastify/merge-json-schemas/-/merge-json-schemas-0.2.1.tgz",+ "integrity": "sha512-OA3KGBCy6KtIvLf8DINC5880o5iBlDX4SxzLQS8HorJAbqluzLRn80UXU0bxZn7UOFhFgpRJDasfwn9nG4FG4A==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT",+ "dependencies": {+ "dequal": "^2.0.3"+ }+ },+ "node_modules/@fastify/proxy-addr": {+ "version": "5.1.0",+ "resolved": "https://registry.npmjs.org/@fastify/proxy-addr/-/proxy-addr-5.1.0.tgz",+ "integrity": "sha512-INS+6gh91cLUjB+PVHfu1UqcB76Sqtpyp7bnL+FYojhjygvOPA9ctiD/JDKsyD9Xgu4hUhCSJBPig/w7duNajw==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT",+ "dependencies": {+ "@fastify/forwarded": "^3.0.0",+ "ipaddr.js": "^2.1.0"+ }+ },+ "node_modules/@fastify/websocket": {+ "version": "11.2.0",+ "resolved": "https://registry.npmjs.org/@fastify/websocket/-/websocket-11.2.0.tgz",+ "integrity": "sha512-3HrDPbAG1CzUCqnslgJxppvzaAZffieOVbLp1DAy1huCSynUWPifSvfdEDUR8HlJLp3sp1A36uOM2tJogADS8w==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT",+ "dependencies": {+ "duplexify": "^4.1.3",+ "fastify-plugin": "^5.0.0",+ "ws": "^8.16.0"+ }+ },+ "node_modules/@jridgewell/sourcemap-codec": {+ "version": "1.5.5",+ "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz",+ "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==",+ "dev": true,+ "license": "MIT"+ },+ "node_modules/@napi-rs/wasm-runtime": {+ "version": "1.1.4",+ "resolved": "https://registry.npmjs.org/@napi-rs/wasm-runtime/-/wasm-runtime-1.1.4.tgz",+ "integrity": "sha512-3NQNNgA1YSlJb/kMH1ildASP9HW7/7kYnRI2szWJaofaS1hWmbGI4H+d3+22aGzXXN9IJ+n+GiFVcGipJP18ow==",+ "dev": true,+ "license": "MIT",+ "optional": true,+ "dependencies": {+ "@tybys/wasm-util": "^0.10.1"+ },+ "funding": {+ "type": "github",+ "url": "https://github.com/sponsors/Brooooooklyn"+ },+ "peerDependencies": {+ "@emnapi/core": "^1.7.1",+ "@emnapi/runtime": "^1.7.1"+ }+ },+ "node_modules/@oxc-project/types": {+ "version": "0.127.0",+ "resolved": "https://registry.npmjs.org/@oxc-project/types/-/types-0.127.0.tgz",+ "integrity": "sha512-aIYXQBo4lCbO4z0R3FHeucQHpF46l2LbMdxRvqvuRuW2OxdnSkcng5B8+K12spgLDj93rtN3+J2Vac/TIO+ciQ==",+ "dev": true,+ "license": "MIT",+ "funding": {+ "url": "https://github.com/sponsors/Boshen"+ }+ },+ "node_modules/@pinojs/redact": {+ "version": "0.4.0",+ "resolved": "https://registry.npmjs.org/@pinojs/redact/-/redact-0.4.0.tgz",+ "integrity": "sha512-k2ENnmBugE/rzQfEcdWHcCY+/FM3VLzH9cYEsbdsoqrvzAKRhUZeRNhAZvB8OitQJ1TBed3yqWtdjzS6wJKBwg==",+ "license": "MIT"+ },+ "node_modules/@rolldown/binding-android-arm64": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-android-arm64/-/binding-android-arm64-1.0.0-rc.17.tgz",+ "integrity": "sha512-s70pVGhw4zqGeFnXWvAzJDlvxhlRollagdCCKRgOsgUOH3N1l0LIxf83AtGzmb5SiVM4Hjl5HyarMRfdfj3DaQ==",+ "cpu": [+ "arm64"+ ],+ "dev": true,+ "license": "MIT",+ "optional": true,+ "os": [+ "android"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-darwin-arm64": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-darwin-arm64/-/binding-darwin-arm64-1.0.0-rc.17.tgz",+ "integrity": "sha512-4ksWc9n0mhlZpZ9PMZgTGjeOPRu8MB1Z3Tz0Mo02eWfWCHMW1zN82Qz/pL/rC+yQa+8ZnutMF0JjJe7PjwasYw==",+ "cpu": [+ "arm64"+ ],+ "dev": true,+ "license": "MIT",+ "optional": true,+ "os": [+ "darwin"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-darwin-x64": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-darwin-x64/-/binding-darwin-x64-1.0.0-rc.17.tgz",+ "integrity": "sha512-SUSDOI6WwUVNcWxd02QEBjLdY1VPHvlEkw6T/8nYG322iYWCTxRb1vzk4E+mWWYehTp7ERibq54LSJGjmouOsw==",+ "cpu": [+ "x64"+ ],+ "dev": true,+ "license": "MIT",+ "optional": true,+ "os": [+ "darwin"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-freebsd-x64": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-freebsd-x64/-/binding-freebsd-x64-1.0.0-rc.17.tgz",+ "integrity": "sha512-hwnz3nw9dbJ05EDO/PvcjaaewqqDy7Y1rn1UO81l8iIK1GjenME75dl16ajbvSSMfv66WXSRCYKIqfgq2KCfxw==",+ "cpu": [+ "x64"+ ],+ "dev": true,+ "license": "MIT",+ "optional": true,+ "os": [+ "freebsd"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-linux-arm-gnueabihf": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-arm-gnueabihf/-/binding-linux-arm-gnueabihf-1.0.0-rc.17.tgz",+ "integrity": "sha512-IS+W7epTcwANmFSQFrS1SivEXHtl1JtuQA9wlxrZTcNi6mx+FDOYrakGevvvTwgj2JvWiK8B29/qD9BELZPyXQ==",+ "cpu": [+ "arm"+ ],+ "dev": true,+ "license": "MIT",+ "optional": true,+ "os": [+ "linux"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-linux-arm64-gnu": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-arm64-gnu/-/binding-linux-arm64-gnu-1.0.0-rc.17.tgz",+ "integrity": "sha512-e6usGaHKW5BMNZOymS1UcEYGowQMWcgZ71Z17Sl/h2+ZziNJ1a9n3Zvcz6LdRyIW5572wBCTH/Z+bKuZouGk9Q==",+ "cpu": [+ "arm64"+ ],+ "dev": true,+ "libc": [+ "glibc"+ ],+ "license": "MIT",+ "optional": true,+ "os": [+ "linux"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-linux-arm64-musl": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-arm64-musl/-/binding-linux-arm64-musl-1.0.0-rc.17.tgz",+ "integrity": "sha512-b/CgbwAJpmrRLp02RPfhbudf5tZnN9nsPWK82znefso832etkem8H7FSZwxrOI9djcdTP7U6YfNhbRnh7djErg==",+ "cpu": [+ "arm64"+ ],+ "dev": true,+ "libc": [+ "musl"+ ],+ "license": "MIT",+ "optional": true,+ "os": [+ "linux"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-linux-ppc64-gnu": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-ppc64-gnu/-/binding-linux-ppc64-gnu-1.0.0-rc.17.tgz",+ "integrity": "sha512-4EII1iNGRUN5WwGbF/kOh/EIkoDN9HsupgLQoXfY+D1oyJm7/F4t5PYU5n8SWZgG0FEwakyM8pGgwcBYruGTlA==",+ "cpu": [+ "ppc64"+ ],+ "dev": true,+ "libc": [+ "glibc"+ ],+ "license": "MIT",+ "optional": true,+ "os": [+ "linux"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-linux-s390x-gnu": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-s390x-gnu/-/binding-linux-s390x-gnu-1.0.0-rc.17.tgz",+ "integrity": "sha512-AH8oq3XqQo4IibpVXvPeLDI5pzkpYn0WiZAfT05kFzoJ6tQNzwRdDYQ45M8I/gslbodRZwW8uxLhbSBbkv96rA==",+ "cpu": [+ "s390x"+ ],+ "dev": true,+ "libc": [+ "glibc"+ ],+ "license": "MIT",+ "optional": true,+ "os": [+ "linux"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-linux-x64-gnu": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-x64-gnu/-/binding-linux-x64-gnu-1.0.0-rc.17.tgz",+ "integrity": "sha512-cLnjV3xfo7KslbU41Z7z8BH/E1y5mzUYzAqih1d1MDaIGZRCMqTijqLv76/P7fyHuvUcfGsIpqCdddbxLLK9rA==",+ "cpu": [+ "x64"+ ],+ "dev": true,+ "libc": [+ "glibc"+ ],+ "license": "MIT",+ "optional": true,+ "os": [+ "linux"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-linux-x64-musl": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-x64-musl/-/binding-linux-x64-musl-1.0.0-rc.17.tgz",+ "integrity": "sha512-0phclDw1spsL7dUB37sIARuis2tAgomCJXAHZlpt8PXZ4Ba0dRP1e+66lsRqrfhISeN9bEGNjQs+T/Fbd7oYGw==",+ "cpu": [+ "x64"+ ],+ "dev": true,+ "libc": [+ "musl"+ ],+ "license": "MIT",+ "optional": true,+ "os": [+ "linux"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-openharmony-arm64": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-openharmony-arm64/-/binding-openharmony-arm64-1.0.0-rc.17.tgz",+ "integrity": "sha512-0ag/hEgXOwgw4t8QyQvUCxvEg+V0KBcA6YuOx9g0r02MprutRF5dyljgm3EmR02O292UX7UeS6HzWHAl6KgyhA==",+ "cpu": [+ "arm64"+ ],+ "dev": true,+ "license": "MIT",+ "optional": true,+ "os": [+ "openharmony"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-wasm32-wasi": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-wasm32-wasi/-/binding-wasm32-wasi-1.0.0-rc.17.tgz",+ "integrity": "sha512-LEXei6vo0E5wTGwpkJ4KoT3OZJRnglwldt5ziLzOlc6qqb55z4tWNq2A+PFqCJuvWWdP53CVhG1Z9NtToDPJrA==",+ "cpu": [+ "wasm32"+ ],+ "dev": true,+ "license": "MIT",+ "optional": true,+ "dependencies": {+ "@emnapi/core": "1.10.0",+ "@emnapi/runtime": "1.10.0",+ "@napi-rs/wasm-runtime": "^1.1.4"+ },+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-win32-arm64-msvc": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-win32-arm64-msvc/-/binding-win32-arm64-msvc-1.0.0-rc.17.tgz",+ "integrity": "sha512-gUmyzBl3SPMa6hrqFUth9sVfcLBlYsbMzBx5PlexMroZStgzGqlZ26pYG89rBb45Mnia+oil6YAIFeEWGWhoZA==",+ "cpu": [+ "arm64"+ ],+ "dev": true,+ "license": "MIT",+ "optional": true,+ "os": [+ "win32"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/binding-win32-x64-msvc": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/binding-win32-x64-msvc/-/binding-win32-x64-msvc-1.0.0-rc.17.tgz",+ "integrity": "sha512-3hkiolcUAvPB9FLb3UZdfjVVNWherN1f/skkGWJP/fgSQhYUZpSIRr0/I8ZK9TkF3F7kxvJAk0+IcKvPHk9qQg==",+ "cpu": [+ "x64"+ ],+ "dev": true,+ "license": "MIT",+ "optional": true,+ "os": [+ "win32"+ ],+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ }+ },+ "node_modules/@rolldown/pluginutils": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/@rolldown/pluginutils/-/pluginutils-1.0.0-rc.17.tgz",+ "integrity": "sha512-n8iosDOt6Ig1UhJ2AYqoIhHWh/isz0xpicHTzpKBeotdVsTEcxsSA/i3EVM7gQAj0rU27OLAxCjzlj15IWY7bg==",+ "dev": true,+ "license": "MIT"+ },+ "node_modules/@standard-schema/spec": {+ "version": "1.1.0",+ "resolved": "https://registry.npmjs.org/@standard-schema/spec/-/spec-1.1.0.tgz",+ "integrity": "sha512-l2aFy5jALhniG5HgqrD6jXLi/rUWrKvqN/qJx6yoJsgKhblVd+iqqU4RCXavm/jPityDo5TCvKMnpjKnOriy0w==",+ "dev": true,+ "license": "MIT"+ },+ "node_modules/@tybys/wasm-util": {+ "version": "0.10.1",+ "resolved": "https://registry.npmjs.org/@tybys/wasm-util/-/wasm-util-0.10.1.tgz",+ "integrity": "sha512-9tTaPJLSiejZKx+Bmog4uSubteqTvFrVrURwkmHixBo0G4seD0zUxp98E1DzUBJxLQ3NPwXrGKDiVjwx/DpPsg==",+ "dev": true,+ "license": "MIT",+ "optional": true,+ "dependencies": {+ "tslib": "^2.4.0"+ }+ },+ "node_modules/@types/chai": {+ "version": "5.2.3",+ "resolved": "https://registry.npmjs.org/@types/chai/-/chai-5.2.3.tgz",+ "integrity": "sha512-Mw558oeA9fFbv65/y4mHtXDs9bPnFMZAL/jxdPFUpOHHIXX91mcgEHbS5Lahr+pwZFR8A7GQleRWeI6cGFC2UA==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "@types/deep-eql": "*",+ "assertion-error": "^2.0.1"+ }+ },+ "node_modules/@types/deep-eql": {+ "version": "4.0.2",+ "resolved": "https://registry.npmjs.org/@types/deep-eql/-/deep-eql-4.0.2.tgz",+ "integrity": "sha512-c9h9dVVMigMPc4bwTvC5dxqtqJZwQPePsWjPlpSOnojbor6pGqdk541lfA7AqFQr5pB1BRdq0juY9db81BwyFw==",+ "dev": true,+ "license": "MIT"+ },+ "node_modules/@types/estree": {+ "version": "1.0.8",+ "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.8.tgz",+ "integrity": "sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==",+ "dev": true,+ "license": "MIT"+ },+ "node_modules/@vitest/expect": {+ "version": "4.1.5",+ "resolved": "https://registry.npmjs.org/@vitest/expect/-/expect-4.1.5.tgz",+ "integrity": "sha512-PWBaRY5JoKuRnHlUHfpV/KohFylaDZTupcXN1H9vYryNLOnitSw60Mw9IAE2r67NbwwzBw/Cc/8q9BK3kIX8Kw==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "@standard-schema/spec": "^1.1.0",+ "@types/chai": "^5.2.2",+ "@vitest/spy": "4.1.5",+ "@vitest/utils": "4.1.5",+ "chai": "^6.2.2",+ "tinyrainbow": "^3.1.0"+ },+ "funding": {+ "url": "https://opencollective.com/vitest"+ }+ },+ "node_modules/@vitest/mocker": {+ "version": "4.1.5",+ "resolved": "https://registry.npmjs.org/@vitest/mocker/-/mocker-4.1.5.tgz",+ "integrity": "sha512-/x2EmFC4mT4NNzqvC3fmesuV97w5FC903KPmey4gsnJiMQ3Be1IlDKVaDaG8iqaLFHqJ2FVEkxZk5VmeLjIItw==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "@vitest/spy": "4.1.5",+ "estree-walker": "^3.0.3",+ "magic-string": "^0.30.21"+ },+ "funding": {+ "url": "https://opencollective.com/vitest"+ },+ "peerDependencies": {+ "msw": "^2.4.9",+ "vite": "^6.0.0 || ^7.0.0 || ^8.0.0"+ },+ "peerDependenciesMeta": {+ "msw": {+ "optional": true+ },+ "vite": {+ "optional": true+ }+ }+ },+ "node_modules/@vitest/pretty-format": {+ "version": "4.1.5",+ "resolved": "https://registry.npmjs.org/@vitest/pretty-format/-/pretty-format-4.1.5.tgz",+ "integrity": "sha512-7I3q6l5qr03dVfMX2wCo9FxwSJbPdwKjy2uu/YPpU3wfHvIL4QHwVRp57OfGrDFeUJ8/8QdfBKIV12FTtLn00g==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "tinyrainbow": "^3.1.0"+ },+ "funding": {+ "url": "https://opencollective.com/vitest"+ }+ },+ "node_modules/@vitest/runner": {+ "version": "4.1.5",+ "resolved": "https://registry.npmjs.org/@vitest/runner/-/runner-4.1.5.tgz",+ "integrity": "sha512-2D+o7Pr82IEO46YPpoA/YU0neeyr6FTerQb5Ro7BUnBuv6NQtT/kmVnczngiMEBhzgqz2UZYl5gArejsyERDSQ==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "@vitest/utils": "4.1.5",+ "pathe": "^2.0.3"+ },+ "funding": {+ "url": "https://opencollective.com/vitest"+ }+ },+ "node_modules/@vitest/snapshot": {+ "version": "4.1.5",+ "resolved": "https://registry.npmjs.org/@vitest/snapshot/-/snapshot-4.1.5.tgz",+ "integrity": "sha512-zypXEt4KH/XgKGPUz4eC2AvErYx0My5hfL8oDb1HzGFpEk1P62bxSohdyOmvz+d9UJwanI68MKwr2EquOaOgMQ==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "@vitest/pretty-format": "4.1.5",+ "@vitest/utils": "4.1.5",+ "magic-string": "^0.30.21",+ "pathe": "^2.0.3"+ },+ "funding": {+ "url": "https://opencollective.com/vitest"+ }+ },+ "node_modules/@vitest/spy": {+ "version": "4.1.5",+ "resolved": "https://registry.npmjs.org/@vitest/spy/-/spy-4.1.5.tgz",+ "integrity": "sha512-2lNOsh6+R2Idnf1TCZqSwYlKN2E/iDlD8sgU59kYVl+OMDmvldO1VDk39smRfpUNwYpNRVn3w4YfuC7KfbBnkQ==",+ "dev": true,+ "license": "MIT",+ "funding": {+ "url": "https://opencollective.com/vitest"+ }+ },+ "node_modules/@vitest/utils": {+ "version": "4.1.5",+ "resolved": "https://registry.npmjs.org/@vitest/utils/-/utils-4.1.5.tgz",+ "integrity": "sha512-76wdkrmfXfqGjueGgnb45ITPyUi1ycZ4IHgC2bhPDUfWHklY/q3MdLOAB+TF1e6xfl8NxNY0ZYaPCFNWSsw3Ug==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "@vitest/pretty-format": "4.1.5",+ "convert-source-map": "^2.0.0",+ "tinyrainbow": "^3.1.0"+ },+ "funding": {+ "url": "https://opencollective.com/vitest"+ }+ },+ "node_modules/abstract-logging": {+ "version": "2.0.1",+ "resolved": "https://registry.npmjs.org/abstract-logging/-/abstract-logging-2.0.1.tgz",+ "integrity": "sha512-2BjRTZxTPvheOvGbBslFSYOUkr+SjPtOnrLP33f+VIWLzezQpZcqVg7ja3L4dBXmzzgwT+a029jRx5PCi3JuiA==",+ "license": "MIT"+ },+ "node_modules/ajv": {+ "version": "8.20.0",+ "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.20.0.tgz",+ "integrity": "sha512-Thbli+OlOj+iMPYFBVBfJ3OmCAnaSyNn4M1vz9T6Gka5Jt9ba/HIR56joy65tY6kx/FCF5VXNB819Y7/GUrBGA==",+ "license": "MIT",+ "dependencies": {+ "fast-deep-equal": "^3.1.3",+ "fast-uri": "^3.0.1",+ "json-schema-traverse": "^1.0.0",+ "require-from-string": "^2.0.2"+ },+ "funding": {+ "type": "github",+ "url": "https://github.com/sponsors/epoberezkin"+ }+ },+ "node_modules/ajv-formats": {+ "version": "3.0.1",+ "resolved": "https://registry.npmjs.org/ajv-formats/-/ajv-formats-3.0.1.tgz",+ "integrity": "sha512-8iUql50EUR+uUcdRQ3HDqa6EVyo3docL8g5WJ3FNcWmu62IbkGUue/pEyLBW8VGKKucTPgqeks4fIU1DA4yowQ==",+ "license": "MIT",+ "dependencies": {+ "ajv": "^8.0.0"+ },+ "peerDependencies": {+ "ajv": "^8.0.0"+ },+ "peerDependenciesMeta": {+ "ajv": {+ "optional": true+ }+ }+ },+ "node_modules/assertion-error": {+ "version": "2.0.1",+ "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-2.0.1.tgz",+ "integrity": "sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA==",+ "dev": true,+ "license": "MIT",+ "engines": {+ "node": ">=12"+ }+ },+ "node_modules/atomic-sleep": {+ "version": "1.0.0",+ "resolved": "https://registry.npmjs.org/atomic-sleep/-/atomic-sleep-1.0.0.tgz",+ "integrity": "sha512-kNOjDqAh7px0XWNI+4QbzoiR/nTkHAWNud2uvnJquD1/x5a7EQZMJT0AczqK0Qn67oY/TTQ1LbUKajZpp3I9tQ==",+ "license": "MIT",+ "engines": {+ "node": ">=8.0.0"+ }+ },+ "node_modules/avvio": {+ "version": "9.2.0",+ "resolved": "https://registry.npmjs.org/avvio/-/avvio-9.2.0.tgz",+ "integrity": "sha512-2t/sy01ArdHHE0vRH5Hsay+RtCZt3dLPji7W7/MMOCEgze5b7SNDC4j5H6FnVgPkI1MTNFGzHdHrVXDDl7QSSQ==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT",+ "dependencies": {+ "@fastify/error": "^4.0.0",+ "fastq": "^1.17.1"+ }+ },+ "node_modules/chai": {+ "version": "6.2.2",+ "resolved": "https://registry.npmjs.org/chai/-/chai-6.2.2.tgz",+ "integrity": "sha512-NUPRluOfOiTKBKvWPtSD4PhFvWCqOi0BGStNWs57X9js7XGTprSmFoz5F0tWhR4WPjNeR9jXqdC7/UpSJTnlRg==",+ "dev": true,+ "license": "MIT",+ "engines": {+ "node": ">=18"+ }+ },+ "node_modules/convert-source-map": {+ "version": "2.0.0",+ "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz",+ "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==",+ "dev": true,+ "license": "MIT"+ },+ "node_modules/cookie": {+ "version": "1.1.1",+ "resolved": "https://registry.npmjs.org/cookie/-/cookie-1.1.1.tgz",+ "integrity": "sha512-ei8Aos7ja0weRpFzJnEA9UHJ/7XQmqglbRwnf2ATjcB9Wq874VKH9kfjjirM6UhU2/E5fFYadylyhFldcqSidQ==",+ "license": "MIT",+ "engines": {+ "node": ">=18"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/express"+ }+ },+ "node_modules/dequal": {+ "version": "2.0.3",+ "resolved": "https://registry.npmjs.org/dequal/-/dequal-2.0.3.tgz",+ "integrity": "sha512-0je+qPKHEMohvfRTCEo3CrPG6cAzAYgmzKyxRiYSSDkS6eGJdyVJm7WaYA5ECaAD9wLB2T4EEeymA5aFVcYXCA==",+ "license": "MIT",+ "engines": {+ "node": ">=6"+ }+ },+ "node_modules/detect-libc": {+ "version": "2.1.2",+ "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz",+ "integrity": "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==",+ "dev": true,+ "license": "Apache-2.0",+ "engines": {+ "node": ">=8"+ }+ },+ "node_modules/dotenv": {+ "version": "16.6.1",+ "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.6.1.tgz",+ "integrity": "sha512-uBq4egWHTcTt33a72vpSG0z3HnPuIl6NqYcTrKEg2azoEyl2hpW0zqlxysq2pK9HlDIHyHyakeYaYnSAwd8bow==",+ "license": "BSD-2-Clause",+ "engines": {+ "node": ">=12"+ },+ "funding": {+ "url": "https://dotenvx.com"+ }+ },+ "node_modules/duplexify": {+ "version": "4.1.3",+ "resolved": "https://registry.npmjs.org/duplexify/-/duplexify-4.1.3.tgz",+ "integrity": "sha512-M3BmBhwJRZsSx38lZyhE53Csddgzl5R7xGJNk7CVddZD6CcmwMCH8J+7AprIrQKH7TonKxaCjcv27Qmf+sQ+oA==",+ "license": "MIT",+ "dependencies": {+ "end-of-stream": "^1.4.1",+ "inherits": "^2.0.3",+ "readable-stream": "^3.1.1",+ "stream-shift": "^1.0.2"+ }+ },+ "node_modules/end-of-stream": {+ "version": "1.4.5",+ "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.5.tgz",+ "integrity": "sha512-ooEGc6HP26xXq/N+GCGOT0JKCLDGrq2bQUZrQ7gyrJiZANJ/8YDTxTpQBXGMn+WbIQXNVpyWymm7KYVICQnyOg==",+ "license": "MIT",+ "dependencies": {+ "once": "^1.4.0"+ }+ },+ "node_modules/es-module-lexer": {+ "version": "2.1.0",+ "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-2.1.0.tgz",+ "integrity": "sha512-n27zTYMjYu1aj4MjCWzSP7G9r75utsaoc8m61weK+W8JMBGGQybd43GstCXZ3WNmSFtGT9wi59qQTW6mhTR5LQ==",+ "dev": true,+ "license": "MIT"+ },+ "node_modules/estree-walker": {+ "version": "3.0.3",+ "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-3.0.3.tgz",+ "integrity": "sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "@types/estree": "^1.0.0"+ }+ },+ "node_modules/expect-type": {+ "version": "1.3.0",+ "resolved": "https://registry.npmjs.org/expect-type/-/expect-type-1.3.0.tgz",+ "integrity": "sha512-knvyeauYhqjOYvQ66MznSMs83wmHrCycNEN6Ao+2AeYEfxUIkuiVxdEa1qlGEPK+We3n0THiDciYSsCcgW/DoA==",+ "dev": true,+ "license": "Apache-2.0",+ "engines": {+ "node": ">=12.0.0"+ }+ },+ "node_modules/fast-decode-uri-component": {+ "version": "1.0.1",+ "resolved": "https://registry.npmjs.org/fast-decode-uri-component/-/fast-decode-uri-component-1.0.1.tgz",+ "integrity": "sha512-WKgKWg5eUxvRZGwW8FvfbaH7AXSh2cL+3j5fMGzUMCxWBJ3dV3a7Wz8y2f/uQ0e3B6WmodD3oS54jTQ9HVTIIg==",+ "license": "MIT"+ },+ "node_modules/fast-deep-equal": {+ "version": "3.1.3",+ "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz",+ "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==",+ "license": "MIT"+ },+ "node_modules/fast-json-stringify": {+ "version": "6.3.0",+ "resolved": "https://registry.npmjs.org/fast-json-stringify/-/fast-json-stringify-6.3.0.tgz",+ "integrity": "sha512-oRCntNDY/329HJPlmdNLIdogNtt6Vyjb1WuT01Soss3slIdyUp8kAcDU3saQTOquEK8KFVfwIIF7FebxUAu+yA==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT",+ "dependencies": {+ "@fastify/merge-json-schemas": "^0.2.0",+ "ajv": "^8.12.0",+ "ajv-formats": "^3.0.1",+ "fast-uri": "^3.0.0",+ "json-schema-ref-resolver": "^3.0.0",+ "rfdc": "^1.2.0"+ }+ },+ "node_modules/fast-querystring": {+ "version": "1.1.2",+ "resolved": "https://registry.npmjs.org/fast-querystring/-/fast-querystring-1.1.2.tgz",+ "integrity": "sha512-g6KuKWmFXc0fID8WWH0jit4g0AGBoJhCkJMb1RmbsSEUNvQ+ZC8D6CUZ+GtF8nMzSPXnhiePyyqqipzNNEnHjg==",+ "license": "MIT",+ "dependencies": {+ "fast-decode-uri-component": "^1.0.1"+ }+ },+ "node_modules/fast-uri": {+ "version": "3.1.0",+ "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.1.0.tgz",+ "integrity": "sha512-iPeeDKJSWf4IEOasVVrknXpaBV0IApz/gp7S2bb7Z4Lljbl2MGJRqInZiUrQwV16cpzw/D3S5j5Julj/gT52AA==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "BSD-3-Clause"+ },+ "node_modules/fastify": {+ "version": "5.8.5",+ "resolved": "https://registry.npmjs.org/fastify/-/fastify-5.8.5.tgz",+ "integrity": "sha512-Yqptv59pQzPgQUSIm87hMqHJmdkb1+GPxdE6vW6FRyVE9G86mt7rOghitiU4JHRaTyDUk9pfeKmDeu70lAwM4Q==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT",+ "dependencies": {+ "@fastify/ajv-compiler": "^4.0.5",+ "@fastify/error": "^4.0.0",+ "@fastify/fast-json-stringify-compiler": "^5.0.0",+ "@fastify/proxy-addr": "^5.0.0",+ "abstract-logging": "^2.0.1",+ "avvio": "^9.0.0",+ "fast-json-stringify": "^6.0.0",+ "find-my-way": "^9.0.0",+ "light-my-request": "^6.0.0",+ "pino": "^9.14.0 || ^10.1.0",+ "process-warning": "^5.0.0",+ "rfdc": "^1.3.1",+ "secure-json-parse": "^4.0.0",+ "semver": "^7.6.0",+ "toad-cache": "^3.7.0"+ }+ },+ "node_modules/fastify-plugin": {+ "version": "5.1.0",+ "resolved": "https://registry.npmjs.org/fastify-plugin/-/fastify-plugin-5.1.0.tgz",+ "integrity": "sha512-FAIDA8eovSt5qcDgcBvDuX/v0Cjz0ohGhENZ/wpc3y+oZCY2afZ9Baqql3g/lC+OHRnciQol4ww7tuthOb9idw==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT"+ },+ "node_modules/fastq": {+ "version": "1.20.1",+ "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.20.1.tgz",+ "integrity": "sha512-GGToxJ/w1x32s/D2EKND7kTil4n8OVk/9mycTc4VDza13lOvpUZTGX3mFSCtV9ksdGBVzvsyAVLM6mHFThxXxw==",+ "license": "ISC",+ "dependencies": {+ "reusify": "^1.0.4"+ }+ },+ "node_modules/fdir": {+ "version": "6.5.0",+ "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.5.0.tgz",+ "integrity": "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==",+ "dev": true,+ "license": "MIT",+ "engines": {+ "node": ">=12.0.0"+ },+ "peerDependencies": {+ "picomatch": "^3 || ^4"+ },+ "peerDependenciesMeta": {+ "picomatch": {+ "optional": true+ }+ }+ },+ "node_modules/find-my-way": {+ "version": "9.5.0",+ "resolved": "https://registry.npmjs.org/find-my-way/-/find-my-way-9.5.0.tgz",+ "integrity": "sha512-VW2RfnmscZO5KgBY5XVyKREMW5nMZcxDy+buTOsL+zIPnBlbKm+00sgzoQzq1EVh4aALZLfKdwv6atBGcjvjrQ==",+ "license": "MIT",+ "dependencies": {+ "fast-deep-equal": "^3.1.3",+ "fast-querystring": "^1.0.0",+ "safe-regex2": "^5.0.0"+ },+ "engines": {+ "node": ">=20"+ }+ },+ "node_modules/fsevents": {+ "version": "2.3.3",+ "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz",+ "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==",+ "dev": true,+ "hasInstallScript": true,+ "license": "MIT",+ "optional": true,+ "os": [+ "darwin"+ ],+ "engines": {+ "node": "^8.16.0 || ^10.6.0 || >=11.0.0"+ }+ },+ "node_modules/inherits": {+ "version": "2.0.4",+ "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz",+ "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==",+ "license": "ISC"+ },+ "node_modules/ipaddr.js": {+ "version": "2.3.0",+ "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-2.3.0.tgz",+ "integrity": "sha512-Zv/pA+ciVFbCSBBjGfaKUya/CcGmUHzTydLMaTwrUUEM2DIEO3iZvueGxmacvmN50fGpGVKeTXpb2LcYQxeVdg==",+ "license": "MIT",+ "engines": {+ "node": ">= 10"+ }+ },+ "node_modules/json-schema-ref-resolver": {+ "version": "3.0.0",+ "resolved": "https://registry.npmjs.org/json-schema-ref-resolver/-/json-schema-ref-resolver-3.0.0.tgz",+ "integrity": "sha512-hOrZIVL5jyYFjzk7+y7n5JDzGlU8rfWDuYyHwGa2WA8/pcmMHezp2xsVwxrebD/Q9t8Nc5DboieySDpCp4WG4A==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT",+ "dependencies": {+ "dequal": "^2.0.3"+ }+ },+ "node_modules/json-schema-traverse": {+ "version": "1.0.0",+ "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz",+ "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==",+ "license": "MIT"+ },+ "node_modules/light-my-request": {+ "version": "6.6.0",+ "resolved": "https://registry.npmjs.org/light-my-request/-/light-my-request-6.6.0.tgz",+ "integrity": "sha512-CHYbu8RtboSIoVsHZ6Ye4cj4Aw/yg2oAFimlF7mNvfDV192LR7nDiKtSIfCuLT7KokPSTn/9kfVLm5OGN0A28A==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "BSD-3-Clause",+ "dependencies": {+ "cookie": "^1.0.1",+ "process-warning": "^4.0.0",+ "set-cookie-parser": "^2.6.0"+ }+ },+ "node_modules/light-my-request/node_modules/process-warning": {+ "version": "4.0.1",+ "resolved": "https://registry.npmjs.org/process-warning/-/process-warning-4.0.1.tgz",+ "integrity": "sha512-3c2LzQ3rY9d0hc1emcsHhfT9Jwz0cChib/QN89oME2R451w5fy3f0afAhERFZAwrbDU43wk12d0ORBpDVME50Q==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT"+ },+ "node_modules/lightningcss": {+ "version": "1.32.0",+ "resolved": "https://registry.npmjs.org/lightningcss/-/lightningcss-1.32.0.tgz",+ "integrity": "sha512-NXYBzinNrblfraPGyrbPoD19C1h9lfI/1mzgWYvXUTe414Gz/X1FD2XBZSZM7rRTrMA8JL3OtAaGifrIKhQ5yQ==",+ "dev": true,+ "license": "MPL-2.0",+ "dependencies": {+ "detect-libc": "^2.0.3"+ },+ "engines": {+ "node": ">= 12.0.0"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/parcel"+ },+ "optionalDependencies": {+ "lightningcss-android-arm64": "1.32.0",+ "lightningcss-darwin-arm64": "1.32.0",+ "lightningcss-darwin-x64": "1.32.0",+ "lightningcss-freebsd-x64": "1.32.0",+ "lightningcss-linux-arm-gnueabihf": "1.32.0",+ "lightningcss-linux-arm64-gnu": "1.32.0",+ "lightningcss-linux-arm64-musl": "1.32.0",+ "lightningcss-linux-x64-gnu": "1.32.0",+ "lightningcss-linux-x64-musl": "1.32.0",+ "lightningcss-win32-arm64-msvc": "1.32.0",+ "lightningcss-win32-x64-msvc": "1.32.0"+ }+ },+ "node_modules/lightningcss-android-arm64": {+ "version": "1.32.0",+ "resolved": "https://registry.npmjs.org/lightningcss-android-arm64/-/lightningcss-android-arm64-1.32.0.tgz",+ "integrity": "sha512-YK7/ClTt4kAK0vo6w3X+Pnm0D2cf2vPHbhOXdoNti1Ga0al1P4TBZhwjATvjNwLEBCnKvjJc2jQgHXH0NEwlAg==",+ "cpu": [+ "arm64"+ ],+ "dev": true,+ "license": "MPL-2.0",+ "optional": true,+ "os": [+ "android"+ ],+ "engines": {+ "node": ">= 12.0.0"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/parcel"+ }+ },+ "node_modules/lightningcss-darwin-arm64": {+ "version": "1.32.0",+ "resolved": "https://registry.npmjs.org/lightningcss-darwin-arm64/-/lightningcss-darwin-arm64-1.32.0.tgz",+ "integrity": "sha512-RzeG9Ju5bag2Bv1/lwlVJvBE3q6TtXskdZLLCyfg5pt+HLz9BqlICO7LZM7VHNTTn/5PRhHFBSjk5lc4cmscPQ==",+ "cpu": [+ "arm64"+ ],+ "dev": true,+ "license": "MPL-2.0",+ "optional": true,+ "os": [+ "darwin"+ ],+ "engines": {+ "node": ">= 12.0.0"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/parcel"+ }+ },+ "node_modules/lightningcss-darwin-x64": {+ "version": "1.32.0",+ "resolved": "https://registry.npmjs.org/lightningcss-darwin-x64/-/lightningcss-darwin-x64-1.32.0.tgz",+ "integrity": "sha512-U+QsBp2m/s2wqpUYT/6wnlagdZbtZdndSmut/NJqlCcMLTWp5muCrID+K5UJ6jqD2BFshejCYXniPDbNh73V8w==",+ "cpu": [+ "x64"+ ],+ "dev": true,+ "license": "MPL-2.0",+ "optional": true,+ "os": [+ "darwin"+ ],+ "engines": {+ "node": ">= 12.0.0"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/parcel"+ }+ },+ "node_modules/lightningcss-freebsd-x64": {+ "version": "1.32.0",+ "resolved": "https://registry.npmjs.org/lightningcss-freebsd-x64/-/lightningcss-freebsd-x64-1.32.0.tgz",+ "integrity": "sha512-JCTigedEksZk3tHTTthnMdVfGf61Fky8Ji2E4YjUTEQX14xiy/lTzXnu1vwiZe3bYe0q+SpsSH/CTeDXK6WHig==",+ "cpu": [+ "x64"+ ],+ "dev": true,+ "license": "MPL-2.0",+ "optional": true,+ "os": [+ "freebsd"+ ],+ "engines": {+ "node": ">= 12.0.0"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/parcel"+ }+ },+ "node_modules/lightningcss-linux-arm-gnueabihf": {+ "version": "1.32.0",+ "resolved": "https://registry.npmjs.org/lightningcss-linux-arm-gnueabihf/-/lightningcss-linux-arm-gnueabihf-1.32.0.tgz",+ "integrity": "sha512-x6rnnpRa2GL0zQOkt6rts3YDPzduLpWvwAF6EMhXFVZXD4tPrBkEFqzGowzCsIWsPjqSK+tyNEODUBXeeVHSkw==",+ "cpu": [+ "arm"+ ],+ "dev": true,+ "license": "MPL-2.0",+ "optional": true,+ "os": [+ "linux"+ ],+ "engines": {+ "node": ">= 12.0.0"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/parcel"+ }+ },+ "node_modules/lightningcss-linux-arm64-gnu": {+ "version": "1.32.0",+ "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-gnu/-/lightningcss-linux-arm64-gnu-1.32.0.tgz",+ "integrity": "sha512-0nnMyoyOLRJXfbMOilaSRcLH3Jw5z9HDNGfT/gwCPgaDjnx0i8w7vBzFLFR1f6CMLKF8gVbebmkUN3fa/kQJpQ==",+ "cpu": [+ "arm64"+ ],+ "dev": true,+ "libc": [+ "glibc"+ ],+ "license": "MPL-2.0",+ "optional": true,+ "os": [+ "linux"+ ],+ "engines": {+ "node": ">= 12.0.0"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/parcel"+ }+ },+ "node_modules/lightningcss-linux-arm64-musl": {+ "version": "1.32.0",+ "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-musl/-/lightningcss-linux-arm64-musl-1.32.0.tgz",+ "integrity": "sha512-UpQkoenr4UJEzgVIYpI80lDFvRmPVg6oqboNHfoH4CQIfNA+HOrZ7Mo7KZP02dC6LjghPQJeBsvXhJod/wnIBg==",+ "cpu": [+ "arm64"+ ],+ "dev": true,+ "libc": [+ "musl"+ ],+ "license": "MPL-2.0",+ "optional": true,+ "os": [+ "linux"+ ],+ "engines": {+ "node": ">= 12.0.0"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/parcel"+ }+ },+ "node_modules/lightningcss-linux-x64-gnu": {+ "version": "1.32.0",+ "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-gnu/-/lightningcss-linux-x64-gnu-1.32.0.tgz",+ "integrity": "sha512-V7Qr52IhZmdKPVr+Vtw8o+WLsQJYCTd8loIfpDaMRWGUZfBOYEJeyJIkqGIDMZPwPx24pUMfwSxxI8phr/MbOA==",+ "cpu": [+ "x64"+ ],+ "dev": true,+ "libc": [+ "glibc"+ ],+ "license": "MPL-2.0",+ "optional": true,+ "os": [+ "linux"+ ],+ "engines": {+ "node": ">= 12.0.0"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/parcel"+ }+ },+ "node_modules/lightningcss-linux-x64-musl": {+ "version": "1.32.0",+ "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-musl/-/lightningcss-linux-x64-musl-1.32.0.tgz",+ "integrity": "sha512-bYcLp+Vb0awsiXg/80uCRezCYHNg1/l3mt0gzHnWV9XP1W5sKa5/TCdGWaR/zBM2PeF/HbsQv/j2URNOiVuxWg==",+ "cpu": [+ "x64"+ ],+ "dev": true,+ "libc": [+ "musl"+ ],+ "license": "MPL-2.0",+ "optional": true,+ "os": [+ "linux"+ ],+ "engines": {+ "node": ">= 12.0.0"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/parcel"+ }+ },+ "node_modules/lightningcss-win32-arm64-msvc": {+ "version": "1.32.0",+ "resolved": "https://registry.npmjs.org/lightningcss-win32-arm64-msvc/-/lightningcss-win32-arm64-msvc-1.32.0.tgz",+ "integrity": "sha512-8SbC8BR40pS6baCM8sbtYDSwEVQd4JlFTOlaD3gWGHfThTcABnNDBda6eTZeqbofalIJhFx0qKzgHJmcPTnGdw==",+ "cpu": [+ "arm64"+ ],+ "dev": true,+ "license": "MPL-2.0",+ "optional": true,+ "os": [+ "win32"+ ],+ "engines": {+ "node": ">= 12.0.0"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/parcel"+ }+ },+ "node_modules/lightningcss-win32-x64-msvc": {+ "version": "1.32.0",+ "resolved": "https://registry.npmjs.org/lightningcss-win32-x64-msvc/-/lightningcss-win32-x64-msvc-1.32.0.tgz",+ "integrity": "sha512-Amq9B/SoZYdDi1kFrojnoqPLxYhQ4Wo5XiL8EVJrVsB8ARoC1PWW6VGtT0WKCemjy8aC+louJnjS7U18x3b06Q==",+ "cpu": [+ "x64"+ ],+ "dev": true,+ "license": "MPL-2.0",+ "optional": true,+ "os": [+ "win32"+ ],+ "engines": {+ "node": ">= 12.0.0"+ },+ "funding": {+ "type": "opencollective",+ "url": "https://opencollective.com/parcel"+ }+ },+ "node_modules/magic-string": {+ "version": "0.30.21",+ "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.21.tgz",+ "integrity": "sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "@jridgewell/sourcemap-codec": "^1.5.5"+ }+ },+ "node_modules/nanoid": {+ "version": "3.3.12",+ "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.12.tgz",+ "integrity": "sha512-ZB9RH/39qpq5Vu6Y+NmUaFhQR6pp+M2Xt76XBnEwDaGcVAqhlvxrl3B2bKS5D3NH3QR76v3aSrKaF/Kiy7lEtQ==",+ "dev": true,+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/ai"+ }+ ],+ "license": "MIT",+ "bin": {+ "nanoid": "bin/nanoid.cjs"+ },+ "engines": {+ "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1"+ }+ },+ "node_modules/obug": {+ "version": "2.1.1",+ "resolved": "https://registry.npmjs.org/obug/-/obug-2.1.1.tgz",+ "integrity": "sha512-uTqF9MuPraAQ+IsnPf366RG4cP9RtUi7MLO1N3KEc+wb0a6yKpeL0lmk2IB1jY5KHPAlTc6T/JRdC/YqxHNwkQ==",+ "dev": true,+ "funding": [+ "https://github.com/sponsors/sxzz",+ "https://opencollective.com/debug"+ ],+ "license": "MIT"+ },+ "node_modules/on-exit-leak-free": {+ "version": "2.1.2",+ "resolved": "https://registry.npmjs.org/on-exit-leak-free/-/on-exit-leak-free-2.1.2.tgz",+ "integrity": "sha512-0eJJY6hXLGf1udHwfNftBqH+g73EU4B504nZeKpz1sYRKafAghwxEJunB2O7rDZkL4PGfsMVnTXZ2EjibbqcsA==",+ "license": "MIT",+ "engines": {+ "node": ">=14.0.0"+ }+ },+ "node_modules/once": {+ "version": "1.4.0",+ "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",+ "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==",+ "license": "ISC",+ "dependencies": {+ "wrappy": "1"+ }+ },+ "node_modules/pathe": {+ "version": "2.0.3",+ "resolved": "https://registry.npmjs.org/pathe/-/pathe-2.0.3.tgz",+ "integrity": "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==",+ "dev": true,+ "license": "MIT"+ },+ "node_modules/picocolors": {+ "version": "1.1.1",+ "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz",+ "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==",+ "dev": true,+ "license": "ISC"+ },+ "node_modules/picomatch": {+ "version": "4.0.4",+ "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.4.tgz",+ "integrity": "sha512-QP88BAKvMam/3NxH6vj2o21R6MjxZUAd6nlwAS/pnGvN9IVLocLHxGYIzFhg6fUQ+5th6P4dv4eW9jX3DSIj7A==",+ "dev": true,+ "license": "MIT",+ "engines": {+ "node": ">=12"+ },+ "funding": {+ "url": "https://github.com/sponsors/jonschlinkert"+ }+ },+ "node_modules/pino": {+ "version": "10.3.1",+ "resolved": "https://registry.npmjs.org/pino/-/pino-10.3.1.tgz",+ "integrity": "sha512-r34yH/GlQpKZbU1BvFFqOjhISRo1MNx1tWYsYvmj6KIRHSPMT2+yHOEb1SG6NMvRoHRF0a07kCOox/9yakl1vg==",+ "license": "MIT",+ "dependencies": {+ "@pinojs/redact": "^0.4.0",+ "atomic-sleep": "^1.0.0",+ "on-exit-leak-free": "^2.1.0",+ "pino-abstract-transport": "^3.0.0",+ "pino-std-serializers": "^7.0.0",+ "process-warning": "^5.0.0",+ "quick-format-unescaped": "^4.0.3",+ "real-require": "^0.2.0",+ "safe-stable-stringify": "^2.3.1",+ "sonic-boom": "^4.0.1",+ "thread-stream": "^4.0.0"+ },+ "bin": {+ "pino": "bin.js"+ }+ },+ "node_modules/pino-abstract-transport": {+ "version": "3.0.0",+ "resolved": "https://registry.npmjs.org/pino-abstract-transport/-/pino-abstract-transport-3.0.0.tgz",+ "integrity": "sha512-wlfUczU+n7Hy/Ha5j9a/gZNy7We5+cXp8YL+X+PG8S0KXxw7n/JXA3c46Y0zQznIJ83URJiwy7Lh56WLokNuxg==",+ "license": "MIT",+ "dependencies": {+ "split2": "^4.0.0"+ }+ },+ "node_modules/pino-std-serializers": {+ "version": "7.1.0",+ "resolved": "https://registry.npmjs.org/pino-std-serializers/-/pino-std-serializers-7.1.0.tgz",+ "integrity": "sha512-BndPH67/JxGExRgiX1dX0w1FvZck5Wa4aal9198SrRhZjH3GxKQUKIBnYJTdj2HDN3UQAS06HlfcSbQj2OHmaw==",+ "license": "MIT"+ },+ "node_modules/postcss": {+ "version": "8.5.13",+ "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.13.tgz",+ "integrity": "sha512-qif0+jGGZoLWdHey3UFHHWP0H7Gbmsk8T5VEqyYFbWqPr1XqvLGBbk/sl8V5exGmcYJklJOhOQq1pV9IcsiFag==",+ "dev": true,+ "funding": [+ {+ "type": "opencollective",+ "url": "https://opencollective.com/postcss/"+ },+ {+ "type": "tidelift",+ "url": "https://tidelift.com/funding/github/npm/postcss"+ },+ {+ "type": "github",+ "url": "https://github.com/sponsors/ai"+ }+ ],+ "license": "MIT",+ "dependencies": {+ "nanoid": "^3.3.11",+ "picocolors": "^1.1.1",+ "source-map-js": "^1.2.1"+ },+ "engines": {+ "node": "^10 || ^12 || >=14"+ }+ },+ "node_modules/process-warning": {+ "version": "5.0.0",+ "resolved": "https://registry.npmjs.org/process-warning/-/process-warning-5.0.0.tgz",+ "integrity": "sha512-a39t9ApHNx2L4+HBnQKqxxHNs1r7KF+Intd8Q/g1bUh6q0WIp9voPXJ/x0j+ZL45KF1pJd9+q2jLIRMfvEshkA==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT"+ },+ "node_modules/quick-format-unescaped": {+ "version": "4.0.4",+ "resolved": "https://registry.npmjs.org/quick-format-unescaped/-/quick-format-unescaped-4.0.4.tgz",+ "integrity": "sha512-tYC1Q1hgyRuHgloV/YXs2w15unPVh8qfu/qCTfhTYamaw7fyhumKa2yGpdSo87vY32rIclj+4fWYQXUMs9EHvg==",+ "license": "MIT"+ },+ "node_modules/readable-stream": {+ "version": "3.6.2",+ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz",+ "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==",+ "license": "MIT",+ "dependencies": {+ "inherits": "^2.0.3",+ "string_decoder": "^1.1.1",+ "util-deprecate": "^1.0.1"+ },+ "engines": {+ "node": ">= 6"+ }+ },+ "node_modules/real-require": {+ "version": "0.2.0",+ "resolved": "https://registry.npmjs.org/real-require/-/real-require-0.2.0.tgz",+ "integrity": "sha512-57frrGM/OCTLqLOAh0mhVA9VBMHd+9U7Zb2THMGdBUoZVOtGbJzjxsYGDJ3A9AYYCP4hn6y1TVbaOfzWtm5GFg==",+ "license": "MIT",+ "engines": {+ "node": ">= 12.13.0"+ }+ },+ "node_modules/require-from-string": {+ "version": "2.0.2",+ "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz",+ "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==",+ "license": "MIT",+ "engines": {+ "node": ">=0.10.0"+ }+ },+ "node_modules/ret": {+ "version": "0.5.0",+ "resolved": "https://registry.npmjs.org/ret/-/ret-0.5.0.tgz",+ "integrity": "sha512-I1XxrZSQ+oErkRR4jYbAyEEu2I0avBvvMM5JN+6EBprOGRCs63ENqZ3vjavq8fBw2+62G5LF5XelKwuJpcvcxw==",+ "license": "MIT",+ "engines": {+ "node": ">=10"+ }+ },+ "node_modules/reusify": {+ "version": "1.1.0",+ "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.1.0.tgz",+ "integrity": "sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==",+ "license": "MIT",+ "engines": {+ "iojs": ">=1.0.0",+ "node": ">=0.10.0"+ }+ },+ "node_modules/rfdc": {+ "version": "1.4.1",+ "resolved": "https://registry.npmjs.org/rfdc/-/rfdc-1.4.1.tgz",+ "integrity": "sha512-q1b3N5QkRUWUl7iyylaaj3kOpIT0N2i9MqIEQXP73GVsN9cw3fdx8X63cEmWhJGi2PPCF23Ijp7ktmd39rawIA==",+ "license": "MIT"+ },+ "node_modules/rolldown": {+ "version": "1.0.0-rc.17",+ "resolved": "https://registry.npmjs.org/rolldown/-/rolldown-1.0.0-rc.17.tgz",+ "integrity": "sha512-ZrT53oAKrtA4+YtBWPQbtPOxIbVDbxT0orcYERKd63VJTF13zPcgXTvD4843L8pcsI7M6MErt8QtON6lrB9tyA==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "@oxc-project/types": "=0.127.0",+ "@rolldown/pluginutils": "1.0.0-rc.17"+ },+ "bin": {+ "rolldown": "bin/cli.mjs"+ },+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ },+ "optionalDependencies": {+ "@rolldown/binding-android-arm64": "1.0.0-rc.17",+ "@rolldown/binding-darwin-arm64": "1.0.0-rc.17",+ "@rolldown/binding-darwin-x64": "1.0.0-rc.17",+ "@rolldown/binding-freebsd-x64": "1.0.0-rc.17",+ "@rolldown/binding-linux-arm-gnueabihf": "1.0.0-rc.17",+ "@rolldown/binding-linux-arm64-gnu": "1.0.0-rc.17",+ "@rolldown/binding-linux-arm64-musl": "1.0.0-rc.17",+ "@rolldown/binding-linux-ppc64-gnu": "1.0.0-rc.17",+ "@rolldown/binding-linux-s390x-gnu": "1.0.0-rc.17",+ "@rolldown/binding-linux-x64-gnu": "1.0.0-rc.17",+ "@rolldown/binding-linux-x64-musl": "1.0.0-rc.17",+ "@rolldown/binding-openharmony-arm64": "1.0.0-rc.17",+ "@rolldown/binding-wasm32-wasi": "1.0.0-rc.17",+ "@rolldown/binding-win32-arm64-msvc": "1.0.0-rc.17",+ "@rolldown/binding-win32-x64-msvc": "1.0.0-rc.17"+ }+ },+ "node_modules/safe-buffer": {+ "version": "5.2.1",+ "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz",+ "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/feross"+ },+ {+ "type": "patreon",+ "url": "https://www.patreon.com/feross"+ },+ {+ "type": "consulting",+ "url": "https://feross.org/support"+ }+ ],+ "license": "MIT"+ },+ "node_modules/safe-regex2": {+ "version": "5.1.1",+ "resolved": "https://registry.npmjs.org/safe-regex2/-/safe-regex2-5.1.1.tgz",+ "integrity": "sha512-mOSBvHGDZMuIEZMdOz/aCEYDCv0E7nfcNsIhUF+/P+xC7Hyf3FkvymqgPbg9D1EdSGu+uKbJgy09K/RKKc7kJA==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "MIT",+ "dependencies": {+ "ret": "~0.5.0"+ },+ "bin": {+ "safe-regex2": "bin/safe-regex2.js"+ }+ },+ "node_modules/safe-stable-stringify": {+ "version": "2.5.0",+ "resolved": "https://registry.npmjs.org/safe-stable-stringify/-/safe-stable-stringify-2.5.0.tgz",+ "integrity": "sha512-b3rppTKm9T+PsVCBEOUR46GWI7fdOs00VKZ1+9c1EWDaDMvjQc6tUwuFyIprgGgTcWoVHSKrU8H31ZHA2e0RHA==",+ "license": "MIT",+ "engines": {+ "node": ">=10"+ }+ },+ "node_modules/secure-json-parse": {+ "version": "4.1.0",+ "resolved": "https://registry.npmjs.org/secure-json-parse/-/secure-json-parse-4.1.0.tgz",+ "integrity": "sha512-l4KnYfEyqYJxDwlNVyRfO2E4NTHfMKAWdUuA8J0yve2Dz/E/PdBepY03RvyJpssIpRFwJoCD55wA+mEDs6ByWA==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/fastify"+ },+ {+ "type": "opencollective",+ "url": "https://opencollective.com/fastify"+ }+ ],+ "license": "BSD-3-Clause"+ },+ "node_modules/semver": {+ "version": "7.7.4",+ "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.4.tgz",+ "integrity": "sha512-vFKC2IEtQnVhpT78h1Yp8wzwrf8CM+MzKMHGJZfBtzhZNycRFnXsHk6E5TxIkkMsgNS7mdX3AGB7x2QM2di4lA==",+ "license": "ISC",+ "bin": {+ "semver": "bin/semver.js"+ },+ "engines": {+ "node": ">=10"+ }+ },+ "node_modules/set-cookie-parser": {+ "version": "2.7.2",+ "resolved": "https://registry.npmjs.org/set-cookie-parser/-/set-cookie-parser-2.7.2.tgz",+ "integrity": "sha512-oeM1lpU/UvhTxw+g3cIfxXHyJRc/uidd3yK1P242gzHds0udQBYzs3y8j4gCCW+ZJ7ad0yctld8RYO+bdurlvw==",+ "license": "MIT"+ },+ "node_modules/siginfo": {+ "version": "2.0.0",+ "resolved": "https://registry.npmjs.org/siginfo/-/siginfo-2.0.0.tgz",+ "integrity": "sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==",+ "dev": true,+ "license": "ISC"+ },+ "node_modules/sonic-boom": {+ "version": "4.2.1",+ "resolved": "https://registry.npmjs.org/sonic-boom/-/sonic-boom-4.2.1.tgz",+ "integrity": "sha512-w6AxtubXa2wTXAUsZMMWERrsIRAdrK0Sc+FUytWvYAhBJLyuI4llrMIC1DtlNSdI99EI86KZum2MMq3EAZlF9Q==",+ "license": "MIT",+ "dependencies": {+ "atomic-sleep": "^1.0.0"+ }+ },+ "node_modules/source-map-js": {+ "version": "1.2.1",+ "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz",+ "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==",+ "dev": true,+ "license": "BSD-3-Clause",+ "engines": {+ "node": ">=0.10.0"+ }+ },+ "node_modules/split2": {+ "version": "4.2.0",+ "resolved": "https://registry.npmjs.org/split2/-/split2-4.2.0.tgz",+ "integrity": "sha512-UcjcJOWknrNkF6PLX83qcHM6KHgVKNkV62Y8a5uYDVv9ydGQVwAHMKqHdJje1VTWpljG0WYpCDhrCdAOYH4TWg==",+ "license": "ISC",+ "engines": {+ "node": ">= 10.x"+ }+ },+ "node_modules/stackback": {+ "version": "0.0.2",+ "resolved": "https://registry.npmjs.org/stackback/-/stackback-0.0.2.tgz",+ "integrity": "sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==",+ "dev": true,+ "license": "MIT"+ },+ "node_modules/std-env": {+ "version": "4.1.0",+ "resolved": "https://registry.npmjs.org/std-env/-/std-env-4.1.0.tgz",+ "integrity": "sha512-Rq7ybcX2RuC55r9oaPVEW7/xu3tj8u4GeBYHBWCychFtzMIr86A7e3PPEBPT37sHStKX3+TiX/Fr/ACmJLVlLQ==",+ "dev": true,+ "license": "MIT"+ },+ "node_modules/stream-shift": {+ "version": "1.0.3",+ "resolved": "https://registry.npmjs.org/stream-shift/-/stream-shift-1.0.3.tgz",+ "integrity": "sha512-76ORR0DO1o1hlKwTbi/DM3EXWGf3ZJYO8cXX5RJwnul2DEg2oyoZyjLNoQM8WsvZiFKCRfC1O0J7iCvie3RZmQ==",+ "license": "MIT"+ },+ "node_modules/string_decoder": {+ "version": "1.3.0",+ "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz",+ "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==",+ "license": "MIT",+ "dependencies": {+ "safe-buffer": "~5.2.0"+ }+ },+ "node_modules/thread-stream": {+ "version": "4.0.0",+ "resolved": "https://registry.npmjs.org/thread-stream/-/thread-stream-4.0.0.tgz",+ "integrity": "sha512-4iMVL6HAINXWf1ZKZjIPcz5wYaOdPhtO8ATvZ+Xqp3BTdaqtAwQkNmKORqcIo5YkQqGXq5cwfswDwMqqQNrpJA==",+ "license": "MIT",+ "dependencies": {+ "real-require": "^0.2.0"+ },+ "engines": {+ "node": ">=20"+ }+ },+ "node_modules/tinybench": {+ "version": "2.9.0",+ "resolved": "https://registry.npmjs.org/tinybench/-/tinybench-2.9.0.tgz",+ "integrity": "sha512-0+DUvqWMValLmha6lr4kD8iAMK1HzV0/aKnCtWb9v9641TnP/MFb7Pc2bxoxQjTXAErryXVgUOfv2YqNllqGeg==",+ "dev": true,+ "license": "MIT"+ },+ "node_modules/tinyexec": {+ "version": "1.1.2",+ "resolved": "https://registry.npmjs.org/tinyexec/-/tinyexec-1.1.2.tgz",+ "integrity": "sha512-dAqSqE/RabpBKI8+h26GfLq6Vb3JVXs30XYQjdMjaj/c2tS8IYYMbIzP599KtRj7c57/wYApb3QjgRgXmrCukA==",+ "dev": true,+ "license": "MIT",+ "engines": {+ "node": ">=18"+ }+ },+ "node_modules/tinyglobby": {+ "version": "0.2.16",+ "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.16.tgz",+ "integrity": "sha512-pn99VhoACYR8nFHhxqix+uvsbXineAasWm5ojXoN8xEwK5Kd3/TrhNn1wByuD52UxWRLy8pu+kRMniEi6Eq9Zg==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "fdir": "^6.5.0",+ "picomatch": "^4.0.4"+ },+ "engines": {+ "node": ">=12.0.0"+ },+ "funding": {+ "url": "https://github.com/sponsors/SuperchupuDev"+ }+ },+ "node_modules/tinyrainbow": {+ "version": "3.1.0",+ "resolved": "https://registry.npmjs.org/tinyrainbow/-/tinyrainbow-3.1.0.tgz",+ "integrity": "sha512-Bf+ILmBgretUrdJxzXM0SgXLZ3XfiaUuOj/IKQHuTXip+05Xn+uyEYdVg0kYDipTBcLrCVyUzAPz7QmArb0mmw==",+ "dev": true,+ "license": "MIT",+ "engines": {+ "node": ">=14.0.0"+ }+ },+ "node_modules/toad-cache": {+ "version": "3.7.0",+ "resolved": "https://registry.npmjs.org/toad-cache/-/toad-cache-3.7.0.tgz",+ "integrity": "sha512-/m8M+2BJUpoJdgAHoG+baCwBT+tf2VraSfkBgl0Y00qIWt41DJ8R5B8nsEw0I58YwF5IZH6z24/2TobDKnqSWw==",+ "license": "MIT",+ "engines": {+ "node": ">=12"+ }+ },+ "node_modules/tslib": {+ "version": "2.8.1",+ "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz",+ "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==",+ "dev": true,+ "license": "0BSD",+ "optional": true+ },+ "node_modules/util-deprecate": {+ "version": "1.0.2",+ "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",+ "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==",+ "license": "MIT"+ },+ "node_modules/vite": {+ "version": "8.0.10",+ "resolved": "https://registry.npmjs.org/vite/-/vite-8.0.10.tgz",+ "integrity": "sha512-rZuUu9j6J5uotLDs+cAA4O5H4K1SfPliUlQwqa6YEwSrWDZzP4rhm00oJR5snMewjxF5V/K3D4kctsUTsIU9Mw==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "lightningcss": "^1.32.0",+ "picomatch": "^4.0.4",+ "postcss": "^8.5.10",+ "rolldown": "1.0.0-rc.17",+ "tinyglobby": "^0.2.16"+ },+ "bin": {+ "vite": "bin/vite.js"+ },+ "engines": {+ "node": "^20.19.0 || >=22.12.0"+ },+ "funding": {+ "url": "https://github.com/vitejs/vite?sponsor=1"+ },+ "optionalDependencies": {+ "fsevents": "~2.3.3"+ },+ "peerDependencies": {+ "@types/node": "^20.19.0 || >=22.12.0",+ "@vitejs/devtools": "^0.1.0",+ "esbuild": "^0.27.0 || ^0.28.0",+ "jiti": ">=1.21.0",+ "less": "^4.0.0",+ "sass": "^1.70.0",+ "sass-embedded": "^1.70.0",+ "stylus": ">=0.54.8",+ "sugarss": "^5.0.0",+ "terser": "^5.16.0",+ "tsx": "^4.8.1",+ "yaml": "^2.4.2"+ },+ "peerDependenciesMeta": {+ "@types/node": {+ "optional": true+ },+ "@vitejs/devtools": {+ "optional": true+ },+ "esbuild": {+ "optional": true+ },+ "jiti": {+ "optional": true+ },+ "less": {+ "optional": true+ },+ "sass": {+ "optional": true+ },+ "sass-embedded": {+ "optional": true+ },+ "stylus": {+ "optional": true+ },+ "sugarss": {+ "optional": true+ },+ "terser": {+ "optional": true+ },+ "tsx": {+ "optional": true+ },+ "yaml": {+ "optional": true+ }+ }+ },+ "node_modules/vitest": {+ "version": "4.1.5",+ "resolved": "https://registry.npmjs.org/vitest/-/vitest-4.1.5.tgz",+ "integrity": "sha512-9Xx1v3/ih3m9hN+SbfkUyy0JAs72ap3r7joc87XL6jwF0jGg6mFBvQ1SrwaX+h8BlkX6Hz9shdd1uo6AF+ZGpg==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "@vitest/expect": "4.1.5",+ "@vitest/mocker": "4.1.5",+ "@vitest/pretty-format": "4.1.5",+ "@vitest/runner": "4.1.5",+ "@vitest/snapshot": "4.1.5",+ "@vitest/spy": "4.1.5",+ "@vitest/utils": "4.1.5",+ "es-module-lexer": "^2.0.0",+ "expect-type": "^1.3.0",+ "magic-string": "^0.30.21",+ "obug": "^2.1.1",+ "pathe": "^2.0.3",+ "picomatch": "^4.0.3",+ "std-env": "^4.0.0-rc.1",+ "tinybench": "^2.9.0",+ "tinyexec": "^1.0.2",+ "tinyglobby": "^0.2.15",+ "tinyrainbow": "^3.1.0",+ "vite": "^6.0.0 || ^7.0.0 || ^8.0.0",+ "why-is-node-running": "^2.3.0"+ },+ "bin": {+ "vitest": "vitest.mjs"+ },+ "engines": {+ "node": "^20.0.0 || ^22.0.0 || >=24.0.0"+ },+ "funding": {+ "url": "https://opencollective.com/vitest"+ },+ "peerDependencies": {+ "@edge-runtime/vm": "*",+ "@opentelemetry/api": "^1.9.0",+ "@types/node": "^20.0.0 || ^22.0.0 || >=24.0.0",+ "@vitest/browser-playwright": "4.1.5",+ "@vitest/browser-preview": "4.1.5",+ "@vitest/browser-webdriverio": "4.1.5",+ "@vitest/coverage-istanbul": "4.1.5",+ "@vitest/coverage-v8": "4.1.5",+ "@vitest/ui": "4.1.5",+ "happy-dom": "*",+ "jsdom": "*",+ "vite": "^6.0.0 || ^7.0.0 || ^8.0.0"+ },+ "peerDependenciesMeta": {+ "@edge-runtime/vm": {+ "optional": true+ },+ "@opentelemetry/api": {+ "optional": true+ },+ "@types/node": {+ "optional": true+ },+ "@vitest/browser-playwright": {+ "optional": true+ },+ "@vitest/browser-preview": {+ "optional": true+ },+ "@vitest/browser-webdriverio": {+ "optional": true+ },+ "@vitest/coverage-istanbul": {+ "optional": true+ },+ "@vitest/coverage-v8": {+ "optional": true+ },+ "@vitest/ui": {+ "optional": true+ },+ "happy-dom": {+ "optional": true+ },+ "jsdom": {+ "optional": true+ },+ "vite": {+ "optional": false+ }+ }+ },+ "node_modules/why-is-node-running": {+ "version": "2.3.0",+ "resolved": "https://registry.npmjs.org/why-is-node-running/-/why-is-node-running-2.3.0.tgz",+ "integrity": "sha512-hUrmaWBdVDcxvYqnyh09zunKzROWjbZTiNy8dBEjkS7ehEDQibXJ7XvlmtbwuTclUiIyN+CyXQD4Vmko8fNm8w==",+ "dev": true,+ "license": "MIT",+ "dependencies": {+ "siginfo": "^2.0.0",+ "stackback": "0.0.2"+ },+ "bin": {+ "why-is-node-running": "cli.js"+ },+ "engines": {+ "node": ">=8"+ }+ },+ "node_modules/wrappy": {+ "version": "1.0.2",+ "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",+ "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==",+ "license": "ISC"+ },+ "node_modules/ws": {+ "version": "8.20.0",+ "resolved": "https://registry.npmjs.org/ws/-/ws-8.20.0.tgz",+ "integrity": "sha512-sAt8BhgNbzCtgGbt2OxmpuryO63ZoDk/sqaB/znQm94T4fCEsy/yV+7CdC1kJhOU9lboAEU7R3kquuycDoibVA==",+ "license": "MIT",+ "engines": {+ "node": ">=10.0.0"+ },+ "peerDependencies": {+ "bufferutil": "^4.0.1",+ "utf-8-validate": ">=5.0.2"+ },+ "peerDependenciesMeta": {+ "bufferutil": {+ "optional": true+ },+ "utf-8-validate": {+ "optional": true+ }+ }+ }+ }+}diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/package.json b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/package.jsonnew file mode 100644index 00000000..65c2c433--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/package.json@@ -0,0 +1,24 @@+{+ "name": "twilio-realtime-translation-demo",+ "version": "0.1.0",+ "private": true,+ "type": "module",+ "engines": {+ "node": ">=20"+ },+ "scripts": {+ "start": "node src/server.js",+ "dev": "node --watch src/server.js",+ "test": "vitest run"+ },+ "dependencies": {+ "@fastify/formbody": "^8.0.2",+ "@fastify/websocket": "^11.0.2",+ "dotenv": "^16.4.7",+ "fastify": "^5.2.1",+ "ws": "^8.18.0"+ },+ "devDependencies": {+ "vitest": "^4.1.5"+ }+}diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/audio.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/audio.jsnew file mode 100644index 00000000..3fa018f7--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/audio.js@@ -0,0 +1,105 @@+const MULAW_BIAS = 0x84;+const MULAW_CLIP = 32635;++export function base64ToInt16(base64) {+ const bytes = Buffer.from(base64, "base64");+ const samples = new Int16Array(Math.floor(bytes.length / 2));+ for (let index = 0; index < samples.length; index += 1) {+ samples[index] = bytes.readInt16LE(index * 2);+ }+ return samples;+}++export function int16ToBase64(samples) {+ const bytes = Buffer.alloc(samples.length * 2);+ for (let index = 0; index < samples.length; index += 1) {+ bytes.writeInt16LE(clampInt16(samples[index]), index * 2);+ }+ return bytes.toString("base64");+}++export function mulawBase64ToPcm16(base64) {+ const bytes = Buffer.from(base64, "base64");+ const samples = new Int16Array(bytes.length);+ for (let index = 0; index < bytes.length; index += 1) {+ samples[index] = mulawToPcm16(bytes[index]);+ }+ return samples;+}++export function pcm16ToMulawBase64(samples) {+ const bytes = Buffer.alloc(samples.length);+ for (let index = 0; index < samples.length; index += 1) {+ bytes[index] = pcm16ToMulaw(samples[index]);+ }+ return bytes.toString("base64");+}++export function resampleLinear(samples, fromRate, toRate) {+ if (fromRate === toRate) {+ return new Int16Array(samples);+ }++ const outputLength = Math.max(1, Math.round((samples.length * toRate) / fromRate));+ const output = new Int16Array(outputLength);+ const ratio = fromRate / toRate;++ for (let index = 0; index < output.length; index += 1) {+ const sourceIndex = index * ratio;+ const leftIndex = Math.floor(sourceIndex);+ const rightIndex = Math.min(samples.length - 1, leftIndex + 1);+ const fraction = sourceIndex - leftIndex;+ const left = samples[leftIndex] ?? 0;+ const right = samples[rightIndex] ?? left;+ output[index] = clampInt16(Math.round(left + (right - left) * fraction));+ }++ return output;+}++export function twilioMediaToRealtimeAudio(payload) {+ const pcm8k = mulawBase64ToPcm16(payload);+ return int16ToBase64(resampleLinear(pcm8k, 8000, 24000));+}++export function realtimeAudioToTwilioMedia(delta) {+ const pcm24k = base64ToInt16(delta);+ return pcm16ToMulawBase64(resampleLinear(pcm24k, 24000, 8000));+}++function pcm16ToMulaw(sample) {+ let pcm = clampInt16(sample);+ let sign = 0;++ if (pcm < 0) {+ pcm = -pcm;+ sign = 0x80;+ }++ pcm = Math.min(MULAW_CLIP, pcm) + MULAW_BIAS;++ let exponent = 7;+ for (let mask = 0x4000; (pcm & mask) === 0 && exponent > 0; mask >>= 1) {+ exponent -= 1;+ }++ const mantissa = (pcm >> (exponent + 3)) & 0x0f;+ return ~(sign | (exponent << 4) | mantissa) & 0xff;+}++function mulawToPcm16(byte) {+ const value = ~byte & 0xff;+ const sign = value & 0x80;+ const exponent = (value >> 4) & 0x07;+ const mantissa = value & 0x0f;+ let sample = ((mantissa << 3) + MULAW_BIAS) << exponent;+ sample -= MULAW_BIAS;+ return sign ? -sample : sample;+}++function clampInt16(value) {+ if (!Number.isFinite(value)) {+ return 0;+ }+ return Math.max(-32768, Math.min(32767, Math.trunc(value)));+}diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/languages.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/languages.jsnew file mode 100644index 00000000..751f65a1--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/languages.js@@ -0,0 +1,127 @@+export const supportedLanguages = [+ { code: "es", label: "Spanish", aliases: ["spanish"] },+ { code: "pt", label: "Portuguese", aliases: ["portuguese"] },+ { code: "fr", label: "French", aliases: ["french"] },+ { code: "ja", label: "Japanese", aliases: ["japanese"] },+ { code: "ru", label: "Russian", aliases: ["russian"] },+ {+ code: "zh",+ label: "Chinese",+ aliases: ["chinese", "mandarin", "mandarin chinese"],+ },+ { code: "de", label: "German", aliases: ["german"] },+ { code: "ko", label: "Korean", aliases: ["korean"] },+ { code: "hi", label: "Hindi", aliases: ["hindi"] },+ {+ code: "id",+ label: "Indonesian",+ aliases: ["indonesian", "bahasa indonesia"],+ },+ { code: "vi", label: "Vietnamese", aliases: ["vietnamese"] },+ { code: "it", label: "Italian", aliases: ["italian"] },+ { code: "en", label: "English", aliases: ["english"] },+];++const unsupportedLanguageNames = [+ "Afrikaans",+ "Arabic",+ "Armenian",+ "Azerbaijani",+ "Bengali",+ "Bulgarian",+ "Catalan",+ "Croatian",+ "Czech",+ "Danish",+ "Dutch",+ "Finnish",+ "Greek",+ "Hebrew",+ "Hungarian",+ "Malay",+ "Norwegian",+ "Persian",+ "Polish",+ "Romanian",+ "Swahili",+ "Swedish",+ "Tagalog",+ "Tamil",+ "Thai",+ "Turkish",+ "Ukrainian",+ "Urdu",+];++export function languageForDigit(digit) {+ const index = Number.parseInt(digit, 10) - 1;+ return publicLanguage(supportedLanguages[index]);+}++export function languageForSpeech(speech) {+ const selection = classifyLanguageSelection(speech);+ return selection.status === "supported" ? selection.language : null;+}++export function classifyLanguageSelection(speech) {+ const normalized = normalizeSpeech(speech);+ if (!normalized) {+ return { status: "missing" };+ }++ const match = supportedLanguages.find((language) =>+ language.aliases.some((alias) => includesPhrase(normalized, alias)),+ );+ if (match) {+ return { status: "supported", language: publicLanguage(match) };+ }++ const unsupported = unsupportedLanguageNames.find((language) =>+ includesPhrase(normalized, language),+ );+ if (unsupported) {+ return { status: "unsupported", language: unsupported };+ }++ return { status: "unknown" };+}++export function languageLabelForCode(code) {+ return supportedLanguages.find((language) => language.code === code)?.label ?? code;+}++export function languageMenuText() {+ return (+ "Please say the language you want to hear. Supported languages are " ++ supportedLanguageListText() ++ "."+ );+}++export function supportedLanguageListText() {+ const labels = supportedLanguages.map((language) => language.label);+ return labels.slice(0, -1).join(", ") + ", or " + labels[labels.length - 1];+}++function normalizeSpeech(speech) {+ return String(speech ?? "")+ .toLowerCase()+ .replace(/[^a-z\s]/g, " ")+ .replace(/\s+/g, " ")+ .trim();+}++function includesPhrase(normalized, phrase) {+ const normalizedPhrase = normalizeSpeech(phrase);+ return new RegExp("(^|\\s)" + escapeRegExp(normalizedPhrase) + "($|\\s)").test(+ normalized,+ );+}++function publicLanguage(language) {+ return language ? { code: language.code, label: language.label } : null;+}++function escapeRegExp(value) {+ return value.replace(/[.*+?^$(){}|[\]\\]/g, "\\$&");+}diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/realtime-translation.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/realtime-translation.jsnew file mode 100644index 00000000..76fc224f--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/realtime-translation.js@@ -0,0 +1,211 @@+import WebSocket from "ws";+import {+ realtimeAudioToTwilioMedia,+ twilioMediaToRealtimeAudio,+} from "./audio.js";++export const DEFAULT_TRANSLATION_MODEL = "gpt-realtime-translate";+export const DEFAULT_INPUT_TRANSCRIPTION_MODEL = "gpt-realtime-whisper";+export const TRANSLATION_ENDPOINT =+ "wss://api.openai.com/v1/realtime/translations";++const INPUT_TRANSCRIPT_EVENTS = new Set([+ "conversation.item.input_audio_transcription.delta",+ "conversation.item.input_audio_transcription.completed",+ "session.input_transcript.delta",+ "session.input_transcript.completed",+ "session.input_transcript.done",+]);++const OUTPUT_TRANSCRIPT_EVENTS = new Set([+ "session.output_transcript.delta",+ "session.output_transcript.completed",+ "session.output_transcript.done",+ "response.output_audio_transcript.delta",+ "response.output_audio_transcript.done",+]);++export function buildTranslationUrl(model = DEFAULT_TRANSLATION_MODEL) {+ const url = new URL(TRANSLATION_ENDPOINT);+ url.searchParams.set("model", model);+ return url.toString();+}++export function buildSessionUpdate(targetLanguage) {+ return {+ type: "session.update",+ session: {+ audio: {+ input: {+ transcription: { model: DEFAULT_INPUT_TRANSCRIPTION_MODEL },+ noise_reduction: { type: "near_field" },+ },+ output: { language: targetLanguage },+ },+ },+ };+}++export function createRealtimeTranslationBridge({+ apiKey,+ model = DEFAULT_TRANSLATION_MODEL,+ sourceLabel,+ target,+ targetLanguage,+ WebSocketImpl = WebSocket,+ logger = console,+}) {+ if (!apiKey) {+ throw new Error("OPENAI_API_KEY is required.");+ }+ if (!targetLanguage) {+ throw new Error("targetLanguage is required.");+ }++ const socket = new WebSocketImpl(buildTranslationUrl(model), {+ headers: {+ Authorization: `Bearer ${apiKey}`,+ },+ });+ const pendingEvents = [];++ const sendEvent = (event) => {+ const payload = JSON.stringify(event);+ if (socket.readyState === 1) {+ socket.send(payload);+ return;+ }+ pendingEvents.push(payload);+ };++ socket.on("open", () => {+ socket.send(JSON.stringify(buildSessionUpdate(targetLanguage)));+ while (pendingEvents.length > 0) {+ socket.send(pendingEvents.shift());+ }+ logger.info?.(`[translation:${sourceLabel}] connected -> ${targetLanguage}`);+ });++ socket.on("message", (data) => {+ const text = Buffer.isBuffer(data) ? data.toString("utf8") : String(data);+ let event;+ try {+ event = JSON.parse(text);+ } catch {+ logger.warn?.(`[translation:${sourceLabel}] non-JSON message`, text);+ return;+ }++ if (event.type === "session.output_audio.delta" && typeof event.delta === "string") {+ target.sendTwilioMedia(realtimeAudioToTwilioMedia(event.delta));+ return;+ }++ if (+ logTranscriptEvent({+ direction: transcriptDirection(event.type),+ event,+ logger,+ sourceLabel,+ targetLanguage,+ })+ ) {+ return;+ }++ if (event.type === "error") {+ logger.error?.(`[translation:${sourceLabel}]`, event.error ?? event);+ }+ });++ socket.on("close", () => {+ logger.info?.(`[translation:${sourceLabel}] closed`);+ });++ socket.on("error", (error) => {+ logger.error?.(`[translation:${sourceLabel}] websocket error`, error);+ });++ return {+ sendTwilioMedia(payload) {+ if (!payload) {+ return;+ }+ sendEvent({+ type: "session.input_audio_buffer.append",+ audio: twilioMediaToRealtimeAudio(payload),+ });+ },+ close() {+ socket.close();+ },+ };+}++function transcriptDirection(eventType) {+ if (INPUT_TRANSCRIPT_EVENTS.has(eventType)) {+ return "input";+ }+ if (OUTPUT_TRANSCRIPT_EVENTS.has(eventType)) {+ return "output";+ }+ return null;+}++function logTranscriptEvent({+ direction,+ event,+ logger,+ sourceLabel,+ targetLanguage,+}) {+ if (!direction) {+ return false;+ }++ const text = transcriptText(event);+ if (!text) {+ return false;+ }++ logger.info?.(+ "[translation-transcript] " ++ JSON.stringify({+ callSid: sourceLabel,+ direction,+ phase: transcriptPhase(event.type),+ targetLanguage,+ eventType: event.type,+ itemId: event.item_id,+ responseId: event.response_id,+ text,+ }),+ );+ return true;+}++function transcriptText(event) {+ if (typeof event.delta === "string") {+ return event.delta;+ }+ if (typeof event.transcript === "string") {+ return event.transcript;+ }+ if (typeof event.text === "string") {+ return event.text;+ }+ return "";+}++function transcriptPhase(eventType) {+ if (eventType.endsWith(".delta")) {+ return "delta";+ }+ if (eventType.endsWith(".completed")) {+ return "completed";+ }+ if (eventType.endsWith(".done")) {+ return "done";+ }+ return "unknown";+}diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/room.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/room.jsnew file mode 100644index 00000000..5764c78d--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/room.js@@ -0,0 +1,87 @@+export class TranslationRoom {+ constructor({ createBridge, logger = console }) {+ this.createBridge = createBridge;+ this.logger = logger;+ this.waiting = [];+ this.callers = new Map();+ this.pairs = new Map();+ }++ addCaller(caller) {+ this.callers.set(caller.callSid, caller);++ const waitingCaller = this.waiting.find(+ (candidate) => candidate.callSid !== caller.callSid,+ );+ if (!waitingCaller) {+ this.waiting.push(caller);+ this.logger.info?.(`[room] ${caller.callSid} waiting in ${caller.language}`);+ return null;+ }++ this.waiting = this.waiting.filter(+ (candidate) => candidate.callSid !== waitingCaller.callSid,+ );+ return this.#pairCallers(waitingCaller, caller);+ }++ handleMedia(callSid, payload) {+ const caller = this.callers.get(callSid);+ caller?.bridgeToPeer?.sendTwilioMedia(payload);+ }++ removeCaller(callSid) {+ this.waiting = this.waiting.filter((caller) => caller.callSid !== callSid);+ const caller = this.callers.get(callSid);+ this.callers.delete(callSid);++ const pair = caller?.pairId ? this.pairs.get(caller.pairId) : null;+ if (!pair) {+ return;+ }++ pair.a.bridgeToPeer?.close();+ pair.b.bridgeToPeer?.close();+ this.pairs.delete(pair.id);+ this.callers.delete(pair.a.callSid);+ this.callers.delete(pair.b.callSid);++ if (pair.a.callSid !== callSid) {+ pair.a.close?.();+ }+ if (pair.b.callSid !== callSid) {+ pair.b.close?.();+ }+ }++ status() {+ return {+ activeCallers: this.callers.size,+ activePairs: this.pairs.size,+ waiting: this.waiting.length,+ };+ }++ #pairCallers(a, b) {+ const id = `${a.callSid}:${b.callSid}`;+ a.pairId = id;+ b.pairId = id;+ a.bridgeToPeer = this.createBridge({+ sourceLabel: a.callSid,+ target: b,+ targetLanguage: b.language,+ });+ b.bridgeToPeer = this.createBridge({+ sourceLabel: b.callSid,+ target: a,+ targetLanguage: a.language,+ });++ const pair = { id, a, b };+ this.pairs.set(id, pair);+ this.logger.info?.(+ `[room] paired ${a.callSid} (${a.language}) <-> ${b.callSid} (${b.language})`,+ );+ return pair;+ }+}diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/security.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/security.jsnew file mode 100644index 00000000..e9096cf3--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/security.js@@ -0,0 +1,96 @@+import { createHmac, timingSafeEqual } from "node:crypto";++export function verifyTwilioSignature({ authToken, params = {}, signature, url }) {+ if (!authToken || !signature || !url) {+ return false;+ }++ const data =+ url ++ Object.keys(params)+ .sort()+ .map((key) => `${key}${stringValue(params[key])}`)+ .join("");++ const expected = createHmac("sha1", authToken).update(data).digest("base64");+ return safeEqual(signature, expected);+}++export function validateTwilioRequest(request, env = process.env, options = {}) {+ if (env.SKIP_TWILIO_SIGNATURE_VALIDATION === "true") {+ return true;+ }++ if (!env.TWILIO_AUTH_TOKEN) {+ return true;+ }++ return verifyTwilioSignature({+ authToken: env.TWILIO_AUTH_TOKEN,+ params: request.body ?? {},+ signature: twilioSignatureHeader(request),+ url: publicWebhookUrl(request, env, options),+ });+}++export function publicWebhookUrl(request, env = process.env, options = {}) {+ const base = env.PUBLIC_URL+ ? new URL(env.PUBLIC_URL)+ : new URL(`${request.protocol ?? "https"}://${request.headers.host}`);++ if (options.protocol) {+ base.protocol = `${options.protocol}:`;+ }++ return new URL(request.url, base).toString();+}++export function isAllowedCaller(from, allowList) {+ const allowed = parseAllowList(allowList);+ if (allowed.size === 0) {+ return true;+ }+ return allowed.has(normalizePhone(from));+}++export function maxActiveCallers(env = process.env) {+ const parsed = Number.parseInt(env.MAX_ACTIVE_CALLERS ?? "", 10);+ return Number.isFinite(parsed) && parsed > 0 ? parsed : Infinity;+}++function parseAllowList(value) {+ return new Set(+ String(value ?? "")+ .split(",")+ .map(normalizePhone)+ .filter(Boolean),+ );+}++function normalizePhone(value) {+ return String(value ?? "").replace(/[^\d+]/g, "");+}++function twilioSignatureHeader(request) {+ return (+ request.headers["x-twilio-signature"] ??+ request.headers["X-Twilio-Signature"] ??+ ""+ );+}++function stringValue(value) {+ if (Array.isArray(value)) {+ return value.join("");+ }+ return String(value ?? "");+}++function safeEqual(left, right) {+ const leftBuffer = Buffer.from(left);+ const rightBuffer = Buffer.from(right);+ return (+ leftBuffer.length === rightBuffer.length &&+ timingSafeEqual(leftBuffer, rightBuffer)+ );+}diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/server.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/server.jsnew file mode 100644index 00000000..cb406ce5--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/server.js@@ -0,0 +1,227 @@+import Fastify from "fastify";+import formBody from "@fastify/formbody";+import websocket from "@fastify/websocket";+import dotenv from "dotenv";+import { fileURLToPath } from "node:url";+import { languageLabelForCode } from "./languages.js";+import {+ DEFAULT_TRANSLATION_MODEL,+ createRealtimeTranslationBridge,+} from "./realtime-translation.js";+import { TranslationRoom } from "./room.js";+import {+ busyTwiml,+ chooseLanguageTwiml,+ incomingCallTwiml,+ rejectedCallerTwiml,+} from "./twiml.js";+import {+ isAllowedCaller,+ maxActiveCallers,+ validateTwilioRequest,+} from "./security.js";++dotenv.config();++export function buildApp(env = process.env, logger = console) {+ const app = Fastify({ logger: false });+ const room = new TranslationRoom({+ logger,+ createBridge: (options) =>+ createRealtimeTranslationBridge({+ ...options,+ apiKey: env.OPENAI_API_KEY,+ model: env.OPENAI_TRANSLATION_MODEL ?? DEFAULT_TRANSLATION_MODEL,+ logger,+ }),+ });++ app.register(formBody);+ app.register(websocket);++ app.get("/", async () => ({+ ok: true,+ service: "twilio-realtime-translation-demo",+ status: room.status(),+ }));++ app.get("/status", async () => room.status());++ app.all("/incoming-call", async (request, reply) => {+ if (!validateTwilioRequest(request, env)) {+ reply.code(403).send("Invalid Twilio signature");+ return;+ }++ if (!isAllowedCaller(request.body?.From, env.ALLOWED_CALLER_NUMBERS)) {+ reply.type("text/xml").send(rejectedCallerTwiml());+ return;+ }++ reply.type("text/xml").send(incomingCallTwiml());+ });++ app.all("/choose-language", async (request, reply) => {+ if (!validateTwilioRequest(request, env)) {+ reply.code(403).send("Invalid Twilio signature");+ return;+ }++ if (room.status().activeCallers >= maxActiveCallers(env)) {+ reply.type("text/xml").send(busyTwiml());+ return;+ }++ const body = request.body ?? {};+ const speechResult =+ typeof body.SpeechResult === "string" ? body.SpeechResult : undefined;+ const callSid = typeof body.CallSid === "string" ? body.CallSid : "unknown";++ reply.type("text/xml").send(+ chooseLanguageTwiml({+ speechResult,+ host: publicHost(request, env),+ callSid,+ attempt: request.query?.attempt,+ }),+ );+ });++ app.register(async (scopedApp) => {+ scopedApp.get("/media-stream", { websocket: true }, (connection, request) => {+ const socket = connection.socket ?? connection;+ let callSid = null;++ if (!validateTwilioRequest(request, env, { protocol: "wss" })) {+ logger.warn?.("[twilio] rejected media stream with invalid signature");+ socket.close(1008, "Invalid Twilio signature");+ return;+ }++ socket.on("message", (raw) => {+ const message = parseTwilioMessage(raw, logger);+ if (!message) {+ return;+ }++ if (message.event === "start") {+ const custom = message.start?.customParameters ?? {};+ callSid = custom.callSid ?? message.start?.callSid;+ const language = custom.language ?? "es";+ const languageLabel =+ custom.languageLabel ?? languageLabelForCode(language);+ const streamSid = message.start?.streamSid;++ if (!callSid || !streamSid) {+ logger.warn?.("[twilio] start event missing callSid or streamSid");+ return;+ }++ room.addCaller(+ createCaller({+ callSid,+ language,+ languageLabel,+ logger,+ socket,+ streamSid,+ }),+ );+ return;+ }++ if (message.event === "media" && callSid && message.media?.payload) {+ room.handleMedia(callSid, message.media.payload);+ return;+ }++ if (message.event === "stop" && callSid) {+ room.removeCaller(callSid);+ }+ });++ socket.on("close", () => {+ if (callSid) {+ room.removeCaller(callSid);+ }+ });+ });+ });++ return app;+}++function createCaller({+ callSid,+ language,+ languageLabel,+ logger,+ socket,+ streamSid,+}) {+ return {+ callSid,+ language,+ languageLabel,+ streamSid,+ close() {+ try {+ socket.close();+ } catch (error) {+ logger.warn?.(`[twilio:${callSid}] failed to close socket`, error);+ }+ },+ sendTwilioMedia(payload) {+ if (!payload || socket.readyState !== 1) {+ return;+ }+ socket.send(+ JSON.stringify({+ event: "media",+ streamSid,+ media: { payload },+ }),+ );+ },+ };+}++function parseTwilioMessage(raw, logger) {+ try {+ const text = Buffer.isBuffer(raw) ? raw.toString("utf8") : String(raw);+ return JSON.parse(text);+ } catch (error) {+ logger.warn?.("[twilio] failed to parse message", error);+ return null;+ }+}++function publicHost(request, env) {+ if (env.PUBLIC_URL) {+ return new URL(env.PUBLIC_URL).host;+ }++ const forwardedHost = request.headers["x-forwarded-host"];+ if (typeof forwardedHost === "string" && forwardedHost.trim()) {+ return forwardedHost.split(",")[0].trim();+ }++ if (request.headers.host) {+ return request.headers.host;+ }++ throw new Error("Set PUBLIC_URL or provide a Host header.");+}++if (process.argv[1] === fileURLToPath(import.meta.url)) {+ const port = Number.parseInt(process.env.PORT ?? "5050", 10);+ const app = buildApp();++ app.listen({ host: "0.0.0.0", port }, (error, address) => {+ if (error) {+ console.error(error);+ process.exit(1);+ }+ console.log(`Twilio Realtime Translation demo listening at ${address}`);+ });+}diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/twiml.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/twiml.jsnew file mode 100644index 00000000..9702d721--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/src/twiml.js@@ -0,0 +1,152 @@+import {+ classifyLanguageSelection,+ languageMenuText,+ supportedLanguageListText,+} from "./languages.js";++const MAX_LANGUAGE_ATTEMPTS = 3;++const xml = (value) =>+ String(value ?? "")+ .replaceAll("&", "&")+ .replaceAll("<", "<")+ .replaceAll(">", ">")+ .replaceAll('"', """)+ .replaceAll("'", "'");++export function incomingCallTwiml() {+ return languagePromptTwiml();+}++export function languagePromptTwiml({+ attempt = 0,+ reason = "initial",+ unsupportedLanguage,+} = {}) {+ const nextAttempt = normalizeAttempt(attempt) + 1;+ const action = "/choose-language?attempt=" + nextAttempt;+ const prompt = promptForLanguageAttempt({ reason, unsupportedLanguage });++ return [+ '<?xml version="1.0" encoding="UTF-8"?>',+ "<Response>",+ ' <Gather input="speech" timeout="10" speechTimeout="auto" action="' ++ xml(action) ++ '" method="POST">',+ " <Say>" + xml(prompt) + "</Say>",+ " </Gather>",+ ' <Redirect method="POST">' + xml(action) + "</Redirect>",+ "</Response>",+ ].join("\n");+}++export function rejectedCallerTwiml() {+ return [+ '<?xml version="1.0" encoding="UTF-8"?>',+ "<Response>",+ " <Say>This number is not enabled for this demo.</Say>",+ " <Hangup />",+ "</Response>",+ ].join("\n");+}++export function busyTwiml() {+ return [+ '<?xml version="1.0" encoding="UTF-8"?>',+ "<Response>",+ " <Say>The translation demo is currently full. Please try again later.</Say>",+ " <Hangup />",+ "</Response>",+ ].join("\n");+}++export function chooseLanguageTwiml({+ speechResult,+ host,+ callSid,+ attempt = 0,+}) {+ const selection = classifyLanguageSelection(speechResult);+ if (selection.status !== "supported") {+ const currentAttempt = normalizeAttempt(attempt);+ if (currentAttempt >= MAX_LANGUAGE_ATTEMPTS) {+ return languageFailedTwiml();+ }++ return languagePromptTwiml({+ attempt: currentAttempt,+ reason: selection.status,+ unsupportedLanguage: selection.language,+ });+ }++ const language = selection.language;+ return streamTwiml({+ host,+ callSid,+ language: language.code,+ languageLabel: language.label,+ });+}++export function streamTwiml({ host, callSid, language, languageLabel }) {+ return [+ '<?xml version="1.0" encoding="UTF-8"?>',+ "<Response>",+ " <Say>You chose " ++ xml(languageLabel) ++ ". Wait for the other caller, then begin speaking.</Say>",+ " <Connect>",+ ' <Stream url="wss://' + xml(host) + '/media-stream">',+ ' <Parameter name="callSid" value="' + xml(callSid) + '" />',+ ' <Parameter name="language" value="' + xml(language) + '" />',+ ' <Parameter name="languageLabel" value="' + xml(languageLabel) + '" />',+ " </Stream>",+ " </Connect>",+ "</Response>",+ ].join("\n");+}++function promptForLanguageAttempt({ reason, unsupportedLanguage }) {+ if (reason === "unsupported" && unsupportedLanguage) {+ return (+ unsupportedLanguage ++ " is not supported for this demo. Please say one of these languages: " ++ supportedLanguageListText() ++ "."+ );+ }++ if (reason === "missing") {+ return (+ "I didn't catch the language. Please say one of these languages: " ++ supportedLanguageListText() ++ "."+ );+ }++ if (reason === "unknown") {+ return (+ "I didn't hear a supported language. Please say one of these languages: " ++ supportedLanguageListText() ++ "."+ );+ }++ return languageMenuText();+}++function languageFailedTwiml() {+ return [+ '<?xml version="1.0" encoding="UTF-8"?>',+ "<Response>",+ " <Say>Sorry, I couldn't confirm a supported language. Please call again and say one of the supported languages.</Say>",+ " <Hangup />",+ "</Response>",+ ].join("\n");+}++function normalizeAttempt(attempt) {+ const parsed = Number.parseInt(attempt, 10);+ return Number.isFinite(parsed) && parsed > 0 ? parsed : 0;+}diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/audio.test.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/audio.test.jsnew file mode 100644index 00000000..a68425bb--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/audio.test.js@@ -0,0 +1,36 @@+import { describe, expect, it } from "vitest";+import {+ base64ToInt16,+ int16ToBase64,+ mulawBase64ToPcm16,+ pcm16ToMulawBase64,+ resampleLinear,+} from "../src/audio.js";++describe("audio conversion", () => {+ it("round trips PCM16 through base64", () => {+ const samples = new Int16Array([-32768, -1000, 0, 1000, 32767]);+ expect(base64ToInt16(int16ToBase64(samples))).toEqual(samples);+ });++ it("resamples 8 kHz telephony audio to 24 kHz model audio", () => {+ const samples = new Int16Array(160);+ const upsampled = resampleLinear(samples, 8000, 24000);+ expect(upsampled).toHaveLength(480);+ });++ it("resamples 24 kHz model audio to 8 kHz telephony audio", () => {+ const samples = new Int16Array(4800);+ const downsampled = resampleLinear(samples, 24000, 8000);+ expect(downsampled).toHaveLength(1600);+ });++ it("converts Twilio mulaw payloads into PCM16 and back", () => {+ const pcm = new Int16Array([0, 1000, -1000, 4000, -4000]);+ const payload = pcm16ToMulawBase64(pcm);+ const decoded = mulawBase64ToPcm16(payload);++ expect(decoded).toHaveLength(pcm.length);+ expect(Math.abs(decoded[0])).toBeLessThan(200);+ });+});diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/languages.test.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/languages.test.jsnew file mode 100644index 00000000..0b1fa8e8--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/languages.test.js@@ -0,0 +1,71 @@+import { describe, expect, it } from "vitest";+import {+ classifyLanguageSelection,+ languageForSpeech,+ languageMenuText,+ supportedLanguages,+} from "../src/languages.js";++describe("language selection", () => {+ it("defines the full spoken output language menu", () => {+ expect(supportedLanguages).toHaveLength(13);+ expect(supportedLanguages.map((language) => language.label)).toEqual([+ "Spanish",+ "Portuguese",+ "French",+ "Japanese",+ "Russian",+ "Chinese",+ "German",+ "Korean",+ "Hindi",+ "Indonesian",+ "Vietnamese",+ "Italian",+ "English",+ ]);+ });++ it("maps spoken language names to supported output languages", () => {+ expect(languageForSpeech("Spanish")).toEqual({ code: "es", label: "Spanish" });+ expect(languageForSpeech("I want to hear French please")).toEqual({+ code: "fr",+ label: "French",+ });+ expect(languageForSpeech("portuguese")).toEqual({+ code: "pt",+ label: "Portuguese",+ });+ expect(languageForSpeech("Mandarin Chinese")).toEqual({+ code: "zh",+ label: "Chinese",+ });+ expect(languageForSpeech("bahasa indonesia")).toEqual({+ code: "id",+ label: "Indonesian",+ });+ expect(languageForSpeech("vietnamese")).toEqual({+ code: "vi",+ label: "Vietnamese",+ });+ });++ it("returns null for missing or unknown speech instead of defaulting", () => {+ expect(languageForSpeech(undefined)).toBeNull();+ expect(languageForSpeech("surprise me")).toBeNull();+ });++ it("classifies unsupported spoken language names", () => {+ expect(classifyLanguageSelection("Swedish")).toEqual({+ status: "unsupported",+ language: "Swedish",+ });+ });++ it("renders a spoken-only menu", () => {+ expect(languageMenuText()).toContain("say the language you want to hear");+ expect(languageMenuText()).toContain("English");+ expect(languageMenuText()).toContain("Russian");+ expect(languageMenuText()).not.toContain("press");+ });+});diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/realtime-translation.test.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/realtime-translation.test.jsnew file mode 100644index 00000000..248a90bd--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/realtime-translation.test.js@@ -0,0 +1,183 @@+import { describe, expect, it, vi } from "vitest";+import {+ buildSessionUpdate,+ buildTranslationUrl,+ createRealtimeTranslationBridge,+} from "../src/realtime-translation.js";++describe("Realtime Translation bridge", () => {+ it("selects the translation model in the direct server-side WebSocket URL", () => {+ expect(buildTranslationUrl("gpt-realtime-translate")).toBe(+ "wss://api.openai.com/v1/realtime/translations?model=gpt-realtime-translate",+ );+ });++ it("builds the translation session payload", () => {+ expect(buildSessionUpdate("es")).toEqual({+ type: "session.update",+ session: {+ audio: {+ input: {+ transcription: { model: "gpt-realtime-whisper" },+ noise_reduction: { type: "near_field" },+ },+ output: { language: "es" },+ },+ },+ });+ });++ it("opens Realtime and forwards translated audio to Twilio", () => {+ const sentToRealtime = [];+ const sentToTwilio = [];+ class FakeWebSocket {+ static instances = [];++ constructor(url, options) {+ this.url = url;+ this.options = options;+ this.readyState = FakeWebSocket.OPEN;+ this.listeners = new Map();+ FakeWebSocket.instances.push(this);+ }++ static OPEN = 1;++ on(event, handler) {+ this.listeners.set(event, handler);+ }++ send(payload) {+ sentToRealtime.push(JSON.parse(payload));+ }++ emit(event, payload) {+ this.listeners.get(event)?.(payload);+ }++ close() {}+ }++ const target = {+ streamSid: "MZ123",+ sendTwilioMedia: vi.fn((payload) => sentToTwilio.push(payload)),+ };+ const bridge = createRealtimeTranslationBridge({+ apiKey: "sk-test",+ sourceLabel: "caller-a",+ target,+ targetLanguage: "es",+ WebSocketImpl: FakeWebSocket,+ });++ const socket = FakeWebSocket.instances[0];+ expect(socket.url).toBe(+ "wss://api.openai.com/v1/realtime/translations?model=gpt-realtime-translate",+ );+ expect(socket.options.headers).toMatchObject({+ Authorization: "Bearer sk-test",+ });+ expect(Object.keys(socket.options.headers)).toEqual(["Authorization"]);++ socket.emit("open");+ expect(sentToRealtime[0]).toEqual(buildSessionUpdate("es"));++ socket.emit(+ "message",+ JSON.stringify({+ type: "session.output_audio.delta",+ delta: "AAAA",+ }),+ );+ expect(sentToTwilio).toHaveLength(1);+ });++ it("logs input and output transcript events with eval-friendly metadata", () => {+ const sentToRealtime = [];+ class FakeWebSocket {+ static instances = [];++ constructor() {+ this.readyState = FakeWebSocket.OPEN;+ this.listeners = new Map();+ FakeWebSocket.instances.push(this);+ }++ static OPEN = 1;++ on(event, handler) {+ this.listeners.set(event, handler);+ }++ send(payload) {+ sentToRealtime.push(JSON.parse(payload));+ }++ emit(event, payload) {+ this.listeners.get(event)?.(payload);+ }++ close() {}+ }++ const logger = {+ info: vi.fn(),+ warn: vi.fn(),+ error: vi.fn(),+ };+ createRealtimeTranslationBridge({+ apiKey: "sk-test",+ sourceLabel: "caller-a",+ target: { sendTwilioMedia: vi.fn() },+ targetLanguage: "de",+ WebSocketImpl: FakeWebSocket,+ logger,+ });++ const socket = FakeWebSocket.instances[0];+ socket.emit("open");+ socket.emit(+ "message",+ JSON.stringify({+ type: "conversation.item.input_audio_transcription.completed",+ item_id: "item-1",+ transcript: "hello there",+ }),+ );+ socket.emit(+ "message",+ JSON.stringify({+ type: "session.output_transcript.delta",+ response_id: "response-1",+ delta: "hallo",+ }),+ );++ expect(logger.info).toHaveBeenCalledWith(+ "[translation-transcript] " ++ JSON.stringify({+ callSid: "caller-a",+ direction: "input",+ phase: "completed",+ targetLanguage: "de",+ eventType: "conversation.item.input_audio_transcription.completed",+ itemId: "item-1",+ responseId: undefined,+ text: "hello there",+ }),+ );+ expect(logger.info).toHaveBeenCalledWith(+ "[translation-transcript] " ++ JSON.stringify({+ callSid: "caller-a",+ direction: "output",+ phase: "delta",+ targetLanguage: "de",+ eventType: "session.output_transcript.delta",+ itemId: undefined,+ responseId: "response-1",+ text: "hallo",+ }),+ );+ });+});diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/room.test.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/room.test.jsnew file mode 100644index 00000000..cfa38a94--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/room.test.js@@ -0,0 +1,37 @@+import { describe, expect, it, vi } from "vitest";+import { TranslationRoom } from "../src/room.js";++const caller = (id, language) => ({+ callSid: id,+ language,+ languageLabel: language,+ sendTwilioMedia: vi.fn(),+});++describe("TranslationRoom", () => {+ it("waits for a second caller before pairing", () => {+ const room = new TranslationRoom({ createBridge: vi.fn() });+ room.addCaller(caller("CA1", "en"));+ expect(room.status().waiting).toBe(1);+ expect(room.status().activePairs).toBe(0);+ });++ it("creates one translation bridge per direction using the listener language", () => {+ const createBridge = vi.fn(() => ({ close: vi.fn() }));+ const room = new TranslationRoom({ createBridge });+ room.addCaller(caller("CA1", "en"));+ room.addCaller(caller("CA2", "es"));++ expect(room.status().waiting).toBe(0);+ expect(room.status().activePairs).toBe(1);+ expect(createBridge).toHaveBeenCalledTimes(2);+ expect(createBridge.mock.calls[0][0]).toMatchObject({+ sourceLabel: "CA1",+ targetLanguage: "es",+ });+ expect(createBridge.mock.calls[1][0]).toMatchObject({+ sourceLabel: "CA2",+ targetLanguage: "en",+ });+ });+});diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/security.test.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/security.test.jsnew file mode 100644index 00000000..f79ab26d--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/security.test.js@@ -0,0 +1,69 @@+import { createHmac } from "node:crypto";+import { describe, expect, it } from "vitest";+import {+ isAllowedCaller,+ publicWebhookUrl,+ verifyTwilioSignature,+} from "../src/security.js";++function sign(url, params, authToken) {+ const data =+ url ++ Object.keys(params)+ .sort()+ .map((key) => `${key}${params[key]}`)+ .join("");++ return createHmac("sha1", authToken).update(data).digest("base64");+}++describe("Twilio request security", () => {+ it("validates Twilio signatures for form webhooks", () => {+ const url = "https://demo.example.com/incoming-call";+ const params = { CallSid: "CA123", From: "+15551234567", To: "+15557654321" };+ const authToken = "test-token";+ const signature = sign(url, params, authToken);++ expect(+ verifyTwilioSignature({+ authToken,+ params,+ signature,+ url,+ }),+ ).toBe(true);+ });++ it("rejects invalid Twilio signatures", () => {+ expect(+ verifyTwilioSignature({+ authToken: "test-token",+ params: { CallSid: "CA123" },+ signature: "bad-signature",+ url: "https://demo.example.com/incoming-call",+ }),+ ).toBe(false);+ });++ it("allows callers when no allow-list is configured", () => {+ expect(isAllowedCaller("+15551234567", undefined)).toBe(true);+ });++ it("requires exact caller matches when an allow-list is configured", () => {+ const allowList = "+15551234567, +15557654321";++ expect(isAllowedCaller("+15551234567", allowList)).toBe(true);+ expect(isAllowedCaller("+15550000000", allowList)).toBe(false);+ });++ it("builds public webhook URLs from PUBLIC_URL so signature validation survives proxies", () => {+ const request = {+ url: "/choose-language?foo=bar",+ headers: { host: "internal.local" },+ };++ expect(publicWebhookUrl(request, { PUBLIC_URL: "https://demo.example.com" })).toBe(+ "https://demo.example.com/choose-language?foo=bar",+ );+ });+});diff --git a/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/twiml.test.js b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/twiml.test.jsnew file mode 100644index 00000000..8cab7c35--- /dev/null+++ b/examples/voice_solutions/realtime_translation_guide/twilio-translation-demo/test/twiml.test.js@@ -0,0 +1,114 @@+import { describe, expect, it } from "vitest";+import {+ busyTwiml,+ chooseLanguageTwiml,+ incomingCallTwiml,+ languagePromptTwiml,+ rejectedCallerTwiml,+ streamTwiml,+} from "../src/twiml.js";++describe("twiml", () => {+ it("prompts callers to choose their output language by speech", () => {+ const xml = incomingCallTwiml();++ expect(xml).toContain("<Gather");+ expect(xml).toContain('input="speech"');+ expect(xml).not.toContain("dtmf");+ expect(xml).toContain('speechTimeout="auto"');+ expect(xml).toContain('action="/choose-language?attempt=1"');+ expect(xml).toContain("English");+ expect(xml).toContain("Russian");+ expect(xml).not.toContain("Defaulting to Spanish");+ });++ it("connects a caller to a two-way media stream with custom parameters", () => {+ const xml = streamTwiml({+ host: "demo.example.com",+ callSid: "CA123",+ language: "es",+ languageLabel: "Spanish",+ });++ expect(xml).toContain('<Connect>');+ expect(xml).toContain('<Stream url="wss://demo.example.com/media-stream">');+ expect(xml).toContain('<Parameter name="callSid" value="CA123" />');+ expect(xml).toContain('<Parameter name="language" value="es" />');+ });++ it("uses the spoken language when returning stream TwiML", () => {+ const xml = chooseLanguageTwiml({+ speechResult: "I would like Japanese",+ host: "demo.example.com",+ callSid: "CA789",+ });++ expect(xml).toContain("Japanese");+ expect(xml).toContain('<Parameter name="language" value="ja" />');+ });++ it("reprompts when the caller names an unsupported language", () => {+ const xml = chooseLanguageTwiml({+ speechResult: "Swedish",+ host: "demo.example.com",+ callSid: "CA789",+ attempt: "1",+ });++ expect(xml).toContain("<Gather");+ expect(xml).toContain("Swedish is not supported");+ expect(xml).toContain("Please say one of these languages");+ expect(xml).toContain("Vietnamese");+ expect(xml).not.toContain("Arabic");+ expect(xml).not.toContain("<Stream");+ });++ it("reprompts when no language is captured", () => {+ const xml = chooseLanguageTwiml({+ host: "demo.example.com",+ callSid: "CA789",+ attempt: "1",+ });++ expect(xml).toContain("<Gather");+ expect(xml).toContain("I didn't catch the language");+ expect(xml).not.toContain("Defaulting to Spanish");+ });++ it("hangs up after repeated invalid language attempts", () => {+ const xml = chooseLanguageTwiml({+ speechResult: "Swedish",+ host: "demo.example.com",+ callSid: "CA789",+ attempt: "3",+ });++ expect(xml).toContain("<Hangup");+ expect(xml).toContain("couldn't confirm a supported language");+ });++ it("can render an unsupported-language prompt directly", () => {+ const xml = languagePromptTwiml({+ attempt: 1,+ reason: "unsupported",+ unsupportedLanguage: "Swedish",+ });++ expect(xml).toContain("Swedish is not supported");+ expect(xml).toContain('action="/choose-language?attempt=2"');+ });++ it("rejects callers outside the allow-list", () => {+ const xml = rejectedCallerTwiml();++ expect(xml).toContain("<Hangup");+ expect(xml).toContain("not enabled for this demo");+ });++ it("returns a busy response when the room is at capacity", () => {+ const xml = busyTwiml();++ expect(xml).toContain("<Hangup");+ expect(xml).toContain("demo is currently full");+ });+});diff --git a/images/realtime_translation_guide/browser-tab-translation.png b/images/realtime_translation_guide/browser-tab-translation.pngnew file mode 100644index 00000000..9be4667bBinary files /dev/null and b/images/realtime_translation_guide/browser-tab-translation.png differdiff --git a/images/realtime_translation_guide/livekit-video-translation.png b/images/realtime_translation_guide/livekit-video-translation.pngnew file mode 100644index 00000000..9df2ae07Binary files /dev/null and b/images/realtime_translation_guide/livekit-video-translation.png differdiff --git a/images/realtime_translation_guide/twilio-phone-translation.png b/images/realtime_translation_guide/twilio-phone-translation.pngnew file mode 100644index 00000000..42552cf9Binary files /dev/null and b/images/realtime_translation_guide/twilio-phone-translation.png differdiff --git a/registry.yaml b/registry.yamlindex e9954458..c93d5896 100644--- a/registry.yaml+++ b/registry.yaml@@ -2806,6 +2806,21 @@- responses- speech+- title: Build Live Translation Apps with gpt-realtime-translate+ path: examples/voice_solutions/realtime_translation_guide.mdx+ slug: realtime-translation-guide+ description: Cookbook for building browser, phone, and video-call translation experiences with Realtime Translation.+ date: 2026-05-07+ authors:+ - erikakettleson-openai+ tags:+ - realtime+ - audio+ - speech+ - translation+ - webrtc+ - websockets+- title: Multi-Language One-Way Translation with the Realtime APIpath: examples/voice_solutions/one_way_translation_using_realtime_api.mdxslug: one-way-translation-using-realtime-api