@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.
16 lines (15 loc) • 564 B
TypeScript
import { ProjectionNode } from '@layout-projection/core';
import { type AnimationConfig } from '@layout-projection/animation';
/**
* Map of DOM elements to their projection nodes.
*/
export declare const nodeMap: WeakMap<HTMLElement, ProjectionNode>;
/**
* Layout projection attachment factory
* Returns an attachment function that handles layout animations
*/
export declare const layout: ({ layoutId, track, animationConfig }: {
layoutId?: string;
track: () => any;
animationConfig?: AnimationConfig;
}) => (element: HTMLElement) => () => void;