{"version":3,"file":"types.mjs","sources":["../../../src/lib/hydration/types.ts"],"sourcesContent":["/**\n * @file Hydration System Types\n * @description Comprehensive TypeScript types for the Auto-Prioritized Hydration System.\n *\n * This module defines the type contracts for:\n * - Priority levels and hydration triggers\n * - Hydration state machine states\n * - Scheduler configuration and tasks\n * - Performance metrics and telemetry\n * - Component boundary configuration\n * - Interaction replay buffers\n *\n * @module hydration/types\n */\n\nimport type { ReactNode, ComponentType, CSSProperties } from 'react';\n\n// ============================================================================\n// Priority System Types\n// ============================================================================\n\n/**\n * Hydration priority levels ordered from highest to lowest urgency.\n *\n * - `critical`: Must hydrate immediately (above-the-fold, interactive elements)\n * - `high`: Should hydrate soon (visible in viewport, likely to be interacted with)\n * - `normal`: Standard priority (visible or about to become visible)\n * - `low`: Can be deferred (below-the-fold, secondary content)\n * - `idle`: Only hydrate when browser is idle (footer, non-essential widgets)\n */\nexport type HydrationPriority = 'critical' | 'high' | 'normal' | 'low' | 'idle';\n\n/**\n * Numeric mapping for priority comparison and queue ordering.\n * Lower numbers indicate higher priority.\n */\nexport const PRIORITY_WEIGHTS: Record<HydrationPriority, number> = {\n  critical: 0,\n  high: 1,\n  normal: 2,\n  low: 3,\n  idle: 4,\n} as const;\n\n/**\n * Hydration triggers that determine when a component should hydrate.\n *\n * - `immediate`: Hydrate as soon as possible\n * - `visible`: Hydrate when component enters viewport\n * - `interaction`: Hydrate on user interaction (click, focus, hover)\n * - `idle`: Hydrate during browser idle time\n * - `manual`: Explicit programmatic hydration control\n * - `media`: Hydrate based on media query match\n */\nexport type HydrationTrigger =\n  | 'immediate'\n  | 'visible'\n  | 'interaction'\n  | 'idle'\n  | 'manual'\n  | 'media';\n\n// ============================================================================\n// Hydration State Machine Types\n// ============================================================================\n\n/**\n * Possible states in the hydration lifecycle.\n *\n * State transitions:\n * - pending -> hydrating -> hydrated\n * - pending -> hydrating -> error\n * - pending -> skipped (SSR-only component)\n */\nexport type HydrationState = 'pending' | 'hydrating' | 'hydrated' | 'error' | 'skipped';\n\n/**\n * Detailed hydration status with timing information.\n */\nexport interface HydrationStatus {\n  /** Current hydration state */\n  readonly state: HydrationState;\n  /** Timestamp when hydration started (if applicable) */\n  readonly startedAt: number | null;\n  /** Timestamp when hydration completed (if applicable) */\n  readonly completedAt: number | null;\n  /** Duration of hydration in milliseconds */\n  readonly duration: number | null;\n  /** Error that occurred during hydration (if applicable) */\n  readonly error: Error | null;\n  /** Number of hydration attempts (for retry logic) */\n  readonly attempts: number;\n  /** Whether this was a replay-triggered hydration */\n  readonly triggeredByReplay: boolean;\n}\n\n/**\n * Factory for creating initial hydration status.\n */\nexport function createInitialHydrationStatus(): HydrationStatus {\n  return {\n    state: 'pending',\n    startedAt: null,\n    completedAt: null,\n    duration: null,\n    error: null,\n    attempts: 0,\n    triggeredByReplay: false,\n  };\n}\n\n// ============================================================================\n// Hydration Task Types\n// ============================================================================\n\n/**\n * Unique identifier for hydration boundaries.\n */\nexport type HydrationBoundaryId = string & { readonly __brand: 'HydrationBoundaryId' };\n\n/**\n * Creates a branded hydration boundary ID.\n */\nexport function createBoundaryId(id: string): HydrationBoundaryId {\n  return id as HydrationBoundaryId;\n}\n\n/**\n * Represents a single hydration task in the scheduler queue.\n */\nexport interface HydrationTask {\n  /** Unique identifier for this hydration boundary */\n  readonly id: HydrationBoundaryId;\n  /** Priority level determining queue position */\n  readonly priority: HydrationPriority;\n  /** What triggers hydration */\n  readonly trigger: HydrationTrigger;\n  /** Function to execute hydration */\n  readonly hydrate: () => Promise<void>;\n  /** Callback when hydration completes successfully */\n  readonly onHydrated?: () => void;\n  /** Callback when hydration fails */\n  readonly onError?: (error: Error) => void;\n  /** Timestamp when task was enqueued */\n  readonly enqueuedAt: number;\n  /** DOM element reference for visibility tracking */\n  readonly element?: HTMLElement | null;\n  /** Estimated hydration cost in milliseconds (for budget management) */\n  readonly estimatedCost?: number;\n  /** Maximum time to wait before hydration (timeout) */\n  readonly timeout?: number;\n  /** Whether this task can be cancelled */\n  readonly cancellable?: boolean;\n  /** Metadata for debugging and telemetry */\n  readonly metadata?: HydrationTaskMetadata;\n}\n\n/**\n * Optional metadata attached to hydration tasks.\n */\nexport interface HydrationTaskMetadata {\n  /** Component display name */\n  readonly componentName?: string;\n  /** Route path where component is rendered */\n  readonly routePath?: string;\n  /** Whether component is above the fold */\n  readonly aboveTheFold?: boolean;\n  /** Parent boundary ID for hierarchical tracking */\n  readonly parentBoundaryId?: HydrationBoundaryId;\n  /** Custom tags for filtering metrics */\n  readonly tags?: readonly string[];\n}\n\n// ============================================================================\n// Scheduler Configuration Types\n// ============================================================================\n\n/**\n * Budget configuration for the hydration scheduler.\n * Prevents main thread blocking during hydration.\n */\nexport interface HydrationBudget {\n  /** Maximum time per hydration frame in milliseconds (default: 50ms for 60fps) */\n  readonly frameTimeLimit: number;\n  /** Maximum number of tasks to process per frame */\n  readonly maxTasksPerFrame: number;\n  /** Minimum idle time required for background hydration */\n  readonly minIdleTime: number;\n  /** Whether to yield to more important work */\n  readonly yieldToMain: boolean;\n}\n\n/**\n * Default hydration budget optimized for 60fps.\n */\nexport const DEFAULT_HYDRATION_BUDGET: HydrationBudget = {\n  frameTimeLimit: 50, // 50ms per frame leaves room for other work\n  maxTasksPerFrame: 10, // Process up to 10 small components per frame\n  minIdleTime: 100, // Require 100ms idle for background hydration\n  yieldToMain: true, // Always yield to user input\n} as const;\n\n/**\n * Visibility detection configuration using IntersectionObserver.\n */\nexport interface VisibilityConfig {\n  /** Root element for intersection calculation (null = viewport) */\n  readonly root?: Element | null;\n  /** Margin around root for intersection calculation */\n  readonly rootMargin?: string;\n  /** Visibility threshold(s) for triggering hydration */\n  readonly threshold?: number | readonly number[];\n  /** Whether to disconnect observer after first intersection */\n  readonly triggerOnce?: boolean;\n}\n\n/**\n * Default visibility configuration with reasonable margins.\n */\nexport const DEFAULT_VISIBILITY_CONFIG: VisibilityConfig = {\n  root: null,\n  rootMargin: '100px 0px', // Hydrate slightly before entering viewport\n  threshold: 0,\n  triggerOnce: true,\n} as const;\n\n/**\n * Configuration for the hydration scheduler.\n */\nexport interface HydrationSchedulerConfig {\n  /** Hydration budget configuration */\n  readonly budget: HydrationBudget;\n  /** Visibility detection configuration */\n  readonly visibility: VisibilityConfig;\n  /** Enable debug logging */\n  readonly debug: boolean;\n  /** Strategy for handling interactions during hydration */\n  readonly interactionStrategy: InteractionStrategy;\n  /** Whether to use requestIdleCallback for idle hydration */\n  readonly useIdleCallback: boolean;\n  /** Maximum queue size before dropping low-priority tasks */\n  readonly maxQueueSize: number;\n  /** Timeout for stalled tasks in milliseconds */\n  readonly taskTimeout: number;\n  /** Whether to collect performance metrics */\n  readonly collectMetrics: boolean;\n  /** Sample rate for metrics collection (0-1) */\n  readonly metricsSampleRate: number;\n}\n\n/**\n * Strategy for handling user interactions during hydration.\n */\nexport type InteractionStrategy =\n  | 'replay' // Buffer and replay interactions after hydration\n  | 'immediate-hydrate' // Immediately hydrate on any interaction\n  | 'block' // Block interaction until hydrated (not recommended)\n  | 'passthrough'; // Allow interaction to propagate (may cause issues)\n\n/**\n * Default scheduler configuration.\n */\nexport const DEFAULT_SCHEDULER_CONFIG: HydrationSchedulerConfig = {\n  budget: DEFAULT_HYDRATION_BUDGET,\n  visibility: DEFAULT_VISIBILITY_CONFIG,\n  debug: false,\n  interactionStrategy: 'replay',\n  useIdleCallback: true,\n  maxQueueSize: 1000,\n  taskTimeout: 10000,\n  collectMetrics: true,\n  metricsSampleRate: 1.0,\n} as const;\n\n// ============================================================================\n// Hydration Metrics Types\n// ============================================================================\n\n/**\n * Performance metrics for a single hydration operation.\n */\nexport interface HydrationMetric {\n  /** Boundary ID that was hydrated */\n  readonly boundaryId: HydrationBoundaryId;\n  /** Component name (if available) */\n  readonly componentName?: string;\n  /** Priority at time of hydration */\n  readonly priority: HydrationPriority;\n  /** What triggered hydration */\n  readonly trigger: HydrationTrigger;\n  /** Time spent waiting in queue */\n  readonly queueDuration: number;\n  /** Time spent hydrating */\n  readonly hydrationDuration: number;\n  /** Total time from enqueue to hydrated */\n  readonly totalDuration: number;\n  /** Whether hydration was successful */\n  readonly success: boolean;\n  /** Error message if hydration failed */\n  readonly errorMessage?: string;\n  /** Number of interactions replayed */\n  readonly replayedInteractions: number;\n  /** Timestamp of metric collection */\n  readonly timestamp: number;\n}\n\n/**\n * Aggregated hydration metrics for the session.\n */\nexport interface HydrationMetricsSnapshot {\n  /** Total boundaries registered */\n  readonly totalBoundaries: number;\n  /** Boundaries successfully hydrated */\n  readonly hydratedCount: number;\n  /** Boundaries pending hydration */\n  readonly pendingCount: number;\n  /** Boundaries that failed hydration */\n  readonly failedCount: number;\n  /** Average hydration duration in milliseconds */\n  readonly averageHydrationDuration: number;\n  /** 95th percentile hydration duration */\n  readonly p95HydrationDuration: number;\n  /** Total interactions replayed */\n  readonly totalReplayedInteractions: number;\n  /** Time to full hydration (all boundaries) in milliseconds */\n  readonly timeToFullHydration: number | null;\n  /** Time to above-the-fold hydration */\n  readonly timeToAboveFoldHydration: number | null;\n  /** Current queue size */\n  readonly queueSize: number;\n  /** Snapshot timestamp */\n  readonly timestamp: number;\n}\n\n/**\n * Metrics reporter callback type.\n */\nexport type HydrationMetricsReporter = (\n  metric: HydrationMetric,\n  snapshot: HydrationMetricsSnapshot\n) => void;\n\n// ============================================================================\n// Interaction Replay Types\n// ============================================================================\n\n/**\n * Types of interactions that can be replayed.\n */\nexport type ReplayableInteractionType =\n  | 'click'\n  | 'focus'\n  | 'input'\n  | 'keydown'\n  | 'keyup'\n  | 'submit'\n  | 'change'\n  | 'touchstart'\n  | 'touchend';\n\n/**\n * Captured interaction for replay after hydration.\n */\nexport interface CapturedInteraction {\n  /** Unique interaction ID */\n  readonly id: string;\n  /** Type of interaction */\n  readonly type: ReplayableInteractionType;\n  /** Target element selector for re-targeting */\n  readonly targetSelector: string;\n  /** Original event properties to replay */\n  readonly eventInit: Partial<EventInit>;\n  /** Timestamp when interaction occurred */\n  readonly capturedAt: number;\n  /** Input value at time of capture (for input events) */\n  readonly inputValue?: string;\n  /** Key information (for keyboard events) */\n  readonly keyInfo?: {\n    readonly key: string;\n    readonly code: string;\n    readonly shiftKey: boolean;\n    readonly ctrlKey: boolean;\n    readonly altKey: boolean;\n    readonly metaKey: boolean;\n  };\n  /** Pointer position (for click/touch events) */\n  readonly pointerPosition?: {\n    readonly clientX: number;\n    readonly clientY: number;\n  };\n}\n\n/**\n * Configuration for interaction replay.\n */\nexport interface InteractionReplayConfig {\n  /** Maximum time to buffer interactions before discarding */\n  readonly maxBufferTime: number;\n  /** Maximum number of interactions to buffer */\n  readonly maxBufferSize: number;\n  /** Delay between replayed events in milliseconds */\n  readonly replayDelay: number;\n  /** Event types to capture for replay */\n  readonly captureTypes: readonly ReplayableInteractionType[];\n  /** Whether to prevent default during capture */\n  readonly preventDefaultDuringCapture: boolean;\n  /** Whether to show visual feedback during capture */\n  readonly showCaptureIndicator: boolean;\n}\n\n/**\n * Default interaction replay configuration.\n */\nexport const DEFAULT_REPLAY_CONFIG: InteractionReplayConfig = {\n  maxBufferTime: 5000,\n  maxBufferSize: 50,\n  replayDelay: 10,\n  captureTypes: ['click', 'focus', 'input', 'change', 'submit'],\n  preventDefaultDuringCapture: true,\n  showCaptureIndicator: false,\n} as const;\n\n// ============================================================================\n// Component Types\n// ============================================================================\n\n/**\n * Props for the HydrationBoundary component.\n */\nexport interface HydrationBoundaryProps {\n  /** Unique identifier for this boundary */\n  readonly id?: string;\n  /** Child components to hydrate */\n  readonly children: ReactNode;\n  /** Priority level for hydration scheduling */\n  readonly priority?: HydrationPriority;\n  /** What triggers hydration */\n  readonly trigger?: HydrationTrigger;\n  /** Placeholder to show before hydration */\n  readonly placeholder?: ReactNode;\n  /** Component to show if hydration fails */\n  readonly errorFallback?: ReactNode | ((error: Error) => ReactNode);\n  /** Callback when hydration starts */\n  readonly onHydrationStart?: () => void;\n  /** Callback when hydration completes */\n  readonly onHydrationComplete?: (duration: number) => void;\n  /** Callback when hydration fails */\n  readonly onHydrationError?: (error: Error) => void;\n  /** Whether to skip hydration entirely (SSR-only) */\n  readonly ssrOnly?: boolean;\n  /** Custom visibility configuration */\n  readonly visibilityConfig?: Partial<VisibilityConfig>;\n  /** Media query for media-triggered hydration */\n  readonly mediaQuery?: string;\n  /** Timeout for hydration in milliseconds */\n  readonly timeout?: number;\n  /** Estimated hydration cost for budget management */\n  readonly estimatedCost?: number;\n  /** Whether this component is above the fold */\n  readonly aboveTheFold?: boolean;\n  /** Additional CSS class for the wrapper */\n  readonly className?: string;\n  /** Additional styles for the wrapper */\n  readonly style?: CSSProperties;\n}\n\n/**\n * Props for the HydrationProvider component.\n */\nexport interface HydrationProviderProps {\n  /** Child components */\n  readonly children: ReactNode;\n  /** Scheduler configuration */\n  readonly config?: Partial<HydrationSchedulerConfig>;\n  /** Callback for metrics reporting */\n  readonly onMetric?: HydrationMetricsReporter;\n  /** Whether to auto-start the scheduler */\n  readonly autoStart?: boolean;\n  /** Whether to integrate with performance monitoring */\n  readonly integrateWithPerformance?: boolean;\n}\n\n// ============================================================================\n// Context Types\n// ============================================================================\n\n/**\n * Value provided by the HydrationContext.\n */\nexport interface HydrationContextValue {\n  /** Register a new hydration boundary */\n  readonly registerBoundary: (task: HydrationTask) => void;\n  /** Unregister a hydration boundary */\n  readonly unregisterBoundary: (id: HydrationBoundaryId) => void;\n  /** Get current status of a boundary */\n  readonly getBoundaryStatus: (id: HydrationBoundaryId) => HydrationStatus | undefined;\n  /** Update priority of a boundary */\n  readonly updatePriority: (id: HydrationBoundaryId, priority: HydrationPriority) => void;\n  /** Force immediate hydration of a boundary */\n  readonly forceHydrate: (id: HydrationBoundaryId) => Promise<void>;\n  /** Force hydration of all boundaries */\n  readonly forceHydrateAll: () => Promise<void>;\n  /** Pause hydration scheduling */\n  readonly pause: () => void;\n  /** Resume hydration scheduling */\n  readonly resume: () => void;\n  /** Check if scheduler is paused */\n  readonly isPaused: boolean;\n  /** Get current metrics snapshot */\n  readonly getMetrics: () => HydrationMetricsSnapshot;\n  /** Current configuration */\n  readonly config: HydrationSchedulerConfig;\n  /** Whether system has initialized */\n  readonly isInitialized: boolean;\n}\n\n// ============================================================================\n// HOC Types\n// ============================================================================\n\n/**\n * Options for the withHydrationBoundary HOC.\n */\nexport interface WithHydrationBoundaryOptions<P = unknown> {\n  /** Display name for the wrapped component */\n  readonly displayName?: string;\n  /** Default priority for the boundary */\n  readonly defaultPriority?: HydrationPriority;\n  /** Default trigger for the boundary */\n  readonly defaultTrigger?: HydrationTrigger;\n  /** Placeholder to show before hydration */\n  readonly placeholder?: ReactNode | ((props: P) => ReactNode);\n  /** Whether component is above the fold */\n  readonly aboveTheFold?: boolean;\n  /** Estimated hydration cost */\n  readonly estimatedCost?: number;\n}\n\n/**\n * Higher-order component type for hydration boundaries.\n */\nexport type WithHydrationBoundary = <P extends object>(\n  Component: ComponentType<P>,\n  options?: WithHydrationBoundaryOptions<P>\n) => ComponentType<P & Partial<HydrationBoundaryProps>>;\n\n// ============================================================================\n// Event Types\n// ============================================================================\n\n/**\n * Events emitted by the hydration system.\n */\nexport type HydrationEventType =\n  | 'boundary:registered'\n  | 'boundary:unregistered'\n  | 'hydration:start'\n  | 'hydration:complete'\n  | 'hydration:error'\n  | 'scheduler:paused'\n  | 'scheduler:resumed'\n  | 'interaction:captured'\n  | 'interaction:replayed'\n  | 'queue:overflow';\n\n/**\n * Base hydration event structure.\n */\nexport interface HydrationEvent {\n  readonly type: HydrationEventType;\n  readonly timestamp: number;\n  readonly boundaryId?: HydrationBoundaryId;\n  readonly payload?: unknown;\n}\n\n/**\n * Event listener for hydration events.\n */\nexport type HydrationEventListener = (event: HydrationEvent) => void;\n\n// ============================================================================\n// Utility Types\n// ============================================================================\n\n/**\n * Partial configuration that can be merged with defaults.\n */\nexport type PartialHydrationConfig = Partial<{\n  budget: Partial<HydrationBudget>;\n  visibility: Partial<VisibilityConfig>;\n  debug: boolean;\n  interactionStrategy: InteractionStrategy;\n  useIdleCallback: boolean;\n  maxQueueSize: number;\n  taskTimeout: number;\n  collectMetrics: boolean;\n  metricsSampleRate: number;\n}>;\n\n/**\n * Deep merge configuration with defaults.\n */\nexport function mergeWithDefaults(partial: PartialHydrationConfig = {}): HydrationSchedulerConfig {\n  return {\n    budget: {\n      ...DEFAULT_HYDRATION_BUDGET,\n      ...partial.budget,\n    },\n    visibility: {\n      ...DEFAULT_VISIBILITY_CONFIG,\n      ...partial.visibility,\n    },\n    debug: partial.debug ?? DEFAULT_SCHEDULER_CONFIG.debug,\n    interactionStrategy:\n      partial.interactionStrategy ?? DEFAULT_SCHEDULER_CONFIG.interactionStrategy,\n    useIdleCallback: partial.useIdleCallback ?? DEFAULT_SCHEDULER_CONFIG.useIdleCallback,\n    maxQueueSize: partial.maxQueueSize ?? DEFAULT_SCHEDULER_CONFIG.maxQueueSize,\n    taskTimeout: partial.taskTimeout ?? DEFAULT_SCHEDULER_CONFIG.taskTimeout,\n    collectMetrics: partial.collectMetrics ?? DEFAULT_SCHEDULER_CONFIG.collectMetrics,\n    metricsSampleRate: partial.metricsSampleRate ?? DEFAULT_SCHEDULER_CONFIG.metricsSampleRate,\n  };\n}\n\n/**\n * Type guard to check if a value is a valid hydration priority.\n */\nexport function isHydrationPriority(value: unknown): value is HydrationPriority {\n  return typeof value === 'string' && ['critical', 'high', 'normal', 'low', 'idle'].includes(value);\n}\n\n/**\n * Type guard to check if a value is a valid hydration trigger.\n */\nexport function isHydrationTrigger(value: unknown): value is HydrationTrigger {\n  return (\n    typeof value === 'string' &&\n    ['immediate', 'visible', 'interaction', 'idle', 'manual', 'media'].includes(value)\n  );\n}\n\n/**\n * Type guard to check if a value is a valid hydration state.\n */\nexport function isHydrationState(value: unknown): value is HydrationState {\n  return (\n    typeof value === 'string' &&\n    ['pending', 'hydrating', 'hydrated', 'error', 'skipped'].includes(value)\n  );\n}\n"],"names":["PRIORITY_WEIGHTS","createInitialHydrationStatus","createBoundaryId","id","DEFAULT_HYDRATION_BUDGET","DEFAULT_VISIBILITY_CONFIG","DEFAULT_SCHEDULER_CONFIG","DEFAULT_REPLAY_CONFIG","mergeWithDefaults","partial","isHydrationPriority","value","isHydrationTrigger","isHydrationState"],"mappings":"AAoCO,MAAMA,IAAsD;AAAA,EACjE,UAAU;AAAA,EACV,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,KAAK;AAAA,EACL,MAAM;AACR;AAyDO,SAASC,IAAgD;AAC9D,SAAO;AAAA,IACL,OAAO;AAAA,IACP,WAAW;AAAA,IACX,aAAa;AAAA,IACb,UAAU;AAAA,IACV,OAAO;AAAA,IACP,UAAU;AAAA,IACV,mBAAmB;AAAA,EAAA;AAEvB;AAcO,SAASC,EAAiBC,GAAiC;AAChE,SAAOA;AACT;AAsEO,MAAMC,IAA4C;AAAA,EACvD,gBAAgB;AAAA;AAAA,EAChB,kBAAkB;AAAA;AAAA,EAClB,aAAa;AAAA;AAAA,EACb,aAAa;AAAA;AACf,GAmBaC,IAA8C;AAAA,EACzD,MAAM;AAAA,EACN,YAAY;AAAA;AAAA,EACZ,WAAW;AAAA,EACX,aAAa;AACf,GAsCaC,IAAqD;AAAA,EAChE,QAAQF;AAAA,EACR,YAAYC;AAAA,EACZ,OAAO;AAAA,EACP,qBAAqB;AAAA,EACrB,iBAAiB;AAAA,EACjB,cAAc;AAAA,EACd,aAAa;AAAA,EACb,gBAAgB;AAAA,EAChB,mBAAmB;AACrB,GA6IaE,IAAiD;AAAA,EAC5D,eAAe;AAAA,EACf,eAAe;AAAA,EACf,aAAa;AAAA,EACb,cAAc,CAAC,SAAS,SAAS,SAAS,UAAU,QAAQ;AAAA,EAC5D,6BAA6B;AAAA,EAC7B,sBAAsB;AACxB;AAsLO,SAASC,EAAkBC,IAAkC,IAA8B;AAChG,SAAO;AAAA,IACL,QAAQ;AAAA,MACN,GAAGL;AAAA,MACH,GAAGK,EAAQ;AAAA,IAAA;AAAA,IAEb,YAAY;AAAA,MACV,GAAGJ;AAAA,MACH,GAAGI,EAAQ;AAAA,IAAA;AAAA,IAEb,OAAOA,EAAQ,SAASH,EAAyB;AAAA,IACjD,qBACEG,EAAQ,uBAAuBH,EAAyB;AAAA,IAC1D,iBAAiBG,EAAQ,mBAAmBH,EAAyB;AAAA,IACrE,cAAcG,EAAQ,gBAAgBH,EAAyB;AAAA,IAC/D,aAAaG,EAAQ,eAAeH,EAAyB;AAAA,IAC7D,gBAAgBG,EAAQ,kBAAkBH,EAAyB;AAAA,IACnE,mBAAmBG,EAAQ,qBAAqBH,EAAyB;AAAA,EAAA;AAE7E;AAKO,SAASI,EAAoBC,GAA4C;AAC9E,SAAO,OAAOA,KAAU,YAAY,CAAC,YAAY,QAAQ,UAAU,OAAO,MAAM,EAAE,SAASA,CAAK;AAClG;AAKO,SAASC,EAAmBD,GAA2C;AAC5E,SACE,OAAOA,KAAU,YACjB,CAAC,aAAa,WAAW,eAAe,QAAQ,UAAU,OAAO,EAAE,SAASA,CAAK;AAErF;AAKO,SAASE,EAAiBF,GAAyC;AACxE,SACE,OAAOA,KAAU,YACjB,CAAC,WAAW,aAAa,YAAY,SAAS,SAAS,EAAE,SAASA,CAAK;AAE3E;"}