Skip to content

Commit

Permalink
feat: profile picture on the main page
Browse files Browse the repository at this point in the history
  • Loading branch information
jvmonjo committed Feb 22, 2024
1 parent b206bfe commit 7493207
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 0 deletions.
16 changes: 16 additions & 0 deletions assets/css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -428,6 +428,22 @@ html {
height: 100%;
object-fit: cover; } }

.authors-container {
display: flex;
justify-content: center;
gap: 20px; }

.author-image-container {
width: 100px;
height: 100px;
border-radius: 50%;
overflow: hidden;
border: 2px solid white; }
.author-image-container img {
width: 100%;
height: 100%;
object-fit: cover; }

.post-card-image {
max-width: 800px;
height: 150px; }
Expand Down
1 change: 1 addition & 0 deletions index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
<header class="blog-header {{#if @site.cover_image}} has-cover{{/if}}">
<div class="inner">
<div class="box blog-box">
{{> "primary-author"}}
<h1 class="blog-name">{{@site.title}}</h1>
{{#if @site.description}}
<span class="blog-description">{{@site.description}}</span>
Expand Down
10 changes: 10 additions & 0 deletions partials/primary-author.hbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{{#get "authors"}}
{{! Loop through authors }}
<div class="authors-container">
{{#foreach authors}}
<div class="author-image-container">
<img class="author-profile-image" src='{{ profile_image }}' alt='{{ name }}'>
</div>
{{/foreach}}
</div>
{{/get}}
19 changes: 19 additions & 0 deletions src/sass/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,25 @@ html {
}
}

.authors-container {
display: flex;
justify-content: center;
gap: 20px;
}

.author-image-container {
width: 100px;
height: 100px;
border-radius: 50%;
overflow: hidden;
border: 2px solid white;
img {
width: 100%;
height: 100%;
object-fit: cover;
}
}

.post-card-image {
max-width: 800px;
height: 150px;
Expand Down

0 comments on commit 7493207

Please sign in to comment.