hypertrack-sdk-react-native 11.0.11 → 12.1.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/README.md +2 -39
- package/android/build.gradle +0 -2
- package/android/gradle.properties +1 -1
- package/hypertrack-sdk-react-native.podspec +1 -1
- package/lib/commonjs/HyperTrack/HyperTrack.js +2 -2
- package/lib/commonjs/HyperTrack/HyperTrack.js.map +1 -1
- package/lib/module/HyperTrack/HyperTrack.js +2 -2
- package/package.json +7 -3
- package/CHANGELOG.md +0 -733
- package/CONTRIBUTING.md +0 -77
- package/LICENSE +0 -21
- package/android/.gradle/7.2/fileChanges/last-build.bin +0 -0
- package/android/.gradle/7.2/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/7.2/gc.properties +0 -0
- package/android/.gradle/checksums/checksums.lock +0 -0
- package/android/.gradle/vcs-1/gc.properties +0 -0
package/README.md
CHANGED
|
@@ -1,40 +1,3 @@
|
|
|
1
|
-
#
|
|
1
|
+
# `hypertrack-sdk-react-native`
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
[](https://www.npmjs.com/package/hypertrack-sdk-react-native)
|
|
5
|
-
[](https://github.com/hypertrack/sdk-ios)
|
|
6
|
-
[](https://github.com/hypertrack/sdk-android)
|
|
7
|
-
|
|
8
|
-
[HyperTrack](https://www.hypertrack.com) lets you add live location tracking to your mobile app. Live location is made available along with ongoing activity, tracking controls and tracking outage with reasons.
|
|
9
|
-
|
|
10
|
-
React Native HyperTrack SDK is a wrapper around native iOS and Android SDKs that allows to integrate HyperTrack into React Native apps.
|
|
11
|
-
|
|
12
|
-
For information about how to get started with React Native HyperTrack SDK, please check this [Guide](https://www.hypertrack.com/docs/install-sdk-react-native).
|
|
13
|
-
|
|
14
|
-
## Installation
|
|
15
|
-
|
|
16
|
-
`yarn add hypertrack-sdk-react-native`
|
|
17
|
-
|
|
18
|
-
## Sample code
|
|
19
|
-
|
|
20
|
-
[Quickstart React Native app](https://github.com/hypertrack/quickstart-react-native)
|
|
21
|
-
|
|
22
|
-
## Wrapper API Documentation
|
|
23
|
-
|
|
24
|
-
[Wrapper API Documentation](https://hypertrack.github.io/sdk-react-native/)
|
|
25
|
-
|
|
26
|
-
## Requirements
|
|
27
|
-
|
|
28
|
-
### Android
|
|
29
|
-
|
|
30
|
-
- Gradle version 6.7.1+
|
|
31
|
-
- compileSdkVersion 31+
|
|
32
|
-
- minSdkVersion 19+
|
|
33
|
-
|
|
34
|
-
### iOS
|
|
35
|
-
|
|
36
|
-
- iOS version 12.4+
|
|
37
|
-
|
|
38
|
-
## Contributing
|
|
39
|
-
|
|
40
|
-
If you want to contribute check [CONTRIBUTING.md](CONTRIBUTING.md)
|
|
3
|
+
The main package for HyperTrack SDK React Native.
|
package/android/build.gradle
CHANGED
|
@@ -148,8 +148,6 @@ dependencies {
|
|
|
148
148
|
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
|
|
149
149
|
|
|
150
150
|
implementation "com.hypertrack:sdk-android:$hyperTrackSdk_version"
|
|
151
|
-
implementation "com.hypertrack:location-services-google-19-0-1:$hyperTrackSdk_version"
|
|
152
|
-
implementation "com.hypertrack:push-service-firebase:$hyperTrackSdk_version"
|
|
153
151
|
}
|
|
154
152
|
|
|
155
153
|
if (isNewArchitectureEnabled()) {
|
|
@@ -18,7 +18,7 @@ Pod::Spec.new do |s|
|
|
|
18
18
|
s.source_files = "ios/**/*.{h,m,mm,swift}"
|
|
19
19
|
|
|
20
20
|
s.dependency "React-Core"
|
|
21
|
-
s.dependency 'HyperTrack', '5.0
|
|
21
|
+
s.dependency 'HyperTrack', '5.2.0'
|
|
22
22
|
|
|
23
23
|
# Don't install the dependencies when we run `pod install` in the old architecture.
|
|
24
24
|
if ENV['RCT_NEW_ARCH_ENABLED'] == '1' then
|
|
@@ -7,8 +7,8 @@ exports.default = void 0;
|
|
|
7
7
|
var _reactNative = require("react-native");
|
|
8
8
|
var _HyperTrackError = require("./data_types/HyperTrackError");
|
|
9
9
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
10
|
-
function _toPropertyKey(
|
|
11
|
-
function _toPrimitive(
|
|
10
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : String(i); }
|
|
11
|
+
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
12
12
|
const EVENT_ERRORS = 'errors';
|
|
13
13
|
const EVENT_IS_AVAILABLE = 'isAvailable';
|
|
14
14
|
const EVENT_IS_TRACKING = 'isTracking';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNative","require","_HyperTrackError","_defineProperty","obj","key","value","_toPropertyKey","Object","defineProperty","enumerable","configurable","writable","arg","_toPrimitive","String","input","hint","prim","Symbol","toPrimitive","undefined","res","call","TypeError","Number","EVENT_ERRORS","EVENT_IS_AVAILABLE","EVENT_IS_TRACKING","EVENT_LOCATE","EVENT_LOCATION","LINKING_ERROR","Platform","select","ios","default","HyperTrackSdk","NativeModules","HyperTrackReactNativePlugin","Proxy","get","Error","EventEmitter","NativeEventEmitter","HyperTrack","addGeotag","args","length","data","expectedLocation","then","locationResponse","deserializeLocationResponse","isLocation","type","latitude","longitude","deserializeLocationWithDeviationResponse","getDeviceId","deviceId","getErrors","errors","deserializeHyperTrackErrors","getIsAvailable","isAvailable","getIsTracking","isTracking","getLocation","getMetadata","metadata","deserializeMetadata","getName","name","deserializeName","locate","callback","_this$locateSubscript","locateSubscription","remove","addListener","location","deserializeLocateResponse","setIsAvailable","setIsTracking","setMetadata","setName","subscribeToErrors","listener","rawErrors","subscribeToIsAvailable","subscribeToIsTracking","subscribeToLocation","map","error","keys","HyperTrackError","find","response","deserializeLocationError","locationError","locationWithDeviationInternal","locationInternal","deviation","JSON","stringify","exports"],"sources":["HyperTrack.ts"],"sourcesContent":["import {\n NativeModules,\n Platform,\n NativeEventEmitter,\n EmitterSubscription,\n} from 'react-native';\nimport { HyperTrackError } from './data_types/HyperTrackError';\nimport type { IsAvailable } from './data_types/internal/IsAvailable';\nimport type { IsTracking } from './data_types/internal/IsTracking';\nimport type { Location } from './data_types/Location';\nimport type { LocationError } from './data_types/LocationError';\nimport type { DeviceId } from './data_types/internal/DeviceId';\nimport type { GeotagData } from './data_types/internal/GeotagData';\nimport type { Name } from './data_types/internal/Name';\nimport type { HyperTrackErrorInternal } from './data_types/internal/HyperTrackErrorInternal';\nimport type { LocationWithDeviation } from './data_types/LocationWithDeviation';\nimport type { LocationErrorInternal } from './data_types/internal/LocationErrorInternal';\nimport type { Result } from './data_types/Result';\nimport type { LocationInternal } from './data_types/internal/LocationInternal';\nimport type { LocationWithDeviationInternal } from './data_types/internal/LocationWithDeviationInternal';\nimport type { Metadata } from './data_types/internal/Metadata';\n\nconst EVENT_ERRORS = 'errors';\nconst EVENT_IS_AVAILABLE = 'isAvailable';\nconst EVENT_IS_TRACKING = 'isTracking';\nconst EVENT_LOCATE = 'locate';\nconst EVENT_LOCATION = 'location';\n\nconst LINKING_ERROR =\n `The package 'hypertrack-sdk-react-native' doesn't seem to be linked. Make sure: \\n\\n` +\n Platform.select({ ios: \"- You have run 'pod install'\\n\", default: '' }) +\n '- You rebuilt the app after installing the package\\n' +\n '- You are not using Expo managed workflow\\n';\n\nconst HyperTrackSdk = NativeModules.HyperTrackReactNativePlugin\n ? NativeModules.HyperTrackReactNativePlugin\n : new Proxy(\n {},\n {\n get() {\n throw new Error(LINKING_ERROR);\n },\n }\n );\n\nconst EventEmitter = new NativeEventEmitter(HyperTrackSdk);\n\nexport default class HyperTrack {\n private static locateSubscription: EmitterSubscription | undefined;\n\n /**\n * Adds a new geotag\n *\n * @param {Object} data - Geotad data JSON\n * @returns current location if success or LocationError if failure\n */\n static async addGeotag(\n data: Object\n ): Promise<Result<Location, LocationError>>;\n\n /**\n * Adds a new geotag with expected location\n *\n * @param {Object} data - Geotad data JSON\n * @param {Location} expectedLocation - Expected location\n * @returns location with deviation if success or LocationError if failure\n */\n static async addGeotag(\n data: Object,\n expectedLocation: Location\n ): Promise<Result<LocationWithDeviation, LocationError>>;\n\n static async addGeotag(\n ...args: any[]\n ): Promise<Result<Location | LocationWithDeviation, LocationError>> {\n if (args.length === 1 && typeof args[0] === 'object') {\n return HyperTrackSdk.addGeotag({\n data: args[0],\n expectedLocation: undefined,\n } as GeotagData).then(\n (locationResponse: Result<LocationInternal, LocationErrorInternal>) => {\n return this.deserializeLocationResponse(locationResponse);\n }\n );\n } else if (\n args.length === 2 &&\n typeof args[0] === 'object' &&\n HyperTrack.isLocation(args[1])\n ) {\n let expectedLocation = args[1] as Location;\n return HyperTrackSdk.addGeotag({\n data: args[0],\n expectedLocation: {\n type: 'location',\n value: {\n latitude: expectedLocation.latitude,\n longitude: expectedLocation.longitude,\n },\n } as LocationInternal,\n } as GeotagData).then(\n (\n locationResponse: Result<\n LocationWithDeviationInternal,\n LocationErrorInternal\n >\n ) => {\n return this.deserializeLocationWithDeviationResponse(\n locationResponse\n );\n }\n );\n } else {\n throw new Error('Invalid arguments');\n }\n }\n\n /**\n * Returns a string that is used to uniquely identify the device\n *\n * @returns {string} Device ID\n */\n static async getDeviceId(): Promise<string> {\n return HyperTrackSdk.getDeviceId().then(\n (deviceId: DeviceId) => deviceId.value\n );\n }\n\n /**\n * Returns a list of errors that blocks SDK from tracking\n *\n * @returns {HyperTrackError[]} List of errors\n */\n static async getErrors(): Promise<HyperTrackError[]> {\n return HyperTrackSdk.getErrors().then(\n (errors: HyperTrackErrorInternal[]) => {\n return this.deserializeHyperTrackErrors(errors);\n }\n );\n }\n\n /**\n * Reflects availability of the device for the Nearby search\n *\n * @returns true when is available or false when unavailable\n */\n static async getIsAvailable(): Promise<boolean> {\n return HyperTrackSdk.getIsAvailable().then(\n (isAvailable: IsAvailable) => isAvailable.value\n );\n }\n\n /**\n * Reflects the tracking intent for the device\n *\n * @returns {boolean} Whether the user's movement data is getting tracked or not.\n */\n static async getIsTracking(): Promise<boolean> {\n return HyperTrackSdk.getIsTracking().then(\n (isTracking: IsTracking) => isTracking.value\n );\n }\n\n /**\n * Reflects the current location of the user or an outage reason\n */\n static async getLocation(): Promise<Result<Location, LocationError>> {\n return HyperTrackSdk.getLocation().then(\n (locationResponse: Result<LocationInternal, LocationErrorInternal>) => {\n return this.deserializeLocationResponse(locationResponse);\n }\n );\n }\n\n /**\n * Gets the metadata that is set for the device\n *\n * @returns {Object} Metadata JSON\n */\n static async getMetadata(): Promise<Object> {\n return HyperTrackSdk.getMetadata().then((metadata: Metadata) => {\n return this.deserializeMetadata(metadata);\n });\n }\n\n /**\n * Gets the name that is set for the device\n *\n * @returns {string} Device name\n */\n static async getName(): Promise<string> {\n return HyperTrackSdk.getName().then((name: Name) => {\n return this.deserializeName(name);\n });\n }\n\n /**\n * Requests one-time location update and returns the location once it is available, or error.\n *\n * Only one locate subscription can be active at a time. If you re-subscribe, the old EmitterSubscription\n * will be automaticaly removed.\n *\n * This method will start location tracking if called, and will stop it when the location is received or\n * the subscription is cancelled. If any other tracking intent is present (e.g. isAvailable is set to `true`),\n * the tracking will not be stopped.\n *\n * @param callback\n * @returns EmitterSubscription\n * @example\n * ```js\n * const subscription = HyperTrack.locate(location => {\n * ...\n * })\n *\n * // to unsubscribe\n * subscription.remove()\n * ```\n */\n static locate(\n callback: (location: Result<Location, HyperTrackError[]>) => void\n ) {\n this.locateSubscription?.remove();\n this.locateSubscription = EventEmitter.addListener(\n EVENT_LOCATE,\n (location: Result<LocationInternal, HyperTrackErrorInternal[]>) => {\n callback(this.deserializeLocateResponse(location));\n }\n );\n HyperTrackSdk.locate();\n return this.locateSubscription;\n }\n\n /**\n * Sets the availability of the device for the Nearby search\n *\n * @param availability true when is available or false when unavailable\n */\n static async setIsAvailable(isAvailable: boolean) {\n HyperTrackSdk.setIsAvailable({\n type: 'isAvailable',\n value: isAvailable,\n } as IsAvailable);\n }\n\n /**\n * Sets the tracking intent for the device\n *\n * @param {boolean} isTracking\n */\n static async setIsTracking(isTracking: boolean): Promise<void> {\n HyperTrackSdk.setIsTracking({\n type: 'isTracking',\n value: isTracking,\n } as IsTracking);\n }\n\n /**\n * Sets the metadata for the device\n *\n * @param {Object} data - Metadata JSON\n */\n static async setMetadata(data: Object) {\n HyperTrackSdk.setMetadata({\n type: 'metadata',\n value: data,\n });\n }\n\n /**\n * Sets the name for the device\n *\n * @param {string} name\n */\n static async setName(name: string) {\n HyperTrackSdk.setName({\n type: 'name',\n value: name,\n } as Name);\n }\n\n /**\n * Subscribe to tracking errors\n *\n * @param listener\n * @returns EmitterSubscription\n * @example\n * ```js\n * const subscription = HyperTrack.subscribeToErrors(errors => {\n * errors.forEach(error => {\n * // ... error\n * })\n * })\n *\n * // later, to stop listening\n * subscription.remove()\n * ```\n */\n static subscribeToErrors(\n listener: (errors: HyperTrackError[]) => void\n ): EmitterSubscription {\n return EventEmitter.addListener(\n EVENT_ERRORS,\n (rawErrors: HyperTrackErrorInternal[]) => {\n listener(this.deserializeHyperTrackErrors(rawErrors));\n }\n );\n }\n\n /**\n * Subscribe to availability changes\n *\n * @param listener\n * @returns EmitterSubscription\n * @example\n * ```js\n * const subscription = HyperTrack.subscribeToIsAvailable(isAvailable => {\n * if (isAvailable) {\n * // ... ready to go\n * }\n * })\n *\n * // later, to stop listening\n * subscription.remove()\n * ```\n */\n static subscribeToIsAvailable(\n listener: (isAvailable: boolean) => void\n ): EmitterSubscription {\n return EventEmitter.addListener(\n EVENT_IS_AVAILABLE,\n (isAvailable: IsAvailable) => {\n listener(isAvailable.value);\n }\n );\n }\n\n /**\n * Subscribe to tracking intent changes\n *\n * @param listener\n * @returns EmitterSubscription\n * @example\n * ```js\n * const subscription = HyperTrack.subscribeToIsTracking(isTracking => {\n * if (isTracking) {\n * // ... ready to go\n * }\n * })\n *\n * // later, to stop listening\n * subscription.remove()\n * ```\n */\n static subscribeToIsTracking(\n listener: (isTracking: boolean) => void\n ): EmitterSubscription {\n return EventEmitter.addListener(\n EVENT_IS_TRACKING,\n (isTracking: IsTracking) => {\n listener(isTracking.value);\n }\n );\n }\n\n /**\n * Subscribe to location changes\n *\n * @param listener\n * @returns EmitterSubscription\n * @example\n * ```js\n * const subscription = HyperTrack.subscribeToLocation(location => {\n * ...\n * })\n *\n * // later, to stop listening\n * subscription.remove()\n * ```\n */\n static subscribeToLocation(\n listener: (location: Result<Location, LocationError>) => void\n ) {\n return EventEmitter.addListener(\n EVENT_LOCATION,\n (location: Result<LocationInternal, LocationErrorInternal>) => {\n listener(this.deserializeLocationResponse(location));\n }\n );\n }\n\n /** @ignore */\n private static deserializeHyperTrackErrors(\n errors: HyperTrackErrorInternal[]\n ): HyperTrackError[] {\n let res = errors.map((error: HyperTrackErrorInternal) => {\n if (error.type != 'error') {\n throw new Error('Invalid error type');\n }\n return Object.keys(HyperTrackError).find(\n (key) =>\n HyperTrackError[key as keyof typeof HyperTrackError] === error.value\n ) as HyperTrackError;\n });\n return res;\n }\n\n /** @ignore */\n private static deserializeLocateResponse(\n response: Result<LocationInternal, HyperTrackErrorInternal[]>\n ): Result<Location, HyperTrackError[]> {\n switch (response.type) {\n case 'success':\n return {\n type: 'success',\n value: response.value.value,\n };\n case 'failure':\n return {\n type: 'failure',\n value: this.deserializeHyperTrackErrors(response.value),\n };\n }\n }\n\n /** @ignore */\n private static deserializeLocationError(\n locationError: LocationErrorInternal\n ): LocationError {\n switch (locationError.type) {\n case 'notRunning':\n case 'starting':\n return locationError;\n case 'errors':\n return {\n type: 'errors',\n value: this.deserializeHyperTrackErrors(locationError.value),\n };\n }\n }\n\n /** @ignore */\n private static deserializeLocationResponse(\n response: Result<LocationInternal, LocationErrorInternal>\n ): Result<Location, LocationError> {\n switch (response.type) {\n case 'success':\n return {\n type: 'success',\n value: response.value.value,\n };\n case 'failure':\n return {\n type: 'failure',\n value: this.deserializeLocationError(response.value),\n };\n }\n }\n\n /** @ignore */\n private static deserializeLocationWithDeviationResponse(\n response: Result<LocationWithDeviationInternal, LocationErrorInternal>\n ): Result<LocationWithDeviation, LocationError> {\n switch (response.type) {\n case 'success':\n const locationWithDeviationInternal: LocationWithDeviationInternal =\n response.value;\n const locationInternal: LocationInternal =\n locationWithDeviationInternal.value.location;\n\n return {\n type: 'success',\n value: {\n location: locationInternal.value,\n deviation: locationWithDeviationInternal.value.deviation,\n } as LocationWithDeviation,\n };\n case 'failure':\n return {\n type: 'failure',\n value: this.deserializeLocationError(response.value),\n };\n }\n }\n\n /** @ignore */\n private static deserializeMetadata(metadata: Metadata): Object {\n if (metadata.type != 'metadata') {\n throw new Error(`Invalid metadata: ${JSON.stringify(metadata)}`);\n }\n return metadata.value;\n }\n\n /** @ignore */\n private static deserializeName(name: Name): string {\n if (name.type != 'name') {\n throw new Error(`Invalid name: ${JSON.stringify(name)}`);\n }\n return name.value;\n }\n\n /** @ignore */\n private static isLocation(obj: Location): obj is Location {\n return (\n 'latitude' in obj &&\n typeof obj.latitude == 'number' &&\n 'longitude' in obj &&\n typeof obj.longitude == 'number'\n );\n }\n}\n"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAMA,IAAAC,gBAAA,GAAAD,OAAA;AAA+D,SAAAE,gBAAAC,GAAA,EAAAC,GAAA,EAAAC,KAAA,IAAAD,GAAA,GAAAE,cAAA,CAAAF,GAAA,OAAAA,GAAA,IAAAD,GAAA,IAAAI,MAAA,CAAAC,cAAA,CAAAL,GAAA,EAAAC,GAAA,IAAAC,KAAA,EAAAA,KAAA,EAAAI,UAAA,QAAAC,YAAA,QAAAC,QAAA,oBAAAR,GAAA,CAAAC,GAAA,IAAAC,KAAA,WAAAF,GAAA;AAAA,SAAAG,eAAAM,GAAA,QAAAR,GAAA,GAAAS,YAAA,CAAAD,GAAA,2BAAAR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AC0E,QAAQ;QAE9C,OAAO;UACL1B,IAAI,EAAE,SAAS;UACfhD,KAAK,EAAE;YACL0E,QAAQ,EAAEqB,gBAAgB,CAAC/F,KAAK;YAChCgG,SAAS,EAAEF,6BAA6B,CAAC9F,KAAK,CAACgG;UACjD;QACF,CAAC;MACH,KAAK,SAAS;QACZ,OAAO;UACLhD,IAAI,EAAE,SAAS;UACfhD,KAAK,EAAE,IAAI,CAAC4F,wBAAwB,CAACD,QAAQ,CAAC3F,KAAK;QACrD,CAAC;IACL;EACF;;EAEA;EACA,OAAegE,mBAAmBA,CAACD,QAAkB,EAAU;IAC7D,IAAIA,QAAQ,CAACf,IAAI,IAAI,UAAU,EAAE;MAC/B,MAAM,IAAIb,KAAK,CAAE,qBAAoB8D,IAAI,CAACC,SAAS,CAACnC,QAAQ,CAAE,EAAC,CAAC;IAClE;IACA,OAAOA,QAAQ,CAAC/D,KAAK;EACvB;;EAEA;EACA,OAAemE,eAAeA,CAACD,IAAU,EAAU;IACjD,IAAIA,IAAI,CAAClB,IAAI,IAAI,MAAM,EAAE;MACvB,MAAM,IAAIb,KAAK,CAAE,iBAAgB8D,IAAI,CAACC,SAAS,CAAChC,IAAI,CAAE,EAAC,CAAC;IAC1D;IACA,OAAOA,IAAI,CAAClE,KAAK;EACnB;;EAEA;EACA,OAAe+C,UAAUA,CAACjD,GAAa,EAAmB;IACxD,OACE,UAAU,IAAIA,GAAG,IACjB,OAAOA,GAAG,CAACmD,QAAQ,IAAI,QAAQ,IAC/B,WAAW,IAAInD,GAAG,IAClB,OAAOA,GAAG,CAACoD,SAAS,IAAI,QAAQ;EAEpC;AACF;AAACiD,OAAA,CAAAtE,OAAA,GAAAS,UAAA;AAAAzC,eAAA,CA7coByC,UAAU"}
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_HyperTrackError","_defineProperty","obj","key","value","_toPropertyKey","Object","defineProperty","enumerable","configurable","writable","t","i","_toPrimitive","String","r","e","Symbol","toPrimitive","call","TypeError","Number","EVENT_ERRORS","EVENT_IS_AVAILABLE","EVENT_IS_TRACKING","EVENT_LOCATE","EVENT_LOCATION","LINKING_ERROR","Platform","select","ios","default","HyperTrackSdk","NativeModules","HyperTrackReactNativePlugin","Proxy","get","Error","EventEmitter","NativeEventEmitter","HyperTrack","addGeotag","args","length","data","expectedLocation","undefined","then","locationResponse","deserializeLocationResponse","isLocation","type","latitude","longitude","deserializeLocationWithDeviationResponse","getDeviceId","deviceId","getErrors","errors","deserializeHyperTrackErrors","getIsAvailable","isAvailable","getIsTracking","isTracking","getLocation","getMetadata","metadata","deserializeMetadata","getName","name","deserializeName","locate","callback","_this$locateSubscript","locateSubscription","remove","addListener","location","deserializeLocateResponse","setIsAvailable","setIsTracking","setMetadata","setName","subscribeToErrors","listener","rawErrors","subscribeToIsAvailable","subscribeToIsTracking","subscribeToLocation","res","map","error","keys","HyperTrackError","find","response","deserializeLocationError","locationError","locationWithDeviationInternal","locationInternal","deviation","JSON","stringify","exports"],"sources":["HyperTrack.ts"],"sourcesContent":["import {\n NativeModules,\n Platform,\n NativeEventEmitter,\n EmitterSubscription,\n} from 'react-native';\nimport { HyperTrackError } from './data_types/HyperTrackError';\nimport type { IsAvailable } from './data_types/internal/IsAvailable';\nimport type { IsTracking } from './data_types/internal/IsTracking';\nimport type { Location } from './data_types/Location';\nimport type { LocationError } from './data_types/LocationError';\nimport type { DeviceId } from './data_types/internal/DeviceId';\nimport type { GeotagData } from './data_types/internal/GeotagData';\nimport type { Name } from './data_types/internal/Name';\nimport type { HyperTrackErrorInternal } from './data_types/internal/HyperTrackErrorInternal';\nimport type { LocationWithDeviation } from './data_types/LocationWithDeviation';\nimport type { LocationErrorInternal } from './data_types/internal/LocationErrorInternal';\nimport type { Result } from './data_types/Result';\nimport type { LocationInternal } from './data_types/internal/LocationInternal';\nimport type { LocationWithDeviationInternal } from './data_types/internal/LocationWithDeviationInternal';\nimport type { Metadata } from './data_types/internal/Metadata';\n\nconst EVENT_ERRORS = 'errors';\nconst EVENT_IS_AVAILABLE = 'isAvailable';\nconst EVENT_IS_TRACKING = 'isTracking';\nconst EVENT_LOCATE = 'locate';\nconst EVENT_LOCATION = 'location';\n\nconst LINKING_ERROR =\n `The package 'hypertrack-sdk-react-native' doesn't seem to be linked. Make sure: \\n\\n` +\n Platform.select({ ios: \"- You have run 'pod install'\\n\", default: '' }) +\n '- You rebuilt the app after installing the package\\n' +\n '- You are not using Expo managed workflow\\n';\n\nconst HyperTrackSdk = NativeModules.HyperTrackReactNativePlugin\n ? NativeModules.HyperTrackReactNativePlugin\n : new Proxy(\n {},\n {\n get() {\n throw new Error(LINKING_ERROR);\n },\n }\n );\n\nconst EventEmitter = new NativeEventEmitter(HyperTrackSdk);\n\nexport default class HyperTrack {\n private static locateSubscription: EmitterSubscription | undefined;\n\n /**\n * Adds a new geotag\n *\n * @param {Object} data - Geotad data JSON\n * @returns current location if success or LocationError if failure\n */\n static async addGeotag(\n data: Object\n ): Promise<Result<Location, LocationError>>;\n\n /**\n * Adds a new geotag with expected location\n *\n * @param {Object} data - Geotad data JSON\n * @param {Location} expectedLocation - Expected location\n * @returns location with deviation if success or LocationError if failure\n */\n static async addGeotag(\n data: Object,\n expectedLocation: Location\n ): Promise<Result<LocationWithDeviation, LocationError>>;\n\n static async addGeotag(\n ...args: any[]\n ): Promise<Result<Location | LocationWithDeviation, LocationError>> {\n if (args.length === 1 && typeof args[0] === 'object') {\n return HyperTrackSdk.addGeotag({\n data: args[0],\n expectedLocation: undefined,\n } as GeotagData).then(\n (locationResponse: Result<LocationInternal, LocationErrorInternal>) => {\n return this.deserializeLocationResponse(locationResponse);\n }\n );\n } else if (\n args.length === 2 &&\n typeof args[0] === 'object' &&\n HyperTrack.isLocation(args[1])\n ) {\n let expectedLocation = args[1] as Location;\n return HyperTrackSdk.addGeotag({\n data: args[0],\n expectedLocation: {\n type: 'location',\n value: {\n latitude: expectedLocation.latitude,\n longitude: expectedLocation.longitude,\n },\n } as LocationInternal,\n } as GeotagData).then(\n (\n locationResponse: Result<\n LocationWithDeviationInternal,\n LocationErrorInternal\n >\n ) => {\n return this.deserializeLocationWithDeviationResponse(\n locationResponse\n );\n }\n );\n } else {\n throw new Error('Invalid arguments');\n }\n }\n\n /**\n * Returns a string that is used to uniquely identify the device\n *\n * @returns {string} Device ID\n */\n static async getDeviceId(): Promise<string> {\n return HyperTrackSdk.getDeviceId().then(\n (deviceId: DeviceId) => deviceId.value\n );\n }\n\n /**\n * Returns a list of errors that blocks SDK from tracking\n *\n * @returns {HyperTrackError[]} List of errors\n */\n static async getErrors(): Promise<HyperTrackError[]> {\n return HyperTrackSdk.getErrors().then(\n (errors: HyperTrackErrorInternal[]) => {\n return this.deserializeHyperTrackErrors(errors);\n }\n );\n }\n\n /**\n * Reflects availability of the device for the Nearby search\n *\n * @returns true when is available or false when unavailable\n */\n static async getIsAvailable(): Promise<boolean> {\n return HyperTrackSdk.getIsAvailable().then(\n (isAvailable: IsAvailable) => isAvailable.value\n );\n }\n\n /**\n * Reflects the tracking intent for the device\n *\n * @returns {boolean} Whether the user's movement data is getting tracked or not.\n */\n static async getIsTracking(): Promise<boolean> {\n return HyperTrackSdk.getIsTracking().then(\n (isTracking: IsTracking) => isTracking.value\n );\n }\n\n /**\n * Reflects the current location of the user or an outage reason\n */\n static async getLocation(): Promise<Result<Location, LocationError>> {\n return HyperTrackSdk.getLocation().then(\n (locationResponse: Result<LocationInternal, LocationErrorInternal>) => {\n return this.deserializeLocationResponse(locationResponse);\n }\n );\n }\n\n /**\n * Gets the metadata that is set for the device\n *\n * @returns {Object} Metadata JSON\n */\n static async getMetadata(): Promise<Object> {\n return HyperTrackSdk.getMetadata().then((metadata: Metadata) => {\n return this.deserializeMetadata(metadata);\n });\n }\n\n /**\n * Gets the name that is set for the device\n *\n * @returns {string} Device name\n */\n static async getName(): Promise<string> {\n return HyperTrackSdk.getName().then((name: Name) => {\n return this.deserializeName(name);\n });\n }\n\n /**\n * Requests one-time location update and returns the location once it is available, or error.\n *\n * Only one locate subscription can be active at a time. If you re-subscribe, the old EmitterSubscription\n * will be automaticaly removed.\n *\n * This method will start location tracking if called, and will stop it when the location is received or\n * the subscription is cancelled. If any other tracking intent is present (e.g. isAvailable is set to `true`),\n * the tracking will not be stopped.\n *\n * @param callback\n * @returns EmitterSubscription\n * @example\n * ```js\n * const subscription = HyperTrack.locate(location => {\n * ...\n * })\n *\n * // to unsubscribe\n * subscription.remove()\n * ```\n */\n static locate(\n callback: (location: Result<Location, HyperTrackError[]>) => void\n ) {\n this.locateSubscription?.remove();\n this.locateSubscription = EventEmitter.addListener(\n EVENT_LOCATE,\n (location: Result<LocationInternal, HyperTrackErrorInternal[]>) => {\n callback(this.deserializeLocateResponse(location));\n }\n );\n HyperTrackSdk.locate();\n return this.locateSubscription;\n }\n\n /**\n * Sets the availability of the device for the Nearby search\n *\n * @param availability true when is available or false when unavailable\n */\n static async setIsAvailable(isAvailable: boolean) {\n HyperTrackSdk.setIsAvailable({\n type: 'isAvailable',\n value: isAvailable,\n } as IsAvailable);\n }\n\n /**\n * Sets the tracking intent for the device\n *\n * @param {boolean} isTracking\n */\n static async setIsTracking(isTracking: boolean): Promise<void> {\n HyperTrackSdk.setIsTracking({\n type: 'isTracking',\n value: isTracking,\n } as IsTracking);\n }\n\n /**\n * Sets the metadata for the device\n *\n * @param {Object} data - Metadata JSON\n */\n static async setMetadata(data: Object) {\n HyperTrackSdk.setMetadata({\n type: 'metadata',\n value: data,\n });\n }\n\n /**\n * Sets the name for the device\n *\n * @param {string} name\n */\n static async setName(name: string) {\n HyperTrackSdk.setName({\n type: 'name',\n value: name,\n } as Name);\n }\n\n /**\n * Subscribe to tracking errors\n *\n * @param listener\n * @returns EmitterSubscription\n * @example\n * ```js\n * const subscription = HyperTrack.subscribeToErrors(errors => {\n * errors.forEach(error => {\n * // ... error\n * })\n * })\n *\n * // later, to stop listening\n * subscription.remove()\n * ```\n */\n static subscribeToErrors(\n listener: (errors: HyperTrackError[]) => void\n ): EmitterSubscription {\n return EventEmitter.addListener(\n EVENT_ERRORS,\n (rawErrors: HyperTrackErrorInternal[]) => {\n listener(this.deserializeHyperTrackErrors(rawErrors));\n }\n );\n }\n\n /**\n * Subscribe to availability changes\n *\n * @param listener\n * @returns EmitterSubscription\n * @example\n * ```js\n * const subscription = HyperTrack.subscribeToIsAvailable(isAvailable => {\n * if (isAvailable) {\n * // ... ready to go\n * }\n * })\n *\n * // later, to stop listening\n * subscription.remove()\n * ```\n */\n static subscribeToIsAvailable(\n listener: (isAvailable: boolean) => void\n ): EmitterSubscription {\n return EventEmitter.addListener(\n EVENT_IS_AVAILABLE,\n (isAvailable: IsAvailable) => {\n listener(isAvailable.value);\n }\n );\n }\n\n /**\n * Subscribe to tracking intent changes\n *\n * @param listener\n * @returns EmitterSubscription\n * @example\n * ```js\n * const subscription = HyperTrack.subscribeToIsTracking(isTracking => {\n * if (isTracking) {\n * // ... ready to go\n * }\n * })\n *\n * // later, to stop listening\n * subscription.remove()\n * ```\n */\n static subscribeToIsTracking(\n listener: (isTracking: boolean) => void\n ): EmitterSubscription {\n return EventEmitter.addListener(\n EVENT_IS_TRACKING,\n (isTracking: IsTracking) => {\n listener(isTracking.value);\n }\n );\n }\n\n /**\n * Subscribe to location changes\n *\n * @param listener\n * @returns EmitterSubscription\n * @example\n * ```js\n * const subscription = HyperTrack.subscribeToLocation(location => {\n * ...\n * })\n *\n * // later, to stop listening\n * subscription.remove()\n * ```\n */\n static subscribeToLocation(\n listener: (location: Result<Location, LocationError>) => void\n ) {\n return EventEmitter.addListener(\n EVENT_LOCATION,\n (location: Result<LocationInternal, LocationErrorInternal>) => {\n listener(this.deserializeLocationResponse(location));\n }\n );\n }\n\n /** @ignore */\n private static deserializeHyperTrackErrors(\n errors: HyperTrackErrorInternal[]\n ): HyperTrackError[] {\n let res = errors.map((error: HyperTrackErrorInternal) => {\n if (error.type != 'error') {\n throw new Error('Invalid error type');\n }\n return Object.keys(HyperTrackError).find(\n (key) =>\n HyperTrackError[key as keyof typeof HyperTrackError] === error.value\n ) as HyperTrackError;\n });\n return res;\n }\n\n /** @ignore */\n private static deserializeLocateResponse(\n response: Result<LocationInternal, HyperTrackErrorInternal[]>\n ): Result<Location, HyperTrackError[]> {\n switch (response.type) {\n case 'success':\n return {\n type: 'success',\n value: response.value.value,\n };\n case 'failure':\n return {\n type: 'failure',\n value: this.deserializeHyperTrackErrors(response.value),\n };\n }\n }\n\n /** @ignore */\n private static deserializeLocationError(\n locationError: LocationErrorInternal\n ): LocationError {\n switch (locationError.type) {\n case 'notRunning':\n case 'starting':\n return locationError;\n case 'errors':\n return {\n type: 'errors',\n value: this.deserializeHyperTrackErrors(locationError.value),\n };\n }\n }\n\n /** @ignore */\n private static deserializeLocationResponse(\n response: Result<LocationInternal, LocationErrorInternal>\n ): Result<Location, LocationError> {\n switch (response.type) {\n case 'success':\n return {\n type: 'success',\n value: response.value.value,\n };\n case 'failure':\n return {\n type: 'failure',\n value: this.deserializeLocationError(response.value),\n };\n }\n }\n\n /** @ignore */\n private static deserializeLocationWithDeviationResponse(\n response: Result<LocationWithDeviationInternal, LocationErrorInternal>\n ): Result<LocationWithDeviation, LocationError> {\n switch (response.type) {\n case 'success':\n const locationWithDeviationInternal: LocationWithDeviationInternal =\n response.value;\n const locationInternal: LocationInternal =\n locationWithDeviationInternal.value.location;\n\n return {\n type: 'success',\n value: {\n location: locationInternal.value,\n deviation: locationWithDeviationInternal.value.deviation,\n } as LocationWithDeviation,\n };\n case 'failure':\n return {\n type: 'failure',\n value: this.deserializeLocationError(response.value),\n };\n }\n }\n\n /** @ignore */\n private static deserializeMetadata(metadata: Metadata): Object {\n if (metadata.type != 'metadata') {\n throw new Error(`Invalid metadata: ${JSON.stringify(metadata)}`);\n }\n return metadata.value;\n }\n\n /** @ignore */\n private static deserializeName(name: Name): string {\n if (name.type != 'name') {\n throw new Error(`Invalid name: ${JSON.stringify(name)}`);\n }\n return name.value;\n }\n\n /** @ignore */\n private static isLocation(obj: Location): obj is Location {\n return (\n 'latitude' in obj &&\n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B9B,IAAI,EAAE,UAAU;MAChB/C,KAAK,EAAEwC;IACT,CAAC,CAAC;EACJ;;EAEA;AACF;AACA;AACA;AACA;EACE,aAAasC,OAAOA,CAACb,IAAY,EAAE;IACjCrC,aAAa,CAACkD,OAAO,CAAC;MACpB/B,IAAI,EAAE,MAAM;MACZ/C,KAAK,EAAEiE;IACT,CAAS,CAAC;EACZ;;EAEA;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACE,OAAOc,iBAAiBA,CACtBC,QAA6C,EACxB;IACrB,OAAO9C,YAAY,CAACsC,WAAW,CAC7BtD,YAAY,EACX+D,SAAoC,IAAK;MACxCD,QAAQ,CAAC,IAAI,CAACzB,2BAA2B,CAAC0B,SAAS,CAAC,CAAC;IACvD,CACF,CAAC;EACH;;EAEA;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACE,OAAOC,sBAAsBA,CAC3BF,QAAwC,EACnB;IACrB,OAAO9C,YAAY,CAACsC,WAAW,CAC7BrD,kBAAkB,EACjBsC,WAAwB,IAAK;MAC5BuB,QAAQ,CAACvB,WAAW,CAACzD,KAAK,CAAC;IAC7B,CACF,CAAC;EACH;;EAEA;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACE,OAAOmF,qBAAqBA,CAC1BH,QAAuC,EAClB;IACrB,OAAO9C,YAAY,CAACsC,WAAW,CAC7BpD,iBAAiB,EAChBuC,UAAsB,IAAK;MAC1BqB,QAAQ,CAACrB,UAAU,CAAC3D,KAAK,CAAC;IAC5B,CACF,CAAC;EACH;;EAEA;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACE,OAAOoF,mBAAmBA,CACxBJ,QAA6D,EAC7D;IACA,OAAO9C,YAAY,CAACsC,WAAW,CAC7B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,EAAC,CAAC;IAC1D;IACA,OAAOA,IAAI,CAACjE,KAAK;EACnB;;EAEA;EACA,OAAe8C,UAAUA,CAAChD,GAAa,EAAmB;IACxD,OACE,UAAU,IAAIA,GAAG,IACjB,OAAOA,GAAG,CAACkD,QAAQ,IAAI,QAAQ,IAC/B,WAAW,IAAIlD,GAAG,IAClB,OAAOA,GAAG,CAACmD,SAAS,IAAI,QAAQ;EAEpC;AACF;AAACkD,OAAA,CAAAxE,OAAA,GAAAS,UAAA;AAAAvC,eAAA,CA7coBuC,UAAU"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
2
|
-
function _toPropertyKey(
|
|
3
|
-
function _toPrimitive(
|
|
2
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : String(i); }
|
|
3
|
+
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
4
4
|
import { NativeModules, Platform, NativeEventEmitter } from 'react-native';
|
|
5
5
|
import { HyperTrackError } from './data_types/HyperTrackError';
|
|
6
6
|
const EVENT_ERRORS = 'errors';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "hypertrack-sdk-react-native",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "12.1.0",
|
|
4
4
|
"description": "React Native HyperTrack SDK is a wrapper around native iOS and Android SDKs that allows to integrate HyperTrack into React Native apps.",
|
|
5
5
|
"main": "lib/commonjs/index",
|
|
6
6
|
"module": "lib/module/index",
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
"lint": "eslint \"**/*.{js,ts,tsx}\"",
|
|
32
32
|
"prepare": "bob build",
|
|
33
33
|
"release": "release-it",
|
|
34
|
-
"docs": "typedoc --options typedoc.json",
|
|
34
|
+
"docs": "typedoc --options typedoc.json -out ../docs",
|
|
35
35
|
"bootstrap": "yarn && yarn docs"
|
|
36
36
|
},
|
|
37
37
|
"keywords": [
|
|
@@ -42,7 +42,11 @@
|
|
|
42
42
|
"location",
|
|
43
43
|
"tracking"
|
|
44
44
|
],
|
|
45
|
-
"repository":
|
|
45
|
+
"repository": {
|
|
46
|
+
"type": "git",
|
|
47
|
+
"url": "https://github.com/hypertrack/sdk-react-native.git",
|
|
48
|
+
"directory": "sdk"
|
|
49
|
+
},
|
|
46
50
|
"author": "HyperTrack <help@hypertrack.com> (https://hypertrack.com)",
|
|
47
51
|
"license": "MIT",
|
|
48
52
|
"bugs": {
|
package/CHANGELOG.md
DELETED
|
@@ -1,733 +0,0 @@
|
|
|
1
|
-
# Changelog
|
|
2
|
-
|
|
3
|
-
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
4
|
-
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
5
|
-
|
|
6
|
-
## [11.0.11] - 2023-12-11
|
|
7
|
-
|
|
8
|
-
### Changed
|
|
9
|
-
|
|
10
|
-
- Updated HyperTrack Android SDK to [7.0.10](https://github.com/hypertrack/sdk-android/releases/tag/7.0.10)
|
|
11
|
-
- Updated HyperTrack iOS SDK to [5.0.8](https://github.com/hypertrack/sdk-ios/releases/tag/5.0.8)
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
## [11.0.10] - 2023-11-20
|
|
15
|
-
|
|
16
|
-
### Changed
|
|
17
|
-
|
|
18
|
-
- Updated HyperTrack Android SDK to [7.0.9](https://github.com/hypertrack/sdk-android/releases/tag/7.0.9)
|
|
19
|
-
- Updated HyperTrack iOS SDK to [5.0.7](https://github.com/hypertrack/sdk-ios/releases/tag/5.0.7)
|
|
20
|
-
|
|
21
|
-
## [11.0.9] - 2023-11-10
|
|
22
|
-
|
|
23
|
-
### Changed
|
|
24
|
-
|
|
25
|
-
- Updated HyperTrack Android SDK to [7.0.8](https://github.com/hypertrack/sdk-android/releases/tag/7.0.8)
|
|
26
|
-
- Updated HyperTrack iOS SDK to [5.0.6](https://github.com/hypertrack/sdk-ios/releases/tag/5.0.6)
|
|
27
|
-
|
|
28
|
-
## [11.0.8] - 2023-11-08
|
|
29
|
-
|
|
30
|
-
### Changed
|
|
31
|
-
|
|
32
|
-
- Updated HyperTrack Android SDK to [7.0.7](https://github.com/hypertrack/sdk-android/releases/tag/7.0.7)
|
|
33
|
-
- Updated HyperTrack iOS SDK to [5.0.5](https://github.com/hypertrack/sdk-ios/releases/tag/5.0.5)
|
|
34
|
-
|
|
35
|
-
## [11.0.7] - 2023-10-19
|
|
36
|
-
|
|
37
|
-
### Fixed
|
|
38
|
-
|
|
39
|
-
- Lazily initialize event listener subscriptions
|
|
40
|
-
|
|
41
|
-
## [11.0.6] - 2023-10-12
|
|
42
|
-
|
|
43
|
-
### Changed
|
|
44
|
-
|
|
45
|
-
- Updated HyperTrack iOS SDK to [5.0.4](https://github.com/hypertrack/sdk-ios/releases/tag/5.0.3)
|
|
46
|
-
|
|
47
|
-
## [11.0.5] - 2023-10-10
|
|
48
|
-
|
|
49
|
-
### Changed
|
|
50
|
-
|
|
51
|
-
- Updated HyperTrack Android SDK to [7.0.6](https://github.com/hypertrack/sdk-android/releases/tag/7.0.6)
|
|
52
|
-
- Updated HyperTrack iOS SDK to [5.0.3](https://github.com/hypertrack/sdk-ios/releases/tag/5.0.3)
|
|
53
|
-
|
|
54
|
-
## [11.0.4] - 2023-10-06
|
|
55
|
-
|
|
56
|
-
### Changed
|
|
57
|
-
|
|
58
|
-
- Updated HyperTrack Android SDK to [7.0.5](https://github.com/hypertrack/sdk-android/releases/tag/7.0.5)
|
|
59
|
-
|
|
60
|
-
## [11.0.3] - 2023-10-04
|
|
61
|
-
|
|
62
|
-
### Changed
|
|
63
|
-
|
|
64
|
-
- Updated HyperTrack Android SDK to [7.0.4](https://github.com/hypertrack/sdk-android/releases/tag/7.0.4)
|
|
65
|
-
|
|
66
|
-
## [11.0.2] - 2023-09-28
|
|
67
|
-
|
|
68
|
-
### Changed
|
|
69
|
-
|
|
70
|
-
- Updated HyperTrack Android SDK to [7.0.3](https://github.com/hypertrack/sdk-android/releases/tag/7.0.3)
|
|
71
|
-
- Updated HyperTrack iOS SDK to [5.0.2](https://github.com/hypertrack/sdk-ios/releases/tag/5.0.2)
|
|
72
|
-
|
|
73
|
-
## [11.0.1] - 2023-09-20
|
|
74
|
-
|
|
75
|
-
### Fixed
|
|
76
|
-
|
|
77
|
-
- Fixed setting wrong object format for `setMetadata()`
|
|
78
|
-
|
|
79
|
-
## [11.0.0] - 2023-09-14
|
|
80
|
-
|
|
81
|
-
### Added
|
|
82
|
-
|
|
83
|
-
- `locate()` to ask for one-time user location
|
|
84
|
-
- `subscribeToLocation()` to subscribe to user location updates
|
|
85
|
-
- `getErrors()`
|
|
86
|
-
- `getName()`
|
|
87
|
-
- `getMetadata()`
|
|
88
|
-
- HyperTrackError types:
|
|
89
|
-
- `noExemptionFromBackgroundStartRestrictions`
|
|
90
|
-
- `permissionsNotificationsDenied`
|
|
91
|
-
|
|
92
|
-
### Changed
|
|
93
|
-
|
|
94
|
-
- Updated HyperTrack Android SDK to [7.0.1](https://github.com/hypertrack/sdk-android/releases/tag/7.0.1)
|
|
95
|
-
- Add Android SDK plugins (`location-services-google-19-0-1` and `push-service-firebase`)
|
|
96
|
-
- Updated HyperTrack iOS SDK to [5.0.1](https://github.com/hypertrack/sdk-ios/releases/tag/5.0.2)
|
|
97
|
-
- The whole HyperTrack API is now static
|
|
98
|
-
- Changed the way to provide publishableKey (you need to add `HyperTrackPublishableKey` `meta-data` item to your `AndroidManifest.xml`)
|
|
99
|
-
- Renamed HyperTrackError types:
|
|
100
|
-
- `gpsSignalLost` to `locationSignalLost`
|
|
101
|
-
- `locationPermissionsDenied` to `permissionsLocationDenied`
|
|
102
|
-
- `locationPermissionsInsufficientForBackground` to `permissionsLocationInsufficientForBackground`
|
|
103
|
-
- `locationPermissionsNotDetermined` to `permissionsLocationNotDetermined`
|
|
104
|
-
- `locationPermissionsProvisional` to `locationPermissionsProvisional`
|
|
105
|
-
- `locationPermissionsReducedAccuracy` to `permissionsLocationReducedAccuracy`
|
|
106
|
-
- `locationPermissionsRestricted` to `permissionsLocationRestricted`
|
|
107
|
-
- Renamed `isAvailable()` to `getIsAvailable()`
|
|
108
|
-
- Renamed `isTracking()` to `getIsTracking()`
|
|
109
|
-
- Renamed `setAvailability()` to `setIsAvailable(boolean)`
|
|
110
|
-
- Changed `startTracking()` and `stopTracking()` to `setIsTracking(boolean)`
|
|
111
|
-
- Renamed `subscribeToTracking()` to `subscribeToIsTracking()`
|
|
112
|
-
- Renamed `subscribeToAvailability()` to `subscribeToIsAvailable()`
|
|
113
|
-
|
|
114
|
-
### Removed
|
|
115
|
-
|
|
116
|
-
- `initialize()` method (the API is now static)
|
|
117
|
-
- `SdkInitParams` (the config now should be done with the `AndroidManifest` metadata and `Info.plist`)
|
|
118
|
-
- Motion Activity permissions are not required for tracking anymore
|
|
119
|
-
- HyperTrackError types:
|
|
120
|
-
- `motionActivityPermissionsDenied`
|
|
121
|
-
- `motionActivityServicesDisabled`
|
|
122
|
-
- `motionActivityServicesUnavailable`
|
|
123
|
-
- `motionActivityPermissionsRestricted`
|
|
124
|
-
- `networkConnectionUnavailable`
|
|
125
|
-
- `sync()` method
|
|
126
|
-
|
|
127
|
-
## [10.0.3] - 2023-08-04
|
|
128
|
-
|
|
129
|
-
### Fixed
|
|
130
|
-
|
|
131
|
-
- Propagating Android exception stacktrace to JS API
|
|
132
|
-
|
|
133
|
-
## [10.0.2] - 2023-06-16
|
|
134
|
-
|
|
135
|
-
### Changed
|
|
136
|
-
|
|
137
|
-
- Updated HyperTrack iOS SDK to 4.16.1
|
|
138
|
-
|
|
139
|
-
## [10.0.1] - 2023-06-13
|
|
140
|
-
|
|
141
|
-
### Changed
|
|
142
|
-
|
|
143
|
-
- Updated HyperTrack Android SDK to 6.4.2
|
|
144
|
-
|
|
145
|
-
## [10.0.0] - 2023-06-06
|
|
146
|
-
|
|
147
|
-
### Changed
|
|
148
|
-
|
|
149
|
-
- Updated HyperTrack Android SDK to 6.4.1
|
|
150
|
-
- `getLocation` return type to `Result<Location, LocationError>`
|
|
151
|
-
|
|
152
|
-
### Fixed
|
|
153
|
-
|
|
154
|
-
- `addGeotag` and `getLocation` wrong return type that is different from the one in the API docs (introduced in 9.2.0)
|
|
155
|
-
|
|
156
|
-
## [9.2.2] - 2023-06-01
|
|
157
|
-
|
|
158
|
-
### Changed
|
|
159
|
-
|
|
160
|
-
- Updated HyperTrack iOS SDK to 4.16.0
|
|
161
|
-
|
|
162
|
-
## [9.2.1] - 2023-05-19
|
|
163
|
-
|
|
164
|
-
### Fixed
|
|
165
|
-
|
|
166
|
-
- Fixed `addGeotag` (with expected location) return type
|
|
167
|
-
|
|
168
|
-
## [9.2.0] - 2023-05-18
|
|
169
|
-
|
|
170
|
-
### Changed
|
|
171
|
-
|
|
172
|
-
- **Breaking change:** Changed `addGeotag` return type to `Result<Location, LocationError>`
|
|
173
|
-
- HyperTrack iOS SDK updated to 4.15.0
|
|
174
|
-
|
|
175
|
-
### Added
|
|
176
|
-
|
|
177
|
-
- `addGeotag` with expected location
|
|
178
|
-
|
|
179
|
-
## [9.1.1] - 2023-03-30
|
|
180
|
-
|
|
181
|
-
### Fixed
|
|
182
|
-
|
|
183
|
-
- Removed types re-export to fix issues with some build configurations
|
|
184
|
-
|
|
185
|
-
## [9.1.0] - 2023-03-21
|
|
186
|
-
|
|
187
|
-
### Added
|
|
188
|
-
|
|
189
|
-
- `automaticallyRequestPermissions` param to `initialize()`
|
|
190
|
-
|
|
191
|
-
## [9.0.0] - 2023-02-17
|
|
192
|
-
|
|
193
|
-
### Changed
|
|
194
|
-
|
|
195
|
-
- Updated HyperTrack iOS SDK to 4.14.0
|
|
196
|
-
- Updated HyperTrack Android SDK to 6.4.0
|
|
197
|
-
- `createInstance()` renamed to `initialize()`
|
|
198
|
-
- `getDeviceID()` renamed to `getDeviceId()`
|
|
199
|
-
- `syncDeviceSettings()` renamed to `sync()`
|
|
200
|
-
- `setDeviceName()` renamed to `setName()`
|
|
201
|
-
- `subscribeToErrors()` callback now has param type (`HyperTrackError`)
|
|
202
|
-
- `getLocation` return type
|
|
203
|
-
- `LocationError` now has different structure
|
|
204
|
-
|
|
205
|
-
### Added
|
|
206
|
-
|
|
207
|
-
- `initialize()` configuration params for
|
|
208
|
-
- Debug logging
|
|
209
|
-
- Background location permissions request for Android
|
|
210
|
-
- Mock locations
|
|
211
|
-
- `subscribeToAvailability()`
|
|
212
|
-
|
|
213
|
-
### Removed
|
|
214
|
-
|
|
215
|
-
- `automaticallyRequestPermissions` param from `initialize()`
|
|
216
|
-
- `enableDebugLogging()` (use `initialize()` param `loggingEnabled` istead)
|
|
217
|
-
- `setTripMarker()` (use `addGeotag` instead)
|
|
218
|
-
|
|
219
|
-
## [8.2.2] - 2022-10-10
|
|
220
|
-
|
|
221
|
-
### Fixed
|
|
222
|
-
|
|
223
|
-
- Deployment target for iOS changed to 11, to comply with native iOS SDK.
|
|
224
|
-
|
|
225
|
-
## [8.2.1] - 2022-09-27
|
|
226
|
-
|
|
227
|
-
### Fixed
|
|
228
|
-
|
|
229
|
-
- `enableDebugLogging()` now doesn't cause an infinite loop when called.
|
|
230
|
-
|
|
231
|
-
## [8.2.0] - 2022-09-23
|
|
232
|
-
|
|
233
|
-
### Changed
|
|
234
|
-
|
|
235
|
-
- Updated Android SDK to 6.3.0 and iOS SDK to 4.13.0
|
|
236
|
-
- When the Android app is uninstalled completely from the device and then installed back, the device_id will change. This improves the stability of the data coming from the SDK. Now this behavior is the same between Android SDK and iOS SDK.
|
|
237
|
-
- If the user simulates locations when it's prohibited, the SDK still passes real locations through if there are any.
|
|
238
|
-
- Decreased the time sensitivity for first location detection. Results in fewer `location_unavailable` outages when tracking starts on Android.
|
|
239
|
-
|
|
240
|
-
### Fixed
|
|
241
|
-
|
|
242
|
-
- Now, all logs in Android SDK are disabled by default and can be enabled by enableDebugLogging()
|
|
243
|
-
|
|
244
|
-
## [8.1.0] - 2022-08-30
|
|
245
|
-
|
|
246
|
-
### Changed
|
|
247
|
-
|
|
248
|
-
- Updated Android SDK to 6.2.2 that is compabible with any native library (React Native C++) and reduces the SDK size too. SDK should now add only 4MB to the compressed app's size, when downloaded from Google Play instead of 17 MB on 8.0.0.
|
|
249
|
-
|
|
250
|
-
## [8.0.0] - 2022-08-05
|
|
251
|
-
|
|
252
|
-
### Added
|
|
253
|
-
|
|
254
|
-
- New interface for listeners.
|
|
255
|
-
- Reference documentation.
|
|
256
|
-
- TypeScript support.
|
|
257
|
-
|
|
258
|
-
### Changed
|
|
259
|
-
|
|
260
|
-
- Updated React Native from 0.63.3 to 0.69.1
|
|
261
|
-
|
|
262
|
-
## [7.19.1] - 2022-07-27
|
|
263
|
-
|
|
264
|
-
### Fixed
|
|
265
|
-
|
|
266
|
-
- Fixed React Native C++ incompatibility issue with Android SDK 6.2.0
|
|
267
|
-
|
|
268
|
-
## [7.19.0] - 2022-07-18
|
|
269
|
-
|
|
270
|
-
### Changed
|
|
271
|
-
|
|
272
|
-
- Updated HyperTrack Android SDK to 6.2.0 and iOS SDK to 4.12.4
|
|
273
|
-
|
|
274
|
-
## [7.18.4] - 2022-06-15
|
|
275
|
-
|
|
276
|
-
### Changed
|
|
277
|
-
|
|
278
|
-
- Updated HyperTrack Android SDK to 6.1.4
|
|
279
|
-
|
|
280
|
-
## [7.18.3] - 2022-06-15
|
|
281
|
-
|
|
282
|
-
### Changed
|
|
283
|
-
|
|
284
|
-
- Updated HyperTrack Android SDK to 6.1.3
|
|
285
|
-
|
|
286
|
-
## [7.18.2] - 2022-06-13
|
|
287
|
-
|
|
288
|
-
### Changed
|
|
289
|
-
|
|
290
|
-
- Updated HyperTrack iOS SDK to 4.12.3
|
|
291
|
-
|
|
292
|
-
## [7.18.1] - 2022-06-10
|
|
293
|
-
|
|
294
|
-
### Changed
|
|
295
|
-
|
|
296
|
-
- Updated HyperTrack iOS SDK to 4.12.1 to fix a regression in tracking listener
|
|
297
|
-
|
|
298
|
-
## [7.18.0] - 2022-06-09
|
|
299
|
-
|
|
300
|
-
### Changed
|
|
301
|
-
|
|
302
|
-
- Updated HyperTrack Android SDK to 6.1.2 and iOS SDK to 4.12.0
|
|
303
|
-
|
|
304
|
-
## [7.17.0] - 2022-06-03
|
|
305
|
-
|
|
306
|
-
### Changed
|
|
307
|
-
|
|
308
|
-
- Updated HyperTrack Android SDK to 6.1.1
|
|
309
|
-
|
|
310
|
-
## [7.16.0] - 2022-05-03
|
|
311
|
-
|
|
312
|
-
### Changed
|
|
313
|
-
|
|
314
|
-
- Updated HyperTrack Android SDK to [6.0.4](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#604---2022-04-29)
|
|
315
|
-
|
|
316
|
-
## [7.16.0] - 2022-05-03
|
|
317
|
-
|
|
318
|
-
### Changed
|
|
319
|
-
|
|
320
|
-
- Updated HyperTrack Android SDK to [6.0.4](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#604---2022-04-29)
|
|
321
|
-
|
|
322
|
-
## [7.15.0] - 2022-04-29
|
|
323
|
-
|
|
324
|
-
### Added
|
|
325
|
-
|
|
326
|
-
- Current location getter returns either the current location of the device or an outage reason for why current location is unavailable.
|
|
327
|
-
|
|
328
|
-
## [7.14.0] - 2022-03-24
|
|
329
|
-
|
|
330
|
-
### Changed
|
|
331
|
-
|
|
332
|
-
- Updated HyperTrack Android SDK to [6.0.2](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#602---2022-03-18)
|
|
333
|
-
|
|
334
|
-
## [7.13.0] - 2022-01-05
|
|
335
|
-
|
|
336
|
-
### Changed
|
|
337
|
-
|
|
338
|
-
- Updated iOS SDK to [4.9.0](https://github.com/hypertrack/sdk-ios/blob/master/CHANGELOG.md#490---2022-01-05)
|
|
339
|
-
|
|
340
|
-
## [7.12.1] - 2021-11-11
|
|
341
|
-
|
|
342
|
-
### Changed
|
|
343
|
-
|
|
344
|
-
- Updated Android SDK to [5.4.5](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#545---2021-11-05)
|
|
345
|
-
|
|
346
|
-
## [7.12.0] - 2021-10-29
|
|
347
|
-
|
|
348
|
-
### Changed
|
|
349
|
-
|
|
350
|
-
- Updated Android SDK to [5.4.4](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#544---2021-10-29)
|
|
351
|
-
|
|
352
|
-
## [7.11.0] - 2021-10-28
|
|
353
|
-
|
|
354
|
-
### Changed
|
|
355
|
-
|
|
356
|
-
- Updated Android SDK to [5.4.3](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#543---2021-09-01)
|
|
357
|
-
|
|
358
|
-
## [7.10.0] - 2021-08-04
|
|
359
|
-
|
|
360
|
-
### Changed
|
|
361
|
-
|
|
362
|
-
- Updated Android SDK to [5.4.0](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#540---2021-08-04)
|
|
363
|
-
|
|
364
|
-
## [7.9.0] - 2021-07-07
|
|
365
|
-
|
|
366
|
-
### Changed
|
|
367
|
-
|
|
368
|
-
- Updated Android SDK to [v5.2.5](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#525---2021-07-02)
|
|
369
|
-
|
|
370
|
-
## [7.8.1] - 2021-06-11
|
|
371
|
-
|
|
372
|
-
### Fixed
|
|
373
|
-
|
|
374
|
-
- Accidently removed import added back.
|
|
375
|
-
|
|
376
|
-
## [7.8.0] - 2021-06-11
|
|
377
|
-
|
|
378
|
-
### Changed
|
|
379
|
-
|
|
380
|
-
- Updated Android SDK to [v5.2.2](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#522---2021-06-11)
|
|
381
|
-
|
|
382
|
-
## [7.7.0] - 2021-05-29
|
|
383
|
-
|
|
384
|
-
### Changed
|
|
385
|
-
|
|
386
|
-
- Updated Android SDK to [v5.1.0](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#510---2021-05-28)
|
|
387
|
-
|
|
388
|
-
## [7.6.0] - 2021-05-07
|
|
389
|
-
|
|
390
|
-
### Changed
|
|
391
|
-
|
|
392
|
-
- Updated Android SDK to [v4.12.0](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#4120---2021-05-07)
|
|
393
|
-
|
|
394
|
-
## [7.5.0] - 2021-04-26
|
|
395
|
-
|
|
396
|
-
### Changed
|
|
397
|
-
|
|
398
|
-
- Updated iOS SDK to [4.8.0](https://github.com/hypertrack/sdk-ios/blob/master/CHANGELOG.md#480---2021-04-22)
|
|
399
|
-
- Updated Android SDK to [v4.11.1](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#4111---2021-04-20)
|
|
400
|
-
|
|
401
|
-
## [7.4.0] - 2021-04-02
|
|
402
|
-
|
|
403
|
-
### Changed
|
|
404
|
-
|
|
405
|
-
- Updated Android SDK to [v4.11.0](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#4110---2021-03-30)
|
|
406
|
-
|
|
407
|
-
### Fixed
|
|
408
|
-
|
|
409
|
-
- SDK won't navigate to Settings showing "Select `Allow Always` option" snackbar on Android 11 and later.
|
|
410
|
-
|
|
411
|
-
## [7.3.0] - 2021-03-04
|
|
412
|
-
|
|
413
|
-
### Changed
|
|
414
|
-
|
|
415
|
-
- Updated Android SDK to [v4.10.0](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#4100---2021-02-22)
|
|
416
|
-
|
|
417
|
-
## [7.2.0] - 2020-12-23
|
|
418
|
-
|
|
419
|
-
### Changed
|
|
420
|
-
|
|
421
|
-
- Updated iOS SDK to [v4.7.0](https://github.com/hypertrack/sdk-ios/blob/master/CHANGELOG.md#470---2020-12-23)
|
|
422
|
-
|
|
423
|
-
### Fixed
|
|
424
|
-
|
|
425
|
-
- iOS plugin runtime error notification.
|
|
426
|
-
|
|
427
|
-
## [7.1.0] - 2020-11-17
|
|
428
|
-
|
|
429
|
-
### Changed
|
|
430
|
-
|
|
431
|
-
- Updated Anroid SDK to [v4.8.0](https://github.com/hypertrack/sdk-android/blob/master/CHANGELOG.md#480---2020-10-30)
|
|
432
|
-
- Updated iOS SDK to [v4.6.0](https://github.com/hypertrack/sdk-ios/blob/master/CHANGELOG.md#460---2020-11-09)
|
|
433
|
-
- Using React-Core on iOS (https://github.com/hypertrack/sdk-react-native/pull/19)
|
|
434
|
-
|
|
435
|
-
## [7.0.1] - 2020-10-07
|
|
436
|
-
|
|
437
|
-
### Fixed
|
|
438
|
-
|
|
439
|
-
- Added `hypertrack-sdk-react-native.podspec` to `package.json` file.
|
|
440
|
-
|
|
441
|
-
### Changed
|
|
442
|
-
|
|
443
|
-
- Updated iOS SDK to `4.5.1`.
|
|
444
|
-
|
|
445
|
-
## [7.0.0] - 2020-10-02
|
|
446
|
-
|
|
447
|
-
### Changed
|
|
448
|
-
|
|
449
|
-
- Updated react-native to version `0.63.3`.
|
|
450
|
-
- Updated Android SDK to `4.6.0`.
|
|
451
|
-
|
|
452
|
-
### Removed
|
|
453
|
-
|
|
454
|
-
- Remove startsTracking API from createInstance.
|
|
455
|
-
|
|
456
|
-
### API Diff
|
|
457
|
-
|
|
458
|
-
```diff
|
|
459
|
-
/**
|
|
460
|
-
* Initialize the HyperTrack SDK
|
|
461
|
-
* @param {string} publishableKey - A unique String that is used to identify your account with HyperTrack.
|
|
462
|
-
- * @param {boolean} startsTracking - Should the SDK start tracking immediately after initialization.
|
|
463
|
-
* @param {boolean} automaticallyRequestPermissions - If true, SDK automatically triggers location and motion activity permissions dialogs when tracking starts.
|
|
464
|
-
*/
|
|
465
|
-
- async createInstance(publishableKey, startsTracking = true, automaticallyRequestPermissions = true): Promise<HyperTrackAPI> {
|
|
466
|
-
- await HyperTrack.initialize(publishableKey, startsTracking, automaticallyRequestPermissions);
|
|
467
|
-
+ async createInstance(publishableKey, automaticallyRequestPermissions = true): Promise<HyperTrackAPI> {
|
|
468
|
-
+ await HyperTrack.initialize(publishableKey, false, automaticallyRequestPermissions);
|
|
469
|
-
return new HyperTrackAPI();
|
|
470
|
-
},
|
|
471
|
-
```
|
|
472
|
-
|
|
473
|
-
## [6.6.0] - 2020-07-24
|
|
474
|
-
|
|
475
|
-
### Changed
|
|
476
|
-
|
|
477
|
-
- Updated react-native to version `0.61.4`.
|
|
478
|
-
- Updated Android SDK to `4.5.2`.
|
|
479
|
-
|
|
480
|
-
## [6.5.1] - 2020-07-20
|
|
481
|
-
|
|
482
|
-
### Changed
|
|
483
|
-
|
|
484
|
-
- Updated Android SDK to `4.5.1`.
|
|
485
|
-
|
|
486
|
-
## [6.5.0] - 2020-07-16
|
|
487
|
-
|
|
488
|
-
### Changed
|
|
489
|
-
|
|
490
|
-
- Updated Android SDK to `4.5.0`.
|
|
491
|
-
|
|
492
|
-
## [6.4.0] - 2020-07-14
|
|
493
|
-
|
|
494
|
-
### Added
|
|
495
|
-
|
|
496
|
-
- Only send events when there are listeners in iOS wrapper.
|
|
497
|
-
|
|
498
|
-
### Changed
|
|
499
|
-
|
|
500
|
-
- Reject promise properly and with error code during iOS initialization.
|
|
501
|
-
|
|
502
|
-
### Fixed
|
|
503
|
-
|
|
504
|
-
- Fixed regression where syncDeviceSettings was removed from iOS SDK wrapper.
|
|
505
|
-
|
|
506
|
-
## [6.3.0] - 2020-07-13
|
|
507
|
-
|
|
508
|
-
### Changed
|
|
509
|
-
|
|
510
|
-
- Control permission dialogs on iOS.
|
|
511
|
-
|
|
512
|
-
### API Diff
|
|
513
|
-
|
|
514
|
-
```diff
|
|
515
|
-
/**
|
|
516
|
-
* Initialize the HyperTrack SDK
|
|
517
|
-
* @param {string} publishableKey - A unique String that is used to identify your account with HyperTrack.
|
|
518
|
-
* @param {bool} startsTracking - Should the SDK start tracking immediately after initialization.
|
|
519
|
-
+ * @param {boolean} automaticallyRequestPermissions - If true, SDK automatically triggers location and motion activity permissions dialogs when tracking starts.
|
|
520
|
-
*/
|
|
521
|
-
|
|
522
|
-
- async createInstance(publishableKey, startsTracking = true): Promise<HyperTrackAPI> {
|
|
523
|
-
+ async createInstance(publishableKey, startsTracking = true, automaticallyRequestPermissions = true): Promise<HyperTrackAPI> {
|
|
524
|
-
- await HyperTrack.initialize(publishableKey, startsTracking);
|
|
525
|
-
+ await HyperTrack.initialize(publishableKey, startsTracking, automaticallyRequestPermissions);
|
|
526
|
-
return new HyperTrackAPI();
|
|
527
|
-
},
|
|
528
|
-
```
|
|
529
|
-
|
|
530
|
-
## [6.2.2] - 2020-04-14
|
|
531
|
-
|
|
532
|
-
### Changed
|
|
533
|
-
|
|
534
|
-
- Updated Android dependency repos.
|
|
535
|
-
|
|
536
|
-
## [6.2.1] - 2020-01-08
|
|
537
|
-
|
|
538
|
-
### Added
|
|
539
|
-
|
|
540
|
-
- RN SDK wrapper now supports native iOS `4.0.x` SDK.
|
|
541
|
-
|
|
542
|
-
## [6.1.0] - 2019-09-30
|
|
543
|
-
|
|
544
|
-
### Added
|
|
545
|
-
|
|
546
|
-
- Adding sync device settings
|
|
547
|
-
- Updated Android SDK to `3.4.7`.
|
|
548
|
-
|
|
549
|
-
## [6.0.0] - 2019-09-17
|
|
550
|
-
|
|
551
|
-
### Changed
|
|
552
|
-
|
|
553
|
-
- Updated interface with promises and split name and metadata
|
|
554
|
-
- Updated react-native to version `0.59.9`.
|
|
555
|
-
|
|
556
|
-
## [5.0.5] - 2019-08-29
|
|
557
|
-
|
|
558
|
-
### Changed
|
|
559
|
-
|
|
560
|
-
- Updated Android SDK to `3.4.5`.
|
|
561
|
-
|
|
562
|
-
## [5.0.4] - 2019-08-23
|
|
563
|
-
|
|
564
|
-
### Changed
|
|
565
|
-
|
|
566
|
-
- Updated Android SDK to `3.3.4` and stop tracking events.
|
|
567
|
-
|
|
568
|
-
## [5.0.3] - 2019-08-22
|
|
569
|
-
|
|
570
|
-
### Added
|
|
571
|
-
|
|
572
|
-
- Make deviceID change with publishable key.
|
|
573
|
-
|
|
574
|
-
## [5.0.2] - 2019-08-15
|
|
575
|
-
|
|
576
|
-
### Fixed
|
|
577
|
-
|
|
578
|
-
- Fixed Android wrapper permissions handling in initialize and startTracking.
|
|
579
|
-
|
|
580
|
-
## [5.0.1] - 2019-08-15
|
|
581
|
-
|
|
582
|
-
### Added
|
|
583
|
-
|
|
584
|
-
- Expose critical errors and update the integration.
|
|
585
|
-
|
|
586
|
-
## [4.1.1] - 2019-08-08
|
|
587
|
-
|
|
588
|
-
### Changed
|
|
589
|
-
|
|
590
|
-
- Bump Android SDK version to `3.3.1`.
|
|
591
|
-
|
|
592
|
-
## [4.1.0] - 2019-08-07
|
|
593
|
-
|
|
594
|
-
### Changed
|
|
595
|
-
|
|
596
|
-
- Make `getDeviceID` consistent between Android and iOS wrappers.
|
|
597
|
-
|
|
598
|
-
## [4.0.2] - 2019-08-06
|
|
599
|
-
|
|
600
|
-
### Fixed
|
|
601
|
-
|
|
602
|
-
- Fixed null context exception in Android wrapper.
|
|
603
|
-
|
|
604
|
-
## [4.0.1] - 2019-07-29
|
|
605
|
-
|
|
606
|
-
### Added
|
|
607
|
-
|
|
608
|
-
- Added an option to start tracking right after initialization.
|
|
609
|
-
|
|
610
|
-
### API Diff
|
|
611
|
-
|
|
612
|
-
```diff
|
|
613
|
-
/**
|
|
614
|
-
* Initialize the HyperTrack SDK
|
|
615
|
-
* @param {string} publishableKey - A unique String that is used to identify your account with HyperTrack.
|
|
616
|
-
+ * @param {bool} startsTracking - Should the SDK start tracking immediately after initialization
|
|
617
|
-
*/
|
|
618
|
-
initialize(publishableKey) {
|
|
619
|
-
- RNHyperTrack.initialize(publishableKey);
|
|
620
|
-
+ RNHyperTrack.initialize(publishableKey, startsTracking);
|
|
621
|
-
},
|
|
622
|
-
```
|
|
623
|
-
|
|
624
|
-
## [3.0.0] - 2019-07-23
|
|
625
|
-
|
|
626
|
-
### Added
|
|
627
|
-
|
|
628
|
-
- Backups key for Android SDK
|
|
629
|
-
|
|
630
|
-
### Changed
|
|
631
|
-
|
|
632
|
-
- Bump Android SDK version to 3.3.0 and switch to trip markers for native calls.
|
|
633
|
-
|
|
634
|
-
## [2.0.0] - 2019-07-17
|
|
635
|
-
|
|
636
|
-
### Deprecated
|
|
637
|
-
|
|
638
|
-
- `sendCustomEvent` was renamed to `setTripMarker`.
|
|
639
|
-
|
|
640
|
-
## [1.0.2] - 2019-07-04
|
|
641
|
-
|
|
642
|
-
### Added
|
|
643
|
-
|
|
644
|
-
- Added silent push notifications.
|
|
645
|
-
|
|
646
|
-
## [1.0.1] - 2019-06-26
|
|
647
|
-
|
|
648
|
-
### Added
|
|
649
|
-
|
|
650
|
-
- Added HyperTrack repository to repos list.
|
|
651
|
-
|
|
652
|
-
## [1.0.0] - 2019-06-07
|
|
653
|
-
|
|
654
|
-
Initial release.
|
|
655
|
-
|
|
656
|
-
[1.0.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/1.0.0
|
|
657
|
-
[1.0.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/1.0.1
|
|
658
|
-
[1.0.2]: https://github.com/hypertrack/sdk-react-native/releases/tag/1.0.2
|
|
659
|
-
[2.0.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/2.0.0
|
|
660
|
-
[3.0.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/3.0.0
|
|
661
|
-
[4.0.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/4.0.1
|
|
662
|
-
[4.0.2]: https://github.com/hypertrack/sdk-react-native/releases/tag/4.0.2
|
|
663
|
-
[4.1.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/4.1.0
|
|
664
|
-
[4.1.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/4.1.1
|
|
665
|
-
[5.0.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/5.0.1
|
|
666
|
-
[5.0.2]: https://github.com/hypertrack/sdk-react-native/releases/tag/5.0.2
|
|
667
|
-
[5.0.3]: https://github.com/hypertrack/sdk-react-native/releases/tag/5.0.3
|
|
668
|
-
[5.0.4]: https://github.com/hypertrack/sdk-react-native/releases/tag/5.0.4
|
|
669
|
-
[5.0.5]: https://github.com/hypertrack/sdk-react-native/releases/tag/5.0.5
|
|
670
|
-
[6.0.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/6.0.0
|
|
671
|
-
[6.1.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/6.1.0
|
|
672
|
-
[6.2.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/6.2.1
|
|
673
|
-
[6.2.2]: https://github.com/hypertrack/sdk-react-native/releases/tag/6.2.2
|
|
674
|
-
[6.3.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/6.3.0
|
|
675
|
-
[6.4.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/6.4.0
|
|
676
|
-
[6.5.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/6.5.0
|
|
677
|
-
[6.5.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/6.5.1
|
|
678
|
-
[6.6.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/6.6.0
|
|
679
|
-
[7.0.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.0.0
|
|
680
|
-
[7.0.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.0.1
|
|
681
|
-
[7.1.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.1.0
|
|
682
|
-
[7.2.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.2.0
|
|
683
|
-
[7.3.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.3.0
|
|
684
|
-
[7.4.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.4.0
|
|
685
|
-
[7.5.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.5.0
|
|
686
|
-
[7.6.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.6.0
|
|
687
|
-
[7.7.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.7.0
|
|
688
|
-
[7.8.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.8.0
|
|
689
|
-
[7.8.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.8.1
|
|
690
|
-
[7.9.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.9.0
|
|
691
|
-
[7.10.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.10.0
|
|
692
|
-
[7.11.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.11.0
|
|
693
|
-
[7.12.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.12.0
|
|
694
|
-
[7.12.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.12.1
|
|
695
|
-
[7.13.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.13.0
|
|
696
|
-
[7.14.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.14.0
|
|
697
|
-
[7.15.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.15.0
|
|
698
|
-
[7.16.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.16.0
|
|
699
|
-
[7.17.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.17.0
|
|
700
|
-
[7.18.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.18.0
|
|
701
|
-
[7.18.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.18.1
|
|
702
|
-
[7.18.2]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.18.2
|
|
703
|
-
[7.18.3]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.18.3
|
|
704
|
-
[7.18.4]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.18.4
|
|
705
|
-
[7.19.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.19.0
|
|
706
|
-
[7.19.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/7.19.1
|
|
707
|
-
[8.0.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/8.0.0
|
|
708
|
-
[8.1.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/8.1.0
|
|
709
|
-
[8.2.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/8.2.0
|
|
710
|
-
[8.2.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/8.2.1
|
|
711
|
-
[8.2.2]: https://github.com/hypertrack/sdk-react-native/releases/tag/8.2.2
|
|
712
|
-
[9.0.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/9.0.0
|
|
713
|
-
[9.1.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/9.1.0
|
|
714
|
-
[9.1.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/9.1.1
|
|
715
|
-
[9.2.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/9.2.0
|
|
716
|
-
[9.2.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/9.2.1
|
|
717
|
-
[9.2.2]: https://github.com/hypertrack/sdk-react-native/releases/tag/9.2.2
|
|
718
|
-
[10.0.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/10.0.0
|
|
719
|
-
[10.0.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/10.0.1
|
|
720
|
-
[10.0.2]: https://github.com/hypertrack/sdk-react-native/releases/tag/10.0.2
|
|
721
|
-
[10.0.3]: https://github.com/hypertrack/sdk-react-native/releases/tag/10.0.3
|
|
722
|
-
[11.0.0]: https://github.com/hypertrack/sdk-react-native/releases/tag/11.0.0
|
|
723
|
-
[11.0.1]: https://github.com/hypertrack/sdk-react-native/releases/tag/11.0.1
|
|
724
|
-
[11.0.2]: https://github.com/hypertrack/sdk-react-native/releases/tag/11.0.2
|
|
725
|
-
[11.0.3]: https://github.com/hypertrack/sdk-react-native/releases/tag/11.0.3
|
|
726
|
-
[11.0.4]: https://github.com/hypertrack/sdk-react-native/releases/tag/11.0.4
|
|
727
|
-
[11.0.5]: https://github.com/hypertrack/sdk-react-native/releases/tag/11.0.5
|
|
728
|
-
[11.0.6]: https://github.com/hypertrack/sdk-react-native/releases/tag/11.0.6
|
|
729
|
-
[11.0.7]: https://github.com/hypertrack/sdk-react-native/releases/tag/11.0.7
|
|
730
|
-
[11.0.8]: https://github.com/hypertrack/sdk-react-native/releases/tag/11.0.8
|
|
731
|
-
[11.0.9]: https://github.com/hypertrack/sdk-react-native/releases/tag/11.0.9
|
|
732
|
-
[11.0.10]: https://github.com/hypertrack/sdk-react-native/releases/tag/11.0.10
|
|
733
|
-
[11.0.11]: https://github.com/hypertrack/sdk-react-native/releases/tag/11.0.11
|
package/CONTRIBUTING.md
DELETED
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
# Contributing
|
|
2
|
-
|
|
3
|
-
## FAQ
|
|
4
|
-
|
|
5
|
-
### How to update the HyperTrack SDK version and make a release?
|
|
6
|
-
|
|
7
|
-
1. Update SDK version constant
|
|
8
|
-
|
|
9
|
-
- android
|
|
10
|
-
- [android/gradle.properties](android/gradle.properties)
|
|
11
|
-
- HyperTrackSdk_HyperTrackSDKVersion
|
|
12
|
-
- ios
|
|
13
|
-
- [hypertrack-sdk-react-native.podspec](hypertrack-sdk-react-native.podspec)
|
|
14
|
-
- s.dependency 'HyperTrack', '**version**'
|
|
15
|
-
|
|
16
|
-
2. Increment wrapper version
|
|
17
|
-
|
|
18
|
-
- [package.json](package.json)
|
|
19
|
-
- version
|
|
20
|
-
|
|
21
|
-
3. Update [CHANGELOG](CHANGELOG.md)
|
|
22
|
-
|
|
23
|
-
- **Add the release link to the bottom**
|
|
24
|
-
|
|
25
|
-
4. Update badge in [README](README.md)
|
|
26
|
-
5. Do the release dry run with `just release` and verify that the release is correct (checklist is in the command output)
|
|
27
|
-
6. Commit and merge to master
|
|
28
|
-
7. Create a Github repo release
|
|
29
|
-
- Release title should be the current version tag
|
|
30
|
-
8. Run `npm publish` to publish the package to npm
|
|
31
|
-
|
|
32
|
-
### How to change build config
|
|
33
|
-
|
|
34
|
-
#### Android
|
|
35
|
-
|
|
36
|
-
Change Android build config in `android/gradle.properties`
|
|
37
|
-
|
|
38
|
-
## Development workflow
|
|
39
|
-
|
|
40
|
-
To get started with the project, run `yarn` in the root directory to install the required dependencies for each package:
|
|
41
|
-
|
|
42
|
-
```sh
|
|
43
|
-
yarn
|
|
44
|
-
```
|
|
45
|
-
|
|
46
|
-
> While it's possible to use [`npm`](https://github.com/npm/cli), the tooling is built around [`yarn`](https://classic.yarnpkg.com/), so you'll have an easier time if you use `yarn` for development.
|
|
47
|
-
|
|
48
|
-
Make sure your code passes TypeScript and ESLint. Run the following to verify:
|
|
49
|
-
|
|
50
|
-
```sh
|
|
51
|
-
yarn typescript
|
|
52
|
-
yarn lint
|
|
53
|
-
```
|
|
54
|
-
|
|
55
|
-
To fix formatting errors, run the following:
|
|
56
|
-
|
|
57
|
-
```sh
|
|
58
|
-
yarn lint --fix
|
|
59
|
-
```
|
|
60
|
-
|
|
61
|
-
### Linting and tests
|
|
62
|
-
|
|
63
|
-
[ESLint](https://eslint.org/), [Prettier](https://prettier.io/), [TypeScript](https://www.typescriptlang.org/)
|
|
64
|
-
|
|
65
|
-
We use [TypeScript](https://www.typescriptlang.org/) for type checking, [ESLint](https://eslint.org/) with [Prettier](https://prettier.io/) for linting and formatting the code, and [Jest](https://jestjs.io/) for testing.
|
|
66
|
-
|
|
67
|
-
### Sending a pull request
|
|
68
|
-
|
|
69
|
-
> **Working on your first pull request?** You can learn how from this _free_ series: [How to Contribute to an Open Source Project on GitHub](https://app.egghead.io/playlists/how-to-contribute-to-an-open-source-project-on-github).
|
|
70
|
-
|
|
71
|
-
When you're sending a pull request:
|
|
72
|
-
|
|
73
|
-
- Prefer small pull requests focused on one change.
|
|
74
|
-
- Verify that linters and tests are passing.
|
|
75
|
-
- Review the documentation to make sure it looks good.
|
|
76
|
-
- Follow the pull request template when opening a pull request.
|
|
77
|
-
- For pull requests that change the API or implementation, discuss with maintainers first by opening an issue.
|
package/LICENSE
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2023 HyperTrack
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
Binary file
|
|
Binary file
|
|
File without changes
|
|
Binary file
|
|
File without changes
|