-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Open
Labels
Description
Describe the bug
Using Svelte 4 and before, this REPL custom Accordion with a slide effect was working perfectly. Since Svelte 5, it throws a warning:
Invalid keyframe value for property height: NaNpx
I like the approach of this accordion using {#key isOpen} as it re-runs the transition and also keeps the content in the DOM, only playing with CSS to hide the content when closed.
I haven't made this REPL but adapted it to a similar component in my codebase.
Reproduction
REPL with Svelte 5 (and the warning): https://svelte.dev/playground/a904286e5a4c497daa9e6f9351b3f3a9?version=5
REPL with Svelte 4 (and no warning): https://svelte.dev/playground/a904286e5a4c497daa9e6f9351b3f3a9?version=4
Logs
> Invalid keyframe value for property height: NaNpxSystem Info
System:
OS: macOS 15.1
CPU: (12) arm64 Apple M2 Max
Memory: 258.97 MB / 32.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 20.18.0 - ~/.local/state/fnm_multishells/32005_1720871078955/bin/node
Yarn: 1.22.19 - ~/.local/state/fnm_multishells/32005_1720871078955/bin/yarn
npm: 10.9.0 - ~/.local/state/fnm_multishells/32005_1720871078955/bin/npm
pnpm: 8.5.0 - ~/.local/state/fnm_multishells/32005_1720871078955/bin/pnpm
bun: 1.1.34 - ~/.bun/bin/bun
Browsers:
Brave Browser: 130.1.71.118
Safari: 18.1Severity
annoyance
kevinsschmidt, EskelCz, VismaTobbe, brenthoneybone, daviareias and 6 morevhtmui, VismaTobbe, brenthoneybone and nopale