Skip to content

Commit

Permalink
fix(animation): add back flip keyframe
Browse files Browse the repository at this point in the history
  • Loading branch information
abboahene committed Mar 15, 2024
1 parent 4199f59 commit 67211aa
Showing 1 changed file with 22 additions and 30 deletions.
52 changes: 22 additions & 30 deletions packages/animated-pandacss/src/keyframes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -542,6 +542,28 @@ export const keyframes = defineKeyframes({
transform: 'translate3d(-100%, 100%, 0)',
},
},
flip: {
'0%': {
transform: 'perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn)',
animationTimingFunction: 'ease-out',
},
'40%': {
transform: 'perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg)',
animationTimingFunction: 'ease-out',
},
'50%': {
transform: 'perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg)',
animationTimingFunction: 'ease-in',
},
'80%': {
transform: 'perspective(400px) scale3d(0.95, 0.95, 0.95) translateZ(0) rotateY(0deg)',
animationTimingFunction: 'ease-in',
},
to: {
transform: 'perspective(400px) scaleX(1) translateZ(0) rotateY(0deg)',
animationTimingFunction: 'ease-in',
},
},
flipInX: {
'0%': {
transform: 'perspective(400px) rotateX(90deg)',
Expand Down Expand Up @@ -878,33 +900,3 @@ export const keyframes = defineKeyframes({
},
},
})

// some how causees compile error
// flip: {
// '0%': {
// WebkitTransform: 'perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn)',
// transform: 'perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn)',
// animationTimingFunction: 'ease-out',
// },
// '40%': {
// WebkitTransform: 'perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg)',
// transform: 'perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg)',
// animationTimingFunction: 'ease-out',
// },
// '50%': {
// WebkitTransform: 'perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg)',
// transform: 'perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg)',
// animationTimingFunction: 'ease-in',
// },
// '80%': {
// WebkitTransform:
// 'perspective(400px) scale3d(0.95, 0.95, 0.95) translateZ(0) rotateY(0deg)',
// transform: 'perspective(400px) scale3d(0.95, 0.95, 0.95) translateZ(0) rotateY(0deg)',
// animationTimingFunction: 'ease-in',
// },
// to: {
// WebkitTransform: 'perspective(400px) scaleX(1) translateZ(0) rotateY(0deg)',
// transform: 'perspective(400px) scaleX(1) translateZ(0) rotateY(0deg)',
// animationTimingFunction: 'ease-in',
// },
// },

0 comments on commit 67211aa

Please sign in to comment.