UNPKG

@omicrxn/mercury

Version:

Mercury is a Svelte animation library using AnimeJS under the hood. It simplifies complex animations with Svelte actions, provides layout and exit animations, and integrates seamlessly with Svelte features.

14 lines (13 loc) 430 B
import { handleDrag } from './drag.js'; import { handleScroll } from './scroll.js'; import { handleHover } from './hover.js'; import { handleTap } from './tap.js'; export const handleGestures = (element, params) => { let dragGesture = handleDrag(element, params); handleTap(element, params); handleHover(element, params); handleScroll(element, params); return () => { dragGesture?.destroy(); }; };