-
Notifications
You must be signed in to change notification settings - Fork 2
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
Switch to Grid and Footer #97
Merged
Merged
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
e984c91
WIP
wilwade 63f7ff9
WIP 2
wilwade fe77033
Grid wip Hiding is not working, but many things are
wilwade a5e1489
Most of the grid is working
wilwade 290caa6
Transitions working in all setups
wilwade 7a028c2
Most things working
wilwade c321b60
Cleanup
wilwade f06e7a0
Fix footer copyright structure on mobile
wilwade 5e3a75f
Fix issues with tall browsers and short content
wilwade f7f93f3
Cleanup
wilwade 5d117b4
Remove non-working icons on no-js
wilwade 80a6a02
Fix theme hover states
wilwade fbb8ee4
Fix cross browser footer issues
wilwade 562e5cc
Print styles for the grid
wilwade File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
/* Custom CSS for the Footer Component */ | ||
|
||
:root { | ||
--footer-color-primary: #000; | ||
--footer-color-primary-inverted: #fff; | ||
--footer-color-secondary: #19455e; | ||
--footer-section-margin-bottom: 3rem; | ||
} | ||
|
||
.frqcy-footer { | ||
background: var(--footer-color-primary-inverted); | ||
z-index: 1; | ||
display: flex; | ||
flex-direction: column; | ||
align-items: center; | ||
color: var(--footer-color-primary); | ||
padding: var(--footer-section-margin-bottom) 1rem; | ||
} | ||
|
||
#frqcy-footer-logo { | ||
display: block; | ||
max-width: 257px; | ||
width: 100%; | ||
color: var(--footer-color-primary); | ||
margin-bottom: var(--footer-section-margin-bottom); | ||
} | ||
|
||
#frqcy-footer-copyright { | ||
display: flex; | ||
flex-direction: column; | ||
justify-content: center; | ||
text-align: center; | ||
width: 100%; | ||
line-height: 1; | ||
margin: 0 1rem var(--footer-section-margin-bottom) 1rem; | ||
} | ||
|
||
#frqcy-footer-copyright div.frqcy-footer-vbar { | ||
width: 10%; | ||
height: 2px; | ||
background: var(--footer-color-primary); | ||
justify-self: stretch; | ||
margin: 1rem auto; | ||
} | ||
|
||
#frqcy-footer-copyright a { | ||
color: var(--footer-color-primary); | ||
padding: 0; | ||
} | ||
|
||
#frqcy-footer-copyright a:hover, | ||
#frqcy-footer-copyright a:visited:hover { | ||
color: var(--footer-color-secondary); | ||
} | ||
|
||
.frqcy-footer .frqcy-footer-social-links { | ||
display: flex; | ||
flex-direction: row; | ||
margin-bottom: var(--footer-section-margin-bottom); | ||
width: 100%; | ||
justify-content: center; | ||
} | ||
|
||
.frqcy-footer .frqcy-footer-social-links a { | ||
cursor: pointer; | ||
display: flex; | ||
height: 100%; | ||
margin: 1rem; | ||
padding: 0.5rem; | ||
border-radius: 0.5rem; | ||
flex: 0 0 32px; | ||
background: var(--footer-color-primary); | ||
color: var(--footer-color-primary-inverted); | ||
} | ||
|
||
.frqcy-footer .frqcy-footer-social-links a:hover, | ||
.frqcy-footer .frqcy-footer-social-links a:visited:hover { | ||
background: var(--footer-color-secondary); | ||
} | ||
|
||
/* Desktop */ | ||
@media only screen and (min-width: 620px) { | ||
#frqcy-footer-copyright { | ||
flex-direction: row; | ||
} | ||
|
||
#frqcy-footer-copyright div.frqcy-footer-vbar { | ||
width: 2px; | ||
height: 100%; | ||
margin: 0 2rem; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -604,66 +604,3 @@ function playground_text(playground, hidden = true) { | |
document.scrollingElement.scrollTo({ top: 0, behavior: "smooth" }); | ||
}); | ||
})(); | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We don't want to do any of this anymore. Perhaps we'll bring back the scrolling header disappearing later. |
||
(function controllMenu() { | ||
var menu = document.getElementById("menu-bar"); | ||
|
||
(function controllPosition() { | ||
var scrollTop = document.scrollingElement.scrollTop; | ||
var prevScrollTop = scrollTop; | ||
var minMenuY = -menu.clientHeight - 50; | ||
// When the script loads, the page can be at any scroll (e.g. if you reforesh it). | ||
menu.style.top = scrollTop + "px"; | ||
// Same as parseInt(menu.style.top.slice(0, -2), but faster | ||
var topCache = menu.style.top.slice(0, -2); | ||
menu.classList.remove("sticky"); | ||
var stickyCache = false; // Same as menu.classList.contains('sticky'), but faster | ||
document.addEventListener( | ||
"scroll", | ||
function () { | ||
scrollTop = Math.max(document.scrollingElement.scrollTop, 0); | ||
// `null` means that it doesn't need to be updated | ||
var nextSticky = null; | ||
var nextTop = null; | ||
var scrollDown = scrollTop > prevScrollTop; | ||
var menuPosAbsoluteY = topCache - scrollTop; | ||
if (scrollDown) { | ||
nextSticky = false; | ||
if (menuPosAbsoluteY > 0) { | ||
nextTop = prevScrollTop; | ||
} | ||
} else { | ||
if (menuPosAbsoluteY > 0) { | ||
nextSticky = true; | ||
} else if (menuPosAbsoluteY < minMenuY) { | ||
nextTop = prevScrollTop + minMenuY; | ||
} | ||
} | ||
if (nextSticky === true && stickyCache === false) { | ||
menu.classList.add("sticky"); | ||
stickyCache = true; | ||
} else if (nextSticky === false && stickyCache === true) { | ||
menu.classList.remove("sticky"); | ||
stickyCache = false; | ||
} | ||
if (nextTop !== null) { | ||
menu.style.top = nextTop + "px"; | ||
topCache = nextTop; | ||
} | ||
prevScrollTop = scrollTop; | ||
}, | ||
{ passive: true }, | ||
); | ||
})(); | ||
(function controllBorder() { | ||
function updateBorder() { | ||
if (menu.offsetTop === 0) { | ||
menu.classList.remove("bordered"); | ||
} else { | ||
menu.classList.add("bordered"); | ||
} | ||
} | ||
updateBorder(); | ||
document.addEventListener("scroll", updateBorder, { passive: true }); | ||
})(); | ||
})(); |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This helps align the Frequency logo by default with the sidebar