Make name clickable
This commit is contained in:
parent
859804a649
commit
5a00e2a100
|
|
@ -94,7 +94,7 @@ export function FavoriteBar({teams}) {
|
||||||
<p className="m-2">{favorite ? favorite.name : ''}</p>
|
<p className="m-2">{favorite ? favorite.name : ''}</p>
|
||||||
<ButtonGroup className="m-2">
|
<ButtonGroup className="m-2">
|
||||||
<Button title="Favorit Auswahlmenü öffnen/schließen" onClick={() => setIsVisible(!isVisible)}>
|
<Button title="Favorit Auswahlmenü öffnen/schließen" onClick={() => setIsVisible(!isVisible)}>
|
||||||
<FaHeartCirclePlus />
|
<FaHeartCirclePlus/>
|
||||||
</Button>
|
</Button>
|
||||||
{favorite && (
|
{favorite && (
|
||||||
<Button
|
<Button
|
||||||
|
|
@ -102,7 +102,7 @@ export function FavoriteBar({teams}) {
|
||||||
onClick={scrollToFavorite}
|
onClick={scrollToFavorite}
|
||||||
className={isPulsing ? 'pulse-animation' : ''}
|
className={isPulsing ? 'pulse-animation' : ''}
|
||||||
>
|
>
|
||||||
<FaArrowTurnDown />
|
<FaArrowTurnDown/>
|
||||||
</Button>
|
</Button>
|
||||||
)}
|
)}
|
||||||
</ButtonGroup>
|
</ButtonGroup>
|
||||||
|
|
@ -119,13 +119,21 @@ export function FavoriteBar({teams}) {
|
||||||
)}
|
)}
|
||||||
<div>
|
<div>
|
||||||
{filteredTeams.map(team => (
|
{filteredTeams.map(team => (
|
||||||
<div key={team.id} style={{display: 'flex', alignItems: 'center'}}>
|
<div
|
||||||
<Button onClick={() => toggleFavorite(team)} style={{marginRight: '10px'}}>
|
key={team.id}
|
||||||
{favorite && favorite.id === team.id ? <FaHeart /> : <FaRegHeart />}
|
onClick={() => toggleFavorite(team)}
|
||||||
|
style={{display: 'flex', alignItems: 'center', cursor: 'pointer'}}
|
||||||
|
>
|
||||||
|
<Button
|
||||||
|
onClick={e => {
|
||||||
|
e.stopPropagation();
|
||||||
|
toggleFavorite(team);
|
||||||
|
}}
|
||||||
|
style={{marginRight: '10px'}}
|
||||||
|
>
|
||||||
|
{favorite && favorite.id === team.id ? <FaHeart/> : <FaRegHeart/>}
|
||||||
</Button>
|
</Button>
|
||||||
<span>
|
<span>{team.name}</span>
|
||||||
{team.name}
|
|
||||||
</span>
|
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue