Skip to content

STooltip <s-tooltip>

ts
import { STooltip } from 'polaris-vue-elements'

Example

Hover or focus the button below to reveal the tooltip — it activates via interestFor, not a click.

Hover or focus meExtra context shown on hover or focus.
vue
<script setup>
import { SButton, SText, STooltip } from 'polaris-vue-elements'
</script>

<template>
  <!-- interestFor activates the target on hover/focus, unlike commandFor which
       requires a click/activation. -->
  <SButton interestFor="example-tooltip">Hover or focus me</SButton>

  <STooltip id="example-tooltip">
    <SText>Extra context shown on hover or focus.</SText>
  </STooltip>
</template>

Props

PropTypeDescription
idstringA unique identifier for the element.

Slots

SlotDescription
defaultThe content of the Tooltip. Only accepts Text, Paragraph components, and raw textContent.