Skip to content

Element types — core API

Generated reference for @aparte/core. The data and event types the elements take and send. The elements themselves are on their catalogue pages.

On this page
ts
function populateBubbleFromMessage(
   bubble, 
   message, 
   siblingInfo?): void;

Defined in: packages/core/src/components/bubble/bubble-sync.ts:78

Reconcile a bubble element with a message and optional sibling metadata.

For framework wrappers (Angular, React, Vue, Svelte) that own bubble creation through their own template engine. After the framework has mounted/diffed its bubbles, call this helper for each (bubble, message, siblingInfo) tuple to push the imperative state — segments, attachments, and the sibling-picker — that cannot travel via attribute bindings.

The default vanilla viewport (AparteChatViewport with _frameworkManagedDOM === false) uses this helper internally, so the contract stays in lockstep across the core and every wrapper.

Idempotent. Safe to call on every render. Segment count drives the strategy:

  • same count → reconcile content per segment (cheap, preserves user-toggled <details> open/closed state on thinking blocks, etc.)
  • count changed (new segment streamed, branch switched, etc.) → full rebuild via setSegments

Plain content is only pushed when no segments are present — segments take precedence in the bubble’s render logic.

Sibling-picker is only shown when siblingInfo.count > 1; below that, the bubble hides the picker on its own.

ParameterType
bubbleSyncableBubble
messageAparteMessage
siblingInfo?AparteSiblingInfo

void


ts
function setupSuggestionBlocks(config?): () => void;

Defined in: packages/core/src/components/suggestions/suggestion-blocks.ts:163

Read the code blocks in language suggestions in replies as the replies that <aparte-suggestions answers> offers. Returns the function that stops it. Off until called: a block is then no longer shown as code, so it is the app’s choice.

ParameterTypeDefault value
configAparteConfigaparteGlobalConfig

() => void

ts
setupSuggestionBlocks();
// and, in the composer, an `<aparte-suggestions answers>` element

ts
const SUGGESTIONS_BLOCK_LANGUAGE: "suggestions" = 'suggestions';

Defined in: packages/core/src/components/suggestions/suggestion-blocks.ts:27

The language the block is written in.


Defined in: packages/core/src/components/bubble/bubble-sync.ts:20

Minimal structural type representing the imperative slice of AparteChatBubble needed to reconcile a message into a bubble. Declared loosely so framework wrappers can pass any element that exposes the same surface (custom element registered cross-context, mocked test double, etc.) without dragging the concrete AparteChatBubble class through every wrapper’s typing.

ts
optional getSegments?: () => AparteSegment[];

Defined in: packages/core/src/components/bubble/bubble-sync.ts:21

AparteSegment[]

ts
optional setSegments?: (segments) => void;

Defined in: packages/core/src/components/bubble/bubble-sync.ts:22

ParameterType
segmentsAparteSegment[]

void

ts
optional updateSegment?: (segmentId, updates) => void;

Defined in: packages/core/src/components/bubble/bubble-sync.ts:23

ParameterType
segmentIdstring
updatesPartial<AparteSegment>

void

ts
optional setContent?: (content) => void;

Defined in: packages/core/src/components/bubble/bubble-sync.ts:24

ParameterType
contentstring

void

ts
optional setTokens?: (tokens) => void;

Defined in: packages/core/src/components/bubble/bubble-sync.ts:25

ParameterType
tokensreadonly AparteMessageToken[] | undefined

void

ts
optional setAttachments?: (attachments) => void;

Defined in: packages/core/src/components/bubble/bubble-sync.ts:26

ParameterType
attachmentsAparteAttachment[]

void

ts
optional setSiblings?: (count, index) => void;

Defined in: packages/core/src/components/bubble/bubble-sync.ts:27

ParameterType
countnumber
indexnumber

void

ts
optional setUsage?: (usage) => void;

Defined in: packages/core/src/components/bubble/bubble-sync.ts:28

ParameterType
usageAparteUsage | null | undefined

void

ts
optional setFinishReason?: (reason) => void;

Defined in: packages/core/src/components/bubble/bubble-sync.ts:29

ParameterType
reasonAparteFinishReason | null | undefined

void

ts
optional setContextSummary?: (summary, options?) => void;

Defined in: packages/core/src/components/bubble/bubble-sync.ts:30

ParameterType
summaryAparteContextSummary | null | undefined
options?{ legacy?: boolean; }
options.legacy?boolean

void


Defined in: packages/core/src/components/composer/aparte-composer.ts:42

ts
value-change: {
  value: string;
};

Defined in: packages/core/src/components/composer/aparte-composer.ts:43

ts
value: string;
ts
streaming-change: {
  streaming: boolean;
};

Defined in: packages/core/src/components/composer/aparte-composer.ts:44

ts
streaming: boolean;
ts
disabled-change: {
  disabled: boolean;
};

Defined in: packages/core/src/components/composer/aparte-composer.ts:45

ts
disabled: boolean;
ts
attachments-change: {
  attachments: File[];
};

Defined in: packages/core/src/components/composer/aparte-composer.ts:46

ts
attachments: File[];
ts
submit: {
  value: string;
  attachments: File[];
};

Defined in: packages/core/src/components/composer/aparte-composer.ts:47

ts
value: string;
ts
attachments: File[];
ts
cancel: Record<string, never>;

Defined in: packages/core/src/components/composer/aparte-composer.ts:48

ts
panel-change: {
  active: boolean;
  submitEnabled: boolean;
  mode: AparteComposerPanelMode;
};

Defined in: packages/core/src/components/composer/aparte-composer.ts:49

ts
active: boolean;
ts
submitEnabled: boolean;
ts
mode: AparteComposerPanelMode;

Defined in: packages/core/src/components/composer/aparte-composer.ts:61

Public snapshot of the composer’s observable state. Delivered on every aparte-composer-change DOM event and available synchronously via AparteComposer.getState. Lets an element OUTSIDE the composer package (a custom send button, a footer control) mirror the composer’s live state without the internal _on/_emit bus.

ts
value: string;

Defined in: packages/core/src/components/composer/aparte-composer.ts:62

ts
streaming: boolean;

Defined in: packages/core/src/components/composer/aparte-composer.ts:63

ts
disabled: boolean;

Defined in: packages/core/src/components/composer/aparte-composer.ts:64

ts
attachments: File[];

Defined in: packages/core/src/components/composer/aparte-composer.ts:65

ts
panelActive: boolean;

Defined in: packages/core/src/components/composer/aparte-composer.ts:67

A panel (e.g. an elicitation form) is showing in place of the input.

ts
submitEnabled: boolean;

Defined in: packages/core/src/components/composer/aparte-composer.ts:69

Whether the send button should act as “submit” while a panel is active.


Defined in: packages/core/src/components/composer/aparte-composer.ts:73

Detail of the public aparte-composer-change DOM event.

ts
state: AparteComposerState;

Defined in: packages/core/src/components/composer/aparte-composer.ts:74

ts
composer: AparteComposer;

Defined in: packages/core/src/components/composer/aparte-composer.ts:75


Defined in: packages/core/src/components/context/aparte-context.ts:18

Detail of aparte-context-threshold: the level just entered, and the numbers behind it.

ts
level: AparteContextLevel;

Defined in: packages/core/src/components/context/aparte-context.ts:19

ts
used: number;

Defined in: packages/core/src/components/context/aparte-context.ts:21

Tokens in use — the last turn’s reported usage (prompt sent plus reply), or an estimate once the context has changed since.

ts
window: number;

Defined in: packages/core/src/components/context/aparte-context.ts:23

The window those tokens are measured against.

ts
ratio: number;

Defined in: packages/core/src/components/context/aparte-context.ts:25

used / window, capped at 1.

ts
optional targetId?: string;

Defined in: packages/core/src/components/context/aparte-context.ts:27

The chat this gauge watches, when it has an id.


Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:18

ts
id: string;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:19

ts
title: string;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:20

ts
optional updatedAt?: number;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:22

Drives the date groups. A list where no item carries one renders flat.

ts
optional archivedAt?: number;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:24

When set, the row is italic and its menu offers unarchive instead of archive.

ts
optional pinnedAt?: number;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:26

When set, the row sits in the “Pinned” group first, and its menu offers unpin.


Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:29

ts
id: string;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:30


Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:33

ts
id: string;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:34


Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:37

ts
id: string;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:38


Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:41

ts
id: string;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:42


Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:45

ts
id: string;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:46

ts
title: string;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:48

The new title, trimmed and non-empty — an unchanged or emptied title fires nothing.


Defined in: packages/core/src/components/launcher/aparte-launcher.ts:8

Detail of aparte-launcher-toggle: the state just entered.

ts
open: boolean;

Defined in: packages/core/src/components/launcher/aparte-launcher.ts:9

ts
sheet: boolean;

Defined in: packages/core/src/components/launcher/aparte-launcher.ts:11

True while the window is under the breakpoint and the open chat fills it. Kept current: the event fires again when the window crosses the breakpoint while the chat is open.


Defined in: packages/core/src/components/scroll-rail/aparte-scroll-rail.ts:8

Detail of aparte-scroll-rail-jump: the message a tick points at.

ts
messageId: string;

Defined in: packages/core/src/components/scroll-rail/aparte-scroll-rail.ts:9


Defined in: packages/core/src/components/sidebar/aparte-sidebar.ts:9

Detail of aparte-sidebar-toggle: the state just entered.

ts
collapsed: boolean;

Defined in: packages/core/src/components/sidebar/aparte-sidebar.ts:10

ts
drawer: boolean;

Defined in: packages/core/src/components/sidebar/aparte-sidebar.ts:12

True while the sidebar is a drawer — the window is under the breakpoint.


Defined in: packages/core/src/components/split/aparte-split.ts:9

Detail of aparte-split-resize: the position that settled, and what settled it.

ts
position: number;

Defined in: packages/core/src/components/split/aparte-split.ts:11

The achieved size of the primary pane, as a percentage of the container.

ts
collapsed: boolean;

Defined in: packages/core/src/components/split/aparte-split.ts:13

The primary pane is folded to its minimum.

ts
stacked: boolean;

Defined in: packages/core/src/components/split/aparte-split.ts:15

The split is showing one pane — under its breakpoint, or told to by single.

ts
pane: "start" | "end";

Defined in: packages/core/src/components/split/aparte-split.ts:17

Which pane is shown while stacked.

ts
orientation: "horizontal" | "vertical";

Defined in: packages/core/src/components/split/aparte-split.ts:19

The container’s axis, as the orientation attribute names it.

ts
source: "pointer" | "keyboard" | "api";

Defined in: packages/core/src/components/split/aparte-split.ts:21

What moved it: a drag, a key, or the host setting the property.


Defined in: packages/core/src/components/suggestions/aparte-suggestions.ts:17

Detail of aparte-suggestion: what was shown and what will be sent.

ts
label: string;

Defined in: packages/core/src/components/suggestions/aparte-suggestions.ts:18

ts
prompt: string;

Defined in: packages/core/src/components/suggestions/aparte-suggestions.ts:19


Defined in: packages/core/src/generated/element-attributes.ts:6

<aparte-chat> — AparteChat - The Shell

ts
optional placeholder?: string;

Defined in: packages/core/src/generated/element-attributes.ts:8

Placeholder for the composer input (default composition)

ts
optional disabled?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:10

Disables the composer

ts
optional submit-on-enter?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:12

Forwarded to the composer by value: submit-on-enter="false" makes Enter break the line and Shift+Enter send (the bare attribute, or none, keeps the default — Enter sends). The four wrappers expose the same switch as submitOnEnter.

ts
optional attachments?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:14

Add the file picker + chips strip to the default composition (opt-in: the host must consume the files — an AparteClient does, a hand-rolled loop must read event.detail.files)

ts
optional center-empty?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:16

Center the composer as a welcome state until the first message, then slide to the normal layout

ts
optional data-empty?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:18

Reflected BY the element while its viewport holds no <aparte-chat-bubble> and is not loading — set again when the conversation is cleared. With or without center-empty: the stylesheet centers the composer through aparte-chat[center-empty][data-empty], and an app styles or scripts its own empty state against aparte-chat[data-empty]. Read-only.

ts
optional data-glide?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:20

Reflected BY the element at the first key or pointer in the page, or the first send: from then on center-empty slides the composer between the welcome and the conversation. Before it, a conversation a script restores on load lands in one frame. Read-only.

ts
optional overlay-composer?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:22

The ChatGPT anatomy, opt-in: the transcript’s scroll surface spans the whole column and the composer (with the rest of the bottom stack) floats over it, so the scrollbar runs edge to edge instead of stopping at the composer’s top. The viewport measures the stack and publishes --aparte-bottom-inset; content, spacer and the scroll button clear it. Followed by the viewport: it can be set or removed after the chat mounts. Also honoured on a wrapper’s [data-aparte-chat] root.

ts
optional framework-managed?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:24

The wrapper’s explicit hands-off signal: set it and this element composes none of its own children, because the framework owns them. Read once at connect (it is not observed), so it has to be in the initial markup. Angular’s wrapper sets it on this element — its component selector IS aparte-chat; React/Vue/Svelte render a [data-aparte-chat] div and never create this element at all.


Defined in: packages/core/src/generated/element-attributes.ts:28

<aparte-chat-bubble> — One message: plain content or a list of rich segments, in light DOM.

ts
optional data-role?: string;

Defined in: packages/core/src/generated/element-attributes.ts:30

The message role, user or assistant — the one channel for it, and what the CSS keys off. (role is ARIA’s attribute; this element sets it to article itself and does not read a message role from it.)

ts
optional content?: string;

Defined in: packages/core/src/generated/element-attributes.ts:32

Plain text content, for a bubble with no segments.

ts
optional timestamp?: string | number;

Defined in: packages/core/src/generated/element-attributes.ts:34

Epoch milliseconds or a date string; a numeric string is read as milliseconds.

ts
optional message-id?: string;

Defined in: packages/core/src/generated/element-attributes.ts:36

How streaming and the action bar address this bubble.

ts
optional streaming?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:38

Hides the action bar and shows the caret while a reply is in flight.

ts
optional name?: string;

Defined in: packages/core/src/generated/element-attributes.ts:40

Who wrote the message: shown in the header, and the message’s accessible name (“Message from {name}”). Leave it out for the reader and the assistant, whose names come from the locale.

ts
optional data-checkpoint?: string;

Defined in: packages/core/src/generated/element-attributes.ts:42

pending or failed: what a compaction is doing to this message, which it will carry as a checkpoint. The viewport and the framework host set it from aparte-compact-start / -error and take it off again; the bubble draws the separator’s “Summarising the context…” or Retry from it. Read it, do not write it.

ts
optional data-checkpoint-reason?: string;

Defined in: packages/core/src/generated/element-attributes.ts:44

Why the compaction failed, beside data-checkpoint="failed": the separator gives it as the failure’s tooltip and to screen readers. Set and cleared with data-checkpoint; read it, do not write it.


Defined in: packages/core/src/generated/element-attributes.ts:48

<aparte-chat-status> — A standalone status line — a light-DOM indicator the APP owns. Nothing in core turns it on: the framework host only ever flips it back OFF (on the first streamed token), and the four wrappers render one inside the viewport driven by their own isTyping prop.

ts
optional visible?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:50

Shows or hides the indicator.

ts
optional text?: string;

Defined in: packages/core/src/generated/element-attributes.ts:52

The line to show. Absent, the line is dots-only and the accessible name falls back to the locale’s typing word (“Typing” in English).


Defined in: packages/core/src/generated/element-attributes.ts:56

<aparte-chat-viewport> — The transcript surface: a light-DOM container with sticky scrolling, token streaming and segment-aware rendering.

ts
optional scroll-threshold?: number;

Defined in: packages/core/src/generated/element-attributes.ts:58

How close to the bottom still counts as “at the bottom”.

ts
optional max-rendered-bubbles?: number;

Defined in: packages/core/src/generated/element-attributes.ts:60

Caps how many bubbles stay in the DOM; older ones are released.

ts
optional loading?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:62

The transcript is on its way: a conversation was chosen and its messages are being fetched. The element draws two skeleton turns, marks its scroll surface aria-busy and names the wait for a screen reader; aparte-chat[center-empty] does not count a loading viewport as empty. Set by AparteConversationController through its binding, or by hand from a loop of your own (setLoading(true)).

ts
optional framework-managed?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:64

The wrapper’s explicit hands-off signal: set it and this element builds no wrapper of its own and relocates none of the nodes the FRAMEWORK renders into it, because the framework owns them. Not “none of its children”: core’s own scroll-to-bottom button is re-appended whenever it stops being last, and that path runs in this mode only. All four wrappers set it.

ts
optional data-busy?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:66

Reflected BY the element while a turn streams: the transcript is read-only meanwhile, and every bubble inside reads it (at connect, and when it changes). The vanilla path derives it from the repository; a framework host sets it through setTranscriptBusy(). Read-only from the outside.


Defined in: packages/core/src/generated/element-attributes.ts:70

<aparte-composer> — The root context for every aparte-composer-* primitive. It imposes no visual layout — the consumer owns the structure — and holds the shared state the parts read: the value, the streaming flag, pending attachments, whether a panel is up.

ts
optional placeholder?: string;

Defined in: packages/core/src/generated/element-attributes.ts:72

Fallback placeholder for <aparte-composer-input>, which reads it off this element when it carries none of its own. Changing it here reaches the inputs already on the page too.

ts
optional disabled?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:74

Disables the composer’s own controls — the input, send, add-attachment and <aparte-composer-action> buttons each read it. What you put in the toolbar is yours to disable.

ts
optional target?: string;

Defined in: packages/core/src/generated/element-attributes.ts:76

The id of the <aparte-chat> this composer drives.

ts
optional submit-on-enter?: boolean | "false";

Defined in: packages/core/src/generated/element-attributes.ts:78

Enter sends and Shift+Enter breaks the line (the default); set it to the string "false" to swap them. Read lazily by the submitOnEnter getter rather than observed.

ts
optional data-panel-active?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:80

Reflected BY the element while a panel (an elicitation, an approval) is mounted inside it; the shipped stylesheet keys off it. Read-only.

ts
optional data-panel-mode?: string;

Defined in: packages/core/src/generated/element-attributes.ts:82

Reflected BY the element while a panel is active: what the send button does meanwhile ('none' removes it — through this attribute, not by reaching into the button). Read-only.

ts
optional data-model-gated?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:84

Reflected BY the element when requireModelSelection is on and no model is selected: sending is blocked and the shipped stylesheet greys the composer. Read-only.


Defined in: packages/core/src/generated/element-attributes.ts:88

<aparte-composer-action> — Generic action button primitive for <aparte-composer>.

ts
optional icon?: string;

Defined in: packages/core/src/generated/element-attributes.ts:90

Icon key for aparteGlobalConfig.getIcon(), or raw SVG/HTML starting with <. A key the icon set does not hold renders AS TEXT (icon="star" draws the word star), so add it with registerIcons or pass the SVG.

ts
optional label?: string;

Defined in: packages/core/src/generated/element-attributes.ts:92

Accessible label (also used as tooltip)

ts
optional disabled?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:94

Disables the button

ts
optional action-id?: string;

Defined in: packages/core/src/generated/element-attributes.ts:96

Identifies WHICH button fired; carried as AparteActionClickEventDetail.actionId. Read lazily at dispatch time rather than observed, so changing it takes effect on the next click.


Defined in: packages/core/src/generated/element-attributes.ts:100

<aparte-composer-add-attachment> — File picker button for <aparte-composer>.

ts
optional accept?: string;

Defined in: packages/core/src/generated/element-attributes.ts:102

MIME types / extensions the composer admits (e.g. “image/*,.pdf”): the file input’s filter, and checked again on a pick, a drop and a pasted image, so a file outside it is not attached however it arrives.

ts
optional multiple?: boolean | "false";

Defined in: packages/core/src/generated/element-attributes.ts:104

Allow multiple file selection (default: true)

ts
optional disabled?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:106

Greys out the picker. Drops are gated by the composer root’s disabled, not by this one.


Defined in: packages/core/src/generated/element-attributes.ts:110

<aparte-composer-input> — Contenteditable text input primitive.

ts
optional placeholder?: string;

Defined in: packages/core/src/generated/element-attributes.ts:112

Placeholder text (fallback: reads from aparte-composer)

ts
optional max-height?: number;

Defined in: packages/core/src/generated/element-attributes.ts:114

Max height in px before scroll (default: 200)

ts
optional min-height?: number;

Defined in: packages/core/src/generated/element-attributes.ts:116

Min height in px. When omitted, the stylesheet’s min-height governs (44px in aparte.css) — so themes can resize the editor in pure CSS without being fought by an inline height.

ts
optional disabled?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:118

Makes the field non-editable; the composer’s own disabled also reaches it.


Defined in: packages/core/src/generated/element-attributes.ts:122

<aparte-composer-toolbar> — The composer’s bottom row — the strip a mode picker, a model selector or a token counter belongs in, rather than a bar of your own floating below the chat. Purely structural: it lays its children out in a row and gets out of the way.

ts
optional data-empty?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:124

Reflected BY the element while it holds neither a visible element child nor non-whitespace text; the stylesheet hides it then. A child that hides itself — hidden, or its own data-empty the way <aparte-context> does before its first usage — does not count: a row whose only child shows nothing is an empty band with a border. Read-only, do not set it yourself.


Defined in: packages/core/src/generated/element-attributes.ts:128

<aparte-context> — A gauge of the model’s context window: how much of it the conversation uses, and what fills it.

ts
optional window?: number;

Defined in: packages/core/src/generated/element-attributes.ts:130

The context window, in tokens. Overrides the current model’s contextWindow.

ts
optional warn?: number;

Defined in: packages/core/src/generated/element-attributes.ts:132

Fraction of the window at which the level turns warn. Default 0.75.

ts
optional danger?: number;

Defined in: packages/core/src/generated/element-attributes.ts:134

Fraction at which it turns danger. Default 0.9.

ts
optional target?: string;

Defined in: packages/core/src/generated/element-attributes.ts:136

The id of the <aparte-chat> to watch, when the element is not under it.

ts
optional variant?: string;

Defined in: packages/core/src/generated/element-attributes.ts:138

bar (default) or ring: a progress bar with the reading beside it, or a ring with the percentage.

ts
optional used?: number;

Defined in: packages/core/src/generated/element-attributes.ts:140

Tokens in use before a turn of this page has reported any: a restored conversation’s last usage. The next turn’s usage replaces it.

ts
optional data-level?: string;

Defined in: packages/core/src/generated/element-attributes.ts:142

Reflected BY the element: ok, warn or danger. Read-only.

ts
optional data-empty?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:144

Reflected BY the element while it has nothing to show. Read-only.

ts
optional data-compact?: string;

Defined in: packages/core/src/generated/element-attributes.ts:146

Reflected BY the element while this chat is being compacted (running) and after a compaction failed (failed). Read-only.


Defined in: packages/core/src/generated/element-attributes.ts:150

<aparte-conversation-list> — Conversation-history sidebar — a framework-agnostic web component. The host sets the conversations JS property and the active-id attribute; this renders the rows and fires the user’s intent. Acting on it is the host’s, unless manage hands the row menu’s writes to the registered conversation manager.

ts
optional active-id?: string;

Defined in: packages/core/src/generated/element-attributes.ts:152

The id of the conversation to render as selected.

ts
optional flat?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:154

Render the rows flat, in host order, with no date headings.

ts
optional loading?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:156

The list is on its way: six skeleton rows stand where the rows will be, the element is aria-busy and a visually hidden line names the wait. A list that is not there yet is not an empty list. Set it while your store answers, clear it when you assign conversations.

ts
optional manage?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:158

Let the list finish the gesture: rename, pin, unpin, archive, unarchive and delete are performed on the conversation manager registered with setConversationManager(), instead of leaving you six listeners to write. The event still fires first, and preventDefault() on it takes the gesture back. Off by default, and selecting stays yours either way.

ts
optional data-no-match?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:160

Reflected BY the element while filter() holds a query no title matches. Read-only.


Defined in: packages/core/src/generated/element-attributes.ts:164

<aparte-icon> — AparteIcon

ts
optional name?: string;

Defined in: packages/core/src/generated/element-attributes.ts:166

Which glyph to draw. One of the names setIconProvider accepts; an unknown name draws nothing rather than a broken-image box.


Defined in: packages/core/src/generated/element-attributes.ts:170

<aparte-launcher> — A chat that floats in a corner of the page — the support widget every product site has, as an element. A round button sits at the bottom of the window, on the inline-end side; a click opens the chat above it as a card, and a second click, Escape or any control marked data-aparte-launcher-close inside closes it again.

ts
optional open?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:172

The chat is open. Reflected; set it to start open.

ts
optional label?: string;

Defined in: packages/core/src/generated/element-attributes.ts:174

Text shown beside the bubble on the closed button, which then reads as a pill. Without it the button is round and named by the locale.

ts
optional breakpoint?: string;

Defined in: packages/core/src/generated/element-attributes.ts:176

The window width under which the open chat fills the window: a length, or none for a card at any size. Unset, a window under 30rem wide or 30rem high.

ts
optional data-sheet?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:178

Reflected BY the element while the window is narrower than breakpoint (30rem unless you set it). Read-only.


Defined in: packages/core/src/generated/element-attributes.ts:182

<aparte-optgroup> — AparteOptgroup

ts
optional label?: string;

Defined in: packages/core/src/generated/element-attributes.ts:184

Group label

ts
optional collapsible?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:186

Adds the chevron and the click handler to the header — so it needs a label, and it is read only when that header is first built.

ts
optional collapsed?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:188

Collapsed state

ts
optional loading?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:190

Appends a spinner row to the group; the options stay visible.


Defined in: packages/core/src/generated/element-attributes.ts:194

<aparte-option> — AparteOption

ts
optional value?: string;

Defined in: packages/core/src/generated/element-attributes.ts:196

Option value

ts
optional disabled?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:198

Disabled state

ts
optional selected?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:200

Selected state

ts
optional data-status?: string;

Defined in: packages/core/src/generated/element-attributes.ts:202

Free-form status the host sets; styled, never read by core.


Defined in: packages/core/src/generated/element-attributes.ts:206

<aparte-progress-spinner> — AparteProgressSpinner

ts
optional value?: number;

Defined in: packages/core/src/generated/element-attributes.ts:208

Progress percentage 0–100 (omit for indeterminate)


Defined in: packages/core/src/generated/element-attributes.ts:212

<aparte-scroll-rail> — A rail of ticks beside the transcript — one per turn — that shows where you are in a long conversation and jumps back to any message on a click.

ts
optional target?: string;

Defined in: packages/core/src/generated/element-attributes.ts:214

The id of the <aparte-chat> to follow, when the element is not inside it.

ts
optional every?: string;

Defined in: packages/core/src/generated/element-attributes.ts:216

user (default): one tick per user turn. message: one per message.

ts
optional data-empty?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:218

Reflected BY the element while it has fewer than two ticks. Read-only.


Defined in: packages/core/src/generated/element-attributes.ts:222

<aparte-select> — Dropdown select for aparté — a vanilla web component with optional grouping, a search filter and a keyboard-driven listbox.

ts
optional value?: string;

Defined in: packages/core/src/generated/element-attributes.ts:224

The selected option’s value.

ts
optional placeholder?: string;

Defined in: packages/core/src/generated/element-attributes.ts:226

Shown while nothing is selected.

ts
optional disabled?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:228

Blocks opening the dropdown.

ts
optional searchable?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:230

Adds a filter field above the options. Set or removed later, the field comes or goes.

ts
optional open?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:232

Reflects (and controls) whether the dropdown is open.


Defined in: packages/core/src/generated/element-attributes.ts:236

<aparte-sidebar> — The column beside the chat — conversations, a new-chat button, a search field, an account row — as an element, because it has behaviour: it collapses, it becomes a drawer on a narrow window, and its search field filters the conversation list.

ts
optional collapsed?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:238

Hidden (in the flow) or closed (as a drawer). Reflected; set it to start closed.

ts
optional breakpoint?: string;

Defined in: packages/core/src/generated/element-attributes.ts:240

The window width under which the sidebar becomes a drawer: a length (default 48rem), or none for a column that never does.

ts
optional data-drawer?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:242

Reflected BY the element while the window is narrower than breakpoint (48rem unless you set it). Read-only.


Defined in: packages/core/src/generated/element-attributes.ts:246

<aparte-split> — Two panes and a draggable seam — a chat beside a preview, an editor, an artifact card.

ts
optional position?: number;

Defined in: packages/core/src/generated/element-attributes.ts:248

The primary pane’s size, as a percentage of the container. Reflected on commit, never per drag frame.

ts
optional orientation?: string;

Defined in: packages/core/src/generated/element-attributes.ts:250

horizontal (panes side by side, the default) or vertical (stacked). Names the CONTAINER’s axis.

ts
optional primary?: string;

Defined in: packages/core/src/generated/element-attributes.ts:252

start (default) or end: which pane position sizes.

ts
optional collapsed?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:254

The primary pane folded to its minimum. Enter on the seam toggles it; a second Enter restores the size it had.

ts
optional breakpoint?: string;

Defined in: packages/core/src/generated/element-attributes.ts:256

Below this width the split shows one pane at a time. A length (default 48rem), or none to never stack.

ts
optional pane?: string;

Defined in: packages/core/src/generated/element-attributes.ts:258

start (default) or end: which pane is shown while stacked.

ts
optional disabled?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:260

No drag, no keys, no tab stop; the seam stays drawn.

ts
optional label?: string;

Defined in: packages/core/src/generated/element-attributes.ts:262

The seam’s accessible name. Defaults to the locale’s splitHandleLabel.

ts
optional single?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:264

Show one pane — the one pane names — whatever the width: the seam and the other pane are gone, as under the breakpoint. For a host that decides itself when a second pane exists (a preview with nothing to preview yet). collapsed is not this: it folds the primary pane to --aparte-split-min and keeps the seam. The CSS route, .aparte-split--only-start / --only-end, is the same state for a host that owns its breakpoints.

ts
optional data-stacked?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:266

Written BY the element while one pane is shown. Read-only; style against it.


Defined in: packages/core/src/generated/element-attributes.ts:270

<aparte-suggestions> — Prompt starters — a row of suggested prompts a reader clicks instead of typing.

ts
optional suggestions?: string;

Defined in: packages/core/src/generated/element-attributes.ts:272

The starters, as a JSON array: strings, or { "label", "prompt" } objects when the visible label and the sent text differ. The suggestions PROPERTY takes the same shape without the JSON.

ts
optional target?: string;

Defined in: packages/core/src/generated/element-attributes.ts:274

The id of the <aparte-chat> whose composer should receive the click, when the element is not inside that composer.

ts
optional empty-only?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:276

Shows the row only while the conversation it serves is empty: hidden (hidden) once a message is in its transcript or on its way — a thread being loaded counts — and shown again when the transcript is cleared, by a new chat for instance. The composer’s send hides it at once, before its message lands. The element sets and lifts hidden itself and never lifts one you set. With no transcript to read — a composer outside any chat — the first send hides it until the attribute is removed.

ts
optional answers?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:278

Shows the replies the LAST message offered instead of fixed starters: a code block in language suggestions in that answer (setupSuggestionBlocks), e.g. the free times a booking bot proposes. Written by the model, so a reply sends what its chip shows: its label, never a prompt. Empty until an answer offers some, emptied the moment a message is sent, and when the last message is the person’s.

ts
optional mode?: string;

Defined in: packages/core/src/generated/element-attributes.ts:280

send (default): the click fills the composer and submits. fill: the click fills the composer and focuses it, so the reader edits first.

ts
optional data-empty?: boolean;

Defined in: packages/core/src/generated/element-attributes.ts:282

Reflected BY the element while it has no suggestion to show; the stylesheet hides it then. Read-only, do not set it yourself.


Defined in: packages/core/src/generated/element-attributes.ts:298

Tag name to its attribute surface — the registry every wrapper maps over.

Total by construction: it is generated from the manifest, so an element cannot be missing from it, which is the property a hand-written list could not have.

ts
aparte-chat: AparteChatAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:299

ts
aparte-chat-bubble: AparteChatBubbleAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:300

ts
aparte-chat-status: AparteChatStatusAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:301

ts
aparte-chat-viewport: AparteChatViewportAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:302

ts
aparte-composer: AparteComposerAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:303

ts
aparte-composer-action: AparteComposerActionAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:304

ts
aparte-composer-add-attachment: AparteComposerAddAttachmentAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:305

ts
aparte-composer-attachments: AparteNoAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:306

ts
aparte-composer-cancel: AparteNoAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:307

ts
aparte-composer-input: AparteComposerInputAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:308

ts
aparte-composer-send: AparteNoAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:309

ts
aparte-composer-toolbar: AparteComposerToolbarAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:310

ts
aparte-context: AparteContextAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:311

ts
aparte-conversation-list: AparteConversationListAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:312

ts
aparte-elicitation: AparteNoAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:313

ts
aparte-icon: AparteIconAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:314

ts
aparte-launcher: AparteLauncherAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:315

ts
aparte-optgroup: AparteOptgroupAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:316

ts
aparte-option: AparteOptionAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:317

ts
aparte-progress-spinner: AparteProgressSpinnerAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:318

ts
aparte-scroll-rail: AparteScrollRailAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:319

ts
aparte-select: AparteSelectAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:320

ts
aparte-sidebar: AparteSidebarAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:321

ts
aparte-split: AparteSplitAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:322

ts
aparte-suggestions: AparteSuggestionsAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:323


Defined in: packages/core/src/primitives/select/aparte-select.ts:8

ts
value: string;

Defined in: packages/core/src/primitives/select/aparte-select.ts:9

ts
label: string;

Defined in: packages/core/src/primitives/select/aparte-select.ts:10

ts
previousValue: string;

Defined in: packages/core/src/primitives/select/aparte-select.ts:11


ts
type AparteComposerPanelMode = "submit" | "none";

Defined in: packages/core/src/components/composer/aparte-composer.ts:25

What the composer’s one button means while a panel is up — and whether it is there at all.

'submit' answers, and 'none' says this panel has NO act left for that button, so it is not drawn. The chips are the navigation through a form’s questions, so the button never means “next”.

'none' is for a panel whose options settle on the first click (an approval, a single-choice question): a button beside them would sit permanently disabled, meaning nothing. A control that is never the way forward is not disabled, it is absent.

Named rather than inlined at each of its six readers, so they share one list.


ts
type AparteComposerEventType = keyof AparteComposerEventMap;

Defined in: packages/core/src/components/composer/aparte-composer.ts:52


ts
type AparteContextLevel = "ok" | "warn" | "danger";

Defined in: packages/core/src/components/context/aparte-context.ts:15

How full the window is, against the two thresholds.


ts
type AparteScrollRailEvery = "user" | "message";

Defined in: packages/core/src/components/scroll-rail/aparte-scroll-rail.ts:13

What a tick is drawn for: one per user turn (the default), or one per message.


ts
type AparteSuggestion = 
  | string
  | {
  label: string;
  prompt?: string;
};

Defined in: packages/core/src/components/suggestions/aparte-suggestions.ts:14

One prompt starter: the text sent, or a visible label over a longer prompt.

A string is both. The object form is for the case every welcome screen has — “Write a haiku” on the chip, “Write a haiku about web components.” in the request.


ts
type AparteNoAttributes = Record<never, never>;

Defined in: packages/core/src/generated/element-attributes.ts:290

The elements that observe no attribute at all. An empty surface is the honest declaration — it says “checked, there are none”, where an absent entry would only say “not looked at”: <aparte-composer-attachments>, <aparte-composer-cancel>, <aparte-composer-send>, <aparte-elicitation>.


ts
type AparteElementTagName = keyof AparteElementAttributes;

Defined in: packages/core/src/generated/element-attributes.ts:327

Every tag this package defines, derived from the registry so the two cannot diverge.


Defined in: packages/core/src/components/composer/aparte-composer-action.ts:199

Detail payload for aparte-action-click.

<aparte-composer-action> is a publicly exported element whose only purpose is to emit this event, and nothing in core listens for it — so the app IS the consumer, and it had no type to read e.detail with. The shape was already published in prose in the generated API reference; this makes it compile.

aparte-action-click

ts
actionId: string;

Defined in: packages/core/src/components/composer/aparte-composer-action.ts:201

The action-id attribute of the button that was clicked, or ''.

ts
composer: AparteComposer | null;

Defined in: packages/core/src/components/composer/aparte-composer-action.ts:203

The owning composer, or null when the button is used outside one.


Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:60

A conversation’s state changed, on window. The conversation controller sends it as turns start, pause and end; every list on the page applies it to its row. null for neither state.

aparte-conversation-status

ts
id: string;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:61

ts
status: AparteConversationStatus | null;

Defined in: packages/core/src/components/conversation-list/aparte-conversation-list.ts:62


Defined in: packages/core/src/primitives/select/aparte-optgroup.ts:218

Detail payload for aparte-optgroup-toggle.

types/event-map.ts types aparte-optgroup-toggle with this detail, and @aparte/plugin-model-selector reads both of its fields, from another package, through an untyped cast — while the event is published in the generated CEM event table. It is a contract.

aparte-optgroup-toggle

ts
label: string;

Defined in: packages/core/src/primitives/select/aparte-optgroup.ts:220

The group’s label.

ts
collapsed: boolean;

Defined in: packages/core/src/primitives/select/aparte-optgroup.ts:222

true when the group just collapsed.