Header.js 786 B

1234567891011121314151617181920212223242526
  1. import * as React from 'react';
  2. import { Platform } from 'react-native';
  3. import { StatusBar } from 'expo-status-bar';
  4. import Constants from 'expo-constants';
  5. import { Appbar } from 'react-native-paper';
  6. import { goBack } from '../navigation/RootNavigation';
  7. export default function Header() {
  8. return (
  9. <>
  10. <StatusBar backgroundColor="#FFC21C" translucent={false} />
  11. <Appbar.Header
  12. dark
  13. statusBarHeight={Platform.OS === 'ios' ? Constants.statusBarHeight : 0}
  14. >
  15. <Appbar.BackAction onPress={goBack} />
  16. <Appbar.Content
  17. title="忘记密码"
  18. titleStyle={{ textAlign: 'center', fontSize: 16 }}
  19. />
  20. <Appbar.Action icon="dots-vertical" />
  21. </Appbar.Header>
  22. </>
  23. );
  24. }