我嘗試建立AA粘性組分喜歡這個程序粘性組分內滾動型
http://www.screencapture.ru/file/E88F08Fc
交易,產品展示,活動標籤頁/ segmentControl實際上是從底部開始,當你滾動,當你打的頭的底部停止和啓動棒,而內容保持滾動
這是我的代碼
<View style={styles.container}>
<ScrollView
style={styles.container}
scrollEventThrottle={16}
onScroll={
Animated.event(
[{nativeEvent:{contentOffset: {y: this.state.scrollY}}}]
)
}
>
{this._renderScrollViewContent()}
</ScrollView>
<View style={styles.stickyStuff}></View>
<Animated.View
style={[styles.header, {height: headerHeight}]}
>
<Animated.Image
source={require('../../assets/images/pvj.jpg')}
style={[styles.backgroundImage, {opacity: imageOpacity}]}
/>
<Animated.View style={[styles.bar, {transform: [{translateY: titleTranslateY}, {translateX: titleTranslateX}]}]}>
<Text style={styles.title}>PARIS VAN JAVA</Text>
</Animated.View>
</Animated.View>
</View>
我不明白你正在試圖做 –
@ChrisGeirman抱歉讓你分不清什麼,因爲我仍然還沒有得到任何的聲譽,所以我不能嵌入圖像需要屏幕截圖每一個動作來演示用戶體驗,所以在這裏一步一步地我需要預期1。http://www.screencapture.ru/file/1609269e 2. http://www.screencapture.ru/file/fEA8377B 3.http ://www.screencapture.ru/file/651a7f98 4.http://www.screencapture。ru/file/8871a435當你看到選項卡(Deals,Products,Events)從屏幕中間開始向上滾動時,它將開始粘貼在標題上 –
奇怪的是,SO會限制新用戶添加屏幕截圖。我不記得那個。我現在知道了。請考慮一下,但是你看過[LayoutAnimation](https://facebook.github.io/react-native/docs/layoutanimation.html)嗎? –