import React from 'react';
import styled from 'styled-components';

import v from '../../styles/Variables';

interface Props {
  show: boolean;
}

const LabelRequired = ({ show }: Props) => {
  if (show !== true) return <></>;

  return <Label data-test="component-buttonGroup-required">{' *'}</Label>;
};

export default LabelRequired;

/* styles */
const Label = styled.sup`
  color: ${v.colors.cta};
`;
