Style graph

This commit is contained in:
Joscha 2023-08-18 02:41:19 +02:00
parent c83f193143
commit 7ecd812b11
3 changed files with 77 additions and 39 deletions

View file

@ -7,34 +7,15 @@
<script type="module" src="{{ link_graph_js }}"></script>
{% endblock %}
{# {% macro metric_tree(tree) %}
{% match tree %}
{% when File with { name, metric } %}
<label><input type="checkbox" name="{{ metric }}"> {{ name }}</label>
{% when Folder with { name, metric, children } %}
<details>
<summary>{{ name }}/</summary>
{% call metric_forest(children) %}
</details>
{% endmatch %}
{% endmacro %}
{% macro metric_forest(trees) %}
<ul>
{% for tree in forest %}
{% call metric_tree(tree) %}
{% endfor %}
</ul>
{% endmacro %} #}
{% block body %}
<h2>Graph</h2>
<div id="plot"></div>
<div id="metrics">
{{ metrics|safe }}
<div class="graph-container">
<div id="plot"></div>
<div id="metrics" class="metrics-list">
{{ metrics|safe }}
</div>
</div>
{% endblock %}