zoom and scroll page #1929
Replies: 5 comments
-
Can I assume you're using the latest, v1.3? Perhaps you want to set the touch-action attribute to |
Beta Was this translation helpful? Give feedback.
-
Can I assume you're using the latest, v1.3? Perhaps you want to set the touch-action attribute to When you say mouse zoom, at you talking about a mouse wheel? And do you really want both zooming and scrolling to happen at once? You can also set up zoom to be triggered by scroll you can see my test page here : https://data.strategia.io/modelviewertest/index.html I think it need a line trace hit between 3d model and mouse cursor to detect if i'm over the 3d model or not, I don't know if model-viewer can do that. |
Beta Was this translation helpful? Give feedback.
-
Ah, thank you for the details, I understand now. We don't support hit-testing to determine what interactions do for a couple of reasons. First, it's expensive to hit test, so putting that in a mouse handler would destroy page responsiveness. Second, some models (like fences or screens) have such finely detailed geometry that a user could have a hard time putting their mouse on/off the model reliably. Perhaps a subtle background highlight when the user is hovering over the model-viewer element? |
Beta Was this translation helpful? Give feedback.
-
What would I have to do to disable model-viewer zoom with scroll wheel and let it scroll the page instead? |
Beta Was this translation helpful? Give feedback.
-
At the moment all we have is not including the |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello
Is it possible to ensure that the modelviewer background don't receive the scroll, only 3D model?
Because I have a scroll page and if my mouse is inside modelviewer div it zoom instead of scrolling on the page.
I want to keep the zoom functionality but aslo scroll to my page.
Or perhaps another solution?
Thanks
Beta Was this translation helpful? Give feedback.
All reactions