From d4cd147a334187f5ba2b0622d0aeae7812f0cb95 Mon Sep 17 00:00:00 2001 From: Dotta Date: Thu, 11 Jun 2026 13:57:38 +0000 Subject: [PATCH] Apply PAP-10907 Skills Store store + detail polish MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Store cards / discovery grid: - Bundled tab no longer appends "(required)"; card badge reads "Bundled" - Card stats reordered to installed-agents · stars · forks, hiding stars and forks when zero - Hover border-highlight (border-primary) on cards - Missing descriptions render a reserved blank line so cards align - Installed badge moved ahead of the other tags, checkmark dropped - Category sidebar scrolls independently of the results pane on desktop - Search field height/typography matched to the sort/action buttons (and 16px font on mobile to stop iOS zoom) Skill detail page: - Source icon moved after the H1 with a "Installed from …" tooltip - Top-level description capped at max-w-2xl - Installs · stars · fork relocated to a GitHub-style top-right cluster; stars and fork are buttons, installs is a stat - Remove moved into the sidebar Sharing section, gated on edit permission - Overview/Files/Versions/Agents tabs given a visible underline - Comments tab removed (and its dead queries/mutations/component) - Agents tab lists only attached agents with a full "Add to agent" button - Sidebar "Add to agent" is now a big button opening the multi-selector, with a preview of up to 3 attached agents (icon + name, "and n more") - Multi-selector sorts checked agents up top and shows agent icon + paused - Related skills section removed Adds a Storybook story (Skills Store/Skill detail) covering the detail page. Co-Authored-By: Claude Opus 4.8 --- ui/src/pages/CompanySkills.tsx | 575 +++++++----------- .../stories/skills-store-detail.stories.tsx | 198 ++++++ 2 files changed, 426 insertions(+), 347 deletions(-) create mode 100644 ui/storybook/stories/skills-store-detail.stories.tsx diff --git a/ui/src/pages/CompanySkills.tsx b/ui/src/pages/CompanySkills.tsx index 1fb8cba530d..35b0c8568b2 100644 --- a/ui/src/pages/CompanySkills.tsx +++ b/ui/src/pages/CompanySkills.tsx @@ -6,7 +6,6 @@ import type { Agent, CatalogSkill, CatalogSkillFileDetail, - CompanySkillComment, CompanySkillCompatibility, CompanySkillCreateRequest, CompanySkillDetail, @@ -32,6 +31,7 @@ import { MarkdownEditor } from "../components/MarkdownEditor"; import { PageSkeleton } from "../components/PageSkeleton"; import { CopyText } from "../components/CopyText"; import { Identity } from "../components/Identity"; +import { AgentIcon } from "../components/AgentIconPicker"; import { useAdapterCapabilities } from "../adapters/use-adapter-capabilities"; import { Dialog, @@ -86,9 +86,9 @@ import { LayoutGrid, Link2, Lock, - MessageSquare, ExternalLink, Paperclip, + Pause, Pencil, Plus, Copy, @@ -537,7 +537,9 @@ function cardDescriptionText(raw: string | null | undefined): string { const cleaned = (raw ?? "") .replace(/^[\s>#*_\-`>]+/, "") .trim(); - return cleaned.length >= 3 ? cleaned : "No description yet."; + // Empty descriptions render as a blank line on cards so spacing stays + // consistent across the grid (PAP-10907). + return cleaned.length >= 3 ? cleaned : ""; } // --------------------------------------------------------------------------- @@ -823,7 +825,7 @@ function SkillCard({ card, onOpen }: { card: DiscoveryCard; onOpen: (card: Disco type="button" onClick={() => onOpen(card)} className={cn( - "group flex h-full min-h-[11.5rem] flex-col rounded-md border border-border p-4 text-left transition-colors hover:border-foreground/30 hover:bg-accent/30 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring", + "group flex h-full min-h-[11.5rem] flex-col rounded-md border border-border p-4 text-left transition-colors hover:border-primary hover:bg-accent/30 hover:shadow-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring", card.required && "bg-muted/30", )} > @@ -844,38 +846,41 @@ function SkillCard({ card, onOpen }: { card: DiscoveryCard; onOpen: (card: Disco ) : null} -

+ {/* Always reserve two lines so cards line up even without a description. */} +

{cardDescriptionText(card.description)}

+ {/* Stats: installed agents · stars · forks — stars/forks only when > 0. */}
- {card.required ? ( - {card.agentCount} agents using - ) : ( + {card.agentCount} {card.agentCount === 1 ? "agent" : "agents"} + {card.starCount > 0 ? ( <> + - - {card.agentCount} agents - - - )} + ) : null} + {card.forkCount > 0 ? ( + <> + + + + ) : null}
+ {card.installed ? ( + + Installed + + ) : null} {card.categories.slice(0, 2).map((category) => ( ))} - {card.required ? ( - + - ) : card.installed ? ( - - ) : null}
@@ -976,10 +981,13 @@ export function DiscoveryGrid({ scanStatus: string | null; }) { return ( -
+ // On desktop the store is bounded to the viewport so the category sidebar + // and the results pane each scroll independently (PAP-10907). Mobile keeps + // the natural page flow. +
{/* Secondary category sidebar — the main app nav collapses to a rail while this is present (handled in Layout). */} -