locale-translation-update-info.html.twig

Same filename in this branch
  1. 10 core/modules/locale/templates/locale-translation-update-info.html.twig
Same filename in other branches
  1. 9 core/themes/stable9/templates/admin/locale-translation-update-info.html.twig
  2. 9 core/themes/stable/templates/admin/locale-translation-update-info.html.twig
  3. 9 core/modules/locale/templates/locale-translation-update-info.html.twig
  4. 8.9.x core/themes/stable/templates/admin/locale-translation-update-info.html.twig
  5. 8.9.x core/modules/locale/templates/locale-translation-update-info.html.twig
  6. 11.x core/themes/stable9/templates/admin/locale-translation-update-info.html.twig
  7. 11.x core/modules/locale/templates/locale-translation-update-info.html.twig

Theme override for displaying translation status information.

Displays translation status information per language.

Available variables:

  • modules: A list of modules names that have available translation updates.
  • updates: A list of available translation updates.
  • not_found: A list of modules missing translation updates.

See also

template_preprocess_locale_translation_update_info()

1 theme call to locale-translation-update-info.html.twig
TranslationStatusForm::buildForm in core/modules/locale/src/Form/TranslationStatusForm.php
Form builder for displaying the current translation status.

File

core/themes/stable9/templates/admin/locale-translation-update-info.html.twig

View source
  1. {#
  2. /**
  3. * @file
  4. * Theme override for displaying translation status information.
  5. *
  6. * Displays translation status information per language.
  7. *
  8. * Available variables:
  9. * - modules: A list of modules names that have available translation updates.
  10. * - updates: A list of available translation updates.
  11. * - not_found: A list of modules missing translation updates.
  12. *
  13. * @see template_preprocess_locale_translation_update_info()
  14. */
  15. #}
  16. <div class="locale-translation-update__wrapper" tabindex="0" role="button">
  17. <span class="locale-translation-update__prefix visually-hidden">Show description</span>
  18. {% if modules %}
  19. {% set module_list = modules|safe_join(', ') %}
  20. <span class="locale-translation-update__message">{% trans %}Updates for: {{ module_list }}{% endtrans %}</span>
  21. {% elseif not_found %}
  22. <span class="locale-translation-update__message">
  23. {%- trans -%}
  24. Missing translations for one project
  25. {%- plural not_found|length -%}
  26. Missing translations for @count projects
  27. {%- endtrans -%}
  28. </span>
  29. {% endif %}
  30. {% if updates or not_found %}
  31. <div class="locale-translation-update__details">
  32. {% if updates %}
  33. <ul>
  34. {% for update in updates %}
  35. <li>{{ update.name }} ({{ update.timestamp|format_date('html_date') }})</li>
  36. {% endfor %}
  37. </ul>
  38. {% endif %}
  39. {% if not_found %}
  40. {#
  41. Prefix the missing updates list if there is an available updates lists
  42. before it.
  43. #}
  44. {% if updates %}
  45. {{ 'Missing translations for:'|t }}
  46. {% endif %}
  47. {% if not_found %}
  48. <ul>
  49. {% for update in not_found %}
  50. <li>{{ update.name }} ({{ update.version|default('no version'|t) }}). {{ update.info }}</li>
  51. {% endfor %}
  52. </ul>
  53. {% endif %}
  54. {% endif %}
  55. </div>
  56. {% endif %}
  57. </div>

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.