refactor: enhance legend render function
This commit is contained in:
parent
9dbea37f55
commit
910e2dc422
3 changed files with 19 additions and 3 deletions
|
|
@ -58,7 +58,7 @@ func NewLineChart(opt LineChartOption) (*Draw, error) {
|
|||
return nil, err
|
||||
}
|
||||
|
||||
_, err = drawLegend(d, &opt.Legend, &theme)
|
||||
_, err = NewLegend(d, opt.Legend).Render()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue