Your lightweight open-source personal agent.
Python agent-frameworkai-agentai-agentschatbotchatopsdiscord-botllm-agentsllmslocal-llmmcpmodel-context-protocolmulti-agentopenai-compatibleopenclawpersonal-ai-assistantpythonself-hostedtelegram-bot-ai-assistantwebuiworkflow-automation
fix(webui): preserve sidebar control alignment
Xubin Ren588be51d8cf9
diff --git a/webui/src/components/Sidebar.tsx b/webui/src/components/Sidebar.tsxindex 01792a4b0..26ac4fa9e 100644--- a/webui/src/components/Sidebar.tsx+++ b/webui/src/components/Sidebar.tsx@@ -165,7 +165,7 @@ export function Sidebar(props: SidebarProps) {size="icon"aria-label={t("sidebar.collapse")}onClick={props.onCollapse}- className="host-no-drag h-7 w-7 rounded-lg text-muted-foreground/85 hover:bg-sidebar-accent/75 hover:text-sidebar-foreground"+ className="host-no-drag mt-1 h-7 w-7 rounded-lg text-muted-foreground/85 hover:bg-sidebar-accent/75 hover:text-sidebar-foreground"><Menu className="h-3.5 w-3.5" /></Button>diff --git a/webui/src/tests/app-layout.test.tsx b/webui/src/tests/app-layout.test.tsxindex 1511f92b8..ab3ea13d8 100644--- a/webui/src/tests/app-layout.test.tsx+++ b/webui/src/tests/app-layout.test.tsx@@ -458,6 +458,7 @@ describe("App layout", () => {expect(main).not.toHaveAttribute("style");expect(screen.getByTestId("sidebar-brand-row")).toHaveClass("pt-3");expect(screen.getByTestId("sidebar-brand-mark")).not.toHaveClass("mt-5");+ expect(screen.getByRole("button", { name: "Collapse sidebar" })).toHaveClass("mt-1");const asideClassNames = Array.from(container.querySelectorAll("aside")).map((el) => el.className,@@ -1642,6 +1643,7 @@ describe("App layout", () => {expect(flowSidebar).toHaveStyle({ width: "272px" });expect(screen.getByTestId("sidebar-brand-row")).toHaveClass("pt-3");expect(screen.getByTestId("sidebar-brand-mark")).toHaveClass("mt-5");+ expect(screen.getByRole("button", { name: "Collapse sidebar" })).toHaveClass("mt-1");expect(screen.queryByTestId("host-sidebar-toggle")).not.toBeInTheDocument();expect(screen.getByRole("navigation", { name: "Sidebar navigation" }),