-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Set up the headings and the meta block that goes under the title.
- Loading branch information
Showing
8 changed files
with
124 additions
and
5 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
@import './vars'; | ||
@import './mixins'; | ||
@import './typography'; | ||
|
||
.article { | ||
h1.article--title { | ||
font-size: 2.5rem; | ||
margin-bottom: 2rem; | ||
} | ||
|
||
h2 { | ||
font-size: 1.75rem; | ||
margin-top: 2.5rem; | ||
} | ||
|
||
h3 { | ||
font-size: 1.225rem; | ||
margin-top: 1.28rem; | ||
} | ||
|
||
&--subtitle { | ||
display: flex; | ||
flex-direction: row; | ||
flex-wrap: wrap; | ||
gap: .75rem; | ||
justify-content: space-between; | ||
margin-bottom: 2.625rem; | ||
font-size: .875rem; | ||
} | ||
|
||
&--meta { | ||
display: flex; | ||
flex-direction: row; | ||
flex-wrap: wrap; | ||
gap: .75rem; | ||
} | ||
|
||
&--author { | ||
font-weight: 600; | ||
} | ||
|
||
&--userpic { | ||
width: 1.5rem; | ||
height: 1.5rem; | ||
border-radius: 0.75rem; | ||
} | ||
|
||
&--follow { | ||
display: flex; | ||
flex-direction: row; | ||
gap: 1rem; | ||
} | ||
|
||
img { | ||
max-width: 100%; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
@import './about'; | ||
@import './article'; | ||
@import './blog'; | ||
@import './btn'; | ||
@import './contact'; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
[minute_with_count] | ||
one = '{{ . }} minute' | ||
other = '{{ . }} minutes' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,48 @@ | ||
<h1>{{ .Title }}</h1> | ||
<time datetime="{{ .Date | time.Format "2006-01-02" }}"> | ||
{{ .Date | time.Format ":date_medium" }} | ||
</time> | ||
{{ .Content }} | ||
{{- define "main" }} | ||
<div class="page article"> | ||
<article class="narrow-container"> | ||
<h1 class="article--title">{{ .Title }}</h1> | ||
|
||
<div class="article--subtitle"> | ||
<div class="article--meta"> | ||
<div> | ||
<img | ||
class="article--userpic" | ||
src="{{ printf "/img/userpics/%s.png" (urlize .Params.author) }}" | ||
/> | ||
</div> | ||
|
||
<div class="article--author">{{ .Params.author }}</div> | ||
|
||
<time datetime="{{ .Date | time.Format "2006-01-02" }}"> | ||
{{ .Date | time.Format ":date_long" }} | ||
</time> | ||
|
||
<div>|</div> | ||
|
||
<div> | ||
{{ | ||
T "minute_with_count" .ReadingTime | ||
| printf "Estimated %s read" | ||
}} | ||
</div> | ||
</div> | ||
|
||
<div class="article--follow"> | ||
<div>Follow us:</div> | ||
<div> | ||
<img src="{{ (resources.Get "img/ico-x.svg").RelPermalink }}" /> | ||
</div> | ||
<div> | ||
<img | ||
src="{{ (resources.Get "img/ico-youtube.svg").RelPermalink }}" | ||
/> | ||
</div> | ||
{{- /* TODO: Social links */}} | ||
</div> | ||
</div> | ||
|
||
{{ .Content }} | ||
</article> | ||
</div> | ||
{{- end }} |