@javascriptcommon/react-native-carplay 2.3.11 → 2.4.1-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/android/build.gradle +110 -0
- package/android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/android/gradle/wrapper/gradle-wrapper.properties +5 -0
- package/android/gradle.properties +20 -0
- package/android/gradlew +234 -0
- package/android/gradlew.bat +89 -0
- package/android/src/main/AndroidManifest.xml +30 -0
- package/android/src/main/AndroidManifestNew.xml +30 -0
- package/android/src/main/java/org/birkir/carplay/CarPlayModule.kt +321 -0
- package/android/src/main/java/org/birkir/carplay/CarPlayPackage.kt +18 -0
- package/android/src/main/java/org/birkir/carplay/CarPlayService.kt +35 -0
- package/android/src/main/java/org/birkir/carplay/CarPlaySession.kt +126 -0
- package/android/src/main/java/org/birkir/carplay/parser/Ext.kt +11 -0
- package/android/src/main/java/org/birkir/carplay/parser/Parser.kt +18 -0
- package/android/src/main/java/org/birkir/carplay/parser/RCTGridTemplate.kt +28 -0
- package/android/src/main/java/org/birkir/carplay/parser/RCTListTemplate.kt +64 -0
- package/android/src/main/java/org/birkir/carplay/parser/RCTMapTemplate.kt +128 -0
- package/android/src/main/java/org/birkir/carplay/parser/RCTMessageTemplate.kt +28 -0
- package/android/src/main/java/org/birkir/carplay/parser/RCTPaneTemplate.kt +24 -0
- package/android/src/main/java/org/birkir/carplay/parser/RCTSearchTemplate.kt +41 -0
- package/android/src/main/java/org/birkir/carplay/parser/RCTTabTemplate.kt +157 -0
- package/android/src/main/java/org/birkir/carplay/parser/RCTTemplate.kt +419 -0
- package/android/src/main/java/org/birkir/carplay/parser/TemplateParser.kt +35 -0
- package/android/src/main/java/org/birkir/carplay/screens/CarScreen.kt +76 -0
- package/android/src/main/java/org/birkir/carplay/screens/CarScreenContext.kt +10 -0
- package/android/src/main/java/org/birkir/carplay/utils/EventEmitter.kt +167 -0
- package/android/src/main/java/org/birkir/carplay/utils/VirtualRenderer.kt +75 -0
- package/ios/RCTConvert+RNCarPlay.h +7 -8
- package/ios/RCTConvert+RNCarPlay.m +3 -2
- package/ios/RNCarPlay.h +11 -14
- package/ios/RNCarPlay.m +749 -945
- package/ios/RNCarPlayViewController.h +10 -0
- package/ios/RNCarPlayViewController.m +50 -0
- package/lib/CarPlay.d.ts +183 -0
- package/lib/CarPlay.d.ts.map +1 -0
- package/lib/index.d.ts +44 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/interfaces/Action.d.ts +13 -0
- package/lib/interfaces/Action.d.ts.map +1 -0
- package/lib/interfaces/AlertAction.d.ts +6 -0
- package/lib/interfaces/AlertAction.d.ts.map +1 -0
- package/lib/interfaces/BarButton.d.ts +39 -0
- package/lib/interfaces/BarButton.d.ts.map +1 -0
- package/lib/interfaces/CarColor.d.ts +2 -0
- package/lib/interfaces/CarColor.d.ts.map +1 -0
- package/lib/interfaces/GridButton.d.ts +24 -0
- package/lib/interfaces/GridButton.d.ts.map +1 -0
- package/lib/interfaces/Header.d.ts +15 -0
- package/lib/interfaces/Header.d.ts.map +1 -0
- package/lib/interfaces/ListItem.d.ts +90 -0
- package/lib/interfaces/ListItem.d.ts.map +1 -0
- package/lib/interfaces/ListItemUpdate.d.ts +15 -0
- package/lib/interfaces/ListItemUpdate.d.ts.map +1 -0
- package/lib/interfaces/ListSection.d.ts +21 -0
- package/lib/interfaces/ListSection.d.ts.map +1 -0
- package/lib/interfaces/Maneuver.d.ts +31 -0
- package/lib/interfaces/Maneuver.d.ts.map +1 -0
- package/lib/interfaces/MapButton.d.ts +27 -0
- package/lib/interfaces/MapButton.d.ts.map +1 -0
- package/lib/interfaces/NavigationAlert.d.ts +44 -0
- package/lib/interfaces/NavigationAlert.d.ts.map +1 -0
- package/lib/interfaces/NavigationInfo.d.ts +17 -0
- package/lib/interfaces/NavigationInfo.d.ts.map +1 -0
- package/lib/interfaces/NavigationStep.d.ts +17 -0
- package/lib/interfaces/NavigationStep.d.ts.map +1 -0
- package/lib/interfaces/Pane.d.ts +29 -0
- package/lib/interfaces/Pane.d.ts.map +1 -0
- package/lib/interfaces/PauseReason.d.ts +8 -0
- package/lib/interfaces/PauseReason.d.ts.map +1 -0
- package/lib/interfaces/Place.d.ts +11 -0
- package/lib/interfaces/Place.d.ts.map +1 -0
- package/lib/interfaces/TextConfiguration.d.ts +6 -0
- package/lib/interfaces/TextConfiguration.d.ts.map +1 -0
- package/lib/interfaces/TimeRemainingColor.d.ts +2 -0
- package/lib/interfaces/TimeRemainingColor.d.ts.map +1 -0
- package/lib/interfaces/TravelEstimates.d.ts +37 -0
- package/lib/interfaces/TravelEstimates.d.ts.map +1 -0
- package/lib/interfaces/VoiceControlState.d.ts +8 -0
- package/lib/interfaces/VoiceControlState.d.ts.map +1 -0
- package/lib/navigation/NavigationSession.d.ts +18 -0
- package/lib/navigation/NavigationSession.d.ts.map +1 -0
- package/lib/navigation/Trip.d.ts +22 -0
- package/lib/navigation/Trip.d.ts.map +1 -0
- package/lib/templates/ActionSheetTemplate.d.ts +18 -0
- package/lib/templates/ActionSheetTemplate.d.ts.map +1 -0
- package/lib/templates/AlertTemplate.d.ts +17 -0
- package/lib/templates/AlertTemplate.d.ts.map +1 -0
- package/lib/templates/ContactTemplate.d.ts +36 -0
- package/lib/templates/ContactTemplate.d.ts.map +1 -0
- package/lib/templates/GridTemplate.d.ts +38 -0
- package/lib/templates/GridTemplate.d.ts.map +1 -0
- package/lib/templates/InformationTemplate.d.ts +28 -0
- package/lib/templates/InformationTemplate.d.ts.map +1 -0
- package/lib/templates/ListTemplate.d.ts +127 -0
- package/lib/templates/ListTemplate.d.ts.map +1 -0
- package/lib/templates/ListTemplate.js +24 -16
- package/lib/templates/MapTemplate.d.ts +171 -0
- package/lib/templates/MapTemplate.d.ts.map +1 -0
- package/lib/templates/NowPlayingTemplate.d.ts +31 -0
- package/lib/templates/NowPlayingTemplate.d.ts.map +1 -0
- package/lib/templates/PointOfInterestTemplate.d.ts +33 -0
- package/lib/templates/PointOfInterestTemplate.d.ts.map +1 -0
- package/lib/templates/SearchTemplate.d.ts +32 -0
- package/lib/templates/SearchTemplate.d.ts.map +1 -0
- package/lib/templates/SearchTemplate.js +2 -2
- package/lib/templates/TabBarTemplate.d.ts +27 -0
- package/lib/templates/TabBarTemplate.d.ts.map +1 -0
- package/lib/templates/Template.d.ts +82 -0
- package/lib/templates/Template.d.ts.map +1 -0
- package/lib/templates/VoiceControlTemplate.d.ts +18 -0
- package/lib/templates/VoiceControlTemplate.d.ts.map +1 -0
- package/lib/templates/android/AndroidNavigationBaseTemplate.d.ts +19 -0
- package/lib/templates/android/AndroidNavigationBaseTemplate.d.ts.map +1 -0
- package/lib/templates/android/MessageTemplate.d.ts +16 -0
- package/lib/templates/android/MessageTemplate.d.ts.map +1 -0
- package/lib/templates/android/NavigationTemplate.d.ts +44 -0
- package/lib/templates/android/NavigationTemplate.d.ts.map +1 -0
- package/lib/templates/android/PaneTemplate.d.ts +13 -0
- package/lib/templates/android/PaneTemplate.d.ts.map +1 -0
- package/lib/templates/android/PlaceListMapTemplate.d.ts +58 -0
- package/lib/templates/android/PlaceListMapTemplate.d.ts.map +1 -0
- package/lib/templates/android/PlaceListNavigationTemplate.d.ts +51 -0
- package/lib/templates/android/PlaceListNavigationTemplate.d.ts.map +1 -0
- package/lib/templates/android/RoutePreviewNavigationTemplate.d.ts +60 -0
- package/lib/templates/android/RoutePreviewNavigationTemplate.d.ts.map +1 -0
- package/package.json +3 -3
- package/react-native-carplay.podspec +3 -3
- package/src/CarPlay.ts +28 -16
- package/src/interfaces/ListItem.ts +14 -8
- package/src/interfaces/ListSection.ts +1 -1
- package/src/templates/ListTemplate.ts +64 -44
- package/src/templates/NowPlayingTemplate.ts +10 -3
- package/src/templates/SearchTemplate.ts +2 -2
- package/README.md +0 -633
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { ImageSourcePropType } from 'react-native';
|
|
2
|
+
export declare enum NavigationAlertActionStyle {
|
|
3
|
+
Default = 0,
|
|
4
|
+
Cancel = 1,
|
|
5
|
+
Destructive = 2
|
|
6
|
+
}
|
|
7
|
+
export interface NavigationAlertAction {
|
|
8
|
+
/**
|
|
9
|
+
* The action button's title.
|
|
10
|
+
*/
|
|
11
|
+
title: string;
|
|
12
|
+
/**
|
|
13
|
+
* The display style for the action button.
|
|
14
|
+
*/
|
|
15
|
+
style?: NavigationAlertActionStyle;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* An alert panel that displays map or navigation related information to the user.
|
|
19
|
+
*/
|
|
20
|
+
export interface NavigationAlert {
|
|
21
|
+
lightImage?: ImageSourcePropType;
|
|
22
|
+
darkImage?: ImageSourcePropType;
|
|
23
|
+
/**
|
|
24
|
+
* An array of title strings.
|
|
25
|
+
*/
|
|
26
|
+
titleVariants: string[];
|
|
27
|
+
/**
|
|
28
|
+
* An array of subtitle strings.
|
|
29
|
+
*/
|
|
30
|
+
subtitleVariants?: string[];
|
|
31
|
+
/**
|
|
32
|
+
* The primary action, and button, for the navigation alert.
|
|
33
|
+
*/
|
|
34
|
+
primaryAction: NavigationAlertAction;
|
|
35
|
+
/**
|
|
36
|
+
* An optional, secondary action (and button) for the navigation alert.
|
|
37
|
+
*/
|
|
38
|
+
secondaryAction?: NavigationAlertAction;
|
|
39
|
+
/**
|
|
40
|
+
* The amount of time, in seconds, that the alert is visible.
|
|
41
|
+
*/
|
|
42
|
+
duration: number;
|
|
43
|
+
}
|
|
44
|
+
//# sourceMappingURL=NavigationAlert.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NavigationAlert.d.ts","sourceRoot":"","sources":["../../src/interfaces/NavigationAlert.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAEnD,oBAAY,0BAA0B;IACpC,OAAO,IAAI;IACX,MAAM,IAAI;IACV,WAAW,IAAI;CAChB;AAED,MAAM,WAAW,qBAAqB;IACpC;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,KAAK,CAAC,EAAE,0BAA0B,CAAC;CACpC;AAED;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,UAAU,CAAC,EAAE,mBAAmB,CAAC;IACjC,SAAS,CAAC,EAAE,mBAAmB,CAAC;IAChC;;OAEG;IACH,aAAa,EAAE,MAAM,EAAE,CAAC;IACxB;;OAEG;IACH,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC5B;;OAEG;IACH,aAAa,EAAE,qBAAqB,CAAC;IACrC;;OAEG;IACH,eAAe,CAAC,EAAE,qBAAqB,CAAC;IACxC;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;CAClB"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ImageResolvedAssetSource } from 'react-native';
|
|
2
|
+
import { NavigationStep } from './NavigationStep';
|
|
3
|
+
export type NavigationRoutingInfo = {
|
|
4
|
+
type: 'routingInfo';
|
|
5
|
+
loading?: boolean;
|
|
6
|
+
junctionImage?: ImageResolvedAssetSource;
|
|
7
|
+
nextStep?: NavigationStep;
|
|
8
|
+
distance: number;
|
|
9
|
+
distanceUnits: number;
|
|
10
|
+
};
|
|
11
|
+
export type NavigationMessageInfo = {
|
|
12
|
+
type: 'messageInfo';
|
|
13
|
+
title: string;
|
|
14
|
+
icon?: ImageResolvedAssetSource;
|
|
15
|
+
};
|
|
16
|
+
export type NavigationInfo = NavigationRoutingInfo | NavigationMessageInfo;
|
|
17
|
+
//# sourceMappingURL=NavigationInfo.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NavigationInfo.d.ts","sourceRoot":"","sources":["../../src/interfaces/NavigationInfo.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,MAAM,cAAc,CAAC;AACxD,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAElD,MAAM,MAAM,qBAAqB,GAAG;IAClC,IAAI,EAAE,aAAa,CAAC;IACpB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,aAAa,CAAC,EAAE,wBAAwB,CAAC;IACzC,QAAQ,CAAC,EAAE,cAAc,CAAC;IAC1B,QAAQ,EAAE,MAAM,CAAC;IACjB,aAAa,EAAE,MAAM,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG;IAClC,IAAI,EAAE,aAAa,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,wBAAwB,CAAC;CACjC,CAAC;AAEF,MAAM,MAAM,cAAc,GAAG,qBAAqB,GAAG,qBAAqB,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ImageResolvedAssetSource } from 'react-native';
|
|
2
|
+
export type NavigationStep = {
|
|
3
|
+
lane: {
|
|
4
|
+
shape: number;
|
|
5
|
+
recommended: boolean;
|
|
6
|
+
};
|
|
7
|
+
cue?: string;
|
|
8
|
+
lanesImage: ImageResolvedAssetSource;
|
|
9
|
+
maneuver?: {
|
|
10
|
+
type: number;
|
|
11
|
+
icon: ImageResolvedAssetSource;
|
|
12
|
+
roundaboutExitAngle: number;
|
|
13
|
+
roundaboutExitNumber: number;
|
|
14
|
+
};
|
|
15
|
+
road?: string;
|
|
16
|
+
};
|
|
17
|
+
//# sourceMappingURL=NavigationStep.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NavigationStep.d.ts","sourceRoot":"","sources":["../../src/interfaces/NavigationStep.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,MAAM,cAAc,CAAC;AAExD,MAAM,MAAM,cAAc,GAAG;IAC3B,IAAI,EAAE;QACJ,KAAK,EAAE,MAAM,CAAC;QACd,WAAW,EAAE,OAAO,CAAC;KACtB,CAAC;IACF,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,wBAAwB,CAAC;IACrC,QAAQ,CAAC,EAAE;QACT,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,EAAE,wBAAwB,CAAC;QAC/B,mBAAmB,EAAE,MAAM,CAAC;QAC5B,oBAAoB,EAAE,MAAM,CAAC;KAC9B,CAAC;IACF,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { ImageSourcePropType } from 'react-native';
|
|
2
|
+
import { Action } from './Action';
|
|
3
|
+
import { ListItem } from './ListItem';
|
|
4
|
+
/**
|
|
5
|
+
* Represents a list of rows used for displaying informational content and a set of Actions that users can perform based on such content.
|
|
6
|
+
* @namespace Android
|
|
7
|
+
*/
|
|
8
|
+
export interface Pane {
|
|
9
|
+
/**
|
|
10
|
+
* Sets whether the Pane is in a loading state.
|
|
11
|
+
* If set to true, the UI will display a loading indicator where the list content would be otherwise. The caller is expected to call invalidate and send the new template content to the host once the data is ready. If set to false, the UI shows the actual row contents.
|
|
12
|
+
*/
|
|
13
|
+
loading?: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* Sets an CarIcon to display alongside the rows in the pane.
|
|
16
|
+
* Image Sizing Guidance To minimize scaling artifacts across a wide range of car screens, apps should provide images targeting a 480 x 480 dp bounding box. If the image exceeds this maximum size in either one of the dimensions, it will be scaled down to be centered inside the bounding box while preserving its aspect ratio.
|
|
17
|
+
*/
|
|
18
|
+
image?: ImageSourcePropType;
|
|
19
|
+
/**
|
|
20
|
+
* Actions to display alongside the rows in the pane.
|
|
21
|
+
* By default, no actions are displayed.
|
|
22
|
+
*/
|
|
23
|
+
actions?: Action[];
|
|
24
|
+
/**
|
|
25
|
+
* Rows to display in the list.
|
|
26
|
+
*/
|
|
27
|
+
items?: ListItem[];
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=Pane.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Pane.d.ts","sourceRoot":"","sources":["../../src/interfaces/Pane.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC;;;GAGG;AACH,MAAM,WAAW,IAAI;IACnB;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;OAGG;IACH,KAAK,CAAC,EAAE,mBAAmB,CAAC;IAC5B;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB;;OAEG;IACH,KAAK,CAAC,EAAE,QAAQ,EAAE,CAAC;CACpB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PauseReason.d.ts","sourceRoot":"","sources":["../../src/interfaces/PauseReason.ts"],"names":[],"mappings":"AAAA,oBAAY,WAAW;IACrB,OAAO,IAAI;IACX,OAAO,IAAI;IACX,QAAQ,IAAI;IACZ,SAAS,IAAI;IACb,cAAc,IAAI;CACnB"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ImageSourcePropType } from 'react-native';
|
|
2
|
+
/**
|
|
3
|
+
* A place to be displayed on the map.
|
|
4
|
+
* @namespace Android
|
|
5
|
+
*/
|
|
6
|
+
export interface Place {
|
|
7
|
+
latitude: number;
|
|
8
|
+
longitude: number;
|
|
9
|
+
icon: ImageSourcePropType;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=Place.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Place.d.ts","sourceRoot":"","sources":["../../src/interfaces/Place.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAEnD;;;GAGG;AACH,MAAM,WAAW,KAAK;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAElB,IAAI,EAAE,mBAAmB,CAAC;CAC3B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TextConfiguration.d.ts","sourceRoot":"","sources":["../../src/interfaces/TextConfiguration.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,iBAAiB;IAChC,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,2BAA2B,CAAC,EAAE,MAAM,CAAC;IACrC,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TimeRemainingColor.d.ts","sourceRoot":"","sources":["../../src/interfaces/TimeRemainingColor.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,kBAAkB,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { CarColor } from './CarColor';
|
|
2
|
+
export type DistanceUnits = 'meters' | 'miles' | 'kilometers' | 'yards' | 'feet';
|
|
3
|
+
export interface TravelEstimates {
|
|
4
|
+
/**
|
|
5
|
+
* Distance remaining
|
|
6
|
+
*/
|
|
7
|
+
distanceRemaining: number;
|
|
8
|
+
/**
|
|
9
|
+
* Time remaining in seconds
|
|
10
|
+
*/
|
|
11
|
+
timeRemaining: number;
|
|
12
|
+
/**
|
|
13
|
+
* unit of measurement for the
|
|
14
|
+
* distance, defaults to kilometer
|
|
15
|
+
* @namespace iOS
|
|
16
|
+
*/
|
|
17
|
+
distanceUnits?: DistanceUnits;
|
|
18
|
+
/**
|
|
19
|
+
* Color of the distance remaining
|
|
20
|
+
* @namespace Android
|
|
21
|
+
*/
|
|
22
|
+
distanceRemainingColor?: CarColor;
|
|
23
|
+
/**
|
|
24
|
+
* Color of the time remaining
|
|
25
|
+
* @namespace Android
|
|
26
|
+
*/
|
|
27
|
+
timeRemainingColor?: CarColor;
|
|
28
|
+
/**
|
|
29
|
+
* Destination time
|
|
30
|
+
* @namespace Android
|
|
31
|
+
*/
|
|
32
|
+
destinationTime?: {
|
|
33
|
+
timeSinceEpochMillis: number;
|
|
34
|
+
id: string;
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
//# sourceMappingURL=TravelEstimates.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TravelEstimates.d.ts","sourceRoot":"","sources":["../../src/interfaces/TravelEstimates.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,MAAM,MAAM,aAAa,GAAG,QAAQ,GAAG,OAAO,GAAG,YAAY,GAAG,OAAO,GAAG,MAAM,CAAC;AAEjF,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,iBAAiB,EAAE,MAAM,CAAC;IAC1B;;OAEG;IACH,aAAa,EAAE,MAAM,CAAC;IACtB;;;;OAIG;IACH,aAAa,CAAC,EAAE,aAAa,CAAC;IAE9B;;;OAGG;IACH,sBAAsB,CAAC,EAAE,QAAQ,CAAC;IAClC;;;OAGG;IACH,kBAAkB,CAAC,EAAE,QAAQ,CAAC;IAC9B;;;OAGG;IACH,eAAe,CAAC,EAAE;QAChB,oBAAoB,EAAE,MAAM,CAAC;QAC7B,EAAE,EAAE,MAAM,CAAC;KACZ,CAAC;CACH"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"VoiceControlState.d.ts","sourceRoot":"","sources":["../../src/interfaces/VoiceControlState.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAEnD,MAAM,WAAW,iBAAiB;IAChC,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,mBAAmB,CAAC;IAC5B,OAAO,EAAE,OAAO,CAAC;IACjB,aAAa,EAAE,MAAM,EAAE,CAAC;CACzB"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Maneuver } from '../interfaces/Maneuver';
|
|
2
|
+
import { PauseReason } from '../interfaces/PauseReason';
|
|
3
|
+
import { TravelEstimates } from '../interfaces/TravelEstimates';
|
|
4
|
+
import { MapTemplate } from '../templates/MapTemplate';
|
|
5
|
+
import { Trip } from './Trip';
|
|
6
|
+
export declare class NavigationSession {
|
|
7
|
+
id: string;
|
|
8
|
+
trip: Trip;
|
|
9
|
+
mapTemplate: MapTemplate;
|
|
10
|
+
maneuvers: Maneuver[];
|
|
11
|
+
constructor(id: string, trip: Trip, mapTemplate: MapTemplate);
|
|
12
|
+
updateManeuvers(maneuvers: Maneuver[]): void;
|
|
13
|
+
updateTravelEstimates(maneuverIndex: number, travelEstimates: TravelEstimates): void;
|
|
14
|
+
cancel(): void;
|
|
15
|
+
finish(): void;
|
|
16
|
+
pause(reason: PauseReason, description?: string): void;
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=NavigationSession.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NavigationSession.d.ts","sourceRoot":"","sources":["../../src/navigation/NavigationSession.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AACxD,OAAO,EAAE,eAAe,EAAE,MAAM,+BAA+B,CAAC;AAChE,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAG9B,qBAAa,iBAAiB;IAGT,EAAE,EAAE,MAAM;IAAS,IAAI,EAAE,IAAI;IAAS,WAAW,EAAE,WAAW;IAF1E,SAAS,EAAE,QAAQ,EAAE,CAAM;gBAEf,EAAE,EAAE,MAAM,EAAS,IAAI,EAAE,IAAI,EAAS,WAAW,EAAE,WAAW;IAE1E,eAAe,CAAC,SAAS,EAAE,QAAQ,EAAE;IAyBrC,qBAAqB,CAAC,aAAa,EAAE,MAAM,EAAE,eAAe,EAAE,eAAe;IAO7E,MAAM;IAIN,MAAM;IAIN,KAAK,CAAC,MAAM,EAAE,WAAW,EAAE,WAAW,CAAC,EAAE,MAAM;CAGvD"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export interface RouteChoice {
|
|
2
|
+
additionalInformationVariants: string[];
|
|
3
|
+
selectionSummaryVariants: string[];
|
|
4
|
+
summaryVariants: string[];
|
|
5
|
+
}
|
|
6
|
+
export interface TripPoint {
|
|
7
|
+
latitude: number;
|
|
8
|
+
longitude: number;
|
|
9
|
+
name: string;
|
|
10
|
+
}
|
|
11
|
+
export interface TripConfig {
|
|
12
|
+
id?: string;
|
|
13
|
+
origin: TripPoint;
|
|
14
|
+
destination: TripPoint;
|
|
15
|
+
routeChoices: RouteChoice[];
|
|
16
|
+
}
|
|
17
|
+
export declare class Trip {
|
|
18
|
+
config: TripConfig;
|
|
19
|
+
id: string;
|
|
20
|
+
constructor(config: TripConfig);
|
|
21
|
+
}
|
|
22
|
+
//# sourceMappingURL=Trip.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Trip.d.ts","sourceRoot":"","sources":["../../src/navigation/Trip.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,WAAW;IAC1B,6BAA6B,EAAE,MAAM,EAAE,CAAC;IACxC,wBAAwB,EAAE,MAAM,EAAE,CAAC;IACnC,eAAe,EAAE,MAAM,EAAE,CAAC;CAC3B;AAED,MAAM,WAAW,SAAS;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,WAAW,UAAU;IACzB,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,SAAS,CAAC;IAClB,WAAW,EAAE,SAAS,CAAC;IACvB,YAAY,EAAE,WAAW,EAAE,CAAC;CAC7B;AAED,qBAAa,IAAI;IAGI,MAAM,EAAE,UAAU;IAF9B,EAAE,EAAG,MAAM,CAAC;gBAEA,MAAM,EAAE,UAAU;CAWtC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { AlertAction } from '../interfaces/AlertAction';
|
|
2
|
+
import { Template, TemplateConfig } from './Template';
|
|
3
|
+
export interface ActionSheetTemplateConfig extends TemplateConfig {
|
|
4
|
+
title: string;
|
|
5
|
+
message?: string;
|
|
6
|
+
actions: AlertAction[];
|
|
7
|
+
onActionButtonPressed?(e: {
|
|
8
|
+
id: string;
|
|
9
|
+
templateId: string;
|
|
10
|
+
}): void;
|
|
11
|
+
}
|
|
12
|
+
export declare class ActionSheetTemplate extends Template<ActionSheetTemplateConfig> {
|
|
13
|
+
get type(): string;
|
|
14
|
+
get eventMap(): {
|
|
15
|
+
actionButtonPressed: string;
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=ActionSheetTemplate.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ActionSheetTemplate.d.ts","sourceRoot":"","sources":["../../src/templates/ActionSheetTemplate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AACxD,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAEtD,MAAM,WAAW,yBAA0B,SAAQ,cAAc;IAC/D,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,WAAW,EAAE,CAAC;IACvB,qBAAqB,CAAC,CAAC,CAAC,EAAE;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;CACrE;AAED,qBAAa,mBAAoB,SAAQ,QAAQ,CAAC,yBAAyB,CAAC;IAC1E,IAAW,IAAI,IAAI,MAAM,CAExB;IAED,IAAI,QAAQ;;MAIX;CACF"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { AlertAction } from '../interfaces/AlertAction';
|
|
2
|
+
import { Template, TemplateConfig } from './Template';
|
|
3
|
+
export interface AlertTemplateConfig extends TemplateConfig {
|
|
4
|
+
titleVariants: string[];
|
|
5
|
+
actions?: AlertAction[];
|
|
6
|
+
onActionButtonPressed?(e: {
|
|
7
|
+
id: string;
|
|
8
|
+
templateId: string;
|
|
9
|
+
}): void;
|
|
10
|
+
}
|
|
11
|
+
export declare class AlertTemplate extends Template<AlertTemplateConfig> {
|
|
12
|
+
get type(): string;
|
|
13
|
+
get eventMap(): {
|
|
14
|
+
actionButtonPressed: string;
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=AlertTemplate.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AlertTemplate.d.ts","sourceRoot":"","sources":["../../src/templates/AlertTemplate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AACxD,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAEtD,MAAM,WAAW,mBAAoB,SAAQ,cAAc;IACzD,aAAa,EAAE,MAAM,EAAE,CAAC;IACxB,OAAO,CAAC,EAAE,WAAW,EAAE,CAAC;IACxB,qBAAqB,CAAC,CAAC,CAAC,EAAE;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;CACrE;AAED,qBAAa,aAAc,SAAQ,QAAQ,CAAC,mBAAmB,CAAC;IAC9D,IAAW,IAAI,IAAI,MAAM,CAExB;IAED,IAAI,QAAQ;;MAIX;CACF"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { ImageSourcePropType } from 'react-native';
|
|
2
|
+
import { Template, TemplateConfig } from './Template';
|
|
3
|
+
export interface ContactButtonEvent {
|
|
4
|
+
id: string;
|
|
5
|
+
templateId: string;
|
|
6
|
+
}
|
|
7
|
+
export interface ContactActionBase {
|
|
8
|
+
id: string;
|
|
9
|
+
type: 'call' | 'directions' | 'message';
|
|
10
|
+
disabled?: boolean;
|
|
11
|
+
title?: string;
|
|
12
|
+
}
|
|
13
|
+
export interface ContactActionMessage extends ContactActionBase {
|
|
14
|
+
type: 'message';
|
|
15
|
+
phoneOrEmail: string;
|
|
16
|
+
}
|
|
17
|
+
export type ContactAction = ContactActionBase | ContactActionMessage;
|
|
18
|
+
export interface ContactTemplateConfig extends TemplateConfig {
|
|
19
|
+
name: string;
|
|
20
|
+
image: ImageSourcePropType;
|
|
21
|
+
subtitle?: string;
|
|
22
|
+
informativeText?: string;
|
|
23
|
+
actions?: ContactAction[];
|
|
24
|
+
/**
|
|
25
|
+
* Fired when bar button is pressed
|
|
26
|
+
* @param e Event
|
|
27
|
+
*/
|
|
28
|
+
onButtonPressed?(e: ContactButtonEvent): void;
|
|
29
|
+
}
|
|
30
|
+
export declare class ContactTemplate extends Template<ContactTemplateConfig> {
|
|
31
|
+
get type(): string;
|
|
32
|
+
get eventMap(): {
|
|
33
|
+
buttonPressed: string;
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
//# sourceMappingURL=ContactTemplate.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ContactTemplate.d.ts","sourceRoot":"","sources":["../../src/templates/ContactTemplate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAEtD,MAAM,WAAW,kBAAkB;IACjC,EAAE,EAAE,MAAM,CAAC;IACX,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,iBAAiB;IAChC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,GAAG,YAAY,GAAG,SAAS,CAAC;IACxC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,oBAAqB,SAAQ,iBAAiB;IAC7D,IAAI,EAAE,SAAS,CAAC;IAChB,YAAY,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,MAAM,aAAa,GAAG,iBAAiB,GAAG,oBAAoB,CAAC;AAErE,MAAM,WAAW,qBAAsB,SAAQ,cAAc;IAC3D,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,mBAAmB,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,OAAO,CAAC,EAAE,aAAa,EAAE,CAAC;IAC1B;;;OAGG;IACH,eAAe,CAAC,CAAC,CAAC,EAAE,kBAAkB,GAAG,IAAI,CAAC;CAC/C;AAED,qBAAa,eAAgB,SAAQ,QAAQ,CAAC,qBAAqB,CAAC;IAClE,IAAW,IAAI,IAAI,MAAM,CAExB;IACD,IAAI,QAAQ;;MAIX;CACF"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { GridButton } from '../interfaces/GridButton';
|
|
2
|
+
import { BaseEvent, Template, TemplateConfig } from './Template';
|
|
3
|
+
export interface ButtonPressedEvent extends BaseEvent {
|
|
4
|
+
/**
|
|
5
|
+
* Button ID
|
|
6
|
+
*/
|
|
7
|
+
id: string;
|
|
8
|
+
/**
|
|
9
|
+
* Button Index
|
|
10
|
+
*/
|
|
11
|
+
index: number;
|
|
12
|
+
/**
|
|
13
|
+
* template ID
|
|
14
|
+
*/
|
|
15
|
+
templateId: string;
|
|
16
|
+
}
|
|
17
|
+
export interface GridTemplateConfig extends TemplateConfig {
|
|
18
|
+
/**
|
|
19
|
+
* The title displayed in the navigation bar while the list template is visible.
|
|
20
|
+
*/
|
|
21
|
+
title?: string;
|
|
22
|
+
/**
|
|
23
|
+
* The array of grid buttons displayed on the template.
|
|
24
|
+
*/
|
|
25
|
+
buttons: GridButton[];
|
|
26
|
+
/**
|
|
27
|
+
* Fired when a button is pressed
|
|
28
|
+
*/
|
|
29
|
+
onButtonPressed?(e: ButtonPressedEvent): void;
|
|
30
|
+
}
|
|
31
|
+
export declare class GridTemplate extends Template<GridTemplateConfig> {
|
|
32
|
+
get type(): string;
|
|
33
|
+
get eventMap(): {
|
|
34
|
+
gridButtonPressed: string;
|
|
35
|
+
backButtonPressed: string;
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
//# sourceMappingURL=GridTemplate.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"GridTemplate.d.ts","sourceRoot":"","sources":["../../src/templates/GridTemplate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AACtD,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAEjE,MAAM,WAAW,kBAAmB,SAAQ,SAAS;IACnD;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IACX;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,kBAAmB,SAAQ,cAAc;IACxD;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,OAAO,EAAE,UAAU,EAAE,CAAC;IACtB;;OAEG;IACH,eAAe,CAAC,CAAC,CAAC,EAAE,kBAAkB,GAAG,IAAI,CAAC;CAC/C;AAED,qBAAa,YAAa,SAAQ,QAAQ,CAAC,kBAAkB,CAAC;IAC5D,IAAW,IAAI,IAAI,MAAM,CAExB;IAED,IAAI,QAAQ;;;MAKX;CACF"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { Template, TemplateConfig } from './Template';
|
|
2
|
+
export interface InformationItem {
|
|
3
|
+
title: string;
|
|
4
|
+
detail: string;
|
|
5
|
+
}
|
|
6
|
+
export interface InformationAction {
|
|
7
|
+
id: string;
|
|
8
|
+
title: string;
|
|
9
|
+
}
|
|
10
|
+
export interface InformationTemplateConfig extends TemplateConfig {
|
|
11
|
+
title: string;
|
|
12
|
+
leading?: boolean;
|
|
13
|
+
items: InformationItem[];
|
|
14
|
+
actions: InformationAction[];
|
|
15
|
+
onActionButtonPressed(e: {
|
|
16
|
+
id: string;
|
|
17
|
+
templateId: string;
|
|
18
|
+
}): void;
|
|
19
|
+
}
|
|
20
|
+
export declare class InformationTemplate extends Template<InformationTemplateConfig> {
|
|
21
|
+
get type(): string;
|
|
22
|
+
get eventMap(): {
|
|
23
|
+
actionButtonPressed: string;
|
|
24
|
+
};
|
|
25
|
+
updateInformationTemplateItems: (items: InformationItem[]) => void;
|
|
26
|
+
updateInformationTemplateActions: (actions: InformationAction[]) => void;
|
|
27
|
+
}
|
|
28
|
+
//# sourceMappingURL=InformationTemplate.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"InformationTemplate.d.ts","sourceRoot":"","sources":["../../src/templates/InformationTemplate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAGtD,MAAM,WAAW,eAAe;IAC9B,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,iBAAiB;IAChC,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,yBAA0B,SAAQ,cAAc;IAC/D,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,KAAK,EAAE,eAAe,EAAE,CAAC;IACzB,OAAO,EAAE,iBAAiB,EAAE,CAAC;IAC7B,qBAAqB,CAAC,CAAC,EAAE;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;CACpE;AAED,qBAAa,mBAAoB,SAAQ,QAAQ,CAAC,yBAAyB,CAAC;IAC1E,IAAW,IAAI,IAAI,MAAM,CAExB;IAED,IAAI,QAAQ;;MAIX;IAEM,8BAA8B,UAAW,eAAe,EAAE,UAG/D;IAEK,gCAAgC,YAAa,iBAAiB,EAAE,UAGrE;CACH"}
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
import { Action } from '../interfaces/Action';
|
|
2
|
+
import { ListItem } from '../interfaces/ListItem';
|
|
3
|
+
import { ListItemUpdate } from '../interfaces/ListItemUpdate';
|
|
4
|
+
import { ListSection } from '../interfaces/ListSection';
|
|
5
|
+
import { Template, TemplateConfig } from './Template';
|
|
6
|
+
export interface ListTemplateConfig extends TemplateConfig {
|
|
7
|
+
/**
|
|
8
|
+
* The title displayed in the navigation bar while the list template is visible.
|
|
9
|
+
*/
|
|
10
|
+
title?: string;
|
|
11
|
+
/**
|
|
12
|
+
* The sections displayed in the list.
|
|
13
|
+
*/
|
|
14
|
+
sections?: ListSection[];
|
|
15
|
+
/**
|
|
16
|
+
* Sets a single ItemList to show in the template.
|
|
17
|
+
* @namespace Android
|
|
18
|
+
*/
|
|
19
|
+
items?: ListItem[];
|
|
20
|
+
/**
|
|
21
|
+
* An optional array of strings, ordered from most to least preferred.
|
|
22
|
+
* The variant strings should be provided as localized, displayable content.
|
|
23
|
+
* The system will select the first variant that fits the available space.
|
|
24
|
+
* If the list template does not contain any items (itemCount == 0), then
|
|
25
|
+
* the template will display an empty view with a title and subtitle to indicate
|
|
26
|
+
* that the template has no list items.
|
|
27
|
+
* If the list template is updated to contain items, the empty view will be automatically
|
|
28
|
+
* removed.
|
|
29
|
+
* @namespace iOS
|
|
30
|
+
*/
|
|
31
|
+
emptyViewTitleVariants?: string[];
|
|
32
|
+
/**
|
|
33
|
+
* An optional array of strings, ordered from most to least preferred.
|
|
34
|
+
* The variant strings should be provided as localized, displayable content.
|
|
35
|
+
* The system will select the first variant that fits the available space.
|
|
36
|
+
* If the list template does not contain any items (itemCount == 0), then
|
|
37
|
+
* the template will display an empty view with a title and subtitle to indicate
|
|
38
|
+
* that the template has no list items.
|
|
39
|
+
* If the list template is updated to contain items, the empty view will be automatically
|
|
40
|
+
* removed.
|
|
41
|
+
* @namespace iOS
|
|
42
|
+
*/
|
|
43
|
+
emptyViewSubtitleVariants?: string[];
|
|
44
|
+
/**
|
|
45
|
+
* Fired when list item is selected.
|
|
46
|
+
* Spinner shows by default.
|
|
47
|
+
* When the returned promise is resolved the spinner will hide.
|
|
48
|
+
* @param item Object with the selected index
|
|
49
|
+
*/
|
|
50
|
+
onItemSelect?(item: {
|
|
51
|
+
templateId: string;
|
|
52
|
+
index: number;
|
|
53
|
+
}): Promise<void>;
|
|
54
|
+
/**
|
|
55
|
+
* Fired when image row item is selected.
|
|
56
|
+
* Spinner shows by default.
|
|
57
|
+
* When the returned promise is resolved the spinner will hide.
|
|
58
|
+
* @param item Object with the selected index
|
|
59
|
+
*/
|
|
60
|
+
onImageRowItemSelect?(item: {
|
|
61
|
+
templateId: string;
|
|
62
|
+
index: number;
|
|
63
|
+
imageIndex: number;
|
|
64
|
+
}): Promise<void>;
|
|
65
|
+
/**
|
|
66
|
+
* Fired when the back button is pressed
|
|
67
|
+
*/
|
|
68
|
+
onBackButtonPressed?(): void;
|
|
69
|
+
/**
|
|
70
|
+
* Option to hide back button
|
|
71
|
+
* @default false
|
|
72
|
+
*/
|
|
73
|
+
backButtonHidden?: boolean;
|
|
74
|
+
/**
|
|
75
|
+
* Assistant Configuration
|
|
76
|
+
* @see https://developer.apple.com/documentation/carplay/cplisttemplate#3762508
|
|
77
|
+
* @namespace iOS
|
|
78
|
+
*/
|
|
79
|
+
assistant?: {
|
|
80
|
+
enabled: boolean;
|
|
81
|
+
position: 'top' | 'bottom';
|
|
82
|
+
visibility: 'off' | 'always' | 'limited';
|
|
83
|
+
action: 'playMedia' | 'startCall';
|
|
84
|
+
};
|
|
85
|
+
/**
|
|
86
|
+
* Sets whether the template is in a loading state.
|
|
87
|
+
* If set to true, the UI will display a loading indicator where the list content would be otherwise. The caller is expected to call invalidate and send the new template content to the host once the data is ready.
|
|
88
|
+
* If set to false, the UI will display the contents of the ItemList instance(s) added via setSingleList or addSectionedList.
|
|
89
|
+
* @namespace Android
|
|
90
|
+
*/
|
|
91
|
+
loading?: boolean;
|
|
92
|
+
/**
|
|
93
|
+
* Sets the Action that will be displayed in the header of the template.
|
|
94
|
+
* @namespace Android
|
|
95
|
+
*/
|
|
96
|
+
headerAction?: Action<'appIcon' | 'back'>;
|
|
97
|
+
/**
|
|
98
|
+
* Sets the ActionStrip for this template or null to not display an .
|
|
99
|
+
* This template allows up to 2 Actions. Of the 2 allowed Actions, one of them can contain a title as set via setTitle. Otherwise, only Actions with icons are allowed.
|
|
100
|
+
*/
|
|
101
|
+
actions?: [Action<'custom'>] | [Action<'custom'>, Action<'custom'>];
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* A hierarchical list of menu items can be displayed on the CarPlay screen using a list template.
|
|
105
|
+
*
|
|
106
|
+
* The List Template allows navigation apps to present a hierarchical list of menu items. It includes a navigation bar and a list view.
|
|
107
|
+
*
|
|
108
|
+
* The navigation bar includes a title, and up to two (2) leading buttons and two (2) trailing buttons. You can customize the appearance of these buttons with icons or text.
|
|
109
|
+
*
|
|
110
|
+
* Each item in the list view may include an icon, title, subtitle, and an optional disclosure indicator indicating the presence of a submenu. The depth of the menu hierarchy may not exceed 5 levels. Note that some cars limit the total number of items that may be shown in a list.
|
|
111
|
+
*/
|
|
112
|
+
export declare class ListTemplate extends Template<ListTemplateConfig> {
|
|
113
|
+
config: ListTemplateConfig;
|
|
114
|
+
get type(): string;
|
|
115
|
+
get eventMap(): {
|
|
116
|
+
backButtonPressed: string;
|
|
117
|
+
};
|
|
118
|
+
constructor(config: ListTemplateConfig);
|
|
119
|
+
updateSections: (sections: ListSection[]) => void;
|
|
120
|
+
updateListTemplateItem: (config: ListItemUpdate) => void;
|
|
121
|
+
getMaximumListItemCount(): Promise<number>;
|
|
122
|
+
getMaximumListSectionCount(): Promise<number>;
|
|
123
|
+
getMaximumListItemImageSize(): Promise<import("../CarPlay").ImageSize>;
|
|
124
|
+
getMaximumNumberOfGridImages(): Promise<number>;
|
|
125
|
+
getMaximumListImageRowItemImageSize(): Promise<import("../CarPlay").ImageSize>;
|
|
126
|
+
}
|
|
127
|
+
//# sourceMappingURL=ListTemplate.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ListTemplate.d.ts","sourceRoot":"","sources":["../../src/templates/ListTemplate.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AACxD,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAEtD,MAAM,WAAW,kBAAmB,SAAQ,cAAc;IACxD;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,QAAQ,CAAC,EAAE,WAAW,EAAE,CAAC;IACzB;;;OAGG;IACH,KAAK,CAAC,EAAE,QAAQ,EAAE,CAAC;IACnB;;;;;;;;;;OAUG;IACH,sBAAsB,CAAC,EAAE,MAAM,EAAE,CAAC;IAClC;;;;;;;;;;OAUG;IACH,yBAAyB,CAAC,EAAE,MAAM,EAAE,CAAC;IACrC;;;;;OAKG;IACH,YAAY,CAAC,CAAC,IAAI,EAAE;QAAE,UAAU,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAE1E;;;;;OAKG;IACH,oBAAoB,CAAC,CAAC,IAAI,EAAE;QAC1B,UAAU,EAAE,MAAM,CAAC;QACnB,KAAK,EAAE,MAAM,CAAC;QACd,UAAU,EAAE,MAAM,CAAC;KACpB,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAElB;;OAEG;IACH,mBAAmB,CAAC,IAAI,IAAI,CAAC;IAE7B;;;OAGG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAE3B;;;;OAIG;IACH,SAAS,CAAC,EAAE;QACV,OAAO,EAAE,OAAO,CAAC;QACjB,QAAQ,EAAE,KAAK,GAAG,QAAQ,CAAC;QAC3B,UAAU,EAAE,KAAK,GAAG,QAAQ,GAAG,SAAS,CAAC;QACzC,MAAM,EAAE,WAAW,GAAG,WAAW,CAAC;KACnC,CAAC;IACF;;;;;OAKG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC,SAAS,GAAG,MAAM,CAAC,CAAC;IAC1C;;;OAGG;IACH,OAAO,CAAC,EAAE,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,GAAG,CAAC,MAAM,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC;CACrE;AAED;;;;;;;;GAQG;AACH,qBAAa,YAAa,SAAQ,QAAQ,CAAC,kBAAkB,CAAC;IAWzC,MAAM,EAAE,kBAAkB;IAV7C,IAAW,IAAI,IAAI,MAAM,CAExB;IAED,IAAI,QAAQ;;MAIX;gBAEkB,MAAM,EAAE,kBAAkB;IA2BtC,cAAc,aAAc,WAAW,EAAE,UAG9C;IAEK,sBAAsB,WAAY,cAAc,UAMrD;IAEK,uBAAuB;IAIvB,0BAA0B;IAI1B,2BAA2B;IAI3B,4BAA4B;IAI5B,mCAAmC;CAG3C"}
|