{% assign file = page.fileName %} {% assign lang = page.lang %} {% assign folder = page.folderName %} {% assign featureData= site.data[folder][lang][file] %} <section class="authors-list"> <div class="container"> <div class="row"> <div class="col-md-12"> {%- if featureData.author -%} <h3 class="mb-4 text-center authors-heading font-weight-bolder"> About The Author </h3> {%- endif -%} <div class="row"> {%- if featureData.author -%} {%- include authors/authors.html -%} {%- assign featureAuthor = featureData.author | split: " " -%} {%- assign author = featureAuthor.first | downcase -%} {%- assign collection = [author] -%} {%- for item in collection -%} {%- if forloop.index==1 -%} {%- assign featureAuthorName = item -%} {%- endif -%} {%- if forloop.index==2 -%} {%- assign featureAuthorImage = item -%} {%- endif -%} {%- if forloop.index==3 -%} {%- assign featureAuthorBio = item -%} {%- endif %} {%- endfor %} <div class="featurePageAuthor"> <a href="/authors/{{featureAuthor | downcase | replace: ' ' , '-'' }}" class="author_image" > <img class="author-img" loading="lazy" src="{{ featureAuthorImage }}" height="35px" width="35px" alt="{{ featureAuthor}}" id="author_img" {%- if site.crossorigin -%} crossorigin {%- endif -%} /> </a> <div class="author-meta"> <p class="mb-0 authorName text-capitalize"> <a target="_blank" href="/authors/{{featureAuthor | downcase | replace: ' ' , '-'' }}" > {{featureAuthor}} </a> </p> <p class="author_bio mb-0">{{featureAuthorBio}}</p> </div> </div> {%- endif %} {%- assign contributors = featureData.contributors | uniq: 'name' -%} {%- if contributors.size > 0 -%} <h3 class="mb-4 w-100 text-center authors-heading font-weight-bolder"> Contributors </h3> <div class="d-flex justify-content-center w-100" style="gap: 10px"> {%- for contributor in contributors -%} {%- assign featureContributorData = contributor.name | split: " " -%} {%- assign featureContributorData = featureContributorData.first | downcase -%} {%- assign collectionData = [featureContributorData] -%} {%- for item in collectionData -%} {%- if forloop.index == 1 -%} {%- assign featureContributorDataName = item -%} {%- endif -%} {%- if forloop.index == 2 -%} {%- assign featureContributorDataImage = item -%} {%- endif -%} {%- if forloop.index == 3 -%} {%- assign featureContributorDataBio = item -%} {%- endif -%} {%- if forloop.index == 4 -%} {%- assign featureContributorDataTwitter = item -%} {%- endif -%} {%- endfor -%} {%- if featureContributorDataName -%} <a href="/authors/{{featureContributorDataName | downcase | replace: ' ' , '-'' }}" class="contributor" > <img loading="lazy" src="{{ featureContributorDataImage }}" alt="{{ featureContributorDataName}}" style="border-radius: 100%; width: 50px; height: 50px" /> <div class="contributor-name"> {{ featureContributorDataName }} </div> </a> {%- assign featureContributorDataName = false -%} {%- else -%} {%- endif -%} {%- endfor -%} </div> {%- endif -%} </div> </div> </div> </div> </section>