Understand SpringEvent types and sources
mainAll event handlers receive a SpringEvent object. The type property is always present and can be 'OPEN' | 'RESIZE' | 'SNAP' | 'CLOSE'. Some event types include a source property to provide context:
RESIZE source
'window': Triggered by a window resize event.'maxheightprop': Triggered when themaxHeightprop changes.'element': Triggered when header, footer, or content resize observers detect a change.
SNAP source
'dragging': Triggered when a drag gesture ends.'custom': Triggered when using theref.current.snapTo()method.string: A custom source string provided by the user.