(data: SeriesData, dataIndex: number, key: string)
| 28 | |
| 29 | |
| 30 | export function getItemVisualFromData(data: SeriesData, dataIndex: number, key: string) { |
| 31 | switch (key) { |
| 32 | case 'color': |
| 33 | const style = data.getItemVisual(dataIndex, 'style'); |
| 34 | return style[data.getVisual('drawType')]; |
| 35 | case 'opacity': |
| 36 | return data.getItemVisual(dataIndex, 'style').opacity; |
| 37 | case 'symbol': |
| 38 | case 'symbolSize': |
| 39 | case 'liftZ': |
| 40 | return data.getItemVisual(dataIndex, key); |
| 41 | default: |
| 42 | if (__DEV__) { |
| 43 | console.warn(`Unknown visual type ${key}`); |
| 44 | } |
| 45 | } |
| 46 | } |
| 47 | |
| 48 | export function getVisualFromData(data: SeriesData, key: string) { |
| 49 | switch (key) { |
no test coverage detected