{"version":3,"file":"FloatingWindow.context.mjs","names":[],"sources":["../../../src/components/FloatingWindow/FloatingWindow.context.ts"],"sourcesContent":["import { createSafeContext } from '../../core';\n\nexport interface FloatingWindowDimensions {\n  /** Initial width of the floating window in px */\n  initialWidth?: number;\n\n  /** Minimum width of the floating window in px */\n  minWidth?: number;\n\n  /** Maximum width of the floating window in px */\n  maxWidth?: number;\n\n  /** Initial height of the floating window in px */\n  initialHeight?: number;\n\n  /** Minimum height of the floating window in px */\n  minHeight?: number;\n\n  /** Maximum height of the floating window in px */\n  maxHeight?: number;\n}\n\nexport interface FloatingWindowSize {\n  /** Width of the floating window in px */\n  width: number;\n\n  /** Height of the floating window in px */\n  height: number;\n}\n\nexport interface FloatingWindowContextValue {\n  rootRef: React.RefObject<HTMLDivElement | null>;\n  dimensions: FloatingWindowDimensions | undefined;\n  constrainToViewport: boolean | undefined;\n  constrainOffset: number | undefined;\n  onResizeStart: (() => void) | undefined;\n  onResizeEnd: (() => void) | undefined;\n  onSizeChange: ((size: FloatingWindowSize) => void) | undefined;\n}\n\nexport const [FloatingWindowProvider, useFloatingWindowContext] =\n  createSafeContext<FloatingWindowContextValue>(\n    'FloatingWindow.ResizeHandle must be used within FloatingWindow'\n  );\n"],"mappings":";;;AAwCA,MAAa,CAAC,wBAAwB,4BACpC,kBACE,gEACF"}