Package-level declarations

Types

Link copied to clipboard
external interface ArrowOptions
Link copied to clipboard
Link copied to clipboard
external interface UseFloatingOptions<R : ReferenceElement>
Link copied to clipboard

Functions

Link copied to clipboard
external fun arrow(options: ArrowOptions, dependencies: DependencyList = definedExternally): Middleware

Provides data to position an inner element of the floating element so that it appears centered to the reference element. This wraps the core arrow middleware to allow React refs as the element.

Link copied to clipboard
external fun autoPlacement(options: AutoPlacementOptions, dependencies: DependencyList = definedExternally): Middleware

Optimizes the visibility of the floating element by choosing the placement that has the most space available automatically, without needing to specify a preferred placement. Alternative to flip. API Docs

Link copied to clipboard
external fun offset(value: OffsetOptions, dependencies: DependencyList = definedExternally): Middleware

external fun offset(value: Double, dependencies: DependencyList = definedExternally): Middleware

Modifies the placement by translating the floating element along the specified axes. A number (shorthand for mainAxis or distance), or an axes configuration object may be passed.

Link copied to clipboard
external fun shift(options: ShiftOptions, dependencies: DependencyList = definedExternally): Middleware

Optimizes the visibility of the floating element by shifting it in order to keep it in view when it will overflow the clipping boundary. API Docs

Link copied to clipboard
external fun <R : VirtualElement> useFloating(options: UseFloatingOptions<R> = definedExternally): UseFloatingReturn<R>

Provides data to position a floating element. API Docs

external fun <R : Element> useFloating(options: UseFloatingOptions<R> = definedExternally): UseFloatingReturn<R>