ModelPicker
A model from the project's catalogue: provider mark, name and id, grouped by provider. The start of a comparison column's header.
function Basic() {
const [model, setModel] = useState("claude-sonnet-4-5");
return (
<div className="flex h-52 w-full max-w-360 items-center pl-8 hairline-b">
<ModelPicker value={model} onValueChange={setModel} options={playgroundModels} />
</div>
);
}import { ModelPicker } from "@logicplanes/kaeso-ui/playground";Props
appearance"ghost" | "default" = ghostA quiet button (
ghost) or a filled one (default).aria-labelstringThe picker's accessible name ("Model" by default).
defaultValuestring | nullThe chosen model on first render.
disabledbooleanTurns it off: it can't be used, and it looks dimmed.
groupByProviderbooleanGroups the list by provider (true by default when there are several).
onValueChange((value: string) => void)Called with the chosen model.
optionsModelPickerOption[]The models to choose from.
placeholderstringText shown while there is no value.
size"md" | "sm" = smThe button's height.
valuestring | nullThe chosen model, when you control it.