Files
AutoMetabuilder/frontend/autometabuilder/components/layout/Sidebar.tsx
johndoe6345789 22c9306347 Introduce AutoMetabuilder core components and workflow packages:
- Implement core components: CLI argument parsing, environment loading, GitHub service creation, and logging configuration.
- Add support for OpenAI client setup and model resolution.
- Develop SDLC context loader from GitHub and repository files.
- Implement workflow context and engine builders.
- Introduce major workflow packages: `game_tick_loop` and `contextual_iterative_loop`.
- Update localization files with new package descriptions and labels.
- Streamline web navigation by loading items from a dedicated JSON file.
2026-01-10 01:08:34 +00:00

32 lines
884 B
TypeScript

import { NavigationItem } from "../../lib/types";
type SidebarProps = {
items: NavigationItem[];
selected: string;
onSelect: (section: string) => void;
t: (key: string, fallback?: string) => string;
};
export default function Sidebar({ items, selected, onSelect, t }: SidebarProps) {
return (
<aside className="sidebar">
<div className="sidebar__brand">
<span>{t("ui.app.name", "AutoMetabuilder")}</span>
</div>
<nav>
{items.map((item) => (
<button
key={item.section}
type="button"
className={`sidebar__item ${selected === item.section ? "active" : ""}`}
onClick={() => onSelect(item.section)}
data-section={item.section}
>
<span>{t(item.label_key, item.default_label)}</span>
</button>
))}
</nav>
</aside>
);
}