You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

styles.js 3.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149
  1. // @flow
  2. import { BoxModel, ColorPalette } from '../../../base/styles';
  3. /**
  4. * The styles of the feature chat.
  5. *
  6. * NOTE: Sizes and colors come from the 8x8 guidelines. This is the first
  7. * component to receive this treating, if others happen to have similar, we
  8. * need to extract the brand colors and sizes into a branding feature (planned
  9. * for the future).
  10. */
  11. export default {
  12. /**
  13. * Wrapper View for the avatar.
  14. */
  15. avatarWrapper: {
  16. marginRight: 8,
  17. width: 32
  18. },
  19. /**
  20. * Background of the chat screen.
  21. */
  22. backdrop: {
  23. backgroundColor: ColorPalette.white,
  24. flex: 1
  25. },
  26. chatContainer: {
  27. alignItems: 'stretch',
  28. flex: 1,
  29. flexDirection: 'column'
  30. },
  31. chatLink: {
  32. color: ColorPalette.blue
  33. },
  34. /**
  35. * Wrapper for the details together, such as name, message and time.
  36. */
  37. detailsWrapper: {
  38. alignItems: 'flex-start',
  39. flex: 1,
  40. flexDirection: 'column'
  41. },
  42. /**
  43. * The text node for the display name.
  44. */
  45. displayName: {
  46. color: 'rgb(118, 136, 152)',
  47. fontSize: 13
  48. },
  49. /**
  50. * A special padding to avoid issues on some devices (such as Android devices with custom suggestions bar).
  51. */
  52. extraBarPadding: {
  53. paddingBottom: 30
  54. },
  55. inputBar: {
  56. alignItems: 'center',
  57. borderTopColor: 'rgb(209, 219, 231)',
  58. borderTopWidth: 1,
  59. flexDirection: 'row',
  60. paddingHorizontal: BoxModel.padding
  61. },
  62. inputField: {
  63. color: 'rgb(28, 32, 37)',
  64. flex: 1,
  65. height: 48
  66. },
  67. messageContainer: {
  68. flex: 1
  69. },
  70. /**
  71. * The message text itself.
  72. */
  73. messageText: {
  74. color: 'rgb(28, 32, 37)',
  75. fontSize: 15
  76. },
  77. /**
  78. * Wrapper View for the entire block.
  79. */
  80. messageWrapper: {
  81. alignItems: 'flex-start',
  82. flex: 1,
  83. flexDirection: 'row',
  84. marginHorizontal: 17,
  85. marginVertical: 4
  86. },
  87. /**
  88. * Style modifier for the {@code detailsWrapper} for own messages.
  89. */
  90. ownMessageDetailsWrapper: {
  91. alignItems: 'flex-end'
  92. },
  93. /**
  94. * Style modifier for the {@code textWrapper} for own messages.
  95. */
  96. ownTextWrapper: {
  97. backgroundColor: 'rgb(210, 231, 249)',
  98. borderTopLeftRadius: 8,
  99. borderTopRightRadius: 0
  100. },
  101. sendButtonIcon: {
  102. color: ColorPalette.darkGrey,
  103. fontSize: 22
  104. },
  105. /**
  106. * Style modifier for system (error) messages.
  107. */
  108. systemTextWrapper: {
  109. backgroundColor: 'rgb(247, 215, 215)'
  110. },
  111. /**
  112. * Wrapper for the name and the message text.
  113. */
  114. textWrapper: {
  115. alignItems: 'flex-start',
  116. backgroundColor: 'rgb(240, 243, 247)',
  117. borderRadius: 8,
  118. borderTopLeftRadius: 0,
  119. flexDirection: 'column',
  120. padding: 9
  121. },
  122. /**
  123. * Text node for the timestamp.
  124. */
  125. timeText: {
  126. color: 'rgb(164, 184, 209)',
  127. fontSize: 13
  128. }
  129. };