finish basic text support on iOS

This commit is contained in:
Horcrux
2016-09-17 15:42:27 +08:00
parent d549f6ca9c
commit a37c3ceee6
11 changed files with 150 additions and 75 deletions

View File

@@ -1,7 +1,7 @@
import SerializablePath from '../SerializablePath';
import _ from 'lodash';
import React, {Children} from 'react';
import {fontAndRenderPropsKeys} from '../props';
import {fontAndRenderPropsKeys, fontPropsKeys} from '../props';
import Span from '../../elements/Span';
const fontRegExp = /^\s*((?:(?:normal|bold|italic)\s+)*)(?:(\d+(?:\.\d+)?)[ptexm%]*(?:\s*\/.*?)?\s+)?\s*"?([^"]*)/i;
@@ -209,8 +209,11 @@ export default function(props) {
...extractFont(frame.props)
}
};
return <Span {...spanProps} />;
return <Span
{..._.omit(frame.props, fontPropsKeys)}
frame={spanProps}
/>;
});
return {