react-native-mesmart 1.0.0 → 1.0.1

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.
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sourceRoot":"../../../src","sources":["@types/index.ts"],"mappings":"","ignoreList":[]}
@@ -0,0 +1,6 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ //# sourceMappingURL=react-native.d.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sourceRoot":"../../../src","sources":["@types/react-native.d.ts"],"mappings":"","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sourceRoot":"../../../src","sources":["@types/index.ts"],"mappings":"","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=react-native.d.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sourceRoot":"../../../src","sources":["@types/react-native.d.ts"],"mappings":"","ignoreList":[]}
@@ -0,0 +1,7 @@
1
+ export type PaymentMethod = 'debitCard' | 'creditCard' | 'pix' | 'voucher' | 'money' | 'bonus';
2
+ export type * from './plugpag';
3
+ export type * from './paystore';
4
+ export type * from './sunmi';
5
+ export type * from './pax';
6
+ export type * from './stone';
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/@types/index.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,aAAa,GACrB,WAAW,GACX,YAAY,GACZ,KAAK,GACL,SAAS,GACT,OAAO,GACP,OAAO,CAAC;AAEZ,mBAAmB,WAAW,CAAC;AAC/B,mBAAmB,YAAY,CAAC;AAChC,mBAAmB,SAAS,CAAC;AAC7B,mBAAmB,OAAO,CAAC;AAC3B,mBAAmB,SAAS,CAAC"}
@@ -2,9 +2,9 @@ export declare const IOS_ERROR = "\u26A0\uFE0F The package 'react-native-mesmart
2
2
  declare const Plugpag: {
3
3
  init: (code: string) => Promise<null>;
4
4
  destroy: () => Promise<null>;
5
- pay: (value: string, paymentMethod: import("./@types/index.d.ts").PaymentMethod) => Promise<import("./@types/plugpag").PlugpagTransactionResult>;
5
+ pay: (value: string, paymentMethod: import("./@types").PaymentMethod) => Promise<import("./@types").PlugpagTransactionResult>;
6
6
  abortPayment: () => Promise<null>;
7
- resolveEvent: (data: import("./@types/plugpag").PlugpagEventData) => Promise<string>;
7
+ resolveEvent: (data: import("./@types").PlugpagEventData) => Promise<string>;
8
8
  isActivated: () => Promise<boolean>;
9
9
  };
10
10
  declare const Sunmi: {
@@ -27,19 +27,19 @@ declare const Pax: {
27
27
  };
28
28
  declare const Paystore: {
29
29
  init: () => Promise<null>;
30
- pay: (value: string, transactionId: string, showReceipt: boolean, paymentMethods: import("./@types/index.d.ts").PaymentMethod[], installments: number) => Promise<void>;
30
+ pay: (value: string, transactionId: string, showReceipt: boolean, paymentMethods: import("./@types").PaymentMethod[], installments: number) => Promise<void>;
31
31
  isActivated: () => Promise<boolean>;
32
32
  };
33
33
  declare const Stone: {
34
- init: (keys: import("./@types/stone").StoneKeys, appName: string) => Promise<null>;
34
+ init: (keys: import("./@types").StoneKeys, appName: string) => Promise<null>;
35
35
  isActivated: () => Promise<boolean>;
36
36
  getStoneCode: () => Promise<string>;
37
- pay: (value: string, paymentType: import("./@types/index.d.ts").PaymentMethod, isCapture: boolean) => Promise<import("./@types/stone").StoneTransaction>;
37
+ pay: (value: string, paymentType: import("./@types").PaymentMethod, isCapture: boolean) => Promise<import("./@types").StoneTransaction>;
38
38
  abortPayment: () => Promise<null>;
39
- printVia: (transaction: import("./@types/stone").StoneTransaction, type: import("./@types/stone").StoneReceiptType) => Promise<null>;
40
- captureTransaction: (transaction: import("./@types/stone").StoneTransaction) => Promise<import("./@types/stone").StoneCaptureResponse>;
41
- cancelTransaction: (transaction: import("./@types/stone").StoneTransaction) => Promise<import("./@types/stone").StoneCancelResponse>;
39
+ printVia: (transaction: import("./@types").StoneTransaction, type: import("./@types").StoneReceiptType) => Promise<null>;
40
+ captureTransaction: (transaction: import("./@types").StoneTransaction) => Promise<import("./@types").StoneCaptureResponse>;
41
+ cancelTransaction: (transaction: import("./@types").StoneTransaction) => Promise<import("./@types").StoneCancelResponse>;
42
42
  };
43
43
  export { Plugpag, Sunmi, Pax, Paystore, Stone };
44
- export type * from './@types/index.d.ts';
44
+ export type * from './@types';
45
45
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,SAAS,qFACoD,CAAC;AAI3E,QAAA,MAAM,OAAO;;;;;;;CAOZ,CAAC;AACF,QAAA,MAAM,KAAK;;;;qBAKF,MAAM,aACD,MAAM,WACR,OAAO,gBACF,OAAO;;;;CAKvB,CAAC;AACF,QAAA,MAAM,GAAG;;;;;;mBAMQ,MAAM,aAAY,MAAM;;CAGxC,CAAC;AACF,QAAA,MAAM,QAAQ;;;;CAIb,CAAC;AACF,QAAA,MAAM,KAAK;;;;;;;;;CASV,CAAC;AAEF,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,GAAG,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;AAChD,mBAAmB,qBAAqB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,SAAS,qFACoD,CAAC;AAI3E,QAAA,MAAM,OAAO;;;;;;;CAOZ,CAAC;AACF,QAAA,MAAM,KAAK;;;;qBAKF,MAAM,aACD,MAAM,WACR,OAAO,gBACF,OAAO;;;;CAKvB,CAAC;AACF,QAAA,MAAM,GAAG;;;;;;mBAMQ,MAAM,aAAY,MAAM;;CAGxC,CAAC;AACF,QAAA,MAAM,QAAQ;;;;CAIb,CAAC;AACF,QAAA,MAAM,KAAK;;;;;;;;;CASV,CAAC;AAEF,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,GAAG,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;AAChD,mBAAmB,UAAU,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-mesmart",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
4
  "description": "Sunmi P2 utilities and Plugpag wrapper for React Native",
5
5
  "main": "lib/commonjs/index",
6
6
  "module": "lib/module/index",
@@ -0,0 +1,13 @@
1
+ export type PaymentMethod =
2
+ | 'debitCard'
3
+ | 'creditCard'
4
+ | 'pix'
5
+ | 'voucher'
6
+ | 'money'
7
+ | 'bonus';
8
+
9
+ export type * from './plugpag';
10
+ export type * from './paystore';
11
+ export type * from './sunmi';
12
+ export type * from './pax';
13
+ export type * from './stone';
@@ -1,3 +1,15 @@
1
+ export interface PaystoreAPI {
2
+ init: () => Promise<null>;
3
+ pay: (
4
+ value: string,
5
+ transactionId: string,
6
+ showReceipt: boolean,
7
+ paymentType: Array<'CREDIT' | 'DEBIT' | 'VOUCHER'>,
8
+ installments: number
9
+ ) => Promise<null>;
10
+ isActivated: () => Promise<boolean>;
11
+ }
12
+
1
13
  export type PaystorePaymentTypes =
2
14
  | 'CREDIT'
3
15
  | 'DEBIT'
@@ -62,15 +74,3 @@ export interface PaystorePaymentResult {
62
74
  receipt: PaystoreReceipts;
63
75
  value: number;
64
76
  }
65
-
66
- export interface PaystoreAPI {
67
- init: () => Promise<null>;
68
- pay: (
69
- value: string,
70
- transactionId: string,
71
- showReceipt: boolean,
72
- paymentType: Array<'CREDIT' | 'DEBIT' | 'VOUCHER'>,
73
- installments: number
74
- ) => Promise<null>;
75
- isActivated: () => Promise<boolean>;
76
- }
@@ -13,17 +13,3 @@ declare module 'react-native' {
13
13
  Stone: StoneAPI;
14
14
  }
15
15
  }
16
-
17
- export type PaymentMethod =
18
- | 'debitCard'
19
- | 'creditCard'
20
- | 'pix'
21
- | 'voucher'
22
- | 'money'
23
- | 'bonus';
24
-
25
- export * from './plugpag';
26
- export * from './paystore';
27
- export * from './sunmi';
28
- export * from './pax';
29
- export * from './stone';
package/src/index.ts CHANGED
@@ -57,4 +57,4 @@ const Stone = {
57
57
  };
58
58
 
59
59
  export { Plugpag, Sunmi, Pax, Paystore, Stone };
60
- export type * from './@types/index.d.ts';
60
+ export type * from './@types';
@@ -1,61 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- var _plugpag = require("./plugpag");
7
- Object.keys(_plugpag).forEach(function (key) {
8
- if (key === "default" || key === "__esModule") return;
9
- if (key in exports && exports[key] === _plugpag[key]) return;
10
- Object.defineProperty(exports, key, {
11
- enumerable: true,
12
- get: function () {
13
- return _plugpag[key];
14
- }
15
- });
16
- });
17
- var _paystore = require("./paystore");
18
- Object.keys(_paystore).forEach(function (key) {
19
- if (key === "default" || key === "__esModule") return;
20
- if (key in exports && exports[key] === _paystore[key]) return;
21
- Object.defineProperty(exports, key, {
22
- enumerable: true,
23
- get: function () {
24
- return _paystore[key];
25
- }
26
- });
27
- });
28
- var _sunmi = require("./sunmi");
29
- Object.keys(_sunmi).forEach(function (key) {
30
- if (key === "default" || key === "__esModule") return;
31
- if (key in exports && exports[key] === _sunmi[key]) return;
32
- Object.defineProperty(exports, key, {
33
- enumerable: true,
34
- get: function () {
35
- return _sunmi[key];
36
- }
37
- });
38
- });
39
- var _pax = require("./pax");
40
- Object.keys(_pax).forEach(function (key) {
41
- if (key === "default" || key === "__esModule") return;
42
- if (key in exports && exports[key] === _pax[key]) return;
43
- Object.defineProperty(exports, key, {
44
- enumerable: true,
45
- get: function () {
46
- return _pax[key];
47
- }
48
- });
49
- });
50
- var _stone = require("./stone");
51
- Object.keys(_stone).forEach(function (key) {
52
- if (key === "default" || key === "__esModule") return;
53
- if (key in exports && exports[key] === _stone[key]) return;
54
- Object.defineProperty(exports, key, {
55
- enumerable: true,
56
- get: function () {
57
- return _stone[key];
58
- }
59
- });
60
- });
61
- //# sourceMappingURL=index.d.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["_plugpag","require","Object","keys","forEach","key","exports","defineProperty","enumerable","get","_paystore","_sunmi","_pax","_stone"],"sourceRoot":"../../../src","sources":["@types/index.d.ts"],"mappings":";;;;;AAwBA,IAAAA,QAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAH,QAAA,EAAAI,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAL,QAAA,CAAAK,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAT,QAAA,CAAAK,GAAA;IAAA;EAAA;AAAA;AACA,IAAAK,SAAA,GAAAT,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAO,SAAA,EAAAN,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAK,SAAA,CAAAL,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAC,SAAA,CAAAL,GAAA;IAAA;EAAA;AAAA;AACA,IAAAM,MAAA,GAAAV,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAQ,MAAA,EAAAP,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAM,MAAA,CAAAN,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAE,MAAA,CAAAN,GAAA;IAAA;EAAA;AAAA;AACA,IAAAO,IAAA,GAAAX,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAS,IAAA,EAAAR,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAO,IAAA,CAAAP,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAG,IAAA,CAAAP,GAAA;IAAA;EAAA;AAAA;AACA,IAAAQ,MAAA,GAAAZ,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAU,MAAA,EAAAT,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAQ,MAAA,CAAAR,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAI,MAAA,CAAAR,GAAA;IAAA;EAAA;AAAA","ignoreList":[]}
@@ -1,7 +0,0 @@
1
- export * from './plugpag';
2
- export * from './paystore';
3
- export * from './sunmi';
4
- export * from './pax';
5
- export * from './stone';
6
- export {};
7
- //# sourceMappingURL=index.d.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":[],"sourceRoot":"../../../src","sources":["@types/index.d.ts"],"mappings":"AAwBA,cAAc,WAAW;AACzB,cAAc,YAAY;AAC1B,cAAc,SAAS;AACvB,cAAc,OAAO;AACrB,cAAc,SAAS;AAAC","ignoreList":[]}