base.html.twig 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. <!DOCTYPE html>
  2. <html lang="{{ (grav.language.getActive ?: grav.config.site.default_lang)|e }}">
  3. <head>
  4. {% block head %}
  5. <meta charset="utf-8" />
  6. <title>{% if header.title %}{{ header.title|e }} | {% endif %}{{ site.title|e }}</title>
  7. <meta http-equiv="X-UA-Compatible" content="IE=edge">
  8. <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=0">
  9. {% include 'partials/metadata.html.twig' %}
  10. <link rel="icon" type="image/png" href="{{ url('theme://images/favicon.png')|e }}" />
  11. <link rel="canonical" href="{{ page.canonical(true)|e }}" />
  12. {% endblock head %}
  13. {% block stylesheets %}
  14. {% do assets.addCss('theme://css/theme.css', 95) %}
  15. {% do assets.addCss('theme://css/owl.carousel.min.css', 95) %}
  16. {% endblock %}
  17. {% block javascripts %}
  18. {% do assets.addJs('jquery', 100) %}
  19. <script src="https://unpkg.com/@barba/core"></script>
  20. <script src="https://unpkg.com/animate-css-grid@latest"></script>
  21. {% do assets.addJs('theme://js/libraries/lazy/jquery.lazy.min.js', 99) %}
  22. {% do assets.addJs('theme://js/libraries/blotter/blotter.min.js', 98) %}
  23. {% do assets.addJs('theme://js/libraries/blotter/liquidDistortMaterial.js', 97) %}
  24. {% do assets.addJs('theme://js/libraries/gsap/gsap.min.js', 96) %}
  25. {% do assets.addJs('theme://js/libraries/owl.carousel.min.js', 94) %}
  26. {% endblock %}
  27. {% block assets deferred %}
  28. {{ assets.css()|raw }}
  29. {{ assets.js()|raw }}
  30. {% endblock %}
  31. </head>
  32. <body id="top" class="{{ page.header.body_classes|e }}" data-barba="wrapper">
  33. {% block header %}
  34. <header>
  35. {% block header_navigation %}
  36. {% include 'partials/navigation.html.twig' %}
  37. {% endblock %}
  38. </header>
  39. {% endblock %}
  40. {% block body %}
  41. <main>
  42. {% block content %}{% endblock %}
  43. </main>
  44. {% endblock %}
  45. {% block footer %}
  46. {% set contact = { items: {'@page.self': '/home/contact'} } %}
  47. <footer>
  48. {% for item in page.collection(contact) %}
  49. {{item.content}}
  50. {% endfor %}
  51. </footer>
  52. {% endblock %}
  53. {% block bottom %}
  54. {{ assets.js('bottom')|raw }}
  55. {% do assets.addJs('theme://js/script.js', 94) %}
  56. {% endblock %}
  57. </body>
  58. </html>