Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: introduce global footer #15

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions _i18n/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ global:
accessibility:
title: Accessibility
summary: We understand accessibility in a broad sense and strive to do better. We try to host meetings that are wheelchair accessible, smoke free, short(er) and provide child care. We provide information on the meeting location, including a description of the entrance, lighting and sounds, and policy around companion and service dogs beforehand so that participants can best plan for their visit. If you have feedback or questions regarding the accessibility of our meetings or initiatives, please get in touch at <a rel="noopener noreferrer" target="_blank" href="mailto:[email protected]">[email protected]</a>.
footer: Proud to be part of the


press:
mentions: Press mentions
Expand Down
1 change: 1 addition & 0 deletions _i18n/nl.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ global:
accessibility:
title: Toegangelijkheid
summary: De techwerkerscoalitie vat toegankelijkheid ruim op en streeft er altijd naar om het beter te doen. Bijeenkomsten zijn zoveel mogelijk rolstoeltoegankelijke, rookvrij, kort(er) en er is kinderopvang aanwezig. Informatie over de locatie van de bijeenkomst, inclusief een omschrijving van de ingang, light en geluid, en beleid rondom steun- en geleidehonden, wordt vooraf verstrekt zodat deelnemers hun bezoek zo goed mogelijk kunnen plannen. Heb je ideeën, suggesties, of vragen rondom de toegankelijkheid van bijeenkomsten of initiatieven? Neem dan contact op met <a rel="noopener noreferrer" target="_blank" href="mailto:[email protected]">[email protected]</a>.
footer: Trots om deel uit te maken van

press:
mentions: Pers
Expand Down
6 changes: 6 additions & 0 deletions _includes/footer.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<footer class="footer">
<div class="footer-container">
<img alt="" role="presentation" aria-hidden="true" height="40" src="/assets/css/images/logo.svg" width="40" class="logo">
<div>{% t global.footer %} <a href="https://techworkerscoalition.org/">Tech Workers Coalition</a></div>
</div>
</footer>
8 changes: 8 additions & 0 deletions _includes/main.scss
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
@import "structures/event";

@import "header";
@import "footer";

@import "layouts/home";

Expand Down Expand Up @@ -105,6 +106,13 @@ input[type="submit"] {
}
}

html, body { min-height: 100vh; }

body > footer {
position: sticky;
top: 100vh;
}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Based on the approach documented here: https://css-tricks.com/a-clever-sticky-footer-technique/

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmmm. I think I'd rather apply a flex to both the body and the footer. Sticky becomes problematic if the css for the content isn't consistent/allows for it.


blockquote,
ol,
p,
Expand Down
3 changes: 3 additions & 0 deletions _layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
<main class="{{ page.templateClass }}">
{{ content }}
</main>

{% include footer.html %}

<script type="text/javascript">{% include main.js %}</script>
</body>
</html>
51 changes: 51 additions & 0 deletions _sass/_footer.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
@import 'variables';

// https://dvcs.w3.org/hg/FXTF/raw-file/tip/filters/index.html
//
// grayscale ex: filter: grayscale(100%);
// sepia ex: filter: sepia(100%);
// saturate ex: filter: saturate(0%);
// hue-rotate ex: filter: hue-rotate(45deg);
// invert ex: filter: invert(100%);
// brightness ex: filter: brightness(15%);
// contrast ex: filter: contrast(200%);
// blur ex: filter: blur(2px);

@mixin filter($filter-type,$filter-amount) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe refactor to a global mixins file, but this seems like an optimization to make once we are using it in multiple places.

-webkit-filter: $filter-type+unquote('(#{$filter-amount})');
-moz-filter: $filter-type+unquote('(#{$filter-amount})');
-ms-filter: $filter-type+unquote('(#{$filter-amount})');
-o-filter: $filter-type+unquote('(#{$filter-amount})');
filter: $filter-type+unquote('(#{$filter-amount})');
}

.footer {
border-top: 1px solid;
padding: 2em 2em;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

too much padding IMHO. Can you try something more proportional?

padding: 1rem 1.5rem;

Maybe that's something we can do with a css cleanup - get some good ratios in.

background: $black;
color: $white;
text-align: left;

@include mobile {
padding: 4vmin;
}

a {
color: $white;

&:hover {
color: $red;
}
}

&-container {
display: flex;
align-items: center;
justify-content: flex-start;
}

.logo {
@include filter(invert, 1);
margin-right: 10px;
}
}