Components
BaseTooltip
A tooltip with an optional keyboard shortcut, shown the right way on Mac and PC.
components/ui/BaseTooltip.vue
View in the demo
Example
API
It also accepts every prop, slot and event of v-tooltip, which it passes through.
Props
Name | Type | Default | Description |
|---|---|---|---|
textrequired | string | — | The tooltip text. |
keys | string | — | A shortcut such as cmd+s; cmd becomes ⌘ or Ctrl. |
location | Anchor | "bottom" | Where it opens. |
disabled | boolean | false | Turns it off. |
Slots
Name | Slot props | Description |
|---|---|---|
#default | { props: { 'aria-keyshortcuts': any; }; } | The activator; bind the props it receives. |
Accessibility
With keys, the activator also gets aria-keyshortcuts, so screen readers announce the shortcut.