New workspace components: - emit_card: structured detail card with title, subtitle, fields, actions Fields can be clickable links (action property) Used for: entity details (Kunde, Objekt, Auftrag) - emit_list: vertical list of cards for multiple entities Used for: search results, navigation lists - "WHEN TO USE WHAT" guide in expert prompt Frontend rendering: - renderCard() with key-value fields, clickable links, action buttons - List container with title + stacked cards - Full CSS: dark theme cards, hover states, link styling Pipeline: - ExpertNode handles emit_card/emit_list in tool execution - UINode passes card/list through as-is (not wrapped in display) - Test runner: check_actions supports "has card", "has list", "has X or Y" Workspace components test: 22/22 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1.1 KiB
1.1 KiB
Workspace Components
Tests that the expert emits structured UI components (cards, lists, tables) instead of dumping text or raw SQL. The workspace should show domain-aware displays.
Setup
- clear history
Steps
1. Detail card for a single entity
- send: zeig mir Details zu Kunde 2
- expect_trace: has tool_call
- expect_actions: has card
- expect_response: not contains "SELECT" or "JOIN"
- expect_response: length > 10
2. List of items with navigation
- send: zeig mir alle Objekte von Kunde 2
- expect_trace: has tool_call
- expect_actions: has card or has table
- expect_response: length > 10
3. Table for tabular data
- send: zeig mir die Geraete von Objekt 4
- expect_trace: has tool_call
- expect_actions: has table
- expect_response: length > 10
4. Card with actions (drill-down buttons)
- send: zeig mir Auftrag 21479
- expect_trace: has tool_call
- expect_actions: length >= 1
- expect_response: length > 10
5. Summary card with key metrics
- send: gib mir eine Zusammenfassung von Objekt 4
- expect_trace: has tool_call
- expect_actions: has card
- expect_response: length > 20