fix: fetch all knowledge bases via pagination in link-to-dataset dialog (#17170)

This commit is contained in:
euvre
2026-07-23 16:48:05 +08:00
committed by GitHub
parent 6467df3437
commit 418d3c8cef
8 changed files with 169 additions and 47 deletions

View File

@@ -192,6 +192,7 @@ interface MultiSelectProps
onSearchChange?: (value: string) => void;
isSearching?: boolean;
shouldFilter?: boolean;
onListScroll?: (e: React.UIEvent<HTMLDivElement>) => void;
}
export const MultiSelect = React.forwardRef<
@@ -217,6 +218,7 @@ export const MultiSelect = React.forwardRef<
onSearchChange,
isSearching = false,
shouldFilter,
onListScroll,
...props
},
ref,
@@ -451,7 +453,7 @@ export const MultiSelect = React.forwardRef<
onValueChange={onSearchChange}
/>
)}
<CommandList className="mt-2">
<CommandList className="mt-2" onScroll={onListScroll}>
<CommandEmpty>
{isSearching ? t('common.searching') : t('common.noDataFound')}
</CommandEmpty>