theatre-js / theatre

Motion design editor for the web
https://www.theatrejs.com
Apache License 2.0
10.82k stars 337 forks source link

studio.transaction set method is throwing error when same code used with old and new versions #481

Open rm-vt opened 1 month ago

rm-vt commented 1 month ago

Thanks for inventing this framework/lib.

Facing issues with studio.transaction set method.

Current package versions which is throwing error on set method

"@theatre/core": "^0.7.0",
"@theatre/studio": "^0.7.0",
"next": "14.1.0",

Old package versions - no error

"@theatre/core": "^0.4.7",
"@theatre/studio": "^0.4.7",
"react": "^17.0.2",
"react-dom": "^17.0.2"

TheatreSheetObject props(proxy object) shows diff implementation get(obj, props) vs get(pointerKey, prop) Right-side old version - ^0.4.7 Left-side new version - ^0.7.0 image

TheatreSheetObject implementation is different across versions image

Please help. Thanks.

AriaMinaei commented 1 month ago

@rm-vt This looks interesting. Is there any way you can share a reproduction on Stackblitz/Codesandbox/Git repo?

rm-vt commented 1 month ago

Sure. @AriaMinaei

Setup with old package versions: https://codesandbox.io/p/devbox/theatre-js-svg-animation-updated-forked-n63dy7

Setup with new package versions: https://codesandbox.io/p/devbox/threatrejs-nextjs-latest-svg-l98nvw

Please drag the robot hand as pointed out on both of the above setup to see the error!

image

Thanks.