Skip to content

feat(marketplace): admin browse + install UI for plugin catalogue - #420

Merged
tayebmokni merged 1 commit into
mainfrom
feat/plugin-marketplace-ui
May 23, 2026
Merged

feat(marketplace): admin browse + install UI for plugin catalogue#420
tayebmokni merged 1 commit into
mainfrom
feat/plugin-marketplace-ui

Conversation

@tayebmokni

Copy link
Copy Markdown
Contributor

Summary

Test plan

  • cd apps/api && go vet ./internal/admin/marketplace/...
  • cd apps/api && go test -race -count=1 ./internal/admin/marketplace/... (all green; covers list filters, slug 404, install dispatch + event capture, capability gate on install + rating, rating range checks)
  • pnpm --filter @gonext/admin typecheck
  • pnpm --filter @gonext/admin test (37 files / 255 tests pass — new tests: MarketplaceClient.test.tsx, RatingStars.test.tsx, InstallConfirm.test.tsx asserts the shared CapabilityReview is reused)

🤖 Generated with Claude Code

@tayebmokni
tayebmokni enabled auto-merge (squash) May 19, 2026 20:25
Adds the public-facing browse/install surface that sits next to the
existing plugins manager (PR #385). The catalogue is fed by the
marketplace data model from PR #396; the install path reuses the
plugin lifecycle.Install runtime so consent semantics stay identical
across manual and catalogue flows.

Backend (apps/api/internal/admin/marketplace):
  - GET    /api/v1/admin/marketplace/listings        (category/q/sort)
  - GET    /api/v1/admin/marketplace/listings/{slug}
  - GET    /api/v1/admin/marketplace/listings/{slug}/versions
  - GET    /api/v1/admin/marketplace/listings/{slug}/ratings
  - POST   /api/v1/admin/marketplace/listings/{slug}/ratings  (1..5 stars)
  - POST   /api/v1/admin/marketplace/listings/{slug}/install
  - Read endpoints require an authenticated principal; install +
    rating POST gated on plugins.install (CapInstallPlugins).
  - Install dispatches to lifecycle.Install with the resolved
    version's wasm bytes via a BundleFetcher abstraction; success
    and failure both append a plugin_install_events row.

Admin UI (apps/admin/src/app/marketplace):
  - page.tsx + MarketplaceClient — grid w/ search, category chips,
    and sort-by recent/stars/popular.
  - [slug]/page.tsx + ListingDetailView — description, version
    history, compat matrix, rating aggregate + submission form.
  - [slug]/install/page.tsx + InstallConfirm — reuses the
    CapabilityReview component from #385 (no duplication) and the
    consent checkbox before firing the install action.
  - components/RatingStars (read-only + interactive variants),
    components/MarketplaceCard.

Tests:
  - Backend: filter/sort, slug detail/404, install dispatch + event
    capture, capability gate, rating range checks.
  - Frontend: grid render, URL push for search/sort/category, capability
    review reuse + consent gating, install success path.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Signed-off-by: Mohamed Tayeb Mokni <tayeb.mokni@gmail.com>
@tayebmokni
tayebmokni force-pushed the feat/plugin-marketplace-ui branch from 8d06be7 to bc7d88a Compare May 23, 2026 22:00
@tayebmokni
tayebmokni merged commit 2cf9b86 into main May 23, 2026
21 of 24 checks passed
@tayebmokni
tayebmokni deleted the feat/plugin-marketplace-ui branch May 23, 2026 22:23
tayebmokni added a commit that referenced this pull request May 26, 2026
…brand (#437)

## Summary

Restyles every screen in the GoNext plugin marketplace admin (PR #420)
and installed-plugins admin (PR #385) to the **"Living systems"**
brand foundation that landed via PR #432. Tokens from
`src/styles/tokens.css` are honoured throughout — no hex literals, no
legacy `--color-accent`. Each page lands the brand's signature
italic-serif accent inside a heavy Archivo headline.

- **`/marketplace` — catalogue.** Headline reads `Marketplace
catalogue.`
  with the italic-accent on the noun, an emerald eyebrow, and a Geist
  lead. Filter chips toggle to `--emerald-soft` when active; sort chips
  swap to a solid `--ink` fill. MarketplaceCard sits on `--paper-2`
  with a paper-3 thumb glyph well, Archivo display title, monospace
  slug, lavender-soft capability chip, and emerald rating stars. Cards
  lift to `--sh-md` on hover via a 2px transform — the marketplace
  moodboard's hover gesture.
- **`/marketplace/[slug]` — listing detail.** Headline pairs the
  Archivo title with an italic-serif accent on the author name.
  Version history is a paper-2 table with mono row IDs + SHA digests;
  the compat matrix lives on `--paper-3` sunken surface to read as
  reference data. Ratings render as a horizontal review carousel of
  cream cards with emerald stars.
- **`/marketplace/[slug]/install` — confirmation.** Headline:
  `Install <name>.` with the listing name in italic-serif. The meta
  strip uses the brand's card chrome with mono version label and
  uppercase eyebrow labels. Install CTA is the emerald brand button.
  Success panel uses the italic-accent pattern with an emerald
  left-border.
- **Shared `CapabilityReview` (also rendered by `/plugins/install`).**
  Each capability row is its own paper-2 card with a 22px circular
  marker. Sensitive caps swap to `--lavender-soft` background + solid
  lavender marker; once the consent box is ticked every non-unknown
  marker flips to an **emerald checkmark** — the row visibly confirms
  it has been reviewed.
- **`/plugins` — installed plugins list.** Headline:
  `Installed plugins.` with the italic-accent on `plugins`. Status
  filter chips and `PluginStatusBadge` share the brand's semantic
  palette: emerald for active (alive), paper-3 / fg-muted for inactive
  (quietly present), lavender-soft for installed, warning-soft for
  pending uninstall, danger-soft for errored. Badge gains a leading
  `currentColor` dot so the row is legible without colour.

## Test plan

- [x] `pnpm --filter @gonext/admin lint` — clean (only pre-existing
  `<img>` warnings in unrelated `media/` files)
- [x] `pnpm --filter @gonext/admin typecheck` — clean
- [x] `pnpm --filter @gonext/admin test:ci` — **349 tests pass**,
  including new snapshot tests for `MarketplaceCard` and every
  `PluginStatusBadge` state
- [x] `pnpm --filter @gonext/admin build` — succeeds, marketplace +
  plugins routes ship under their existing bundle budgets
- [x] Snapshot pins lock the brand contract — future drift will fail
  the snapshot and demand a deliberate update

## Tokens audit

Every colour, type ramp, radius, shadow, motion, and spacing in the
diff resolves to a `var(--*)` from `tokens.css`. The few raw values
that remain are intentional: the modal backdrop scrim is
`rgba(14, 26, 20, 0.55)` (the ink ramp tinted at 55%, no token covers
backdrop overlays) and the icon-well letter sizes are pixel-precise
display measurements.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Signed-off-by: Mohamed Tayeb Mokni <tayeb.mokni@gmail.com>
Co-authored-by: Mohamed Tayeb Mokni <tayeb.mokni@gmail.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