UNPKG

@bitrix24/b24ui-nuxt

Version:

Bitrix24 UI-Kit for developing web applications REST API for NUXT & VUE

58 lines (57 loc) 2.27 kB
import type { TooltipRootProps, TooltipRootEmits, TooltipContentProps, TooltipContentEmits, TooltipArrowProps, TooltipTriggerProps } from 'reka-ui'; import type { AppConfig } from '@nuxt/schema'; import theme from '#build/b24ui/tooltip'; import type { KbdProps } from '../types'; import type { EmitsToProps, ComponentConfig } from '../types/utils'; type Tooltip = ComponentConfig<typeof theme, AppConfig, 'tooltip'>; export interface TooltipProps extends TooltipRootProps { /** The text content of the tooltip. */ text?: string; /** The keyboard keys to display in the tooltip. */ kbds?: KbdProps['value'][] | KbdProps[]; /** * The content of the tooltip. * @defaultValue { side: 'bottom', sideOffset: 8, collisionPadding: 8 } */ content?: Omit<TooltipContentProps, 'as' | 'asChild'> & Partial<EmitsToProps<TooltipContentEmits>>; /** * Display an arrow alongside the tooltip. * @defaultValue false */ arrow?: boolean | Omit<TooltipArrowProps, 'as' | 'asChild'>; /** * Render the tooltip in a portal. * @defaultValue true */ portal?: boolean | string | HTMLElement; /** * The reference (or anchor) element that is being referred to for positioning. * * If not provided will use the current component as anchor. */ reference?: TooltipTriggerProps['reference']; class?: any; b24ui?: Tooltip['slots']; } export interface TooltipEmits extends TooltipRootEmits { } export interface TooltipSlots { default(props: { open: boolean; }): any; content(props?: {}): any; } declare const _default: __VLS_WithSlots<import("vue").DefineComponent<TooltipProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { "update:open": (value: boolean) => any; }, string, import("vue").PublicProps, Readonly<TooltipProps> & Readonly<{ "onUpdate:open"?: ((value: boolean) => any) | undefined; }>, { portal: boolean | string | HTMLElement; arrow: boolean | Omit<TooltipArrowProps, "as" | "asChild">; }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, TooltipSlots>; export default _default; type __VLS_WithSlots<T, S> = T & { new (): { $slots: S; }; };