react-native-animated-header-flat-list
Version:
A React Native FlatList component with an animated collapsible header, featuring parallax effects, smooth title transitions, sticky component support, and customizable styles. Built with TypeScript and separate background/content layers in header.
16 lines (15 loc) • 488 B
JavaScript
;
export const getFontSizeFromStyle = textStyle => {
if (!textStyle) return undefined;
if (Array.isArray(textStyle)) {
for (const styleItem of textStyle.reverse()) {
if (styleItem && typeof styleItem === 'object' && 'fontSize' in styleItem) {
return styleItem.fontSize;
}
}
} else if (typeof textStyle === 'object' && 'fontSize' in textStyle) {
return textStyle.fontSize;
}
return undefined;
};
//# sourceMappingURL=styleUtils.js.map