feat: support padding for legend

This commit is contained in:
vicanso 2022-07-19 20:12:31 +08:00
parent 3af0d4d445
commit 8740c55a1a
2 changed files with 15 additions and 5 deletions

View file

@ -89,7 +89,13 @@ func main() {
"Video Ads",
"Direct",
"Search Engine",
}, charts.PositionCenter),
}, "50"),
func(opt *charts.ChartOption) {
opt.Legend.Padding = charts.Box{
Top: 5,
Bottom: 10,
}
},
)
if err != nil {