brianzinn / react-babylonjs

React for Babylon 3D engine
https://brianzinn.github.io/react-babylonjs/
822 stars 105 forks source link

textBlock onPointerDownObservable not called again after first event #241

Closed AJamesPhillips closed 2 years ago

AJamesPhillips commented 2 years ago

With the following code you can click the textBlock multiple times and see it only log to the console once. If you click the button it logs multiple times: https://codesandbox.io/s/textblock-onpointerdown-9yv7vt?file=/src/App.tsx

Expected result: clicking the textBlock should log multiple times.

Related info: it appears that clicking the console window then allows you to click the textBlock again so I assume this is some focus related issue.

brianzinn commented 2 years ago

Unfortunately I'm not going to be able to fix that - it's a downstream issue. If you upgrade your codesandbox to @babylonjs/gui@5.19.0, for example, then it works as expected. Please re-open if you have more questions.