Repository navigation
[Experiment] Show a pip and popup when a Copilot sale is ongoing and the chat is closed - #331588
Merged
Logan Ramos (lramos15) merged 33 commits intoSep 24, 2026
Merged
Conversation
Arm via Chat: Start Model Picker Tour (F1), show an activity badge on Chat, then open chat and spotlight the model picker when the view is revealed. Co-authored-by: Copilot App <[email protected]>
When a model has a live discount, skip the chat-input banner and open the post-update card with one Try CTA. The CTA opens chat and switches the model the same way the banner does. Close and CTA share the banner dismissal store. Remove the out-of-scope model picker tour. Co-authored-by: Copilot App <[email protected]>
Contributor
There was a problem hiding this comment.
Pull request overview
Replaces discounted chat promo banners with the reusable post-update sale card while preserving message-only banners and shared dismissal state.
Changes:
- Adds sale-card display, dismissal, and model-switch commands.
- Extends update-card metadata and dismissal handling.
- Updates promo tests and adds model-picker onboarding scaffolding.
Show a summary per file
| File | Description |
|---|---|
updateInfoParser.ts |
Parses dismissal command metadata. |
postUpdateWidget.ts |
Supports dismissal callbacks and formatted feature icons. |
chatPromoNotification.test.ts |
Updates promo behavior tests. |
modelPickerWidget.ts |
Adds an onboarding target marker. |
chatPromoNotification.ts |
Routes discounted promos to sale cards. |
chatActions.ts |
Exports the toggle-chat action ID. |
Review details
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
- Files reviewed: 6/6 changed files
- Comments generated: 5
- Review effort level: Balanced
Keep TOGGLE_CHAT_ACTION_ID file-local and remove the onboarding spotlight target from the model picker. Neither is needed for the sale card. Co-authored-by: Copilot App <[email protected]>
Add a banner|popup setting (default banner) with an ExP auto override. Keep the post-update sale card on-screen when the window is narrow: size to the viewport, drop the fixed 80px gutter, and re-place on layout. Co-authored-by: Copilot App <[email protected]>
Co-authored-by: Copilot App <[email protected]>
Take Logan's promo showBanner plumbing (hasPromoBanner is opt-out unless showBanner is false). Keep the closed-chat Copilot icon pip and popup after that gate. Co-authored-by: Copilot App <[email protected]>
Drop the copied post-update widget changes, preview command, and unused sale-card extras. Keep the collapsed-chat Copilot-icon pip and popup after hasPromoBanner. Codex and Claude sales stay on their input banners. Co-authored-by: Copilot App <[email protected]>
Keep the Copilot-icon popup only while Chat is collapsed so expanded Chat still uses the input banner. Drop extra SKU, entitlement, and unselectable gates, slim the card payload, and activate the pip via click, keyboard, and touch. Recover the pip class if the status entry rebuilds. Co-authored-by: Copilot App <[email protected]>
Use typed card data and the shared Button, refresh changed promo payloads, recover replaced status entries and restore icons on disposal. Complete the Sale-to-Promo naming cleanup within the feature and cover refresh, dismissal and lifecycle regressions. Co-authored-by: Copilot App <[email protected]>
Honor explicit closed-promo settings without reading ExP. Resolve the configured treatment only for eligible collapsed-chat promos with a visible status icon, preserve control banners, and reject stale responses. Remove eager experimental-default enrollment and cover override, visibility, refetch, failure and disposal behavior. Co-authored-by: Copilot App <[email protected]>
The collapsed-chat pip could re-offer a sale the user had already met as a banner in an open chat. Record a promo as seen the first time a chat input actually renders it, and stand the pip down for that promo id. The record is application-scoped, so it holds across windows and reloads, and a later sale still gets its own pip. The experiment stays the last gate. Co-authored-by: Copilot App <[email protected]>
Opening Chat from a collapsed state resolves its session asynchronously, so the promo CTA read an undefined session and assumed the Local harness. A user who met the sale as a pip therefore landed on whichever session Chat restored, and the promoted model was never applied. Co-authored-by: Copilot App <[email protected]>
The collapsed-chat promo card fell back to a generic sparkle after the payload lost its provider icon. Pass the model provider icon through the card input again and cover it with a rendering test. Co-authored-by: Copilot App <[email protected]>
The hover host styles every codicon under .hover-contents with font-size: inherit, which outranked the card's own rule and shrank the model vendor mark to the card body font size. Scope the rule to the promo hover so it wins, and pin the size in the widget test. Co-authored-by: Copilot App <[email protected]>
Co-authored-by: Copilot App <[email protected]>
Move closed-chat pip eligibility into the promo widget, hide the pip only when Local chat is already showing the sale, and emit chatPromoWidgetShown, chatPromoWidgetDismissed, and chatPromoWidgetAction telemetry with tests. Co-authored-by: Copilot App <[email protected]>
Contributor
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Hidden banners can suppress the intended pip, and failed hover creation can permanently dismiss an unseen promotion.
Get a fresh assessment by requesting another Copilot review.
Review tier: Balanced
Findings: 4
Open (4)
Resolved since last review (5)
The unchanged-promo fast path above compares only model and promo IDs, but this new branch also… This reaches directly from the chat contribution into onboarding's browser-internal implementation,… This CTA is not equivalent to the banner action for models scoped to a non-local… The promo is marked as shown before_update.showUpdateInfoactually displays anything. A… These newly parsed dismissal fields are not covered by the existing comprehensive…
Keep the status-bar pip discoverable, avoid permanent dismiss when the hover cannot open, use high-contrast borders, and defer input-notification onDidShow until the Chat host is actually visible. Co-authored-by: Copilot App <[email protected]>
Use a fixed 110px left wash at 33% button tint so every sale card gets the same leading-edge gradient regardless of width. Co-authored-by: Copilot App <[email protected]>
Co-authored-by: Copilot App <[email protected]>
Split opportunity detection (closed Local Chat + eligible sale) and treatment selection (config/policy/TAS) out of ChatPromoWidgetContribution so future closed-Chat treatments can branch independently of the Copilot icon popup. Co-authored-by: Copilot App <[email protected]>
Combine opportunity detection and treatment selection into one feature-local helper owned by the promo contribution, matching tip-style non-Service naming. Co-authored-by: Copilot App <[email protected]>
Remove setHostVisible / deferred onDidShow for hidden Chat hosts. That path only covered collapsed-but-still-mounted Chat and is not a product case we want to engineer for. Co-authored-by: Copilot App <[email protected]>
ChatClosedPromoContribution owns eligibility, treatment, and background listeners, and drives ChatPromoIconPopup as presentation-only. Co-authored-by: Copilot App <[email protected]>
Ralph Feltis (rfeltis)
marked this pull request as ready for review
September 16, 2026 22:56
Keep closed-promo constants/import alongside main's agent session cleanup tag and agentSessionsConfiguration import. Co-authored-by: Copilot App <[email protected]>
Sinon withArgs is arity-typed to store(); count matching store calls by args instead. Type the hover mock options parameter. Co-authored-by: Copilot App <[email protected]>
Co-authored-by: Copilot App <[email protected]>
Use DOM.isHTMLElement and dataset dot notation, track labeled nodes without querySelectorAll, and scope status-bar lookups with no-restricted-syntax disables. Co-authored-by: Copilot App <[email protected]>
Always forward the current opportunity model to the icon popup so title and payload updates apply even when the promo id is unchanged. Co-authored-by: Copilot App <[email protected]>
Agent Host Provider Integration idle-release timeout is unrelated to the closed-chat promo changes. Co-authored-by: Copilot App <[email protected]>
Replace the custom popup and DOM interception with the standard status-bar tooltip and action. Preserve status priority, seen-promo state, keyboard focus, and restored chat sessions, with focused regression coverage. Refactors microsoft#331588. Co-authored-by: Copilot <[email protected]>
Contributor
📬 CODENOTIFYThe following users are being notified based on files changed in this PR: Benjamin Christopher Simmonds (@benibenj)Matched files:
|
Preserve upstream tooltip toggling, configuration registration, and input-scoped notifications alongside the native status-bar promo refactor. Extend promo interaction coverage to verify toggling closes and reopens the offer without dismissing it. Co-authored-by: Copilot <[email protected]>
Logan Ramos (lramos15)
previously approved these changes
Sep 24, 2026
Michael Lively (Yoyokrazy)
previously approved these changes
Sep 24, 2026
Preserve upstream managed-hover cancellation when replacing a pinned promo tooltip. Keep focus handling and verify replacement content remains active until the hover is dismissed. Co-authored-by: Copilot <[email protected]>
Logan Ramos (lramos15)
dismissed stale reviews from Michael Lively (Yoyokrazy) and themself
via
September 24, 2026 20:24
a50db7f
Logan Ramos (lramos15)
approved these changes
Sep 24, 2026
Dmitriy Vasyura (dmitrivMS)
approved these changes
Sep 24, 2026
Logan Ramos (lramos15)
enabled auto-merge (squash)
September 24, 2026 21:29
Logan Ramos (lramos15)
merged commit Sep 24, 2026
dfb272f
into
microsoft:main
36 of 38 checks passed
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.


Adds a dedicated Copilot-icon pip and promo popup for eligible discounted models while Chat is collapsed. Expanded Chat retains the existing input banner. Shared post-update components and model-picker promo behavior are unchanged. Clicking the pip or expanding the chat when the banner in the chat exists will dismiss the pip.
Will be run as an experiment: https://exp.microsoft.com/features/8af04802-561e-4474-8d57-f9e71d1fadd6/progressions?workspaceId=dbd12384-5001-4e90-a863-526321eaf233
Validation
69 targeted tests pass at
0a6e1869, covering configuration bypass, no enrollment for ineligible or hidden surfaces, delayed responses, revocation, existing status-entry behavior, the seen-promo rule, the cold-Chat CTA, and the card vendor icon and its size.End-to-end proof was re-recorded against this branch tip (
6f581e3) in a Codespace, driving the real Code OSS window with a mocked sale fixture on real upstream models. Icons and status bar are healthy (24-bit display). The closed-promo card uses a fixed 110px left wash at 33% button tint.Treatment —
copilotIconPopupSale arrives against a collapsed Chat: the Copilot pip appears, the promo card opens, and Try opens Chat and selects the promoted model. Telemetry records shown and CTA actions.
https://raw.githubusercontent.com/rfeltis/vscode/pr-331588-sale-media/treatment-cta.mp4?v=9
Control —
noneSame sale against a collapsed Chat with
chat.closedPromoNotificationforced tonone. No pip on the Copilot status icon. Opening Chat still shows no pip.https://raw.githubusercontent.com/rfeltis/vscode/pr-331588-sale-media/control.mp4?v=10
Already met the sale — Local banner marks seen
Sale opens against a collapsed Chat: the treatment pip appears. Opening Chat on Local shows the sale banner (
onDidShowrecords the promo id). Collapsing Chat after that does not restore the pip for the same sale.https://raw.githubusercontent.com/rfeltis/vscode/pr-331588-sale-media/seen.mp4?v=10
Closed-chat cards on hosted models (still GitHub Copilot)
Same pip + card treatment when Copilot puts a hosted model on sale (OpenAI/GPT, MAI, Anthropic, Grok). Product LM vendor remains
copilot; OpenAI / Microsoft / Anthropic / xAI are manufacturer metadata only. Open-chat banners are unchanged and not shown here. Card gradient: 33% tint, 110px stop.GPT-5.3-Codex (OpenAI)
MAI-Code-1.1-Flash (Microsoft)
Claude Opus 4.7 (Anthropic)
Grok 4.5 (xAI)
Tracked as github/growth-eng#134.