Skip to content

Commit 0cb6e02

Browse files
Merge pull request #969 from creativecommons/correct-hero
align hero area of homepage to better align with vocabulary norms
2 parents 798373a + ce39c46 commit 0cb6e02

File tree

2 files changed

+65
-26
lines changed

2 files changed

+65
-26
lines changed

assets/static/css/style.css

Lines changed: 59 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -348,33 +348,60 @@ main > aside.sidebar nav.filter-menu ul li.current a {
348348
font-size: 1rem;
349349
}
350350

351+
.home-page .topic-summary {
352+
grid-column: 2 / span 9;
353+
display: grid;
354+
grid-template:
355+
"title graphic graphic"
356+
"description graphic graphic"
357+
"button graphic graphic";
358+
display: grid;
359+
grid-template-columns: 1fr 1fr;
360+
margin-bottom: 6.4em;
361+
gap: 0 4em;
362+
}
351363

352-
@media (min-width: 1024px) {
353-
.hero-section img {
354-
width: auto;
355-
}
364+
.home-page .topic-summary h2 {
365+
grid-area: title;
356366

357-
.hero-section {
358-
display: grid;
359-
grid-column: 2 / span 9;
360-
grid-template:
361-
"title title title"
362-
"description description description "
363-
"graphic graphic graphic";
367+
font-size: 2.4em;
368+
}
364369

365-
margin-bottom: 6.4em;
366-
gap: 0 4em;
367-
}
370+
.home-page .topic-summary img {
371+
width: 100%;
372+
grid-area: graphic;
373+
margin-top: 3.1em;
374+
}
368375

369-
.hero-section h2 {
370-
grid-area: title;
371-
}
376+
.home-page .topic-summary figure {
377+
width: 100%;
378+
grid-area: graphic;
379+
margin: 0;
380+
padding: 0;
381+
margin-top: .6em;
382+
}
372383

373-
.hero-description {
374-
grid-area: description;
375-
width: 41.67%
376-
}
384+
.home-page .topic-summary .description {
385+
grid-area: description;
386+
}
387+
388+
.home-page .topic-summary .description p {
389+
margin-bottom: 1em;
390+
}
391+
392+
.home-page .topic-summary .description a {
393+
display: inline;
394+
box-sizing: border-box;
395+
grid-column-start: 1;
396+
grid-row-start: 3;
397+
398+
text-transform: uppercase;
399+
font-size: 1.5em;
400+
font-weight: 700;
401+
}
377402

403+
404+
@media (min-width: 1024px) {
378405
.projects ul {
379406
grid-template-columns: 1fr 1fr;
380407

@@ -431,3 +458,14 @@ main > aside.sidebar nav.filter-menu ul li.current a {
431458
margin-top: -6rem;
432459
}
433460
}
461+
462+
@media (max-width: 900px) {
463+
.home-page .topic-summary {
464+
display: block;
465+
}
466+
467+
.home-page .topic-summary figure {
468+
display: none;
469+
}
470+
}
471+
Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
<article class="hero-section">
1+
<article class="topic-summary">
22
<h2> {{ this.title }} </h2>
3-
<div class="hero-description">
4-
{{ this.links }}
5-
</div>
6-
<div class="hero-image">
3+
<figure>
74
<img class="image" src="./github.svg" />
5+
</figure>
6+
<div class="description">
7+
{{ this.links }}
88
</div>
9+
910
</article>

0 commit comments

Comments
 (0)