Skip to content

Commit

Permalink
feat: improve lift interaction
Browse files Browse the repository at this point in the history
  • Loading branch information
emilkowalski committed Nov 3, 2024
1 parent 0c5fab4 commit 9aecbb5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -664,7 +664,7 @@ const Toaster = forwardRef<HTMLElement, ToasterProps>(function Toaster(props, re
data-sonner-toaster
data-theme={actualTheme}
data-y-position={y}
data-expanded={expanded}
data-lifted={expanded && toasts.length > 1 && !expand}
data-x-position={x}
style={
{
Expand Down
2 changes: 1 addition & 1 deletion src/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
transition: transform 400ms ease;
}

:where([data-sonner-toaster][data-expanded='true']) {
:where([data-sonner-toaster][data-lifted='true']) {
transform: translateY(-10px);
}

Expand Down

0 comments on commit 9aecbb5

Please sign in to comment.