LevelChatDocs
Docs
PollPanel

Components

PollPanel

Live polls during a call — host composes, audience votes, results animate in.

PollPanel renders live in-call polls — list of open + closed polls, vote buttons with progress bars, and (when isHost is true) a composer at the bottom for posting a new poll with 2–6 options. Composes usePolls.

Install

pnpm add @levelchat/react-components @levelchat/web

Basic usage

import { PollPanel } from '@levelchat/react-components';

<PollPanel isHost={isHost} className="h-full w-80" />

Host composer

Hosts get the composer at the bottom. Each poll supports 2–6 options, an optional anonymous mode, optional auto-close timer, and a "show results live" toggle. Server enforces all caps; we don't double-validate client-side.

Live vs. post-close results

  • liveResults: true — vote bars + percentages render the moment a vote lands.
  • liveResults: false — bars stay hidden until the poll closes (or the host taps Close poll).

Props

PropTypeDefaultNotes
isHostbooleanfalseShow the composer + close-poll action.
hideComposerbooleanfalseHide the composer even when isHost is true.
classNamestringContainer override.
PollPanel — LevelChat Docs