# インターフェース: TooltipOptions<TType>
# 型パラメータ
| 名前 | 型 |
|---|---|
TType | extends ChartType = ChartType |
# 階層構造
-
↳
TooltipOptions
# プロパティ
# animation
• animation: false | AnimationSpec<TType>
# 定義済み
types/index.d.ts:2888 (新しいウィンドウで開きます)
# animations
• animations: false | AnimationsSpec<TType>
# 定義済み
types/index.d.ts:2889 (新しいウィンドウで開きます)
# axis
• axis: InteractionAxis
距離計算で使用される方向を定義します。'index'モードでは'x'、datasetと'nearest'モードでは'xy'がデフォルトです。
# 継承元
# 定義済み
types/index.d.ts:1579 (新しいウィンドウで開きます)
# backgroundColor
• backgroundColor: Scriptable<Color, ScriptableTooltipContext<TType>>
ツールチップの背景色。
デフォルト
'rgba(0, 0, 0, 0.8)'
# 定義済み
types/index.d.ts:2746 (新しいウィンドウで開きます)
# bodyAlign
• bodyAlign: Scriptable<TextAlign, ScriptableTooltipContext<TType>>
本文テキスト行の水平方向の配置。
デフォルト
'left'
# 定義済み
types/index.d.ts:2796 (新しいウィンドウで開きます)
# bodyColor
• bodyColor: Scriptable<Color, ScriptableTooltipContext<TType>>
本文の色
デフォルト
'#fff'
# 定義済み
types/index.d.ts:2786 (新しいウィンドウで開きます)
# bodyFont
• bodyFont: ScriptableAndScriptableOptions<Partial<FontSpec>, ScriptableTooltipContext<TType>>
フォントを参照してください。
デフォルト
# 定義済み
types/index.d.ts:2791 (新しいウィンドウで開きます)
# bodySpacing
• bodySpacing: Scriptable<number, ScriptableTooltipContext<TType>>
各ツールチップアイテムの上部と下部に追加するスペース。
デフォルト
2
# 定義済み
types/index.d.ts:2781 (新しいウィンドウで開きます)
# borderColor
• borderColor: Scriptable<Color, ScriptableTooltipContext<TType>>
枠線の色。
デフォルト
'rgba(0, 0, 0, 0)'
# 定義場所
types/index.d.ts:2871 (新しいウィンドウで開きます)
# borderWidth
• borderWidth: Scriptable<number, ScriptableTooltipContext<TType>>
ボーダーのサイズ。
デフォルト
0
# 定義場所
types/index.d.ts:2876 (新しいウィンドウで開きます)
# boxHeight
• boxHeight: Scriptable<number, ScriptableTooltipContext<TType>>
displayColors が true の場合の色ボックスの高さ。
デフォルト
bodyFont.size
# 定義場所
types/index.d.ts:2861 (新しいウィンドウで開きます)
# boxPadding
• boxPadding: number
色ボックスとテキスト間の余白。
デフォルト
1
# 定義場所
types/index.d.ts:2751 (新しいウィンドウで開きます)
# boxWidth
• boxWidth: Scriptable<number, ScriptableTooltipContext<TType>>
displayColors が true の場合の色ボックスの幅。
デフォルト
bodyFont.size
# 定義場所
types/index.d.ts:2856 (新しいウィンドウで開きます)
# callbacks
• callbacks: TooltipCallbacks<TType, TooltipModel<TType>, TooltipItem<TType>>
# 定義場所
types/index.d.ts:2890 (新しいウィンドウで開きます)
# caretPadding
• caretPadding: Scriptable<number, ScriptableTooltipContext<TType>>
ツールチップの矢印の先端をツールチップポイントから動かす追加距離。
デフォルト
2
# 定義場所
types/index.d.ts:2831 (新しいウィンドウで開きます)
# caretSize
• caretSize: Scriptable<number, ScriptableTooltipContext<TType>>
ツールチップの矢印のサイズ(px)。
デフォルト
5
# 定義場所
types/index.d.ts:2836 (新しいウィンドウで開きます)
# cornerRadius
• cornerRadius: Scriptable<number | BorderRadius, ScriptableTooltipContext<TType>>
ツールチップの角の曲線の半径。
デフォルト
6
# 定義場所
types/index.d.ts:2841 (新しいウィンドウで開きます)
# displayColors
• displayColors: Scriptable<boolean, ScriptableTooltipContext<TType>>
true の場合、ツールチップに色ボックスが表示されます。
デフォルト
true
# 定義場所
types/index.d.ts:2851 (新しいウィンドウで開きます)
# enabled
• enabled: Scriptable<boolean, ScriptableTooltipContext<TType>>
キャンバス上のツールチップを有効にしますか?
デフォルト
true
# 定義場所
types/index.d.ts:2719 (新しいウィンドウで開きます)
# filter
• filter: (e: TooltipItem<TType>, index: number, array: TooltipItem<TType>[], data: ChartData<keyof ChartTypeRegistry, (number | [number, number] | Point | BubbleDataPoint)[], unknown>) => boolean
# 型宣言
▸ (e, index, array, data): boolean
# パラメータ
| 名前 | 型 |
|---|---|
e | TooltipItem<TType> |
index | number |
array | TooltipItem<TType>[] |
data | ChartData<keyof ChartTypeRegistry, (number | [number, number] | Point | BubbleDataPoint)[], unknown> |
# 戻り値
boolean
# 定義場所
types/index.d.ts:2740 (新しいウィンドウで開きます)
# footerAlign
• footerAlign: Scriptable<TextAlign, ScriptableTooltipContext<TType>>
フッターテキスト行の水平方向の配置。
デフォルト
'left'
# 定義場所
types/index.d.ts:2821 (新しいウィンドウで開きます)
# footerColor
• footerColor: Scriptable<Color, ScriptableTooltipContext<TType>>
フッターの色
デフォルト
'#fff'
# 定義場所
types/index.d.ts:2811 (新しいウィンドウで開きます)
# footerFont
• footerFont: ScriptableAndScriptableOptions<Partial<FontSpec>, ScriptableTooltipContext<TType>>
フォントを参照
デフォルト
# 定義されている場所
types/index.d.ts:2816 (新しいウィンドウで開きます)
# footerMarginTop
• footerMarginTop: Scriptable<number, ScriptableTooltipContext<TType>>
フッターを描画する前に追加するマージン。
デフォルト
6
# 定義されている場所
types/index.d.ts:2806 (新しいウィンドウで開きます)
# footerSpacing
• footerSpacing: Scriptable<number, ScriptableTooltipContext<TType>>
フッターの各行の上下に追加するスペース。
デフォルト
2
# 定義されている場所
types/index.d.ts:2801 (新しいウィンドウで開きます)
# includeInvisible
• includeInvisible: boolean
trueの場合、チャート領域の外側にある非表示のポイントも、インタラクションの評価時に含まれます。
デフォルト
false
# 継承元
CoreInteractionOptions.includeInvisible
# 定義されている場所
types/index.d.ts:1585 (新しいウィンドウで開きます)
# intersect
• intersect: boolean
trueの場合、ホバーモードはマウス位置がチャート上のアイテムと交差する場合にのみ適用されます。
デフォルト
true
# 継承元
CoreInteractionOptions.intersect
# 定義されている場所
types/index.d.ts:1574 (新しいウィンドウで開きます)
# itemSort
• itemSort: (a: TooltipItem<TType>, b: TooltipItem<TType>, data: ChartData<keyof ChartTypeRegistry, (number | [number, number] | Point | BubbleDataPoint)[], unknown>) => number
# 型宣言
▸ (a, b, data): number
ツールチップアイテムをソートします。
# パラメータ
| 名前 | 型 |
|---|---|
a | TooltipItem<TType> |
b | TooltipItem<TType> |
data | ChartData<keyof ChartTypeRegistry, (number | [number, number] | Point | BubbleDataPoint)[], unknown> |
# 戻り値
number
# 定義されている場所
types/index.d.ts:2738 (新しいウィンドウで開きます)
# mode
• mode: keyof InteractionModeMap
ツールチップに表示される要素を設定します。詳細はインタラクションモードを参照してください。
デフォルト
'nearest'
# 継承元
# 定義されている場所
types/index.d.ts:1569 (新しいウィンドウで開きます)
# multiKeyBackground
• multiKeyBackground: Scriptable<Color, ScriptableTooltipContext<TType>>
複数のアイテムがツールチップに含まれる場合に、カラーボックスの後ろに描画する色。
デフォルト
'#fff'
# 定義されている場所
types/index.d.ts:2846 (新しいウィンドウで開きます)
# padding
• padding: Scriptable<Padding, ScriptableTooltipContext<TType>>
ツールチップに追加するパディング
デフォルト
6
# 定義されている場所
types/index.d.ts:2826 (新しいウィンドウで開きます)
# position
• position: Scriptable<keyof TooltipPositionerMap, ScriptableTooltipContext<TType>>
ツールチップの配置モード
# 定義されている場所
types/index.d.ts:2727 (新しいウィンドウで開きます)
# rtl
• rtl: Scriptable<boolean, ScriptableTooltipContext<TType>>
凡例を右から左にレンダリングする場合true。
# 定義されている場所
types/index.d.ts:2880 (新しいウィンドウで開きます)
# textDirection
• textDirection: Scriptable<string, ScriptableTooltipContext<TType>>
キャンバスで指定されたCSSに関係なく、ツールチップのレンダリングのためにテキストの方向を'rtl'または'ltr'に強制します。
デフォルト
キャンバスのデフォルト
# 定義されている場所
types/index.d.ts:2886 (新しいウィンドウで開きます)
# titleAlign
• **titleAlign**: Scriptable<TextAlign, ScriptableTooltipContext<TType>>
タイトルテキスト行の水平方向の配置。
デフォルト
'left'
# 定義されている場所
types/index.d.ts:2776 (新しいウィンドウで開きます)
# titleColor
• **titleColor**: Scriptable<Color, ScriptableTooltipContext<TType>>
タイトルの色
デフォルト
'#fff'
# 定義されている場所
types/index.d.ts:2756 (新しいウィンドウで開きます)
# titleFont
• **titleFont**: ScriptableAndScriptableOptions<Partial<FontSpec>, ScriptableTooltipContext<TType>>
フォントを参照
デフォルト
# 定義されている場所
types/index.d.ts:2761 (新しいウィンドウで開きます)
# titleMarginBottom
• **titleMarginBottom**: Scriptable<number, ScriptableTooltipContext<TType>>
タイトルセクションの下部に追加するマージン。
デフォルト
6
# 定義されている場所
types/index.d.ts:2771 (新しいウィンドウで開きます)
# titleSpacing
• **titleSpacing**: Scriptable<number, ScriptableTooltipContext<TType>>
各タイトル行の上下に追加するスペース。
デフォルト
2
# 定義されている場所
types/index.d.ts:2766 (新しいウィンドウで開きます)
# usePointStyle
• **usePointStyle**: Scriptable<boolean, ScriptableTooltipContext<TType>>
カラーボックスの代わりに、対応するポイントスタイル(データセットオプションから)を使用します(例:星、三角形など)。(サイズは、boxWidthとboxHeightの最小値に基づきます)
デフォルト
false
# 定義されている場所
types/index.d.ts:2866 (新しいウィンドウで開きます)
# xAlign
• **xAlign**: Scriptable<TooltipXAlignment, ScriptableTooltipContext<TType>>
ツールチップの配置計算を上書きします。
# 定義されている場所
types/index.d.ts:2732 (新しいウィンドウで開きます)
# yAlign
• **yAlign**: Scriptable<TooltipYAlignment, ScriptableTooltipContext<TType>>
# 定義されている場所
types/index.d.ts:2733 (新しいウィンドウで開きます)
# メソッド
# external
▸ **external**(this, args): void
外部ツールチップセクションを参照してください。
# パラメータ
| 名前 | 型 |
|---|---|
this | TooltipModel<TType> |
args | オブジェクト |
args.chart | Chart<keyof ChartTypeRegistry, (number | [number, number] | Point | BubbleDataPoint)[], unknown> |
args.tooltip | TooltipModel<TType> |
# 戻り値
void