@shepai/cli 1.50.0 → 1.51.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/apis/json-schema/AgentType.yaml +1 -0
- package/dist/packages/core/src/application/ports/output/services/git-pr-service.interface.d.ts +11 -0
- package/dist/packages/core/src/application/ports/output/services/git-pr-service.interface.d.ts.map +1 -1
- package/dist/packages/core/src/application/use-cases/agents/configure-agent.use-case.d.ts.map +1 -1
- package/dist/packages/core/src/application/use-cases/agents/configure-agent.use-case.js +6 -4
- package/dist/packages/core/src/domain/generated/output.d.ts +2 -1
- package/dist/packages/core/src/domain/generated/output.d.ts.map +1 -1
- package/dist/packages/core/src/domain/generated/output.js +1 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/agent-executor-factory.service.d.ts.map +1 -1
- package/dist/packages/core/src/infrastructure/services/agents/common/agent-executor-factory.service.js +10 -1
- package/dist/packages/core/src/infrastructure/services/agents/common/agent-validator.service.d.ts.map +1 -1
- package/dist/packages/core/src/infrastructure/services/agents/common/agent-validator.service.js +3 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/dev-executor.service.d.ts +12 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/dev-executor.service.d.ts.map +1 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/dev-executor.service.js +128 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/plan.fixture.d.ts +8 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/plan.fixture.d.ts.map +1 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/plan.fixture.js +94 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/research.fixture.d.ts +8 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/research.fixture.d.ts.map +1 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/research.fixture.js +140 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/spec-analyze.fixture.d.ts +8 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/spec-analyze.fixture.d.ts.map +1 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/spec-analyze.fixture.js +81 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/spec-requirements.fixture.d.ts +8 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/spec-requirements.fixture.d.ts.map +1 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/spec-requirements.fixture.js +131 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/tasks.fixture.d.ts +6 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/tasks.fixture.d.ts.map +1 -0
- package/dist/packages/core/src/infrastructure/services/agents/common/executors/fixtures/tasks.fixture.js +146 -0
- package/dist/packages/core/src/infrastructure/services/agents/feature-agent/feature-agent-worker.d.ts.map +1 -1
- package/dist/packages/core/src/infrastructure/services/agents/feature-agent/feature-agent-worker.js +1 -0
- package/dist/packages/core/src/infrastructure/services/agents/feature-agent/nodes/merge.node.d.ts +5 -0
- package/dist/packages/core/src/infrastructure/services/agents/feature-agent/nodes/merge.node.d.ts.map +1 -1
- package/dist/packages/core/src/infrastructure/services/agents/feature-agent/nodes/merge.node.js +16 -4
- package/dist/packages/core/src/infrastructure/services/agents/feature-agent/nodes/prompts/merge-prompts.d.ts +1 -1
- package/dist/packages/core/src/infrastructure/services/agents/feature-agent/nodes/prompts/merge-prompts.d.ts.map +1 -1
- package/dist/packages/core/src/infrastructure/services/agents/feature-agent/nodes/prompts/merge-prompts.js +3 -2
- package/dist/packages/core/src/infrastructure/services/git/git-pr.service.d.ts +1 -0
- package/dist/packages/core/src/infrastructure/services/git/git-pr.service.d.ts.map +1 -1
- package/dist/packages/core/src/infrastructure/services/git/git-pr.service.js +11 -0
- package/dist/src/presentation/cli/commands/settings/agent.command.js +3 -3
- package/dist/src/presentation/tui/prompts/agent-select.prompt.d.ts +8 -4
- package/dist/src/presentation/tui/prompts/agent-select.prompt.d.ts.map +1 -1
- package/dist/src/presentation/tui/prompts/agent-select.prompt.js +10 -5
- package/dist/src/presentation/web/components/common/feature-node/agent-type-icons.d.ts +1 -1
- package/dist/src/presentation/web/components/common/feature-node/agent-type-icons.d.ts.map +1 -1
- package/dist/src/presentation/web/components/common/feature-node/agent-type-icons.js +6 -0
- package/dist/src/presentation/web/components/common/feature-node/agent-type-icons.stories.d.ts +1 -0
- package/dist/src/presentation/web/components/common/feature-node/agent-type-icons.stories.d.ts.map +1 -1
- package/dist/src/presentation/web/components/common/feature-node/agent-type-icons.stories.js +7 -0
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/web/.next/BUILD_ID +1 -1
- package/web/.next/build-manifest.json +2 -2
- package/web/.next/cache/.previewinfo +1 -1
- package/web/.next/cache/.rscinfo +1 -1
- package/web/.next/cache/.tsbuildinfo +1 -1
- package/web/.next/cache/config.json +3 -3
- package/web/.next/fallback-build-manifest.json +2 -2
- package/web/.next/prerender-manifest.json +3 -3
- package/web/.next/required-server-files.js +1 -1
- package/web/.next/required-server-files.json +1 -1
- package/web/.next/server/app/_global-error.html +2 -2
- package/web/.next/server/app/_global-error.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/web/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/page/server-reference-manifest.json +14 -14
- package/web/.next/server/app/page_client-reference-manifest.js +1 -1
- package/web/.next/server/app/version/page_client-reference-manifest.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__03a0dba7._.js +4 -4
- package/web/.next/server/chunks/ssr/[root-of-the-server]__03a0dba7._.js.map +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__249c74f6._.js +1 -1
- package/web/.next/server/chunks/ssr/[root-of-the-server]__2d1a8e37._.js +2 -2
- package/web/.next/server/chunks/ssr/_1fafa9db._.js +1 -1
- package/web/.next/server/chunks/ssr/_1fafa9db._.js.map +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_ed0934e5._.js +1 -1
- package/web/.next/server/chunks/ssr/src_presentation_web_ed0934e5._.js.map +1 -1
- package/web/.next/server/pages/500.html +2 -2
- package/web/.next/server/server-reference-manifest.js +1 -1
- package/web/.next/server/server-reference-manifest.json +15 -15
- package/web/.next/standalone/src/presentation/web/.next/BUILD_ID +1 -1
- package/web/.next/standalone/src/presentation/web/.next/build-manifest.json +2 -2
- package/web/.next/standalone/src/presentation/web/.next/prerender-manifest.json +3 -3
- package/web/.next/standalone/src/presentation/web/.next/required-server-files.json +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/app/_global-error.html +2 -2
- package/web/.next/standalone/src/presentation/web/.next/server/app/_global-error.rsc +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/app/page/server-reference-manifest.json +14 -14
- package/web/.next/standalone/src/presentation/web/.next/server/app/page_client-reference-manifest.js +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/app/version/page_client-reference-manifest.js +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/chunks/ssr/[root-of-the-server]__03a0dba7._.js +4 -4
- package/web/.next/standalone/src/presentation/web/.next/server/chunks/ssr/[root-of-the-server]__249c74f6._.js +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/chunks/ssr/[root-of-the-server]__2d1a8e37._.js +2 -2
- package/web/.next/standalone/src/presentation/web/.next/server/chunks/ssr/_1fafa9db._.js +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/chunks/ssr/src_presentation_web_ed0934e5._.js +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/pages/500.html +2 -2
- package/web/.next/standalone/src/presentation/web/.next/server/server-reference-manifest.js +1 -1
- package/web/.next/standalone/src/presentation/web/.next/server/server-reference-manifest.json +15 -15
- package/web/.next/standalone/src/presentation/web/components/common/feature-node/agent-type-icons.stories.tsx +16 -0
- package/web/.next/standalone/src/presentation/web/components/common/feature-node/agent-type-icons.tsx +8 -1
- package/web/.next/standalone/src/presentation/web/server.js +1 -1
- package/web/.next/static/chunks/{86340848468ecffa.js → 52930750dd593d0c.js} +4 -4
- package/web/.next/static/chunks/{0da7a9860fa6ae05.js → f9953dad6d0c239c.js} +1 -1
- package/web/.next/trace +1 -1
- package/web/.next/trace-build +1 -1
- /package/web/.next/static/{Hbv-BqJZOvcXHMnbSKEtM → xkINn0kUHKOhvEvbvlh-B}/_buildManifest.js +0 -0
- /package/web/.next/static/{Hbv-BqJZOvcXHMnbSKEtM → xkINn0kUHKOhvEvbvlh-B}/_clientMiddlewareManifest.json +0 -0
- /package/web/.next/static/{Hbv-BqJZOvcXHMnbSKEtM → xkINn0kUHKOhvEvbvlh-B}/_ssgManifest.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"merge-prompts.d.ts","sourceRoot":"","sources":["../../../../../../../../../../packages/core/src/infrastructure/services/agents/feature-agent/nodes/prompts/merge-prompts.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAqCxD;;;;;GAKG;AACH,wBAAgB,uBAAuB,CACrC,KAAK,EAAE,iBAAiB,EACxB,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,MAAM,GACjB,MAAM,CAyDR;AAED;;;;;;GAMG;AACH,wBAAgB,sBAAsB,CACpC,KAAK,EAAE,iBAAiB,EACxB,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"merge-prompts.d.ts","sourceRoot":"","sources":["../../../../../../../../../../packages/core/src/infrastructure/services/agents/feature-agent/nodes/prompts/merge-prompts.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAqCxD;;;;;GAKG;AACH,wBAAgB,uBAAuB,CACrC,KAAK,EAAE,iBAAiB,EACxB,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,MAAM,GACjB,MAAM,CAyDR;AAED;;;;;;GAMG;AACH,wBAAgB,sBAAsB,CACpC,KAAK,EAAE,iBAAiB,EACxB,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,MAAM,EAClB,SAAS,UAAQ,GAChB,MAAM,CAkER"}
|
|
@@ -104,7 +104,7 @@ ${steps.join('\n')}
|
|
|
104
104
|
* When no PR exists, performs a local merge in the ORIGINAL repo directory
|
|
105
105
|
* (not the worktree, which IS the feature branch).
|
|
106
106
|
*/
|
|
107
|
-
export function buildMergeSquashPrompt(state, branch, baseBranch) {
|
|
107
|
+
export function buildMergeSquashPrompt(state, branch, baseBranch, hasRemote = false) {
|
|
108
108
|
if (state.prUrl && state.prNumber) {
|
|
109
109
|
// PR path: remote merge via GitHub CLI — no local merge needed
|
|
110
110
|
return `You are merging a pull request via the GitHub CLI.
|
|
@@ -127,7 +127,6 @@ export function buildMergeSquashPrompt(state, branch, baseBranch) {
|
|
|
127
127
|
}
|
|
128
128
|
// Non-PR path: local merge in the ORIGINAL repo (not the worktree)
|
|
129
129
|
const originalRepo = state.repositoryPath;
|
|
130
|
-
const hasRemote = state.push || state.openPr;
|
|
131
130
|
const fetchSteps = hasRemote
|
|
132
131
|
? `2. Fetch latest: \`git fetch origin\`
|
|
133
132
|
3. Checkout the base branch: \`git checkout ${baseBranch}\`
|
|
@@ -163,6 +162,8 @@ ${fetchSteps}
|
|
|
163
162
|
|
|
164
163
|
- Use squash merge strategy to keep history clean
|
|
165
164
|
- All commands MUST run in \`${originalRepo}\` (the original repo), NOT in the worktree
|
|
165
|
+
- NEVER remove, modify, or prune git worktrees — they are managed by the system
|
|
166
|
+
- Do NOT try to \`git checkout\` the feature branch — \`git merge --squash\` reads from it without checking it out
|
|
166
167
|
- If conflicts arise during merge, attempt to resolve them intelligently
|
|
167
168
|
- Do NOT modify any source code beyond what is needed for conflict resolution
|
|
168
169
|
- Report the merge result clearly`;
|
|
@@ -22,6 +22,7 @@ export declare class GitPrService implements IGitPrService {
|
|
|
22
22
|
watchCi(cwd: string, branch: string, timeoutMs?: number): Promise<CiStatusResult>;
|
|
23
23
|
deleteBranch(cwd: string, branch: string, deleteRemote?: boolean): Promise<void>;
|
|
24
24
|
getPrDiffSummary(cwd: string, baseBranch: string): Promise<DiffSummary>;
|
|
25
|
+
verifyMerge(cwd: string, featureBranch: string, baseBranch: string): Promise<boolean>;
|
|
25
26
|
private parseGitError;
|
|
26
27
|
private parseGhError;
|
|
27
28
|
private parsePrNumberFromUrl;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"git-pr.service.d.ts","sourceRoot":"","sources":["../../../../../../../packages/core/src/infrastructure/services/git/git-pr.service.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wEAAwE,CAAC;AAC5G,OAAO,KAAK,EACV,cAAc,EACd,WAAW,EACX,aAAa,EACb,cAAc,EACf,MAAM,wEAAwE,CAAC;AAOhF,OAAO,KAAK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AAO,CAAC,IAAI,CAAC;IAUnF,WAAW,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,cAAc,CAAC;IAkBjE,OAAO,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,cAAc,CAAC;IAuBjF,YAAY,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,YAAY,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC;IAWhF,gBAAgB,CAAC,GAAG,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC;IAevE,WAAW,CAAC,GAAG,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;IAW3F,OAAO,CAAC,aAAa;IAcrB,OAAO,CAAC,YAAY;IAepB,OAAO,CAAC,oBAAoB;IAK5B,OAAO,CAAC,aAAa;CAiBtB"}
|
|
@@ -191,6 +191,17 @@ let GitPrService = class GitPrService {
|
|
|
191
191
|
const { stdout: logOutput } = await this.execFile('git', ['log', '--oneline', `${baseBranch}...HEAD`], { cwd });
|
|
192
192
|
return this.parseDiffStat(diffStat, logOutput);
|
|
193
193
|
}
|
|
194
|
+
async verifyMerge(cwd, featureBranch, baseBranch) {
|
|
195
|
+
try {
|
|
196
|
+
await this.execFile('git', ['merge-base', '--is-ancestor', featureBranch, baseBranch], {
|
|
197
|
+
cwd,
|
|
198
|
+
});
|
|
199
|
+
return true;
|
|
200
|
+
}
|
|
201
|
+
catch {
|
|
202
|
+
return false;
|
|
203
|
+
}
|
|
204
|
+
}
|
|
194
205
|
parseGitError(error) {
|
|
195
206
|
const message = error instanceof Error ? error.message : String(error);
|
|
196
207
|
const cause = error instanceof Error ? error : undefined;
|
|
@@ -33,15 +33,15 @@ Examples:
|
|
|
33
33
|
const isNonInteractive = options.agent !== undefined;
|
|
34
34
|
let input;
|
|
35
35
|
if (isNonInteractive) {
|
|
36
|
-
// Non-interactive: require --auth when --agent is provided
|
|
37
|
-
if (!options.auth) {
|
|
36
|
+
// Non-interactive: require --auth when --agent is provided (dev type defaults to session)
|
|
37
|
+
if (!options.auth && options.agent !== 'dev') {
|
|
38
38
|
messages.error('--auth is required when using --agent flag');
|
|
39
39
|
process.exitCode = 1;
|
|
40
40
|
return;
|
|
41
41
|
}
|
|
42
42
|
input = {
|
|
43
43
|
type: options.agent,
|
|
44
|
-
authMethod: options.auth,
|
|
44
|
+
authMethod: options.auth ?? 'session',
|
|
45
45
|
...(options.token !== undefined && { token: options.token }),
|
|
46
46
|
};
|
|
47
47
|
}
|
|
@@ -21,6 +21,14 @@ export declare function createAgentSelectConfig(): {
|
|
|
21
21
|
readonly name: "Gemini CLI";
|
|
22
22
|
readonly value: AgentType.GeminiCli;
|
|
23
23
|
readonly description: "Google Gemini CLI";
|
|
24
|
+
}, {
|
|
25
|
+
readonly name: "Cursor";
|
|
26
|
+
readonly value: AgentType.Cursor;
|
|
27
|
+
readonly description: "Cursor AI coding agent";
|
|
28
|
+
}, {
|
|
29
|
+
readonly name: "Dev (Mock)";
|
|
30
|
+
readonly value: AgentType.Dev;
|
|
31
|
+
readonly description: "Local development mock — no agent binary required";
|
|
24
32
|
}, {
|
|
25
33
|
readonly name: "Aider";
|
|
26
34
|
readonly value: AgentType.Aider;
|
|
@@ -29,10 +37,6 @@ export declare function createAgentSelectConfig(): {
|
|
|
29
37
|
readonly name: "Continue";
|
|
30
38
|
readonly value: AgentType.Continue;
|
|
31
39
|
readonly disabled: "(Coming Soon)";
|
|
32
|
-
}, {
|
|
33
|
-
readonly name: "Cursor";
|
|
34
|
-
readonly value: AgentType.Cursor;
|
|
35
|
-
readonly description: "Cursor AI coding agent";
|
|
36
40
|
}];
|
|
37
41
|
readonly theme: {
|
|
38
42
|
readonly prefix: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-select.prompt.d.ts","sourceRoot":"","sources":["../../../../../src/presentation/tui/prompts/agent-select.prompt.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAGzD;;;;;GAKG;AACH,wBAAgB,uBAAuB
|
|
1
|
+
{"version":3,"file":"agent-select.prompt.d.ts","sourceRoot":"","sources":["../../../../../src/presentation/tui/prompts/agent-select.prompt.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAGzD;;;;;GAKG;AACH,wBAAgB,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAqCtC"}
|
|
@@ -26,6 +26,16 @@ export function createAgentSelectConfig() {
|
|
|
26
26
|
value: AgentType.GeminiCli,
|
|
27
27
|
description: 'Google Gemini CLI',
|
|
28
28
|
},
|
|
29
|
+
{
|
|
30
|
+
name: 'Cursor',
|
|
31
|
+
value: AgentType.Cursor,
|
|
32
|
+
description: 'Cursor AI coding agent',
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
name: 'Dev (Mock)',
|
|
36
|
+
value: AgentType.Dev,
|
|
37
|
+
description: 'Local development mock — no agent binary required',
|
|
38
|
+
},
|
|
29
39
|
{
|
|
30
40
|
name: 'Aider',
|
|
31
41
|
value: AgentType.Aider,
|
|
@@ -36,11 +46,6 @@ export function createAgentSelectConfig() {
|
|
|
36
46
|
value: AgentType.Continue,
|
|
37
47
|
disabled: '(Coming Soon)',
|
|
38
48
|
},
|
|
39
|
-
{
|
|
40
|
-
name: 'Cursor',
|
|
41
|
-
value: AgentType.Cursor,
|
|
42
|
-
description: 'Cursor AI coding agent',
|
|
43
|
-
},
|
|
44
49
|
],
|
|
45
50
|
theme: shepTheme,
|
|
46
51
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ComponentType, SVGProps } from 'react';
|
|
2
2
|
/** Agent type values mirroring the TypeSpec AgentType enum. */
|
|
3
|
-
export type AgentTypeValue = 'claude-code' | 'cursor' | 'gemini-cli' | 'aider' | 'continue';
|
|
3
|
+
export type AgentTypeValue = 'claude-code' | 'cursor' | 'gemini-cli' | 'aider' | 'continue' | 'dev';
|
|
4
4
|
type IconProps = SVGProps<SVGSVGElement> & {
|
|
5
5
|
className?: string;
|
|
6
6
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-type-icons.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/common/feature-node/agent-type-icons.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"agent-type-icons.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/common/feature-node/agent-type-icons.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAKrD,+DAA+D;AAC/D,MAAM,MAAM,cAAc,GAAG,aAAa,GAAG,QAAQ,GAAG,YAAY,GAAG,OAAO,GAAG,UAAU,GAAG,KAAK,CAAC;AAEpG,KAAK,SAAS,GAAG,QAAQ,CAAC,aAAa,CAAC,GAAG;IAAE,SAAS,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAmBlE,6DAA6D;AAC7D,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,SAAS,2CAOhD;AAgBD,wEAAwE;AACxE,wBAAgB,gBAAgB,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,aAAa,CAAC,SAAS,CAAC,CAK7E"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import Image from 'next/image';
|
|
3
|
+
import { Beaker } from 'lucide-react';
|
|
3
4
|
import { cn } from '../../../lib/utils.js';
|
|
4
5
|
/** Create a stable image-based icon component for a brand. */
|
|
5
6
|
function createBrandIcon(src, alt) {
|
|
@@ -13,12 +14,17 @@ function createBrandIcon(src, alt) {
|
|
|
13
14
|
export function DefaultAgentIcon(props) {
|
|
14
15
|
return (_jsxs("svg", { viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props, children: [_jsx("circle", { cx: "12", cy: "12", r: "9", stroke: "currentColor", strokeWidth: "2" }), _jsx("circle", { cx: "12", cy: "12", r: "3", fill: "currentColor" })] }));
|
|
15
16
|
}
|
|
17
|
+
function DevAgentIcon({ className, ...props }) {
|
|
18
|
+
return _jsx(Beaker, { className: cn('h-6 w-6', className), ...props });
|
|
19
|
+
}
|
|
20
|
+
DevAgentIcon.displayName = 'DevAgentIcon';
|
|
16
21
|
const agentTypeIconMap = {
|
|
17
22
|
'claude-code': createBrandIcon('/icons/agents/claude-ai-icon.svg', 'Claude Code'),
|
|
18
23
|
cursor: createBrandIcon('/icons/agents/cursor.jpeg', 'Cursor'),
|
|
19
24
|
'gemini-cli': createBrandIcon('/icons/agents/gemini-cli.jpeg', 'Gemini CLI'),
|
|
20
25
|
aider: createBrandIcon('/icons/agents/aider.png', 'Aider'),
|
|
21
26
|
continue: createBrandIcon('/icons/agents/continue.jpeg', 'Continue'),
|
|
27
|
+
dev: DevAgentIcon,
|
|
22
28
|
};
|
|
23
29
|
/** Resolve an agent type string to its corresponding icon component. */
|
|
24
30
|
export function getAgentTypeIcon(agentType) {
|
package/dist/src/presentation/web/components/common/feature-node/agent-type-icons.stories.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-type-icons.stories.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/common/feature-node/agent-type-icons.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"agent-type-icons.stories.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/common/feature-node/agent-type-icons.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAyCvD,QAAA,MAAM,IAAI,EAAE,IAIX,CAAC;AAEF,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC;AAEtB,eAAO,MAAM,QAAQ,EAAE,KAEtB,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,KAExB,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,KAExB,CAAC;AAEF,eAAO,MAAM,YAAY,EAAE,KAa1B,CAAC"}
|
package/dist/src/presentation/web/components/common/feature-node/agent-type-icons.stories.js
CHANGED
|
@@ -6,6 +6,7 @@ const allAgentTypes = [
|
|
|
6
6
|
{ type: 'gemini-cli', label: 'Gemini CLI' },
|
|
7
7
|
{ type: 'aider', label: 'Aider' },
|
|
8
8
|
{ type: 'continue', label: 'Continue' },
|
|
9
|
+
{ type: 'dev', label: 'Dev (Mock)' },
|
|
9
10
|
];
|
|
10
11
|
function AgentIconGallery({ size }) {
|
|
11
12
|
return (_jsxs("div", { className: "flex flex-wrap gap-6", children: [allAgentTypes.map(({ type, label }) => {
|
|
@@ -28,3 +29,9 @@ export const SmallIcons = {
|
|
|
28
29
|
export const LargeIcons = {
|
|
29
30
|
render: () => _jsx(AgentIconGallery, { size: 16 }),
|
|
30
31
|
};
|
|
32
|
+
export const DevAgentIcon = {
|
|
33
|
+
render: () => {
|
|
34
|
+
const Icon = getAgentTypeIcon('dev');
|
|
35
|
+
return (_jsxs("div", { className: "flex flex-col items-center gap-2", children: [_jsx("div", { className: "border-border bg-muted/30 rounded-md border p-3", children: _jsx(Icon, { style: { width: 40, height: 40 } }) }), _jsx("span", { className: "text-sm font-medium", children: "Dev (Mock)" }), _jsx("code", { className: "text-muted-foreground text-xs", children: "dev" })] }));
|
|
36
|
+
},
|
|
37
|
+
};
|