Skip to content

Interface: BarClientOptions

Defined in: core.ts:93

@habemus-papadum/aiui-remote-bar — the command bar as its own channel (aiui-pencil plan, decision D5). The mode engine of a host page, projected over its own websocket, mounted as a channel sidecar at its own URL, with a Solid client that renders the projected bar and dispatches taps back.

This barrel is the browser/isomorphic surface — the wire, the socket-free cores, the host binding, and the client component. The node relay is a separate import so this entry never drags ws/express into a browser bundle:

import { createBarBackend } from "@habemus-papadum/aiui-remote-bar/server"; import { barSidecar } from "@habemus-papadum/aiui-remote-bar/sidecar";

Layers:

  • protocol.ts — the pure wire (bar down / command up), the WireCap↔CapView drift guard, framing.
  • core.ts — the two endpoint cores, socket-free (a send in, a receive out).
  • solid.ts — the host binding: a solidModeEngine-shaped source → the wire.
  • ui/ — the remote's reactive client (behind a transport seam) + the RemoteBar Solid component.

Properties

onBar?

optional onBar?: (rows, claims, phase?) => void

Defined in: core.ts:103

The host's projected bar — render it.

Parameters

rows

WireCap[]

claims

Record<string, string>

phase?

string

Returns

void


onHostGone?

optional onHostGone?: () => void

Defined in: core.ts:105

The host disconnected while joined — the bar is stale; fall back to the list.

Returns

void


onJoined?

optional onJoined?: (host, label) => void

Defined in: core.ts:99

A join was accepted — the remote is now viewing this host's bar.

Parameters

host

string

label

string

Returns

void


onJoinRejected?

optional onJoinRejected?: (reason) => void

Defined in: core.ts:101

A join was refused (e.g. the host is gone) — show it, don't retry blindly.

Parameters

reason

string

Returns

void


onSessions?

optional onSessions?: (sessions) => void

Defined in: core.ts:97

The relay's list of connectable hosts (broadcast on connect + on change).

Parameters

sessions

SessionInfo[]

Returns

void


send

send: (message) => void

Defined in: core.ts:95

Put a message on the wire.

Parameters

message

ClientToRelay

Returns

void