Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

그우린차 이미지 적용 #51

Merged
merged 9 commits into from
Jan 13, 2024
4 changes: 3 additions & 1 deletion src/components/card/PokemonCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,9 @@ const PokemonCard = ({
? `${styles.pokemon_image__my}`
: `${styles.pokemon_image}`
}
src={data.sprites}
src={
data.id !== 1013 ? data.sprites : '/pokemonImg/그우린차.webp'
}
alt="포켓몬 이미지"
/>
<div className={styles.pokemon_intro}>
Expand Down
6 changes: 4 additions & 2 deletions src/components/cardEdit/CardsRowLayout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,10 @@ const CardsRowLayout = ({ pokemonArray }: CardsRowLayoutProps) => {
{pokemonData ? (
<img
src={
pokemonData?.sprites?.other?.['official-artwork']
?.front_default
pokemonData.id !== 1013
? pokemonData.sprites?.other?.['official-artwork']
?.front_default
: '/pokemonImg/그우린차.webp'
}
alt="포켓몬 이미지"
/>
Expand Down
6 changes: 5 additions & 1 deletion src/components/list/PokemonListElement.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,11 @@ const PokemonListElement = ({ data }: PokemonListElementProp) => {
<img
loading="lazy"
className={styles.pokemon_image}
src={data.sprites?.other?.['official-artwork']?.front_default}
src={
data.id !== 1013
? data.sprites?.other?.['official-artwork']?.front_default
: '/pokemonImg/그우린차.webp'
}
alt="포켓몬 이미지"
/>
<span className={styles.pokemon_name}>
Expand Down
Loading