Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
import logoIcon from 'images/logo.sprite.svg';
import sendIcon from 'images/send.sprite.svg';
import chartIcon from 'images/chart.sprite.svg';
import transactionsIcon from 'images/transaction.sprite.svg';
import addressBookIcon from 'images/address-book.sprite.svg';
import settingsIcon from 'images/settings.sprite.svg';
import consoleIcon from 'images/console.sprite.svg';
// import shapeshiftIcon from 'images/shapeshift.sprite.svg';
// import trustListIcon from 'images/trust-list.sprite.svg';
const slideUp = keyframes`
from { opacity: 0; transform: translateY(70%) }
to { opacity: 1; transform: translateY(0) }
`;
const Nav = styled.nav({
gridArea: 'navigation',
position: 'relative',
background: 'linear-gradient(to top, rgba(0,0,0,.6), transparent)',
});
const NavBar = styled.div({
width: '100%',
height: '100%',
display: 'flex',
justifyContent: 'center',
paddingBottom: 10,
animation: `${slideUp} ${timing.slow} ${consts.enhancedEaseOut}`,
});
const AboveNav = styled.div({
position: 'absolute',
import settingsIcon from 'icons/settings.svg';
import consoleIcon from 'icons/console.svg';
import userIcon from 'icons/user.svg';
import tokenIcons from 'icons/blockexplorer-invert-white.svg';
import { legacyMode } from 'consts/misc';
// import shapeshiftIcon from 'icons/shapeshift.svg';
// import trustListIcon from 'icons/trust-list.svg';
__ = __context('NavigationBar');
const slideUp = keyframes`
from { opacity: 0; transform: translateY(70%) }
to { opacity: 1; transform: translateY(0) }
`;
const Nav = styled.nav({
gridArea: 'navigation',
position: 'relative',
background: 'linear-gradient(to top, rgba(0,0,0,.6), transparent)',
});
const NavBar = styled.div({
width: '100%',
height: '100%',
display: 'flex',
justifyContent: 'center',
paddingBottom: 10,
animation: `${slideUp} ${timing.slow} ${consts.enhancedEaseOut}`,
});
const AboveNav = styled.div({
position: 'absolute',
import NavItem from './nav-item';
import PropTypes from 'prop-types';
import React from 'react';
import styled from '@emotion/styled';
import {breakpoints} from 'gatsby-theme-apollo-core';
const Container = styled.nav({
display: 'flex',
alignSelf: 'stretch',
marginLeft: 'auto',
paddingLeft: 40,
[breakpoints.sm]: {
display: 'none'
}
});
export default function Nav(props) {
return (
{props.items.map(({value, text, matchRegex, subpages}) => {
let isActive = matchRegex
? new RegExp(matchRegex).test(props.pathname)
: props.isPathActive(value);
import styled from '@emotion/styled';
import { colors, gridSize } from '@arch-ui/theme';
import { ItemElement } from './common';
export const PRIMARY_NAV_GUTTER = gridSize * 2;
export const NavGroupIcons = styled.div({
alignItems: 'center',
alignSelf: 'stretch',
display: 'flex',
justifyContent: 'space-between',
});
export const PrimaryNav = styled.nav({
boxSizing: 'border-box',
display: 'flex',
flexDirection: 'column',
height: '100vh',
position: 'fixed',
zIndex: 2,
});
export const PrimaryNavScrollArea = styled.div(({ hasScroll, isBottom, isScrollable }) => {
const divider = {
backgroundColor: 'rgba(9, 30, 66, 0.1)',
content: '" "',
height: 2,
left: PRIMARY_NAV_GUTTER,
right: PRIMARY_NAV_GUTTER,
position: 'absolute',
};
const Footer = styled.footer({
display: 'flex',
flexDirection: 'column',
alignItems: 'center',
padding: 48,
fontSize: 14,
color: colors.text1,
backgroundColor: colors.background
});
const Colophon = styled.span({
margin: '20px 0'
});
const FooterNav = styled.nav({
textAlign: 'center',
a: {
margin: '0 12px',
color: 'inherit',
textDecoration: 'none',
':hover': {
textDecoration: 'underline'
}
}
});
const Divider = styled.hr({
width: '100%',
maxWidth: 400
});
import React from 'react';
import styled from '@emotion/styled';
import { colors, gridSize } from '@arch-ui/theme';
import { ItemElement } from './common';
const Wrapper = styled.nav({
borderBottom: `1px solid ${colors.N10}`,
color: colors.text,
fontSize: '0.85em',
});
export const SecondaryNavItem = styled(ItemElement)(({ isSelected }) => ({
boxShadow: `inset 0 ${isSelected ? -2 : 0}px 0 currentColor`,
color: isSelected ? colors.text : colors.N60,
cursor: 'pointer',
display: 'inline-block',
marginRight: gridSize,
paddingBottom: gridSize * 2,
paddingTop: gridSize * 2,
transition: 'box-shadow 200ms',
':hover': {
color: colors.text,
backgroundColor: colors.background
});
const Colophon = styled.span({
marginTop: 8,
marginBottom: 20,
a: {
color: colors.primary,
textDecoration: 'none',
':hover': {
textDecoration: 'underline'
}
}
});
const FooterNav = styled.nav({
textAlign: 'center',
a: {
margin: '0 12px',
color: 'inherit',
textDecoration: 'none',
':hover': {
textDecoration: 'underline'
}
}
});
const FooterNavLinks = styled.div({
marginTop: 4
});
const Divider = styled.hr({
const SidebarContentHeader = styled.h4({
display: 'flex',
alignItems: 'center',
justifyContent: 'space-between',
paddingRight: 16,
fontWeight: 400,
color: colors.primary
});
const Main = styled.main({
flexGrow: 1,
overflowY: 'auto'
});
const Nav = styled.nav({
display: 'flex',
alignSelf: 'stretch',
margin: '0 40px'
});
const NavItem = styled.a({
display: 'flex',
alignItems: 'center',
padding: '0 4px',
borderBottom: '2px solid transparent',
fontSize: 18,
color: colors.primary,
textDecoration: 'none',
'&.active': {
borderColor: colors.secondary
},
import NavItem from './nav-item'
import PropTypes from 'prop-types'
import React from 'react'
import styled from '@emotion/styled'
import {breakpoints} from 'gatsby-theme-base'
const Container = styled.nav({
display: 'flex',
alignSelf: 'stretch',
marginLeft: 'auto',
paddingLeft: 40,
[breakpoints.sm]: {
display: 'none'
}
})
const navConfig = {
'/api': {
text: 'Docs',
},
'/plugins': {
text: 'Plugins',
},
export const NavItemTitle = styled.h4({
marginBottom: 8,
fontWeight: 600,
color: 'inherit'
});
export const NavItemDescription = styled.p({
marginBottom: 0,
fontSize: 14,
lineHeight: 1.5,
color: colors.text3,
transition: 'color 150ms ease-in-out'
});
const FooterNav = styled.nav({
display: 'flex',
alignItems: 'center',
padding: '16px 24px',
backgroundColor: colors.background,
[breakpoints.md]: {
display: 'block'
}
});
const FooterNavItem = styled.a({
color: colors.text2,
textDecoration: 'none',
':hover': {
color: colors.text3
},
':not(:last-child)': {