1
0
mirror of https://github.com/yldio/copilot.git synced 2024-09-21 05:43:52 +03:00

changing props name to be more consistant

This commit is contained in:
Alex Windett 2016-10-28 12:47:58 +01:00
parent 7e85e17367
commit 54b9601d9c
2 changed files with 6 additions and 6 deletions

View File

@ -6,7 +6,7 @@ const styles = require('./style.css');
const Avatar = ({
color,
image,
src,
name,
className,
style
@ -23,12 +23,12 @@ const Avatar = ({
};
const fill = () => {
if ( image ) {
if ( src ) {
return (
<img
alt={name}
className={styles.picture}
src={image}
src={src}
style={style}
/>
);
@ -55,8 +55,8 @@ const Avatar = ({
Avatar.propTypes = {
className: React.PropTypes.string,
color: React.PropTypes.string,
image: React.PropTypes.string,
name: React.PropTypes.string,
src: React.PropTypes.string,
style: React.PropTypes.object
};

View File

@ -19,7 +19,7 @@ nmodule.exports = ReactDOM.renderToString(
<Avatar color='#35a8c0' name='Alex' />
</Column>
<Column>
<Avatar color='#ef6176' name='Alex' image='https://openclipart.org/image/2400px/svg_to_png/177482/ProfilePlaceholderSuit.png' />
<Avatar color='#ef6176' name='Alex' src='https://openclipart.org/image/2400px/svg_to_png/177482/ProfilePlaceholderSuit.png' />
</Column>
</Row>
</Base>
@ -35,7 +35,7 @@ const Avatar = require('ui/avatar');
module.exports = () => {
return (
<Avatar color='#35a8c0' name='Alex' />
<Avatar color='#ef6176' name='Alex' image='path/to/image.png' />
<Avatar color='#ef6176' name='Alex' src='path/to/image.png' />
);
}
```