Repository navigation
v0.8.0 - Dispatch
v0.8.0 - Dispatch
⚠️ Breaking Changes
reactpeer bumped to>=19.2.0(from^19.0) - the event system below usesuseEffectEvent, stable only from React 19.2 onward. Only affects the@kvvasuu/klipp/reactentry point; the framework-agnostic@kvvasuu/klippengine has no React dependency at all, so this doesn't touch it.
✨ New Features
- Camera Events -
KlippCorenow extends three'sEventDispatcher, dispatchingactivated/deactivated/blendCreated/blendFinished/cutfor every arbitration and blend transition it drives.VirtualCameraControllerextendsEventDispatchertoo, re-dispatching only the events one specific camera takes part in -activatedwhen it's incoming,deactivatedwhen it's outgoing,blendCreated/cuton either side,blendFinishedwhen it's the one that just settled live. Two ways to listen to either:<Klipp.Events>/<VirtualCamera.Events>as callback props, or arefon<VirtualCamera>foraddEventListenerstraight on the underlyingVirtualCameraController.
🐛 Bug Fixes
CameraControlsno longer reconnects on every unrelated re-render - itson*event props (onControlStart/onUpdate/etc.) used to sit in the connect effect's dependency array, so a fresh inline callback from any parent re-render tore down and rebuilt the wholecamera-controlsconnection, occasionally dropping an in-progress drag. Now handled viauseEffectEvent, so only an actual change in target/domElement/arbitration reconnects.
🔧 Internal Changes
- Hardened
KlippCore.tick()'s event dispatch against reentrancy - a listener that synchronously callsregisterCamera/updatePrioritycan no longer corrupt a later event's payload within the same tick. - New tests:
KlippCore,VirtualCameraController,VirtualCamera, andCameraControlsall get coverage for the new events and the two fixes above. - Docs: a new Events page under Advanced, covering both listening paths, all five events, and the
refalternative.
What's Changed
Full Changelog: v0.7.0...v0.8.0