base.html.twig 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  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. <link
  17. rel="stylesheet"
  18. href="https://cdn.jsdelivr.net/npm/swiper@11/swiper-bundle.min.css"
  19. />
  20. {% endblock %}
  21. {% block javascripts %}
  22. {% do assets.addJs('jquery', 100) %}
  23. <script src="https://unpkg.com/@barba/core"></script>
  24. {% do assets.addJs('theme://js/libraries/lazy/jquery.lazy.min.js', 99) %}
  25. <script src="https://unpkg.com/animate-css-grid@1.4.3"></script>
  26. {% do assets.addJs('theme://js/libraries/gsap/gsap.min.js', 96) %}
  27. <script src="https://cdn.jsdelivr.net/npm/swiper@11/swiper-bundle.min.js"></script>
  28. {% endblock %}
  29. {% block assets deferred %}
  30. {{ assets.css()|raw }}
  31. {{ assets.js()|raw }}
  32. {% endblock %}
  33. </head>
  34. <body id="top" class="{{ page.header.body_classes|e }}" data-barba="wrapper">
  35. {% block header %}
  36. <header>
  37. {% block header_navigation %}
  38. {% include 'partials/navigation.html.twig' %}
  39. {% endblock %}
  40. </header>
  41. {% endblock %}
  42. {% block body %}
  43. <main>
  44. {% block content %}{% endblock %}
  45. </main>
  46. {% endblock %}
  47. {% block footer %}
  48. {% set contact = { items: {'@page.self': '/home/contact'} } %}
  49. <footer>
  50. {% for item in page.collection(contact) %}
  51. {{item.content}}
  52. {% endfor %}
  53. </footer>
  54. {% endblock %}
  55. {% block bottom %}
  56. {{ assets.js('bottom')|raw }}
  57. {% do assets.addJs('theme://js/script.js', 94) %}
  58. {% endblock %}
  59. </body>
  60. </html>