✨ Replace WebChat v2 With v3 on Main Branch#100
Open
cristiantela wants to merge 193 commits intomainfrom
Open
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #100 +/- ##
==========================================
- Coverage 66.14% 61.94% -4.21%
==========================================
Files 71 81 +10
Lines 3096 3747 +651
Branches 854 1024 +170
==========================================
+ Hits 2048 2321 +273
- Misses 1020 1378 +358
- Partials 28 48 +20 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Creates src/styles/mixins.scss with scrollable-container, scrollable-content and scrollbar-styles mixins. Registers the file in additionalData so it is globally available without per-file @use imports. Replaces all duplicated overflow/scrollbar declarations across views and components with @include calls. Made-with: Cursor
Adds the #ADADAD gray token required by the scrollbar-styles mixin for the default thumb color. Made-with: Cursor
…hing 🐛 Resolve ESLint Silently Ignoring All Files in Flat Config
…veal Introduces a hook that simulates a natural typing pace when streaming messages arrive faster than 70 ms/word. Words are revealed one at a time with a randomised delay (70 ± 20 ms) via recursive setTimeout, so the animation never looks mechanical. The loop only stops after all buffered words are shown AND the streaming status has ended, preventing the effect from being cut short by a fast stream. Also adds MessagesScrollContext to decouple the scroll-to-bottom callback from the component tree, consumed directly by the hook. Made-with: Cursor
…mingBuffer Removes all buffering state, refs and effects from the component and delegates them to useStreamingBuffer, keeping MessageText focused on rendering. The caret indicator now follows isBuffering instead of isStreaming, so it stays visible until the last word is revealed. Made-with: Cursor
Adds isNearBottomRef to track scroll position without stale state and scrollToBottomOnReveal (instant, near-bottom-only) provided via MessagesScrollProvider. This keeps the list anchored to the bottom while words are buffered, without interfering when the user has scrolled up to read older messages. Made-with: Cursor
Covers initial state, word-by-word reveal timing, onWordRevealed callback invocation, mid-stream text growth, and the full streaming lifecycle (buffering continues after status ends, stops only when queue is empty). MessagesScrollContext tests verify null fallback outside the provider, callback delivery, and re-render propagation. Made-with: Cursor
✨ Centralise Scroll Styles into Reusable SCSS Mixins with Custom Scrollbar
✨ Simulate Word-by-Word Typing Pace for Streaming Messages
Handle messages of type "file" that arrive with a media_url and optional caption instead of text. MessageDocument now defensively reads metadata, falls back to inferring mimeType from the URL extension, and displays caption when filename is unavailable. Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Cover label fallback chain, mimeType inference from URL extension, window.open gating by ALLOWED_DOCUMENT_TYPES, direction styling, and MessageImage anchor (open in new tab) behavior. Co-authored-by: Cursor <cursoragent@cursor.com>
✨ Handle `file` Message Type with mimeType Fallback and Image Open-in-New-Tab
…onent Remove the count/max display logic from Badge, turning it into a minimal dot indicator. Move absolute positioning from Launcher into Badge itself so placement is self-contained. Co-authored-by: Cursor <cursoragent@cursor.com>
Rename the Tooltip component to Notification and move it to src/components/Notification/. Clicking the notification content now opens the webchat via onOpen, and long messages are clamped to three lines. The close button is prevented from shrinking on wide content. Adds full unit test coverage for all new behaviour. Co-authored-by: Cursor <cursoragent@cursor.com>
paulobernardoaf
approved these changes
May 7, 2026
✨ Redesign Tooltip as Notification With Open-on-Click and Line Clamp
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Type of Change
Motivation and Context
Version 2 of the WebChat widget has been deprecated. This pull request promotes the
v3-mainbranch as the new baseline formain. The v2 codebase will remain available and maintainable under thev2-mainbranch for any critical hotfixes that may be required.Summary of Changes
The key changes introduced by v3 include:
UI Redesign
InputBoxwith updated styles and draft-persistence across unmountsLauncher,Widget,Chat,Header, andMessagesListcomponentsChatPresentationcomponent for the initial chat stateThinkingIndicatorand updatedTypingIndicatorstylesWaveformVisualizercomponent; simplifiedVoiceModeButtonConversationStartersandQuickRepliesvisualsrounded-x(default launcher icon)New Features
positionparameter added, enabling the widget to be anchored to thebottom-leftcornerInputBoxunmountssetOrderFormaddProductToCartintegration for VTEX storefrontsBug Fixes & Compatibility
URL.canParsewith atry/catchblock for broader browser compatibility