Tooltip

アイコンのみのコントロール向けに、ホバーとフォーカスで表示されるツールチップ。任意の方向に表示でき、矢印も付けられます。

対応フレームワーク
  • Angular: 対応
  • Vue: 対応
  • React: 対応
  • React Native: 対応

使い方

インポート

ts
import {
  SoneTooltipDirective,
} from "@surface-one/angular/tooltip";

API リファレンス

SoneTooltipDirectiveディレクティブ

Replaces the host's native `title` rather than sitting beside it — both at once would show two tooltips. The bubble is `aria-hidden`; the control keeps naming itself as it already did, or a screen reader would announce the name twice.

セレクター
[soneTooltip]
入力
名前型 デフォルト
soneTooltipstring""
soneTooltipSide

`null`: the side its container asks for (`SONE_TOOLTIP_SIDE`), else `bottom`.

TooltipSide | nullnull
soneTooltipAlignTooltipAlign"center"
soneTooltipArrowbooleantrue
soneTooltipDisabledbooleanfalse
soneTooltipShowDelay—SHOW_DELAY_MS