import PropTypes from 'prop-types';
import React from 'react';
import Icon from '../icon';

export default function Edit({
  stroke,
  fill,
  strokeWidth,
  style: styleProp,
  ...rest // eslint-disable-line comma-dangle
}) {
  const style = {
    ...styleProp,
    ...Icon.defaultProps.style,
  };
  return (
    <svg style={style} {...rest}>
      <g stroke="none" strokeWidth={strokeWidth} fill="none" fillRule="evenodd">
        <g fillRule="nonzero" fill={fill}>
          <path
            d="M15.4551084,3.9628483 C15.4551084,1.77773375 13.6773746,0 11.4922601,0 C10.8954551,0 10.3208421,0.129981424
            9.78585759,0.385188854 C9.74385139,0.405003096 9.70739319,0.431950464 9.67648297,0.462860681 L9.67648297,0.462860681
            L1.30456966,8.83477399 C1.2435418,8.89580186 1.20470588,8.97426625 1.19281734,9.05907121 L0.400247678,14.6070588
            C0.382811146,14.7306997 0.424024768,14.8551331 0.512,14.9431084 C0.586501548,15.0176099 0.687950464,15.0588235
            0.79177709,15.0588235 C0.810006192,15.0588235 0.829027864,15.0572384 0.848049536,15.0548607 L6.39603715,14.262291
            C6.48084211,14.2504025 6.5593065,14.210774 6.62033437,14.1505387 L14.9859071,5.78496594 L14.9866997,5.78417337
            L14.9922477,5.77862539 L14.9922477,5.77862539 C15.0231579,5.74771517 15.0493127,5.71125697 15.0699195,5.66925077
            C15.3259195,5.13426625 15.4551084,4.55965325 15.4551084,3.9628483 L15.4551084,3.9628483 Z M14.6625387,3.9628483
            C14.6625387,4.41857585 14.5682229,4.85765944 14.381969,5.26821053 L13.4705139,6.17966563 C13.3872941,3.90340557
            11.5517028,2.06781424 9.27544272,1.98459443 L10.1868978,1.07313932 C10.5974489,0.886885449 11.0365325,0.792569659
            11.4922601,0.792569659 C13.2406687,0.792569659 14.6625387,2.21443963 14.6625387,3.9628483 L14.6625387,3.9628483
            Z M1.58910217,11.8885449 L1.92435913,9.53936842 C2.0741548,9.52034675 2.2255356,9.51083591 2.37770898,9.51083591
            C4.3440743,9.51083591 5.94427245,11.1110341 5.94427245,13.0773994 C5.94427245,13.2287802 5.93476161,13.3809536
            5.91573994,13.5307492 L3.56656347,13.8660062 C3.56418576,12.7770155 2.67888545,11.8909226 1.58910217,11.8885449
            L1.58910217,11.8885449 Z M8.41788235,2.8421548 C8.64614241,2.79697833 8.87995046,2.77399381 9.11455108,2.77399381
            C9.95546749,2.77399381 10.7290155,3.06645201 11.3392941,3.55546749 L5.16517647,9.72958514 C4.44710836,9.13119505
            3.53486068,8.75868731 2.53780805,8.7222291 L8.41708978,2.84294737 L8.41788235,2.8421548 Z M5.72631579,10.2891393
            L11.9004334,4.11502167 C12.3886563,4.72530031 12.6819071,5.4988483 12.6819071,6.33976471 C12.6819071,6.57436533
            12.6589226,6.80817337 12.6137461,7.03643344 L6.7344644,12.9157152 C6.69800619,11.9186625 6.32549845,11.0064149
            5.72710836,10.2883467 L5.72631579,10.2891393 Z M1.47497214,12.6866625 C1.51143034,12.6834923 1.54788854,12.6811146
            1.58513932,12.6811146 C2.24059443,12.6811146 2.77399381,13.2145139 2.77399381,13.869969 C2.77399381,13.9072198
            2.77240867,13.943678 2.76844582,13.9801362 L1.25939319,14.1957152 L1.47497214,12.6866625 L1.47497214,12.6866625 Z"
          />
        </g>
      </g>
    </svg>
  );
}

Edit.propTypes = {
  ...Icon.propTypes,
  stroke: PropTypes.string,
  fill: PropTypes.string,
  strokeWidth: PropTypes.number,
};

Edit.defaultProps = Icon.defaultProps;
