Skip to content

Commit e139c64

Browse files
committed
Document configuration for material symbols
1 parent dec46bd commit e139c64

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

versioned_docs/version-8.x/bottom-tab-navigator.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -571,6 +571,37 @@ The icon object can be one of the following types:
571571
}
572572
```
573573

574+
It also supports the following optional properties:
575+
- `variant` - Supported values: `outlined`, `rounded`, `sharp`
576+
- `weight` - Supported values: `100`, `200`, `300`, `400`, `500`, `600`, `700`
577+
578+
To avoid bundling all the Material Symbols icons in your app, only the `outlined` variant and `400` weight are included by default. To use a different variant and weight, you can customize the font by setting a `"react-navigation"` key in your app's `package.json`:
579+
580+
```json
581+
"react-navigation": {
582+
"material-symbols": {
583+
"fonts": [
584+
{
585+
"variant": "rounded",
586+
"weights": [300]
587+
}
588+
]
589+
}
590+
}
591+
```
592+
593+
You don't need to specify `variant` and `weight` in the `tabBarIcon` option if you only include one variant and weight. The available variant and weight will be used automatically.
594+
595+
If you don't use Material Symbols and want to reduce your app size, you can also disable the font entirely by specifying an empty array for `fonts`:
596+
597+
```json
598+
"react-navigation": {
599+
"material-symbols": {
600+
"fonts": []
601+
}
602+
}
603+
```
604+
574605
- [Drawable resource](https://developer.android.com/guide/topics/resources/drawable-resource) name - Supported on Android
575606

576607
```js

0 commit comments

Comments
 (0)