base-ui
base-ui copied to clipboard
[number field] Ensure `onValueChange` is called with already-formatted parsed value
Fixes #1817
- Uses
maximumFractionDigits: 20when checking to ensure full precision - Values coming externally have their precision respected as priority until changed via the event handlers, at which point the formatting is respected
Preview: https://codesandbox.io/p/sandbox/base-ui-number-input-blurring-2-forked-crsnw2?file=%2Fsrc%2FApp.tsx
Deploy Preview for base-ui ready!
| Name | Link |
|---|---|
| Latest commit | e65cbddac06f7844dbf1d44cbb35ffa29ec00d5d |
| Latest deploy log | https://app.netlify.com/projects/base-ui/deploys/684fad36a2e5fe0008ad2c3f |
| Deploy Preview | https://deploy-preview-1905--base-ui.netlify.app |
| Preview on mobile | Toggle QR Code...Use your smartphone camera to open QR code link. |
To edit notification comments on pull requests, go to your Netlify project configuration.
Bundle size report
Total Size Change:${\tiny{\color{red}▲}}$+829B(+0.06%) - Total Gzip Change:${\tiny{\color{red}▲}}$+255B(+0.05%) Files: 41 total (0 added, 0 removed, 2 changed)
@base-ui-components/react parsed:${\tiny{\color{red}▲}}$+418B(+0.14%) gzip:${\tiny{\color{red}▲}}$+120B(+0.13%) @base-ui-components/react/number-field parsed:${\tiny{\color{red}▲}}$+411B(+1.45%) gzip:${\tiny{\color{red}▲}}$+135B(+1.32%)
Generated by :no_entry_sign: dangerJS against e65cbddac06f7844dbf1d44cbb35ffa29ec00d5d