Skip to content

Commit

Permalink
Moved updated fonticon to new file
Browse files Browse the repository at this point in the history
  • Loading branch information
nathanmarks committed Nov 22, 2015
1 parent 4cb7fe1 commit 6206e70
Showing 1 changed file with 14 additions and 8 deletions.
22 changes: 14 additions & 8 deletions components/font_icon/FontIcon.jsx
@@ -1,18 +1,24 @@
import React from 'react';
import style from './style';
import ClassNames from 'classnames';

const FontIcon = ({
children,
className,
value,
...otherProps
}) => {

const classes = ClassNames('material-icons', className);

const FontIcon = props => {
let className = style[props.value];
if (props.className) className += ` ${props.className}`;
return (
<i data-react-toolbox='icon' {...props} className={className}>
{props.children}
</i>
<span className={classes} {...otherProps} >
{value ? value : children}
</span>
);
};

FontIcon.propTypes = {
children: React.PropTypes.any,
children: React.PropTypes.string,
className: React.PropTypes.string,
value: React.PropTypes.string
};
Expand Down

0 comments on commit 6206e70

Please sign in to comment.