Support for cicular image (#728)

This commit is contained in:
Rohan Deb Sarkar 2022-06-26 13:50:45 +05:30 committed by GitHub
parent bb5ef8fafb
commit bcd43a18fe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 1 deletions

View File

@ -16,9 +16,16 @@ layout: default
<div class="profile float-{%- if page.profile.align == 'left' -%}left{%- else -%}right{%- endif -%}">
{%- if page.profile.image %}
{%- assign profile_image_path = page.profile.image | prepend: 'assets/img/' -%}
{% if page.profile.image_cicular %}
{%- assign profile_image_class = "img-fluid z-dept-1 rounded-circle" -%}
{% else %}
{%- assign profile_image_class = "img-fluid z-dept-1 rounded" -%}
{% endif %}
{% include figure.html
path=profile_image_path
class="img-fluid z-dept-1 rounded"
class=profile_image_class
alt=page.profile.image -%}
{% endif -%}
{%- if page.profile.address %}

View File

@ -7,6 +7,7 @@ subtitle: <a href='#'>Affiliations</a>. Address. Contacts. Moto. Etc.
profile:
align: right
image: prof_pic.jpg
image_cicular: false # crops the image to make it circular
address: >
<p>555 your office number</p>
<p>123 your address street</p>