diff --git a/components/dashboard/src/projects/NewProject.tsx b/components/dashboard/src/projects/NewProject.tsx index 328f1d1fa66881..c4e711f76c5455 100644 --- a/components/dashboard/src/projects/NewProject.tsx +++ b/components/dashboard/src/projects/NewProject.tsx @@ -214,9 +214,11 @@ export default function NewProject() { const renderSelectRepository = () => { const noReposAvailable = reposInAccounts.length === 0; - const filteredRepos = Array.from(reposInAccounts).filter(r => r.account === selectedAccount && r.name.includes(repoSearchFilter)); + const filteredRepos = Array.from(reposInAccounts).filter(r => r.account === selectedAccount && `${r.name}`.toLowerCase().includes(repoSearchFilter.toLowerCase())); const icon = selectedAccount && accounts.get(selectedAccount)?.avatarUrl; + const showSearchInput = !!repoSearchFilter || filteredRepos.length > 0; + const renderRepos = () => (<>
@@ -229,7 +231,7 @@ export default function NewProject() {
- {filteredRepos.length > 0 && ( + {showSearchInput && (