UNPKG

@alicloud/cloud-charts

Version:

![](https://img.shields.io/npm/v/@alicloud/cloud-charts?color=%23ff8200)

26 lines (25 loc) 966 B
import { Geometry, Types } from "./types"; import { IGroup, IShape } from "@antv/g2/esm/dependents"; export interface LabelConfig extends Types.GeometryLabelCfg { visible?: boolean; labelFormatter?: (value: string, mappingData: Types.MappingDatum, index: number) => string | IShape | IGroup; customConfig?: Types.GeometryLabelCfg; field?: string; /** @deprecated key 属性已废弃,请使用 field 属性 */ key?: string; offset?: number; callback?: Types.LabelCallback; } export default function ({ geom, config, field, defaultConfig, extraConfigKey, useCustomOffset, componentConfig, extraCallbackParams, }: { geom: Geometry; config: { label?: LabelConfig | boolean; [p: string]: any; }; field?: string; defaultConfig?: Types.GeometryLabelCfg; extraConfigKey?: string; useCustomOffset?: boolean; componentConfig?: Types.GeometryLabelCfg; extraCallbackParams?: any[]; }): void;