experiences.html 1.1 KB

123456789101112131415161718192021222324252627282930
  1. {{ $sectionID := replace (lower .section.name) " " "-" }}
  2. {{ if .section.id }}
  3. {{ $sectionID = .section.id }}
  4. {{ end }}
  5. <div class="container-fluid anchor pb-5 experiences-section" id="{{ $sectionID }}">
  6. {{ if not (.section.hideTitle) }}
  7. <h1 class="text-center">{{ .section.name }}</h1>
  8. {{ end }}
  9. <div class="container timeline text-justify">
  10. {{ $totalExperiences:= len .experiences }}
  11. {{ range $index,$experience:= .experiences }}
  12. {{ if eq (mod $index 2) 0 }}
  13. <div class="row align-items-center d-flex">
  14. {{ partial "sections/experiences/vertical-line.html" $index }}
  15. {{ partial "sections/experiences/experience-info.html" $experience }}
  16. </div>
  17. {{else}}
  18. <div class="row align-items-center justify-content-end d-flex">
  19. {{ partial "sections/experiences/experience-info.html" $experience }}
  20. {{ partial "sections/experiences/vertical-line.html" $index }}
  21. </div>
  22. {{ end }}
  23. {{ if lt $index (sub $totalExperiences 1) }}
  24. {{ partial "sections/experiences/horizontal-line.html" $index }}
  25. {{ end }}
  26. {{ end }}
  27. </div>
  28. </div>