({ layout, legend, colorValueScale, theme }: ChartState<Options>)
| 74 | }; |
| 75 | |
| 76 | render({ layout, legend, colorValueScale, theme }: ChartState<Options>) { |
| 77 | this.rect = layout.legend; |
| 78 | this.align = legend.align; |
| 79 | this.isShow = legend.visible && !!legend.data.length; |
| 80 | |
| 81 | if (!this.isShow) { |
| 82 | return; |
| 83 | } |
| 84 | |
| 85 | this.labels = this.makeLabels(colorValueScale); |
| 86 | const { startColor, endColor } = theme.series?.heatmap! || theme.series?.treemap!; |
| 87 | |
| 88 | this.models = { legend: this.renderSpectrumLegendModel(startColor, endColor), tooltip: [] }; |
| 89 | |
| 90 | this.eventBus.on('renderSpectrumTooltip', this.renderSpectrumTooltip); |
| 91 | } |
| 92 | } |
nothing calls this directly
no test coverage detected