Skip to content

Commit

Permalink
Fixed the merge of style-attributes
Browse files Browse the repository at this point in the history
  • Loading branch information
itinance committed Dec 27, 2016
1 parent 7bd7bcc commit ad07113
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
'use strict';

import React, { Component, PropTypes } from 'react';
import { Image, Platform, Dimensions } from 'react-native';
import { Image, Platform, Dimensions, StyleSheet } from 'react-native';

const IMG_CENTER_MODE = Platform.OS === 'ios' ? 'center' : 'contain';

Expand All @@ -25,8 +25,8 @@ class Ikon extends Component {
const height = doScale( props.height ? props.height : this.traverseIconSet(name, 'height') );
const source = props.source ? props.source : this.traverseIconSet(name, 'source');

let _style = style ? style : {};
_style = [..._style, {width, height}];
let _style = style ? StyleSheet.flatten(style) : {};
_style = {..._style, width, height};

if(!!disabled) {
let disabledStyle = this.traverseIconSet(name, '$disabled')
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-native-ikon",
"version": "0.0.2",
"version": "0.0.3",
"description": "flexible IconSets for react-native",
"main": "index.js",
"repository": {
Expand Down

0 comments on commit ad07113

Please sign in to comment.