@fluritheme/fluri
Version:
Interactive snowfall for websites: DOM-aware snow accumulation, mouse interactions, snow physics, Canvas 2D rendering, and Christmas effects.
46 lines • 1.5 kB
TypeScript
import type { Surface, SurfaceOptions, WeatherConfig, WeatherEventName } from '../types.js';
export declare class SurfaceRegistry {
private root;
private config;
private emit;
private shed;
private onInvalidate?;
readonly surfaces: Surface[];
private registered;
private excluded;
private dirty;
private observer;
private resizeObserver;
private nextId;
private transforms;
private scrollOffsets;
private positionModes;
private scrollChains;
private lastTime;
private lastSurfaceEvents;
private lastScan;
private occlusionCursor;
private lastOcclusion;
private clipsDirty;
geometryScanTime: number;
constructor(root: HTMLElement, config: () => WeatherConfig, emit: (name: WeatherEventName, data: unknown) => void, shed: (surface: Surface, reason?: 'removed' | 'resize') => void, onInvalidate?: (() => void) | undefined);
start(): void;
refreshObservers(): void;
invalidate(): void;
invalidateGeometry(): void;
register(element: Element, options?: SurfaceOptions): () => void;
unregister(element: Element): void;
update(time: number, physicalMotion?: boolean): void;
private resizeProfile;
private scan;
private updateOcclusion;
private packing;
private cacheScrollChain;
private scrollPosition;
private readOptions;
private measure;
private clips;
private paintOrder;
destroy(): void;
}
//# sourceMappingURL=SurfaceRegistry.d.ts.map