{% from 'components/page-heading.html' import page_heading %} {% from 'components/artifact-type.html' import artifact_type %} {% from 'components/section-heading.html' import section_heading %}
{{ page_heading(data.title, data.summary) }} {% include 'components/home-attention.html' %} {% include 'home-summary.html' %}

{{ t.usage_resources }}

{{ t.view_usage }} →
{% if errors.get('usage') %}{{ read_error(errors.usage,t.usage_resources) }}{% elif stats %}{% include 'compact_usage.html' %}{% endif %}
{% if data.handoff or errors.get('handoff') %}

{{ t.handoff }}

{{ t.view_all }} →
{% if errors.get('handoff') %}{{ read_error(errors.handoff,t.handoff) }} {% else %}
{{ t['home_handoff_' + data.handoff.disposition] }}

{{ data.handoff.objective }}

{% if data.handoff.state %}

{{ data.handoff.state[0].text }}

{% endif %} {% if data.handoff.next_action %}
{{ t.next_action }}

{{ data.handoff.next_action.text }}

{% endif %}
{{ t.home_open_handoff }} →
{% endif %}
{% endif %}

{{ t.processing_sources_title }}

{{ t.processing_recent_sources_title }}

{% if errors.get('activity') %}{{ read_error(errors.activity, t.recent_processing) }} {% elif home_activity %}
{% for item in home_activity[:3] %}{% endfor %}
{{ t.processing_source_saved_time }}{{ t.home_activity_result }}{{ t.home_activity_input }}
{% for family in item.artifact_families or [] %}{{ artifact_type(family) }}{% else %}{{ 'Unknown' if item.artifact_families is none else 'None' }}{% endfor %}
{{ item.title|truncate(180,true) }}
{% else %}
{{ t.recent_processing_empty }} · {{ t.home_processing_unknown }}{{ t.processing_sources }} →
{% endif %}

{{ t.home_saved_content_heading }}

{{ t.recent_saved_content }}

{{ t.view_notes }} →
{% macro change_table(items) %}
{% for item in items %}{% endfor %}
{{ t.home_activity_time }}{{ t.home_saved_type_version }}{{ t.home_saved_content }}
{{ item.family_label }}{{ t.revision }} {{ item.revision }} {% if item.url %}{{ item.title|truncate(180,true) }}{% else %}{{ t.home_change_unreadable }}{% endif %}
{% endmacro %} {% if errors.get('changes') %}{{ read_error(errors.changes, t.notes) }} {% elif home_changes %}{{ change_table(home_changes[:3]) }} {% elif data.notes %}
{% for item in data.notes %}
{{ item.text|truncate(140,true) }}
{% endfor %}
{% elif errors.get('notes') %}{{ read_error(errors.notes, t.notes) }}{% else %}
{{ t.notes_empty_body }}
{% endif %}
{% for family in ['experience','skill'] if errors.get(family) %}{{ read_error(errors[family],t[family]) }}{% endfor %}