joyent-portal/packages/ui-toolkit/src/header/item.js

44 lines
749 B
JavaScript
Raw Normal View History

import React from 'react';
import styled from 'styled-components';
import remcalc from 'remcalc';
import P from '../text/p';
const Text = P.extend`
text-align: center;
color: ${props => props.theme.white};
margin: 0;
a {
color: ${props => props.theme.white};
text-decoration: none;
}
`;
const Box = styled.section`
flex: 0 1 auto;
align-self: auto;
order: 0;
display: flex;
align-items: center;
padding: ${remcalc(15)};
svg {
margin-right: ${remcalc(6)};
}
&:not(:last-of-type) {
border-right: ${remcalc(1)} solid rgba(255, 255, 255, 0.15);
}
&:first-of-type {
margin-left: auto;
}
`;
2017-08-28 22:21:08 +03:00
export default ({ children, ...rest }) => (
<Box {...rest}>
2017-08-28 22:21:08 +03:00
<Text>{children}</Text>
</Box>
);