{# The collapsed state, before the first paint: a sidebar that opens wide and then snaps shut on every page is a sidebar that flickers. #} {% block head %}{% endblock %} {% from "_icons.html" import icon %} {% if user %} {# The navigation, down the left: the pages in groups, one icon each, so that with the text folded away the icons still say where you are. Groups fold too; the one holding the current page starts open. #} {% set nav_groups = [ {'key': 'invest', 'label': _("Investing"), 'items': [ ('portfolio', url_for('portfolio_page'), _("Portfolio"), 'portfolio'), ('crypto', url_for('crypto_page'), _("Crypto"), 'crypto'), ('allocation', url_for('allocation_page'), _("Allocation"), 'allocation'), ('dividends', url_for('dividends_page'), _("Dividends"), 'dividends'), ('ideas', url_for('screener_page'), _("Share Ideas"), 'screener')]}, {'key': 'money', 'label': _("Money"), 'items': [ ('cashflow', url_for('cashflow_page'), _("Cash Flow"), 'cashflow'), ('income', url_for('income_page'), _("Income"), 'income'), ('budget', url_for('budget_page'), _("Budget"), 'budget'), ('subscriptions', url_for('subscriptions_page'), _("Subscriptions"), 'subscriptions'), ('bills', url_for('bills_page'), _("Bills"), 'bills'), ('transactions', url_for('transactions'), _("Transactions"), 'transactions'), ('categorize', url_for('categorize'), _("Categorize"), 'categorize')]}, {'key': 'plan', 'label': _("Planning"), 'items': [ ('forecast', url_for('forecast_page'), _("Forecast"), 'forecast'), ('stages', url_for('stages_page'), _("Stages"), 'stages'), ('goals', url_for('goals_page'), _("Goals"), 'goals'), ('retirement', url_for('retirement_page'), _("Retirement"), 'retirement'), ('loans', url_for('loans_page'), _("Loans"), 'loans')]}, ] %} {% endif %}
{% if user %}
{% if people %} {# Whose picture: everyone's, or one person's. A lens on the same data, so it sits above every page it applies to. #}
{% for p in people %} {% endfor %}
{% endif %}
{% endif %}
{% with messages = get_flashed_messages(with_categories=true) %} {% for category, message in messages %}
{{ message }}
{% endfor %} {% endwith %} {% block heading_block %} {% if self.heading() | trim %}

{% block heading %}{% endblock %}

{% endif %} {% endblock %} {% if view_person and active_page in ('overview', 'portfolio', 'crypto', 'allocation', 'dividends', 'loans', 'bills', 'cashflow', 'income', 'budget', 'forecast', 'stages', 'subscriptions', 'transactions', 'categorize', 'accounts') %}

{{ _f("Only {name}'s accounts are counted on this page.", name=view_person.name) }}

{% endif %} {% block lede %}{% endblock %} {% block content %}{% endblock %}
{% if user %} {% endif %} {# Page scripts go last, after Chart.js and after the markup they draw into. A child template that defines a scripts block and finds no matching block here is not an error in Jinja — the block is simply dropped, the page renders perfectly, and nothing happens. #} {% block scripts %}{% endblock %}