Skip to content

Commit

Permalink
fix(frontend): only animate titlecard when showDetail is true
Browse files Browse the repository at this point in the history
  • Loading branch information
sct committed Jan 4, 2021
1 parent effc809 commit 0ab4c3c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/components/TitleCard/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,9 @@ const TitleCard: React.FC<TitleCardProps> = ({
onCancel={closeModal}
/>
<div
className="transition duration-300 transform scale-100 outline-none cursor-default titleCard hover:scale-105 focus:scale-105"
className={`transition duration-300 transform scale-100 outline-none cursor-default titleCard ${
showDetail ? 'scale-105' : ''
}`}
style={{
backgroundImage: `url(//image.tmdb.org/t/p/w300_and_h450_face${image})`,
}}
Expand Down

0 comments on commit 0ab4c3c

Please sign in to comment.