Skip to content

Commit 005a147

Browse files
authored
Merge pull request #29 from AgentWorkforce/proactive-agents
proactive agents update
2 parents 3e132b5 + 0c2dc1e commit 005a147

23 files changed

Lines changed: 696 additions & 233 deletions

‎web/app/agents/AgentsGallery.tsx‎

Lines changed: 38 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ import Link from 'next/link';
44
import { Box, Database, Zap } from 'lucide-react';
55

66
import { FadeIn } from '../../components/FadeIn';
7-
import { AgentArt } from '../../components/agents/AgentArt';
87
import { BuildYourOwn } from '../../components/agents/BuildYourOwn';
9-
import { AGENTS, INTEGRATION_LABELS } from '../../lib/agents';
8+
import { IntegrationLogos } from '../../components/agents/IntegrationLogos';
9+
import { AGENTS } from '../../lib/agents';
1010
import s from './agents.module.css';
1111

1212
const CAPABILITIES = [
@@ -89,31 +89,45 @@ export function AgentsGallery() {
8989
</div>
9090

9191
<div className={s.gallery}>
92-
<div className={s.grid}>
92+
<div className={s.listHead} aria-hidden="true">
93+
<span>Agent</span>
94+
<span>Integrations</span>
95+
</div>
96+
<ul className={s.list}>
9397
{AGENTS.map((agent, i) => (
94-
<FadeIn key={agent.slug} direction="up" delay={(i % 3) * 60} className={s.col}>
95-
<Link href={`/agents/${agent.slug}`} className={s.card}>
96-
<div className={s.cardMedia}>
97-
<AgentArt agent={agent} variant="card-sm" alt={`${agent.name} card`} />
98-
</div>
99-
<div className={s.cardBody}>
100-
<h2 className={s.cardName}>{agent.name}</h2>
101-
<p className={s.cardTagline}>{agent.tagline}</p>
102-
<div className={s.chips}>
103-
{agent.integrations.map((integration) => (
104-
<span key={integration} className={s.chip}>
105-
{INTEGRATION_LABELS[integration]}
98+
<li key={agent.slug} className={s.row}>
99+
<FadeIn direction="up" delay={Math.min(i, 6) * 40}>
100+
<Link href={`/agents/${agent.slug}`} className={s.rowLink}>
101+
<span className={s.rowMain}>
102+
<span className={s.rowName}>{agent.name}</span>
103+
<span className={s.rowTagline}>{agent.tagline}</span>
104+
{/* Its own reserved line, so revealing it on hover/focus
105+
never shifts the row or hides the tagline. */}
106+
<span className={s.rowTrigger}>
107+
<span
108+
className={agent.trigger.kind === 'schedule' ? s.kindSchedule : s.kindEvent}
109+
>
110+
{agent.trigger.kind}
106111
</span>
107-
))}
108-
</div>
109-
<div className={s.cardFooter}>
110-
<span className={s.cardArrow}>View agent →</span>
111-
</div>
112-
</div>
113-
</Link>
114-
</FadeIn>
112+
<span className={s.rowTriggerText}>{agent.trigger.summary}</span>
113+
</span>
114+
</span>
115+
116+
<IntegrationLogos
117+
integrations={agent.integrations}
118+
className={s.rowLogos}
119+
logoClassName={s.rowLogo}
120+
chipClassName={s.chip}
121+
/>
122+
123+
<span className={s.rowArrow} aria-hidden="true">
124+
→
125+
</span>
126+
</Link>
127+
</FadeIn>
128+
</li>
115129
))}
116-
</div>
130+
</ul>
117131
</div>
118132

119133
<BuildYourOwn />

‎web/app/agents/[slug]/AgentDetail.tsx‎

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@ import Link from 'next/link';
55
import { FadeIn } from '../../../components/FadeIn';
66
import { AgentArt } from '../../../components/agents/AgentArt';
77
import { ForkAgentButton } from '../../../components/agents/ForkAgentButton';
8-
import { INTEGRATION_LABELS, sourceUrl, type Agent } from '../../../lib/agents';
8+
import { IntegrationLogos } from '../../../components/agents/IntegrationLogos';
9+
import { sourceUrl, type Agent } from '../../../lib/agents';
910
import s from '../agents.module.css';
1011

1112
export function AgentDetail({ agent }: { agent: Agent }) {
@@ -42,13 +43,13 @@ export function AgentDetail({ agent }: { agent: Agent }) {
4243
</a>
4344
</div>
4445
<p className={s.detailTagline}>{agent.tagline}</p>
45-
<div className={s.chips}>
46-
{agent.integrations.map((integration) => (
47-
<span key={integration} className={s.chip}>
48-
{INTEGRATION_LABELS[integration]}
49-
</span>
50-
))}
51-
</div>
46+
<IntegrationLogos
47+
integrations={agent.integrations}
48+
withLabel
49+
className={s.chips}
50+
chipClassName={s.logoChip}
51+
logoClassName={s.logoChipIcon}
52+
/>
5253
</div>
5354
</FadeIn>
5455

@@ -98,13 +99,13 @@ export function AgentDetail({ agent }: { agent: Agent }) {
9899
</div>
99100
<div className={s.metaRow}>
100101
<span className={s.metaLabel}>Integrations</span>
101-
<div className={s.chips}>
102-
{agent.integrations.map((integration) => (
103-
<span key={integration} className={s.chip}>
104-
{INTEGRATION_LABELS[integration]}
105-
</span>
106-
))}
107-
</div>
102+
<IntegrationLogos
103+
integrations={agent.integrations}
104+
withLabel
105+
className={s.chips}
106+
chipClassName={s.logoChip}
107+
logoClassName={s.logoChipIcon}
108+
/>
108109
</div>
109110
{agent.inputs.length > 0 && (
110111
<div className={s.metaRow}>

0 commit comments

Comments
 (0)