templates/pages/index-portfolio.html.twig line 1

Open in your IDE?
  1. {% extends 'base.html.twig' %}
  2. {% block title %}Portfolio — Raw Studio{% endblock %}
  3. {% block stylesheets %}
  4.     {{ parent() }}
  5.     <link rel="stylesheet" href="{{ asset('assets/css/portfolio.css') }}">
  6.     <link href="https://fonts.googleapis.com/css2?family=Archivo:wght@600;800;900&family=Work+Sans:wght@300;400;500;600&display=swap" rel="stylesheet">
  7. {% endblock %}
  8. {% block body %}
  9. <section class="hero">
  10.     <div class="eyebrow">NOS RÉALISATIONS</div>
  11.     <h1>Portfolio</h1>
  12.     <p>Chaque projet est une prise de vue brute, pensée pour raconter une histoire précise. Filtrez par service pour explorer nos réalisations.</p>
  13.     {# ---- Niveau 1 : catégories (Photo / Vidéographie...) ---- #}    
  14. </section>
  15. <div class="filters-wrap">
  16.     <div class="cat-tabs" id="catTabs" data-preselect="{{ preselectCategory }}">
  17.         {% for category in categories %}
  18.             <button class="cat-tab {{ preselectCategory == category.slug ? 'active' }}" data-cat="{{ category.slug }}">
  19.                 {{ category.name|upper }}
  20.             </button>
  21.         {% endfor %}
  22.     </div>
  23. </div>
  24. <div class="filters-wrap">    
  25.     {# ---- Niveau 2 : services, filtrés selon la catégorie active ---- #}
  26.     <div class="filters" id="filters" data-preselect="{{ preselectService }}">
  27.         <button class="pill {{ preselectService == 'all' ? 'active' }}" data-filter="all">TOUT</button>
  28.         {% for service in services %}
  29.             <button class="pill {{ preselectService == service.slug ? 'active' }}"
  30.                     data-filter="{{ service.slug }}"
  31.                     data-category="{{ service.categoryService.slug }}">
  32.                 {{ service.name|upper }}
  33.             </button>
  34.         {% endfor %}
  35.         <span class="count"><b id="countNum">{{ albums|length }}</b> projets</span>
  36.     </div>
  37. </div>
  38. <div class="grid" id="grid">
  39.     {% for album in albums %}
  40.         <div class="card" data-cat="{{ album.service.slug }}" data-category="{{ album.service.categoryService.slug }}">
  41.             <a href="{{ path('portfolio_albums', {serviceSlug:album.service.slug, id:album.id}) }}">
  42.                 <img src="{{ asset('assets/img/portfolio/cover/' ~ album.cover) }}" alt="{{ album.title }}" loading="lazy">
  43.                 <div class="corner tl"></div>
  44.                 <div class="corner tr"></div>
  45.                 <div class="corner bl"></div>
  46.                 <div class="corner br"></div>
  47.                 <div class="rec"><span class="dot"></span></div>
  48.                 <div class="overlay">
  49.                     <span class="tag">{{ album.service.name }}</span>
  50.                     <div class="title">{{ album.title }}</div>
  51.                     
  52.                 </div>
  53.             </a>
  54.         </div>
  55.     {% else %}
  56.         <p style="color:var(--muted)">Aucun album pour le moment.</p>
  57.     {% endfor %}
  58. </div>
  59. {% endblock %}
  60. {% block javascripts %}
  61.     {{ parent() }}
  62.     <script src="{{ asset('assets/js/portfolio.js') }}"></script>
  63. {% endblock %}