Axon 911 Frontend DocsAxon 911 Frontend Docs
Axon 911 Frontend Docs
    Loading navigation…
U
User
Switch to light mode
  1. Blocks
  2. Control Island
  3. Usage

Control Island

Usage

Import @prepared911/ui/blocks/control-island and its styles.css, plus the styles.css of each component the block composes (Box, Button, ButtonGroup, Icon, Menu, Text, VisuallyHidden). ControlIsland is the raised pill at the start of the Navbar. It carries the person's role, queue, and availability. It is one block with three variants; variant is required and decides which props exist.
The block imports no glyph (ADR 0014), so every glyph is a prop. The Figma glyphs are briefcase-business, headset, and route for the roles, hand for raise hand, chevron-down for the menu pill, and phone-call for Ringing.
Variants
  • Supervisor is a thin host around the Expanding ButtonGroup. items, value, defaultValue, onValueChange, size, and label pass straight through, and each item becomes a ButtonGroupItem. The group draws the whole pill, so the block adds nothing but a host that takes className, id, and ref. Hovering or focusing a collapsed role never changes a width: its label shows in a tooltip. Pressing a role selects it at once and it shows its label while selected; the selected role gets no tooltip, and a disabled role still shows its tooltip on hover (CI-22, ButtonGroup BG-28 to BG-32). Calltaker and Dispatcher have no expanding segments.
  • Calltaker is the accent role badge, the queue label, a decorative dot, the raise hand toggle, and the availability pill.
  • Dispatcher is the same without the availability pill; its end padding is wider (12px) because the island ends in the hand control.
Availability
status is Busy, Ready, or Ringing. It is controlled with status or uncontrolled with defaultStatus (Busy).
  • Busy and Ready are one solid pill Button (dusty red and cool green) that opens a Menu with a radio choice of the two. Choosing a row closes the menu and calls onStatusChange(status, details). Cancel the details to keep the previous choice.
  • Ringing is not a choice. The host sets it while a call is incoming. It is a static cobalt pill with a phone glyph, no chevron, and no menu, and it is not a control. onStatusChange is never called with it.
  • The island keeps no memory of the choice Ringing replaced. A host that rings the island controls status, keeps the person's choice itself, and passes it back when the call ends. See the Composition story.
Entering Ringing is announced once, politely, with ringingAnnouncement.
Raise hand
A toggle Button (aria-pressed) named by raiseHandLabel, which does not change with the state. It is controlled with raisedHand or uncontrolled with defaultRaisedHand, and reports through onRaisedHandChange(raised, details).
Size
size is the shared control height (ADR 0012) and defaults to Medium, the design's size: a 38px island with 30px pills. The role segments, the badge, the raise hand control, and the status pill all follow it. A pill is the control height plus its 1px edge on each side, and the island is a pill plus a 4px inset (--space-4, measured from the island's outer edge) above and below, so the pills are centered and the three variants are always the same height:
sizeControl heightPillIsland
Small24px26px34px
Medium28px30px38px
Large32px34px42px
In the Navbar
The island goes in the Navbar's start slot, after the brand. The Navbar places it and sizes the slot to its content; the island sets its own height. The shell imports both: Navbar is a component and does not import this block (NB-12), so NavbarStart takes the island as a child. See the Composition stories InNavbarSupervisor, InNavbarCalltaker, and InNavbarDispatcher, which use the real Navbar, and the Navbar's Composition stories (Calltaker, Dispatcher, Supervisor) for the full header design.
Role badge and queue
The badge and the queue label are static. The badge shows only a glyph, so roleLabel is its accessible name. The queue label truncates with an ellipsis when the island is short of room.
Previous
Takeover dialog / Accessibility
Next
Control Island / API and Development
On this page
Variants
Availability
Raise hand
Size
In the Navbar
Role badge and queue