<commit_before>import styled, { css } from 'styled-components';
import Portrait from '../portrait';
import baseTheme from '../../style/themes/base';
import { THEMES } from '../../style/themes';

const portraitSizes = {
  'extra-small': {
    dimensions: 24,
    nameSize: '13px',
    emailSize: '12px',
    lineHeight: '12px',
    marginLeft: '16px'
  },
  small: {
    dimensions: 32,
    nameSize: '14px',
    emailsize: '12px',
    lineHeight: '16px',
    marginLeft: '16px'
  },
  'medium-small': {
    dimensions: 40,
    nameSize: '14px',
    emailSize: '14px',
    lineHeight: '16px',
    marginLeft: '16px'
  },
  medium: {
    dimensions: 56,
    nameSize: '14px',
    emailSize: '14px',
    lineHeight: '20px',
    marginLEft: '24px'
  },
  'medium-large': {
    dimensions: 72,
    nameSize: '20px',
    emailSize: '14px',
    lineHeight: '22px',
    marginLeft: '24px'
  },
  large: {
    dimensions: 104,
    nameSize: '24px',
    emailSize: '20px',
    lineHeight: '26px',
    marginLeft: '32px'
  },
  'extra-large': {
    dimensions: 128,
    nameSize: '24px',
    emailSize: '20px',
    lineHeight: '30px',
    marginLeft: '40px'
  }
};

const ProfileNameStyle = styled.span`
    font-weight: bold;
    display: inline-block;
    font-size: ${props => portraitSizes[props.size].nameSize};
`;

const ProfileEmailStyle = styled.span`
    font-size: ${({ size }) => portraitSizes[size].emailSize};
`;

const ProfileStyle = styled.div`
    white-space: nowrap;
    color: ${({ theme }) => theme.text.color};

    ${({ large }) => large && css`
        ${ProfileNameStyle} {
            font-size: 20px;
            font-weight: 400;
            line-height: 21px;
        }
    `}

    ${({ theme }) => theme.name === THEMES.classic && css`
      color: rgba(0, 0, 0, 0.85);
    `};
`;

const ProfileDetailsStyle = styled.div`
  margin-left: 14px;
  vertical-align: middle;
  display: inline-block;
  line-height: 16px;

  line-height: ${({ size }) => portraitSizes[size].lineHeight};
  margin-left: ${({ size }) => portraitSizes[size].marginLeft};
`;

const ProfileAvatarStyle = styled(Portrait)`
  display: inline-block;
`;

ProfileStyle.defaultProps = {
  theme: baseTheme
};

ProfileNameStyle.defaultProps = {
  size: 'medium-small'
};

ProfileEmailStyle.defaultProps = {
  size: 'medium-small'
};

ProfileDetailsStyle.defaultProps = {
  size: 'medium-small'
};

export {
  ProfileStyle,
  ProfileNameStyle,
  ProfileDetailsStyle,
  ProfileAvatarStyle,
  ProfileEmailStyle
};<commit_msg>add some classic rules, fix typo<commit_after>import styled, { css } from 'styled-components';
import Portrait from '../portrait';
import baseTheme from '../../style/themes/base';
import { THEMES } from '../../style/themes';

const portraitSizes = {
  'extra-small': {
    dimensions: 24,
    nameSize: '13px',
    emailSize: '12px',
    lineHeight: '12px',
    marginLeft: '16px'
  },
  small: {
    dimensions: 32,
    nameSize: '14px',
    emailsize: '12px',
    lineHeight: '16px',
    marginLeft: '16px'
  },
  'medium-small': {
    dimensions: 40,
    nameSize: '14px',
    emailSize: '14px',
    lineHeight: '16px',
    marginLeft: '16px'
  },
  medium: {
    dimensions: 56,
    nameSize: '14px',
    emailSize: '14px',
    lineHeight: '20px',
    marginLeft: '24px'
  },
  'medium-large': {
    dimensions: 72,
    nameSize: '20px',
    emailSize: '14px',
    lineHeight: '22px',
    marginLeft: '24px'
  },
  large: {
    dimensions: 104,
    nameSize: '24px',
    emailSize: '20px',
    lineHeight: '26px',
    marginLeft: '32px'
  },
  'extra-large': {
    dimensions: 128,
    nameSize: '24px',
    emailSize: '20px',
    lineHeight: '30px',
    marginLeft: '40px'
  }
};

const ProfileNameStyle = styled.span`
    font-weight: bold;
    display: inline-block;
    font-size: ${props => portraitSizes[props.size].nameSize};

    ${({ theme }) => theme.name === THEMES.classic && css`
      display: inline;
    `};
`;

const ProfileEmailStyle = styled.span`
    font-size: ${({ size }) => portraitSizes[size].emailSize};

    ${({ theme }) => theme.name === THEMES.classic && css`
      font-size: 14px;
    `};
`;

const ProfileStyle = styled.div`
    white-space: nowrap;
    color: ${({ theme }) => theme.text.color};

    ${({ theme }) => theme.name === THEMES.classic && css`
      color: rgba(0, 0, 0, 0.85);

      ${({ large }) => large && css`
        ${ProfileNameStyle} {
            font-size: 20px;
            font-weight: 400;
            line-height: 21px;
        }
      `}

    `};
`;

const ProfileDetailsStyle = styled.div`
  vertical-align: middle;
  display: inline-block;
  line-height: ${({ size }) => portraitSizes[size].lineHeight};
  margin-left: ${({ size }) => portraitSizes[size].marginLeft};

  ${({ theme }) => theme.name === THEMES.classic && css`
      line-height: 16px;
      margin-left: 14px;
    `};
`;

const ProfileAvatarStyle = styled(Portrait)`
  display: inline-block;
`;

ProfileStyle.defaultProps = {
  theme: baseTheme
};

ProfileNameStyle.defaultProps = {
  size: 'medium-small',
  theme: baseTheme
};

ProfileEmailStyle.defaultProps = {
  size: 'medium-small',
  theme: baseTheme
};

ProfileDetailsStyle.defaultProps = {
  size: 'medium-small',
  theme: baseTheme
};

export {
  ProfileStyle,
  ProfileNameStyle,
  ProfileDetailsStyle,
  ProfileAvatarStyle,
  ProfileEmailStyle
};
{'fraction_non_alphanumeric': 0.1681316626145502, 'fraction_numerical': 0.0336637366747709, 'mean_word_length': 2.9673590504451037, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 20, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3298819', 'n_tokens_mistral': 1977, 'n_tokens_neox': 1864, 'n_words': 385}