{"version":3,"file":"useTimelineScrollLeft.mjs","names":[],"sources":["../../../src/hooks/viewport/useTimelineScrollLeft.ts"],"sourcesContent":["import type { TimelineEngine } from '@techsquidtv/canvas-timeline-core';\nimport { useTimelineExternalStore } from '#react/hooks/core/useTimelineExternalStore';\n\nconst scrollLeftEvents = ['scroll:change', 'render'] as const;\nconst getTimelineScrollLeft = (engine: TimelineEngine) => engine.scrollLeft;\n\n/**\n * Hook to subscribe directly to scroll left position changes.\n * Bypasses root-level context state updates for smooth scroll navigation.\n *\n * @returns The current scroll left offset in pixels.\n */\nexport function useTimelineScrollLeft(): number {\n  return useTimelineExternalStore(scrollLeftEvents, getTimelineScrollLeft);\n}\n"],"mappings":";;AAGA,MAAM,mBAAmB,CAAC,iBAAiB,QAAQ;AACnD,MAAM,yBAAyB,WAA2B,OAAO;;;;;;;AAQjE,SAAgB,wBAAgC;CAC9C,OAAO,yBAAyB,kBAAkB,qBAAqB;AACzE"}