Skip to content

Latest commit

 

History

History
76 lines (59 loc) · 2.19 KB

File metadata and controls

76 lines (59 loc) · 2.19 KB

API Report File for "@fluentui/react-headless-components-preview"

Do not edit this file. It is a report generated by API Extractor.

import type * as React_2 from 'react';

// @public (undocumented)
export type Alignment = 'top' | 'bottom' | 'start' | 'end' | 'center';

// @public (undocumented)
export const ALIGNMENTS: {
    readonly start: "start";
    readonly center: "center";
    readonly end: "end";
};

// @public
export function getPlacementString(position: Position, align: LogicalAlignment): string;

// @public (undocumented)
export type Position = 'above' | 'below' | 'before' | 'after';

// @public
export type PositioningImperativeRef = {
    setTarget: (target: HTMLElement | null) => void;
    updatePosition: () => void;
};

// @public (undocumented)
export type PositioningProps = {
    position?: Position;
    align?: Alignment;
    offset?: number | {
        mainAxis?: number;
        crossAxis?: number;
    };
    fallbackPositions?: PositioningShorthandValue[];
    coverTarget?: boolean;
    target?: HTMLElement | React_2.RefObject<HTMLElement | null> | null;
    strategy?: 'absolute' | 'fixed';
    matchTargetSize?: 'width';
    pinned?: boolean;
    positioningRef?: React_2.Ref<PositioningImperativeRef>;
};

// @public (undocumented)
export type PositioningReturn = {
    targetRef: React_2.RefCallback<HTMLElement>;
    containerRef: React_2.RefCallback<HTMLElement>;
};

// @public (undocumented)
export type PositioningShorthand = PositioningProps | PositioningShorthandValue;

// @public (undocumented)
export type PositioningShorthandValue = 'above' | 'above-start' | 'above-end' | 'below' | 'below-start' | 'below-end' | 'before' | 'before-start' | 'before-end' | 'after' | 'after-start' | 'after-end';

// @public (undocumented)
export const POSITIONS: {
    readonly above: "above";
    readonly below: "below";
    readonly before: "before";
    readonly after: "after";
};

// @public
export function resolvePositioningShorthand(value: PositioningShorthand | undefined): PositioningProps;

// @public (undocumented)
export function usePositioning(options: PositioningProps): PositioningReturn;

// (No @packageDocumentation comment for this package)