hugo-toha/layouts/partials/sections/experiences.html
Reyhan 6e41689c06
Fixed section landing position on navigation #154 (#436)
* Fixed alignment issue in tables under education(#233)

* Fixed section landing position on navigation

Co-authored-by: Emruz Hossain <hossainemruz@gmail.com>
2021-10-18 18:16:10 +00:00

32 lines
No EOL
1.1 KiB
HTML

{{ $sectionID := replace (lower .section.name) " " "-" }}
{{ if .section.id }}
{{ $sectionID = .section.id }}
{{ end }}
<div class="container-fluid anchor pb-5 experiences-section">
{{ if not (.section.hideTitle) }}
<h1 class="text-center">
<span id="{{ $sectionID }}"></span>{{ .section.name }}
</h1>
{{ end }}
<div class="container timeline text-justify">
{{ $totalExperiences:= len .experiences }}
{{ range $index,$experience:= .experiences }}
{{ if eq (mod $index 2) 0 }}
<div class="row align-items-center d-flex">
{{ partial "sections/experiences/vertical-line.html" $index }}
{{ partial "sections/experiences/experience-info.html" $experience }}
</div>
{{else}}
<div class="row align-items-center justify-content-end d-flex">
{{ partial "sections/experiences/experience-info.html" $experience }}
{{ partial "sections/experiences/vertical-line.html" $index }}
</div>
{{ end }}
{{ if lt $index (sub $totalExperiences 1) }}
{{ partial "sections/experiences/horizontal-line.html" $index }}
{{ end }}
{{ end }}
</div>
</div>