Kanshō/Continuation token banner

Continuation token banner

Background and long-running tasks can outlive their stream. This banner surfaces the continuation token and the current connection posture — polling, reconnecting, interrupted, resumed — with a clear reconnect affordance.

Included in the single kansho full pack. Components are not offered as separate installs.

States

Static preview: Copy and Reconnect require host callbacks
Polling for updatesNext poll in 4s
cont_8f29ac01b7
Reconnecting to streamAttempt 2 of 5
cont_8f29ac01b7
Stream interruptedStream dropped 8s ago
cont_8f29ac01b7
Stream resumedCaught up to live
cont_8f29ac01b7

Component documentation

Continuation Token Banner

components/tasks/continuation-token-banner.tsx

Purpose

Reports long-running stream continuity and exposes copy or reconnect actions.

Appropriate use

Use when a task continues through polling, reconnection, interruption, or resumption and the continuation token matters operationally.

Example

components/tasks/continuation-token-banner.tsx has a representative live example in the "States" section on /components/continuation-token-banner.

States

States are polling, reconnecting, interrupted, and resumed; detail text and both callbacks are optional.

API and props

ContinuationTokenBanner accepts state, token, detail, onReconnect, onCopyToken, and className.

Dependencies

Direct imports are React, Lucide icons, IconButton, StatusPill, shared status types, and cn.

Accessibility

The banner is a polite status except interruption, which is assertive; the copy control is named and reconnect is textual.

Limitations

It does not poll, reconnect, copy automatically, validate tokens, or expose pending/error results after a callback.

Source

Source: components/tasks/continuation-token-banner.tsx.

Full pack

components/tasks/continuation-token-banner.tsx is documented at /components/continuation-token-banner and installs only through the single Kansho full pack; no individual component install is offered.