Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@ dist/
assets/.DS_Store
.DS_Store
.idea/
package-lock.json
4 changes: 2 additions & 2 deletions assets/css/screen.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions assets/scss/screen.scss
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@
@import "theme/footer";
@import "theme/media";
@import "theme/koenig";
@import "theme/homepage.scss";
65 changes: 65 additions & 0 deletions assets/scss/theme/homepage.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
/* ==========================================================================
Homepage CSS Styling
========================================================================== */



.introduction{
display: flex;
flex-direction: column;
&-title{
align-self: center;
font-size: 2.5rem;
}

&-container{
display: flex;
flex-direction: column;
p {
font-size: 1.7rem;
order: 2;
}
&-img{
flex-basis: auto;
align-self: center;
max-width: 300px;
height: 300px;
border-radius: 5px;
order: 1;
}
}
&-post-container{
display: flex;
flex-direction: column;
h2{
align-self: center;
font-size: 2.5rem;
}
}
&-post{
position: relative;
width: 100%;
max-width: 700px;
margin: 0 auto;
word-break: break-word;
-webkit-hyphens: auto;
-ms-hyphens: auto;
hyphens: auto;
}
@media screen and (min-width: 700px) {
&-container{
display: flex;
flex-basis: auto;
flex-direction: row;
justify-content: space-between;
&-img{
flex-basis: auto;
width: 40%;
height: 250px;
border-radius: 5px;
margin: 5%;
order: 2;
}
}
}
}
64 changes: 62 additions & 2 deletions assets/scss/theme/post.scss
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,41 @@
max-width: 100%;
margin: 0 auto;
}

&-subscribe {
display: flex;
flex-direction: column;
align-items: center;
padding: 2%;
border: 1px solid #1d2027;
border-radius: 25px;
background:#1d2027;
z-index: 1;
box-shadow: 0px 0px 15px #1d2027;
h3 {
font-size: 1.5em;
}
p {
font-size: 0.9em;
}
.submit-button {
border-radius: 25px;
transition: background-color 0.3s ease !important;
}
form {
width: 100%;
div {
width: 100%;
text-align: center;
}
text-align: center;
}
input {
border-radius: 5px;
width: 20em;
text-align: center
}
}
&-footer {
position: relative;
margin: 4rem 0 0 0;
Expand All @@ -43,15 +78,40 @@
top: 4rem;
right: 0;
width: 140px;
display: inline-block;
a {
font-size: 1.8rem;
display: inline-block;
margin: 1.4rem 1.6rem 1.6rem 0;
color: #BBC7CC;
&:hover {
color: #50585D;
}
}
}
@media screen and (min-width: 501px) {
.share {
position: absolute;
top: 4rem;
right: 0;
width: 140px;
display: flex;
flex-direction: row;
justify-content: center;
flex-wrap: wrap;
h4 {
flex-grow: 1;
flex-shrink: 0;
}
a {
font-size: 1.8rem;
margin: 1.4rem 1.6rem 1.6rem 0;
color: #BBC7CC;
flex-grow: 0;
&:hover {
color: #50585D;
}
}
}
}
}
}
}
19 changes: 19 additions & 0 deletions assets/scss/theme/theme.scss
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,19 @@
}
}
}
&-feature-image {
width: 100%;
height: 300px;
background: $background no-repeat center center;
object-fit: cover
}

&-feature-image-link {
position: relative;
display: block;
overflow: hidden;
border-radius: 5px 5px 0 0;
}
&-excerpt p {
margin: 1.6rem 0 0 0;
font-size: 0.9em;
Expand All @@ -116,6 +129,12 @@
color: lighten(#846d8f, 10%);
}
}
&-meta-reading-time {
margin: 0;
display: block;
font-size: 1.5rem;
color: #846d8f;
}

&-header {
a {
Expand Down
7 changes: 7 additions & 0 deletions assets/scss/theme/utilites.scss
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,14 @@
margin: 0 auto;
}

@media screen and (max-width: 700px){
.inner{
width: 95%
}
}

/* Centres vertically yo. (IE8+) */
/* table-cell display lets it behave like a table-cell */
.vertical {
display: table-cell;
vertical-align: middle;
Expand Down
53 changes: 53 additions & 0 deletions blog.hbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
{{!< default}}

{{! The comment above "< default" means - insert everything in this file into
the {body} of the default.hbs template, which contains our header/footer. }}

{{! The big featured header on the homepage, with the site logo and description }}
<header id="site-head" {{#if @site.cover_image}}style="background-image: url({{@site.cover_image}})"{{/if}}>
<div class="vertical animated bounceInDown">
<div id="site-head-content" class="inner">

{{#if @site.logo}}<a id="blog-logo" href="{{@site.url}}"><img src="{{@site.logo}}" alt="Blog Logo" /></a>{{/if}}
<h1 class="blog-title">{{@site.title}}</h1>
<h2 class="blog-description">{{@site.description}}</h2>
{{> "site-nav"}}
</div>
</div>
</header>

{{! The main content area on the homepage }}
<main class="content" role="main">

{{! Each post will be output using this markup }}
{{#foreach posts}}

<article class="{{post_class}}">
<header class="post-header">
<span class="post-meta"><time datetime="{{date format='YYYY-MM-DD'}}">{{date format="DD MMM YYYY"}}</time> {{#if tags}}on {{tags}}{{/if}}</span>
<p class="post-meta-reading-time">{{reading_time}}</p>
<h2 class="post-title"><a href="{{url}}">{{{title}}}</a></h2>
{{#if feature_image}}
<a class="post-feature-image-link" href={{url}}>
<img class="post-feature-image"
srcset="{{img_url feature_image size="s"}} 300w,
{{img_url feature_image size="m"}} 600w,
{{img_url feature_image size="l"}} 1000w,
{{img_url feature_image size="xl"}} 2000w"
src="{{img_url feature_image size="m"}}"
sizes="(max-width: 1000px) 400px, 700px"
alt="{{title}}"
/>
</a>
{{/if}}
</header>
<section class="post-excerpt">
<p>{{excerpt}}&hellip;</p>
</section>
</article>

{{/foreach}}

{{!! After all the posts, we have the previous/next pagination links }}
{{pagination }}
</main>
4 changes: 2 additions & 2 deletions default.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@
{{{body}}}

<footer class="site-footer">
<!-- <a class="subscribe icon-feed" href="{{@blog.url}}/rss/"><span class="tooltip">Subscribe!</span></a> -->
<!-- <a class="subscribe icon-feed" href="{{@site.url}}/rss/"><span class="tooltip">Subscribe!</span></a> -->
<div class="inner">
<section class="copyright">All content copyright <a href="/">{{@blog.title}}</a> &copy; {{date format="YYYY"}} &bull; All rights reserved.</section>
<section class="copyright">All content copyright <a href="/">{{@site.title}}</a> &copy; {{date format="YYYY"}} &bull; All rights reserved.</section>
<section class="poweredby">Proudly published with <a class="icon-ghost" href="http://ghost.org"><span class="icon-ghost-text">Ghost</span></a> in <a href="https://github.com/mityalebedev/The-Shell">The Shell</a> theme.</section>
</div>
</footer>
Expand Down
64 changes: 64 additions & 0 deletions home.hbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
{{!< default}}


<header id="site-head" {{#if @site.cover_image}}style="background-image: url({{@site.cover_image}})"{{/if}}>
<div class="vertical animated bounceInDown">
<div id="site-head-content" class="inner">
{{#if @site.logo}}<a id="blog-logo" href="{{@site.url}}"><img src="{{@site.logo}}" alt="Blog Logo" /></a>{{/if}}
<h1 class="blog-title">{{@site.title}}</h1>
<h2 class="blog-description">{{@site.description}}</h2>
{{> "site-nav"}}
</div>
</div>
</header>

<main class="content" role = "main">
<div class="inner">
<article class="introduction">
<h1 class="introduction-title">👋 Welcome to my site 🌠!</h1>
<div class="introduction-container">
<p>
Hey there ! My name is Omar Nasr, a full stack developer based out of
Ottawa Ontario. My passion is to bring ideas to life and I especially love working on
projects that have the potential to change the status quo. The federal public service of
Canada is my current home.
</p>
<img
class="introduction-container-img"
src="/content/images/memojime.jpg">
</img>
</div>
</article>
<article class="introduction-post-container">
<h2> Read my latest post</h2>
{{#get "posts" limit="1" filter="tag:hash-blog"}}
{{! Each post will be output using this markup }}
{{#foreach posts}}
<article class="introduction-post">
<header class="post-header">
<span class="post-meta"><time datetime="{{date format='YYYY-MM-DD'}}">{{date format="DD MMM YYYY"}}</time> {{#if tags}}on {{tags}}{{/if}}</span>
<p class="post-meta-reading-time">{{reading_time}}</p>
<h2 class="post-title"><a href="{{url}}">{{{title}}}</a></h2>
{{#if feature_image}}
<a class="post-feature-image-link" href={{url}}>
<img class="post-feature-image"
srcset="{{img_url feature_image size="s"}} 300w,
{{img_url feature_image size="m"}} 600w,
{{img_url feature_image size="l"}} 1000w,
{{img_url feature_image size="xl"}} 2000w"
src="{{img_url feature_image size="m"}}"
sizes="(max-width: 1000px) 400px, 700px"
alt="{{title}}"
/>
</a>
{{/if}}
</header>
<section class="post-excerpt">
<p>{{excerpt}}&hellip;</p>
</section>
</article>
{{/foreach}}
{{/get}}
</article>
</div>
</main>
24 changes: 19 additions & 5 deletions index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
the {body} of the default.hbs template, which contains our header/footer. }}

{{! The big featured header on the homepage, with the site logo and description }}
<header id="site-head" {{#if @blog.cover_image}}style="background-image: url({{@blog.cover_image}})"{{/if}}>
<header id="site-head" {{#if @site.cover_image}}style="background-image: url({{@site.cover_image}})"{{/if}}>
<div class="vertical animated bounceInDown">
<div id="site-head-content" class="inner">

{{#if @blog.logo}}<a id="blog-logo" href="{{@blog.url}}"><img src="{{@blog.logo}}" alt="Blog Logo" /></a>{{/if}}
<h1 class="blog-title">{{@blog.title}}</h1>
<h2 class="blog-description">{{@blog.description}}</h2>
{{#if @site.logo}}<a id="blog-logo" href="{{@site.url}}"><img src="{{@site.logo}}" alt="Blog Logo" /></a>{{/if}}
<h1 class="blog-title">{{@site.title}}</h1>
<h2 class="blog-description">{{@site.description}}</h2>
{{> "site-nav"}}
</div>
</div>
Expand All @@ -25,7 +25,21 @@
<article class="{{post_class}}">
<header class="post-header">
<span class="post-meta"><time datetime="{{date format='YYYY-MM-DD'}}">{{date format="DD MMM YYYY"}}</time> {{#if tags}}on {{tags}}{{/if}}</span>
<p class="post-meta-reading-time">{{reading_time}}</p>
<h2 class="post-title"><a href="{{url}}">{{{title}}}</a></h2>
{{#if feature_image}}
<a class="post-feature-image-link" href={{url}}>
<img class="post-feature-image"
srcset="{{img_url feature_image size="s"}} 300w,
{{img_url feature_image size="m"}} 600w,
{{img_url feature_image size="l"}} 1000w,
{{img_url feature_image size="xl"}} 2000w"
src="{{img_url feature_image size="m"}}"
sizes="(max-width: 1000px) 400px, 700px"
alt="{{title}}"
/>
</a>
{{/if}}
</header>
<section class="post-excerpt">
<p>{{excerpt}}&hellip;</p>
Expand All @@ -35,5 +49,5 @@
{{/foreach}}

{{!! After all the posts, we have the previous/next pagination links }}
{{pagination}}
{{pagination }}
</main>
Loading