<commit_before>/* eslint-disable react/forbid-prop-types */
import React from 'react';
import { View } from 'react-native';
import PropTypes from 'prop-types';

import { TRANSPARENT } from '../globalStyles';

export const Circle = ({ size, children, backgroundColor, borderColor, elevate, style }) => {
  const adjustedStyle = {
    width: size,
    height: size,
    borderRadius: size / 2,
    backgroundColor,
    borderColor: borderColor ?? TRANSPARENT,
    elevation: elevate ? 5 : 0,
  };

  const internalStyle = [adjustedStyle, defaultStyle, style];

  return <View style={internalStyle}>{children}</View>;
};

const defaultStyle = {
  alignItems: 'center',
  justifyContent: 'center',
  overflow: 'hidden',
  borderWidth: 1,
};

Circle.defaultProps = {
  size: 30,
  children: null,
  backgroundColor: TRANSPARENT,
  borderColor: TRANSPARENT,
  elevate: false,
  style: {},
};

Circle.propTypes = {
  style: PropTypes.object,
  size: PropTypes.number,
  children: PropTypes.node,
  backgroundColor: PropTypes.string,
  borderColor: PropTypes.string,
  elevate: PropTypes.number,
};<commit_msg>Add propType fix<commit_after>/* eslint-disable react/forbid-prop-types */
import React from 'react';
import { View } from 'react-native';
import PropTypes from 'prop-types';

import { TRANSPARENT } from '../globalStyles';

export const Circle = ({ size, children, backgroundColor, borderColor, elevate, style }) => {
  const adjustedStyle = {
    width: size,
    height: size,
    borderRadius: size / 2,
    backgroundColor,
    borderColor: borderColor ?? TRANSPARENT,
    elevation: elevate ? 5 : 0,
  };

  const internalStyle = [adjustedStyle, defaultStyle, style];

  return <View style={internalStyle}>{children}</View>;
};

const defaultStyle = {
  alignItems: 'center',
  justifyContent: 'center',
  overflow: 'hidden',
  borderWidth: 1,
};

Circle.defaultProps = {
  size: 30,
  children: null,
  backgroundColor: TRANSPARENT,
  borderColor: TRANSPARENT,
  elevate: false,
  style: {},
};

Circle.propTypes = {
  style: PropTypes.object,
  size: PropTypes.number,
  children: PropTypes.node,
  backgroundColor: PropTypes.string,
  borderColor: PropTypes.string,
  elevate: PropTypes.bool,
};
{'fraction_non_alphanumeric': 0.1306122448979592, 'fraction_numerical': 0.005442176870748299, 'mean_word_length': 4.26491646778043, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 9, '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': '1165529', 'n_tokens_mistral': 702, 'n_tokens_neox': 689, 'n_words': 178}