# 接口:TooltipModel<TType>
# 类型参数
| 名称 | 类型 |
|---|---|
TType | 扩展 ChartType |
# 层次结构
default<AnyObject,TooltipOptions<TType>>↳
TooltipModel
# 属性
# $animations
• $animations: Record<string, Animation>
# 继承自
Element.$animations
# 定义在
core/core.element.ts:15 (打开新窗口)
# active
• active: boolean = false
# 继承自
Element.active
# 定义在
core/core.element.ts:13 (打开新窗口)
# afterBody
• afterBody: string[]
# 定义在
# beforeBody
• beforeBody: string[]
# 定义在
# body
• body: { after: string[] ; before: string[] ; lines: string[] }[]
# 定义在
# caretX
• caretX: number
# 定义在
types/index.d.ts:2596 (在新窗口中打开)
# caretY
• caretY: number
# 定义于
types/index.d.ts:2597 (在新窗口中打开)
# chart
• Readonly chart: Chart<TType, DistributiveArray<ChartTypeRegistry[TType]["defaultDataPoint"]>, unknown>
# 定义于
types/index.d.ts:2581 (在新窗口中打开)
# dataPoints
• dataPoints: TooltipItem<TType>[]
# 定义于
types/index.d.ts:2584 (在新窗口中打开)
# footer
• footer: string[]
# 定义于
types/index.d.ts:2617 (在新窗口中打开)
# height
• height: number
# 定义于
types/index.d.ts:2594 (在新窗口中打开)
# labelColors
• labelColors: TooltipLabelStyle[]
# 定义于
types/index.d.ts:2620 (在新窗口中打开)
# labelPointStyles
• labelPointStyles: { pointStyle: PointStyle ; rotation: number }[]
# 定义于
types/index.d.ts:2622 (在新窗口中打开)
# labelTextColors
• labelTextColors: Color[]
# 定义于
types/index.d.ts:2621 (在新窗口中打开)
# opacity
• opacity: number
# 定义于
types/index.d.ts:2625 (在新窗口中打开)
# options
• options: TooltipOptions<TType>
# 覆盖
Element.options
# 定义于
types/index.d.ts:2628 (在新窗口中打开)
# title
• title: string[]
# 定义于
types/index.d.ts:2613 (在新窗口中打开)
# width
• width: number
# 定义于
types/index.d.ts:2593 (在新窗口中打开)
# x
• x: number
# 覆盖
Element.x
# 定义于
types/index.d.ts:2591 (在新窗口中打开)
# xAlign
• xAlign: TooltipXAlignment
# 定义于
types/index.d.ts:2587 (在新窗口中打开)
# y
• y: number
# 覆盖
Element.y
# 定义于
types/index.d.ts:2592 (在新窗口中打开)
# yAlign
• yAlign: TooltipYAlignment
# 定义于
types/index.d.ts:2588 (在新窗口中打开)
# 方法
# getActiveElements
▸ getActiveElements(): ActiveElement[]
# 返回
# 定义于
types/index.d.ts:2630 (在新窗口中打开)
# getProps
▸ getProps<P>(props, final?): Pick<AnyObject, P[number]>
获取每个属性当前或最终值。可以返回额外的属性(整个对象)。
# 类型参数
| 名称 | 类型 |
|---|---|
P | extends string[] |
# 参数
| 名称 | 类型 | 描述 |
|---|---|---|
props | P | 要获取的属性 |
final? | boolean | 获取最终值(动画目标) |
# 返回
Pick<AnyObject, P[number]>
# 继承自
Element.getProps
# 定义于
core/core.element.ts:31 (在新窗口中打开)
▸ getProps<P>(props, final?): Partial<Record<P, unknown>>
# 类型参数
| 名称 | 类型 |
|---|---|
P | extends string |
# 参数
| 名称 | 类型 |
|---|---|
props | P[] |
final? | boolean |
# 返回
Partial<Record<P, unknown>>
# 继承自
Element.getProps
# 定义于
# hasValue
▸ hasValue(): boolean
# 返回值
boolean
# 继承自
Element.hasValue
# 定义在
# setActiveElements
▸ setActiveElements(active, eventPosition): void
# 参数
| 名称 | 类型 |
|---|---|
active | ActiveDataPoint[] |
eventPosition | Point |
# 返回值
void
# 定义在
# tooltipPosition
▸ tooltipPosition(useFinalPosition): Point
# 参数
| 名称 | 类型 |
|---|---|
useFinalPosition | boolean |
# 返回值
# 继承自
Element.tooltipPosition