All files / Select/partials SelectControl.js

100% Statements 7/7
100% Branches 2/2
100% Functions 1/1
100% Lines 6/6
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 331x   1x   1x 1x   17x                                             44x    
import styled from 'styled-components'
 
import { autoCssGenerator } from '../cssHelpers';
 
const globalCss = autoCssGenerator('select');
const g = autoCssGenerator('select-control');
 
const isOpened = () => `
  ${g('border-color', 'focused')}
`
 
export default styled.div`
  display: flex;
  position: relative;
  align-items: center;
  box-sizing: border-box;
  cursor: default;
  border-spacing: 0;
  border-collapse: separate;
  outline: none;
  overflow: hidden;
  width: 100%;
 
  ${g('border-color')}
  ${g('min-height')}
  ${globalCss('border-radius')}
  ${globalCss('border-style')}
  ${globalCss('border-width')}
  ${globalCss('background-color')}
 
  ${props => props.isOpened && isOpened()}
 `