This fixes an issue where the consumer wouldn't know if the onValueChange was triggered by a mouse or by keyboard. They might decide to react on the user finishing resizing, which, for a mouse is easy (onDragEnd) but for a keyboard we don't have such callback, since we trigger onValueChange each time a button is pressed and value updated.
By updating the event callbacks to be in better alignment with Fluent UI and using EventHandler, we can now determine if the source of onValueChange is keyboard by comparing the data.type attribute to EVENTS.keyboard
This fixes an issue where the consumer wouldn't know if the
onValueChange
was triggered by a mouse or by keyboard. They might decide to react on the user finishing resizing, which, for a mouse is easy (onDragEnd
) but for a keyboard we don't have such callback, since we triggeronValueChange
each time a button is pressed and value updated.By updating the event callbacks to be in better alignment with Fluent UI and using
EventHandler
, we can now determine if the source ofonValueChange
is keyboard by comparing thedata.type
attribute toEVENTS.keyboard