Skip to content

Commit

Permalink
move legend on top of plots (#113)
Browse files Browse the repository at this point in the history
* move legend on top of plots

* fix linting failures
  • Loading branch information
dberenbaum authored Feb 1, 2023
1 parent e36f916 commit 011bdb6
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions src/dvc_render/vega_templates.py
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,11 @@ class SmoothLinearTemplate(Template):
"title": Template.anchor("y_label"),
"scale": {"zero": False},
},
"color": {"field": "rev", "type": "nominal"},
"color": {
"field": "rev",
"type": "nominal",
"legend": {"orient": "top", "direction": "vertical"},
},
},
"layer": [
{
Expand Down Expand Up @@ -546,7 +550,11 @@ class LinearTemplate(Template):
"title": Template.anchor("y_label"),
"scale": {"zero": False},
},
"color": {"field": "rev", "type": "nominal"},
"color": {
"field": "rev",
"type": "nominal",
"legend": {"orient": "top", "direction": "vertical"},
},
},
}

Expand Down

0 comments on commit 011bdb6

Please sign in to comment.