UNPKG

@qn-pandora/pandora-visualization

Version:

Pandora 通用可视化库

72 lines (71 loc) 2.79 kB
import { RegressionType, ChartType, AxisNameMode, LabelShowMode, LabelRotation, AxisType, YEmptyValueMode } from '../../../../../constants/chart-style'; import TwoDChartStyleService, { ITwoDChartStyle } from '../two-d'; import { IChartStyleInitOption } from '../base'; export interface IScatterChartStyle extends ITwoDChartStyle { regression: RegressionType; regressionOrder: number; } export default abstract class ScatterChartStyleService extends TwoDChartStyleService<IScatterChartStyle> { static getChartInitStyle: typeof getChartInitStyle; chartType: ChartType; regression: RegressionType; regressionOrder: number; getOptions(): { regression: RegressionType; regressionOrder: number; chartType: ChartType; mainAxis: import("../..").IMainAxis; crossAxis1: import("../..").ICrossAxis; crossAxis2: import("../..").ICrossAxis2; legend: import("../../components/two-d-legend").ITwoDLegend; colors: import("../..").IColors; colorMode: import("@qn-pandora/pandora-app-component").EColorMode; compare: import("../../components/compare").ICompare; baseLine: import("@qn-pandora/pandora-app-component/lib/components/BaseLineItem/constants").IBaseLine<any>[]; showToolBox: boolean; tooltipType: import("../../../../../constants/chart-style").ETooltipType; tooltipAppendToBody?: boolean | undefined; markLine?: import("../../../../../constants/chart-style").IMarkLineType | undefined; displayColors?: import("../base").IColor[] | undefined; }; setRegression(regression: RegressionType): void; setRegressionOrder(order: number): void; constructor(options: IScatterChartStyle); } /** * 获取第一个有效的字段 */ export declare function getFirstUsefulField(buckets: string[], metrics: string[], fieldNames?: string[]): string; /** * 获取第一个有效的分组 */ export declare function getFirstUsefulBucket(buckets: string[]): string; /** * 获取第一个有效的指标 */ export declare function getFirstUsefulMetric(metrics: string[]): string; declare function getChartInitStyle(option: IChartStyleInitOption, initFirst?: boolean): { fields: import("@qn-pandora/app-sdk").IChartField[]; buckets: string[]; metrics: string[]; regression: RegressionType; colors: { fields: string[]; }; mainAxis: { name: string; nameMode: AxisNameMode; labelShowMode: LabelShowMode; labelRotation: LabelRotation; field: string; unit: string[]; }; crossAxis1: { name: string; nameMode: AxisNameMode; fields: string[]; scale: AxisType; yEmptyValueMode: YEmptyValueMode; }; }; export {};