import { CommonComponentProps } from "@open-pioneer/react-utils"; import { ReactNode } from "react"; /** * The position of an anchor on the map. * * This is either a predefined position (like a corner) or a completely manual position. * * @group UI Components and Hooks */ export type MapAnchorPosition = "manual" | "top-left" | "top-right" | "top-center" | "bottom-left" | "bottom-right" | "bottom-center" | "left-center" | "right-center" | "center"; /** * @group UI Components and Hooks */ export interface MapAnchorProps extends CommonComponentProps { /** * The position of the anchor container above the map. * * Use `manual` if you wish to position the anchor manually using absolute positioning. * This can be achieved by configuring a css class on the map anchor and using css properties like `left`, `top`, etc. * * @default "top-right" */ position?: MapAnchorPosition; /** * Horizontal gap in pixel applied to anchor container. * Only interpreted if a non-manual position is used. * * @default 0 */ horizontalGap?: number; /** * Vertical gap in pixel applied to anchor container. * Only interpreted if a non-manual position is used. * * @default 0 (If positioned at the bottom, default verticalGap == `30`) */ verticalGap?: number; children?: ReactNode; } /** * A map anchor is a layout component that sits on top of the map. * * It can be used to position widgets (such as zoom buttons) at a specific location. * * Map anchors respect the map's current _view padding_. * * @group UI Components and Hooks */ export declare function MapAnchor(props: MapAnchorProps): ReactNode;