File tree Expand file tree Collapse file tree 6 files changed +34
-31
lines changed Expand file tree Collapse file tree 6 files changed +34
-31
lines changed Original file line number Diff line number Diff line change @@ -9,7 +9,6 @@ import type { AppNavigationProp } from '../nav/AppNavigator';
9
9
import { ThemeContext , createStyleSheet } from '../styles' ;
10
10
import type { Narrow , EditMessage } from '../types' ;
11
11
import KeyboardAvoider from '../common/KeyboardAvoider' ;
12
- import OfflineNotice from '../common/OfflineNotice' ;
13
12
import ChatNavBar from '../nav/ChatNavBar' ;
14
13
import MessageList from '../webview/MessageList' ;
15
14
import NoMessages from '../message/NoMessages' ;
@@ -199,7 +198,6 @@ export default function ChatScreen(props: Props): Node {
199
198
return (
200
199
< KeyboardAvoider style = { [ componentStyles . screen , { backgroundColor } ] } behavior = "padding" >
201
200
< ChatNavBar narrow = { narrow } editMessage = { editMessage } />
202
- < OfflineNotice />
203
201
< UnreadNotice narrow = { narrow } />
204
202
{ ( ( ) => {
205
203
if ( ! isNarrowValid ) {
Original file line number Diff line number Diff line change @@ -10,7 +10,6 @@ import type { EditingEvent } from 'react-native/Libraries/Components/TextInput/T
10
10
import styles , { createStyleSheet , ThemeContext } from '../styles' ;
11
11
import type { LocalizableText , LocalizableReactText } from '../types' ;
12
12
import KeyboardAvoider from './KeyboardAvoider' ;
13
- import OfflineNotice from './OfflineNotice' ;
14
13
import LoadingBanner from './LoadingBanner' ;
15
14
import ModalNavBar from '../nav/ModalNavBar' ;
16
15
import ModalSearchNavBar from '../nav/ModalSearchNavBar' ;
@@ -112,7 +111,6 @@ export default function Screen(props: Props): Node {
112
111
) : (
113
112
< ModalNavBar canGoBack = { canGoBack } title = { title } />
114
113
) }
115
- < OfflineNotice />
116
114
{ shouldShowLoadingBanner && < LoadingBanner /> }
117
115
< KeyboardAvoider
118
116
behavior = "padding"
Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ import { doNarrow } from '../actions';
21
21
import { isNarrowValid as getIsNarrowValid } from '../selectors' ;
22
22
import NavButton from './NavButton' ;
23
23
import { useNavigation } from '../react-navigation' ;
24
+ import OfflineNotice from '../common/OfflineNotice' ;
24
25
25
26
function ExtraNavButtonStream ( props : { | + color : string , + narrow : Narrow | } ) : Node {
26
27
const { color, narrow } = props ;
@@ -191,6 +192,7 @@ export default function ChatNavBar(props: {|
191
192
textColor = { textColor }
192
193
/>
193
194
</ SafeAreaView >
195
+ < OfflineNotice />
194
196
</ >
195
197
) ;
196
198
}
Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ import type { LocalizableReactText } from '../types';
8
8
import globalStyles , { ThemeContext , NAVBAR_SIZE } from '../styles' ;
9
9
import ZulipTextIntl from '../common/ZulipTextIntl' ;
10
10
import NavBarBackButton from './NavBarBackButton' ;
11
+ import OfflineNotice from '../common/OfflineNotice' ;
11
12
12
13
type Props = $ReadOnly < { |
13
14
canGoBack : boolean ,
@@ -63,12 +64,15 @@ export default function ModalNavBar(props: Props): Node {
63
64
) ;
64
65
65
66
return (
66
- < SafeAreaView mode = "padding" edges = { [ 'top' , 'right' , 'left' ] } style = { styles . safeAreaView } >
67
- { /* See comment on styles.contentArea.minHeight. */ }
68
- < View style = { styles . contentArea } >
69
- { canGoBack && < NavBarBackButton /> }
70
- < ZulipTextIntl style = { styles . text } text = { title } numberOfLines = { 1 } ellipsizeMode = "tail" />
71
- </ View >
72
- </ SafeAreaView >
67
+ < >
68
+ < SafeAreaView mode = "padding" edges = { [ 'top' , 'right' , 'left' ] } style = { styles . safeAreaView } >
69
+ { /* See comment on styles.contentArea.minHeight. */ }
70
+ < View style = { styles . contentArea } >
71
+ { canGoBack && < NavBarBackButton /> }
72
+ < ZulipTextIntl style = { styles . text } text = { title } numberOfLines = { 1 } ellipsizeMode = "tail" />
73
+ </ View >
74
+ </ SafeAreaView >
75
+ < OfflineNotice />
76
+ </ >
73
77
) ;
74
78
}
Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ import { ThemeContext, NAVBAR_SIZE } from '../styles';
9
9
import SearchInput from '../common/SearchInput' ;
10
10
import NavBarBackButton from './NavBarBackButton' ;
11
11
import type { LocalizableText } from '../types' ;
12
+ import OfflineNotice from '../common/OfflineNotice' ;
12
13
13
14
type Props = $ReadOnly < { |
14
15
autoFocus : boolean ,
@@ -50,22 +51,25 @@ export default function ModalSearchNavBar(props: Props): Node {
50
51
) ;
51
52
52
53
return (
53
- < SafeAreaView mode = "padding" edges = { [ 'top' , 'right' , 'left' ] } style = { styles . safeAreaView } >
54
- { /* See comment on styles.contentArea.minHeight. */ }
55
- < View style = { styles . contentArea } >
56
- { canGoBack && (
57
- < >
58
- < NavBarBackButton />
59
- < View style = { { width : 20 } } />
60
- </ >
61
- ) }
62
- < SearchInput
63
- autoFocus = { autoFocus }
64
- onChangeText = { searchBarOnChange }
65
- onSubmitEditing = { searchBarOnSubmit }
66
- placeholder = { placeholder }
67
- />
68
- </ View >
69
- </ SafeAreaView >
54
+ < >
55
+ < SafeAreaView mode = "padding" edges = { [ 'top' , 'right' , 'left' ] } style = { styles . safeAreaView } >
56
+ { /* See comment on styles.contentArea.minHeight. */ }
57
+ < View style = { styles . contentArea } >
58
+ { canGoBack && (
59
+ < >
60
+ < NavBarBackButton />
61
+ < View style = { { width : 20 } } />
62
+ </ >
63
+ ) }
64
+ < SearchInput
65
+ autoFocus = { autoFocus }
66
+ onChangeText = { searchBarOnChange }
67
+ onSubmitEditing = { searchBarOnSubmit }
68
+ placeholder = { placeholder }
69
+ />
70
+ </ View >
71
+ </ SafeAreaView >
72
+ < OfflineNotice />
73
+ </ >
70
74
) ;
71
75
}
Original file line number Diff line number Diff line change @@ -21,7 +21,6 @@ import { caseInsensitiveCompareFunc } from '../utils/misc';
21
21
import StreamItem from './StreamItem' ;
22
22
import ModalNavBar from '../nav/ModalNavBar' ;
23
23
import NestedNavRow from '../common/NestedNavRow' ;
24
- import OfflineNotice from '../common/OfflineNotice' ;
25
24
26
25
const styles = createStyleSheet ( {
27
26
container : {
@@ -74,8 +73,6 @@ export default function SubscriptionsScreen(props: Props): Node {
74
73
< View style = { styles . container } >
75
74
{ /* Consumes the top inset. */ }
76
75
< ModalNavBar canGoBack = { false } title = "Streams" />
77
- < OfflineNotice />
78
-
79
76
< LoadingBanner />
80
77
{ subscriptions . length === 0 ? (
81
78
< SearchEmptyState text = "No streams found" />
You can’t perform that action at this time.
0 commit comments