Skip to content
navy

Tooltip

Display contextual information on hover or focus.

Live Demo

Placements

With Icons

Custom Content

With Delay

Usage

vue
<template>
  <!-- Simple text tooltip -->
  <orio-tooltip text="Hello World">
    <orio-button variant="secondary">Hover me</orio-button>
  </orio-tooltip>

  <!-- Custom content slot -->
  <orio-tooltip placement="top">
    <orio-button variant="secondary">Hover me</orio-button>
    <template #content>
      <div>Custom HTML content</div>
    </template>
  </orio-tooltip>

  <!-- With delay -->
  <orio-tooltip text="Delayed" :delay="300">
    <orio-button variant="secondary">Hover me</orio-button>
  </orio-tooltip>
</template>

Props

PropTypeDefaultDescription
textstringundefinedTooltip text (when not using content slot)
placement'top' | 'bottom' | 'left' | 'right''top'Tooltip position relative to trigger
delaynumber500Delay before showing tooltip (ms)
disabledbooleanfalseDisable tooltip
offsetnumber8Distance from trigger element (px)

Slots

SlotDescription
defaultTrigger element
contentCustom tooltip content (overrides text prop)

Features

  • Automatic positioning with arrow indicator
  • Shows on hover and focus (keyboard accessible)
  • Teleports to body to avoid z-index issues
  • Updates position on scroll and resize
  • Configurable delay
  • Support for custom content via slot
  • Dark theme by default