No Description

FollowingItem.js 3.8KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146
  1. /**
  2. * Created by zack on 2018/5/2.
  3. */
  4. import {
  5. View,
  6. Text,
  7. StyleSheet,
  8. FlatList,
  9. Platform,
  10. TouchableOpacity,
  11. ImageBackground,
  12. Image
  13. } from 'react-native'
  14. import React, {Component} from 'react'
  15. import {NavigationBarHeight, TabBarHeight, ScreenDimensions} from '../../../../utils/DimensionsTools'
  16. export default class FollowingItem extends Component {
  17. render() {
  18. return (
  19. <View style={styles.ImageView}>
  20. <View style={styles.TopView}>
  21. <View style={styles.UserInfoImageBgView}>
  22. <Image source={require('../../../../resources/images/TabBar/Community/Follow/user1.png')} style={styles.UserHeaderImageView} />
  23. <View style={styles.UserInfoBgView}>
  24. <Text style={styles.NameText}>{'Zack'}</Text>
  25. <Text style={styles.TimeText}>{'50分钟前'}</Text>
  26. </View>
  27. </View>
  28. <Image source={require('../../../../resources/images/TabBar/Community/Follow/cancel.png')} style={styles.EyeImageView}/>
  29. </View>
  30. <Text style={styles.TitleText}>{"记忆要从读背开始,因为语言大都是从模仿开始的。"}</Text>
  31. <ImageBackground source={require('../../../../resources/images/TabBar/Community/Follow/img2.png')} style={styles.CenterImageBackground}>
  32. <Image source={require('../../../../resources/images/TabBar/Community/Follow/img_bg.png')} style={styles.ShadowImageView}/>
  33. </ImageBackground>
  34. <View style = {styles.BottomTagBgView}>
  35. <View style={styles.BottomLineView} />
  36. <TouchableOpacity style={styles.BottomButtonView}>
  37. <Image source={require('../../../../resources/images/TabBar/Community/Answer/like.png')} style={[styles.BottomButtonImageView, {marginLeft: 48}]}/>
  38. <Text style={styles.BottomButtonText}>{'29'}</Text>
  39. </TouchableOpacity>
  40. <TouchableOpacity style={styles.BottomButtonView}>
  41. <Image source={require('../../../../resources/images/TabBar/Community/Answer/mess.png')} style={styles.BottomButtonImageView}/>
  42. <Text style={styles.BottomButtonText}>{'68'}</Text>
  43. </TouchableOpacity>
  44. <TouchableOpacity style={styles.BottomButtonView}>
  45. <Image source={require('../../../../resources/images/TabBar/Community/Answer/Forward.png')} style={[styles.BottomButtonImageView]}/>
  46. <Text style={[styles.BottomButtonText, {marginRight: 48}]}>{'453'}</Text>
  47. </TouchableOpacity>
  48. </View>
  49. </View>
  50. );
  51. }
  52. }
  53. const styles = StyleSheet.create({
  54. View: {
  55. width: ScreenDimensions.width,
  56. height: 377,
  57. backgroundColor: '#ffffff'
  58. },
  59. TopView: {
  60. width: ScreenDimensions.width,
  61. flexDirection: 'row',
  62. alignItems: 'center',
  63. justifyContent: 'space-between'
  64. },
  65. UserInfoImageBgView: {
  66. flexDirection: 'row',
  67. alignItems: 'center',
  68. marginTop: 14,
  69. },
  70. UserHeaderImageView: {
  71. height: 48,
  72. width: 48,
  73. marginLeft: 17,
  74. marginRight: 35,
  75. },
  76. UserInfoBgView: {
  77. justifyContent: 'center',
  78. },
  79. NameText: {
  80. fontSize: 17,
  81. color: '#000000'
  82. },
  83. TimeText: {
  84. marginTop: 8,
  85. fontSize: 17,
  86. color: '#9c9c9c'
  87. },
  88. EyeImageView: {
  89. marginRight: 12,
  90. },
  91. TitleText: {
  92. fontSize: 17,
  93. color: '#000000',
  94. marginTop: 30,
  95. marginBottom: 20,
  96. marginLeft: 13,
  97. marginRight: 13,
  98. },
  99. CenterImageBackground: {
  100. width: ScreenDimensions.width,
  101. height: 196,
  102. },
  103. ShadowImageView: {
  104. position: 'absolute',
  105. left: 0,
  106. bottom: 0,
  107. },
  108. BottomTagBgView: {
  109. width: ScreenDimensions.width,
  110. height: 56,
  111. backgroundColor: '#eef0ef',
  112. flexDirection: 'row',
  113. },
  114. BottomButtonView: {
  115. width: ScreenDimensions.width/3.0,
  116. height: 48,
  117. flexDirection: 'row',
  118. justifyContent: 'center',
  119. alignItems: 'center',
  120. backgroundColor: 'white'
  121. },
  122. BottomButtonImageView: {
  123. marginRight: 13,
  124. },
  125. BottomButtonText: {
  126. fontSize: 13,
  127. color: '#9c9c9c'
  128. },
  129. BottomLineView: {
  130. position: 'absolute',
  131. width: ScreenDimensions.width,
  132. height: 0.5,
  133. backgroundColor: '#d7d7d7',
  134. left: 0,
  135. top: 0,
  136. },
  137. })