Skip to content

Commit

Permalink
ui: Show start new translation only if available
Browse files Browse the repository at this point in the history
  • Loading branch information
nijel committed Jun 29, 2023
1 parent 813c4d6 commit 69f5929
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion weblate/templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,10 @@
<li><a href="{% url 'create-project' %}">{% trans "Add new translation project" %}</a></li>
<li><a href="{% url 'create-component' %}{% if project %}?project={{ project.id }}{% endif %}">{% trans "Add new translation component" %}</a></li>
{% if component %}
<li><a href="{% url "new-language" project=component.project.slug component=component.slug %}">{% trans "Start new translation" %}</a></li>
{% perm 'translation.add' component as user_can_add_translation %}
{% if user_can_add_translation %}
<li><a href="{% url "new-language" project=component.project.slug component=component.slug %}">{% trans "Start new translation" %}</a></li>
{% endif %}
{% endif %}
{% if offer_hosting %}
<li role="separator" class="divider"></li>
Expand Down

0 comments on commit 69f5929

Please sign in to comment.