const { aparteGlobalConfig } = window.aparte;
// One line after the tool's name: what it targeted. Plain text, never HTML; the row,
// its states and its disclosure stay the library's.
aparteGlobalConfig.registerToolSummary('read_file', (segment) => String(segment.toolCall.input.path ?? ''));
aparteGlobalConfig.registerToolSummary('search_docs', (segment) => `“${segment.toolCall.input.query}”`);
document.querySelector('aparte-chat-bubble').setSegments([
{ id: 's1', type: 'tool_call', status: 'resolved', toolCall: { id: 't1', name: 'search_docs', input: { query: 'release checklist' } }, result: '3 pages' },
{ id: 's2', type: 'tool_call', status: 'resolved', toolCall: { id: 't2', name: 'read_file', input: { path: 'docs/release.md' } }, result: '## Release' },
]);