Interface: NavigationTemplateConfig
Hierarchy
-
AndroidNavigationBaseTemplateConfig
↳
NavigationTemplateConfig
Table of contents
Properties
- actions
- backgroundColor
- component
- id
- leadingNavigationBarButtons
- mapButtons
- navigationInfo
- tabImage
- tabSystemImageName
- tabSystemItem
- tabTitle
- trailingNavigationBarButtons
- travelEstimate
Methods
- onBarButtonPressed
- onDidAppear
- onDidDisappear
- onDidDismissPanningInterface
- onDidShowPanningInterface
- onWillAppear
- onWillDisappear
Properties
actions
• actions: Action
<ActionType
>[]
Sets an ActionStrip with a list of template-scoped actions for this template. The Action buttons in Map Based Template are automatically adjusted based on the screen size. On narrow width screen, icon Actions show by default. If no icon specify, showing title Actions instead. On wider width screen, title Actions show by default. If no title specify, showing icon Actions instead. Requirements This template allows up to 4 Actions in its ActionStrip. Of the 4 allowed Actions, it can either be a title Action as set via setTitle, or a icon Action as set via setIcon.
Defined in
packages/react-native-carplay/src/templates/android/NavigationTemplate.ts:16 (opens in a new tab)
backgroundColor
• Optional
backgroundColor: CarColor
Sets the background color to use for the navigation information. Depending on contrast requirements, capabilities of the vehicle screens, or other factors, the color may be ignored by the host or overridden by the vehicle system.
Defined in
packages/react-native-carplay/src/templates/android/NavigationTemplate.ts:21 (opens in a new tab)
component
• component: ComponentType
<any
>
Your component to render inside Android Auto Map view
Example component: MyComponent
Inherited from
AndroidNavigationBaseTemplateConfig.component
Defined in
id
• Optional
id: string
Give the template your own ID. Must be unique.
Inherited from
AndroidNavigationBaseTemplateConfig.id
Defined in
packages/react-native-carplay/src/templates/Template.ts:23 (opens in a new tab)
leadingNavigationBarButtons
• Optional
leadingNavigationBarButtons: BarButton
[]
An array of bar buttons to display on the leading side of the navigation bar.
The navigation bar displays up to two buttons in the leading space. When including more than two buttons in the array, the system displays only the first two buttons. iOS
Inherited from
AndroidNavigationBaseTemplateConfig.leadingNavigationBarButtons
Defined in
packages/react-native-carplay/src/templates/Template.ts:30 (opens in a new tab)
mapButtons
• Optional
mapButtons: Action
<ActionType
>[]
Sets an ActionStrip with a list of map-control related actions for this template, such as pan or zoom. The host will draw the buttons in an area that is associated with map controls. If the app does not include the PAN button in this ActionStrip, the app will not receive the user input for panning gestures from SurfaceCallback methods, and the host will exit any previously activated pan mode. Requirements This template allows up to 4 Actions in its map ActionStrip. Only Actions with icons set via setIcon are allowed.
Defined in
packages/react-native-carplay/src/templates/android/NavigationTemplate.ts:32 (opens in a new tab)
navigationInfo
• Optional
navigationInfo: NavigationInfo
Sets the navigation information to display on the template. Unless set with this method, navigation info won't be displayed on the template.
Defined in
packages/react-native-carplay/src/templates/android/NavigationTemplate.ts:37 (opens in a new tab)
tabImage
• Optional
tabImage: ImageSourcePropType
Image source for tab
Inherited from
AndroidNavigationBaseTemplateConfig.tabImage
Defined in
packages/react-native-carplay/src/templates/Template.ts:49 (opens in a new tab)
tabSystemImageName
• Optional
tabSystemImageName: string
Name of system image for tab
Inherited from
AndroidNavigationBaseTemplateConfig.tabSystemImageName
Defined in
packages/react-native-carplay/src/templates/Template.ts:45 (opens in a new tab)
tabSystemItem
• Optional
tabSystemItem: number
UITabBarSystemItem
Inherited from
AndroidNavigationBaseTemplateConfig.tabSystemItem
Defined in
packages/react-native-carplay/src/templates/Template.ts:41 (opens in a new tab)
tabTitle
• Optional
tabTitle: string
Set tab title
Inherited from
AndroidNavigationBaseTemplateConfig.tabTitle
Defined in
packages/react-native-carplay/src/templates/Template.ts:53 (opens in a new tab)
trailingNavigationBarButtons
• Optional
trailingNavigationBarButtons: BarButton
[]
An array of bar buttons to display on the trailing side of the navigation bar.
The navigation bar displays up to two buttons in the trailing space. When including more than two buttons in the array, the system displays only the first two buttons. iOS
Inherited from
AndroidNavigationBaseTemplateConfig.trailingNavigationBarButtons
Defined in
packages/react-native-carplay/src/templates/Template.ts:37 (opens in a new tab)
travelEstimate
• Optional
travelEstimate: TravelEstimates
Sets the TravelEstimate to the final destination.
Defined in
packages/react-native-carplay/src/templates/android/NavigationTemplate.ts:25 (opens in a new tab)
Methods
onBarButtonPressed
▸ onBarButtonPressed(e
): void
Fired when bar button is pressed
Parameters
Name | Type | Description |
---|---|---|
e | BarButtonEvent | Event |
Returns
void
Inherited from
AndroidNavigationBaseTemplateConfig.onBarButtonPressed
Defined in
packages/react-native-carplay/src/templates/Template.ts:79 (opens in a new tab)
onDidAppear
▸ onDidAppear(e
): void
Fired after template appears
Parameters
Name | Type | Description |
---|---|---|
e | BaseEvent | Event |
Returns
void
Inherited from
AndroidNavigationBaseTemplateConfig.onDidAppear
Defined in
packages/react-native-carplay/src/templates/Template.ts:68 (opens in a new tab)
onDidDisappear
▸ onDidDisappear(e
): void
Fired after template disappears
Parameters
Name | Type | Description |
---|---|---|
e | BaseEvent | Event |
Returns
void
Inherited from
AndroidNavigationBaseTemplateConfig.onDidDisappear
Defined in
packages/react-native-carplay/src/templates/Template.ts:73 (opens in a new tab)
onDidDismissPanningInterface
▸ onDidDismissPanningInterface(): void
Returns
void
Inherited from
AndroidNavigationBaseTemplateConfig.onDidDismissPanningInterface
Defined in
onDidShowPanningInterface
▸ onDidShowPanningInterface(): void
Returns
void
Inherited from
AndroidNavigationBaseTemplateConfig.onDidShowPanningInterface
Defined in
onWillAppear
▸ onWillAppear(e
): void
Fired before template appears
Parameters
Name | Type | Description |
---|---|---|
e | BaseEvent | Event |
Returns
void
Inherited from
AndroidNavigationBaseTemplateConfig.onWillAppear
Defined in
packages/react-native-carplay/src/templates/Template.ts:58 (opens in a new tab)
onWillDisappear
▸ onWillDisappear(e
): void
Fired before template disappears
Parameters
Name | Type | Description |
---|---|---|
e | BaseEvent | Event |
Returns
void
Inherited from
AndroidNavigationBaseTemplateConfig.onWillDisappear
Defined in
packages/react-native-carplay/src/templates/Template.ts:63 (opens in a new tab)