UNPKG

utils-echart

Version:

Echart component

767 lines (766 loc) 19.4 kB
/** */ export declare class Bar { /** 柱条宽度 */ static barWidth: number; /** * 获取单柱数据 * @param xAxis x轴 * @param range 数据范围 * @returns obj */ static getSingleBarData(xAxis: string[], range?: number[]): any; /** * 获取多柱数据 * @param xAxis x轴 * @param name 名称 * @param range 数据范围 * @return obj */ static getMultipleBarData(xAxis: string[], name: string[], range?: number[]): { xAxis: string[]; data: {}[]; }; /** * 柱0 * @param data 数据 * @param color 柱颜色 * @returns option */ static bar0(data?: any, color?: any): { backgroundColor: any; color: any; grid: any; tooltip: { trigger: string; }; title: any; xAxis: { type: string; data: string[]; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; yAxis: { type: string; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; series: { data: unknown[]; type: string; label: { show: boolean; position: string; color: any; }; barWidth: number; }[]; }; /** * 柱1 * @param data 数据 * @param barColor 柱颜色 * @param barBgColor 柱背景色 * @returns option */ static bar1(data?: any, barColor?: any, barBgColor?: any): { backgroundColor: any; color: any; grid: any; tooltip: { trigger: string; }; legend: any; title: any; xAxis: { name: string; type: string; data: string[]; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; yAxis: { name: string; type: string; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; series: { data: unknown[]; type: string; label: { show: boolean; position: string; color: any; }; showBackground: boolean; backgroundStyle: { color: any; }; barWidth: number; }[]; }; /** * 柱2 * @param data 数据 * @param index 变色柱(数组下标从0开始) * @param color 要变的颜色 * @returns option */ static bar2(data?: any, index?: number, color?: any): { backgroundColor: any; color: any; grid: any; tooltip: { trigger: string; }; legend: any; title: any; xAxis: { name: string; type: string; data: string[]; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; yAxis: { name: string; type: string; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; series: { type: string; data: any[]; barWidth: number; }[]; }; /** * 柱3 * @param data 数据 * @param color 颜色 * @returns option */ static bar3(data?: any, color?: any): { backgroundColor: any; color: any; grid: any; tooltip: { trigger: string; }; legend: any; title: any; xAxis: { name: string; type: string; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; yAxis: { name: string; data: string[]; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; series: { type: string; data: unknown[]; barWidth: number; }[]; }; /** * 柱4 * @param data 数据 * @param color 颜色 * @returns option */ static bar4(data?: any, color?: any): { backgroundColor: any; color: any; grid: any; tooltip: { trigger: string; }; legend: any; title: any; xAxis: { name: string; type: string; data: string[]; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; yAxis: { name: string; type: string; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; series: { type: string; label: { show: boolean; position: string; color: any; }; data: unknown[]; barWidth: number; }[]; }; /** * 柱5 * @param data 数据 * @param color 颜色 * @returns option */ static bar5(data?: any, color?: any): { backgroundColor: any; grid: any; tooltip: { trigger: string; }; legend: any; title: any; xAxis: { name: string; type: string; data: string[]; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; yAxis: { name: string; type: string; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; series: { data: unknown[]; type: string; barWidth: number; label: { show: boolean; position: string; color: any; }; itemStyle: { color: (params: any) => any; }; }[]; }; /** * 柱6 * @param data 数据 * @param colorArr 颜色组 * @param barBgColor 柱背景色 * @param yMax y轴最大值 * @returns option */ static bar6(data?: any, colorArr?: any[], barBgColor?: any, yMax?: number): { backgroundColor: any; grid: any; tooltip: { trigger: string; }; animation: boolean; xAxis: { data: string[]; axisLine: { show: boolean; }; axisTick: { show: boolean; }; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { show: boolean; fontSize: number; color: any; }; }; yAxis: { type: string; gridIndex: number; min: number; max: number; interval: number; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisTick: { show: boolean; }; axisLine: { show: boolean; }; axisLabel: { show: boolean; fontSize: number; color: any; }; }; series: ({ type: string; barWidth: number; showBackground: boolean; backgroundStyle: { color: any; }; itemStyle: { label: { show: boolean; position: string; color: any; fontSize: number; }; color: any; normal?: undefined; }; data: unknown[]; symbolRepeat?: undefined; symbolMargin?: undefined; symbol?: undefined; symbolClip?: undefined; symbolSize?: undefined; symbolPosition?: undefined; symbolOffset?: undefined; zlevel?: undefined; } | { type: string; itemStyle: { normal: { color: any; }; label?: undefined; color?: undefined; }; symbolRepeat: string; symbolMargin: number; symbol: string; symbolClip: boolean; symbolSize: number[]; symbolPosition: string; symbolOffset: number[]; data: number[]; zlevel: number; barWidth?: undefined; showBackground?: undefined; backgroundStyle?: undefined; })[]; }; /** * 柱7 * @param data 数据 * @param colorArr 颜色组 * @param borderColor 边框颜色 * @param shadowColor 阴影颜色 * @returns otpion */ static bar7(data?: any, colorArr?: any[], borderColor?: any, shadowColor?: any): { backgroundColor: any; title: any; grid: any; tooltip: { trigger: string; }; xAxis: { type: string; data: string[]; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; yAxis: { type: string; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; series: { type: string; label: { show: boolean; position: string; color: any; }; data: unknown[]; barWidth: number; showBackground: boolean; itemStyle: { borderWidth: number; borderColor: any; shadowColor: any; shadowBlur: number; color: any; }; }[]; }; /** * 柱8 * @param data 数据 * @param colorArr 柱颜色 * @param gridColor 网格颜色 * @returns option */ static bar8(data?: any, colorArr?: any, gridColor?: any): { backgroundColor: any; color: any; grid: any; tooltip: { trigger: string; }; title: any; xAxis: { type: string; data: string[]; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; yAxis: { type: string; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; series: { data: unknown[]; type: string; label: { show: boolean; position: string; color: any; }; itemStyle: { color: any; }; barWidth: number; }[]; }; /** * 多柱0 * @param obj 数据 * @param colorArr 颜色组 * @returns option */ static multipleBar0(obj?: any, colorArr?: any[]): { backgroundColor: any; legend: { top: string; }; grid: any; tooltip: { trigger: string; }; color: any; title: any; xAxis: { type: string; data: any; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; yAxis: { splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; series: any[]; }; /** * 多柱1 * @param obj 数据 * @param colorArr 颜色组 * @returns option */ static multipleBar1(obj?: any, colorArr?: any[]): { backgroundColor: any; color: any; grid: any; tooltip: { trigger: string; axisPointer: { type: string; }; }; legend: any; xAxis: { type: string; splitLineX: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; }; yAxis: { type: string; splitLineY: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { fontSize: number; color: any; }; data: any; }; series: any[]; }; /** * 多柱状2 * @param obj 数据 * @param colorArr 颜色组 * @returns */ static multipleBar2(obj?: any, colorArr?: any[]): { backgroundColor: any; color: any; tooltip: { trigger: string; axisPointer: { type: string; }; }; legend: { left: string; top: string; icon: string; itemGap: number; itemHeight: number; itemWidth: number; textStyle: { fontSize: number; color: any; }; }; grid: any; yAxis: { type: string; splitLine: { show: any; lineStyle: { color: any; width: any; type: any; }; }; axisLabel: { color: any; fontSize: number; }; }; xAxis: { type: string; axisLine: { show: boolean; }; axisLabel: { color: any; fontSize: number; }; axisTick: { alignWithLabel: boolean; }; data: any; }; series: any[]; }; }