fix(ssr): fix no players msg showing if there's no search
All checks were successful
deploy / deploy (push) Successful in 1m5s

This commit is contained in:
Lee 2023-11-09 20:01:28 +00:00
parent 350fe875fe
commit 426a2b5a2f

@ -80,8 +80,8 @@ export default function SearchPlayer() {
players ? "flex" : "hidden", players ? "flex" : "hidden",
)} )}
> >
{players && players.length > 0 ? ( {players && players.length > 0
players.map((player: ScoresaberPlayer) => ( ? players.map((player: ScoresaberPlayer) => (
<Link <Link
key={player.id} key={player.id}
className="flex min-w-[14rem] items-center gap-2 p-2 transition-all hover:bg-background" className="flex min-w-[14rem] items-center gap-2 p-2 transition-all hover:bg-background"
@ -97,9 +97,7 @@ export default function SearchPlayer() {
</div> </div>
</Link> </Link>
)) ))
) : ( : search.length > 0 && <div className="p-2">No players found</div>}
<div className="p-2">No players found</div>
)}
</div> </div>
</form> </form>
); );