WebUI hide models in router mode (#19374)

This commit is contained in:
crsawyer
2026-02-19 15:53:42 -06:00
committed by GitHub
parent 3dadc88b58
commit 10b26ee23a
2 changed files with 10 additions and 1 deletions
@@ -42,7 +42,13 @@
useGlobalSelection = false
}: Props = $props();
let options = $derived(modelOptions());
let options = $derived(
modelOptions().filter((option) => {
const modelProps = modelsStore.getModelProps(option.model);
return modelProps?.webui !== false;
})
);
let loading = $derived(modelsLoading());
let updating = $derived(modelsUpdating());
let activeId = $derived(selectedModelId());
@@ -245,6 +251,9 @@
return options.find((option) => option.id === activeId);
}
if (options.length === 1) {
return options[0];
}
// No selection - return undefined to show "Select model"
return undefined;
}