mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-02-10 01:50:08 +00:00
[backport cloud/1.36] [feat] Filter out nlf model type from Upload Model flow (#7886)
Backport of #7793 to `cloud/1.36` Automatically created by backport workflow. Co-authored-by: Luke Mino-Altherr <luke@comfy.org> Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -37,6 +37,8 @@ interface ModelTypeOption {
|
||||
value: string // Actual tag value
|
||||
}
|
||||
|
||||
const DISALLOWED_MODEL_TYPES = ['nlf'] as const
|
||||
|
||||
/**
|
||||
* Composable for fetching and managing model types from the API
|
||||
* Uses shared state to ensure data is only fetched once
|
||||
@@ -51,6 +53,12 @@ export const useModelTypes = createSharedComposable(() => {
|
||||
async (): Promise<ModelTypeOption[]> => {
|
||||
const response = await api.getModelFolders()
|
||||
return response
|
||||
.filter(
|
||||
(folder) =>
|
||||
!DISALLOWED_MODEL_TYPES.includes(
|
||||
folder.name as (typeof DISALLOWED_MODEL_TYPES)[number]
|
||||
)
|
||||
)
|
||||
.map((folder) => ({
|
||||
name: formatDisplayName(folder.name),
|
||||
value: folder.name
|
||||
|
||||
Reference in New Issue
Block a user