Closed devinmarkley closed 2 months ago
Please, make me a sandbox, so I can easily help you
Sorry about that here is a link to my sandbox
https://codesandbox.io/p/github/devinmarkley/rps_example/main?import=true
I looked into this more deeply today to see why your version was working, and mine was not. Setting the default zoom level to 0 only works for images in the public directory.
Here's a link to my example
https://codesandbox.io/p/github/devinmarkley/rps_example/main?import=true
If you uncomment src={"Test_Pano.jpg"} the zoom level will be set to zero, but using the import image, it will use the default zoom of 50.
What happened?
When setting defaultZoomLvl to zero, my image uses the default zoom of 50.
What should have happened?
The image should be all the way zoomed out at the default level of 0
Code
`import React from "react"; import { ReactPhotoSphereViewer } from "react-photo-sphere-viewer"; import image from "./images/somePano.JPG";
export default function ImageViewer() { const pSRef = React.createRef();
return ( <> <ReactPhotoSphereViewer ref={pSRef} width={"100vw"} height={"100vh"} container={"container-360"} src={image} navbar={false} defaultZoomLvl={0} /> </> ); };`
Sandbox Link
No response
Library Version
What operating system are you using?
macOS
What browser are you using?
Chrome
Logs
No response
Interest to fix the bug