diff options
| author | Tobias McNulty <tobias@caktusgroup.com> | 2019-03-11 20:33:23 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-03-11 20:33:23 -0400 |
| commit | 68ecaee55c0e07f1b48bb681cbb249a9b50eab2f (patch) | |
| tree | bfe4d96f4a3f974533d99e6ed6da20b7709cb401 /dashboard | |
| parent | 0a6cf5cc7e1d8a0a6b5634ade5524ccc5b1f2da6 (diff) | |
Reorganized locale directories and added Transifex config for managing the translation process (#866)
Diffstat (limited to 'dashboard')
| -rw-r--r-- | dashboard/locale/en/LC_MESSAGES/django.po | 23 | ||||
| -rw-r--r-- | dashboard/locale/fr/LC_MESSAGES/django.po | 25 | ||||
| -rw-r--r-- | dashboard/templates/dashboard/detail.html | 13 | ||||
| -rw-r--r-- | dashboard/templates/dashboard/index.html | 25 |
4 files changed, 86 insertions, 0 deletions
diff --git a/dashboard/locale/en/LC_MESSAGES/django.po b/dashboard/locale/en/LC_MESSAGES/django.po new file mode 100644 index 00000000..7932aca1 --- /dev/null +++ b/dashboard/locale/en/LC_MESSAGES/django.po @@ -0,0 +1,23 @@ +# Copyright (C) Django Software Foundation and contributors +# This file is distributed under the same license as the djangoproject.com +# source files. +# +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2019-02-18 20:21-0500\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" +"Language-Team: LANGUAGE <LL@li.org>\n" +"Language: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +#: dashboard/templates/dashboard/index.html:22 +#, python-format +msgid "Updated %(timestamp)s ago." +msgstr "" diff --git a/dashboard/locale/fr/LC_MESSAGES/django.po b/dashboard/locale/fr/LC_MESSAGES/django.po new file mode 100644 index 00000000..7e6e8a8b --- /dev/null +++ b/dashboard/locale/fr/LC_MESSAGES/django.po @@ -0,0 +1,25 @@ +# Copyright (C) Django Software Foundation and contributors +# This file is distributed under the same license as the djangoproject.com +# source files. +# +# Translators: +# Tobias McNulty <tobias+dsf@caktusgroup.com>, 2019 +# +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2019-02-18 20:21-0500\n" +"PO-Revision-Date: 2019-02-21 14:15+0000\n" +"Last-Translator: Tobias McNulty <tobias+dsf@caktusgroup.com>, 2019\n" +"Language-Team: French (https://www.transifex.com/django/teams/17080/fr/)\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Language: fr\n" +"Plural-Forms: nplurals=2; plural=(n > 1);\n" + +#, python-format +msgid "Updated %(timestamp)s ago." +msgstr "Mis à jour il y a %(timestamp)s." diff --git a/dashboard/templates/dashboard/detail.html b/dashboard/templates/dashboard/detail.html new file mode 100644 index 00000000..25df49ba --- /dev/null +++ b/dashboard/templates/dashboard/detail.html @@ -0,0 +1,13 @@ +{% extends "base_dashboard.html" %} + +{% block title %}{{ metric }} | {{ block.super }}{% endblock %} + +{% block content %} +<div class="dashboard-detail"> + <h2><a href="{{ metric.link }}">{{ metric }}</a></h2> + <div class="graph-wrapper"> + <div id="graph" class="graph" data-path="{% url "metric-list" host "dashboard" %}" data-metric="{{ metric.slug }}"></div> + </div> + <a class="link-readmore back-link" href="{% url "dashboard-index" host "dashboard" %}">All metrics</a> +</div> +{% endblock %} diff --git a/dashboard/templates/dashboard/index.html b/dashboard/templates/dashboard/index.html new file mode 100644 index 00000000..2d03d86c --- /dev/null +++ b/dashboard/templates/dashboard/index.html @@ -0,0 +1,25 @@ +{% extends "base_dashboard.html" %} +{% load i18n %} + +{% block content %} +<div class="dashboard-index"> + {% for report in data %} + {% ifchanged report.metric.category %} + {% if report.metric.category %}<h2>{{ report.metric.category }}</h2>{% endif %} + {% endifchanged %} + <div class="metric{% if report.metric.show_sparkline %} has-sparkline{% endif %}"> + <h3><a href="{{ report.metric.link }}">{{ report.metric.name }}</a></h3> + <div class="value" > + <a href="{{ report.metric.get_absolute_url }}">{{ report.latest.measurement }}{% if report.metric.unit == "%" %}%{% endif %}</a> + <div class="timestamp"> </div> + </div> + {% if report.metric.show_sparkline %} + <div class="sparkline" id="spark{{ forloop.counter0 }}" data-path="{% url "metric-list" host "dashboard" %}" data-metric="{{ report.metric.slug }}"></div> + {% endif %} + </div> + {% endfor %} + <p class="updated"> + {% blocktrans with timestamp=data.0.latest.timestamp|timesince %}Updated {{ timestamp }} ago.{% endblocktrans %} + </p> +</div> +{% endblock %} |
