nunjuck template for updatenotification

This commit is contained in:
Felix Wiedenbach 2021-09-18 03:55:32 +02:00
parent c2d2c278e0
commit 1dfa5d383c
2 changed files with 18 additions and 0 deletions

View File

@ -0,0 +1,3 @@
.module.updatenotification a.difflink {
text-decoration: none;
}

View File

@ -0,0 +1,15 @@
{% if not suspended %}
{% for name, status in moduleList %}
<div class="small bright">
<i class="fa fa-exclamation-circle"></i>
<span>
{% set mainTextLabel = "UPDATE_NOTIFICATION" if name === "default" else "UPDATE_NOTIFICATION_MODULE" %}
{{ mainTextLabel | translate({MODULE_NAME: name}) }}
</span>
</div>
<div class="xsmall dimmed">
{% set subTextLabel = "UPDATE_INFO_SINGLE" if status.behind === 1 else "UPDATE_INFO_MULTIPLE" %}
{{ subTextLabel | translate({COMMIT_COUNT: status.behind, BRANCH_NAME: status.current}) | diffLink(status) | safe }}
</div>
{% endfor %}
{% endif %}