AutoGPT is the vision of accessible AI for everyone, to use and to build on. Our mission is to provide the tools, so that you can focus on what matters.
feat(frontend): add compact variants to core atoms and restyle Home (#14398)
Abhimanyu Yadav06b1dd66327e
diff --git a/autogpt_platform/frontend/public/experts/covers/default.jpg b/autogpt_platform/frontend/public/experts/covers/default.jpgdeleted file mode 100644index 3676df9ba6..0000000000Binary files a/autogpt_platform/frontend/public/experts/covers/default.jpg and /dev/null differdiff --git a/autogpt_platform/frontend/src/app/(platform)/copilot/components/ChatInput/ChatInput.tsx b/autogpt_platform/frontend/src/app/(platform)/copilot/components/ChatInput/ChatInput.tsxindex 75851127a3..25d3d2c862 100644--- a/autogpt_platform/frontend/src/app/(platform)/copilot/components/ChatInput/ChatInput.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/copilot/components/ChatInput/ChatInput.tsx@@ -42,6 +42,8 @@ import { TokenDevtoolBadge } from "../TokenDevtoolBadge/TokenDevtoolBadge";import {CARD_ICON_BUTTON_CLASS,CARD_SEND_BUTTON_CLASS,+ COMPACT_ICON_BUTTON_CLASS,+ COMPACT_SEND_BUTTON_CLASS,getFilesFromClipboard,} from "./helpers";import { useChatInput } from "./useChatInput";@@ -81,6 +83,9 @@ interface Props {/** Card composer: the text always keeps its own row above the controls,* instead of sharing a single pill row until it wraps. Empty state only. */stacked?: boolean;+ /** Compact composer for side panels: tighter radius, flat shadow, smaller+ * controls, and no per-message connection chip. */+ variant?: "default" | "compact";}export function ChatInput({@@ -100,6 +105,7 @@ export function ChatInput({hideSubmitWhenEmpty = false,recipientPicker,stacked = false,+ variant = "default",}: Props) {const { isDryRun, setIsDryRun } = useCopilotUIStore();// Still the CHAT_MODE_OPTION flag, which no longer names what it gates: the@@ -265,6 +271,18 @@ export function ChatInput({setAttachments((prev) => prev.filter((_, i) => i !== index));}+ const isCompact = variant === "compact";+ const iconButtonClass = stacked+ ? CARD_ICON_BUTTON_CLASS+ : isCompact+ ? COMPACT_ICON_BUTTON_CLASS+ : undefined;+ const sendButtonClass = stacked+ ? CARD_SEND_BUTTON_CLASS+ : isCompact+ ? COMPACT_SEND_BUTTON_CLASS+ : undefined;+return (<form onSubmit={handleSubmit} className={cn("relative flex-1", className)}>{mentions.isOpen && (@@ -288,6 +306,8 @@ export function ChatInput({// pill's deep shadow, so it reads as a surface the text sits on.stacked &&"gap-3 !rounded-3xl border-transparent px-3.5 pb-3.5 pt-3 shadow-[0_0_0_0.5px_rgba(0,0,0,0.08),0_1px_2px_rgba(0,0,0,0.05),0_2px_4px_rgba(0,0,0,0.02)] has-[[data-slot=input-group-control]:focus-visible]:border-transparent",+ isCompact &&+ "!rounded-xl border-zinc-200 shadow-[0_1px_2px_rgba(0,0,0,0.04)] has-[[data-slot=input-group-control]:focus-visible]:border-zinc-400",isRecording &&"border-red-400 ring-1 ring-red-400 has-[[data-slot=input-group-control]:focus-visible]:border-red-400 has-[[data-slot=input-group-control]:focus-visible]:ring-red-400",)}@@ -301,7 +321,7 @@ export function ChatInput({<divclassName={cn("flex w-full flex-wrap",- stacked ? "items-center" : "items-end",+ stacked || isCompact ? "items-center" : "items-end",)}><InputGroupAddon@@ -309,6 +329,7 @@ export function ChatInput({className={cn("order-none gap-1 py-1 pl-1.5",stacked && "gap-1.5 p-0",+ isCompact && "gap-0.5 py-1 pl-1",)}><ComposerPlusMenu@@ -322,7 +343,7 @@ export function ChatInput({CARD_ICON_BUTTON_CLASS,"[&[aria-expanded=true]_svg]:rotate-45 [&_svg]:transition-transform [&_svg]:duration-200",)- : undefined+ : iconButtonClass}/>{recipientPicker}@@ -346,7 +367,10 @@ export function ChatInput({disabled={isInputDisabled}placeholder={resolvedPlaceholder}onMultilineChange={setIsMultiline}- className={stacked ? "px-0.5 py-1" : undefined}+ className={cn(+ stacked && "px-0.5 py-1",+ isCompact && "text-sm leading-5 md:text-sm",+ )}/>{isRecording && !value && (<div className="pointer-events-none absolute inset-0 flex items-center justify-center">@@ -362,12 +386,13 @@ export function ChatInput({className={cn("order-none ml-auto gap-1 py-1 pr-1.5",stacked && "gap-1.5 p-0",+ isCompact && "gap-0.5 py-1 pr-1",)}>{/* Connection and tier are per-message settings, so they remainchangeable between turns in an existing session. The cardcomposer leaves this to the page's top-right control. */}- {!stacked && (!hasSession || !isStreaming) && (+ {!stacked && !isCompact && (!hasSession || !isStreaming) && (<ConnectionPicker connectionLocked={hasSession} />)}{showAdvancedComposerControls && !hasSession && (@@ -386,7 +411,7 @@ export function ChatInput({isStreaming={isStreaming}disabled={disabled || isTranscribing || isStreaming}highlight={isMicGlowing}- className={stacked ? CARD_ICON_BUTTON_CLASS : undefined}+ className={iconButtonClass}onClick={() => {dismissGlow();toggleRecording();@@ -412,7 +437,10 @@ export function ChatInput({}}}}- className="size-[2.625rem] rounded-full border-zinc-800 bg-zinc-800 text-white hover:border-zinc-900 hover:bg-zinc-900 disabled:border-zinc-200 disabled:bg-zinc-200 disabled:text-white disabled:opacity-100"+ className={cn(+ "size-[2.625rem] rounded-full border-zinc-800 bg-zinc-800 text-white hover:border-zinc-900 hover:bg-zinc-900 disabled:border-zinc-200 disabled:bg-zinc-200 disabled:text-white disabled:opacity-100",+ sendButtonClass,+ )}><Icon icon={ArrowUp02Icon} className="size-4" /></PromptInputButton>@@ -420,14 +448,18 @@ export function ChatInput({{isStreaming ? (<Tooltip><TooltipTrigger asChild>- <PromptInputSubmit status="streaming" onStop={onStop} />+ <PromptInputSubmit+ status="streaming"+ onStop={onStop}+ className={sendButtonClass}+ /></TooltipTrigger><TooltipContent side="top">Stop</TooltipContent></Tooltip>) : hideSubmitWhenEmpty && !canSend ? null : (<PromptInputSubmitdisabled={!canSend}- className={stacked ? CARD_SEND_BUTTON_CLASS : undefined}+ className={sendButtonClass}/>)}</InputGroupAddon>diff --git a/autogpt_platform/frontend/src/app/(platform)/copilot/components/ChatInput/helpers.ts b/autogpt_platform/frontend/src/app/(platform)/copilot/components/ChatInput/helpers.tsindex 6fc45e8036..33ca4cae78 100644--- a/autogpt_platform/frontend/src/app/(platform)/copilot/components/ChatInput/helpers.ts+++ b/autogpt_platform/frontend/src/app/(platform)/copilot/components/ChatInput/helpers.ts@@ -35,5 +35,11 @@ export function formatElapsedTime(ms: number): string {export const CARD_ICON_BUTTON_CLASS ="size-9 rounded-full border-transparent bg-zinc-950/[0.06] p-0 text-zinc-900 shadow-none transition-[background-color,transform] hover:border-transparent hover:bg-zinc-950/10 hover:text-zinc-900 active:scale-[0.98] aria-expanded:bg-zinc-950/[0.12]";+export const COMPACT_ICON_BUTTON_CLASS =+ "size-8 rounded-lg border-transparent bg-transparent p-0 text-zinc-700 shadow-none hover:border-transparent hover:bg-zinc-100 hover:text-zinc-900 aria-expanded:bg-zinc-100";++export const COMPACT_SEND_BUTTON_CLASS =+ "size-8 rounded-lg border-zinc-900 bg-zinc-900 text-white hover:border-zinc-800 hover:bg-zinc-800 disabled:border-zinc-200 disabled:bg-zinc-200 disabled:text-white disabled:opacity-100";+export const CARD_SEND_BUTTON_CLASS ="size-9 rounded-full border-transparent bg-zinc-950 text-white transition-[background-color,transform] hover:border-transparent hover:bg-zinc-800 active:scale-[0.98] disabled:border-transparent disabled:bg-zinc-950/[0.06] disabled:text-zinc-400";diff --git a/autogpt_platform/frontend/src/app/(platform)/copilot/components/ChatMessagesContainer/ChatMessagesContainer.tsx b/autogpt_platform/frontend/src/app/(platform)/copilot/components/ChatMessagesContainer/ChatMessagesContainer.tsxindex e51b87885b..5edb821139 100644--- a/autogpt_platform/frontend/src/app/(platform)/copilot/components/ChatMessagesContainer/ChatMessagesContainer.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/copilot/components/ChatMessagesContainer/ChatMessagesContainer.tsx@@ -107,6 +107,12 @@ interface Props {* every other host (share viewer, memory and builder panels) leaves this* off, whatever the persisted panel state says. */areFilesOpen?: boolean;+ /** Compact thread for side panels: smaller text, tighter bubbles and+ * spacing. */+ variant?: "default" | "compact";+ /** Hosts that already name the thread (e.g. the expert chat drawer)+ * turn the floating identity chip off. */+ showThreadHeader?: boolean;}/**@@ -308,7 +314,10 @@ export function ChatMessagesContainer({hasFloatingControls = false,canOpenActivity = false,areFilesOpen = false,+ variant = "default",+ showThreadHeader = true,}: Props) {+ const isCompact = variant === "compact";const messages = useMemo(() => revealKickoffMessages(allMessages),[allMessages],@@ -462,14 +471,16 @@ export function ChatMessagesContainer({return (<>- <ThreadHeader- expertIdentity={expertIdentity}- readOnly={readOnly}- sessionId={sessionID}- hasFloatingControls={hasFloatingControls}- canOpenActivity={canOpenActivity}- />- <ChatMinimap messages={messages} />+ {showThreadHeader && (+ <ThreadHeader+ expertIdentity={expertIdentity}+ readOnly={readOnly}+ sessionId={sessionID}+ hasFloatingControls={hasFloatingControls}+ canOpenActivity={canOpenActivity}+ />+ )}+ {!isCompact && <ChatMinimap messages={messages} />}<Conversationkey={sessionID ?? "new"}resize="instant"@@ -483,6 +494,8 @@ export function ChatMessagesContainer({<ConversationContentclassName={cn("ease-[cubic-bezier(0.32,0.72,0,1)] mx-auto flex min-h-full w-full max-w-3xl flex-1 flex-col gap-6 px-6 pb-4 pt-14 transition-transform duration-300 will-change-transform motion-reduce:transition-none",+ isCompact && "gap-4 px-4 pt-4",+ !showThreadHeader && "pt-4",areFilesOpen && "xl:-translate-x-40",)}style={@@ -604,14 +617,16 @@ export function ChatMessagesContainer({className="duration-300 animate-in fade-in slide-in-from-bottom-2 fill-mode-both"><MessageContent- className={- "text-[1rem] leading-relaxed " +- "group-[.is-user]:rounded-3xl group-[.is-user]:bg-zinc-100 group-[.is-user]:px-4 group-[.is-user]:py-2.5 group-[.is-user]:text-zinc-900 " +- "group-[.is-user]:[&_h1]:text-lg group-[.is-user]:[&_h1]:font-semibold group-[.is-user]:[&_h2]:text-lg group-[.is-user]:[&_h2]:font-semibold group-[.is-user]:[&_h3]:text-lg group-[.is-user]:[&_h3]:font-semibold group-[.is-user]:[&_h4]:text-lg group-[.is-user]:[&_h4]:font-semibold group-[.is-user]:[&_h5]:text-lg group-[.is-user]:[&_h5]:font-semibold group-[.is-user]:[&_h6]:text-lg group-[.is-user]:[&_h6]:font-semibold " ++ className={cn(+ isCompact+ ? "text-sm leading-6 group-[.is-user]:rounded-xl"+ : "text-[1rem] leading-relaxed group-[.is-user]:rounded-3xl",+ "group-[.is-user]:bg-zinc-100 group-[.is-user]:px-4 group-[.is-user]:py-2.5 group-[.is-user]:text-zinc-900",+ "group-[.is-user]:[&_h1]:text-lg group-[.is-user]:[&_h1]:font-semibold group-[.is-user]:[&_h2]:text-lg group-[.is-user]:[&_h2]:font-semibold group-[.is-user]:[&_h3]:text-lg group-[.is-user]:[&_h3]:font-semibold group-[.is-user]:[&_h4]:text-lg group-[.is-user]:[&_h4]:font-semibold group-[.is-user]:[&_h5]:text-lg group-[.is-user]:[&_h5]:font-semibold group-[.is-user]:[&_h6]:text-lg group-[.is-user]:[&_h6]:font-semibold",// Chain hover pills use negative margins that the base// overflow-hidden would clip.- "group-[.is-assistant]:overflow-visible group-[.is-assistant]:bg-transparent group-[.is-assistant]:text-slate-900"- }+ "group-[.is-assistant]:overflow-visible group-[.is-assistant]:bg-transparent group-[.is-assistant]:text-slate-900",+ )}>{isAssistant ? (<ChainMessageParts@@ -772,7 +787,14 @@ export function ChatMessagesContainer({{!readOnly &&queuedMessages?.map((msg, idx) => (<Message key={idx} from="user">- <MessageContent className="flex flex-col gap-1 rounded-3xl border border-dashed border-zinc-300 bg-zinc-100 px-4 py-2.5 text-[1rem] leading-relaxed text-zinc-900 opacity-60">+ <MessageContent+ className={cn(+ "flex flex-col gap-1 border border-dashed border-zinc-300 bg-zinc-100 px-4 py-2.5 text-zinc-900 opacity-60",+ isCompact+ ? "rounded-xl text-sm leading-6"+ : "rounded-3xl text-[1rem] leading-relaxed",+ )}+ ><span>{msg}</span><span className="flex items-center gap-1 text-xs text-slate-500"><Icon icon={Clock01Icon} className="size-3" />diff --git a/autogpt_platform/frontend/src/app/(platform)/copilot/components/OnboardingWelcomeDialog/ConnectProviderRow.tsx b/autogpt_platform/frontend/src/app/(platform)/copilot/components/OnboardingWelcomeDialog/ConnectProviderRow.tsxindex 0f41557204..ce6dff0a47 100644--- a/autogpt_platform/frontend/src/app/(platform)/copilot/components/OnboardingWelcomeDialog/ConnectProviderRow.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/copilot/components/OnboardingWelcomeDialog/ConnectProviderRow.tsx@@ -1,6 +1,7 @@"use client";import { Icon } from "@/components/atoms/Icon/Icon";+import { cn } from "@/lib/utils";import { Add01Icon, CheckmarkCircle02Icon } from "@hugeicons/core-free-icons";import Image from "next/image";import { useState } from "react";@@ -13,6 +14,7 @@ interface Props {isConnected?: boolean;/** Second line, used by the recommended list to show the model's reason. */description?: string | null;+ className?: string;}// The welcome dialog's provider card: compact (two per row), name plus an@@ -23,6 +25,7 @@ export function ConnectProviderRow({onSelect,isConnected,description,+ className,}: Props) {const src = `/integrations/${provider.id}.png`;const [brokenSrc, setBrokenSrc] = useState<string | null>(null);@@ -32,7 +35,10 @@ export function ConnectProviderRow({<buttontype="button"onClick={() => onSelect(provider.id)}- className="group flex h-14 w-full items-center gap-2.5 rounded-xl bg-neutral-100 px-3 text-left transition-colors hover:bg-neutral-200 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-purple-400 active:bg-neutral-200"+ className={cn(+ "group flex h-14 w-full items-center gap-2.5 rounded-xl bg-neutral-100 px-3 text-left transition-colors hover:bg-neutral-200 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-purple-400 active:bg-neutral-200",+ className,+ )}>{broken ? (<divdiff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/AgentTeam/AgentTeam.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/AgentTeam/AgentTeam.tsxindex f710b81ce7..01e88eb86d 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/AgentTeam/AgentTeam.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/AgentTeam/AgentTeam.tsx@@ -2,6 +2,7 @@ import { AiEraserIcon, ArrowRight01Icon } from "@hugeicons/core-free-icons";import Link from "next/link";import type { HomeDashboardResponse } from "@/app/api/__generated__/models/homeDashboardResponse";import { Icon } from "@/components/atoms/Icon/Icon";+import { Text } from "@/components/atoms/Text/Text";import { formatWeeklySpend } from "../../helpers";import { HomeTileEmpty } from "../HomeTileEmpty/HomeTileEmpty";import { HomeTile } from "../HomeTile/HomeTile";@@ -50,9 +51,16 @@ export function AgentTeam({ dashboard, className }: Props) {{team.total > 0 ? (<Linkhref="/team"- className="flex items-center justify-between border-t border-zinc-100 px-4 py-2 text-xs font-medium text-zinc-500 outline-none transition-colors hover:bg-zinc-50 hover:text-zinc-900 focus-visible:bg-zinc-50"+ className="group flex items-center justify-between border-t border-zinc-100 px-4 py-2 outline-none transition-colors hover:bg-zinc-50 focus-visible:bg-zinc-50">- View all {team.total} experts+ <Text+ variant="small-medium"+ as="span"+ tone="muted"+ className="transition-colors group-hover:text-zinc-900"+ >+ View all {team.total} experts+ </Text><Icon icon={ArrowRight01Icon} size={14} aria-hidden="true" /></Link>) : null}diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/AgentTeam/components/AgentRow.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/AgentTeam/components/AgentRow.tsxindex 82ff072ccc..0d4646efe2 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/AgentTeam/components/AgentRow.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/AgentTeam/components/AgentRow.tsx@@ -10,8 +10,6 @@ interface Props {agent: HomeAgentStatus;}-const ACTION_CLASS = "h-7 min-w-0 rounded-md px-2.5 text-xs";-/** One expert with its status and two ways in. The detail line is gone:* anything that needs doing is already spelled out under Needs you. */export function AgentRow({ agent }: Props) {@@ -32,7 +30,8 @@ export function AgentRow({ agent }: Props) {<div className="flex items-center gap-2"><Textvariant="body-medium"- className="truncate leading-5 text-zinc-900"+ tone="primary"+ className="truncate leading-5">{agent.expert.name}</Text>@@ -41,7 +40,8 @@ export function AgentRow({ agent }: Props) {{secondLine ? (<Textvariant="small"- className="truncate tabular-nums leading-4 text-zinc-500"+ tone="muted"+ className="truncate tabular-nums leading-4"unmask={false}>{secondLine}@@ -53,8 +53,7 @@ export function AgentRow({ agent }: Props) {as="NextLink"href={`/copilot?expertId=${agent.expert.id}`}variant="secondary"- size="small"- className={ACTION_CLASS}+ size="xs"aria-label={`Chat with ${agent.expert.name}`}>Chat@@ -63,8 +62,7 @@ export function AgentRow({ agent }: Props) {as="NextLink"href={`/team/${agent.expert.id}`}variant="secondary"- size="small"- className={ACTION_CLASS}+ size="xs"aria-label={`Manage ${agent.expert.name}`}>Managediff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/AgentTeam/components/StatusBadge.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/AgentTeam/components/StatusBadge.tsxindex 162e6cd022..32f9aa6dd8 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/AgentTeam/components/StatusBadge.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/AgentTeam/components/StatusBadge.tsx@@ -1,4 +1,5 @@import type { HomeAgentStatus } from "@/app/api/__generated__/models/homeAgentStatus";+import { Text } from "@/components/atoms/Text/Text";import { cn } from "@/lib/utils";const STATUS_CONFIG = {@@ -25,7 +26,12 @@ export function StatusBadge({ status }: Props) {const config = STATUS_CONFIG[status] ?? UNKNOWN_STATUS_CONFIG;return (- <span className="inline-flex shrink-0 items-center gap-1.5 text-[11px] font-medium text-zinc-500">+ <Text+ variant="small-medium"+ as="span"+ tone="muted"+ className="inline-flex shrink-0 items-center gap-1.5"+ ><spanclassName={cn("size-1.5 rounded-full",@@ -35,6 +41,6 @@ export function StatusBadge({ status }: Props) {aria-hidden="true"/>{config.label}- </span>+ </Text>);}diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/HomeHeader/HomeHeader.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/HomeHeader/HomeHeader.tsxindex b4aecd1a2c..21bae53884 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/HomeHeader/HomeHeader.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/HomeHeader/HomeHeader.tsx@@ -16,13 +16,14 @@ export function HomeHeader({ greeting, name, dashboard }: Props) {<header className="flex items-end justify-between gap-6 px-1 pb-5 pt-1"><div className="min-w-0"><Text- variant="large-semibold"+ variant="lead-semibold"as="h1"- className="text-pretty text-[1.25rem] leading-7 tracking-[-0.01em] text-zinc-950"+ tone="primary"+ className="text-pretty tracking-[-0.01em]">{greeting}, {name}</Text>- <Text variant="body" className="mt-0.5 text-pretty text-zinc-950">+ <Text variant="body" tone="primary" className="mt-0.5 text-pretty">{status.split(/(\d+)/).map((part, index) =>/^\d+$/.test(part) ? (<span@@ -41,10 +42,10 @@ export function HomeHeader({ greeting, name, dashboard }: Props) {dateTime={new Date(dashboard.generated_at).toISOString()}className="shrink-0 text-right">- <Text variant="large-medium" className="text-zinc-950">+ <Text variant="large-medium" tone="primary">{date.weekday}</Text>- <Text variant="body" className="text-zinc-950">+ <Text variant="body" tone="primary">{date.calendarDate}</Text></time>diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/HomeSectionLabel/HomeSectionLabel.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/HomeSectionLabel/HomeSectionLabel.tsxindex 9e4ae130be..26ab6efba0 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/HomeSectionLabel/HomeSectionLabel.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/HomeSectionLabel/HomeSectionLabel.tsx@@ -8,10 +8,7 @@ interface Props {* header row. */export function HomeSectionLabel({ children }: Props) {return (- <Text- variant="small-medium"- className="px-4 pb-1 pt-3 text-[11px] uppercase tracking-[0.06em] text-zinc-400"- >+ <Text variant="eyebrow" className="block px-4 pb-1 pt-3">{children}</Text>);diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/HomeTile/HomeTile.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/HomeTile/HomeTile.tsxindex 93ed6172d3..33c997b26a 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/HomeTile/HomeTile.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/HomeTile/HomeTile.tsx@@ -32,6 +32,7 @@ export function HomeTile({const Component = as;return (<Component+ aria-label={as === "section" ? title : undefined}className={cn("flex min-w-0 flex-col overflow-hidden rounded-lg border border-zinc-200 bg-white",className,@@ -48,7 +49,8 @@ export function HomeTile({<Textvariant="body-medium"as="h2"- className="truncate text-sm text-zinc-900"+ tone="primary"+ className="truncate">{title}</Text>diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/HomeTileEmpty/HomeTileEmpty.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/HomeTileEmpty/HomeTileEmpty.tsxindex 8c290481f7..fefeefe20a 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/HomeTileEmpty/HomeTileEmpty.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/HomeTileEmpty/HomeTileEmpty.tsx@@ -53,12 +53,12 @@ export function HomeTileEmpty({</motion.div><div className="flex max-w-xs flex-col items-center gap-1"><motion.div {...fadeUp(0.22)}>- <Text variant="large-medium" className="text-zinc-800">+ <Text variant="large-medium" tone="primary">{title}</Text></motion.div><motion.div {...fadeUp(0.3)}>- <Text variant="body" className="text-pretty text-zinc-500">+ <Text variant="body" tone="muted" className="text-pretty">{description}</Text></motion.div>@@ -69,8 +69,7 @@ export function HomeTileEmpty({as="NextLink"href={action.href}variant="secondary"- size="small"- className="h-8 min-w-0 rounded-md px-3 text-xs"+ size="xs">{action.label}</Button>diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/HomeTileFilter/HomeTileFilter.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/HomeTileFilter/HomeTileFilter.tsxindex ca4fe29b1d..85e0f975c6 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/HomeTileFilter/HomeTileFilter.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/HomeTileFilter/HomeTileFilter.tsx@@ -2,7 +2,6 @@import { FilterHorizontalIcon } from "@hugeicons/core-free-icons";import { Button } from "@/components/atoms/Button/Button";-import { Icon } from "@/components/atoms/Icon/Icon";import {DropdownMenu,DropdownMenuContent,@@ -32,11 +31,9 @@ export function HomeTileFilter({<DropdownMenuTrigger asChild><Buttonvariant="ghost"- size="small"- className="h-7 min-w-0 gap-1 rounded-md px-2 text-xs text-zinc-600 hover:bg-zinc-100 hover:text-zinc-900"- leftIcon={- <Icon icon={FilterHorizontalIcon} size={13} aria-hidden="true" />- }+ size="xs"+ className="gap-1 px-2 text-zinc-600 hover:bg-zinc-100 hover:text-zinc-900"+ leadingIcon={FilterHorizontalIcon}aria-label={`${ariaLabelPrefix}: ${activeLabel}`}unmask={false}>diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/NeedsYou/NeedsYou.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/NeedsYou/NeedsYou.tsxindex 490f75184f..1db023558a 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/NeedsYou/NeedsYou.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/NeedsYou/NeedsYou.tsx@@ -2,6 +2,7 @@import { AlertCircleIcon } from "@hugeicons/core-free-icons";import type { HomeDashboardResponse } from "@/app/api/__generated__/models/homeDashboardResponse";+import { Text } from "@/components/atoms/Text/Text";import { HomeTileFilter } from "../HomeTileFilter/HomeTileFilter";import { HomeTile } from "../HomeTile/HomeTile";import { AttentionRow } from "./components/AttentionRow";@@ -30,13 +31,16 @@ export function NeedsYou({ dashboard, className }: Props) {icon={AlertCircleIcon}title="Needs you"badge={- <span+ <Text+ variant="small-medium"+ as="span"+ tone="secondary"role="status"aria-label={`${itemCount} ${itemCount === 1 ? "item needs" : "items need"} your attention`}- className="rounded-md bg-zinc-100 px-1.5 py-0.5 text-[11px] font-medium tabular-nums text-zinc-700"+ className="rounded-md bg-zinc-100 px-1.5 py-0.5 tabular-nums">{itemCount}- </span>+ </Text>}meta={hasFilters ? (diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/NeedsYou/components/AttentionRow.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/NeedsYou/components/AttentionRow.tsxindex b0f3ea67fe..6f6029073e 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/NeedsYou/components/AttentionRow.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/NeedsYou/components/AttentionRow.tsx@@ -55,18 +55,23 @@ export function AttentionRow({ item, isProcessing, onDecision }: Props) {)}<div className="min-w-0 flex-1"><div className="flex flex-wrap items-center gap-2">- <Text variant="body-medium" className="text-pretty text-zinc-950">+ <Text variant="body-medium" tone="primary" className="text-pretty">{item.title}</Text>{item.priority === "high" ? (- <span className="rounded bg-amber-50 px-1.5 py-px text-[10px] font-medium text-amber-700 ring-1 ring-inset ring-amber-600/10">+ <Text+ variant="small-medium"+ as="span"+ className="rounded bg-amber-50 px-1.5 py-px text-amber-700 ring-1 ring-inset ring-amber-600/10"+ >Waiting- </span>+ </Text>) : null}</div><Textvariant="body"- className="line-clamp-2 text-pretty text-zinc-600"+ tone="secondary"+ className="line-clamp-2 text-pretty">{item.description}</Text>diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/NeedsYou/components/AttentionRowActions.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/NeedsYou/components/AttentionRowActions.tsxindex e3694531e1..2c38ea9cba 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/NeedsYou/components/AttentionRowActions.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/NeedsYou/components/AttentionRowActions.tsx@@ -1,8 +1,6 @@import { Cancel01Icon, Tick02Icon } from "@hugeicons/core-free-icons";import type { HomeAttentionItem } from "@/app/api/__generated__/models/homeAttentionItem";import { Button } from "@/components/atoms/Button/Button";-import { Icon } from "@/components/atoms/Icon/Icon";-import { cn } from "@/lib/utils";interface Props {item: HomeAttentionItem;@@ -13,8 +11,6 @@ interface Props {onDeclineBlur: () => void;}-const ICON_BUTTON_CLASS = "size-7 rounded-md p-0";-export function AttentionRowActions({item,isProcessing,@@ -28,8 +24,7 @@ export function AttentionRowActions({as="NextLink"href={item.primary_action.href}variant="secondary"- size="small"- className="h-7 min-w-0 rounded-md px-2.5 text-xs"+ size="xs">{item.primary_action.label}</Button>@@ -43,34 +38,22 @@ export function AttentionRowActions({<>{primaryAction}<Button- variant="icon"- size="icon"- className={cn(- ICON_BUTTON_CLASS,- "border-zinc-900 bg-zinc-900 text-white hover:border-zinc-800 hover:bg-zinc-800",- )}+ variant="primary"+ size="icon-xs"+ leadingIcon={Tick02Icon}disabled={isProcessing}aria-label={`Approve: ${item.title}`}onClick={onApprove}- >- <Icon icon={Tick02Icon} size={15} aria-hidden="true" />- </Button>+ /><Button- variant="icon"- size="icon"- className={cn(- ICON_BUTTON_CLASS,- "border-zinc-200 text-zinc-600 hover:border-zinc-300 hover:bg-zinc-50",- confirmDecline &&- "border-red-500 bg-red-500 text-white hover:border-red-600 hover:bg-red-600 hover:text-white",- )}+ variant={confirmDecline ? "destructive" : "icon"}+ size="icon-xs"+ leadingIcon={Cancel01Icon}disabled={isProcessing}aria-label={`${confirmDecline ? "Confirm decline" : "Decline"}: ${item.title}`}onClick={onDecline}onBlur={onDeclineBlur}- >- <Icon icon={Cancel01Icon} size={15} aria-hidden="true" />- </Button>+ /></>);}diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/NowNext/components/ActiveRow.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/NowNext/components/ActiveRow.tsxindex 3654e57d49..61db320824 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/NowNext/components/ActiveRow.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/NowNext/components/ActiveRow.tsx@@ -28,11 +28,12 @@ export function ActiveRow({ item }: Props) {<div className="min-w-0 flex-1"><Textvariant="body-medium"- className="truncate text-[13px] leading-5 text-zinc-900"+ tone="primary"+ className="truncate leading-5">{item.title}</Text>- <Text variant="small" className="truncate text-[11px] text-zinc-500">+ <Text variant="small" tone="muted" className="truncate">{item.status === "queued"? "Queued": (formatRunningFor(item.started_at) ?? "Running now")}diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/NowNext/components/UpcomingRow.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/NowNext/components/UpcomingRow.tsxindex 701cdcee5f..eb32c78d03 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/NowNext/components/UpcomingRow.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/NowNext/components/UpcomingRow.tsx@@ -34,11 +34,12 @@ export function UpcomingRow({ item }: Props) {<div className="min-w-0 flex-1"><Textvariant="body-medium"- className="truncate text-[13px] leading-5 text-zinc-900"+ tone="primary"+ className="truncate leading-5">{item.title}</Text>- <Text variant="body" className="truncate text-zinc-500">+ <Text variant="body" tone="muted" className="truncate">{item.expert?.name ??(item.kind === "followup" ? "Follow-up" : "Scheduled task")}<span aria-hidden="true"> · </span>diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/RecentWork.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/RecentWork.tsxindex 129735b0ea..ee43fc05ca 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/RecentWork.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/RecentWork.tsx@@ -29,13 +29,28 @@ export function RecentWork({ dashboard, className }: Props) {title="Recent work"meta={<>- <span className="hidden sm:inline">This week</span>+ <Text+ variant="small"+ as="span"+ tone="muted"+ className="hidden sm:inline"+ >+ This week+ </Text><span aria-hidden="true" className="hidden text-zinc-300 sm:inline">·</span>- <span className="tabular-nums">{completed} completed</span>+ <Text variant="small" as="span" tone="muted" className="tabular-nums">+ {completed} completed+ </Text>{failed > 0 ? (- <span className="tabular-nums text-rose-600">{failed} failed</span>+ <Text+ variant="small"+ as="span"+ className="tabular-nums text-rose-600"+ >+ {failed} failed+ </Text>) : null}</>}@@ -50,7 +65,8 @@ export function RecentWork({ dashboard, className }: Props) {{briefing.narrative ? (<Textvariant="body"- className="text-pretty px-4 py-3 text-[13px] leading-5 text-zinc-600"+ tone="secondary"+ className="text-pretty px-4 py-3 leading-5">{briefing.narrative}</Text>diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/components/OutcomeRow.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/components/OutcomeRow.tsxindex 646243f930..2d1af039c3 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/components/OutcomeRow.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/components/OutcomeRow.tsx@@ -48,13 +48,19 @@ export function OutcomeRow({{mark}<Textvariant="body"- className="min-w-0 flex-1 truncate text-[13px] leading-5 text-zinc-700"+ tone="secondary"+ className="min-w-0 flex-1 truncate leading-5">{outcome.title}</Text>- <span className="shrink-0 text-[11px] tabular-nums text-zinc-400">+ <Text+ variant="small"+ as="span"+ tone="muted"+ className="shrink-0 tabular-nums"+ >{formatWorkTime(outcome.occurred_at, timezone)}- </span>+ </Text></>) : (<>@@ -62,13 +68,15 @@ export function OutcomeRow({<div className="min-w-0 flex-1"><Textvariant="body-medium"- className="text-pretty text-[13px] leading-5 text-zinc-900"+ tone="primary"+ className="text-pretty leading-5">{outcome.title}</Text><Text- variant="small"- className="mt-0.5 line-clamp-2 text-pretty text-[13px] leading-5 text-zinc-500"+ variant="body"+ tone="muted"+ className="mt-0.5 line-clamp-2 text-pretty leading-5">{outcome.summary}</Text>@@ -125,13 +133,18 @@ function RunMeta({ outcome, timezone, showAgentName }: Omit<Props, "compact">) {].filter(Boolean);return (- <div className="mt-1 flex flex-wrap items-center gap-x-1.5 gap-y-1 text-[11px] text-zinc-400">+ <Text+ variant="small"+ as="div"+ tone="muted"+ className="mt-1 flex flex-wrap items-center gap-x-1.5 gap-y-1"+ >{parts.map((part, index) => (<span key={index} className="flex items-center gap-x-1.5">{index > 0 ? <span aria-hidden="true">·</span> : null}{part}</span>))}- </div>+ </Text>);}diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/components/WorkGroup.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/components/WorkGroup.tsxindex 3e7e6307b0..7f5c0318c2 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/components/WorkGroup.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/components/WorkGroup.tsx@@ -20,18 +20,25 @@ export function WorkGroup({ group, timezone }: Props) {const header = (<div className="flex min-w-0 items-center gap-2"><ActorMark actor={actor} />- <Text- variant="body-medium"- className="truncate text-sm font-semibold leading-5 text-zinc-900"- >+ <Text variant="body-medium" tone="primary" className="truncate leading-5">{actor.name}</Text>- <span className="shrink-0 rounded-full border border-zinc-200 bg-white px-1.5 text-[10px] font-medium uppercase leading-4 tracking-[0.04em] text-zinc-500">+ <Text+ variant="small-medium"+ as="span"+ tone="muted"+ className="shrink-0 rounded-full border border-zinc-200 bg-white px-1.5 uppercase leading-4 tracking-[0.04em]"+ >{getActorKindLabel(actor.kind)}- </span>- <span className="ml-auto shrink-0 text-[11px] tabular-nums text-zinc-400">+ </Text>+ <Text+ variant="small"+ tone="muted"+ className="ml-auto shrink-0 tabular-nums"+ as="span"+ >{formatGroupCounts(group)}- </span>+ </Text>{actor.link ? (<Iconicon={ArrowUpRight01Icon}diff --git a/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/components/WorkItemRow.tsx b/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/components/WorkItemRow.tsxindex b7a1eee6a5..dcf2f34baf 100644--- a/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/components/WorkItemRow.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/home/components/RecentWork/components/WorkItemRow.tsx@@ -23,15 +23,21 @@ export function WorkItemRow({ item, timezone }: Props) {/></span><Text- variant="small"- className="min-w-0 flex-1 truncate text-[13px] leading-5 text-zinc-700"+ variant="body"+ tone="secondary"+ className="min-w-0 flex-1 truncate leading-5">{item.title}</Text>- <span className="shrink-0 text-[11px] tabular-nums text-zinc-400">+ <Text+ variant="small"+ as="span"+ tone="muted"+ className="shrink-0 tabular-nums"+ >{item.provider ? `${item.provider} · ` : ""}{formatWorkTime(item.occurred_at, timezone)}- </span>+ </Text></>);diff --git a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/modals/RunAgentModal/RunAgentModal.tsx b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/modals/RunAgentModal/RunAgentModal.tsxindex 0353c044ed..8865305ad8 100644--- a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/modals/RunAgentModal/RunAgentModal.tsx+++ b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/modals/RunAgentModal/RunAgentModal.tsx@@ -32,6 +32,10 @@ interface Props {onRunCreated?: (execution: GraphExecutionMeta) => void;onTriggerSetup?: (preset: LibraryAgentPreset) => void;onScheduleCreated?: (schedule: GraphExecutionJobInfo) => void;+ /** Hosts that call agents something else (the expert page's workflows)+ * override the dialog title. */+ title?: string;+ dialogVariant?: "default" | "compact";}export function RunAgentModal({@@ -42,6 +46,8 @@ export function RunAgentModal({onRunCreated,onTriggerSetup,onScheduleCreated,+ title = "Run Agent",+ dialogVariant = "default",}: Props) {const {// UI state@@ -201,7 +207,8 @@ export function RunAgentModal({return (<><Dialog- title="Run Agent"+ title={title}+ variant={dialogVariant}controlled={{ isOpen, set: handleSetOpen }}styling={{ maxWidth: "600px", maxHeight: "90vh" }}>diff --git a/autogpt_platform/frontend/src/components/atoms/Button/Button.stories.tsx b/autogpt_platform/frontend/src/components/atoms/Button/Button.stories.tsxindex e525d313b5..673d8c83a5 100644--- a/autogpt_platform/frontend/src/components/atoms/Button/Button.stories.tsx+++ b/autogpt_platform/frontend/src/components/atoms/Button/Button.stories.tsx@@ -1,4 +1,15 @@import type { Meta, StoryObj } from "@storybook/nextjs";+import {+ Cancel01Icon,+ FilterHorizontalIcon,+ GridViewIcon,+ ListViewIcon,+ MoreHorizontalIcon,+ PencilEdit02Icon,+ PlusSignIcon,+ SparklesIcon,+ Tick02Icon,+} from "@hugeicons/core-free-icons";import { Play, Plus } from "lucide-react";import { TooltipProvider } from "../Tooltip/BaseTooltip";import { Button } from "./Button";@@ -32,6 +43,9 @@ const meta: Meta<typeof Button> = {"destructive","outline","ghost",+ "icon",+ "floating",+ "toggle","link","loading",],@@ -39,7 +53,7 @@ const meta: Meta<typeof Button> = {},size: {control: "select",- options: ["small", "large", "icon"],+ options: ["small", "large", "icon", "xs", "icon-xs", "icon-sm"],description: "Button size",},loading: {@@ -181,6 +195,43 @@ export const LargeButtons: Story = {render: renderLargeButtons,};+// Compact actions (team, home)+export const ActionButtons: Story = {+ render: renderActionButtons,+ parameters: {+ docs: {+ description: {+ story:+ '`size="xs"` is the 28px rounded-rectangle chip used for row and header actions across Home and Team. Pair with `leadingIcon` for a 14px Hugeicon.',+ },+ },+ },+};++export const IconButtons: Story = {+ render: renderIconButtons,+ parameters: {+ docs: {+ description: {+ story:+ '`size="icon-xs"` (28px) and `size="icon-sm"` (32px) are square icon-only actions. `aria-label` is required and doubles as the tooltip. `variant="floating"` sits over images and card covers.',+ },+ },+ },+};++export const ToggleButtons: Story = {+ render: renderToggleButtons,+ parameters: {+ docs: {+ description: {+ story:+ '`variant="toggle"` reads `aria-pressed` for its on state. Use it for filter chips and segmented controls.',+ },+ },+ },+};+// With iconsexport const WithLeftIcon: Story = {args: {@@ -218,6 +269,149 @@ export const AllVariants: Story = {};// Render functions as function declarations+function renderActionButtons() {+ return (+ <div className="space-y-6">+ <div className="flex flex-wrap items-center gap-2">+ <Button variant="primary" size="xs">+ Chat+ </Button>+ <Button variant="secondary" size="xs">+ Manage+ </Button>+ <Button variant="outline" size="xs">+ New Pod+ </Button>+ <Button variant="ghost" size="xs">+ Open in library+ </Button>+ <Button variant="destructive" size="xs">+ Fire Maria+ </Button>+ </div>+ <div className="flex flex-wrap items-center gap-2">+ <Button variant="primary" size="xs" leadingIcon={SparklesIcon}>+ New Expert+ </Button>+ <Button variant="secondary" size="xs" leadingIcon={PencilEdit02Icon}>+ Edit Soul+ </Button>+ <Button variant="secondary" size="xs" leadingIcon={PlusSignIcon}>+ Install workflow+ </Button>+ <Button+ variant="ghost"+ size="xs"+ leadingIcon={FilterHorizontalIcon}+ className="text-zinc-600"+ >+ All work+ </Button>+ </div>+ <div className="flex flex-wrap items-center gap-2">+ <Button variant="secondary" size="xs" loading>+ Resuming...+ </Button>+ <Button variant="secondary" size="xs" disabled>+ Disabled+ </Button>+ <Button as="NextLink" href="#" variant="secondary" size="xs">+ Review+ </Button>+ </div>+ </div>+ );+}++function renderIconButtons() {+ return (+ <div className="space-y-6">+ <div className="flex flex-wrap items-center gap-2">+ <Button+ variant="icon"+ size="icon-xs"+ leadingIcon={FilterHorizontalIcon}+ aria-label="Filter workflows"+ />+ <Button+ variant="primary"+ size="icon-xs"+ leadingIcon={Tick02Icon}+ aria-label="Approve"+ />+ <Button+ variant="destructive"+ size="icon-xs"+ leadingIcon={Cancel01Icon}+ aria-label="Confirm decline"+ />+ <Button+ variant="ghost"+ size="icon-xs"+ leadingIcon={MoreHorizontalIcon}+ aria-label="More actions"+ />+ </div>+ <div className="flex flex-wrap items-center gap-2 rounded-lg bg-gradient-to-r from-violet-200 to-sky-200 p-4">+ <Button+ variant="floating"+ size="icon-xs"+ leadingIcon={PencilEdit02Icon}+ aria-label="Edit workflow"+ />+ <Button+ variant="floating"+ size="icon-xs"+ leadingIcon={SparklesIcon}+ aria-label="Ask about this workflow"+ />+ <Button+ variant="floating"+ size="icon-sm"+ leadingIcon={PencilEdit02Icon}+ aria-label="Edit Soul"+ />+ </div>+ </div>+ );+}++function renderToggleButtons() {+ return (+ <div className="flex flex-wrap items-center gap-4">+ <Button variant="toggle" size="xs" aria-pressed={false}>+ Needs review (3)+ </Button>+ <Button+ variant="toggle"+ size="xs"+ aria-pressed+ className="border-zinc-200 bg-white aria-pressed:border-amber-200 aria-pressed:bg-amber-100 aria-pressed:text-amber-700"+ >+ Needs review (3)+ </Button>+ <div className="flex h-7 items-center rounded-md border border-zinc-200 p-0.5">+ <Button+ variant="toggle"+ size="icon-xs"+ className="size-6 rounded"+ leadingIcon={ListViewIcon}+ aria-label="List view"+ aria-pressed+ />+ <Button+ variant="toggle"+ size="icon-xs"+ className="size-6 rounded"+ leadingIcon={GridViewIcon}+ aria-label="Grid view"+ aria-pressed={false}+ />+ </div>+ </div>+ );+}+function renderContextualLoadingExamples() {return (<div className="space-y-6">diff --git a/autogpt_platform/frontend/src/components/atoms/Button/Button.test.tsx b/autogpt_platform/frontend/src/components/atoms/Button/Button.test.tsxindex 8c115ae013..6a76f42e7a 100644--- a/autogpt_platform/frontend/src/components/atoms/Button/Button.test.tsx+++ b/autogpt_platform/frontend/src/components/atoms/Button/Button.test.tsx@@ -1,5 +1,6 @@import { TooltipProvider } from "@/components/atoms/Tooltip/BaseTooltip";import { render, screen, cleanup } from "@testing-library/react";+import { PencilEdit02Icon } from "@hugeicons/core-free-icons";import { afterEach, describe, expect, it } from "vitest";import { Button } from "./Button";import { ButtonProps } from "./helpers";@@ -102,3 +103,58 @@ describe("Button unmask prop", () => {expect(el.className).not.toContain("sentry-unmask");});});++describe("Button compact sizes", () => {+ it("renders xs as a 28px rounded-rectangle chip", () => {+ renderButton({ variant: "secondary", size: "xs", children: "Chat" });+ const el = screen.getByRole("button", { name: "Chat" });+ expect(el.className).toContain("h-7");+ expect(el.className).toContain("rounded-md");+ expect(el.className).not.toContain("rounded-full");+ });++ it("softens the outline border at xs", () => {+ renderButton({ variant: "outline", size: "xs", children: "New Pod" });+ const el = screen.getByRole("button", { name: "New Pod" });+ expect(el.className).toContain("border-zinc-200");+ expect(el.className).not.toContain("border-zinc-700");+ });++ it("renders a leadingIcon before the label", () => {+ renderButton({+ size: "xs",+ leadingIcon: PencilEdit02Icon,+ children: "Edit Soul",+ });+ const el = screen.getByRole("button", { name: "Edit Soul" });+ expect(el.querySelector("svg")).not.toBeNull();+ expect(el.querySelector("svg")?.getAttribute("width")).toBe("14");+ });++ it("names icon-only buttons by aria-label", () => {+ renderButton({+ variant: "floating",+ size: "icon-xs",+ leadingIcon: PencilEdit02Icon,+ "aria-label": "Edit workflow",+ children: undefined,+ });+ const el = screen.getByRole("button", { name: "Edit workflow" });+ expect(el.className).toContain("size-7");+ expect(el.className).toContain("bg-white/90");+ });++ it("styles toggle by aria-pressed", () => {+ renderButton({+ variant: "toggle",+ size: "xs",+ "aria-pressed": true,+ children: "Needs review",+ });+ const el = screen.getByRole("button", {+ name: "Needs review",+ pressed: true,+ });+ expect(el.className).toContain("aria-pressed:bg-zinc-100");+ });+});diff --git a/autogpt_platform/frontend/src/components/atoms/Button/Button.tsx b/autogpt_platform/frontend/src/components/atoms/Button/Button.tsxindex 99b9ac45da..e539e7e96b 100644--- a/autogpt_platform/frontend/src/components/atoms/Button/Button.tsx+++ b/autogpt_platform/frontend/src/components/atoms/Button/Button.tsx@@ -6,7 +6,12 @@ import {import { cn } from "@/lib/utils";import NextLink, { type LinkProps } from "next/link";import React from "react";-import { ButtonProps, extendedButtonVariants } from "./helpers";+import {+ BUTTON_ICON_SIZE,+ ButtonProps,+ extendedButtonVariants,+ ICON_ONLY_SIZES,+} from "./helpers";import { Loading03Icon } from "@hugeicons/core-free-icons";import { Icon } from "@/components/atoms/Icon/Icon";@@ -17,6 +22,7 @@ export function Button(props: ButtonProps) {size,loading = false,withTooltip = true,+ leadingIcon,leftIcon,rightIcon,children,@@ -36,8 +42,18 @@ export function Button(props: ButtonProps) {const ariaLabel ="aria-label" in restProps ? restProps["aria-label"] : undefined;- const shouldShowTooltip =- variant === "icon" && ariaLabel && !loading && withTooltip;+ const isIconOnly =+ variant === "icon" || (size != null && ICON_ONLY_SIZES.has(size));+ const shouldShowTooltip = isIconOnly && ariaLabel && !loading && withTooltip;+ const resolvedLeftIcon = leadingIcon ? (+ <Icon+ icon={leadingIcon}+ size={BUTTON_ICON_SIZE[size ?? "large"]}+ aria-hidden+ />+ ) : (+ leftIcon+ );// Helper to wrap button with tooltip if neededconst wrapWithTooltip = (buttonElement: React.ReactElement) => {@@ -57,7 +73,7 @@ export function Button(props: ButtonProps) {{loading && (<Icon icon={Loading03Icon} className="h-4 w-4 animate-spin" />)}- {!loading && leftIcon}+ {!loading && resolvedLeftIcon}{children}{!loading && rightIcon}</>diff --git a/autogpt_platform/frontend/src/components/atoms/Button/helpers.ts b/autogpt_platform/frontend/src/components/atoms/Button/helpers.tsindex 644bda68a4..43077d025a 100644--- a/autogpt_platform/frontend/src/components/atoms/Button/helpers.ts+++ b/autogpt_platform/frontend/src/components/atoms/Button/helpers.ts@@ -5,6 +5,7 @@ import {} from "@/components/atoms/Link/Link";import { cn } from "@/lib/utils";import { cva, VariantProps } from "class-variance-authority";+import { IconSvgElement } from "@hugeicons/react";import { LinkProps } from "next/link";// Extended button variants based on our design system@@ -24,6 +25,10 @@ export const extendedButtonVariants = cva(ghost:"bg-transparent border-transparent text-black hover:bg-zinc-50 hover:border-zinc-50 rounded-full disabled:text-zinc-200 disabled:opacity-1",icon: "bg-transparent text-black border border-zinc-300 hover:bg-zinc-100 hover:border-zinc-600 rounded-[96px] disabled:opacity-1 !min-w-0",+ toggle:+ "bg-transparent border-transparent text-zinc-500 hover:bg-transparent hover:border-transparent hover:text-zinc-800 aria-pressed:bg-zinc-100 aria-pressed:text-zinc-900 rounded-md disabled:opacity-50",+ floating:+ "bg-white/90 border-transparent text-zinc-700 backdrop-blur hover:bg-white hover:border-transparent hover:text-zinc-900 rounded-md disabled:text-zinc-300 disabled:opacity-1",link: cn(linkBaseClasses,linkVariantClasses.secondary,@@ -35,8 +40,24 @@ export const extendedButtonVariants = cva(small: "px-3 py-2 text-sm gap-1.5 h-[2.25rem] min-w-[5.5rem]",large: "px-4 py-3 text-sm gap-2 h-[3.25rem]",icon: "p-3 !min-w-0",+ xs: "h-7 min-w-0 gap-1.5 rounded-md px-2.5 text-xs",+ "icon-xs": "size-7 min-w-0 rounded-md p-0",+ "icon-sm": "size-8 min-w-0 rounded-lg p-0",},},+ compoundVariants: [+ {+ variant: "outline",+ size: ["xs", "icon-xs", "icon-sm"],+ class: "border-zinc-200 hover:border-zinc-300",+ },+ {+ variant: "icon",+ size: ["icon-xs", "icon-sm"],+ class:+ "border-zinc-200 text-zinc-600 hover:border-zinc-300 hover:bg-zinc-50",+ },+ ],defaultVariants: {variant: "primary",size: "large",@@ -44,8 +65,24 @@ export const extendedButtonVariants = cva(},);+export const BUTTON_ICON_SIZE = {+ small: 16,+ large: 18,+ icon: 16,+ xs: 14,+ "icon-xs": 14,+ "icon-sm": 16,+} as const;++export const ICON_ONLY_SIZES: ReadonlySet<string> = new Set([+ "icon-xs",+ "icon-sm",+]);+type BaseButtonProps = {loading?: boolean;+ /** Hugeicon rendered before the label at the size's icon scale. */+ leadingIcon?: IconSvgElement;leftIcon?: React.ReactNode;rightIcon?: React.ReactNode;asChild?: boolean;diff --git a/autogpt_platform/frontend/src/components/atoms/Text/Text.stories.tsx b/autogpt_platform/frontend/src/components/atoms/Text/Text.stories.tsxindex 94f0c1589a..4baae480f1 100644--- a/autogpt_platform/frontend/src/components/atoms/Text/Text.stories.tsx+++ b/autogpt_platform/frontend/src/components/atoms/Text/Text.stories.tsx@@ -1,6 +1,6 @@import { StoryCode } from "@/components/tokens/helpers/StoryCode";import type { Meta, StoryObj } from "@storybook/nextjs";-import { Text, textVariants } from "./Text";+import { Text, textTones, textVariants } from "./Text";const meta: Meta<typeof Text> = {title: "Atoms/Text",@@ -25,6 +25,11 @@ const meta: Meta<typeof Text> = {options: textVariants,description: "Typography variant to apply",},+ tone: {+ control: { type: "select" },+ options: [undefined, ...textTones],+ description: "Semantic colour",+ },as: {control: { type: "select" },options: ["h1", "h2", "h3", "h4", "h5", "h6", "p", "span", "div", "code"],@@ -187,3 +192,68 @@ export function CustomElement() {</div>);}++//=============================================================================+// Tones+//=============================================================================+export function Tones() {+ return (+ <div className="space-y-6 p-8">+ <Text variant="body">Default (black)</Text>+ <Text variant="body" tone="primary">+ Primary · zinc-900 · titles and values+ </Text>+ <Text variant="body" tone="secondary">+ Secondary · zinc-600 · descriptions+ </Text>+ <Text variant="body" tone="muted">+ Muted · zinc-500 · meta, captions, empty states+ </Text>+ <Text variant="body" tone="danger">+ Danger · red-600 · destructive copy+ </Text>+ <StoryCode+ code={`<Text variant="body" tone="primary">Primary</Text>+<Text variant="body" tone="secondary">Secondary</Text>+<Text variant="body" tone="muted">Muted</Text>+<Text variant="body" tone="danger">Danger</Text>`}+ />+ </div>+ );+}++//=============================================================================+// Text roles (Home / Team)+//=============================================================================+export function TextRoles() {+ return (+ <div className="max-w-md space-y-3 p-8">+ <Text variant="eyebrow">Needs you</Text>+ <Text variant="large-medium" tone="primary">+ Section title · large-medium+ </Text>+ <Text variant="body-medium" tone="primary">+ Row title · body-medium+ </Text>+ <Text variant="body" tone="secondary">+ Description · body · secondary+ </Text>+ <Text variant="small" tone="muted" className="tabular-nums">+ Meta · small · muted · 2 files · 1 action+ </Text>+ <Text variant="small-medium" tone="muted">+ Chip label · small-medium+ </Text>+ <StoryCode+ code={`<Text variant="eyebrow">Needs you</Text>+<Text variant="large-medium" tone="primary">Section title</Text>+<Text variant="body-medium" tone="primary">Row title</Text>+<Text variant="body" tone="secondary">Description</Text>+<Text variant="small" tone="muted" className="tabular-nums">Meta</Text>`}+ />+ <Text variant="small" tone="muted">+ Floor is 12px (small). No arbitrary px sizes.+ </Text>+ </div>+ );+}diff --git a/autogpt_platform/frontend/src/components/atoms/Text/Text.test.tsx b/autogpt_platform/frontend/src/components/atoms/Text/Text.test.tsxindex 7317231762..a2bd30fa67 100644--- a/autogpt_platform/frontend/src/components/atoms/Text/Text.test.tsx+++ b/autogpt_platform/frontend/src/components/atoms/Text/Text.test.tsx@@ -62,3 +62,29 @@ describe("Text unmask prop", () => {expect(el.className).not.toContain("sentry-unmask");});});++describe("Text tone and eyebrow", () => {+ it("applies the tone colour over the variant default", () => {+ render(+ <Text variant="small" tone="muted">+ Meta+ </Text>,+ );+ const el = screen.getByText("Meta");+ expect(el.className).toContain("text-zinc-500");+ expect(el.className).not.toContain("text-black");+ });++ it("keeps black when no tone is given", () => {+ render(<Text variant="body">Plain</Text>);+ expect(screen.getByText("Plain").className).toContain("text-black");+ });++ it("renders eyebrow as a 12px uppercase span", () => {+ render(<Text variant="eyebrow">Needs you</Text>);+ const el = screen.getByText("Needs you");+ expect(el.tagName).toBe("SPAN");+ expect(el.className).toContain("uppercase");+ expect(el.className).toContain("text-[0.75rem]");+ });+});diff --git a/autogpt_platform/frontend/src/components/atoms/Text/Text.tsx b/autogpt_platform/frontend/src/components/atoms/Text/Text.tsxindex 76e04368d9..592767e32a 100644--- a/autogpt_platform/frontend/src/components/atoms/Text/Text.tsx+++ b/autogpt_platform/frontend/src/components/atoms/Text/Text.tsx@@ -1,11 +1,20 @@import React from "react";import { cn } from "@/lib/utils";-import { As, Variant, variantElementMap, variants } from "./helpers";+import {+ As,+ Tone,+ tones,+ Variant,+ variantElementMap,+ variants,+} from "./helpers";type CustomProps = {variant: Variant;as?: As;size?: Variant;+ /** Semantic colour: primary zinc-900, secondary zinc-600, muted zinc-500, danger red-600. */+ tone?: Tone;className?: string;/*** Adds the sentry-unmask class for static text visibility in replays.@@ -23,6 +32,7 @@ export function Text({variant,as: outerAs,size,+ tone,className = "",unmask = true,...rest@@ -31,6 +41,7 @@ export function Text({const Element = outerAs || variantElementMap[variant];const combinedClassName = cn(variantClasses,+ tone && tones[tone],unmask && "sentry-unmask",className,);@@ -47,4 +58,5 @@ export function Text({// Export variant names for use in storiesexport const textVariants = Object.keys(variants) as Variant[];+export const textTones = Object.keys(tones) as Tone[];export type TextVariant = Variant;diff --git a/autogpt_platform/frontend/src/components/atoms/Text/helpers.ts b/autogpt_platform/frontend/src/components/atoms/Text/helpers.tsindex cf5d9c1da0..31e02a96c9 100644--- a/autogpt_platform/frontend/src/components/atoms/Text/helpers.ts+++ b/autogpt_platform/frontend/src/components/atoms/Text/helpers.ts@@ -10,7 +10,10 @@ export type As =| "div"| "code"| "label"- | "kbd";+ | "kbd"+ | "li"+ | "dt"+ | "dd";export const variants = {// Headings@@ -41,10 +44,22 @@ export const variants = {// Label Textlabel:"font-sans text-[0.6785rem] font-medium uppercase leading-[1.25rem] tracking-[0.06785rem] text-black",+ eyebrow:+ "font-sans text-[0.75rem] font-[500] uppercase leading-[1rem] tracking-[0.06em] text-zinc-500",} as const;export type Variant = keyof typeof variants;+/** Semantic colours. Omit for the variant's own colour (black). */+export const tones = {+ primary: "text-zinc-900",+ secondary: "text-zinc-600",+ muted: "text-zinc-500",+ danger: "text-red-600",+} as const;++export type Tone = keyof typeof tones;+export const variantElementMap: Record<Variant, As> = {h1: "h1",h2: "h2",@@ -62,4 +77,5 @@ export const variantElementMap: Record<Variant, As> = {small: "p","small-medium": "p",label: "span",+ eyebrow: "span",};diff --git a/autogpt_platform/frontend/src/components/molecules/Dialog/Dialog.tsx b/autogpt_platform/frontend/src/components/molecules/Dialog/Dialog.tsxindex d14b572ed7..dfc7d41d6f 100644--- a/autogpt_platform/frontend/src/components/molecules/Dialog/Dialog.tsx+++ b/autogpt_platform/frontend/src/components/molecules/Dialog/Dialog.tsx@@ -6,11 +6,14 @@ import { Drawer } from "vaul";import { BaseContent } from "./components/BaseContent";import { BaseFooter } from "./components/BaseFooter";import { BaseTrigger } from "./components/BaseTrigger";-import { DialogCtx, useDialogCtx } from "./useDialogCtx";+import { DialogCtx, DialogVariant, useDialogCtx } from "./useDialogCtx";import { useDialogInternal } from "./useDialogInternal";interface Props extends PropsWithChildren {title?: React.ReactNode;+ /** `compact` is the dense neutral style: smaller radius, tighter padding,+ * sans title. */+ variant?: DialogVariant;styling?: CSSProperties;className?: string;@@ -29,6 +32,7 @@ Dialog.Footer = BaseFooter;function Dialog({children,title,+ variant = "default",styling,className,@@ -43,6 +47,7 @@ function Dialog({<DialogCtx.Providervalue={{title: title || "",+ variant,styling,className,diff --git a/autogpt_platform/frontend/src/components/molecules/Dialog/components/DialogWrap.tsx b/autogpt_platform/frontend/src/components/molecules/Dialog/components/DialogWrap.tsxindex 8c56657715..834ecc9f31 100644--- a/autogpt_platform/frontend/src/components/molecules/Dialog/components/DialogWrap.tsx+++ b/autogpt_platform/frontend/src/components/molecules/Dialog/components/DialogWrap.tsx@@ -10,8 +10,8 @@ import {useRef,useState,} from "react";-import { DialogCtx } from "../useDialogCtx";-import { modalStyles } from "./styles";+import { DialogCtx, DialogVariant } from "../useDialogCtx";+import { compactStyles, modalStyles } from "./styles";import { Cancel01Icon } from "@hugeicons/core-free-icons";import { Icon } from "@/components/atoms/Icon/Icon";@@ -19,6 +19,7 @@ type BaseProps = DialogCtx & PropsWithChildren;interface Props extends BaseProps {title: React.ReactNode;+ variant: DialogVariant;styling: CSSProperties | undefined;withGradient?: boolean;}@@ -34,6 +35,7 @@ function isExternalPickerOpen(): boolean {export function DialogWrap({children,title,+ variant,styling = {},className,isForceOpen,@@ -41,6 +43,7 @@ export function DialogWrap({}: Props) {const scrollRef = useRef<HTMLDivElement | null>(null);const [hasVerticalScrollbar, setHasVerticalScrollbar] = useState(false);+ const isCompact = variant === "compact";// Prevent dialog from closing when external picker is open or when forceOpen is trueconst handleInteractOutside = useCallback(@@ -98,18 +101,25 @@ export function DialogWrap({onFocusOutside={handleFocusOutside}onEscapeKeyDown={isForceOpen ? undefined : handleClose}aria-describedby={undefined}- className={cn(modalStyles.content, className)}+ className={cn(+ modalStyles.content,+ isCompact && compactStyles.content,+ className,+ )}style={{...styling,}}><div- className={`flex items-center justify-between px-2 ${- title ? "pb-6" : "pb-0"- }`}+ className={cn(+ "flex items-center justify-between px-2",+ title ? (isCompact ? compactStyles.header : "pb-6") : "pb-0",+ )}>{title ? (- <RXDialog.Title className={modalStyles.title}>+ <RXDialog.Title+ className={isCompact ? compactStyles.title : modalStyles.title}+ >{title}</RXDialog.Title>) : (@@ -119,10 +129,13 @@ export function DialogWrap({{isForceOpen ? null : (<Buttonvariant="icon"- size="icon"+ size={isCompact ? "icon-sm" : "icon"}onClick={handleClose}aria-label="Close"- className="absolute right-4 top-4 z-50 size-[2.5rem] bg-white"+ className={cn(+ "absolute right-4 top-4 z-50 bg-white",+ isCompact ? compactStyles.close : "size-[2.5rem]",+ )}withTooltip={false}><Icon icon={Cancel01Icon} width="1rem" />diff --git a/autogpt_platform/frontend/src/components/molecules/Dialog/components/DrawerWrap.tsx b/autogpt_platform/frontend/src/components/molecules/Dialog/components/DrawerWrap.tsxindex 83624adc6d..bdb89fc762 100644--- a/autogpt_platform/frontend/src/components/molecules/Dialog/components/DrawerWrap.tsx+++ b/autogpt_platform/frontend/src/components/molecules/Dialog/components/DrawerWrap.tsx@@ -4,7 +4,7 @@ import { cn } from "@/lib/utils";import { PropsWithChildren } from "react";import { Drawer } from "vaul";import { DialogCtx } from "../useDialogCtx";-import { drawerStyles, modalStyles } from "./styles";+import { compactStyles, drawerStyles, modalStyles } from "./styles";import { Cancel01Icon } from "@hugeicons/core-free-icons";import { Icon } from "@/components/atoms/Icon/Icon";@@ -19,6 +19,7 @@ interface Props extends BaseProps {export function DrawerWrap({children,title,+ variant,testId,handleClose,isForceOpen,@@ -26,6 +27,7 @@ export function DrawerWrap({}: Props) {const accessibleTitle = title || "Dialog";const hasVisibleTitle = Boolean(title);+ const isCompact = variant === "compact";const closeBtn = (<Button@@ -34,7 +36,7 @@ export function DrawerWrap({onClick={handleClose}className="!focus-visible:ring-0 p-0">- <Icon icon={Cancel01Icon} width="1.5rem" />+ <Icon icon={Cancel01Icon} width={isCompact ? "1.25rem" : "1.5rem"} /></Button>);@@ -43,17 +45,28 @@ export function DrawerWrap({<Drawer.Overlay className={drawerStyles.overlay} /><Drawer.Contentaria-describedby={undefined}- className={cn(drawerStyles.content, className)}+ className={cn(+ drawerStyles.content,+ isCompact && compactStyles.drawerContent,+ className,+ )}data-testid={testId}onInteractOutside={handleClose}><div- className={`flex w-full shrink-0 items-center justify-between ${- hasVisibleTitle ? "pb-6" : "pb-0"- }`}+ className={cn(+ "flex w-full shrink-0 items-center justify-between",+ hasVisibleTitle+ ? isCompact+ ? compactStyles.header+ : "pb-6"+ : "pb-0",+ )}>{hasVisibleTitle ? (- <Drawer.Title className={drawerStyles.title}>+ <Drawer.Title+ className={isCompact ? compactStyles.title : drawerStyles.title}+ >{accessibleTitle}</Drawer.Title>) : (diff --git a/autogpt_platform/frontend/src/components/molecules/Dialog/components/styles.ts b/autogpt_platform/frontend/src/components/molecules/Dialog/components/styles.tsindex dbacda0cb9..2f1b8a5364 100644--- a/autogpt_platform/frontend/src/components/molecules/Dialog/components/styles.ts+++ b/autogpt_platform/frontend/src/components/molecules/Dialog/components/styles.ts@@ -15,6 +15,17 @@ export const modalStyles = {icon: "w-4 h-4 text-stone-800",};+// Compact variant: dense neutral dialog for in-app forms — smaller radius,+// tighter padding, sans title.+export const compactStyles = {+ content: "rounded-xl p-5",+ title: "font-sans text-base font-medium leading-6 text-zinc-900",+ header: "pb-4",+ close: "right-3 top-3",+ // Bottom sheet keeps its top-only radius; only the padding tightens.+ drawerContent: "p-5",+};+// Drawer specific stylesexport const drawerStyles = {...commonStyles,diff --git a/autogpt_platform/frontend/src/components/molecules/Dialog/useDialogCtx.ts b/autogpt_platform/frontend/src/components/molecules/Dialog/useDialogCtx.tsindex 9cd5273514..a796ce9622 100644--- a/autogpt_platform/frontend/src/components/molecules/Dialog/useDialogCtx.ts+++ b/autogpt_platform/frontend/src/components/molecules/Dialog/useDialogCtx.ts@@ -6,8 +6,11 @@ export function useDialogCtx() {return modalContext;}+export type DialogVariant = "default" | "compact";+export interface DialogCtx {title: React.ReactNode;+ variant: DialogVariant;handleOpen: () => void;handleClose: () => void;isOpen: boolean;@@ -19,6 +22,7 @@ export interface DialogCtx {export const DialogCtx = createContext<DialogCtx>({title: "",+ variant: "default",isOpen: false,isForceOpen: false,isLargeScreen: true,diff --git a/autogpt_platform/frontend/src/components/molecules/InstallWorkflowPicker/InstallWorkflowPicker.tsx b/autogpt_platform/frontend/src/components/molecules/InstallWorkflowPicker/InstallWorkflowPicker.tsxindex 67229bc86c..a3c334d829 100644--- a/autogpt_platform/frontend/src/components/molecules/InstallWorkflowPicker/InstallWorkflowPicker.tsx+++ b/autogpt_platform/frontend/src/components/molecules/InstallWorkflowPicker/InstallWorkflowPicker.tsx@@ -9,7 +9,8 @@ import { Button } from "@/components/atoms/Button/Button";import { Input } from "@/components/atoms/Input/Input";import { Text } from "@/components/atoms/Text/Text";import { Dialog } from "@/components/molecules/Dialog/Dialog";-import { cn } from "@/lib/utils";+import { Icon } from "@/components/atoms/Icon/Icon";+import { WorkflowSquare01Icon } from "@hugeicons/core-free-icons";import { INSTALL_WORKFLOW_SOURCES, workflowSubtitle } from "./helpers";import { useInstallWorkflowPicker } from "./useInstallWorkflowPicker";@@ -61,7 +62,8 @@ export function InstallWorkflowPicker({return (<Dialogtitle={title}- styling={{ width: "480px" }}+ variant="compact"+ styling={{ width: "480px", maxHeight: "70vh" }}controlled={{isOpen: open,set: (nextOpen) => {@@ -76,7 +78,7 @@ export function InstallWorkflowPicker({No hired experts yet.</Text>) : (- <div className="divide-y divide-zinc-100 overflow-hidden rounded-xl border border-zinc-200/80">+ <div className="divide-y divide-zinc-100 overflow-hidden rounded-lg border border-zinc-200/80">{hiredExperts.map((expert) => (<divkey={expert.id}@@ -98,7 +100,7 @@ export function InstallWorkflowPicker({</div><Buttonvariant="secondary"- size="small"+ size="xs"loading={pendingKey === expert.id}onClick={() => installOnExpert(expert)}>@@ -116,24 +118,21 @@ export function InstallWorkflowPicker({aria-label="Workflow source">{INSTALL_WORKFLOW_SOURCES.map((option) => (- <button+ <Buttonkey={option.id}type="button"+ variant="toggle"+ size="xs"aria-pressed={source === option.id}onClick={() => setSource(option.id)}- className={cn(- "rounded-full px-3 py-1.5 text-sm transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-zinc-900",- source === option.id- ? "bg-zinc-800 text-white"- : "bg-zinc-100 text-zinc-600 hover:bg-zinc-200",- )}>{option.label}- </button>+ </Button>))}</div><Inputid="install-workflow-search"+ size="small"label="Search workflows"hideLabelplaceholder={@@ -143,6 +142,7 @@ export function InstallWorkflowPicker({}value={searchQuery}onChange={(event) => setSearchQuery(event.target.value)}+ wrapperClassName="!mb-0"/>{isSearching ? (<Text variant="small" className="py-2 text-center !text-zinc-500">@@ -155,7 +155,7 @@ export function InstallWorkflowPicker({: "No workflows found."}</Text>) : (- <div className="divide-y divide-zinc-100 overflow-hidden rounded-xl border border-zinc-200/80">+ <div className="divide-y divide-zinc-100 overflow-hidden rounded-lg border border-zinc-200/80">{source === "library"? libraryResults.map((agent) => (<div@@ -163,15 +163,7 @@ export function InstallWorkflowPicker({data-testid="install-workflow-option"className="flex items-center gap-3 px-3.5 py-2.5 transition-colors hover:bg-zinc-50">- <Avatar className="h-9 w-9">- {agent.image_url ? (- <AvatarImage- src={agent.image_url}- alt={agent.name}- />- ) : null}- <AvatarFallback>{agent.name}</AvatarFallback>- </Avatar>+ <WorkflowTile /><div className="min-w-0 flex-1"><Text variant="body-medium" className="truncate">{agent.name}@@ -185,7 +177,7 @@ export function InstallWorkflowPicker({</div><Buttonvariant="secondary"- size="small"+ size="xs"loading={pendingKey === agent.id}onClick={() => installLibraryAgent(agent)}>@@ -199,15 +191,7 @@ export function InstallWorkflowPicker({data-testid="install-workflow-option"className="flex items-center gap-3 px-3.5 py-2.5 transition-colors hover:bg-zinc-50">- <Avatar className="h-9 w-9">- {agent.agent_image ? (- <AvatarImage- src={agent.agent_image}- alt={agent.agent_name}- />- ) : null}- <AvatarFallback>{agent.agent_name}</AvatarFallback>- </Avatar>+ <WorkflowTile /><div className="min-w-0 flex-1"><Text variant="body-medium" className="truncate">{agent.agent_name}@@ -218,7 +202,7 @@ export function InstallWorkflowPicker({</div><Buttonvariant="secondary"- size="small"+ size="xs"loading={pendingKey === agent.agent_graph_id}onClick={() => installFromListing(agent)}>@@ -231,7 +215,7 @@ export function InstallWorkflowPicker({{source === "library" && hasMoreLibraryResults ? (<Buttonvariant="secondary"- size="small"+ size="xs"loading={isLoadingMore}onClick={() => loadMoreLibraryResults()}>@@ -244,3 +228,14 @@ export function InstallWorkflowPicker({</Dialog>);}++function WorkflowTile() {+ return (+ <span+ aria-hidden="true"+ className="flex size-9 shrink-0 items-center justify-center rounded-lg bg-zinc-100 text-zinc-600"+ >+ <Icon icon={WorkflowSquare01Icon} size={18} />+ </span>+ );+}diff --git a/autogpt_platform/frontend/src/components/molecules/TabsLine/TabsLine.stories.tsx b/autogpt_platform/frontend/src/components/molecules/TabsLine/TabsLine.stories.tsxindex 8d1922c420..9afbc95fe6 100644--- a/autogpt_platform/frontend/src/components/molecules/TabsLine/TabsLine.stories.tsx+++ b/autogpt_platform/frontend/src/components/molecules/TabsLine/TabsLine.stories.tsx@@ -1,4 +1,10 @@import type { Meta, StoryObj } from "@storybook/nextjs";+import {+ Briefcase01Icon,+ Calendar03Icon,+ SparklesIcon,+ UserIcon,+} from "@hugeicons/core-free-icons";import {TabsLine,TabsLineContent,@@ -256,3 +262,50 @@ export const FullWidth: Story = {</div>),};++function CompactDemo() {+ return (+ <div className="p-8">+ <TabsLine variant="compact" defaultValue="basics" className="w-full">+ <TabsLineList className="overflow-x-auto">+ <TabsLineTrigger value="basics" icon={UserIcon}>+ Basics+ </TabsLineTrigger>+ <TabsLineTrigger value="work" icon={Briefcase01Icon}>+ Work+ </TabsLineTrigger>+ <TabsLineTrigger value="schedules" icon={Calendar03Icon}>+ Schedules+ </TabsLineTrigger>+ <TabsLineTrigger value="skills" icon={SparklesIcon}>+ Skills+ </TabsLineTrigger>+ </TabsLineList>+ <TabsLineContent value="basics">+ <div className="text-sm text-zinc-600">Basics panel</div>+ </TabsLineContent>+ <TabsLineContent value="work">+ <div className="text-sm text-zinc-600">Work panel</div>+ </TabsLineContent>+ <TabsLineContent value="schedules">+ <div className="text-sm text-zinc-600">Schedules panel</div>+ </TabsLineContent>+ <TabsLineContent value="skills">+ <div className="text-sm text-zinc-600">Skills panel</div>+ </TabsLineContent>+ </TabsLine>+ </div>+ );+}++export const Compact: Story = {+ render: () => <CompactDemo />,+ parameters: {+ docs: {+ description: {+ story:+ '`variant="compact"` is the dense neutral style used on Team pages: flush, zinc underline, 14px triggers. Pass `icon` on a trigger for a 14px Hugeicon.',+ },+ },+ },+};diff --git a/autogpt_platform/frontend/src/components/molecules/TabsLine/TabsLine.tsx b/autogpt_platform/frontend/src/components/molecules/TabsLine/TabsLine.tsxindex 8354009009..a6fa2b073f 100644--- a/autogpt_platform/frontend/src/components/molecules/TabsLine/TabsLine.tsx+++ b/autogpt_platform/frontend/src/components/molecules/TabsLine/TabsLine.tsx@@ -1,10 +1,15 @@"use client";+import { Icon } from "@/components/atoms/Icon/Icon";import { cn } from "@/lib/utils";+import type { IconSvgElement } from "@hugeicons/react";import * as TabsPrimitive from "@radix-ui/react-tabs";import * as React from "react";+type TabsLineVariant = "default" | "compact";+interface TabsLineContextValue {+ variant: TabsLineVariant;activeTabElement: HTMLElement | null;setActiveTabElement: React.Dispatch<React.SetStateAction<HTMLElement | null>>;}@@ -21,14 +26,23 @@ function useTabsLine() {return context;}-function TabsLine(- props: React.ComponentPropsWithoutRef<typeof TabsPrimitive.Root>,-) {+interface TabsLineProps+ extends React.ComponentPropsWithoutRef<typeof TabsPrimitive.Root> {+ /**+ * `compact` is the dense neutral style: flush, zinc underline, 14px+ * triggers with tighter padding. `default` keeps the purple accent.+ */+ variant?: TabsLineVariant;+}++function TabsLine({ variant = "default", ...props }: TabsLineProps) {const [activeTabElement, setActiveTabElement] =React.useState<HTMLElement | null>(null);return (- <TabsLineContext.Provider value={{ activeTabElement, setActiveTabElement }}>+ <TabsLineContext.Provider+ value={{ variant, activeTabElement, setActiveTabElement }}+ ><TabsPrimitive.Root {...props} /></TabsLineContext.Provider>);@@ -51,9 +65,11 @@ interface TabsLineListPropsconst TabsLineList = React.forwardRef<React.ElementRef<typeof TabsPrimitive.List>,TabsLineListProps->(({ className, flush = false, indicatorClassName, ...props }, ref) => {- const { activeTabElement } = useTabsLine();+>(({ className, flush, indicatorClassName, ...props }, ref) => {+ const { variant, activeTabElement } = useTabsLine();const listRef = React.useRef<HTMLDivElement>(null);+ const isCompact = variant === "compact";+ const isFlush = flush ?? isCompact;return (<div className="relative">@@ -67,7 +83,7 @@ const TabsLineList = React.forwardRef<}}className={cn("inline-flex w-full items-center justify-start border-b border-zinc-100",- flush && "[&>button:first-child]:!pl-0",+ isFlush && "[&>button:first-child]:!pl-0",className,)}{...props}@@ -76,6 +92,7 @@ const TabsLineList = React.forwardRef<<divclassName={cn("transition-left transition-right absolute bottom-0 h-0.5 bg-purple-600 duration-200 ease-in-out",+ isCompact && "bg-zinc-900",indicatorClassName,)}style={{@@ -90,12 +107,18 @@ const TabsLineList = React.forwardRef<});TabsLineList.displayName = "TabsLineList";+interface TabsLineTriggerProps+ extends React.ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger> {+ /** Hugeicon shown before the label at 14px. */+ icon?: IconSvgElement;+}+const TabsLineTrigger = React.forwardRef<React.ElementRef<typeof TabsPrimitive.Trigger>,- React.ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger>->(({ className, ...props }, ref) => {+ TabsLineTriggerProps+>(({ className, icon, children, ...props }, ref) => {const elementRef = React.useRef<HTMLButtonElement>(null);- const { setActiveTabElement } = useTabsLine();+ const { variant, setActiveTabElement } = useTabsLine();React.useEffect(() => {if (!elementRef.current) return;@@ -128,10 +151,16 @@ const TabsLineTrigger = React.forwardRef<}}className={cn("relative inline-flex items-center justify-center whitespace-nowrap px-3 py-3 font-sans text-[0.875rem] font-medium leading-[1.5rem] text-zinc-700 transition-all data-[state=active]:text-purple-600 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-neutral-400 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",+ icon && "gap-1.5",+ variant === "compact" &&+ "px-2.5 py-2 text-sm leading-5 text-zinc-600 data-[state=active]:text-zinc-900",className,)}{...props}- />+ >+ {icon ? <Icon icon={icon} size={14} aria-hidden /> : null}+ {children}+ </TabsPrimitive.Trigger>);});TabsLineTrigger.displayName = "TabsLineTrigger";