Skip to content

feat(shopping): open Product Visibility with its data sources, a Why popup and the Shelf and Products tabs (Product Visibility, part 1) - #1636

Merged
gkhngyk merged 5 commits into
ansvisor:mainfrom
cihan-gyk:feature/product-visibility-shell
Oct 28, 2026
Merged

gkhngyk merged 5 commits into
ansvisor:mainfrom
cihan-gyk:feature/product-visibility-shell

Conversation

@cihan-gyk

Copy link
Copy Markdown
Collaborator

Summary

Product Visibility, part 1 of 14: the page's frame. It starts the Product Visibility screens of the ECOM spec and mockup (Drive › E-commerce, 2026-10-20): what the page is for, what feeds it, and tabs you can link to.

From main. This PR's own change is its commit after main: a5baa55. Parts 2–14 are stacked on it, one on the other.

Reviewing in three waves (suggested):

  • parts 1–4: the frame, card matching (00360), Shelf, Products (00361);
  • parts 5–8: Categories, the product page, actions and Readiness, which complete the mockup's screens;
  • parts 9–14: the second round. 00362 goes before the API deploy.

Where you see it:

  • Sidebar › Analytics › Product Visibility, now with a New badge.
  • It shows for a brand with Shopping mode on (Brand settings). On the cloud, plans without shopping_analytics see it locked, as before.
  • The page stays at /dashboard/shopping. The menu keeps its name; the mockup's "Products" is a tab here.

Header (ECOM-010):

  • New subtitle: "Which of your products AI recommends, why, and what it sells."
  • A Why Ansvisor Product Visibility? pill beside the title. It opens "From AI shelf to cart": four steps from the AI shelf to the sale, then Got it.
  • The popup also offers Connect Google Analytics while GA isn't connected, to admins and managers.

Data sources (ECOM-009), under the header, as on AI Traffic:

  • Product catalog: its products and last sync, with Manage; or Connect. Both go to Settings › Integrations.
  • Google Analytics and Google Search Console: connected, or Connect with what each adds here ("see the path from AI visit to order", "shopping questions from your real searches").
  • AI Traffic's Google card is shared: GoogleSource is exported, with an optional pitch line for while it isn't connected.

Marketplaces & feeds row, under the strip:

  • Google Merchant Center: Connected, or Connect (Settings › Integrations, as a catalog source).
  • Amazon, eBay, Walmart, Etsy, Trendyol and Hepsiburada: Soon, until they have a connector.

Tabs:

  • Shelf, Prompts, Products, Competitors. Overview becomes Shelf and My Products becomes Products.
  • The open tab is in the URL (?tab=products), so a tab can be linked and survives a reload.
  • Their content changes in the next parts. From part 8 the tabs are Shelf · Categories · Products · Readiness · Competitors.

Related issue

No issue: ECOM-001, ECOM-009 and ECOM-010 in Drive › E-commerce › ECOM-spec.md. The screens' tasks were only in epic #1190, closed as not planned.

Type of change

  • feat — New feature
  • fix — Bug fix
  • chore — Maintenance / dependencies
  • docs — Documentation only
  • refactor — Code change that neither fixes a bug nor adds a feature
  • test — Adding or updating tests

How to test

  1. cd web && yarn vitest run "src/app/[locale]/(dashboard)/dashboard/shopping" src/lib/dashboard-navigation.test.ts
  2. Turn Shopping mode on for a brand (Brand settings), on Growth or self-hosted:
    • Sidebar › Analytics › Product Visibility shows New.
    • Why Ansvisor Product Visibility? opens the four steps.
    • The data strip and the Marketplaces & feeds row sit under the header.
    • Open Products: the URL gets ?tab=products, and a reload keeps it.

Browser check, at the top of the chain (part 14), not on this branch alone:

  • 1024 px, light and dark, against the dev DB.
  • All five tabs (Shelf, Categories, Products, Readiness, Competitors) load without errors, and nothing scrolls sideways.
  • The dev DB lacked main's 00225, 00268 and 00277. They were applied, with 00360–00362.
  • The demo brand's catalog is empty, so the product and category content showed its empty states.

Checklist

  • Branch follows the naming convention (feature/, fix/, chore/, docs/) — see CONTRIBUTING.md
  • Commits follow Conventional Commits
  • yarn lint passes (run from web/)
  • yarn typecheck passes (run from web/)
  • yarn format:check passes (run from web/)
  • Changes are focused — one concern per PR

Checks:

  • At the top of the chain (part 14): server/ npm test (3,383 tests), web/ vitest (4,451 tests) and yarn build.
  • At this branch's tip: yarn typecheck, and the tests, eslint and prettier of the files it changes.

For you, @gkhngyk:

🤖 Generated with Claude Code

cihan-gyk and others added 2 commits October 27, 2026 18:33
…popup and the Shelf and Products tabs (product visibility, part 1)

The first step to the Products screens in Drive › E-commerce (ECOM-spec,
ECOM-mockup): the page says what it's for, "Which of your products AI
recommends, why, and what it sells.", with "Why Ansvisor Product
Visibility?" beside the title. That opens the four steps from the AI
shelf to the sale, and offers Connect Google Analytics while GA isn't
connected (ECOM-010).

Under the title, the data sources (ECOM-009), as on AI Traffic:
- the product catalog (its products and last sync, Manage, or Connect);
- Google Analytics and Search Console, each with what it adds here;
- a Marketplaces & feeds row: Merchant Center connects as a catalog
  source, and the marketplaces show Soon until they have a connector.

The tabs read Shelf, Prompts, Products and Competitors, the one open in
the URL (?tab=products). The sidebar item is new. AI Traffic's Google
source card is shared, with an optional line for while it isn't
connected.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@cihan-gyk

Copy link
Copy Markdown
Collaborator Author

Merged main forward (8356ba3): resolved lib/dashboard-navigation.test.ts (kept the Shopping "New" test and main's menu access test). Typecheck and navigation tests pass.

@gkhngyk gkhngyk left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good, with follow-ups.

What I checked:

  • Own change. a5baa55 plus a merge of main (cf37045); a re-merge of its parents gives the same tree. No migration.
  • Merge on today's main. It needs a merge of main: web/src/lib/dashboard-navigation.test.ts conflicts (main added "hides a section off the viewer's menu" where this adds "marks Shopping new"; keep both). web/src/config/dashboard.ts merges cleanly with the menu-access change.
  • Data strip. It reads the catalog sources and the Google sources through the existing listCatalogSources and getTrafficSources actions, so organization scoping is the same as on Settings and AI Traffic. A failed read shows "Couldn't be read right now" rather than an empty strip. A read for the brand you just switched away from counts as loading, so the strip never shows the old brand's sources. Connect and Connect Google Analytics only show for managers (canManage). GoogleSource gets an optional pitch, and AI Traffic's strip is unchanged without it.
  • Tabs. ?tab= is read with readUrlChoice, so an old or unknown value (overview, own_products) opens the Shelf. Nothing else in the app links to the old tab values.
  • Tests. On the PR's tree, tsc is clean, and the shopping tests plus dashboard-navigation.test.ts pass (8 files, 48 tests). Prettier and eslint are clean on the touched files.

Follow-ups (none block):

  1. The Why popup promises "The agent rewrites titles, feed fields and schema. You approve, we send it to Shopify." Make sure the later parts ship that before this goes live, or soften it until they do.
  2. The Marketplaces & feeds row shows Amazon, eBay, Walmart, Etsy, Trendyol and Hepsiburada as "Soon" to everyone. If none of them is planned for this quarter, a shorter list would promise less.

@gkhngyk
gkhngyk merged commit 47c575b into ansvisor:main Oct 28, 2026
4 of 5 checks passed
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