Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: SpinButton slot input handler cannot set value #33501

Open
2 tasks done
spmonahan opened this issue Dec 20, 2024 · 0 comments
Open
2 tasks done

[Bug]: SpinButton slot input handler cannot set value #33501

spmonahan opened this issue Dec 20, 2024 · 0 comments

Comments

@spmonahan
Copy link
Contributor

Component

SpinButton

Package version

latest

React version

18

Environment

StackBlitz

Current Behavior

When I add an onInput listener to the input slot so I can handle more input cases the value is not set when SpinButton is controlled.

Expected Behavior

When I update the value of a controlled component the value should be updated.

Reproduction

https://stackblitz.com/edit/drepb7?file=src%2Fexample.tsx,package.json

Steps to reproduce

  1. Go to repro case
  2. Click into the SpinButton's text field
  3. Type a number
  4. Click the increment button
  5. Value increments based on the initial value, not what was typed.

I expect the value to increment based on what was typed.

Are you reporting an Accessibility issue?

None

Suggested severity

High - No workaround

Products/sites affected

No response

Are you willing to submit a PR to fix?

yes

Validations

  • Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
  • The provided reproduction is a minimal reproducible example of the bug.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants