Skip to content

Commit

Permalink
fix(rn): chat detail loader
Browse files Browse the repository at this point in the history
Signed-off-by: Godefroy Ponsinet <godefroy.ponsinet@outlook.com>
  • Loading branch information
90dy committed Dec 21, 2018
1 parent c9830dc commit 08a4991
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions client/react-native/common/components/Screens/Chats/Detail.js
@@ -1,7 +1,11 @@
import { Platform, TextInput as RNTextInput } from 'react-native'
import {
ActivityIndicator,
Platform,
TextInput as RNTextInput,
} from 'react-native'
import React, { PureComponent } from 'react'

import { Flex, Header, Icon, Loader, Screen, Text } from '../../Library'
import { Flex, Header, Icon, Screen, Text } from '../../Library'
import { Pagination, QueryReducer, RelayContext } from '../../../relay'
import { colors } from '../../../constants'
import { fragments } from '../../../graphql'
Expand Down Expand Up @@ -299,7 +303,13 @@ export default class Detail extends PureComponent {
switch (state.type) {
default:
case state.loading:
return <Loader />
return (
<Flex.Rows align='center'>
<Flex.Cols align='center'>
<ActivityIndicator size='large' />
</Flex.Cols>
</Flex.Rows>
)
case state.success:
return (
<Chat
Expand Down

0 comments on commit 08a4991

Please sign in to comment.