This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import { StyleSheet, Text, View, Animated } from 'react-native'; | |
import {withSelfMeasure} from './utils/selfMeasureBehavior'; | |
import {compose} from 'recompose'; | |
import buildTransform from './utils/buildTransform'; | |
const AnimatedText = ({ | |
animationRange, | |
onLayoutSetMeasurements, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import {compose, withState, withProps} from 'recompose'; | |
const withMeasurements = compose( | |
withState('elementX', 'setX', 0), | |
withState('elementY', 'setY', 0), | |
withState('elementWidth', 'setWidth', 0), | |
withState('elementHeight', 'setHeight', 0) | |
); | |
const withOnLayout = withProps(({setX, setY, setWidth, setHeight}) => ({ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import { StyleSheet, Text, View, ScrollView, Animated } from 'react-native'; | |
import {compose, withState, withProps} from 'recompose'; | |
import AnimatedHeader from './AnimatedHeader'; | |
import ItemInScroll from './ItemInScroll'; | |
export const scrollRangeForAnimation = 100; | |
const HeaderPlaceholder = <View style={{flex: 0, height: 200, width: '100%'}} />; |