leftmenu alignment and border listbutton

Signed-off-by: Virginie Ky <virginie.ky@gmail.com>
This commit is contained in:
Virginie Ky 2020-03-20 09:19:43 +01:00
parent a70991a37e
commit 83b326e9a5
5 changed files with 21 additions and 3 deletions

View File

@ -0,0 +1,15 @@
import React from 'react';
import styled from 'styled-components';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import colors from '../../assets/styles/colors';
const LeftMenuIcon = styled(({ ...props }) => <FontAwesomeIcon {...props} icon="circle" />)`
position: absolute;
top: calc(50% - 0.3rem);
left: 1.4rem;
font-size: 0.7rem;
color: ${colors.leftMenu.darkGrey};
`;
export default LeftMenuIcon;

View File

@ -2,9 +2,12 @@ import React, { memo } from 'react';
import PropTypes from 'prop-types';
import { NavLink } from 'react-router-dom';
import Icon from './Icon';
function LeftMenuLink({ children, to }) {
return (
<NavLink to={to}>
<Icon />
<p>{children}</p>
</NavLink>
);

View File

@ -5,8 +5,7 @@ import colors from '../../assets/styles/colors';
const List = styled.ul`
margin-bottom: 0;
padding-left: 0;
max-height: ${props =>
props.numberOfVisibleItems ? `${props.numberOfVisibleItems * 35}px` : null};
max-height: 178px;
overflow-y: scroll;
li {
position: relative;

View File

@ -4,6 +4,7 @@ const ListButton = styled.div`
button {
width: 100%;
height: 54px;
border: 0;
border-top: 1px solid #aed4fb;
color: #007eff;
font-weight: 500;

View File

@ -8,7 +8,7 @@ import styled from 'styled-components';
const StyledCustomLink = styled.div`
padding-left: 15px;
padding-top: 9px;
padding-top: 10px;
line-height: 0;
margin-left: -3px;