Source

admin-bro-design-system/src/atoms/tooltip/tooltip-props.ts

import { ReactNode, RefObject } from 'react'
import { DirectionProps } from '../../utils/direction-props'
import { BoxProps } from '../box/box'

/**
 * Props passed to the {@link Tooltip} component.
 *
 * @memberof Tooltip
 * @alias TooltipProps
 */
export type TooltipProps = {
  /** Text shown on the tooltip */
  title?: string,
  /** Direction of tooltip */
  direction: DirectionProps,
  /** Tooltip size */
  size?: 'default' | 'lg'
}

export type PortalProps = TooltipProps & {
  childRef: RefObject<HTMLElement>,
  ContentElement?: ReactNode,
}

export type StyledTooltipProps = BoxProps & Pick<TooltipProps, 'direction'> & {
  isVisible: boolean;
}

export default TooltipProps
SoftwareBrothers

Proudly built and maintained by SoftwareBrothers

Software House with a passion for both JavaScript and TypeScript.

See what we do See what we believe in

Proudly built and maintained by

SoftwareBrothers