Files
notifications-admin/app/templates/views/user-profile.html
Chris Hill-Scott 39e94ac8ec Add row numbers to tables
When a table is showing the contents of a CSV file, it should look
something like a spreadsheet.

The minimally skeuomorphic way to do this is by adding row numbers.

This commit doesn’t
- make the row numbers monospace (it’s barely noticeable and doesn’t
  reflect what actual spreadsheets do)
- make the first column heading ‘Row’ (again, doesn’t reflect how actual
  spreadsheets work, and takes up more valuable space)
2016-04-06 11:31:37 +01:00

36 lines
1.1 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{% extends "withoutnav_template.html" %}
{% from "components/table.html" import list_table, row, field %}
{% block page_title %}
Your profile GOV.UK Notify
{% endblock %}
{% block maincolumn_content %}
<h1 class="heading-large">Your profile</h1>
{% call(item, row_number) list_table(
[
{'label': 'Name', 'value': current_user.name, 'url': url_for('.user_profile_name')},
{'label': 'Email address', 'value': current_user.email_address, 'url': url_for('.user_profile_email')},
{'label': 'Mobile number', 'value': current_user.mobile_number, 'url': url_for('.user_profile_mobile_number')},
{'label': 'Password', 'value': 'Last changed 1 January 2016, 10:00AM', 'url': url_for('.user_profile_password')},
],
caption='Account settings',
field_headings=['Setting', 'Value', 'Link to change'],
field_headings_visible=False,
caption_visible=False
) %}
{% call field() %}
{{ item.label }}
{% endcall %}
{% call field() %}
{{ item.value }}
{% endcall %}
{% call field(align='right') %}
<a href="{{ item.url }}">Change</a>
{% endcall %}
{% endcall %}
{% endblock %}