sanity-io / sanity-plugin-hotspot-array

A configurable Custom Input for Arrays that will add and update items by clicking on an Image
MIT License
23 stars 7 forks source link

Spot Bounds not properly updated on first drag #2

Closed applehat closed 2 years ago

applehat commented 2 years ago

Short explanation of problem I'm seeing.

The rect state in Spot.tsx is getting reset to its default on the first drag of a newly created "spot".

Dragging it again seems to resolve the issue.

Haven't spent any real time tying to solve the issue myself outside of just diagnosing the bug I was seeing.

I've attached a video showing the issue in action.

https://user-images.githubusercontent.com/262524/147983930-8abfe057-e722-4387-ab9a-6629e5513ab8.mp4

SimeonGriggs commented 2 years ago

Thanks for reporting! Fixed in 0.0.3

applehat commented 2 years ago

Super quick!

@SimeonGriggs Thanks man, confirmed working as expected in my local studio!