Skip to content
Viewership Inquire
Astro UI

Agent Screen.

An agent's live screen with an expandable viewer and recording.

AgentComponent1 dependency Beautiful UI, MIT

.md
Reporting agent's screen
Reporting agent

Install

  1. Import the foundation once

    foundation.css holds the tokens every component reads.

    Layout.astro
    ---
    // src/layouts/Layout.astro
    import "../styles/foundation.css";
    ---
  2. Copy AgentScreen.astro

    Paste into src/components/viewership/agent-screen/

  3. Copy its dependencies

    Each in its own folder, next to this one.

  4. Use it

    Page.astro
    ---
    import AgentScreen from "../components/viewership/agent-screen/AgentScreen.astro";
    ---
    
    <AgentScreen />

Props 5

PropTypeDefaultDescription
agentName string "Agent" Caption and viewer title.
state "live" | "connecting" "live" connecting disables opening.
src string · Image or video URL. Falls back to a sample desktop.
<slot /> HTML · Custom screen markup. Size in em or cqw.
labels Partial<AgentScreenLabels> · Text overrides.

Events

EventDetailWhen
vs-agent-screen-open / -close CustomEvent Fires when the viewer opens or collapses.
vs-agent-screen-record CustomEvent<{ recording: true }> Fires when recording starts.
vs-agent-screen-end CustomEvent<{ seconds: number }> Fires when recording ends.

Source 1 file

Ported from Beautiful UI, MIT. Notices.