Skip to content

Commit

Permalink
add .content for consistent padding around content
Browse files Browse the repository at this point in the history
  • Loading branch information
willnorris committed Oct 11, 2021
1 parent 1cf1553 commit f504d96
Show file tree
Hide file tree
Showing 9 changed files with 24 additions and 24 deletions.
10 changes: 8 additions & 2 deletions assets/css/_main.scss
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ body {
}
}

.section {
.content, .section {
padding: calc(var(--feather-grid-mega) * 2) 0;
}

Expand Down Expand Up @@ -348,11 +348,17 @@ br {

/* Less than 600px */
@media (max-width: 600px) {
.section {
.content, .section {
padding: calc(var(--feather-grid-mega) * 1.5) 0;
}

.container {
margin: 0 var(--feather-grid-medium);
}
}

@media (max-width: 480px) {
.content, .section {
padding: var(--feather-grid-large) 0;
}
}
4 changes: 4 additions & 0 deletions assets/css/index.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
/* Styles specific to home page */

.content {
padding: 0;
}

.grey {
background-color: var(--tw-color-gray-faint);

Expand Down
6 changes: 0 additions & 6 deletions assets/css/memberships.scss
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,6 @@
}
}

@media (max-width: 480px) {
.section {
padding: var(--feather-grid-large) 0;
}
}

/* Membership card elements that are consistent throughout all screen sizes */

.membership {
Expand Down
6 changes: 0 additions & 6 deletions assets/css/projects.scss
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,6 @@
--search-bar-width: 450px;
}

.all-projects {
padding-top: var(--feather-grid-mega);
padding-bottom: calc(var(--feather-grid-mega) * 2);
}


.project-card {
position: relative;
padding: var(--feather-grid-mega) calc(var(--feather-grid-mega) * 1.5);
Expand Down
8 changes: 5 additions & 3 deletions layouts/_default/baseof.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
{{ partial "nav.html" . }}

<!-- Site wrapper -->
<div class="site">
<main>
<div class="header">
<div class="Grid container">
<div id="header-text" class="Grid-cell">
Expand All @@ -19,8 +19,10 @@
</div>
</div>
</div>
{{ block "main" . }}{{ end }}
</div>
<div class="content">
{{ block "content" . }}{{ end }}
</div>
</main>

{{ partial "footer.html" . }}
</body>
Expand Down
4 changes: 1 addition & 3 deletions layouts/_default/memberships.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
{{ define "main" }}
<div class="section">
{{ define "content" }}
<div class="Grid membership-container container">
{{ range $.Site.Data.memberships }}
<div class="Grid-cell sizeFull membership">
Expand Down Expand Up @@ -29,5 +28,4 @@ <h2>{{ .name }}</h2>
</div>
{{ end }}
</div>
</div>
{{ end }}
2 changes: 1 addition & 1 deletion layouts/_default/projects.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ <h1 class="large-title">Projects</h1>
</div>
{{ end }}

{{ define "main" }}
{{ define "content" }}
<!-- Container for no results text -->
<div class="Grid container no-results-container"></div>

Expand Down
6 changes: 4 additions & 2 deletions layouts/_default/single.html
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
{{ define "main" }}
{{ .Content }}
{{ define "content" }}
<div class="container">
{{ .Content }}
</div>
{{ end }}
2 changes: 1 addition & 1 deletion layouts/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ <h1 class="subtitle">
<h1 class="large-title">Open Source is Happening</h1>
{{ end }}

{{ define "main" }}
{{ define "content" }}
{{ .Content }}
{{ end }}

0 comments on commit f504d96

Please sign in to comment.