pmndrs / uikit

🎨 user interfaces for react-three-fiber
https://pmndrs.github.io/uikit/docs/
Other
2.6k stars 135 forks source link

onFocusChange is not called #75

Closed wrangelvid closed 3 months ago

wrangelvid commented 3 months ago

The onFocusChange callback in the input is not being called. Here is a runnable example where I construct a basic Input component that changes the border color upon focusing on it. I attached a console log to the onHoverChange, which works, but onFocusChange doesn't result in logs.

        <Input
          borderWidth={2}
          focus={{ borderColor: 'orange' }}
          onFocusChange={(focused) => console.log('focus: ', focused)}
          onHoverChange={(hovered) => console.log('hover: ', hovered)}
          borderColor="black"
          value={text}
          onValueChange={setText}
          minWidth={100}
        />
wrangelvid commented 3 months ago

Ah @bbohlender was too quick and already fixed it in #74 :)