bevy
bevy copied to clipboard
Button web example on bevyengine.org clickable area is wrong (Regression?)
Bevy version
Whatever the examples are built with on the webpage: https://bevyengine.org/examples/ui/button/ Is not happening for me locally using Bevy 0.7
System information
Chrome Version 102.0.5005.63 (Official Build) (64-bit) on Windows 11
`AdapterInfo { name: "ANGLE (NVIDIA, NVIDIA GeForce RTX 3080 Direct3D11 vs_5_0 ps_5_0, D3D11)", vendor: 4318, device: 0, device_type: DiscreteGpu, backend: Gl }`
What you did
I opened https://bevyengine.org/examples/ui/button/ and tried clicking the button in the example.
What went wrong
The area that I can click the button is offset from the visual position of the button. It gets more offset (and maybe larger?) if the window is made smaller.
Additional information
Example:
https://user-images.githubusercontent.com/7019130/172485403-d792d1e0-337f-4f55-bed6-6fe9bc2b127d.mp4
I'm 90% sure this wasn't happening earlier today, so it might be something merged recently.
I just tried pulling the main branch and running the example locally using cargo run --release --target wasm32-unknown-unknown --example button
and it seems to be working correctly.
Depending on what version the website uses, this may already be resolved.
Yeah seems like @paul-hansen is right. I'm seeing this same issue on the examples webpage (on firefox too, so a totally different browser), but not if i compile the lastest bevy example locally.
Depending on what version the website uses, this may already be resolved.
The website is using the last released version, 0.7 here
This looks like it might be a duplicate of https://github.com/bevyengine/bevy-website/issues/371 and should have been fixed by https://github.com/bevyengine/bevy/pull/4726.
I agree that looks like the same thing and looks to be fixed in main now. Thanks for tracking that down 👍
I'll close this for now, feel free to reopen or anything though if you think something should be done before 0.8 releases.
#4726 probably didn't fix this as it's an optional behaviour that is not enabled by default
Reopened as we have a fresh reproduction.
issue is on the CSS of the website changing the size of the canvas, I opened https://github.com/bevyengine/bevy-website/pull/429 to change that