import * as React from 'react';
import { RadioItem, LabelItem } from './Radio.styled';

export interface IProps {
  checked?: boolean;
  value?: string;
  name?: string;
  autoFocus?: any;
  disabled?: boolean;
  required?: boolean;
  onChange?: (event?: any) => void;
  id: string;
  label: string;
  css?: string;
  isClassic?: boolean;
}

export default React.memo(({ id, label, ...props }: IProps) => (
    <React.Fragment>
      <RadioItem id={id} name='qualquer' {...props} />
      <LabelItem htmlFor={id} className='radio-item__label'>{label}</LabelItem>
    </React.Fragment>
  )
);
