Kaynağa Gözat

Update docs (#1019)

Guy Carmeli 7 yıl önce
ebeveyn
işleme
11ecd8c3bc
1 değiştirilmiş dosya ile 11 ekleme ve 1 silme
  1. 11
    1
      docs/styling-the-navigator.md

+ 11
- 1
docs/styling-the-navigator.md Dosyayı Görüntüle

@@ -26,6 +26,8 @@ export default class StyledScreen extends Component {
26 26
 {
27 27
   navigationBarColor: '#000000', // change the background color of the bottom native navigation bar. Android only
28 28
   navBarTextColor: '#000000', // change the text color of the title (remembered across pushes)
29
+  navBarTextFontFamily: 'font-name', // Changes the title font
30
+  navBarTitleTextCentered: true, // Android only. centers the title, default false.
29 31
   navBarBackgroundColor: '#f7f7f7', // change the background color of the nav bar (remembered across pushes)
30 32
   navBarButtonColor: '#007aff', // change the button colors of the nav bar (eg. the back button) (remembered across pushes)
31 33
   navBarHidden: false, // make the nav bar hidden
@@ -55,6 +57,14 @@ export default class StyledScreen extends Component {
55 57
 }
56 58
 ```
57 59
 
58
-> Note: If you set any styles related to the Status Bar, make sure that in Xcode > project > Info.plist, the property `View controller-based status bar appearance` is set to `YES`.
60
+## Styling the StatusBar
61
+If you set any styles related to the Status Bar, make sure that in Xcode > project > Info.plist, the property `View controller-based status bar appearance` is set to `YES`.
62
+
63
+## Custom fonts
64
+If you'd like to use a custom font, you'll first have to your project.
65
+
66
+* Android - add the `.ttf` or `.otf` files to `src/main/assets/fonts/`
67
+
68
+* iOS - follow this [guide](https://medium.com/@dabit3/adding-custom-fonts-to-react-native-b266b41bff7f)
59 69
 
60 70
 All supported styles are defined [here](https://github.com/wix/react-native-controllers#styling-navigation). There's also an example project there showcasing all the different styles.