@soltech/fluid-common 0.1.1 → 0.1.2

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/lib/index.d.ts CHANGED
@@ -8,12 +8,12 @@ export declare enum TraitType {
8
8
  TEXT = "TEXT"
9
9
  }
10
10
  export declare enum PaymentType {
11
- BankTransfer = 0,
12
- CreditCard = 1,
13
- Crypto = 2,
14
- DigitalWallet = 3,
15
- PrepaidCard = 4,
16
- Voucher = 5
11
+ BANK_TRANSFER = 0,
12
+ CREDIT_CARD = 1,
13
+ CRYPTO = 2,
14
+ DIGITAL_WALLET = 3,
15
+ PREPAID_CARD = 4,
16
+ VOUCHER = 5
17
17
  }
18
18
  export interface WalletRequestBody {
19
19
  payload?: object | string;
@@ -51,11 +51,10 @@ export interface PaymentMethod {
51
51
  info: string;
52
52
  paymentType: PaymentType;
53
53
  }
54
- export interface RecentMethod {
54
+ export interface RecentMethod extends PaymentMethod {
55
55
  accountId: string;
56
56
  maskedAccount: string;
57
57
  lastSuccess: string;
58
- paymentMethod: PaymentMethod;
59
58
  }
60
59
  export interface TransactionParams {
61
60
  accountId?: string;
package/lib/index.js CHANGED
@@ -11,10 +11,10 @@ export var TraitType;
11
11
  })(TraitType || (TraitType = {}));
12
12
  export var PaymentType;
13
13
  (function (PaymentType) {
14
- PaymentType[PaymentType["BankTransfer"] = 0] = "BankTransfer";
15
- PaymentType[PaymentType["CreditCard"] = 1] = "CreditCard";
16
- PaymentType[PaymentType["Crypto"] = 2] = "Crypto";
17
- PaymentType[PaymentType["DigitalWallet"] = 3] = "DigitalWallet";
18
- PaymentType[PaymentType["PrepaidCard"] = 4] = "PrepaidCard";
19
- PaymentType[PaymentType["Voucher"] = 5] = "Voucher";
14
+ PaymentType[PaymentType["BANK_TRANSFER"] = 0] = "BANK_TRANSFER";
15
+ PaymentType[PaymentType["CREDIT_CARD"] = 1] = "CREDIT_CARD";
16
+ PaymentType[PaymentType["CRYPTO"] = 2] = "CRYPTO";
17
+ PaymentType[PaymentType["DIGITAL_WALLET"] = 3] = "DIGITAL_WALLET";
18
+ PaymentType[PaymentType["PREPAID_CARD"] = 4] = "PREPAID_CARD";
19
+ PaymentType[PaymentType["VOUCHER"] = 5] = "VOUCHER";
20
20
  })(PaymentType || (PaymentType = {}));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@soltech/fluid-common",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "type": "module",
5
5
  "description": "Fluid frontend and API commons",
6
6
  "main": "lib/index.js",
package/src/index.ts CHANGED
@@ -11,12 +11,12 @@ export enum TraitType {
11
11
  }
12
12
 
13
13
  export enum PaymentType {
14
- BankTransfer,
15
- CreditCard,
16
- Crypto,
17
- DigitalWallet,
18
- PrepaidCard,
19
- Voucher
14
+ BANK_TRANSFER,
15
+ CREDIT_CARD,
16
+ CRYPTO,
17
+ DIGITAL_WALLET,
18
+ PREPAID_CARD,
19
+ VOUCHER
20
20
  }
21
21
 
22
22
  export interface WalletRequestBody {
@@ -61,11 +61,10 @@ export interface PaymentMethod {
61
61
  paymentType: PaymentType;
62
62
  }
63
63
 
64
- export interface RecentMethod {
64
+ export interface RecentMethod extends PaymentMethod {
65
65
  accountId: string;
66
66
  maskedAccount: string;
67
67
  lastSuccess: string;
68
- paymentMethod: PaymentMethod; //TODO extend PaymentMethod instead
69
68
  }
70
69
 
71
70
  export interface TransactionParams {