pmndrs / react-xr

🤳 VR/AR with react-three-fiber
https://npmjs.com/@react-three/xr
MIT License
1.98k stars 137 forks source link

XRButton styling #267

Closed Soham1803 closed 1 year ago

Soham1803 commented 1 year ago

Props should be added to the XRButton component to position and style the XRButton.

CodyJasonBennett commented 1 year ago

This is already supported, XRButton is an HTML button and accepts all of its props in addition to the XRButton interface.

Soham1803 commented 1 year ago

Ok, I am able to style the button using style prop, but it needs to be styled from the scratch, even the position and zIndex are needed to be set. It would be better if I could just preserve its default form and tweak its color, dimensions, font size and family, and position etc.

CodyJasonBennett commented 1 year ago

I'm not sure how to help you, this is default DOM behavior; this library does not modify HTML buttons emitted other than add listeners to initialize a WebXR session.

Soham1803 commented 1 year ago

I'm extremely sorry, I think I misunderstood something. I thought it was a custom react component. Sorry, I'll close the issue.