mirror of
https://github.com/vercel/commerce.git
synced 2025-05-18 07:26:59 +00:00
Remove transition/animation for mobile
This commit is contained in:
parent
e8b92119ea
commit
9bd7d1eda3
@ -1,13 +1,7 @@
|
||||
.root {
|
||||
@apply shadow-lg w-56 bg-accent-0;
|
||||
box-shadow: hsl(206 22% 7% / 45%) 0px 10px 38px -10px,
|
||||
hsl(206 22% 7% / 20%) 0px 10px 20px -15px;
|
||||
will-change: transform, opacity;
|
||||
animation-duration: 600ms;
|
||||
animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
|
||||
animation-fill-mode: forwards;
|
||||
transform-origin: var(--radix-dropdown-menu-content-transform-origin);
|
||||
animation-name: slideIn;
|
||||
@apply w-56 bg-accent-0;
|
||||
animation: none;
|
||||
transition: none;
|
||||
}
|
||||
|
||||
@keyframes slideIn {
|
||||
@ -17,6 +11,20 @@
|
||||
}
|
||||
100% {
|
||||
opacity: 1;
|
||||
transform: translateY(0);
|
||||
transform: translateY(0px);
|
||||
}
|
||||
}
|
||||
|
||||
@media screen(md) {
|
||||
.root {
|
||||
@apply shadow-lg;
|
||||
box-shadow: hsl(206 22% 7% / 45%) 0px 10px 38px -10px,
|
||||
hsl(206 22% 7% / 20%) 0px 10px 20px -15px;
|
||||
will-change: transform, opacity;
|
||||
animation-duration: 600ms;
|
||||
animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
|
||||
animation-fill-mode: forwards;
|
||||
transform-origin: var(--radix-dropdown-menu-content-transform-origin);
|
||||
animation-name: slideIn;
|
||||
}
|
||||
}
|
||||
|
@ -15,7 +15,7 @@ export const DropdownContent = React.forwardRef<
|
||||
React.RefAttributes<HTMLDivElement>
|
||||
>(function DropdownContent({ children, ...props }, forwardedRef) {
|
||||
return (
|
||||
<DropdownMenu.Content ref={forwardedRef} side="bottom" {...props}>
|
||||
<DropdownMenu.Content ref={forwardedRef} asChild {...props}>
|
||||
<div className={s.root}>{children}</div>
|
||||
</DropdownMenu.Content>
|
||||
)
|
||||
|
Loading…
x
Reference in New Issue
Block a user