Skip to content

Commit

Permalink
fix safari scroll #120
Browse files Browse the repository at this point in the history
Revert "fix safari scroll #120"

This reverts commit 8c0096b.

add zIndex to back
  • Loading branch information
yangchristina authored and AaronCCWong committed May 31, 2024
1 parent 72de968 commit 65b3241
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/ReactCardFlip.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const ReactCardFlip: React.FC<ReactFlipCardProps> = (props) => {
flipSpeedBackToFront,
infinite,
isFlipped,
} = {
} = {
cardStyles: {
back: {},
front: {},
Expand All @@ -31,7 +31,7 @@ const ReactCardFlip: React.FC<ReactFlipCardProps> = (props) => {
isFlipped: false,
...props
}

const [isFlippedState, setFlipped] = useState(isFlipped);
const [rotation, setRotation] = useState(0);

Expand Down Expand Up @@ -84,6 +84,7 @@ const ReactCardFlip: React.FC<ReactFlipCardProps> = (props) => {
transformStyle: 'preserve-3d',
transition: `${flipSpeedFrontToBack}s`,
width: '100%',
zIndex: isFlipped ? '2' : '1',
...back,
},
container: {
Expand Down

0 comments on commit 65b3241

Please sign in to comment.