added contact and more

This commit is contained in:
Vrifox 2020-11-09 16:12:02 +01:00
parent 1c23a90826
commit 9ccc7b5bd7
7 changed files with 83 additions and 22 deletions

View file

@ -2,6 +2,7 @@
@import '../import/main.scss'; @import '../import/main.scss';
@import '../import/nav.scss'; @import '../import/nav.scss';
@import '../import/footer.scss'; @import '../import/footer.scss';
@import '../import/include.scss';
main { main {
margin: 60px 0 0 0; margin: 60px 0 0 0;

View file

@ -3,6 +3,7 @@
@import '../import/main.scss'; @import '../import/main.scss';
@import '../import/nav.scss'; @import '../import/nav.scss';
@import '../import/footer.scss'; @import '../import/footer.scss';
@import '../import/include.scss';
.section-article { .section-article {
article { article {
@ -21,17 +22,7 @@
margin-bottom: 15px; margin-bottom: 15px;
max-width: 100%; max-width: 100%;
} }
a { @include a-underlined;
border-bottom: 1px solid;
color: $white;
margin: -5px;
padding: 5px;
transition: border .2s, color .2s;
&:hover {
color: $red;
text-decoration: none;
}
}
h2 { h2 {
font-size: .6em; font-size: .6em;
} }

View file

@ -1,7 +1,8 @@
@import 'import/colors.scss'; @import 'import/colors.scss';
@import 'import/main.scss'; @import 'import/main.scss';
@import 'import/nav.scss'; @import 'import/nav.scss';
@import 'import/footer'; @import 'import/footer.scss';
@import 'import/include.scss';
header { header {
margin: 150px 0; margin: 150px 0;

View file

@ -0,0 +1,13 @@
@mixin a-underlined {
a {
border-bottom: 1px solid;
color: $white;
margin: -5px;
padding: 5px;
transition: border .2s, color .2s;
&:hover {
color: $red;
text-decoration: none;
}
}
}

View file

@ -2,28 +2,49 @@
@import 'import/main.scss'; @import 'import/main.scss';
@import 'import/nav.scss'; @import 'import/nav.scss';
@import 'import/footer.scss'; @import 'import/footer.scss';
@import 'import/include.scss';
.section.header { .section.header {
align-items: center; align-items: center;
background: $bg60; background: $bg60;
display: flex; display: flex;
height: 350px; @include a-underlined;
order: -1;
text-align: center;
header { header {
margin: 60px auto;
max-width: 600px; max-width: 600px;
margin: auto; text-align: center;
h1 { h1 {
font-size: 2.5em; font-size: 2.5em;
margin: auto; margin: auto;
} }
} }
.section.contact {
background: $bg70;
border-radius: 5px;
display: flex;
padding: 20px;
margin: 60px auto;
max-width: 500px;
.table.contact {
margin: 0 auto;
white-space: nowrap;
tr {
td {
&:first-of-type {
padding: 5px 30px 5px 0;
text-align: right;
}
}
}
}
}
} }
main { main {
margin: 60px 0 0 0; margin: 60px 0 0 0;
} }
.section.latest { .section.latest {
color: $white-dark; color: $white-dark;
font-size: 1.5em; font-size: 1.5em;
@ -85,11 +106,6 @@ main {
} }
} }
} }
@media (max-width: 900px) {
.section.articles {
grid-template-columns: repeat(1, 1fr);
}
}
.section.projects { .section.projects {
display: grid; display: grid;
@ -142,11 +158,35 @@ main {
} }
} }
@media (max-width: 900px) { @media (max-width: 900px) {
.section.articles {
grid-template-columns: repeat(1, 1fr);
}
.section.projects { .section.projects {
grid-template-columns: repeat(2, 1fr); grid-template-columns: repeat(2, 1fr);
} }
} }
@media (max-width: 600px) { @media (max-width: 600px) {
.section.header {
.section.contact {
border-radius: 0;
padding: 10px;
margin: 60px -20px;
max-width: none;
overflow-x: auto;
width: 100vw;
.table.contact {
margin: 0 auto;
white-space: nowrap;
tr {
td {
&:first-of-type {
padding: 5px 20px 5px 0;
}
}
}
}
}
}
.section.projects { .section.projects {
grid-template-columns: repeat(1, 1fr); grid-template-columns: repeat(1, 1fr);
} }

View file

@ -2,6 +2,7 @@
@import '../import/main.scss'; @import '../import/main.scss';
@import '../import/nav.scss'; @import '../import/nav.scss';
@import '../import/footer.scss'; @import '../import/footer.scss';
@import '../import/include.scss';
main { main {
margin: 60px 0 0 0; margin: 60px 0 0 0;

View file

@ -9,6 +9,20 @@
<h1>{{ .Params.heading }}</h1> <h1>{{ .Params.heading }}</h1>
<span class="subtitle">{{.Params.subheading}}</span> <span class="subtitle">{{.Params.subheading}}</span>
</header> </header>
<section class="section contact">
<table class="table contact">
{{ range sort .Params.contact "weight" "asc" }}
<tr>
<td>{{ .name }}</td>
<td>
{{ with .url }}<a href="{{ . }}">{{ end }}
{{ .handle }}
{{ with .url }}</a>{{ end }}
</td>
</tr>
{{ end }}
</table>
</section>
</div> </div>
</section> </section>
<main> <main>
@ -45,7 +59,7 @@
<a href="{{ .Permalink }}"> <a href="{{ .Permalink }}">
<article> <article>
<h1>{{ .Title }}</h1> <h1>{{ .Title }}</h1>
<p class="meta" title="last change: {{ .Date.Format "2 Jan 2006" }}">{{ with .Params.activetime }}<span class="date">{{ . }}</span>{{ end }} {{ with .Params.status }}<span class="status">{{ . }}</span>{{ end }}</p> <p class="meta">{{ with .Params.activetime }}<span class="date">{{ . }}</span>{{ end }} {{ with .Params.status }}<span class="status">{{ . }}</span>{{ end }}</p>
{{ with .Description }}<p>{{ . }}</p>{{ end }} {{ with .Description }}<p>{{ . }}</p>{{ end }}
<img {{ with .Params.featured_image }}src="{{ . | relURL }}"{{ end }} alt=""> <img {{ with .Params.featured_image }}src="{{ . | relURL }}"{{ end }} alt="">
</article> </article>