ReactVision/viro

ViroNode Component onClick not working smoothly on Android devices

sanoop-newagesmb opened this issue · 2 comments

Requirements:

Environment

Please provide the following information about your environment:

  1. Development OS: Mac
  2. Device OS & Version: Android 11,12, 13
  3. Version: React Native: 0.66.4, ViroReact 2.22.0
  4. Device(s): Motorola One Fusion Plus, Vivo T1 Pro

Description

In Android devices, ViroNode component onClick is not calling as expected. We had to click multiple times to get the onClick event. I am searching for a solution to this for a long time.

Reproducible Demo

const MyVRScene = () => {
  const handleClick = () => {
    // Handle click event logic here
  };

  return (
    <ViroScene>
      <ViroNode onClick={handleClick}>
          <Viro3DObject
          source={require('model.obj')}
          scale={[1, 1, 1]}
          rotation={[0, 0, 0]}
          position={[0, 0, -1]}
        />
      </ViroNode>
    </ViroScene>
  );
};

export default MyVRScene;
skizzo commented

Hi,
may I ask which version of React Native you are using?
Thank you for some info

Hi skizzo,

React Native Version: 0.66.4