export type UseBackendOptions = {
    placement: Placement
    rtlAware: boolean
    offset: Offset
    boundary?: Boundary
    onCalculateLayout?: OnCalculateLayout
};
export type Placement = `${Exclude<HorizontalPlacement, 'center'>}-${VerticalPlacement}` | `${Exclude<VerticalPlacement, 'center'>}-${HorizontalPlacement}`;
type HorizontalPlacement = 'start' | 'center' | 'end';
type VerticalPlacement = 'top' | 'center' | 'bottom';
export type Offset = {
    main: number;
    cross: number;
};
export type Boundary = 'viewport' | HTMLElement;
export type OnCalculateLayout = (options: OnCalculateLayoutOptions) => void;
export type OnCalculateLayoutOptions = {
    reference: Rect;
    content: Rect;
    available: {
        height: number;
        width: number;
    };
};
export type Rect = {
    top: number;
    left: number;
    width: number;
    height: number;
};
export type Backend = {
    setReference: (reference: Reference | null) => void
    contentProps: ElementProps<Content>
    setArrow: (arrow: Arrow | null) => void
    update: () => void
};
type ElementProps<T> = Omit<Partial<React.HTMLProps<T>>, 'ref'> & {
    ref: (value: T | null) => void;
};
export type Reference = HTMLElement | ReferenceObject;
export type Content = HTMLElement;
export type Arrow = HTMLElement;
export type ReferenceObject = {
    getBoundingClientRect(): DOMRect;
};
export declare function isReferenceObject<T>(reference: T | ReferenceObject): reference is ReferenceObject;
export type UseBackend = (options: UseBackendOptions) => Backend;
export declare const useBackend: UseBackend;
export {};
