Skip to content

feat(widget): fluent assistant-ui-style UI and internal refactor - #57

Merged
Asaf-prog merged 1 commit into
mainfrom
feat/widget-fluent-ui
Jul 27, 2026
Merged

feat(widget): fluent assistant-ui-style UI and internal refactor#57
Asaf-prog merged 1 commit into
mainfrom
feat/widget-fluent-ui

Conversation

@AmitAvital1

Copy link
Copy Markdown
Collaborator

Stack 1/4 · base: main

Rebuilds the embeddable chat widget to match assistant-ui's AssistantModal 1:1 — fluent 60fps open/close animations, a neutral professional palette, welcome empty-state, ErrorPrimitive-style alerts, and "Powered by Extra". Internals refactored into a layered widget module (config, api client, react app, storage, styles) so the public contract stays just the <agent-chat> tag + attributes.

Verified: typecheck:widget, test:widget, Playwright e2e all green.

🤖 Generated with Claude Code

Bring the embeddable chat widget to assistant-ui parity in feel while
keeping the framework-agnostic custom-element contract intact.

UI:
- FAB press/hover feedback and bot<->chevron icon morph on open/close
- Panel opens with a corner-origin zoom/slide on the iOS settle curve,
  faster out than in; composer cascades in after the panel
- Centered welcome empty-state ("How can I help you today?")
- Neutral, professional default palette (zinc-900) that adopts any host
- Message-level error rendered as an accessible destructive alert
- Copy action bar revealed on hover of assistant replies
- Roomier input; scrollbar clipped to the rounded field and only shown
  once the field reaches its max height
- "Powered by Extra" footer
- All motion respects prefers-reduced-motion

Refactor:
- Extract conversation lifecycle (id storage, create, 404-recovery,
  history) into useConversation behind a typed Conversation interface
- Replace the mutable stream handler with a pure reduceStreamEvent fold
- Split message rendering into named components; drop ~130 lines of
  hand-copied SVG in favour of lucide-react

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@Asaf-prog
Asaf-prog merged commit ee6ec09 into main Jul 27, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ui enhancement User-facing UI improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants