[new feature] Icon: size prop support number type

This commit is contained in:
陈嘉涵
2019-05-04 16:41:01 +08:00
parent b644c91383
commit ca020f3214
8 changed files with 29 additions and 7 deletions
+2 -2
View File
@@ -1,4 +1,4 @@
import { use } from '../utils';
import { use, suffixPx } from '../utils';
import { inherit } from '../utils/functional';
import Info from '../info';
import { isSrc } from '../utils/validate/src';
@@ -38,7 +38,7 @@ function Icon(
]}
style={{
color: props.color,
fontSize: props.size
fontSize: suffixPx(props.size)
}}
{...inherit(ctx, true)}
>