// ============================================================================ // Stylescape | Lazy Load Manager // ============================================================================ // Manages lazy loading of images and content using Intersection Observer. // Supports data-ss="lazy" and data-src attributes for declarative configuration. // ============================================================================ /** * Configuration options for LazyLoadManager */ export interface LazyLoadManagerOptions { /** Root margin for intersection observer */ rootMargin?: string; /** Threshold for visibility (0-1) */ threshold?: number; /** Attribute containing the real source */ srcAttribute?: string; /** CSS class added when loaded */ loadedClass?: string; /** Callback when item loads */ onLoad?: (element: HTMLElement) => void; } /** What the constructor accepts: a selector, one element or a collection. */ export type LazyLoadTarget = string | HTMLElement | NodeListOf | HTMLElement[]; /** * Lazy load manager using Intersection Observer API. * Defers loading of images until they enter the viewport. * * ``, `