Skip to content

Commit 56d5a9f

Browse files
aaronbrezelclaude
andauthored
feat: client panel-router architecture with component-based sidebar (#26)
* refactor: derive SavedState from RunConfig to eliminate field duplication Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * reordering menu buttons --------- Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent d5d28a2 commit 56d5a9f

2 files changed

Lines changed: 6 additions & 12 deletions

File tree

src/client/panels/configure-ai-run.ts

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,7 @@ import { SingleTagList } from "../components/single-tag-list";
55
import { RowRange } from "../components/row-range";
66
import { getSheetHeaders, runBatchAI } from "../services";
77

8-
export interface SavedState {
9-
userPromptCols: string[];
10-
driveFileCols: string[];
11-
systemPromptCol: string;
12-
outputCol: string;
13-
rowRange?: { start: number; end: number };
14-
}
8+
export type SavedState = Required<Omit<RunConfig, "rowRange">> & Pick<RunConfig, "rowRange">;
159

1610
export class ConfigureAIRunPanel implements Panel<Partial<RunConfig>, SavedState> {
1711
private userPromptList: TagList | null = null;

src/client/panels/tool-list.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -60,18 +60,18 @@ export class ToolListPanel implements Panel {
6060
</div>
6161
<div class="section">
6262
<h3>Main Tools</h3>
63-
<button id="btn-import-drive-links" class="tool-btn">
64-
<span class="icon">📂</span> Import Drive Links
63+
<button id="btn-recipes" class="tool-btn">
64+
<span class="icon">🥞</span> Recipes
6565
</button>
6666
<button id="btn-run-ai" class="tool-btn">
6767
<span class="icon">▶️</span> Run AI Inference
6868
</button>
69-
<button id="btn-recipes" class="tool-btn">
70-
<span class="icon">🥞</span> Recipes
71-
</button>
7269
</div>
7370
<div class="section">
7471
<h3>Extras</h3>
72+
<button id="btn-import-drive-links" class="tool-btn">
73+
<span class="icon">📂</span> Import Drive Links
74+
</button>
7575
<button id="btn-sample-rows" class="tool-btn">
7676
<span class="icon">🎲</span> Sample Rows
7777
</button>

0 commit comments

Comments
 (0)