Local UI to run and train LLMs and diffusion models. Supports GGUF, MLX, Qwen3.8, DeepSeek-V4.1, MiniMax-H3, Gemma 4, FLUX and more.
Python agentaichatgptdeepseekfine-tuninggemmaimage-generationllamallmllmsopenaipythonqwenreinforcement-learningself-hostedstable-diffusiontext-to-speechttsuiunsloth
Studio: show the close button in the mobile sidebar (#12806)
Michael Han74f70316f634
diff --git a/studio/frontend/src/components/app-sidebar.tsx b/studio/frontend/src/components/app-sidebar.tsxindex 200befa1f0e..383abea250d 100644--- a/studio/frontend/src/components/app-sidebar.tsx+++ b/studio/frontend/src/components/app-sidebar.tsx@@ -5298,12 +5298,13 @@ export function AppSidebar() {)}</TooltipContent></Tooltip>- {!isMobile && !usesDesktopTitlebar && (+ {/* On narrow screens this closes the sidebar sheet. */}+ {(isMobile || !usesDesktopTitlebar) && (<Tooltip><TooltipPrimitive.Trigger asChild><buttontype="button"- onClick={togglePinned}+ onClick={isMobile ? () => setOpenMobile(false) : togglePinned}className="inline-flex size-[calc(30px*var(--ui-space-scale,1))] cursor-pointer items-center justify-center rounded-[10px] text-nav-icon-idle dark:text-nav-fg-muted transition-colors hover:bg-nav-surface-hover hover:text-black dark:hover:text-white focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring"aria-label={t("shell.aria.closeSidebar")}>@@ -5314,6 +5315,7 @@ export function AppSidebar() {side="bottom"sideOffset={6}className="tooltip-compact"+ hidden={isMobile}>{t("shell.aria.closeSidebar")}</TooltipContent>diff --git a/studio/frontend/tests/sidebar-width.test.ts b/studio/frontend/tests/sidebar-width.test.tsindex f2263a26ffe..d86aaf99e1c 100644--- a/studio/frontend/tests/sidebar-width.test.ts+++ b/studio/frontend/tests/sidebar-width.test.ts@@ -40,9 +40,9 @@ test("the web keeps room for the collapse button beside search; desktop does notsource,/SIDEBAR_WIDTH_MIN = isTauri\s*\?\s*SIDEBAR_WIDTH_MIN_DESKTOP\s*:\s*SIDEBAR_WIDTH_MIN_WEB;/,);- // The header only draws that button off the desktop titlebar.+ // Off the desktop titlebar, or always in the mobile sheet.const sidebar = await readSrcAsync("components/app-sidebar.tsx");- assert.match(sidebar, /\{!isMobile && !usesDesktopTitlebar && \(/);+ assert.match(sidebar, /\{\(isMobile \|\| !usesDesktopTitlebar\) && \(/);});test("clamps to the absolute range on a roomy window", () => {