ptomasroos / react-native-scrollable-tab-view

Tabbed navigation that you can swipe between, each tab can have its own ScrollView and maintain its own scroll position between swipes. Pleasantly animated. Customizable tab bar
https://www.npmjs.com/package/react-native-scrollable-tab-view
6.93k stars 2.28k forks source link

安卓环境,改变菜单renderTabBar里面的数据,内容就不显示 #1123

Open xiaoketeng opened 3 years ago

xiaoketeng commented 3 years ago

Steps to Reproduce

Expected Behavior

Actual Behavior

xiaoketeng commented 3 years ago

"react-native": "0.63.2", "react-native-scrollable-tab-view": "^1.0.0",

部门代码`<ScrollableTabView locked={isLocked} onChangeTab={(obj) => menuTab(obj)} ref={item => setTabViewRef(item)} tabBarPosition='top' //位于屏幕的位置,top顶部 bottom底部 overlayTop顶部,悬浮在内容视图之上 overlayBottom底部,悬浮在内容视图之上 renderTabBar={() => <ScrollableTabBar onAddBtn={()=>openModal()}/>} //ScrollableTabBar支持超过屏幕宽度,Tab左右滚动,而DefaultTabBar不支持 initialPage={0} style={[{flex:1}]} tabBarUnderlineStyle={styles.lineStyle} tabBarActiveTextColor='#fff'

{ selectedColumns.map((item) =>{ return <View style={{flex:1,height:2000,backgroundColor:'#923rr'}} key={item.sortId} tabLabel={item.text}>{item.sortId} // if(item.sortId === 'menuH6'){ // return ( // // <WebView // style={{ width: DEVICE_WIDTH}} // source={{ uri: item.url}} // /> // ) // }else{ // return pageDataList[item.sortId]?( // <NewList // loadMore={loadMore} // onRefresh={onRefresh} // tabLabel={item.text} // key={item.sortId} // sortId={item.sortId} // list={ pageDataList[item.sortId].list } // imgTitleList={newImgList} // preventTouchEvetn={()=>preventTouchEvetn()} // releaseTouchEvetn={()=>releaseTouchEvetn()} // hasMore={ pageDataList[item.sortId].hasMore}/> // ):( // // ) // } }) } )}`