Skip to content

Commit 6997a9e

Browse files
authored
fix(preview-server): broken file tree animation on built preview (#2403)
1 parent c85be9f commit 6997a9e

File tree

5 files changed

+35
-64
lines changed

5 files changed

+35
-64
lines changed

.changeset/some-experts-call.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@react-email/preview-server": patch
3+
---
4+
5+
fix broken file tree animation on built preview server

packages/preview-server/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
"chalk": "4.1.2",
3535
"clsx": "2.1.1",
3636
"esbuild": "0.25.0",
37-
"framer-motion": "12.7.5",
37+
"framer-motion": "12.23.12",
3838
"json5": "2.2.3",
3939
"log-symbols": "4.1.0",
4040
"module-punycode": "npm:[email protected]",

packages/preview-server/src/components/toolbar/checking-results.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import * as Collapsible from '@radix-ui/react-collapsible';
2-
import { AnimatePresence, motion } from 'framer-motion';
2+
import { AnimatePresence, motion, type Variants } from 'framer-motion';
33
import type { ComponentProps } from 'react';
44
import { cn } from '../../utils';
55

@@ -80,7 +80,7 @@ type ResultProps = {
8080
status: ResultStatus;
8181
} & ComponentProps<typeof motion.li>;
8282

83-
const resultAnimation = {
83+
const resultAnimation: Variants = {
8484
hidden: { opacity: 0, y: 10 },
8585
visible: {
8686
opacity: 1,
@@ -110,7 +110,7 @@ export const Result = ({ children, status, ...rest }: ResultProps) => {
110110
);
111111
};
112112

113-
const titleStatusAnimation = {
113+
const titleStatusAnimation: Variants = {
114114
hidden: { opacity: 0, y: 5 },
115115
visible: {
116116
opacity: 1,

packages/preview-server/src/utils/constants.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
export const tabTransition = {
1+
import type { Transition } from 'framer-motion';
2+
3+
export const tabTransition: Transition = {
24
type: 'spring',
35
stiffness: 2000,
46
damping: 80,

pnpm-lock.yaml

Lines changed: 23 additions & 59 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)