@pagopa/io-react-native-iso18013 0.2.0 → 0.4.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 +1 -1
- package/android/src/main/java/com/ioreactnativeiso18013/IoReactNativeCborModule.kt +67 -164
- package/android/src/main/java/com/ioreactnativeiso18013/IoReactNativeIso18013Module.kt +102 -146
- package/ios/Base64Utils.swift +10 -3
- package/ios/IoReactNativeCbor.swift +55 -125
- package/ios/IoReactNativeIso18013.swift +88 -117
- package/lib/module/cbor/cbor/README.md +37 -5
- package/lib/module/cbor/cbor/error.js +15 -0
- package/lib/module/cbor/cbor/error.js.map +1 -0
- package/lib/module/cbor/cbor/index.js +1 -0
- package/lib/module/cbor/cbor/index.js.map +1 -1
- package/lib/module/cbor/cose/README.md +39 -9
- package/lib/module/cbor/cose/error.js +17 -0
- package/lib/module/cbor/cose/error.js.map +1 -0
- package/lib/module/cbor/cose/index.js +1 -0
- package/lib/module/cbor/cose/index.js.map +1 -1
- package/lib/module/cbor/index.js +1 -1
- package/lib/module/cbor/index.js.map +1 -1
- package/lib/module/iso18013/index.js +2 -3
- package/lib/module/iso18013/index.js.map +1 -1
- package/lib/module/iso18013/iso18013-5/README.md +52 -16
- package/lib/module/iso18013/iso18013-5/error.js +25 -0
- package/lib/module/iso18013/iso18013-5/error.js.map +1 -0
- package/lib/module/iso18013/iso18013-5/index.js +3 -2
- package/lib/module/iso18013/iso18013-5/index.js.map +1 -1
- package/lib/module/iso18013/iso18013-5/proximity.js +10 -18
- package/lib/module/iso18013/iso18013-5/proximity.js.map +1 -1
- package/lib/module/iso18013/iso18013-5/{schema.js → request.js} +1 -20
- package/lib/module/iso18013/iso18013-5/request.js.map +1 -0
- package/lib/module/iso18013/iso18013-7/README.md +38 -9
- package/lib/module/iso18013/iso18013-7/error.js +15 -0
- package/lib/module/iso18013/iso18013-7/error.js.map +1 -0
- package/lib/module/iso18013/iso18013-7/index.js +1 -0
- package/lib/module/iso18013/iso18013-7/index.js.map +1 -1
- package/lib/module/iso18013/iso18013-7/remote.js +2 -14
- package/lib/module/iso18013/iso18013-7/remote.js.map +1 -1
- package/lib/module/schema.js +46 -0
- package/lib/module/schema.js.map +1 -0
- package/lib/typescript/src/cbor/cbor/error.d.ts +68 -0
- package/lib/typescript/src/cbor/cbor/error.d.ts.map +1 -0
- package/lib/typescript/src/cbor/cbor/index.d.ts +1 -1
- package/lib/typescript/src/cbor/cbor/index.d.ts.map +1 -1
- package/lib/typescript/src/cbor/cose/error.d.ts +68 -0
- package/lib/typescript/src/cbor/cose/error.d.ts.map +1 -0
- package/lib/typescript/src/cbor/cose/index.d.ts +1 -1
- package/lib/typescript/src/cbor/cose/index.d.ts.map +1 -1
- package/lib/typescript/src/iso18013/index.d.ts +1 -2
- package/lib/typescript/src/iso18013/index.d.ts.map +1 -1
- package/lib/typescript/src/iso18013/iso18013-5/error.d.ts +73 -0
- package/lib/typescript/src/iso18013/iso18013-5/error.d.ts.map +1 -0
- package/lib/typescript/src/iso18013/iso18013-5/index.d.ts +3 -2
- package/lib/typescript/src/iso18013/iso18013-5/index.d.ts.map +1 -1
- package/lib/typescript/src/iso18013/iso18013-5/proximity.d.ts +2 -7
- package/lib/typescript/src/iso18013/iso18013-5/proximity.d.ts.map +1 -1
- package/lib/typescript/src/iso18013/iso18013-5/{schema.d.ts → request.d.ts} +1 -16
- package/lib/typescript/src/iso18013/iso18013-5/request.d.ts.map +1 -0
- package/lib/typescript/src/iso18013/iso18013-7/error.d.ts +68 -0
- package/lib/typescript/src/iso18013/iso18013-7/error.d.ts.map +1 -0
- package/lib/typescript/src/iso18013/iso18013-7/index.d.ts +2 -1
- package/lib/typescript/src/iso18013/iso18013-7/index.d.ts.map +1 -1
- package/lib/typescript/src/iso18013/iso18013-7/remote.d.ts +0 -14
- package/lib/typescript/src/iso18013/iso18013-7/remote.d.ts.map +1 -1
- package/lib/typescript/src/schema.d.ts +76 -0
- package/lib/typescript/src/schema.d.ts.map +1 -0
- package/package.json +1 -1
- package/src/cbor/cbor/README.md +37 -5
- package/src/cbor/cbor/error.ts +23 -0
- package/src/cbor/cbor/index.ts +5 -1
- package/src/cbor/cose/README.md +39 -9
- package/src/cbor/cose/error.ts +23 -0
- package/src/cbor/cose/index.ts +5 -1
- package/src/cbor/index.ts +1 -1
- package/src/iso18013/index.ts +2 -9
- package/src/iso18013/iso18013-5/README.md +52 -16
- package/src/iso18013/iso18013-5/error.ts +35 -0
- package/src/iso18013/iso18013-5/index.ts +9 -4
- package/src/iso18013/iso18013-5/proximity.ts +11 -19
- package/src/iso18013/iso18013-5/{schema.ts → request.ts} +0 -20
- package/src/iso18013/iso18013-7/README.md +38 -9
- package/src/iso18013/iso18013-7/error.ts +21 -0
- package/src/iso18013/iso18013-7/index.ts +5 -4
- package/src/iso18013/iso18013-7/remote.ts +2 -22
- package/src/schema.ts +55 -0
- package/lib/module/cbor/cbor/failure.js +0 -2
- package/lib/module/cbor/cbor/failure.js.map +0 -1
- package/lib/module/cbor/cose/failure.js +0 -2
- package/lib/module/cbor/cose/failure.js.map +0 -1
- package/lib/module/iso18013/iso18013-5/schema.js.map +0 -1
- package/lib/typescript/src/cbor/cbor/failure.d.ts +0 -15
- package/lib/typescript/src/cbor/cbor/failure.d.ts.map +0 -1
- package/lib/typescript/src/cbor/cose/failure.d.ts +0 -15
- package/lib/typescript/src/cbor/cose/failure.d.ts.map +0 -1
- package/lib/typescript/src/iso18013/iso18013-5/schema.d.ts.map +0 -1
- package/src/cbor/cbor/failure.ts +0 -18
- package/src/cbor/cose/failure.ts +0 -20
|
@@ -42,12 +42,42 @@ try {
|
|
|
42
42
|
}
|
|
43
43
|
```
|
|
44
44
|
|
|
45
|
-
### Error
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
|
49
|
-
|
|
|
50
|
-
|
|
|
51
|
-
|
|
|
52
|
-
| THREADING_ERROR
|
|
53
|
-
|
|
45
|
+
### Error
|
|
46
|
+
|
|
47
|
+
This table contains the list of error codes that can be thrown by the `COSE` module which are mapped via the `ModuleErrorCodes` type:
|
|
48
|
+
| Type | Platform | Description |
|
|
49
|
+
| -------------------------- | ----------- | ------------------------------------------------------------ |
|
|
50
|
+
| SIGN_ERROR | Android/iOS | An error occurred while signing the data |
|
|
51
|
+
| VERIFY_ERROR | Android/iOS | An error occurred while verifying the signature |
|
|
52
|
+
| THREADING_ERROR | iOS | An error occurred while performing the sign operation in background |
|
|
53
|
+
|
|
54
|
+
An error can be parsed using the `ModuleErrorSchema` with type `ModuleErrorCodes` exposed by the `COSE` module. The error can be parsed as follows:
|
|
55
|
+
|
|
56
|
+
```typescript
|
|
57
|
+
import { COSE } from '@pagopa/io-react-native-iso18013';
|
|
58
|
+
try {
|
|
59
|
+
await COSE.func();
|
|
60
|
+
} catch (error) {
|
|
61
|
+
const parsedError = COSE.ModuleErrorSchema.parse(error); // Or ModuleErrorSchema.safeParse(error) for safe parsing
|
|
62
|
+
console.log(JSON.stringify(parsedError, null, 2));
|
|
63
|
+
}
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
The parsed object will contain properties from both iOS and Android platforms:
|
|
67
|
+
|
|
68
|
+
```typescript
|
|
69
|
+
{
|
|
70
|
+
code: string; // Defined in ModuleErrorCodes
|
|
71
|
+
message: string;
|
|
72
|
+
name: string;
|
|
73
|
+
userInfo?: Record<string, any> | null;
|
|
74
|
+
nativeStackAndroid?: Array<{
|
|
75
|
+
lineNumber: number;
|
|
76
|
+
file: string;
|
|
77
|
+
methodName: string;
|
|
78
|
+
class: string;
|
|
79
|
+
}>;
|
|
80
|
+
domain?: string;
|
|
81
|
+
nativeStackIOS?: Array<string>;
|
|
82
|
+
};
|
|
83
|
+
```
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import z from 'zod';
|
|
4
|
+
import { GenericModuleErrorSchema } from "../../schema.js";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Error codes which the COSE module uses to reject a promise.
|
|
8
|
+
*/
|
|
9
|
+
const ModuleErrorCodesSchema = z.enum(['SIGN_ERROR', 'VERIFY_ERROR', 'THREADING_ERROR',
|
|
10
|
+
// iOS only
|
|
11
|
+
'EUNSPECIFIED' // Android only default when no other error is specified
|
|
12
|
+
]);
|
|
13
|
+
/**
|
|
14
|
+
* Schema which can be used to parse a rejected promise error by the COSE module.
|
|
15
|
+
*/
|
|
16
|
+
export const ModuleErrorSchema = GenericModuleErrorSchema(ModuleErrorCodesSchema);
|
|
17
|
+
//# sourceMappingURL=error.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["z","GenericModuleErrorSchema","ModuleErrorCodesSchema","enum","ModuleErrorSchema"],"sourceRoot":"../../../../src","sources":["cbor/cose/error.ts"],"mappings":";;AAAA,OAAOA,CAAC,MAAM,KAAK;AACnB,SAASC,wBAAwB,QAAQ,iBAAc;;AAEvD;AACA;AACA;AACA,MAAMC,sBAAsB,GAAGF,CAAC,CAACG,IAAI,CAAC,CACpC,YAAY,EACZ,cAAc,EACd,iBAAiB;AAAE;AACnB,cAAc,CAAE;AAAA,CACjB,CAAC;AAIF;AACA;AACA;AACA,OAAO,MAAMC,iBAAiB,GAAGH,wBAAwB,CACvDC,sBACF,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["sign","verify"],"sourceRoot":"../../../../src","sources":["cbor/cose/index.ts"],"mappings":";;AAAA,SAASA,IAAI,EAAEC,MAAM,QAAQ,WAAQ","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["sign","verify","ModuleErrorSchema"],"sourceRoot":"../../../../src","sources":["cbor/cose/index.ts"],"mappings":";;AAAA,SAASA,IAAI,EAAEC,MAAM,QAAQ,WAAQ;AACrC,SAGEC,iBAAiB,QACZ,YAAS","ignoreList":[]}
|
package/lib/module/cbor/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
import { NativeModules, Platform } from 'react-native';
|
|
4
|
-
const LINKING_ERROR = `The package '@pagopa/io-react-native-
|
|
4
|
+
const LINKING_ERROR = `The package '@pagopa/io-react-native-iso18013' (IoReactNativeCbor) doesn't seem to be linked. Make sure: \n\n` + Platform.select({
|
|
5
5
|
ios: "- You have run 'pod install'\n",
|
|
6
6
|
default: ''
|
|
7
7
|
}) + '- You rebuilt the app after installing the package\n' + '- You are not using Expo Go\n';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["NativeModules","Platform","LINKING_ERROR","select","ios","default","IoReactNativeCbor","Proxy","get","Error"],"sourceRoot":"../../../src","sources":["cbor/index.ts"],"mappings":";;AAAA,SAASA,aAAa,EAAEC,QAAQ,QAAQ,cAAc;AAEtD,MAAMC,aAAa,GACjB,
|
|
1
|
+
{"version":3,"names":["NativeModules","Platform","LINKING_ERROR","select","ios","default","IoReactNativeCbor","Proxy","get","Error"],"sourceRoot":"../../../src","sources":["cbor/index.ts"],"mappings":";;AAAA,SAASA,aAAa,EAAEC,QAAQ,QAAQ,cAAc;AAEtD,MAAMC,aAAa,GACjB,+GAA+G,GAC/GD,QAAQ,CAACE,MAAM,CAAC;EAAEC,GAAG,EAAE,gCAAgC;EAAEC,OAAO,EAAE;AAAG,CAAC,CAAC,GACvE,sDAAsD,GACtD,+BAA+B;AAEjC,OAAO,MAAMC,iBAAiB,GAAGN,aAAa,CAACM,iBAAiB,GAC5DN,aAAa,CAACM,iBAAiB,GAC/B,IAAIC,KAAK,CACP,CAAC,CAAC,EACF;EACEC,GAAGA,CAAA,EAAG;IACJ,MAAM,IAAIC,KAAK,CAACP,aAAa,CAAC;EAChC;AACF,CACF,CAAC","ignoreList":[]}
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
import { NativeModules, Platform } from 'react-native';
|
|
4
|
-
|
|
5
|
-
const LINKING_ERROR = `The package '@pagopa/io-react-native-proximity' doesn't seem to be linked. Make sure: \n\n` + Platform.select({
|
|
4
|
+
const LINKING_ERROR = `The package '@pagopa/io-react-native-iso18013' (IoReactNativeIso18013) doesn't seem to be linked. Make sure: \n\n` + Platform.select({
|
|
6
5
|
ios: "- You have run 'pod install'\n",
|
|
7
6
|
default: ''
|
|
8
7
|
}) + '- You rebuilt the app after installing the package\n' + '- You are not using Expo Go\n';
|
|
9
|
-
export const
|
|
8
|
+
export const IoReactNativeIso18013 = NativeModules.IoReactNativeIso18013 ? NativeModules.IoReactNativeIso18013 : new Proxy({}, {
|
|
10
9
|
get() {
|
|
11
10
|
throw new Error(LINKING_ERROR);
|
|
12
11
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["NativeModules","Platform","
|
|
1
|
+
{"version":3,"names":["NativeModules","Platform","LINKING_ERROR","select","ios","default","IoReactNativeIso18013","Proxy","get","Error"],"sourceRoot":"../../../src","sources":["iso18013/index.ts"],"mappings":";;AAAA,SAASA,aAAa,EAAEC,QAAQ,QAAQ,cAAc;AAEtD,MAAMC,aAAa,GACjB,mHAAmH,GACnHD,QAAQ,CAACE,MAAM,CAAC;EAAEC,GAAG,EAAE,gCAAgC;EAAEC,OAAO,EAAE;AAAG,CAAC,CAAC,GACvE,sDAAsD,GACtD,+BAA+B;AAEjC,OAAO,MAAMC,qBAAqB,GAAGN,aAAa,CAACM,qBAAqB,GACpEN,aAAa,CAACM,qBAAqB,GACnC,IAAIC,KAAK,CACP,CAAC,CAAC,EACF;EACEC,GAAGA,CAAA,EAAG;IACJ,MAAM,IAAIC,KAAK,CAACP,aAAa,CAAC;EAChC;AACF,CACF,CAAC","ignoreList":[]}
|
|
@@ -18,14 +18,16 @@ This library emits the following events:
|
|
|
18
18
|
| onDeviceDisconnected | `undefined` | Event dispatched when the verifier app disconnects. |
|
|
19
19
|
| onError | `{ error: string } \| undefined` | Event dispatched when an error occurs which is contained in the error payload. It can be parsed via the `parseError` provided [here](src/schema.ts). |
|
|
20
20
|
|
|
21
|
-
Listeners can be added using the `addListener` method and removed using the `
|
|
21
|
+
Listeners can be added using the `addListener` method and removed by using the returned reference by calling the `remove` method.
|
|
22
22
|
|
|
23
23
|
```typescript
|
|
24
24
|
import { ISO18013_5 } from '@pagopa/io-react-native-iso18013';
|
|
25
25
|
|
|
26
|
-
ISO18013_5.addListener('event', () =>
|
|
26
|
+
const listener = ISO18013_5.addListener('event', () =>
|
|
27
|
+
console.log('event occurred')
|
|
28
|
+
);
|
|
27
29
|
|
|
28
|
-
|
|
30
|
+
listener.remove();
|
|
29
31
|
```
|
|
30
32
|
|
|
31
33
|
#### `onDeviceConnecting`
|
|
@@ -173,7 +175,7 @@ await ISO18013_5.sendErrorResponse({
|
|
|
173
175
|
|
|
174
176
|
Closes the QR engagement by releasing the resources allocated during the `start` method.
|
|
175
177
|
Before starting a new flow, it is necessary to call this method to ensure that the previous flow is properly closed.
|
|
176
|
-
|
|
178
|
+
Listeners can be added using the `addListener` method and removed using the `removeListener` method.
|
|
177
179
|
|
|
178
180
|
```typescript
|
|
179
181
|
import { ISO18013_5 } from '@pagopa/io-react-native-iso18013';
|
|
@@ -220,15 +222,49 @@ sequenceDiagram
|
|
|
220
222
|
proximity->>+app: Calls the onDeviceDisconnected callback
|
|
221
223
|
```
|
|
222
224
|
|
|
223
|
-
##
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
|
228
|
-
|
|
|
229
|
-
|
|
|
230
|
-
|
|
|
231
|
-
|
|
|
232
|
-
|
|
|
233
|
-
|
|
|
234
|
-
|
|
|
225
|
+
## Errors
|
|
226
|
+
|
|
227
|
+
This table contains the list of error codes that can be thrown by the `ISO18013_5` module which are mapped via the `ModuleErrorCodes` type:
|
|
228
|
+
|
|
229
|
+
| Type | Platform | Description |
|
|
230
|
+
| ------------------------- | ----------- | ---------------------------------------------------------------------------- |
|
|
231
|
+
| DRH_NOT_DEFINED | Android | The device retrieval helper hasn't been initialized, call the `start` method |
|
|
232
|
+
| QR_ENGAGEMENT_NOT_DEFINED | Android | The QR engagement hasn't been initialized, call the `start` method |
|
|
233
|
+
| START_ERROR | Android/iOS | An error occurred while initializing the required resources |
|
|
234
|
+
| GET_QR_CODE_ERROR | Android/iOS | An error occurred while generating the engagement QR code |
|
|
235
|
+
| SEND_RESPONSE_ERROR | Android/iOS | An error occurred while sending the response for the verifier app |
|
|
236
|
+
| SEND_ERROR_RESPONSE_ERROR | Android/iOS | An error occurred while sending the error response to the verifier app |
|
|
237
|
+
| GENERATE_RESPONSE_ERROR | Android/iOS | An error occurred while generating the response for the verifier app |
|
|
238
|
+
| CLOSE_ERROR | Android | An error occured while closing the required resources |
|
|
239
|
+
| EUNSPECIFIED | Android | Default error when no other error is specified |
|
|
240
|
+
|
|
241
|
+
An error can be parsed using the `ModuleErrorSchema` with type `ModuleErrorCodes` exposed by the `ISO18013_5` module. The error can be parsed as follows:
|
|
242
|
+
|
|
243
|
+
```typescript
|
|
244
|
+
import { ISO18013_5 } from '@pagopa/io-react-native-iso18013';
|
|
245
|
+
try {
|
|
246
|
+
await ISO18013_5.func();
|
|
247
|
+
} catch (error) {
|
|
248
|
+
const parsedError = ISO18013_5.ModuleErrorSchema.parse(error); // Or ModuleErrorSchema.safeParse(error) for safe parsing
|
|
249
|
+
console.log(JSON.stringify(parsedError, null, 2));
|
|
250
|
+
}
|
|
251
|
+
```
|
|
252
|
+
|
|
253
|
+
The parsed object will contain properties from both iOS and Android platforms:
|
|
254
|
+
|
|
255
|
+
```typescript
|
|
256
|
+
{
|
|
257
|
+
code: string; // Defined in ModuleErrorCodes
|
|
258
|
+
message: string;
|
|
259
|
+
name: string;
|
|
260
|
+
userInfo?: Record<string, any> | null;
|
|
261
|
+
nativeStackAndroid?: Array<{
|
|
262
|
+
lineNumber: number;
|
|
263
|
+
file: string;
|
|
264
|
+
methodName: string;
|
|
265
|
+
class: string;
|
|
266
|
+
}>;
|
|
267
|
+
domain?: string;
|
|
268
|
+
nativeStackIOS?: Array<string>;
|
|
269
|
+
};
|
|
270
|
+
```
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import z from 'zod';
|
|
4
|
+
import { GenericModuleErrorSchema } from "../../schema.js";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Schema for parsing the payload returned by the `onError` event in Proximity `Events`, along with its type definition.
|
|
8
|
+
*/
|
|
9
|
+
export const OnErrorPayloadSchema = z.string().catch('Unknown error');
|
|
10
|
+
/**
|
|
11
|
+
* Error codes which the ISO18013_5 module uses to reject a promise.
|
|
12
|
+
*/
|
|
13
|
+
const ModuleErrorCodesSchema = z.enum(['DRH_NOT_DEFINED',
|
|
14
|
+
// Android only
|
|
15
|
+
'QR_ENGAGEMENT_NOT_DEFINED',
|
|
16
|
+
// Android only
|
|
17
|
+
'START_ERROR', 'GET_QR_CODE_ERROR', 'SEND_RESPONSE_ERROR', 'SEND_ERROR_RESPONSE_ERROR', 'GENERATE_RESPONSE_ERROR', 'CLOSE_ERROR',
|
|
18
|
+
// Android only
|
|
19
|
+
'EUNSPECIFIED' // Android only default when no other error is specified
|
|
20
|
+
]);
|
|
21
|
+
/**
|
|
22
|
+
* Schema which can be used to parse a rejected promise error by the ISO18013_5 module.
|
|
23
|
+
*/
|
|
24
|
+
export const ModuleErrorSchema = GenericModuleErrorSchema(ModuleErrorCodesSchema);
|
|
25
|
+
//# sourceMappingURL=error.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["z","GenericModuleErrorSchema","OnErrorPayloadSchema","string","catch","ModuleErrorCodesSchema","enum","ModuleErrorSchema"],"sourceRoot":"../../../../src","sources":["iso18013/iso18013-5/error.ts"],"mappings":";;AAAA,OAAOA,CAAC,MAAM,KAAK;AACnB,SAASC,wBAAwB,QAAQ,iBAAc;;AAEvD;AACA;AACA;AACA,OAAO,MAAMC,oBAAoB,GAAGF,CAAC,CAACG,MAAM,CAAC,CAAC,CAACC,KAAK,CAAC,eAAe,CAAC;AAIrE;AACA;AACA;AACA,MAAMC,sBAAsB,GAAGL,CAAC,CAACM,IAAI,CAAC,CACpC,iBAAiB;AAAE;AACnB,2BAA2B;AAAE;AAC7B,aAAa,EACb,mBAAmB,EACnB,qBAAqB,EACrB,2BAA2B,EAC3B,yBAAyB,EACzB,aAAa;AAAE;AACf,cAAc,CAAE;AAAA,CACjB,CAAC;AAIF;AACA;AACA;AACA,OAAO,MAAMC,iBAAiB,GAAGN,wBAAwB,CACvDI,sBACF,CAAC","ignoreList":[]}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
export {
|
|
4
|
-
export {
|
|
3
|
+
export { parseVerifierRequest } from "./request.js";
|
|
4
|
+
export { OnErrorPayloadSchema, ModuleErrorSchema } from "./error.js";
|
|
5
|
+
export { ErrorCode, addListener, close, generateResponse, getQrCodeString, sendErrorResponse, sendResponse, start } from "./proximity.js";
|
|
5
6
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["parseVerifierRequest","OnErrorPayloadSchema","ModuleErrorSchema","ErrorCode","addListener","close","generateResponse","getQrCodeString","sendErrorResponse","sendResponse","start"],"sourceRoot":"../../../../src","sources":["iso18013/iso18013-5/index.ts"],"mappings":";;AAAA,SAGEA,oBAAoB,QACf,cAAW;AAElB,SAEEC,oBAAoB,EACpBC,iBAAiB,QAGZ,YAAS;AAEhB,SACEC,SAAS,EAGTC,WAAW,EACXC,KAAK,EACLC,gBAAgB,EAChBC,eAAe,EACfC,iBAAiB,EACjBC,YAAY,EACZC,KAAK,QACA,gBAAa","ignoreList":[]}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
import { NativeEventEmitter, Platform } from 'react-native';
|
|
4
|
-
import {
|
|
5
|
-
const eventEmitter = new NativeEventEmitter(
|
|
4
|
+
import { IoReactNativeIso18013 } from "../index.js";
|
|
5
|
+
const eventEmitter = new NativeEventEmitter(IoReactNativeIso18013);
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Events emitted by the native module:
|
|
@@ -44,9 +44,9 @@ export function start(config = {}) {
|
|
|
44
44
|
certificates
|
|
45
45
|
} = config;
|
|
46
46
|
if (Platform.OS === 'ios') {
|
|
47
|
-
return
|
|
47
|
+
return IoReactNativeIso18013.start(certificates ? certificates : []);
|
|
48
48
|
} else {
|
|
49
|
-
return
|
|
49
|
+
return IoReactNativeIso18013.start(peripheralMode ? peripheralMode : true, centralClientMode ? centralClientMode : false, clearBleCache ? clearBleCache : true, certificates ? certificates : []);
|
|
50
50
|
}
|
|
51
51
|
}
|
|
52
52
|
|
|
@@ -54,14 +54,14 @@ export function start(config = {}) {
|
|
|
54
54
|
* Gets the QR code string this method is responsible for initializing the connection and retrieving the QR code string
|
|
55
55
|
*/
|
|
56
56
|
export function getQrCodeString() {
|
|
57
|
-
return
|
|
57
|
+
return IoReactNativeIso18013.getQrCodeString();
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
/**
|
|
61
61
|
* Closes the QR engagement
|
|
62
62
|
*/
|
|
63
63
|
export function close() {
|
|
64
|
-
return
|
|
64
|
+
return IoReactNativeIso18013.close();
|
|
65
65
|
}
|
|
66
66
|
|
|
67
67
|
/**
|
|
@@ -70,7 +70,7 @@ export function close() {
|
|
|
70
70
|
* @param code - The error code to be sent to the verifier app.
|
|
71
71
|
*/
|
|
72
72
|
export function sendErrorResponse(code) {
|
|
73
|
-
return
|
|
73
|
+
return IoReactNativeIso18013.sendErrorResponse(code);
|
|
74
74
|
}
|
|
75
75
|
|
|
76
76
|
/**
|
|
@@ -80,7 +80,7 @@ export function sendErrorResponse(code) {
|
|
|
80
80
|
* @returns A base64 encoded response to be sent to the verifier app via `sendResponse`
|
|
81
81
|
*/
|
|
82
82
|
export function generateResponse(documents, acceptedFields) {
|
|
83
|
-
return
|
|
83
|
+
return IoReactNativeIso18013.generateResponse(documents, acceptedFields);
|
|
84
84
|
}
|
|
85
85
|
|
|
86
86
|
/**
|
|
@@ -89,7 +89,7 @@ export function generateResponse(documents, acceptedFields) {
|
|
|
89
89
|
* @param response - The base64 encoded response to be sent to the verifier app.
|
|
90
90
|
*/
|
|
91
91
|
export function sendResponse(response) {
|
|
92
|
-
return
|
|
92
|
+
return IoReactNativeIso18013.sendResponse(response);
|
|
93
93
|
}
|
|
94
94
|
|
|
95
95
|
/**
|
|
@@ -99,14 +99,6 @@ export function sendResponse(response) {
|
|
|
99
99
|
* @param callback - The callback to be called when the event is emitted. The callback will receive the event payload as an argument.
|
|
100
100
|
*/
|
|
101
101
|
export function addListener(event, callback) {
|
|
102
|
-
eventEmitter.addListener(event, callback);
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
/**
|
|
106
|
-
* Removes a listener for a `QrEngagementEvents` event.
|
|
107
|
-
* @param event - The event to remove the listener for. The available events are defined in the `QrEngagementEvents` type.
|
|
108
|
-
*/
|
|
109
|
-
export function removeListener(event) {
|
|
110
|
-
eventEmitter.removeAllListeners(event);
|
|
102
|
+
return eventEmitter.addListener(event, callback);
|
|
111
103
|
}
|
|
112
104
|
//# sourceMappingURL=proximity.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["NativeEventEmitter","Platform","
|
|
1
|
+
{"version":3,"names":["NativeEventEmitter","Platform","IoReactNativeIso18013","eventEmitter","ErrorCode","start","config","peripheralMode","centralClientMode","clearBleCache","certificates","OS","getQrCodeString","close","sendErrorResponse","code","generateResponse","documents","acceptedFields","sendResponse","response","addListener","event","callback"],"sourceRoot":"../../../../src","sources":["iso18013/iso18013-5/proximity.ts"],"mappings":";;AAAA,SAASA,kBAAkB,EAAEC,QAAQ,QAAQ,cAAc;AAE3D,SAASC,qBAAqB,QAAQ,aAAI;AAG1C,MAAMC,YAAY,GAAG,IAAIH,kBAAkB,CAACE,qBAAqB,CAAC;;AAElE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAUA;AACA;AACA;;AAGA;AACA;AACA;AACA;AACA;AACA,WAAYE,SAAS,0BAATA,SAAS;EAATA,SAAS,CAATA,SAAS;EAATA,SAAS,CAATA,SAAS;EAATA,SAAS,CAATA,SAAS;EAAA,OAATA,SAAS;AAAA;;AAMrB;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,KAAKA,CACnBC,MAKC,GAAG,CAAC,CAAC,EACY;EAClB,MAAM;IAAEC,cAAc;IAAEC,iBAAiB;IAAEC,aAAa;IAAEC;EAAa,CAAC,GACtEJ,MAAM;EACR,IAAIL,QAAQ,CAACU,EAAE,KAAK,KAAK,EAAE;IACzB,OAAOT,qBAAqB,CAACG,KAAK,CAACK,YAAY,GAAGA,YAAY,GAAG,EAAE,CAAC;EACtE,CAAC,MAAM;IACL,OAAOR,qBAAqB,CAACG,KAAK,CAChCE,cAAc,GAAGA,cAAc,GAAG,IAAI,EACtCC,iBAAiB,GAAGA,iBAAiB,GAAG,KAAK,EAC7CC,aAAa,GAAGA,aAAa,GAAG,IAAI,EACpCC,YAAY,GAAGA,YAAY,GAAG,EAChC,CAAC;EACH;AACF;;AAEA;AACA;AACA;AACA,OAAO,SAASE,eAAeA,CAAA,EAAoB;EACjD,OAAOV,qBAAqB,CAACU,eAAe,CAAC,CAAC;AAChD;;AAEA;AACA;AACA;AACA,OAAO,SAASC,KAAKA,CAAA,EAAqB;EACxC,OAAOX,qBAAqB,CAACW,KAAK,CAAC,CAAC;AACtC;;AAEA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,iBAAiBA,CAACC,IAAe,EAAoB;EACnE,OAAOb,qBAAqB,CAACY,iBAAiB,CAACC,IAAI,CAAC;AACtD;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,gBAAgBA,CAC9BC,SAAmC,EACnCC,cAA8B,EACb;EACjB,OAAOhB,qBAAqB,CAACc,gBAAgB,CAACC,SAAS,EAAEC,cAAc,CAAC;AAC1E;;AAEA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,YAAYA,CAACC,QAAgB,EAAoB;EAC/D,OAAOlB,qBAAqB,CAACiB,YAAY,CAACC,QAAQ,CAAC;AACrD;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,WAAWA,CACzBC,KAAQ,EACRC,QAA0C,EAC1C;EACA,OAAOpB,YAAY,CAACkB,WAAW,CAACC,KAAK,EAAEC,QAAQ,CAAC;AAClD","ignoreList":[]}
|
|
@@ -41,25 +41,6 @@ export const parseVerifierRequest = input => {
|
|
|
41
41
|
return VerifierRequest.parse(input);
|
|
42
42
|
};
|
|
43
43
|
|
|
44
|
-
/**
|
|
45
|
-
* Zod schema for the type returned by the `onError` event in Proximity `Events`.
|
|
46
|
-
*/
|
|
47
|
-
const EventError = z.string().catch('Unknown error');
|
|
48
|
-
|
|
49
|
-
/**
|
|
50
|
-
* Error type returned by the `onError` event in Proximity `Events`.
|
|
51
|
-
*/
|
|
52
|
-
|
|
53
|
-
/**
|
|
54
|
-
* Parses the input to an Error object.
|
|
55
|
-
* This function is used to parse the error received from the verifier app via the `onError` event.
|
|
56
|
-
* @param input - The input to be parsed
|
|
57
|
-
* @returns The parsed Error object or a default error message if parsing fails
|
|
58
|
-
*/
|
|
59
|
-
export const parseEventError = input => {
|
|
60
|
-
return EventError.parse(input);
|
|
61
|
-
};
|
|
62
|
-
|
|
63
44
|
/**
|
|
64
45
|
* This is the type definition for the accepted fields that will be presented to the verifier app.
|
|
65
46
|
* It contains of a nested object structure, where the outermost key represents the credential doctype.
|
|
@@ -76,4 +57,4 @@ export const parseEventError = input => {
|
|
|
76
57
|
* }
|
|
77
58
|
* }`
|
|
78
59
|
**/
|
|
79
|
-
//# sourceMappingURL=
|
|
60
|
+
//# sourceMappingURL=request.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["z","booleanFieldGroup","record","boolean","credentialEntrySchema","object","isAuthenticated","catchall","VerifierRequest","request","parseVerifierRequest","input","parse"],"sourceRoot":"../../../../src","sources":["iso18013/iso18013-5/request.ts"],"mappings":";;AAAA,SAASA,CAAC,QAAQ,KAAK;;AAEvB;AACA,MAAMC,iBAAiB,GAAGD,CAAC,CAACE,MAAM,CAACF,CAAC,CAACG,OAAO,CAAC,CAAC,CAAC;AAE/C,MAAMC,qBAAqB,GAAGJ,CAAC,CAC5BK,MAAM,CAAC;EACNC,eAAe,EAAEN,CAAC,CAACG,OAAO,CAAC;AAC7B,CAAC,CAAC,CACDI,QAAQ,CAACN,iBAAiB,CAAC;AAE9B,MAAMO,eAAe,GAAGR,CAAC,CAACK,MAAM,CAAC;EAC/BI,OAAO,EAAET,CAAC,CAACE,MAAM,CAACE,qBAAqB;AACzC,CAAC,CAAC;;AAEF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAGA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMM,oBAAoB,GAAIC,KAAc,IAAsB;EACvE,OAAOH,eAAe,CAACI,KAAK,CAACD,KAAK,CAAC;AACrC,CAAC;;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","ignoreList":[]}
|
|
@@ -48,12 +48,41 @@ export const generateOID4VPDeviceResponse = async (
|
|
|
48
48
|
) : Promise<string> => {...};
|
|
49
49
|
```
|
|
50
50
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
|
56
|
-
|
|
|
57
|
-
|
|
|
58
|
-
|
|
59
|
-
|
|
51
|
+
## Errors
|
|
52
|
+
|
|
53
|
+
This table contains the list of error codes that can be thrown by the `ISO18013_7` module which are mapped via the `ModuleErrorCodes` type:
|
|
54
|
+
|
|
55
|
+
| Type | Platform | Description |
|
|
56
|
+
| ------------------------------ | ----------- | ----------------------------------------------- |
|
|
57
|
+
| GENERATE_OID4VP_RESPONSE_ERROR | Android/iOS | An error occurred while generating the response |
|
|
58
|
+
|
|
59
|
+
An error can be parsed using the `ModuleErrorSchema` with type `ModuleErrorCodes` exposed by the `ISO18013_5` module. The error can be parsed as follows:
|
|
60
|
+
|
|
61
|
+
```typescript
|
|
62
|
+
import { ISO18013_7 } from '@pagopa/io-react-native-iso18013';
|
|
63
|
+
try {
|
|
64
|
+
await ISO18013_7.func();
|
|
65
|
+
} catch (error) {
|
|
66
|
+
const parsedError = ISO18013_7.ModuleErrorSchema.parse(error); // Or ModuleErrorSchema.safeParse(error) for safe parsing
|
|
67
|
+
console.log(JSON.stringify(parsedError, null, 2));
|
|
68
|
+
}
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
The parsed object will contain properties from both iOS and Android platforms:
|
|
72
|
+
|
|
73
|
+
```typescript
|
|
74
|
+
{
|
|
75
|
+
code: string; // Defined in ModuleErrorCodes
|
|
76
|
+
message: string;
|
|
77
|
+
name: string;
|
|
78
|
+
userInfo?: Record<string, any> | null;
|
|
79
|
+
nativeStackAndroid?: Array<{
|
|
80
|
+
lineNumber: number;
|
|
81
|
+
file: string;
|
|
82
|
+
methodName: string;
|
|
83
|
+
class: string;
|
|
84
|
+
}>;
|
|
85
|
+
domain?: string;
|
|
86
|
+
nativeStackIOS?: Array<string>;
|
|
87
|
+
};
|
|
88
|
+
```
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import z from 'zod';
|
|
4
|
+
import { GenericModuleErrorSchema } from "../../schema.js";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Error codes which the ISO18013_7 module uses to reject a promise.
|
|
8
|
+
*/
|
|
9
|
+
const ModuleErrorCodesSchema = z.enum(['GENERATE_OID4VP_RESPONSE_ERROR', 'EUNSPECIFIED' // Android only default when no other error is specified
|
|
10
|
+
]);
|
|
11
|
+
/**
|
|
12
|
+
* Schema which can be used to parse a rejected promise error by the ISO18013_7 module.
|
|
13
|
+
*/
|
|
14
|
+
export const ModuleErrorSchema = GenericModuleErrorSchema(ModuleErrorCodesSchema);
|
|
15
|
+
//# sourceMappingURL=error.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["z","GenericModuleErrorSchema","ModuleErrorCodesSchema","enum","ModuleErrorSchema"],"sourceRoot":"../../../../src","sources":["iso18013/iso18013-7/error.ts"],"mappings":";;AAAA,OAAOA,CAAC,MAAM,KAAK;AACnB,SAASC,wBAAwB,QAAQ,iBAAc;;AAEvD;AACA;AACA;AACA,MAAMC,sBAAsB,GAAGF,CAAC,CAACG,IAAI,CAAC,CACpC,gCAAgC,EAChC,cAAc,CAAE;AAAA,CACjB,CAAC;AAIF;AACA;AACA;AACA,OAAO,MAAMC,iBAAiB,GAAGH,wBAAwB,CACvDC,sBACF,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["generateOID4VPDeviceResponse"],"sourceRoot":"../../../../src","sources":["iso18013/iso18013-7/index.ts"],"mappings":";;AAAA,
|
|
1
|
+
{"version":3,"names":["generateOID4VPDeviceResponse","ModuleErrorSchema"],"sourceRoot":"../../../../src","sources":["iso18013/iso18013-7/index.ts"],"mappings":";;AAAA,SAASA,4BAA4B,QAAQ,aAAU;AACvD,SACEC,iBAAiB,QAGZ,YAAS","ignoreList":[]}
|
|
@@ -1,18 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* All error codes that the module could return.
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
/**
|
|
10
|
-
* Error type returned by a rejected promise.
|
|
11
|
-
*
|
|
12
|
-
* If additional error information are available,
|
|
13
|
-
* they are stored in the {@link OID4VPFailure["userInfo"]} field.
|
|
14
|
-
*/
|
|
15
|
-
|
|
3
|
+
import { IoReactNativeIso18013 } from "../index.js";
|
|
16
4
|
/**
|
|
17
5
|
*
|
|
18
6
|
* @param clientId extracted from OID4VP session
|
|
@@ -26,6 +14,6 @@ import { IoReactNativeProximity } from "../index.js";
|
|
|
26
14
|
* @returns the Device Response in CBOR format
|
|
27
15
|
*/
|
|
28
16
|
export const generateOID4VPDeviceResponse = async (clientId, responseUri, authorizationRequestNonce, mdocGeneratedNonce, documents, fieldRequestedAndAccepted) => {
|
|
29
|
-
return await
|
|
17
|
+
return await IoReactNativeIso18013.generateOID4VPDeviceResponse(clientId, responseUri, authorizationRequestNonce, mdocGeneratedNonce, documents, typeof fieldRequestedAndAccepted === 'string' ? fieldRequestedAndAccepted : JSON.stringify(fieldRequestedAndAccepted));
|
|
30
18
|
};
|
|
31
19
|
//# sourceMappingURL=remote.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["IoReactNativeIso18013","generateOID4VPDeviceResponse","clientId","responseUri","authorizationRequestNonce","mdocGeneratedNonce","documents","fieldRequestedAndAccepted","JSON","stringify"],"sourceRoot":"../../../../src","sources":["iso18013/iso18013-7/remote.ts"],"mappings":";;AAAA,SAASA,qBAAqB,QAAQ,aAAI;AAG1C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,4BAA4B,GAAG,MAAAA,CAC1CC,QAAgB,EAChBC,WAAmB,EACnBC,yBAAiC,EACjCC,kBAA0B,EAC1BC,SAAmC,EACnCC,yBAAuD,KACnC;EACpB,OAAO,MAAMP,qBAAqB,CAACC,4BAA4B,CAC7DC,QAAQ,EACRC,WAAW,EACXC,yBAAyB,EACzBC,kBAAkB,EAClBC,SAAS,EACT,OAAOC,yBAAyB,KAAK,QAAQ,GACzCA,yBAAyB,GACzBC,IAAI,CAACC,SAAS,CAACF,yBAAyB,CAC9C,CAAC;AACH,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { z } from 'zod';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Schema for parsing a nativeStackAndroid object of a rejected promise error in an Android native module.
|
|
7
|
+
*/
|
|
8
|
+
const StackTraceElementSchema = z.object({
|
|
9
|
+
lineNumber: z.number(),
|
|
10
|
+
file: z.string(),
|
|
11
|
+
methodName: z.string(),
|
|
12
|
+
class: z.string()
|
|
13
|
+
});
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Schema for parsing specific parameters of a rejected promise error in an Android native module.
|
|
17
|
+
* It's defined as partial to allow merging with the common schema and it must be checked at runtime.
|
|
18
|
+
*/
|
|
19
|
+
const ModuleErrorAndroidSchema = z.object({
|
|
20
|
+
nativeStackAndroid: z.array(StackTraceElementSchema)
|
|
21
|
+
}).partial();
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* Schema for parsing specific parameters of a rejected promise error in an iOS native module.
|
|
25
|
+
* It's defined as partial to allow merging with the common schema and it must be checked at runtime.
|
|
26
|
+
*/
|
|
27
|
+
const ModuleErrorIosSchema = z.object({
|
|
28
|
+
domain: z.string(),
|
|
29
|
+
nativeStackIOS: z.array(z.string())
|
|
30
|
+
}).partial();
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* Schema for parsing common parameters of a rejected promise error in a native module.
|
|
34
|
+
* This schema contains the common parameters that are shared across both Android and iOS native modules.
|
|
35
|
+
* Parameters which are platform specific are defined as optional and must be checked at runtime.
|
|
36
|
+
* It accepts a generic code schema to allow for different error codes which can be defined in each module.
|
|
37
|
+
* @param codeSchema - The Zod schema for the error codes used by the module.
|
|
38
|
+
* @returns A schema for the common parameters of a rejected promise error in a native module.
|
|
39
|
+
*/
|
|
40
|
+
export const GenericModuleErrorSchema = codeSchema => z.object({
|
|
41
|
+
code: codeSchema,
|
|
42
|
+
message: z.string(),
|
|
43
|
+
name: z.string(),
|
|
44
|
+
userInfo: z.record(z.string(), z.any()).optional().or(z.null())
|
|
45
|
+
}).and(ModuleErrorAndroidSchema).and(ModuleErrorIosSchema);
|
|
46
|
+
//# sourceMappingURL=schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["z","StackTraceElementSchema","object","lineNumber","number","file","string","methodName","class","ModuleErrorAndroidSchema","nativeStackAndroid","array","partial","ModuleErrorIosSchema","domain","nativeStackIOS","GenericModuleErrorSchema","codeSchema","code","message","name","userInfo","record","any","optional","or","null","and"],"sourceRoot":"../../src","sources":["schema.ts"],"mappings":";;AAAA,SAASA,CAAC,QAAQ,KAAK;;AAEvB;AACA;AACA;AACA,MAAMC,uBAAuB,GAAGD,CAAC,CAACE,MAAM,CAAC;EACvCC,UAAU,EAAEH,CAAC,CAACI,MAAM,CAAC,CAAC;EACtBC,IAAI,EAAEL,CAAC,CAACM,MAAM,CAAC,CAAC;EAChBC,UAAU,EAAEP,CAAC,CAACM,MAAM,CAAC,CAAC;EACtBE,KAAK,EAAER,CAAC,CAACM,MAAM,CAAC;AAClB,CAAC,CAAC;;AAEF;AACA;AACA;AACA;AACA,MAAMG,wBAAwB,GAAGT,CAAC,CAC/BE,MAAM,CAAC;EACNQ,kBAAkB,EAAEV,CAAC,CAACW,KAAK,CAACV,uBAAuB;AACrD,CAAC,CAAC,CACDW,OAAO,CAAC,CAAC;;AAEZ;AACA;AACA;AACA;AACA,MAAMC,oBAAoB,GAAGb,CAAC,CAC3BE,MAAM,CAAC;EACNY,MAAM,EAAEd,CAAC,CAACM,MAAM,CAAC,CAAC;EAClBS,cAAc,EAAEf,CAAC,CAACW,KAAK,CAACX,CAAC,CAACM,MAAM,CAAC,CAAC;AACpC,CAAC,CAAC,CACDM,OAAO,CAAC,CAAC;;AAEZ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMI,wBAAwB,GAGnCC,UAAoB,IAEpBjB,CAAC,CACEE,MAAM,CAAC;EACNgB,IAAI,EAAED,UAAU;EAChBE,OAAO,EAAEnB,CAAC,CAACM,MAAM,CAAC,CAAC;EACnBc,IAAI,EAAEpB,CAAC,CAACM,MAAM,CAAC,CAAC;EAChBe,QAAQ,EAAErB,CAAC,CAACsB,MAAM,CAACtB,CAAC,CAACM,MAAM,CAAC,CAAC,EAAEN,CAAC,CAACuB,GAAG,CAAC,CAAC,CAAC,CAACC,QAAQ,CAAC,CAAC,CAACC,EAAE,CAACzB,CAAC,CAAC0B,IAAI,CAAC,CAAC;AAChE,CAAC,CAAC,CACDC,GAAG,CAAClB,wBAAwB,CAAC,CAC7BkB,GAAG,CAACd,oBAAoB,CAAC","ignoreList":[]}
|