update-version.html.twig

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

Theme override for the version display of a project.

Available variables:

  • attributes: HTML attributes suitable for a container element.
  • title: The title of the project.
  • core_compatibility_details: Render array of core compatibility details.
  • version: A list of data about the latest released version, containing:
    • version: The version number.
    • date: The date of the release.
    • download_link: The URL for the downloadable file.
    • release_link: The URL for the release notes.
    • core_compatible: A flag indicating whether the project is compatible with the currently installed version of Drupal core. This flag is not set for the Drupal core project itself.
    • core_compatibility_message: A message indicating the versions of Drupal core with which this project is compatible. This message is also contained within the 'core_compatibility_details' variable documented above. This message is not set for the Drupal core project itself.

See also

template_preprocess_update_version()

1 theme call to update-version.html.twig
template_preprocess_update_project_status in core/modules/update/update.report.inc
Prepares variables for update project status templates.

File

core/themes/claro/templates/admin/update-version.html.twig

View source
  1. {#
  2. /**
  3. * @file
  4. * Theme override for the version display of a project.
  5. *
  6. * Available variables:
  7. * - attributes: HTML attributes suitable for a container element.
  8. * - title: The title of the project.
  9. * - core_compatibility_details: Render array of core compatibility details.
  10. * - version: A list of data about the latest released version, containing:
  11. * - version: The version number.
  12. * - date: The date of the release.
  13. * - download_link: The URL for the downloadable file.
  14. * - release_link: The URL for the release notes.
  15. * - core_compatible: A flag indicating whether the project is compatible
  16. * with the currently installed version of Drupal core. This flag is not
  17. * set for the Drupal core project itself.
  18. * - core_compatibility_message: A message indicating the versions of Drupal
  19. * core with which this project is compatible. This message is also
  20. * contained within the 'core_compatibility_details' variable documented
  21. * above. This message is not set for the Drupal core project itself.
  22. *
  23. * @see template_preprocess_update_version()
  24. */
  25. #}
  26. <div class="{{ attributes.class }} project-update__version"{{ attributes|without('class') }}>
  27. <div class="layout-row clearfix">
  28. <div class="project-update__version-title layout-column layout-column--quarter">{{ title }}</div>
  29. <div class="project-update__version-details layout-column layout-column--quarter">
  30. <a href="{{ version.release_link }}">{{ version.version }}</a>
  31. <span class="project-update__version-date">({{ version.date|date('Y-M-d') }})</span>
  32. </div>
  33. <div class="layout-column layout-column--half">
  34. <ul class="project-update__version-links">
  35. <li class="project-update__release-notes-link">
  36. <a href="{{ version.release_link }}">{{ 'Release notes'|t }}</a>
  37. </li>
  38. {% if core_compatibility_details %}
  39. <li class="project-update__compatibility-details">
  40. {{ core_compatibility_details }}
  41. </li>
  42. {% endif %}
  43. </ul>
  44. </div>
  45. </div>
  46. </div>

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