/** * @fileoverview Device Detection - Utilities for detecting device capabilities * * Provides utilities for detecting device type, screen size, touch support, * and other device-specific features to enable adaptive UI. * * @module @vowel.to/client/utils * @author vowel.to * @license Proprietary */ /** * Device type classification */ export type DeviceType = 'mobile' | 'tablet' | 'desktop'; /** * Device capabilities */ export interface DeviceCapabilities { /** Device type (mobile, tablet, desktop) */ type: DeviceType; /** Whether the device has touch support */ hasTouch: boolean; /** Screen width in pixels */ screenWidth: number; /** Screen height in pixels */ screenHeight: number; /** Device pixel ratio */ pixelRatio: number; /** Whether the device is in portrait orientation */ isPortrait: boolean; /** Whether the device is in landscape orientation */ isLandscape: boolean; /** Whether the browser is in standalone/PWA mode */ isStandalone: boolean; /** User agent string */ userAgent: string; /** Whether running on iOS */ isIOS: boolean; /** Whether running on Android */ isAndroid: boolean; /** Whether running on macOS */ isMacOS: boolean; /** Whether running on Windows */ isWindows: boolean; } /** * Detect device type based on screen width and user agent */ export declare function getDeviceType(): DeviceType; /** * Detect if device has touch support */ export declare function hasTouchSupport(): boolean; /** * Detect device orientation */ export declare function getOrientation(): 'portrait' | 'landscape'; /** * Detect if running in standalone/PWA mode */ export declare function isStandalone(): boolean; /** * Detect operating system */ export declare function getOperatingSystem(): string; /** * Get comprehensive device capabilities */ export declare function getDeviceCapabilities(): DeviceCapabilities; /** * Check if device is mobile (phone) */ export declare function isMobile(): boolean; /** * Check if device is tablet */ export declare function isTablet(): boolean; /** * Check if device is desktop */ export declare function isDesktop(): boolean; /** * Check if device is mobile or tablet (any touch device) */ export declare function isMobileOrTablet(): boolean; /** * Listen for device capability changes (orientation, resize) */ export declare function onDeviceChange(callback: (capabilities: DeviceCapabilities) => void): () => void; /** * Get safe area insets (for devices with notches, etc.) */ export declare function getSafeAreaInsets(): { top: number; right: number; bottom: number; left: number; }; /** * Check if device prefers reduced motion */ export declare function prefersReducedMotion(): boolean; /** * Check if device prefers dark mode */ export declare function prefersDarkMode(): boolean; //# sourceMappingURL=device-detection.d.ts.map