您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

styles.js 4.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186
  1. import { BoxModel, ColorPalette, createStyleSheet } from '../../../base/styles';
  2. /**
  3. * The style of toolbar buttons.
  4. */
  5. const toolbarButton = {
  6. backgroundColor: ColorPalette.white,
  7. borderRadius: 20,
  8. borderWidth: 0,
  9. flex: 0,
  10. flexDirection: 'row',
  11. height: 40,
  12. justifyContent: 'center',
  13. margin: BoxModel.margin,
  14. marginBottom: BoxModel.margin / 2,
  15. opacity: 0.7,
  16. width: 40
  17. };
  18. /**
  19. * The icon style of the toolbar buttons.
  20. */
  21. const toolbarButtonIcon = {
  22. alignSelf: 'center',
  23. color: ColorPalette.darkGrey,
  24. fontSize: 22
  25. };
  26. /**
  27. * The Toolbox and toolbar related styles.
  28. */
  29. const styles = createStyleSheet({
  30. /**
  31. * The style of the toolbar button which hangs the current conference up.
  32. */
  33. hangupButton: {
  34. ...toolbarButton,
  35. backgroundColor: ColorPalette.red,
  36. borderRadius: 30,
  37. height: 60,
  38. width: 60
  39. },
  40. /**
  41. * The icon style of toolbar buttons which hangs the current conference up.
  42. */
  43. hangupButtonIcon: {
  44. ...toolbarButtonIcon,
  45. color: ColorPalette.white,
  46. fontSize: 24
  47. },
  48. /**
  49. * The style of the toolbar.
  50. */
  51. toolbar: {
  52. alignItems: 'center',
  53. bottom: 0,
  54. flex: 0,
  55. flexDirection: 'row',
  56. justifyContent: 'center',
  57. left: 0,
  58. position: 'absolute',
  59. right: 0
  60. },
  61. /**
  62. * The style of toolbar buttons.
  63. */
  64. toolbarButton,
  65. /**
  66. * The icon style of the toolbar buttons.
  67. */
  68. toolbarButtonIcon,
  69. /**
  70. * The style of the root/top-level {@link Container} of {@link Toolbox}.
  71. * This is the narrow layout version which locates the toolbar on top of
  72. * the filmstrip, at the bottom of the screen.
  73. */
  74. toolboxNarrow: {
  75. flexDirection: 'column',
  76. flexGrow: 1
  77. },
  78. /**
  79. * The style of the root/top-level {@link Container} of {@link Toolbox}.
  80. * This is the wide layout version which locates the toolbar at the bottom
  81. * of the screen.
  82. */
  83. toolboxWide: {
  84. bottom: 0,
  85. left: 0,
  86. position: 'absolute',
  87. right: 0,
  88. top: 0
  89. },
  90. /**
  91. * The style of toolbar buttons which display white icons.
  92. */
  93. whiteToolbarButton: {
  94. ...toolbarButton,
  95. backgroundColor: ColorPalette.buttonUnderlay
  96. },
  97. /**
  98. * The icon style of toolbar buttons which display white icons.
  99. */
  100. whiteToolbarButtonIcon: {
  101. ...toolbarButtonIcon,
  102. color: ColorPalette.white
  103. }
  104. });
  105. export default styles;
  106. /**
  107. * Styles for the hangup button.
  108. */
  109. export const hangupButtonStyles = {
  110. iconStyle: styles.whiteToolbarButtonIcon,
  111. style: styles.hangupButton,
  112. underlayColor: ColorPalette.buttonUnderlay
  113. };
  114. /**
  115. * Styles for buttons in the toolbar.
  116. */
  117. export const toolbarButtonStyles = {
  118. iconStyle: styles.toolbarButtonIcon,
  119. style: styles.toolbarButton
  120. };
  121. /**
  122. * Styles for toggled buttons in the toolbar.
  123. */
  124. export const toolbarToggledButtonStyles = {
  125. iconStyle: styles.whiteToolbarButtonIcon,
  126. style: styles.whiteToolbarButton
  127. };
  128. /**
  129. * Styles for the {@code OverflowMenu} items.
  130. *
  131. * These have been implemented as per the Material Design guidelines:
  132. * {@link https://material.io/guidelines/components/bottom-sheets.html}.
  133. */
  134. const overflowMenuStyles = createStyleSheet({
  135. /**
  136. * Container style for a {@code ToolboxItem} rendered in the
  137. * {@code OverflowMenu}.
  138. */
  139. container: {
  140. alignItems: 'center',
  141. flexDirection: 'row',
  142. height: 48
  143. },
  144. /**
  145. * Style for the {@code Icon} element in a {@code ToolboxItem} rendered in
  146. * the {@code OverflowMenu}.
  147. */
  148. icon: {
  149. fontSize: 24
  150. },
  151. /**
  152. * Style for the label in a {@code ToolboxItem} rendered in the
  153. * {@code OverflowMenu}.
  154. */
  155. label: {
  156. flex: 1,
  157. fontSize: 16,
  158. marginLeft: 32,
  159. opacity: 0.87
  160. }
  161. });
  162. export const overflowMenuItemStyles = {
  163. iconStyle: overflowMenuStyles.icon,
  164. labelStyle: overflowMenuStyles.label,
  165. style: overflowMenuStyles.container,
  166. underlayColor: '#eee'
  167. };