mirror of
https://github.com/zoriya/react-native-svg.git
synced 2026-06-09 01:25:01 +00:00
First letterSpacing implementation attempt
This commit is contained in:
+3
-1
@@ -23,7 +23,9 @@ function fontDiffer(a, b) {
|
||||
return a.fontSize !== b.fontSize ||
|
||||
a.fontFamily !== b.fontFamily ||
|
||||
a.fontStyle !== b.fontStyle ||
|
||||
a.fontWeight !== b.fontWeight;
|
||||
a.fontWeight !== b.fontWeight ||
|
||||
a.kerning !== b.kerning ||
|
||||
a.letterSpacing !== b.letterSpacing;
|
||||
}
|
||||
|
||||
const ViewBoxAttributes = {
|
||||
|
||||
@@ -55,7 +55,9 @@ export function extractFont(props) {
|
||||
fontFamily: extractSingleFontFamily(props.fontFamily),
|
||||
fontSize: isNaN(fontSize) ? null : fontSize,
|
||||
fontWeight: props.fontWeight,
|
||||
fontStyle: props.fontStyle
|
||||
fontStyle: props.fontStyle,
|
||||
kerning: props.kerning,
|
||||
letterSpacing: props.letterSpacing,
|
||||
};
|
||||
|
||||
if (typeof props.font === 'string') {
|
||||
|
||||
@@ -53,6 +53,8 @@ const fontProps = {
|
||||
fontSize: numberProp,
|
||||
fontWeight: numberProp,
|
||||
fontStyle: PropTypes.string,
|
||||
letterSpacing: PropTypes.string,
|
||||
kerning: PropTypes.string,
|
||||
font: PropTypes.object
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user