import type { ReactElement, HTMLAttributes, Ref } from "react";
import type SlTooltipElement from "@shoelace-style/shoelace/dist/components/tooltip/tooltip.js";
import {
SlShowEvent,
SlAfterShowEvent,
SlHideEvent,
SlAfterHideEvent,
} from "../events";
export type { SlTooltipElement };
export type SlTooltipShowEvent = SlShowEvent;
export type SlTooltipAfterShowEvent = SlAfterShowEvent;
export type SlTooltipHideEvent = SlHideEvent;
export type SlTooltipAfterHideEvent = SlAfterHideEvent;
export interface SlTooltipProps extends HTMLAttributes {
ref?: Ref;
/**
* The tooltip's content. If you need to display HTML, use the `content` slot instead.
*/
content?: string;
/**
* The preferred placement of the tooltip. Note that the actual placement may vary as needed to keep the tooltip
* inside of the viewport.
*/
placement?:
| "top"
| "top-start"
| "top-end"
| "right"
| "right-start"
| "right-end"
| "bottom"
| "bottom-start"
| "bottom-end"
| "left"
| "left-start"
| "left-end";
/**
* Disables the tooltip so it won't show when triggered.
*/
disabled?: boolean;
/**
* The distance in pixels from which to offset the tooltip away from its target.
*/
distance?: number;
/**
* Indicates whether or not the tooltip is open. You can use this in lieu of the show/hide methods.
*/
open?: boolean;
/**
* The distance in pixels from which to offset the tooltip along its target.
*/
skidding?: number;
/**
* Controls how the tooltip is activated. Possible options include `click`, `hover`, `focus`, and `manual`. Multiple
* options can be passed by separating them with a space. When manual is used, the tooltip must be activated
* programmatically.
*/
trigger?: string;
/**
* Enable this option to prevent the tooltip from being clipped when the component is placed inside a container with
* `overflow: auto|hidden|scroll`. Hoisting uses a fixed positioning strategy that works in many, but not all,
* scenarios.
*/
hoist?: boolean;
/**
* Emitted when the tooltip begins to show.
*/
onSlShow?: (event: SlTooltipShowEvent) => void;
/**
* Emitted when the tooltip begins to show.
*/
onSlShowCapture?: (event: SlTooltipShowEvent) => void;
/**
* Emitted after the tooltip has shown and all animations are complete.
*/
onSlAfterShow?: (event: SlTooltipAfterShowEvent) => void;
/**
* Emitted after the tooltip has shown and all animations are complete.
*/
onSlAfterShowCapture?: (event: SlTooltipAfterShowEvent) => void;
/**
* Emitted when the tooltip begins to hide.
*/
onSlHide?: (event: SlTooltipHideEvent) => void;
/**
* Emitted when the tooltip begins to hide.
*/
onSlHideCapture?: (event: SlTooltipHideEvent) => void;
/**
* Emitted after the tooltip has hidden and all animations are complete.
*/
onSlAfterHide?: (event: SlTooltipAfterHideEvent) => void;
/**
* Emitted after the tooltip has hidden and all animations are complete.
*/
onSlAfterHideCapture?: (event: SlTooltipAfterHideEvent) => void;
}
/**
* Tooltips display additional information based on a specific action.
*/
export default function SlTooltip(
props: SlTooltipProps,
): ReactElement;