From 655b0cbcee1d68b22629e3ceeab7f84c7d685af8 Mon Sep 17 00:00:00 2001 From: Michael Han <107991372+shimmyshimmer@users.noreply.github.com> Date: Mon, 22 Jun 2026 20:57:01 -0700 Subject: [PATCH] Studio: default Hub Discover scope to all models (#6593) - Discover defaults to the whole Hub instead of the unsloth org; an explicit Unsloth choice is still remembered - Discover models placeholder reads Search all models to match - Give the Unsloth/All scope pill a min width so it stays readable --- .../frontend/src/features/hub/catalog/models-toolbar.tsx | 2 +- .../src/features/hub/catalog/owner-scope-toggle.tsx | 4 ++-- studio/frontend/src/features/hub/hub-page.tsx | 9 +++++---- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/studio/frontend/src/features/hub/catalog/models-toolbar.tsx b/studio/frontend/src/features/hub/catalog/models-toolbar.tsx index c8adfb54f5..48f7fcffaa 100644 --- a/studio/frontend/src/features/hub/catalog/models-toolbar.tsx +++ b/studio/frontend/src/features/hub/catalog/models-toolbar.tsx @@ -252,7 +252,7 @@ export const ModelsToolbar = memo(function ModelsToolbar({ ? `Search on-device ${isDataset ? "datasets" : "models"}` : isDataset ? "Search datasets" - : "Search models" + : "Search all models" } className={cn( "field-soft h-9 rounded-full !border-0 pl-10 text-[13px] placeholder:text-muted-foreground/80 focus-visible:!ring-0", diff --git a/studio/frontend/src/features/hub/catalog/owner-scope-toggle.tsx b/studio/frontend/src/features/hub/catalog/owner-scope-toggle.tsx index fed8568f99..5f36f5d031 100644 --- a/studio/frontend/src/features/hub/catalog/owner-scope-toggle.tsx +++ b/studio/frontend/src/features/hub/catalog/owner-scope-toggle.tsx @@ -28,8 +28,8 @@ export function OwnerScopeToggle({ onValueChange={onChange} ariaLabel="Publisher scope" align="end" - // Extra gap so the chevron sits a touch further from the label. - className="h-8 gap-1.5 text-[11.5px]" + // Extra gap before the chevron; min-width keeps the pill readable. + className="h-8 min-w-[96px] gap-1.5 text-[11.5px]" /> ); } diff --git a/studio/frontend/src/features/hub/hub-page.tsx b/studio/frontend/src/features/hub/hub-page.tsx index b3c9dd0dbe..e379d7f2ee 100644 --- a/studio/frontend/src/features/hub/hub-page.tsx +++ b/studio/frontend/src/features/hub/hub-page.tsx @@ -90,18 +90,19 @@ const ALL_MODELS_VIEW_STORAGE_KEY = "unsloth.hub.allModelsView"; const INVENTORY_SORT_STORAGE_KEY = "unsloth.hub.inventorySort"; const OWNER_SCOPE_STORAGE_KEY = "unsloth.hub.ownerScope"; -/** Discover browsing scope: only the unsloth org (default) or the whole Hub. */ +/** Discover browsing scope: the whole Hub (default) or only the unsloth org. */ export type OwnerScope = "unsloth" | "all"; function readOwnerScopePreference(): OwnerScope { if (typeof window === "undefined") { - return "unsloth"; + return "all"; } try { const value = window.localStorage.getItem(OWNER_SCOPE_STORAGE_KEY); - return value === "all" ? "all" : "unsloth"; + // Default to the whole Hub; only honor an explicit "unsloth" preference. + return value === "unsloth" ? "unsloth" : "all"; } catch { - return "unsloth"; + return "all"; } }