You are here

toc-back-to-top.html.twig in TOC API 8

Default theme implementation to display a back to top link.

Returns HTML for a back to top link.

Available variables:

  • item: A table of contents header item.
  • options: Options associated with the current header item.

File

templates/toc-back-to-top.html.twig
View source
  1. {#
  2. /**
  3. * @file
  4. * Default theme implementation to display a back to top link.
  5. *
  6. * Returns HTML for a back to top link.
  7. *
  8. * Available variables:
  9. * - item: A table of contents header item.
  10. * - options: Options associated with the current header item.
  11. *
  12. * @ingroup themeable
  13. */
  14. #}
  15. {% set classes = ['back-to-top'] %}
  16. <a{{ attributes.addClass(classes) }}>{{ label }}</a>