Image Rendering: Fix render of graph panel legend aligned to the right using Grafana image renderer plugin/service (#21854)
Don't render class body--phantomjs on body element when PhantomJS renderer not is in use. Fixes #21830
This commit is contained in:
@@ -20,6 +20,8 @@ func init() {
|
||||
registry.RegisterService(&RenderingService{})
|
||||
}
|
||||
|
||||
var IsPhantomJSEnabled = false
|
||||
|
||||
type RenderingService struct {
|
||||
log log.Logger
|
||||
pluginInfo *plugins.RendererPlugin
|
||||
@@ -69,6 +71,7 @@ func (rs *RenderingService) Run(ctx context.Context) error {
|
||||
"You should consider migrating from phantomJS to grafana-image-renderer plugin. " +
|
||||
"Read more at https://grafana.com/docs/grafana/latest/administration/image_rendering/")
|
||||
rs.renderAction = rs.renderViaPhantomJS
|
||||
IsPhantomJSEnabled = true
|
||||
<-ctx.Done()
|
||||
return nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user