[bug]: block-toolbar component on blocks page stops working if you click the currently active toggle again
ItsValerius opened this issue · 0 comments
ItsValerius commented
Describe the bug
The ToggleGroup component on the blocks page stops working if you click the currently active toggle again.
This is because we pass an empty string to the parseInt function, when the value doesn't change.
Fixing only requires checking if there is a value.
See here in the radix documentation:
https://www.radix-ui.com/primitives/docs/components/toggle-group#ensuring-there-is-always-a-value
Affected component/components
How to reproduce
- Go to Blocks page
- chose a size
- click that size again
Codesandbox/StackBlitz link
No response
Logs
No response
System Info
Windows, Firefox/Chrome
Before submitting
- I've made research efforts and searched the documentation
- I've searched for existing issues