Skip to content
This repository was archived by the owner on May 15, 2026. It is now read-only.

feat: In-extension dismissible upsells for Roo Code Cloud - #7850

Merged
jr merged 34 commits into
mainfrom
feat/rcc-upsells
Sep 10, 2025
Merged

feat: In-extension dismissible upsells for Roo Code Cloud#7850
jr merged 34 commits into
mainfrom
feat/rcc-upsells

Conversation

@brunobergher

@brunobergherbrunobergher commented Sep 10, 2025

Copy link
Copy Markdown
Collaborator

Description

Adds in-app upsells for Roo Code Cloud.
Introduces a new DismissibleUpsell React component, which ensures messages are displayed in a consistent way and enforces dismissal logic, so we don't annoy users. The dismissal state is persisted in the VS Code extension's global state, ensuring they do not reappear after a user has closed them.

Key implementation details include:

  • A shared DismissibleUpsell component
  • A centralized CloudUpsellDialog component, which is called from different places
  • Integration of these upsell CTAs into several key user workflows:
    • On the extion home page.
    • Within the "AutoApprove" settings menu.
    • After a long-running task runs for a while.
  • CloudUpsellDialog is also used in the "Share Task" and "Cloud View" screens, reducing duplication
  • Robust state management to handle component mounting/unmounting and prevent common issues like race conditions or memory leaks during asynchronous operations.

Test Procedure

The functionality was tested via a combination of new unit tests and manual verification.

Unit Tests:

Comprehensive tests were added for the DismissibleUpsell component, covering its variants, dismissal logic, and various edge cases such as rapid dismissals and state updates on unmounted components.
Tests for the auto-approve upsell functionality were also created and fixed.

Manual Testing:

To verify the changes, reviewers can perform the following steps:

  1. Navigate to the Roo Code home page and confirm the new CTA is visible.
  2. Open the "AutoApprove" menu and enable several options
  3. Run a task that takes a significant amount of time and check that the upsell appears after a while
  4. Dismiss one of the upsells, then restart the extension to ensure it remains dismissed.
  5. Verify that all new UI text has been correctly internationalized.

Screenshots


Important

Introduces in-app dismissible upsells for Roo Code Cloud with new React components, state management, and internationalization support.

  • Behavior:
    • Adds DismissibleUpsell React component for consistent message display and dismissal logic.
    • Integrates upsells into workflows: extension home page, "AutoApprove" settings, long-running tasks, "Share Task", and "Cloud View".
    • Uses CloudUpsellDialog to reduce duplication in "Share Task" and "Cloud View".
    • Persists dismissal state in VS Code extension's global state.
  • State Management:
    • Manages component mounting/unmounting to prevent race conditions and memory leaks.
  • Testing:
    • Adds unit tests for DismissibleUpsell covering variants, dismissal logic, and edge cases.
    • Tests auto-approve upsell functionality.
    • Manual testing includes verifying CTA visibility, dismissal persistence, and internationalization.
  • Internationalization:
    • Updates translations in multiple languages to support new upsell messages.

This description was created by Ellipsis for 9610626. You can customize this summary. It will automatically update as commits are pushed.

Bruno Bergherand others added 25 commits September 8, 2025 16:28
…#7783)
Fixes#7703 - CodeBlock language dropdown and copy button were appearing above popovers due to z-index: 100. Reduced to z-index: 40 to maintain proper layering hierarchy while keeping buttons functional.
…or chat messages (#7790)
* feat: add click-to-edit, ESC-to-cancel, and fix padding consistency
- Enable click-to-edit for past messages by making message text clickable
- Add ESC key handler to cancel edit mode in ChatTextArea
- Fix padding consistency between past and queued message editors
- Adjust right padding for edit mode to accommodate cancel button
Fixes#7788
* fix: adjust padding and layout for ChatTextArea in edit mode
* refactor: replace hardcoded pr-[72px] with standard Tailwind pr-20 class
---------
Co-authored-by: Roo Code <roomote@roocode.com>
Co-authored-by: Hannes Rudolph <hrudolph@gmail.com>
Co-authored-by: daniel-lxs <ricciodaniel98@gmail.com>
Co-authored-by: roomote[bot] <219738659+roomote[bot]@users.noreply.github.com>
Co-authored-by: Bruno Bergher <me@brunobergher.com>
Co-authored-by: Roo Code <roomote@roocode.com>
Co-authored-by: Hannes Rudolph <hrudolph@gmail.com>
Co-authored-by: daniel-lxs <ricciodaniel98@gmail.com>
feat: add taskSyncEnabled to userSettingsConfigSchema
Co-authored-by: Roo Code <roomote@roocode.com>
chore: bump version to v1.75.0
…ls chart (#7830)
Co-authored-by: Roo Code <roomote@roocode.com>
- Created DismissibleUpsell component with variant support (banner/default)
- Added dismissedUpsells to GlobalState for persistence
- Implemented message handlers for dismissing and retrieving dismissed upsells
- Added comprehensive tests for the component
- Uses VSCode extension globalState for persistent storage
- Changed from className to separate 'id' and 'className' props for better semantics
- Added i18n support for accessibility labels (aria-label and title)
- Fixed memory leak by adding mounted flag to prevent state updates after unmount
- Fixed race condition by sending dismiss message before hiding component
- Fixed inefficient array operations in webviewMessageHandler
- Added comprehensive test coverage for edge cases including:
- Multiple rapid dismissals
- Component unmounting during async operations
- Invalid/malformed message handling
- Proper message sending before unmount
- Added null checks for message data to handle edge cases gracefully

ghost left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your contribution! I've reviewed the changes and found some issues that need attention. The implementation of dismissible upsells is well-structured overall with good test coverage, but there are a few important items to address.

<tool>gh pr checkout [PR_NUMBER] --force</tool>
<tool>git fetch origin main</tool>
<tool>git rebase origin/main</tool>
<tool>GIT_EDITOR=true git rebase origin/main</tool>

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These changes to the merge resolver rules appear unrelated to the upsell feature. Could you remove these files from this PR to keep it focused on the dismissible upsells implementation?

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have no idea how they ended up here. If a reviewer has any thoughts, I'm all ears.

Comment threadpackages/types/src/cloud.ts
Comment threadwebview-ui/src/components/common/DismissibleUpsell.tsx
Comment threadwebview-ui/src/components/chat/AutoApproveMenu.tsx
Comment threadwebview-ui/src/components/chat/ChatView.tsx
Comment threadwebview-ui/src/components/cloud/CloudUpsellDialog.tsx
Comment threadwebview-ui/src/components/common/DismissibleUpsell.tsx
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

EnhancementNew feature or requestlgtmThis PR has been approved by a maintainerPR - Needs Reviewsize:XXLThis PR changes 1000+ lines, ignoring generated files.

Projects

No open projects
Archived in project

Development

Successfully merging this pull request may close these issues.

7 participants

@brunobergher@mrubens@daniel-lxs@jr@hannesrudolph@ItsOnlyBinary@roomote