{% extends "base.html" %}
{% import "activity/_head.html" as ac with context %}
{% block title %}Activity{% endblock %}
{% block head %}{{ ac.assets() }}{% endblock %}
{% block main_attrs %} data-norefresh{% endblock %}
{# One day, sorted (views.day): the totals + week + Smoothed | Raw, per-computer strips over the hours
that had anything (hover: what, why), the category tree (time incl. sub-categories; what it was about
inside — click one to move it: a learned rule), the unsorted list — "Sort" makes the suggested rule
(pattern editable) and the page sorts again (activity.js). #}
{% macro node(n, depth) %}
{{ n.cat.name }}
{% if n.cat.productive %}●{% endif %}{% if n.cat.distraction %}●{% endif %}
{{ hm(n.sec) }}
{% if n.top %}{% for i in n.top %}
{% endif %}
{% for c in n.kids %}{{ node(c, depth + 1) }}{% endfor %}
Nothing sorted {{ "yet " if v.day == v.today }}this day.
{% endfor %}{{ "All sorted." if v.total else "Nothing recorded this day." }}
{% endfor %} {% if v.unsorted_more %}… and {{ v.unsorted_more }} more, smaller ones
{% endif %}