diff --git a/src/components/Iconfont/Iconfont.js b/src/components/Iconfont/Iconfont.js index 1c54eff..9b48342 100644 --- a/src/components/Iconfont/Iconfont.js +++ b/src/components/Iconfont/Iconfont.js @@ -1,21 +1,38 @@ import React from 'react' import PropTypes from 'prop-types' +import classnames from 'classnames' import './iconfont.less' -const Iconfont = ({ type, colorful }) => { +const Iconfont = ({ type, colorful, className }) => { + const propsClassName = className; + + const csSvg = classnames( + { 'colorful-icon': true }, + { [`${propsClassName}`]: className !== undefined }, + ); + if (colorful) { - return (