chore: fix search suggestion

This commit is contained in:
Louis 2023-10-06 16:35:22 +07:00 committed by Louis
parent 1ceedf1cfe
commit c23d1b6bbe
2 changed files with 4 additions and 1 deletions

View File

@ -8,7 +8,7 @@ const ExploreModelContainer: React.FC = () => (
<HeaderTitle title="Explore Models" /> <HeaderTitle title="Explore Models" />
<SearchBar <SearchBar
type={SearchType.Model} type={SearchType.Model}
placeholder="Owner name like TheBloke, etc.." placeholder="Owner name like TheBloke, bhlim etc.."
/> />
<div className="flex flex-1 gap-x-10 mt-9 overflow-hidden"> <div className="flex flex-1 gap-x-10 mt-9 overflow-hidden">
<ExploreModelFilter /> <ExploreModelFilter />

View File

@ -17,6 +17,9 @@ const ExploreModelList: React.FC = () => {
}); });
useEffect(() => { useEffect(() => {
if (modelList.length === 0 && modelSearch.length > 0) {
setLoadMoreInProress(true);
}
getHuggingFaceModel(modelSearch); getHuggingFaceModel(modelSearch);
}, [modelSearch]); }, [modelSearch]);