Skip to content

Commit 6023d54

Browse files
committed
feat: center objects properly
1 parent 4ae87e1 commit 6023d54

5 files changed

Lines changed: 37 additions & 14 deletions

File tree

‎sass/_body.scss‎

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@ body {
2020
font-weight: 800;
2121
}
2222

23-
max-width: 1000px;
24-
margin-inline: auto;
23+
margin: 0;
24+
25+
div.content {
26+
max-width: $page-width;
27+
margin-inline: auto;
28+
}
2529
}

‎sass/_footer.scss‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
@use 'variables' as *;
2+
3+
@use 'sass:color';
4+
5+
@media (prefers-color-scheme: dark) {
6+
footer {
7+
background: #{
8+
color.adjust($dark-background-colour, $lightness: 3.5%)
9+
};
10+
}
11+
}

‎sass/_variables.scss‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
11
$dark-background-colour: hsl(279, 7%, 9%);
2-
$light-background-colour: #f2f2f3;
2+
$light-background-colour: #f2f2f3;
3+
4+
$page-width: 1000px;

‎sass/style.scss‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
@use 'fonts';
2+
@use 'variables';
3+
24
@use 'body';
3-
@use 'variables';
5+
@use 'footer';

‎templates/base.html‎

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,25 +9,29 @@
99

1010
<body>
1111
<header class="header">
12-
<nav>
13-
<a>Apollo</a>
12+
<div class="content">
13+
<nav>
14+
<a>Apollo</a>
1415

15-
<div class="links">
16-
<a href="/download/">Download</a>
17-
<a href="https://docs.getapollo.dev/">Documentation</a>
18-
</div>
19-
</nav>
16+
<div class="links">
17+
<a href="/download/">Download</a>
18+
<a href="https://docs.getapollo.dev/">Documentation</a>
19+
</div>
20+
</nav>
21+
</div>
2022
</header>
2123

2224
<section class="section">
23-
<div class="container">
25+
<div class="content">
2426
{% block content %} {% endblock content %}
2527
</div>
2628
</section>
2729

2830
<footer>
29-
<p>© 2026 Apollo Contributors</p>
30-
<p>Apollo is made by humans, for humans</p>
31+
<div class="content">
32+
<p>© 2026 Apollo Contributors</p>
33+
<p>Apollo is made by humans, for humans</p>
34+
</div>
3135
</footer>
3236
</body>
3337

0 commit comments

Comments
 (0)