Skip to content

Commit 6736589

Browse files
authored
fix: agent name in UI (#44)
* refactor: remove unused `DecisionBar` * fix: coding agent name in UI
1 parent 0926837 commit 6736589

2 files changed

Lines changed: 13 additions & 138 deletions

File tree

packages/editor/App.tsx

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -543,6 +543,12 @@ const App: React.FC = () => {
543543

544544
const diffOutput = useMemo(() => exportDiff(blocks, annotations, globalAttachments), [blocks, annotations, globalAttachments]);
545545

546+
const agentName = useMemo(() => {
547+
if (origin === 'opencode') return 'OpenCode';
548+
if (origin === 'claude-code') return 'Claude Code';
549+
return 'Coding Agent';
550+
}, [origin]);
551+
546552
return (
547553
<ThemeProvider defaultTheme="dark">
548554
<div className="h-screen flex flex-col bg-background overflow-hidden">
@@ -573,7 +579,7 @@ const App: React.FC = () => {
573579
? 'bg-orange-500/15 text-orange-400'
574580
: 'bg-zinc-500/20 text-zinc-400'
575581
}`}>
576-
{origin === 'claude-code' ? 'Claude Code' : 'OpenCode'}
582+
{agentName}
577583
</span>
578584
)}
579585
</div>
@@ -629,7 +635,7 @@ const App: React.FC = () => {
629635
<div className="absolute top-full right-0 mt-2 px-3 py-2 bg-popover border border-border rounded-lg shadow-xl text-xs text-foreground w-56 text-center opacity-0 invisible group-hover/approve:opacity-100 group-hover/approve:visible transition-all pointer-events-none z-50">
630636
<div className="absolute bottom-full right-4 border-4 border-transparent border-b-border" />
631637
<div className="absolute bottom-full right-4 mt-px border-4 border-transparent border-b-popover" />
632-
Claude Code doesn't support feedback on approval. Your annotations won't be seen.
638+
{agentName} doesn't support feedback on approval. Your annotations won't be seen.
633639
</div>
634640
)}
635641
</div>
@@ -723,7 +729,7 @@ const App: React.FC = () => {
723729
isOpen={showFeedbackPrompt}
724730
onClose={() => setShowFeedbackPrompt(false)}
725731
title="Add Annotations First"
726-
message="To provide feedback, select text in the plan and add annotations. Claude will use your annotations to revise the plan."
732+
message={`To provide feedback, select text in the plan and add annotations. ${agentName} will use your annotations to revise the plan.`}
727733
variant="info"
728734
/>
729735

@@ -736,7 +742,7 @@ const App: React.FC = () => {
736742
handleApprove();
737743
}}
738744
title="Annotations Won't Be Sent"
739-
message={<>Claude Code doesn't yet support feedback on approval. Your {annotations.length} annotation{annotations.length !== 1 ? 's' : ''} will be lost.</>}
745+
message={<>{agentName} doesn't yet support feedback on approval. Your {annotations.length} annotation{annotations.length !== 1 ? 's' : ''} will be lost.</>}
740746
subMessage={
741747
<>
742748
To send feedback, use <strong>Deny with Feedback</strong> instead.
@@ -780,14 +786,14 @@ const App: React.FC = () => {
780786
</h2>
781787
<p className="text-muted-foreground">
782788
{submitted === 'approved'
783-
? 'Claude will proceed with the implementation.'
784-
: 'Claude will revise the plan based on your annotations.'}
789+
? `${agentName} will proceed with the implementation.`
790+
: `${agentName} will revise the plan based on your annotations.`}
785791
</p>
786792
</div>
787793

788794
<div className="pt-4 border-t border-border">
789795
<p className="text-sm text-muted-foreground">
790-
Return to your <span className="text-foreground font-medium">Claude Code terminal</span> to continue.
796+
Return to your <span className="text-foreground font-medium">{agentName}</span> to continue.
791797
</p>
792798
</div>
793799
</div>

packages/ui/components/DecisionBar.tsx

Lines changed: 0 additions & 131 deletions
This file was deleted.

0 commit comments

Comments
 (0)