Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into jerel/layout-tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
jerelmiller committed Jun 16, 2020
2 parents e9cda4d + 7c2d6f9 commit 98e20f6
Show file tree
Hide file tree
Showing 6 changed files with 78 additions and 37 deletions.
36 changes: 26 additions & 10 deletions src/components/Footer.js
Original file line number Diff line number Diff line change
@@ -1,20 +1,36 @@
import React from 'react';
import { Link } from 'gatsby';
import cx from 'classnames';
import ExternalLink from './ExternalLink';
import styles from './Footer.module.scss';
import Logo from './Logo';

const Footer = () => (
<footer className={styles.footer}>
<div className={styles.leftColumn}>
<Link to="/">
<Logo
className={styles.logo}
textColor="#7DA5A8"
bracketColor="#7DA5A8"
/>
</Link>
<div className={styles.copyright}>
Copyright &copy; 2020 New Relic Inc.
<div className={cx('site-container', styles.container)}>
<div className={styles.left}>
<Link to="/">
<Logo
className={styles.logo}
textColor="#7DA5A8"
bracketColor="#7DA5A8"
/>
</Link>
<div className={styles.copyright}>
Copyright &copy; 2020 New Relic Inc.
</div>
</div>

<div className={styles.right}>
<Link to="/" className={styles.edit}>
Edit this page
</Link>
<ExternalLink
href="https://github.com/newrelic/developer-website/issues/new/choose"
className={styles.issue}
>
Create an issue
</ExternalLink>
</div>
</div>
</footer>
Expand Down
58 changes: 32 additions & 26 deletions src/components/Footer.module.scss
Original file line number Diff line number Diff line change
@@ -1,12 +1,17 @@
.footer {
--footer-text-color: #7da5a8;

background-color: var(--color-neutrals-800);
color: var(--footer-text-color);
color: var(--color-teal-300);
padding: 1.5rem 0;
font-size: 0.75rem;
}

.leftColumn {
.container {
display: flex;
justify-content: space-between;
align-items: center;
}

.left {
display: flex;
align-items: center;

Expand All @@ -20,7 +25,6 @@
}

.copyright {
font-size: 0.75rem;
margin-left: 1rem;
padding: 0.75rem 0.5rem;
border-left: 1px dotted var(--color-neutrals-700);
Expand All @@ -32,31 +36,33 @@
}
}

.nav {
@media (max-width: 760px) {
display: none;
}
.right {
display: flex;

ul {
a {
color: var(--color-teal-300);
margin-left: 1rem;
padding: 0.2rem;
padding-right: 0;
display: flex;
list-style: none;
margin: 0;
padding: 0;

li {
text-align: center;
}
align-items: center;

a {
color: var(--footer-text-color);
text-decoration: none;
font-size: 0.9rem;
padding: 0.5rem 0 0.5rem 1rem;
&:before {
content: '';
display: inline-block;
}

a:hover {
color: var(--color-white);
height: 1rem;
width: 1rem;
background-repeat: no-repeat;
background-position: center center;
margin-right: 0.5rem;
}
}
}

.edit:before {
background-image: url('../images/edit.svg');
}

.issue:before {
background-image: url('../images/github.svg');
}
2 changes: 1 addition & 1 deletion src/components/Layout.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const Layout = ({ children }) => (
<Sidebar pages={pages} />
<main className={styles.content}>{children}</main>
</div>
<Footer pages={pages} />
<Footer />
</div>
);

Expand Down
5 changes: 5 additions & 0 deletions src/components/styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -180,4 +180,9 @@ code {
font-size: 1.125rem;
line-height: 2rem;
}

.site-container {
max-width: 1200px;
margin: auto;
}
}
4 changes: 4 additions & 0 deletions src/images/edit.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 10 additions & 0 deletions src/images/github.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 98e20f6

Please sign in to comment.