Skip to content
This repository has been archived by the owner on Aug 13, 2019. It is now read-only.

ON HOLD: STIJ-183: POC - footer with CSS Grid and flexbox fallback. #156

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
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: 1 addition & 1 deletion .sass-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ rules:
no-debug: 2
# We use sizes in rem followed by px for these
no-duplicate-properties:
- 2
- 0
Copy link
Contributor

Choose a reason for hiding this comment

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

please exclude the display in this rule instead of changing the error level

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed.

- exclude:
- padding-left
- padding-right
Expand Down
4 changes: 0 additions & 4 deletions components/11-base/section/_section.scss
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,3 @@
color: map-get($colors, 'section-text-color');
}
}

*[class*="section--"] {
@include clearfix();
}
62 changes: 32 additions & 30 deletions components/41-organisms/footer/_footer.scss
Original file line number Diff line number Diff line change
@@ -1,47 +1,49 @@
// General footer styling.
footer {
padding: 1.5rem 0;
@include tablet {
padding: 1.5rem;
}

padding: 1.5rem .5rem;

p {
color: $color-gray;
}

.db-block-partnership {
@include tablet {
margin-top: 6rem;
}
}
}

// Footer 2 column layout.
footer[data-columns="2"] {
.footer--column {
@include make-mobile-column(12);
@include make-tablet-column(6);
@include make-desktop-column(6);
// Footer 4 column layout.
footer[data-columns="4"] {
@include tablet {
display: flex;
display: grid;
grid-template-columns: repeat(2, 1fr [footer-column]);
grid-gap: 1rem;
grid-auto-rows: 275px;
}
}

// Footer 3 column layout.
footer[data-columns="3"] {
.footer--column {
@include make-mobile-column(12);
@include make-tablet-column(6);
@include make-desktop-column(4);
@include desktop {
grid-template-columns: repeat(4, 1fr [footer-column]);
grid-auto-rows: 400px;
}
}

// Footer 4 column layout.
footer[data-columns="4"] {
.footer--column {
@include make-mobile-column(12);
@include make-tablet-column(6);
@include make-desktop-column(3);
@include tablet {
width: 50%;
}
@include desktop {
width: 25%;
}
@supports (display: grid) {
width: auto;
}
}

.db-block-partnership {
@include desktop {
margin-top: 12.5rem;
.footer--column:last-child {
Copy link
Contributor

Choose a reason for hiding this comment

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

alignment of the molecule should me added on the molecule itself, not on the grid system.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed.

align-self: flex-end;
justify-self: flex-end;

@supports (display: grid) {
align-self: end;
justify-self: end;
}
}
}
28 changes: 12 additions & 16 deletions components/41-organisms/footer/footer.twig
Original file line number Diff line number Diff line change
@@ -1,19 +1,15 @@
<footer class="section--wrapper" role="contentinfo" data-columns="4">
<div class="content-container">
<div class="row">
<div class="footer--column">
{% include '@gentinfo-island' %}
</div>
<div class="footer--column">
{% include '@post-address-block' %}
{% include '@disclaimer-block' %}
</div>
<div class="footer--column">
{% include '@social-media-block' %}
</div>
<div class="footer--column">
{% include '@partnership-block' %}
</div>
</div>
<div class="footer--column">
{% include '@gentinfo-island' %}
</div>
<div class="footer--column">
{% include '@post-address-block' %}
{% include '@disclaimer-block' %}
</div>
<div class="footer--column">
{% include '@social-media-block' %}
</div>
<div class="footer--column">
{% include '@partnership-block' %}
</div>
</footer>