@thevillages/capacitor-arcmap
v1.0.22
Published
Capacitor plugin for ARCGIS maps.
Downloads
421
Readme
Capacitor Plugin for ArcGIS Navigation
A Capacitor plugin for integrating ArcGIS navigation into Ionic apps, designed for The Villages App. This plugin provides advanced navigation features with modern UI components, seamless audio integration, and enhanced user interaction.
Features
Updated Modern UI
- Larger views and UI components.
- Interactive animated UI indicating feature usage.
- Corporate identity colors and icons.
New Features
- Audio On/Off Button: Enable or disable navigation audio.
- Navigation Audio: Blends seamlessly with user music players.
- Reroute Button: Improved automatic handling with a manual reroute option.
- Show Route Button: Zoom out to view the entire route.
- Speedometer: Toggle between units (e.g., mph, km/h).
Enhanced Navigation Experience
- Help Page: Comprehensive feature overview for users.
- Enhanced Direction List:
- Larger list with intuitive symbols.
- See the next/upcoming navigation turn.
- Route Information Viewer:
- Real-time updates for estimated arrival time, distance to go, and time remaining.
- Touch Interaction:
- Tap the screen to hide UI components.
- Access destination details by tapping the title bar.
Additional Improvements
- Improved messaging for system errors.
- Start button displays route type image (Car/Golf Cart).
- Code restructuring for enhanced stability and maintainability.
Installation
Install the plugin via npm:
npm install capacitor-plugin-arcmap
npx cap sync
## updated:
* Upgraded to capacitor version 5.
* Upgraded gradle version to 8.0.2
* Android java jdk version 17
* Drop references to jcenter() repository
## For IOS need to add Privacy-location properties to info.plist
<key>NSPhotoLibraryAddUsageDescription</key>
<string>In the event we need to save crash detection images</string>
<key>NSLocationWhenInUseUsageDescription</key>
<string>Your location is required for the map</string>
<key>NSLocationAlwaysAndWhenInUseUsageDescription</key>
<string>Your current location is displayed</string>
## Note add repostitory to build.gradle module: android.app, add to android section packagingOptions { exclude 'META-INF/DEPENDENCIES' }
// Add to repositories {
maven {
url 'https://esri.jfrog.io/artifactory/arcgis'
}
## Example of how to call plugin
```Call plugin example
import { MapNav, MapParameters } from 'capacitor-plugin-arcmap';
const mapParms: MapParameters = {
stops: [{ name: 'first stop mvp brownwood ', gisLong: -82.02373937, gisLat: 28.84617393 },
{ name: '2886 Petoskey PL.', gisLong: -82.027396242, gisLat: 28.848607530 },
{ name: '5748 BARRAW TERRACE', gisLong: -81.969576550, gisLat: 28.793533750 }],
travelType: 0 // car 0, golf cart 1
};
MapNav.startNavigation(mapParms)
.then(result => {
console.log('Return from plugin with: ' + result.completed);
});
}npm install capacitor-plugin-arcmap
npx cap syncAPI
echo(...)
echo(options: { value: string; }) => Promise<{ value: string; }>| Param | Type |
| ------------- | ------------------------------- |
| options | { value: string; } |
Returns: Promise<{ value: string; }>
startNavigation(...)
startNavigation(options: MapParameters) => Promise<NavigationResult>| Param | Type |
| ------------- | ------------------------------------------------------- |
| options | MapParameters |
Returns: Promise<NavigationResult>
Interfaces
NavigationResult
| Prop | Type |
| --------------- | -------------------- |
| completed | boolean |
MapParameters
| Prop | Type |
| ---------------- | ------------------- |
| stops | Stop[] |
| travelType | number |
Stop
| Prop | Type |
| ------------- | ------------------- |
| name | string |
| gisLong | number |
| gisLat | number |
