UNPKG

@werk1/w1-system-videoblock

Version:

Universal video player supporting YouTube, Vimeo, HLS, DASH with coordination and GSAP integration for W1 System

22 lines (21 loc) 703 B
/** * Video Format Detection Utilities * Automatically detects video format based on URL patterns and file extensions */ export type VideoFormat = "youtube" | "vimeo" | "hls" | "dash" | "progressive"; /** * Detects video format from URL */ export declare function detectVideoFormat(src: string): VideoFormat; /** * Extracts YouTube video ID from various YouTube URL formats */ export declare function extractYouTubeId(url: string): string | null; /** * Extracts Vimeo video ID from various Vimeo URL formats */ export declare function extractVimeoId(url: string): string | null; /** * Checks if URL is a valid video source */ export declare function isValidVideoSource(src: string): boolean;