(data: SeriesData, key: string)
| 46 | } |
| 47 | |
| 48 | export function getVisualFromData(data: SeriesData, key: string) { |
| 49 | switch (key) { |
| 50 | case 'color': |
| 51 | const style = data.getVisual('style'); |
| 52 | return style[data.getVisual('drawType')]; |
| 53 | case 'opacity': |
| 54 | return data.getVisual('style').opacity; |
| 55 | case 'symbol': |
| 56 | case 'symbolSize': |
| 57 | case 'liftZ': |
| 58 | return data.getVisual(key); |
| 59 | default: |
| 60 | if (__DEV__) { |
| 61 | console.warn(`Unknown visual type ${key}`); |
| 62 | } |
| 63 | } |
| 64 | } |
| 65 | |
| 66 | export function setItemVisualFromData(data: SeriesData, dataIndex: number, key: string, value: any) { |
| 67 | switch (key) { |
no test coverage detected
searching dependent graphs…