Interface: RoutePreviewNavigationTemplateConfig
Hierarchy
-
AndroidNavigationBaseTemplateConfig
↳
RoutePreviewNavigationTemplateConfig
Table of contents
Properties
- actions
- component
- header
- id
- itemList
- leadingNavigationBarButtons
- loading
- mapButtons
- navigateAction
- tabImage
- tabSystemImageName
- tabSystemItem
- tabTitle
- title
- trailingNavigationBarButtons
Methods
- onBarButtonPressed
- onDidAppear
- onDidDisappear
- onDidDismissPanningInterface
- onDidShowPanningInterface
- onWillAppear
- onWillDisappear
Properties
actions
• Optional
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.
Limit
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
component
• component: ComponentType
<any
>
Your component to render inside Android Auto Map view
Example component: MyComponent
Inherited from
AndroidNavigationBaseTemplateConfig.component
Defined in
header
• Optional
header: Header
Sets the Header for this template.
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)
itemList
• Optional
itemList: ListItem
[]
Sets an ItemList to show in a list view along with the map. Unless set with this method, the template will not show an item list. To show a marker corresponding to a point of interest represented by a row, set the Place instance via setMetadata. The host will display the PlaceMarker in both the map and the list view as the row becomes visible.
Limit
The number of items in the ItemList should be smaller or equal than the limit provided by CONTENT_LIMIT_TYPE_PLACE_LIST. The host will ignore any items over that limit. The list itself cannot be selectable as set via setOnSelectedListener. Each Row can add up to 2 lines of texts via addText and cannot contain a Toggle.
Defined in
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)
loading
• Optional
loading: boolean
Sets whether the template is in a loading state.
Defined in
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.
Limit
This template allows up to 4 Actions in its map ActionStrip. Only Actions with icons set via setIcon are allowed.
Defined in
navigateAction
• Optional
navigateAction: Action
<ActionType
>
Sets the Action to allow users to request navigation using the currently selected route. This should not be null if the template is not in a loading state (see #setIsLoading}), and the Action's title must be set. Spans are not supported in the navigate action and will be ignored.
Defined in
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)
title
• Optional
title: string
Title for the map
Defined in
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)
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)