Skip to content

[BUG] useTransform doesn't work well with padding-block using numbers and other logical values #3413

@Calvein

Description

@Calvein

1. Read the FAQs 👇

2. Describe the bug

use

3. IMPORTANT: Provide a CodeSandbox reproduction of the bug

I hope stackblitz is fine: https://stackblitz.com/edit/vitejs-vite-4d7vhxcr?file=src%2FApp.tsx&terminal=dev

4. Steps to reproduce

Steps to reproduce the behavior:

  1. Scroll the example
  2. The 2 elements are very similar, one using useTransform with numbers and one with strings
  3. When scrolling, the one using number jumps from 100 to 0 and never goes back to 100

5. Expected behavior

It should work like any other css values accepting pixels, e.g: padding

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions