Skip to content

feat(search): add daily-dev-ask upsell banner on search page#5732

Open
capJavert wants to merge 9 commits intomainfrom
eng-1074-add-daily-dev-ask-upsell-on-web-search-page
Open

feat(search): add daily-dev-ask upsell banner on search page#5732
capJavert wants to merge 9 commits intomainfrom
eng-1074-add-daily-dev-ask-upsell-on-web-search-page

Conversation

@capJavert
Copy link
Contributor

@capJavert capJavert commented Mar 16, 2026

Summary

  • Add a dismissible AskSearchBanner component promoting daily-dev-ask to Plus users on the web search page
  • Banner follows the existing DigestBookmarkBanner pattern: accent-cabbage border card with icon, title, description, CTA link, and close button
  • Dismiss persistence via ActionType.AskUpsellSearch using the existing completeAction mutation
  • Analytics: impression logged on mount, click logged on CTA and dismiss

Key decisions

  • Plus-only visibility: Banner renders only for authenticated Plus users (inverse of DigestBookmarkBanner which targets non-Plus)
  • Always visible until dismissed: Shows both in empty state and with search results, since search is the highest-intent surface
  • CTA links to /agents/ask via Button with tag="a"
  • ActionType value ask_upsell_search: Stable string persisted in DB — chosen to be clear and consistent with existing naming

Test plan

  • 7 integration tests in AskSearchBanner.spec.tsx covering:
    • Renders for Plus users
    • Hidden for non-Plus users
    • Hidden when not authenticated
    • Hidden when previously dismissed
    • Impression event logged on mount
    • Click event logged on CTA, link points to /agents/ask
    • Dismiss logs click event and calls completeAction
  • Lint passes (shared + webapp)
  • TypeScript compiles with no new errors

Closes ENG-1074


Created by Huginn 🐦‍⬛

Preview domain

https://eng-1074-add-daily-dev-ask-upsel.preview.app.daily.dev

Add a dismissible banner promoting daily-dev-ask to Plus users on the
web search page. Follows the DigestBookmarkBanner pattern with dismiss
persistence via ActionType and analytics logging.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@vercel
Copy link

vercel bot commented Mar 16, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
daily-webapp Ready Ready Preview Mar 16, 2026 6:15pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
storybook Ignored Ignored Mar 16, 2026 6:15pm

Request Review

The CTA button now calls completeAction so the banner won't reappear
after the user clicks through to /agents/ask.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Move AskSearchBanner from page children (renders after feed) to
feedHeader layout prop (renders before feed). Add feedHeader slot to
MainFeedLayout so pages can inject content above the feed.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Remove the feedHeader prop and pass AskSearchBanner via the existing
searchChildren prop. On mobile, searchChildren renders inside the
LayoutHeader (existing behavior). On laptop, it now also renders
directly above the feed to ensure the banner appears above results
on all viewports.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Move AskSearchBanner from the main feed area into the search page
sidebar (PageWidgets), rendered above Related Tags for a better fit
in the layout. Adapt styling for sidebar width and revert the
searchChildren approach from MainFeedLayout.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Title: "WebSearch for Developers"
Content: updated messaging about community vetted articles and
trusted developer content.
CTA: "Try /daily-dev-ask"

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
When neither navChildren nor searchChildren are provided, the
LayoutHeader rendered an empty <header> element with mb-6 and
min-h-14 classes, creating a visible gap on mobile search. Skip
rendering when there is no content.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
capJavert and others added 2 commits March 16, 2026 18:11
- Add `ask_upsell_search` feature flag via GrowthBook for A/B testing
- Gate banner rendering on feature flag with shouldEvaluate only when
  user is authenticated, Plus, and hasn't dismissed
- Show banner above search results on mobile/tablet
- Remove banner from sidebar on desktop (laptop+)
- Add tests for feature flag gating and conditional evaluation

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants